RISC-V: testsuite: fix target selector for sync_char_short
Checks
Context |
Check |
Description |
rivoscibot/toolchain-ci-rivos-apply-patch |
success
|
Patch applied
|
rivoscibot/toolchain-ci-rivos-lint |
success
|
Lint passed
|
rivoscibot/toolchain-ci-rivos-build--newlib-rv64gcv-lp64d-multilib |
success
|
Build passed
|
rivoscibot/toolchain-ci-rivos-build--linux-rv64gc_zba_zbb_zbc_zbs-lp64d-multilib |
success
|
Build passed
|
rivoscibot/toolchain-ci-rivos-build--linux-rv64gcv-lp64d-multilib |
success
|
Build passed
|
rivoscibot/toolchain-ci-rivos-test |
success
|
Testing passed
|
linaro-tcwg-bot/tcwg_gcc_build--master-arm |
fail
|
Patch failed to apply
|
linaro-tcwg-bot/tcwg_gcc_build--master-aarch64 |
fail
|
Patch failed to apply
|
Commit Message
The effective-target selector for riscv on sync_char_short did not
check to see if atomics were enabled. As a result, these test cases were
ran on targets without the a extension. Add additional checks for zalrsc
or zabha extensions.
gcc/testsuite/ChangeLog:
* lib/target-supports.exp: Fix effective target sync_char_short
for riscv*-*-*
Signed-off-by: Edwin Lu <ewlu@rivosinc.com>
---
gcc/testsuite/lib/target-supports.exp | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
Comments
On 1/9/25 11:33 AM, Edwin Lu wrote:
> The effective-target selector for riscv on sync_char_short did not
> check to see if atomics were enabled. As a result, these test cases were
> ran on targets without the a extension. Add additional checks for zalrsc
> or zabha extensions.
>
> gcc/testsuite/ChangeLog:
>
> * lib/target-supports.exp: Fix effective target sync_char_short
> for riscv*-*-*
OK
jeff
Thanks! Committed.
Edwin
On 1/9/2025 1:04 PM, Jeff Law wrote:
>
>
> On 1/9/25 11:33 AM, Edwin Lu wrote:
>> The effective-target selector for riscv on sync_char_short did not
>> check to see if atomics were enabled. As a result, these test cases were
>> ran on targets without the a extension. Add additional checks for zalrsc
>> or zabha extensions.
>>
>> gcc/testsuite/ChangeLog:
>>
>> * lib/target-supports.exp: Fix effective target sync_char_short
>> for riscv*-*-*
> OK
> jeff
>
@@ -10080,7 +10080,9 @@ proc check_effective_target_sync_char_short { } {
|| ([istarget sparc*-*-*] && [check_effective_target_sparc_v9])
|| ([istarget arc*-*-*] && [check_effective_target_arc_atomic])
|| [istarget loongarch*-*-*]
- || [istarget riscv*-*-*]
+ || ([istarget riscv*-*-*]
+ && ([check_effective_target_riscv_zalrsc]
+ || [check_effective_target_riscv_zabha]))
|| [check_effective_target_mips_llsc] }}]
}