(self, args)
| 568 | self.do_benchmark('primes' if check else 'primes-nocheck', src, 'lastprime:' if check else '', shared_args=['-DCHECK'] if check else []) |
| 569 | |
| 570 | def do_toolchain_benchmark(self, args): |
| 571 | # TODO: Perhaps this can be merged with the regular `do_benchmark` somehow. |
| 572 | benchmarkers = [ |
| 573 | named_benchmarkers['clang-build'], |
| 574 | named_benchmarkers['emcc-build'], |
| 575 | ] |
| 576 | baseline = None |
| 577 | print() |
| 578 | for b in benchmarkers: |
| 579 | b.bench(args) |
| 580 | b.display(baseline) |
| 581 | if not baseline: |
| 582 | # Use the first benchmarker as the baseline. Other benchmarkers can then |
| 583 | # report relative performance compared to this. |
| 584 | baseline = b |
| 585 | |
| 586 | def test_compile_noop(self): |
| 587 | self.do_toolchain_benchmark(['--version']) |
no test coverage detected