aboutsummaryrefslogtreecommitdiff
path: root/gcc/tlink.c
AgeCommit message (Collapse)AuthorFilesLines
1999-09-17tlink.c (scan_linker_output): Look for keywords before accepting a mangled ↵Jason Merrill1-2/+6
name in quotes. * tlink.c (scan_linker_output): Look for keywords before accepting a mangled name in quotes. From-SVN: r29479
1999-09-03Makefile.in (tlink.o): Don't depend on toplev.h.Kaveh R. Ghazi1-28/+19
* Makefile.in (tlink.o): Don't depend on toplev.h. * collect2.c (c_file, o_file, export_file, import_file, ldout, output_file, nm_file_name, ldd_file_name, strip_file_name, c_file_name, prefix_list, libexts, is_ctor_dtor, find_a_file, add_prefix, prefix_from_env, prefix_from_string, do_wait, fork_execute, maybe_unlink, add_to_list, extract_init_priority, write_list, dump_list, dump_prefix_list, write_list_with_asm, write_c_file, write_c_file_stat, write_c_file_glob, scan_prog_file, scan_libraries, is_in_list, resolve_lib_name, use_import_list, ignore_library, extract_string, notice, dump_file, target_machine, collect_wait, collect_execute, libname, locatelib, aix_std_libs, read_file, print_load_command): Constify a char*. (fdopen, error, fatal, fatal_perror): Don't prototype. (my_strerror): Remove. All callers use xstrerror instead. (xcalloc, xmalloc, xrealloc, xstrdup, putenv): Remove definitions. (main): Add prototype. Constify lots of char* ptrs. Change calls to xcalloc/strcpy/strcat/... to one call to concat. (main, scan_prog_file, scan_libraries): Use an intermediate `const char **' to build an argv array. (mapfile, libselect, libcompare, locatelib): Add prototypes. * collect2.h (collect_execute, collect_wait, dump_file, file_exists): Constify a char*. (ldout, c_file_name, temporary_obstack, permanent_obstack, temporary_firstobj, vflag, debug): Add extern declarations. (fancy_abort, error, notice, fatal, fatal_perror): Add prototypes. * tlink.c: Don't include toplev.h. (vflag, debug, ldout, c_file_name, temporary_obstack, permanent_obstack, temporary_firstobj): Don't declare. (tlink_execute, frob_extension, symbol_hash_lookup, file_hash_lookup, demangled_hash_lookup, tlink_init, freadsym, recompile_files, read_repo_files, demangle_new_symbols, scan_linker_output): Constify a char*. (symbol_hash_newfunc, file_hash_newfunc, demangled_hash_newfunc, do_tlink): Mark parameters with ATTRIBUTE_UNUSED. From-SVN: r29087
1999-09-03tlink.c (scan_linker_output): Skip the initial underscore in a mangled name ↵Jason Merrill1-1/+5
if appropriate. * tlink.c (scan_linker_output): Skip the initial underscore in a mangled name if appropriate. From-SVN: r29083
1999-08-04tlink.c (symbol_hash_lookup): Do not prefix functions used as function ↵Philippe De Muyter1-8/+8
parameters with `&'. * tlink.c (symbol_hash_lookup): Do not prefix functions used as function parameters with `&'. (file_hash_lookup, demangled_hash_lookup, tlink_init): Ditto. From-SVN: r28485
1999-03-25tlink.c (symbol_hash_newfunc): Remove redundant call to hash_newfunc.Art Haas1-6/+0
* tlink.c (symbol_hash_newfunc): Remove redundant call to hash_newfunc. (file_hash_newfunc, demangled_hash_newfunc): Likewise. From-SVN: r25974
1999-03-20Warning fixes:Kaveh R. Ghazi1-11/+41
* c-lex.c (yylex): Remove unused variable `bytes'. * flow.c (print_rtl_with_bb): Cast the return value of alloca. * function.c (assign_parms): Wrap variable `varargs_setup' in macro SETUP_INCOMING_VARARGS. (thread_prologue_and_epilogue_insns): Mark parameter `f' with ATTRIBUTE_UNUSED. * local-alloc.c (no_equiv): Likewise for parameter `store'. * sched.c (schedule_insns): Remove unused variables `insn' and `next'. * tlink.c (symbol_hash_newfunc, symbol_hash_lookup, file_hash_newfunc, file_hash_lookup, demangled_hash_newfunc, demangled_hash_lookup, symbol_push, symbol_pop, file_push, file_pop, tlink_init, tlink_execute, frob_extension, obstack_fgets, tfgets, pfgets, freadsym, read_repo_file, maybe_tweak, recompile_files, read_repo_files, demangle_new_symbols, scan_linker_output): Add static prototype. (symbol_hash_newfunc, file_hash_newfunc, demangled_hash_newfunc): Make the third argument a `hash_table_key'. * toplev.c (debug_start_source_file): Mark parameter `filename' with ATTRIBUTE_UNUSED. From-SVN: r25871
1999-01-26add commentsJason Merrill1-1/+58
From-SVN: r24873
1999-01-11Update FSF address in copyright header.Jeff Law1-1/+2
From-SVN: r24614
1998-12-10collect2.h: New header file for prototypes.Kaveh R. Ghazi1-0/+1
* collect2.h: New header file for prototypes. * Makefile.in (collect2.o, tlink.o): Depend on collect2.h. * collect2.c: Include collect2.h. * tlink.c: Likewise. From-SVN: r24231
1998-11-27system.h: Include libiberty.h.Kaveh R. Ghazi1-2/+0
* system.h: Include libiberty.h. * c-aux-info.c: Remove prototypes for concat/concat3. Change function `concat' from fixed parameters to variable parameters, as is done in libiberty. All callers of concat/concat3 changed to use the new `concat' with variable args. * cccp.c: Remove things made redundant by libiberty.h and/or conform to libiberty standards. * cexp.y: Likewise. * collect2.c: Likewise. * config/1750a/1750a.h: Likewise. * cppalloc.c: Likewise. * cppexp.c: Likewise. * cppfiles.c: Likewise. * cpphash.c: Likewise. * cpplib.c: Likewise. * dyn-string.c: Likewise. * fix-header.c: Likewise. * gcc.c: Likewise. * gcov.c: Likewise. * genattr.c: Likewise. * genattrtab.c: Likewise. * gencheck.c: Likewise. * gencodes.c: Likewise. * genconfig.c: Likewise. * genemit.c: Likewise. * genextract.c: Likewise. * genflags.c: Likewise. * gengenrtl.c: Likewise. * genopinit.c: Likewise. * genoutput.c: Likewise. * genpeep.c: Likewise. * genrecog.c: Likewise. * getpwd.c: Likewise. * halfpic.c: Likewise. * hash.c: Likewise. * mips-tdump.c: Likewise. Wrap malloc/realloc/calloc prototypes in NEED_DECLARATION_* macros. * mips-tfile.c: Remove things made redundant by libiberty.h and/or conform to libiberty standards. (fatal): Fix const-ification of variable `format' in !ANSI_PROTOTYPES case. * prefix.c: Remove things made redundant by libiberty.h and/or conform to libiberty standards. * print-rtl.c: Rename variable `spaces' to `xspaces' to avoid conflicting with function `spaces' from libiberty. * profile.c: Remove things made redundant by libiberty.h and/or conform to libiberty standards. * protoize.c: Likewise. * rtl.h: Likewise. * scan.h: Likewise. * tlink.c: Likewise. * toplev.c: Likewise. * toplev.h: Likewise. * tree.h: Likewise. From-SVN: r23931
1998-11-17hash.h (hash_table_key): New type.Mark Mitchell1-17/+28
* hash.h (hash_table_key): New type. (hash_entry): Change `string' field to generic `key'. (hash_table): Add `comp' and `hash' functions. (hash_table_init): Take them as input. (hash_table_init_n): Likewise. (hash_lookup): Modify for generic keys. (hash_newfunc): Likewise. (hash_traverse): Likewise. (string_hash): New function. (string_compare): Likewise. (string_copy): Likewise. * hash.c (hash_table_init_n): Modify for generic keys. (hash_table_init): Likewise. (hash_lookup): Likewise. (hash_newfunc): Likewise. (hash_traverse): Likewise. (string_hash): Split out from hash_lookup. (string_compare): New function. (string_copy): Split out from hash_lookup. * tlink.c (symbol_hash_newfunc): Modify for new interfaces to hash tables. (symbol_hash_lookup): Likewise. (file_hash_newfunc): Likewise. (file_hash_lookup): Likewise. (demangled_hash_newfunc): Likewise. (demangled_hash_lookup): Likewise. (tlink_int): Likewise. (read_repo_file): Likewise. (recompile_files): Likewise. (demangle_new_symbols): Likewise. (scan_linker_output): Likewise. From-SVN: r23683
1998-10-17Warning fixes:Kaveh R. Ghazi1-2/+2
* Makefile.in (flow.o): Depend on recog.h. * cpplib.h (directive_table): Add missing initializiers. (finclude): Change type of variable `bsize' to size_t. * cse.c (rtx_cost): Mark parameter `outer_code' with ATTRIBUTE_UNUSED. * dwarfout.h (dwarfout_label): Wrap prototype in macro RTX_CODE. * fix-header.c (lookup_std_proto): Cast the result of `strlen' to `int' when comparing against one. (cpp_file_line_for_message): Mark parameter `pfile' with ATTRIBUTE_UNUSED. (cpp_fatal): Mark parameter `pfile' with ATTRIBUTE_UNUSED. * flow.c: Include recog.h. (sbitmap_copy): Cast arguments 1 & 2 of `bcopy' to (PTR). * function.c (thread_prologue_and_epilogue_insns): Mark parameter `f' with ATTRIBUTE_UNUSED. (reposition_prologue_and_epilogue_notes): Likewise. * genopinit.c (gen_insn): Cast argument of ctype functions to `unsigned char'. * haifa-sched.c: Include recog.h. (blockage_range): Cast result of UNIT_BLOCKED macro to (int) when comparing against one. * libgcc2.a (__throw): Revert ATTRIBUTE_UNUSED change for now. * mips-tfile.c (parse_end): Cast the argument of ctype function to `unsigned char'. (parse_ent): Likewise. (parse_input): Likewise. * optabs.c (init_libfuncs): Likewise. * protoize.c (find_rightmost_formals_list): Likewise. * recog.h (const_double_operand): Fix typo in prototype. * tlink.c (scan_linker_output): Cast the argument of ctype function to `unsigned char'. * toplev.c (check_lang_option): Cast the result of `strlen' to `int' when comparing against one. From-SVN: r23155
1998-10-04tlink.c (scan_linker_output): Recognize errors from irix 6.2 linker.Jason Merrill1-13/+16
* tlink.c (scan_linker_output): Recognize errors from irix 6.2 linker. Recognize mangled names in quotes. Co-Authored-By: Scott Snyder <snyder@fnal.gov> From-SVN: r22823
1998-05-06c-common.c: Convert to using ctype macros defined in system.h.Kaveh R. Ghazi1-2/+2
* c-common.c: Convert to using ctype macros defined in system.h. * c-lex.c: Likewise. * cccp.c: Likewise. * collect2.c: Likewise. * rs6000.c: Likewise. * cpplib.c: Likewise. * fix-header.c: Likewise. * gcc.c: Likewise. * gen-protos.c: Likewise. * pexecute.c: Likewise. * protoize.c: Likewise. * rtl.c: Likewise. * scan.c: Likewise. * stmt.c: Likewise. * tlink.c: Likewise. * toplev.c: Likewise. From-SVN: r19579
1998-05-06toplev.h: New file.Robert Lipe1-0/+1
Wed May 6 06:35:38 1998 Robert Lipe <robertl@dgii.com> * toplev.h: New file. Protypes for functions in toplev.c. * tree.h, rtl.h: Deleted protos for functions in toplev.c. * c-common.c, c-convert.c, c-decl.c, c-iterate.c, c-lex.c, c-parse.in, c-parse.y, c-pragma.c, c-typeck.c, calls.c, convert.c, dwarf2out.c, except.c, expr.c, final.c, fold-const.c, function.c, hash.c, profile.c, real.c, reg-stack.c, regclass.c, reload.c, reload1.c, stmt.c, stor-layout.c, tlink.c, tree.c, varasm.c: include it. From-SVN: r19564
1998-03-20Major cutover to using system.h:Kaveh R. Ghazi1-28/+5
* Makefile.in (alias.o, bitmap.o, c-aux-info.o, c-common.o, c-decl.o, c-iterate.o, c-lang.o, c-lex.o, c-pragma.o, c-typeck.o, caller-save.o, calls.o, collect2.o, combine.o, cse.o, dbxout.o, dwarf2out.o, dwarfout.o, emit-rtl.o, except.o, explow.o, expmed.o, expr.o, final.o, flow.o, function.o, getpwd.o, global.o, integrate.o, jump.o, local-alloc.o, loop.o, optabs.o, pexecute.o, prefix.o, print-rtl.o, print-tree.o, profile.o, real.o, recog.o, reg-stack.o, regclass.o, regmove.o, reload.o, reload1.o, reorg.o, rtl.o, rtlanal.o, sdbout.o, stmt.o, stor-layout.o, stupid.o, tlink.o, toplev.o, tree.o, unroll.o, varasm.o, xcoffout.o): Depend on system.h. * alias.c, bitmap.c, c-aux-info.c, c-common.c, c-decl.c, c-iterate.c, c-lang.c, c-lex.c, c-pragma.c, c-typeck.c, caller-save.c, calls.c, collect2.c, combine.c, cse.c, dbxout.c, dwarf2out.c, dwarfout.c, emit-rtl.c, except.c, explow.c, expmed.c, expr.c, final.c, flow.c, function.c, gcc.c, getpwd.c, global.c, integrate.c, jump.c, local-alloc.c, loop.c, optabs.c, pexecute.c, prefix.c, print-rtl.c, print-tree.c, profile.c, real.c, recog.c, reg-stack.c, regclass.c, regmove.c, reload.c, reload1.c, reorg.c, rtl.c, rtlanal.c, sched.c, sdbout.c, stmt.c, stor-layout.c, stupid.c, tlink.c, toplev.c, tree.c, unroll.c, varasm.c, xcoffout.c: Include system.h. Organize include ordering so that stdarg/varargs comes before other system headers. Remove spurious casts of functions assured of a prototype in system.h. From-SVN: r18726
1998-02-27genattr.c: Wrap prototype of `free' in NEED_DECLARATION_FREE.Kaveh Ghazi1-0/+4
* genattr.c: Wrap prototype of `free' in NEED_DECLARATION_FREE. * genattrtab.c: Likewise. * genconfig.c: Likewise. * genemit.c: Likewise. * genextract.c: Likewise. * genflags.c: Likewise. * genopinit.c: Likewise. * genoutput.c: Likewise. * genpeep.c: Likewise. * genrecog.c: Likewise. * tlink.c: Likewise. Also wrap `getenv' in NEED_DECLARATION_GETENV. From-SVN: r18284
1998-02-13Rats. Forgot to change copyrights on the first commit.Robert Lipe1-1/+1
From-SVN: r17902
1998-02-13c-lang.c (finish_file): Bracket declaration of static_ctors, static_dtors.Robert Lipe1-0/+16
* c-lang.c (finish_file): Bracket declaration of static_ctors, static_dtors. * calls.c (expand_call): Bracket declaration of 'rtx_before_call', 'old_stack_arg_under_construction' (emit_library_call): Bracket declaration of 'upper_bound', 'lower_bound', 'i', 'reg_parm_stack_space' (emit_library_call_value): Likewise. (store_one_arg): * collect2.c: include <unistd.h> when appropriate. Bracket declaration of 'exportf' and 'full_real_ld_suffix'. * emit-rtl.c (prev_cc0_setter): Remove unused variable 'link'. * explow.c (plus_constant_for_output_wide): Remove unused variable 'code'. (memory_address): Remove unused variable 'orig_x'. * genattrtab.c (make_canonical): Remove unreferenced label 'cond:'. (write_const_num_delay_slots): Remove unused variable 'i'. * genopinit.c (main): Remove unused variables 'dummy', 'insn_ptr'. (gen_insn): Remove unused variable 'obstack_ptr'. * libgcc2.c (__bb_exit_func): Remove unused variables 'ret', 'j', 'tmp', 'i'. (__bb_exit_trace_func): Remove unused variable 'e'. * optabs.c (expand_binop): remove unused variables 'lhs', 'rhs', 'funexp'. (expand_unop): Remove unused variable 'funexp'. (expand_complex_abs): Remove unused variable 'funexp'. (init_optabs): Bracket declaration of 'j'. (init_complex_libfuncs): Deleted. Dead static function. * profile.c (branch_prob): Remove unused variables 'insn', 'dest'. * reg-stack.c: Fix typo in proto for 'get_asm_operand_lengths' (reg_to_stack): 'initialized', 'before_function_beg' explictly type as ints instead of defaulting. (emit_swap_insn): Remove unused variable 'i2'. (compare_for_stack_reg): Remove unused variable 'src_note'. * rtlanal.c (computed_jump_p): Remove unused variable 'computed_jump'. * sched.c (actual_hazard): Bracket declaration of 'this_cost'. * stmt.c (add_case_node): Add parens for assignment used as truth. (all_cases_count): Remove unused variable 'count_high'. (mark_seen_cases): Remove unused variable 'i'. (check_for_full_enumeration_handling): Remove unused variable 't'. Bracket declaration of 'all_values', 'l'. * tlink.c: Include <stdlib.h>, <unistd.h>, <string.h>/<strings.h>. * varasm.c (assemble_string): Remove unused variable 'i'. (immed_double_const): Remove unused variable 'in_current_obstack'. (immed_real_const_1): Likewise. (output_constant_pool): Remove unreferenced label 'done'. (output_constant): Remove unused variable 'x'. * i386/i386.h (ENCODE_SECTION_INFO): TREE_PUBLIC is an int, not a string. * i386/sco5.h (ASM_OUTPUT_ASCII): Add parens for assignment used as truth. From-SVN: r17901
1998-01-27* tlink.c (scan_linker_output): Call fclose() for opened files.Kamil Iskra1-1/+5
From-SVN: r17504
1998-01-10Remove bogus CYGNUS LOCAL markers.Jeff Law1-1/+0
From-SVN: r17315
1997-09-04Fix minor bugs found by riscos build attempt.Jim Wilson1-0/+1
* tlink.c: Include ctype.h. * ginclude/va-mips.h: Add _VA_MIPS_H_ENUM ifdef/define/endif. From-SVN: r15080
1997-08-11* Integrate tlink patch from jason@cygnus.comJeffrey A Law1-0/+631
* gcc.c (SWITCH_TAKES_ARG): Add 'V', 'B' and 'b'. (process_command): Increment n_switches for them. Don't discard their args. Validate them. (main): Escape " marks when creating COLLECT_GCC_OPTIONS. From Rohan Lenard. (process_command): Set include_prefixes from COMPILER_PATH. (main): Set COLLECT_GCC_OPTIONS sooner. * confiugre.in: Link ../ld/ld.new to collect-ld rather than real-ld. * tlink.c, hash.c, hash.h: New files. * Makefile.in (USE_COLLECT2): Always use collect2. (collect2): Depend on and link in hash.o and tlink.o. (tlink.o, hash.o): Add dependencies. tlink patches from Jason. From-SVN: r14769