https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96835
Thomas Schwinge <tschwinge at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Ever confirmed|0 |1
Assignee|unassigned at gcc dot gnu.org |tschwinge at gcc dot
gnu.org
Depends on| |105018
CC| |tschwinge at gcc dot gnu.org
Status|UNCONFIRMED |ASSIGNED
Last reconfirmed|2020-08-28 00:00:00 |2024-10-08
--- Comment #8 from Thomas Schwinge <tschwinge at gcc dot gnu.org> ---
With current GCC, for nvptx offloading, '-O0', we get for the "Reproducer"
(attached, also #c2):
reproducer.cpp:18:1: error: alias definitions not supported in this
configuration
18 | vector<sz>::vector(int const& init_val) {
| ^
nvptx mkoffload: fatal error:
build-gcc/gcc/x86_64-pc-linux-gnu-accel-nvptx-none-gcc returned 1 exit status
[...]
With either optimizations enabled, or '-O0' with additional
'-foffload-options=nvptx-none="-mptx=6.3 -malias"', compilation succeeds, and
we get the expected:
$ ./a.out
8
Therefore, this issue should (soon...) get resolved via PR105018 "[nvptx] Need
better alias support", and I'll make sure to include your test case, thanks!
Referenced Bugs:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105018
[Bug 105018] [nvptx] Need better alias support