This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PATCH RFA: Add -ggo option


"Joseph S. Myers" <joseph@codesourcery.com> writes:

> On Wed, 3 Nov 2010, Ian Lance Taylor wrote:
>
>> This patch adds a -ggo option to gcc.  This option is used when building
>> the Go library.  The Go library calls libc functions directly, which
>> means that it needs to know the layout of structures like stat and the
>> size of types like uid_t.  I implemented this by adding a -ggo option to
>> gcc which generates debugging information as Go language comments in the
>> assembler file.  The shell script mksysinfo.sh in the libgo library uses
>> that like this:
>
> Why is this a -g option rather than -f (writing to a separate file rather 
> than the .s output)?  It seems much more closely related to 
> -fdump-ada-spec (or -aux-info, though that's a legacy option name) than to 
> other -g options.

Because tying into the debug hooks is a natural place to gather all the
required information.

That said, of course I could probably tie into the debug hooks using a
-f option if people think that would be a better approach.

Ian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]