gcc/ 2007-08-08 Richard Sandiford <richard@codesourcery.com> Sandra Loosemore <sandra@codesourcery.com> Chao-ying Fu <fu@mips.com> Nigel Stephens <nigel@mips.com> David Ung <davidu@mips.com> * doc/invoke.texi (-mcode-readable): Document. * config/mips/mips.opt (mcode-readable): New option. * config/mips/mips-protos.h (SYMBOL_32_HIGH): New symbol type. * config/mips/mips.h (mips_code_readable_setting): New enum. (mips_code_readable): Declare. (TARGET_MIPS16_TEXT_LOADS, TARGET_MIPS16_PCREL_LOADS): New macros. (TARGET_MIPS16_SHORT_JUMP_TABLES): New macro. (JUMP_TABLES_IN_TEXT_SECTION): Use it. (CASE_VECTOR_MODE, CASE_VECTOR_PC_RELATIVE): Likewise. Remove boiler-plate comments. (ASM_OUTPUT_ADDR_DIFF_ELT): Use TARGET_MIPS16_SHORT_JUMP_TABLES. * config/mips/mips.c (mips_code_readable): New variable. (mips_classify_symbol): Only return SYMBOL_PC_RELATIVE for MIPS16 labels if TARGET_MIPS16_SHORT_JUMP_TABLES. Use both the context and -mcode-readable setting to restrict the use of SYMBOL_PC_RELATIVE for MIPS16 constant pool references. Only return TARGET_FORCE_TO_MEM if PC-relative loads are allowed. (mips_symbolic_constant_p): Handle SYMBOL_32_HIGH. (mips_blocks_for_constant_p): Only return false for TARGET_MIPS16_PCREL_LOADS. (mips_symbol_insns_1): Treat HIGHs as 2 extended instructions for MIPS16. Handle SYMBOL_32_HIGH. (mips_const_insns): Allow HIGHs for MIPS16 too. (mips_unspec_address_offset): New function, split out from... (mips_unspec_address): ...here. (mips_output_move): Handle MIPS16 HIGH moves. Use "li" to load 16-bit symbolic constants. Assert approropiate conditions for using the "la" and "dla" macros. (mips_handle_option): Handle -mcode-readable=. (override_options): Use %hi/%lo relocations for TARGET_MIPS16 too. Set up mips_lo_relocs[SYMBOL_32_HIGH]. (mips_strip_unspec_address): New function, split out from... (print_operand_reloc): ...here. (print_operand): Pass constants through mips_strip_unspec_address. (print_operand_address): Likewise. (mips_output_mi_thunk): Remove guard of mips16_lay_out_constants. (mips_select_rtx_section): Remove MIPS16 handling. (mips16_gp_pseudo_reg): Check currently_expanding_to_rtl. (mips16_rewrite_pool_refs): Wrap the labels in an address UNSPEC. (mips16_lay_out_constants): Do nothing unless TARGET_MIPS16_PCREL_LOADS. (mips_avoid_hazards): Remove guard of mips16_lay_out_constants. * config/mips/mips.md: Split HIGHs for MIPS16. (tablejump): Use TARGET_MIPS16_SHORT_JUMP_TABLES. gcc/testsuite/ * gcc.target/mips/code-readable-1.c: New test. * gcc.target/mips/code-readable-2.c: Likewise. * gcc.target/mips/code-readable-3.c: Likewise. Co-Authored-By: Chao-ying Fu <fu@mips.com> Co-Authored-By: David Ung <davidu@mips.com> Co-Authored-By: Nigel Stephens <nigel@mips.com> Co-Authored-By: Sandra Loosemore <sandra@codesourcery.com> From-SVN: r127300
Name |
Last commit
|
Last update |
---|---|---|
INSTALL | Loading commit data... | |
boehm-gc | Loading commit data... | |
config | Loading commit data... | |
contrib | Loading commit data... | |
fixincludes | Loading commit data... | |
gcc | Loading commit data... | |
gnattools | Loading commit data... | |
include | Loading commit data... | |
intl | Loading commit data... | |
libada | Loading commit data... | |
libcpp | Loading commit data... | |
libdecnumber | Loading commit data... | |
libffi | Loading commit data... | |
libgcc | Loading commit data... | |
libgfortran | Loading commit data... | |
libgomp | Loading commit data... | |
libiberty | Loading commit data... | |
libjava | Loading commit data... | |
libmudflap | Loading commit data... | |
libobjc | Loading commit data... | |
libssp | Loading commit data... | |
libstdc++-v3 | Loading commit data... | |
maintainer-scripts | Loading commit data... | |
zlib | Loading commit data... | |
ABOUT-NLS | Loading commit data... | |
COPYING | Loading commit data... | |
COPYING.LIB | Loading commit data... | |
COPYING3 | Loading commit data... | |
COPYING3.LIB | Loading commit data... | |
ChangeLog | Loading commit data... | |
ChangeLog.tree-ssa | Loading commit data... | |
MAINTAINERS | Loading commit data... | |
Makefile.def | Loading commit data... | |
Makefile.in | Loading commit data... | |
Makefile.tpl | Loading commit data... | |
README | Loading commit data... | |
README.SCO | Loading commit data... | |
compile | Loading commit data... | |
config-ml.in | Loading commit data... | |
config.guess | Loading commit data... | |
config.rpath | Loading commit data... | |
config.sub | Loading commit data... | |
configure | Loading commit data... | |
configure.ac | Loading commit data... | |
depcomp | Loading commit data... | |
install-sh | Loading commit data... | |
libtool-ldflags | Loading commit data... | |
libtool.m4 | Loading commit data... | |
ltgcc.m4 | Loading commit data... | |
ltmain.sh | Loading commit data... | |
ltoptions.m4 | Loading commit data... | |
ltsugar.m4 | Loading commit data... | |
ltversion.m4 | Loading commit data... | |
lt~obsolete.m4 | Loading commit data... | |
missing | Loading commit data... | |
mkdep | Loading commit data... | |
mkinstalldirs | Loading commit data... | |
move-if-change | Loading commit data... | |
symlink-tree | Loading commit data... | |
ylwrap | Loading commit data... |