This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug build/19444] build failures with -O1 due to -Wmaybe-uninitialized
- From: "carlos at redhat dot com" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sourceware dot org
- Date: Mon, 11 Jan 2016 21:42:31 +0000
- Subject: [Bug build/19444] build failures with -O1 due to -Wmaybe-uninitialized
- Auto-submitted: auto-generated
- References: <bug-19444-131 at http dot sourceware dot org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=19444
--- Comment #6 from Carlos O'Donell <carlos at redhat dot com> ---
(In reply to Martin Sebor from comment #5)
> I was aware of the -O0 restriction but not that it also applied to -O1.
>
> I have been using #pragma GCC optimize ("-O0") in the files I'm debugging
> but it seemed that building the rest with -O1 would be useful when one has
> to step into functions defined in other files.
>
> If using -O1 is just as futile as -O0 then perhaps updating the Wiki would
> be the best solution.
>
> Otherwise, if using -O1 should be possible (modulo the uninitialized
> warnings) then one of the other solutions I suggested in comment #2 would be
> a better approach.
>
> Which do you suggest?
I suggest fixing everything until -O1 builds, and then fixing everything until
-O0 builds. Those source files that need inlining must be marked such that they
work regardless of the global CFLAGS and should override any global settings.
Simialarly if we could mark just those functions that needed optimization with
source-level markup that overrides global CFLAGS, that would be even better.
Does that answer your question?
I think what you're doing is the right thing, but we just don't test it well,
and I'd be willing to review and accept any such patches.
--
You are receiving this mail because:
You are on the CC list for the bug.