mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2025-01-31 20:51:52 +01:00
Have FastISel skip the multiply by 1 for getelementptr on i8*.
llvm-svn: 55129
This commit is contained in:
parent
5bbfc7e05f
commit
7c434de476
@ -124,10 +124,8 @@ bool FastISel::SelectGetElementPtr(Instruction *I,
|
||||
// Unhandled operand. Halt "fast" selection and bail.
|
||||
return false;
|
||||
|
||||
// FIXME: If multiple is power of two, turn it into a shift. The
|
||||
// optimization should be in FastEmit_ri?
|
||||
IdxN = FastEmit_ri_(VT, ISD::MUL, IdxN,
|
||||
ElementSize, VT);
|
||||
if (ElementSize != 1)
|
||||
IdxN = FastEmit_ri_(VT, ISD::MUL, IdxN, ElementSize, VT);
|
||||
if (IdxN == 0)
|
||||
// Unhandled operand. Halt "fast" selection and bail.
|
||||
return false;
|
||||
|
Loading…
x
Reference in New Issue
Block a user