diff --git a/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp b/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp index 7e78bf1b7ad..073e2964d20 100644 --- a/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp +++ b/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp @@ -712,7 +712,7 @@ void SelectionDAGISel::SelectAllBasicBlocks(const Function &Fn) { // Defer instructions with no side effects; they'll be emitted // on-demand later. if (BI->isSafeToSpeculativelyExecute() && - !FuncInfo->ValueMap.count(BI)) + !FuncInfo->isExportedInst(BI)) continue; // Try to select the instruction with FastISel.