blob: 9917c21fca4031990b25beb30a3962d32e10c0ad (
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
|
// 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.
.assembly extern mscorlib {}
.assembly DevDiv_359737 {}
// This test originally repro'd a bug in morph that transformed modulus by a constant into division and subtraction
// while re-morphing as part of CSE.
.class C extends [mscorlib]System.Object
{
.method static int16 M() cil managed noinlining
{
ldc.i4 0x78804C04
conv.ovf.u2
dup
rem
ret
}
.method static int32 Main() cil managed
{
.entrypoint
.try
{
call int16 C::M()
pop
leave.s done
}
catch [mscorlib]System.Exception
{
pop
leave.s done
}
done:
ldc.i4 100
ret
}
}
|