Allow {e,r}bp as the target of {read,write}_register.
authorPat Gavlin <pagavlin@microsoft.com>
Thu, 9 Jul 2015 17:40:29 +0000 (17:40 +0000)
committerPat Gavlin <pagavlin@microsoft.com>
Thu, 9 Jul 2015 17:40:29 +0000 (17:40 +0000)
commitdb5a82b861c976066cca1ca3d2bf1de1931d6019
tree1b16db1325e7ac166ec6ad18505e296f7b26f6f3
parentdc219dddde93aee367fe7982f2ceeb26528f06dc
Allow {e,r}bp as the target of {read,write}_register.

This patch allows the read_register and write_register intrinsics to
read/write the RBP/EBP registers on X86 iff the targeted register is
the frame pointer for the containing function.

Differential Revision: http://reviews.llvm.org/D10977

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@241827 91177308-0d34-0410-b5e6-96231b3b80d8
14 files changed:
include/llvm/Target/TargetLowering.h
lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp
lib/Target/AArch64/AArch64ISelLowering.cpp
lib/Target/AArch64/AArch64ISelLowering.h
lib/Target/ARM/ARMISelLowering.cpp
lib/Target/ARM/ARMISelLowering.h
lib/Target/Mips/MipsISelLowering.cpp
lib/Target/Mips/MipsISelLowering.h
lib/Target/PowerPC/PPCISelLowering.cpp
lib/Target/PowerPC/PPCISelLowering.h
lib/Target/X86/X86ISelLowering.cpp
lib/Target/X86/X86ISelLowering.h
test/CodeGen/X86/frameregister.ll [new file with mode: 0644]
test/CodeGen/X86/read-fp-no-frame-pointer.ll [new file with mode: 0644]