[Bug c++/97222] GCC discards attributes aligned and may_alias for typedefs passed as template arguments

2023-01-01 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97222

Andrew Pinski  changed:

   What|Removed |Added

 CC||ian at geometrian dot com

--- Comment #9 from Andrew Pinski  ---
*** Bug 108262 has been marked as a duplicate of this bug. ***

[Bug c++/97222] GCC discards attributes aligned and may_alias for typedefs passed as template arguments

2021-12-03 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97222

Andrew Pinski  changed:

   What|Removed |Added

 CC||liavonlida at gmail dot com

--- Comment #8 from Andrew Pinski  ---
*** Bug 100742 has been marked as a duplicate of this bug. ***

[Bug c++/97222] GCC discards attributes aligned and may_alias for typedefs passed as template arguments

2021-12-03 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97222

Andrew Pinski  changed:

   What|Removed |Added

 CC||kip at thevertigo dot com

--- Comment #7 from Andrew Pinski  ---
*** Bug 84055 has been marked as a duplicate of this bug. ***

[Bug c++/97222] GCC discards attributes aligned and may_alias for typedefs passed as template arguments

2021-12-03 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97222

Andrew Pinski  changed:

   What|Removed |Added

 CC||paul.groke at dynatrace dot com

--- Comment #6 from Andrew Pinski  ---
*** Bug 82270 has been marked as a duplicate of this bug. ***

[Bug c++/97222] GCC discards attributes aligned and may_alias for typedefs passed as template arguments

2021-12-03 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97222

Andrew Pinski  changed:

   What|Removed |Added

 CC||myriachan at gmail dot com

--- Comment #5 from Andrew Pinski  ---
*** Bug 84415 has been marked as a duplicate of this bug. ***

[Bug c++/97222] GCC discards attributes aligned and may_alias for typedefs passed as template arguments

2020-09-29 Thread mte.zych at gmail dot com via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97222

Mateusz Zych  changed:

   What|Removed |Added

   See Also||https://bugs.llvm.org/show_
   ||bug.cgi?id=47674

--- Comment #4 from Mateusz Zych  ---
I just wanted to mention, that I raised issue in the Clang Bugzilla,
since Clang is matching GCC behavior (also discards attributes):

 - https://bugs.llvm.org/show_bug.cgi?id=47674

Thanks, Mateusz

[Bug c++/97222] GCC discards attributes aligned and may_alias for typedefs passed as template arguments

2020-09-28 Thread richard-gccbugzilla at metafoo dot co.uk via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97222

Richard Smith  changed:

   What|Removed |Added

 CC||richard-gccbugzilla@metafoo
   ||.co.uk

--- Comment #3 from Richard Smith  ---
> would be interesting to see how ICC mangles the aligned case

It doesn't, it just takes the properties from whichever instantiation happens
to be performed first. On ICC,

 std::cout << alignof(typename identity::type) << std::endl;
 std::cout << alignof(typename identity::type) << std::endl;

prints 4 4, and 

 std::cout << alignof(typename identity::type) << std::endl;
 std::cout << alignof(typename identity::type) << std::endl;

prints 16 16. The ICC behavior seems unsound, compared to the GCC / Clang
behavior of (effectively) stripping the attribute from template arguments.

> There is NO way defined at this point to mange for some attributes
> including but not limited to may_alias and alignment.

These can be mangled as s:
http://itanium-cxx-abi.github.io/cxx-abi/abi.html#mangle.qualified-type

Presumably the more problematic part from an ABI perspective is that this will
change a bunch of existing manglings. Similarly from a source compatibility
standpoint, making the alignment override part of the type would be a breaking
change. It'd probably be better to add a new syntax for the new functionality
(please, not based on an attributed typedef this time!) and deprecate the old
way.

[Bug c++/97222] GCC discards attributes aligned and may_alias for typedefs passed as template arguments

2020-09-28 Thread rguenth at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97222

--- Comment #2 from Richard Biener  ---
would be interesting to see how ICC mangles the aligned case

[Bug c++/97222] GCC discards attributes aligned and may_alias for typedefs passed as template arguments

2020-09-27 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=97222

Andrew Pinski  changed:

   What|Removed |Added

   Severity|normal  |enhancement
   Keywords||ABI
   Last reconfirmed||2020-09-28
 Status|UNCONFIRMED |SUSPENDED
 Ever confirmed|0   |1

--- Comment #1 from Andrew Pinski  ---
Actually this is more complex than what is mentioned here.  THIS REQUIRES An
ABI addition.  Due to the way templates cause name managling to come into play.
 There is NO way defined at this point to mange for some attributes including
but not limited to may_alias and alignment.

Suspending until there is a definition of that defined.