clangupc / upc2c

Clang based UPC to C Translator
https://clangupc.github.io/clang-upc2c
Other
4 stars 3 forks source link

TLD: Assertion failures inside Debug build #109

Closed nenadv closed 10 years ago

nenadv commented 10 years ago

After rebuilding clang-upc on pthreads branch these are the tests that fail on x86_64

[UPC-Atomic-RefImp/atomic_test_st04] FAILED: expect pass but got compiler crash (NEW)
[UPC-Atomic-RefImp/atomic_test] FAILED: expect pass but got compiler crash  (NEW)
[UPC-Atomic-RefImp/atomicperf_st04] FAILED: expect pass but got compiler crash  (NEW)
[UPC-Atomic-RefImp/atomicperf] FAILED: expect pass but got compiler crash   (NEW)
[benchmarks/lockperf_st04] FAILED: expect pass but got compiler crash   (NEW)
[benchmarks/lockperf] FAILED: expect pass but got compiler crash    (NEW)
[sobel/sobel-dynamic_st04] FAILED: expect pass but got compiler crash   (NEW)
[sobel/sobel-static_st04] FAILED: expect pass but got compiler crash    (NEW)
[sobel/sobel-dynamic-prefetch_st04] FAILED: expect pass but got compiler crash  (NEW)
[sobel/sobel-static-prefetch_st04] FAILED: expect pass but got compiler crash   (NEW)
[bugzilla/bug858a] FAILED: expect pass but got compiler crash   (NEW)
[bugzilla/bug2723] FAILED: expect pass but got compiler crash   (NEW)
[bugzilla/bug3058_st04] FAILED: expect pass but got compiler crash  (NEW)
[bugzilla/bug3059_st04] FAILED: expect pass but got compiler crash  (NEW)
[bugzilla/bug3198_st01] FAILED: expect pass but got compiler crash  (NEW)
[bugzilla/bug3198] FAILED: expect pass but got compiler crash   (NEW)
[upc_collectivev/bupc_collectivev_test_st04] FAILED: expect pass but got compiler crash (NEW)
[upc_collectivev/bupc_collectivev_test] FAILED: expect pass but got compiler crash  (NEW)

All of them fail with assertion:

[...]/eng/upc/dev/nenad/clang-upc-pthreads/src/llvm/tools/clang/lib/AST/DeclBase.cpp:1122:  void clang::DeclContext::addHiddenDecl(clang::Decl*): Assertion `D->getLexicalDeclContext() == this && "Decl inserted into wrong lexical context"' failed.
swatanabe commented 10 years ago

AMDG

On 08/19/2014 10:17 PM, Nenad Vukicevic wrote:

All of them fail with assertion:

[...]/eng/upc/dev/nenad/clang-upc-pthreads/src/llvm/tools/clang/lib/AST/DeclBase.cpp:1122:  void clang::DeclContext::addHiddenDecl(clang::Decl*): Assertion `D->getLexicalDeclContext() == this && "Decl inserted into wrong lexical context"' failed.

I've fixed this one locally already, but it leads to yet another problem.

In Christ, Steven Watanabe

nenadv commented 10 years ago

After the latest update there is only one issue which makes it the same as the Release build.

[UPC-Atomic-RefImp/atomic_test_st04] FAILED: UPC-To-C Translation or Link error (NEW)
cd /eng/upc/dev/nenad/clang-upc-pthreads/bld/upcr-packed-opt/opt_cupc2c/upc-tests/UPC-Atomic-RefImp
/eng/upc/dev/nenad/clang-upc-pthreads/bld/upcr-packed-opt/opt_cupc2c/upcc -Ww,-Wno-duplicate-decl-specifier -Ww,-Werror=pointer-arith -network=smp -pthreads -nolink-cache -I. -D__UPC_ATOMIC__=1 -DBUPC_TEST_HARNESS -lm -T 4 -o atomic_test_st04 /eng/upc/dev/nenad/clang-upc-pthreads/src/upcr/upc-tests/spec1.3/atomic_test.upc upc_atomic.upc
upcc: Error building pthread objects with thread-local data:                    
/eng/upc/dev/nenad/clang-upc-pthreads/src/upcr/upc-tests/spec1.3/atomic_test_help.upc:389:13: error: declaration of anonymous struct must be a definition
            struct <anonymous struct at /eng/upc/dev/nenad/clang-upc-pthreads/src/upcr/upc-tests/spec1.3/atomic_test_help.upc:389:1> testinfo[] = { { "GET/SET id test", (1UL << 16) | (1UL << 17), 3 }, { "GET/SET/CSWAP id test", (1UL << 16) | (1UL << 17) | (1UL << 18), 4 }, { "GET/SET/CSWAP/MIN/MAX id test", (1UL << 16) | (1UL << 17) | (1UL << 18) | (1UL << 7) | (1UL << 8), 6 } };
            ^                                                                   
/eng/upc/dev/nenad/clang-upc-pthreads/src/upcr/upc-tests/spec1.3/atomic_test_help.upc:389:13: warning: declaration does not declare anything [-Wmissing-declarations]
            struct <anonymous struct at /eng/upc/dev/nenad/clang-upc-pthreads/src/upcr/upc-tests/spec1.3/atomic_test_help.upc:389:1> testinfo[] = { { "GET/SET id test", (1UL << 16) | (1UL << 17), 3 }, { "GET/SET/CSWAP id test", (1UL << 16) | (1UL << 17) | (1UL << 18), 4 }, { "GET/SET/CSWAP/MIN/MAX id test", (1UL << 16) | (1UL << 17) | (1UL << 18) | (1UL << 7) | (1UL << 8), 6 } };