diff options
Diffstat (limited to 'contrib/llvm/lib/Target/PIC16/PIC16Passes')
4 files changed, 6 insertions, 5 deletions
diff --git a/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Cloner.cpp b/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Cloner.cpp index 27f1cf5..56f0211 100644 --- a/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Cloner.cpp +++ b/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Cloner.cpp @@ -256,7 +256,7 @@ PIC16Cloner::cloneFunction(Function *OrgF) { CloneAutos(OrgF); // Now create the clone. - ClonedF = CloneFunction(OrgF, VMap); + ClonedF = CloneFunction(OrgF, VMap, /*ModuleLevelChanges=*/false); // The new function should be for interrupt line. Therefore should have // the name suffixed with IL and section attribute marked with IL. diff --git a/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Cloner.h b/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Cloner.h index e8b5aa4..e7d67ce 100644 --- a/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Cloner.h +++ b/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Cloner.h @@ -35,7 +35,7 @@ namespace llvm { class PIC16Cloner : public ModulePass { public: static char ID; // Class identification - PIC16Cloner() : ModulePass(&ID) {} + PIC16Cloner() : ModulePass(ID) {} virtual void getAnalysisUsage(AnalysisUsage &AU) const { AU.addRequired<CallGraph>(); diff --git a/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Overlay.cpp b/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Overlay.cpp index 5ecb6aa..0f8928a 100644 --- a/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Overlay.cpp +++ b/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Overlay.cpp @@ -171,8 +171,9 @@ void PIC16Overlay::MarkIndirectlyCalledFunctions(Module &M) { for (Module::iterator MI = M.begin(), E = M.end(); MI != E; ++MI) { for (Value::use_iterator I = MI->use_begin(), E = MI->use_end(); I != E; ++I) { - if ((!isa<CallInst>(I) && !isa<InvokeInst>(I)) - || !CallSite(cast<Instruction>(I)).isCallee(I)) { + User *U = *I; + if ((!isa<CallInst>(U) && !isa<InvokeInst>(U)) + || !CallSite(cast<Instruction>(U)).isCallee(I)) { setColor(MI, ++IndirectCallColor); break; } diff --git a/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Overlay.h b/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Overlay.h index 5a2551f..2f611e6 100644 --- a/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Overlay.h +++ b/contrib/llvm/lib/Target/PIC16/PIC16Passes/PIC16Overlay.h @@ -39,7 +39,7 @@ namespace llvm { unsigned IndirectCallColor; public: static char ID; // Class identification - PIC16Overlay() : ModulePass(&ID) { + PIC16Overlay() : ModulePass(ID) { OverlayStr = "Overlay="; InterruptDepth = PIC16OVERLAY::StartInterruptColor; IndirectCallColor = PIC16OVERLAY::StartIndirectCallColor; |