mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-21 23:17:16 +00:00
Clear the cached cost when removing a function in
the inliner; prevents nondeterministic behavior when the same address is reallocated. Don't build call graph nodes for debug intrinsic calls; they're useless, and there were typically a lot of them. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@67311 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -15,6 +15,7 @@
|
||||
#include "llvm/Analysis/CallGraph.h"
|
||||
#include "llvm/Module.h"
|
||||
#include "llvm/Instructions.h"
|
||||
#include "llvm/IntrinsicInst.h"
|
||||
#include "llvm/Support/CallSite.h"
|
||||
#include "llvm/Support/Compiler.h"
|
||||
#include "llvm/Support/Streams.h"
|
||||
@@ -143,7 +144,7 @@ private:
|
||||
for (BasicBlock::iterator II = BB->begin(), IE = BB->end();
|
||||
II != IE; ++II) {
|
||||
CallSite CS = CallSite::get(II);
|
||||
if (CS.getInstruction()) {
|
||||
if (CS.getInstruction() && !isa<DbgInfoIntrinsic>(II)) {
|
||||
const Function *Callee = CS.getCalledFunction();
|
||||
if (Callee)
|
||||
Node->addCalledFunction(CS, getOrInsertFunction(Callee));
|
||||
|
||||
Reference in New Issue
Block a user