[llvm] 0923341 - Revert part of D112349 to allow ifunc resolvers be declarations.
Erich Keane via llvm-commits
llvm-commits at lists.llvm.org
Wed Nov 3 07:15:23 PDT 2021
Author: Erich Keane
Date: 2021-11-03T07:15:16-07:00
New Revision: 09233412edae388a7bfa349cf792dba5aced057f
URL: https://github.com/llvm/llvm-project/commit/09233412edae388a7bfa349cf792dba5aced057f
DIFF: https://github.com/llvm/llvm-project/commit/09233412edae388a7bfa349cf792dba5aced057f.diff
LOG: Revert part of D112349 to allow ifunc resolvers be declarations.
The patch in D112349 added a previously nonexistant restriction on ifunc
resolvers that they MUST be defintions. However, the function
multiversioning depends on being able to resolve these resolvers at
link-time, so this additional restriction was breaking.
Added:
Modified:
llvm/lib/IR/Verifier.cpp
Removed:
################################################################################
diff --git a/llvm/lib/IR/Verifier.cpp b/llvm/lib/IR/Verifier.cpp
index a72c8bb119e2..1e0f8b5b82c9 100644
--- a/llvm/lib/IR/Verifier.cpp
+++ b/llvm/lib/IR/Verifier.cpp
@@ -829,11 +829,9 @@ void Verifier::visitGlobalAlias(const GlobalAlias &GA) {
void Verifier::visitGlobalIFunc(const GlobalIFunc &GI) {
// Pierce through ConstantExprs and GlobalAliases and check that the resolver
- // is a Function definition
+ // has a Function
const Function *Resolver = GI.getResolverFunction();
Assert(Resolver, "IFunc must have a Function resolver", &GI);
- Assert(!Resolver->isDeclarationForLinker(),
- "IFunc resolver must be a definition", &GI);
// Check that the immediate resolver operand (prior to any bitcasts) has the
// correct type
More information about the llvm-commits
mailing list