You can subscribe to this list here.
| 2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
(122) |
Nov
(152) |
Dec
(69) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2003 |
Jan
(6) |
Feb
(25) |
Mar
(73) |
Apr
(82) |
May
(24) |
Jun
(25) |
Jul
(10) |
Aug
(11) |
Sep
(10) |
Oct
(54) |
Nov
(203) |
Dec
(182) |
| 2004 |
Jan
(307) |
Feb
(305) |
Mar
(430) |
Apr
(312) |
May
(187) |
Jun
(342) |
Jul
(487) |
Aug
(637) |
Sep
(336) |
Oct
(373) |
Nov
(441) |
Dec
(210) |
| 2005 |
Jan
(385) |
Feb
(480) |
Mar
(636) |
Apr
(544) |
May
(679) |
Jun
(625) |
Jul
(810) |
Aug
(838) |
Sep
(634) |
Oct
(521) |
Nov
(965) |
Dec
(543) |
| 2006 |
Jan
(494) |
Feb
(431) |
Mar
(546) |
Apr
(411) |
May
(406) |
Jun
(322) |
Jul
(256) |
Aug
(401) |
Sep
(345) |
Oct
(542) |
Nov
(308) |
Dec
(481) |
| 2007 |
Jan
(427) |
Feb
(326) |
Mar
(367) |
Apr
(255) |
May
(244) |
Jun
(204) |
Jul
(223) |
Aug
(231) |
Sep
(354) |
Oct
(374) |
Nov
(497) |
Dec
(362) |
| 2008 |
Jan
(322) |
Feb
(482) |
Mar
(658) |
Apr
(422) |
May
(476) |
Jun
(396) |
Jul
(455) |
Aug
(267) |
Sep
(280) |
Oct
(253) |
Nov
(232) |
Dec
(304) |
| 2009 |
Jan
(486) |
Feb
(470) |
Mar
(458) |
Apr
(423) |
May
(696) |
Jun
(461) |
Jul
(551) |
Aug
(575) |
Sep
(134) |
Oct
(110) |
Nov
(157) |
Dec
(102) |
| 2010 |
Jan
(226) |
Feb
(86) |
Mar
(147) |
Apr
(117) |
May
(107) |
Jun
(203) |
Jul
(193) |
Aug
(238) |
Sep
(300) |
Oct
(246) |
Nov
(23) |
Dec
(75) |
| 2011 |
Jan
(133) |
Feb
(195) |
Mar
(315) |
Apr
(200) |
May
(267) |
Jun
(293) |
Jul
(353) |
Aug
(237) |
Sep
(278) |
Oct
(611) |
Nov
(274) |
Dec
(260) |
| 2012 |
Jan
(303) |
Feb
(391) |
Mar
(417) |
Apr
(441) |
May
(488) |
Jun
(655) |
Jul
(590) |
Aug
(610) |
Sep
(526) |
Oct
(478) |
Nov
(359) |
Dec
(372) |
| 2013 |
Jan
(467) |
Feb
(226) |
Mar
(391) |
Apr
(281) |
May
(299) |
Jun
(252) |
Jul
(311) |
Aug
(352) |
Sep
(481) |
Oct
(571) |
Nov
(222) |
Dec
(231) |
| 2014 |
Jan
(185) |
Feb
(329) |
Mar
(245) |
Apr
(238) |
May
(281) |
Jun
(399) |
Jul
(382) |
Aug
(500) |
Sep
(579) |
Oct
(435) |
Nov
(487) |
Dec
(256) |
| 2015 |
Jan
(338) |
Feb
(357) |
Mar
(330) |
Apr
(294) |
May
(191) |
Jun
(108) |
Jul
(142) |
Aug
(261) |
Sep
(190) |
Oct
(54) |
Nov
(83) |
Dec
(22) |
| 2016 |
Jan
(49) |
Feb
(89) |
Mar
(33) |
Apr
(50) |
May
(27) |
Jun
(34) |
Jul
(53) |
Aug
(53) |
Sep
(98) |
Oct
(206) |
Nov
(93) |
Dec
(53) |
| 2017 |
Jan
(65) |
Feb
(82) |
Mar
(102) |
Apr
(86) |
May
(187) |
Jun
(67) |
Jul
(23) |
Aug
(93) |
Sep
(65) |
Oct
(45) |
Nov
(35) |
Dec
(17) |
| 2018 |
Jan
(26) |
Feb
(35) |
Mar
(38) |
Apr
(32) |
May
(8) |
Jun
(43) |
Jul
(27) |
Aug
(30) |
Sep
(43) |
Oct
(42) |
Nov
(38) |
Dec
(67) |
| 2019 |
Jan
(32) |
Feb
(37) |
Mar
(53) |
Apr
(64) |
May
(49) |
Jun
(18) |
Jul
(14) |
Aug
(53) |
Sep
(25) |
Oct
(30) |
Nov
(49) |
Dec
(31) |
| 2020 |
Jan
(87) |
Feb
(45) |
Mar
(37) |
Apr
(51) |
May
(99) |
Jun
(36) |
Jul
(11) |
Aug
(14) |
Sep
(20) |
Oct
(24) |
Nov
(40) |
Dec
(23) |
| 2021 |
Jan
(14) |
Feb
(53) |
Mar
(85) |
Apr
(15) |
May
(19) |
Jun
(3) |
Jul
(14) |
Aug
(1) |
Sep
(57) |
Oct
(73) |
Nov
(56) |
Dec
(22) |
| 2022 |
Jan
(3) |
Feb
(22) |
Mar
(6) |
Apr
(55) |
May
(46) |
Jun
(39) |
Jul
(15) |
Aug
(9) |
Sep
(11) |
Oct
(34) |
Nov
(20) |
Dec
(36) |
| 2023 |
Jan
(79) |
Feb
(41) |
Mar
(99) |
Apr
(169) |
May
(48) |
Jun
(16) |
Jul
(16) |
Aug
(57) |
Sep
(19) |
Oct
|
Nov
|
Dec
|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
|
|
|
|
|
|
1
(6) |
|
2
(6) |
3
(9) |
4
(4) |
5
(1) |
6
|
7
|
8
|
|
9
|
10
(2) |
11
(1) |
12
(2) |
13
(4) |
14
(6) |
15
(8) |
|
16
(9) |
17
(5) |
18
(13) |
19
(6) |
20
(15) |
21
(17) |
22
(19) |
|
23
(2) |
24
(4) |
25
(2) |
26
(10) |
27
(6) |
28
(9) |
29
(3) |
|
30
|
|
|
|
|
|
|
|
From: Nicholas N. <n.n...@gm...> - 2023-04-03 21:42:36
|
On Tue, 4 Apr 2023 at 07:08, Mark Wielaard <ma...@kl...> wrote: > > > I looked at some of the failing builders, they all fail like this: > > > > > [...] > > > integration > > > -FAIL: qawo(f456) elist (7.25063790881233303e-15 observed vs > 7.25922435194575979e-15 expected) > > > interpolation > > > [...] > > > rng > > > +FAIL: random32-bsd, 10000 steps (852261210 observed vs 1663114331 > expected) > > > +FAIL: random64-bsd, 10000 steps (210970120 observed vs 864469165 > expected) > > > +FAIL: random32-libc5, 10000 steps (367802360 observed vs 1967452027 > expected) > > > +FAIL: random64-libc5, 10000 steps (221021662 observed vs 2106639801 > expected) > > > roots > > So the (now new) failures are the random tests. > And it looks like `qawo` has changed to passing, too? Nick |
|
From: Mark W. <ma...@kl...> - 2023-04-03 21:08:50
|
Hi Nick, On Mon, Apr 03, 2023 at 08:04:37PM +1000, Nicholas Nethercote wrote: > On Sun, 2 Apr 2023 at 08:55, Mark Wielaard <ma...@kl...> wrote: > > Hopefully we can figure out why the auxtests fail now on some of these > > setups. > > > > What are the auxtests? I don't remember hearing about them and a Google > search didn't turn up anything helpful. It is what you get when you do make auxchecks which is a target inside the auxprogs directory. See #---------------------------------------------------------------------------- # Auxiliary testsuits #---------------------------------------------------------------------------- auxchecks: gsl-check It basically downloads and builds the (very old) GNU Scientific Library 1.6. Then it runs the testsuite under valgrind. > I looked at some of the failing builders, they all fail like this: > > > for gsl_test in block cblas cdf cheb combination complex const deriv dht diff eigen err fft fit histogram ieee-utils integration interpolation linalg matrix min monte multifit multimin multiroots ntuple ode-initval permutation poly qrng rng roots sort specfunc statistics sum sys vector wavelet; do echo $gsl_test; done \ > > | cmp - /home/builder/valgrind-auxtests/gsl-build-g-O3/valgrind-gsl.out || \ > > diff -u /home/builder/shared/bb1-2/worker/valgrind-debian-testing-x86_64/build/auxprogs/gsl-1.6.out.x86.exp \ > > /home/builder/valgrind-auxtests/gsl-build-g-O3/valgrind-gsl.out > > - /home/builder/valgrind-auxtests/gsl-build-g-O3/valgrind-gsl.out differ: char 226, line 32 > > --- /home/builder/shared/bb1-2/worker/valgrind-debian-testing-x86_64/build/auxprogs/gsl-1.6.out.x86.exp 2022-08-09 19:45:48.726405142 +0000 > > +++ /home/builder/valgrind-auxtests/gsl-build-g-O3/valgrind-gsl.out 2023-04-02 13:43:46.609646296 +0000 > > @@ -15,7 +15,6 @@ > > histogram > > ieee-utils > > integration > > -FAIL: qawo(f456) elist (7.25063790881233303e-15 observed vs 7.25922435194575979e-15 expected) > > interpolation > > linalg > > matrix > > @@ -30,6 +29,10 @@ > > poly > > qrng > > rng > > +FAIL: random32-bsd, 10000 steps (852261210 observed vs 1663114331 expected) > > +FAIL: random64-bsd, 10000 steps (210970120 observed vs 864469165 expected) > > +FAIL: random32-libc5, 10000 steps (367802360 observed vs 1967452027 expected) > > +FAIL: random64-libc5, 10000 steps (221021662 observed vs 2106639801 expected) > > roots > > sort > > specfunc > > make[1]: Leaving directory '/home/builder/shared/bb1-2/worker/valgrind-debian-testing-x86_64/build/auxprogs' > > > > I don't know why it's comparing against `gsl-1.6.out.x86.exp` even on > x86-64, arm64, ppc64le, and so on. That is explained in the auxprogs/Makefile just above the gsl-check target: # We hope all tests PASS (so don't produce output except for the test names). # But on x86 we get one FAIL, so that is "fine" too. # We currently don't check stderr, but we probably should. So the (now new) failures are the random tests. Cheers, Mark |
|
From: Floyd, P. <pj...@wa...> - 2023-04-03 16:12:30
|
On 03/04/2023 11:29, Nicholas Nethercote wrote: > Hi, > > > Therefore, I propose changing the default to `--cache-sim=no`. Does > anyone have any objections to this? > No objection. I tend to use Linux perf at work because the things we want to optimize have runtimes of hours to days with 8 threads. A+ Paul |
|
From: Floyd, P. <pj...@wa...> - 2023-04-03 16:04:19
|
On 02/04/2023 00:55, Mark Wielaard wrote: > > So should we make a new check target that runs a subset of make > regtests? Or maybe have a "ci mode" for regtests? So you would run > CI_MODE=true make regtests and it would skip any vgtest that has > prereq: test -z "$CI_MODE" > > And then add make regtests to the ci and try buildbots? How long does make regtest take, compared to make auxtests? There is a patchset in bugzilla to get regtest to run in parallel https://bugs.kde.org/show_bug.cgi?id=319307 that could speed things up. If we do want to have a CI mode the way I'd do it is to add an option to tests/vg_regtest to run tests from a file containing a list and then put a list of tests in tests/ci_list It would be good to do more kinds of testing. Adding unit tests would be a bit of a challenge - we'd probably have to write out own VG_(unit_test) framework. We could do a bit of fuzz testing on the command line interface, but probably not much with the testcases. Fuzzing the testcase source files would be more of a test of the compiler. Maybe ELF fuzzing e.g., https://github.com/IOActive/Melkor_ELF_Fuzzer. On the larger scale, it would be good to be able to run more 3rd party suites with Valgrind. I've run the FreeBSD libc tests by simply running everything under Valgrind. Can we do something similar for glibc or other popular libraries? A+ Paul |
|
From: Roger L. <ro...@at...> - 2023-04-03 10:33:02
|
Hi, Whether or not you do this, it might be worth updating the description on https://valgrind.org/info/tools.html with some of the information in your email. Cheers, Roger On Mon, 3 Apr 2023 at 10:30, Nicholas Nethercote <n.n...@gm...> wrote: > Hi, > > Cachegrind has an option `--cache-sim`. > > If you run with `--cache-sim=yes` (the default) it tells it Cachegrind to > do a full cache simulation with lots of events: Ir, I1mr, ILmr, Dr, D1mr, > DLmr, Dw, D1mw, DLmw. > > If you run with `--cache-sim=no` then the cache simulation is disabled and > you just get one event: Ir. (This is "instruction cache reads", which is > equivalent to "instructions executed".) > > I have been using `--cache-sim=no` almost exclusively for a long time. The > cache simulation done by Valgrind is an approximation of the memory > hierarchy of a 2002 AMD Athlon processor. Its accuracy for a modern memory > hierarchy with three levels of cache, prefetching, non-LRU replacement, and > who-knows-what-else is likely to be low. If you want to accurately know > about cache behaviour you'd be much better off using hardware counters via > `perf` or some other profiler. > > But `--cache-sim=no` is still very useful because instruction execution > counts are still very useful. > > Therefore, I propose changing the default to `--cache-sim=no`. Does anyone > have any objections to this? > > Thanks. > > Nick > > _______________________________________________ > Valgrind-developers mailing list > Val...@li... > https://lists.sourceforge.net/lists/listinfo/valgrind-developers > |
|
From: Nicholas N. <n.n...@gm...> - 2023-04-03 10:04:56
|
On Sun, 2 Apr 2023 at 08:55, Mark Wielaard <ma...@kl...> wrote: > > So for the original buildbot CI I set it up to only run the auxtests > (that is build gsl and run the testsuite under valgrind). This used to > work on all setups, but after a gcc (or glibc?) update some setups > started failing as you can see at: > https://builder.sourceware.org/buildbot/#/builders?tags=valgrind > > For the try builders I took out the now failing builders > (debian-testing-x86_64, fedora-arm64, fedora-x86_64, ibm-power10, > opensusetw-x86_64 and rawhide-x86_64). > https://builder.sourceware.org/buildbot/#/builders?tags=valgrind-try > > Hopefully we can figure out why the auxtests fail now on some of these > setups. > What are the auxtests? I don't remember hearing about them and a Google search didn't turn up anything helpful. I looked at some of the failing builders, they all fail like this: > for gsl_test in block cblas cdf cheb combination complex const deriv dht diff eigen err fft fit histogram ieee-utils integration interpolation linalg matrix min monte multifit multimin multiroots ntuple ode-initval permutation poly qrng rng roots sort specfunc statistics sum sys vector wavelet; do echo $gsl_test; done \ > | cmp - /home/builder/valgrind-auxtests/gsl-build-g-O3/valgrind-gsl.out || \ > diff -u /home/builder/shared/bb1-2/worker/valgrind-debian-testing-x86_64/build/auxprogs/gsl-1.6.out.x86.exp \ > /home/builder/valgrind-auxtests/gsl-build-g-O3/valgrind-gsl.out > - /home/builder/valgrind-auxtests/gsl-build-g-O3/valgrind-gsl.out differ: char 226, line 32 > --- /home/builder/shared/bb1-2/worker/valgrind-debian-testing-x86_64/build/auxprogs/gsl-1.6.out.x86.exp 2022-08-09 19:45:48.726405142 +0000 > +++ /home/builder/valgrind-auxtests/gsl-build-g-O3/valgrind-gsl.out 2023-04-02 13:43:46.609646296 +0000 > @@ -15,7 +15,6 @@ > histogram > ieee-utils > integration > -FAIL: qawo(f456) elist (7.25063790881233303e-15 observed vs 7.25922435194575979e-15 expected) > interpolation > linalg > matrix > @@ -30,6 +29,10 @@ > poly > qrng > rng > +FAIL: random32-bsd, 10000 steps (852261210 observed vs 1663114331 expected) > +FAIL: random64-bsd, 10000 steps (210970120 observed vs 864469165 expected) > +FAIL: random32-libc5, 10000 steps (367802360 observed vs 1967452027 expected) > +FAIL: random64-libc5, 10000 steps (221021662 observed vs 2106639801 expected) > roots > sort > specfunc > make[1]: Leaving directory '/home/builder/shared/bb1-2/worker/valgrind-debian-testing-x86_64/build/auxprogs' > > I don't know why it's comparing against `gsl-1.6.out.x86.exp` even on x86-64, arm64, ppc64le, and so on. So should we make a new check target that runs a subset of make > regtests? Or maybe have a "ci mode" for regtests? So you would run > CI_MODE=true make regtests and it would skip any vgtest that has > prereq: test -z "$CI_MODE" > > And then add make regtests to the ci and try buildbots? > Seems reasonable. Nick |
|
From: Nicholas N. <n.n...@gm...> - 2023-04-03 09:29:43
|
Hi, Cachegrind has an option `--cache-sim`. If you run with `--cache-sim=yes` (the default) it tells it Cachegrind to do a full cache simulation with lots of events: Ir, I1mr, ILmr, Dr, D1mr, DLmr, Dw, D1mw, DLmw. If you run with `--cache-sim=no` then the cache simulation is disabled and you just get one event: Ir. (This is "instruction cache reads", which is equivalent to "instructions executed".) I have been using `--cache-sim=no` almost exclusively for a long time. The cache simulation done by Valgrind is an approximation of the memory hierarchy of a 2002 AMD Athlon processor. Its accuracy for a modern memory hierarchy with three levels of cache, prefetching, non-LRU replacement, and who-knows-what-else is likely to be low. If you want to accurately know about cache behaviour you'd be much better off using hardware counters via `perf` or some other profiler. But `--cache-sim=no` is still very useful because instruction execution counts are still very useful. Therefore, I propose changing the default to `--cache-sim=no`. Does anyone have any objections to this? Thanks. Nick |
|
From: Paul F. <pa...@so...> - 2023-04-02 13:28:48
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=0641a27ffb1969f6a6ff26fc3831588beb11ed29 commit 0641a27ffb1969f6a6ff26fc3831588beb11ed29 Author: Paul Floyd <pj...@wa...> Date: Sun Apr 2 15:28:21 2023 +0200 Darwin regtest: update strchr filter Diff: --- memcheck/tests/filter_strchr | 1 + 1 file changed, 1 insertion(+) diff --git a/memcheck/tests/filter_strchr b/memcheck/tests/filter_strchr index b770c32051..a00d7d01a5 100755 --- a/memcheck/tests/filter_strchr +++ b/memcheck/tests/filter_strchr @@ -6,4 +6,5 @@ sed -e "s/: strchr (vg_replace_strmem.c:/: index (vg_replace_strmem.c:/; s/: _platform_strchr (vg_replace_strmem.c:/: index (vg_replace_strmem.c:/; s/: _platform_strchr\$VARIANT\$Generic (vg_replace_strmem.c:/: index (vg_replace_strmem.c:/; s/: _platform_strchr\$VARIANT\$Haswell (vg_replace_strmem.c:/: index (vg_replace_strmem.c:/; + s/: _platform_strchr\$VARIANT\$Base (vg_replace_strmem.c:/: index (vg_replace_strmem.c:/; s/: strrchr (vg_replace_strmem.c:/: rindex (vg_replace_strmem.c:/" |
|
From: Paul F. <pa...@so...> - 2023-04-02 13:23:41
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=b32875d20cf8288b05ed2e5846454ba93d7aad30 commit b32875d20cf8288b05ed2e5846454ba93d7aad30 Author: Paul Floyd <pj...@wa...> Date: Sun Apr 2 15:22:54 2023 +0200 Darwin: more suppressions for Darwin 17, and another strchr wrapper Diff: --- darwin17.supp | 47 ++++++++++++++++++++++++++++++++++++++++++++++ shared/vg_replace_strmem.c | 1 + 2 files changed, 48 insertions(+) diff --git a/darwin17.supp b/darwin17.supp index 78f33477ca..5e9f3c0960 100644 --- a/darwin17.supp +++ b/darwin17.supp @@ -766,3 +766,50 @@ macos-__pthread_rwlock_init-see-our-bug-196528 Memcheck:Cond fun:pthread_rwlock_init } + +# macOS 10.13 mach-o loader at startup +{ + OSX1013:map_images-1 + Memcheck:Leak + match-leak-kinds: all + fun:*alloc + fun:NXCreate*TableFromZone +} + +{ + OSX1013:map_images-2 + Memcheck:Leak + match-leak-kinds: possible + fun:calloc + fun:map_images_nolock + fun:map_images +} +{ + OSX1013:map_images-3 + Memcheck:Leak + match-leak-kinds: definite + fun:calloc + fun:_ZL12realizeClassP10objc_class +} +{ + OSX1013:map_images-4 + Memcheck:Leak + match-leak-kinds: indirect + fun:malloc_zone_malloc + ... + fun:map_images_nolock +} +{ + OSX1013:map_images-5 + Memcheck:Leak + match-leak-kinds: indirect + fun:malloc_zone_calloc + fun:*NXHash* +} + +{ + OSX1013:_pthread_start + Helgrind:Race + fun:_pthread_start + fun:thread_start +} diff --git a/shared/vg_replace_strmem.c b/shared/vg_replace_strmem.c index 71b0e14cf5..30065d537a 100644 --- a/shared/vg_replace_strmem.c +++ b/shared/vg_replace_strmem.c @@ -293,6 +293,7 @@ static inline void my_exit ( int x ) /* _platform_strchr$VARIANT$Haswell */ STRCHR(libsystemZuplatformZddylib, _platform_strchr$VARIANT$Haswell) # endif + STRCHR(libsystemZuplatformZddylib, _platform_strchr$VARIANT$Base) #elif defined(VGO_solaris) STRCHR(VG_Z_LIBC_SONAME, strchr) |
|
From: Paul F. <pa...@so...> - 2023-04-02 12:06:00
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=28a164761f9357646920111610339a8d9e8b4579 commit 28a164761f9357646920111610339a8d9e8b4579 Author: Paul Floyd <pj...@wa...> Date: Sun Apr 2 14:03:14 2023 +0200 Darwin: missed removing a couple of delete wrappers Diff: --- coregrind/m_replacemalloc/vg_replace_malloc.c | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/coregrind/m_replacemalloc/vg_replace_malloc.c b/coregrind/m_replacemalloc/vg_replace_malloc.c index eed82381af..78d0b33104 100644 --- a/coregrind/m_replacemalloc/vg_replace_malloc.c +++ b/coregrind/m_replacemalloc/vg_replace_malloc.c @@ -1034,15 +1034,6 @@ extern int * __error(void) __attribute__((weak)); FREE(VG_Z_LIBSTDCXX_SONAME, _ZdlPv, __builtin_delete ); FREE(VG_Z_LIBCXX_SONAME, _ZdlPv, __builtin_delete ); FREE(SO_SYN_MALLOC, _ZdlPv, __builtin_delete ); -#if __SIZEOF_SIZE_T__ == 4 - FREE(VG_Z_LIBSTDCXX_SONAME, _ZdlPvj, __builtin_delete ); - FREE(VG_Z_LIBCXX_SONAME, _ZdlPvj, __builtin_delete ); - FREE(SO_SYN_MALLOC, _ZdlPvj, __builtin_delete ); -#elif __SIZEOF_SIZE_T__ == 8 - FREE(VG_Z_LIBSTDCXX_SONAME, _ZdlPvm, __builtin_delete ); - FREE(VG_Z_LIBCXX_SONAME, _ZdlPvm, __builtin_delete ); - FREE(SO_SYN_MALLOC, _ZdlPvm, __builtin_delete ); -#endif #elif defined(VGO_solaris) // operator delete(void*) @@ -1307,17 +1298,6 @@ extern int * __error(void) __attribute__((weak)); FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPv, __builtin_vec_delete ); FREE(VG_Z_LIBCXX_SONAME, _ZdaPv, __builtin_vec_delete ); FREE(SO_SYN_MALLOC, _ZdaPv, __builtin_vec_delete ); - #if __SIZEOF_SIZE_T__ == 4 - FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPvj, __builtin_vec_delete ); - FREE(VG_Z_LIBCXX_SONAME, _ZdaPvj, __builtin_vec_delete ); - FREE(SO_SYN_MALLOC, _ZdaPvj, __builtin_vec_delete ); - - #elif __SIZEOF_SIZE_T__ == 8 - FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPvm, __builtin_vec_delete ); - FREE(VG_Z_LIBCXX_SONAME, _ZdaPvm, __builtin_vec_delete ); - FREE(SO_SYN_MALLOC, _ZdaPvm, __builtin_vec_delete ); - #endif - #elif defined(VGO_solaris) // operator delete[](void*) |
|
From: Paul F. <pa...@so...> - 2023-04-02 11:44:54
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=e27f24c1653d55854bd823231ca574b22128f70c commit e27f24c1653d55854bd823231ca574b22128f70c Author: Paul Floyd <pj...@wa...> Date: Sun Apr 2 13:43:14 2023 +0200 Darwin and FreeBSD: new / delete wrappers A few typos in the FreeBSD soname wrappers Many missing Darwin wrappers And no need to repeat that GNU mangling is used Diff: --- coregrind/m_replacemalloc/vg_replace_malloc.c | 386 +++++++++++++++++--------- 1 file changed, 261 insertions(+), 125 deletions(-) diff --git a/coregrind/m_replacemalloc/vg_replace_malloc.c b/coregrind/m_replacemalloc/vg_replace_malloc.c index 64d9b67c1e..eed82381af 100644 --- a/coregrind/m_replacemalloc/vg_replace_malloc.c +++ b/coregrind/m_replacemalloc/vg_replace_malloc.c @@ -457,14 +457,14 @@ extern int * __error(void) __attribute__((weak)); ALLOC_or_BOMB(VG_Z_LIBC_SONAME, builtin_new, __builtin_new); ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, __builtin_new, __builtin_new); ALLOC_or_BOMB(VG_Z_LIBC_SONAME, __builtin_new, __builtin_new); - // operator new(unsigned int), GNU mangling + // operator new(unsigned int) #if VG_WORDSIZE == 4 ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znwj, __builtin_new); ALLOC_or_BOMB(VG_Z_LIBCXX_SONAME, _Znwj, __builtin_new); ALLOC_or_BOMB(VG_Z_LIBC_SONAME, _Znwj, __builtin_new); ALLOC_or_BOMB(SO_SYN_MALLOC, _Znwj, __builtin_new); #endif - // operator new(unsigned long), GNU mangling + // operator new(unsigned long) #if VG_WORDSIZE == 8 ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znwm, __builtin_new); ALLOC_or_BOMB(VG_Z_LIBCXX_SONAME, _Znwm, __builtin_new); @@ -473,13 +473,13 @@ extern int * __error(void) __attribute__((weak)); #endif #elif defined(VGO_freebsd) - // operator new(unsigned int), GNU mangling + // operator new(unsigned int) #if VG_WORDSIZE == 4 ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znwj, __builtin_new); ALLOC_or_BOMB(VG_Z_LIBCXX_SONAME, _Znwj, __builtin_new); ALLOC_or_BOMB(SO_SYN_MALLOC, _Znwj, __builtin_new); #endif - // operator new(unsigned long), GNU mangling + // operator new(unsigned long) #if VG_WORDSIZE == 8 ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znwm, __builtin_new); ALLOC_or_BOMB(VG_Z_LIBCXX_SONAME, _Znwm, __builtin_new); @@ -487,24 +487,26 @@ extern int * __error(void) __attribute__((weak)); #endif #elif defined(VGO_darwin) - // operator new(unsigned int), GNU mangling + // operator new(unsigned int) #if VG_WORDSIZE == 4 - //ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znwj, __builtin_new); - //ALLOC_or_BOMB(VG_Z_LIBC_SONAME, _Znwj, __builtin_new); + ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znwj, __builtin_new); + ALLOC_or_BOMB(VG_Z_LIBCXX_SONAME, _Znwj, __builtin_new); + ALLOC_or_BOMB(VG_Z_LIBC_SONAME, _Znwj, __builtin_new); #endif - // operator new(unsigned long), GNU mangling - #if 1 // FIXME: is this right? - //ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znwm, __builtin_new); - //ALLOC_or_BOMB(VG_Z_LIBC_SONAME, _Znwm, __builtin_new); + // operator new(unsigned long) + #if VG_WORDSIZE == 8 + ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znwm, __builtin_new); + ALLOC_or_BOMB(VG_Z_LIBCXX_SONAME, _Znwm, __builtin_new); + ALLOC_or_BOMB(SO_SYN_MALLOC, _Znwm, __builtin_new); #endif #elif defined(VGO_solaris) - // operator new(unsigned int), GNU mangling + // operator new(unsigned int) #if VG_WORDSIZE == 4 ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znwj, __builtin_new); ALLOC_or_BOMB(SO_SYN_MALLOC, _Znwj, __builtin_new); #endif - // operator new(unsigned long), GNU mangling + // operator new(unsigned long) #if VG_WORDSIZE == 8 ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znwm, __builtin_new); ALLOC_or_BOMB(SO_SYN_MALLOC, _Znwm, __builtin_new); @@ -515,14 +517,14 @@ extern int * __error(void) __attribute__((weak)); /*------------------- C++17 new aligned -------------------*/ #if defined(VGO_linux) - // operator new(unsigned int, std::align_val_t), GNU mangling + // operator new(unsigned int, std::align_val_t) #if VG_WORDSIZE == 4 ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwjSt11align_val_t, __builtin_new_aligned); ALLOC_or_BOMB_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnwjSt11align_val_t, __builtin_new_aligned); ALLOC_or_BOMB_ALIGNED(VG_Z_LIBC_SONAME, _ZnwjSt11align_val_t, __builtin_new_aligned); ALLOC_or_BOMB_ALIGNED(SO_SYN_MALLOC, _ZnwjSt11align_val_t, __builtin_new_aligned); #endif - // operator new(unsigned long, std::align_val_t), GNU mangling + // operator new(unsigned long, std::align_val_t) #if VG_WORDSIZE == 8 ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwmSt11align_val_t, __builtin_new_aligned); ALLOC_or_BOMB_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnwmSt11align_val_t, __builtin_new_aligned); @@ -531,13 +533,13 @@ extern int * __error(void) __attribute__((weak)); #endif #elif defined(VGO_freebsd) - // operator new(unsigned int), GNU mangling + // operator new(unsigned int) #if VG_WORDSIZE == 4 ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwjSt11align_val_t, __builtin_new_aligned); ALLOC_or_BOMB_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnwjSt11align_val_t, __builtin_new_aligned); ALLOC_or_BOMB_ALIGNED(SO_SYN_MALLOC, _ZnwjSt11align_val_t, __builtin_new_aligned); #endif - // operator new(unsigned long), GNU mangling + // operator new(unsigned long) #if VG_WORDSIZE == 8 ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwmSt11align_val_t, __builtin_new_aligned); ALLOC_or_BOMB_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnwmSt11align_val_t, __builtin_new_aligned); @@ -545,14 +547,24 @@ extern int * __error(void) __attribute__((weak)); #endif #elif defined(VGO_darwin) + #if VG_WORDSIZE == 4 + ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwjSt11align_val_t, __builtin_new_aligned); + ALLOC_or_BOMB_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnwjSt11align_val_t, __builtin_new_aligned); + ALLOC_or_BOMB_ALIGNED(SO_SYN_MALLOC, _ZnwjSt11align_val_t, __builtin_new_aligned); + #endif + #if VG_WORDSIZE == 8 + ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwmSt11align_val_t, __builtin_new_aligned); + ALLOC_or_BOMB_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnwmSt11align_val_t, __builtin_new_aligned); + ALLOC_or_BOMB_ALIGNED(SO_SYN_MALLOC, _ZnwmSt11align_val_t, __builtin_new_aligned); + #endif #elif defined(VGO_solaris) - // operator new(unsigned int, std::align_val_t), GNU mangling + // operator new(unsigned int, std::align_val_t) #if VG_WORDSIZE == 4 ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwjSt11align_val_t, __builtin_new_aligned); ALLOC_or_BOMB_ALIGNED(SO_SYN_MALLOC, _ZnwjSt11align_val_t, __builtin_new_aligned); #endif - // operator new(unsigned long, std::align_val_t), GNU mangling + // operator new(unsigned long, std::align_val_t) #if VG_WORDSIZE == 8 ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwmSt11align_val_t, __builtin_new_aligned); ALLOC_or_BOMB_ALIGNED(SO_SYN_MALLOC, _ZnwmSt11align_val_t, __builtin_new_aligned); @@ -565,14 +577,14 @@ extern int * __error(void) __attribute__((weak)); /*---------------------- new nothrow ----------------------*/ #if defined(VGO_linux) - // operator new(unsigned, std::nothrow_t const&), GNU mangling + // operator new(unsigned, std::nothrow_t const&) #if VG_WORDSIZE == 4 ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnwjRKSt9nothrow_t, __builtin_new); ALLOC_or_NULL(VG_Z_LIBCXX_SONAME, _ZnwjRKSt9nothrow_t, __builtin_new); ALLOC_or_NULL(VG_Z_LIBC_SONAME, _ZnwjRKSt9nothrow_t, __builtin_new); ALLOC_or_NULL(SO_SYN_MALLOC, _ZnwjRKSt9nothrow_t, __builtin_new); #endif - // operator new(unsigned long, std::nothrow_t const&), GNU mangling + // operator new(unsigned long, std::nothrow_t const&) #if VG_WORDSIZE == 8 ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnwmRKSt9nothrow_t, __builtin_new); ALLOC_or_NULL(VG_Z_LIBCXX_SONAME, _ZnwmRKSt9nothrow_t, __builtin_new); @@ -581,38 +593,40 @@ extern int * __error(void) __attribute__((weak)); #endif #elif defined(VGO_freebsd) - // operator new(unsigned, std::nothrow_t const&), GNU mangling + // operator new(unsigned, std::nothrow_t const&) #if VG_WORDSIZE == 4 ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnwjRKSt9nothrow_t, __builtin_new); ALLOC_or_BOMB(VG_Z_LIBCXX_SONAME, _ZnwjRKSt9nothrow_t, __builtin_new); ALLOC_or_NULL(SO_SYN_MALLOC, _ZnwjRKSt9nothrow_t, __builtin_new); #endif - // operator new(unsigned long, std::nothrow_t const&), GNU mangling + // operator new(unsigned long, std::nothrow_t const&) #if VG_WORDSIZE == 8 ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnwmRKSt9nothrow_t, __builtin_new); ALLOC_or_NULL(VG_Z_LIBCXX_SONAME, _ZnwmRKSt9nothrow_t, __builtin_new); - ALLOC_or_NULL(SO_SYN_MALLOC, _ZnwjRKSt9nothrow_t, __builtin_new); + ALLOC_or_NULL(SO_SYN_MALLOC, _ZnwmRKSt9nothrow_t, __builtin_new); #endif #elif defined(VGO_darwin) - // operator new(unsigned, std::nothrow_t const&), GNU mangling + // operator new(unsigned, std::nothrow_t const&) #if VG_WORDSIZE == 4 - //ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnwjRKSt9nothrow_t, __builtin_new); - //ALLOC_or_NULL(VG_Z_LIBC_SONAME, _ZnwjRKSt9nothrow_t, __builtin_new); + ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnwjRKSt9nothrow_t, __builtin_new); + ALLOC_or_NULL(VG_Z_LIBCXX_SONAME, _ZnwjRKSt9nothrow_t, __builtin_new); + ALLOC_or_NULL(VG_Z_LIBC_SONAME, _ZnwjRKSt9nothrow_t, __builtin_new); #endif - // operator new(unsigned long, std::nothrow_t const&), GNU mangling - #if 1 // FIXME: is this right? - //ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnwmRKSt9nothrow_t, __builtin_new); - //ALLOC_or_NULL(VG_Z_LIBC_SONAME, _ZnwmRKSt9nothrow_t, __builtin_new); + // operator new(unsigned long, std::nothrow_t const&) + #if VG_WORDSIZE == 8 + ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnwmRKSt9nothrow_t, __builtin_new); + ALLOC_or_NULL(VG_Z_LIBCXX_SONAME, _ZnwmRKSt9nothrow_t, __builtin_new); + ALLOC_or_NULL(SO_SYN_MALLOC, _ZnwmRKSt9nothrow_t, __builtin_new); #endif #elif defined(VGO_solaris) - // operator new(unsigned, std::nothrow_t const&), GNU mangling + // operator new(unsigned, std::nothrow_t const&) #if VG_WORDSIZE == 4 ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnwjRKSt9nothrow_t, __builtin_new); ALLOC_or_NULL(SO_SYN_MALLOC, _ZnwjRKSt9nothrow_t, __builtin_new); #endif - // operator new(unsigned long, std::nothrow_t const&), GNU mangling + // operator new(unsigned long, std::nothrow_t const&) #if VG_WORDSIZE == 8 ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnwmRKSt9nothrow_t, __builtin_new); ALLOC_or_NULL(SO_SYN_MALLOC, _ZnwmRKSt9nothrow_t, __builtin_new); @@ -623,14 +637,14 @@ extern int * __error(void) __attribute__((weak)); /*----------------- C++17 new aligned nothrow -----------------*/ #if defined(VGO_linux) - // operator new(unsigned int, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator new(unsigned int, std::align_val_t, std::nothrow_t const&) #if VG_WORDSIZE == 4 ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwjSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); ALLOC_or_NULL_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnwjSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); ALLOC_or_NULL_ALIGNED(VG_Z_LIBC_SONAME, _ZnwjSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); ALLOC_or_NULL_ALIGNED(SO_SYN_MALLOC, _ZnwjSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); #endif - // operator new(unsigned long, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator new(unsigned long, std::align_val_t, std::nothrow_t const&) #if VG_WORDSIZE == 8 ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwmSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); ALLOC_or_NULL_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnwmSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); @@ -639,13 +653,13 @@ extern int * __error(void) __attribute__((weak)); #endif #elif defined(VGO_freebsd) - // operator new(unsigned int, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator new(unsigned int, std::align_val_t, std::nothrow_t const&) #if VG_WORDSIZE == 4 ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwjSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); ALLOC_or_NULL_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnwjSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); ALLOC_or_NULL_ALIGNED(SO_SYN_MALLOC, _ZnwjSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); #endif - // operator new(unsigned long, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator new(unsigned long, std::align_val_t, std::nothrow_t const&) #if VG_WORDSIZE == 8 ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwmSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); ALLOC_or_NULL_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnwmSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); @@ -653,14 +667,24 @@ extern int * __error(void) __attribute__((weak)); #endif #elif defined(VGO_darwin) + #if VG_WORDSIZE == 4 + ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwjSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); + ALLOC_or_NULL_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnwjSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); + ALLOC_or_NULL_ALIGNED(SO_SYN_MALLOC, _ZnwjSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); + #endif + #if VG_WORDSIZE == 8 + ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwmSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); + ALLOC_or_NULL_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnwmSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); + ALLOC_or_NULL_ALIGNED(SO_SYN_MALLOC, _ZnwmSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); + #endif #elif defined(VGO_solaris) - // operator new(unsigned, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator new(unsigned, std::align_val_t, std::nothrow_t const&) #if VG_WORDSIZE == 4 ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, __ZnwjSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); ALLOC_or_NULL_ALIGNED(SO_SYN_MALLOC, __ZnwjSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); #endif - // operator new(unsigned long, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator new(unsigned long, std::align_val_t, std::nothrow_t const&) #if VG_WORDSIZE == 8 ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnwmSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); ALLOC_or_NULL_ALIGNED(SO_SYN_MALLOC, _ZnwmSt11align_val_tRKSt9nothrow_t, __builtin_new_aligned); @@ -675,14 +699,14 @@ extern int * __error(void) __attribute__((weak)); // operator new[](unsigned int), not mangled (for gcc 2.96) ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, __builtin_vec_new, __builtin_vec_new ); ALLOC_or_BOMB(VG_Z_LIBC_SONAME, __builtin_vec_new, __builtin_vec_new ); - // operator new[](unsigned int), GNU mangling + // operator new[](unsigned int) #if VG_WORDSIZE == 4 ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znaj, __builtin_vec_new ); ALLOC_or_BOMB(VG_Z_LIBCXX_SONAME, _Znaj, __builtin_vec_new ); ALLOC_or_BOMB(VG_Z_LIBC_SONAME, _Znaj, __builtin_vec_new ); ALLOC_or_BOMB(SO_SYN_MALLOC, _Znaj, __builtin_vec_new ); #endif - // operator new[](unsigned long), GNU mangling + // operator new[](unsigned long), #if VG_WORDSIZE == 8 ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znam, __builtin_vec_new ); ALLOC_or_BOMB(VG_Z_LIBCXX_SONAME, _Znam, __builtin_vec_new ); @@ -691,38 +715,40 @@ extern int * __error(void) __attribute__((weak)); #endif #elif defined(VGO_freebsd) - // operator new[](unsigned int), GNU mangling + // operator new[](unsigned int) #if VG_WORDSIZE == 4 ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znaj, __builtin_vec_new ); ALLOC_or_BOMB(VG_Z_LIBCXX_SONAME, _Znaj, __builtin_vec_new ); ALLOC_or_BOMB(SO_SYN_MALLOC, _Znaj, __builtin_vec_new ); #endif - // operator new[](unsigned long), GNU mangling + // operator new[](unsigned long) #if VG_WORDSIZE == 8 ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znam, __builtin_vec_new ); ALLOC_or_BOMB(VG_Z_LIBCXX_SONAME, _Znam, __builtin_vec_new ); - ALLOC_or_BOMB(SO_SYN_MALLOC, _Znaj, __builtin_vec_new ); + ALLOC_or_BOMB(SO_SYN_MALLOC, _Znam, __builtin_vec_new ); #endif #elif defined(VGO_darwin) - // operator new[](unsigned int), GNU mangling + // operator new[](unsigned int) #if VG_WORDSIZE == 4 - //ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znaj, __builtin_vec_new ); - //ALLOC_or_BOMB(VG_Z_LIBC_SONAME, _Znaj, __builtin_vec_new ); + ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znaj, __builtin_vec_new ); + ALLOC_or_BOMB(VG_Z_LIBCXX_SONAME, _Znaj, __builtin_vec_new ); + ALLOC_or_BOMB(SO_SYN_MALLOC, _Znaj, __builtin_vec_new ); #endif - // operator new[](unsigned long), GNU mangling - #if 1 // FIXME: is this right? - //ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znam, __builtin_vec_new ); - //ALLOC_or_BOMB(VG_Z_LIBC_SONAME, _Znam, __builtin_vec_new ); + // operator new[](unsigned long) + #if VG_WORDSIZE == 8 + ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znam, __builtin_vec_new ); + ALLOC_or_BOMB(VG_Z_LIBCXX_SONAME, _Znam, __builtin_vec_new ); + ALLOC_or_BOMB(SO_SYN_MALLOC, _Znam, __builtin_vec_new ); #endif #elif defined(VGO_solaris) - // operator new[](unsigned int), GNU mangling + // operator new[](unsigned int) #if VG_WORDSIZE == 4 ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znaj, __builtin_vec_new ); ALLOC_or_BOMB(SO_SYN_MALLOC, _Znaj, __builtin_vec_new ); #endif - // operator new[](unsigned long), GNU mangling + // operator new[](unsigned long) #if VG_WORDSIZE == 8 ALLOC_or_BOMB(VG_Z_LIBSTDCXX_SONAME, _Znam, __builtin_vec_new ); ALLOC_or_BOMB(SO_SYN_MALLOC, _Znam, __builtin_vec_new ); @@ -733,14 +759,14 @@ extern int * __error(void) __attribute__((weak)); /*------------------ C++ 17 new aligned [] ------------------*/ #if defined(VGO_linux) - // operator new[](unsigned int, std::align_val_t), GNU mangling + // operator new[](unsigned int, std::align_val_t) #if VG_WORDSIZE == 4 ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnajSt11align_val_t, __builtin_vec_new_aligned ); ALLOC_or_BOMB_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnajSt11align_val_t, __builtin_vec_new_aligned ); ALLOC_or_BOMB_ALIGNED(VG_Z_LIBC_SONAME, _ZnajSt11align_val_t, __builtin_vec_new_aligned ); ALLOC_or_BOMB_ALIGNED(SO_SYN_MALLOC, _ZnajSt11align_val_t, __builtin_vec_new_aligned ); #endif - // operator new[](unsigned long, std::align_val_t), GNU mangling + // operator new[](unsigned long, std::align_val_t) #if VG_WORDSIZE == 8 ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnamSt11align_val_t, __builtin_vec_new_aligned ); ALLOC_or_BOMB_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnamSt11align_val_t, __builtin_vec_new_aligned ); @@ -749,13 +775,13 @@ extern int * __error(void) __attribute__((weak)); #endif #elif defined(VGO_freebsd) - // operator new[](unsigned int, std::align_val_t), GNU mangling + // operator new[](unsigned int, std::align_val_t) #if VG_WORDSIZE == 4 ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnajSt11align_val_t, __builtin_vec_new_aligned ); ALLOC_or_BOMB_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnajSt11align_val_t, __builtin_vec_new_aligned ); ALLOC_or_BOMB_ALIGNED(SO_SYN_MALLOC, _ZnajSt11align_val_t, __builtin_vec_new_aligned ); #endif - // operator new[](unsigned long, std::align_val_t), GNU mangling + // operator new[](unsigned long, std::align_val_t) #if VG_WORDSIZE == 8 ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnamSt11align_val_t, __builtin_vec_new_aligned ); ALLOC_or_BOMB_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnamSt11align_val_t, __builtin_vec_new_aligned ); @@ -764,13 +790,25 @@ extern int * __error(void) __attribute__((weak)); #elif defined(VGO_darwin) + #if VG_WORDSIZE == 4 + ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnajSt11align_val_t, __builtin_vec_new_aligned ); + ALLOC_or_BOMB_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnajSt11align_val_t, __builtin_vec_new_aligned ); + ALLOC_or_BOMB_ALIGNED(SO_SYN_MALLOC, _ZnajSt11align_val_t, __builtin_vec_new_aligned ); + #endif + // operator new[](unsigned long, std::align_val_t) + #if VG_WORDSIZE == 8 + ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnamSt11align_val_t, __builtin_vec_new_aligned ); + ALLOC_or_BOMB_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnamSt11align_val_t, __builtin_vec_new_aligned ); + ALLOC_or_BOMB_ALIGNED(SO_SYN_MALLOC, _ZnamSt11align_val_t, __builtin_vec_new_aligned ); + #endif + #elif defined(VGO_solaris) - // operator new[](unsigned int, std::align_val_t), GNU mangling + // operator new[](unsigned int, std::align_val_t) #if VG_WORDSIZE == 4 ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnajSt11align_val_t, __builtin_vec_new_aligned ); ALLOC_or_BOMB_ALIGNED(SO_SYN_MALLOC, _ZnajSt11align_val_t, __builtin_vec_new_aligned ); #endif - // operator new[](unsigned long, std::align_val_t), GNU mangling + // operator new[](unsigned long, std::align_val_t) #if VG_WORDSIZE == 8 ALLOC_or_BOMB_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnamSt11align_val_t, __builtin_vec_new_aligned ); ALLOC_or_BOMB_ALIGNED(SO_SYN_MALLOC, _ZnamSt11align_val_t, __builtin_vec_new_aligned ); @@ -782,14 +820,14 @@ extern int * __error(void) __attribute__((weak)); /*---------------------- new [] nothrow ----------------------*/ #if defined(VGO_linux) - // operator new[](unsigned, std::nothrow_t const&), GNU mangling + // operator new[](unsigned, std::nothrow_t const&) #if VG_WORDSIZE == 4 ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnajRKSt9nothrow_t, __builtin_vec_new ); ALLOC_or_NULL(VG_Z_LIBCXX_SONAME, _ZnajRKSt9nothrow_t, __builtin_vec_new ); ALLOC_or_NULL(VG_Z_LIBC_SONAME, _ZnajRKSt9nothrow_t, __builtin_vec_new ); ALLOC_or_NULL(SO_SYN_MALLOC, _ZnajRKSt9nothrow_t, __builtin_vec_new ); #endif - // operator new[](unsigned long, std::nothrow_t const&), GNU mangling + // operator new[](unsigned long, std::nothrow_t const&) #if VG_WORDSIZE == 8 ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnamRKSt9nothrow_t, __builtin_vec_new ); ALLOC_or_NULL(VG_Z_LIBCXX_SONAME, _ZnamRKSt9nothrow_t, __builtin_vec_new ); @@ -798,38 +836,40 @@ extern int * __error(void) __attribute__((weak)); #endif #elif defined(VGO_freebsd) - // operator new[](unsigned, std::nothrow_t const&), GNU mangling + // operator new[](unsigned, std::nothrow_t const&) #if VG_WORDSIZE == 4 ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnajRKSt9nothrow_t, __builtin_vec_new ); ALLOC_or_NULL(VG_Z_LIBCXX_SONAME, _ZnajRKSt9nothrow_t, __builtin_vec_new ); ALLOC_or_NULL(SO_SYN_MALLOC, _ZnajRKSt9nothrow_t, __builtin_vec_new ); #endif - // operator new[](unsigned long, std::nothrow_t const&), GNU mangling + // operator new[](unsigned long, std::nothrow_t const&) #if VG_WORDSIZE == 8 ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnamRKSt9nothrow_t, __builtin_vec_new ); ALLOC_or_NULL(VG_Z_LIBCXX_SONAME, _ZnamRKSt9nothrow_t, __builtin_vec_new ); - ALLOC_or_NULL(SO_SYN_MALLOC, _ZnajRKSt9nothrow_t, __builtin_vec_new ); + ALLOC_or_NULL(SO_SYN_MALLOC, _ZnamRKSt9nothrow_t, __builtin_vec_new ); #endif #elif defined(VGO_darwin) - // operator new[](unsigned, std::nothrow_t const&), GNU mangling + // operator new[](unsigned, std::nothrow_t const&) #if VG_WORDSIZE == 4 - //ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnajRKSt9nothrow_t, __builtin_vec_new ); - //ALLOC_or_NULL(VG_Z_LIBC_SONAME, _ZnajRKSt9nothrow_t, __builtin_vec_new ); + ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnajRKSt9nothrow_t, __builtin_vec_new ); + ALLOC_or_NULL(VG_Z_LIBCXX_SONAME, _ZnajRKSt9nothrow_t, __builtin_vec_new ); + ALLOC_or_NULL(VG_Z_LIBC_SONAME, _ZnajRKSt9nothrow_t, __builtin_vec_new ); #endif - // operator new[](unsigned long, std::nothrow_t const&), GNU mangling - #if 1 // FIXME: is this right? - //ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnamRKSt9nothrow_t, __builtin_vec_new ); - //ALLOC_or_NULL(VG_Z_LIBC_SONAME, _ZnamRKSt9nothrow_t, __builtin_vec_new ); + // operator new[](unsigned long, std::nothrow_t const&) + #if VG_WORDSIZE == 8 + ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnamRKSt9nothrow_t, __builtin_vec_new ); + ALLOC_or_NULL(VG_Z_LIBCXX_SONAME, _ZnamRKSt9nothrow_t, __builtin_vec_new ); + ALLOC_or_NULL(SO_SYN_MALLOC, _ZnamRKSt9nothrow_t, __builtin_vec_new ); #endif #elif defined(VGO_solaris) - // operator new[](unsigned, std::nothrow_t const&), GNU mangling + // operator new[](unsigned, std::nothrow_t const&) #if VG_WORDSIZE == 4 ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnajRKSt9nothrow_t, __builtin_vec_new ); ALLOC_or_NULL(SO_SYN_MALLOC, _ZnajRKSt9nothrow_t, __builtin_vec_new ); #endif - // operator new[](unsigned long, std::nothrow_t const&), GNU mangling + // operator new[](unsigned long, std::nothrow_t const&) #if VG_WORDSIZE == 8 ALLOC_or_NULL(VG_Z_LIBSTDCXX_SONAME, _ZnamRKSt9nothrow_t, __builtin_vec_new ); ALLOC_or_NULL(SO_SYN_MALLOC, _ZnamRKSt9nothrow_t, __builtin_vec_new ); @@ -840,14 +880,14 @@ extern int * __error(void) __attribute__((weak)); /*----------------- C++17 new aligned [] nothrow -----------------*/ #if defined(VGO_linux) - // operator new[](unsigned int, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator new[](unsigned int, std::align_val_t, std::nothrow_t const&) #if VG_WORDSIZE == 4 ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnajSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); ALLOC_or_NULL_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnajSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); ALLOC_or_NULL_ALIGNED(VG_Z_LIBC_SONAME, _ZnajSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); ALLOC_or_NULL_ALIGNED(SO_SYN_MALLOC, _ZnajSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); #endif - // operator new[](unsigned long, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator new[](unsigned long, std::align_val_t, std::nothrow_t const&) #if VG_WORDSIZE == 8 ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnamSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); ALLOC_or_NULL_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnamSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); @@ -856,13 +896,13 @@ extern int * __error(void) __attribute__((weak)); #endif #elif defined(VGO_freebsd) - // operator new[](unsigned int, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator new[](unsigned int, std::align_val_t, std::nothrow_t const&) #if VG_WORDSIZE == 4 ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnajSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); ALLOC_or_NULL_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnajSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); ALLOC_or_NULL_ALIGNED(SO_SYN_MALLOC, _ZnajSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); #endif - // operator new[](unsigned long, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator new[](unsigned long, std::align_val_t, std::nothrow_t const&) #if VG_WORDSIZE == 8 ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnamSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); ALLOC_or_NULL_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnamSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); @@ -871,13 +911,25 @@ extern int * __error(void) __attribute__((weak)); #elif defined(VGO_darwin) + #if VG_WORDSIZE == 4 + ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnajSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); + ALLOC_or_NULL_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnajSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); + ALLOC_or_NULL_ALIGNED(SO_SYN_MALLOC, _ZnajSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); + #endif + // operator new[](unsigned long, std::align_val_t, std::nothrow_t const&) + #if VG_WORDSIZE == 8 + ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnamSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); + ALLOC_or_NULL_ALIGNED(VG_Z_LIBCXX_SONAME, _ZnamSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); + ALLOC_or_NULL_ALIGNED(SO_SYN_MALLOC, _ZnamSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); + #endif + #elif defined(VGO_solaris) - // operator new[](unsigned int, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator new[](unsigned int, std::align_val_t, std::nothrow_t const&) #if VG_WORDSIZE == 4 ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnajSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); ALLOC_or_NULL_ALIGNED(SO_SYN_MALLOC, _ZnajSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); #endif - // operator new[](unsigned long, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator new[](unsigned long, std::align_val_t, std::nothrow_t const&) #if VG_WORDSIZE == 8 ALLOC_or_NULL_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZnamSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); ALLOC_or_NULL_ALIGNED(SO_SYN_MALLOC, _ZnamSt11align_val_tRKSt9nothrow_t, __builtin_vec_new_aligned ); @@ -966,7 +1018,7 @@ extern int * __error(void) __attribute__((weak)); // operator delete(void*), not mangled (for gcc 2.96) FREE(VG_Z_LIBSTDCXX_SONAME, __builtin_delete, __builtin_delete ); FREE(VG_Z_LIBC_SONAME, __builtin_delete, __builtin_delete ); - // operator delete(void*), GNU mangling + // operator delete(void*) FREE(VG_Z_LIBSTDCXX_SONAME, _ZdlPv, __builtin_delete ); FREE(VG_Z_LIBCXX_SONAME, _ZdlPv, __builtin_delete ); FREE(VG_Z_LIBC_SONAME, _ZdlPv, __builtin_delete ); @@ -978,12 +1030,22 @@ extern int * __error(void) __attribute__((weak)); FREE(SO_SYN_MALLOC, _ZdlPv, __builtin_delete ); #elif defined(VGO_darwin) - // operator delete(void*), GNU mangling - //FREE(VG_Z_LIBSTDCXX_SONAME, _ZdlPv, __builtin_delete ); - //FREE(VG_Z_LIBC_SONAME, _ZdlPv, __builtin_delete ); + // operator delete(void*) + FREE(VG_Z_LIBSTDCXX_SONAME, _ZdlPv, __builtin_delete ); + FREE(VG_Z_LIBCXX_SONAME, _ZdlPv, __builtin_delete ); + FREE(SO_SYN_MALLOC, _ZdlPv, __builtin_delete ); +#if __SIZEOF_SIZE_T__ == 4 + FREE(VG_Z_LIBSTDCXX_SONAME, _ZdlPvj, __builtin_delete ); + FREE(VG_Z_LIBCXX_SONAME, _ZdlPvj, __builtin_delete ); + FREE(SO_SYN_MALLOC, _ZdlPvj, __builtin_delete ); +#elif __SIZEOF_SIZE_T__ == 8 + FREE(VG_Z_LIBSTDCXX_SONAME, _ZdlPvm, __builtin_delete ); + FREE(VG_Z_LIBCXX_SONAME, _ZdlPvm, __builtin_delete ); + FREE(SO_SYN_MALLOC, _ZdlPvm, __builtin_delete ); +#endif #elif defined(VGO_solaris) - // operator delete(void*), GNU mangling + // operator delete(void*) FREE(VG_Z_LIBSTDCXX_SONAME, _ZdlPv, __builtin_delete ); FREE(SO_SYN_MALLOC, _ZdlPv, __builtin_delete ); @@ -1033,6 +1095,17 @@ extern int * __error(void) __attribute__((weak)); #endif #elif defined(VGO_darwin) + // operator delete(void*, unsigned int) +#if __SIZEOF_SIZE_T__ == 4 + DELETE_SIZED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvj, __builtin_delete ); + DELETE_SIZED(VG_Z_LIBCXX_SONAME, _ZdlPvj, __builtin_delete ); + DELETE_SIZED(SO_SYN_MALLOC, _ZdlPvj, __builtin_delete ); +#elif __SIZEOF_SIZE_T__ == 8 + // operator delete(void*, unsigned long) + DELETE_SIZED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvm, __builtin_delete ); + DELETE_SIZED(VG_Z_LIBCXX_SONAME, _ZdlPvm, __builtin_delete ); + DELETE_SIZED(SO_SYN_MALLOC, _ZdlPvm, __builtin_delete ); +#endif #elif defined(VGO_solaris) // operator delete(void*, unsigned long) @@ -1076,19 +1149,19 @@ extern int * __error(void) __attribute__((weak)); } #if defined(VGO_linux) - // operator delete(void*, std::align_val_t), GNU mangling + // operator delete(void*, std::align_val_t) DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvSt11align_val_t, __builtin_delete_aligned ); DELETE_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdlPvSt11align_val_t, __builtin_delete_aligned ); DELETE_ALIGNED(VG_Z_LIBC_SONAME, _ZdlPvSt11align_val_t, __builtin_delete_aligned ); DELETE_ALIGNED(SO_SYN_MALLOC, _ZdlPvSt11align_val_t, __builtin_delete_aligned ); - // operator delete(void*, unsigned int, std::align_val_t), GNU mangling + // operator delete(void*, unsigned int, std::align_val_t) #if __SIZEOF_SIZE_T__ == 4 DELETE_SIZED_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvjSt11align_val_t, __builtin_delete_aligned ); DELETE_SIZED_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdlPvjSt11align_val_t, __builtin_delete_aligned ); DELETE_SIZED_ALIGNED(VG_Z_LIBC_SONAME, _ZdlPvjSt11align_val_t, __builtin_delete_aligned ); DELETE_SIZED_ALIGNED(SO_SYN_MALLOC, _ZdlPvjSt11align_val_t, __builtin_delete_aligned ); - // operator delete(void*, unsigned long, std::align_val_t), GNU mangling + // operator delete(void*, unsigned long, std::align_val_t) #elif __SIZEOF_SIZE_T__ == 8 DELETE_SIZED_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvmSt11align_val_t, __builtin_delete_aligned ); DELETE_SIZED_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdlPvmSt11align_val_t, __builtin_delete_aligned ); @@ -1097,17 +1170,17 @@ extern int * __error(void) __attribute__((weak)); #endif #elif defined(VGO_freebsd) - // operator delete(void*, std::align_val_t), GNU mangling + // operator delete(void*, std::align_val_t) DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvSt11align_val_t, __builtin_delete_aligned ); DELETE_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdlPvSt11align_val_t, __builtin_delete_aligned ); DELETE_ALIGNED(SO_SYN_MALLOC, _ZdlPvSt11align_val_t, __builtin_delete_aligned ); - // operator delete(void*, unsigned int, std::align_val_t), GNU mangling + // operator delete(void*, unsigned int, std::align_val_t) #if __SIZEOF_SIZE_T__ == 4 DELETE_SIZED_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvjSt11align_val_t, __builtin_delete_aligned ); DELETE_SIZED_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdlPvjSt11align_val_t, __builtin_delete_aligned ); DELETE_SIZED_ALIGNED(SO_SYN_MALLOC, _ZdlPvjSt11align_val_t, __builtin_delete_aligned ); - // operator delete(void*, unsigned long, std::align_val_t), GNU mangling + // operator delete(void*, unsigned long, std::align_val_t) #elif __SIZEOF_SIZE_T__ == 8 DELETE_SIZED_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvmSt11align_val_t, __builtin_delete_aligned ); DELETE_SIZED_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdlPvmSt11align_val_t, __builtin_delete_aligned ); @@ -1116,6 +1189,23 @@ extern int * __error(void) __attribute__((weak)); #elif defined(VGO_darwin) + // operator delete(void*, std::align_val_t) + DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvSt11align_val_t, __builtin_delete_aligned ); + DELETE_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdlPvSt11align_val_t, __builtin_delete_aligned ); + DELETE_ALIGNED(SO_SYN_MALLOC, _ZdlPvSt11align_val_t, __builtin_delete_aligned ); + + // operator delete(void*, unsigned int, std::align_val_t) +#if __SIZEOF_SIZE_T__ == 4 + DELETE_SIZED_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvjSt11align_val_t, __builtin_delete_aligned ); + DELETE_SIZED_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdlPvjSt11align_val_t, __builtin_delete_aligned ); + DELETE_SIZED_ALIGNED(SO_SYN_MALLOC, _ZdlPvjSt11align_val_t, __builtin_delete_aligned ); + // operator delete(void*, unsigned long, std::align_val_t) +#elif __SIZEOF_SIZE_T__ == 8 + DELETE_SIZED_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvmSt11align_val_t, __builtin_delete_aligned ); + DELETE_SIZED_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdlPvmSt11align_val_t, __builtin_delete_aligned ); + DELETE_SIZED_ALIGNED(SO_SYN_MALLOC, _ZdlPvmSt11align_val_t, __builtin_delete_aligned ); +#endif + #elif defined(VGO_solaris) // operator delete(void*, std::align_val_t) @@ -1137,25 +1227,26 @@ extern int * __error(void) __attribute__((weak)); /*---------------------- delete nothrow ----------------------*/ #if defined(VGO_linux) - // operator delete(void*, std::nothrow_t const&), GNU mangling + // operator delete(void*, std::nothrow_t const&) FREE(VG_Z_LIBSTDCXX_SONAME, _ZdlPvRKSt9nothrow_t, __builtin_delete ); FREE(VG_Z_LIBCXX_SONAME, _ZdlPvRKSt9nothrow_t, __builtin_delete ); FREE(VG_Z_LIBC_SONAME, _ZdlPvRKSt9nothrow_t, __builtin_delete ); FREE(SO_SYN_MALLOC, _ZdlPvRKSt9nothrow_t, __builtin_delete ); #elif defined(VGO_freebsd) - // operator delete(void*, std::nothrow_t const&), GNU mangling + // operator delete(void*, std::nothrow_t const&) FREE(VG_Z_LIBSTDCXX_SONAME, _ZdlPvRKSt9nothrow_t, __builtin_delete ); FREE(VG_Z_LIBCXX_SONAME, _ZdlPvRKSt9nothrow_t, __builtin_delete ); FREE(SO_SYN_MALLOC, _ZdlPvRKSt9nothrow_t, __builtin_delete ); #elif defined(VGO_darwin) - // operator delete(void*, std::nothrow_t const&), GNU mangling - //FREE(VG_Z_LIBSTDCXX_SONAME, _ZdlPvRKSt9nothrow_t, __builtin_delete ); - //FREE(VG_Z_LIBC_SONAME, _ZdlPvRKSt9nothrow_t, __builtin_delete ); + // operator delete(void*, std::nothrow_t const&) + FREE(VG_Z_LIBSTDCXX_SONAME, _ZdlPvRKSt9nothrow_t, __builtin_delete ); + FREE(VG_Z_LIBCXX_SONAME, _ZdlPvRKSt9nothrow_t, __builtin_delete ); + FREE(SO_SYN_MALLOC, _ZdlPvRKSt9nothrow_t, __builtin_delete ); #elif defined(VGO_solaris) - // operator delete(void*, std::nothrow_t const&), GNU mangling + // operator delete(void*, std::nothrow_t const&) FREE(VG_Z_LIBSTDCXX_SONAME, _ZdlPvRKSt9nothrow_t, __builtin_delete ); FREE(SO_SYN_MALLOC, _ZdlPvRKSt9nothrow_t, __builtin_delete ); @@ -1164,7 +1255,7 @@ extern int * __error(void) __attribute__((weak)); /*---------------------- C++17 delete aligned nothrow ----------------------*/ #if defined(VGO_linux) - // operator delete(void*, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator delete(void*, std::align_val_t, std::nothrow_t const&) DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvSt11align_val_tRKSt9nothrow_t, __builtin_delete_aligned ); DELETE_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdlPvSt11align_val_tRKSt9nothrow_t, __builtin_delete_aligned ); DELETE_ALIGNED(VG_Z_LIBC_SONAME, _ZdlPvSt11align_val_tRKSt9nothrow_t, __builtin_delete_aligned ); @@ -1173,15 +1264,19 @@ extern int * __error(void) __attribute__((weak)); // no sized version of this operator #elif defined(VGO_freebsd) - // operator delete(void*, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator delete(void*, std::align_val_t, std::nothrow_t const&) DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvSt11align_val_tRKSt9nothrow_t, __builtin_delete_aligned ); DELETE_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdlPvSt11align_val_tRKSt9nothrow_t, __builtin_delete_aligned ); DELETE_ALIGNED(SO_SYN_MALLOC, _ZdlPvSt11align_val_tRKSt9nothrow_t, __builtin_delete_aligned ); #elif defined(VGO_darwin) + DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvSt11align_val_tRKSt9nothrow_t, __builtin_delete_aligned ); + DELETE_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdlPvSt11align_val_tRKSt9nothrow_t, __builtin_delete_aligned ); + DELETE_ALIGNED(SO_SYN_MALLOC, _ZdlPvSt11align_val_tRKSt9nothrow_t, __builtin_delete_aligned ); + #elif defined(VGO_solaris) - // operator delete(void*, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator delete(void*, std::align_val_t, std::nothrow_t const&) DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdlPvSt11align_val_tRKSt9nothrow_t, __builtin_delete_aligned ); DELETE_ALIGNED(SO_SYN_MALLOC, _ZdlPvSt11align_val_tRKSt9nothrow_t, __builtin_delete_aligned ); @@ -1196,28 +1291,36 @@ extern int * __error(void) __attribute__((weak)); // operator delete[](void*), not mangled (for gcc 2.96) FREE(VG_Z_LIBSTDCXX_SONAME, __builtin_vec_delete, __builtin_vec_delete ); FREE(VG_Z_LIBC_SONAME, __builtin_vec_delete, __builtin_vec_delete ); - // operator delete[](void*), GNU mangling + // operator delete[](void*) FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPv, __builtin_vec_delete ); FREE(VG_Z_LIBCXX_SONAME, _ZdaPv, __builtin_vec_delete ); FREE(VG_Z_LIBC_SONAME, _ZdaPv, __builtin_vec_delete ); FREE(SO_SYN_MALLOC, _ZdaPv, __builtin_vec_delete ); #elif defined(VGO_freebsd) - // operator delete[](void*), GNU mangling + // operator delete[](void*) FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPv, __builtin_vec_delete ); FREE(VG_Z_LIBCXX_SONAME, _ZdaPv, __builtin_vec_delete ); FREE(SO_SYN_MALLOC, _ZdaPv, __builtin_vec_delete ); #elif defined(VGO_darwin) - // operator delete[](void*), not mangled (for gcc 2.96) - //FREE(VG_Z_LIBSTDCXX_SONAME, __builtin_vec_delete, __builtin_vec_delete ); - //FREE(VG_Z_LIBC_SONAME, __builtin_vec_delete, __builtin_vec_delete ); - // operator delete[](void*), GNU mangling - //FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPv, __builtin_vec_delete ); - //FREE(VG_Z_LIBC_SONAME, _ZdaPv, __builtin_vec_delete ); + FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPv, __builtin_vec_delete ); + FREE(VG_Z_LIBCXX_SONAME, _ZdaPv, __builtin_vec_delete ); + FREE(SO_SYN_MALLOC, _ZdaPv, __builtin_vec_delete ); + #if __SIZEOF_SIZE_T__ == 4 + FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPvj, __builtin_vec_delete ); + FREE(VG_Z_LIBCXX_SONAME, _ZdaPvj, __builtin_vec_delete ); + FREE(SO_SYN_MALLOC, _ZdaPvj, __builtin_vec_delete ); + + #elif __SIZEOF_SIZE_T__ == 8 + FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPvm, __builtin_vec_delete ); + FREE(VG_Z_LIBCXX_SONAME, _ZdaPvm, __builtin_vec_delete ); + FREE(SO_SYN_MALLOC, _ZdaPvm, __builtin_vec_delete ); + #endif + #elif defined(VGO_solaris) - // operator delete[](void*), GNU mangling + // operator delete[](void*) FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPv, __builtin_vec_delete ); FREE(SO_SYN_MALLOC, _ZdaPv, __builtin_vec_delete ); @@ -1254,6 +1357,16 @@ extern int * __error(void) __attribute__((weak)); #elif defined(VGO_darwin) + #if __SIZEOF_SIZE_T__ == 4 + DELETE_SIZED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvj, __builtin_vec_delete ); + DELETE_SIZED(VG_Z_LIBCXX_SONAME, _ZdaPvj, __builtin_vec_delete ); + DELETE_SIZED(SO_SYN_MALLOC, _ZdaPvj, __builtin_vec_delete ); + #elif __SIZEOF_SIZE_T__ == 8 + DELETE_SIZED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvm, __builtin_vec_delete ); + DELETE_SIZED(VG_Z_LIBCXX_SONAME, _ZdaPvm, __builtin_vec_delete ); + DELETE_SIZED(SO_SYN_MALLOC, _ZdaPvm, __builtin_vec_delete ); + #endif + #elif defined(VGO_solaris) // operator delete[](void*, unsigned int) #if __SIZEOF_SIZE_T__ == 4 @@ -1270,19 +1383,19 @@ extern int * __error(void) __attribute__((weak)); /*---------------------- C++17 delete aligned [] ----------------------*/ #if defined(VGO_linux) - // operator delete[](void*, std::align_val_t), GNU mangling + // operator delete[](void*, std::align_val_t) DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdaPvSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_ALIGNED(VG_Z_LIBC_SONAME, _ZdaPvSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_ALIGNED(SO_SYN_MALLOC, _ZdaPvSt11align_val_t, __builtin_vec_delete_aligned ); - // operator delete[](void*, unsigned int, std::align_val_t), GNU mangling + // operator delete[](void*, unsigned int, std::align_val_t) #if __SIZEOF_SIZE_T__ == 4 DELETE_SIZED_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvjSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_SIZED_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdaPvjSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_SIZED_ALIGNED(VG_Z_LIBC_SONAME, _ZdaPvjSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_SIZED_ALIGNED(SO_SYN_MALLOC, _ZdaPvjSt11align_val_t, __builtin_vec_delete_aligned ); - // operator delete[](void*, unsigned long, std::align_val_t), GNU mangling + // operator delete[](void*, unsigned long, std::align_val_t) #elif __SIZEOF_SIZE_T__ == 8 DELETE_SIZED_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvmSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_SIZED_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdaPvmSt11align_val_t, __builtin_vec_delete_aligned ); @@ -1291,17 +1404,17 @@ extern int * __error(void) __attribute__((weak)); #endif #elif defined(VGO_freebsd) - // operator delete[](void*, std::align_val_t), GNU mangling + // operator delete[](void*, std::align_val_t) DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdaPvSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_ALIGNED(SO_SYN_MALLOC, _ZdaPvSt11align_val_t, __builtin_vec_delete_aligned ); - // operator delete[](void*, unsigned int, std::align_val_t), GNU mangling + // operator delete[](void*, unsigned int, std::align_val_t) #if __SIZEOF_SIZE_T__ == 4 DELETE_SIZED_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvjSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_SIZED_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdaPvjSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_SIZED_ALIGNED(SO_SYN_MALLOC, _ZdaPvjSt11align_val_t, __builtin_vec_delete_aligned ); - // operator delete[](void*, unsigned long, std::align_val_t), GNU mangling + // operator delete[](void*, unsigned long, std::align_val_t) #elif __SIZEOF_SIZE_T__ == 8 DELETE_SIZED_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvmSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_SIZED_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdaPvmSt11align_val_t, __builtin_vec_delete_aligned ); @@ -1310,8 +1423,26 @@ extern int * __error(void) __attribute__((weak)); #elif defined(VGO_darwin) + // operator delete[](void*, std::align_val_t) + DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvSt11align_val_t, __builtin_vec_delete_aligned ); + DELETE_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdaPvSt11align_val_t, __builtin_vec_delete_aligned ); + DELETE_ALIGNED(SO_SYN_MALLOC, _ZdaPvSt11align_val_t, __builtin_vec_delete_aligned ); + + // operator delete[](void*, unsigned int, std::align_val_t) + #if __SIZEOF_SIZE_T__ == 4 + DELETE_SIZED_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvjSt11align_val_t, __builtin_vec_delete_aligned ); + DELETE_SIZED_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdaPvjSt11align_val_t, __builtin_vec_delete_aligned ); + DELETE_SIZED_ALIGNED(SO_SYN_MALLOC, _ZdaPvjSt11align_val_t, __builtin_vec_delete_aligned ); + // operator delete[](void*, unsigned long, std::align_val_t) + #elif __SIZEOF_SIZE_T__ == 8 + DELETE_SIZED_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvmSt11align_val_t, __builtin_vec_delete_aligned ); + DELETE_SIZED_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdaPvmSt11align_val_t, __builtin_vec_delete_aligned ); + DELETE_SIZED_ALIGNED(SO_SYN_MALLOC, _ZdaPvmSt11align_val_t, __builtin_vec_delete_aligned ); +#endif + + #elif defined(VGO_solaris) - // operator delete[](void*, std::align_val_t), GNU mangling + // operator delete[](void*, std::align_val_t) DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_ALIGNED(SO_SYN_MALLOC, _ZdaPvSt11align_val_t, __builtin_vec_delete_aligned ); @@ -1319,7 +1450,7 @@ extern int * __error(void) __attribute__((weak)); #if __SIZEOF_SIZE_T__ == 4 DELETE_SIZED_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvjSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_SIZED_ALIGNED(SO_SYN_MALLOC, _ZdaPvjSt11align_val_t, __builtin_vec_delete_aligned ); - // operator delete[](void*, unsigned long), GNU mangling + // operator delete[](void*, unsigned long) #elif __SIZEOF_SIZE_T__ == 8 DELETE_SIZED_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvmSt11align_val_t, __builtin_vec_delete_aligned ); DELETE_SIZED_ALIGNED(SO_SYN_MALLOC, _ZdaPvmSt11align_val_t, __builtin_vec_delete_aligned ); @@ -1330,25 +1461,26 @@ extern int * __error(void) __attribute__((weak)); /*---------------------- delete [] nothrow ----------------------*/ #if defined(VGO_linux) - // operator delete[](void*, std::nothrow_t const&), GNU mangling + // operator delete[](void*, std::nothrow_t const&) FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPvRKSt9nothrow_t, __builtin_vec_delete ); FREE(VG_Z_LIBCXX_SONAME, _ZdaPvRKSt9nothrow_t, __builtin_vec_delete ); FREE(VG_Z_LIBC_SONAME, _ZdaPvRKSt9nothrow_t, __builtin_vec_delete ); FREE(SO_SYN_MALLOC, _ZdaPvRKSt9nothrow_t, __builtin_vec_delete ); #elif defined(VGO_freebsd) - // operator delete[](void*, std::nothrow_t const&), GNU mangling + // operator delete[](void*, std::nothrow_t const&) FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPvRKSt9nothrow_t, __builtin_vec_delete ); FREE(VG_Z_LIBCXX_SONAME, _ZdaPvRKSt9nothrow_t, __builtin_vec_delete ); FREE(SO_SYN_MALLOC, _ZdaPvRKSt9nothrow_t, __builtin_vec_delete ); #elif defined(VGO_darwin) - // operator delete[](void*, std::nothrow_t const&), GNU mangling - //FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPvRKSt9nothrow_t, __builtin_vec_delete ); - //FREE(VG_Z_LIBC_SONAME, _ZdaPvRKSt9nothrow_t, __builtin_vec_delete ); + // operator delete[](void*, std::nothrow_t const&) + FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPvRKSt9nothrow_t, __builtin_vec_delete ); + FREE(VG_Z_LIBCXX_SONAME, _ZdaPvRKSt9nothrow_t, __builtin_vec_delete ); + FREE(VG_Z_LIBC_SONAME, _ZdaPvRKSt9nothrow_t, __builtin_vec_delete ); #elif defined(VGO_solaris) - // operator delete[](void*, std::nothrow_t const&), GNU mangling + // operator delete[](void*, std::nothrow_t const&) FREE(VG_Z_LIBSTDCXX_SONAME, _ZdaPvRKSt9nothrow_t, __builtin_vec_delete ); FREE(SO_SYN_MALLOC, _ZdaPvRKSt9nothrow_t, __builtin_vec_delete ); @@ -1357,7 +1489,7 @@ extern int * __error(void) __attribute__((weak)); /*---------------------- C+17 delete aligned [] nothrow ----------------------*/ #if defined(VGO_linux) - // operator delete[](void*, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator delete[](void*, std::align_val_t, std::nothrow_t const&) DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvSt11align_val_tRKSt9nothrow_t, __builtin_vec_delete_aligned ); DELETE_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdaPvSt11align_val_tRKSt9nothrow_t, __builtin_vec_delete_aligned ); DELETE_ALIGNED(VG_Z_LIBC_SONAME, _ZdaPvSt11align_val_tRKSt9nothrow_t, __builtin_vec_delete_aligned ); @@ -1366,15 +1498,19 @@ extern int * __error(void) __attribute__((weak)); // no sized version of this operator #elif defined(VGO_freebsd) - // operator delete[](void*, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator delete[](void*, std::align_val_t, std::nothrow_t const&) DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvSt11align_val_tRKSt9nothrow_t, __builtin_vec_delete_aligned ); DELETE_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdaPvSt11align_val_tRKSt9nothrow_t, __builtin_vec_delete_aligned ); DELETE_ALIGNED(SO_SYN_MALLOC, _ZdaPvSt11align_val_tRKSt9nothrow_t, __builtin_vec_delete_aligned ); #elif defined(VGO_darwin) + DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvSt11align_val_tRKSt9nothrow_t, __builtin_vec_delete_aligned ); + DELETE_ALIGNED(VG_Z_LIBCXX_SONAME, _ZdaPvSt11align_val_tRKSt9nothrow_t, __builtin_vec_delete_aligned ); + DELETE_ALIGNED(SO_SYN_MALLOC, _ZdaPvSt11align_val_tRKSt9nothrow_t, __builtin_vec_delete_aligned ); + #elif defined(VGO_solaris) - // operator delete[](void*, std::align_val_t, std::nothrow_t const&), GNU mangling + // operator delete[](void*, std::align_val_t, std::nothrow_t const&) DELETE_ALIGNED(VG_Z_LIBSTDCXX_SONAME, _ZdaPvSt11align_val_tRKSt9nothrow_t, __builtin_vec_delete_aligned ); DELETE_ALIGNED(SO_SYN_MALLOC, _ZdaPvSt11align_val_tRKSt9nothrow_t, __builtin_vec_delete_aligned ); |
|
From: Paul F. <pa...@so...> - 2023-04-02 09:07:21
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=421693f4327e783fe12bda8453752a38a19ec886 commit 421693f4327e783fe12bda8453752a38a19ec886 Author: Paul Floyd <pj...@wa...> Date: Sun Apr 2 11:06:18 2023 +0200 Darwin: add support for setting errno from alloc wrappers Diff: --- coregrind/m_replacemalloc/vg_replace_malloc.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/coregrind/m_replacemalloc/vg_replace_malloc.c b/coregrind/m_replacemalloc/vg_replace_malloc.c index 5977fa317b..64d9b67c1e 100644 --- a/coregrind/m_replacemalloc/vg_replace_malloc.c +++ b/coregrind/m_replacemalloc/vg_replace_malloc.c @@ -234,6 +234,13 @@ extern int *___errno (void) __attribute__((weak)); (*___errno ()) = VKI_ENOMEM; #define SET_ERRNO_EINVAL if (___errno) \ (*___errno ()) = VKI_EINVAL; +#elif defined(VGO_darwin) +extern int * __error(void) __attribute__((weak)); +#define SET_ERRNO_ENOMEM if (__error) \ + (*__error ()) = VKI_ENOMEM; +#define SET_ERRNO_EINVAL if (__error) \ + (*__error ()) = VKI_EINVAL; + #else #define SET_ERRNO_ENOMEM {} #define SET_ERRNO_EINVAL {} |
|
From: Paul F. <pa...@so...> - 2023-04-02 08:15:24
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=708d0eb6b489a23ee0cf103a699160af8fd352d5 commit 708d0eb6b489a23ee0cf103a699160af8fd352d5 Author: Paul Floyd <pj...@wa...> Date: Sun Apr 2 10:12:17 2023 +0200 Regtest: fixes for callgrind tests referring to cachegrind reference files cachegrind/tests/cgout-test was renamed to ann1.cgout but the two tests in callgrind that use it weren't updated. Diff: --- callgrind/tests/ann1.post.exp | 2 +- callgrind/tests/ann1.vgtest | 2 +- callgrind/tests/ann2.post.exp | 2 +- callgrind/tests/ann2.vgtest | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/callgrind/tests/ann1.post.exp b/callgrind/tests/ann1.post.exp index 201b967d1d..1c68fc95c2 100644 --- a/callgrind/tests/ann1.post.exp +++ b/callgrind/tests/ann1.post.exp @@ -1,5 +1,5 @@ -------------------------------------------------------------------------------- -Profile data file '../../cachegrind/tests/cgout-test' +Profile data file '../../cachegrind/tests/ann1.cgout' -------------------------------------------------------------------------------- I1 cache: 32768 B, 64 B, 8-way associative D1 cache: 32768 B, 64 B, 8-way associative diff --git a/callgrind/tests/ann1.vgtest b/callgrind/tests/ann1.vgtest index 3c53e1f55e..6b355ef741 100644 --- a/callgrind/tests/ann1.vgtest +++ b/callgrind/tests/ann1.vgtest @@ -2,5 +2,5 @@ # the post-processing of the cgout-test file. prog: ../../tests/true vgopts: --callgrind-out-file=callgrind.out -post: touch ../../cachegrind/tests/cgout-test && perl ../../callgrind/callgrind_annotate --show=Ir,I1mr,ILmr --show-percs=no --include=../../cachegrind/tests ../../cachegrind/tests/cgout-test +post: touch ../../cachegrind/tests/ann1.cgout && perl ../../callgrind/callgrind_annotate --show=Ir,I1mr,ILmr --show-percs=no --include=../../cachegrind/tests ../../cachegrind/tests/ann1.cgout cleanup: rm callgrind.out diff --git a/callgrind/tests/ann2.post.exp b/callgrind/tests/ann2.post.exp index 47e5636038..3f6f17f6a3 100644 --- a/callgrind/tests/ann2.post.exp +++ b/callgrind/tests/ann2.post.exp @@ -1,5 +1,5 @@ -------------------------------------------------------------------------------- -Profile data file '../../cachegrind/tests/cgout-test' +Profile data file '../../cachegrind/tests/ann1.cgout' -------------------------------------------------------------------------------- I1 cache: 32768 B, 64 B, 8-way associative D1 cache: 32768 B, 64 B, 8-way associative diff --git a/callgrind/tests/ann2.vgtest b/callgrind/tests/ann2.vgtest index 9b7dffa0f0..9a4a565591 100644 --- a/callgrind/tests/ann2.vgtest +++ b/callgrind/tests/ann2.vgtest @@ -2,5 +2,5 @@ # the post-processing of the cgout-test file. prog: ../../tests/true vgopts: --callgrind-out-file=callgrind.out -post: touch ../../cachegrind/tests/cgout-test && perl ../../callgrind/callgrind_annotate --sort=Dr --show=Dw,Dr,Ir --auto=yes --include=../../cachegrind/tests ../../cachegrind/tests/cgout-test +post: touch ../../cachegrind/tests/ann1.cgout && perl ../../callgrind/callgrind_annotate --sort=Dr --show=Dw,Dr,Ir --auto=yes --include=../../cachegrind/tests ../../cachegrind/tests/ann1.cgout cleanup: rm callgrind.out |
|
From: Mark W. <ma...@kl...> - 2023-04-01 22:56:07
|
Hi Nick, On Sat, Mar 25, 2023 at 11:23:54AM +1100, Nicholas Nethercote wrote: > One way to do it is to divide the tests into "must pass on CI" and "the > rest". I suspect there are plenty of tests that work on all platforms, > which would give a lot of useful coverage from the start. Over time you can > hopefully move tests from the first category to the second. So for the original buildbot CI I set it up to only run the auxtests (that is build gsl and run the testsuite under valgrind). This used to work on all setups, but after a gcc (or glibc?) update some setups started failing as you can see at: https://builder.sourceware.org/buildbot/#/builders?tags=valgrind For the try builders I took out the now failing builders (debian-testing-x86_64, fedora-arm64, fedora-x86_64, ibm-power10, opensusetw-x86_64 and rawhide-x86_64). https://builder.sourceware.org/buildbot/#/builders?tags=valgrind-try Hopefully we can figure out why the auxtests fail now on some of these setups. > The other way to do it is to divide the tests into "run on CI" and "don't > run on CI", i.e. exceptions, which does require a mechanism for specifying > those exceptions. In practice I think this works out much the same as the > first approach, because a test that consistently fails on one platform > isn't much use. (In fact, it can have negative value if its presence masks > new failures in other tests.) So should we make a new check target that runs a subset of make regtests? Or maybe have a "ci mode" for regtests? So you would run CI_MODE=true make regtests and it would skip any vgtest that has prereq: test -z "$CI_MODE" And then add make regtests to the ci and try buildbots? Cheers, Mark |
|
From: Mark W. <ma...@kl...> - 2023-04-01 22:04:26
|
Hi, On Sat, Mar 25, 2023 at 11:25:12AM +1100, Nicholas Nethercote wrote: > On Fri, 24 Mar 2023 at 22:25, Mark Wielaard <ma...@kl...> wrote: > > We aren't (yet?) using all of them (and some of them would mean moving > > over bugzilla and the mailinglist, which might be controversial). But > > I'll at least add the buildbot CI testers to the website (and we should > > at least make use of the try-branches) this weekend. > > Great! I'd be happy to try this out. Though I guess I'd need to do a > no-change try run before testing a real change, to give a baseline of > expected test failures, right? I setup the user try branches on sourceware (just for the setups that have passing aux-tests) debian-arm64, debian-armhf, debian-i386, debian-ppc64, fedora-ppc64le, fedora-s390x, ibm-power9, opensuseleap-x86_64. And added instructions on how to use them into README_DEVELOPERS: Every developer with commit access can use try branches. Code committed to a try branch will be build by the buildbot at builder.sourceware.org https://builder.sourceware.org/buildbot/#/builders?tags=valgrind-try If you want to try a commit you can push to a special named try branch (users/<your-user-name>/try-<topic>) as follows: git checkout -b frob ...hack, hack, hack... OK, looks good to submit git commit -a -m "Awesome hack" git push origin frob:users/username/try-frob When all builders have build your patch the buildbot will sent you (or actually the patch author) an email telling you if any builds failed and references to all the logs. You can also find the logs and the builds here: https://builder.sourceware.org/buildbot/#/builders?tags=valgrind-try Afterwards you can delete the branch again: git push origin :users/username/try-frob |
|
From: Mark W. <ma...@so...> - 2023-04-01 21:58:43
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=03e36bc36ec9fe9a6ea83e3ad0338480a5a97f6c commit 03e36bc36ec9fe9a6ea83e3ad0338480a5a97f6c Author: Mark Wielaard <ma...@kl...> Date: Sat Apr 1 23:58:14 2023 +0200 Commit access and try branches Diff: --- README_DEVELOPERS | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/README_DEVELOPERS b/README_DEVELOPERS index 5b0a1bc6ad..4ed21a561b 100644 --- a/README_DEVELOPERS +++ b/README_DEVELOPERS @@ -80,6 +80,33 @@ compare them on all the performance tests: perl perf/vg_perf --vg=../trunk1 --vg=../trunk2 perf/ +Commit access and try branches +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +To get commit access to the valgrind git repository on sourceware +you will have to ask an existing developer and fill in the following +form: https://sourceware.org/cgi-bin/pdw/ps_form.cgi + +Every developer with commit access can use try branches. Code committed +to a try branch will be build by the buildbot at builder.sourceware.org +https://builder.sourceware.org/buildbot/#/builders?tags=valgrind-try + +If you want to try a commit you can push to a special named try branch +(users/<your-user-name>/try-<topic>) as follows: + + git checkout -b frob + ...hack, hack, hack... OK, looks good to submit + git commit -a -m "Awesome hack" + git push origin frob:users/username/try-frob + +When all builders have build your patch the buildbot will sent you (or +actually the patch author) an email telling you if any builds failed and +references to all the logs. You can also find the logs and the builds here: +https://builder.sourceware.org/buildbot/#/builders?tags=valgrind-try + +Afterwards you can delete the branch again: + + git push origin :users/username/try-frob + Debugging Valgrind with GDB ~~~~~~~~~~~~~~~~~~~~~~~~~~~ To debug the valgrind launcher program (<prefix>/bin/valgrind) just |
|
From: Paul F. <pa...@so...> - 2023-04-01 20:29:48
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=3f4052623c6246ee0d59db00d607ec858cefa849 commit 3f4052623c6246ee0d59db00d607ec858cefa849 Author: Paul Floyd <pj...@wa...> Date: Sat Apr 1 22:28:36 2023 +0200 Darwin: try to improve posix_memalign / zone_memalign wrapper It still doesn't set errno though. Diff: --- coregrind/m_replacemalloc/vg_replace_malloc.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/coregrind/m_replacemalloc/vg_replace_malloc.c b/coregrind/m_replacemalloc/vg_replace_malloc.c index db2fc5f309..5977fa317b 100644 --- a/coregrind/m_replacemalloc/vg_replace_malloc.c +++ b/coregrind/m_replacemalloc/vg_replace_malloc.c @@ -1575,7 +1575,8 @@ extern int *___errno (void) __attribute__((weak)); * */ - /* @todo PJF exactly what is the behaviour if this? */ + /* Probably in the wrong place, this is the function + called by posix_memalign, at least on macOS 10.13 */ #define ZONEMEMALIGN(soname, fnname) \ \ void* VG_REPLACE_FUNCTION_EZU(10100,soname,fnname) \ @@ -1591,6 +1592,12 @@ extern int *___errno (void) __attribute__((weak)); MALLOC_TRACE("zone_memalign(%p, al %llu, size %llu)", \ zone, (ULong)alignment, (ULong)n ); \ \ + if (alignment == 0 \ + || alignment % sizeof (void *) != 0 \ + || (alignment & (alignment - 1)) != 0) { \ + SET_ERRNO_EINVAL; \ + return NULL; \ + } \ /* Round up to minimum alignment if necessary. */ \ if (alignment < VG_MIN_MALLOC_SZB) \ alignment = VG_MIN_MALLOC_SZB; \ |
|
From: Paul F. <pa...@so...> - 2023-04-01 19:13:43
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=e105ce0d8f69f3784168562823ec9111e92aea95 commit e105ce0d8f69f3784168562823ec9111e92aea95 Author: Paul Floyd <pj...@wa...> Date: Sat Apr 1 21:11:58 2023 +0200 Darwin regtest: another test using aligned_alloc I added this test because I wanted to check the behaviour of aligned_alloc on current macOS, but Valgrind doesn't support it yet. Diff: --- memcheck/tests/darwin/aligned_alloc.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/memcheck/tests/darwin/aligned_alloc.c b/memcheck/tests/darwin/aligned_alloc.c index 1c2fdb78cb..bcbae51fe4 100644 --- a/memcheck/tests/darwin/aligned_alloc.c +++ b/memcheck/tests/darwin/aligned_alloc.c @@ -1,8 +1,11 @@ #include <stdlib.h> #include <assert.h> +#include "../../../config.h" int main(void) { + // @todo PJF this is a placeholder for 10.15 and later support +#if !defined(VGO_darwin) char* p = NULL; // zero size @@ -14,6 +17,7 @@ int main(void) // align not power of 2 p = aligned_alloc(40, 160); assert(p == NULL); +#endif // @todo PJF this works standalone // but for some reason it doesn't fail in arena_memalign |
|
From: Paul F. <pa...@so...> - 2023-04-01 18:57:10
|
https://sourceware.org/git/gitweb.cgi?p=valgrind.git;h=abf513febd1f98aad37201fe91468bf94ebae7f8 commit abf513febd1f98aad37201fe91468bf94ebae7f8 Author: Paul Floyd <pj...@wa...> Date: Sat Apr 1 20:55:22 2023 +0200 Darwin regtest: fix building on older OS versions aligned_alloc was added to macOS 10.15 and 10.13 is the latest that we support. Diff: --- memcheck/tests/memalign_args.c | 2 ++ memcheck/tests/memalign_args.stderr.exp | 4 ++-- memcheck/tests/memalign_args.stderr.exp-glibc | 4 ++-- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/memcheck/tests/memalign_args.c b/memcheck/tests/memalign_args.c index 0946a6ce98..9c774d61ee 100644 --- a/memcheck/tests/memalign_args.c +++ b/memcheck/tests/memalign_args.c @@ -23,8 +23,10 @@ int main(void) res = posix_memalign((void **)&mem,align,size); free(mem); +#if !defined(VGO_darwin) p = aligned_alloc(align, size); free(p); +#endif p = valloc(size); free(p); diff --git a/memcheck/tests/memalign_args.stderr.exp b/memcheck/tests/memalign_args.stderr.exp index 4d426d3696..5482798875 100644 --- a/memcheck/tests/memalign_args.stderr.exp +++ b/memcheck/tests/memalign_args.stderr.exp @@ -8,8 +8,8 @@ Conditional jump or move depends on uninitialised value(s) Conditional jump or move depends on uninitialised value(s) at 0x........: aligned_alloc (vg_replace_malloc.c:...) - by 0x........: main (memalign_args.c:26) + by 0x........: main (memalign_args.c:27) Conditional jump or move depends on uninitialised value(s) at 0x........: valloc (vg_replace_malloc.c:...) - by 0x........: main (memalign_args.c:29) + by 0x........: main (memalign_args.c:31) diff --git a/memcheck/tests/memalign_args.stderr.exp-glibc b/memcheck/tests/memalign_args.stderr.exp-glibc index 8106196391..30cc1dc923 100644 --- a/memcheck/tests/memalign_args.stderr.exp-glibc +++ b/memcheck/tests/memalign_args.stderr.exp-glibc @@ -8,8 +8,8 @@ Conditional jump or move depends on uninitialised value(s) Conditional jump or move depends on uninitialised value(s) at 0x........: memalign (vg_replace_malloc.c:...) - by 0x........: main (memalign_args.c:26) + by 0x........: main (memalign_args.c:27) Conditional jump or move depends on uninitialised value(s) at 0x........: valloc (vg_replace_malloc.c:...) - by 0x........: main (memalign_args.c:29) + by 0x........: main (memalign_args.c:31) |