This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [build, driver] RFC: Support compressed debug sections
- From: Rainer Orth <ro at CeBiTec dot Uni-Bielefeld dot DE>
- To: "Joseph S. Myers" <joseph at codesourcery dot com>
- Cc: <gcc-patches at gcc dot gnu dot org>, Paolo Bonzini <bonzini at gnu dot org>, Mike Stump <mikestump at comcast dot net>, DJ Delorie <dj at delorie dot com>
- Date: Tue, 27 May 2014 10:11:27 +0200
- Subject: Re: [build, driver] RFC: Support compressed debug sections
- Authentication-results: sourceware.org; auth=none
- References: <yddvc7tmhx9 dot fsf at lokon dot CeBiTec dot Uni-Bielefeld dot DE> <Pine dot LNX dot 4 dot 64 dot 1304261553200 dot 27966 at digraph dot polyomino dot org dot uk> <yddd2tcazm5 dot fsf at lokon dot CeBiTec dot Uni-Bielefeld dot DE> <Pine dot LNX dot 4 dot 64 dot 1305032000020 dot 30366 at digraph dot polyomino dot org dot uk> <yddfvy2l9xa dot fsf at CeBiTec dot Uni-Bielefeld dot DE> <Pine dot LNX dot 4 dot 64 dot 1305051411440 dot 16386 at digraph dot polyomino dot org dot uk> <yddtx8if35c dot fsf at lokon dot CeBiTec dot Uni-Bielefeld dot DE> <Pine dot LNX dot 4 dot 64 dot 1405221547120 dot 11868 at digraph dot polyomino dot org dot uk> <yddiooxzszw dot fsf at CeBiTec dot Uni-Bielefeld dot DE> <Pine dot LNX dot 4 dot 64 dot 1405221632580 dot 11868 at digraph dot polyomino dot org dot uk>
"Joseph S. Myers" <joseph@codesourcery.com> writes:
> On Thu, 22 May 2014, Rainer Orth wrote:
>
>> "Joseph S. Myers" <joseph@codesourcery.com> writes:
>>
>> > On Thu, 22 May 2014, Rainer Orth wrote:
>> >
>> >> * common.opt (compressed_debug_sections): New enum.
>> >> (gz, gz=): New options.
>> >
>> >> * opts.c (common_handle_option): Handle OPT_gz, OPT_gz_.
>> >
>> > Given that the options are completely handled via specs, why can't they
>> > just be Driver options (without Common) and so not mentioned in
>> > common_handle_option?
>>
>> If I do this, -gz still gets passed to e.g. cc1, which errors out like
>> this:
>>
>> cc1: error: unrecognised debug output level "z"
>>
>> It seems my way of handling this is clearer than doing this in opts.c
>> (set_debug_level).
>
> Thanks for the explanation. The driver changes are OK.
Thanks. I still need approval for the doc and build parts, as well as
the Darwin and DJGPP changes. For the latter two, I've included the
patch in a x86_64-apple-darwin11.4.2 build, verifying that -gz is
rejected as expected (no idea if the are any working gas and gold ports
that would support the option). For DJGPP, I've tried a
i386-pc-solaris2.11 x i586-pc-msdosdjgpp cross. While the specs
additions look correct, trying to compile even the most trivial program
SEGVs:
ro@snoopy 319 > ./xgcc -B./ -o hello hello.c
<built-in>: internal compiler error: Segmentation Fault
0x87549df crash_signal
/vol/gcc/src/hg/trunk/local/gcc/toplev.c:337
0x82b8270 contains_struct_check
/vol/gcc/src/hg/trunk/local/gcc/tree.h:2841
0x82b8270 c_common_nodes_and_builtins()
/vol/gcc/src/hg/trunk/local/gcc/c-family/c-common.c:5619
0x82437be c_init_decl_processing()
/vol/gcc/src/hg/trunk/local/gcc/c/c-decl.c:3567
0x827fe1a c_objc_common_init()
/vol/gcc/src/hg/trunk/local/gcc/c/c-objc-common.c:63
0x8756333 lang_dependent_init
/vol/gcc/src/hg/trunk/local/gcc/toplev.c:1712
0x8756333 do_compile
/vol/gcc/src/hg/trunk/local/gcc/toplev.c:1901
Rainer
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University