add another note
authorChris Lattner <sabre@nondot.org>
Fri, 24 Mar 2006 20:04:27 +0000 (20:04 +0000)
committerChris Lattner <sabre@nondot.org>
Fri, 24 Mar 2006 20:04:27 +0000 (20:04 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27077 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/PowerPC/README.txt

index 5bdefaa23ce2d7378ecacf3d0224e3d31f383ed9..12599cb2fa8a01e332d37050d3c7b3df259d565a 100644 (file)
@@ -579,3 +579,18 @@ Since we know that "Vector" is 16-byte aligned and we know the element offset
 of ".X", we should change the load into a lve*x instruction, instead of doing
 a load/store/lve*x sequence.
 
+===-------------------------------------------------------------------------===
+
+We generate ugly code for this:
+
+void func(unsigned int *ret, float dx, float dy, float dz, float dw) {
+  unsigned code = 0;
+  if(dx < -dw) code |= 1;
+  if(dx > dw)  code |= 2;
+  if(dy < -dw) code |= 4;
+  if(dy > dw)  code |= 8;
+  if(dz < -dw) code |= 16;
+  if(dz > dw)  code |= 32;
+  *ret = code;
+}
+