Merging r257730:
authorHans Wennborg <hans@hanshq.net>
Thu, 14 Jan 2016 17:52:28 +0000 (17:52 +0000)
committerHans Wennborg <hans@hanshq.net>
Thu, 14 Jan 2016 17:52:28 +0000 (17:52 +0000)
commit25d64abdb39a834541edbafdc686f371dad58a76
treee63cc77601b39dcb447d0fe4893051b03494c4c3
parent7b9eef037dbacab102881f19826fb04cfe69c7e7
Merging r257730:
------------------------------------------------------------------------
r257730 | majnemer | 2016-01-13 17:20:03 -0800 (Wed, 13 Jan 2016) | 11 lines

[X86] Don't alter HasOpaqueSPAdjustment after we've relied on it

We rely on HasOpaqueSPAdjustment not changing after we've calculated
things based on it.  Things like whether or not we can use 'rep;movs' to
copy bytes around, that sort of thing.  If it changes, invariants in the
backend will quietly break.  This situation arose when we had a call to
memcpy *and* a COPY of the FLAGS register where we would attempt to
reference local variables using %esi, a register that was clobbered by
the 'rep;movs'.

This fixes PR26124.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_38@257779 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/CodeGen/MachineFrameInfo.h
include/llvm/Target/TargetLowering.h
lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
lib/Target/X86/X86FrameLowering.cpp
lib/Target/X86/X86ISelLowering.cpp
test/CodeGen/X86/x86-repmov-copy-eflags.ll [new file with mode: 0644]