[llvm] [MCJIT] Suppress UBSAN report (PR #119484)
Vitaly Buka via llvm-commits
llvm-commits at lists.llvm.org
Tue Dec 10 20:33:08 PST 2024
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/119484
>From ace3c10bae976511f8d889253766f956d9abfe4b Mon Sep 17 00:00:00 2001
From: Vitaly Buka <vitalybuka at google.com>
Date: Tue, 10 Dec 2024 18:06:04 -0800
Subject: [PATCH 1/2] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20in?=
=?UTF-8?q?itial=20version?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Created using spr 1.3.4
---
llvm/lib/ExecutionEngine/MCJIT/MCJIT.cpp | 2 ++
1 file changed, 2 insertions(+)
diff --git a/llvm/lib/ExecutionEngine/MCJIT/MCJIT.cpp b/llvm/lib/ExecutionEngine/MCJIT/MCJIT.cpp
index 5f3067b2a97eac..edf0ef330ce932 100644
--- a/llvm/lib/ExecutionEngine/MCJIT/MCJIT.cpp
+++ b/llvm/lib/ExecutionEngine/MCJIT/MCJIT.cpp
@@ -507,6 +507,8 @@ GlobalVariable *MCJIT::FindGlobalVariableNamed(StringRef Name, bool AllowInterna
return GV;
}
+// FIXME: A lot of unaligned loads `(intptr_t)FPtr`.
+__attribute__((no_sanitize("alignment")))
GenericValue MCJIT::runFunction(Function *F, ArrayRef<GenericValue> ArgValues) {
assert(F && "Function *F was null at entry to run()");
>From 514ca7fcf22b25034ce1a24691108175d20d8b0e Mon Sep 17 00:00:00 2001
From: Vitaly Buka <vitalybuka at google.com>
Date: Tue, 10 Dec 2024 18:19:02 -0800
Subject: [PATCH 2/2] rebase
Created using spr 1.3.4
---
llvm/lib/ExecutionEngine/MCJIT/MCJIT.cpp | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/llvm/lib/ExecutionEngine/MCJIT/MCJIT.cpp b/llvm/lib/ExecutionEngine/MCJIT/MCJIT.cpp
index edf0ef330ce932..21e0e742097771 100644
--- a/llvm/lib/ExecutionEngine/MCJIT/MCJIT.cpp
+++ b/llvm/lib/ExecutionEngine/MCJIT/MCJIT.cpp
@@ -508,8 +508,8 @@ GlobalVariable *MCJIT::FindGlobalVariableNamed(StringRef Name, bool AllowInterna
}
// FIXME: A lot of unaligned loads `(intptr_t)FPtr`.
-__attribute__((no_sanitize("alignment")))
-GenericValue MCJIT::runFunction(Function *F, ArrayRef<GenericValue> ArgValues) {
+__attribute__((no_sanitize("alignment"))) GenericValue
+MCJIT::runFunction(Function *F, ArrayRef<GenericValue> ArgValues) {
assert(F && "Function *F was null at entry to run()");
void *FPtr = getPointerToFunction(F);
More information about the llvm-commits
mailing list