[interp] properly pass 64bit integers to native code on 32bit arches
[mono-project.git] / mono / benchmark / inline4.cs
blob47cd0ee839cc95e08150820b7cd54bbdc28760e7
1 using System;
3 public class Tests {
5 public static int test (int n) {
6 if ((n & 1) == 0)
7 return 2;
8 else
9 return 1;
12 public static int Main (string[] args) {
13 int repeat = 1;
14 int sum = 0;
16 if (args.Length == 1)
17 repeat = Convert.ToInt32 (args [0]);
19 Console.WriteLine ("Repeat = " + repeat);
21 for (int i = 0; i < repeat; i++)
22 for (int j = 0; j < 50000000; j++)
23 sum += test (j);
26 Console.WriteLine (sum);
27 if (sum != (75000000 * repeat))
28 return 1;
30 return 0;