public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc r14-6236] aarch64: Add rsr128 and wsr128 ACLE tests
@ 2023-12-06 21:23 Victor Do Nascimento
  0 siblings, 0 replies; only message in thread
From: Victor Do Nascimento @ 2023-12-06 21:23 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:09a08df71939cc0035ebae85220ff0214a38fb7c

commit r14-6236-g09a08df71939cc0035ebae85220ff0214a38fb7c
Author: Victor Do Nascimento <victor.donascimento@arm.com>
Date:   Sun Oct 29 01:49:45 2023 +0100

    aarch64: Add rsr128 and wsr128 ACLE tests
    
    Extend existing unit tests for the ACLE system register manipulation
    functions to include 128-bit tests.
    
    gcc/testsuite/ChangeLog:
    
            * gcc.target/aarch64/acle/rwsr.c (get_rsr128): New.
            (set_wsr128): Likewise.

Diff:
---
 gcc/testsuite/gcc.target/aarch64/acle/rwsr.c | 32 ++++++++++++++++++++++++++++
 1 file changed, 32 insertions(+)

diff --git a/gcc/testsuite/gcc.target/aarch64/acle/rwsr.c b/gcc/testsuite/gcc.target/aarch64/acle/rwsr.c
index 93c48c4caf0..6feb0bef2d6 100644
--- a/gcc/testsuite/gcc.target/aarch64/acle/rwsr.c
+++ b/gcc/testsuite/gcc.target/aarch64/acle/rwsr.c
@@ -6,6 +6,38 @@
 
 #include <arm_acle.h>
 
+#pragma GCC push_options
+#pragma GCC target ("arch=armv9.4-a+d128")
+
+#ifndef __ARM_FEATURE_SYSREG128
+#error "__ARM_FEATURE_SYSREG128 feature macro not defined."
+#endif
+
+/*
+** get_rsr128:
+**	mrrs	x0, x1, s3_0_c7_c4_0
+** ...
+*/
+__uint128_t
+get_rsr128 ()
+{
+  __arm_rsr128 ("par_el1");
+}
+
+/*
+** set_wsr128:
+** ...
+** 	msrr	s3_0_c7_c4_0, x0, x1
+** ...
+*/
+void
+set_wsr128 (__uint128_t c)
+{
+  __arm_wsr128 ("par_el1", c);
+}
+
+#pragma GCC pop_options
+
 /*
 ** get_rsr:
 ** ...

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2023-12-06 21:23 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-12-06 21:23 [gcc r14-6236] aarch64: Add rsr128 and wsr128 ACLE tests Victor Do Nascimento

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).