[PATCH] D87312: [IRSim] Letting call instructions be legal for similarity identification.
Jon Roelofs via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 15 10:13:16 PDT 2020
jroelofs accepted this revision.
jroelofs added a comment.
This revision is now accepted and ready to land.
LGTM
================
Comment at: llvm/lib/Analysis/IRSimilarityIdentifier.cpp:36
+std::string getCalledFunctionName(CallInst &CI) {
+ return CI.getCalledFunction()->getName().str();
----------------
static StringRef
================
Comment at: llvm/lib/Analysis/IRSimilarityIdentifier.cpp:59
+ "Called Function is nullptr?");
+ assert(CIB->getCalledFunction() != nullptr &&
+ "Called Function is nullptr?");
----------------
could sink the assert into the helper, which dedupes this a bit more.
================
Comment at: llvm/unittests/Analysis/IRSimilarityIdentifierTest.cpp:757
+// Checks that indirect call instructions are mapped to be illegal since we
+// cannot guarantee the same of the function.
+TEST(IRInstructionMapper, CallsIllegalIndirect) {
----------------
same what?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D87312/new/
https://reviews.llvm.org/D87312
More information about the llvm-commits
mailing list