aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Target/PowerPC/PPCISelLowering.h
diff options
context:
space:
mode:
authorHal Finkel <hfinkel@anl.gov>2013-03-15 15:27:13 +0000
committerHal Finkel <hfinkel@anl.gov>2013-03-15 15:27:13 +0000
commit2d37f7b979a24930c444f9783173a90a6e548118 (patch)
treea30c316b5d17f708c2c44d5d0461baa8452e1622 /lib/Target/PowerPC/PPCISelLowering.h
parentc0d8dc0eb6e1df872affadba01f60e42275e2863 (diff)
downloadexternal_llvm-2d37f7b979a24930c444f9783173a90a6e548118.zip
external_llvm-2d37f7b979a24930c444f9783173a90a6e548118.tar.gz
external_llvm-2d37f7b979a24930c444f9783173a90a6e548118.tar.bz2
Enable unaligned memory access on PPC for scalar types
Unaligned access is supported on PPC for non-vector types, and is generally more efficient than manually expanding the loads and stores. A few of the existing test cases were using expanded unaligned loads and stores to test other features (like load/store with update), and for these test cases, unaligned access remains disabled. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@177160 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/PowerPC/PPCISelLowering.h')
-rw-r--r--lib/Target/PowerPC/PPCISelLowering.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Target/PowerPC/PPCISelLowering.h b/lib/Target/PowerPC/PPCISelLowering.h
index 3931384..8d44d9f 100644
--- a/lib/Target/PowerPC/PPCISelLowering.h
+++ b/lib/Target/PowerPC/PPCISelLowering.h
@@ -449,6 +449,10 @@ namespace llvm {
bool IsMemset, bool ZeroMemset, bool MemcpyStrSrc,
MachineFunction &MF) const;
+ /// Is unaligned memory access allowed for the given type, and is it fast
+ /// relative to software emulation.
+ virtual bool allowsUnalignedMemoryAccesses(EVT VT, bool *Fast = 0) const;
+
/// isFMAFasterThanMulAndAdd - Return true if an FMA operation is faster than
/// a pair of mul and add instructions. fmuladd intrinsics will be expanded to
/// FMAs when this method returns true (and FMAs are legal), otherwise fmuladd