TomasMatousek

user stats

Member SinceJuly 12, 2006
Last VisitAugust 12, 2014

Contact

coordinator for

IronRuby
MySQL Extensions for Phalanger

developer for

.NET Compiler Platform ("Roslyn")

TomasMatousek

personal statement

No personal statement has been written.

activity stream

August 14, 2014 - .NET Compiler Platform ("Roslyn"): Committed ad2bd29ce8320b62dccdd0c41a3255e172d41f62, Preparation for hoisting more locals in Debug builds. I noticed we can use less maps while rewriting a method to a class. MethodToClassRewriter: - parameterMap could be moved up to LambdaRewriter since it's only needed when rewriting lambdas. - variablesCaptured is replaced by a virtual NeedsProxy method which is implemented on LambdaRewriter and StateMachineRewriter using existing maps (so we can save another HashSet). We can also distinguish between "captured" variables and variables we create proxy field for. The former are deduced from syntax. A variable may be captured but not lifted into a field (e.g. expression tree lambda parameter). Or a variable can be lifted to field but not captured (in Debug builds we are going to lift user defined variables that are not captured to allow their later capture during EnC). LambdaRewriter: - variablesCaptured encodes the same information as keys of captured syntax multi-dictionary. - declaredInsideExpressionLambda is not needed either. When visiting ET lambdas we used to add their parameters to both variableBlock and declaredInsideExpressionLambda maps. Since ET lambda parameters are never lifted to closure we can avoid adding them to variableBlock map instead of excluding them later via declaredInsideExpressionLambda lookup. Adds internal IReadOnlySet similar to IReadOnlyList and IReadOnlyDictionary so that we can specify an intent of not mutating a set. (changeset 1317999)

August 14, 2014 - .NET Compiler Platform ("Roslyn"): Committed ad2bd29ce8320b62dccdd0c41a3255e172d41f62, Preparation for hoisting more locals in Debug builds. I noticed we can use less maps while rewriting a method to a class. MethodToClassRewriter: - parameterMap could be moved up to LambdaRewriter since it's only needed when rewriting lambdas. - variablesCaptured is replaced by a virtual NeedsProxy method which is implemented on LambdaRewriter and StateMachineRewriter using existing maps (so we can save another HashSet). We can also distinguish between "captured" variables and variables we create proxy field for. The former are deduced from syntax. A variable may be captured but not lifted into a field (e.g. expression tree lambda parameter). Or a variable can be lifted to field but not captured (in Debug builds we are going to lift user defined variables that are not captured to allow their later capture during EnC). LambdaRewriter: - variablesCaptured encodes the same information as keys of captured syntax multi-dictionary. - declaredInsideExpressionLambda is not needed either. When visiting ET lambdas we used to add their parameters to both variableBlock and declaredInsideExpressionLambda maps. Since ET lambda parameters are never lifted to closure we can avoid adding them to variableBlock map instead of excluding them later via declaredInsideExpressionLambda lookup. Adds internal IReadOnlySet similar to IReadOnlyList and IReadOnlyDictionary so that we can specify an intent of not mutating a set. (changeset 1317999)

August 14, 2014 - .NET Compiler Platform ("Roslyn"): Committed 1b2ccf9fcf96441a960daa22ac9e399aba7b2617, Remove unneccessary Import. (changeset 1317910)

August 14, 2014 - .NET Compiler Platform ("Roslyn"): Committed 1b2ccf9fcf96441a960daa22ac9e399aba7b2617, Remove unneccessary Import. (changeset 1317910)

August 14, 2014 - .NET Compiler Platform ("Roslyn"): Committed 26cb4147b9f34f6b7ada221678c8df7b1c82c928, Splits async code gen tests into 4 files. (changeset 1317161)

August 14, 2014 - .NET Compiler Platform ("Roslyn"): Committed 26cb4147b9f34f6b7ada221678c8df7b1c82c928, Splits async code gen tests into 4 files. (changeset 1317161)

August 14, 2014 - .NET Compiler Platform ("Roslyn"): Committed 848633e444a7402cbadf6957a27d7fae895fded5, Enable PDB generation in all emit tests. (changeset 1316676)

August 14, 2014 - .NET Compiler Platform ("Roslyn"): Committed 848633e444a7402cbadf6957a27d7fae895fded5, Enable PDB generation in all emit tests. (changeset 1316676)

August 14, 2014 - .NET Compiler Platform ("Roslyn"): Committed 9fbe14328f29090c929dee6582dd1d1e9fd5e8ea, Replaces CompilationOptions.Optimize and CompilationOptions.DebugInformationKind with a single enum OptimizationLevel that has two values: Release and Debug. Removes dependency in IL generation on whether PDB stream is passed to Emit or not. IL shall only differ between Release and Debug. Command line arguments /optimize, /debug and /pdb remain the same, their values map to either Release or Debug. The value of /optimize is mapped to Release or Debug. /debug+, /debug:full and /debug:pdbonly have all the same effect - enable generating PDB file. They don't influence the generated IL. Debug information/instrumentation (sequence points, dead stores, nops, etc.) doesn't need to be emitted for synthesized methods that don't contain user code (property GenerateDebugInfo on a symbol returns true). During lowering always create bound sequence nodes. In some scenarios (PDB stream is not passed, we are emitting helper that contains no user code) these nodes are not used. However, in mainstream scenarios we always emit PDBs, so optimizing the bound nodes away is optimizing for uncommon case and just increases test matrix. Lambda, iterator and async lowering have to handle presence of bound sequence point nodes. We get more test coverage if they are always present. Another reason why to always create bound sequence points is to avoid complexity and ambiguity when checking if a symbol needs debug information. Some symbols might need debug information during some lowering phases but not other. For example, the generated body of a method symbol that represents an async kick-off method doesn't need debug information since it doesn't contain any user code. However, all source code contained in an async method should have debug information emitted. Bound tree for such code is lowered in the context of the async method symbol, so the value of GenerateDebugInfo for the async method symbol would need to differ depending on which phase of compilation are we in. Finally, IL body deduplication can always be enabled (in Release and Debug), even in EnC scenarios. Removing another compiler knob further simplifies testing. (changeset 1316430)

August 14, 2014 - .NET Compiler Platform ("Roslyn"): Committed 9fbe14328f29090c929dee6582dd1d1e9fd5e8ea, Replaces CompilationOptions.Optimize and CompilationOptions.DebugInformationKind with a single enum OptimizationLevel that has two values: Release and Debug. Removes dependency in IL generation on whether PDB stream is passed to Emit or not. IL shall only differ between Release and Debug. Command line arguments /optimize, /debug and /pdb remain the same, their values map to either Release or Debug. The value of /optimize is mapped to Release or Debug. /debug+, /debug:full and /debug:pdbonly have all the same effect - enable generating PDB file. They don't influence the generated IL. Debug information/instrumentation (sequence points, dead stores, nops, etc.) doesn't need to be emitted for synthesized methods that don't contain user code (property GenerateDebugInfo on a symbol returns true). During lowering always create bound sequence nodes. In some scenarios (PDB stream is not passed, we are emitting helper that contains no user code) these nodes are not used. However, in mainstream scenarios we always emit PDBs, so optimizing the bound nodes away is optimizing for uncommon case and just increases test matrix. Lambda, iterator and async lowering have to handle presence of bound sequence point nodes. We get more test coverage if they are always present. Another reason why to always create bound sequence points is to avoid complexity and ambiguity when checking if a symbol needs debug information. Some symbols might need debug information during some lowering phases but not other. For example, the generated body of a method symbol that represents an async kick-off method doesn't need debug information since it doesn't contain any user code. However, all source code contained in an async method should have debug information emitted. Bound tree for such code is lowered in the context of the async method symbol, so the value of GenerateDebugInfo for the async method symbol would need to differ depending on which phase of compilation are we in. Finally, IL body deduplication can always be enabled (in Release and Debug), even in EnC scenarios. Removing another compiler knob further simplifies testing. (changeset 1316430)

projects i'm following

forks

No forks.