OSDN Git Service

* common.opt (record-gcc-switches): New command line switch.
authornickc <nickc@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 7 Dec 2006 10:54:13 +0000 (10:54 +0000)
committernickc <nickc@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 7 Dec 2006 10:54:13 +0000 (10:54 +0000)
commit7c6733e83d719397e14db3fe220bc544132a6550
tree46d6178c94554a22a20fe838a94fbf98cec94d4d
parent90bf0a0066d0e93b78eb3012c17b323cd084ff8b
* common.opt (record-gcc-switches): New command line switch.
* target.h (print_switch_type): New enum.
  (print_switch_fn_type): New typedef for a function pointer.
  (struct gcc_target): Add record_gcc_switches and record_gcc_switches_section fields.
* target-def.h (TARGET_ASM_RECORD_GCC_SWITCHES): Provide a default definition.
  (TARGET_ASM_RECORD_GCC_SWITCHES_SECTION): Provide a default definition.
* toplev.c (print_single_switch): Simplify by providing a pointer to function that will format and output the switch appropriately.
  (print_switch_values): Likewise.
  (print_to_asm_out_file): New function.
  (print_to_stderr): New function.
  (init_asm_output): If flag_record_gcc_switches is set then if the target supports recording the switches then emit them into the assembler output file, otherwise tell the user that the switch is not supported.
* varasm.c (eld_record_gcc_switches): New function.  Example handler for the record_gcc_switches target hook.
* doc/tm.texi (TARGET_ASM_RECORD_GCC_SWITCHES): Document the new target hook.
  (TARGET_ASM_RECORD_GCC_SWITCHES_SECTION): Likewise.
* doc/invoke.texi (-frecord-gcc-switches): Document.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@119615 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ChangeLog
gcc/common.opt
gcc/doc/invoke.texi
gcc/doc/tm.texi
gcc/target-def.h
gcc/target.h
gcc/toplev.c
gcc/varasm.c