Re: proposal to add -Wheader-guard option

2014-02-04 Thread Prathamesh Kulkarni
On Tue, Feb 4, 2014 at 12:45 PM, Markus Trippelsdorf
 wrote:
> On 2014.02.04 at 12:36 +0530, Prathamesh Kulkarni wrote:
>> Ping ?
>
> Patches should be posted to the gcc-patc...@gcc.gnu.org list.
> Please follow up there.
Redirected to gcc-patc...@gcc.gnu.org list. I apologize for posting here.
>
> --
> Markus


FW: Git repo lagging behing

2014-02-04 Thread Paulo Matos
Since the owner of the repo http://gcc.gnu.org/git/?p=gcc.git;a=summary is 
marked as being: gcc@gcc.gnu.org
moving this thread of the gcc mailing list.

Paulo Matos


-Original Message-
From: gcc-help-ow...@gcc.gnu.org [mailto:gcc-help-ow...@gcc.gnu.org] On Behalf 
Of Paulo Matos
Sent: 04 February 2014 14:08
To: gcc-h...@gcc.gnu.org
Subject: Git repo lagging behing

Hi,

Don't know if anybody noticed but something's wrong with the git repo. It's 
lagging behind. Last commit there was:
18 hours agotejohnson   2014-02-03 Teresa Johnson 

which was certainly not the last commit on trunk.

Paulo Matos




Merge epilog loop & loop version due to alias/alignment in vectorization?

2014-02-04 Thread Bingfeng Mei
Hi,
One of biggest issues we have with GCC vectorization is bloated code size.
For example, vectorized version is 2.5 times of non-vectorized one for the
following simple code. One reason is that GCC often creates one loop copy
because of aliasing/alignment and one epilog loop because of loop iteration
constraint.

void foo (int *a, int *b, int N)
{
  int i;
  for (i = 0; i < N; i++)
  {
a[i] = b[i];
  }
}

Looking closely, the epilog loop and alignement/aliasing loop are almost
identical, just different in initial values for some variables entering
the loop. Can they be merged into one in such situations? If yes, any 
suggestion on how to implement it? 

...
  :
  # i_39 = PHI 
  _41 = (long unsigned int) i_39;
  _42 = _41 * 4;
  _43 = a_7(D) + _42;
  _44 = b_9(D) + _42;
  _45 = *_44;
  *_43 = _45;
  i_47 = i_39 + 1;
  if (N_4(D) > i_47)
goto ;
  else
goto ;

  :
  goto ;

  :
  # i_51 = PHI 
  tmp.6_56 = (int) ratio_mult_vf.5_38;
  if (niters.3_34 == ratio_mult_vf.5_38)
goto ;
  else
goto ;

  :
  # i_50 = PHI 
  goto ;

  :
  goto ;

  :

  :
  # i_24 = PHI <0(12), i_32(14)>
  _26 = (long unsigned int) i_24;
  _27 = _26 * 4;
  _28 = a_7(D) + _27;
  _29 = b_9(D) + _27;
  _30 = *_29;
  *_28 = _30;
  i_32 = i_24 + 1;
  if (N_4(D) > i_32)
goto ;
  else
goto ;
...

Thanks,
Bingfeng


Re: Merge epilog loop & loop version due to alias/alignment in vectorization?

2014-02-04 Thread Xinliang David Li
See also http://gcc.gnu.org/ml/gcc/2013-08/msg00259.html

There are some concerns, but it would be interesting to do some
benchmarking of this.

David

On Tue, Feb 4, 2014 at 8:27 AM, Bingfeng Mei  wrote:
> Hi,
> One of biggest issues we have with GCC vectorization is bloated code size.
> For example, vectorized version is 2.5 times of non-vectorized one for the
> following simple code. One reason is that GCC often creates one loop copy
> because of aliasing/alignment and one epilog loop because of loop iteration
> constraint.
>
> void foo (int *a, int *b, int N)
> {
>   int i;
>   for (i = 0; i < N; i++)
>   {
> a[i] = b[i];
>   }
> }
>
> Looking closely, the epilog loop and alignement/aliasing loop are almost
> identical, just different in initial values for some variables entering
> the loop. Can they be merged into one in such situations? If yes, any
> suggestion on how to implement it?
>
> ...
>   :
>   # i_39 = PHI 
>   _41 = (long unsigned int) i_39;
>   _42 = _41 * 4;
>   _43 = a_7(D) + _42;
>   _44 = b_9(D) + _42;
>   _45 = *_44;
>   *_43 = _45;
>   i_47 = i_39 + 1;
>   if (N_4(D) > i_47)
> goto ;
>   else
> goto ;
>
>   :
>   goto ;
>
>   :
>   # i_51 = PHI 
>   tmp.6_56 = (int) ratio_mult_vf.5_38;
>   if (niters.3_34 == ratio_mult_vf.5_38)
> goto ;
>   else
> goto ;
>
>   :
>   # i_50 = PHI 
>   goto ;
>
>   :
>   goto ;
>
>   :
>
>   :
>   # i_24 = PHI <0(12), i_32(14)>
>   _26 = (long unsigned int) i_24;
>   _27 = _26 * 4;
>   _28 = a_7(D) + _27;
>   _29 = b_9(D) + _27;
>   _30 = *_29;
>   *_28 = _30;
>   i_32 = i_24 + 1;
>   if (N_4(D) > i_32)
> goto ;
>   else
> goto ;
> ...
>
> Thanks,
> Bingfeng


Re: FW: Git repo lagging behing

2014-02-04 Thread Marek Polacek
On Tue, Feb 04, 2014 at 03:59:45PM +, Paulo Matos wrote:
> Don't know if anybody noticed but something's wrong with the git repo. It's 
> lagging behind. Last commit there was:
> 18 hours ago  tejohnson   2014-02-03 Teresa Johnson 
> 
> which was certainly not the last commit on trunk.

I believe one of the overseers I don't want to name (hi Frank) will
have a look at this.

Marek


Re: Draft C bindings for IEEE 754-2008 part 4 now available

2014-02-04 Thread Joseph S. Myers
Revised versions of parts 3 and 4 are now available:

http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1789.pdf
http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1790.pdf

(note that these are not yet expected to address all comments on the 
previous versions; see also N1791 and N1792, with minutes of the last 
floating-point group meeting and agenda for the next).  Again, any 
comments are best sent direct to WG14.

-- 
Joseph S. Myers
jos...@codesourcery.com


question about gtype-desc.c

2014-02-04 Thread Iyer, Balaji V
Hello Jakub,
I think I have found a fix to _Cilk_for to be structured the way you 
requested. I am currently trying to clean up my code so that I can send you a 
patch.

Now, I am trying to remove the 2 fields I put in gimple_omp_for_iter: 
loop_count and grain. But, it is giving the following errors when I remove it.

Do you know what is causing it and how I can fix it?

gtype-desc.c: In function âvoid gt_ggc_mx_gimple_statement_base(void*)â:
gtype-desc.c:1721: error: âstruct gimple_omp_for_iterâ has no member named 
âloop_countâ
gtype-desc.c:1721: error: âstruct gimple_omp_for_iterâ has no member named 
âloop_countâ
gtype-desc.c:1722: error: âstruct gimple_omp_for_iterâ has no member named 
âgrainâ
gtype-desc.c:1722: error: âstruct gimple_omp_for_iterâ has no member named 
âgrainâ
gtype-desc.c: In function âvoid gt_pch_nx_gimple_statement_base(void*)â:
gtype-desc.c:4854: error: âstruct gimple_omp_for_iterâ has no member named 
âloop_countâ
gtype-desc.c:4854: error: âstruct gimple_omp_for_iterâ has no member named 
âloop_countâ
gtype-desc.c:4855: error: âstruct gimple_omp_for_iterâ has no member named 
âgrainâ
gtype-desc.c:4855: error: âstruct gimple_omp_for_iterâ has no member named 
âgrainâ
gtype-desc.c: In function âvoid gt_pch_p_21gimple_statement_base(void*, void*, 
void (*)(void*, void*), void*)â:
gtype-desc.c:8176: error: âstruct gimple_omp_for_iterâ has no member named 
âloop_countâ
gtype-desc.c:8178: error: âstruct gimple_omp_for_iterâ has no member named 
âgrainâ

These files are in the build directory. I deleted everything and reconfigured 
but the error reappears.

Thanks,

Balaji V. Iyer.


Re: question about gtype-desc.c

2014-02-04 Thread Jakub Jelinek
On Tue, Feb 04, 2014 at 10:12:13PM +, Iyer, Balaji V wrote:
> Hello Jakub,
>   I think I have found a fix to _Cilk_for to be structured the way you 
> requested. I am currently trying to clean up my code so that I can send you a 
> patch.
> 
>   Now, I am trying to remove the 2 fields I put in gimple_omp_for_iter: 
> loop_count and grain. But, it is giving the following errors when I remove it.
> 
> Do you know what is causing it and how I can fix it?
> 
> gtype-desc.c: In function âvoid gt_ggc_mx_gimple_statement_base(void*)â:
> gtype-desc.c:1721: error: âstruct gimple_omp_for_iterâ has no member named 
> âloop_countâ
> gtype-desc.c:1721: error: âstruct gimple_omp_for_iterâ has no member named 
> âloop_countâ
> gtype-desc.c:1722: error: âstruct gimple_omp_for_iterâ has no member named 
> âgrainâ
> gtype-desc.c:1722: error: âstruct gimple_omp_for_iterâ has no member named 
> âgrainâ
> gtype-desc.c: In function âvoid gt_pch_nx_gimple_statement_base(void*)â:
> gtype-desc.c:4854: error: âstruct gimple_omp_for_iterâ has no member named 
> âloop_countâ
> gtype-desc.c:4854: error: âstruct gimple_omp_for_iterâ has no member named 
> âloop_countâ
> gtype-desc.c:4855: error: âstruct gimple_omp_for_iterâ has no member named 
> âgrainâ
> gtype-desc.c:4855: error: âstruct gimple_omp_for_iterâ has no member named 
> âgrainâ
> gtype-desc.c: In function âvoid gt_pch_p_21gimple_statement_base(void*, 
> void*, void (*)(void*, void*), void*)â:
> gtype-desc.c:8176: error: âstruct gimple_omp_for_iterâ has no member named 
> âloop_countâ
> gtype-desc.c:8178: error: âstruct gimple_omp_for_iterâ has no member named 
> âgrainâ
> 
> These files are in the build directory. I deleted everything and reconfigured 
> but the error reappears.

You mean you've started a new build directory, or just removed *.o or
something similar?  I'd suggest to rm s-gtype gtype-desc.c and make s-gtype.

Jakub


RE: question about gtype-desc.c

2014-02-04 Thread Iyer, Balaji V


> -Original Message-
> From: gcc-ow...@gcc.gnu.org [mailto:gcc-ow...@gcc.gnu.org] On Behalf Of
> Jakub Jelinek
> Sent: Tuesday, February 4, 2014 5:23 PM
> To: Iyer, Balaji V
> Cc: gcc@gcc.gnu.org
> Subject: Re: question about gtype-desc.c
> 
> On Tue, Feb 04, 2014 at 10:12:13PM +, Iyer, Balaji V wrote:
> > Hello Jakub,
> > I think I have found a fix to _Cilk_for to be structured the way you
> requested. I am currently trying to clean up my code so that I can send you a
> patch.
> >
> > Now, I am trying to remove the 2 fields I put in gimple_omp_for_iter:
> loop_count and grain. But, it is giving the following errors when I remove it.
> >
> > Do you know what is causing it and how I can fix it?
> >
> > gtype-desc.c: In function âvoid
> gt_ggc_mx_gimple_statement_base(void*)â:
> > gtype-desc.c:1721: error: âstruct gimple_omp_for_iterâ has no member
> > named âloop_countâ
> > gtype-desc.c:1721: error: âstruct gimple_omp_for_iterâ has no member
> > named âloop_countâ
> > gtype-desc.c:1722: error: âstruct gimple_omp_for_iterâ has no member
> > named âgrainâ
> > gtype-desc.c:1722: error: âstruct gimple_omp_for_iterâ has no member
> > named âgrainâ
> > gtype-desc.c: In function âvoid
> gt_pch_nx_gimple_statement_base(void*)â:
> > gtype-desc.c:4854: error: âstruct gimple_omp_for_iterâ has no member
> > named âloop_countâ
> > gtype-desc.c:4854: error: âstruct gimple_omp_for_iterâ has no member
> > named âloop_countâ
> > gtype-desc.c:4855: error: âstruct gimple_omp_for_iterâ has no member
> > named âgrainâ
> > gtype-desc.c:4855: error: âstruct gimple_omp_for_iterâ has no member
> > named âgrainâ
> > gtype-desc.c: In function âvoid
> gt_pch_p_21gimple_statement_base(void*, void*, void (*)(void*, void*),
> void*)â:
> > gtype-desc.c:8176: error: âstruct gimple_omp_for_iterâ has no member
> > named âloop_countâ
> > gtype-desc.c:8178: error: âstruct gimple_omp_for_iterâ has no member
> > named âgrainâ
> >
> > These files are in the build directory. I deleted everything and 
> > reconfigured
> but the error reappears.
> 
> You mean you've started a new build directory, or just removed *.o or
> something similar?  I'd suggest to rm s-gtype gtype-desc.c and make s-gtype.

I did the following

cd build_dir
rm -rf *
../gcc/configure --prefix=$PWD/../install --enable-languages="c,c++" 
make

Should I do make s-gtype before I do "make" above?



> 
>   Jakub


Re: question about gtype-desc.c

2014-02-04 Thread Jakub Jelinek
On Tue, Feb 04, 2014 at 10:26:20PM +, Iyer, Balaji V wrote:
> > > gtype-desc.c:8176: error: âstruct gimple_omp_for_iterâ has no member
> > > named âloop_countâ
> > > gtype-desc.c:8178: error: âstruct gimple_omp_for_iterâ has no member
> > > named âgrainâ
> > >
> > > These files are in the build directory. I deleted everything and 
> > > reconfigured
> > but the error reappears.
> > 
> > You mean you've started a new build directory, or just removed *.o or
> > something similar?  I'd suggest to rm s-gtype gtype-desc.c and make s-gtype.
> 
> I did the following
> 
> cd build_dir
> rm -rf *
> ../gcc/configure --prefix=$PWD/../install --enable-languages="c,c++" 
> make
> 
> Should I do make s-gtype before I do "make" above?

What you did should be more than enough.  But then, I didn't see
loop_count nor grain fields of gimple_omp_for_iter in your previously posted
patches (only your ChangeLog mentioned it).  So, if you start with wiping up
the build directory, I think you have to grep where the fields appear.

Jakub


RE: question about gtype-desc.c

2014-02-04 Thread Iyer, Balaji V


> -Original Message-
> From: Jakub Jelinek [mailto:ja...@redhat.com]
> Sent: Tuesday, February 4, 2014 5:36 PM
> To: Iyer, Balaji V
> Cc: gcc@gcc.gnu.org
> Subject: Re: question about gtype-desc.c
> 
> On Tue, Feb 04, 2014 at 10:26:20PM +, Iyer, Balaji V wrote:
> > > > gtype-desc.c:8176: error: âstruct gimple_omp_for_iterâ has no
> > > > member named âloop_countâ
> > > > gtype-desc.c:8178: error: âstruct gimple_omp_for_iterâ has no
> > > > member named âgrainâ
> > > >
> > > > These files are in the build directory. I deleted everything and
> > > > reconfigured
> > > but the error reappears.
> > >
> > > You mean you've started a new build directory, or just removed *.o
> > > or something similar?  I'd suggest to rm s-gtype gtype-desc.c and make s-
> gtype.
> >
> > I did the following
> >
> > cd build_dir
> > rm -rf *
> > ../gcc/configure --prefix=$PWD/../install --enable-languages="c,c++"
> > make
> >
> > Should I do make s-gtype before I do "make" above?
> 
> What you did should be more than enough.  But then, I didn't see
> loop_count nor grain fields of gimple_omp_for_iter in your previously
> posted patches (only your ChangeLog mentioned it).  So, if you start with
> wiping up the build directory, I think you have to grep where the fields
> appear.
> 

OK. Found the issue. I had the 2 fields enclosed inside a #if 0 and #endif

I guess whatever that is reading the fields to create gtype-desc.c does not 
understand C/C++ pre-processing, and thus it didn't ignore the fields in 
between #if 0.

Thanks,

Balaji V. Iyer.


Re: git mirror hasn't been updated for 8 hours

2014-02-04 Thread Frank Ch. Eigler
Hi -

There appears to have been a problem with bernie's cron-based
git-svn-fetch job, due to a corrupted (emptied) .git/svn/.cache/XXX.db
file.  With that file removed, the cron job is running again.  A
little bit extra logging was added to help pinpoint the cause next
time.

- FChE


Re: question about gtype-desc.c

2014-02-04 Thread Basile Starynkevitch
On Tue, 2014-02-04 at 23:07 +, Iyer, Balaji V wrote:
> 
> > -Original Message-
> > From: Jakub Jelinek [mailto:ja...@redhat.com]
> > Sent: Tuesday, February 4, 2014 5:36 PM
> > To: Iyer, Balaji V
> > Cc: gcc@gcc.gnu.org
> > Subject: Re: question about gtype-desc.c
> > 
> > On Tue, Feb 04, 2014 at 10:26:20PM +, Iyer, Balaji V wrote:
> > > > > gtype-desc.c:8176: error: âstruct gimple_omp_for_iterâ has no
> > > > > member named âloop_countâ
> > > > > gtype-desc.c:8178: error: âstruct gimple_omp_for_iterâ has no
> > > > > member named âgrainâ
> > > > >
> > > > > These files are in the build directory. I deleted everything and
> > > > > reconfigured
> > > > but the error reappears.
[...]
> > What you did should be more than enough.  But then, I didn't see
> > loop_count nor grain fields of gimple_omp_for_iter in your previously
> > posted patches (only your ChangeLog mentioned it).  So, if you start with
> > wiping up the build directory, I think you have to grep where the fields
> > appear.
> > 
> 
> OK. Found the issue. I had the 2 fields enclosed inside a #if 0 and #endif
> 
> I guess whatever that is reading the fields to create gtype-desc.c does not 
> understand C/C++ pre-processing, and thus it didn't ignore the fields in 
> between #if 0.
[...]

Yes. gengtype, the utility creating gtype-desc.c, does not care about
the C++ preprocessing. Ideally, I believe it should, but that is hard
work.
-- 
Basile STARYNKEVITCH http://starynkevitch.net/Basile/
email: basilestarynkevitchnet mobile: +33 6 8501 2359
8, rue de la Faiencerie, 92340 Bourg La Reine, France
*** opinions {are only mine, sont seulement les miennes} ***