提交 50d39816 编写于 作者: P Pat Gavlin

Use operator/operand size for legality checks.


Commit migrated from https://github.com/dotnet/coreclr/commit/af72bc4055d1a2e079081c091dd733e1b64987e9
上级 397eca86
......@@ -181,8 +181,10 @@ private:
GenTree* const op1 = tree->gtGetOp1();
GenTree* const op2 = tree->gtGetOp2();
const bool op1Legal = tree->OperIsCommutative() && (tree->TypeGet() == op1->TypeGet());
const bool op2Legal = tree->TypeGet() == op2->TypeGet();
const unsigned operatorSize = genTypeSize(tree->TypeGet());
const bool op1Legal = tree->OperIsCommutative() && (operatorSize == genTypeSize(op1->TypeGet()));
const bool op2Legal = operatorSize == genTypeSize(op2->TypeGet());
if (op1Legal)
{
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册