[llvm-commits] CVS: llvm/test/Regression/CodeGen/Generic/BasicInstrs.c

Chris Lattner lattner at cs.uiuc.edu
Wed Apr 7 00:07:05 PDT 2004


Changes in directory llvm/test/Regression/CodeGen/Generic:

BasicInstrs.c added (r1.1)

---
Log message:

New file that can be useful for hand inspection of assembly required for certain
kinds of instructions.


---
Diffs of the changes:  (+23 -0)

Index: llvm/test/Regression/CodeGen/Generic/BasicInstrs.c
diff -c /dev/null llvm/test/Regression/CodeGen/Generic/BasicInstrs.c:1.1
*** /dev/null	Wed Apr  7 00:06:49 2004
--- llvm/test/Regression/CodeGen/Generic/BasicInstrs.c	Wed Apr  7 00:06:39 2004
***************
*** 0 ****
--- 1,23 ----
+ // This file can be used to see what a native C compiler is generating for a 
+ // variety of interesting operations.
+ unsigned int udiv(unsigned int X, unsigned int Y) {
+   return X/Y;
+ }
+ int sdiv(int X, int Y) {
+   return X/Y;
+ }
+ unsigned int urem(unsigned int X, unsigned int Y) {
+   return X%Y;
+ }
+ int srem(int X, int Y) {
+   return X%Y;
+ }
+ 
+ _Bool setlt(int X, int Y) {
+   return X < Y;
+ }
+ 
+ _Bool setgt(int X, int Y) {
+   return X > Y;
+ }
+ 	





More information about the llvm-commits mailing list