[llvm] [BOLT] Turn non-empty CFI StateStack assert into a warning (PR #102216)
Amir Ayupov via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 6 13:30:07 PDT 2024
https://github.com/aaupov created https://github.com/llvm/llvm-project/pull/102216
None
>From d201c36caf3ed3cbfcaa00be3fb2d23b8fb59c04 Mon Sep 17 00:00:00 2001
From: Amir Ayupov <aaupov at fb.com>
Date: Tue, 6 Aug 2024 13:29:55 -0700
Subject: [PATCH] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20initia?=
=?UTF-8?q?l=20version?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Created using spr 1.3.4
---
bolt/lib/Core/BinaryFunction.cpp | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/bolt/lib/Core/BinaryFunction.cpp b/bolt/lib/Core/BinaryFunction.cpp
index ea09371b57e8a..e5c6d551e42a7 100644
--- a/bolt/lib/Core/BinaryFunction.cpp
+++ b/bolt/lib/Core/BinaryFunction.cpp
@@ -2502,7 +2502,10 @@ void BinaryFunction::annotateCFIState() {
}
}
- assert(StateStack.empty() && "corrupt CFI stack");
+ if (!StateStack.empty()) {
+ BC.errs() << "BOLT-WARNING: non-empty CFI stack at the end of " << *this
+ << '\n';
+ }
}
namespace {
More information about the llvm-commits
mailing list