Re: Propose moving vectorization from -O3 to -O2.

2013-08-22 Thread Xinliang David Li
Interesting idea! David On Thu, Aug 22, 2013 at 4:46 PM, Cong Hou wrote: > Another opportunity to reduce the code size is combining the scalar version > from loop versioning, the prolog and the epilog of loop peeling. I manually > made the following function for foo(). The running time does not

Why out-of-ssa does var coalescing based on name?

2013-08-22 Thread Wei Mi
(Sorry if you received the mail twice. The first one was rejected because it was not plain text mode) For the following case: float total = 0.2; int main() { int i; for (i = 0; i < 10; i++) { total += i; } return total == 0.3; } The gcc assembly of its kernel loop is: .L3:

gcc-4.8-20130822 is now available

2013-08-22 Thread gccadmin
Snapshot gcc-4.8-20130822 is now available on ftp://gcc.gnu.org/pub/gcc/snapshots/4.8-20130822/ and on various mirrors, see http://gcc.gnu.org/mirrors.html for details. This snapshot has been generated from the GCC 4.8 SVN branch with the following options: svn://gcc.gnu.org/svn/gcc/branches

Vandalised wiki page

2013-08-22 Thread Alec Teal
http://gcc.gnu.org/wiki/FunctionMultiVersioning Reported by "kobrien" on the Freenode IRC network, channel #gcc just now, I'm just sending the message. Alec

Re: Propose moving vectorization from -O3 to -O2.

2013-08-22 Thread Xinliang David Li
On Thu, Aug 22, 2013 at 1:24 AM, Ondřej Bílka wrote: > On Wed, Aug 21, 2013 at 11:50:34PM -0700, Xinliang David Li wrote: >> > The effect on runtime is not correlated to >> > either (which means the vectorizer cost model is rather bad), but integer >> > code usually does not benefit at all. >> >>

Re: [RFC] Offloading Support in libgomp

2013-08-22 Thread Jakub Jelinek
On Thu, Aug 22, 2013 at 06:08:10PM +0400, Michael V. Zolotukhin wrote: > We're working on design for offloading support in GCC (part of OpenMP4), and I > have a question regarding libgomp part. > > Suppose we expand '#pragma omp target' like we expand '#pragma omp parallel', > i.e. the compiler ex

Re: XNEW and consorts

2013-08-22 Thread Gabriel Dos Reis
On Thu, Aug 22, 2013 at 8:51 AM, Dodji Seketeli wrote: > Richard Biener a écrit: > >> Support for constructing and destructing GC objects will be another >> story of course. > > Just curious. Does supporting this take more than just defining new and > delete > operators that call ggc_alloc_*/gg

Re: XNEW and consorts

2013-08-22 Thread Gabriel Dos Reis
On Thu, Aug 22, 2013 at 7:23 AM, Jakub Jelinek wrote: > On Thu, Aug 22, 2013 at 02:19:39PM +0200, Richard Biener wrote: >> Gabriel Dos Reis wrote: >> >Now that we have transitioned to C++, do we still need to use >> >placebo like XNEW and XNEWVEC in GCC source code proper? >> >(I am not talking a

[RFC] Offloading Support in libgomp

2013-08-22 Thread Michael V. Zolotukhin
Hi, We're working on design for offloading support in GCC (part of OpenMP4), and I have a question regarding libgomp part. Suppose we expand '#pragma omp target' like we expand '#pragma omp parallel', i.e. the compiler expands the following code: #pragma omp target { body; } to this: v

Re: XNEW and consorts

2013-08-22 Thread Dodji Seketeli
Richard Biener a écrit: > Support for constructing and destructing GC objects will be another > story of course. Just curious. Does supporting this take more than just defining new and delete operators that call ggc_alloc_*/ggc_free in there? (OK, that and defining the object walking routines

Re: XNEW and consorts

2013-08-22 Thread Jakub Jelinek
On Thu, Aug 22, 2013 at 02:19:39PM +0200, Richard Biener wrote: > Gabriel Dos Reis wrote: > >Now that we have transitioned to C++, do we still need to use > >placebo like XNEW and XNEWVEC in GCC source code proper? > >(I am not talking about uses in liberty.) > > > >Note that XNEW in particular do

Re: XNEW and consorts

2013-08-22 Thread Richard Biener
Gabriel Dos Reis wrote: >Hi, > >Now that we have transitioned to C++, do we still need to use >placebo like XNEW and XNEWVEC in GCC source code proper? >(I am not talking about uses in liberty.) > >Note that XNEW in particular does not work for types with >non-default constructors. > >We introduce

Re: PoC: Function Pointer Protection in C Programs

2013-08-22 Thread Stephen Röttger
> After bit of thought a loops with callback can be optimized by gcc. > > It could be possible to teach CSE to rewrite > > while(foo){ > check(p); > (*p)(x,y,z); > } > > into > > check(p); > while(foo){ > (*p)(x,y,z); > } > This might introduce security issues, if an attacker is able to o

Re: [oss-security] PoC: Function Pointer Protection in C Programs

2013-08-22 Thread Stephen Röttger
> Your approach seems to have some slight similarities with -fvtable-verify: > > > Maybe some code sharing could be achieved? Thanks for the hint, this project was actually a big inspiration for my thesis and is part of my related work, alth

Re: PoC: Function Pointer Protection in C Programs

2013-08-22 Thread Ondřej Bílka
On Wed, Aug 21, 2013 at 07:04:58PM +0200, Stephen Röttger wrote: > > > What is performance impact for program that just qsorts big array? It > > looks like worst case scenario for me. > > I just put together a quick test program that sorts an array of 10^6 > integers and stopped the execution tim

Re: Propose moving vectorization from -O3 to -O2.

2013-08-22 Thread Ondřej Bílka
On Wed, Aug 21, 2013 at 11:50:34PM -0700, Xinliang David Li wrote: > > The effect on runtime is not correlated to > > either (which means the vectorizer cost model is rather bad), but integer > > code usually does not benefit at all. > > The cost model does need some tuning. For instance, GCC vect

Re: How to specify multiple OSDIRNAME suffixes for multilib (Multilib usage with MPX)?

2013-08-22 Thread Ilya Enkovich
2013/8/21 Joseph S. Myers : > On Mon, 12 Aug 2013, Terry Guo wrote: > >> them to linker. When there is only one compatible library, the linker can >> find it by searching all paths, the whole thing can work. But when there are >> more than one compatible libraries spread in different paths, I am no