Hi gcc-patches mailing list,
Richard Earnshaw via Sourceware Forge 
<[email protected]> has requested that the 
following forgejo pull request
be published on the mailing list.

Created on: 2026-07-07 16:23:42+00:00
Latest update: 2026-07-17 12:26:06+00:00
Changes: 8 changed files, 9 additions, 87 deletions
Head revision: rearnsha/gcc ref no-tme commit 
f3dc154c427a7dd4d1871b5144ccaaad52d1219b
Base revision: gcc/gcc ref trunk commit 
60b27d915e14748a627deb1a4616da419b1e24b2 r17-2486-g60b27d915e1474
Merge base: 60b27d915e14748a627deb1a4616da419b1e24b2
Full diff url: https://forge.sourceware.org/gcc/gcc/pulls/186.diff
Discussion:  https://forge.sourceware.org/gcc/gcc/pulls/186
Requested Reviewers:

Arm has sunset the tme extension from the aarch64 architecture since
there are no known implementations.  Since this has been present in the
compiler for a while though, we need to go through a deprecation cycle.

This patch starts that process by:
 - removing it from the documentation
 - warning if the option is used during compilation
 - removing the tests for it.

gcc/ChangeLog:

        * config/aarch64/aarch64.cc (aarch64_override_options): Warn if
        +tme is used as an architecture feature
        * doc/invoke.texi (aarch64): Remove mentions of +tme.

gcc/testsuite/ChangeLog:

        * gcc.target/aarch64/pragma_cpp_predefs_2.c: Drop tests for TME.
        * gcc.target/aarch64/acle/tme.c: Removed.
        * gcc.target/aarch64/acle/tme_guard-1.c: Removed.
        * gcc.target/aarch64/acle/tme_guard-2.c: Removed.
        * gcc.target/aarch64/acle/tme_guard-3.c: Removed.
        * gcc.target/aarch64/acle/tme_guard-4.c: Removed.


Changed files:
- D: gcc/testsuite/gcc.target/aarch64/acle/tme.c
- D: gcc/testsuite/gcc.target/aarch64/acle/tme_guard-1.c
- D: gcc/testsuite/gcc.target/aarch64/acle/tme_guard-2.c
- D: gcc/testsuite/gcc.target/aarch64/acle/tme_guard-3.c
- D: gcc/testsuite/gcc.target/aarch64/acle/tme_guard-4.c
- M: gcc/config/aarch64/aarch64.cc
- M: gcc/doc/invoke.texi
- M: gcc/testsuite/gcc.target/aarch64/pragma_cpp_predefs_2.c


Richard Earnshaw (1):
  aarch64: deprecate the TME extension

 gcc/config/aarch64/aarch64.cc                 | 10 +++++-
 gcc/doc/invoke.texi                           |  2 --
 gcc/testsuite/gcc.target/aarch64/acle/tme.c   | 34 -------------------
 .../gcc.target/aarch64/acle/tme_guard-1.c     |  9 -----
 .../gcc.target/aarch64/acle/tme_guard-2.c     | 10 ------
 .../gcc.target/aarch64/acle/tme_guard-3.c     |  9 -----
 .../gcc.target/aarch64/acle/tme_guard-4.c     | 10 ------
 .../gcc.target/aarch64/pragma_cpp_predefs_2.c | 12 -------
 8 files changed, 9 insertions(+), 87 deletions(-)
 delete mode 100644 gcc/testsuite/gcc.target/aarch64/acle/tme.c
 delete mode 100644 gcc/testsuite/gcc.target/aarch64/acle/tme_guard-1.c
 delete mode 100644 gcc/testsuite/gcc.target/aarch64/acle/tme_guard-2.c
 delete mode 100644 gcc/testsuite/gcc.target/aarch64/acle/tme_guard-3.c
 delete mode 100644 gcc/testsuite/gcc.target/aarch64/acle/tme_guard-4.c

Range-diff against v1:
1:  91ceba74418b ! 1:  f3dc154c427a aarch64: deprecate the tme extension
    @@ Metadata
     Author: Richard Earnshaw <[email protected]>
     
      ## Commit message ##
    -    aarch64: deprecate the tme extension
    +    aarch64: deprecate the TME extension
     
    -    Arm has sunset the tme extension from the aarch64 architecture since
    +    Arm has sunset the TME extension from the aarch64 architecture since
         there are no known implementations.  Since this has been present in the
         compiler for a while though, we need to go through a deprecation cycle.
     
    @@ Commit message
     
                 * config/aarch64/aarch64.cc (aarch64_override_options): Warn if
                 +tme is used as an architecture feature
    +            (aarch64_process_target_attr): Similarly, but only if TME
    +            was previously disabled.
                 * doc/invoke.texi (aarch64): Remove mentions of +tme.
     
         gcc/testsuite/ChangeLog:
    @@ gcc/config/aarch64/aarch64.cc: aarch64_override_options (void)
        if (global_options.x_pcrelative_literal_loads == 1)
          warning (OPT_Wdeprecated, "%<-mpc-relative-literal-loads%> is 
deprecated");
      
    +@@ gcc/config/aarch64/aarch64.cc: aarch64_process_target_attr (tree args)
    +   while (token)
    +     {
    +       num_attrs++;
    ++
    ++      if ((strcmp (token, "+tme") == 0) && !TARGET_TME)
    ++  warning (OPT_Wdeprecated,
    ++           "the architecture extension %<+tme%> is deprecated");
    ++
    +       if (!aarch64_process_one_target_attr (token))
    +   {
    +     /* Check if token is possibly an arch extension without
    +@@ gcc/config/aarch64/aarch64.cc: aarch64_process_target_attr (tree args)
    +       error ("pragma or attribute %<target(\"%s\")%> is not valid", 
token);
    +     return false;
    +   }
    +-
    +       token = strtok_r (NULL, ",", &str_to_check);
    +     }
    + 
     
      ## gcc/doc/invoke.texi ##
     @@ gcc/doc/invoke.texi: Enable SVE2 sha3 instructions.  This also enables 
SVE2 instructions.
-- 
2.54.0

Reply via email to