mirror of
https://github.com/RPCSX/llvm.git
synced 2024-12-03 09:21:13 +00:00
Have FastISel skip the multiply by 1 for getelementptr on i8*.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@55129 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
62990bafa3
commit
f93cf79505
@ -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…
Reference in New Issue
Block a user