OSDN Git Service

gcc/
authorrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 13 Sep 2007 12:44:10 +0000 (12:44 +0000)
committerrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>
Thu, 13 Sep 2007 12:44:10 +0000 (12:44 +0000)
commit9551843492337dbb698b697399d9a3794e7bad30
tree7ea310d5401715a64606a38ee1ab5e463b04c0cd
parent9a21152d403fca1ef2d585a0bf9452b5f3d06430
gcc/
2007-09-13  Richard Sandiford  <richard@codesourcery.com>
    Sandra Loosemore <sandra@codesourcery.com>

* config/mips/mips.h (SYMBOL_FLAG_MIPS16_FUNC): Delete.
(SYMBOL_REF_MIPS16_FUNC_P): Delete.
* config/mips/mips.c (mips_attribute_table): Turn mips16 and
nomips16 into decl attributes.
(TARGET_INSERT_ATTRIBUTES): Override.
(TARGET_MERGE_DECL_ATTRIBUTES): Likewise.
(TARGET_FUNCTION_ATTRIBUTE_INLINABLE_P): Always return true.
(mips_mips16_type_p, mips_nomips16_type_p): Delete in favor of...
(mips_mips16_decl_p, mips_nomips16_decl_p): ...these new functions.
(mips_comp_type_attributes): Remove mips16 and nomips16 handling.
(mips_use_mips16_mode_p): Reimplement as a function that takes
a decl and considers only decl attributes.  If the decl is nested
function, use its parent attributes.
(mips_function_ok_for_sibcall): Use mips_use_mips16_mode_p
instead of SYMBOL_REF_MIPS16_FUNC_P.
(mips_set_mips16_mode): Move call to sorry here from old
mips_use_mips16_mode_p.
(mflip_mips16_entry): New structure.
(mflip_mips16_htab): New variable.
(mflip_mips16_htab_hash, mflip_mips16_htab_eq): New functions.
(mflip_mips16_use_mips16_p, mips_insert_attributes): Likewise.
(mips_merge_decl_attributes): New function.
(mips_set_current_function): Reinstate call to mips_set_mips16_mode.
Use mips_use_mips16_mode_p.
(mips_output_mi_thunk): Use mips_use_mips16_mode_p instead of
SYMBOL_REF_MIPS16_FUNC_P.
(mips_encode_section_info): Don't set SYMBOL_FLAG_MIPS16_FUNC.

gcc/testsuite/
* gcc.dg/gcc-have-sync-compare-and-swap.c: Skip for -mflip-mips16.
* gcc.target/mips/mips16-attributes-2.c: New test.
* gcc.target/mips/mips16-attributes-3.c: Likewise.
* gcc.target/mips/args-3.c: Skip for -mflip-mips16.  Do not use the
hard-float asm when __mips16 is defined.
* gcc.target/mips/atomic-memory-1.c (main): Add a nomips16 attribute.
* gcc.target/mips/atomic-memory-2.c (main): Likewise.
* gcc.target/mips/fpcmp-1.c (f1, f2): Likewise.
* gcc.target/mips/fpcmp-2.c (f1, f2): Likewise.
* gcc.target/mips/neg-abs-1.c (f1, f2, d1, f2): Likewise.
* gcc.target/mips/pr26765.c (foo): Likewise.
* gcc.target/mips/gcc-have-sync-compare-and-swap-1.c: Run for all
targets, use dg-mips-options instead of dg-options, and use -mgp32
to force 32-bit mode.
* gcc.target/mips/gcc-have-sync-compare-and-swap-2.c: Likewise -mgp64
and 64-bit mode.
* gcc.target/mips/mips.exp (is_gp32_flag): Return true for -mips32*.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@128460 138bc75d-0d04-0410-961f-82ee72b054a4
17 files changed:
gcc/ChangeLog
gcc/config/mips/mips.c
gcc/config/mips/mips.h
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/gcc-have-sync-compare-and-swap.c
gcc/testsuite/gcc.target/mips/args-3.c
gcc/testsuite/gcc.target/mips/atomic-memory-1.c
gcc/testsuite/gcc.target/mips/atomic-memory-2.c
gcc/testsuite/gcc.target/mips/fpcmp-1.c
gcc/testsuite/gcc.target/mips/fpcmp-2.c
gcc/testsuite/gcc.target/mips/gcc-have-sync-compare-and-swap-1.c
gcc/testsuite/gcc.target/mips/gcc-have-sync-compare-and-swap-2.c
gcc/testsuite/gcc.target/mips/mips.exp
gcc/testsuite/gcc.target/mips/mips16-attributes-2.c [new file with mode: 0644]
gcc/testsuite/gcc.target/mips/mips16-attributes-3.c [new file with mode: 0644]
gcc/testsuite/gcc.target/mips/neg-abs-1.c
gcc/testsuite/gcc.target/mips/pr26765.c