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

Assertion volation about length-based descriptor in GC_mark_from #652

Open
ivmai opened this issue Aug 1, 2024 · 2 comments
Open

Assertion volation about length-based descriptor in GC_mark_from #652

ivmai opened this issue Aug 1, 2024 · 2 comments

Comments

@ivmai
Copy link
Owner

ivmai commented Aug 1, 2024

Source: master (4f97540)
Build: https://app.travis-ci.com/github/ivmai/bdwgc/jobs/624709039
Host: Linux/x86_64
Compiler: clang-16
Config: CFLAGS_EXTRA="-m32 -funsigned-char -D _FORTIFY_SOURCE=2 -D GC_GCJ_MARK_DESCR_OFFSET=32 -D NO_LONGLONG64" CONF_OPTIONS="--enable-gc-assertions" GCTEST_WITH_MPROTECT_VDB=true
Output (gctest):
...
Emulating dirty bits with mprotect/signals
Assertion failure: extra/../mark.c:700

        case GC_DS_LENGTH:
          /* Large length.  Process part of the range to avoid pushing  */
          /* too much on the stack.                                     */

          /* Either it is a heap object or a region outside the heap.   */
          GC_ASSERT(descr < GC_greatest_real_heap_addr
                            - GC_least_real_heap_addr
                    || GC_least_real_heap_addr + sizeof(ptr_t)
                        >= ADDR(current_p) + descr
                    || ADDR(current_p) >= GC_greatest_real_heap_addr);
@ivmai
Copy link
Owner Author

ivmai commented Aug 7, 2024

Reproduced locally, both with soft and mprotect-based vdb modes, w/o incremental mode and in single-threaded case:
gcc -I include -I libatomic_ops/src -D GC_GCJ_SUPPORT -O0 -g -m32 -D GC_ASSERTIONS -D GC_GCJ_MARK_DESCR_OFFSET=32 -D NO_TEST_HANDLE_FORK -D NO_INCREMENTAL -D NO_TYPED_TEST tests/gctest.c extra/gc.c

@ivmai
Copy link
Owner Author

ivmai commented Aug 14, 2024

Related: #168 #137 #92

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