syswrap preadv2 and pwritev2 also on ppc32-linux
[valgrind.git] / tests / filter_libc
blobbf035701c153ee27400804795775015059207378
1 #!/usr/bin/env perl
3 use strict;
4 use warnings;
6 while (<>)
8 s/ __getsockname / getsockname /;
9 s/ __sigaction / sigaction /;
10 s/ __GI___/ __/;
11 s/ __([a-z]*)_nocancel / $1 /;
13 # "lib[S|s]ystem*" occurs on Darwin, "libsocket" on older Solaris/illumos.
14 s/\(in \/.*(libc|libSystem|libsystem|libsocket).*\)$/(in \/...libc...)/;
15 s/\(within \/.*(libc|libSystem|libsystem|libsocket).*\)$/(within \/...libc...)/;
17 # Filter out dynamic loader
18 s/ \(in \/.*ld-.*so\)$//;
20 # Remove the filename -- on some platforms (eg. Linux) it will be in
21 # libc, on some (eg. Darwin) it will be in the main executable.
22 s/\(below main\) \(.+\)$/(below main)/;
24 # libc on x86 FreeBSD
25 s#_start1 \(src/lib/csu/i386/crt1_c.c.*#(below main)#;
26 s#__libc_start1 \(in /...libc...\)#(below main)#;
28 # filter out the exact libc-start.c:### line number. (ppc64*)
29 s/\(libc-start.c:[0-9]*\)$/(in \/...libc...)/;
31 # Merge the different C++ operator variations.
32 s/(at.*)__builtin_new/$1...operator new.../;
33 s/(at.*)operator new\(unsigned(| int| long)\)/$1...operator new.../;
35 s/(at.*)__builtin_vec_new/$1...operator new.../;
36 s/(at.*)operator new\[\]\(unsigned(| int| long)\)/$1...operator new[].../;
38 s/(at.*)__builtin_delete/$1...operator delete.../;
39 s/(at.*)operator delete\(void\*(, unsigned(| int| long))?\)/$1...operator delete.../;
41 s/(at.*)__builtin_vec_delete/$1...operator delete[].../;
42 s/(at.*)operator delete\[\]\(void\*\)/$1...operator delete[].../;
44 # Some glibc versions complain about unexpected futex syscall errors.
45 # With or without newline (see sourceware PR20271).
46 next if /^The futex facility returned an unexpected error code.$/;
47 s/The futex facility returned an unexpected error code.//;
49 print;
52 exit 0;