[Bug target/100092] New: [10 Regression] nvptx offloading on aarch64 fails to specify -foffload-abi

rguenth at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Thu Apr 15 08:05:18 GMT 2021


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100092

            Bug ID: 100092
           Summary: [10 Regression] nvptx offloading on aarch64 fails to
                    specify -foffload-abi
           Product: gcc
           Version: 10.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: rguenth at gcc dot gnu.org
  Target Milestone: ---

Comparing GCC 10.2.1 and 10.3.0 testresults on aarch64 I see

                === libgomp Summary ===

-# of expected passes           7627
-# of unexpected successes      6
-# of expected failures         4
+# of expected passes           6837
+# of unexpected failures       820
+# of expected failures         10
+# of unresolved testcases      400
 # of untested testcases                3
-# of unsupported tests         601
+# of unsupported tests         602

with all the FAILs being like

+FAIL: libgomp.c/examples-4/target_data-4.c (internal compiler error)
+FAIL: libgomp.c/examples-4/target_data-4.c (test for excess errors)
+UNRESOLVED: libgomp.c/examples-4/target_data-4.c compilation failed to produce
executable

and in the log

spawn -ignore SIGHUP
/home/abuild/rpmbuild/BUILD/gcc-10.3.0+git1587/obj-aarch64-suse-linux/./gcc/xgcc
-B/home/abuild/rpmbuild/BUILD/gcc-10.3.0+git1587/obj-aarch64-suse-linux/./gcc/
-B/usr/aarch64-suse-linux/bin/ -B/usr/aarch64-suse-linux/lib/ -isystem
/usr/aarch64-suse-linux/include -isystem /usr/aarch64-suse-linux/sys-include
-fchecking=1 ../../../../libgomp/testsuite/libgomp.c/examples-4/target_data-4.c
-B/home/abuild/rpmbuild/BUILD/gcc-10.3.0+git1587/obj-aarch64-suse-linux/aarch64-suse-linux/./libgomp/
-B/home/abuild/rpmbuild/BUILD/gcc-10.3.0+git1587/obj-aarch64-suse-linux/aarch64-suse-linux/./libgomp/.libs
-I/home/abuild/rpmbuild/BUILD/gcc-10.3.0+git1587/obj-aarch64-suse-linux/aarch64-suse-linux/./libgomp
-I../../../../libgomp/testsuite/../../include
-I../../../../libgomp/testsuite/.. -Lno -fmessage-length=0
-fno-diagnostics-show-caret -Wno-hsa -fdiagnostics-color=never
-B/usr/lib64/gcc/aarch64-suse-linux/10 -B/usr/bin -fopenmp -O2
-L/home/abuild/rpmbuild/BUILD/gcc-10.3.0+git1587/obj-aarch64-suse-linux/aarch64-suse-linux/./libgomp/.libs
-lm -o ./target_data-4.exe^M
mkoffload: internal compiler error: in main, at config/nvptx/mkoffload.c:511^M
Please submit a full bug report,^M
with preprocessed source if appropriate.^M
See <https://bugs.opensuse.org/> for instructions.^M
lto-wrapper: fatal error:
/usr/lib64/gcc/aarch64-suse-linux/10//accel/nvptx-none/mkoffload returned 4
exit status^M
compilation terminated.^M
/usr/aarch64-suse-linux/bin/ld: error: lto-wrapper failed^M

if you look at mkoffload you see

  switch (offload_abi)
    {
    case OFFLOAD_ABI_LP64:
      obstack_ptr_grow (&argv_obstack, "-m64");
      break;
    case OFFLOAD_ABI_ILP32:
      obstack_ptr_grow (&argv_obstack, "-m32");
      break;
    default:
      gcc_unreachable ();  // <--- ICE here

I fail to see a corresponding setting of -foffload-abi in the aarch64 backend
on the branch (there is one on trunk).

I'm not at all sure how this is a regression but the testcase passes earlier
(10.2.1+git583 vs. 10.3.0+git1587)


More information about the Gcc-bugs mailing list