A recent change triggered these regressions on v850-elf:
Tests that now fail, but worked before (7 tests): v850-sim/-mgcc-abi/-msoft-float/-mv850e3v5: gcc: gcc.dg/graphite/interchange-0.c (test for excess errors) v850-sim/-mgcc-abi/-msoft-float/-mv850e3v5: gcc: gcc.dg/graphite/interchange-0.c (test for excess errors) v850-sim/-mgcc-abi: gcc: gcc.dg/graphite/interchange-0.c (test for excess errors) v850-sim/-msoft-float/-mv850e3v5: gcc: gcc.dg/graphite/interchange-0.c (test for excess errors) v850-sim/-msoft-float: gcc: gcc.dg/graphite/interchange-0.c (test for excess errors) v850-sim/-mv850e3v5: gcc: gcc.dg/graphite/interchange-0.c (test for excess errors) v850-sim: gcc: gcc.dg/graphite/interchange-0.c (test for excess errors)
I didn't bother to chase down what commit was the culprit as it was clear that the v850 backend was buggy. In particular it wasn't handling (high (const ...)) style addresses in output_operand. The fix is trivial. For the HIGH case we can strip the HIGH and fall into the pre-existing CONST/SYMBOL_REF cases.
That fixes the regression and fixes gcc.dg/pr85164 as an unexpected benefit. Pushing to the trunk.
jeff
commit f41f36835c1179f80dc890de97a5b2b0baf559b6 Author: Jeff Law <[email protected]> Date: Wed Sep 23 09:28:10 2026 -0600 [V850] Fix output_operand to handle (high (const ...)) A recent change triggered these regressions on v850-elf: > Tests that now fail, but worked before (7 tests): > > v850-sim/-mgcc-abi/-msoft-float/-mv850e3v5: gcc: gcc.dg/graphite/interchange-0.c (test for excess errors) > v850-sim/-mgcc-abi/-msoft-float/-mv850e3v5: gcc: gcc.dg/graphite/interchange-0.c (test for excess errors) > v850-sim/-mgcc-abi: gcc: gcc.dg/graphite/interchange-0.c (test for excess errors) > v850-sim/-msoft-float/-mv850e3v5: gcc: gcc.dg/graphite/interchange-0.c (test for excess errors) > v850-sim/-msoft-float: gcc: gcc.dg/graphite/interchange-0.c (test for excess errors) > v850-sim/-mv850e3v5: gcc: gcc.dg/graphite/interchange-0.c (test for excess errors) > v850-sim: gcc: gcc.dg/graphite/interchange-0.c (test for excess errors) I didn't bother to chase down what commit was the culprit as it was clear that the v850 backend was buggy. In particular it wasn't handling (high (const ...)) style addresses in output_operand. The fix is trivial. For the HIGH case we can strip the HIGH and fall into the pre-existing CONST/SYMBOL_REF cases. That fixes the regression and fixes gcc.dg/pr85164. Pushing to the trunk. gcc/ * config/v850/v850.cc (v850_print_oprerand): Handle operands like (high (const ...)) by stripping the high and falling into the (const ...) case. diff --git a/gcc/config/v850/v850.cc b/gcc/config/v850/v850.cc index 8c233cf1e0f..cd6ba13b4b3 100644 --- a/gcc/config/v850/v850.cc +++ b/gcc/config/v850/v850.cc @@ -623,6 +623,11 @@ v850_print_operand (FILE * file, rtx x, int code) fprintf (file, HOST_WIDE_INT_PRINT_HEX, CONST_DOUBLE_LOW (x)); break; + case HIGH: + /* Strip off the HIGH and fall through to print the address. */ + x = XEXP (x, 0); + /* Fall through. */ + case CONST_INT: case SYMBOL_REF: case CONST:
