Commit years-old change for gcc on NetDSB/mips.
The NetbSD libc header files use GCC attributes to emit link-time warning messages (e.g,. for gets()). SO, add a definition of the GCC back-end macro ASM_OUTPUT_SECTION_NAME() to the mips back-end target-specific file. This adds support for emitting warning attributes to binutils 2.6 or newer. (Weak references may or may not work also). This patch has been submitted to the FSF but hasn't made it into 2.7.2.1, and seems to have got buried somewhere inside Cygnus.
This commit is contained in:
parent
5049f4d106
commit
bdc1084483
@ -3811,3 +3811,19 @@ while (0)
|
||||
#define NO_BUILTIN_PTRDIFF_TYPE
|
||||
#define PTRDIFF_TYPE (TARGET_LONG64 ? "long int" : "int")
|
||||
#endif
|
||||
|
||||
/* A C statement to output something to the assembler file to switch to section
|
||||
NAME for object DECL which is either a FUNCTION_DECL, a VAR_DECL or
|
||||
NULL_TREE. Some target formats do not support arbitrary sections. Do not
|
||||
define this macro in such cases. */
|
||||
|
||||
#define ASM_OUTPUT_SECTION_NAME(F, DECL, NAME) \
|
||||
do { \
|
||||
extern FILE *asm_out_text_file; \
|
||||
if ((DECL) && TREE_CODE (DECL) == FUNCTION_DECL) \
|
||||
fprintf (asm_out_text_file, "\t.section %s,\"ax\",@progbits\n", (NAME)); \
|
||||
else if ((DECL) && TREE_READONLY (DECL)) \
|
||||
fprintf (F, "\t.section %s,\"a\",@progbits\n", (NAME)); \
|
||||
else \
|
||||
fprintf (F, "\t.section %s,\"aw\",@progbits\n", (NAME)); \
|
||||
} while (0)
|
||||
|
Loading…
Reference in New Issue
Block a user