Skip to content

Commit 3b27d90

Browse files
committed
Async baselines
1 parent 87e6132 commit 3b27d90

8 files changed

Lines changed: 204 additions & 1272 deletions

tests/FSharp.Compiler.ComponentTests/EmittedIL/AsyncExpressionStepping/AsyncExpressionSteppingTest3.fs.RealInternalSignatureOff.il.debug.bsl

Lines changed: 5 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -37,42 +37,6 @@
3737
extends [runtime]System.Object
3838
{
3939
.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 )
40-
.class auto ansi serializable sealed nested assembly beforefieldinit 'f3@10-1'
41-
extends class [FSharp.Core]Microsoft.FSharp.Core.FSharpFunc`2<valuetype [FSharp.Core]Microsoft.FSharp.Control.AsyncActivation`1<int32>,class [FSharp.Core]Microsoft.FSharp.Control.AsyncReturn>
42-
{
43-
.field public int32 'value'
44-
.custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 )
45-
.custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 )
46-
.custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 )
47-
.method assembly specialname rtspecialname instance void .ctor(int32 'value') cil managed
48-
{
49-
.custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 )
50-
.custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 )
51-
52-
.maxstack 8
53-
IL_0000: ldarg.0
54-
IL_0001: call instance void class [FSharp.Core]Microsoft.FSharp.Core.FSharpFunc`2<valuetype [FSharp.Core]Microsoft.FSharp.Control.AsyncActivation`1<int32>,class [FSharp.Core]Microsoft.FSharp.Control.AsyncReturn>::.ctor()
55-
IL_0006: ldarg.0
56-
IL_0007: ldarg.1
57-
IL_0008: stfld int32 assembly/assembly/'f3@10-1'::'value'
58-
IL_000d: ret
59-
}
60-
61-
.method public strict virtual instance class [FSharp.Core]Microsoft.FSharp.Control.AsyncReturn Invoke(valuetype [FSharp.Core]Microsoft.FSharp.Control.AsyncActivation`1<int32> ctxt) cil managed
62-
{
63-
64-
.maxstack 8
65-
IL_0000: ldarg.1
66-
IL_0001: ldarg.0
67-
IL_0002: ldfld int32 assembly/assembly/'f3@10-1'::'value'
68-
IL_0007: tail.
69-
IL_0009: call class [FSharp.Core]Microsoft.FSharp.Control.AsyncReturn valuetype [FSharp.Core]Microsoft.FSharp.Control.AsyncActivation`1<int32>::Success(valuetype [FSharp.Core]Microsoft.FSharp.Control.AsyncActivation`1<!0>,
70-
!0)
71-
IL_000e: ret
72-
}
73-
74-
}
75-
7640
.class auto ansi serializable sealed nested assembly beforefieldinit f3@5
7741
extends class [FSharp.Core]Microsoft.FSharp.Core.FSharpFunc`2<class [FSharp.Core]Microsoft.FSharp.Core.Unit,class [FSharp.Core]Microsoft.FSharp.Control.FSharpAsync`1<int32>>
7842
{
@@ -100,9 +64,7 @@
10064
.maxstack 7
10165
.locals init (class [FSharp.Core]Microsoft.FSharp.Core.FSharpRef`1<int32> V_0,
10266
class [FSharp.Core]Microsoft.FSharp.Core.FSharpRef`1<int32> V_1,
103-
int32 V_2,
104-
class [FSharp.Core]Microsoft.FSharp.Control.FSharpAsyncBuilder V_3,
105-
int32 V_4)
67+
int32 V_2)
10668
IL_0000: ldc.i4.0
10769
IL_0001: call class [FSharp.Core]Microsoft.FSharp.Core.FSharpRef`1<!!0> [FSharp.Core]Microsoft.FSharp.Core.Operators::Ref<int32>(!!0)
10870
IL_0006: stloc.0
@@ -131,14 +93,10 @@
13193
IL_0039: stloc.2
13294
IL_003a: ldarg.0
13395
IL_003b: ldfld class [FSharp.Core]Microsoft.FSharp.Control.FSharpAsyncBuilder assembly/assembly/f3@5::builder@
134-
IL_0040: stloc.3
135-
IL_0041: ldloc.2
136-
IL_0042: stloc.s V_4
137-
IL_0044: ldloc.s V_4
138-
IL_0046: newobj instance void assembly/assembly/'f3@10-1'::.ctor(int32)
139-
IL_004b: tail.
140-
IL_004d: call class [FSharp.Core]Microsoft.FSharp.Control.FSharpAsync`1<!!0> [FSharp.Core]Microsoft.FSharp.Control.AsyncPrimitives::MakeAsync<int32>(class [FSharp.Core]Microsoft.FSharp.Core.FSharpFunc`2<valuetype [FSharp.Core]Microsoft.FSharp.Control.AsyncActivation`1<!!0>,class [FSharp.Core]Microsoft.FSharp.Control.AsyncReturn>)
141-
IL_0052: ret
96+
IL_0040: ldloc.2
97+
IL_0041: tail.
98+
IL_0043: callvirt instance class [FSharp.Core]Microsoft.FSharp.Control.FSharpAsync`1<!!0> [FSharp.Core]Microsoft.FSharp.Control.FSharpAsyncBuilder::Return<int32>(!!0)
99+
IL_0048: ret
142100
}
143101

144102
}

tests/FSharp.Compiler.ComponentTests/EmittedIL/AsyncExpressionStepping/AsyncExpressionSteppingTest3.fs.RealInternalSignatureOn.il.debug.bsl

Lines changed: 5 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -37,42 +37,6 @@
3737
extends [runtime]System.Object
3838
{
3939
.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 )
40-
.class auto ansi serializable sealed nested assembly beforefieldinit 'f3@10-1'
41-
extends class [FSharp.Core]Microsoft.FSharp.Core.FSharpFunc`2<valuetype [FSharp.Core]Microsoft.FSharp.Control.AsyncActivation`1<int32>,class [FSharp.Core]Microsoft.FSharp.Control.AsyncReturn>
42-
{
43-
.field public int32 'value'
44-
.custom instance void [runtime]System.Diagnostics.DebuggerBrowsableAttribute::.ctor(valuetype [runtime]System.Diagnostics.DebuggerBrowsableState) = ( 01 00 00 00 00 00 00 00 )
45-
.custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 )
46-
.custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 )
47-
.method assembly specialname rtspecialname instance void .ctor(int32 'value') cil managed
48-
{
49-
.custom instance void [runtime]System.Runtime.CompilerServices.CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 )
50-
.custom instance void [runtime]System.Diagnostics.DebuggerNonUserCodeAttribute::.ctor() = ( 01 00 00 00 )
51-
52-
.maxstack 8
53-
IL_0000: ldarg.0
54-
IL_0001: call instance void class [FSharp.Core]Microsoft.FSharp.Core.FSharpFunc`2<valuetype [FSharp.Core]Microsoft.FSharp.Control.AsyncActivation`1<int32>,class [FSharp.Core]Microsoft.FSharp.Control.AsyncReturn>::.ctor()
55-
IL_0006: ldarg.0
56-
IL_0007: ldarg.1
57-
IL_0008: stfld int32 assembly/assembly/'f3@10-1'::'value'
58-
IL_000d: ret
59-
}
60-
61-
.method public strict virtual instance class [FSharp.Core]Microsoft.FSharp.Control.AsyncReturn Invoke(valuetype [FSharp.Core]Microsoft.FSharp.Control.AsyncActivation`1<int32> ctxt) cil managed
62-
{
63-
64-
.maxstack 8
65-
IL_0000: ldarg.1
66-
IL_0001: ldarg.0
67-
IL_0002: ldfld int32 assembly/assembly/'f3@10-1'::'value'
68-
IL_0007: tail.
69-
IL_0009: call class [FSharp.Core]Microsoft.FSharp.Control.AsyncReturn valuetype [FSharp.Core]Microsoft.FSharp.Control.AsyncActivation`1<int32>::Success(valuetype [FSharp.Core]Microsoft.FSharp.Control.AsyncActivation`1<!0>,
70-
!0)
71-
IL_000e: ret
72-
}
73-
74-
}
75-
7640
.class auto ansi serializable sealed nested assembly beforefieldinit f3@5
7741
extends class [FSharp.Core]Microsoft.FSharp.Core.FSharpFunc`2<class [FSharp.Core]Microsoft.FSharp.Core.Unit,class [FSharp.Core]Microsoft.FSharp.Control.FSharpAsync`1<int32>>
7842
{
@@ -100,9 +64,7 @@
10064
.maxstack 7
10165
.locals init (class [FSharp.Core]Microsoft.FSharp.Core.FSharpRef`1<int32> V_0,
10266
class [FSharp.Core]Microsoft.FSharp.Core.FSharpRef`1<int32> V_1,
103-
int32 V_2,
104-
class [FSharp.Core]Microsoft.FSharp.Control.FSharpAsyncBuilder V_3,
105-
int32 V_4)
67+
int32 V_2)
10668
IL_0000: ldc.i4.0
10769
IL_0001: call class [FSharp.Core]Microsoft.FSharp.Core.FSharpRef`1<!!0> [FSharp.Core]Microsoft.FSharp.Core.Operators::Ref<int32>(!!0)
10870
IL_0006: stloc.0
@@ -131,14 +93,10 @@
13193
IL_0039: stloc.2
13294
IL_003a: ldarg.0
13395
IL_003b: ldfld class [FSharp.Core]Microsoft.FSharp.Control.FSharpAsyncBuilder assembly/assembly/f3@5::builder@
134-
IL_0040: stloc.3
135-
IL_0041: ldloc.2
136-
IL_0042: stloc.s V_4
137-
IL_0044: ldloc.s V_4
138-
IL_0046: newobj instance void assembly/assembly/'f3@10-1'::.ctor(int32)
139-
IL_004b: tail.
140-
IL_004d: call class [FSharp.Core]Microsoft.FSharp.Control.FSharpAsync`1<!!0> [FSharp.Core]Microsoft.FSharp.Control.AsyncPrimitives::MakeAsync<int32>(class [FSharp.Core]Microsoft.FSharp.Core.FSharpFunc`2<valuetype [FSharp.Core]Microsoft.FSharp.Control.AsyncActivation`1<!!0>,class [FSharp.Core]Microsoft.FSharp.Control.AsyncReturn>)
141-
IL_0052: ret
96+
IL_0040: ldloc.2
97+
IL_0041: tail.
98+
IL_0043: callvirt instance class [FSharp.Core]Microsoft.FSharp.Control.FSharpAsync`1<!!0> [FSharp.Core]Microsoft.FSharp.Control.FSharpAsyncBuilder::Return<int32>(!!0)
99+
IL_0048: ret
142100
}
143101

144102
}

0 commit comments

Comments
 (0)