Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
c445c57
Fix issues with package management subdirectories (#12381)
KevinRansom Nov 16, 2021
db2c9da
split large methods sensibly (#12397)
dsyme Nov 16, 2021
0458724
Add debug emit docs (#12411)
dsyme Nov 17, 2021
641ace3
Small typo (#12412)
jamil7 Nov 17, 2021
f0f9c17
[main] Update dependencies from dotnet/arcade (#12310)
dotnet-maestro[bot] Nov 17, 2021
9cba74d
Fix 12384: non-nested direct mutrec bindings (#12395)
dsyme Nov 19, 2021
57ef580
add fantomas tool to repo (#12403)
dsyme Nov 19, 2021
76e65ac
Add with keyword to Syntax tree (#12400)
nojaf Nov 19, 2021
8faf123
Fixes 12414: int32 --> Nullable Int64 additional implicit conversion…
dsyme Nov 20, 2021
e989f81
[main] Update dependencies from dotnet/arcade (#12426)
dotnet-maestro[bot] Nov 22, 2021
ef7944d
make diagnostic numbers unique (#12428)
dsyme Nov 22, 2021
7512e5c
Localized file check-in by OneLocBuild Task: Build definition ID 499:…
dotnet-bot Nov 22, 2021
8c300e6
Improve error message for invalid member declarations (#12342)
Nov 22, 2021
c194738
update messages (#12427)
dsyme Nov 22, 2021
5be669b
Localized file check-in by OneLocBuild Task: Build definition ID 499:…
dotnet-bot Nov 22, 2021
3d15c43
Fix 12405 (#12406)
KevinRansom Nov 22, 2021
c5da378
Fix debug tailcalls for pipelines if /tailcalls+ is explicitly specif…
dsyme Nov 22, 2021
2080a47
Localized file check-in by OneLocBuild Task: Build definition ID 499:…
dotnet-bot Nov 22, 2021
69ece79
Rename FSharpReferencedProject.ProjectFileName for clarity (#12431)
baronfel Nov 23, 2021
edd4c3b
12322: Fix deep recursive expression processing (#12420)
dsyme Nov 23, 2021
ee93e05
UnmanagedCallersOnlyAttribute is unsupported (#12350)
Happypig375 Nov 23, 2021
a847a71
Added CI job for deterministic builds (#12335)
TIHan Nov 23, 2021
cd7847d
Added service_slim
ncave Nov 15, 2021
adcea08
Async ParseAndCheckProject by Alfonso
ncave Nov 15, 2021
760f583
Added ParseAndCheckFileInProject
ncave Nov 15, 2021
2a49718
Add Compile to service_slim and pub-sub pattern
alfonsogarciacaro Dec 23, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix debug tailcalls for pipelines if /tailcalls+ is explicitly specif…
…ied (dotnet#12430)

* don't suppress tailcalls in pipeline debugging if tailcalls are on

* don't suppress tailcalls in pipeline debugging if tailcalls are on
  • Loading branch information
dsyme authored Nov 22, 2021
commit c5da37846baec2d584e193a796d13a61e9335fe7
39 changes: 24 additions & 15 deletions src/fsharp/IlxGen.fs
Original file line number Diff line number Diff line change
Expand Up @@ -2941,26 +2941,35 @@ and GenLinearExpr cenv cgbuf eenv sp expr sequel preSteps (contf: FakeUnit -> Fa
// Compiler generated sequential executions result in suppressions of debug points on both
// left and right of the sequence
let spStmt, spExpr =
(match spSeq with
| DebugPointAtSequential.SuppressNeither -> SPAlways, SPAlways
| DebugPointAtSequential.SuppressStmt -> SPSuppress, sp
| DebugPointAtSequential.SuppressExpr -> sp, SPSuppress
| DebugPointAtSequential.SuppressBoth -> SPSuppress, SPSuppress)
match spSeq with
| DebugPointAtSequential.SuppressNeither -> SPAlways, SPAlways
| DebugPointAtSequential.SuppressStmt -> SPSuppress, sp
| DebugPointAtSequential.SuppressExpr -> sp, SPSuppress
| DebugPointAtSequential.SuppressBoth -> SPSuppress, SPSuppress

match specialSeqFlag with
| NormalSeq ->
GenExpr cenv cgbuf eenv spStmt e1 discard
GenLinearExpr cenv cgbuf eenv spExpr e2 sequel true contf
| ThenDoSeq ->
let g = cenv.g
let isUnit = isUnitTy g (tyOfExpr g e1)
if isUnit then
GenExpr cenv cgbuf eenv spExpr e1 discard
GenExpr cenv cgbuf eenv spStmt e2 discard
GenUnitThenSequel cenv eenv e2.Range eenv.cloc cgbuf sequel
else
GenExpr cenv cgbuf eenv spExpr e1 Continue
GenExpr cenv cgbuf eenv spStmt e2 discard
GenSequel cenv eenv.cloc cgbuf sequel
// "e then ()" with DebugPointAtSequential.SuppressStmt is used
// in mkDebugPoint to emit a debug point on "e". However we don't want this to interfere
// with tailcalls, so detect this case and throw the "then ()" away, having already
// worked out "spExpr" up above.
match e2 with
| Expr.Const (Const.Unit, _, _) ->
GenExpr cenv cgbuf eenv spExpr e1 sequel
| _ ->
let g = cenv.g
let isUnit = isUnitTy g (tyOfExpr g e1)
if isUnit then
GenExpr cenv cgbuf eenv spExpr e1 discard
GenExpr cenv cgbuf eenv spStmt e2 discard
GenUnitThenSequel cenv eenv e2.Range eenv.cloc cgbuf sequel
else
GenExpr cenv cgbuf eenv spExpr e1 Continue
GenExpr cenv cgbuf eenv spStmt e2 discard
GenSequel cenv eenv.cloc cgbuf sequel
contf Fake

| Expr.Let (bind, body, _, _) ->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
.assembly extern FSharp.Core
{
.publickeytoken = (B0 3F 5F 7F 11 D5 0A 3A ) // .?_....:
.ver 5:0:0:0
.ver 6:0:0:0
}
.assembly TestFunction15
{
Expand All @@ -36,13 +36,13 @@
// Offset: 0x000001F0 Length: 0x00000072
}
.module TestFunction15.exe
// MVID: {611B0ED4-A624-4662-A745-0383D40E1B61}
// MVID: {6197D1F9-A624-4662-A745-0383F9D19761}
.imagebase 0x00400000
.file alignment 0x00000200
.stackreserve 0x00100000
.subsystem 0x0003 // WINDOWS_CUI
.corflags 0x00000001 // ILONLY
// Image base: 0x07120000
// Image base: 0x06AD0000


// =============== CLASS MEMBERS DECLARATION ===================
Expand Down Expand Up @@ -95,7 +95,7 @@
.method public static class [FSharp.Core]Microsoft.FSharp.Collections.FSharpList`1<int32>
TestFunction15(int32 inp) cil managed
{
// Code size 40 (0x28)
// Code size 42 (0x2a)
.maxstack 6
.locals init ([0] int32 x,
[1] class [FSharp.Core]Microsoft.FSharp.Collections.FSharpList`1<int32> 'Pipe #1 input at line 6')
Expand All @@ -119,9 +119,10 @@
.line 6,6 : 16,41 ''
IL_001c: ldsfld class TestFunction15/TestFunction15@6 TestFunction15/TestFunction15@6::@_instance
IL_0021: ldloc.1
IL_0022: call class [FSharp.Core]Microsoft.FSharp.Collections.FSharpList`1<!!1> [FSharp.Core]Microsoft.FSharp.Collections.ListModule::Map<int32,int32>(class [FSharp.Core]Microsoft.FSharp.Core.FSharpFunc`2<!!0,!!1>,
IL_0022: tail.
IL_0024: call class [FSharp.Core]Microsoft.FSharp.Collections.FSharpList`1<!!1> [FSharp.Core]Microsoft.FSharp.Collections.ListModule::Map<int32,int32>(class [FSharp.Core]Microsoft.FSharp.Core.FSharpFunc`2<!!0,!!1>,
class [FSharp.Core]Microsoft.FSharp.Collections.FSharpList`1<!!0>)
IL_0027: ret
IL_0029: ret
} // end of method TestFunction15::TestFunction15

} // end of class TestFunction15
Expand Down