diff options
Diffstat (limited to 'utils')
-rw-r--r-- | utils/benchmark/benchmark-parse.py | 7 | ||||
-rw-r--r-- | utils/benchmark/inputs/.gitattributes | 2 |
2 files changed, 7 insertions, 2 deletions
diff --git a/utils/benchmark/benchmark-parse.py b/utils/benchmark/benchmark-parse.py index dd98449..003acda 100644 --- a/utils/benchmark/benchmark-parse.py +++ b/utils/benchmark/benchmark-parse.py @@ -17,6 +17,13 @@ from pycparser import c_parser, c_ast def measure_parse(text, n, progress_cb): + """Measure the parsing of text with pycparser. + + text should represent a full file. n is the number of iterations to measure. + progress_cb will be called with the iteration number each time one is done. + + Returns a list of elapsed times, one per iteration. + """ times = [] for i in range(n): parser = c_parser.CParser() diff --git a/utils/benchmark/inputs/.gitattributes b/utils/benchmark/inputs/.gitattributes deleted file mode 100644 index 91c326c..0000000 --- a/utils/benchmark/inputs/.gitattributes +++ /dev/null @@ -1,2 +0,0 @@ -*.ppout linguist-vendored=true - |