diff options
author | Steven Bosscher <steven@gcc.gnu.org> | 2012-06-19 19:55:33 +0000 |
---|---|---|
committer | Steven Bosscher <steven@gcc.gnu.org> | 2012-06-19 19:55:33 +0000 |
commit | a8781821e0f8f7ce6b89160bf3b2a0f2c1ee4350 (patch) | |
tree | fca433b11c05a5a771c4a816fb110130e6e63fcb /gcc/config/cris/cris.c | |
parent | e42d5b2d0ea214f6f52a77693327b2a12ad8dc38 (diff) | |
download | gcc-a8781821e0f8f7ce6b89160bf3b2a0f2c1ee4350.zip gcc-a8781821e0f8f7ce6b89160bf3b2a0f2c1ee4350.tar.gz gcc-a8781821e0f8f7ce6b89160bf3b2a0f2c1ee4350.tar.bz2 |
target.def (output_ident): New hook.
gcc/
* target.def (output_ident): New hook.
* targhooks.h (default_asm_output_ident_directive): Add prototype.
* varasm.c (assemble_asm): Only prefix a tab if the string does not
already start with one.
(default_asm_output_ident_directive): New function to emit
.ident as a top-level asm node while parsing, or directly to
asm_out_file after parsing.
* toplev.c (compile_file): Print a GCC .ident with
targetm.asm_out.output_ident.
* doc/tm.texi.in (ASM_OUTPUT_IDENT): Remove documentation for macro.
(TARGET_ASM_OUTPUT_IDENT): Add @hook for this.
* doc/tm.texi: Update.
* config/elfos.h (ASM_OUTPUT_IDENT, IDENT_ASM_OP): Remove.
(TARGET_ASM_OUTPUT_IDENT): Define.
* config/i386/djgpp.h (IDENT_ASM_OP): Remove.
* config/i386/gas.h (ASM_OUTPUT_IDENT): Remove.
* config/arm/aout.h (ASM_OUTPUT_IDENT): Remove.
* config/sparc/sparc.h (IDENT_ASM_OP): Remove.
(TARGET_ASM_OUTPUT_IDENT): Define.
* config/picochip/picochip.h (IDENT_ASM_OP): Remove.
(TARGET_ASM_OUTPUT_IDENT): Define.
* config/cris/cris-protos.h (cris_asm_output_ident): Add prototype.
* config/cris/cris.c (cris_asm_output_ident): New function.
* config/cris/cris.h (ASM_OUTPUT_IDENT, IDENT_ASM_OP): Remove.
* config/microblaze/microblaze-protos.h (microblaze_asm_output_ident):
Add prototype.
* config/microblaze/microblaze.c: Include cgraph.h for add_asm_node.
(microblaze_asm_output_ident): Rewrite to work similar to
default_asm_output_ident_directive for front-end .idents.
* config/microblaze/microblaze.h (ASM_OUTPUT_IDENT): Remove.
(TARGET_ASM_OUTPUT_IDENT): Define.
* config/mips/mips.h (ASM_OUTPUT_IDENT): Remove.
* config/mips/sde.h (IDENT_ASM_OP, ASM_OUTPUT_IDENT): Remove.
* config/rx/rx.c: Include cgraph.h for add_asm_node.
(rx_asm_output_ident): New function, similar to
default_asm_output_ident_directive, but handle AS100 syntax also, so
that #ident also works for rx in AS100 syntax.
(TARGET_ASM_OUTPUT_IDENT): Define.
* config/rx/rx.h (IDENT_ASM_OP): Remove.
* Makefile.in: Fix dependencies for c-family/c-lex.o.
c-family/
* c-lex.c: Do not include output.h.
(cb_ident): Try to put out .ident with targetm.asm_out.output_ident.
Remove uses of ASM_OUTPUT_IDENT.
ada/
* gcc-interface/trans.c: Include target.h.
(gigi): Try to put out .ident with targetm.asm_out.output_ident.
Remove uses of ASM_OUTPUT_IDENT.
* gcc-interface/Make-lang.in: Fix dependencies.
From-SVN: r188791
Diffstat (limited to 'gcc/config/cris/cris.c')
-rw-r--r-- | gcc/config/cris/cris.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/gcc/config/cris/cris.c b/gcc/config/cris/cris.c index 3c6fb08..a5a3427 100644 --- a/gcc/config/cris/cris.c +++ b/gcc/config/cris/cris.c @@ -2467,6 +2467,22 @@ cris_legitimate_pic_operand (rtx x) return cris_valid_pic_const (x, true); } +/* Queue an .ident string in the queue of top-level asm statements. + If the front-end is done, we must be being called from toplev.c. + In that case, do nothing. */ +void +cris_asm_output_ident (const char *string) +{ + const char *section_asm_op; + int size; + char *buf; + + if (cgraph_state != CGRAPH_STATE_PARSING) + return; + + default_asm_output_ident_directive (string); +} + /* The ASM_OUTPUT_CASE_END worker. */ void @@ -2517,6 +2533,10 @@ cris_asm_output_case_end (FILE *stream, int num, rtx table) static void cris_option_override (void) { + /* We don't want an .ident for gcc. + It isn't really clear anymore why not. */ + flag_no_gcc_ident = true; + if (cris_max_stackframe_str) { cris_max_stackframe = atoi (cris_max_stackframe_str); |