summaryrefslogtreecommitdiff
path: root/src/jit/lsraxarch.cpp
diff options
context:
space:
mode:
authorCarol Eidt <carol.eidt@microsoft.com>2018-03-02 11:08:42 -0800
committerCarol Eidt <carol.eidt@microsoft.com>2018-03-02 16:38:22 -0800
commit1765a4e337ac9e992760783e1e717f7b24cc2d89 (patch)
treefd952314cdcf5ebffa581424c8030baa874a83b3 /src/jit/lsraxarch.cpp
parentfa7465f931caad8823e590277a1a4c44984b1a67 (diff)
downloadcoreclr-1765a4e337ac9e992760783e1e717f7b24cc2d89.tar.gz
coreclr-1765a4e337ac9e992760783e1e717f7b24cc2d89.tar.bz2
coreclr-1765a4e337ac9e992760783e1e717f7b24cc2d89.zip
Don't force byte regs for indir address
Diffstat (limited to 'src/jit/lsraxarch.cpp')
-rw-r--r--src/jit/lsraxarch.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/jit/lsraxarch.cpp b/src/jit/lsraxarch.cpp
index fdb875a827..ac0062a271 100644
--- a/src/jit/lsraxarch.cpp
+++ b/src/jit/lsraxarch.cpp
@@ -754,7 +754,9 @@ void LinearScan::BuildCheckByteable(GenTree* tree)
if (tree->OperIsSimple())
{
GenTree* op = tree->gtOp.gtOp1;
- if (op != nullptr)
+ // We need byte registers on the operands of most simple operators that produce a byte result.
+ // However, indirections are simple operators but do not require their address in a byte register.
+ if ((op != nullptr) && !tree->OperIsIndir())
{
// No need to set src candidates on a contained child operand.
if (!op->isContained())