diff options
author | Sergey Andreenko <seandree@microsoft.com> | 2017-08-09 13:55:02 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-08-09 13:55:02 -0700 |
commit | 4ba2c3829661a6f3633038823f1971d7cf1acfd8 (patch) | |
tree | a385f71aa98465ba131edd200c55a2f4f156f238 /src | |
parent | 95b075fbdaee0c98b1527530787df708607063ae (diff) | |
download | coreclr-4ba2c3829661a6f3633038823f1971d7cf1acfd8.tar.gz coreclr-4ba2c3829661a6f3633038823f1971d7cf1acfd8.tar.bz2 coreclr-4ba2c3829661a6f3633038823f1971d7cf1acfd8.zip |
Add fail-fast check after lvaGrabTemp in impImportBlockCode (#13271)
Fix #13231.
* responce Brian's comment.
Diffstat (limited to 'src')
-rw-r--r-- | src/jit/importer.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/jit/importer.cpp b/src/jit/importer.cpp index d529bb2fe9..299595656d 100644 --- a/src/jit/importer.cpp +++ b/src/jit/importer.cpp @@ -12728,6 +12728,12 @@ void Compiler::impImportBlockCode(BasicBlock* block) /* get a temporary for the new object */ lclNum = lvaGrabTemp(true DEBUGARG("NewObj constructor temp")); + if (compDonotInline()) + { + // Fail fast if lvaGrabTemp fails with CALLSITE_TOO_MANY_LOCALS. + assert(compInlineResult->GetObservation() == InlineObservation::CALLSITE_TOO_MANY_LOCALS); + return; + } // In the value class case we only need clsHnd for size calcs. // |