https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61848
Alan Modra <amodra at gmail dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |amodra at gmail dot com --- Comment #10 from Alan Modra <amodra at gmail dot com> --- Created attachment 33480 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=33480&action=edit A different approach to fixing this bug I was playing with this one today, before I found your bugzilla Andrew. It has been regression tested on x86_64, fixes the loss of section attributes, and builds a 3.16 x86_64 defconfig kernel - haven't checked if it boots yet.. Adds a fix for C++ which has the same problem as C. (The s/olddecl/newdecl/ lines are because "if (TREE_CODE (newdecl) == FUNCTION_DECL) ... else switch (TREE_CODE (olddecl))" looks horrible. Cosmetic really since we exit the function before this code if TREE_CODE (newdecl) != TREE_CODE (olddecl).)