Chicken-Bones
481e05eabb
Better shortcircuit detection to avoid single condition switch statements
7 years ago
Chicken-Bones
d8244e347b
Select outer-loop continue branches as break targets for switches in nested loops
7 years ago
Chicken-Bones
9f21e6a2b2
Increase max values per switch section
7 years ago
Chicken-Bones
eed337c12e
Remove dead code when unreachable condition blocks are consumed by SwitchDetection
7 years ago
Chicken-Bones
d86f4b4132
Prefer simple if statements over switch with single case block
7 years ago
Chicken-Bones
52a279f861
Restore HighLevelLoopTransform pattern match for loop contents within if body
7 years ago
Chicken-Bones
7017d998d0
Improve switch decompilation in loops via early detection of continue blocks.
7 years ago
Chicken-Bones
1a021635cc
Fix detection of switch statements with cases containing a single break;
...
Remedy incorrect assumption that the default case was special.
7 years ago
Chicken-Bones
cb4fa90545
Add IL ordering based hint to UseCSharpSwitch
7 years ago
Chicken-Bones
62b2ad4f8d
Improve UseCSharpSwitch to reduce over-aggressive use of switch producing poor quality code.
7 years ago
Chicken-Bones
9a3914fca9
Handle roslyn generated sub instructions in partitioned C# switch statements
7 years ago
Siegfried Pammer
cf1d05042f
Add detection of local functions, so we do not hide the methods/display classes.
7 years ago
Siegfried Pammer
fc717be0d8
Fix typo in YieldReturnDecompiler
7 years ago
Siegfried Pammer
1dcae5bff8
Extend HandleCall to NewObj instructions as well.
7 years ago
Siegfried Pammer
b701bed2ff
SplitVariables: analyze address usage in virtual calls as well. Treat them the same as call instructions.
7 years ago
Siegfried Pammer
4fab913bf6
Fix #1249 : Bug in detection of multiple nested expression trees in query expressions.
7 years ago
Siegfried Pammer
2047923809
Add ShowChildIndexInBlock option to make debugging of larger blocks easier.
7 years ago
Siegfried Pammer
08af55aa57
Avoid ITypeDefinition.FullName. Use Name and Namespace separately to avoid string allocation. Reorder checks to improve performance on pattern mismatch.
7 years ago
Siegfried Pammer
ebbe25fba7
Apply suggested refactorings on TransformArrayInitializers.cs
7 years ago
Siegfried Pammer
772b529d16
Add support for stackalloc initializer pattern that uses initblk.
7 years ago
Siegfried Pammer
057ab82534
Add basic stackalloc initializer transforms.
7 years ago
Siegfried Pammer
2a537fcecb
Reorder code in TransformArrayInitializers.cs
7 years ago
Andrew Au
9837933e9d
Fix issue #1224
7 years ago
Daniel Grunwald
542e088ceb
Fix #1185 : assertion with unreachable code in loop detection
7 years ago
Daniel Grunwald
c16817ab4e
Fix #1186 : LoopDetection assertion with unreachable code
7 years ago
Daniel Grunwald
2f54eee5db
#1195 : Fix comparison of object reference with ldc.i4 0.
7 years ago
Daniel Grunwald
ba0a3af3c4
#1195 : Fix several issues decompiling SharpSvn.dll (C++/CLI)
7 years ago
Daniel Grunwald
066da1ea16
Fix #1200 : assertion in TransformInlineAssignmentLocal when reconstructed stack slot (after async-await transform) has small integer type.
...
The assertion was unnecessary, because we already check 'IsImplicitTruncation(inst.Value, inst.Variable.Type)'.
7 years ago
Daniel Grunwald
8270a93c1a
Fix #1233 : Fix some crashes on corrupt type references.
7 years ago
Daniel Grunwald
0006330c1a
Fix #1235 : Insert StackType conversion when filling in Leave target.
7 years ago
Daniel Grunwald
dd5845e83d
Support short-circuiting operators with dynamic. (e.g. "if (x.A && x.B)" where "x" is dynamic)
7 years ago
Siegfried Pammer
e92b9fe5e4
Optimize performance of debug builds: only call string.Format, if assertion fails.
7 years ago
Chicken-Bones
5ed5ea0e0f
Improve block ordering in ConditionDetection using the ILOffsets of Leave instruction arguments
7 years ago
Daniel Grunwald
9479e8af13
Support overloaded operator &&/||.
7 years ago
Daniel Grunwald
aa10f0089a
Fix #1226 : Use StackType.O for LdLen argument.
7 years ago
Chicken-Bones
f539bee362
Move binary->logical AND to ExpressionTransforms and use SemanticHelper.IsPure
7 years ago
Chicken-Bones
fe6a85fa68
Reverse Roslyn optimisation to favour && over & on boolean operands.
7 years ago
Siegfried Pammer
dbe29596de
Fix #1210 : v4.x: System.InvalidCastException: Specified cast is not valid
7 years ago
Daniel Grunwald
4e8ebbf7f4
Fix #1189 : Avoid crashing on invalid IL bytes.
7 years ago
Daniel Grunwald
08e8091336
Fix #1211 : Handle BadImageFormatException on invalid local signatures.
7 years ago
Daniel Grunwald
90d866d78a
Fix #1193 : Performance issues with deeply nested block structures
7 years ago
Daniel Grunwald
bafb6d1d49
Fix #1194 : empty if statements are decompiled into goto statements
7 years ago
Daniel Grunwald
2d04f24670
Fix stack overflow in RequiredNamespaceCollector.
7 years ago
Daniel Grunwald
d8c8a75c2e
Fix #1154 : Decompilation of fixed statement when pointer variable is unused
7 years ago
Daniel Grunwald
b396d203bd
Merge IDecompilerTypeSystem with ICompilation.
7 years ago
Daniel Grunwald
1f3916d554
Use the resolve methods in MetadataModule, and remove the wrappers in DecompilerTypeSystem.
7 years ago
Daniel Grunwald
c54632e7cb
Fix some type system bugs.
7 years ago
Daniel Grunwald
107fe5eb1c
Eliminate SpecializingDecompilerTypeSystem and use GenericContext instead.
7 years ago
Daniel Grunwald
4580eab7ab
Disable ref inline assignments.
...
This increases the chances that we'll avoid CS8174: A declaration of a by-reference variable must have an initializer.
7 years ago
Daniel Grunwald
7ee686cb67
Allow splitting a variable even if it has its address taken and stored in a ref-local.
...
The currently implementation is somewhat minimal and only works in a very limited set of circumstances:
* the ref local is single-assignment
* the ref local is initialized directly with 'ldloca target; stloc ref_local',
not a derived pointer (e.g. 'ldloca target; ldflda F; stloc ref_local').
* all uses of the ref_local are immediately consuming the address
This improves variable splitting cases where the compiler re-uses a stack slot containing a reference,
e.g. in some cases of '?.' on Nullable<T>.
7 years ago