From: Sergey Andreenko Date: Wed, 27 Sep 2017 19:00:33 +0000 (-0700) Subject: [Jit] fix DevDiv_499435 (#14179) X-Git-Tag: accepted/tizen/base/20180629.140029~1042 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=bb2f5e780f7e0c12afb65261790fe84b2f02462e;p=platform%2Fupstream%2Fcoreclr.git [Jit] fix DevDiv_499435 (#14179) fix DevDiv_499435 --- diff --git a/src/jit/morph.cpp b/src/jit/morph.cpp index 6c9e3ad..1d04913 100644 --- a/src/jit/morph.cpp +++ b/src/jit/morph.cpp @@ -14285,6 +14285,13 @@ GenTreePtr Compiler::fgMorphSmpOp(GenTreePtr tree, MorphAddrContext* mac) /* Both tree and op1 are GT_COMMA nodes */ /* Change the tree's op1 to the throw node: op1->gtOp.gtOp1 */ tree->gtOp.gtOp1 = throwNode; + + // Possibly reset the assignment flag + if (((throwNode->gtFlags & GTF_ASG) == 0) && ((op2 == nullptr) || ((op2->gtFlags & GTF_ASG) == 0))) + { + tree->gtFlags &= ~GTF_ASG; + } + return tree; } else if (oper != GT_NOP)