Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

segmentation fault when building with -DX86_OPT=ON #2836

Open
Apteryks opened this issue May 6, 2024 · 1 comment
Open

segmentation fault when building with -DX86_OPT=ON #2836

Apteryks opened this issue May 6, 2024 · 1 comment

Comments

@Apteryks
Copy link

Apteryks commented May 6, 2024

Hi,

I'm encountering a segmentation fault, only when GLideN64 is built with the X86_OPT build option enabled:

(gdb) bt
#0  0x00007fffd0930887 in RSP_LoadMatrix (mtx=0x7fffffffc3f0, address=<optimized out>) at /tmp/guix-build-mupen64plus-video-gliden64-4.0-0.b021d8e.drv-0/source/src/RSP_LoadMatrixX86.cpp:53
#1  0x00007fffd0894cce in gSPMatrix (matrix=<optimized out>, param=<optimized out>) at /tmp/guix-build-mupen64plus-video-gliden64-4.0-0.b021d8e.drv-0/source/src/gSP.cpp:173
#2  0x00007fffd089db30 in _ProcessDList () at /tmp/guix-build-mupen64plus-video-gliden64-4.0-0.b021d8e.drv-0/source/src/RSP.cpp:59
#3  RSP_ProcessDList () at /tmp/guix-build-mupen64plus-video-gliden64-4.0-0.b021d8e.drv-0/source/src/RSP.cpp:182
#4  RSP_ProcessDList () at /tmp/guix-build-mupen64plus-video-gliden64-4.0-0.b021d8e.drv-0/source/src/RSP.cpp:110
#5  0x00007ffff1ebd2ff in DoRspCycles () from /home/maxim/.guix-profile/lib/mupen64plus/mupen64plus-rsp-hle.so
#6  0x00007ffff20347ee in ?? () from /gnu/store/jjwcgqg8xqz2gblzcj7x38q265j27djk-mupen64plus-core-2.5.9/lib/libmupen64plus.so.2
#7  0x00007ffff203631f in ?? () from /gnu/store/jjwcgqg8xqz2gblzcj7x38q265j27djk-mupen64plus-core-2.5.9/lib/libmupen64plus.so.2
#8  0x00007fffa73a7242 in ?? ()
#9  0x00007ffff5e83020 in ?? () from /gnu/store/jjwcgqg8xqz2gblzcj7x38q265j27djk-mupen64plus-core-2.5.9/lib/libmupen64plus.so.2
#10 0x00007ffff5e83020 in ?? () from /gnu/store/jjwcgqg8xqz2gblzcj7x38q265j27djk-mupen64plus-core-2.5.9/lib/libmupen64plus.so.2
#11 0x0000000010000040 in ?? ()
#12 0x00007ffff2025193 in ?? () from /gnu/store/jjwcgqg8xqz2gblzcj7x38q265j27djk-mupen64plus-core-2.5.9/lib/libmupen64plus.so.2
#13 0x00007ffff203a969 in ?? () from /gnu/store/jjwcgqg8xqz2gblzcj7x38q265j27djk-mupen64plus-core-2.5.9/lib/libmupen64plus.so.2
#14 0x0000000000403faa in main ()
(gdb) taas bt

Thread 8 (Thread 0x7fffa7e00640 (LWP 9195) "SDLAudioP1"):
#0  0x00007ffff7a8616a in __futex_abstimed_wait_common () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#1  0x00007ffff7a887e8 in pthread_cond_wait@@GLIBC_2.3.2 () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#2  0x00007ffff7e83aa8 in pa_threaded_mainloop_wait () from /gnu/store/h70jib2s2iymk6m2442bn9l2wxhjpjwx-pulseaudio-16.1/lib/libpulse.so.0
#3  0x00007ffff7d3eb8d in ?? () from /gnu/store/fq939shv5sfn7aav6np4gnf1yzizfjqa-sdl2-2.30.1/lib/libSDL2-2.0.so.0
#4  0x00007ffff7c38b16 in ?? () from /gnu/store/fq939shv5sfn7aav6np4gnf1yzizfjqa-sdl2-2.30.1/lib/libSDL2-2.0.so.0
#5  0x00007ffff7cc84a6 in ?? () from /gnu/store/fq939shv5sfn7aav6np4gnf1yzizfjqa-sdl2-2.30.1/lib/libSDL2-2.0.so.0
#6  0x00007ffff7d807c9 in ?? () from /gnu/store/fq939shv5sfn7aav6np4gnf1yzizfjqa-sdl2-2.30.1/lib/libSDL2-2.0.so.0
#7  0x00007ffff7a893aa in start_thread () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#8  0x00007ffff7b09f7c in clone3 () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6

Thread 6 (Thread 0x7ffff1a54640 (LWP 9193) "PulseHotplug"):
#0  0x00007ffff7a8616a in __futex_abstimed_wait_common () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#1  0x00007ffff7a887e8 in pthread_cond_wait@@GLIBC_2.3.2 () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#2  0x00007ffff7e83aa8 in pa_threaded_mainloop_wait () from /gnu/store/h70jib2s2iymk6m2442bn9l2wxhjpjwx-pulseaudio-16.1/lib/libpulse.so.0
#3  0x00007ffff7d3ef8d in ?? () from /gnu/store/fq939shv5sfn7aav6np4gnf1yzizfjqa-sdl2-2.30.1/lib/libSDL2-2.0.so.0
#4  0x00007ffff7cc84a6 in ?? () from /gnu/store/fq939shv5sfn7aav6np4gnf1yzizfjqa-sdl2-2.30.1/lib/libSDL2-2.0.so.0
#5  0x00007ffff7d807c9 in ?? () from /gnu/store/fq939shv5sfn7aav6np4gnf1yzizfjqa-sdl2-2.30.1/lib/libSDL2-2.0.so.0
#6  0x00007ffff7a893aa in start_thread () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#7  0x00007ffff7b09f7c in clone3 () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6

Thread 5 (Thread 0x7fffc4a00640 (LWP 9192) "PulseMainloop"):
#0  0x00007ffff7afdd6f in poll () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#1  0x00007ffff7e834c2 in ?? () from /gnu/store/h70jib2s2iymk6m2442bn9l2wxhjpjwx-pulseaudio-16.1/lib/libpulse.so.0
#2  0x00007ffff7e753b9 in pa_mainloop_poll () from /gnu/store/h70jib2s2iymk6m2442bn9l2wxhjpjwx-pulseaudio-16.1/lib/libpulse.so.0
#3  0x00007ffff7e75a17 in pa_mainloop_iterate () from /gnu/store/h70jib2s2iymk6m2442bn9l2wxhjpjwx-pulseaudio-16.1/lib/libpulse.so.0
#4  0x00007ffff7e75ac0 in pa_mainloop_run () from /gnu/store/h70jib2s2iymk6m2442bn9l2wxhjpjwx-pulseaudio-16.1/lib/libpulse.so.0
#5  0x00007ffff7e83386 in ?? () from /gnu/store/h70jib2s2iymk6m2442bn9l2wxhjpjwx-pulseaudio-16.1/lib/libpulse.so.0
#6  0x00007ffff76d9a6f in ?? () from /gnu/store/h70jib2s2iymk6m2442bn9l2wxhjpjwx-pulseaudio-16.1/lib/pulseaudio/libpulsecommon-16.1.so
#7  0x00007ffff7a893aa in start_thread () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#8  0x00007ffff7b09f7c in clone3 () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6

Thread 4 (Thread 0x7fffc5400640 (LWP 9191) "SDLTimer"):
#0  0x00007ffff7a8616a in __futex_abstimed_wait_common () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#1  0x00007ffff7a90d18 in __new_sem_wait_slow64.constprop.0 () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#2  0x00007ffff7d80cde in ?? () from /gnu/store/fq939shv5sfn7aav6np4gnf1yzizfjqa-sdl2-2.30.1/lib/libSDL2-2.0.so.0
#3  0x00007ffff7cc8b5f in ?? () from /gnu/store/fq939shv5sfn7aav6np4gnf1yzizfjqa-sdl2-2.30.1/lib/libSDL2-2.0.so.0
#4  0x00007ffff7cc84a6 in ?? () from /gnu/store/fq939shv5sfn7aav6np4gnf1yzizfjqa-sdl2-2.30.1/lib/libSDL2-2.0.so.0
#5  0x00007ffff7d807c9 in ?? () from /gnu/store/fq939shv5sfn7aav6np4gnf1yzizfjqa-sdl2-2.30.1/lib/libSDL2-2.0.so.0
#6  0x00007ffff7a893aa in start_thread () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#7  0x00007ffff7b09f7c in clone3 () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6

Thread 3 (Thread 0x7fffc8000640 (LWP 9177) "mupen64:disk$0"):
#0  0x00007ffff7a8616a in __futex_abstimed_wait_common () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#1  0x00007ffff7a887e8 in pthread_cond_wait@@GLIBC_2.3.2 () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#2  0x00007fffcd3b6229 in ?? () from /gnu/store/9i3zzv8kmv2rkkiyn70lp594fz637vna-mesa-24.0.4/lib/dri/nouveau_dri.so
#3  0x00007fffcd36e19b in ?? () from /gnu/store/9i3zzv8kmv2rkkiyn70lp594fz637vna-mesa-24.0.4/lib/dri/nouveau_dri.so
#4  0x00007fffcd3b6167 in ?? () from /gnu/store/9i3zzv8kmv2rkkiyn70lp594fz637vna-mesa-24.0.4/lib/dri/nouveau_dri.so
#5  0x00007ffff7a893aa in start_thread () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#6  0x00007ffff7b09f7c in clone3 () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6

Thread 2 (Thread 0x7fffd1800640 (LWP 9160) "m64pwq"):
#0  0x00007ffff7a8616a in __futex_abstimed_wait_common () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#1  0x00007ffff7a887e8 in pthread_cond_wait@@GLIBC_2.3.2 () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#2  0x00007ffff7d811fe in ?? () from /gnu/store/fq939shv5sfn7aav6np4gnf1yzizfjqa-sdl2-2.30.1/lib/libSDL2-2.0.so.0
#3  0x00007ffff2035fa0 in ?? () from /gnu/store/jjwcgqg8xqz2gblzcj7x38q265j27djk-mupen64plus-core-2.5.9/lib/libmupen64plus.so.2
#4  0x00007ffff7cc84a6 in ?? () from /gnu/store/fq939shv5sfn7aav6np4gnf1yzizfjqa-sdl2-2.30.1/lib/libSDL2-2.0.so.0
--Type <RET> for more, q to quit, c to continue without paging--c
#5  0x00007ffff7d807c9 in ?? () from /gnu/store/fq939shv5sfn7aav6np4gnf1yzizfjqa-sdl2-2.30.1/lib/libSDL2-2.0.so.0
#6  0x00007ffff7a893aa in start_thread () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6
#7  0x00007ffff7b09f7c in clone3 () from /gnu/store/ln6hxqjvz6m9gdd9s97pivlqck7hzs99-glibc-2.35/lib/libc.so.6

Thread 1 (Thread 0x7ffff7274740 (LWP 9157) "mupen64plus"):
#0  0x00007fffd0930887 in RSP_LoadMatrix (mtx=0x7fffffffc3f0, address=<optimized out>) at /tmp/guix-build-mupen64plus-video-gliden64-4.0-0.b021d8e.drv-0/source/src/RSP_LoadMatrixX86.cpp:53
#1  0x00007fffd0894cce in gSPMatrix (matrix=<optimized out>, param=<optimized out>) at /tmp/guix-build-mupen64plus-video-gliden64-4.0-0.b021d8e.drv-0/source/src/gSP.cpp:173
#2  0x00007fffd089db30 in _ProcessDList () at /tmp/guix-build-mupen64plus-video-gliden64-4.0-0.b021d8e.drv-0/source/src/RSP.cpp:59
#3  RSP_ProcessDList () at /tmp/guix-build-mupen64plus-video-gliden64-4.0-0.b021d8e.drv-0/source/src/RSP.cpp:182
#4  RSP_ProcessDList () at /tmp/guix-build-mupen64plus-video-gliden64-4.0-0.b021d8e.drv-0/source/src/RSP.cpp:110
#5  0x00007ffff1ebd2ff in DoRspCycles () from /home/maxim/.guix-profile/lib/mupen64plus/mupen64plus-rsp-hle.so
#6  0x00007ffff20347ee in ?? () from /gnu/store/jjwcgqg8xqz2gblzcj7x38q265j27djk-mupen64plus-core-2.5.9/lib/libmupen64plus.so.2
#7  0x00007ffff203631f in ?? () from /gnu/store/jjwcgqg8xqz2gblzcj7x38q265j27djk-mupen64plus-core-2.5.9/lib/libmupen64plus.so.2
#8  0x00007fffa73a7242 in ?? ()
#9  0x00007ffff5e83020 in ?? () from /gnu/store/jjwcgqg8xqz2gblzcj7x38q265j27djk-mupen64plus-core-2.5.9/lib/libmupen64plus.so.2
#10 0x00007ffff5e83020 in ?? () from /gnu/store/jjwcgqg8xqz2gblzcj7x38q265j27djk-mupen64plus-core-2.5.9/lib/libmupen64plus.so.2
#11 0x0000000010000040 in ?? ()
#12 0x00007ffff2025193 in ?? () from /gnu/store/jjwcgqg8xqz2gblzcj7x38q265j27djk-mupen64plus-core-2.5.9/lib/libmupen64plus.so.2
#13 0x00007ffff203a969 in ?? () from /gnu/store/jjwcgqg8xqz2gblzcj7x38q265j27djk-mupen64plus-core-2.5.9/lib/libmupen64plus.so.2
#14 0x0000000000403faa in main ()

This was with mupen64plus --windowed --gfx mupen64plus-video-GLideN64.so ....

Any clue?

@Apteryks
Copy link
Author

Apteryks commented May 6, 2024

The processor is an old Core 2 Duo (Q6700) Intel processor, in case it matters.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant