2006-07-26 22:57:51 +02:00
|
|
|
#!/bin/sh
|
|
|
|
platform=$1
|
|
|
|
LIBUNWIND=../src/.libs/libunwind.so
|
|
|
|
LIBUNWIND_PLAT=../src/.libs/libunwind-$platform.so
|
|
|
|
warmup=$(./forker 2000 /bin/true | cut -f1 -d' ')
|
|
|
|
|
|
|
|
nsec1=$(./forker 2000 /bin/true | cut -f1 -d' ')
|
2012-08-02 10:57:09 +02:00
|
|
|
printf "\"/bin/true\"\t\t\t\t\t\t: $nsec1 nsec/execution\n"
|
2006-07-26 22:57:51 +02:00
|
|
|
|
|
|
|
nsec2=$(LD_PRELOAD=$LIBUNWIND ./forker 2000 /bin/true | cut -f1 -d' ')
|
2012-08-02 10:57:09 +02:00
|
|
|
printf "\"LD_PRELOAD=$LIBUNWIND /bin/true\"\t: $nsec2 nsec/execution\n"
|
2006-07-26 22:57:51 +02:00
|
|
|
|
|
|
|
nsec3=$(LD_PRELOAD=$LIBUNWIND_PLAT ./forker 2000 /bin/true | cut -f1 -d' ')
|
2012-08-02 10:57:09 +02:00
|
|
|
printf "\"LD_PRELOAD=$LIBUNWIND_PLAT /bin/true\"\t: $nsec3 nsec/execution\n"
|
2006-07-26 22:57:51 +02:00
|
|
|
|
|
|
|
echo
|
|
|
|
|
2012-08-02 10:57:09 +02:00
|
|
|
printf "Overhead of preloading $LIBUNWIND\t: $(($nsec2 - $nsec1)) nsec\n"
|
|
|
|
printf "Overhead of preloading $LIBUNWIND_PLAT\t: $(($nsec3 - $nsec1)) nsec\n"
|