]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
gcn: Update --with-arch= for newer archs
authorTobias Burnus <tburnus@baylibre.com>
Thu, 5 Jun 2025 08:36:21 +0000 (10:36 +0200)
committerTobias Burnus <tburnus@baylibre.com>
Fri, 6 Jun 2025 13:46:05 +0000 (15:46 +0200)
Replace hard-coded list of supported devices by directly checking
config/gcn/gcn-devices.def.

gcc/ChangeLog:

* config.gcc (--with-{arch,tune}): Use .def file to validate gcn
processor names.
* doc/install.texi (amdgcn*-*-*): Update list of devices supported
by --with-arch/--with-tune.

(cherry picked from commit 61a6430cf663e3c980c2ee966f094fea7d99f8e7)

gcc/config.gcc
gcc/doc/install.texi

index 40b50dc969ede4418b305ca01869ec157e054283..5725704e06be1b3e13eefd0652215b84885d65d0 100644 (file)
@@ -4598,15 +4598,13 @@ case "${target}" in
 
                for which in arch tune; do
                        eval "val=\$with_$which"
-                       case ${val} in
-                       "" | gfx900 | gfx906 | gfx908 | gfx90a | gfx90c | gfx1030 | gfx1036 | gfx1100 | gfx1103)
-                               # OK
-                               ;;
-                       *)
+                       if test x"$val" != x \
+                          && ! grep -q "GCN_DEVICE($val," \
+                                       "${srcdir}/config/gcn/gcn-devices.def";
+                       then
                                echo "Unknown cpu used in --with-$which=$val." 1>&2
                                exit 1
-                               ;;
-                       esac
+                       fi
                done
                [ "x$with_arch" = x ] && with_arch=gfx900
 
index 1af0082ed772978cc3161b55ca0fcc4d97ffe2d5..3e9e09b4ae3edbb02d5e8763ba50cdc92b2d9073 100644 (file)
@@ -1342,9 +1342,13 @@ default set of libraries is selected based on the value of
 
 @item amdgcn*-*-*
 @var{list} is a comma separated list of ISA names (allowed values:
-@code{gfx900}, @code{gfx906}, @code{gfx908}, @code{gfx90a}, @code{gfx90c}, 
-@code{gfx1030}, @code{gfx1036}, @code{gfx1100}, @code{gfx1103}).
-It ought not include the name of the default
+@code{gfx900}, @code{gfx902}, @code{gfx904}, @code{gfx906}, @code{gfx908},
+@code{gfx909}, @code{gfx90a}, @code{gfx90c}, @code{gfx9-generic},
+@code{gfx1030}, @code{gfx1031}, @code{gfx1032}, @code{gfx1033},
+@code{gfx1034}, @code{gfx1035}, @code{gfx1036}, @code{gfx10-3-generic},
+@code{gfx1100}, @code{gfx1101}, @code{gfx1102}, @code{gfx1103},
+@code{gfx1150}, @code{gfx1151}, @code{gfx1152}, @code{gfx1153},
+@code{gfx11-generic}).  It ought not include the name of the default
 ISA, specified via @option{--with-arch}.  If @var{list} is empty, then there
 will be no multilibs and only the default run-time library will be built.  If
 @var{list} is @code{default} or @option{--with-multilib-list=} is not