diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopByte.fs.RealInternalSignatureOff.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopByte.fs.RealInternalSignatureOff.OptimizeOn.il.bsl new file mode 100644 index 00000000000..b287301dd82 --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopByte.fs.RealInternalSignatureOff.OptimizeOn.il.bsl @@ -0,0 +1,386 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (uint8 V_0, + uint8 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(uint8) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.0 + IL_0017: blt.un.s IL_0007 + + IL_0019: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint8 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.1 + IL_0003: stloc.1 + IL_0004: br.s IL_0014 + + IL_0006: ldloc.1 + IL_0007: call void assembly::set_c(uint8) + IL_000c: ldloc.1 + IL_000d: ldc.i4.1 + IL_000e: add + IL_000f: stloc.1 + IL_0010: ldloc.0 + IL_0011: ldc.i4.1 + IL_0012: add + IL_0013: stloc.0 + IL_0014: ldloc.0 + IL_0015: ldc.i4.s 10 + IL_0017: blt.un.s IL_0006 + + IL_0019: ret + } + + .method public static void constStart(uint8 start) cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + uint8 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.un.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldc.i4.s 10 + IL_000b: ldarg.0 + IL_000c: sub + IL_000d: conv.u2 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldarg.0 + IL_0015: stloc.2 + IL_0016: br.s IL_0026 + + IL_0018: ldloc.2 + IL_0019: call void assembly::set_c(uint8) + IL_001e: ldloc.2 + IL_001f: ldc.i4.1 + IL_0020: add + IL_0021: stloc.2 + IL_0022: ldloc.1 + IL_0023: ldc.i4.1 + IL_0024: add + IL_0025: stloc.1 + IL_0026: ldloc.1 + IL_0027: ldloc.0 + IL_0028: blt.un.s IL_0018 + + IL_002a: ret + } + + .method public static void constFinish(uint8 finish) cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + uint8 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldc.i4.1 + IL_000a: sub + IL_000b: conv.u2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldc.i4.1 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedStart(uint8 start, + uint8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + uint8 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedFinish(uint8 start, + uint8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + uint8 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void inferredStartAndFinish(uint8 start, + uint8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + uint8 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + } + + .method public specialname static uint8 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld uint8 ''.$assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(uint8 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld uint8 ''.$assembly::c@1 + IL_0006: ret + } + + .property uint8 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(uint8) + .get uint8 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly uint8 c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld uint8 ''.$assembly::c@1 + IL_0006: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopByte.fs.RealInternalSignatureOn.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopByte.fs.RealInternalSignatureOn.OptimizeOn.il.bsl new file mode 100644 index 00000000000..1c6a5c0c94c --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopByte.fs.RealInternalSignatureOn.OptimizeOn.il.bsl @@ -0,0 +1,405 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (uint8 V_0, + uint8 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(uint8) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.0 + IL_0017: blt.un.s IL_0007 + + IL_0019: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint8 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.1 + IL_0003: stloc.1 + IL_0004: br.s IL_0014 + + IL_0006: ldloc.1 + IL_0007: call void assembly::set_c(uint8) + IL_000c: ldloc.1 + IL_000d: ldc.i4.1 + IL_000e: add + IL_000f: stloc.1 + IL_0010: ldloc.0 + IL_0011: ldc.i4.1 + IL_0012: add + IL_0013: stloc.0 + IL_0014: ldloc.0 + IL_0015: ldc.i4.s 10 + IL_0017: blt.un.s IL_0006 + + IL_0019: ret + } + + .method public static void constStart(uint8 start) cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + uint8 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.un.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldc.i4.s 10 + IL_000b: ldarg.0 + IL_000c: sub + IL_000d: conv.u2 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldarg.0 + IL_0015: stloc.2 + IL_0016: br.s IL_0026 + + IL_0018: ldloc.2 + IL_0019: call void assembly::set_c(uint8) + IL_001e: ldloc.2 + IL_001f: ldc.i4.1 + IL_0020: add + IL_0021: stloc.2 + IL_0022: ldloc.1 + IL_0023: ldc.i4.1 + IL_0024: add + IL_0025: stloc.1 + IL_0026: ldloc.1 + IL_0027: ldloc.0 + IL_0028: blt.un.s IL_0018 + + IL_002a: ret + } + + .method public static void constFinish(uint8 finish) cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + uint8 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldc.i4.1 + IL_000a: sub + IL_000b: conv.u2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldc.i4.1 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedStart(uint8 start, + uint8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + uint8 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedFinish(uint8 start, + uint8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + uint8 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void inferredStartAndFinish(uint8 start, + uint8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + uint8 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + } + + .field static assembly uint8 c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .method public specialname static uint8 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld uint8 assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(uint8 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld uint8 assembly::c@1 + IL_0006: ret + } + + .method private specialname rtspecialname static void .cctor() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int32 ''.$assembly::init@ + IL_0006: ldsfld int32 ''.$assembly::init@ + IL_000b: pop + IL_000c: ret + } + + .method assembly specialname static void staticInitialization@() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld uint8 assembly::c@1 + IL_0006: ret + } + + .property uint8 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(uint8) + .get uint8 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: call void assembly::staticInitialization@() + IL_0005: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopChar.fs.RealInternalSignatureOff.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopChar.fs.RealInternalSignatureOff.OptimizeOn.il.bsl new file mode 100644 index 00000000000..bc0d27c660e --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopChar.fs.RealInternalSignatureOff.OptimizeOn.il.bsl @@ -0,0 +1,386 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (char V_0, + char V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 122 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(char) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.0 + IL_0017: blt.un.s IL_0007 + + IL_0019: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + char V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 97 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(char) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.s 26 + IL_0018: blt.un.s IL_0007 + + IL_001a: ret + } + + .method public static void constStart(char start) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + char V_2) + IL_0000: ldc.i4.s 122 + IL_0002: ldarg.0 + IL_0003: bge.un.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldc.i4.s 122 + IL_000b: ldarg.0 + IL_000c: sub + IL_000d: conv.u4 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldarg.0 + IL_0015: stloc.2 + IL_0016: br.s IL_0026 + + IL_0018: ldloc.2 + IL_0019: call void assembly::set_c(char) + IL_001e: ldloc.2 + IL_001f: ldc.i4.1 + IL_0020: add + IL_0021: stloc.2 + IL_0022: ldloc.1 + IL_0023: ldc.i4.1 + IL_0024: add + IL_0025: stloc.1 + IL_0026: ldloc.1 + IL_0027: ldloc.0 + IL_0028: blt.un.s IL_0018 + + IL_002a: ret + } + + .method public static void constFinish(char finish) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + char V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.s 97 + IL_0003: bge.un.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.0 + IL_000a: ldc.i4.s 97 + IL_000c: sub + IL_000d: conv.u4 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldc.i4.s 97 + IL_0016: stloc.2 + IL_0017: br.s IL_0027 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(char) + IL_001f: ldloc.2 + IL_0020: ldc.i4.1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: add + IL_0026: stloc.1 + IL_0027: ldloc.1 + IL_0028: ldloc.0 + IL_0029: blt.un.s IL_0019 + + IL_002b: ret + } + + .method public static void annotatedStart(char start, + char finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + char V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(char) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedFinish(char start, + char finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + char V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(char) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void inferredStartAndFinish(char start, + char finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + char V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(char) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + } + + .method public specialname static char get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld char ''.$assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(char 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld char ''.$assembly::c@1 + IL_0006: ret + } + + .property char c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(char) + .get char assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly char c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld char ''.$assembly::c@1 + IL_0006: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopChar.fs.RealInternalSignatureOn.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopChar.fs.RealInternalSignatureOn.OptimizeOn.il.bsl new file mode 100644 index 00000000000..ba5d25098ce --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopChar.fs.RealInternalSignatureOn.OptimizeOn.il.bsl @@ -0,0 +1,405 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (char V_0, + char V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 122 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(char) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.0 + IL_0017: blt.un.s IL_0007 + + IL_0019: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + char V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 97 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(char) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.s 26 + IL_0018: blt.un.s IL_0007 + + IL_001a: ret + } + + .method public static void constStart(char start) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + char V_2) + IL_0000: ldc.i4.s 122 + IL_0002: ldarg.0 + IL_0003: bge.un.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldc.i4.s 122 + IL_000b: ldarg.0 + IL_000c: sub + IL_000d: conv.u4 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldarg.0 + IL_0015: stloc.2 + IL_0016: br.s IL_0026 + + IL_0018: ldloc.2 + IL_0019: call void assembly::set_c(char) + IL_001e: ldloc.2 + IL_001f: ldc.i4.1 + IL_0020: add + IL_0021: stloc.2 + IL_0022: ldloc.1 + IL_0023: ldc.i4.1 + IL_0024: add + IL_0025: stloc.1 + IL_0026: ldloc.1 + IL_0027: ldloc.0 + IL_0028: blt.un.s IL_0018 + + IL_002a: ret + } + + .method public static void constFinish(char finish) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + char V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.s 97 + IL_0003: bge.un.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.0 + IL_000a: ldc.i4.s 97 + IL_000c: sub + IL_000d: conv.u4 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldc.i4.s 97 + IL_0016: stloc.2 + IL_0017: br.s IL_0027 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(char) + IL_001f: ldloc.2 + IL_0020: ldc.i4.1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: add + IL_0026: stloc.1 + IL_0027: ldloc.1 + IL_0028: ldloc.0 + IL_0029: blt.un.s IL_0019 + + IL_002b: ret + } + + .method public static void annotatedStart(char start, + char finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + char V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(char) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedFinish(char start, + char finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + char V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(char) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void inferredStartAndFinish(char start, + char finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + char V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(char) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + } + + .field static assembly char c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .method public specialname static char get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld char assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(char 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld char assembly::c@1 + IL_0006: ret + } + + .method private specialname rtspecialname static void .cctor() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int32 ''.$assembly::init@ + IL_0006: ldsfld int32 ''.$assembly::init@ + IL_000b: pop + IL_000c: ret + } + + .method assembly specialname static void staticInitialization@() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld char assembly::c@1 + IL_0006: ret + } + + .property char c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(char) + .get char assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: call void assembly::staticInitialization@() + IL_0005: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt16.fs.RealInternalSignatureOff.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt16.fs.RealInternalSignatureOff.OptimizeOn.il.bsl new file mode 100644 index 00000000000..a72a2dbb2cc --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt16.fs.RealInternalSignatureOff.OptimizeOn.il.bsl @@ -0,0 +1,686 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Down + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (int16 V_0, + int16 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.1 + IL_0003: stloc.1 + IL_0004: br.s IL_0014 + + IL_0006: ldloc.1 + IL_0007: call void assembly::set_c(int16) + IL_000c: ldloc.1 + IL_000d: ldc.i4.m1 + IL_000e: add + IL_000f: stloc.1 + IL_0010: ldloc.0 + IL_0011: ldc.i4.1 + IL_0012: add + IL_0013: stloc.0 + IL_0014: ldloc.0 + IL_0015: ldc.i4.0 + IL_0016: blt.un.s IL_0006 + + IL_0018: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + int16 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(int16) + IL_000d: ldloc.1 + IL_000e: ldc.i4.m1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.s 10 + IL_0018: blt.un.s IL_0007 + + IL_001a: ret + } + + .method public static void constFinish(int16 start) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldc.i4.1 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void constStart(int16 finish) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldc.i4.s 10 + IL_000b: ldarg.0 + IL_000c: sub + IL_000d: conv.i4 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldc.i4.s 10 + IL_0016: stloc.2 + IL_0017: br.s IL_0027 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(int16) + IL_001f: ldloc.2 + IL_0020: ldc.i4.m1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: add + IL_0026: stloc.1 + IL_0027: ldloc.1 + IL_0028: ldloc.0 + IL_0029: blt.un.s IL_0019 + + IL_002b: ret + } + + .method public static void annotatedStart(int16 start, + int16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldarg.1 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedFinish(int16 start, + int16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldarg.1 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void inferredStartAndFinish(int16 start, + int16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldarg.1 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + } + + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (int16 V_0, + int16 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(int16) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.0 + IL_0017: blt.un.s IL_0007 + + IL_0019: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + int16 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.1 + IL_0003: stloc.1 + IL_0004: br.s IL_0014 + + IL_0006: ldloc.1 + IL_0007: call void assembly::set_c(int16) + IL_000c: ldloc.1 + IL_000d: ldc.i4.1 + IL_000e: add + IL_000f: stloc.1 + IL_0010: ldloc.0 + IL_0011: ldc.i4.1 + IL_0012: add + IL_0013: stloc.0 + IL_0014: ldloc.0 + IL_0015: ldc.i4.s 10 + IL_0017: blt.un.s IL_0006 + + IL_0019: ret + } + + .method public static void constFinish(int16 start) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldc.i4.s 10 + IL_000b: ldarg.0 + IL_000c: sub + IL_000d: conv.i4 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldarg.0 + IL_0015: stloc.2 + IL_0016: br.s IL_0026 + + IL_0018: ldloc.2 + IL_0019: call void assembly::set_c(int16) + IL_001e: ldloc.2 + IL_001f: ldc.i4.1 + IL_0020: add + IL_0021: stloc.2 + IL_0022: ldloc.1 + IL_0023: ldc.i4.1 + IL_0024: add + IL_0025: stloc.1 + IL_0026: ldloc.1 + IL_0027: ldloc.0 + IL_0028: blt.un.s IL_0018 + + IL_002a: ret + } + + .method public static void constStart(int16 finish) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldc.i4.1 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldc.i4.1 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedStart(int16 start, + int16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedFinish(int16 start, + int16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void inferredStartAndFinish(int16 start, + int16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + } + + .method public specialname static int16 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld int16 ''.$assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(int16 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld int16 ''.$assembly::c@1 + IL_0006: ret + } + + .property int16 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(int16) + .get int16 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int16 c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int16 ''.$assembly::c@1 + IL_0006: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt16.fs.RealInternalSignatureOn.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt16.fs.RealInternalSignatureOn.OptimizeOn.il.bsl new file mode 100644 index 00000000000..c5e917f009d --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt16.fs.RealInternalSignatureOn.OptimizeOn.il.bsl @@ -0,0 +1,705 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Down + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (int16 V_0, + int16 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.1 + IL_0003: stloc.1 + IL_0004: br.s IL_0014 + + IL_0006: ldloc.1 + IL_0007: call void assembly::set_c(int16) + IL_000c: ldloc.1 + IL_000d: ldc.i4.m1 + IL_000e: add + IL_000f: stloc.1 + IL_0010: ldloc.0 + IL_0011: ldc.i4.1 + IL_0012: add + IL_0013: stloc.0 + IL_0014: ldloc.0 + IL_0015: ldc.i4.0 + IL_0016: blt.un.s IL_0006 + + IL_0018: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + int16 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(int16) + IL_000d: ldloc.1 + IL_000e: ldc.i4.m1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.s 10 + IL_0018: blt.un.s IL_0007 + + IL_001a: ret + } + + .method public static void constFinish(int16 start) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldc.i4.1 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void constStart(int16 finish) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldc.i4.s 10 + IL_000b: ldarg.0 + IL_000c: sub + IL_000d: conv.i4 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldc.i4.s 10 + IL_0016: stloc.2 + IL_0017: br.s IL_0027 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(int16) + IL_001f: ldloc.2 + IL_0020: ldc.i4.m1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: add + IL_0026: stloc.1 + IL_0027: ldloc.1 + IL_0028: ldloc.0 + IL_0029: blt.un.s IL_0019 + + IL_002b: ret + } + + .method public static void annotatedStart(int16 start, + int16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldarg.1 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedFinish(int16 start, + int16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldarg.1 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void inferredStartAndFinish(int16 start, + int16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldarg.1 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + } + + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (int16 V_0, + int16 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(int16) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.0 + IL_0017: blt.un.s IL_0007 + + IL_0019: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + int16 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.1 + IL_0003: stloc.1 + IL_0004: br.s IL_0014 + + IL_0006: ldloc.1 + IL_0007: call void assembly::set_c(int16) + IL_000c: ldloc.1 + IL_000d: ldc.i4.1 + IL_000e: add + IL_000f: stloc.1 + IL_0010: ldloc.0 + IL_0011: ldc.i4.1 + IL_0012: add + IL_0013: stloc.0 + IL_0014: ldloc.0 + IL_0015: ldc.i4.s 10 + IL_0017: blt.un.s IL_0006 + + IL_0019: ret + } + + .method public static void constFinish(int16 start) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldc.i4.s 10 + IL_000b: ldarg.0 + IL_000c: sub + IL_000d: conv.i4 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldarg.0 + IL_0015: stloc.2 + IL_0016: br.s IL_0026 + + IL_0018: ldloc.2 + IL_0019: call void assembly::set_c(int16) + IL_001e: ldloc.2 + IL_001f: ldc.i4.1 + IL_0020: add + IL_0021: stloc.2 + IL_0022: ldloc.1 + IL_0023: ldc.i4.1 + IL_0024: add + IL_0025: stloc.1 + IL_0026: ldloc.1 + IL_0027: ldloc.0 + IL_0028: blt.un.s IL_0018 + + IL_002a: ret + } + + .method public static void constStart(int16 finish) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldc.i4.1 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldc.i4.1 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedStart(int16 start, + int16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedFinish(int16 start, + int16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void inferredStartAndFinish(int16 start, + int16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + int16 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.i4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + } + + .field static assembly int16 c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .method public specialname static int16 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld int16 assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(int16 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld int16 assembly::c@1 + IL_0006: ret + } + + .method private specialname rtspecialname static void .cctor() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int32 ''.$assembly::init@ + IL_0006: ldsfld int32 ''.$assembly::init@ + IL_000b: pop + IL_000c: ret + } + + .method assembly specialname static void staticInitialization@() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int16 assembly::c@1 + IL_0006: ret + } + + .property int16 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(int16) + .get int16 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: call void assembly::staticInitialization@() + IL_0005: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt32.fs.RealInternalSignatureOff.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt32.fs.RealInternalSignatureOff.OptimizeOn.il.bsl new file mode 100644 index 00000000000..1c068b9ad1e --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt32.fs.RealInternalSignatureOff.OptimizeOn.il.bsl @@ -0,0 +1,692 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Down + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 5 + .locals init (int32 V_0, + int32 V_1) + IL_0000: ldc.i4.1 + IL_0001: stloc.1 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.0 + IL_0005: ldloc.0 + IL_0006: ldloc.1 + IL_0007: bgt.s IL_0019 + + IL_0009: ldloc.1 + IL_000a: call void assembly::set_c(int32) + IL_000f: ldloc.1 + IL_0010: ldc.i4.1 + IL_0011: sub + IL_0012: stloc.1 + IL_0013: ldloc.1 + IL_0014: ldloc.0 + IL_0015: ldc.i4.1 + IL_0016: sub + IL_0017: bne.un.s IL_0009 + + IL_0019: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 5 + .locals init (int32 V_0, + int32 V_1) + IL_0000: ldc.i4.s 10 + IL_0002: stloc.1 + IL_0003: ldc.i4.1 + IL_0004: stloc.0 + IL_0005: ldloc.0 + IL_0006: ldloc.1 + IL_0007: bgt.s IL_0019 + + IL_0009: ldloc.1 + IL_000a: call void assembly::set_c(int32) + IL_000f: ldloc.1 + IL_0010: ldc.i4.1 + IL_0011: sub + IL_0012: stloc.1 + IL_0013: ldloc.1 + IL_0014: ldloc.0 + IL_0015: ldc.i4.1 + IL_0016: sub + IL_0017: bne.un.s IL_0009 + + IL_0019: ret + } + + .method public static void constFinish(int32 start) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int32 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.0 + IL_000a: ldc.i4.1 + IL_000b: sub + IL_000c: conv.i8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(int32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.m1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + .method public static void constStart(int32 finish) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int32 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.s IL_000a + + IL_0005: ldc.i4.0 + IL_0006: conv.i8 + IL_0007: nop + IL_0008: br.s IL_0013 + + IL_000a: ldc.i4.s 10 + IL_000c: ldarg.0 + IL_000d: sub + IL_000e: conv.i8 + IL_000f: ldc.i4.1 + IL_0010: conv.i8 + IL_0011: add + IL_0012: nop + IL_0013: stloc.0 + IL_0014: ldc.i4.0 + IL_0015: conv.i8 + IL_0016: stloc.1 + IL_0017: ldc.i4.s 10 + IL_0019: stloc.2 + IL_001a: br.s IL_002b + + IL_001c: ldloc.2 + IL_001d: call void assembly::set_c(int32) + IL_0022: ldloc.2 + IL_0023: ldc.i4.m1 + IL_0024: add + IL_0025: stloc.2 + IL_0026: ldloc.1 + IL_0027: ldc.i4.1 + IL_0028: conv.i8 + IL_0029: add + IL_002a: stloc.1 + IL_002b: ldloc.1 + IL_002c: ldloc.0 + IL_002d: blt.un.s IL_001c + + IL_002f: ret + } + + .method public static void annotatedStart(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int32 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.0 + IL_000a: ldarg.1 + IL_000b: sub + IL_000c: conv.i8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(int32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.m1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + .method public static void annotatedFinish(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int32 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.0 + IL_000a: ldarg.1 + IL_000b: sub + IL_000c: conv.i8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(int32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.m1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + .method public static void inferredStartAndFinish(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int32 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.0 + IL_000a: ldarg.1 + IL_000b: sub + IL_000c: conv.i8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(int32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.m1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + .method public static void unconstrainedStartAndFinish(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int32 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.0 + IL_000a: ldarg.1 + IL_000b: sub + IL_000c: conv.i8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0029 + + IL_0019: ldloc.2 + IL_001a: call void assembly::f(!!0) + IL_001f: nop + IL_0020: ldloc.2 + IL_0021: ldc.i4.m1 + IL_0022: add + IL_0023: stloc.2 + IL_0024: ldloc.1 + IL_0025: ldc.i4.1 + IL_0026: conv.i8 + IL_0027: add + IL_0028: stloc.1 + IL_0029: ldloc.1 + IL_002a: ldloc.0 + IL_002b: blt.un.s IL_0019 + + IL_002d: ret + } + + } + + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (int32 V_0) + IL_0000: ldc.i4.s 10 + IL_0002: stloc.0 + IL_0003: br.s IL_000f + + IL_0005: ldloc.0 + IL_0006: call void assembly::set_c(int32) + IL_000b: ldloc.0 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: stloc.0 + IL_000f: ldloc.0 + IL_0010: ldc.i4.2 + IL_0011: blt.s IL_0005 + + IL_0013: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (int32 V_0) + IL_0000: ldc.i4.1 + IL_0001: stloc.0 + IL_0002: br.s IL_000e + + IL_0004: ldloc.0 + IL_0005: call void assembly::set_c(int32) + IL_000a: ldloc.0 + IL_000b: ldc.i4.1 + IL_000c: add + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.s 11 + IL_0011: blt.s IL_0004 + + IL_0013: ret + } + + .method public static void constFinish(int32 start) cil managed + { + + .maxstack 4 + .locals init (int32 V_0) + IL_0000: ldarg.0 + IL_0001: stloc.0 + IL_0002: br.s IL_000e + + IL_0004: ldloc.0 + IL_0005: call void assembly::set_c(int32) + IL_000a: ldloc.0 + IL_000b: ldc.i4.1 + IL_000c: add + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.s 11 + IL_0011: blt.s IL_0004 + + IL_0013: ret + } + + .method public static void constStart(int32 finish) cil managed + { + + .maxstack 5 + .locals init (int32 V_0, + int32 V_1) + IL_0000: ldc.i4.1 + IL_0001: stloc.1 + IL_0002: ldarg.0 + IL_0003: stloc.0 + IL_0004: ldloc.0 + IL_0005: ldloc.1 + IL_0006: blt.s IL_0018 + + IL_0008: ldloc.1 + IL_0009: call void assembly::set_c(int32) + IL_000e: ldloc.1 + IL_000f: ldc.i4.1 + IL_0010: add + IL_0011: stloc.1 + IL_0012: ldloc.1 + IL_0013: ldloc.0 + IL_0014: ldc.i4.1 + IL_0015: add + IL_0016: bne.un.s IL_0008 + + IL_0018: ret + } + + .method public static void annotatedStart(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 5 + .locals init (int32 V_0, + int32 V_1) + IL_0000: ldarg.0 + IL_0001: stloc.1 + IL_0002: ldarg.1 + IL_0003: stloc.0 + IL_0004: ldloc.0 + IL_0005: ldloc.1 + IL_0006: blt.s IL_0018 + + IL_0008: ldloc.1 + IL_0009: call void assembly::set_c(int32) + IL_000e: ldloc.1 + IL_000f: ldc.i4.1 + IL_0010: add + IL_0011: stloc.1 + IL_0012: ldloc.1 + IL_0013: ldloc.0 + IL_0014: ldc.i4.1 + IL_0015: add + IL_0016: bne.un.s IL_0008 + + IL_0018: ret + } + + .method public static void annotatedFinish(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 5 + .locals init (int32 V_0, + int32 V_1) + IL_0000: ldarg.0 + IL_0001: stloc.1 + IL_0002: ldarg.1 + IL_0003: stloc.0 + IL_0004: ldloc.0 + IL_0005: ldloc.1 + IL_0006: blt.s IL_0018 + + IL_0008: ldloc.1 + IL_0009: call void assembly::set_c(int32) + IL_000e: ldloc.1 + IL_000f: ldc.i4.1 + IL_0010: add + IL_0011: stloc.1 + IL_0012: ldloc.1 + IL_0013: ldloc.0 + IL_0014: ldc.i4.1 + IL_0015: add + IL_0016: bne.un.s IL_0008 + + IL_0018: ret + } + + .method public static void inferredStartAndFinish(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 5 + .locals init (int32 V_0, + int32 V_1) + IL_0000: ldarg.0 + IL_0001: stloc.1 + IL_0002: ldarg.1 + IL_0003: stloc.0 + IL_0004: ldloc.0 + IL_0005: ldloc.1 + IL_0006: blt.s IL_0018 + + IL_0008: ldloc.1 + IL_0009: call void assembly::set_c(int32) + IL_000e: ldloc.1 + IL_000f: ldc.i4.1 + IL_0010: add + IL_0011: stloc.1 + IL_0012: ldloc.1 + IL_0013: ldloc.0 + IL_0014: ldc.i4.1 + IL_0015: add + IL_0016: bne.un.s IL_0008 + + IL_0018: ret + } + + .method public static void unconstrainedStartAndFinish(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 5 + .locals init (int32 V_0, + int32 V_1) + IL_0000: ldarg.0 + IL_0001: stloc.1 + IL_0002: ldarg.1 + IL_0003: stloc.0 + IL_0004: ldloc.0 + IL_0005: ldloc.1 + IL_0006: blt.s IL_0019 + + IL_0008: ldloc.1 + IL_0009: call void assembly::f(!!0) + IL_000e: nop + IL_000f: ldloc.1 + IL_0010: ldc.i4.1 + IL_0011: add + IL_0012: stloc.1 + IL_0013: ldloc.1 + IL_0014: ldloc.0 + IL_0015: ldc.i4.1 + IL_0016: add + IL_0017: bne.un.s IL_0008 + + IL_0019: ret + } + + } + + .method public specialname static int32 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld int32 ''.$assembly::c@3 + IL_0005: ret + } + + .method public specialname static void set_c(int32 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld int32 ''.$assembly::c@3 + IL_0006: ret + } + + .method public static void f(!!a x) cil managed noinlining + { + + .maxstack 8 + IL_0000: ret + } + + .property int32 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(int32) + .get int32 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int32 c@3 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int32 ''.$assembly::c@3 + IL_0006: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt32.fs.RealInternalSignatureOn.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt32.fs.RealInternalSignatureOn.OptimizeOn.il.bsl new file mode 100644 index 00000000000..3e4817c7109 --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt32.fs.RealInternalSignatureOn.OptimizeOn.il.bsl @@ -0,0 +1,711 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Down + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 5 + .locals init (int32 V_0, + int32 V_1) + IL_0000: ldc.i4.1 + IL_0001: stloc.1 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.0 + IL_0005: ldloc.0 + IL_0006: ldloc.1 + IL_0007: bgt.s IL_0019 + + IL_0009: ldloc.1 + IL_000a: call void assembly::set_c(int32) + IL_000f: ldloc.1 + IL_0010: ldc.i4.1 + IL_0011: sub + IL_0012: stloc.1 + IL_0013: ldloc.1 + IL_0014: ldloc.0 + IL_0015: ldc.i4.1 + IL_0016: sub + IL_0017: bne.un.s IL_0009 + + IL_0019: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 5 + .locals init (int32 V_0, + int32 V_1) + IL_0000: ldc.i4.s 10 + IL_0002: stloc.1 + IL_0003: ldc.i4.1 + IL_0004: stloc.0 + IL_0005: ldloc.0 + IL_0006: ldloc.1 + IL_0007: bgt.s IL_0019 + + IL_0009: ldloc.1 + IL_000a: call void assembly::set_c(int32) + IL_000f: ldloc.1 + IL_0010: ldc.i4.1 + IL_0011: sub + IL_0012: stloc.1 + IL_0013: ldloc.1 + IL_0014: ldloc.0 + IL_0015: ldc.i4.1 + IL_0016: sub + IL_0017: bne.un.s IL_0009 + + IL_0019: ret + } + + .method public static void constFinish(int32 start) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int32 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.0 + IL_000a: ldc.i4.1 + IL_000b: sub + IL_000c: conv.i8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(int32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.m1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + .method public static void constStart(int32 finish) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int32 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.s IL_000a + + IL_0005: ldc.i4.0 + IL_0006: conv.i8 + IL_0007: nop + IL_0008: br.s IL_0013 + + IL_000a: ldc.i4.s 10 + IL_000c: ldarg.0 + IL_000d: sub + IL_000e: conv.i8 + IL_000f: ldc.i4.1 + IL_0010: conv.i8 + IL_0011: add + IL_0012: nop + IL_0013: stloc.0 + IL_0014: ldc.i4.0 + IL_0015: conv.i8 + IL_0016: stloc.1 + IL_0017: ldc.i4.s 10 + IL_0019: stloc.2 + IL_001a: br.s IL_002b + + IL_001c: ldloc.2 + IL_001d: call void assembly::set_c(int32) + IL_0022: ldloc.2 + IL_0023: ldc.i4.m1 + IL_0024: add + IL_0025: stloc.2 + IL_0026: ldloc.1 + IL_0027: ldc.i4.1 + IL_0028: conv.i8 + IL_0029: add + IL_002a: stloc.1 + IL_002b: ldloc.1 + IL_002c: ldloc.0 + IL_002d: blt.un.s IL_001c + + IL_002f: ret + } + + .method public static void annotatedStart(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int32 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.0 + IL_000a: ldarg.1 + IL_000b: sub + IL_000c: conv.i8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(int32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.m1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + .method public static void annotatedFinish(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int32 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.0 + IL_000a: ldarg.1 + IL_000b: sub + IL_000c: conv.i8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(int32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.m1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + .method public static void inferredStartAndFinish(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int32 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.0 + IL_000a: ldarg.1 + IL_000b: sub + IL_000c: conv.i8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(int32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.m1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + .method public static void unconstrainedStartAndFinish(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int32 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.0 + IL_000a: ldarg.1 + IL_000b: sub + IL_000c: conv.i8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0029 + + IL_0019: ldloc.2 + IL_001a: call void assembly::f(!!0) + IL_001f: nop + IL_0020: ldloc.2 + IL_0021: ldc.i4.m1 + IL_0022: add + IL_0023: stloc.2 + IL_0024: ldloc.1 + IL_0025: ldc.i4.1 + IL_0026: conv.i8 + IL_0027: add + IL_0028: stloc.1 + IL_0029: ldloc.1 + IL_002a: ldloc.0 + IL_002b: blt.un.s IL_0019 + + IL_002d: ret + } + + } + + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (int32 V_0) + IL_0000: ldc.i4.s 10 + IL_0002: stloc.0 + IL_0003: br.s IL_000f + + IL_0005: ldloc.0 + IL_0006: call void assembly::set_c(int32) + IL_000b: ldloc.0 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: stloc.0 + IL_000f: ldloc.0 + IL_0010: ldc.i4.2 + IL_0011: blt.s IL_0005 + + IL_0013: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (int32 V_0) + IL_0000: ldc.i4.1 + IL_0001: stloc.0 + IL_0002: br.s IL_000e + + IL_0004: ldloc.0 + IL_0005: call void assembly::set_c(int32) + IL_000a: ldloc.0 + IL_000b: ldc.i4.1 + IL_000c: add + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.s 11 + IL_0011: blt.s IL_0004 + + IL_0013: ret + } + + .method public static void constFinish(int32 start) cil managed + { + + .maxstack 4 + .locals init (int32 V_0) + IL_0000: ldarg.0 + IL_0001: stloc.0 + IL_0002: br.s IL_000e + + IL_0004: ldloc.0 + IL_0005: call void assembly::set_c(int32) + IL_000a: ldloc.0 + IL_000b: ldc.i4.1 + IL_000c: add + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.s 11 + IL_0011: blt.s IL_0004 + + IL_0013: ret + } + + .method public static void constStart(int32 finish) cil managed + { + + .maxstack 5 + .locals init (int32 V_0, + int32 V_1) + IL_0000: ldc.i4.1 + IL_0001: stloc.1 + IL_0002: ldarg.0 + IL_0003: stloc.0 + IL_0004: ldloc.0 + IL_0005: ldloc.1 + IL_0006: blt.s IL_0018 + + IL_0008: ldloc.1 + IL_0009: call void assembly::set_c(int32) + IL_000e: ldloc.1 + IL_000f: ldc.i4.1 + IL_0010: add + IL_0011: stloc.1 + IL_0012: ldloc.1 + IL_0013: ldloc.0 + IL_0014: ldc.i4.1 + IL_0015: add + IL_0016: bne.un.s IL_0008 + + IL_0018: ret + } + + .method public static void annotatedStart(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 5 + .locals init (int32 V_0, + int32 V_1) + IL_0000: ldarg.0 + IL_0001: stloc.1 + IL_0002: ldarg.1 + IL_0003: stloc.0 + IL_0004: ldloc.0 + IL_0005: ldloc.1 + IL_0006: blt.s IL_0018 + + IL_0008: ldloc.1 + IL_0009: call void assembly::set_c(int32) + IL_000e: ldloc.1 + IL_000f: ldc.i4.1 + IL_0010: add + IL_0011: stloc.1 + IL_0012: ldloc.1 + IL_0013: ldloc.0 + IL_0014: ldc.i4.1 + IL_0015: add + IL_0016: bne.un.s IL_0008 + + IL_0018: ret + } + + .method public static void annotatedFinish(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 5 + .locals init (int32 V_0, + int32 V_1) + IL_0000: ldarg.0 + IL_0001: stloc.1 + IL_0002: ldarg.1 + IL_0003: stloc.0 + IL_0004: ldloc.0 + IL_0005: ldloc.1 + IL_0006: blt.s IL_0018 + + IL_0008: ldloc.1 + IL_0009: call void assembly::set_c(int32) + IL_000e: ldloc.1 + IL_000f: ldc.i4.1 + IL_0010: add + IL_0011: stloc.1 + IL_0012: ldloc.1 + IL_0013: ldloc.0 + IL_0014: ldc.i4.1 + IL_0015: add + IL_0016: bne.un.s IL_0008 + + IL_0018: ret + } + + .method public static void inferredStartAndFinish(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 5 + .locals init (int32 V_0, + int32 V_1) + IL_0000: ldarg.0 + IL_0001: stloc.1 + IL_0002: ldarg.1 + IL_0003: stloc.0 + IL_0004: ldloc.0 + IL_0005: ldloc.1 + IL_0006: blt.s IL_0018 + + IL_0008: ldloc.1 + IL_0009: call void assembly::set_c(int32) + IL_000e: ldloc.1 + IL_000f: ldc.i4.1 + IL_0010: add + IL_0011: stloc.1 + IL_0012: ldloc.1 + IL_0013: ldloc.0 + IL_0014: ldc.i4.1 + IL_0015: add + IL_0016: bne.un.s IL_0008 + + IL_0018: ret + } + + .method public static void unconstrainedStartAndFinish(int32 start, + int32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 5 + .locals init (int32 V_0, + int32 V_1) + IL_0000: ldarg.0 + IL_0001: stloc.1 + IL_0002: ldarg.1 + IL_0003: stloc.0 + IL_0004: ldloc.0 + IL_0005: ldloc.1 + IL_0006: blt.s IL_0019 + + IL_0008: ldloc.1 + IL_0009: call void assembly::f(!!0) + IL_000e: nop + IL_000f: ldloc.1 + IL_0010: ldc.i4.1 + IL_0011: add + IL_0012: stloc.1 + IL_0013: ldloc.1 + IL_0014: ldloc.0 + IL_0015: ldc.i4.1 + IL_0016: add + IL_0017: bne.un.s IL_0008 + + IL_0019: ret + } + + } + + .field static assembly int32 c@3 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .method public specialname static int32 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld int32 assembly::c@3 + IL_0005: ret + } + + .method public specialname static void set_c(int32 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld int32 assembly::c@3 + IL_0006: ret + } + + .method public static void f(!!a x) cil managed noinlining + { + + .maxstack 8 + IL_0000: ret + } + + .method private specialname rtspecialname static void .cctor() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int32 ''.$assembly::init@ + IL_0006: ldsfld int32 ''.$assembly::init@ + IL_000b: pop + IL_000c: ret + } + + .method assembly specialname static void staticInitialization@() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int32 assembly::c@3 + IL_0006: ret + } + + .property int32 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(int32) + .get int32 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: call void assembly::staticInitialization@() + IL_0005: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt64.fs.RealInternalSignatureOff.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt64.fs.RealInternalSignatureOff.OptimizeOn.il.bsl new file mode 100644 index 00000000000..a1f779b598d --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt64.fs.RealInternalSignatureOff.OptimizeOn.il.bsl @@ -0,0 +1,1069 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Down + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (int64 V_0, + int64 V_1) + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stloc.0 + IL_0003: ldc.i4.1 + IL_0004: conv.i8 + IL_0005: stloc.1 + IL_0006: br.s IL_0018 + + IL_0008: ldloc.1 + IL_0009: call void assembly::set_c(int64) + IL_000e: ldloc.1 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: add + IL_0012: stloc.1 + IL_0013: ldloc.0 + IL_0014: ldc.i4.1 + IL_0015: conv.i8 + IL_0016: add + IL_0017: stloc.0 + IL_0018: ldloc.0 + IL_0019: ldc.i4.0 + IL_001a: conv.i8 + IL_001b: blt.un.s IL_0008 + + IL_001d: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + int64 V_1) + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stloc.0 + IL_0003: ldc.i4.s 10 + IL_0005: conv.i8 + IL_0006: stloc.1 + IL_0007: br.s IL_0019 + + IL_0009: ldloc.1 + IL_000a: call void assembly::set_c(int64) + IL_000f: ldloc.1 + IL_0010: ldc.i4.m1 + IL_0011: conv.i8 + IL_0012: add + IL_0013: stloc.1 + IL_0014: ldloc.0 + IL_0015: ldc.i4.1 + IL_0016: conv.i8 + IL_0017: add + IL_0018: stloc.0 + IL_0019: ldloc.0 + IL_001a: ldc.i4.s 10 + IL_001c: conv.i8 + IL_001d: blt.un.s IL_0009 + + IL_001f: ret + } + + .method public static void constFinish(int64 start) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int64 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: conv.i8 + IL_0003: bge.s IL_000a + + IL_0005: ldc.i4.0 + IL_0006: conv.i8 + IL_0007: nop + IL_0008: br.s IL_0012 + + IL_000a: ldarg.0 + IL_000b: ldc.i4.1 + IL_000c: conv.i8 + IL_000d: sub + IL_000e: ldc.i4.1 + IL_000f: conv.i8 + IL_0010: add.ovf.un + IL_0011: nop + IL_0012: stloc.0 + IL_0013: ldc.i4.0 + IL_0014: conv.i8 + IL_0015: stloc.1 + IL_0016: ldarg.0 + IL_0017: stloc.2 + IL_0018: br.s IL_002a + + IL_001a: ldloc.2 + IL_001b: call void assembly::set_c(int64) + IL_0020: ldloc.2 + IL_0021: ldc.i4.m1 + IL_0022: conv.i8 + IL_0023: add + IL_0024: stloc.2 + IL_0025: ldloc.1 + IL_0026: ldc.i4.1 + IL_0027: conv.i8 + IL_0028: add + IL_0029: stloc.1 + IL_002a: ldloc.1 + IL_002b: ldloc.0 + IL_002c: blt.un.s IL_001a + + IL_002e: ret + } + + .method public static void constStart(int64 finish) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int64 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: conv.i8 + IL_0003: ldarg.0 + IL_0004: bge.s IL_000b + + IL_0006: ldc.i4.0 + IL_0007: conv.i8 + IL_0008: nop + IL_0009: br.s IL_0014 + + IL_000b: ldc.i4.s 10 + IL_000d: conv.i8 + IL_000e: ldarg.0 + IL_000f: sub + IL_0010: ldc.i4.1 + IL_0011: conv.i8 + IL_0012: add.ovf.un + IL_0013: nop + IL_0014: stloc.0 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.1 + IL_0018: ldc.i4.s 10 + IL_001a: conv.i8 + IL_001b: stloc.2 + IL_001c: br.s IL_002e + + IL_001e: ldloc.2 + IL_001f: call void assembly::set_c(int64) + IL_0024: ldloc.2 + IL_0025: ldc.i4.m1 + IL_0026: conv.i8 + IL_0027: add + IL_0028: stloc.2 + IL_0029: ldloc.1 + IL_002a: ldc.i4.1 + IL_002b: conv.i8 + IL_002c: add + IL_002d: stloc.1 + IL_002e: ldloc.1 + IL_002f: ldloc.0 + IL_0030: blt.un.s IL_001e + + IL_0032: ret + } + + .method public static void annotatedStart(int64 start, + int64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + int64 V_3, + uint64 V_4) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.0 + IL_000a: ldarg.1 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(int64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.m1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.0 + IL_0037: ldarg.1 + IL_0038: bge.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.0 + IL_0040: ldarg.1 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.s V_4 + IL_004b: ldarg.0 + IL_004c: stloc.3 + IL_004d: br.s IL_0061 + + IL_004f: ldloc.3 + IL_0050: call void assembly::set_c(int64) + IL_0055: ldloc.3 + IL_0056: ldc.i4.m1 + IL_0057: conv.i8 + IL_0058: add + IL_0059: stloc.3 + IL_005a: ldloc.s V_4 + IL_005c: ldc.i4.1 + IL_005d: conv.i8 + IL_005e: add + IL_005f: stloc.s V_4 + IL_0061: ldloc.s V_4 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + .method public static void annotatedFinish(int64 start, + int64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + int64 V_3, + uint64 V_4) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.0 + IL_000a: ldarg.1 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(int64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.m1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.0 + IL_0037: ldarg.1 + IL_0038: bge.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.0 + IL_0040: ldarg.1 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.s V_4 + IL_004b: ldarg.0 + IL_004c: stloc.3 + IL_004d: br.s IL_0061 + + IL_004f: ldloc.3 + IL_0050: call void assembly::set_c(int64) + IL_0055: ldloc.3 + IL_0056: ldc.i4.m1 + IL_0057: conv.i8 + IL_0058: add + IL_0059: stloc.3 + IL_005a: ldloc.s V_4 + IL_005c: ldc.i4.1 + IL_005d: conv.i8 + IL_005e: add + IL_005f: stloc.s V_4 + IL_0061: ldloc.s V_4 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + .method public static void inferredStartAndFinish(int64 start, + int64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + int64 V_3, + uint64 V_4) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.0 + IL_000a: ldarg.1 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(int64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.m1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.0 + IL_0037: ldarg.1 + IL_0038: bge.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.0 + IL_0040: ldarg.1 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.s V_4 + IL_004b: ldarg.0 + IL_004c: stloc.3 + IL_004d: br.s IL_0061 + + IL_004f: ldloc.3 + IL_0050: call void assembly::set_c(int64) + IL_0055: ldloc.3 + IL_0056: ldc.i4.m1 + IL_0057: conv.i8 + IL_0058: add + IL_0059: stloc.3 + IL_005a: ldloc.s V_4 + IL_005c: ldc.i4.1 + IL_005d: conv.i8 + IL_005e: add + IL_005f: stloc.s V_4 + IL_0061: ldloc.s V_4 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + } + + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (int64 V_0, + int64 V_1) + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stloc.0 + IL_0003: ldc.i4.s 10 + IL_0005: conv.i8 + IL_0006: stloc.1 + IL_0007: br.s IL_0019 + + IL_0009: ldloc.1 + IL_000a: call void assembly::set_c(int64) + IL_000f: ldloc.1 + IL_0010: ldc.i4.1 + IL_0011: conv.i8 + IL_0012: add + IL_0013: stloc.1 + IL_0014: ldloc.0 + IL_0015: ldc.i4.1 + IL_0016: conv.i8 + IL_0017: add + IL_0018: stloc.0 + IL_0019: ldloc.0 + IL_001a: ldc.i4.0 + IL_001b: conv.i8 + IL_001c: blt.un.s IL_0009 + + IL_001e: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + int64 V_1) + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stloc.0 + IL_0003: ldc.i4.1 + IL_0004: conv.i8 + IL_0005: stloc.1 + IL_0006: br.s IL_0018 + + IL_0008: ldloc.1 + IL_0009: call void assembly::set_c(int64) + IL_000e: ldloc.1 + IL_000f: ldc.i4.1 + IL_0010: conv.i8 + IL_0011: add + IL_0012: stloc.1 + IL_0013: ldloc.0 + IL_0014: ldc.i4.1 + IL_0015: conv.i8 + IL_0016: add + IL_0017: stloc.0 + IL_0018: ldloc.0 + IL_0019: ldc.i4.s 10 + IL_001b: conv.i8 + IL_001c: blt.un.s IL_0008 + + IL_001e: ret + } + + .method public static void constFinish(int64 start) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int64 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: conv.i8 + IL_0003: ldarg.0 + IL_0004: bge.s IL_000b + + IL_0006: ldc.i4.0 + IL_0007: conv.i8 + IL_0008: nop + IL_0009: br.s IL_0014 + + IL_000b: ldc.i4.s 10 + IL_000d: conv.i8 + IL_000e: ldarg.0 + IL_000f: sub + IL_0010: ldc.i4.1 + IL_0011: conv.i8 + IL_0012: add.ovf.un + IL_0013: nop + IL_0014: stloc.0 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.1 + IL_0018: ldarg.0 + IL_0019: stloc.2 + IL_001a: br.s IL_002c + + IL_001c: ldloc.2 + IL_001d: call void assembly::set_c(int64) + IL_0022: ldloc.2 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.2 + IL_0027: ldloc.1 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.1 + IL_002c: ldloc.1 + IL_002d: ldloc.0 + IL_002e: blt.un.s IL_001c + + IL_0030: ret + } + + .method public static void constStart(int64 finish) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int64 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: conv.i8 + IL_0003: bge.s IL_000a + + IL_0005: ldc.i4.0 + IL_0006: conv.i8 + IL_0007: nop + IL_0008: br.s IL_0012 + + IL_000a: ldarg.0 + IL_000b: ldc.i4.1 + IL_000c: conv.i8 + IL_000d: sub + IL_000e: ldc.i4.1 + IL_000f: conv.i8 + IL_0010: add.ovf.un + IL_0011: nop + IL_0012: stloc.0 + IL_0013: ldc.i4.0 + IL_0014: conv.i8 + IL_0015: stloc.1 + IL_0016: ldc.i4.1 + IL_0017: conv.i8 + IL_0018: stloc.2 + IL_0019: br.s IL_002b + + IL_001b: ldloc.2 + IL_001c: call void assembly::set_c(int64) + IL_0021: ldloc.2 + IL_0022: ldc.i4.1 + IL_0023: conv.i8 + IL_0024: add + IL_0025: stloc.2 + IL_0026: ldloc.1 + IL_0027: ldc.i4.1 + IL_0028: conv.i8 + IL_0029: add + IL_002a: stloc.1 + IL_002b: ldloc.1 + IL_002c: ldloc.0 + IL_002d: blt.un.s IL_001b + + IL_002f: ret + } + + .method public static void annotatedStart(int64 start, + int64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + int64 V_3, + uint64 V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(int64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.1 + IL_0037: ldarg.0 + IL_0038: bge.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.1 + IL_0040: ldarg.0 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.s V_4 + IL_004b: ldarg.0 + IL_004c: stloc.3 + IL_004d: br.s IL_0061 + + IL_004f: ldloc.3 + IL_0050: call void assembly::set_c(int64) + IL_0055: ldloc.3 + IL_0056: ldc.i4.1 + IL_0057: conv.i8 + IL_0058: add + IL_0059: stloc.3 + IL_005a: ldloc.s V_4 + IL_005c: ldc.i4.1 + IL_005d: conv.i8 + IL_005e: add + IL_005f: stloc.s V_4 + IL_0061: ldloc.s V_4 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + .method public static void annotatedFinish(int64 start, + int64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + int64 V_3, + uint64 V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(int64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.1 + IL_0037: ldarg.0 + IL_0038: bge.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.1 + IL_0040: ldarg.0 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.s V_4 + IL_004b: ldarg.0 + IL_004c: stloc.3 + IL_004d: br.s IL_0061 + + IL_004f: ldloc.3 + IL_0050: call void assembly::set_c(int64) + IL_0055: ldloc.3 + IL_0056: ldc.i4.1 + IL_0057: conv.i8 + IL_0058: add + IL_0059: stloc.3 + IL_005a: ldloc.s V_4 + IL_005c: ldc.i4.1 + IL_005d: conv.i8 + IL_005e: add + IL_005f: stloc.s V_4 + IL_0061: ldloc.s V_4 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + .method public static void inferredStartAndFinish(int64 start, + int64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + int64 V_3, + uint64 V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(int64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.1 + IL_0037: ldarg.0 + IL_0038: bge.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.1 + IL_0040: ldarg.0 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.s V_4 + IL_004b: ldarg.0 + IL_004c: stloc.3 + IL_004d: br.s IL_0061 + + IL_004f: ldloc.3 + IL_0050: call void assembly::set_c(int64) + IL_0055: ldloc.3 + IL_0056: ldc.i4.1 + IL_0057: conv.i8 + IL_0058: add + IL_0059: stloc.3 + IL_005a: ldloc.s V_4 + IL_005c: ldc.i4.1 + IL_005d: conv.i8 + IL_005e: add + IL_005f: stloc.s V_4 + IL_0061: ldloc.s V_4 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + } + + .method public specialname static int64 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld int64 ''.$assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(int64 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld int64 ''.$assembly::c@1 + IL_0006: ret + } + + .property int64 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(int64) + .get int64 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int64 c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stsfld int64 ''.$assembly::c@1 + IL_0007: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt64.fs.RealInternalSignatureOn.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt64.fs.RealInternalSignatureOn.OptimizeOn.il.bsl new file mode 100644 index 00000000000..f134b547366 --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopInt64.fs.RealInternalSignatureOn.OptimizeOn.il.bsl @@ -0,0 +1,1088 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Down + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (int64 V_0, + int64 V_1) + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stloc.0 + IL_0003: ldc.i4.1 + IL_0004: conv.i8 + IL_0005: stloc.1 + IL_0006: br.s IL_0018 + + IL_0008: ldloc.1 + IL_0009: call void assembly::set_c(int64) + IL_000e: ldloc.1 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: add + IL_0012: stloc.1 + IL_0013: ldloc.0 + IL_0014: ldc.i4.1 + IL_0015: conv.i8 + IL_0016: add + IL_0017: stloc.0 + IL_0018: ldloc.0 + IL_0019: ldc.i4.0 + IL_001a: conv.i8 + IL_001b: blt.un.s IL_0008 + + IL_001d: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + int64 V_1) + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stloc.0 + IL_0003: ldc.i4.s 10 + IL_0005: conv.i8 + IL_0006: stloc.1 + IL_0007: br.s IL_0019 + + IL_0009: ldloc.1 + IL_000a: call void assembly::set_c(int64) + IL_000f: ldloc.1 + IL_0010: ldc.i4.m1 + IL_0011: conv.i8 + IL_0012: add + IL_0013: stloc.1 + IL_0014: ldloc.0 + IL_0015: ldc.i4.1 + IL_0016: conv.i8 + IL_0017: add + IL_0018: stloc.0 + IL_0019: ldloc.0 + IL_001a: ldc.i4.s 10 + IL_001c: conv.i8 + IL_001d: blt.un.s IL_0009 + + IL_001f: ret + } + + .method public static void constFinish(int64 start) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int64 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: conv.i8 + IL_0003: bge.s IL_000a + + IL_0005: ldc.i4.0 + IL_0006: conv.i8 + IL_0007: nop + IL_0008: br.s IL_0012 + + IL_000a: ldarg.0 + IL_000b: ldc.i4.1 + IL_000c: conv.i8 + IL_000d: sub + IL_000e: ldc.i4.1 + IL_000f: conv.i8 + IL_0010: add.ovf.un + IL_0011: nop + IL_0012: stloc.0 + IL_0013: ldc.i4.0 + IL_0014: conv.i8 + IL_0015: stloc.1 + IL_0016: ldarg.0 + IL_0017: stloc.2 + IL_0018: br.s IL_002a + + IL_001a: ldloc.2 + IL_001b: call void assembly::set_c(int64) + IL_0020: ldloc.2 + IL_0021: ldc.i4.m1 + IL_0022: conv.i8 + IL_0023: add + IL_0024: stloc.2 + IL_0025: ldloc.1 + IL_0026: ldc.i4.1 + IL_0027: conv.i8 + IL_0028: add + IL_0029: stloc.1 + IL_002a: ldloc.1 + IL_002b: ldloc.0 + IL_002c: blt.un.s IL_001a + + IL_002e: ret + } + + .method public static void constStart(int64 finish) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int64 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: conv.i8 + IL_0003: ldarg.0 + IL_0004: bge.s IL_000b + + IL_0006: ldc.i4.0 + IL_0007: conv.i8 + IL_0008: nop + IL_0009: br.s IL_0014 + + IL_000b: ldc.i4.s 10 + IL_000d: conv.i8 + IL_000e: ldarg.0 + IL_000f: sub + IL_0010: ldc.i4.1 + IL_0011: conv.i8 + IL_0012: add.ovf.un + IL_0013: nop + IL_0014: stloc.0 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.1 + IL_0018: ldc.i4.s 10 + IL_001a: conv.i8 + IL_001b: stloc.2 + IL_001c: br.s IL_002e + + IL_001e: ldloc.2 + IL_001f: call void assembly::set_c(int64) + IL_0024: ldloc.2 + IL_0025: ldc.i4.m1 + IL_0026: conv.i8 + IL_0027: add + IL_0028: stloc.2 + IL_0029: ldloc.1 + IL_002a: ldc.i4.1 + IL_002b: conv.i8 + IL_002c: add + IL_002d: stloc.1 + IL_002e: ldloc.1 + IL_002f: ldloc.0 + IL_0030: blt.un.s IL_001e + + IL_0032: ret + } + + .method public static void annotatedStart(int64 start, + int64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + int64 V_3, + uint64 V_4) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.0 + IL_000a: ldarg.1 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(int64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.m1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.0 + IL_0037: ldarg.1 + IL_0038: bge.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.0 + IL_0040: ldarg.1 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.s V_4 + IL_004b: ldarg.0 + IL_004c: stloc.3 + IL_004d: br.s IL_0061 + + IL_004f: ldloc.3 + IL_0050: call void assembly::set_c(int64) + IL_0055: ldloc.3 + IL_0056: ldc.i4.m1 + IL_0057: conv.i8 + IL_0058: add + IL_0059: stloc.3 + IL_005a: ldloc.s V_4 + IL_005c: ldc.i4.1 + IL_005d: conv.i8 + IL_005e: add + IL_005f: stloc.s V_4 + IL_0061: ldloc.s V_4 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + .method public static void annotatedFinish(int64 start, + int64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + int64 V_3, + uint64 V_4) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.0 + IL_000a: ldarg.1 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(int64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.m1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.0 + IL_0037: ldarg.1 + IL_0038: bge.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.0 + IL_0040: ldarg.1 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.s V_4 + IL_004b: ldarg.0 + IL_004c: stloc.3 + IL_004d: br.s IL_0061 + + IL_004f: ldloc.3 + IL_0050: call void assembly::set_c(int64) + IL_0055: ldloc.3 + IL_0056: ldc.i4.m1 + IL_0057: conv.i8 + IL_0058: add + IL_0059: stloc.3 + IL_005a: ldloc.s V_4 + IL_005c: ldc.i4.1 + IL_005d: conv.i8 + IL_005e: add + IL_005f: stloc.s V_4 + IL_0061: ldloc.s V_4 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + .method public static void inferredStartAndFinish(int64 start, + int64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + int64 V_3, + uint64 V_4) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.0 + IL_000a: ldarg.1 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(int64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.m1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.0 + IL_0037: ldarg.1 + IL_0038: bge.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.0 + IL_0040: ldarg.1 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.s V_4 + IL_004b: ldarg.0 + IL_004c: stloc.3 + IL_004d: br.s IL_0061 + + IL_004f: ldloc.3 + IL_0050: call void assembly::set_c(int64) + IL_0055: ldloc.3 + IL_0056: ldc.i4.m1 + IL_0057: conv.i8 + IL_0058: add + IL_0059: stloc.3 + IL_005a: ldloc.s V_4 + IL_005c: ldc.i4.1 + IL_005d: conv.i8 + IL_005e: add + IL_005f: stloc.s V_4 + IL_0061: ldloc.s V_4 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + } + + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (int64 V_0, + int64 V_1) + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stloc.0 + IL_0003: ldc.i4.s 10 + IL_0005: conv.i8 + IL_0006: stloc.1 + IL_0007: br.s IL_0019 + + IL_0009: ldloc.1 + IL_000a: call void assembly::set_c(int64) + IL_000f: ldloc.1 + IL_0010: ldc.i4.1 + IL_0011: conv.i8 + IL_0012: add + IL_0013: stloc.1 + IL_0014: ldloc.0 + IL_0015: ldc.i4.1 + IL_0016: conv.i8 + IL_0017: add + IL_0018: stloc.0 + IL_0019: ldloc.0 + IL_001a: ldc.i4.0 + IL_001b: conv.i8 + IL_001c: blt.un.s IL_0009 + + IL_001e: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + int64 V_1) + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stloc.0 + IL_0003: ldc.i4.1 + IL_0004: conv.i8 + IL_0005: stloc.1 + IL_0006: br.s IL_0018 + + IL_0008: ldloc.1 + IL_0009: call void assembly::set_c(int64) + IL_000e: ldloc.1 + IL_000f: ldc.i4.1 + IL_0010: conv.i8 + IL_0011: add + IL_0012: stloc.1 + IL_0013: ldloc.0 + IL_0014: ldc.i4.1 + IL_0015: conv.i8 + IL_0016: add + IL_0017: stloc.0 + IL_0018: ldloc.0 + IL_0019: ldc.i4.s 10 + IL_001b: conv.i8 + IL_001c: blt.un.s IL_0008 + + IL_001e: ret + } + + .method public static void constFinish(int64 start) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int64 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: conv.i8 + IL_0003: ldarg.0 + IL_0004: bge.s IL_000b + + IL_0006: ldc.i4.0 + IL_0007: conv.i8 + IL_0008: nop + IL_0009: br.s IL_0014 + + IL_000b: ldc.i4.s 10 + IL_000d: conv.i8 + IL_000e: ldarg.0 + IL_000f: sub + IL_0010: ldc.i4.1 + IL_0011: conv.i8 + IL_0012: add.ovf.un + IL_0013: nop + IL_0014: stloc.0 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.1 + IL_0018: ldarg.0 + IL_0019: stloc.2 + IL_001a: br.s IL_002c + + IL_001c: ldloc.2 + IL_001d: call void assembly::set_c(int64) + IL_0022: ldloc.2 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.2 + IL_0027: ldloc.1 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.1 + IL_002c: ldloc.1 + IL_002d: ldloc.0 + IL_002e: blt.un.s IL_001c + + IL_0030: ret + } + + .method public static void constStart(int64 finish) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + int64 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: conv.i8 + IL_0003: bge.s IL_000a + + IL_0005: ldc.i4.0 + IL_0006: conv.i8 + IL_0007: nop + IL_0008: br.s IL_0012 + + IL_000a: ldarg.0 + IL_000b: ldc.i4.1 + IL_000c: conv.i8 + IL_000d: sub + IL_000e: ldc.i4.1 + IL_000f: conv.i8 + IL_0010: add.ovf.un + IL_0011: nop + IL_0012: stloc.0 + IL_0013: ldc.i4.0 + IL_0014: conv.i8 + IL_0015: stloc.1 + IL_0016: ldc.i4.1 + IL_0017: conv.i8 + IL_0018: stloc.2 + IL_0019: br.s IL_002b + + IL_001b: ldloc.2 + IL_001c: call void assembly::set_c(int64) + IL_0021: ldloc.2 + IL_0022: ldc.i4.1 + IL_0023: conv.i8 + IL_0024: add + IL_0025: stloc.2 + IL_0026: ldloc.1 + IL_0027: ldc.i4.1 + IL_0028: conv.i8 + IL_0029: add + IL_002a: stloc.1 + IL_002b: ldloc.1 + IL_002c: ldloc.0 + IL_002d: blt.un.s IL_001b + + IL_002f: ret + } + + .method public static void annotatedStart(int64 start, + int64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + int64 V_3, + uint64 V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(int64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.1 + IL_0037: ldarg.0 + IL_0038: bge.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.1 + IL_0040: ldarg.0 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.s V_4 + IL_004b: ldarg.0 + IL_004c: stloc.3 + IL_004d: br.s IL_0061 + + IL_004f: ldloc.3 + IL_0050: call void assembly::set_c(int64) + IL_0055: ldloc.3 + IL_0056: ldc.i4.1 + IL_0057: conv.i8 + IL_0058: add + IL_0059: stloc.3 + IL_005a: ldloc.s V_4 + IL_005c: ldc.i4.1 + IL_005d: conv.i8 + IL_005e: add + IL_005f: stloc.s V_4 + IL_0061: ldloc.s V_4 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + .method public static void annotatedFinish(int64 start, + int64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + int64 V_3, + uint64 V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(int64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.1 + IL_0037: ldarg.0 + IL_0038: bge.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.1 + IL_0040: ldarg.0 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.s V_4 + IL_004b: ldarg.0 + IL_004c: stloc.3 + IL_004d: br.s IL_0061 + + IL_004f: ldloc.3 + IL_0050: call void assembly::set_c(int64) + IL_0055: ldloc.3 + IL_0056: ldc.i4.1 + IL_0057: conv.i8 + IL_0058: add + IL_0059: stloc.3 + IL_005a: ldloc.s V_4 + IL_005c: ldc.i4.1 + IL_005d: conv.i8 + IL_005e: add + IL_005f: stloc.s V_4 + IL_0061: ldloc.s V_4 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + .method public static void inferredStartAndFinish(int64 start, + int64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + int64 V_3, + uint64 V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(int64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.1 + IL_0037: ldarg.0 + IL_0038: bge.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.1 + IL_0040: ldarg.0 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.s V_4 + IL_004b: ldarg.0 + IL_004c: stloc.3 + IL_004d: br.s IL_0061 + + IL_004f: ldloc.3 + IL_0050: call void assembly::set_c(int64) + IL_0055: ldloc.3 + IL_0056: ldc.i4.1 + IL_0057: conv.i8 + IL_0058: add + IL_0059: stloc.3 + IL_005a: ldloc.s V_4 + IL_005c: ldc.i4.1 + IL_005d: conv.i8 + IL_005e: add + IL_005f: stloc.s V_4 + IL_0061: ldloc.s V_4 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + } + + .field static assembly int64 c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .method public specialname static int64 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld int64 assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(int64 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld int64 assembly::c@1 + IL_0006: ret + } + + .method private specialname rtspecialname static void .cctor() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int32 ''.$assembly::init@ + IL_0006: ldsfld int32 ''.$assembly::init@ + IL_000b: pop + IL_000c: ret + } + + .method assembly specialname static void staticInitialization@() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stsfld int64 assembly::c@1 + IL_0007: ret + } + + .property int64 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(int64) + .get int64 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: call void assembly::staticInitialization@() + IL_0005: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopIntPtr.fs.RealInternalSignatureOff.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopIntPtr.fs.RealInternalSignatureOff.OptimizeOn.il.bsl new file mode 100644 index 00000000000..941d69bc7b4 --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopIntPtr.fs.RealInternalSignatureOff.OptimizeOn.il.bsl @@ -0,0 +1,1599 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Down + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldc.i8 0x1 + IL_0009: conv.i + IL_000a: ldc.i8 0xa + IL_0013: conv.i + IL_0014: bge.s IL_0023 + + IL_0016: ldc.i8 0x0 + IL_001f: conv.i + IL_0020: nop + IL_0021: br.s IL_0039 + + IL_0023: ldc.i8 0x1 + IL_002c: conv.i + IL_002d: ldc.i8 0xa + IL_0036: conv.i + IL_0037: sub + IL_0038: nop + IL_0039: stloc.0 + IL_003a: sizeof [runtime]System.IntPtr + IL_0040: ldc.i4.4 + IL_0041: bne.un.s IL_0053 + + IL_0043: ldloc.0 + IL_0044: ldc.i8 0xffffffff + IL_004d: conv.u + IL_004e: ceq + IL_0050: nop + IL_0051: br.s IL_0061 + + IL_0053: ldloc.0 + IL_0054: ldc.i8 0xffffffffffffffff + IL_005d: conv.u + IL_005e: ceq + IL_0060: nop + IL_0061: brfalse.s IL_00af + + IL_0063: ldc.i4.1 + IL_0064: stloc.1 + IL_0065: ldc.i8 0x0 + IL_006e: conv.i + IL_006f: stloc.2 + IL_0070: ldc.i8 0x1 + IL_0079: conv.i + IL_007a: stloc.3 + IL_007b: br.s IL_00ab + + IL_007d: ldloc.3 + IL_007e: call void assembly::set_c(native int) + IL_0083: ldloc.3 + IL_0084: ldc.i8 0xffffffffffffffff + IL_008d: conv.i + IL_008e: add + IL_008f: stloc.3 + IL_0090: ldloc.2 + IL_0091: ldc.i8 0x1 + IL_009a: conv.i + IL_009b: add + IL_009c: stloc.2 + IL_009d: ldloc.2 + IL_009e: ldc.i8 0x0 + IL_00a7: conv.i + IL_00a8: cgt.un + IL_00aa: stloc.1 + IL_00ab: ldloc.1 + IL_00ac: brtrue.s IL_007d + + IL_00ae: ret + + IL_00af: ldc.i8 0x1 + IL_00b8: conv.i + IL_00b9: ldc.i8 0xa + IL_00c2: conv.i + IL_00c3: bge.s IL_00d2 + + IL_00c5: ldc.i8 0x0 + IL_00ce: conv.i + IL_00cf: nop + IL_00d0: br.s IL_00f3 + + IL_00d2: ldc.i8 0x1 + IL_00db: conv.i + IL_00dc: ldc.i8 0xa + IL_00e5: conv.i + IL_00e6: sub + IL_00e7: ldc.i8 0x1 + IL_00f0: conv.i + IL_00f1: add.ovf.un + IL_00f2: nop + IL_00f3: stloc.2 + IL_00f4: ldc.i8 0x0 + IL_00fd: conv.i + IL_00fe: stloc.3 + IL_00ff: ldc.i8 0x1 + IL_0108: conv.i + IL_0109: stloc.s V_4 + IL_010b: br.s IL_0130 + + IL_010d: ldloc.s V_4 + IL_010f: call void assembly::set_c(native int) + IL_0114: ldloc.s V_4 + IL_0116: ldc.i8 0xffffffffffffffff + IL_011f: conv.i + IL_0120: add + IL_0121: stloc.s V_4 + IL_0123: ldloc.3 + IL_0124: ldc.i8 0x1 + IL_012d: conv.i + IL_012e: add + IL_012f: stloc.3 + IL_0130: ldloc.3 + IL_0131: ldloc.2 + IL_0132: blt.un.s IL_010d + + IL_0134: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldc.i8 0xa + IL_0009: conv.i + IL_000a: ldc.i8 0x1 + IL_0013: conv.i + IL_0014: bge.s IL_0023 + + IL_0016: ldc.i8 0x0 + IL_001f: conv.i + IL_0020: nop + IL_0021: br.s IL_0039 + + IL_0023: ldc.i8 0xa + IL_002c: conv.i + IL_002d: ldc.i8 0x1 + IL_0036: conv.i + IL_0037: sub + IL_0038: nop + IL_0039: stloc.0 + IL_003a: sizeof [runtime]System.IntPtr + IL_0040: ldc.i4.4 + IL_0041: bne.un.s IL_0053 + + IL_0043: ldloc.0 + IL_0044: ldc.i8 0xffffffff + IL_004d: conv.u + IL_004e: ceq + IL_0050: nop + IL_0051: br.s IL_0061 + + IL_0053: ldloc.0 + IL_0054: ldc.i8 0xffffffffffffffff + IL_005d: conv.u + IL_005e: ceq + IL_0060: nop + IL_0061: brfalse.s IL_00af + + IL_0063: ldc.i4.1 + IL_0064: stloc.1 + IL_0065: ldc.i8 0x0 + IL_006e: conv.i + IL_006f: stloc.2 + IL_0070: ldc.i8 0xa + IL_0079: conv.i + IL_007a: stloc.3 + IL_007b: br.s IL_00ab + + IL_007d: ldloc.3 + IL_007e: call void assembly::set_c(native int) + IL_0083: ldloc.3 + IL_0084: ldc.i8 0xffffffffffffffff + IL_008d: conv.i + IL_008e: add + IL_008f: stloc.3 + IL_0090: ldloc.2 + IL_0091: ldc.i8 0x1 + IL_009a: conv.i + IL_009b: add + IL_009c: stloc.2 + IL_009d: ldloc.2 + IL_009e: ldc.i8 0x0 + IL_00a7: conv.i + IL_00a8: cgt.un + IL_00aa: stloc.1 + IL_00ab: ldloc.1 + IL_00ac: brtrue.s IL_007d + + IL_00ae: ret + + IL_00af: ldc.i8 0xa + IL_00b8: conv.i + IL_00b9: ldc.i8 0x1 + IL_00c2: conv.i + IL_00c3: bge.s IL_00d2 + + IL_00c5: ldc.i8 0x0 + IL_00ce: conv.i + IL_00cf: nop + IL_00d0: br.s IL_00f3 + + IL_00d2: ldc.i8 0xa + IL_00db: conv.i + IL_00dc: ldc.i8 0x1 + IL_00e5: conv.i + IL_00e6: sub + IL_00e7: ldc.i8 0x1 + IL_00f0: conv.i + IL_00f1: add.ovf.un + IL_00f2: nop + IL_00f3: stloc.2 + IL_00f4: ldc.i8 0x0 + IL_00fd: conv.i + IL_00fe: stloc.3 + IL_00ff: ldc.i8 0xa + IL_0108: conv.i + IL_0109: stloc.s V_4 + IL_010b: br.s IL_0130 + + IL_010d: ldloc.s V_4 + IL_010f: call void assembly::set_c(native int) + IL_0114: ldloc.s V_4 + IL_0116: ldc.i8 0xffffffffffffffff + IL_011f: conv.i + IL_0120: add + IL_0121: stloc.s V_4 + IL_0123: ldloc.3 + IL_0124: ldc.i8 0x1 + IL_012d: conv.i + IL_012e: add + IL_012f: stloc.3 + IL_0130: ldloc.3 + IL_0131: ldloc.2 + IL_0132: blt.un.s IL_010d + + IL_0134: ret + } + + .method public static void constFinish(native int start) cil managed + { + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.0 + IL_0001: ldc.i8 0x1 + IL_000a: conv.i + IL_000b: bge.s IL_001a + + IL_000d: ldc.i8 0x0 + IL_0016: conv.i + IL_0017: nop + IL_0018: br.s IL_0027 + + IL_001a: ldarg.0 + IL_001b: ldc.i8 0x1 + IL_0024: conv.i + IL_0025: sub + IL_0026: nop + IL_0027: stloc.0 + IL_0028: sizeof [runtime]System.IntPtr + IL_002e: ldc.i4.4 + IL_002f: bne.un.s IL_0041 + + IL_0031: ldloc.0 + IL_0032: ldc.i8 0xffffffff + IL_003b: conv.u + IL_003c: ceq + IL_003e: nop + IL_003f: br.s IL_004f + + IL_0041: ldloc.0 + IL_0042: ldc.i8 0xffffffffffffffff + IL_004b: conv.u + IL_004c: ceq + IL_004e: nop + IL_004f: brfalse.s IL_0094 + + IL_0051: ldc.i4.1 + IL_0052: stloc.1 + IL_0053: ldc.i8 0x0 + IL_005c: conv.i + IL_005d: stloc.2 + IL_005e: ldarg.0 + IL_005f: stloc.3 + IL_0060: br.s IL_0090 + + IL_0062: ldloc.3 + IL_0063: call void assembly::set_c(native int) + IL_0068: ldloc.3 + IL_0069: ldc.i8 0xffffffffffffffff + IL_0072: conv.i + IL_0073: add + IL_0074: stloc.3 + IL_0075: ldloc.2 + IL_0076: ldc.i8 0x1 + IL_007f: conv.i + IL_0080: add + IL_0081: stloc.2 + IL_0082: ldloc.2 + IL_0083: ldc.i8 0x0 + IL_008c: conv.i + IL_008d: cgt.un + IL_008f: stloc.1 + IL_0090: ldloc.1 + IL_0091: brtrue.s IL_0062 + + IL_0093: ret + + IL_0094: ldarg.0 + IL_0095: ldc.i8 0x1 + IL_009e: conv.i + IL_009f: bge.s IL_00ae + + IL_00a1: ldc.i8 0x0 + IL_00aa: conv.i + IL_00ab: nop + IL_00ac: br.s IL_00c6 + + IL_00ae: ldarg.0 + IL_00af: ldc.i8 0x1 + IL_00b8: conv.i + IL_00b9: sub + IL_00ba: ldc.i8 0x1 + IL_00c3: conv.i + IL_00c4: add.ovf.un + IL_00c5: nop + IL_00c6: stloc.2 + IL_00c7: ldc.i8 0x0 + IL_00d0: conv.i + IL_00d1: stloc.3 + IL_00d2: ldarg.0 + IL_00d3: stloc.s V_4 + IL_00d5: br.s IL_00fa + + IL_00d7: ldloc.s V_4 + IL_00d9: call void assembly::set_c(native int) + IL_00de: ldloc.s V_4 + IL_00e0: ldc.i8 0xffffffffffffffff + IL_00e9: conv.i + IL_00ea: add + IL_00eb: stloc.s V_4 + IL_00ed: ldloc.3 + IL_00ee: ldc.i8 0x1 + IL_00f7: conv.i + IL_00f8: add + IL_00f9: stloc.3 + IL_00fa: ldloc.3 + IL_00fb: ldloc.2 + IL_00fc: blt.un.s IL_00d7 + + IL_00fe: ret + } + + .method public static void constStart(native int finish) cil managed + { + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldc.i8 0xa + IL_0009: conv.i + IL_000a: ldarg.0 + IL_000b: bge.s IL_001a + + IL_000d: ldc.i8 0x0 + IL_0016: conv.i + IL_0017: nop + IL_0018: br.s IL_0027 + + IL_001a: ldc.i8 0xa + IL_0023: conv.i + IL_0024: ldarg.0 + IL_0025: sub + IL_0026: nop + IL_0027: stloc.0 + IL_0028: sizeof [runtime]System.IntPtr + IL_002e: ldc.i4.4 + IL_002f: bne.un.s IL_0041 + + IL_0031: ldloc.0 + IL_0032: ldc.i8 0xffffffff + IL_003b: conv.u + IL_003c: ceq + IL_003e: nop + IL_003f: br.s IL_004f + + IL_0041: ldloc.0 + IL_0042: ldc.i8 0xffffffffffffffff + IL_004b: conv.u + IL_004c: ceq + IL_004e: nop + IL_004f: brfalse.s IL_009d + + IL_0051: ldc.i4.1 + IL_0052: stloc.1 + IL_0053: ldc.i8 0x0 + IL_005c: conv.i + IL_005d: stloc.2 + IL_005e: ldc.i8 0xa + IL_0067: conv.i + IL_0068: stloc.3 + IL_0069: br.s IL_0099 + + IL_006b: ldloc.3 + IL_006c: call void assembly::set_c(native int) + IL_0071: ldloc.3 + IL_0072: ldc.i8 0xffffffffffffffff + IL_007b: conv.i + IL_007c: add + IL_007d: stloc.3 + IL_007e: ldloc.2 + IL_007f: ldc.i8 0x1 + IL_0088: conv.i + IL_0089: add + IL_008a: stloc.2 + IL_008b: ldloc.2 + IL_008c: ldc.i8 0x0 + IL_0095: conv.i + IL_0096: cgt.un + IL_0098: stloc.1 + IL_0099: ldloc.1 + IL_009a: brtrue.s IL_006b + + IL_009c: ret + + IL_009d: ldc.i8 0xa + IL_00a6: conv.i + IL_00a7: ldarg.0 + IL_00a8: bge.s IL_00b7 + + IL_00aa: ldc.i8 0x0 + IL_00b3: conv.i + IL_00b4: nop + IL_00b5: br.s IL_00cf + + IL_00b7: ldc.i8 0xa + IL_00c0: conv.i + IL_00c1: ldarg.0 + IL_00c2: sub + IL_00c3: ldc.i8 0x1 + IL_00cc: conv.i + IL_00cd: add.ovf.un + IL_00ce: nop + IL_00cf: stloc.2 + IL_00d0: ldc.i8 0x0 + IL_00d9: conv.i + IL_00da: stloc.3 + IL_00db: ldc.i8 0xa + IL_00e4: conv.i + IL_00e5: stloc.s V_4 + IL_00e7: br.s IL_010c + + IL_00e9: ldloc.s V_4 + IL_00eb: call void assembly::set_c(native int) + IL_00f0: ldloc.s V_4 + IL_00f2: ldc.i8 0xffffffffffffffff + IL_00fb: conv.i + IL_00fc: add + IL_00fd: stloc.s V_4 + IL_00ff: ldloc.3 + IL_0100: ldc.i8 0x1 + IL_0109: conv.i + IL_010a: add + IL_010b: stloc.3 + IL_010c: ldloc.3 + IL_010d: ldloc.2 + IL_010e: blt.un.s IL_00e9 + + IL_0110: ret + } + + .method public static void annotatedStart(native int start, + native int finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.i + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.0 + IL_0012: ldarg.1 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.i + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native int) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0xffffffffffffffff + IL_0060: conv.i + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.i + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.i + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.0 + IL_0083: ldarg.1 + IL_0084: bge.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.i + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.0 + IL_0094: ldarg.1 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.i + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.i + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native int) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0xffffffffffffffff + IL_00c5: conv.i + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.i + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + .method public static void annotatedFinish(native int start, + native int finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.i + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.0 + IL_0012: ldarg.1 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.i + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native int) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0xffffffffffffffff + IL_0060: conv.i + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.i + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.i + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.0 + IL_0083: ldarg.1 + IL_0084: bge.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.i + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.0 + IL_0094: ldarg.1 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.i + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.i + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native int) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0xffffffffffffffff + IL_00c5: conv.i + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.i + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + .method public static void inferredStartAndFinish(native int start, + native int finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.i + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.0 + IL_0012: ldarg.1 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.i + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native int) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0xffffffffffffffff + IL_0060: conv.i + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.i + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.i + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.0 + IL_0083: ldarg.1 + IL_0084: bge.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.i + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.0 + IL_0094: ldarg.1 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.i + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.i + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native int) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0xffffffffffffffff + IL_00c5: conv.i + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.i + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + } + + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (native int V_0, + native int V_1) + IL_0000: ldc.i8 0x0 + IL_0009: conv.i + IL_000a: stloc.0 + IL_000b: ldc.i8 0xa + IL_0014: conv.i + IL_0015: stloc.1 + IL_0016: br.s IL_0038 + + IL_0018: ldloc.1 + IL_0019: call void assembly::set_c(native int) + IL_001e: ldloc.1 + IL_001f: ldc.i8 0x1 + IL_0028: conv.i + IL_0029: add + IL_002a: stloc.1 + IL_002b: ldloc.0 + IL_002c: ldc.i8 0x1 + IL_0035: conv.i + IL_0036: add + IL_0037: stloc.0 + IL_0038: ldloc.0 + IL_0039: ldc.i8 0x0 + IL_0042: conv.i + IL_0043: blt.un.s IL_0018 + + IL_0045: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (native int V_0, + native int V_1) + IL_0000: ldc.i8 0x0 + IL_0009: conv.i + IL_000a: stloc.0 + IL_000b: ldc.i8 0x1 + IL_0014: conv.i + IL_0015: stloc.1 + IL_0016: br.s IL_0038 + + IL_0018: ldloc.1 + IL_0019: call void assembly::set_c(native int) + IL_001e: ldloc.1 + IL_001f: ldc.i8 0x1 + IL_0028: conv.i + IL_0029: add + IL_002a: stloc.1 + IL_002b: ldloc.0 + IL_002c: ldc.i8 0x1 + IL_0035: conv.i + IL_0036: add + IL_0037: stloc.0 + IL_0038: ldloc.0 + IL_0039: ldc.i8 0xa + IL_0042: conv.u + IL_0043: blt.un.s IL_0018 + + IL_0045: ret + } + + .method public static void constFinish(native int start) cil managed + { + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldc.i8 0xa + IL_0009: conv.i + IL_000a: ldarg.0 + IL_000b: bge.s IL_001a + + IL_000d: ldc.i8 0x0 + IL_0016: conv.i + IL_0017: nop + IL_0018: br.s IL_0027 + + IL_001a: ldc.i8 0xa + IL_0023: conv.i + IL_0024: ldarg.0 + IL_0025: sub + IL_0026: nop + IL_0027: stloc.0 + IL_0028: sizeof [runtime]System.IntPtr + IL_002e: ldc.i4.4 + IL_002f: bne.un.s IL_0041 + + IL_0031: ldloc.0 + IL_0032: ldc.i8 0xffffffff + IL_003b: conv.u + IL_003c: ceq + IL_003e: nop + IL_003f: br.s IL_004f + + IL_0041: ldloc.0 + IL_0042: ldc.i8 0xffffffffffffffff + IL_004b: conv.u + IL_004c: ceq + IL_004e: nop + IL_004f: brfalse.s IL_0094 + + IL_0051: ldc.i4.1 + IL_0052: stloc.1 + IL_0053: ldc.i8 0x0 + IL_005c: conv.i + IL_005d: stloc.2 + IL_005e: ldarg.0 + IL_005f: stloc.3 + IL_0060: br.s IL_0090 + + IL_0062: ldloc.3 + IL_0063: call void assembly::set_c(native int) + IL_0068: ldloc.3 + IL_0069: ldc.i8 0x1 + IL_0072: conv.i + IL_0073: add + IL_0074: stloc.3 + IL_0075: ldloc.2 + IL_0076: ldc.i8 0x1 + IL_007f: conv.i + IL_0080: add + IL_0081: stloc.2 + IL_0082: ldloc.2 + IL_0083: ldc.i8 0x0 + IL_008c: conv.i + IL_008d: cgt.un + IL_008f: stloc.1 + IL_0090: ldloc.1 + IL_0091: brtrue.s IL_0062 + + IL_0093: ret + + IL_0094: ldc.i8 0xa + IL_009d: conv.i + IL_009e: ldarg.0 + IL_009f: bge.s IL_00ae + + IL_00a1: ldc.i8 0x0 + IL_00aa: conv.i + IL_00ab: nop + IL_00ac: br.s IL_00c6 + + IL_00ae: ldc.i8 0xa + IL_00b7: conv.i + IL_00b8: ldarg.0 + IL_00b9: sub + IL_00ba: ldc.i8 0x1 + IL_00c3: conv.i + IL_00c4: add.ovf.un + IL_00c5: nop + IL_00c6: stloc.2 + IL_00c7: ldc.i8 0x0 + IL_00d0: conv.i + IL_00d1: stloc.3 + IL_00d2: ldarg.0 + IL_00d3: stloc.s V_4 + IL_00d5: br.s IL_00fa + + IL_00d7: ldloc.s V_4 + IL_00d9: call void assembly::set_c(native int) + IL_00de: ldloc.s V_4 + IL_00e0: ldc.i8 0x1 + IL_00e9: conv.i + IL_00ea: add + IL_00eb: stloc.s V_4 + IL_00ed: ldloc.3 + IL_00ee: ldc.i8 0x1 + IL_00f7: conv.i + IL_00f8: add + IL_00f9: stloc.3 + IL_00fa: ldloc.3 + IL_00fb: ldloc.2 + IL_00fc: blt.un.s IL_00d7 + + IL_00fe: ret + } + + .method public static void constStart(native int finish) cil managed + { + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.0 + IL_0001: ldc.i8 0x1 + IL_000a: conv.i + IL_000b: bge.s IL_001a + + IL_000d: ldc.i8 0x0 + IL_0016: conv.i + IL_0017: nop + IL_0018: br.s IL_0027 + + IL_001a: ldarg.0 + IL_001b: ldc.i8 0x1 + IL_0024: conv.i + IL_0025: sub + IL_0026: nop + IL_0027: stloc.0 + IL_0028: sizeof [runtime]System.IntPtr + IL_002e: ldc.i4.4 + IL_002f: bne.un.s IL_0041 + + IL_0031: ldloc.0 + IL_0032: ldc.i8 0xffffffff + IL_003b: conv.u + IL_003c: ceq + IL_003e: nop + IL_003f: br.s IL_004f + + IL_0041: ldloc.0 + IL_0042: ldc.i8 0xffffffffffffffff + IL_004b: conv.u + IL_004c: ceq + IL_004e: nop + IL_004f: brfalse.s IL_009d + + IL_0051: ldc.i4.1 + IL_0052: stloc.1 + IL_0053: ldc.i8 0x0 + IL_005c: conv.i + IL_005d: stloc.2 + IL_005e: ldc.i8 0x1 + IL_0067: conv.i + IL_0068: stloc.3 + IL_0069: br.s IL_0099 + + IL_006b: ldloc.3 + IL_006c: call void assembly::set_c(native int) + IL_0071: ldloc.3 + IL_0072: ldc.i8 0x1 + IL_007b: conv.i + IL_007c: add + IL_007d: stloc.3 + IL_007e: ldloc.2 + IL_007f: ldc.i8 0x1 + IL_0088: conv.i + IL_0089: add + IL_008a: stloc.2 + IL_008b: ldloc.2 + IL_008c: ldc.i8 0x0 + IL_0095: conv.i + IL_0096: cgt.un + IL_0098: stloc.1 + IL_0099: ldloc.1 + IL_009a: brtrue.s IL_006b + + IL_009c: ret + + IL_009d: ldarg.0 + IL_009e: ldc.i8 0x1 + IL_00a7: conv.i + IL_00a8: bge.s IL_00b7 + + IL_00aa: ldc.i8 0x0 + IL_00b3: conv.i + IL_00b4: nop + IL_00b5: br.s IL_00cf + + IL_00b7: ldarg.0 + IL_00b8: ldc.i8 0x1 + IL_00c1: conv.i + IL_00c2: sub + IL_00c3: ldc.i8 0x1 + IL_00cc: conv.i + IL_00cd: add.ovf.un + IL_00ce: nop + IL_00cf: stloc.2 + IL_00d0: ldc.i8 0x0 + IL_00d9: conv.i + IL_00da: stloc.3 + IL_00db: ldc.i8 0x1 + IL_00e4: conv.i + IL_00e5: stloc.s V_4 + IL_00e7: br.s IL_010c + + IL_00e9: ldloc.s V_4 + IL_00eb: call void assembly::set_c(native int) + IL_00f0: ldloc.s V_4 + IL_00f2: ldc.i8 0x1 + IL_00fb: conv.i + IL_00fc: add + IL_00fd: stloc.s V_4 + IL_00ff: ldloc.3 + IL_0100: ldc.i8 0x1 + IL_0109: conv.i + IL_010a: add + IL_010b: stloc.3 + IL_010c: ldloc.3 + IL_010d: ldloc.2 + IL_010e: blt.un.s IL_00e9 + + IL_0110: ret + } + + .method public static void annotatedStart(native int start, + native int finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.i + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.1 + IL_0012: ldarg.0 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.i + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native int) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0x1 + IL_0060: conv.i + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.i + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.i + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.1 + IL_0083: ldarg.0 + IL_0084: bge.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.i + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.1 + IL_0094: ldarg.0 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.i + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.i + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native int) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0x1 + IL_00c5: conv.i + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.i + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + .method public static void annotatedFinish(native int start, + native int finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.i + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.1 + IL_0012: ldarg.0 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.i + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native int) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0x1 + IL_0060: conv.i + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.i + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.i + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.1 + IL_0083: ldarg.0 + IL_0084: bge.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.i + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.1 + IL_0094: ldarg.0 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.i + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.i + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native int) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0x1 + IL_00c5: conv.i + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.i + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + .method public static void inferredStartAndFinish(native int start, + native int finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.i + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.1 + IL_0012: ldarg.0 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.i + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native int) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0x1 + IL_0060: conv.i + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.i + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.i + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.1 + IL_0083: ldarg.0 + IL_0084: bge.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.i + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.1 + IL_0094: ldarg.0 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.i + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.i + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native int) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0x1 + IL_00c5: conv.i + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.i + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + } + + .method public specialname static native int get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld native int ''.$assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(native int 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld native int ''.$assembly::c@1 + IL_0006: ret + } + + .property native int c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(native int) + .get native int assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly native int c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: ldc.i8 0x0 + IL_0009: conv.i + IL_000a: stsfld native int ''.$assembly::c@1 + IL_000f: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopIntPtr.fs.RealInternalSignatureOn.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopIntPtr.fs.RealInternalSignatureOn.OptimizeOn.il.bsl new file mode 100644 index 00000000000..f08694df683 --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopIntPtr.fs.RealInternalSignatureOn.OptimizeOn.il.bsl @@ -0,0 +1,1618 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Down + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldc.i8 0x1 + IL_0009: conv.i + IL_000a: ldc.i8 0xa + IL_0013: conv.i + IL_0014: bge.s IL_0023 + + IL_0016: ldc.i8 0x0 + IL_001f: conv.i + IL_0020: nop + IL_0021: br.s IL_0039 + + IL_0023: ldc.i8 0x1 + IL_002c: conv.i + IL_002d: ldc.i8 0xa + IL_0036: conv.i + IL_0037: sub + IL_0038: nop + IL_0039: stloc.0 + IL_003a: sizeof [runtime]System.IntPtr + IL_0040: ldc.i4.4 + IL_0041: bne.un.s IL_0053 + + IL_0043: ldloc.0 + IL_0044: ldc.i8 0xffffffff + IL_004d: conv.u + IL_004e: ceq + IL_0050: nop + IL_0051: br.s IL_0061 + + IL_0053: ldloc.0 + IL_0054: ldc.i8 0xffffffffffffffff + IL_005d: conv.u + IL_005e: ceq + IL_0060: nop + IL_0061: brfalse.s IL_00af + + IL_0063: ldc.i4.1 + IL_0064: stloc.1 + IL_0065: ldc.i8 0x0 + IL_006e: conv.i + IL_006f: stloc.2 + IL_0070: ldc.i8 0x1 + IL_0079: conv.i + IL_007a: stloc.3 + IL_007b: br.s IL_00ab + + IL_007d: ldloc.3 + IL_007e: call void assembly::set_c(native int) + IL_0083: ldloc.3 + IL_0084: ldc.i8 0xffffffffffffffff + IL_008d: conv.i + IL_008e: add + IL_008f: stloc.3 + IL_0090: ldloc.2 + IL_0091: ldc.i8 0x1 + IL_009a: conv.i + IL_009b: add + IL_009c: stloc.2 + IL_009d: ldloc.2 + IL_009e: ldc.i8 0x0 + IL_00a7: conv.i + IL_00a8: cgt.un + IL_00aa: stloc.1 + IL_00ab: ldloc.1 + IL_00ac: brtrue.s IL_007d + + IL_00ae: ret + + IL_00af: ldc.i8 0x1 + IL_00b8: conv.i + IL_00b9: ldc.i8 0xa + IL_00c2: conv.i + IL_00c3: bge.s IL_00d2 + + IL_00c5: ldc.i8 0x0 + IL_00ce: conv.i + IL_00cf: nop + IL_00d0: br.s IL_00f3 + + IL_00d2: ldc.i8 0x1 + IL_00db: conv.i + IL_00dc: ldc.i8 0xa + IL_00e5: conv.i + IL_00e6: sub + IL_00e7: ldc.i8 0x1 + IL_00f0: conv.i + IL_00f1: add.ovf.un + IL_00f2: nop + IL_00f3: stloc.2 + IL_00f4: ldc.i8 0x0 + IL_00fd: conv.i + IL_00fe: stloc.3 + IL_00ff: ldc.i8 0x1 + IL_0108: conv.i + IL_0109: stloc.s V_4 + IL_010b: br.s IL_0130 + + IL_010d: ldloc.s V_4 + IL_010f: call void assembly::set_c(native int) + IL_0114: ldloc.s V_4 + IL_0116: ldc.i8 0xffffffffffffffff + IL_011f: conv.i + IL_0120: add + IL_0121: stloc.s V_4 + IL_0123: ldloc.3 + IL_0124: ldc.i8 0x1 + IL_012d: conv.i + IL_012e: add + IL_012f: stloc.3 + IL_0130: ldloc.3 + IL_0131: ldloc.2 + IL_0132: blt.un.s IL_010d + + IL_0134: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldc.i8 0xa + IL_0009: conv.i + IL_000a: ldc.i8 0x1 + IL_0013: conv.i + IL_0014: bge.s IL_0023 + + IL_0016: ldc.i8 0x0 + IL_001f: conv.i + IL_0020: nop + IL_0021: br.s IL_0039 + + IL_0023: ldc.i8 0xa + IL_002c: conv.i + IL_002d: ldc.i8 0x1 + IL_0036: conv.i + IL_0037: sub + IL_0038: nop + IL_0039: stloc.0 + IL_003a: sizeof [runtime]System.IntPtr + IL_0040: ldc.i4.4 + IL_0041: bne.un.s IL_0053 + + IL_0043: ldloc.0 + IL_0044: ldc.i8 0xffffffff + IL_004d: conv.u + IL_004e: ceq + IL_0050: nop + IL_0051: br.s IL_0061 + + IL_0053: ldloc.0 + IL_0054: ldc.i8 0xffffffffffffffff + IL_005d: conv.u + IL_005e: ceq + IL_0060: nop + IL_0061: brfalse.s IL_00af + + IL_0063: ldc.i4.1 + IL_0064: stloc.1 + IL_0065: ldc.i8 0x0 + IL_006e: conv.i + IL_006f: stloc.2 + IL_0070: ldc.i8 0xa + IL_0079: conv.i + IL_007a: stloc.3 + IL_007b: br.s IL_00ab + + IL_007d: ldloc.3 + IL_007e: call void assembly::set_c(native int) + IL_0083: ldloc.3 + IL_0084: ldc.i8 0xffffffffffffffff + IL_008d: conv.i + IL_008e: add + IL_008f: stloc.3 + IL_0090: ldloc.2 + IL_0091: ldc.i8 0x1 + IL_009a: conv.i + IL_009b: add + IL_009c: stloc.2 + IL_009d: ldloc.2 + IL_009e: ldc.i8 0x0 + IL_00a7: conv.i + IL_00a8: cgt.un + IL_00aa: stloc.1 + IL_00ab: ldloc.1 + IL_00ac: brtrue.s IL_007d + + IL_00ae: ret + + IL_00af: ldc.i8 0xa + IL_00b8: conv.i + IL_00b9: ldc.i8 0x1 + IL_00c2: conv.i + IL_00c3: bge.s IL_00d2 + + IL_00c5: ldc.i8 0x0 + IL_00ce: conv.i + IL_00cf: nop + IL_00d0: br.s IL_00f3 + + IL_00d2: ldc.i8 0xa + IL_00db: conv.i + IL_00dc: ldc.i8 0x1 + IL_00e5: conv.i + IL_00e6: sub + IL_00e7: ldc.i8 0x1 + IL_00f0: conv.i + IL_00f1: add.ovf.un + IL_00f2: nop + IL_00f3: stloc.2 + IL_00f4: ldc.i8 0x0 + IL_00fd: conv.i + IL_00fe: stloc.3 + IL_00ff: ldc.i8 0xa + IL_0108: conv.i + IL_0109: stloc.s V_4 + IL_010b: br.s IL_0130 + + IL_010d: ldloc.s V_4 + IL_010f: call void assembly::set_c(native int) + IL_0114: ldloc.s V_4 + IL_0116: ldc.i8 0xffffffffffffffff + IL_011f: conv.i + IL_0120: add + IL_0121: stloc.s V_4 + IL_0123: ldloc.3 + IL_0124: ldc.i8 0x1 + IL_012d: conv.i + IL_012e: add + IL_012f: stloc.3 + IL_0130: ldloc.3 + IL_0131: ldloc.2 + IL_0132: blt.un.s IL_010d + + IL_0134: ret + } + + .method public static void constFinish(native int start) cil managed + { + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.0 + IL_0001: ldc.i8 0x1 + IL_000a: conv.i + IL_000b: bge.s IL_001a + + IL_000d: ldc.i8 0x0 + IL_0016: conv.i + IL_0017: nop + IL_0018: br.s IL_0027 + + IL_001a: ldarg.0 + IL_001b: ldc.i8 0x1 + IL_0024: conv.i + IL_0025: sub + IL_0026: nop + IL_0027: stloc.0 + IL_0028: sizeof [runtime]System.IntPtr + IL_002e: ldc.i4.4 + IL_002f: bne.un.s IL_0041 + + IL_0031: ldloc.0 + IL_0032: ldc.i8 0xffffffff + IL_003b: conv.u + IL_003c: ceq + IL_003e: nop + IL_003f: br.s IL_004f + + IL_0041: ldloc.0 + IL_0042: ldc.i8 0xffffffffffffffff + IL_004b: conv.u + IL_004c: ceq + IL_004e: nop + IL_004f: brfalse.s IL_0094 + + IL_0051: ldc.i4.1 + IL_0052: stloc.1 + IL_0053: ldc.i8 0x0 + IL_005c: conv.i + IL_005d: stloc.2 + IL_005e: ldarg.0 + IL_005f: stloc.3 + IL_0060: br.s IL_0090 + + IL_0062: ldloc.3 + IL_0063: call void assembly::set_c(native int) + IL_0068: ldloc.3 + IL_0069: ldc.i8 0xffffffffffffffff + IL_0072: conv.i + IL_0073: add + IL_0074: stloc.3 + IL_0075: ldloc.2 + IL_0076: ldc.i8 0x1 + IL_007f: conv.i + IL_0080: add + IL_0081: stloc.2 + IL_0082: ldloc.2 + IL_0083: ldc.i8 0x0 + IL_008c: conv.i + IL_008d: cgt.un + IL_008f: stloc.1 + IL_0090: ldloc.1 + IL_0091: brtrue.s IL_0062 + + IL_0093: ret + + IL_0094: ldarg.0 + IL_0095: ldc.i8 0x1 + IL_009e: conv.i + IL_009f: bge.s IL_00ae + + IL_00a1: ldc.i8 0x0 + IL_00aa: conv.i + IL_00ab: nop + IL_00ac: br.s IL_00c6 + + IL_00ae: ldarg.0 + IL_00af: ldc.i8 0x1 + IL_00b8: conv.i + IL_00b9: sub + IL_00ba: ldc.i8 0x1 + IL_00c3: conv.i + IL_00c4: add.ovf.un + IL_00c5: nop + IL_00c6: stloc.2 + IL_00c7: ldc.i8 0x0 + IL_00d0: conv.i + IL_00d1: stloc.3 + IL_00d2: ldarg.0 + IL_00d3: stloc.s V_4 + IL_00d5: br.s IL_00fa + + IL_00d7: ldloc.s V_4 + IL_00d9: call void assembly::set_c(native int) + IL_00de: ldloc.s V_4 + IL_00e0: ldc.i8 0xffffffffffffffff + IL_00e9: conv.i + IL_00ea: add + IL_00eb: stloc.s V_4 + IL_00ed: ldloc.3 + IL_00ee: ldc.i8 0x1 + IL_00f7: conv.i + IL_00f8: add + IL_00f9: stloc.3 + IL_00fa: ldloc.3 + IL_00fb: ldloc.2 + IL_00fc: blt.un.s IL_00d7 + + IL_00fe: ret + } + + .method public static void constStart(native int finish) cil managed + { + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldc.i8 0xa + IL_0009: conv.i + IL_000a: ldarg.0 + IL_000b: bge.s IL_001a + + IL_000d: ldc.i8 0x0 + IL_0016: conv.i + IL_0017: nop + IL_0018: br.s IL_0027 + + IL_001a: ldc.i8 0xa + IL_0023: conv.i + IL_0024: ldarg.0 + IL_0025: sub + IL_0026: nop + IL_0027: stloc.0 + IL_0028: sizeof [runtime]System.IntPtr + IL_002e: ldc.i4.4 + IL_002f: bne.un.s IL_0041 + + IL_0031: ldloc.0 + IL_0032: ldc.i8 0xffffffff + IL_003b: conv.u + IL_003c: ceq + IL_003e: nop + IL_003f: br.s IL_004f + + IL_0041: ldloc.0 + IL_0042: ldc.i8 0xffffffffffffffff + IL_004b: conv.u + IL_004c: ceq + IL_004e: nop + IL_004f: brfalse.s IL_009d + + IL_0051: ldc.i4.1 + IL_0052: stloc.1 + IL_0053: ldc.i8 0x0 + IL_005c: conv.i + IL_005d: stloc.2 + IL_005e: ldc.i8 0xa + IL_0067: conv.i + IL_0068: stloc.3 + IL_0069: br.s IL_0099 + + IL_006b: ldloc.3 + IL_006c: call void assembly::set_c(native int) + IL_0071: ldloc.3 + IL_0072: ldc.i8 0xffffffffffffffff + IL_007b: conv.i + IL_007c: add + IL_007d: stloc.3 + IL_007e: ldloc.2 + IL_007f: ldc.i8 0x1 + IL_0088: conv.i + IL_0089: add + IL_008a: stloc.2 + IL_008b: ldloc.2 + IL_008c: ldc.i8 0x0 + IL_0095: conv.i + IL_0096: cgt.un + IL_0098: stloc.1 + IL_0099: ldloc.1 + IL_009a: brtrue.s IL_006b + + IL_009c: ret + + IL_009d: ldc.i8 0xa + IL_00a6: conv.i + IL_00a7: ldarg.0 + IL_00a8: bge.s IL_00b7 + + IL_00aa: ldc.i8 0x0 + IL_00b3: conv.i + IL_00b4: nop + IL_00b5: br.s IL_00cf + + IL_00b7: ldc.i8 0xa + IL_00c0: conv.i + IL_00c1: ldarg.0 + IL_00c2: sub + IL_00c3: ldc.i8 0x1 + IL_00cc: conv.i + IL_00cd: add.ovf.un + IL_00ce: nop + IL_00cf: stloc.2 + IL_00d0: ldc.i8 0x0 + IL_00d9: conv.i + IL_00da: stloc.3 + IL_00db: ldc.i8 0xa + IL_00e4: conv.i + IL_00e5: stloc.s V_4 + IL_00e7: br.s IL_010c + + IL_00e9: ldloc.s V_4 + IL_00eb: call void assembly::set_c(native int) + IL_00f0: ldloc.s V_4 + IL_00f2: ldc.i8 0xffffffffffffffff + IL_00fb: conv.i + IL_00fc: add + IL_00fd: stloc.s V_4 + IL_00ff: ldloc.3 + IL_0100: ldc.i8 0x1 + IL_0109: conv.i + IL_010a: add + IL_010b: stloc.3 + IL_010c: ldloc.3 + IL_010d: ldloc.2 + IL_010e: blt.un.s IL_00e9 + + IL_0110: ret + } + + .method public static void annotatedStart(native int start, + native int finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.i + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.0 + IL_0012: ldarg.1 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.i + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native int) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0xffffffffffffffff + IL_0060: conv.i + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.i + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.i + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.0 + IL_0083: ldarg.1 + IL_0084: bge.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.i + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.0 + IL_0094: ldarg.1 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.i + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.i + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native int) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0xffffffffffffffff + IL_00c5: conv.i + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.i + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + .method public static void annotatedFinish(native int start, + native int finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.i + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.0 + IL_0012: ldarg.1 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.i + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native int) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0xffffffffffffffff + IL_0060: conv.i + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.i + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.i + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.0 + IL_0083: ldarg.1 + IL_0084: bge.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.i + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.0 + IL_0094: ldarg.1 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.i + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.i + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native int) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0xffffffffffffffff + IL_00c5: conv.i + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.i + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + .method public static void inferredStartAndFinish(native int start, + native int finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.i + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.0 + IL_0012: ldarg.1 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.i + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native int) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0xffffffffffffffff + IL_0060: conv.i + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.i + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.i + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.0 + IL_0083: ldarg.1 + IL_0084: bge.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.i + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.0 + IL_0094: ldarg.1 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.i + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.i + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native int) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0xffffffffffffffff + IL_00c5: conv.i + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.i + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + } + + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (native int V_0, + native int V_1) + IL_0000: ldc.i8 0x0 + IL_0009: conv.i + IL_000a: stloc.0 + IL_000b: ldc.i8 0xa + IL_0014: conv.i + IL_0015: stloc.1 + IL_0016: br.s IL_0038 + + IL_0018: ldloc.1 + IL_0019: call void assembly::set_c(native int) + IL_001e: ldloc.1 + IL_001f: ldc.i8 0x1 + IL_0028: conv.i + IL_0029: add + IL_002a: stloc.1 + IL_002b: ldloc.0 + IL_002c: ldc.i8 0x1 + IL_0035: conv.i + IL_0036: add + IL_0037: stloc.0 + IL_0038: ldloc.0 + IL_0039: ldc.i8 0x0 + IL_0042: conv.i + IL_0043: blt.un.s IL_0018 + + IL_0045: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (native int V_0, + native int V_1) + IL_0000: ldc.i8 0x0 + IL_0009: conv.i + IL_000a: stloc.0 + IL_000b: ldc.i8 0x1 + IL_0014: conv.i + IL_0015: stloc.1 + IL_0016: br.s IL_0038 + + IL_0018: ldloc.1 + IL_0019: call void assembly::set_c(native int) + IL_001e: ldloc.1 + IL_001f: ldc.i8 0x1 + IL_0028: conv.i + IL_0029: add + IL_002a: stloc.1 + IL_002b: ldloc.0 + IL_002c: ldc.i8 0x1 + IL_0035: conv.i + IL_0036: add + IL_0037: stloc.0 + IL_0038: ldloc.0 + IL_0039: ldc.i8 0xa + IL_0042: conv.u + IL_0043: blt.un.s IL_0018 + + IL_0045: ret + } + + .method public static void constFinish(native int start) cil managed + { + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldc.i8 0xa + IL_0009: conv.i + IL_000a: ldarg.0 + IL_000b: bge.s IL_001a + + IL_000d: ldc.i8 0x0 + IL_0016: conv.i + IL_0017: nop + IL_0018: br.s IL_0027 + + IL_001a: ldc.i8 0xa + IL_0023: conv.i + IL_0024: ldarg.0 + IL_0025: sub + IL_0026: nop + IL_0027: stloc.0 + IL_0028: sizeof [runtime]System.IntPtr + IL_002e: ldc.i4.4 + IL_002f: bne.un.s IL_0041 + + IL_0031: ldloc.0 + IL_0032: ldc.i8 0xffffffff + IL_003b: conv.u + IL_003c: ceq + IL_003e: nop + IL_003f: br.s IL_004f + + IL_0041: ldloc.0 + IL_0042: ldc.i8 0xffffffffffffffff + IL_004b: conv.u + IL_004c: ceq + IL_004e: nop + IL_004f: brfalse.s IL_0094 + + IL_0051: ldc.i4.1 + IL_0052: stloc.1 + IL_0053: ldc.i8 0x0 + IL_005c: conv.i + IL_005d: stloc.2 + IL_005e: ldarg.0 + IL_005f: stloc.3 + IL_0060: br.s IL_0090 + + IL_0062: ldloc.3 + IL_0063: call void assembly::set_c(native int) + IL_0068: ldloc.3 + IL_0069: ldc.i8 0x1 + IL_0072: conv.i + IL_0073: add + IL_0074: stloc.3 + IL_0075: ldloc.2 + IL_0076: ldc.i8 0x1 + IL_007f: conv.i + IL_0080: add + IL_0081: stloc.2 + IL_0082: ldloc.2 + IL_0083: ldc.i8 0x0 + IL_008c: conv.i + IL_008d: cgt.un + IL_008f: stloc.1 + IL_0090: ldloc.1 + IL_0091: brtrue.s IL_0062 + + IL_0093: ret + + IL_0094: ldc.i8 0xa + IL_009d: conv.i + IL_009e: ldarg.0 + IL_009f: bge.s IL_00ae + + IL_00a1: ldc.i8 0x0 + IL_00aa: conv.i + IL_00ab: nop + IL_00ac: br.s IL_00c6 + + IL_00ae: ldc.i8 0xa + IL_00b7: conv.i + IL_00b8: ldarg.0 + IL_00b9: sub + IL_00ba: ldc.i8 0x1 + IL_00c3: conv.i + IL_00c4: add.ovf.un + IL_00c5: nop + IL_00c6: stloc.2 + IL_00c7: ldc.i8 0x0 + IL_00d0: conv.i + IL_00d1: stloc.3 + IL_00d2: ldarg.0 + IL_00d3: stloc.s V_4 + IL_00d5: br.s IL_00fa + + IL_00d7: ldloc.s V_4 + IL_00d9: call void assembly::set_c(native int) + IL_00de: ldloc.s V_4 + IL_00e0: ldc.i8 0x1 + IL_00e9: conv.i + IL_00ea: add + IL_00eb: stloc.s V_4 + IL_00ed: ldloc.3 + IL_00ee: ldc.i8 0x1 + IL_00f7: conv.i + IL_00f8: add + IL_00f9: stloc.3 + IL_00fa: ldloc.3 + IL_00fb: ldloc.2 + IL_00fc: blt.un.s IL_00d7 + + IL_00fe: ret + } + + .method public static void constStart(native int finish) cil managed + { + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.0 + IL_0001: ldc.i8 0x1 + IL_000a: conv.i + IL_000b: bge.s IL_001a + + IL_000d: ldc.i8 0x0 + IL_0016: conv.i + IL_0017: nop + IL_0018: br.s IL_0027 + + IL_001a: ldarg.0 + IL_001b: ldc.i8 0x1 + IL_0024: conv.i + IL_0025: sub + IL_0026: nop + IL_0027: stloc.0 + IL_0028: sizeof [runtime]System.IntPtr + IL_002e: ldc.i4.4 + IL_002f: bne.un.s IL_0041 + + IL_0031: ldloc.0 + IL_0032: ldc.i8 0xffffffff + IL_003b: conv.u + IL_003c: ceq + IL_003e: nop + IL_003f: br.s IL_004f + + IL_0041: ldloc.0 + IL_0042: ldc.i8 0xffffffffffffffff + IL_004b: conv.u + IL_004c: ceq + IL_004e: nop + IL_004f: brfalse.s IL_009d + + IL_0051: ldc.i4.1 + IL_0052: stloc.1 + IL_0053: ldc.i8 0x0 + IL_005c: conv.i + IL_005d: stloc.2 + IL_005e: ldc.i8 0x1 + IL_0067: conv.i + IL_0068: stloc.3 + IL_0069: br.s IL_0099 + + IL_006b: ldloc.3 + IL_006c: call void assembly::set_c(native int) + IL_0071: ldloc.3 + IL_0072: ldc.i8 0x1 + IL_007b: conv.i + IL_007c: add + IL_007d: stloc.3 + IL_007e: ldloc.2 + IL_007f: ldc.i8 0x1 + IL_0088: conv.i + IL_0089: add + IL_008a: stloc.2 + IL_008b: ldloc.2 + IL_008c: ldc.i8 0x0 + IL_0095: conv.i + IL_0096: cgt.un + IL_0098: stloc.1 + IL_0099: ldloc.1 + IL_009a: brtrue.s IL_006b + + IL_009c: ret + + IL_009d: ldarg.0 + IL_009e: ldc.i8 0x1 + IL_00a7: conv.i + IL_00a8: bge.s IL_00b7 + + IL_00aa: ldc.i8 0x0 + IL_00b3: conv.i + IL_00b4: nop + IL_00b5: br.s IL_00cf + + IL_00b7: ldarg.0 + IL_00b8: ldc.i8 0x1 + IL_00c1: conv.i + IL_00c2: sub + IL_00c3: ldc.i8 0x1 + IL_00cc: conv.i + IL_00cd: add.ovf.un + IL_00ce: nop + IL_00cf: stloc.2 + IL_00d0: ldc.i8 0x0 + IL_00d9: conv.i + IL_00da: stloc.3 + IL_00db: ldc.i8 0x1 + IL_00e4: conv.i + IL_00e5: stloc.s V_4 + IL_00e7: br.s IL_010c + + IL_00e9: ldloc.s V_4 + IL_00eb: call void assembly::set_c(native int) + IL_00f0: ldloc.s V_4 + IL_00f2: ldc.i8 0x1 + IL_00fb: conv.i + IL_00fc: add + IL_00fd: stloc.s V_4 + IL_00ff: ldloc.3 + IL_0100: ldc.i8 0x1 + IL_0109: conv.i + IL_010a: add + IL_010b: stloc.3 + IL_010c: ldloc.3 + IL_010d: ldloc.2 + IL_010e: blt.un.s IL_00e9 + + IL_0110: ret + } + + .method public static void annotatedStart(native int start, + native int finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.i + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.1 + IL_0012: ldarg.0 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.i + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native int) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0x1 + IL_0060: conv.i + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.i + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.i + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.1 + IL_0083: ldarg.0 + IL_0084: bge.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.i + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.1 + IL_0094: ldarg.0 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.i + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.i + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native int) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0x1 + IL_00c5: conv.i + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.i + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + .method public static void annotatedFinish(native int start, + native int finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.i + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.1 + IL_0012: ldarg.0 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.i + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native int) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0x1 + IL_0060: conv.i + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.i + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.i + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.1 + IL_0083: ldarg.0 + IL_0084: bge.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.i + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.1 + IL_0094: ldarg.0 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.i + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.i + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native int) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0x1 + IL_00c5: conv.i + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.i + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + .method public static void inferredStartAndFinish(native int start, + native int finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native int V_0, + bool V_1, + native int V_2, + native int V_3, + native int V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.i + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.1 + IL_0012: ldarg.0 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.i + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native int) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0x1 + IL_0060: conv.i + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.i + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.i + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.1 + IL_0083: ldarg.0 + IL_0084: bge.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.i + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.1 + IL_0094: ldarg.0 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.i + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.i + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native int) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0x1 + IL_00c5: conv.i + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.i + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + } + + .field static assembly native int c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .method public specialname static native int get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld native int assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(native int 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld native int assembly::c@1 + IL_0006: ret + } + + .method private specialname rtspecialname static void .cctor() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int32 ''.$assembly::init@ + IL_0006: ldsfld int32 ''.$assembly::init@ + IL_000b: pop + IL_000c: ret + } + + .method assembly specialname static void staticInitialization@() cil managed + { + + .maxstack 8 + IL_0000: ldc.i8 0x0 + IL_0009: conv.i + IL_000a: stsfld native int assembly::c@1 + IL_000f: ret + } + + .property native int c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(native int) + .get native int assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: call void assembly::staticInitialization@() + IL_0005: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopSByte.fs.RealInternalSignatureOff.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopSByte.fs.RealInternalSignatureOff.OptimizeOn.il.bsl new file mode 100644 index 00000000000..b1b40c7ec81 --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopSByte.fs.RealInternalSignatureOff.OptimizeOn.il.bsl @@ -0,0 +1,686 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Down + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (int8 V_0, + int8 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.1 + IL_0003: stloc.1 + IL_0004: br.s IL_0014 + + IL_0006: ldloc.1 + IL_0007: call void assembly::set_c(int8) + IL_000c: ldloc.1 + IL_000d: ldc.i4.m1 + IL_000e: add + IL_000f: stloc.1 + IL_0010: ldloc.0 + IL_0011: ldc.i4.1 + IL_0012: add + IL_0013: stloc.0 + IL_0014: ldloc.0 + IL_0015: ldc.i4.0 + IL_0016: blt.un.s IL_0006 + + IL_0018: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + int8 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(int8) + IL_000d: ldloc.1 + IL_000e: ldc.i4.m1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.s 10 + IL_0018: blt.un.s IL_0007 + + IL_001a: ret + } + + .method public static void constFinish(int8 start) cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldc.i4.1 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void constStart(int8 finish) cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldc.i4.s 10 + IL_000b: ldarg.0 + IL_000c: sub + IL_000d: conv.i2 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldc.i4.s 10 + IL_0016: stloc.2 + IL_0017: br.s IL_0027 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(int8) + IL_001f: ldloc.2 + IL_0020: ldc.i4.m1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: add + IL_0026: stloc.1 + IL_0027: ldloc.1 + IL_0028: ldloc.0 + IL_0029: blt.un.s IL_0019 + + IL_002b: ret + } + + .method public static void annotatedStart(int8 start, + int8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldarg.1 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedFinish(int8 start, + int8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldarg.1 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void inferredStartAndFinish(int8 start, + int8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldarg.1 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + } + + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (int8 V_0, + int8 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(int8) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.0 + IL_0017: blt.un.s IL_0007 + + IL_0019: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + int8 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.1 + IL_0003: stloc.1 + IL_0004: br.s IL_0014 + + IL_0006: ldloc.1 + IL_0007: call void assembly::set_c(int8) + IL_000c: ldloc.1 + IL_000d: ldc.i4.1 + IL_000e: add + IL_000f: stloc.1 + IL_0010: ldloc.0 + IL_0011: ldc.i4.1 + IL_0012: add + IL_0013: stloc.0 + IL_0014: ldloc.0 + IL_0015: ldc.i4.s 10 + IL_0017: blt.un.s IL_0006 + + IL_0019: ret + } + + .method public static void constFinish(int8 start) cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldc.i4.s 10 + IL_000b: ldarg.0 + IL_000c: sub + IL_000d: conv.i2 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldarg.0 + IL_0015: stloc.2 + IL_0016: br.s IL_0026 + + IL_0018: ldloc.2 + IL_0019: call void assembly::set_c(int8) + IL_001e: ldloc.2 + IL_001f: ldc.i4.1 + IL_0020: add + IL_0021: stloc.2 + IL_0022: ldloc.1 + IL_0023: ldc.i4.1 + IL_0024: add + IL_0025: stloc.1 + IL_0026: ldloc.1 + IL_0027: ldloc.0 + IL_0028: blt.un.s IL_0018 + + IL_002a: ret + } + + .method public static void constStart(int8 finish) cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldc.i4.1 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldc.i4.1 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedStart(int8 start, + int8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedFinish(int8 start, + int8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void inferredStartAndFinish(int8 start, + int8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + } + + .method public specialname static int8 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld int8 ''.$assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(int8 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld int8 ''.$assembly::c@1 + IL_0006: ret + } + + .property int8 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(int8) + .get int8 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int8 c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int8 ''.$assembly::c@1 + IL_0006: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopSByte.fs.RealInternalSignatureOn.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopSByte.fs.RealInternalSignatureOn.OptimizeOn.il.bsl new file mode 100644 index 00000000000..fa00532415a --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopSByte.fs.RealInternalSignatureOn.OptimizeOn.il.bsl @@ -0,0 +1,705 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Down + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (int8 V_0, + int8 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.1 + IL_0003: stloc.1 + IL_0004: br.s IL_0014 + + IL_0006: ldloc.1 + IL_0007: call void assembly::set_c(int8) + IL_000c: ldloc.1 + IL_000d: ldc.i4.m1 + IL_000e: add + IL_000f: stloc.1 + IL_0010: ldloc.0 + IL_0011: ldc.i4.1 + IL_0012: add + IL_0013: stloc.0 + IL_0014: ldloc.0 + IL_0015: ldc.i4.0 + IL_0016: blt.un.s IL_0006 + + IL_0018: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + int8 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(int8) + IL_000d: ldloc.1 + IL_000e: ldc.i4.m1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.s 10 + IL_0018: blt.un.s IL_0007 + + IL_001a: ret + } + + .method public static void constFinish(int8 start) cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldc.i4.1 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void constStart(int8 finish) cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldc.i4.s 10 + IL_000b: ldarg.0 + IL_000c: sub + IL_000d: conv.i2 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldc.i4.s 10 + IL_0016: stloc.2 + IL_0017: br.s IL_0027 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(int8) + IL_001f: ldloc.2 + IL_0020: ldc.i4.m1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: add + IL_0026: stloc.1 + IL_0027: ldloc.1 + IL_0028: ldloc.0 + IL_0029: blt.un.s IL_0019 + + IL_002b: ret + } + + .method public static void annotatedStart(int8 start, + int8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldarg.1 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedFinish(int8 start, + int8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldarg.1 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void inferredStartAndFinish(int8 start, + int8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.0 + IL_0001: ldarg.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldarg.1 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.m1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + } + + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (int8 V_0, + int8 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(int8) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.0 + IL_0017: blt.un.s IL_0007 + + IL_0019: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + int8 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.1 + IL_0003: stloc.1 + IL_0004: br.s IL_0014 + + IL_0006: ldloc.1 + IL_0007: call void assembly::set_c(int8) + IL_000c: ldloc.1 + IL_000d: ldc.i4.1 + IL_000e: add + IL_000f: stloc.1 + IL_0010: ldloc.0 + IL_0011: ldc.i4.1 + IL_0012: add + IL_0013: stloc.0 + IL_0014: ldloc.0 + IL_0015: ldc.i4.s 10 + IL_0017: blt.un.s IL_0006 + + IL_0019: ret + } + + .method public static void constFinish(int8 start) cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldc.i4.s 10 + IL_000b: ldarg.0 + IL_000c: sub + IL_000d: conv.i2 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldarg.0 + IL_0015: stloc.2 + IL_0016: br.s IL_0026 + + IL_0018: ldloc.2 + IL_0019: call void assembly::set_c(int8) + IL_001e: ldloc.2 + IL_001f: ldc.i4.1 + IL_0020: add + IL_0021: stloc.2 + IL_0022: ldloc.1 + IL_0023: ldc.i4.1 + IL_0024: add + IL_0025: stloc.1 + IL_0026: ldloc.1 + IL_0027: ldloc.0 + IL_0028: blt.un.s IL_0018 + + IL_002a: ret + } + + .method public static void constStart(int8 finish) cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldc.i4.1 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldc.i4.1 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedStart(int8 start, + int8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedFinish(int8 start, + int8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void inferredStartAndFinish(int8 start, + int8 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1, + int8 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.i2 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(int8) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + } + + .field static assembly int8 c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .method public specialname static int8 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld int8 assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(int8 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld int8 assembly::c@1 + IL_0006: ret + } + + .method private specialname rtspecialname static void .cctor() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int32 ''.$assembly::init@ + IL_0006: ldsfld int32 ''.$assembly::init@ + IL_000b: pop + IL_000c: ret + } + + .method assembly specialname static void staticInitialization@() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int8 assembly::c@1 + IL_0006: ret + } + + .property int8 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(int8) + .get int8 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: call void assembly::staticInitialization@() + IL_0005: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt16.fs.RealInternalSignatureOff.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt16.fs.RealInternalSignatureOff.OptimizeOn.il.bsl new file mode 100644 index 00000000000..d3bed1fc56e --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt16.fs.RealInternalSignatureOff.OptimizeOn.il.bsl @@ -0,0 +1,386 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(uint16) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.0 + IL_0017: blt.un.s IL_0007 + + IL_0019: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint16 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.1 + IL_0003: stloc.1 + IL_0004: br.s IL_0014 + + IL_0006: ldloc.1 + IL_0007: call void assembly::set_c(uint16) + IL_000c: ldloc.1 + IL_000d: ldc.i4.1 + IL_000e: add + IL_000f: stloc.1 + IL_0010: ldloc.0 + IL_0011: ldc.i4.1 + IL_0012: add + IL_0013: stloc.0 + IL_0014: ldloc.0 + IL_0015: ldc.i4.s 10 + IL_0017: blt.un.s IL_0006 + + IL_0019: ret + } + + .method public static void constStart(uint16 start) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + uint16 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.un.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldc.i4.s 10 + IL_000b: ldarg.0 + IL_000c: sub + IL_000d: conv.u4 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldarg.0 + IL_0015: stloc.2 + IL_0016: br.s IL_0026 + + IL_0018: ldloc.2 + IL_0019: call void assembly::set_c(uint16) + IL_001e: ldloc.2 + IL_001f: ldc.i4.1 + IL_0020: add + IL_0021: stloc.2 + IL_0022: ldloc.1 + IL_0023: ldc.i4.1 + IL_0024: add + IL_0025: stloc.1 + IL_0026: ldloc.1 + IL_0027: ldloc.0 + IL_0028: blt.un.s IL_0018 + + IL_002a: ret + } + + .method public static void constFinish(uint16 finish) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + uint16 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldc.i4.1 + IL_000a: sub + IL_000b: conv.u4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldc.i4.1 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedStart(uint16 start, + uint16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + uint16 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedFinish(uint16 start, + uint16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + uint16 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void inferredStartAndFinish(uint16 start, + uint16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + uint16 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + } + + .method public specialname static uint16 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld uint16 ''.$assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(uint16 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld uint16 ''.$assembly::c@1 + IL_0006: ret + } + + .property uint16 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(uint16) + .get uint16 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly uint16 c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld uint16 ''.$assembly::c@1 + IL_0006: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt16.fs.RealInternalSignatureOn.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt16.fs.RealInternalSignatureOn.OptimizeOn.il.bsl new file mode 100644 index 00000000000..cbc995200a3 --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt16.fs.RealInternalSignatureOn.OptimizeOn.il.bsl @@ -0,0 +1,405 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (uint16 V_0, + uint16 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(uint16) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.0 + IL_0017: blt.un.s IL_0007 + + IL_0019: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint16 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.1 + IL_0003: stloc.1 + IL_0004: br.s IL_0014 + + IL_0006: ldloc.1 + IL_0007: call void assembly::set_c(uint16) + IL_000c: ldloc.1 + IL_000d: ldc.i4.1 + IL_000e: add + IL_000f: stloc.1 + IL_0010: ldloc.0 + IL_0011: ldc.i4.1 + IL_0012: add + IL_0013: stloc.0 + IL_0014: ldloc.0 + IL_0015: ldc.i4.s 10 + IL_0017: blt.un.s IL_0006 + + IL_0019: ret + } + + .method public static void constStart(uint16 start) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + uint16 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.un.s IL_0009 + + IL_0005: ldc.i4.0 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldc.i4.s 10 + IL_000b: ldarg.0 + IL_000c: sub + IL_000d: conv.u4 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: stloc.1 + IL_0014: ldarg.0 + IL_0015: stloc.2 + IL_0016: br.s IL_0026 + + IL_0018: ldloc.2 + IL_0019: call void assembly::set_c(uint16) + IL_001e: ldloc.2 + IL_001f: ldc.i4.1 + IL_0020: add + IL_0021: stloc.2 + IL_0022: ldloc.1 + IL_0023: ldc.i4.1 + IL_0024: add + IL_0025: stloc.1 + IL_0026: ldloc.1 + IL_0027: ldloc.0 + IL_0028: blt.un.s IL_0018 + + IL_002a: ret + } + + .method public static void constFinish(uint16 finish) cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + uint16 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.0 + IL_0009: ldc.i4.1 + IL_000a: sub + IL_000b: conv.u4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldc.i4.1 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedStart(uint16 start, + uint16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + uint16 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void annotatedFinish(uint16 start, + uint16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + uint16 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + .method public static void inferredStartAndFinish(uint16 start, + uint16 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1, + uint16 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0008 + + IL_0004: ldc.i4.0 + IL_0005: nop + IL_0006: br.s IL_000f + + IL_0008: ldarg.1 + IL_0009: ldarg.0 + IL_000a: sub + IL_000b: conv.u4 + IL_000c: ldc.i4.1 + IL_000d: add + IL_000e: nop + IL_000f: stloc.0 + IL_0010: ldc.i4.0 + IL_0011: stloc.1 + IL_0012: ldarg.0 + IL_0013: stloc.2 + IL_0014: br.s IL_0024 + + IL_0016: ldloc.2 + IL_0017: call void assembly::set_c(uint16) + IL_001c: ldloc.2 + IL_001d: ldc.i4.1 + IL_001e: add + IL_001f: stloc.2 + IL_0020: ldloc.1 + IL_0021: ldc.i4.1 + IL_0022: add + IL_0023: stloc.1 + IL_0024: ldloc.1 + IL_0025: ldloc.0 + IL_0026: blt.un.s IL_0016 + + IL_0028: ret + } + + } + + .field static assembly uint16 c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .method public specialname static uint16 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld uint16 assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(uint16 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld uint16 assembly::c@1 + IL_0006: ret + } + + .method private specialname rtspecialname static void .cctor() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int32 ''.$assembly::init@ + IL_0006: ldsfld int32 ''.$assembly::init@ + IL_000b: pop + IL_000c: ret + } + + .method assembly specialname static void staticInitialization@() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld uint16 assembly::c@1 + IL_0006: ret + } + + .property uint16 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(uint16) + .get uint16 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: call void assembly::staticInitialization@() + IL_0005: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt32.fs.RealInternalSignatureOff.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt32.fs.RealInternalSignatureOff.OptimizeOn.il.bsl new file mode 100644 index 00000000000..68c634f0622 --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt32.fs.RealInternalSignatureOff.OptimizeOn.il.bsl @@ -0,0 +1,409 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(uint32) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.0 + IL_0017: blt.un.s IL_0007 + + IL_0019: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint32 V_1) + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stloc.0 + IL_0003: ldc.i4.1 + IL_0004: stloc.1 + IL_0005: br.s IL_0016 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(uint32) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: conv.i8 + IL_0014: add + IL_0015: stloc.0 + IL_0016: ldloc.0 + IL_0017: ldc.i4.s 10 + IL_0019: conv.i8 + IL_001a: blt.un.s IL_0007 + + IL_001c: ret + } + + .method public static void constStart(uint32 start) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + uint32 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.un.s IL_000a + + IL_0005: ldc.i4.0 + IL_0006: conv.i8 + IL_0007: nop + IL_0008: br.s IL_0013 + + IL_000a: ldc.i4.s 10 + IL_000c: ldarg.0 + IL_000d: sub + IL_000e: conv.u8 + IL_000f: ldc.i4.1 + IL_0010: conv.i8 + IL_0011: add + IL_0012: nop + IL_0013: stloc.0 + IL_0014: ldc.i4.0 + IL_0015: conv.i8 + IL_0016: stloc.1 + IL_0017: ldarg.0 + IL_0018: stloc.2 + IL_0019: br.s IL_002a + + IL_001b: ldloc.2 + IL_001c: call void assembly::set_c(uint32) + IL_0021: ldloc.2 + IL_0022: ldc.i4.1 + IL_0023: add + IL_0024: stloc.2 + IL_0025: ldloc.1 + IL_0026: ldc.i4.1 + IL_0027: conv.i8 + IL_0028: add + IL_0029: stloc.1 + IL_002a: ldloc.1 + IL_002b: ldloc.0 + IL_002c: blt.un.s IL_001b + + IL_002e: ret + } + + .method public static void constFinish(uint32 finish) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + uint32 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.un.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.0 + IL_000a: ldc.i4.1 + IL_000b: sub + IL_000c: conv.u8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldc.i4.1 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(uint32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + .method public static void annotatedStart(uint32 start, + uint32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + uint32 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: conv.u8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(uint32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + .method public static void annotatedFinish(uint32 start, + uint32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + uint32 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: conv.u8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(uint32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + .method public static void inferredStartAndFinish(uint32 start, + uint32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + uint32 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: conv.u8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(uint32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + } + + .method public specialname static uint32 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld uint32 ''.$assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(uint32 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld uint32 ''.$assembly::c@1 + IL_0006: ret + } + + .property uint32 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(uint32) + .get uint32 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly uint32 c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld uint32 ''.$assembly::c@1 + IL_0006: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt32.fs.RealInternalSignatureOn.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt32.fs.RealInternalSignatureOn.OptimizeOn.il.bsl new file mode 100644 index 00000000000..2d1cd3f9f36 --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt32.fs.RealInternalSignatureOn.OptimizeOn.il.bsl @@ -0,0 +1,428 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (uint32 V_0, + uint32 V_1) + IL_0000: ldc.i4.0 + IL_0001: stloc.0 + IL_0002: ldc.i4.s 10 + IL_0004: stloc.1 + IL_0005: br.s IL_0015 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(uint32) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: add + IL_0014: stloc.0 + IL_0015: ldloc.0 + IL_0016: ldc.i4.0 + IL_0017: blt.un.s IL_0007 + + IL_0019: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint32 V_1) + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stloc.0 + IL_0003: ldc.i4.1 + IL_0004: stloc.1 + IL_0005: br.s IL_0016 + + IL_0007: ldloc.1 + IL_0008: call void assembly::set_c(uint32) + IL_000d: ldloc.1 + IL_000e: ldc.i4.1 + IL_000f: add + IL_0010: stloc.1 + IL_0011: ldloc.0 + IL_0012: ldc.i4.1 + IL_0013: conv.i8 + IL_0014: add + IL_0015: stloc.0 + IL_0016: ldloc.0 + IL_0017: ldc.i4.s 10 + IL_0019: conv.i8 + IL_001a: blt.un.s IL_0007 + + IL_001c: ret + } + + .method public static void constStart(uint32 start) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + uint32 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: ldarg.0 + IL_0003: bge.un.s IL_000a + + IL_0005: ldc.i4.0 + IL_0006: conv.i8 + IL_0007: nop + IL_0008: br.s IL_0013 + + IL_000a: ldc.i4.s 10 + IL_000c: ldarg.0 + IL_000d: sub + IL_000e: conv.u8 + IL_000f: ldc.i4.1 + IL_0010: conv.i8 + IL_0011: add + IL_0012: nop + IL_0013: stloc.0 + IL_0014: ldc.i4.0 + IL_0015: conv.i8 + IL_0016: stloc.1 + IL_0017: ldarg.0 + IL_0018: stloc.2 + IL_0019: br.s IL_002a + + IL_001b: ldloc.2 + IL_001c: call void assembly::set_c(uint32) + IL_0021: ldloc.2 + IL_0022: ldc.i4.1 + IL_0023: add + IL_0024: stloc.2 + IL_0025: ldloc.1 + IL_0026: ldc.i4.1 + IL_0027: conv.i8 + IL_0028: add + IL_0029: stloc.1 + IL_002a: ldloc.1 + IL_002b: ldloc.0 + IL_002c: blt.un.s IL_001b + + IL_002e: ret + } + + .method public static void constFinish(uint32 finish) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + uint32 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: bge.un.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.0 + IL_000a: ldc.i4.1 + IL_000b: sub + IL_000c: conv.u8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldc.i4.1 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(uint32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + .method public static void annotatedStart(uint32 start, + uint32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + uint32 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: conv.u8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(uint32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + .method public static void annotatedFinish(uint32 start, + uint32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + uint32 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: conv.u8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(uint32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + .method public static void inferredStartAndFinish(uint32 start, + uint32 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + uint32 V_2) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_0011 + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: conv.u8 + IL_000d: ldc.i4.1 + IL_000e: conv.i8 + IL_000f: add + IL_0010: nop + IL_0011: stloc.0 + IL_0012: ldc.i4.0 + IL_0013: conv.i8 + IL_0014: stloc.1 + IL_0015: ldarg.0 + IL_0016: stloc.2 + IL_0017: br.s IL_0028 + + IL_0019: ldloc.2 + IL_001a: call void assembly::set_c(uint32) + IL_001f: ldloc.2 + IL_0020: ldc.i4.1 + IL_0021: add + IL_0022: stloc.2 + IL_0023: ldloc.1 + IL_0024: ldc.i4.1 + IL_0025: conv.i8 + IL_0026: add + IL_0027: stloc.1 + IL_0028: ldloc.1 + IL_0029: ldloc.0 + IL_002a: blt.un.s IL_0019 + + IL_002c: ret + } + + } + + .field static assembly uint32 c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .method public specialname static uint32 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld uint32 assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(uint32 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld uint32 assembly::c@1 + IL_0006: ret + } + + .method private specialname rtspecialname static void .cctor() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int32 ''.$assembly::init@ + IL_0006: ldsfld int32 ''.$assembly::init@ + IL_000b: pop + IL_000c: ret + } + + .method assembly specialname static void staticInitialization@() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld uint32 assembly::c@1 + IL_0006: ret + } + + .property uint32 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(uint32) + .get uint32 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: call void assembly::staticInitialization@() + IL_0005: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt64.fs.RealInternalSignatureOff.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt64.fs.RealInternalSignatureOff.OptimizeOn.il.bsl new file mode 100644 index 00000000000..3d0d7b7b1c5 --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt64.fs.RealInternalSignatureOff.OptimizeOn.il.bsl @@ -0,0 +1,578 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1) + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stloc.0 + IL_0003: ldc.i4.s 10 + IL_0005: conv.i8 + IL_0006: stloc.1 + IL_0007: br.s IL_0019 + + IL_0009: ldloc.1 + IL_000a: call void assembly::set_c(uint64) + IL_000f: ldloc.1 + IL_0010: ldc.i4.1 + IL_0011: conv.i8 + IL_0012: add + IL_0013: stloc.1 + IL_0014: ldloc.0 + IL_0015: ldc.i4.1 + IL_0016: conv.i8 + IL_0017: add + IL_0018: stloc.0 + IL_0019: ldloc.0 + IL_001a: ldc.i4.0 + IL_001b: conv.i8 + IL_001c: blt.un.s IL_0009 + + IL_001e: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1) + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stloc.0 + IL_0003: ldc.i4.1 + IL_0004: conv.i8 + IL_0005: stloc.1 + IL_0006: br.s IL_0018 + + IL_0008: ldloc.1 + IL_0009: call void assembly::set_c(uint64) + IL_000e: ldloc.1 + IL_000f: ldc.i4.1 + IL_0010: conv.i8 + IL_0011: add + IL_0012: stloc.1 + IL_0013: ldloc.0 + IL_0014: ldc.i4.1 + IL_0015: conv.i8 + IL_0016: add + IL_0017: stloc.0 + IL_0018: ldloc.0 + IL_0019: ldc.i4.s 10 + IL_001b: conv.i8 + IL_001c: blt.un.s IL_0008 + + IL_001e: ret + } + + .method public static void constStart(uint64 start) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + uint64 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: conv.i8 + IL_0003: ldarg.0 + IL_0004: bge.un.s IL_000b + + IL_0006: ldc.i4.0 + IL_0007: conv.i8 + IL_0008: nop + IL_0009: br.s IL_0014 + + IL_000b: ldc.i4.s 10 + IL_000d: conv.i8 + IL_000e: ldarg.0 + IL_000f: sub + IL_0010: ldc.i4.1 + IL_0011: conv.i8 + IL_0012: add.ovf.un + IL_0013: nop + IL_0014: stloc.0 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.1 + IL_0018: ldarg.0 + IL_0019: stloc.2 + IL_001a: br.s IL_002c + + IL_001c: ldloc.2 + IL_001d: call void assembly::set_c(uint64) + IL_0022: ldloc.2 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.2 + IL_0027: ldloc.1 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.1 + IL_002c: ldloc.1 + IL_002d: ldloc.0 + IL_002e: blt.un.s IL_001c + + IL_0030: ret + } + + .method public static void constFinish(uint64 finish) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + uint64 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: conv.i8 + IL_0003: bge.un.s IL_000a + + IL_0005: ldc.i4.0 + IL_0006: conv.i8 + IL_0007: nop + IL_0008: br.s IL_0012 + + IL_000a: ldarg.0 + IL_000b: ldc.i4.1 + IL_000c: conv.i8 + IL_000d: sub + IL_000e: ldc.i4.1 + IL_000f: conv.i8 + IL_0010: add.ovf.un + IL_0011: nop + IL_0012: stloc.0 + IL_0013: ldc.i4.0 + IL_0014: conv.i8 + IL_0015: stloc.1 + IL_0016: ldc.i4.1 + IL_0017: conv.i8 + IL_0018: stloc.2 + IL_0019: br.s IL_002b + + IL_001b: ldloc.2 + IL_001c: call void assembly::set_c(uint64) + IL_0021: ldloc.2 + IL_0022: ldc.i4.1 + IL_0023: conv.i8 + IL_0024: add + IL_0025: stloc.2 + IL_0026: ldloc.1 + IL_0027: ldc.i4.1 + IL_0028: conv.i8 + IL_0029: add + IL_002a: stloc.1 + IL_002b: ldloc.1 + IL_002c: ldloc.0 + IL_002d: blt.un.s IL_001b + + IL_002f: ret + } + + .method public static void annotatedStart(uint64 start, + uint64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + uint64 V_3, + uint64 V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(uint64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.1 + IL_0037: ldarg.0 + IL_0038: bge.un.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.1 + IL_0040: ldarg.0 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.3 + IL_004a: ldarg.0 + IL_004b: stloc.s V_4 + IL_004d: br.s IL_0062 + + IL_004f: ldloc.s V_4 + IL_0051: call void assembly::set_c(uint64) + IL_0056: ldloc.s V_4 + IL_0058: ldc.i4.1 + IL_0059: conv.i8 + IL_005a: add + IL_005b: stloc.s V_4 + IL_005d: ldloc.3 + IL_005e: ldc.i4.1 + IL_005f: conv.i8 + IL_0060: add + IL_0061: stloc.3 + IL_0062: ldloc.3 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + .method public static void annotatedFinish(uint64 start, + uint64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + uint64 V_3, + uint64 V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(uint64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.1 + IL_0037: ldarg.0 + IL_0038: bge.un.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.1 + IL_0040: ldarg.0 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.3 + IL_004a: ldarg.0 + IL_004b: stloc.s V_4 + IL_004d: br.s IL_0062 + + IL_004f: ldloc.s V_4 + IL_0051: call void assembly::set_c(uint64) + IL_0056: ldloc.s V_4 + IL_0058: ldc.i4.1 + IL_0059: conv.i8 + IL_005a: add + IL_005b: stloc.s V_4 + IL_005d: ldloc.3 + IL_005e: ldc.i4.1 + IL_005f: conv.i8 + IL_0060: add + IL_0061: stloc.3 + IL_0062: ldloc.3 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + .method public static void inferredStartAndFinish(uint64 start, + uint64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + uint64 V_3, + uint64 V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(uint64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.1 + IL_0037: ldarg.0 + IL_0038: bge.un.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.1 + IL_0040: ldarg.0 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.3 + IL_004a: ldarg.0 + IL_004b: stloc.s V_4 + IL_004d: br.s IL_0062 + + IL_004f: ldloc.s V_4 + IL_0051: call void assembly::set_c(uint64) + IL_0056: ldloc.s V_4 + IL_0058: ldc.i4.1 + IL_0059: conv.i8 + IL_005a: add + IL_005b: stloc.s V_4 + IL_005d: ldloc.3 + IL_005e: ldc.i4.1 + IL_005f: conv.i8 + IL_0060: add + IL_0061: stloc.3 + IL_0062: ldloc.3 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + } + + .method public specialname static uint64 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld uint64 ''.$assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(uint64 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld uint64 ''.$assembly::c@1 + IL_0006: ret + } + + .property uint64 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(uint64) + .get uint64 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly uint64 c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stsfld uint64 ''.$assembly::c@1 + IL_0007: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt64.fs.RealInternalSignatureOn.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt64.fs.RealInternalSignatureOn.OptimizeOn.il.bsl new file mode 100644 index 00000000000..3c22e0432c1 --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUInt64.fs.RealInternalSignatureOn.OptimizeOn.il.bsl @@ -0,0 +1,597 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1) + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stloc.0 + IL_0003: ldc.i4.s 10 + IL_0005: conv.i8 + IL_0006: stloc.1 + IL_0007: br.s IL_0019 + + IL_0009: ldloc.1 + IL_000a: call void assembly::set_c(uint64) + IL_000f: ldloc.1 + IL_0010: ldc.i4.1 + IL_0011: conv.i8 + IL_0012: add + IL_0013: stloc.1 + IL_0014: ldloc.0 + IL_0015: ldc.i4.1 + IL_0016: conv.i8 + IL_0017: add + IL_0018: stloc.0 + IL_0019: ldloc.0 + IL_001a: ldc.i4.0 + IL_001b: conv.i8 + IL_001c: blt.un.s IL_0009 + + IL_001e: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1) + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stloc.0 + IL_0003: ldc.i4.1 + IL_0004: conv.i8 + IL_0005: stloc.1 + IL_0006: br.s IL_0018 + + IL_0008: ldloc.1 + IL_0009: call void assembly::set_c(uint64) + IL_000e: ldloc.1 + IL_000f: ldc.i4.1 + IL_0010: conv.i8 + IL_0011: add + IL_0012: stloc.1 + IL_0013: ldloc.0 + IL_0014: ldc.i4.1 + IL_0015: conv.i8 + IL_0016: add + IL_0017: stloc.0 + IL_0018: ldloc.0 + IL_0019: ldc.i4.s 10 + IL_001b: conv.i8 + IL_001c: blt.un.s IL_0008 + + IL_001e: ret + } + + .method public static void constStart(uint64 start) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + uint64 V_2) + IL_0000: ldc.i4.s 10 + IL_0002: conv.i8 + IL_0003: ldarg.0 + IL_0004: bge.un.s IL_000b + + IL_0006: ldc.i4.0 + IL_0007: conv.i8 + IL_0008: nop + IL_0009: br.s IL_0014 + + IL_000b: ldc.i4.s 10 + IL_000d: conv.i8 + IL_000e: ldarg.0 + IL_000f: sub + IL_0010: ldc.i4.1 + IL_0011: conv.i8 + IL_0012: add.ovf.un + IL_0013: nop + IL_0014: stloc.0 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.1 + IL_0018: ldarg.0 + IL_0019: stloc.2 + IL_001a: br.s IL_002c + + IL_001c: ldloc.2 + IL_001d: call void assembly::set_c(uint64) + IL_0022: ldloc.2 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.2 + IL_0027: ldloc.1 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.1 + IL_002c: ldloc.1 + IL_002d: ldloc.0 + IL_002e: blt.un.s IL_001c + + IL_0030: ret + } + + .method public static void constFinish(uint64 finish) cil managed + { + + .maxstack 4 + .locals init (uint64 V_0, + uint64 V_1, + uint64 V_2) + IL_0000: ldarg.0 + IL_0001: ldc.i4.1 + IL_0002: conv.i8 + IL_0003: bge.un.s IL_000a + + IL_0005: ldc.i4.0 + IL_0006: conv.i8 + IL_0007: nop + IL_0008: br.s IL_0012 + + IL_000a: ldarg.0 + IL_000b: ldc.i4.1 + IL_000c: conv.i8 + IL_000d: sub + IL_000e: ldc.i4.1 + IL_000f: conv.i8 + IL_0010: add.ovf.un + IL_0011: nop + IL_0012: stloc.0 + IL_0013: ldc.i4.0 + IL_0014: conv.i8 + IL_0015: stloc.1 + IL_0016: ldc.i4.1 + IL_0017: conv.i8 + IL_0018: stloc.2 + IL_0019: br.s IL_002b + + IL_001b: ldloc.2 + IL_001c: call void assembly::set_c(uint64) + IL_0021: ldloc.2 + IL_0022: ldc.i4.1 + IL_0023: conv.i8 + IL_0024: add + IL_0025: stloc.2 + IL_0026: ldloc.1 + IL_0027: ldc.i4.1 + IL_0028: conv.i8 + IL_0029: add + IL_002a: stloc.1 + IL_002b: ldloc.1 + IL_002c: ldloc.0 + IL_002d: blt.un.s IL_001b + + IL_002f: ret + } + + .method public static void annotatedStart(uint64 start, + uint64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + uint64 V_3, + uint64 V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(uint64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.1 + IL_0037: ldarg.0 + IL_0038: bge.un.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.1 + IL_0040: ldarg.0 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.3 + IL_004a: ldarg.0 + IL_004b: stloc.s V_4 + IL_004d: br.s IL_0062 + + IL_004f: ldloc.s V_4 + IL_0051: call void assembly::set_c(uint64) + IL_0056: ldloc.s V_4 + IL_0058: ldc.i4.1 + IL_0059: conv.i8 + IL_005a: add + IL_005b: stloc.s V_4 + IL_005d: ldloc.3 + IL_005e: ldc.i4.1 + IL_005f: conv.i8 + IL_0060: add + IL_0061: stloc.3 + IL_0062: ldloc.3 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + .method public static void annotatedFinish(uint64 start, + uint64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + uint64 V_3, + uint64 V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(uint64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.1 + IL_0037: ldarg.0 + IL_0038: bge.un.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.1 + IL_0040: ldarg.0 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.3 + IL_004a: ldarg.0 + IL_004b: stloc.s V_4 + IL_004d: br.s IL_0062 + + IL_004f: ldloc.s V_4 + IL_0051: call void assembly::set_c(uint64) + IL_0056: ldloc.s V_4 + IL_0058: ldc.i4.1 + IL_0059: conv.i8 + IL_005a: add + IL_005b: stloc.s V_4 + IL_005d: ldloc.3 + IL_005e: ldc.i4.1 + IL_005f: conv.i8 + IL_0060: add + IL_0061: stloc.3 + IL_0062: ldloc.3 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + .method public static void inferredStartAndFinish(uint64 start, + uint64 finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (uint64 V_0, + bool V_1, + uint64 V_2, + uint64 V_3, + uint64 V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0009 + + IL_0004: ldc.i4.0 + IL_0005: conv.i8 + IL_0006: nop + IL_0007: br.s IL_000d + + IL_0009: ldarg.1 + IL_000a: ldarg.0 + IL_000b: sub + IL_000c: nop + IL_000d: stloc.0 + IL_000e: ldloc.0 + IL_000f: ldc.i4.m1 + IL_0010: conv.i8 + IL_0011: bne.un.s IL_0036 + + IL_0013: ldc.i4.1 + IL_0014: stloc.1 + IL_0015: ldc.i4.0 + IL_0016: conv.i8 + IL_0017: stloc.2 + IL_0018: ldarg.0 + IL_0019: stloc.3 + IL_001a: br.s IL_0032 + + IL_001c: ldloc.3 + IL_001d: call void assembly::set_c(uint64) + IL_0022: ldloc.3 + IL_0023: ldc.i4.1 + IL_0024: conv.i8 + IL_0025: add + IL_0026: stloc.3 + IL_0027: ldloc.2 + IL_0028: ldc.i4.1 + IL_0029: conv.i8 + IL_002a: add + IL_002b: stloc.2 + IL_002c: ldloc.2 + IL_002d: ldc.i4.0 + IL_002e: conv.i8 + IL_002f: cgt.un + IL_0031: stloc.1 + IL_0032: ldloc.1 + IL_0033: brtrue.s IL_001c + + IL_0035: ret + + IL_0036: ldarg.1 + IL_0037: ldarg.0 + IL_0038: bge.un.s IL_003f + + IL_003a: ldc.i4.0 + IL_003b: conv.i8 + IL_003c: nop + IL_003d: br.s IL_0046 + + IL_003f: ldarg.1 + IL_0040: ldarg.0 + IL_0041: sub + IL_0042: ldc.i4.1 + IL_0043: conv.i8 + IL_0044: add.ovf.un + IL_0045: nop + IL_0046: stloc.2 + IL_0047: ldc.i4.0 + IL_0048: conv.i8 + IL_0049: stloc.3 + IL_004a: ldarg.0 + IL_004b: stloc.s V_4 + IL_004d: br.s IL_0062 + + IL_004f: ldloc.s V_4 + IL_0051: call void assembly::set_c(uint64) + IL_0056: ldloc.s V_4 + IL_0058: ldc.i4.1 + IL_0059: conv.i8 + IL_005a: add + IL_005b: stloc.s V_4 + IL_005d: ldloc.3 + IL_005e: ldc.i4.1 + IL_005f: conv.i8 + IL_0060: add + IL_0061: stloc.3 + IL_0062: ldloc.3 + IL_0063: ldloc.2 + IL_0064: blt.un.s IL_004f + + IL_0066: ret + } + + } + + .field static assembly uint64 c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .method public specialname static uint64 get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld uint64 assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(uint64 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld uint64 assembly::c@1 + IL_0006: ret + } + + .method private specialname rtspecialname static void .cctor() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int32 ''.$assembly::init@ + IL_0006: ldsfld int32 ''.$assembly::init@ + IL_000b: pop + IL_000c: ret + } + + .method assembly specialname static void staticInitialization@() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: conv.i8 + IL_0002: stsfld uint64 assembly::c@1 + IL_0007: ret + } + + .property uint64 c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(uint64) + .get uint64 assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: call void assembly::staticInitialization@() + IL_0005: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUIntPtr.fs.RealInternalSignatureOff.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUIntPtr.fs.RealInternalSignatureOff.OptimizeOn.il.bsl new file mode 100644 index 00000000000..00d6a10c8c2 --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUIntPtr.fs.RealInternalSignatureOff.OptimizeOn.il.bsl @@ -0,0 +1,752 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (native uint V_0, + native uint V_1) + IL_0000: ldc.i8 0x0 + IL_0009: conv.u + IL_000a: stloc.0 + IL_000b: ldc.i8 0xa + IL_0014: conv.u + IL_0015: stloc.1 + IL_0016: br.s IL_0038 + + IL_0018: ldloc.1 + IL_0019: call void assembly::set_c(native uint) + IL_001e: ldloc.1 + IL_001f: ldc.i8 0x1 + IL_0028: conv.u + IL_0029: add + IL_002a: stloc.1 + IL_002b: ldloc.0 + IL_002c: ldc.i8 0x1 + IL_0035: conv.u + IL_0036: add + IL_0037: stloc.0 + IL_0038: ldloc.0 + IL_0039: ldc.i8 0x0 + IL_0042: conv.u + IL_0043: blt.un.s IL_0018 + + IL_0045: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (native uint V_0, + native uint V_1) + IL_0000: ldc.i8 0x0 + IL_0009: conv.u + IL_000a: stloc.0 + IL_000b: ldc.i8 0x1 + IL_0014: conv.u + IL_0015: stloc.1 + IL_0016: br.s IL_0038 + + IL_0018: ldloc.1 + IL_0019: call void assembly::set_c(native uint) + IL_001e: ldloc.1 + IL_001f: ldc.i8 0x1 + IL_0028: conv.u + IL_0029: add + IL_002a: stloc.1 + IL_002b: ldloc.0 + IL_002c: ldc.i8 0x1 + IL_0035: conv.u + IL_0036: add + IL_0037: stloc.0 + IL_0038: ldloc.0 + IL_0039: ldc.i8 0xa + IL_0042: conv.u + IL_0043: blt.un.s IL_0018 + + IL_0045: ret + } + + .method public static void constStart(native uint start) cil managed + { + + .maxstack 4 + .locals init (native uint V_0, + bool V_1, + native uint V_2, + native uint V_3, + native uint V_4) + IL_0000: ldc.i8 0xa + IL_0009: conv.u + IL_000a: ldarg.0 + IL_000b: bge.un.s IL_001a + + IL_000d: ldc.i8 0x0 + IL_0016: conv.u + IL_0017: nop + IL_0018: br.s IL_0027 + + IL_001a: ldc.i8 0xa + IL_0023: conv.u + IL_0024: ldarg.0 + IL_0025: sub + IL_0026: nop + IL_0027: stloc.0 + IL_0028: sizeof [runtime]System.IntPtr + IL_002e: ldc.i4.4 + IL_002f: bne.un.s IL_0041 + + IL_0031: ldloc.0 + IL_0032: ldc.i8 0xffffffff + IL_003b: conv.u + IL_003c: ceq + IL_003e: nop + IL_003f: br.s IL_004f + + IL_0041: ldloc.0 + IL_0042: ldc.i8 0xffffffffffffffff + IL_004b: conv.u + IL_004c: ceq + IL_004e: nop + IL_004f: brfalse.s IL_0094 + + IL_0051: ldc.i4.1 + IL_0052: stloc.1 + IL_0053: ldc.i8 0x0 + IL_005c: conv.u + IL_005d: stloc.2 + IL_005e: ldarg.0 + IL_005f: stloc.3 + IL_0060: br.s IL_0090 + + IL_0062: ldloc.3 + IL_0063: call void assembly::set_c(native uint) + IL_0068: ldloc.3 + IL_0069: ldc.i8 0x1 + IL_0072: conv.u + IL_0073: add + IL_0074: stloc.3 + IL_0075: ldloc.2 + IL_0076: ldc.i8 0x1 + IL_007f: conv.u + IL_0080: add + IL_0081: stloc.2 + IL_0082: ldloc.2 + IL_0083: ldc.i8 0x0 + IL_008c: conv.u + IL_008d: cgt.un + IL_008f: stloc.1 + IL_0090: ldloc.1 + IL_0091: brtrue.s IL_0062 + + IL_0093: ret + + IL_0094: ldc.i8 0xa + IL_009d: conv.u + IL_009e: ldarg.0 + IL_009f: bge.un.s IL_00ae + + IL_00a1: ldc.i8 0x0 + IL_00aa: conv.u + IL_00ab: nop + IL_00ac: br.s IL_00c6 + + IL_00ae: ldc.i8 0xa + IL_00b7: conv.u + IL_00b8: ldarg.0 + IL_00b9: sub + IL_00ba: ldc.i8 0x1 + IL_00c3: conv.u + IL_00c4: add.ovf.un + IL_00c5: nop + IL_00c6: stloc.2 + IL_00c7: ldc.i8 0x0 + IL_00d0: conv.u + IL_00d1: stloc.3 + IL_00d2: ldarg.0 + IL_00d3: stloc.s V_4 + IL_00d5: br.s IL_00fa + + IL_00d7: ldloc.s V_4 + IL_00d9: call void assembly::set_c(native uint) + IL_00de: ldloc.s V_4 + IL_00e0: ldc.i8 0x1 + IL_00e9: conv.u + IL_00ea: add + IL_00eb: stloc.s V_4 + IL_00ed: ldloc.3 + IL_00ee: ldc.i8 0x1 + IL_00f7: conv.u + IL_00f8: add + IL_00f9: stloc.3 + IL_00fa: ldloc.3 + IL_00fb: ldloc.2 + IL_00fc: blt.un.s IL_00d7 + + IL_00fe: ret + } + + .method public static void constFinish(native uint finish) cil managed + { + + .maxstack 4 + .locals init (native uint V_0, + bool V_1, + native uint V_2, + native uint V_3, + native uint V_4) + IL_0000: ldarg.0 + IL_0001: ldc.i8 0x1 + IL_000a: conv.u + IL_000b: bge.un.s IL_001a + + IL_000d: ldc.i8 0x0 + IL_0016: conv.u + IL_0017: nop + IL_0018: br.s IL_0027 + + IL_001a: ldarg.0 + IL_001b: ldc.i8 0x1 + IL_0024: conv.u + IL_0025: sub + IL_0026: nop + IL_0027: stloc.0 + IL_0028: sizeof [runtime]System.IntPtr + IL_002e: ldc.i4.4 + IL_002f: bne.un.s IL_0041 + + IL_0031: ldloc.0 + IL_0032: ldc.i8 0xffffffff + IL_003b: conv.u + IL_003c: ceq + IL_003e: nop + IL_003f: br.s IL_004f + + IL_0041: ldloc.0 + IL_0042: ldc.i8 0xffffffffffffffff + IL_004b: conv.u + IL_004c: ceq + IL_004e: nop + IL_004f: brfalse.s IL_009d + + IL_0051: ldc.i4.1 + IL_0052: stloc.1 + IL_0053: ldc.i8 0x0 + IL_005c: conv.u + IL_005d: stloc.2 + IL_005e: ldc.i8 0x1 + IL_0067: conv.u + IL_0068: stloc.3 + IL_0069: br.s IL_0099 + + IL_006b: ldloc.3 + IL_006c: call void assembly::set_c(native uint) + IL_0071: ldloc.3 + IL_0072: ldc.i8 0x1 + IL_007b: conv.u + IL_007c: add + IL_007d: stloc.3 + IL_007e: ldloc.2 + IL_007f: ldc.i8 0x1 + IL_0088: conv.u + IL_0089: add + IL_008a: stloc.2 + IL_008b: ldloc.2 + IL_008c: ldc.i8 0x0 + IL_0095: conv.u + IL_0096: cgt.un + IL_0098: stloc.1 + IL_0099: ldloc.1 + IL_009a: brtrue.s IL_006b + + IL_009c: ret + + IL_009d: ldarg.0 + IL_009e: ldc.i8 0x1 + IL_00a7: conv.u + IL_00a8: bge.un.s IL_00b7 + + IL_00aa: ldc.i8 0x0 + IL_00b3: conv.u + IL_00b4: nop + IL_00b5: br.s IL_00cf + + IL_00b7: ldarg.0 + IL_00b8: ldc.i8 0x1 + IL_00c1: conv.u + IL_00c2: sub + IL_00c3: ldc.i8 0x1 + IL_00cc: conv.u + IL_00cd: add.ovf.un + IL_00ce: nop + IL_00cf: stloc.2 + IL_00d0: ldc.i8 0x0 + IL_00d9: conv.u + IL_00da: stloc.3 + IL_00db: ldc.i8 0x1 + IL_00e4: conv.u + IL_00e5: stloc.s V_4 + IL_00e7: br.s IL_010c + + IL_00e9: ldloc.s V_4 + IL_00eb: call void assembly::set_c(native uint) + IL_00f0: ldloc.s V_4 + IL_00f2: ldc.i8 0x1 + IL_00fb: conv.u + IL_00fc: add + IL_00fd: stloc.s V_4 + IL_00ff: ldloc.3 + IL_0100: ldc.i8 0x1 + IL_0109: conv.u + IL_010a: add + IL_010b: stloc.3 + IL_010c: ldloc.3 + IL_010d: ldloc.2 + IL_010e: blt.un.s IL_00e9 + + IL_0110: ret + } + + .method public static void annotatedStart(native uint start, + native uint finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native uint V_0, + bool V_1, + native uint V_2, + native uint V_3, + native uint V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.u + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.1 + IL_0012: ldarg.0 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.u + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native uint) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0x1 + IL_0060: conv.u + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.u + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.u + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.1 + IL_0083: ldarg.0 + IL_0084: bge.un.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.u + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.1 + IL_0094: ldarg.0 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.u + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.u + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native uint) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0x1 + IL_00c5: conv.u + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.u + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + .method public static void annotatedFinish(native uint start, + native uint finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native uint V_0, + bool V_1, + native uint V_2, + native uint V_3, + native uint V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.u + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.1 + IL_0012: ldarg.0 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.u + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native uint) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0x1 + IL_0060: conv.u + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.u + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.u + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.1 + IL_0083: ldarg.0 + IL_0084: bge.un.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.u + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.1 + IL_0094: ldarg.0 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.u + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.u + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native uint) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0x1 + IL_00c5: conv.u + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.u + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + .method public static void inferredStartAndFinish(native uint start, + native uint finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native uint V_0, + bool V_1, + native uint V_2, + native uint V_3, + native uint V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.u + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.1 + IL_0012: ldarg.0 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.u + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native uint) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0x1 + IL_0060: conv.u + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.u + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.u + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.1 + IL_0083: ldarg.0 + IL_0084: bge.un.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.u + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.1 + IL_0094: ldarg.0 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.u + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.u + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native uint) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0x1 + IL_00c5: conv.u + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.u + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + } + + .method public specialname static native uint get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld native uint ''.$assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(native uint 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld native uint ''.$assembly::c@1 + IL_0006: ret + } + + .property native uint c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(native uint) + .get native uint assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly native uint c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: ldc.i8 0x0 + IL_0009: conv.u + IL_000a: stsfld native uint ''.$assembly::c@1 + IL_000f: ret + } + +} + + + + + + diff --git a/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUIntPtr.fs.RealInternalSignatureOn.OptimizeOn.il.bsl b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUIntPtr.fs.RealInternalSignatureOn.OptimizeOn.il.bsl new file mode 100644 index 00000000000..c4823293078 --- /dev/null +++ b/tests/FSharp.Compiler.ComponentTests/EmittedIL/ForLoop/ForLoopUIntPtr.fs.RealInternalSignatureOn.OptimizeOn.il.bsl @@ -0,0 +1,771 @@ + + + + + +.assembly extern runtime { } +.assembly extern FSharp.Core { } +.assembly assembly +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.FSharpInterfaceDataVersionAttribute::.ctor(int32, + int32, + int32) = ( 01 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 ) + + + + + .hash algorithm 0x00008004 + .ver 0:0:0:0 +} +.module assembly.exe + +.imagebase {value} +.file alignment 0x00000200 +.stackreserve 0x00100000 +.subsystem 0x0003 +.corflags 0x00000001 + + + + + +.class public abstract auto ansi sealed assembly + extends [runtime]System.Object +{ + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .class abstract auto ansi sealed nested public Up + extends [runtime]System.Object + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 07 00 00 00 00 00 ) + .method public static void constEmpty() cil managed + { + + .maxstack 4 + .locals init (native uint V_0, + native uint V_1) + IL_0000: ldc.i8 0x0 + IL_0009: conv.u + IL_000a: stloc.0 + IL_000b: ldc.i8 0xa + IL_0014: conv.u + IL_0015: stloc.1 + IL_0016: br.s IL_0038 + + IL_0018: ldloc.1 + IL_0019: call void assembly::set_c(native uint) + IL_001e: ldloc.1 + IL_001f: ldc.i8 0x1 + IL_0028: conv.u + IL_0029: add + IL_002a: stloc.1 + IL_002b: ldloc.0 + IL_002c: ldc.i8 0x1 + IL_0035: conv.u + IL_0036: add + IL_0037: stloc.0 + IL_0038: ldloc.0 + IL_0039: ldc.i8 0x0 + IL_0042: conv.u + IL_0043: blt.un.s IL_0018 + + IL_0045: ret + } + + .method public static void constNonEmpty() cil managed + { + + .maxstack 4 + .locals init (native uint V_0, + native uint V_1) + IL_0000: ldc.i8 0x0 + IL_0009: conv.u + IL_000a: stloc.0 + IL_000b: ldc.i8 0x1 + IL_0014: conv.u + IL_0015: stloc.1 + IL_0016: br.s IL_0038 + + IL_0018: ldloc.1 + IL_0019: call void assembly::set_c(native uint) + IL_001e: ldloc.1 + IL_001f: ldc.i8 0x1 + IL_0028: conv.u + IL_0029: add + IL_002a: stloc.1 + IL_002b: ldloc.0 + IL_002c: ldc.i8 0x1 + IL_0035: conv.u + IL_0036: add + IL_0037: stloc.0 + IL_0038: ldloc.0 + IL_0039: ldc.i8 0xa + IL_0042: conv.u + IL_0043: blt.un.s IL_0018 + + IL_0045: ret + } + + .method public static void constStart(native uint start) cil managed + { + + .maxstack 4 + .locals init (native uint V_0, + bool V_1, + native uint V_2, + native uint V_3, + native uint V_4) + IL_0000: ldc.i8 0xa + IL_0009: conv.u + IL_000a: ldarg.0 + IL_000b: bge.un.s IL_001a + + IL_000d: ldc.i8 0x0 + IL_0016: conv.u + IL_0017: nop + IL_0018: br.s IL_0027 + + IL_001a: ldc.i8 0xa + IL_0023: conv.u + IL_0024: ldarg.0 + IL_0025: sub + IL_0026: nop + IL_0027: stloc.0 + IL_0028: sizeof [runtime]System.IntPtr + IL_002e: ldc.i4.4 + IL_002f: bne.un.s IL_0041 + + IL_0031: ldloc.0 + IL_0032: ldc.i8 0xffffffff + IL_003b: conv.u + IL_003c: ceq + IL_003e: nop + IL_003f: br.s IL_004f + + IL_0041: ldloc.0 + IL_0042: ldc.i8 0xffffffffffffffff + IL_004b: conv.u + IL_004c: ceq + IL_004e: nop + IL_004f: brfalse.s IL_0094 + + IL_0051: ldc.i4.1 + IL_0052: stloc.1 + IL_0053: ldc.i8 0x0 + IL_005c: conv.u + IL_005d: stloc.2 + IL_005e: ldarg.0 + IL_005f: stloc.3 + IL_0060: br.s IL_0090 + + IL_0062: ldloc.3 + IL_0063: call void assembly::set_c(native uint) + IL_0068: ldloc.3 + IL_0069: ldc.i8 0x1 + IL_0072: conv.u + IL_0073: add + IL_0074: stloc.3 + IL_0075: ldloc.2 + IL_0076: ldc.i8 0x1 + IL_007f: conv.u + IL_0080: add + IL_0081: stloc.2 + IL_0082: ldloc.2 + IL_0083: ldc.i8 0x0 + IL_008c: conv.u + IL_008d: cgt.un + IL_008f: stloc.1 + IL_0090: ldloc.1 + IL_0091: brtrue.s IL_0062 + + IL_0093: ret + + IL_0094: ldc.i8 0xa + IL_009d: conv.u + IL_009e: ldarg.0 + IL_009f: bge.un.s IL_00ae + + IL_00a1: ldc.i8 0x0 + IL_00aa: conv.u + IL_00ab: nop + IL_00ac: br.s IL_00c6 + + IL_00ae: ldc.i8 0xa + IL_00b7: conv.u + IL_00b8: ldarg.0 + IL_00b9: sub + IL_00ba: ldc.i8 0x1 + IL_00c3: conv.u + IL_00c4: add.ovf.un + IL_00c5: nop + IL_00c6: stloc.2 + IL_00c7: ldc.i8 0x0 + IL_00d0: conv.u + IL_00d1: stloc.3 + IL_00d2: ldarg.0 + IL_00d3: stloc.s V_4 + IL_00d5: br.s IL_00fa + + IL_00d7: ldloc.s V_4 + IL_00d9: call void assembly::set_c(native uint) + IL_00de: ldloc.s V_4 + IL_00e0: ldc.i8 0x1 + IL_00e9: conv.u + IL_00ea: add + IL_00eb: stloc.s V_4 + IL_00ed: ldloc.3 + IL_00ee: ldc.i8 0x1 + IL_00f7: conv.u + IL_00f8: add + IL_00f9: stloc.3 + IL_00fa: ldloc.3 + IL_00fb: ldloc.2 + IL_00fc: blt.un.s IL_00d7 + + IL_00fe: ret + } + + .method public static void constFinish(native uint finish) cil managed + { + + .maxstack 4 + .locals init (native uint V_0, + bool V_1, + native uint V_2, + native uint V_3, + native uint V_4) + IL_0000: ldarg.0 + IL_0001: ldc.i8 0x1 + IL_000a: conv.u + IL_000b: bge.un.s IL_001a + + IL_000d: ldc.i8 0x0 + IL_0016: conv.u + IL_0017: nop + IL_0018: br.s IL_0027 + + IL_001a: ldarg.0 + IL_001b: ldc.i8 0x1 + IL_0024: conv.u + IL_0025: sub + IL_0026: nop + IL_0027: stloc.0 + IL_0028: sizeof [runtime]System.IntPtr + IL_002e: ldc.i4.4 + IL_002f: bne.un.s IL_0041 + + IL_0031: ldloc.0 + IL_0032: ldc.i8 0xffffffff + IL_003b: conv.u + IL_003c: ceq + IL_003e: nop + IL_003f: br.s IL_004f + + IL_0041: ldloc.0 + IL_0042: ldc.i8 0xffffffffffffffff + IL_004b: conv.u + IL_004c: ceq + IL_004e: nop + IL_004f: brfalse.s IL_009d + + IL_0051: ldc.i4.1 + IL_0052: stloc.1 + IL_0053: ldc.i8 0x0 + IL_005c: conv.u + IL_005d: stloc.2 + IL_005e: ldc.i8 0x1 + IL_0067: conv.u + IL_0068: stloc.3 + IL_0069: br.s IL_0099 + + IL_006b: ldloc.3 + IL_006c: call void assembly::set_c(native uint) + IL_0071: ldloc.3 + IL_0072: ldc.i8 0x1 + IL_007b: conv.u + IL_007c: add + IL_007d: stloc.3 + IL_007e: ldloc.2 + IL_007f: ldc.i8 0x1 + IL_0088: conv.u + IL_0089: add + IL_008a: stloc.2 + IL_008b: ldloc.2 + IL_008c: ldc.i8 0x0 + IL_0095: conv.u + IL_0096: cgt.un + IL_0098: stloc.1 + IL_0099: ldloc.1 + IL_009a: brtrue.s IL_006b + + IL_009c: ret + + IL_009d: ldarg.0 + IL_009e: ldc.i8 0x1 + IL_00a7: conv.u + IL_00a8: bge.un.s IL_00b7 + + IL_00aa: ldc.i8 0x0 + IL_00b3: conv.u + IL_00b4: nop + IL_00b5: br.s IL_00cf + + IL_00b7: ldarg.0 + IL_00b8: ldc.i8 0x1 + IL_00c1: conv.u + IL_00c2: sub + IL_00c3: ldc.i8 0x1 + IL_00cc: conv.u + IL_00cd: add.ovf.un + IL_00ce: nop + IL_00cf: stloc.2 + IL_00d0: ldc.i8 0x0 + IL_00d9: conv.u + IL_00da: stloc.3 + IL_00db: ldc.i8 0x1 + IL_00e4: conv.u + IL_00e5: stloc.s V_4 + IL_00e7: br.s IL_010c + + IL_00e9: ldloc.s V_4 + IL_00eb: call void assembly::set_c(native uint) + IL_00f0: ldloc.s V_4 + IL_00f2: ldc.i8 0x1 + IL_00fb: conv.u + IL_00fc: add + IL_00fd: stloc.s V_4 + IL_00ff: ldloc.3 + IL_0100: ldc.i8 0x1 + IL_0109: conv.u + IL_010a: add + IL_010b: stloc.3 + IL_010c: ldloc.3 + IL_010d: ldloc.2 + IL_010e: blt.un.s IL_00e9 + + IL_0110: ret + } + + .method public static void annotatedStart(native uint start, + native uint finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native uint V_0, + bool V_1, + native uint V_2, + native uint V_3, + native uint V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.u + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.1 + IL_0012: ldarg.0 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.u + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native uint) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0x1 + IL_0060: conv.u + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.u + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.u + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.1 + IL_0083: ldarg.0 + IL_0084: bge.un.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.u + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.1 + IL_0094: ldarg.0 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.u + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.u + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native uint) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0x1 + IL_00c5: conv.u + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.u + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + .method public static void annotatedFinish(native uint start, + native uint finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native uint V_0, + bool V_1, + native uint V_2, + native uint V_3, + native uint V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.u + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.1 + IL_0012: ldarg.0 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.u + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native uint) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0x1 + IL_0060: conv.u + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.u + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.u + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.1 + IL_0083: ldarg.0 + IL_0084: bge.un.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.u + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.1 + IL_0094: ldarg.0 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.u + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.u + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native uint) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0x1 + IL_00c5: conv.u + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.u + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + .method public static void inferredStartAndFinish(native uint start, + native uint finish) cil managed + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationArgumentCountsAttribute::.ctor(int32[]) = ( 01 00 02 00 00 00 01 00 00 00 01 00 00 00 00 00 ) + + .maxstack 4 + .locals init (native uint V_0, + bool V_1, + native uint V_2, + native uint V_3, + native uint V_4) + IL_0000: ldarg.1 + IL_0001: ldarg.0 + IL_0002: bge.un.s IL_0011 + + IL_0004: ldc.i8 0x0 + IL_000d: conv.u + IL_000e: nop + IL_000f: br.s IL_0015 + + IL_0011: ldarg.1 + IL_0012: ldarg.0 + IL_0013: sub + IL_0014: nop + IL_0015: stloc.0 + IL_0016: sizeof [runtime]System.IntPtr + IL_001c: ldc.i4.4 + IL_001d: bne.un.s IL_002f + + IL_001f: ldloc.0 + IL_0020: ldc.i8 0xffffffff + IL_0029: conv.u + IL_002a: ceq + IL_002c: nop + IL_002d: br.s IL_003d + + IL_002f: ldloc.0 + IL_0030: ldc.i8 0xffffffffffffffff + IL_0039: conv.u + IL_003a: ceq + IL_003c: nop + IL_003d: brfalse.s IL_0082 + + IL_003f: ldc.i4.1 + IL_0040: stloc.1 + IL_0041: ldc.i8 0x0 + IL_004a: conv.u + IL_004b: stloc.2 + IL_004c: ldarg.0 + IL_004d: stloc.3 + IL_004e: br.s IL_007e + + IL_0050: ldloc.3 + IL_0051: call void assembly::set_c(native uint) + IL_0056: ldloc.3 + IL_0057: ldc.i8 0x1 + IL_0060: conv.u + IL_0061: add + IL_0062: stloc.3 + IL_0063: ldloc.2 + IL_0064: ldc.i8 0x1 + IL_006d: conv.u + IL_006e: add + IL_006f: stloc.2 + IL_0070: ldloc.2 + IL_0071: ldc.i8 0x0 + IL_007a: conv.u + IL_007b: cgt.un + IL_007d: stloc.1 + IL_007e: ldloc.1 + IL_007f: brtrue.s IL_0050 + + IL_0081: ret + + IL_0082: ldarg.1 + IL_0083: ldarg.0 + IL_0084: bge.un.s IL_0093 + + IL_0086: ldc.i8 0x0 + IL_008f: conv.u + IL_0090: nop + IL_0091: br.s IL_00a2 + + IL_0093: ldarg.1 + IL_0094: ldarg.0 + IL_0095: sub + IL_0096: ldc.i8 0x1 + IL_009f: conv.u + IL_00a0: add.ovf.un + IL_00a1: nop + IL_00a2: stloc.2 + IL_00a3: ldc.i8 0x0 + IL_00ac: conv.u + IL_00ad: stloc.3 + IL_00ae: ldarg.0 + IL_00af: stloc.s V_4 + IL_00b1: br.s IL_00d6 + + IL_00b3: ldloc.s V_4 + IL_00b5: call void assembly::set_c(native uint) + IL_00ba: ldloc.s V_4 + IL_00bc: ldc.i8 0x1 + IL_00c5: conv.u + IL_00c6: add + IL_00c7: stloc.s V_4 + IL_00c9: ldloc.3 + IL_00ca: ldc.i8 0x1 + IL_00d3: conv.u + IL_00d4: add + IL_00d5: stloc.3 + IL_00d6: ldloc.3 + IL_00d7: ldloc.2 + IL_00d8: blt.un.s IL_00b3 + + IL_00da: ret + } + + } + + .field static assembly native uint c@1 + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .method public specialname static native uint get_c() cil managed + { + + .maxstack 8 + IL_0000: ldsfld native uint assembly::c@1 + IL_0005: ret + } + + .method public specialname static void set_c(native uint 'value') cil managed + { + + .maxstack 8 + IL_0000: ldarg.0 + IL_0001: stsfld native uint assembly::c@1 + IL_0006: ret + } + + .method private specialname rtspecialname static void .cctor() cil managed + { + + .maxstack 8 + IL_0000: ldc.i4.0 + IL_0001: stsfld int32 ''.$assembly::init@ + IL_0006: ldsfld int32 ''.$assembly::init@ + IL_000b: pop + IL_000c: ret + } + + .method assembly specialname static void staticInitialization@() cil managed + { + + .maxstack 8 + IL_0000: ldc.i8 0x0 + IL_0009: conv.u + IL_000a: stsfld native uint assembly::c@1 + IL_000f: ret + } + + .property native uint c() + { + .custom instance void [FSharp.Core]Microsoft.FSharp.Core.CompilationMappingAttribute::.ctor(valuetype [FSharp.Core]Microsoft.FSharp.Core.SourceConstructFlags) = ( 01 00 09 00 00 00 00 00 ) + .set void assembly::set_c(native uint) + .get native uint assembly::get_c() + } +} + +.class private abstract auto ansi sealed ''.$assembly + extends [runtime]System.Object +{ + .field static assembly int32 init@ + .custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 ) + .custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 ) + .custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 ) + .method public static void main@() cil managed + { + .entrypoint + + .maxstack 8 + IL_0000: call void assembly::staticInitialization@() + IL_0005: ret + } + +} + + + + + +