Skip to content
Merged
Changes from all commits
Commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -523,7 +523,8 @@ private static mdToken FindGenericMethodArgTypeSpec(EcmaModule module)

public static bool ShouldSkipCompilation(InstructionSetSupport instructionSetSupport, MethodDesc methodNeedingCode)
{
if (methodNeedingCode.IsAggressiveOptimization)
bool targetAllowsRuntimeCodeGeneration = ((ReadyToRunCompilerContext)methodNeedingCode.Context).TargetAllowsRuntimeCodeGeneration;
if (methodNeedingCode.IsAggressiveOptimization && targetAllowsRuntimeCodeGeneration)
{
return true;
}
Expand All @@ -532,8 +533,7 @@ public static bool ShouldSkipCompilation(InstructionSetSupport instructionSetSup
// On platforms where we cannot JIT, we need to ensure that we have a fallback implementation pre-compiled
// so any code that uses hardware intrinsics and is interpreted has an implementation to use.
// This allows us to avoid the high cost of manually implementing intrinsics in the interpreter.
if (HardwareIntrinsicHelpers.IsHardwareIntrinsic(methodNeedingCode)
&& ((ReadyToRunCompilerContext)methodNeedingCode.Context).TargetAllowsRuntimeCodeGeneration)
if (HardwareIntrinsicHelpers.IsHardwareIntrinsic(methodNeedingCode) && targetAllowsRuntimeCodeGeneration)
{
return true;
}
Expand Down
Loading