Skip to content

Commit 156dc8c

Browse files
committed
[Arcilator] Timing scopes for JIT
1 parent 4d81b97 commit 156dc8c

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

tools/arcilator/arcilator.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -422,6 +422,7 @@ static LogicalResult processBuffer(
422422
#ifdef ARCILATOR_ENABLE_JIT
423423
// Handle JIT execution.
424424
if (outputFormat == OutputRunJIT) {
425+
auto tsJit = ts.nest("JIT");
425426
if (runUntilBefore != UntilEnd || runUntilAfter != UntilEnd) {
426427
llvm::errs() << "full pipeline must be run for JIT execution\n";
427428
return failure();
@@ -460,6 +461,7 @@ static LogicalResult processBuffer(
460461
engineOptions.transformer = transformer;
461462
engineOptions.sharedLibPaths = sharedLibraries;
462463

464+
auto tsCompile = tsJit.nest("Compile");
463465
auto executionEngine =
464466
mlir::ExecutionEngine::create(module.get(), engineOptions);
465467
if (!executionEngine) {
@@ -480,7 +482,9 @@ static LogicalResult processBuffer(
480482
});
481483
return failure();
482484
}
485+
tsCompile.stop();
483486

487+
auto tsExecute = tsJit.nest("Execute");
484488
void (*simulationFunc)(void **) = *expectedFunc;
485489
(*simulationFunc)(nullptr);
486490

0 commit comments

Comments
 (0)