On Thu, 22 Feb 2024 10:18:21 GMT, Julian Waters <jwat...@openjdk.org> wrote:

>> You mean making a search/replace from `__attribute__ ((foo))` to 
>> `[[gnu::foo)]]` in the code base? It seems a bit like unnecessary churn to 
>> me. We have 100+ places in the code with `__attribute__`. If you really want 
>> to try to push that agenda, be my guest. But do it in a separate PR. ;-)
>
> Oh no, by fix I meant removing the HIDDEN attribute and somehow fixing that 
> issue differently, not replacing everything with C++ Attributes!

Well, I hope that can be done, but it depends... As I see it, there are three 
possible ways to get rid of this `HIDDEN`.

1) Accept that we export these functions on gcc, and just remove the attribute. 
(Kind of capitulating to the bug.)

2) See if there is a way we can work around this problem, by changing something 
in how these functions are defined, that does not trigger this bug.

3) Have this bug fixed in gcc, and move to a minimum version of gcc that 
includes this fix.

I'm not terribly keen on any of these solutions. I think 2, if it is possible, 
would be the simplest and cleanest. Or 1, if we really think this HIDDEN 
workaround is worse than the problem it solves (unintentionally exporting 
symbols).

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/17955#discussion_r1499275242

Reply via email to