Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions deps/llvm.mk
Original file line number Diff line number Diff line change
Expand Up @@ -430,6 +430,8 @@ $(eval $(call LLVM_PATCH,llvm9-D71443-PPC-MC-redef-symbol)) # remove for 10.0
$(eval $(call LLVM_PATCH,llvm-9.0-D78196)) # remove for 11.0
$(eval $(call LLVM_PATCH,llvm-julia-tsan-custom-as))
$(eval $(call LLVM_PATCH,llvm-9.0-D85499))
$(eval $(call LLVM_PATCH,llvm-D80101))
$(eval $(call LLVM_PATCH,llvm-D84031))
endif # LLVM_VER 9.0

ifeq ($(LLVM_VER_SHORT),10.0)
Expand All @@ -445,6 +447,8 @@ $(eval $(call LLVM_PATCH,llvm-D75072-SCEV-add-type))
$(eval $(call LLVM_PATCH,llvm-10.0-PPC_SELECT_CC)) # delete for LLVM 11
$(eval $(call LLVM_PATCH,llvm-10.0-PPC-LI-Elimination)) # delete for LLVM 11
$(eval $(call LLVM_PATCH,llvm-julia-tsan-custom-as))
$(eval $(call LLVM_PATCH,llvm-D80101))
$(eval $(call LLVM_PATCH,llvm-D84031))
endif # LLVM_VER 10.0

ifeq ($(LLVM_VER_SHORT),11.0)
Expand Down
13 changes: 13 additions & 0 deletions deps/patches/llvm-D80101.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/lib/CodeGen/StackColoring.cpp b/lib/CodeGen/StackColoring.cpp
index 9d4fdc6b624..14b52e0ca33 100644
--- a/lib/CodeGen/StackColoring.cpp
+++ b/lib/CodeGen/StackColoring.cpp
@@ -913,6 +913,8 @@ void StackColoring::remapInstructions(DenseMap<int, int> &SlotRemap) {
assert(To && From && "Invalid allocation object");
Allocas[From] = To;

+ const_cast<AllocaInst*>(To)->moveBefore(const_cast<Instruction*>(&*To->getParent()->getFirstInsertionPt()));
+
// AA might be used later for instruction scheduling, and we need it to be
// able to deduce the correct aliasing releationships between pointers
// derived from the alloca being remapped and the target of that remapping.
10 changes: 10 additions & 0 deletions deps/patches/llvm-D84031.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
--- a/lib/CodeGen/CodeGenPrepare.cpp
+++ b/lib/CodeGen/CodeGenPrepare.cpp
@@ -540,6 +540,7 @@
LargeOffsetGEPID.clear();
}

+ NewGEPBases.clear();
SunkAddrs.clear();

if (!DisableBranchOpts) {