On 6/10/2026 9:28 PM, [email protected] wrote:
Hi Jeff,
Thank you for your response. I have attempted to construct a
regression test case where the old HISI definition causes a failure
(e.g., incorrect code generation or ICE) while the new HX definition
works correctly. But I was unable to construct such a case.
OK. Thanks for trying.
However, the change to HX is still technically necessary for
correctness. It strictly enforces the hardware constraint that pack
only operates on XLEN/2 bits.
I realize that. It was never in question, the patch absolutely fixes a
bug, the only question was whether or not we could cover this with
regression test.
Given this, I consider this is a semantic cleanup to align strictly
with the hardware specification , even without a specific failing
testcase. Is it okay to merge it?
Yes. As I said, we don't require a testcase for every change or even
every bugfix, but we do strongly prefer testcases. Usually for a bugfix
something brought the bug to a developer's attention and that is usually
something we can convert into a meaningful testcase.
Given the complexity of GCC's codebase, the number of languages
supported, number of targets, etc thorough test coverage is critically
important. Hence our strong desire to continually expand the testsuite
with both feature tests as well as regression tests.
--
You indicated you tested the zbkb tests, which is good. But not
sufficient. I'll go ahead and throw the patch into my tester for a
deeper evaluation. I don't expect problems, but better safe than sorry.
In the future if you include "RISC-V" in your subject line the RISC-V
pre-commit tester will pick up the patch and automatically test it and
put results on the GCC patchwork page. For reference here's a recent
patch that was tested by that pre-commit tester.
https://patchwork.sourceware.org/project/gcc/patch/[email protected]/
Jeff