Age | Commit message (Collapse) | Author | Files | Lines |
|
PR c++/49756
* libiberty.h (stack_limit_increase): New prototype.
* stack-limit.c: New file.
* Makefile.in: Regenerate deps.
(CFILES): Add stack-limit.c.
(REQUIRED_OFILES): Add ./stack-limit.$(objext).
* configure.ac (checkfuncs): Add getrlimit and setrlimit.
(AC_CHECK_FUNCS): Likewise.
* configure: Regenerated.
* config.in: Regenerated.
* gcc.c (main): Call stack_limit_increase (64MB).
* toplev.c (toplev_main): Likewise.
From-SVN: r176617
|
|
* gcc.c (%[Spec]): Don't document.
(struct spec_list): Update comment.
(do_spec_1): Don't handle %[Spec].
* doc/invoke.texi (%[@var{name}]): Remove documentation of spec.
From-SVN: r175970
|
|
gcc:
PR libmudflap/49550
* gcc.c (MFWRAP_SPEC): Also wrap mmap64.
libmudflap:
PR libmudflap/49550
* mf-runtime.c (__wrap_main) [__sun__ && __svr4__]: Don't register
stdin, stdout, stderr.
Register __ctype, __ctype_mask.
* configure.ac: Check for mmap64.
Check for rawmemchr, stpcpy, mempcpy.
* configure: Regenerate.
* config.h.in: Regenerate.
* mf-hooks1.c [HAVE_MMAP64] (__mf_0fn_mmap64): New function.
(mmap64): New wrapper function.
* mf-impl.h (__mf_dynamic_index) [HAVE_MMAP64]: Add dyn_mmap64.
* mf-runtime.c (__mf_dynamic) [HAVE_MMAP64]: Handle mmap64.
* mf-hooks2.c [HAVE_GETMNTENT && HAVE_SYS_MNTTAB_H]: Implement
getmntent wrapper.
* mf-hooks3.c (_REENTRANT): Define.
* testsuite/libmudflap.c/heap-scalestress.c (SCALE): Reduce to 10000.
* testsuite/libmudflap.c/pass-stratcliff.c: Include ../config.h.
(MIN): Define.
Use HAVE_RAWMEMCHR, HAVE_STPCPY, HAVE_MEMPCPY as guards.
* testsuite/libmudflap.c/pass47-frag.c: Expect __ctype warning on
*-*-solaris2.*.
From-SVN: r175961
|
|
* common.opt (in_lto_p): New Variable entry.
* flags.h (in_lto_p): Move to common.opt.
* gcc.c: Include params.h.
(set_option_handlers): Also use common_handle_option and
target_handle_option.
(main): Call global_init_params, finish_params and
init_options_struct.
* opts.c (debug_type_names): Move from toplev.c.
(print_filtered_help): Access quiet_flag through opts pointer.
(common_handle_option): Return early in the driver for some
options. Access in_lto_p, dwarf_version and
warn_maybe_uninitialized through opts pointer.
* toplev.c (in_lto_p): Move to common.opt.
(debug_type_names): Move to opts.c.
* Makefile.in (OBJS): Remove opts.o.
(OBJS-libcommon-target): Add opts.o.
(gcc.o): Update dependencies.
From-SVN: r175591
|
|
From-SVN: r174492
|
|
2011-05-11 Satoru Takabayashi <satorux@google.com>
Paul Pluzhnikov <ppluzhnikov@google.com>
* gcc/doc/install.texi (Configuration): Document
--with-linker-hash-style.
* gcc/gcc.c (init_spec): Handle LINKER_HASH_STYLE.
* gcc/config.in: Add LINKER_HASH_STYLE.
* gcc/configure.ac: Add --with-linker-hash-style.
* gcc/configure: Regenerate.
Co-Authored-By: Paul Pluzhnikov <ppluzhnikov@google.com>
From-SVN: r173668
|
|
Change "if (E) free (E);" to "free (E);" everywhere except in the
libgo/, intl/, zlib/ and classpath/ directories.
Also transform equivalent variants like
"if (E != NULL) free (E);" and allow an extra cast on the
argument to free. Otherwise, the tested and freed "E"
expressions must be identical, modulo white space.
From-SVN: r172785
|
|
* opts.h (cl_option): Add comments to fields. Add bit-fields for
various flags.
(CL_SEPARATE_NARGS_SHIFT, CL_SEPARATE_NARGS_MASK,
CL_SEPARATE_ALIAS, CL_NO_DRIVER_ARG, CL_REJECT_DRIVER, CL_SAVE,
CL_DISABLED, CL_REPOR, CL_REJECT_NEGATIVE, CL_MISSING_OK,
CL_UINTEGER, CL_NEGATIVE_ALIAS): Remove.
(CL_JOINED, CL_SEPARATE, CL_UNDOCUMENTED): Update bit positions.
* opt-functions.awk (flag_init, switch_bit_fields): New.
(switch_flags): Don't handle flags moved to bit-fields. Don't
generate CL_MISSING_OK or CL_SAVE.
* optc-gen.awk: Update to generate bit-field output as well as
flags field.
* gcc.c (driver_wrong_lang_callback): Use cl_reject_driver
bit-field instead of CL_REJECT_DRIVER flag.
* opts-common.c (generate_canonical_option,
decode_cmdline_option): Use bit-fields instead of CL_* flags.
* opts.c (maybe_default_option): Use cl_reject_negative bit-field
instead of CL_REJECT_NEGATIVE flag.
* toplev.c (print_switch_values): Use cl_report bit-field instead
of CL_REPORT flag.
From-SVN: r171804
|
|
2011-03-25 Kai Tietz <ktietz@redhat.com>
* c-ada-spec.c (compare_comment): Use filename_cmp
instead of strcmp for filename.
Changelog fortran/
2011-03-25 Kai Tietz <ktietz@redhat.com>
* scanner.c (preprocessor_line): Use filename_cmp
instead of strcmp.
Changelog gcc/
2011-03-25 Kai Tietz <ktietz@redhat.com>
* collect2.c (write_c_file_stat): Handle backslash
as right-hand directory separator.
(resolve_lib_name): Use IS_DIR_SEPARATOR instead of
checking just for slash.
* coverage.c (coverage_init): Use IS_ABSOLUTE_PATH
instead of checking for trailing slash.
* gcc.c (record_temp_file): Use filename_cmp instead
of strcmp.
(do_spec_1): Likewise.
(replace_outfile_spec_function): Likewise.
(is_directory): Use filename_ncmp instead of strncmp.
(print_multilib_info): Likewise.
* gcov.c (find_source): Use filename_cmp instead
instead of strcmp.
(make_gcov_file_name): Fix order of slash/backslash
checks.
* incpath.c (DIRS_EQ): Use filename_cmp instead of strcmp.
(add_standard_paths): Likewise.
* mips-tfile.c (saber_stop): Handle backslash.
* prefix.c (update_path): Use filename_ncmp instead of
strncmp.
* profile.c (output_location): Use filename_cmp instead
of strcmp.
* read-md.c (handle_toplevel_file): Handle backslash.
* tlink.c (frob_extension): Likewise.
* tree-cfg.c (same_line_p): Use filename_cmp instead of
strcmp.
* tree-dump.c (dequeue_and_dump): Handle backslash.
* tree.c (get_file_function_name): Likewise.
* gengtype.c (read_input_list): Likewise.
(get_file_realbasename): Likewise.
(get_output_file_with_visibility): Use filename_cmp
instead of strcmp.
ChangeLog java/
2011-03-25 Kai Tietz <ktietz@redhat.com>
* jcf-parse.c (java_read_sourcefilenames): Use filename_cmp
instead of strcmp.
(set_source_filename): Likewise.
* win32-host.c (jcf_open_exact_case): Likewise.
ChangeLog lto/
2011-03-25 Kai Tietz <ktietz@redhat.com>
* lto.c (lto_resolution_read): Use filename_cmp instead
of strcmp.
(lto_read_section_data): Likewise.
ChangeLog cp/
2011-03-25 Kai Tietz <ktietz@redhat.com>
* lex.c (interface_strcmp): Handle dos-paths.
(handle_pragma_implementation): Use filename_cmp instead of
strcmp.
(in_main_input_context): Likewise.
From-SVN: r171522
|
|
options.
* gcc.c (driver_unknown_option_callback): Only permit and save
unknown -Wno- options.
(driver_wrong_lang_callback): Save options directly instead of via
driver_unknown_option_callback.
From-SVN: r171307
|
|
handles -plugin)
PR lto/46944
* configure.ac (gcc_cv_gld_major_version, gcc_cv_gld_minor):
Handle in-tree gold.
(ld_vers): Extract binutils version for gold.
(gcc_cv_ld_hidden): Handle gold here.
(gcc_cv_lto_plugin): Determine level of linker plugin support.
* configure: Regenerate.
* config.in: Regenerate.
* gcc.c: Only use LTO plugin if HAVE_LTO_PLUGIN > 0, reject
-fuse-linker-plugin otherwise.
(LINK_PLUGIN_SPEC): Define. Extract from LINK_COMMAND_SPEC.
(LINK_COMMAND_SPEC): Use it.
(main): Only look for LTOPLUGINSONAME if HAVE_LTO_PLUGIN > 0.
From-SVN: r171039
|
|
decoded->orig_option_with_args_text.
* opts-common.c (decode_cmdline_option): Print empty string
argument as "" in decoded->orig_option_with_args_text.
* gcc.c (execute): Print empty string argument as ""
in the verbose output.
(do_spec_1): Keep empty string argument.
testsuite/
* gcc.dg/cpp/include7.c: New test.
From-SVN: r170426
|
|
PR driver/47787
* gcc.c (default_compilers): Clear combinable field for "@cpp-output".
From-SVN: r170286
|
|
PR driver/47390
* common.opt (export-dynamic): New Driver option.
* gcc.c (LINK_COMMAND_SPEC): Add comment about %{e*}.
From-SVN: r170253
|
|
PR driver/45731
* gcc.c (asm_options): Correct spec matching --target-help.
From-SVN: r170091
|
|
gcc:
* gcc.c (driver_handle_option): Concatenate the argument to -F with
the switch.
From-SVN: r170068
|
|
PR driver/47678
* gcc.c (main): Do not compile inputs if there were errors in
option handling.
* opts-common.c (read_cmdline_option): Check for wrong language
after other error checks.
testsuite:
* gcc.dg/opts-6.c: New test.
From-SVN: r170056
|
|
gcc:
* configure.ac (gcc_cv_ld_static_option): Define.
(gcc_cv_ld_dynamic_option): Define.
(gcc_cv_ld_static_dynamic): Tru64 UNIX support -noso/-so_archive
instead.
(HAVE_LD_STATIC_DYNAMIC): Update message.
(LD_STATIC_OPTION): Define.
(LD_DYNAMIC_OPTION): Define.
* configure: Regenerate.
* config.in: Regenerate.
* gcc.c (init_spec) [USE_LIBUNWIND_EXCEPTIONS &&
HAVE_LD_STATIC_DYNAMIC]: Use them.
gcc/cp:
* g++spec.c (lang_specific_driver) [HAVE_LD_STATIC_DYNAMIC] Use
LD_STATIC_OPTION, LD_DYNAMIC_OPTION.
gcc/fortran:
* gfortranspec.c (add_arg_libgfortran) [HAVE_LD_STATIC_DYNAMIC] Use
LD_STATIC_OPTION, LD_DYNAMIC_OPTION.
gcc/go:
* gospec.c (lang_specific_driver) [HAVE_LD_STATIC_DYNAMIC] Use
LD_STATIC_OPTION, LD_DYNAMIC_OPTION.
From-SVN: r169435
|
|
PR driver/47244
* gcc.c (PLUGIN_COND): Update to disable plugin unless -flto is used.
(PLUGIN_COND_CLOSE): New macro.
(LINK_COMMAND_SPEC): Update to use PLUGIN_COND_CLOSE.
From-SVN: r168717
|
|
* Makefile.in: Regenerate.
* Makefile.def (gcc host module) and soft dependency on lto-plugin
and configure dependency on lto-plugin configure.
(lto-plugin module): Remove dependency on GCC; add dependency on
liniberty.
* doc/invoke.texi: (-flto, -fuse-linker-plugin): Update defaults
and no longer claim that gold is required for linker plugin.
* configure: Regenerate.
* gcc.c (PLUGIN_COND): New macro.
(LINK_COMMAND_SPEC): Use it.
(main): Default to plugin enabled with HAVE_LTO_PLUGIN is set.
* config.in (HAVE_LTO_PLUGIN): New.
* configure.ac (--with-lto-plugin): New parameter; autodetect
HAVE_LTO_PLUGIN.
From-SVN: r168593
|
|
2011-01-07 H.J. Lu <hongjiu.lu@intel.com>
PR driver/42445
* gcc.c (%>S): New.
(SWITCH_KEEP_FOR_GCC): Likewise.
(set_collect_gcc_options): Check SWITCH_KEEP_FOR_GCC.
(do_spec_1): Handle "%>".
* config/i386/i386.h (CC1_CPU_SPEC): Replace "%<" with "%>".
From-SVN: r168583
|
|
PR driver/47137
* gcc.c (default_compilers[]): Set combinable field to 0
for all assembly languages.
From-SVN: r168459
|
|
gcc/
* gcc.c (process_command): Update copyright notice dates.
* gcov.c (print_version): Likewise.
* gcov-dump.c (print_version): Likewise.
* mips-tfile.c (main): Likewise.
* mips-tdump.c (main): Likewise.
gcc/fortran/
* gfortranspec.c (lang_specific_driver): Update copyright notice
dates.
gcc/java/
* jcf-dump.c (version): Update copyright notice dates.
libmudflap/
* mf-runtime.c (__mf_usage): Update copyright notice dates.
libjava/
* gnu/gcj/convert/Convert.java (version): Update copyright notice
dates.
* gnu/gcj/tools/gcj_dbtool/Main.java (main): Likewise.
libjava/classpath/
* gnu/java/rmi/registry/RegistryImpl.java (version): Update
copyright notice dates.
* tools/gnu/classpath/tools/orbd/Main.java (run): Likewise.
From-SVN: r168432
|
|
2011-01-03 H.J. Lu <hongjiu.lu@intel.com>
PR driver/47137
* gcc.c (main): Revert revision 168407.
From-SVN: r168429
|
|
2011-01-02 H.J. Lu <hongjiu.lu@intel.com>
PR driver/47137
* gcc.c (main): Don't check have_o when settting combine_inputs.
From-SVN: r168407
|
|
* common.opt (N, Q, Qn, Qy, Z, n, r, s, t): New options.
* gcc.c (cc1_options): Add %{Qy:}.
ada:
* gcc-interface/lang.opt (k8): New option.
java:
* lang.opt (static-libgcj): New option.
From-SVN: r167429
|
|
* gcc.c (LINK_COMMAND_SPEC): Don't handle -A, -d or -m.
* config/darwin.h (LINK_COMMAND_SPEC_A): Likewise.
* config/i386/djgpp.h (LINK_COMMAND_SPEC): Likewise.
From-SVN: r167428
|
|
gcc/:
* gcc.c (default_compilers): Add entry for ".go".
* common.opt: Add -static-libgo as a driver option.
* doc/install.texi (Configuration): Mention libgo as an option for
--enable-shared. Mention go as an option for --enable-languages.
* doc/invoke.texi (Overall Options): Mention .go as a file name
suffix. Mention go as a -x option.
* doc/frontends.texi (G++ and GCC): Mention Go as a supported
language.
* doc/sourcebuild.texi (Top Level): Mention libgo.
* doc/standards.texi (Standards): Add section on Go language.
Move references for other languages into their own section.
* doc/contrib.texi (Contributors): Mention that I contributed the
Go frontend.
gcc/testsuite/:
* lib/go.exp: New file.
* lib/go-dg.exp: New file.
* lib/go-torture.exp: New file.
* lib/target-supports.exp (check_compile): Match // Go.
From-SVN: r167407
|
|
* gcc.c (trad_capable_cpp, default_compilers): Don't handle
-ftraditional.
objc:
* lang-specs.h: Don't handle -ftraditional.
From-SVN: r167385
|
|
base name of last argument)
2010-11-30 Richard Guenther <rguenther@suse.de>
PR lto/44986
* gcc.c (main): Use the first input with a compiler as infile
for link spec processing.
From-SVN: r167292
|
|
* system.h: Include "safe-ctype.h" instead of <safe-ctype.h>.
Include <signal.h>, <sys/mman.h>, <sys/resource.h> and
<sys/times.h>.
(O_BINARY, SIGCHLD, MAP_FAILED, MAP_ANONYMOUS, kill):
Conditionally define.
(GET_ENVIRONMENT): Poison.
* configure.ac: Don't test for mincore.
* configure: Regenerate.
* config.in: Regenerate.
* collect2-aix.c: Don't include <sys/mman.h>.
* collect2.c: Don't include <signal.h>.
(SIGCHLD): Don't define.
(prefix_from_env): Use getenv instead of GET_ENVIRONMENT.
* config/alpha/alpha.c: Include "splay-tree.h" instead of
<splay-tree.h>.
* config/arm/arm.c (arm_target_help): Use getenv instead of
GET_ENVIRONMENT.
* config/avr/driver-avr.c: Don't include <stdlib.h>.
* config/frv/frv.c: Don't include <ctype.h>.
* config/host-darwin.c: Don't include <sys/mman.h>.
* config/host-hpux.c: Don't include <sys/mman.h> or <unistd.h>.
(MAP_FAILED): Don't define.
* config/host-linux.c: Don't include <sys/mman.h> or <limits.h>.
* config/host-solaris.c: Don't include <sys/mman.h>.
* config/i386/cygming.h: Don't include <stdio.h>.
* config/i386/driver-i386.c: Don't include <stdlib.h>.
* config/i386/host-cygwin.c: Don't include <sys/mman.h>.
* config/iq2000/iq2000.c: Don't include <signal.h>.
* config/m32c/m32c-pragma.c: Don't include <stdio.h>.
* config/m68hc11/m68hc11.c: Don't include <stdio.h>.
* config/mep/mep-pragma.c: Don't include <stdio.h>.
* config/microblaze/microblaze.c: Don't include <signal.h>.
* config/mips/mips.c: Don't include <signal.h>.
* config/rs6000/host-darwin.c: Don't include <signal.h>.
* cppdefault.c (cpp_relocated): Use getenv instead of
GET_ENVIRONMENT.
* defaults.h (GET_ENVIRONMENT): Don't define.
* et-forest.h: Don't include <ansidecl.h> or <stddef.h>.
* gcc.c: Don't include <signal.h>, <sys/mman.h> or <sys/types.h>.
(SIGCHLD, MAP_FAILED, kill): Don't define.
(process_command): Use getenv instead of GET_ENVIRONMENT.
* genhooks.c: Don't include <string.h>.
* ggc-common.c: Don't include <sys/resource.h>, <sys/mman.h> or
<sys/types.h>.
(MAP_FAILED): Don't define.
* ggc-page.c Don't include <sys/mman.h>.
(MAP_ANONYMOUS, MAP_FAILED): Don't define.
* ggc-zone.c: Don't include <sys/mman.h>.
(MAP_ANONYMOUS, MAP_FAILED): Don't define.
* graph.c: Include "config.h" instead of <config.h>.
* incpath.c (add_env_var_paths): Use getenv instead of
GET_ENVIRONMENT.
* lto-wrapper.c: Don't include <errno.h>, <signal.h> or
"libiberty.h".
(SIGCHLD, kill): Don't define.
* mips-tfile.c: Don't include <signal.h>.
* opts.c: Don't include <signal.h> or <sys/resource.h>.
(print_specific_help): Use getenv instead of GET_ENVIRONMENT.
* passes.c: Don't include <signal.h>, <sys/resource.h> or
<sys/times.h>.
* sparseset.h: Don't include <assert.h>.
* timevar.c: Don't include <sys/times.h> or <sys/resource.h>.
* tlink.c: Don't include "libiberty.h".
* toplev.c: Don't include <signal.h> or <sys/times.h>.
* tree-mudflap.c: Include "demangle.h" instead of <demangle.h>.
* tree-switch-conversion.c: Don't include <signal.h>.
* vmsdbgout.c: Don't include <errno.h> or <string.h>.
c-family:
* c-opts.c (check_deps_environment_vars): Use getenv instead of
GET_ENVIRONMENT.
* c-pch.c (O_BINARY): Don't define here.
* c-pragma.h: Include "cpplib.h" instead of <cpplib.h>.
fortran:
* gfortran.h (alloca): Don't include definitions.
(NULL): Don't define.
java:
* boehm.c: Include "config.h" instead of <config.h>.
* builtins.c: Don't include <stdarg.h>.
* class.c: Don't include "stdio.h".
(O_BINARY): Don't define here.
* jcf-depend.c: Don't include <assert.h>.
(jcf_dependency_set_dep_file, jcf_dependency_init,
jcf_dependency_write): Use gcc_assert.
* jcf-io.c (O_BINARY): Don't define here.
* jcf-path.c: Don't include "tm.h".
(jcf_path_init): Use getenv instead of GET_ENVIRONMENT.
* resource.c: Don't include "stdio.h".
(O_BINARY): Don't define here.
* verify-impl.c: Don't include <stdio.h>.
lto:
* lto-endian.h: Delete.
* lto-object.c: Don't include "libiberty.h".
(O_BINARY): Don't define.
* lto.c: Don't include "libiberty.h" or <sys/mman.h>.
(O_BINARY): Don't define.
From-SVN: r167241
|
|
PR driver/42690
* gcc.c (LINK_COMMAND_SPEC): Remove hard-coded pass-through plugin
options, replace by call of pass-through-libs spec function to process
link_gcc_c_sequence spec.
(lto_libgcc_spec): Delete variable.
(static_specs[]): Remove related entry.
(static_spec_functions[]): Add new entry for pass-through-libs.
(main): Don't generate deleted lto_libgcc_spec.
(pass_through_libs_spec_func): New function to implement the new
pass-through-libs spec function.
* doc/invoke.texi (pass-through-libs): Document new spec function.
From-SVN: r167091
|
|
find lto-wrapper)
2010-11-22 Dmitry Gorbachev <d.g.gorbachev@gmail.com>
PR driver/43335
* gcc.c (main): Don't crash when lto-wrapper program is not found.
From-SVN: r167052
|
|
* gcc.c (char_p): Define. Define a VEC of it.
(n_linker_options, n_assembler_options, n_preprocessor_options):
Delete.
(linker_options, assembler_options, preprocessor_options): Convert
to a VEC.
(add_preprocessor_option): Adjust.
(add_assembler_option): Adjust.
(add_linker_option): Adjust.
(do_specs_vec): New function.
(do_spec_1): Call it. Adjust for new types.
From-SVN: r166801
|
|
* gcc.c: Include "vec.h".
(argbuf): Make into a VEC.
(argbuf_length, argbuf_index): Remove.
(alloc_args, clear_args, store_arg, execute, insert_wrapper,
do_spec, do_self_spec, do_spec_1, eval_spec_function, main,
compare_debug_dump_opt_spec_function: Use VEC interfaces on
argbuf.
* Makefile.in (GCC_OBJS): Add vec.o and ggc-none.o.
(gcc.o): Depend on $(VEC_H).
From-SVN: r166788
|
|
* Makefile.in (OPTS_H): Define.
(c-decl.o, c-family/c-common.o, c-family/c-opts.o,
c-family/c-pch.o, c-family/c-pragma.o, gcc.o, gccspec.o,
cppspec.o, options.o, gcc-options.o, lto-opts.o, opts.o,
opts-common.o, toplev.o, passes.o, matrix-reorg.o,
ipa-struct-reorg.o, PLUGIN_HEADERS): Use $(OPTS_H).
* gcc.c (driver_handle_option): Take location_t parameter.
(process_command, do_self_spec): Update calls to
read_cmdline_option.
* langhooks-def.h (lhd_handle_option): Take location_t parameter.
* langhooks.c (lhd_handle_option): Take location_t parameter.
* langhooks.h (handle_option): Take location_t parameter.
* lto-opts.c (lto_reissue_options): Update call to set_option.
* opts-common.c (handle_option): Make static. Take location_t
parameter and pass it to other functions.
(handle_generated_option): Take location_t parameter and pass it
to other functions.
(read_cmdline_option): Take location_t parameter and pass it to
other functions. Use warning_at and error_at.
(set_option): Take location_t parameter and pass it to other
functions.
* opts.c (common_handle_option): Take location_t parameter and
pass it to other functions.
(enable_warning_as_error): Make static. Take location_t parameter
and pass it to other functions.
(lang_handle_option): Take location_t parameter and pass it to
other functions.
(target_handle_option): Take location_t parameter.
(read_cmdline_options, maybe_default_option,
maybe_default_options, default_options_optimization,
decode_options): Take location_t parameter and pass it to other
functions.
* opts.h: Include input.h.
(struct cl_option_handler_func, decode_options, set_option,
handle_generated_option, read_cmdline_option): Take location_t
parameters.
(handle_option, enable_warning_as_error): Remove.
* toplev.c (toplev_main): Update call to decode_options.
ada:
* gcc-interface/Make-lang.in (ada/misc.o): Use $(OPTS_H).
* gcc-interface/misc.c (gnat_handle_option): Take location_t
parameter.
c-family:
* c-common.c (parse_optimize_options): Update call to
decode_options.
* c-common.h (c_common_handle_option): Update prototype.
* c-opts.c (c_common_handle_option): Take location_t parameter and
pass it to other functions.
cp:
* Make-lang.in (g++spec.o): Use $(OPTS_H).
fortran:
* Make-lang.in (gfortranspec.o): Use $(OPTS_H).
* gfortran.h (gfc_handle_option): Take location_t parameter.
* options.c (gfc_handle_option): Take location_t parameter.
java:
* Make-lang.in (jvspec.o, java/lang.o): Use $(OPTS_H).
* lang.c (java_handle_option): Take location_t parameter.
lto:
* Make-lang.in (lto/lto.o): Use $(OPTS_H).
* lto-lang.c (lto_handle_option): Take location_t parameter.
From-SVN: r166688
|
|
* doc/invoke.texi (-fwhopr): Merge into -flto section.
(-flto-partition): Document none.
* gcc.c (LINK_COMMAND_SPEC): Remove -fwhopr.
* lto-wrapper.c: Update comment.
(run_gcc): Update LTO option parsing.
* opts.c (finish_options): add support -flto-partition=none
(common_handle_option): Remove fwhopr.
* common.opt: Turn fwhopr into flto.
* collect2.c (main): Update option handling.
* cgraphunit.c (cgraph_decide_is_function_needed): Remove flag_whopr.
* ipa-split.c (execute_split_functions): Remove flag_whopr.
* ipa.c (function_and_variable_visibility): Remove flag_whopr.
* ipa-prop.c (ipa_compute_jump_functions): Remove flag_whopr.
* varpool.c (decide_is_variable_needed): Remove flag_whopr.
* gcc.dg/20081223-1.c: Update LTO options.
* gcc.dg/lto/20090206-1_0.c: Update LTO options.
* gcc.dg/lto/20081118_0.c: Update LTO options.
* gcc.dg/lto/ipareference_0.c: Update LTO options.
* gcc.dg/lto/20100423-2_0.c: Update LTO options.
* gcc.dg/lto/20081201-1_0.c: Update LTO options.
* gcc.dg/lto/ipacp_0.c: Update LTO options.
* gcc.dg/lto/20090116_0.c: Update LTO options.
* gcc.dg/lto/20091015-1_0.c: Update LTO options.
* gcc.dg/lto/20090126-2_0.c: Update LTO options.
* gcc.dg/lto/20081202-2_0.c: Update LTO options.
* gcc.dg/lto/20081204-1_0.c: Update LTO options.
* gcc.dg/lto/const-uniq_0.c: Update LTO options.
* gcc.dg/lto/20081224_0.c: Update LTO options.
* gcc.dg/lto/20090219_0.c: Update LTO options.
* gcc.dg/lto/ipareference2_0.c: Update LTO options.
* gcc.dg/lto/20090206-2_0.c: Update LTO options.
* gcc.dg/lto/20081115_0.c: Update LTO options.
* gcc.dg/lto/20081201-2_0.c: Update LTO options.
* gcc.dg/lto/20081120-2_0.c: Update LTO options.
* gcc.dg/lto/materialize-1_0.c: Update LTO options.
* gcc.dg/lto/20090126-1_0.c: Update LTO options.
* gcc.dg/lto/20081202-1_0.c: Update LTO options.
* gcc.dg/lto/noreturn-1_0.c: Update LTO options.
* g++.dg/20090107-1.C: Update LTO options.
* g++.dg/lto/pr45679-2_0.C: Update LTO options.
* g++.dg/lto/20081123_0.C: Update LTO options.
* g++.dg/lto/20090313_0.C: Update LTO options.
* g++.dg/lto/20081125_0.C: Update LTO options.
* g++.dg/lto/20081109-1_0.C: Update LTO options.
* g++.dg/lto/20081219_0.C: Update LTO options.
* g++.dg/lto/20100724-1_0.C: Update LTO options.
* g++.dg/lto/20081204-1_0.C: Update LTO options.
* g++.dg/lto/20090303_0.C: Update LTO options.
* g++.dg/lto/20100723-1_0.C: Update LTO options.
* g++.dg/lto/pr45679-1_0.C: Update LTO options.
* g++.dg/lto/20090128_0.C: Update LTO options.
* g++.dg/lto/20081204-2_0.C: Update LTO options.
* g++.dg/lto/20090302_0.C: Update LTO options.
* g++.dg/lto/20081119-1_0.C: Update LTO options.
* g++.dg/lto/20081118_0.C: Update LTO options.
* g++.dg/20090121-1.C: Update LTO options.
* objc.dg/lto/lto.exp: Update LTO options.
* lib/lto.exp: Update LTO options.
* lib/gcc-dg.exp: Update LTO options.
* lib/c-torture.exp: Update LTO options.
* obj-c++.dg/lto/lto.exp: Update LTO options.
From-SVN: r166625
|
|
* common.opt (flag_excess_precision_cmdline, flag_generate_lto,
warn_larger_than, larger_than_size, warn_frame_larger_than,
frame_larger_than_size, flag_gen_aux_info, flag_shlib,
default_visibility, flag_tls_default): New Variable declarations.
(aux-info, auxbase, dumpbase, dumpdir, falign-functions=,
falign-jumps=, falign-labels=, falign-loops=, o, v): Use Var.
(v): Declare as Common and document here.
* flags.h (default_visibility, flag_generate_lto,
warn_larger_than, larger_than_size, warn_frame_larger_than,
frame_larger_than_size, flag_gen_aux_info, flag_pedantic_errors,
flag_shlib, flag_excess_precision_cmdline): Remove.
(set_Wstrict_aliasing): Update prototype.
* gcc.c (verbose_flag): Remove.
(driver_handle_option): Add diagnostic_context parameter. Don't
handle OPT_v explicitly here. Set verbose_flag to 1 rather than
incrementing it.
* opts-common.c (handle_option): Pass dc to handler.
* opts.c (warn_larger_than, larger_than_size,
warn_frame_larger_than, frame_larger_than_size,
default_visibility): Remove.
(common_handle_option): Add diagnostic_context parameter.
(set_fast_math_flags, set_unsafe_math_optimizations_flags): Add
gcc_options parameters.
(lang_handle_option, target_handle_option, read_cmdline_options,
decode_options): Add diagnostic_context parameters.
(finish_options): Access option state through opts pointer where
possible.
(common_handle_option): Access option state through opts pointer
where possible. Do not set local static variable verbose. Do not
explicitly handle OPT_v, OPT_Wstrict_aliasing_,
OPT_Wstrict_overflow_, OPT_Wunused, OPT_auxbase, OPT_dumpbase,
OPT_dumpdir, OPT_falign_functions_, OPT_falign_jumps_,
OPT_falign_labels_, OPT_falign_loops_, OPT_fira_verbose_, OPT_o or
OPT_fwhopr_. Do not explicitly set .opt file variables for
OPT_aux_info or OPT_pedantic_errors. Use dc for diagnostic
context.
(set_Wstrict_aliasing): Add gcc_options parameter.
* opts.h (struct cl_option_handler_func): Add diagnostic_context
parameter to handler.
(decode_options): Add diagnostic_context parameter.
* toplev.c (dump_base_name, dump_dir_name, aux_base_name,
asm_file_name, flag_generate_lto, flag_gen_aux_info,
aux_info_file_name, flag_shlib, flag_tls_default,
flag_excess_precision_cmdline, flag_pedantic_errors): Remove.
(toplev_main): Pass global_dc to decode_options.
* toplev.h (dump_base_name, dump_dir_name, aux_base_name,
aux_info_file_name, asm_file_name): Remove.
* tree.h (flag_tls_default): Remove.
c-family:
* c-common.c (parse_optimize_options): Pass global_dc to
decode_options.
* c-opts.c (c_common_handle_option): Pass &global_options to
set_Wstrict_aliasing.
* c.opt (v): Don't mark Common or document here.
fortran:
* cpp.c (asm_file_name): Don't declare here.
objc:
* objc-act.c (dump_base_name): Don't declare here.
From-SVN: r166565
|
|
* common.opt (R, T, Tbss, Tdata, Ttext, h, z): New.
* defaults.h (DEFAULT_SWITCH_TAKES_ARG, SWITCH_TAKES_ARG): Remove.
(DEFAULT_WORD_SWITCH_TAKES_ARG): Define to 0.
* doc/tm.texi.in (SWITCH_TAKES_ARG): Remove.
(WORD_SWITCH_TAKES_ARG): Don't refer to SWITCH_TAKES_ARG.
Document that options in .opt files do not need to be included.
* doc/tm.texi: Regenerate.
* gcc.c (LINK_COMMAND_SPEC): Don't include %{x}.
* opts-common.c: Update comment on tm.h include.
(decode_cmdline_option): Don't use SWITCH_TAKES_ARG.
* system.h (SWITCH_TAKES_ARG): Poison.
* config/alpha/alpha.h (SWITCH_TAKES_ARG): Remove.
* config/darwin.h (WORD_SWITCH_TAKES_ARG): Remove options included
in darwin.opt.
(LINK_COMMAND_SPEC_A): Don't include %{x}.
* config/fr30/fr30.h (SWITCH_TAKES_ARG, WORD_SWITCH_TAKES_ARG):
Remove.
* config/freebsd-spec.h (FBSD_SWITCH_TAKES_ARG): Remove.
* config/freebsd.h (SWITCH_TAKES_ARG): Remove.
* config/frv/frv.h (SWITCH_TAKES_ARG, WORD_SWITCH_TAKES_ARG):
Remove.
* config/i386/djgpp.h (LINK_COMMAND_SPEC): Don't include %{x}.
* config/ia64/ia64.h (SWITCH_TAKES_ARG): Remove.
* config/interix.h (WORD_SWITCH_TAKES_ARG): Don't handle -T
options.
* config/lm32/lm32.h (SWITCH_TAKES_ARG): Remove.
* config/m32r/m32r.h (SWITCH_TAKES_ARG, WORD_SWITCH_TAKES_ARG):
Remove.
* config/microblaze/microblaze.h (SWITCH_TAKES_ARG): Remove.
* config/mips/mips.h (SWITCH_TAKES_ARG): Remove.
* config/mips/netbsd.h (SWITCH_TAKES_ARG): Remove.
* config/mips/vxworks.h (SWITCH_TAKES_ARG): Remove.
* config/netbsd-aout.h (SWITCH_TAKES_ARG): Remove.
* config/netbsd-elf.h (SWITCH_TAKES_ARG): Remove.
* config/openbsd.h (SWITCH_TAKES_ARG): Remove.
* config/rs6000/sysv4.h (SWITCH_TAKES_ARG): Remove.
* config/score/score.h (SWITCH_TAKES_ARG): Remove.
* config/sol2.h (SWITCH_TAKES_ARG): Remove.
* config/sparc/sp-elf.h (SWITCH_TAKES_ARG): Remove.
* config/sparc/sp64-elf.h (SWITCH_TAKES_ARG): Remove.
* config/sparc/sparc.h (ASM_SPEC): Don't include %{R}.
* config/svr4.h (SWITCH_TAKES_ARG, WORD_SWITCH_TAKES_ARG): Remove.
From-SVN: r166155
|
|
* gcc.c (n_switches_alloc_debug_check): New.
(set_option_handlers): New.
(process_command): Use set_option_handlers.
(do_self_spec): Pass spec-generated options through option
handlers.
(main): Also save and restore n_switches_alloc when swapping
switch arrays.
From-SVN: r165891
|
|
* gcc.c (DEFAULT_SWITCH_CURTAILS_COMPILATION,
SWITCH_CURTAILS_COMPILATION): Remove.
* doc/tm.texi.in (SWITCH_CURTAILS_COMPILATION): Remove
documentation.
* doc/tm.texi: Regenerate.
* system.h (SWITCH_CURTAILS_COMPILATION): Poison.
From-SVN: r165855
|
|
* Makefile.in (TM_H): Include $(FLAGS_H) instead of options.h.
(TREE_H): Include $(FLAGS_H) instead of options.h.
(opts-common.o): Depend on $(FLAGS_H) instead of options.h.
* c-objc-common.h (LANG_HOOKS_INIT_OPTIONS_STRUCT): Define.
* common.opt (flag_complex_method, flag_evaluation_order,
flag_ira_algorithm, flag_ira_region, flag_warn_unused_result): New
Variable declarations.
* configure.ac (tm_include_list): Include flags.h instead of
options.h.
* configure: Regenerate.
* flags.h: Condition out contents for target libraries. Include
options.h at end of file.
(flag_complex_method, flag_ira_algorithm, flag_ira_region,
flag_evaluation_order, flag_warn_unused_result): Remove.
* gcc.c (main): Intialize global_options with global_options_init.
* langhooks-def.h (lhd_init_options_struct): Declare.
(LANG_HOOKS_INIT_OPTIONS_STRUCT): Define.
(LANG_HOOKS_INITIALIZER): Include LANG_HOOKS_INIT_OPTIONS_STRUCT.
* langhooks.c (lhd_init_options_struct): New.
* langhooks.h (struct lang_hooks): Add init_options_struct.
Update comment on init_options.
* optc-gen.awk: Generate initializer for global_options_init, not
global_options.
* opth-gen.awk: Condition out structure declarations for target
libraries. Declare global_options_init.
* opts-common.c: Include flags.h instead of options.h.
* opts.c (flag_warn_unused_result): Remove.
(read_cmdline_options): Take gcc_options parameters. Pass them to
read_cmdline_option.
(initial_lang_mask, initial_min_crossjump_insns,
initial_max_fields_for_field_sensitive,
initial_loop_invariant_max_bbs_in_loop): Define at file scope.
(init_options_once): New. Split out of decode_options.
(init_options_struct): New. Split out of decode_options.
(decode_cmdline_options_to_array_default_mask): New.
(default_options_optimization): New. Split out of decode_options.
(decode_options): Move most code to other functions. Update call
to read_cmdline_options.
(finish_options): New. Split out of decode_options.
* opts.h (decode_options): Add gcc_options parameters.
(init_options_once, init_options_struct,
decode_cmdline_options_to_array_default_mask): New.
* toplev.c (flag_complex_method, flag_ira_algorithm,
flag_ira_region, flag_evaluation_order): Remove.
(general_init): Use global_options_init for initial flag values
for global_dc.
(toplev_main): Call init_options_once, init_options_struct,
lang_hooks.init_options_struct,
decode_cmdline_options_to_array_default_mask and
lang_hooks.init_option before decode_options. Update arguments to
decode_options.
* tree.h: Include flags.h instead of options.h.
ada:
* gcc-interface/misc.c (gnat_init_options_struct): New. Split out
from gnat_init_options.
(LANG_HOOKS_INIT_OPTIONS_STRUCT): Define.
c-family:
* c-common.c (parse_optimize_options): Call
decode_cmdline_options_to_array_default_mask before
decode_options. Update arguments to decode_options.
* c-common.h (c_common_init_options_struct): Declare.
* c-opts.c (c_common_init_options_struct): New. Split out from
c_common_init_options.
cp:
* cp-objcp-common.h (LANG_HOOKS_INIT_OPTIONS_STRUCT): Define.
fortran:
* f95-lang.c (LANG_HOOKS_INIT_OPTIONS_STRUCT): Define.
* gfortran.h (gfc_init_options_struct): Declare.
* options.c (gfc_init_options_struct): New. Split out from
gfc_init_options.
java:
* lang.c (java_init_options_struct): New. Split out from
java_init_options.
(LANG_HOOKS_INIT_OPTIONS_STRUCT): Define.
lto:
* lto-lang.c (lto_init_options): Change to
lto_init_options_struct. Update parameters.
(LANG_HOOKS_INIT_OPTIONS): Don't define.
(LANG_HOOKS_INIT_OPTIONS_STRUCT): Define.
From-SVN: r165189
|
|
ChangeLog:
2010-10-07 Dave Korn <dave.korn.cygwin@gmail.com>
* configure.ac (build_lto_plugin): New shell variable.
(--enable-lto): Turn on by default for all non-ELF platforms that
have had LTO support added so far. Set build_lto_plugin appropriately
for both ELF and non-ELF.
(configdirs): Add lto-plugin or not based on build_lto_plugin.
* configure: Regenerate.
gcc/ChangeLog:
2010-10-07 Dave Korn <dave.korn.cygwin@gmail.com>
* config.host (host_lto_plugin_soname): New shell variable.
* configure.ac (LTOPLUGINSONAME): Add an AC_DEFINE for the above.
* config.in: Regenerate.
* configure: Regenerate.
* gcc.c (main): Use LTOPLUGINSONAME instead of hard-coding name of
LTO plugin shared library.
lto-plugin/ChangeLog:
2010-10-07 Dave Korn <dave.korn.cygwin@gmail.com>
* configure.ac: Source config.gcc to determine lto_binary_reader.
(LTO_FORMAT): New AC_SUBST variable inferred from lto_binary_reader.
* Makefile.am (LTO_FORMAT): Import.
(liblto_plugin_la_SOURCES): Add object format dependent module
defined by LTO_FORMAT.
(liblto_plugin_la_LIBADD): Allow for both PIC and non-PIC libiberty,
and work around libtool warning.
* configure: Regenerate.
* Makefile.in: Likewise.
* lto-plugin.c (struct sym_aux): Move to new lto-plugin.h.
(struct sym_aux): Likewise.
(struct plugin_symtab): Likewise.
(struct plugin_file_info): Likewise.
(LTO_SECTION_PREFIX): Likewise.
(add_symbols): Make non-static.
(claimed_files): Likewise.
(num_claimed_files): Likewise.
(check): Likewise.
(parse_table_entry): Likewise.
(translate): Likewise.
(resolve_conflicts): Likewise.
(process_symtab): Move to new lto-plugin-elf.c object format dependent
source file.
(claim_file_handler): Likewise, and make non-static.
(onload): Call new onload_format_checks function.
* lto-plugin.h: New file.
(LTO_SECTION_PREFIX): Move here.
(struct sym_aux): Likewise.
(struct plugin_symtab): Likewise.
(struct plugin_file_info): Likewise.
(claim_file_handler): Add new function prototype.
(onload_format_checks): Likewise.
(check): Declare extern.
(translate): Likewise.
(parse_table_entry): Likewise.
(resolve_conflicts): Likewise.
(add_symbols): Likewise.
(claimed_files): Likewise.
(num_claimed_files): Likewise.
* lto-plugin-elf.c (process_symtab): Move here.
(claim_file_handler): Likewise, and make non-static.
(onload_format_checks): New function factored out from onload.
* lto-plugin-coff.c (claim_file_handler): New function stub.
(onload_format_checks): Likewise.
From-SVN: r165133
|
|
* opts-common.c (handle_option, handle_generated_option,
read_cmdline_option, set_option): Add diagnostic_context
parameter. Update calls among these functions.
(set_option): Don't use global_dc.
* opts.c (read_cmdline_options): Pass global_dc to
read_cmdline_option.
(decode_options): Pass global_dc to enable_warning_as_error.
(common_handle_option): Pass global_dc to enable_warning_as_error.
(enable_warning_as_error): Add diagnostic_context parameter.
Document parameters. Don't use global_dc. Pass
diagnostic_context parameter to handle_generated_option.
* opts.h (set_option, handle_option, handle_generated_option,
read_cmdline_option, enable_warning_as_error): Add
diagnostic_context parameter.
* Makefile.in (lto-opts.o): Update dependencies.
* coretypes.h (struct diagnostic_context, diagnostic_context):
Declare here.
* diagnostic.h (diagnostic_context): Don't declare typedef here.
* gcc.c (process_command): Pass global_dc to read_cmdline_option.
* langhooks-def.h (struct diagnostic_context): Don't declare here.
(lhd_print_error_function, lhd_initialize_diagnostics): Declare
using diagnostic_context typedef.
* langhooks.c (lhd_initialize_diagnostics): Declare using
diagnostic_context typedef.
* langhooks.h (struct diagnostic_context): Don't declare here.
(initialize_diagnostics, print_error_function): Declare using
diagnostic_context typedef.
* lto-opts.c: Include diagnostic.h.
(lto_reissue_options): Pass global_dc to set_option. Pass
DK_UNSPECIFIED not 0.
* plugin.c (plugins_internal_error_function): Declare using
diagnostic_context typedef.
* plugin.h (struct diagnostic_context): Don't declare here.
(plugins_internal_error_function): Declare using
diagnostic_context typedef.
c-family:
* c-common.h (struct diagnostic_context): Don't declare here.
(c_common_initialize_diagnostics): Declare using
diagnostic_context typedef.
* c-opts.c (c_common_handle_option): Pass global_dc to
handle_generated_option.
cp:
* cp-tree.h (cxx_print_error_function,
cxx_initialize_diagnostics): Declare using diagnostic_context
typedef.
From-SVN: r164991
|
|
* optc-gen.awk: Define global_options_set. Don't define
target_flags_explicit.
* opth-gen.awk: Declare global_options_set. Define
target_flags_explicit as macro.
* opts-common.c (handle_option): Take opts_set and generated_p
parameters.
(handle_generated_option, read_cmdline_option, set_option): Take
opts_set parameter.
(set_option): Use opts_set instead of hardcoding target_flags and
target_flags_explicit.
* opts.c (sel_sched_switch_set, profile_arc_flag_set,
flag_profile_values_set, flag_unroll_loops_set, flag_tracer_set,
flag_value_profile_transformations_set, flag_peel_loops_set,
flag_branch_probabilities_set, flag_inline_functions_set,
flag_ipa_cp_set, flag_ipa_cp_clone_set,
flag_predictive_commoning_set, flag_unswitch_loops_set,
flag_gcse_after_reload_set): Remove.
(common_handle_option, lang_handle_option, target_handle_option):
Take opts_set parameter. Assert that it is &global_options_set.
(common_handle_option): Don't set _set variables. Check opts_set
instead of such variables.
(enable_warning_as_error): Pass &global_options_set to
handle_generated_option.
* opts.h (cl_option_handler_func.handler, set_option,
handle_option, handle_generated_option, read_cmdline_option): Add
opts_set parameters.
(handle_option): Add generated_p parameter.
* config/i386/i386.c (ix86_function_specific_save,
ix86_function_specific_restore): Updat for renaming of
target_flags_explicit field.
* config/i386/i386.opt (target_flags_explicit): Rename to
ix86_target_flags_explicit.
* config/ia64/ia64.c (ia64_override_options_after_change): Check
global_options_set.x_flag_selective_scheduling and
global_options_set.x_flag_selective_scheduling2, not
sel_sched_switch_set.
* flags.h (sel_sched_switch_set,
flag_speculative_prefetching_set): Remove.
* gcc.c (driver_handle_option): Take opts_set parameter. Assert
that it is &global_options_set.
(process_command): Pass &global_options_set to
read_cmdline_option.
* lto-opts.c (lto_reissue_options): Pass &global_options_set to
set_option.
* toplev.c (target_flags_explicit): Remove.
c-family:
* c-opts.c (c_common_handle_option): Pass &global_options_set to
handle_generated_option.
From-SVN: r164932
|
|
* opt-functions.awk (static_var): Update comment.
(var_ref): Return offsetof expression or -1, not variable address.
* optc-gen.awk: Generate structure field initializers instead of
static variables. Expect -1 for missing variables instead of null
pointer. Add gcc_options parameters to generated functions.
* opth-gen.awk: Generate structure fields for static variables.
Add gcc_options parameters to generated functions.
* common.opt (optimize, optimize_size): Add variables.
* config/i386/i386-c.c (ix86_pragma_target_parse): Pass
&global_options to cl_target_option_restore.
* config/i386/i386.c (ix86_valid_target_attribute_p): Pass
&global_options to cl_optimization_restore, cl_target_option_save
and cl_target_option_restore.
(ix86_set_current_function): Pass &global_options to
cl_target_option_restore.
* config/pdp11/pdp11.h (optimize): Remove.
* config/rs6000/rs6000.h (optimize): Remove.
* config/sh/sh.h (optimize): Remove.
* config/xtensa/xtensa.h (optimize): Remove.
* coretypes.h (struct gcc_options): Declare.
* diagnostic.c (diagnostic_initialize): Initialize
context->option_state.
(diagnostic_report_diagnostic): Pass option_state to
option_enabled hook.
* diagnostic.h (diagnostic_context.option_enabled): Add void *
parameter.
(diagnostic_context.option_state): New field.
* final.c (final_start_function, final, final_scan_insn): Rename
optimize parameter to optimize_p.
* flags.h (optimize, optimize_size): Remove.
* function.c (invoke_set_current_function_hook): Pass
&global_options to cl_optimization_restore.
* gcc.c (driver_handle_option): Take gcc_options parameter.
Assert that it is &global_options.
(process_command): Pass &global_options to read_cmdline_option.
* ipa-pure-const.c (suggest_attribute): Pass &global_options to
option_enabled.
* lto-opts.c (lto_reissue_options): Use option_flag_var. Pass
&global_options to set_option.
* opts-common.c (handle_option, handle_generated_option,
read_cmdline_option, set_option): Take explicit gcc_options
parameters. Use option_flag_var.
(option_flag_var): New.
* opts.c (common_handle_option, lang_handle_option,
target_handle_option): Take gcc_options parameter. Assert that it
is &global_options.
(read_cmdline_options): Pass &global_options to
read_cmdline_option.
(print_filtered_help): Use option_flag_var. Pass &global_options
to option_enabled.
(common_handle_option): Use option_flag_var.
(option_enabled): Take opts parameter. Use option_flag_var.
(get_option_state): Take gcc_options parameter. Use
option_flag_var. Pass gcc_options parameter to option_enabled.
(enable_warning_as_error): Pass &global_options to
handle_generated_option.
* opts.h (struct cl_option): Change flag_var to flag_var_offset.
(cl_option_handler_func.handler): Take gcc_options parameter.
(option_enabled, get_option_state, set_option, handle_option,
handle_generated_option, read_cmdline_option): Take gcc_options
parameters.
* toplev.c (optimize, optimize_size): Remove.
(print_switch_values): Pass &global_options to option_enabled.
(option_affects_pch_p): Use option_flag_var. Pass &global_options
to get_option_state.
(general_init): Initialize global_dc->option_state.
* tree.c (build_optimization_node): Pass &global_options to
cl_optimization_save.
(build_target_option_node): Pass &global_options to
cl_target_option_save.
c-family:
* c-common.c (handle_optimize_attribute): Pass &global_options to
cl_optimization_save and cl_optimization_restore.
* c-opts.c (c_common_handle_option): Pass &global_options to
handle_generated_option.
* c-pragma.c (handle_pragma_diagnostic): Use option_flag_var.
(handle_pragma_pop_options, handle_pragma_reset_options): Pass
&global_options to cl_optimization_restore.
From-SVN: r164751
|
|
gcc/:
* common.opt (fsplit-stack): New option.
* opts.c (decode_options): Set flag_split_stack to final value.
* target.def (supports_split_stack): New hook.
* gcc.c (STACK_SPLIT_SPEC): Define.
(LINK_COMMAND_SPEC): Use STACK_SPLIT_SPEC.
* doc/invoke.texi (Option Summary): Mention -fsplit-stack.
(Code Gen Options): Document -fsplit-stack.
* doc/extend.texi (Function Attributes): Mention no_split_stack.
(Function Attributes): Document no_split_stack.
* doc/tm.texi.in (Stack Smashing Protection): Add @hook
TARGET_SUPPORTS_SPLIT_STACK.
* doc/tm.texi: Rebuild.
* function.c (thread_prologue_and_epilogue_insns): If
flag_split_stack, add split stack prologue.
* explow.c (allocate_dynamic_stack_space): Support -fsplit-stack.
* varasm.c (saw_no_split_stack): New static variable.
(assemble_start_function): Set saw_no_split_stack if the function
has the no_split_stack attribute.
(file_end_indicate_split_stack): New function.
* output.h (file_end_indicate_split_stack): Declare.
* libgcc-std.ver (GCC_4.6.0): Add -fsplit-stack support variables
and function.
* doc/libgcc.texi (Miscellaneous routines): Document -fsplit-stack
routines.
* config/i386/i386.c (ix86_option_override_internal): Don't set
expand_builtin_va_start to NULL if -fsplit-stack.
(ix86_function_regparm): Reduce local regparm by 1 for 32-bit
-fsplit-stack.
(ix86_va_start): If -fsplit-stack, get overflow pointer from
scratch register set by prologue.
(ix86_code_end): If -fsplit-stack, call
file_end_indicate_split_stack.
(ix86_supports_split_stack): New static function.
(SPLIT_STACK_AVAILABLE): Define.
(split_stack_prologue_scratch_regno): New static function.
(split_stack_fn): New static variable.
(ix86_expand_split_stack_prologue): New function.
(ix86_live_on_entry): New static function.
(ix86_legitimate_address_p): Handle UNSPEC_STACK_CHECK.
(output_pic_addr_const): Likewise.
(i386_asm_output_addr_const_extra): Likewise.
(ix86_expand_call): Change return type to rtx. Return the new
call instruction.
(TARGET_SUPPORTS_SPLIT_STACK): Define.
(TARGET_EXTRA_LIVE_ON_ENTRY): Define.
* config/i386/i386.md (UNSPEC_STACK_CHECK): Define.
(split_stack_prologue, split_stack_return): New insns.
(split_stack_space_check): New insn.
* config/i386/i386.h (struct machine_function): Add
split_stack_varargs_pointer field.
* config/i386/linux.h (TARGET_CAN_SPLIT_STACK): Define.
(TARGET_THREAD_SPLIT_STACK_OFFSET): Define.
* config/i386/linux64.h (TARGET_CAN_SPLIT_STACK): Define.
(TARGET_THREAD_SPLIT_STACK_OFFSET): Define.
* config/i386/i386-protos.h (ix86_expand_split_stack_prologue):
Declare.
(ix86_expand_call): Update declaration.
gcc/c-family/:
* c-common.c (c_common_attribute_table): Add no_split_stack.
(handle_no_split_stack_attribute): New static function.
gcc/testsuite/:
* lib/target-supports.exp (check_effective_target_split_stack):
New procedure.
* gcc.dg/split-1.c: New test.
* gcc.dg/split-2.c: New test.
* gcc.dg/split-3.c: New test.
* gcc.dg/split-4.c: New test.
libgcc/:
* generic-morestack.h: New file.
* generic-morestack.c: New file.
* generic-morestack-thread.c: New file.
* config/i386/morestack.S: New file.
* config/t-stack: New file.
* config/i386/t-stack-i386: New file.
* config.host (i[34567]86-*-linux* and friends): Add t-stack and
i386/t-stack-i386 to tmake_file.
From-SVN: r164661
|
|
* opts-common.c (prune_options): Make static. Work with decoded
options.
(decode_cmdline_options_to_array): Call prune_options. Don't
resize option array here.
* opts.h (prune_options): Remove prototype.
* gcc.c (process_command): Take decoded options; don't call
decode_cmdline_options_to_array here. Use decoded options for
argv[0].
(main): Call decode_cmdline_options_to_array here instead of
prune_options. Update call to process_command.
* config/darwin-driver.c: Include opts.h.
(darwin_default_min_version): Work with decoded options. Don't
handle -b or -V here.
* config/darwin.h (darwin_default_min_version): Update prototype.
(GCC_DRIVER_HOST_INITIALIZATION): Update call to
darwin_default_min_version.
* config/i386/cygwin.h (mingw_scan): Update prototype.
(GCC_DRIVER_HOST_INITIALIZATION): Update call to mingw_scan.
* config/i386/cygwin1.c: Include opts.h.
(mingw_scan): Work with decoded options.
* config/i386/t-cygwin (cygwin1.o): Update dependencies.
* config/t-darwin (darwin-driver.o): Update dependencies.
From-SVN: r164532
|
|
* common.opt (-assemble, -compile, -coverage, -debug, -dump,
-dump=, -dumpbase, -dumpdir, -entry, -entry=, -extra-warnings,
-for-assembler, -for-assembler=, -for-linker, -for-linker=,
-force-link, -force-link=, -language, -language=,
-library-directory, -library-directory=, -no-canonical-prefixes,
-no-standard-libraries, -no-warnings, -optimize, -output,
-output=, -pass-exit-codes, -pedantic, -pedantic-errors, -pie,
-pipe, -prefix, -prefix=, -preprocess, -print-file-name,
-print-file-name=, -print-libgcc-file-name,
-print-multi-directory, -print-multi-lib,
-print-multi-os-directory, -print-prog-name, -print-prog-name=,
-print-search-dirs, -print-sysroot, -print-sysroot-headers-suffix,
-profile, -save-temps, -shared, -specs, -specs=, -static,
-symbolic, -time, -verbose, -param=, -sysroot, coverage, e, u,
symbolic): New.
(fhelp, fhelp=, ftarget-help, fversion): Make into aliases.
* gcc.c (A Short Introduction to Adding a Command-Line Option):
Remove comment.
(cc1_options): Correct specs for passing down --help,
--target-help and --help=*. Add spec for passing down --version.
(struct option_map, option_map, target_option_translations,
translate_options): Remove.
(driver_handle_option): Handle OPT__version, OPT__help, OPT__help_
and OPT__target_help instead of OPT_fversion, OPT_fhelp,
OPT_fhelp_ and OPT_ftarget_help.
(process_command): Don't call translate_options. Call
decode_cmdline_options_to_array before checking for
-no-canonical-prefixes using decoded options.
* opts-common.c (tm.h): Update comment on #include.
(find_opt): Allow abbreviations of long options.
(struct option_map, option_map): New.
(decode_cmdline_option): Use them instead of hardcoding -Wno, -fno
and -mno handling.
(target_option_translations): New.
(decode_cmdline_options_to_array): Handle
TARGET_OPTION_TRANSLATE_TABLE in driver.
* opts.c (common_handle_option): Don't handle OPT_fhelp,
OPT_ftarget_help, OPT_fhelp_ or OPT_fversion.
ada:
* gcc-interface/lang.opt (-all-warnings, -include-barrier,
-include-directory, -include-directory=, -no-standard-includes,
-no-standard-libraries): New.
c-family:
* c.opt (-all-warnings, -ansi, -assert, -assert=, -comments,
-comments-in-macros, -define-macro, -define-macro=, -dependencies,
-dump, -dump=, -imacros, -imacros=, -include, -include=,
-include-barrier, -include-directory, -include-directory=,
-include-directory-after, -include-directory-after=,
-include-prefix, -include-prefix=, -include-with-prefix,
-include-with-prefix=, -include-with-prefix-after,
-include-with-prefix-after=, -include-with-prefix-before,
-include-with-prefix-before=, -no-integrated-cpp,
-no-line-commands, -no-standard-includes, -no-warnings, -output,
-output=, -pedantic, -pedantic-errors, -preprocess,
-print-missing-file-dependencies, -trace-includes, -traditional,
-traditional-cpp, -trigraphs, -undefine-macro, -undefine-macro=,
-user-dependencies, -verbose, -write-dependencies,
-write-user-dependencies, no-integrated-cpp, traditional): New.
fortran:
* gfortranspec.c (lang_specific_driver): Handle OPT__version and
OPT__help instead of OPT_fversion and OPT_fhelp.
* lang.opt (-all-warnings, -assert, -assert=, -comments,
-comments-in-macros, -define-macro, -define-macro=, -dependencies,
-dump, -dump=, -include-barrier, -include-directory,
-include-directory=, -include-directory-after,
-include-directory-after=, -include-prefix, -include-prefix=,
-no-line-commands, -no-standard-includes, -output, -output=,
-preprocess, -print-missing-file-dependencies, -trace-includes,
-undefine-macro, -undefine-macro=, -user-dependencies, -verbose,
-write-dependencies, -write-user-dependencies): New.
java:
* jvspec.c (lang_specific_driver): Handle OPT__help instead of
OPT_fhelp.
* lang.opt (-CLASSPATH, -all-warnings, -bootclasspath, -classpath,
-dependencies, -encoding, -extdirs, -include-directory,
-include-directory=, -output-class-directory,
-output-class-directory=, -resource, -resource=,
-user-dependencies): New.
From-SVN: r164531
|
|
2010-09-17 Richard Guenther <rguenther@suse.de>
* common.opt (combine): Remove.
* gcc.c (default_compilers): Remove specs testing combine.
The C compilers no longer can combine.
(option_map): Remove -combine.
(display_help): Remove -combine.
(driver_handle_option): Remove OPT_combine handling.
(compile_input_file_p): Remove.
(do_spec): Remove code concerning combine.
(main): Likewise.
* doc/invoke.texi: Remove traces of -combine.
* lto-wrapper.c (run_gcc): Do not pass -combine to the compiler
driver.
lto/
* lang.opt (flag_wpa): Also enable for the driver.
* gcc.dg/pr27898.c: Use -flto instead of -combine.
* gcc.dg/pr28706.c: Likewise.
* gcc.dg/pr28712.c: Likewise.
* gcc.dg/pr30762-1.c: Likewise.
* gcc.dg/pr30762-2.c: Likewise.
* gcc.dg/pr31529-1.c: Likewise.
* gcc.dg/pr31529-2.c: Likewise.
* gcc.dg/pr34457-1.c: Likewise.
* gcc.dg/pr34457-2.c: Likewise.
* gcc.dg/pr34668-1.c: Likewise.
* gcc.dg/pr34668-2.c: Likewise.
* gcc.dg/pr34989-1.c: Likewise.
* gcc.dg/pr34989-2.c: Likewise.
* gcc.dg/pr43557-1.c: Likewise.
* gcc.dg/pr43557-2.c: Likewise.
* gcc.dg/debug/pr41893-1.c: Likewise.
* gcc.dg/matrix/matrix.exp: Do not use -combine.
* gcc.dg/matrix/matrix-3.c: Drop dg-options.
* gcc.dg/matrix/matrix-4.c: Likewise.
* gcc.dg/struct/struct-reorg.exp: Do not use -combine.
* gcc.dg/struct/wo_prof_empty_str.c: Drop dg-options.
* gcc.dg/struct/wo_prof_escape_arg_to_local.c: Likewise.
* gcc.dg/struct/wo_prof_escape_return.c: Likewise.
From-SVN: r164357
|