On 8/11/23 03:11, Tsukasa OI via Gcc-patches wrote:
From: Tsukasa OI <research_tra...@irq.a4lg.com>
Commit c283c4774d1c ("RISC-V: Throw compilation error for unknown
extensions") changed how do we handle unknown extensions and
commit 6f709f79c915a ("[committed] [RISC-V] Fix expected diagnostic messages
in testsuite") "fixed" test failures caused by that change (on pr102957.c,
by testing the error message after the first change).
However, the latter change will break the original intent of PR 102957 test
case because we wanted to make sure that we can parse a valid two-letter
extension name.
Fortunately, there is a valid two-letter extension name, 'Zk' (standard
scalar cryptography extension superset with NIST algorithm suite).
This commit puts this extension name and revives the intent of the test case
for PR 102957.
gcc/testsuite/ChangeLog:
* gcc.target/riscv/pr102957.c: Remove "dg-error" because we don't
need to test for error message. Use the 'Zk' extension to continue
testing whether we can use valid two-letter extensions.
This doesn't look right to me. The whole point of this specific dg line
is to verify that we get an error with an invalid extension specification.
What might make more sense would be to split this into two tests. One
which continues to test that we get an error for something like zb and
the other with everything else.
jeff