diff options
Diffstat (limited to 'gcc/varasm.c')
-rw-r--r-- | gcc/varasm.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/gcc/varasm.c b/gcc/varasm.c index fec16d5..b13e09c 100644 --- a/gcc/varasm.c +++ b/gcc/varasm.c @@ -5364,4 +5364,18 @@ default_internal_label (stream, prefix, labelno) ASM_OUTPUT_LABEL (stream, buf); } +/* This is a generic routine suitable for use as TARGET_ASM_FILE_END + which emits a special section directive used to indicate whether or + not this object file needs an executable stack. This is primarily + a GNU extension to ELF but could be used on other targets. */ +void +file_end_indicate_exec_stack () +{ + unsigned int flags = SECTION_DEBUG; + if (trampolines_created) + flags |= SECTION_CODE; + + named_section_flags (".note.GNU-stack", flags); +} + #include "gt-varasm.h" |