From deb35afd235efa34c49bbed3519e51203c269d46 Mon Sep 17 00:00:00 2001 From: Bob Wilson Date: Wed, 1 Jul 2009 23:16:05 +0000 Subject: Add a new addressing mode for NEON load/store instructions. llvm-svn: 74658 --- llvm/lib/Target/ARM/ARMAddressingModes.h | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) (limited to 'llvm/lib/Target/ARM/ARMAddressingModes.h') diff --git a/llvm/lib/Target/ARM/ARMAddressingModes.h b/llvm/lib/Target/ARM/ARMAddressingModes.h index 7dc2dca58ce..15c9ec1fc23 100644 --- a/llvm/lib/Target/ARM/ARMAddressingModes.h +++ b/llvm/lib/Target/ARM/ARMAddressingModes.h @@ -496,7 +496,29 @@ namespace ARM_AM { static inline bool getAM5WBFlag(unsigned AM5Opc) { return ((AM5Opc >> 8) & 1); } - + + //===--------------------------------------------------------------------===// + // Addressing Mode #6 + //===--------------------------------------------------------------------===// + // + // This is used for NEON load / store instructions. + // + // addrmode6 := reg with optional writeback + // + // This is stored in three operands [regaddr, regupdate, opc]. The first is + // the address register. The second register holds the value of a post-access + // increment for writeback or reg0 if no writeback or if the writeback + // increment is the size of the memory access. The third operand encodes + // whether there is writeback to the address register. + + static inline unsigned getAM6Opc(bool WB = false) { + return (int)WB; + } + + static inline bool getAM6WBFlag(unsigned Mode) { + return Mode & 1; + } + } // end namespace ARM_AM } // end namespace llvm -- cgit v1.2.3