This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
RE: [PATCH] Fix PR39246: -Wuninitialized for partially initialized complex
- From: "Thomas Preud'homme" <thomas dot preudhomme at arm dot com>
- To: "GCC Patches" <gcc-patches at gcc dot gnu dot org>
- Date: Tue, 6 May 2014 17:56:00 +0800
- Subject: RE: [PATCH] Fix PR39246: -Wuninitialized for partially initialized complex
- Authentication-results: sourceware.org; auth=none
- References: <002a01cf6773$57b6c710$07245530$ at arm dot com> <CAFiYyc3Kcss14cGe1HaV=h=fvoFN7bxrR8UEUbT2YNrtWF=siQ at mail dot gmail dot com> <004601cf6910$d86ae0f0$8940a2d0$ at arm dot com>
Sorry, I forgot to include the new ChangeLogs:
*** gcc/ChangeLog ***
2014-05-06 Thomas Preud'homme <thomas.preudhomme@arm.com>
PR middle-end/39246
* tree-complex.c (expand_complex_move): Keep line info when expanding
complex move.
* tree-ssa-uninit.c (uninit_undefined_value_p): For SSA_NAME
initialized by a COMPLEX_EXPR, recurse on each part of the
COMPLEX_EXPR.
(warn_uninit): New argument. Ignore assignment of complex expression.
Use new argument to display correct location for values coming from
phi statement.
(warn_uninitialized_vars): Adapt to new signature of warn_uninit.
(warn_uninitialized_phi): Pass location of phi argument to warn_uninit.
*** gcc/testsuite/ChangeLog ***
2014-05-04 Thomas Preud'homme <thomas.preudhomme@arm.com>
* gcc.dg/uninit-13.c: Move warning on the actual source line where the
uninitialized complex is used.
* gcc.dg/uninit-17.c: New test to check partial initialization of
complex with branches.
* gcc.dg/uninit-17-O0.c: Likewise.
Ok for trunk?
Best regards,
Thomas Preud'homme