Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 918664 - dev-qt/qtdeclarative-6.6.1 - FAILED: .../24bittextmask.frag.qsb
Summary: dev-qt/qtdeclarative-6.6.1 - FAILED: .../24bittextmask.frag.qsb
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Qt Bug Alias
URL:
Whiteboard: fixed in qtbase-6.6.1-r1
Keywords:
: 918712 (view as bug list)
Depends on:
Blocks: gcc-14
  Show dependency tree
 
Reported: 2023-11-27 15:30 UTC by Toralf Förster
Modified: 2024-11-01 18:46 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge-info.txt (emerge-info.txt,18.79 KB, text/plain)
2023-11-27 15:30 UTC, Toralf Förster
Details
dev-qt:qtdeclarative-6.6.1:20231127-145643.log (dev-qt:qtdeclarative-6.6.1:20231127-145643.log,61.53 KB, text/plain)
2023-11-27 15:30 UTC, Toralf Förster
Details
emerge-history.txt (emerge-history.txt,136.38 KB, text/plain)
2023-11-27 15:31 UTC, Toralf Förster
Details
environment (environment,101.05 KB, text/plain)
2023-11-27 15:31 UTC, Toralf Förster
Details
etc.clang.tar.xz (etc.clang.tar.xz,964 bytes, application/x-xz)
2023-11-27 15:31 UTC, Toralf Förster
Details
etc.portage.tar.xz (etc.portage.tar.xz,11.13 KB, application/x-xz)
2023-11-27 15:31 UTC, Toralf Förster
Details
qlist-info.txt (qlist-info.txt,239.25 KB, text/plain)
2023-11-27 15:31 UTC, Toralf Förster
Details
temp.tar.xz (temp.tar.xz,28.55 KB, application/x-xz)
2023-11-27 15:31 UTC, Toralf Förster
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Toralf Förster gentoo-dev 2023-11-27 15:30:56 UTC
too long lines were shrinked:

[51/3069] cd /var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1/src/qmllocalstorage && /usr/bin/cmake -DIN_FILE=/var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/qmllocalstorage/QmlLocalStorage.version.in -DPRIVATE_CONTENT_
[52/3069] cd /var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1/src/qmlxmllistmodel && /usr/bin/cmake -DIN_FILE=/var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/qmlxmllistmodel/qmlxmllistmodelplugin.version.in -DPRIVATE_CO
[53/3069] cd /var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/qmlxmllistmodel && /usr/bin/cmake "-DIN_FILES=/var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/qmlxmllistmodel/qt_lib_qmlxmllistmodel_private.pri;/v
[54/3069] cd /var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/qmlxmllistmodel && /usr/lib64/qt6/libexec/syncqt @/var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/qmlxmllistmodel/QmlXmlListModel_syncqt_args && /u
[55/3069] cd /var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1/src/qmlxmllistmodel && /usr/bin/cmake -DIN_FILE=/var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/qmlxmllistmodel/QmlXmlListModel.version.in -DPRIVATE_CONTENT_
[56/3069] cd /var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quick && /usr/lib64/qt6/bin/qsb --glsl 100es,120,150 --hlsl 50 --msl 12 -b -O -s -o /var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quick/.qsb/scen
FAILED: src/quick/.qsb/scenegraph/shaders_ng/24bittextmask.frag.qsb /var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quick/.qsb/scenegraph/shaders_ng/24bittextmask.frag.qsb 
cd /var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quick && /usr/lib64/qt6/bin/qsb --glsl 100es,120,150 --hlsl 50 --msl 12 -b -O -s -o /var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quick/.qsb/scenegraph/sha
[57/3069] cd /var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/qmlxmllistmodel && /usr/bin/cmake -E cmake_autogen /var/tmp/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/qmlxmllistmodel/CMakeFiles/QmlXmlListModel_autog

  -------------------------------------------------------------------

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 17.1_no_multilib_systemd_merged_usr-20231123-151505

  -------------------------------------------------------------------

gcc-config -l:
 [1] x86_64-pc-linux-gnu-14 *
clang/llvm (if any):
clang version 17.0.5
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/lib/llvm/17/bin
Configuration file: /etc/clang/x86_64-pc-linux-gnu-clang.cfg
/usr/lib/llvm/17
17.0.5
Python 3.11.6
Available Ruby profiles:
  [1]   ruby31 (with Rubygems) *
Available Rust versions:
  [1]   rust-bin-1.73.0 *
The following VMs are available for generation-2:
1)	Eclipse Temurin JDK 17.0.8.1_p1 [openjdk-bin-17]
*)	Eclipse Temurin JDK 21.0.1_p12 [openjdk-bin-21]
3)	Eclipse Temurin JDK 8.382_p05 [openjdk-bin-8]
Available Java Virtual Machines:
  [1]   openjdk-bin-8 
  [2]   openjdk-bin-17 
  [3]   openjdk-bin-21  system-vm

The Glorious Glasgow Haskell Compilation System, version 9.2.8
php cli (if any):
go version go1.21.4 linux/amd64

  HEAD of ::gentoo
commit 65f8a9de0ee73a05f0c79ffbb937ca7de0a45d39
Author: Repository mirror & CI <repomirrorci@gentoo.org>
Date:   Mon Nov 27 13:31:58 2023 +0000

    2023-11-27 13:31:58 UTC

emerge -qpvO dev-qt/qtdeclarative
[ebuild     U ] dev-qt/qtdeclarative-6.6.1 [6.6.0] USE="opengl sql widgets -test -vulkan"
Comment 1 Toralf Förster gentoo-dev 2023-11-27 15:30:57 UTC
Created attachment 875821 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2023-11-27 15:30:59 UTC
Created attachment 875822 [details]
dev-qt:qtdeclarative-6.6.1:20231127-145643.log
Comment 3 Toralf Förster gentoo-dev 2023-11-27 15:31:00 UTC
Created attachment 875823 [details]
emerge-history.txt
Comment 4 Toralf Förster gentoo-dev 2023-11-27 15:31:01 UTC
Created attachment 875824 [details]
environment
Comment 5 Toralf Förster gentoo-dev 2023-11-27 15:31:02 UTC
Created attachment 875825 [details]
etc.clang.tar.xz
Comment 6 Toralf Förster gentoo-dev 2023-11-27 15:31:03 UTC
Created attachment 875826 [details]
etc.portage.tar.xz
Comment 7 Toralf Förster gentoo-dev 2023-11-27 15:31:05 UTC
Created attachment 875827 [details]
qlist-info.txt
Comment 8 Toralf Förster gentoo-dev 2023-11-27 15:31:06 UTC
Created attachment 875828 [details]
temp.tar.xz
Comment 9 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-27 21:16:46 UTC
tentatively blocking gcc-14
Comment 10 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-28 01:18:17 UTC
can't yet reproduce it
Comment 11 Ionen Wolkens gentoo-dev 2023-11-28 04:39:10 UTC
(In reply to Sam James from comment #10)
> can't yet reproduce it
Just gave it a quick try as well by building the whole Qt stack with gcc:14, but can't reproduce either (clang/musl is fine too).

I did triple-check that the SIGSTKSZ from bug #915695 is there in 6.6.1 (did remove the old [8192] patch, SIGSTKSZ gives me 8192 too) so I'd assume it's not the return of the same bug, but who knows if there's something more to it that only specific people will be able to reproduce again.

On a side-note, I wish this was using samurai because samurai was actually able to display that it was a segfault for people hitting bug #915695. Ninja shows nothing, so can't be sure what happened (doesn't help that Qt sends qsb output to /dev/null because it's noisy, see patch at bug #915695 comment #2).
Comment 12 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-29 03:31:09 UTC
With samu:
```
[441/3069] cd /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quickshapes && /usr/lib64/qt6/bin/qsb --glsl 100es,120,150 --hlsl 50 --msl 12 -b -O -s -D USE_DERIVATIVES -o /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quickshapes/.qsb/shaders_ng/shapecurve_derivatives.vert.qsb /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1/src/quickshapes/shaders_ng/shapecurve.vert
samu: job terminated due to signal 11: cd /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quickshapes && /usr/lib64/qt6/bin/qsb --glsl 100es,120,150 --hlsl 50 --msl 12 -b -O -s -o /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quickshapes/.qsb/shaders_ng/wireframe.vert.qsb /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1/src/quickshapes/shaders_ng/wireframe.vert
samu: job terminated due to signal 11: cd /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quickshapes && /usr/lib64/qt6/bin/qsb --glsl 100es,120,150 --hlsl 50 --msl 12 -b -O -s -D RADIALGRADIENT -D USE_DERIVATIVES -o /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quickshapes/.qsb/shaders_ng/shapecurve_rg_derivatives.frag.qsb /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1/src/quickshapes/shaders_ng/shapecurve.frag
[...]
```

In dmesg:
```
[83316.496939] Code: Unable to access opcode bytes at 0xffffffffffffffd6.
[83316.497917] qsb[27695]: segfault at 0 ip 0000000000000000 sp 00007ffd3f9c39b0 error 14 in qsb[55f447e36000+4000] likely on CPU 10 (core 2, socket 0)
[83316.497925] Code: Unable to access opcode bytes at 0xffffffffffffffd6.
[83316.498824] qsb[27701]: segfault at 0 ip 0000000000000000 sp 00007ffdf200ad70 error 14 in qsb[56425a731000+4000] likely on CPU 2 (core 2, socket 0)
[83316.498832] Code: Unable to access opcode bytes at 0xffffffffffffffd6.
[83316.499600] qsb[27698]: segfault at 0 ip 0000000000000000 sp 00007ffdb3068690 error 14 in qsb[562a4c4a6000+4000] likely on CPU 0 (core 0, socket 0)
[83316.499609] Code: Unable to access opcode bytes at 0xffffffffffffffd6.
[83316.500039] qsb[27683]: segfault at 0 ip 0000000000000000 sp 00007ffe64af68d0 error 14 in qsb[559657f8d000+4000] likely on CPU 15 (core 7, socket 0)
[83316.500048] Code: Unable to access opcode bytes at 0xffffffffffffffd6.
```

Works for me when running as root, fails under sandbox.

```
/var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quickshapes # (cd /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quickshapes && /usr/lib64/qt6/bin/qsb --glsl 100es,120,150 --hlsl 50 --msl 12 -b -O -s -D USE_DERIVATIVES -o /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quickshapes/.qsb/shaders_ng//shapecurve_derivatives.vert.qsb /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1/src/quickshapes/shaders_ng/shapecurve.vert) ; echo $?
0
```

```
/var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quickshapes # sandbox
============================= Gentoo path sandbox ==============================
Detection of the support files.
Verification of the required files.
Setting up the required environment variables.
The protected environment has been started.
--------------------------------------------------------------------------------
Process being started in forked instance.

/var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quickshapes # (cd /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quickshapes && /usr/lib64/qt6/bin/qsb --glsl 100es,120,150 --hlsl 50 --msl 12 -b -O -s -D USE_DERIVATIVES -o /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1_build/src/quickshapes/.qsb/shaders_ng//shapecurve_derivatives.vert.qsb /var/tmp/portage/portage/dev-qt/qtdeclarative-6.6.1/work/qtdeclarative-everywhere-src-6.6.1/src/quickshapes/shaders_ng/shapecurve.vert)
Segmentation fault (core dumped)
```
Comment 13 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-29 03:31:42 UTC
stack is hosed and coredump is completely useless
Comment 14 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-29 03:43:33 UTC
we blow up in system_vforkfd (again)

```
#0  system_vforkfd (system=<synthetic pointer>, token=0x7fffffffd280, childFn=0x7ffff67214a0 <_FUN(void*)>, ppid=0x5555555b6968, flags=0x1)
    at /usr/src/debug/dev-qt/qtbase-6.6.1/qtbase-everywhere-src-6.6.1/src/corelib/io/../../3rdparty/forkfd/forkfd_linux.c:162
#1  vforkfd (flags=0x1, ppid=0x5555555b6968, childFn=0x7ffff67214a0 <_FUN(void*)>, token=0x7fffffffd280)
    at /usr/src/debug/dev-qt/qtbase-6.6.1/qtbase-everywhere-src-6.6.1/src/corelib/io/../../3rdparty/forkfd/forkfd.c:814
#2  0x00007ffff6722d41 in QProcessPrivate::startProcess (this=0x5555555b66d0) at /usr/src/debug/dev-qt/qtbase-6.6.1/qtbase-everywhere-src-6.6.1/src/corelib/io/qprocess_unix.cpp:607
#3  0x000055555555f781 in runProcess (binary=..., arguments=..., output=output@entry=0x7fffffffd8f0, errorOutput=errorOutput@entry=0x7fffffffd910) at /usr/include/qt6/QtCore/qflags.h:74
#4  0x000055555555ca88 in main (argc=<optimized out>, argv=<optimized out>) at /usr/src/debug/dev-qt/qtshadertools-6.6.1/qtshadertools-everywhere-src-6.6.1/tools/qsb/qsb.cpp:783
```

```
(gdb) p SIGSTKSZ
$6 = 0x38c0
```

then explodes when we call clone
Comment 15 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-29 03:53:50 UTC
There's no portable way on Linux to figure out how much stack you've got left but I'm not even sure what we're supposed to do here, either, as SIGSTKSZ is still just a recommendation:
```
commit 17cef890c95a71671ec80b1daac88aef7ca46a90
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Jul 10 10:56:50 2021 -0700

    support: Replace _SC_MINSIGSTKSZ with _SC_SIGSTKSZ

    Replace _SC_MINSIGSTKSZ with _SC_SIGSTKSZ since sysconf (_SC_MINSIGSTKSZ)
    returns the minimum number of bytes of free stack space required in order
    to guarantee successful, non-nested handling of a single signal whose
    handler is an empty function while sysconf (_SC_SIGSTKSZ) returns the
    suggested minimum number of bytes of stack space required for a signal
    stack.

    Reviewed-by: Carlos O'Donell <carlos@redhat.com>
```
Comment 16 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-29 04:00:20 UTC
gnulib ended up just doing 64kb. We should probably do at least 32k like floppym mentioned in the original upstream review (https://sourceware.org/git/?p=glibc.git;a=blob;f=sysdeps/unix/sysv/linux/spawni.c#l354, https://codereview.qt-project.org/c/qt/qtbase/+/513140/comments/779b80a3_f5f0247c).
Comment 17 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-29 04:12:52 UTC
*** Bug 918712 has been marked as a duplicate of this bug. ***
Comment 18 Ionen Wolkens gentoo-dev 2023-11-29 04:35:47 UTC
(In reply to Sam James from comment #16)
> gnulib ended up just doing 64kb. We should probably do at least 32k like
> floppym mentioned in the original upstream review
Guess I'll go ahead and do 32k downstream now and see if these stop.
Comment 19 Larry the Git Cow gentoo-dev 2023-11-29 05:36:51 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=313ee5bd17f851405ea0f9176797bc7355a9e648

commit 313ee5bd17f851405ea0f9176797bc7355a9e648
Author:     Ionen Wolkens <ionen@gentoo.org>
AuthorDate: 2023-11-29 04:44:24 +0000
Commit:     Ionen Wolkens <ionen@gentoo.org>
CommitDate: 2023-11-29 05:36:15 +0000

    dev-qt/qtbase: re-add forkfd stacksize patch but with 32k
    
    Bug: https://bugs.gentoo.org/918664
    Bug: https://bugs.gentoo.org/915695
    Signed-off-by: Ionen Wolkens <ionen@gentoo.org>

 .../qtbase-6.6.1-forkfd-childstack-size.patch      | 23 ++++++++++++++++++++++
 ...{qtbase-6.6.1.ebuild => qtbase-6.6.1-r1.ebuild} |  1 +
 dev-qt/qtbase/qtbase-6.6.9999.ebuild               |  1 +
 dev-qt/qtbase/qtbase-6.9999.ebuild                 |  1 +
 4 files changed, 26 insertions(+)
Comment 20 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-29 06:17:47 UTC
built fine, thanks!
Comment 21 Ionen Wolkens gentoo-dev 2023-11-29 14:10:13 UTC
(In reply to Sam James from comment #20)
> built fine, thanks!
Thanks, guess I'll close and see if get new bugs.