diff options
| author | Joshua Bakita <jbakita@cs.unc.edu> | 2020-10-16 16:55:14 -0400 |
|---|---|---|
| committer | Joshua Bakita <jbakita@cs.unc.edu> | 2020-10-16 16:55:14 -0400 |
| commit | 6ea9939e0610a809f6f47d13ec68df00d1ca0afc (patch) | |
| tree | fe4a2eee3ddcf77e2367309dcd75a232b76dcd62 /dis/original | |
| parent | e9285d0cdea756a2830f0ace378e4197b36869aa (diff) | |
Move the DIS benchmarks up a directory and update hardcoded paths
Note that this repo does not attempt to keep a copy of the original
DIS benchmark distributions. UNC real-time has another repo for that.
Diffstat (limited to 'dis/original')
77 files changed, 0 insertions, 5810 deletions
diff --git a/dis/original/Field/DISstressmarkRNG.h b/dis/original/Field/DISstressmarkRNG.h deleted file mode 100644 index 4aa2620..0000000 --- a/dis/original/Field/DISstressmarkRNG.h +++ /dev/null | |||
| @@ -1,190 +0,0 @@ | |||
| 1 | #include <math.h> | ||
| 2 | |||
| 3 | #define IA 16807 | ||
| 4 | #define IM 2147483647 | ||
| 5 | #define AM (1.0/IM) | ||
| 6 | #define IQ 127773 | ||
| 7 | #define IR 2836 | ||
| 8 | #define NTAB 32 | ||
| 9 | #define NDIV (1+(IM-1)/NTAB) | ||
| 10 | #define EPS 1.2e-7 | ||
| 11 | #define RNMX (1.0-EPS) | ||
| 12 | |||
| 13 | static long iy=0; | ||
| 14 | static long iv[NTAB]; | ||
| 15 | static long iseed; | ||
| 16 | |||
| 17 | int ABS(int x){ | ||
| 18 | if (x>= 0) return x; | ||
| 19 | else | ||
| 20 | return (-x); | ||
| 21 | } | ||
| 22 | |||
| 23 | int sign(int x){ | ||
| 24 | if (x >= 0) return 1; | ||
| 25 | else | ||
| 26 | return (-1); | ||
| 27 | } | ||
| 28 | |||
| 29 | int MAX(int x, int y){ | ||
| 30 | if (x>= y) return x; | ||
| 31 | else | ||
| 32 | return y; | ||
| 33 | } | ||
| 34 | |||
| 35 | int MIN(int x, int y){ | ||
| 36 | if (x<= y) return x; | ||
| 37 | else | ||
| 38 | return y; | ||
| 39 | } | ||
| 40 | |||
| 41 | void randInit(long idum) | ||
| 42 | { | ||
| 43 | long j; | ||
| 44 | long k; | ||
| 45 | |||
| 46 | assert (idum <= 0); | ||
| 47 | assert (iy == 0); | ||
| 48 | |||
| 49 | iseed = idum; | ||
| 50 | if (-(iseed)<1){ | ||
| 51 | iseed = 1; | ||
| 52 | } | ||
| 53 | else { | ||
| 54 | iseed = -(iseed); | ||
| 55 | } | ||
| 56 | for (j=NTAB+7; j>=0; j--){ | ||
| 57 | k = (iseed)/IQ; | ||
| 58 | iseed = IA*(iseed-k*IQ)-IR*k; | ||
| 59 | if (iseed < 0){ | ||
| 60 | iseed += IM; | ||
| 61 | } | ||
| 62 | if (j < NTAB){ | ||
| 63 | iv[j] = iseed; | ||
| 64 | } | ||
| 65 | } | ||
| 66 | iy = iv[0]; | ||
| 67 | } | ||
| 68 | |||
| 69 | float randNum() | ||
| 70 | { | ||
| 71 | long j; | ||
| 72 | long k; | ||
| 73 | float temp; | ||
| 74 | |||
| 75 | assert (iy != 0); | ||
| 76 | |||
| 77 | k = (iseed)/IQ; | ||
