Add a note

llvm-svn: 26523
This commit is contained in:
Chris Lattner 2006-03-04 08:44:51 +00:00
parent adf5ec6f96
commit c9a318d8fa
1 changed files with 17 additions and 0 deletions

View File

@ -101,3 +101,20 @@ into:
This would be a win on ppc32, but not x86 or ppc64.
//===---------------------------------------------------------------------===//
Pull add through mul/shift to handle this:
int foo(int P[4][4], int i) {
return P[i+2][1];
}
better than this (no addi needed):
_foo:
addi r2, r4, 2
slwi r2, r2, 4
add r2, r3, r2
lwz r3, 4(r2)
blr