This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Silence some uninitialized variable warnings that appear when bootstrapping
- From: Manuel López-Ibáñez <lopezibanez at gmail dot com>
- To: Eric Gallager <egall at gwmail dot gwu dot edu>
- Cc: Segher Boessenkool <segher at kernel dot crashing dot org>, Gcc Patch List <gcc-patches at gcc dot gnu dot org>
- Date: Sat, 3 Sep 2016 10:37:04 +0100
- Subject: Re: [PATCH] Silence some uninitialized variable warnings that appear when bootstrapping
- Authentication-results: sourceware.org; auth=none
- References: <CAMfHzOtxiecXKsixT7uYSMYp4jxpJ4+YCyW4u=3NyzEs6ajNAg@mail.gmail.com> <20160902153132.GA19656@gate.crashing.org> <CAMfHzOv0NcLinUMFJM2=kfM6vzkb2Ajb9JxZiiByCYffBF-bFA@mail.gmail.com> <20160902192733.GA7983@gate.crashing.org> <1a4528e0-a3e6-1aad-fd7a-7657530c5a92@gmail.com> <CAMfHzOvWSYFGWYe=L5xX3Unm_aBXmrOy4S=B2WaT4jx5eu0LuQ@mail.gmail.com> <20160902223949.GA16400@gate.crashing.org> <CAMfHzOt1HbHLq5=UzyiHeF15O_vGYZPOkFm7sYJirTeo0uDSCg@mail.gmail.com> <CAESRpQAM20Tkgek5PKTv9B2ONg6Qvy9LYzV_28XkzQf_+WJ79A@mail.gmail.com> <CAMfHzOugn=hnLoOeWrtgmWHtc-VWFmV=UW5vDs+LmA-Rw81ndA@mail.gmail.com>
On 3 September 2016 at 02:11, Eric Gallager <egall@gwmail.gwu.edu> wrote:
> On 9/2/16, Manuel López-Ibáñez <lopezibanez@gmail.com> wrote:
>> On 3 Sep 2016 12:56 a.m., "Eric Gallager" <egall@gwmail.gwu.edu> wrote:
>>> I tried that but it doesn't look like it produced any dumpfiles...
>>
>> I often use -fdump-tree-all-all-lineno
>>
>
>
> That produced a lot of files; I'm attaching a tarball of all of them
> because I don't know which is the correct one...
None of them. Are you sure you were using at least -O2 and -Wall ?
In any case, it is not worth it to waste your time on this further:
* Warnings in stage1 don't matter: https://gcc.gnu.org/wiki/FAQ#stage1warnings
* Wrong (missing or bogus) uninitialized warnings only present in old
compilers will not get fixed. They are rarely a regression nor easy to
fix.
* Large testcases for wrong uninitialized warnings are not worth
investigating except if they show a regression in trunk. Otherwise,
there are so many known issues with Wuninitialized that the analysis
will certainly be closed as a duplicate and not help at all towards a
possible fix.
* If you wish to learn about Wuninitialized, it is better to start
with one of the well-known and already analyzed bug reports than with
a large testcase. Major problems are described here:
https://gcc.gnu.org/wiki/Better_Uninitialized_Warnings#Current_Situation
However, those are likely among the hardest problems to solve in GCC,
so you may want to check for easyhacks.
Cheers,
Manuel.