https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115559
--- Comment #4 from Tobias Burnus <burnus at gcc dot gnu.org> --- NOTE to self: This code now adds the attribute unconditionally. For COMMON and MODULE it makes sense; but for programm/subroutine/function, it needs to be rechecked whether that variable is actually used. An example where the variable is in the main program and the user is in a contained subroutine fails – i.e. simply excluding that case will not work. But maybe the decl can be avoided at least in some cases.