diff --git a/src/coreclr/jit/assertionprop.cpp b/src/coreclr/jit/assertionprop.cpp index 280d1fef56dc0..ccade20df0fbc 100644 --- a/src/coreclr/jit/assertionprop.cpp +++ b/src/coreclr/jit/assertionprop.cpp @@ -1344,12 +1344,12 @@ AssertionIndex Compiler::optCreateAssertion(GenTree* op1, if (op1->gtGetOp2()->IsCnsIntOrI()) { offset += op1->gtGetOp2()->AsIntCon()->gtIconVal; - op1 = op1->gtGetOp1(); + op1 = op1->gtGetOp1()->gtEffectiveVal(/* commaOnly */ true); } else if (op1->gtGetOp1()->IsCnsIntOrI()) { offset += op1->gtGetOp1()->AsIntCon()->gtIconVal; - op1 = op1->gtGetOp2(); + op1 = op1->gtGetOp2()->gtEffectiveVal(/* commaOnly */ true); } else {