LLVM API Documentation
Public Member Functions | |
BaseIndexOffset () | |
BaseIndexOffset (SDValue Base, SDValue Index, int64_t Offset, bool IsIndexSignExt) | |
bool | equalBaseIndex (const BaseIndexOffset &Other) |
Static Public Member Functions | |
static BaseIndexOffset | match (SDValue Ptr) |
Parses tree in Ptr for base, index, offset addresses. | |
Public Attributes | |
SDValue | Base |
SDValue | Index |
int64_t | Offset |
bool | IsIndexSignExt |
Helper struct to parse and store a memory address as base + index + offset. We ignore sign extensions when it is safe to do so. The following two expressions are not equivalent. To differentiate we need to store whether there was a sign extension involved in the index computation. (load (i64 add (i64 copyfromreg c) (i64 signextend (add (i8 load index) (i8 1)))) vs
(load (i64 add (i64 copyfromreg c) (i64 signextend (i32 add (i32 signextend (i8 load index)) (i32 1)))))
Definition at line 9043 of file DAGCombiner.cpp.
BaseIndexOffset::BaseIndexOffset | ( | ) | [inline] |
Definition at line 9049 of file DAGCombiner.cpp.
BaseIndexOffset::BaseIndexOffset | ( | SDValue | Base, |
SDValue | Index, | ||
int64_t | Offset, | ||
bool | IsIndexSignExt | ||
) | [inline] |
Definition at line 9051 of file DAGCombiner.cpp.
bool BaseIndexOffset::equalBaseIndex | ( | const BaseIndexOffset & | Other | ) | [inline] |
Definition at line 9055 of file DAGCombiner.cpp.
References Base, Index, and IsIndexSignExt.
static BaseIndexOffset BaseIndexOffset::match | ( | SDValue | Ptr | ) | [inline, static] |
Parses tree in Ptr for base, index, offset addresses.
Definition at line 9061 of file DAGCombiner.cpp.
References ADD, llvm::SDNode::getOpcode(), llvm::SDNode::getOperand(), llvm::ISD::MUL, and llvm::ISD::SIGN_EXTEND.
Definition at line 9044 of file DAGCombiner.cpp.
Referenced by equalBaseIndex().
Definition at line 9045 of file DAGCombiner.cpp.
Referenced by equalBaseIndex().
Definition at line 9047 of file DAGCombiner.cpp.
Referenced by equalBaseIndex().
int64_t BaseIndexOffset::Offset |
Definition at line 9046 of file DAGCombiner.cpp.