feat(benchmarks): add source code information to benchmarks

This commit is contained in:
Umut
2021-10-08 17:27:36 +03:00
parent a7f00ec111
commit 2cfb32d2c1

View File

@@ -308,7 +308,11 @@ def main():
raise RuntimeError(f"Target `{target_name}` is already registered")
# Create an entry in the result for the current target
result["targets"][target_id] = {"name": target_name, "measurements": {}}
result["targets"][target_id] = {
"name": target_name,
"measurements": {},
"code": "\n".join(lines),
}
# Create a dictionary to hold `metric_id` to `metric_name`
metrics = {}