This is the mail archive of the mailing list for the glibc project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Moving dryrun as separate project.


As we talked about whole-system profing on cauldron I mentioned that I
wrote dryrun framework. As Siddhesh asked if that could be independent
project I uploaded it at github

I wrote it mainly as tool for data collection so I could quickly compute
statistics like how often is function called with second parameter
aligned to 4 bytes when first parameter is 0.

It could be used for benchmarking but isn't perfect as there are effect
that could be measured only on living system like how function affects
performance of rest of binary. Thats nontrivial as function could change
whats cached in unpredictable way.

It is general tool as it allows to record arbitrary function if you
write specification for that. Only limitation is that record needs to be
of fixed size.

As I already wrote description of much string functions using dryrun on
those is relatively easy.

First there is question where we do save data. These traces could be
relatively large, I could store some on my pages but I would prefer more
permanent solution.

A tldr way to use dryrun to benchmark glibc function is
1. download it
2. make
3a. Download data.
3b. Create data. Until we decide where to store trace you could just
record workloads that interest you, for example compilation. Do do that


It starts bash shell and dryrun will save trace of any command executed

4. After you collect data run benchmark to test patch compile glibc to
directory old_test without patch and new_test with applied patch. Then 
run benchmark for example with following.

for I in `seq 1 10`; do
  echo "old implementation"
  $OLD_TEST/testrun_sh $DRYRUN_PATH/bin/bench_$FUNCTION -u 
  echo "new implementation"
  $NEW_TEST/testrun_sh $DRYRUN_PATH/bin/bench_$FUNCTION -u

To see what inputs are used you need to use command ./bin/show_function
and to see statistics ./bin/summary_function

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]