aboutsummaryrefslogtreecommitdiff
path: root/gcc/reload.h
diff options
context:
space:
mode:
authorAndrew MacLeod <amacleod@redhat.com>2022-08-22 15:40:48 -0400
committerAndrew MacLeod <amacleod@redhat.com>2022-08-22 21:04:44 -0400
commitde6d9e0b3d5c08896cbf047b299fc7f8d1e42be7 (patch)
tree00da3a5299ca384e2b3a810868cc26c009ffece8 /gcc/reload.h
parent3b2e3fa39dd2b606566f47006d015f9c447dcc7d (diff)
downloadgcc-de6d9e0b3d5c08896cbf047b299fc7f8d1e42be7.zip
gcc-de6d9e0b3d5c08896cbf047b299fc7f8d1e42be7.tar.gz
gcc-de6d9e0b3d5c08896cbf047b299fc7f8d1e42be7.tar.bz2
Return the correct relation
With an input condition of op1 > op2, and evaluating the unsigned expression: LHS = op1 - op2 range-ops was returning LHS < op1 , which is incorrect as op2 coould be zero. This patch adjusts it to return LHS <= op1. PR tree-optimization/106687 gcc/ * range-op.cc (operator_minus::lhs_op1_relation): Return VREL_LE for the VREL_GT case as well. gcc/testsuite/ * g++.dg/pr106687.C: New.
Diffstat (limited to 'gcc/reload.h')
0 files changed, 0 insertions, 0 deletions