From 25c2bb3ebc2f240389eeb33672d0079baed91270 Mon Sep 17 00:00:00 2001 From: SingleAccretion <62474226+SingleAccretion@users.noreply.github.com> Date: Thu, 29 Apr 2021 04:53:01 +0300 Subject: [PATCH] Pass TYP_FLOAT to gtNewDconNode instead of creating a new scope (#51928) --- src/coreclr/jit/importer.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/coreclr/jit/importer.cpp b/src/coreclr/jit/importer.cpp index 9231bed6c7b699..a0b08aa3bd1db5 100644 --- a/src/coreclr/jit/importer.cpp +++ b/src/coreclr/jit/importer.cpp @@ -11508,11 +11508,7 @@ void Compiler::impImportBlockCode(BasicBlock* block) case CEE_LDC_R4: cval.dblVal = getR4LittleEndian(codeAddr); JITDUMP(" %#.17g", cval.dblVal); - { - GenTree* cnsOp = gtNewDconNode(cval.dblVal); - cnsOp->gtType = TYP_FLOAT; - impPushOnStack(cnsOp, typeInfo(TI_DOUBLE)); - } + impPushOnStack(gtNewDconNode(cval.dblVal, TYP_FLOAT), typeInfo(TI_DOUBLE)); break; case CEE_LDSTR: