diff options
author | Hal Finkel <hfinkel@anl.gov> | 2015-01-05 21:33:14 +0000 |
---|---|---|
committer | Hal Finkel <hfinkel@anl.gov> | 2015-01-05 21:33:14 +0000 |
commit | c7d35bb5b1eed5bf5c79fae37f978d10eed9c001 (patch) | |
tree | 1a6f4c1136fff69c1f7ba942c20e51374f62c785 /llvm/lib | |
parent | e541e0b32756321dac8d5067d17901f913385ec2 (diff) | |
download | bcm5719-llvm-c7d35bb5b1eed5bf5c79fae37f978d10eed9c001.tar.gz bcm5719-llvm-c7d35bb5b1eed5bf5c79fae37f978d10eed9c001.zip |
[PowerPC] Add a test for truncating a shifted load
We now produce the desired code as noted in the README.txt file. Remove the
README entry and add a regression test.
llvm-svn: 225209
Diffstat (limited to 'llvm/lib')
-rw-r--r-- | llvm/lib/Target/PowerPC/README.txt | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/llvm/lib/Target/PowerPC/README.txt b/llvm/lib/Target/PowerPC/README.txt index f705139e680..9565ae131f8 100644 --- a/llvm/lib/Target/PowerPC/README.txt +++ b/llvm/lib/Target/PowerPC/README.txt @@ -255,24 +255,6 @@ int f(signed char *a, _Bool b, _Bool c) { ===-------------------------------------------------------------------------=== -This: -int test(unsigned *P) { return *P >> 24; } - -Should compile to: - -_test: - lbz r3,0(r3) - blr - -not: - -_test: - lwz r2, 0(r3) - srwi r3, r2, 24 - blr - -===-------------------------------------------------------------------------=== - On the G5, logical CR operations are more expensive in their three address form: ops that read/write the same register are half as expensive as those that read from two registers that are different from their destination. |