diff options
| author | Vedant Kumar <vsk@apple.com> | 2016-03-11 18:57:48 +0000 |
|---|---|---|
| committer | Vedant Kumar <vsk@apple.com> | 2016-03-11 18:57:48 +0000 |
| commit | e5a9a275d36b20f68bc6e015f83914126004ccf8 (patch) | |
| tree | a68dae62497e003ac713784ad7201e3009b62173 /llvm/lib/Transforms | |
| parent | 6b074f5c9f873f1880fbbd00109253e530587073 (diff) | |
| download | bcm5719-llvm-e5a9a275d36b20f68bc6e015f83914126004ccf8.tar.gz bcm5719-llvm-e5a9a275d36b20f68bc6e015f83914126004ccf8.zip | |
[PGO] Skip value profile instrumentation of inline asm
Value profile instrumentation treats inline asm calls like they are
indirect calls. This causes problems when the 'Callee' is passed to a
ptrtoint cast -- the verifier rightly claims that this is bogus and
crashes opt.
llvm-svn: 263278
Diffstat (limited to 'llvm/lib/Transforms')
| -rw-r--r-- | llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp b/llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp index 4884a499019..787f098869f 100644 --- a/llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp +++ b/llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp @@ -334,7 +334,7 @@ struct PGOIndirectCallSiteVisitor void visitCallInst(CallInst &I) { CallSite CS(&I); - if (CS.getCalledFunction() || !CS.getCalledValue()) + if (CS.getCalledFunction() || !CS.getCalledValue() || I.isInlineAsm()) return; IndirectCallInsts.push_back(&I); } |

