aboutsummaryrefslogtreecommitdiff
path: root/gcc/fortran/trans-expr.cc
diff options
context:
space:
mode:
authorThomas Schwinge <tschwinge@baylibre.com>2025-01-17 21:45:42 +0100
committerThomas Schwinge <tschwinge@baylibre.com>2025-01-20 12:04:06 +0100
commit6c5937991bd744a4916e9cf65eb5d9c9b5706120 (patch)
tree76fd1d3e3c1520eb95c8501752751245da473413 /gcc/fortran/trans-expr.cc
parentd9d0eeea93d39d304c7420e87f4b903d89f2e9fa (diff)
downloadgcc-6c5937991bd744a4916e9cf65eb5d9c9b5706120.zip
gcc-6c5937991bd744a4916e9cf65eb5d9c9b5706120.tar.gz
gcc-6c5937991bd744a4916e9cf65eb5d9c9b5706120.tar.bz2
nvptx: Gracefully handle '-mptx=3.1' if neither sm_30 nor sm_35 multilib variant is built
For example, for GCC/nvptx built with '--with-arch=sm_52' (current default) and '--without-multilib-list', neither a sm_30 nor a sm_35 multilib variant is built, and thus no '-mptx=3.1' sub-variant either. Such a configuration is possible as of commit 86b3a7532d56f74fcd1c362f2da7f95e8cc4e4a6 "nvptx: Support '--with-multilib-list'", but currently results in the following bogus behavior: [...]/xgcc -print-multi-directory -mgomp -march=sm_52 mgomp [...]/xgcc -print-multi-directory -mgomp -march=sm_35 mgomp [...]/xgcc -print-multi-directory -mgomp -march=sm_30 mgomp [...]/xgcc -print-multi-directory -mgomp -march=sm_35 -mptx=3.1 . [...]/xgcc -print-multi-directory -mgomp -march=sm_30 -mptx=3.1 . The latter two '.' are unexpected; linking OpenMP/nvptx offloading code like this fails with: 'unresolved symbol __nvptx_uni', for example. Instead of '.', the latter two should print 'mgomp', too. To achieve that, we must not set up the '-mptx=3.1' multilib axis if no '-mptx=3.1' sub-variant is built. gcc/ * config/nvptx/t-nvptx (MULTILIB_OPTIONS): Don't add 'mptx=3.1' if neither sm_30 nor sm_35 multilib variant is built.
Diffstat (limited to 'gcc/fortran/trans-expr.cc')
0 files changed, 0 insertions, 0 deletions