[mkbundle] Enhanced mkbundle cygwin/mingw fallback support. (#5867)
[mono-project.git] / mono / benchmark / cmov4.cs
blobc00bc32b6c84bd5fa12e7519600e884b27186416
1 using System;
2 class T {
3 // some more advanced versions.
4 static void Main () {
5 int a = 0, b = 0, c = 0, d = 0, e = 0;
6 for (int i = 0; i < 50000000; i ++) {
7 // sgn (x)
8 if (a == 0)
9 a = 0;
10 else if (a < 0)
11 a = -1;
12 else
13 a = 1;
15 // cond incr
16 if (a <= 0)
17 a ++;
19 // buffer ring
20 if (b == 49)
21 b = 0;
22 else
23 b ++;
25 // max
26 c = a > b ? a : b;
28 // abs
29 d = a > 0 ? a : -a;