projects
/
platform
/
upstream
/
dotnet
/
runtime.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ffa0647
)
Fix Issue #877 - Use GT_OBJ when copying a struct (#40483)
author
Brian Sullivan
<briansul@microsoft.com>
Fri, 7 Aug 2020 18:08:34 +0000
(11:08 -0700)
committer
GitHub
<noreply@github.com>
Fri, 7 Aug 2020 18:08:34 +0000
(11:08 -0700)
src/coreclr/src/jit/morph.cpp
patch
|
blob
|
history
diff --git
a/src/coreclr/src/jit/morph.cpp
b/src/coreclr/src/jit/morph.cpp
index
61ad993
..
8134272
100644
(file)
--- a/
src/coreclr/src/jit/morph.cpp
+++ b/
src/coreclr/src/jit/morph.cpp
@@
-5742,7
+5742,9
@@
GenTree* Compiler::fgMorphStackArgForVarArgs(unsigned lclNum, var_types varType,
GenTree* tree;
if (varTypeIsStruct(varType))
{
- tree = new (this, GT_BLK) GenTreeBlk(GT_BLK, TYP_STRUCT, ptrArg, typGetBlkLayout(varDsc->lvExactSize));
+ CORINFO_CLASS_HANDLE typeHnd = varDsc->lvVerTypeInfo.GetClassHandle();
+ assert(typeHnd != nullptr);
+ tree = gtNewObjNode(typeHnd, ptrArg);
}
else
{