This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH 1/3] PR jit/64810: driver, arm, jit: configure-time default options
- From: Joseph Myers <joseph at codesourcery dot com>
- To: David Malcolm <dmalcolm at redhat dot com>
- Cc: <jit at gcc dot gnu dot org>, <gcc-patches at gcc dot gnu dot org>, Ramana Radhakrishnan <ramana dot radhakrishnan at arm dot com>
- Date: Fri, 30 Jan 2015 22:03:17 +0000
- Subject: Re: [PATCH 1/3] PR jit/64810: driver, arm, jit: configure-time default options
- Authentication-results: sourceware.org; auth=none
- References: <1422616184-38258-1-git-send-email-dmalcolm at redhat dot com>
On Fri, 30 Jan 2015, David Malcolm wrote:
> gcc/ChangeLog:
> PR jit/64810
> * Makefile.in (GCC_OBJS): Add gcc-main.o.
> * gcc-main.c: New file, containing "main" taken from gcc.c.
> * gcc.c (do_self_spec): Free decoded_options.
> (class driver): Move declaration to gcc.h.
> (main): Move declaration and implementation to new file
> gcc-main.c.
> (driver_get_configure_time_options): New function.
> * gcc.h (class driver): Move this declaration here, from
> gcc.c.
> (driver_get_configure_time_options): New declaration.
The driver changes are OK. Though in the JIT I suspect you might need to
process DRIVER_SELF_SPECS as well - not everything handled through
DRIVER_SELF_SPECS is a default cc1 would follow anyway, sometimes it may
actually set things rather than merely make them visible to other specs.
And indeed CC1_SPEC may also be needed. Some architectures use
DRIVER_SELF_SPECS to handle -march=native, some use CC1_SPEC - so if you
configure --with-arch=native (a perfectly legitimate way to configure GCC
if you're building it for one particular system to use to build code that
will run only there) then processing OPTION_DEFAULT_SPECS will cause
-march=native to appear in the list of options, and the other two specs
are needed to convert it into the underlying options understood by the
back-end option handling.
--
Joseph S. Myers
joseph@codesourcery.com