summaryrefslogtreecommitdiff
path: root/gas/hash.c
Commit message (Collapse)AuthorAgeFilesLines
* Update year range in copyright notice of binutils filesAlan Modra2023-01-011-1/+1
| | | | | | The newer update-copyright.py fixes file encoding too, removing cr/lf on binutils/bfdtest2.c and ld/testsuite/ld-cygwin/exe-export.exp, and embedded cr in binutils/testsuite/binutils-all/ar.exp string match.
* gas hash.h tidyAlan Modra2022-07-091-0/+20
| | | | | | | | | | | | | | | Only inline functions should be defined in hash.h, there's no benefit in having multiple copies of hash_string_tuple and eq_string_tuple. Also, use the table alloc_f when allocating tuples to be stored, so that these functions are usable with different memory allocation strategies. * hash.h (struct string_tuple, string_tuple_t): Move earlier. (string_tuple_alloc): Add table param, allocate using table alloc_f. (str_hash_insert): Adjust to suit. Call table->free_f when entry is not used. (hash_string_tuple, eq_string_tuple): Move to.. * hash.c: ..here.
* Update year range in copyright notice of binutils filesAlan Modra2022-01-021-1/+1
| | | | | | | | | | The result of running etc/update-copyright.py --this-year, fixing all the files whose mode is changed by the script, plus a build with --enable-maintainer-mode --enable-cgen-maint=yes, then checking out */po/*.pot which we don't update frequently. The copy of cgen was with commit d1dd5fcc38ead reverted as that commit breaks building of bfp opcodes files.
* Update year range in copyright notice of binutils filesAlan Modra2021-01-011-1/+1
|
* PR26513, 629310abec breaks assembling PowerPC Linux kernelsAlan Modra2020-08-231-6/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Inserting with replacement is wrong for some gas hash table uses. This patch implements an htab_insert that conditionally replaces, and similarly for str_hash_insert. str_hash_insert with replace=0 is roughly equivalent to the older hash_insert, and str_hash_insert with replace=1 to the older hash_jam, but return values are different. I found it useful to know whether the slot was occupied prior to inserting/replacing. I've also reinstated the fatal errors on messing up opcode tables with duplicates. PR 26513 * hash.h (htab_insert): Update prototype and comment. (struct string_tuple): Make "value" a const void*. (string_tuple_alloc): Likewise. (str_hash_find, str_hash_find_n): Cast returned value. (str_hash_insert): Add "replace" parameter, and return slot pointer. Free alloc'd element when not inserted. * hash.c (htab_insert): Likewise. Return slot when element exists, otherwise return NULL. * read.c (pop_insert): Insert into hash table without first searching. * config/tc-avr.c (md_begin): Likewise. * config/tc-msp430.c (md_begin): Likewise. * config/tc-nds32.c (nds32_init_nds32_pseudo_opcodes): Likewise. * config/tc-v850.c (md_begin): Likewise. * macro.c (do_formals, define_macro, macro_expand_body): Likewise. (delete_macro): Delete from hash table. * config/tc-tic54x.c (subsym_create_or_replace): Correct logic. * symbols.c (local_symbol_make, symbol_table_insert): Allow replacement of hash table entries. * config/obj-coff-seh.c (seh_hash_insert): Likewise. * config/obj-coff.c (tag_insert): Likewise. * config/tc-iq2000.c (iq2000_add_macro): Likewise. * config/tc-m68k.c (md_begin): Likewise for aliases. * config/tc-tic4x.c (tic4x_asg): Likewise. * config/tc-tic6x.c (md_begin): Likewise. * dw2gencfi.c (dwcfi_hash_find_or_make): Disallow replacement of hash table entries. * ecoff.c (add_string, get_tag): Likewise. * macro.c (expand_irp): Likewise. * config/obj-elf.c (build_additional_section_info): Likewise. * config/tc-aarch64.c (insert_reg_alias): Likewise. (checked_hash_insert): Likewise. * config/tc-alpha.c (get_alpha_reloc_tag, md_begin): Likewise. * config/tc-arc.c (arc_insert_opcode, declare_register): Likewise. (declare_addrtype, md_begin, arc_extcorereg): Likewise. * config/tc-arm.c (insert_reg_alias): Likewise. (arm_tc_equal_in_insn, md_begin): Likewise. * config/tc-cr16.c (initialise_reg_hash_table, md_begin): Likewise. * config/tc-cris.c (md_begin): Likewise. * config/tc-crx.c (md_begin): Likewise. * config/tc-csky.c (md_begin): Likewise. * config/tc-d10v.c (md_begin): Likewise. * config/tc-dlx.c (md_begin): Likewise. * config/tc-ft32.c (md_begin): Likewise. * config/tc-h8300.c (md_begin): Likewise. * config/tc-hppa.c (md_begin): Likewise. * config/tc-i386.c (md_begin): Likewise. * config/tc-ia64.c (dot_rot, dot_entry, declare_register): Likewise. (md_begin, dot_alias): Likewise. * config/tc-m68hc11.c (md_begin): Likewise. * config/tc-m68k.c (md_begin): Likewise. * config/tc-mcore.c (md_begin): Likewise. * config/tc-microblaze.c (md_begin): Likewise. * config/tc-mips.c (md_begin): Likewise. * config/tc-mmix.c (md_begin): Likewise. * config/tc-mn10200.c (md_begin): Likewise. * config/tc-mn10300.c (md_begin): Likewise. * config/tc-moxie.c (md_begin): Likewise. * config/tc-nds32.c (nds32_relax_hint, md_begin): Likewise. * config/tc-nios2.c (md_begin): Likewise. * config/tc-ns32k.c (md_begin): Likewise. * config/tc-pdp11.c (md_begin): Likewise. * config/tc-pj.c (fake_opcode, md_begin): Likewise. * config/tc-ppc.c (ppc_setup_opcodes): Likewise. * config/tc-pru.c (md_begin): Likewise. * config/tc-riscv.c (init_ext_version_hash): Likewise. (init_opcode_names_hash, hash_reg_name, init_opcode_hash): Likewise. (riscv_init_csr_hash): Likewise. * config/tc-s390.c (s390_setup_opcodes, md_begin): Likewise. * config/tc-score.c (s3_insert_reg): Likewise. (s3_build_score_ops_hsh, s3_build_dependency_insn_hsh): Likewise. * config/tc-score7.c (s7_build_score_ops_hsh): Likewise. (s7_build_dependency_insn_hsh, s7_insert_reg): Likewise. * config/tc-sh.c (md_begin): Likewise. * config/tc-sparc.c (md_begin): Likewise. * config/tc-spu.c (md_begin): Likewise. * config/tc-tic30.c (md_begin): Likewise. * config/tc-tic4x.c (tic4x_inst_insert): Likewise. * config/tc-tic54x.c (stag_add_field_symbols, md_begin): Likewise. (tic54x_endstruct, tic54x_var, tic54x_macro_info): Likewise. (subsym_substitute): Likewise. * config/tc-tilegx.c (md_begin): Likewise. * config/tc-tilepro.c (md_begin): Likewise. * config/tc-vax.c (vip_begin): Likewise. * config/tc-wasm32.c (md_begin): Likewise. * config/tc-xgate.c (md_begin): Likewise. * config/tc-z8k.c (md_begin): Likewise. * testsuite/gas/ppc/dcbt.d, * testsuite/gas/ppc/dcbt.s: New test. * testsuite/gas/ppc/ppc.exp: Run it. * ecoff.c (add_string): Report fatal error on duplicates. * config/tc-alpha.c (md_begin): Likewise. * config/tc-arc.c (arc_insert_opcode, declare_register): Likewise. (declare_addrtype, md_begin, arc_extcorereg): Likewise. * config/tc-cr16.c (initialise_reg_hash_table, md_begin): Likewise. * config/tc-cris.c (md_begin): Likewise. * config/tc-crx.c (md_begin): Likewise. * config/tc-dlx.c (md_begin): Likewise. * config/tc-hppa.c (md_begin): Likewise. * config/tc-i386.c (md_begin): Likewise. * config/tc-ia64.c (dot_rot, dot_entry, declare_register): Likewise. (md_begin): Likewise. * config/tc-m68k.c (md_begin): Likewise. * config/tc-mips.c (md_begin): Likewise. * config/tc-nios2.c (md_begin): Likewise. * config/tc-ns32k.c (md_begin): Likewise. * config/tc-ppc.c (ppc_setup_opcodes): Likewise. * config/tc-pru.c (md_begin): Likewise. * config/tc-riscv.c (init_ext_version_hash): Likewise. (init_opcode_names_hash, hash_reg_name, init_opcode_hash): Likewise. * config/tc-s390.c (s390_setup_opcodes, md_begin): Likewise. * config/tc-sparc.c (md_begin): Likewise. * config/tc-tic30.c (md_begin): Likewise. * config/tc-tic4x.c (tic4x_inst_insert): Likewise. * config/tc-tilegx.c (md_begin): Likewise. * config/tc-tilepro.c (md_begin): Likewise. * config/tc-vax.c (vip_begin): Likewise. * config/tc-alpha.c, * config/tc-arm.c, * config/tc-avr.c, * config/tc-cr16.c, * config/tc-csky.c, * config/tc-i386.c, * config/tc-m68hc11.c, * config/tc-m68k.c, * config/tc-microblaze.c, * config/tc-ns32k.c, * config/tc-pj.c, * config/tc-ppc.c, * config/tc-score.c, * config/tc-score7.c, * config/tc-tic4x.c, * config/tc-tic54x.c, * config/tc-tilegx.c, * config/tc-tilepro.c, * config/tc-xgate.c: Formatting.
* Remove --reduce-memory-overheads and --hash-size arguments.Martin Liska2020-08-201-574/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * NEWS: Mention --reduce-memory-overheads and --hash-size arguments options. * as.c: Remove the options from help. * doc/as.texi: Remove options. * doc/internals.texi: Remove hash from documentation. * hash.c (struct hash_entry): Remove. (struct hash_control): Likewise. (set_gas_hash_table_size): Likewise. (hash_new_sized): Likewise. (hash_new): Likewise. (hash_die): Likewise. (hash_lookup): Likewise. (hash_insert): Likewise. (hash_jam): Likewise. (hash_replace): Likewise. (hash_find): Likewise. (hash_find_n): Likewise. (hash_delete): Likewise. (hash_traverse): Likewise. (hash_print_statistics): Likewise. (TABLES): Likewise. (STATBUFSIZE): Likewise. (main): Likewise. (what): Likewise. (destroy): Likewise. (applicatee): Likewise. (whattable): Likewise. * hash.h (struct hash_control): Likewise. (set_gas_hash_table_size): Likewise. (hash_new): Likewise. (hash_new_sized): Likewise. (hash_die): Likewise. (hash_insert): Likewise. (hash_jam): Likewise. (hash_replace): Likewise. (hash_find): Likewise. (hash_find_n): Likewise. (hash_delete): Likewise. (hash_traverse): Likewise. (hash_print_statistics): Likewise.
* gas/hash.c: add new functionsMartin Liska2020-08-201-0/+24
| | | | | | | | | | | | The first of a patch series deleting the gas/hash.c hash table implementation and instead using libiberty/hashtab.c hash tables in gas. * as.h: Include hashtab.h. * hash.c (htab_insert): New. (htab_print_statistics): Likewise. * hash.h (htab_insert): Likewise. (htab_print_statistics): Likewise.
* Update year range in copyright notice of binutils filesAlan Modra2020-01-011-1/+1
|
* Update year range in copyright notice of binutils filesAlan Modra2019-01-011-1/+1
|
* Update year range in copyright notice of binutils filesAlan Modra2018-01-031-1/+1
|
* Update year range in copyright notice of all files.Alan Modra2017-01-021-1/+1
|
* use XNEW and related macros moreTrevor Saunders2016-04-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | gas/ChangeLog: 2016-04-03 Trevor Saunders <tbsaunde+binutils@tbsaunde.org> * app.c (app_push): use XNEW macro. * as.c: Likewise. * config/obj-elf.c (obj_elf_change_section): Likewise. (elf_copy_symbol_attributes): Likewise. (obj_elf_size): Likewise. (build_group_lists): Likewise. * config/tc-aarch64.c (add_operand_error_record): Likewise. (md_assemble): Likewise. (tc_gen_reloc): Likewise. (get_upper_str): Likewise. (aarch64_parse_features): Likewise. * config/tc-arm.c (insert_reg_alias): Likewise. (insert_neon_reg_alias): Likewise. (find_or_make_literal_pool): Likewise. (s_arm_elf_cons): Likewise. (add_unwind_opcode): Likewise. (arm_parse_extension): Likewise. * config/tc-avr.c (create_record_for_frag): Likewise. * config/tc-crx.c: Likewise. * config/tc-d30v.c: Likewise. * config/tc-dlx.c (s_proc): Likewise. * config/tc-ft32.c: Likewise. * config/tc-h8300.c: Likewise. * config/tc-hppa.c (pa_proc): Likewise. (create_new_space): Likewise. (create_new_subspace): Likewise. * config/tc-i860.c: Likewise. * config/tc-i960.c: Likewise. * config/tc-ia64.c: Likewise. * config/tc-iq2000.c (iq2000_add_macro): Likewise. (iq2000_record_hi16): Likewise. * config/tc-m32c.c (m32c_indirect_operand): Likewise. * config/tc-m32r.c (debug_sym): Likewise. (m32r_record_hi16): Likewise. * config/tc-m68k.c (m68k_ip): Likewise. (md_begin): Likewise. * config/tc-mcore.c: Likewise. * config/tc-microblaze.c (check_got): Likewise. * config/tc-mips.c (append_insn): Likewise. (s_mipsset): Likewise. (mips_record_label): Likewise. (s_mips_end): Likewise. * config/tc-mmix.c (mmix_frob_file): Likewise. * config/tc-mn10200.c: Likewise. * config/tc-mn10300.c: Likewise. * config/tc-moxie.c: Likewise. * config/tc-msp430.c: Likewise. * config/tc-nds32.c (nds32_elf_save_pseudo_pattern): Likewise. * config/tc-ns32k.c: Likewise. * config/tc-or1k.c: Likewise. * config/tc-pdp11.c: Likewise. * config/tc-pj.c (fake_opcode): Likewise. * config/tc-ppc.c (ppc_apuinfo_section_add): Likewise. (ppc_macro): Likewise. (ppc_dwsect): Likewise. (ppc_machine): Likewise. * config/tc-rl78.c (rl78_frag_init): Likewise. * config/tc-rx.c (rx_frag_init): Likewise. * config/tc-s390.c (s390_lit_suffix): Likewise. (s390_machine): Likewise. (s390_machinemode): Likewise. * config/tc-score.c (s3_insert_reg): Likewise. (s3_gen_reloc): Likewise. * config/tc-score7.c (s7_insert_reg): Likewise. (s7_gen_reloc): Likewise. * config/tc-tic30.c (tic30_operand): Likewise. * config/tc-tic4x.c (tic4x_inst_make): Likewise. * config/tc-tic54x.c (stag_add_field): Likewise. (tic54x_struct): Likewise. (tic54x_space): Likewise. (tic54x_field): Likewise. (tic54x_mlib): Likewise. (subsym_substitute): Likewise. * config/tc-tic6x.c (tic6x_frob_label): Likewise. * config/tc-vax.c: Likewise. * config/tc-xc16x.c: Likewise. * config/tc-xtensa.c (xtensa_add_insn_label): Likewise. (directive_push): Likewise. (xtensa_begin_directive): Likewise. (tokenize_arguments): Likewise. (xtensa_add_literal_sym): Likewise. (new_resource_table): Likewise. (resize_resource_table): Likewise. (emit_single_op): Likewise. (xtensa_create_trampoline_frag): Likewise. (xtensa_maybe_create_literal_pool_frag): Likewise. (xtensa_add_config_info): Likewise. (xtensa_realloc_fixup_cache): Likewise. (add_subseg_info): Likewise. (cache_literal_section): Likewise. (add_xt_block_frags): Likewise. (add_xt_prop_frags): Likewise. (init_op_placement_info_table): Likewise. (build_section_rename): Likewise. * config/tc-z80.c: Likewise. * config/tc-z8k.c: Likewise. * depend.c (register_dependency): Likewise. * dwarf2dbg.c (get_line_subseg): Likewise. (dwarf2_gen_line_info_1): Likewise. (get_filenum): Likewise. * ecoff.c (allocate_scope): Likewise. (allocate_vlinks): Likewise. (allocate_shash): Likewise. (allocate_thash): Likewise. (allocate_tag): Likewise. (allocate_forward): Likewise. (allocate_thead): Likewise. (allocate_lineno_list): Likewise. * expr.c (make_expr_symbol): Likewise. * hash.c (hash_new_sized): Likewise. * input-file.c (input_file_push): Likewise. * listing.c (file_info): Likewise. (listing_newline): Likewise. * macro.c (new_formal): Likewise. (define_macro): Likewise. * remap.c (add_debug_prefix_map): Likewise. * symbols.c (symbol_find_noref): Likewise. (define_dollar_label): Likewise. (fb_label_instance_inc): Likewise. (symbol_relc_make_value): Likewise.
* Copyright update for binutilsAlan Modra2016-01-011-1/+1
|
* ChangeLog rotatation and copyright year updateAlan Modra2015-01-021-1/+1
|
* Update copyright yearsAlan Modra2014-03-051-3/+1
|
* gas/Roland McGrath2013-01-101-2/+2
| | | | | | | * hash.c (hash_new_sized): Make it global. * hash.h: Declare it. * macro.c (define_macro): Use hash_new_sized instead of hash_new, pass a small size.
* bfd/Alan Modra2011-04-201-28/+10
| | | | | | | | | | | | | | | * hash.c (bfd_default_hash_table_size): Make it an unsigned long. (bfd_hash_table_init_n): Overflow checking. (bfd_hash_set_default_size): Return current size. Take unsigned long arg. Add 65537 to hash_size primes. * bfd-in.h (bfd_hash_set_default_size): Update prototype. * bfd-in2.h: Regenerate. gas/ * hash.c (set_gas_hash_table_size): Use bfd_hash_set_default_size. (hash_new_sized): New function, split out from.. (hash_new): ..here. ld/ * ld.h (ld_config_type <hash_table_size>): Make it an unsigned long.
* Add -Wshadow to the gcc command line options used when compiling the binutils.Nick Clifton2009-12-111-13/+13
| | | | Fix up all warnings generated by the addition of this switch.
* * po/bfd.pot: Updated by the Translation project.Nick Clifton2009-09-111-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * po/binutils.pot: Updated by the Translation project. * po/gold.pot: Updated by the Translation project. * po/gold.pot: Updated by the Translation project. * po/gprof.pot: Updated by the Translation project. * po/sv.po: Updated Swedish translation. * po/ld.pot: Updated by the Translation project. * po/fi.po: Updated Finnish translation. * po/ld.pot: Updated by the Translation project. * po/fi.po: Updated Finnish translation. Updated sources to compile cleanly with -Wc++-compat: * basic_blocks.c: Add casts. * cg_dfn.c: Add cast. * corefile.c: Add casts. * gmon_io.c: Add casts. * hist.c: Add cast. * source.c: Add cast. * sym_ids.c (struct match): Moved to top level. Updated soruces in ld/* to compile cleanly with -Wc++-compat: * ld.h (enum endian_enum,enum symbolic_enum,enum dynamic_list_enum): Move to top level. * ldcref.c: Add casts. * ldctor.c: Add casts. * ldexp.c * ldexp.h (enum node_tree_enum,enum phase_enum): Move to top level. * ldlang.c: Add casts. (lang_insert_orphan): Use enum name instead of integer. * ldlang.h (enum statement_enum): Move to top level. * ldmain.c: Add casts. * ldwrite.c: Add casts. * lexsup.c: Add casts. (enum control_enum): Move to top level. * mri.c: Add casts. (mri_draw_tree): Use enum name instead of integer. Updated sources to compile cleanly with -Wc++-compat: * basic_blocks.c: Add casts. * cg_dfn.c: Add cast. * corefile.c: Add casts. * gmon_io.c: Add casts. * hist.c: Add cast. * source.c: Add cast. * sym_ids.c (struct match): Moved to top level. * as.c (main): Call dwarf2_init. * config/obj-elf.c (struct group_list): New field. (build_group_lists): Use hash lookup. (free_section_idx): New function. (elf_frob_file): Adjust. * dwarf2dbg.c (all_segs_hash, last_seg_ptr): New variables. (get_line_subseg): Adjust. (dwarf2_init): New function. * dwarf2dbg.h (dwarf2_init): New declaration.
* Remove unnecessary casts on obstack_alloc invocations.Alan Modra2008-10-211-2/+2
|
* Banish PARAMS and PTR. Convert to ISO C.Alan Modra2008-08-121-4/+4
| | | | Delete unnecessary forward declarations.
* PR 6575Alan Modra2008-08-111-11/+10
| | | | | | | | | | | | * hash.c: Expand PTR to void *. (hash_delete): Add "freeme" parameter. Call obstack_free. * hash.h: Expand PTR to void *. (hash_delete): Update prototype. * macro.c (macro_expand_body): hash_delete LOCALs from formal_hash. * config/tc-tic54x.c (tic54x_remove_local_label): Update hash_delete call. (subsym_substitute): Likewise. * doc/internals.texi (hash_delete): Update.
* Switch to GPLv3Nick Clifton2007-07-031-2/+2
|
* include/elf:Zack Weinberg2005-05-181-20/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * arm.h: Import complete list of official relocation names and numbers from AAELF. Define FAKE_RELOCs for old names. Remove a few old names no longer used anywhere. bfd: * elf32-arm.c: Wherever possible, use official reloc names from AAELF. (elf32_arm_howto_table, elf32_arm_tls_gd32_howto) (elf32_arm_tls_ldo32_howto, elf32_arm_tls_ldm32_howto) (elf32_arm_tls_le32_howto, elf32_arm_tls_ie32_howto) (elf32_arm_vtinherit_howto, elf32_arm_vtentry_howto) (elf32_arm_pc11_howto, elf32_arm_thm_pc9_howto, elf32_arm_got_prel) (elf32_arm_r_howto): Replace with elf32_arm_howto_table_1, elf32_arm_howto_table_2, and elf32_arm_howto_table_3. Add many new relocations from AAELF. (elf32_arm_howto_from_type): Update to match. (elf32_arm_reloc_map): Add entries for R_ARM_THM_JUMP24, R_ARM_THM_JUMP11, R_ARM_THM_JUMP19, R_ARM_THM_JUMP8, R_ARM_THM_JUMP6, R_ARM_GNU_VTINHERIT, and R_ARM_GNU_VTENTRY. (elf32_arm_reloc_type_lookup): Use elf32_arm_howto_from_type. (elf32_arm_final_link_relocate): Add support for R_ARM_THM_JUMP24, R_ARM_THM_JUMP19, R_ARM_THM_JUMP6. Remove case entries redundant with default. * reloc.c: Reorganize ARM relocations. Add Thumb assembler-internal relocations BFD_RELOC_ARM_T32_OFFSET_U8, BFD_RELOC_ARM_T32_OFFSET_IMM, BFD_RELOC_ARM_T32_IMMEDIATE. Add visible relocations BFD_RELOC_THUMB_PCREL_BRANCH7, BFD_RELOC_THUMB_BRANCH20, BFD_RELOC_THUMB_BRANCH25. Delete unused relocations BFD_RELOC_ARM_GOT12, BFD_RELOC_ARM_COPY. * bfd-in2.h, libbfd.h: Regenerate. opcodes: * arm-dis.c (thumb_opcodes): Add disassembly for V6T2 16-bit instructions. Adjust disassembly of some opcodes to match unified syntax. (thumb32_opcodes): New table. (print_insn_thumb): Rename print_insn_thumb16; don't handle two-halfword branches here. (print_insn_thumb32): New function. (print_insn): Choose among print_insn_arm, print_insn_thumb16, and print_insn_thumb32. Be consistent about order of halfwords when printing 32-bit instructions. gas: * hash.c (hash_lookup): Add len parameter. All callers changed. (hash_find_n): New interface. * hash.h: Prototype hash_find_n. * sb.c: Include as.h. (scrub_from_sb, sb_to_scrub, scrub_position): New statics. (sb_scrub_and_add_sb): New interface. * sb.h: Prototype sb_scrub_and_add_sb. * input-scrub.c (input_scrub_include_sb): Use sb_scrub_and_add_sb. * config/tc-arm.h (TC_FORCE_RELOCATION_LOCAL): Remove reference to BFD_RELOC_ARM_GOT12 which is never generated. * config/tc-arm.c: Rewrite, adding Thumb-2 support. gas/testsuite: * gas/arm/arm.exp: Convert all existing "gas_test" tests to "run_dump_test" tests. Run more tests unconditionally. Run new tests. * gas/arm/arch4t.s, gas/arm/arch6zk.s, gas/arm/arm3.s, gas/arm/arm6.s * gas/arm/arm7dm.s, gas/arm/bignum1.s, gas/arm/float.s * gas/arm/immed.s, gas/arm/iwmmxt.s, gas/arm/offset.s, gas/arm/thumb.s: Adjust to work as a dump test. * gas/arm/arch4t.d, gas/arm/arch6zk.d, gas/arm/arm3.d, gas/arm/arm6.d * gas/arm/arm7dm.d, gas/arm/bignum1.d, gas/arm/float.d * gas/arm/immed.d, gas/arm/iwmmxt.d, gas/arm/offset.d, gas/arm/thumb.d: New files. * gas/arm/armv1-bad.l, gas/arm/armv1-bad.s: Remove tests for diagnostics that don't happen in the first pass anymore. * gas/arm/iwmmxt-bad.l, gas/arm/r15-bad.l, gas/arm/req.l * gas/arm/vfp-bad.l: Update expected diagnostics. * gas/arm/pic.d: Update expected reloc name. * gas/arm/thumbv6.d: CPY no longer appears in disassembly. * gas/arm/r15-bad.s: Avoid two-argument mul. * gas/arm/req.s: Adjust comments. * gas/arm/maverick.d, gas/arm/maverick.s: Avoid inappropriate use of PC. * gas/arm/macro-1.d, gas/arm/macro1.s * gas/arm/t16-bad.l, gas/arm/t16-bad.s * gas/arm/tcompat.d, gas/arm/tcompat.s * gas/arm/tcompat2.d, gas/arm/tcompat2.s * gas/arm/thumb32.d, gas/arm/thumb32.s New test pair. ld/testsuite: * ld-arm/mixed-app.d: Adjust expected disassembly a little.
* Update the address and phone number of the FSFNick Clifton2005-05-051-2/+2
|
* 2005-04-29 H.J. Lu <hongjiu.lu@intel.com>H.J. Lu2005-04-291-0/+54
| | | | | * hash.c: Undo the last change. * hash.h: Likewise.
* * Makefile.am (GAS_CFILES): Remove bignum-copy.c.Ben Elliston2005-04-291-54/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (GENERIC_OBJS): Likewise, remove bignum-copy.o. (bignum-copy.o): Remove. * Makefile.in: Regenerate. * makefile.vms (OBJS): Remove bignum-copy.obj. * symbols.h (local_symbol_make): Remove declaration. (verify_symbol_chain_2): Likewise. * symbols.c (local_symbol_make): Make static. (max_indent_level): Likewise. (verify_symbol_chain_2): Remove. * macro.c (macro_hash): Make static. * messages.c (fprint_value): Remove. * read.h (get_absolute_expr): Remove. (emit_leb128_expr): Likewise. (do_s_func): Likewise. * read.c (do_s_func): Make static. (emit_leb128_expr): Likewise. (get_absolute_expr): Likewise. * as.h (as_howmuch): Remove declaration. (fprint_value): Likewise. * as.c (myname): Make static. * input-scrub.c (as_howmuch): Remove. (as_1_char): Likewise. * input-file.h (input_file_is_open): Remove. * input-file.c (input_file_is_open): Likewise. * expr.h (expr_build_unary): Remove declaration. (expr_build_binary): Likewise. * expr.c (expr_build_unary): Remove. (expr_build_binary): Likewise. * hash.h (hash_replace): Remove declaration. (hash_delete): Likewise. * hash.c (hash_replace): Remove. (hash_delete): Likewise. * bignum-copy.c (bignum_copy): Move from here .. * config/tc-vax.c (bignum_copy): .. to here. * bignum.h (LOG_TO_BASE_2_OF_10): Remove. (bignum_copy): Remove extern declaration. * sb.h (string_count): Remove extern declaration. (sb_build, sb_add_buffer, sb_print, sb_print_at): Likewise. (sb_name): Likewise. * sb.c (dsize): Replace preprocessor macro with static int. (string_count): Make static. (sb_build, sb_add_buffer, sb_print, sb_print_at): Likewise. (sb_name): Likewise. * config/obj-coff.c (dim_index): Make static. * config/tc-i386.c (GOT_symbol): Likewise. (output_invalid_buf): Likewise. * doc/internals.texi (Warning and error messages): Remove the prototype for fprint_value.
* * as.c (main): Move parse_args before symbol_begin and frag_init so that theNick Clifton2005-04-141-6/+6
| | | | | | hash table size can be set before it is used. * hash.c: Use an unsigned long type for the size of the hash tables. * hash.h (set_gas_hash_table_size): Update the prototype.
* * hash.c (DEFAULT_SIZE): Delete. Replace with:Nick Clifton2005-04-121-8/+38
| | | | | | | | | | | | | | | | (gas_hash_table_size): New static variable. (set_gas_hash_table_size): New function: Records a requested size for the hash tables. (get_gas_hash_table_size): New function: Return a prime number near the requested size of the hash table. (hash_new): Use get_gas_hash_table_size. * hash.h: Add a prototype for set_gas_hash_table_size. * as.c (show_usage): Add description of new switches: --hash-size and --reduce-memory-overheads. (option_values): Add OPTION_HASH_TABLE_SIZE and OPTION_REDUCE_MEMORY_OVERHEADS. (std_longpopts): Add entries for the new options. (parse_args): Handle the new options. * Makefile.am: Add a dependency of as.c on hash.h. * Makefile.in: Regenerate. * doc/as.texinfo: Document the new switches. * NEWS: Mention the new switches.
* update copyright datesAlan Modra2005-03-031-1/+1
|
* * hash.c: Convert to ISO-C.Kazu Hirata2003-11-241-37/+18
| | | | | | | | | * hash.h: Likewise. * input-file.c: Likewise. * input-file.h: Likewise. * input-scrub.c: Likewise. * itbl-ops.c: Likewise. * itbl-ops.h: Likewise.
* * README-vms: Fix comment typos.Kazu Hirata2003-11-231-1/+1
| | | | | | | | | * as.h: Likewise. * dwarf2dbg.c: Likewise. * ecoff.c: Likewise. * hash.c: Likewise. * listing.c: Likewise. * write.c: Likewise.
* * ChangeLog: Fix typos.Kazu Hirata2003-10-271-1/+1
| | | | | | | | | | | | | | | | | | | | | * ChangeLog-9295: Likewise. * as.c: Fix comment typos. * as.h: Likewise. * atof-generic.c: Likewise. * bit_fix.h: Likewise. * frags.h: Likewise. * hash.c: Likewise. * input-file.c: Likewise. * input-scrub.c: Likewise. * itbl-ops.c: Likewise. * itbl-parse.y: Likewise. * listing.c: Likewise. * macro.h: Likewise. * read.c: Likewise. * sb.c: Likewise. * sb.h: Likewise. * symbols.c: Likewise. * symbols.h: Likewise.
* * ecoff.c: (get_tag): Replace strcpy with xstrdup.Alan Modra2002-06-261-12/+2
| | | | | | | (ecoff_directive_def): Likewise. (ecoff_directive_tag): Likewise. * listing.c (file_info): Likewise. * hash.c (what): Likewise.
* Locale changes from Bruno Haible <haible@clisp.cons.org>.H.J. Lu2001-09-191-3/+3
|
* Fix copyright noticesNick Clifton2001-03-081-1/+2
|
* 2000-10-30 Kazu Hirata <kazu@hxi.com>Kazu Hirata2000-10-301-4/+2
| | | | | | | | * expr.c: Fix formatting. * flonum-copy.c: Likewise. * flonum.h: Likewise. * gasp.c: Likewise. * hash.c: Likewise.
* 2000-08-09 Kazu Hirata <kazu@hxi.com>Kazu Hirata2000-08-081-23/+31
| | | | * hash.c: Fix formatting.
* More warning fixes, and a tweak in tc-hppa.c to check constantAlan Modra2000-07-101-3/+3
| | | | branch offsets a little more thoroughly.
* * Many files: Changes to avoid gcc warnings: Add ATTRIBUTE_UNUSEDIan Lance Taylor1999-07-111-3/+3
| | | | | | | as appropriate. Fill in structure initializations. Add variable initializations. Add casts. * dwarf2dbg.c (print_stats): Change i to size_t. * listing.c (listing_listing): Change list_line to unsigned int.
* * hash.h: Neaten. Declare hash_traverse.Ian Lance Taylor1999-06-021-765/+338
| | | | * hash.c: Complete rewrite based on BFD hashing code.
* 19990502 sourceware importbinu_ss_19990502Richard Henderson1999-05-031-0/+1028