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

Perhaps GC_push_regs was configured incorrectly (Cygwin/gcc-11) #428

Open
ivmai opened this issue Feb 25, 2022 · 4 comments
Open

Perhaps GC_push_regs was configured incorrectly (Cygwin/gcc-11) #428

ivmai opened this issue Feb 25, 2022 · 4 comments

Comments

@ivmai
Copy link
Owner

ivmai commented Feb 25, 2022

Source: master (cfb325f)
Host: Win64 (Cygwin64)
Compiler: gcc (GCC) 11.2.0
How to reproduce: gcc -O3 -I include -D GC_ASSERTIONS tests/gctest.c extra/gc.c && a.exe
Output:
Switched to incremental mode
Emulating dirty bits with mprotect/signals
Apparently failed to mark from some function arguments.
Perhaps GC_push_regs was configured incorrectly?
Test failed

Also reproduced with: -D GC_DISABLE_INCREMENTAL
Not reproduced with -O2 (or lower) or w/o -D GC_ASSERTIONS

@ivmai
Copy link
Owner Author

ivmai commented Feb 25, 2022

Reproduced also if added: -D HAVE_BUILTIN_UNWIND_INIT
Thus, commit ffb9f1e seems to be wrong (needs to be reverted).

@ivmai
Copy link
Owner Author

ivmai commented Jun 17, 2022

May also lead to "List reversal produced incorrect list - collector is broken" error in gctest (seems to be the same root cause).

@ivmai
Copy link
Owner Author

ivmai commented Jan 1, 2023

In the following config, it is reproduced in ~1/30 runs:
gcc -O3 -I include -Wall -Wextra -Wpedantic -D GC_THREADS -D THREAD_LOCAL_ALLOC -D PARALLEL_MARK -D GC_ASSERTIONS tests/gctest.c extra/gc.c

@ivmai
Copy link
Owner Author

ivmai commented Aug 29, 2023

Probably should be fixed by #566 (although I am not sure gcc-11 has the mentioned optimization)

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