diff options
author | Brian Sullivan <briansul@microsoft.com> | 2018-07-05 16:03:18 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-07-05 16:03:18 -0700 |
commit | 5922cd345fe5de97efaccf426381db4ac74bc53c (patch) | |
tree | daa84e96ef8acc57459beaf82c10ea3d564e8bde | |
parent | c32eff71383529355f85c83c3caee1953501e2e1 (diff) | |
parent | 47c744ebc48cb6c0654f8c11a09870efe16984a3 (diff) | |
download | coreclr-5922cd345fe5de97efaccf426381db4ac74bc53c.tar.gz coreclr-5922cd345fe5de97efaccf426381db4ac74bc53c.tar.bz2 coreclr-5922cd345fe5de97efaccf426381db4ac74bc53c.zip |
Merge pull request #18775 from briansull/add-noway-assert
Add noway asserts in gtNewZeroConNode and gtNewOneConNode
-rw-r--r-- | src/jit/gentree.cpp | 25 | ||||
-rw-r--r-- | src/jit/morph.cpp | 6 |
2 files changed, 19 insertions, 12 deletions
diff --git a/src/jit/gentree.cpp b/src/jit/gentree.cpp index 08aa2efabc..dd2c6ddcc6 100644 --- a/src/jit/gentree.cpp +++ b/src/jit/gentree.cpp @@ -6105,7 +6105,7 @@ GenTree* Compiler::gtNewZeroConNode(var_types type) break; default: - assert(!"Bad type"); + noway_assert(!"Bad type in gtNewZeroConNode"); zero = nullptr; break; } @@ -6114,30 +6114,31 @@ GenTree* Compiler::gtNewZeroConNode(var_types type) GenTree* Compiler::gtNewOneConNode(var_types type) { + GenTree* one; switch (type) { case TYP_INT: case TYP_UINT: - return gtNewIconNode(1); + one = gtNewIconNode(1); + break; case TYP_LONG: case TYP_ULONG: - return gtNewLconNode(1); + one = gtNewLconNode(1); + break; case TYP_FLOAT: - { - GenTree* one = gtNewDconNode(1.0); - one->gtType = type; - return one; - } - case TYP_DOUBLE: - return gtNewDconNode(1.0); + one = gtNewDconNode(1.0); + one->gtType = type; + break; default: - assert(!"Bad type"); - return nullptr; + noway_assert(!"Bad type in gtNewOneConNode"); + one = nullptr; + break; } + return one; } #ifdef FEATURE_SIMD diff --git a/src/jit/morph.cpp b/src/jit/morph.cpp index ffd25d3421..7717e3dc26 100644 --- a/src/jit/morph.cpp +++ b/src/jit/morph.cpp @@ -8048,6 +8048,12 @@ void Compiler::fgMorphRecursiveFastTailCallIntoLoop(BasicBlock* block, GenTreeCa LclVarDsc* varDsc; for (varNum = 0, varDsc = lvaTable; varNum < lvaCount; varNum++, varDsc++) { +#if FEATURE_FIXED_OUT_ARGS + if (varNum == lvaOutgoingArgSpaceVar) + { + continue; + } +#endif // FEATURE_FIXED_OUT_ARGS if (!varDsc->lvIsParam) { var_types lclType = varDsc->TypeGet(); |