Skip to content

Commit

Permalink
fix typo
Browse files Browse the repository at this point in the history
  • Loading branch information
adityavardhanpadala committed Apr 2, 2024
1 parent b13f54c commit d14e6e9
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions svf-llvm/lib/LLVMUtil.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -511,16 +511,16 @@ void LLVMUtil::removeFunAnnotations(Set<Function*>& removedFuncList)
GlobalVariable *GV = new GlobalVariable(newCA->getType(), glob->isConstant(), glob->getLinkage(), newCA, "llvm.global.annotations");
GV->setSection(glob->getSection());

#if (LLVM_VERSION < 17)
#if (LLVM_VERSION_MAJOR < 17)
module->getGlobalList().push_back(GV);
#elif (LLVM_VERSION >= 17)
#elif (LLVM_VERSION_MAJOR >= 17)
module->insertGlobalVariable(GV);
#else
assert(false && "llvm version not supported!");
#endif

glob->replaceAllUsesWith(GV);
glob->eraseFromParent();
glob->replaceAllUsesWith(GV);
glob->eraseFromParent();
}

/// Get all called funcions in a parent function
Expand Down

0 comments on commit d14e6e9

Please sign in to comment.