We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 594bfad commit ff92237Copy full SHA for ff92237
mlir/lib/Target/LLVM/NVVM/Target.cpp
@@ -26,6 +26,7 @@
26
#include "mlir/Target/LLVMIR/Dialect/NVVM/NVVMToLLVMIRTranslation.h"
27
#include "mlir/Target/LLVMIR/Export.h"
28
29
+#include "llvm/ADT/ScopeExit.h"
30
#include "llvm/Config/llvm-config.h"
31
#include "llvm/Support/FileSystem.h"
32
#include "llvm/Support/FileUtilities.h"
@@ -673,6 +674,7 @@ NVPTXSerializer::moduleToObject(llvm::Module &llvmModule) {
673
674
llvm::Timer moduleToObjectTimer(
675
"moduleToObjectTimer",
676
"Timer for perf llvm-ir -> isa and isa -> binary.");
677
+ auto clear = llvm::make_scope_exit([&]() { moduleToObjectTimer.clear(); });
678
// Return LLVM IR if the compilation target is `offload`.
679
#define DEBUG_TYPE "serialize-to-llvm"
680
LLVM_DEBUG({
0 commit comments