[PowerPC] Implement PPCTargetLowering::getTgtMemIntrinsic
authorHal Finkel <hfinkel@anl.gov>
Wed, 13 Aug 2014 01:15:40 +0000 (01:15 +0000)
committerHal Finkel <hfinkel@anl.gov>
Wed, 13 Aug 2014 01:15:40 +0000 (01:15 +0000)
commite693d3c55804812afbcca2268465d9a3fdd56b6f
treec6be981dfe86086e3ef0a39c75038b21a486eff8
parent695e914c03da8f3e7214df6135ca6ab877524828
[PowerPC] Implement PPCTargetLowering::getTgtMemIntrinsic

This implements PPCTargetLowering::getTgtMemIntrinsic for Altivec load/store
intrinsics. As with the construction of the MachineMemOperands for the
intrinsic calls used for unaligned load/store lowering, the only slight
complication is that we need to represent a larger memory range than the
loaded/stored value-type size (because the address is rounded down to an
aligned address, and we need to conservatively represent the entire possible
range of the actual access). This required adding an extra size field to
TargetLowering::IntrinsicInfo, and this was done in a way that required no
modifications to other targets (the size defaults to the store size of the
provided memory data type).

This fixes test/CodeGen/PowerPC/unal-altivec-wint.ll (so it can be un-XFAILed).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@215512 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/CodeGen/SelectionDAG.h
include/llvm/Target/TargetLowering.h
lib/CodeGen/SelectionDAG/SelectionDAG.cpp
lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
lib/Target/PowerPC/PPCISelLowering.cpp
lib/Target/PowerPC/PPCISelLowering.h
test/CodeGen/PowerPC/unal-altivec-wint.ll