forked from OSchip/llvm-project
fix a potentially serious bug in AliasSet::removeCallSite
where we shrunk the list without updating the end iterator. By inspection, from PR9639. llvm-svn: 129190
This commit is contained in:
parent
9cb59fa834
commit
2bd7015de5
|
@ -376,7 +376,7 @@ ifeq ($(HOST_OS),MingW)
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
CXX.Flags += -Woverloaded-virtual
|
CXX.Flags += -Woverloaded-virtual -Wuninitialized-experimental
|
||||||
CPP.BaseFlags += $(CPP.Defines)
|
CPP.BaseFlags += $(CPP.Defines)
|
||||||
AR.Flags := cru
|
AR.Flags := cru
|
||||||
|
|
||||||
|
@ -1528,31 +1528,31 @@ BC_DEPEND_MOVEFILE = then $(MV) -f "$(ObjDir)/$*.bc.d.tmp" "$(ObjDir)/$*.bc.d";
|
||||||
$(ObjDir)/%.ll: %.cpp $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCXX)
|
$(ObjDir)/%.ll: %.cpp $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCXX)
|
||||||
$(Echo) "Compiling $*.cpp for $(BuildMode) build (bytecode)"
|
$(Echo) "Compiling $*.cpp for $(BuildMode) build (bytecode)"
|
||||||
$(Verb) if $(BCCompile.CXX) $(BC_DEPEND_OPTIONS) \
|
$(Verb) if $(BCCompile.CXX) $(BC_DEPEND_OPTIONS) \
|
||||||
$< -o $(ObjDir)/$*.ll -S -$(LLVMCC_EMITIR_FLAG) ; \
|
$< -o $(ObjDir)/$*.ll -S $(LLVMCC_EMITIR_FLAG) ; \
|
||||||
$(BC_DEPEND_MOVEFILE)
|
$(BC_DEPEND_MOVEFILE)
|
||||||
|
|
||||||
$(ObjDir)/%.ll: %.mm $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCXX)
|
$(ObjDir)/%.ll: %.mm $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCXX)
|
||||||
$(Echo) "Compiling $*.mm for $(BuildMode) build (bytecode)"
|
$(Echo) "Compiling $*.mm for $(BuildMode) build (bytecode)"
|
||||||
$(Verb) if $(BCCompile.CXX) $(BC_DEPEND_OPTIONS) \
|
$(Verb) if $(BCCompile.CXX) $(BC_DEPEND_OPTIONS) \
|
||||||
$< -o $(ObjDir)/$*.ll -S -$(LLVMCC_EMITIR_FLAG) ; \
|
$< -o $(ObjDir)/$*.ll -S $(LLVMCC_EMITIR_FLAG) ; \
|
||||||
$(BC_DEPEND_MOVEFILE)
|
$(BC_DEPEND_MOVEFILE)
|
||||||
|
|
||||||
$(ObjDir)/%.ll: %.cc $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCXX)
|
$(ObjDir)/%.ll: %.cc $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCXX)
|
||||||
$(Echo) "Compiling $*.cc for $(BuildMode) build (bytecode)"
|
$(Echo) "Compiling $*.cc for $(BuildMode) build (bytecode)"
|
||||||
$(Verb) if $(BCCompile.CXX) $(BC_DEPEND_OPTIONS) \
|
$(Verb) if $(BCCompile.CXX) $(BC_DEPEND_OPTIONS) \
|
||||||
$< -o $(ObjDir)/$*.ll -S -$(LLVMCC_EMITIR_FLAG) ; \
|
$< -o $(ObjDir)/$*.ll -S $(LLVMCC_EMITIR_FLAG) ; \
|
||||||
$(BC_DEPEND_MOVEFILE)
|
$(BC_DEPEND_MOVEFILE)
|
||||||
|
|
||||||
$(ObjDir)/%.ll: %.c $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCC)
|
$(ObjDir)/%.ll: %.c $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCC)
|
||||||
$(Echo) "Compiling $*.c for $(BuildMode) build (bytecode)"
|
$(Echo) "Compiling $*.c for $(BuildMode) build (bytecode)"
|
||||||
$(Verb) if $(BCCompile.C) $(BC_DEPEND_OPTIONS) \
|
$(Verb) if $(BCCompile.C) $(BC_DEPEND_OPTIONS) \
|
||||||
$< -o $(ObjDir)/$*.ll -S -$(LLVMCC_EMITIR_FLAG) ; \
|
$< -o $(ObjDir)/$*.ll -S $(LLVMCC_EMITIR_FLAG) ; \
|
||||||
$(BC_DEPEND_MOVEFILE)
|
$(BC_DEPEND_MOVEFILE)
|
||||||
|
|
||||||
$(ObjDir)/%.ll: %.m $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCC)
|
$(ObjDir)/%.ll: %.m $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCC)
|
||||||
$(Echo) "Compiling $*.m for $(BuildMode) build (bytecode)"
|
$(Echo) "Compiling $*.m for $(BuildMode) build (bytecode)"
|
||||||
$(Verb) if $(BCCompile.C) $(BC_DEPEND_OPTIONS) \
|
$(Verb) if $(BCCompile.C) $(BC_DEPEND_OPTIONS) \
|
||||||
$< -o $(ObjDir)/$*.ll -S -$(LLVMCC_EMITIR_FLAG) ; \
|
$< -o $(ObjDir)/$*.ll -S $(LLVMCC_EMITIR_FLAG) ; \
|
||||||
$(BC_DEPEND_MOVEFILE)
|
$(BC_DEPEND_MOVEFILE)
|
||||||
|
|
||||||
# Provide alternate rule sets if dependencies are disabled
|
# Provide alternate rule sets if dependencies are disabled
|
||||||
|
@ -1580,23 +1580,23 @@ $(ObjDir)/%.o: %.m $(ObjDir)/.dir $(BUILT_SOURCES)
|
||||||
|
|
||||||
$(ObjDir)/%.ll: %.cpp $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCXX)
|
$(ObjDir)/%.ll: %.cpp $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCXX)
|
||||||
$(Echo) "Compiling $*.cpp for $(BuildMode) build (bytecode)"
|
$(Echo) "Compiling $*.cpp for $(BuildMode) build (bytecode)"
|
||||||
$(BCCompile.CXX) $< -o $@ -S -$(LLVMCC_EMITIR_FLAG)
|
$(BCCompile.CXX) $< -o $@ -S $(LLVMCC_EMITIR_FLAG)
|
||||||
|
|
||||||
$(ObjDir)/%.ll: %.mm $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCXX)
|
$(ObjDir)/%.ll: %.mm $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCXX)
|
||||||
$(Echo) "Compiling $*.mm for $(BuildMode) build (bytecode)"
|
$(Echo) "Compiling $*.mm for $(BuildMode) build (bytecode)"
|
||||||
$(BCCompile.CXX) $< -o $@ -S -$(LLVMCC_EMITIR_FLAG)
|
$(BCCompile.CXX) $< -o $@ -S $(LLVMCC_EMITIR_FLAG)
|
||||||
|
|
||||||
$(ObjDir)/%.ll: %.cc $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCXX)
|
$(ObjDir)/%.ll: %.cc $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCXX)
|
||||||
$(Echo) "Compiling $*.cc for $(BuildMode) build (bytecode)"
|
$(Echo) "Compiling $*.cc for $(BuildMode) build (bytecode)"
|
||||||
$(BCCompile.CXX) $< -o $@ -S -$(LLVMCC_EMITIR_FLAG)
|
$(BCCompile.CXX) $< -o $@ -S $(LLVMCC_EMITIR_FLAG)
|
||||||
|
|
||||||
$(ObjDir)/%.ll: %.c $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCC)
|
$(ObjDir)/%.ll: %.c $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCC)
|
||||||
$(Echo) "Compiling $*.c for $(BuildMode) build (bytecode)"
|
$(Echo) "Compiling $*.c for $(BuildMode) build (bytecode)"
|
||||||
$(BCCompile.C) $< -o $@ -S -$(LLVMCC_EMITIR_FLAG)
|
$(BCCompile.C) $< -o $@ -S $(LLVMCC_EMITIR_FLAG)
|
||||||
|
|
||||||
$(ObjDir)/%.ll: %.m $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCC)
|
$(ObjDir)/%.ll: %.m $(ObjDir)/.dir $(BUILT_SOURCES) $(LLVMCC)
|
||||||
$(Echo) "Compiling $*.m for $(BuildMode) build (bytecode)"
|
$(Echo) "Compiling $*.m for $(BuildMode) build (bytecode)"
|
||||||
$(BCCompile.C) $< -o $@ -S -$(LLVMCC_EMITIR_FLAG)
|
$(BCCompile.C) $< -o $@ -S $(LLVMCC_EMITIR_FLAG)
|
||||||
|
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|
|
@ -259,6 +259,7 @@ private:
|
||||||
if (CallSites[i] == CS.getInstruction()) {
|
if (CallSites[i] == CS.getInstruction()) {
|
||||||
CallSites[i] = CallSites.back();
|
CallSites[i] = CallSites.back();
|
||||||
CallSites.pop_back();
|
CallSites.pop_back();
|
||||||
|
--i; --e; // Revisit the moved entry.
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
void setVolatile() { Volatile = true; }
|
void setVolatile() { Volatile = true; }
|
||||||
|
|
Loading…
Reference in New Issue