summaryrefslogtreecommitdiffstats
path: root/benchmarks/stdio_benchmark.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Refactor the benchmark code.Christopher Ferris2015-02-191-23/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | Changes: - Modify the benchmarks to derive from a single Benchmark object. - Rewrite the main iteration code. This includes changing the iteration code to use the actual total time calculated by the benchmark as a basis for determining whether there are enough iterations instead of using the time it takes to run the benchmark. - Allow benchmarks to take no argument, int, or double. - Fix the PrettyInt printer for negative integers. - Modify the max column width name to include the whole name including the arg part. - Reformat property_benchmark.cpp in line with the rest of the code. - Modify a few of the math benchmarks to take an argument instead of separate benchmarks for the same function with different args. - Create a vector of regex_t structs to represent the args all at once instead of when running each benchmark. This change is in preparation for adding new math based benchmarks. Tested by running on a nexus flo running at max using the new code and the old code and comparing. All of the numbers are similar, but some of the iterations are different due to the slightly different algorithm used. Change-Id: I57ad1f3ff083282b9ffeb72e687cab369ce3523a
* Implement __fsetlocking.Elliott Hughes2015-01-211-2/+14
| | | | | | | | | | | | The old __isthreaded hack was never very useful on Android because all user code runs in a VM where there are lots of threads running. But __fsetlocking lets a caller say "I'll worry about the locking for this FILE*", which is useful for the normal case where you don't share a FILE* between threads so you don't need any locking. Bug: 17154740 Bug: 18593728 Change-Id: I2a8dddc29d3edff39a3d7d793387f2253608a68d
* Add a benchmark for using stdio to read a file in /proc.Elliott Hughes2015-01-161-0/+10
| | | | Change-Id: I12517aae19e36b7c022a11e8807aece61bb0cb9c
* Benchmark fread/fwrite both buffered and unbuffered.Elliott Hughes2014-12-011-15/+21
| | | | | Bug: 18556607 Change-Id: I53905aedcea75fe550d9c423fb701c2c9bf8e831
* Add various benchmarks.Elliott Hughes2014-03-111-0/+61
These are based on ones from system/extras/tests/bionic/. Change-Id: I7b1ae15a2ca5d1031a6a511d97b88125c1770047