Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 916519 - dev-lang/python-3.11.6: crashes during build when bulit with sys-devel/gcc-14 on hppa
Summary: dev-lang/python-3.11.6: crashes during build when bulit with sys-devel/gcc-14...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: HPPA Linux
: Normal normal (vote)
Assignee: Python Gentoo Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: gcc-14
  Show dependency tree
 
Reported: 2023-10-30 06:27 UTC by Sam James
Modified: 2024-02-13 20:06 UTC (History)
2 users (show)

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


Attachments
build.log (file_916519.txt,113.05 KB, text/plain)
2023-10-30 06:27 UTC, Sam James
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-10-30 06:27:54 UTC
Created attachment 873699 [details]
build.log

Really just filing this so we don't forget about it and can come back to it later.

--

hppa2.0-unknown-linux-gnu-gcc -c -Wsign-compare -DNDEBUG     -O2 -pipe -march=2.0 -fdiagnostics-color=always -frecord-gcc-switches -ggdb3 -fwrapv -std=c11 -Wextra -Wno-unused-parameter -Wno-missing-field-init
ializers -Wstrict-prototypes -Werror=implicit-function-declaration -fvisibility=hidden  -I./Include/internal  -I. -I./Include -I/usr/include/ncursesw  -fPIC -DPy_BUILD_CORE -o Python/frozen.o Python/frozen.c
./_bootstrap_python ./Tools/scripts/deepfreeze.py \
Python/frozen_modules/importlib._bootstrap.h:importlib._bootstrap \
Python/frozen_modules/importlib._bootstrap_external.h:importlib._bootstrap_external \
Python/frozen_modules/zipimport.h:zipimport \
Python/frozen_modules/abc.h:abc \
Python/frozen_modules/codecs.h:codecs \
Python/frozen_modules/io.h:io \
Python/frozen_modules/_collections_abc.h:_collections_abc \
Python/frozen_modules/_sitebuiltins.h:_sitebuiltins \
Python/frozen_modules/genericpath.h:genericpath \
Python/frozen_modules/ntpath.h:ntpath \
Python/frozen_modules/posixpath.h:posixpath \
Python/frozen_modules/os.h:os \
Python/frozen_modules/site.h:site \
Python/frozen_modules/stat.h:stat \
Python/frozen_modules/importlib.util.h:importlib.util \
Python/frozen_modules/importlib.machinery.h:importlib.machinery \
Python/frozen_modules/runpy.h:runpy \
Python/frozen_modules/__hello__.h:__hello__ \
Python/frozen_modules/__phello__.h:__phello__ \
Python/frozen_modules/__phello__.ham.h:__phello__.ham \
Python/frozen_modules/__phello__.ham.eggs.h:__phello__.ham.eggs \
Python/frozen_modules/__phello__.spam.h:__phello__.spam \
Python/frozen_modules/frozen_only.h:frozen_only \
-o Python/deepfreeze/deepfreeze.c
make: *** [Makefile:1298: Python/deepfreeze/deepfreeze.c] Segmentation fault (core dumped)
make: *** Waiting for unfinished jobs....
hppa2.0-unknown-linux-gnu-gcc -c -I./Modules/_decimal/libmpdec -DCONFIG_32=1 -DANSI=1 -Wsign-compare -DNDEBUG     -O2 -pipe -march=2.0 -fdiagnostics-color=always -frecord-gcc-switches -ggdb3 -fwrapv -std=c11 -Wextra -Wno-unused-parameter -Wno-missing-field-initializers -Wstrict-prototypes -Werror=implicit-function-declaration -fvisibility=hidden  -I./Include/internal  -I. -I./Include -I/usr/include/ncursesw  -fPIC -fPIC -o Modules/_decimal/libmpdec/mpdecimal.o ./Modules/_decimal/libmpdec/mpdecimal.c
 * ERROR: dev-lang/python-3.11.6::gentoo failed (compile phase):
 *   emake failed

--

# emerge --info
Portage 3.0.54 (python 3.11.5-final-0, default/linux/hppa/17.0/systemd/merged-usr, gcc-14, glibc-2.37-r7, 6.5.9 parisc64)
=================================================================
System uname: Linux-6.5.9-parisc64-PA8900_-Shortfin-with-glibc2.37
KiB Mem:     8195528 total,   5237976 free
KiB Swap:    4194300 total,   4194300 free
Timestamp of repository gentoo: Mon, 30 Oct 2023 05:46:53 +0000
Head commit of repository gentoo: d38a35e6ff96398de3ce419a5221a16a4b82caf0

Timestamp of repository sam_c: Sun, 29 Oct 2023 04:03:15 +0000
Head commit of repository sam_c: efb140f3ff80c29b9306f88f247420faaf9599ec

sh dash 0.5.12
ld GNU ld (Gentoo 2.40 p5) 2.40.0
ccache version 4.7.4 [disabled]
app-misc/pax-utils:        1.3.5::gentoo
app-shells/bash:           5.1_p16-r6::gentoo
dev-lang/perl:             5.38.0-r1::gentoo
dev-lang/python:           3.11.5::gentoo
dev-util/ccache:           4.7.4::gentoo
dev-util/cmake:            3.26.5-r2::gentoo
dev-util/meson:            1.2.1-r1::gentoo
sys-apps/baselayout:       2.14::gentoo
sys-apps/sandbox:          2.38::gentoo
sys-apps/systemd:          253.6::gentoo
sys-devel/autoconf:        2.71-r6::gentoo
sys-devel/automake:        1.16.5-r1::gentoo
sys-devel/binutils:        2.40-r5::gentoo
sys-devel/binutils-config: 5.5::gentoo
sys-devel/gcc:             12.3.1_p20230526::gentoo, 14.0.0_pre20231022-r1::gentoo
sys-devel/gcc-config:      2.11::gentoo
sys-devel/libtool:         2.4.7-r1::gentoo
sys-devel/make:            4.4.1-r1::gentoo
sys-kernel/linux-headers:  6.1::gentoo (virtual/os-headers)
sys-libs/glibc:            2.37-r7::gentoo
Repositories:

gentoo
    location: /var/db/repos/gentoo
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/gentoo.git
    priority: -1000
    eclass-overrides: local
    volatile: False
    sync-git-verify-commit-signature: yes
    sync-git-clone-extra-opts: -b stable -c gc.reflogExpire=0 -c gc.reflogExpireUnreachable=0 -c gc.rerereresolved=0 -c gc.rerereunresolved=0 -c gc.pruneExpire=now

local
    location: /var/db/repos/local
    masters: gentoo
    eclass-overrides: local
    volatile: False

sam_c
    location: /var/db/repos/sam_c
    sync-type: git
    sync-uri: https://github.com/gentoo-mirror/sam_c.git
    masters: gentoo
    eclass-overrides: local
    volatile: False

ACCEPT_KEYWORDS="hppa"
ACCEPT_LICENSE="@FREE"
CBUILD="hppa2.0-unknown-linux-gnu"
CFLAGS="-O2 -pipe -march=2.0 -fdiagnostics-color=always -frecord-gcc-switches"
CHOST="hppa2.0-unknown-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d"
CXXFLAGS="-O2 -pipe -march=2.0 -fdiagnostics-color=always -frecord-gcc-switches"
DISTDIR="/var/cache/distfiles"
EMERGE_DEFAULT_OPTS="--keep-going --usepkg=y"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GDK_PIXBUF_MODULE_FILE GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR XDG_STATE_HOME"
FCFLAGS="-O2 -pipe -march=2.0 -fdiagnostics-color=always -frecord-gcc-switches"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs binpkg-multi-instance buildpkg buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles ipc-sandbox merge-sync mount-sandbox multilib-strict network-sandbox news parallel-fetch parallel-install pid-sandbox pkgdir-index-trusted preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe -march=2.0 -fdiagnostics-color=always -frecord-gcc-switches"
GENTOO_MIRRORS="https://mirrors.gethosted.online/gentoo/ https://www.mirrorservice.org/sites/distfiles.gentoo.org/ https://mirror.bytemark.co.uk/gentoo/ https://mirrors.soeasyto.com/distfiles.gentoo.org/"
LANG="en_GB.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,--defsym=__gentoo_check_ldflags__=0"
LEX="flex"
LINGUAS="en en_GB"
PKGDIR="/var/cache/binpkgs"
PORTAGE_COMPRESS="xz"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
SHELL="/bin/bash"
USE="PIC acl bash-completion big-endian bzip2 caps cli crypt filecaps firewalld fortran gdbm gmp hardened hppa hunspell iconv ipv6 jit ncurses nls nptl openmp pam pcre pie readline seccomp ssl system-av1 system-binutils system-boost system-bootstrap system-cairo system-clang system-digest system-ffmpeg system-harfbuzz system-heimdal system-icu system-jpeg system-leveldb system-libevent system-libs system-libyaml system-lz4 system-mitkrb5 system-sqlite system-ssl system-tbb system-uulib system-webp system-zlib systemd udev unicode verify-sig xattr zlib zsh-completion" ADA_TARGET="gnat_2021" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="libinput" KERNEL="linux" L10N="en en-GB" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php8-1" POSTGRES_TARGETS="postgres15" PYTHON_SINGLE_TARGET="python3_11" PYTHON_TARGETS="python3_11" RUBY_TARGETS="ruby31" VIDEO_CARDS="fbdev dummy v4l" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LC_ALL, LD, LFLAGS, LIBTOOL, MAKE, MAKEFLAGS, MAKEOPTS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS
Comment 1 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-10-30 06:28:59 UTC
(gdb) r
Starting program: /var/tmp/portage/dev-lang/python-3.11.6/work/Python-3.11.6/_bootstrap_python ./Tools/scripts/deepfreeze.py Python/frozen_modules/importlib._bootstrap.h:importlib._bootstrap Python/frozen_modules/importlib._bootstrap_external.h:importlib._bootstrap_external Python/frozen_modules/zipimport.h:zipimport Python/frozen_modules/abc.h:abc Python/frozen_modules/codecs.h:codecs Python/frozen_modules/io.h:io Python/frozen_modules/_collections_abc.h:_collections_abc Python/frozen_modules/_sitebuiltins.h:_sitebuiltins Python/frozen_modules/genericpath.h:genericpath Python/frozen_modules/ntpath.h:ntpath Python/frozen_modules/posixpath.h:posixpath Python/frozen_modules/os.h:os Python/frozen_modules/site.h:site Python/frozen_modules/stat.h:stat Python/frozen_modules/importlib.util.h:importlib.util Python/frozen_modules/importlib.machinery.h:importlib.machinery Python/frozen_modules/runpy.h:runpy Python/frozen_modules/__hello__.h:__hello__ Python/frozen_modules/__phello__.h:__phello__ Python/frozen_modules/__phello__.ham.h:__phello__.ham Python/frozen_modules/__phello__.ham.eggs.h:__phello__.ham.eggs Python/frozen_modules/__phello__.spam.h:__phello__.spam Python/frozen_modules/frozen_only.h:frozen_only -o Python/deepfreeze/deepfreeze.c
warning: File "/usr/lib/libthread_db.so.1" auto-loading has been declined by your `auto-load safe-path' set to "$debugdir:$datadir/auto-load".
To enable execution of this file add
        add-auto-load-safe-path /usr/lib/libthread_db.so.1
line to your configuration file "/root/.config/gdb/gdbinit".
To completely disable this security protection add
        set auto-load safe-path /
line to your configuration file "/root/.config/gdb/gdbinit".
For more information about this security protection see the
"Auto-loading safe path" section in the GDB manual.  E.g., run from the shell:
        info "(gdb)Auto-loading safe path"
warning: Unable to find libthread_db matching inferior's thread library, thread debugging will not be available.

Program received signal SIGSEGV, Segmentation fault.
0x412083fc in _PyST_GetSymbol (name=0xf9a33a60, ste=<optimized out>) at Python/symtable.c:396
396         PyObject *v = PyDict_GetItemWithError(ste->ste_symbols, name);
(gdb) bt
#0  0x412083fc in _PyST_GetSymbol (name=0xf9a33a60, ste=<optimized out>) at Python/symtable.c:396
#1  _PyST_GetScope (ste=<optimized out>, name=0xf9a33a60) at Python/symtable.c:406
#2  0x411bb8f8 in compiler_nameop (c=0xf7b03b88, name=<optimized out>, ctx=Load) at Python/compile.c:4274
#3  0x411be074 in compiler_visit_expr (c=0x1, e=<optimized out>) at Python/compile.c:5969
#4  0x411bcc88 in compiler_visit_expr1 (c=0xf7b03b88, e=0x1) at Python/compile.c:5915
#5  0x411be074 in compiler_visit_expr (c=0x1, e=<optimized out>) at Python/compile.c:5969
#6  0x411bceac in compiler_call (e=0x1, c=0xf7b03b88) at Python/compile.c:4952
#7  compiler_visit_expr1 (c=0xf7b03b88, e=0x1) at Python/compile.c:5905
#8  0x411c1f34 in compiler_visit_expr (e=<optimized out>, c=0xf9a33a60) at Python/compile.c:5969
#9  compiler_decorators (decos=0x8d, c=0xf9a33a60) at Python/compile.c:2327
#10 compiler_class (c=0xf9a33a60, s=0x414e4490) at Python/compile.c:2702
#11 0x411c566c in compiler_body (c=0xf7b03b88, stmts=0xf9a33a60) at Python/compile.c:2180
#12 0x411c7e98 in compiler_mod (mod=0xf7b03b88, c=0x0) at Python/compile.c:2197
#13 _PyAST_Compile (mod=0xf7b03b88, filename=0x8d, flags=<optimized out>, optimize=<optimized out>, arena=<optimized out>) at Python/compile.c:581
#14 0x411fe7b8 in Py_CompileStringObject (str=0xf7b03b88 "\371\240\277\220\371\236\353`\371\257\221\260\367\260:t", filename=0x8d, start=-139445336, flags=0xf9a33a60, optimize=<optimized out>)
    at Python/pythonrun.c:1799
#15 0x4119c334 in builtin_compile_impl (module=<optimized out>, feature_version=<optimized out>, optimize=<optimized out>, dont_inherit=<optimized out>, flags=<optimized out>, mode=<optimized out>,
    filename=0xf998db68, source=0x8d) at Python/bltinmodule.c:831
#16 builtin_compile (module=<optimized out>, args=<optimized out>, nargs=<optimized out>, kwnames=<optimized out>) at Python/clinic/bltinmodule.c.h:328
#17 0x410f3ae4 in cfunction_vectorcall_FASTCALL_KEYWORDS (func=0xf9a33a60, args=0x8d, nargsf=<optimized out>, kwnames=<optimized out>) at ./Include/cpython/methodobject.h:52
#18 0x4109fa88 in _PyVectorcall_Call (tstate=0xf7b03b88, func=<optimized out>, callable=0xf9a33a60, tuple=<optimized out>, kwargs=<optimized out>) at Objects/call.c:257
#19 0x4109fd28 in _PyObject_Call (tstate=0xf9a33a60, callable=0x1, args=0xf7b03ba8, kwargs=0x8d) at Objects/call.c:328
#20 0x4109fdb8 in PyObject_Call () at Objects/call.c:352
#21 0x411a47c8 in do_call_core (tstate=0x8d, func=0x1, callargs=0xf9a33a60, kwdict=0xf7b03b88, use_tracing=<optimized out>) at Python/ceval.c:7315
#22 0x411ab5dc in _PyEval_EvalFrameDefault (tstate=0xf7b03ba8, frame=0xf9a33a60, throwflag=1) at Python/ceval.c:5367
#23 0x411af42c in _PyEval_EvalFrame (throwflag=0, frame=0xf9a33a60, tstate=0x1) at ./Include/internal/pycore_ceval.h:73
#24 _PyEval_Vector (tstate=0x1, func=<optimized out>, locals=<optimized out>, args=<optimized out>, argcount=<optimized out>, kwnames=<optimized out>) at Python/ceval.c:6425
#25 0x4109fe48 in _PyFunction_Vectorcall (func=<optimized out>, stack=<optimized out>, nargsf=<optimized out>, kwnames=<optimized out>) at Objects/call.c:396
#26 0x410a0a0c in _PyObject_VectorcallTstate (kwnames=0x0, nargsf=<optimized out>, args=0xf998db68, callable=0xf7b03b88, tstate=0xf7b03ba8) at ./Include/internal/pycore_call.h:92
#27 object_vacall (tstate=0xf7b03ba8, base=<optimized out>, callable=0xf7b03b88, vargs=<optimized out>) at Objects/call.c:819
#28 0x410a0be0 in PyObject_CallMethodObjArgs (obj=<optimized out>, name=<optimized out>) at Objects/call.c:879
#29 0x411dd9e8 in import_find_and_load (abs_name=0xf7b03ba8, tstate=0xf9a33a60) at Python/import.c:1737
#30 PyImport_ImportModuleLevelObject (name=0x1, globals=<optimized out>, locals=<optimized out>, fromlist=0xf7b03b88, level=<optimized out>) at Python/import.c:1836
#31 0x411aefbc in import_name (level=<optimized out>, fromlist=<optimized out>, name=<optimized out>, frame=<optimized out>, tstate=<optimized out>) at Python/ceval.c:7415
#32 _PyEval_EvalFrameDefault (tstate=0xf7b03ba8, frame=0xf9a33a60, throwflag=1) at Python/ceval.c:3937
#33 0x411af42c in _PyEval_EvalFrame (throwflag=0, frame=0xf9a33a60, tstate=0x1) at ./Include/internal/pycore_ceval.h:73
#34 _PyEval_Vector (tstate=0x1, func=<optimized out>, locals=<optimized out>, args=<optimized out>, argcount=<optimized out>, kwnames=<optimized out>) at Python/ceval.c:6425
#35 0x411af4e4 in PyEval_EvalCode (co=0xf9a33a60, globals=<optimized out>, locals=0xf7b03b88) at Python/ceval.c:1140
#36 0x4119b6d4 in builtin_exec_impl (module=<optimized out>, closure=<optimized out>, locals=0xf7b03ba8, globals=0x8d, source=0xf998db68) at Python/bltinmodule.c:1077
#37 builtin_exec (module=<optimized out>, args=<optimized out>, nargs=<optimized out>, kwnames=<optimized out>) at Python/clinic/bltinmodule.c.h:465
#38 0x410f3ae4 in cfunction_vectorcall_FASTCALL_KEYWORDS (func=0xf9a33a60, args=0x8d, nargsf=<optimized out>, kwnames=<optimized out>) at ./Include/cpython/methodobject.h:52
#39 0x4109fa14 in _PyVectorcall_Call (tstate=0xf7b03b88, func=<optimized out>, callable=0xf9a33a60, tuple=<optimized out>, kwargs=<optimized out>) at Objects/call.c:245
#40 0x4109fd28 in _PyObject_Call (tstate=0xf9a33a60, callable=0x1, args=0xf7b03ba8, kwargs=0x8d) at Objects/call.c:328
#41 0x4109fdb8 in PyObject_Call () at Objects/call.c:352
#42 0x411a47c8 in do_call_core (tstate=0x8d, func=0x1, callargs=0xf9a33a60, kwdict=0xf7b03b88, use_tracing=<optimized out>) at Python/ceval.c:7315
#43 0x411ab5dc in _PyEval_EvalFrameDefault (tstate=0xf7b03ba8, frame=0xf9a33a60, throwflag=1) at Python/ceval.c:5367
#44 0x411af42c in _PyEval_EvalFrame (throwflag=0, frame=0xf9a33a60, tstate=0x1) at ./Include/internal/pycore_ceval.h:73
#45 _PyEval_Vector (tstate=0x1, func=<optimized out>, locals=<optimized out>, args=<optimized out>, argcount=<optimized out>, kwnames=<optimized out>) at Python/ceval.c:6425
#46 0x4109fe48 in _PyFunction_Vectorcall (func=<optimized out>, stack=<optimized out>, nargsf=<optimized out>, kwnames=<optimized out>) at Objects/call.c:396
--Type <RET> for more, q to quit, c to continue without paging--
#47 0x410a0a0c in _PyObject_VectorcallTstate (kwnames=0x0, nargsf=<optimized out>, args=0xf998db68, callable=0xf7b03b88, tstate=0xf7b03ba8) at ./Include/internal/pycore_call.h:92
#48 object_vacall (tstate=0xf7b03ba8, base=<optimized out>, callable=0xf7b03b88, vargs=<optimized out>) at Objects/call.c:819
#49 0x410a0be0 in PyObject_CallMethodObjArgs (obj=<optimized out>, name=<optimized out>) at Objects/call.c:879
#50 0x411dd9e8 in import_find_and_load (abs_name=0xf7b03ba8, tstate=0xf9a33a60) at Python/import.c:1737
#51 PyImport_ImportModuleLevelObject (name=0x1, globals=<optimized out>, locals=<optimized out>, fromlist=0xf7b03b88, level=<optimized out>) at Python/import.c:1836
#52 0x411aefbc in import_name (level=<optimized out>, fromlist=<optimized out>, name=<optimized out>, frame=<optimized out>, tstate=<optimized out>) at Python/ceval.c:7415
#53 _PyEval_EvalFrameDefault (tstate=0xf7b03ba8, frame=0xf9a33a60, throwflag=1) at Python/ceval.c:3937
#54 0x411af42c in _PyEval_EvalFrame (throwflag=0, frame=0xf9a33a60, tstate=0x1) at ./Include/internal/pycore_ceval.h:73
#55 _PyEval_Vector (tstate=0x1, func=<optimized out>, locals=<optimized out>, args=<optimized out>, argcount=<optimized out>, kwnames=<optimized out>) at Python/ceval.c:6425
#56 0x411af4e4 in PyEval_EvalCode (co=0xf9a33a60, globals=<optimized out>, locals=0xf7b03b88) at Python/ceval.c:1140
#57 0x411fa628 in run_eval_code_obj (tstate=0xf7b03b88, co=0xf9a33a60, globals=0x1, locals=0x8d) at Python/pythonrun.c:1710
#58 0x411fa8d8 in run_mod (mod=<optimized out>, filename=<optimized out>, globals=0xf9a33a60, locals=0x8d, flags=<optimized out>, arena=<optimized out>) at Python/pythonrun.c:1731
#59 0x411faa50 in pyrun_file (fp=0x0, filename=0x8d, start=<optimized out>, globals=0xf7b03b88, locals=<optimized out>, closeit=<optimized out>, flags=<optimized out>) at Python/pythonrun.c:1626
#60 0x411fdc38 in _PyRun_SimpleFileObject (fp=0xf998db68, filename=0x8d, closeit=-139445336, flags=0x0) at Python/pythonrun.c:440
#61 0x411fe30c in _PyRun_AnyFileObject (fp=0xf9a33a60, filename=0x1, closeit=141, flags=0xf7b03b88) at Python/pythonrun.c:79
#62 0x41222278 in pymain_run_file_obj (skip_source_first_line=1095637024, filename=0xf7b03ba8, program_name=0x8e) at Modules/main.c:360
#63 pymain_run_file (config=0x1) at Modules/main.c:379
#64 pymain_run_python (exitcode=0x8d) at Modules/main.c:601
#65 Py_RunMain () at Modules/main.c:680
#66 0x4104c4c8 in main (argc=<optimized out>, argv=<optimized out>) at Programs/_bootstrap_python.c:109
(gdb)
Comment 2 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-03 07:17:26 UTC
```
There are only 'skip'ped commits left to test.
The first bad commit could be any of:
04c9cf5c786b94fbe3f6f21f06cae73a7575ff7a
964fd402c9b48eb4da91fb3e4e45d4560d6c676c
c92737722ffff85c759247f96f281438bbf1418d
We cannot bisect more!
error: bisect run cannot continue any more
```

with
```
$ git bisect log
git bisect start
# status: waiting for both good and bad commits
# bad: [5ee894130fd0103b3d95fbca19ea1acc4e68d828] RISC-V: Add the missed combine of [u]int64 -> _Float16 and vcond
git bisect bad 5ee894130fd0103b3d95fbca19ea1acc4e68d828
# status: waiting for good commit(s), bad commit known
# good: [b22b845834f8bdc4e18d95b4f36ba702c01ed5f8] RISC-V: Fix ICE of RVV vget/vset intrinsic[PR111935]
git bisect good b22b845834f8bdc4e18d95b4f36ba702c01ed5f8
# skip: [8e08c7886eed5824bebd0e011526ec302d622844] ipa: Fix double reference-count decrements for the same edge (PR 107769, PR 109318)
git bisect skip 8e08c7886eed5824bebd0e011526ec302d622844
# good: [601a412ef0fe59ce48fb8635ebdaa58b58512a5a] RISC-V: Remove the redundant expressions in the and<mode>3.
git bisect good 601a412ef0fe59ce48fb8635ebdaa58b58512a5a
# good: [faea9d92db9a339f5c2cf949e4890947287d7ef9] libstdc++: Rename C++20 Customization Point Objects
git bisect good faea9d92db9a339f5c2cf949e4890947287d7ef9
# skip: [263369b2f7f726a3d4b269678d2c13a9d06a041e] PR rtl-optimization/110701: Fix SUBREG SET_DEST handling in combine.
git bisect skip 263369b2f7f726a3d4b269678d2c13a9d06a041e
# good: [fd35d72a3dcd5ba14d81a1890236acd0145497e1] c++ __integer_pack conversion again [PR111357]
git bisect good fd35d72a3dcd5ba14d81a1890236acd0145497e1
# good: [3179ad72f67f31824c444ef30ef171ad7495d274] OMP SIMD inbranch call vectorization for AVX512 style masks
git bisect good 3179ad72f67f31824c444ef30ef171ad7495d274
# bad: [47b634a308c59f728783513123e7a9576fdc82aa] Doc: document the new Darwin options
git bisect bad 47b634a308c59f728783513123e7a9576fdc82aa
# skip: [879c91fcccf93681bd7e13290bfbb384cadcd268] [c] Fix PR 101364: ICE after error due to diagnose_arglist_conflict not checking for error
git bisect skip 879c91fcccf93681bd7e13290bfbb384cadcd268
# bad: [eb15fad3190a8b33e3e451b964ff1ecf08bbb113] middle-end: don't pass loop_vinfo to vect_set_loop_condition during prolog peeling
git bisect bad eb15fad3190a8b33e3e451b964ff1ecf08bbb113
# bad: [60c231cb65807fb963624acc4f82d2935e305f93] middle-end: maintain LCSSA throughout loop peeling
git bisect bad 60c231cb65807fb963624acc4f82d2935e305f93
# bad: [04013e4464020b4440aa41524a222658d7e36937] diagnostics: special-case -fdiagnostics-text-art-charset=ascii for LANG=C
git bisect bad 04013e4464020b4440aa41524a222658d7e36937
# good: [15886c0365e4fb1fe2a49a1fd3866161e58ada1a] libgomp.texi: Use present not future tense
git bisect good 15886c0365e4fb1fe2a49a1fd3866161e58ada1a
# good: [a22eeaca5ce753a0a3c22013ee3ecde04c71c2f4] c++: fix truncated diagnostic in C++23 [PR111272]
git bisect good a22eeaca5ce753a0a3c22013ee3ecde04c71c2f4
# skip: [04c9cf5c786b94fbe3f6f21f06cae73a7575ff7a] Implement new RTL optimizations pass: fold-mem-offsets
git bisect skip 04c9cf5c786b94fbe3f6f21f06cae73a7575ff7a
# good: [c7609acb8a8210188d21b2cd72ecc6d3b2de2ab8] MATCH: Improve `A CMP 0 ? A : -A` set of patterns to use bitwise_equal_p.
git bisect good c7609acb8a8210188d21b2cd72ecc6d3b2de2ab8
# bad: [328745607c5d403a1c7b6bc2ecaa1574ee42122f] RISC-V: NFC: Move scalar block move expansion code into riscv-string.cc
git bisect bad 328745607c5d403a1c7b6bc2ecaa1574ee42122f
# skip: [964fd402c9b48eb4da91fb3e4e45d4560d6c676c] d: Merge upstream dmd, druntime 4c18eed967, phobos d945686a4.
git bisect skip 964fd402c9b48eb4da91fb3e4e45d4560d6c676c
# bad: [c92737722ffff85c759247f96f281438bbf1418d] RISC-V/testsuite: add a default march (lacking zfa) to some fp tests
git bisect bad c92737722ffff85c759247f96f281438bbf1418d
# only skipped commits left to test
# possible first bad commit: [c92737722ffff85c759247f96f281438bbf1418d] RISC-V/testsuite: add a default march (lacking zfa) to some fp tests
# possible first bad commit: [04c9cf5c786b94fbe3f6f21f06cae73a7575ff7a] Implement new RTL optimizations pass: fold-mem-offsets
# possible first bad commit: [964fd402c9b48eb4da91fb3e4e45d4560d6c676c] d: Merge upstream dmd, druntime 4c18eed967, phobos d945686a4.
```
Comment 3 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-03 07:18:01 UTC
Surely it's 04c9cf5c786b94fbe3f6f21f06cae73a7575ff7a ('Implement new RTL optimizations pass: fold-mem-offsets') if that list is to be believed...
Comment 4 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-03 10:52:41 UTC
-fno-fold-mem-offsets doesn't seem to help...
Comment 5 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-05 18:54:44 UTC Comment hidden (obsolete)
Comment 6 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-05 18:55:09 UTC
Trying a new bisect with more robust logic in the script.

So far..

$ git bisect visualize --oneline
328745607c5 RISC-V: NFC: Move scalar block move expansion code into riscv-string.cc
c92737722ff RISC-V/testsuite: add a default march (lacking zfa) to some fp tests
04c9cf5c786 Implement new RTL optimizations pass: fold-mem-offsets
964fd402c9b d: Merge upstream dmd, druntime 4c18eed967, phobos d945686a4.
c7609acb8a8 MATCH: Improve `A CMP 0 ? A : -A` set of patterns to use bitwise_equal_p.
29a4453c7b8 (HEAD) [PR31531] MATCH: Improve ~a < ~b and ~a < CST, allow a nop cast inbetween ~ and a/b
7550130c862 c++: improve fold-expr location
a22eeaca5ce c++: fix truncated diagnostic in C++23 [PR111272]
817a7016819 ARC: Split asl dst,1,src into bset dst,0,src to implement 1<<x.
d6ebe618897 s390: Fix expander popcountv8hi2_vx
a5fe9f063de RISC-V: Use VLS modes if the NITERS is known and smaller than VLS mode elements.

$ git bisect log
git bisect start
# status: waiting for both good and bad commits
# bad: [6e9ee44d96e5bda8808dd9d8ccf58d2525383f6b] Reduce false positives for -Wnonnull for VLA parameters [PR98541]
git bisect bad 6e9ee44d96e5bda8808dd9d8ccf58d2525383f6b
# status: waiting for good commit(s), bad commit known
# good: [b22b845834f8bdc4e18d95b4f36ba702c01ed5f8] RISC-V: Fix ICE of RVV vget/vset intrinsic[PR111935]
git bisect good b22b845834f8bdc4e18d95b4f36ba702c01ed5f8
# good: [8e08c7886eed5824bebd0e011526ec302d622844] ipa: Fix double reference-count decrements for the same edge (PR 107769, PR 109318)
git bisect good 8e08c7886eed5824bebd0e011526ec302d622844
# skip: [0407ae8a7732d90622a65ddf1798c9d51d450e9d] PR 95923: More (boolean) bitop simplifications in match.pd
git bisect skip 0407ae8a7732d90622a65ddf1798c9d51d450e9d
# good: [56cf8b01fe1d4d4bb33a107e5d490f589d5f05bc] Normalize irange_bitmask before union/intersect.
git bisect good 56cf8b01fe1d4d4bb33a107e5d490f589d5f05bc
# good: [6f7f728746818062c3d6ed7ea9c7cb1562f2acb1] pretty-print: Fix up pp_wide_int [PR111329]
git bisect good 6f7f728746818062c3d6ed7ea9c7cb1562f2acb1
# good: [1f68a3e8727f36da80be8fe1c67ed6a4d9a568d9] libcpp: eliminate COMBINE_LOCATION_DATA
git bisect good 1f68a3e8727f36da80be8fe1c67ed6a4d9a568d9
# bad: [3e3d73ed5e85e7f467c366e9ad219d558ef9cb79] c++: merge tsubst_copy into tsubst_copy_and_build
git bisect bad 3e3d73ed5e85e7f467c366e9ad219d558ef9cb79
# good: [969f5c3eaa7f073f532206ced0f177b4eb58aee2] Fortran: Support OpenMP's 'allocate' directive for stack vars
git bisect good 969f5c3eaa7f073f532206ced0f177b4eb58aee2
# bad: [dd28f90c95378bf8ebb82a3dfdf24a6ad190877a] ifcvt: rewrite args handling to remove lookups
git bisect bad dd28f90c95378bf8ebb82a3dfdf24a6ad190877a
# bad: [8eb9cdd142182aaa3ee39750924bc0a0491236c3] expr: don't clear SUBREG_PROMOTED_VAR_P flag for a promoted subreg [target/111466]
git bisect bad 8eb9cdd142182aaa3ee39750924bc0a0491236c3
# skip: [a5fe9f063de64aa2755c9ae9e90ed1ff64ee0f47] RISC-V: Use VLS modes if the NITERS is known and smaller than VLS mode elements.
git bisect skip a5fe9f063de64aa2755c9ae9e90ed1ff64ee0f47
# good: [b7a28c0904fa67f98d7ca7e9d828fc5fc58c7078] use more get_range_query
git bisect good b7a28c0904fa67f98d7ca7e9d828fc5fc58c7078
# bad: [328745607c5d403a1c7b6bc2ecaa1574ee42122f] RISC-V: NFC: Move scalar block move expansion code into riscv-string.cc
git bisect bad 328745607c5d403a1c7b6bc2ecaa1574ee42122f
Comment 7 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-06 11:50:59 UTC
Huh.

04c9cf5c786b94fbe3f6f21f06cae73a7575ff7a is the first bad commit
commit 04c9cf5c786b94fbe3f6f21f06cae73a7575ff7a
Author: Manolis Tsamis <manolis.tsamis@vrull.eu>
Date:   Mon Oct 16 13:08:12 2023 -0600

    Implement new RTL optimizations pass: fold-mem-offsets

    This is a new RTL pass that tries to optimize memory offset calculations
    by moving them from add immediate instructions to the memory loads/stores.
    For example it can transform this:

$ git bisect log
git bisect start
# status: waiting for both good and bad commits
# bad: [6e9ee44d96e5bda8808dd9d8ccf58d2525383f6b] Reduce false positives for -Wnonnull for VLA parameters [PR98541]
git bisect bad 6e9ee44d96e5bda8808dd9d8ccf58d2525383f6b
# status: waiting for good commit(s), bad commit known
# good: [b22b845834f8bdc4e18d95b4f36ba702c01ed5f8] RISC-V: Fix ICE of RVV vget/vset intrinsic[PR111935]
git bisect good b22b845834f8bdc4e18d95b4f36ba702c01ed5f8
# good: [8e08c7886eed5824bebd0e011526ec302d622844] ipa: Fix double reference-count decrements for the same edge (PR 107769, PR 109318)
git bisect good 8e08c7886eed5824bebd0e011526ec302d622844
# skip: [0407ae8a7732d90622a65ddf1798c9d51d450e9d] PR 95923: More (boolean) bitop simplifications in match.pd
git bisect skip 0407ae8a7732d90622a65ddf1798c9d51d450e9d
# good: [56cf8b01fe1d4d4bb33a107e5d490f589d5f05bc] Normalize irange_bitmask before union/intersect.
git bisect good 56cf8b01fe1d4d4bb33a107e5d490f589d5f05bc
# good: [6f7f728746818062c3d6ed7ea9c7cb1562f2acb1] pretty-print: Fix up pp_wide_int [PR111329]
git bisect good 6f7f728746818062c3d6ed7ea9c7cb1562f2acb1
# good: [1f68a3e8727f36da80be8fe1c67ed6a4d9a568d9] libcpp: eliminate COMBINE_LOCATION_DATA
git bisect good 1f68a3e8727f36da80be8fe1c67ed6a4d9a568d9
# bad: [3e3d73ed5e85e7f467c366e9ad219d558ef9cb79] c++: merge tsubst_copy into tsubst_copy_and_build
git bisect bad 3e3d73ed5e85e7f467c366e9ad219d558ef9cb79
# good: [969f5c3eaa7f073f532206ced0f177b4eb58aee2] Fortran: Support OpenMP's 'allocate' directive for stack vars
git bisect good 969f5c3eaa7f073f532206ced0f177b4eb58aee2
# bad: [dd28f90c95378bf8ebb82a3dfdf24a6ad190877a] ifcvt: rewrite args handling to remove lookups
git bisect bad dd28f90c95378bf8ebb82a3dfdf24a6ad190877a
# bad: [8eb9cdd142182aaa3ee39750924bc0a0491236c3] expr: don't clear SUBREG_PROMOTED_VAR_P flag for a promoted subreg [target/111466]
git bisect bad 8eb9cdd142182aaa3ee39750924bc0a0491236c3
# skip: [a5fe9f063de64aa2755c9ae9e90ed1ff64ee0f47] RISC-V: Use VLS modes if the NITERS is known and smaller than VLS mode elements.
git bisect skip a5fe9f063de64aa2755c9ae9e90ed1ff64ee0f47
# good: [b7a28c0904fa67f98d7ca7e9d828fc5fc58c7078] use more get_range_query
git bisect good b7a28c0904fa67f98d7ca7e9d828fc5fc58c7078
# bad: [328745607c5d403a1c7b6bc2ecaa1574ee42122f] RISC-V: NFC: Move scalar block move expansion code into riscv-string.cc
git bisect bad 328745607c5d403a1c7b6bc2ecaa1574ee42122f
# good: [29a4453c7b8a86d242dab89b9e4d222749fd911e] [PR31531] MATCH: Improve ~a < ~b and ~a < CST, allow a nop cast inbetween ~ and a/b
git bisect good 29a4453c7b8a86d242dab89b9e4d222749fd911e
# bad: [04c9cf5c786b94fbe3f6f21f06cae73a7575ff7a] Implement new RTL optimizations pass: fold-mem-offsets
git bisect bad 04c9cf5c786b94fbe3f6f21f06cae73a7575ff7a
# good: [964fd402c9b48eb4da91fb3e4e45d4560d6c676c] d: Merge upstream dmd, druntime 4c18eed967, phobos d945686a4.
git bisect good 964fd402c9b48eb4da91fb3e4e45d4560d6c676c
# first bad commit: [04c9cf5c786b94fbe3f6f21f06cae73a7575ff7a] Implement new RTL optimizations pass: fold-mem-offsets
Comment 8 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-06 11:57:19 UTC
and indeed Python built at gcc 964fd402c9b48eb4da91fb3e4e45d4560d6c676c ('d: Merge upstream dmd, druntime 4c18eed967, phobos d945686a4.') is fine.
Comment 9 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-11-06 17:12:33 UTC
OK, -fno-fold-mem-offsets *does* suppress it on trunk so I must have made a mistake before.
Comment 10 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2024-02-13 20:06:35 UTC
This is workedaroundededed upstream.