[llvm-commits] CVS: llvm/test/Programs/SingleSource/Shootout/random.c

Misha Brukman brukman at cs.uiuc.edu
Thu Jul 10 17:35:01 PDT 2003


Changes in directory llvm/test/Programs/SingleSource/Shootout:

random.c updated: 1.2 -> 1.3

---
Log message:

Converted tabs to spaces, lined things up better.


---
Diffs of the changes:

Index: llvm/test/Programs/SingleSource/Shootout/random.c
diff -u llvm/test/Programs/SingleSource/Shootout/random.c:1.2 llvm/test/Programs/SingleSource/Shootout/random.c:1.3
--- llvm/test/Programs/SingleSource/Shootout/random.c:1.2	Sun Aug 25 11:48:03 2002
+++ llvm/test/Programs/SingleSource/Shootout/random.c	Thu Jul 10 17:34:14 2003
@@ -1,5 +1,5 @@
 /* -*- mode: c -*-
- * $Id: random.c,v 1.2 2002/08/25 16:48:03 vadve Exp $
+ * $Id: random.c,v 1.3 2003/07/10 22:34:14 brukman Exp $
  * http://www.bagley.org/~doug/shootout/
  */
 
@@ -14,18 +14,18 @@
 #define IC 29573
 
 inline double gen_random(double max) {
-    static long last = 42;
+  static long last = 42;
     
-    last = (last * IA + IC) % IM;
-    return( max * last / IM );
+  last = (last * IA + IC) % IM;
+  return( max * last / IM );
 }
 
 int main(int argc, char *argv[]) {
-    int N = ((argc == 2) ? atoi(argv[1]) : 1) - 1;
+  int N = ((argc == 2) ? atoi(argv[1]) : 1) - 1;
     
-    while (N--) {
-	gen_random(100.0);
-    }
-    printf("%.9f\n", gen_random(100.0));
-    return(0);
+  while (N--) {
+    gen_random(100.0);
+  }
+  printf("%.9f\n", gen_random(100.0));
+  return(0);
 }





More information about the llvm-commits mailing list