From: Chris Lattner Date: Sun, 19 Sep 2010 00:34:58 +0000 (+0000) Subject: add a readme. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=702917d4e836ec8346c05aadbc2c1a461c6c3ca6;p=oota-llvm.git add a readme. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@114303 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Target/PowerPC/README.txt b/lib/Target/PowerPC/README.txt index 3465779e344..4c80225d041 100644 --- a/lib/Target/PowerPC/README.txt +++ b/lib/Target/PowerPC/README.txt @@ -37,6 +37,31 @@ _f3: ori r3, r2, 65535 blr +===-------------------------------------------------------------------------=== + +This code: + +unsigned add32carry(unsigned sum, unsigned x) { + unsigned z = sum + x; + if (sum + x < x) + z++; + return z; +} + +Should compile to something like: + + addc r3,r3,r4 + addze r3,r3 + +instead we get: + + add r3, r4, r3 + cmplw cr7, r3, r4 + mfcr r4 ; 1 + rlwinm r4, r4, 29, 31, 31 + add r3, r3, r4 + +Ick. ===-------------------------------------------------------------------------===