blob: 3a57e4d59422fbfe10f935005eb9993b5852f5d0 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
|
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.
// This test tests our signed uncontained compare logic
// We should generate a signed jump for the high compare, and an unsigned
// jump for the low compare.
//
using System;
using System.Runtime.CompilerServices;
class Program
{
uint i;
[MethodImpl(MethodImplOptions.NoInlining)]
static int Test(long a, long b)
{
if (a < b)
{
return 5;
}
else
{
return 0;
}
}
static int Main()
{
const int Pass = 100;
const int Fail = -1;
if (Test(-2147483649L, -2147483648L) == 5)
{
Console.WriteLine("Passed");
return Pass;
}
else
{
Console.WriteLine("Failed");
return Fail;
}
}
}
|