This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug malloc/22226] valgrind issues with static binaries
- From: "markus at trippelsdorf dot de" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sourceware dot org
- Date: Thu, 28 Sep 2017 15:08:54 +0000
- Subject: [Bug malloc/22226] valgrind issues with static binaries
- Auto-submitted: auto-generated
- References: <bug-22226-131@http.sourceware.org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=22226
--- Comment #2 from Markus Trippelsdorf <markus at trippelsdorf dot de> ---
(In reply to Carlos O'Donell from comment #1)
> (In reply to Markus Trippelsdorf from comment #0)
> > ==22776== at 0x41DEA8: _int_malloc (malloc.c:3673)
> > ==22776== by 0x41DEA8: tcache_init.part.9 (malloc.c:2985)
> > ==22776== by 0x41EBEB: tcache_init (malloc.c:2981)
>
> What is the source code at this line?
tcache should be culprit.
3661 if (tcache && tc_idx < mp_.tcache_bins)
(gdb) l
3656 */
3657
3658 #if USE_TCACHE
3659 INTERNAL_SIZE_T tcache_nb = 0;
3660 size_t tc_idx = csize2tidx (nb);
3661 if (tcache && tc_idx < mp_.tcache_bins)
3662 tcache_nb = nb;
3663 int return_cached = 0;
3664
3665 tcache_unsorted_count = 0;
(gdb) bt
#0 0x000000000041e328 in _int_malloc (bytes=576, av=0x49e7a0 <main_arena>) at
malloc.c:3661
#1 tcache_init () at malloc.c:2973
#2 0x000000000041f0ac in tcache_init () at malloc.c:2969
#3 __libc_malloc (bytes=20) at malloc.c:3020
#4 malloc_hook_ini (sz=20, caller=<optimized out>) at hooks.c:32
#5 0x0000000000461bf2 in _dl_get_origin () at
../sysdeps/unix/sysv/linux/dl-origin.c:50
#6 0x000000000042f6ef in _dl_non_dynamic_init () at dl-support.c:348
#7 0x0000000000430e81 in __libc_init_first (argc=argc@entry=1,
argv=argv@entry=0x1fff000538, envp=0x1fff000548) at ../csu/init-first.c:74
#8 0x0000000000400c5f in __libc_start_main (main=0x40088d <main>, argc=1,
argv=0x1fff000538, init=0x4014c0 <__libc_csu_init>, fini=0x4016c0
<__libc_csu_fini>, rtld_fini=0x0,
stack_end=0x1fff000528) at ../csu/libc-start.c:244
#9 0x000000000040078a in _start () at ../sysdeps/x86_64/start.S:120
(gdb) p tcache
Cannot find thread-local storage for Thread 9625, executable file
/home/markus/glibc/a.out:
Remote target doesn't support qGetTLSAddr packet
(gdb) p mp_.tcache_bins
$1 = 64
(gdb) p nb
$2 = <optimized out>
(gdb) p tc_idx
$3 = <optimized out>
Not sure if it is a false positive or not.
--
You are receiving this mail because:
You are on the CC list for the bug.