[PATCH] Add strict aliasing warning when inlining function.

2014-08-18 Thread lin zuojian
Hi, I want to add a warning to inlining function when violate strict aliasing. See bug: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60546 For details. * tree-inline.c (global): Add new include to c-family/c-common.h. To access strict aliasing check. (setup_one_parameter): Add

Re: [PATCH] Fix comment typo in ira.c

2014-08-18 Thread Kito Cheng
Oops, I forgot to attach patch in the previous mail. On Mon, Aug 18, 2014 at 10:51 PM, Kito Cheng wrote: > Hi Vladimir: > > Here is a tiny typo in comment, allono -> allocno. > > ChangLog > 2014-08-18 Kito Cheng > > * ira.c: Fix typo in comment. From 6999747b19f53d140571f93991962292637

Re: [PATCH] Add strict aliasing warning when inlining function.

2014-08-18 Thread Andrew Pinski
On Mon, Aug 18, 2014 at 9:35 PM, lin zuojian wrote: > Hi, > I want to add a warning to inlining function when violate strict > aliasing. > See bug: > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60546 > For details. > > * tree-inline.c (global): Add new include to c-family/c-co

Re: [PATCH] Add strict aliasing warning when inlining function.

2014-08-18 Thread lin zuojian
Hi Andrew, I configure my gcc only to c language family. Sorry for my sloppy. I have not run the test yet either. I only run my test manually. That will be patch v2 soon. -- Lin Zuojian

Re: [C/C++ PATCH] Implement -Wbool-compare (PR c++/62153)

2014-08-18 Thread Marek Polacek
On Mon, Aug 18, 2014 at 10:57:58PM +0200, Manuel López-Ibáñez wrote: > On 18 August 2014 22:04, Marek Polacek wrote: > > +void > > +maybe_warn_bool_compare (location_t loc, enum tree_code code, tree op0, > > +tree op1) > > +{ > > + if (TREE_CODE_CLASS (code) != tcc_compari

Re: [PATCH v2] Add strict aliasing warning when inlining function.

2014-08-18 Thread lin zuojian
Hi, Here patch v2. Move the function as Andrew instructed. * tree-inline.c (setup_one_parameter): Add strict aliasing check. * c-family/c-common.c (strict_aliasing_warning): Move to alias.c. * c-family/c-common.h (strict_aliasing_warning): Move to tree.h. * alias.c (strict_alia

<    1   2