27 instantiations of StackSlot
ILCompiler.Compiler (27)
Compiler\Dataflow\MethodBodyScanner.cs (27)
71
stack.Push(new
StackSlot
()); // Push dummy values to avoid crashes.
78
stack.Push(new
StackSlot
());
106
return new
StackSlot
(MultiValueLattice.Meet(a.Value, b.Value));
117
a.Push(new
StackSlot
());
120
b.Push(new
StackSlot
());
417
currentStack.Push(new
StackSlot
(NullValue.Instance));
433
StackSlot slot = new
StackSlot
(civ);
441
StackSlot slot = new
StackSlot
(civ);
450
StackSlot slot = new
StackSlot
(civ);
459
StackSlot slot = new
StackSlot
(civ);
524
StackSlot slot = new
StackSlot
(new KnownStringValue((string)methodIL.GetObject(reader.ReadILToken())));
631
currentStack.Push(new
StackSlot
(ArrayValue.Create(count.Value, arrayElementType)));
866
catchStack.Push(new
StackSlot
());
894
StackSlot slot = new
StackSlot
(
931
newSlot = new
StackSlot
(new LocalVariableReferenceValue(index, methodIL.GetLocals()[index].Type));
934
newSlot = new
StackSlot
(localValue.Value.Value);
936
newSlot = new
StackSlot
(UnknownValue.Instance);
946
StackSlot slot = new
StackSlot
(new RuntimeTypeHandleForGenericParameterValue((GenericParameterDesc)type));
959
currentStack.Push(new
StackSlot
(nullableDam));
963
currentStack.Push(new
StackSlot
(nullableType));
973
currentStack.Push(new
StackSlot
(typeHandle));
981
StackSlot slot = new
StackSlot
(new RuntimeMethodHandleValue(method));
1117
currentStack.Push(new
StackSlot
(value));
1290
currentStack.Push(new
StackSlot
(UnknownValue.Instance));
1305
currentStack.Push(new
StackSlot
(methodReturnValue));
1397
currentStack.Push(new
StackSlot
(arrayOfAnnotated.GetAnyElementValue()));
1425
currentStack.Push(new
StackSlot
(arrayIndexValue.Value));
66 references to StackSlot
ILCompiler.Compiler (66)
Compiler\Dataflow\MethodBodyScanner.cs (66)
65
private void CheckForInvalidStack(Stack<
StackSlot
> stack, int depthRequired, MethodIL method, int ilOffset)
76
private static void PushUnknown(Stack<
StackSlot
> stack)
81
private void PushUnknownAndWarnAboutInvalidIL(Stack<
StackSlot
> stack, MethodIL methodIL, int offset)
87
private
StackSlot
PopUnknown(Stack<
StackSlot
> stack, int count, MethodIL method, int ilOffset)
92
StackSlot
topOfStack = default;
97
StackSlot
slot = stack.Pop();
104
private static
StackSlot
MergeStackElement(
StackSlot
a,
StackSlot
b)
110
private static Stack<
StackSlot
> MergeStack(Stack<
StackSlot
> a, Stack<
StackSlot
> b)
123
Stack<
StackSlot
> newStack = new Stack<
StackSlot
>(a.Count);
124
Stack<
StackSlot
>.Enumerator aEnum = a.GetEnumerator();
125
Stack<
StackSlot
>.Enumerator bEnum = b.GetEnumerator();
132
return new Stack<
StackSlot
>(newStack);
135
private static void ClearStack(ref Stack<
StackSlot
>? stack)
140
private static void NewKnownStack(Dictionary<int, Stack<
StackSlot
>> knownStacks, int newOffset, Stack<
StackSlot
> newStack)
154
knownStacks.Add(newOffset, new Stack<
StackSlot
>(newStack.Reverse()));
350
Dictionary<int, Stack<
StackSlot
>> knownStacks = new Dictionary<int, Stack<
StackSlot
>>();
351
Stack<
StackSlot
>? currentStack = new Stack<
StackSlot
>(methodIL.MaxStack);
368
currentStack = new Stack<
StackSlot
>(knownStack.Reverse());
376
currentStack ??= new Stack<
StackSlot
>(methodIL.MaxStack);
433
StackSlot
slot = new StackSlot(civ);
441
StackSlot
slot = new StackSlot(civ);
450
StackSlot
slot = new StackSlot(civ);
459
StackSlot
slot = new StackSlot(civ);
524
StackSlot
slot = new StackSlot(new KnownStringValue((string)methodIL.GetObject(reader.ReadILToken())));
628
StackSlot
count = PopUnknown(currentStack, 1, methodIL, offset);
784
NewKnownStack(knownStacks, reader.ReadBranchDestination(opcode), new Stack<
StackSlot
>(methodIL.MaxStack));
806
StackSlot
retStackSlot = PopUnknown(currentStack, 1, methodIL, offset);
861
private static void ScanExceptionInformation(Dictionary<int, Stack<
StackSlot
>> knownStacks, MethodIL methodIL)
865
Stack<
StackSlot
> catchStack = new Stack<
StackSlot
>(1);
884
private void ScanLdarg(ILOpcode opcode, int parameterIndex, Stack<
StackSlot
> currentStack, MethodDesc thisMethod)
894
StackSlot
slot = new StackSlot(
905
Stack<
StackSlot
> currentStack
908
var
valueToStore = PopUnknown(currentStack, 1, methodIL, offset);
922
Stack<
StackSlot
> currentStack,
928
StackSlot
newSlot;
940
private void ScanLdtoken(MethodIL methodIL, int offset, object operand, Stack<
StackSlot
> currentStack)
946
StackSlot
slot = new StackSlot(new RuntimeTypeHandleForGenericParameterValue((GenericParameterDesc)type));
981
StackSlot
slot = new StackSlot(new RuntimeMethodHandleValue(method));
1000
Stack<
StackSlot
> currentStack,
1004
StackSlot
valueToStore = PopUnknown(currentStack, 1, methodIL, offset);
1011
Stack<
StackSlot
> currentStack,
1016
StackSlot
valueToStore = PopUnknown(currentStack, 1, methodIL, offset);
1017
StackSlot
destination = PopUnknown(currentStack, 1, methodIL, offset);
1096
Stack<
StackSlot
> currentStack,
1137
Stack<
StackSlot
> currentStack,
1141
StackSlot
valueToStoreSlot = PopUnknown(currentStack, 1, methodIL, offset);
1166
Stack<
StackSlot
> currentStack,
1179
StackSlot
slot = PopUnknown(currentStack, 1, containingMethodIL, ilOffset);
1277
Stack<
StackSlot
> currentStack,
1348
Stack<
StackSlot
> currentStack,
1352
StackSlot
valueToStore = PopUnknown(currentStack, 1, methodIL, offset);
1353
StackSlot
indexToStoreAt = PopUnknown(currentStack, 1, methodIL, offset);
1354
StackSlot
arrayToStoreIn = PopUnknown(currentStack, 1, methodIL, offset);
1380
Stack<
StackSlot
> currentStack,
1384
StackSlot
indexToLoadFrom = PopUnknown(currentStack, 1, methodIL, offset);
1385
StackSlot
arrayToLoadFrom = PopUnknown(currentStack, 1, methodIL, offset);