http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59286

--- Comment #6 from Joost VandeVondele <Joost.VandeVondele at mat dot ethz.ch> 
---
(In reply to Kostya Serebryany from comment #5)
> > However, building a tsan instrumented CP2K is non-trivial, as it requires
> 
> Maybe let's do some remote debugging then :) 

We can give this a try, but I might need rather detailed instructions. I.e.
starting from a sample printf statement and a suggested line number. With my
current setup, I get the segfault in a new location:

Program received signal SIGSEGV, Segmentation fault.
__sanitizer::find (s=0xffffffffffffffff, s@entry=0x7ffff4c2e8b8,
stack=stack@entry=0x7ffff4d797b8, size=size@entry=19,
hash=hash@entry=1116003544)
    at
../../../../gcc/libsanitizer/sanitizer_common/sanitizer_stackdepot.cc:109
109        if (s->hash == hash && s->size == size) {
(gdb) bt 7
#0  __sanitizer::find (s=0xffffffffffffffff, s@entry=0x7ffff4c2e8b8,
stack=stack@entry=0x7ffff4d797b8, size=size@entry=19,
hash=hash@entry=1116003544)
    at
../../../../gcc/libsanitizer/sanitizer_common/sanitizer_stackdepot.cc:109
#1  0x00007ffff35ae1a1 in __sanitizer::StackDepotPut (stack=0x7ffff4d797b8,
size=19)
    at
../../../../gcc/libsanitizer/sanitizer_common/sanitizer_stackdepot.cc:150
#2  0x00007ffff3570e4d in __tsan::CurrentStackId (thr=0xffffffffffffffff,
pc=140737301157816) at ../../../../gcc/libsanitizer/tsan/tsan_rtl.cc:305
#3  0x00007ffff35a1404 in __tsan::user_alloc (thr=0x7ffff4d79780,
pc=140737276073318, sz=24, align=<optimized out>)
    at ../../../../gcc/libsanitizer/tsan/tsan_mman.cc:110
#4  0x00007ffff358d58c in __interceptor_malloc (size=24) at
../../../../gcc/libsanitizer/tsan/tsan_interceptors.cc:447
#5  0x00007ffff57ba78c in timings::timestop (handle=339) at
/data/vjoost/clean/cp2k/cp2k/src/../src/timings.F:328
#6  0x00007ffff76accf6 in dbcsr_error_handling::dbcsr_error_stop (handler=1,
error=...)
    at
/data/vjoost/clean/cp2k/cp2k/src/../src/dbcsr_lib/dbcsr_error_handling.F:180
(More stack frames follow...)
(gdb) print s
$3 = (__sanitizer::StackDesc *) 0xffffffffffffffff

Reply via email to