Infinite loop in compiling javax/swing/text/html/parser/HTML_401F.list

2007-10-27 Thread Dominique Dhumieres
On powerpc-apple-darwin8, I killed jc1 after it took over 37:29.81 at: ... echo ../../../../gcc-4.3-work/libjava/classpath/lib/gnu/javax/swing/text/html/parser/HTML_401F*.class> gnu/javax/swing/text/html/parser/HTML_401F.list /bin/sh ./libtool --tag=GCJ --mode=compile /opt/gcc/darwin_buildw/gcc/

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Darryl Miles
Dave Korn wrote: On 27 October 2007 18:27, Darryl Miles wrote: The "unintended write-access" optimization is a massive headache for developers of multi-threaded code. But it's a boon for the autovectoriser, because it means it can transform code with a branch into straight-line code. Then

Re: Optimization of conditional access to globals: thread-unsafe? II

2007-10-27 Thread Florian Weimer
* Andi Kleen: > Ian Lance Taylor <[EMAIL PROTECTED]> writes: > > Never mind your latest patch with Jakub's feedback seems to handle > that correctly. Looks good to me. It fixes the (very simple) Java test case, too.

RE: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Dave Korn
On 27 October 2007 18:27, Darryl Miles wrote: > The "unintended write-access" optimization is a massive headache for > developers of multi-threaded code. But it's a boon for the autovectoriser, because it means it can transform code with a branch into straight-line code. > The problem here is

RE: -fno-tree-cselim not working?

2007-10-27 Thread Dave Korn
On 26 October 2007 23:46, David Miller wrote: > From: "Dave Korn" > Date: Fri, 26 Oct 2007 17:35:44 +0100 > >> On 26 October 2007 17:28, Andrew Haley wrote: >> >>> Richard Guenther writes: >>> > > >>> > > This is legal POSIX threads code: counter is not accessed when we do >>> > > not hold t

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Andrew Haley
Florian Weimer writes: > * Samuel Tardieu: > > > On 27/10, Florian Weimer wrote: > > > > | (I can't reproduce the conditional store with my GCC 4.2 installation, > > | though.) > > > > You need "-O -fno-inline" to trigger it on this particular example > > (you don't need "-fno-inline" if

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Ian Lance Taylor
Andi Kleen <[EMAIL PROTECTED]> writes: > Ian Lance Taylor <[EMAIL PROTECTED]> writes: > > > > What do people think of this patch? This seems to fix the problem > > case without breaking Michael's case. It basically avoids store > > speculation: we don't write to a MEM unless the function > > unc

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Darryl Miles
Comments inline below v Tomash Brechko wrote: Consider this piece of code: extern int v; void f(int set_v) { if (set_v) v = 1; } f: pushl %ebp movl%esp, %ebp cmpl$0, 8(%ebp) movl$1, %e

Re: Optimization of conditional access to globals: thread-unsafe? II

2007-10-27 Thread Andi Kleen
Ian Lance Taylor <[EMAIL PROTECTED]> writes: Never mind your latest patch with Jakub's feedback seems to handle that correctly. Looks good to me. -Andi

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Andi Kleen
Ian Lance Taylor <[EMAIL PROTECTED]> writes: > > What do people think of this patch? This seems to fix the problem > case without breaking Michael's case. It basically avoids store > speculation: we don't write to a MEM unless the function > unconditionally writes to the MEM anyhow. I'm not sure

Would you like to give me advice about how to compile gcc? __addd3f link error.

2007-10-27 Thread J.C. Pizarro
On Sat 27 Oct 2007, "L.Yan" <[EMAIL PROTECTED]>: > Dear all, > > I want to build the source of gcc and make '-msoft-float' available. But > I don't know how to build the source code. I just do it as the following > steps: > > 1. download the source code, gcc-4.1.2.tar.gz, from the mirror site; > 2.

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Samuel Tardieu
On 27/10, Robert Dewar wrote: > I don't understand, are we looking at the same example, the example > from Sam that I looked at did not have an entry body, so how could the > entry body rule apply? Let's look at the example (where I replaced protected procedures by entries with a guard which is a

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Robert Dewar
Florian Weimer wrote: * Robert Dewar: In the following example, is the access to "Shared" considered unsynchronized even though what looks like a proper lock is used around it? Yes, it is unsynchronized. Why would you think otherwise? The signaling rules are dynamic, not static. Only the co

Re: ICE in libjava on ppc

2007-10-27 Thread Eric Botcazou
> I get the following ICE running bootstrap with -O2 on ppc, > --with-cpu=default32 r129655: http://gcc.gnu.org/ml/gcc-patches/2007-10/msg01543.html -- Eric Botcazou

ICE in libjava on ppc

2007-10-27 Thread Revital1 Eres
Hello, I get the following ICE running bootstrap with -O2 on ppc, --with-cpu=default32 r129655: make[5]: Entering directory `/home/revitale/mainline_750cl_test/new_build2/powerpc64-unknown-linux-gnu/nof/libjava' /bin/sh ./libtool --tag=GCJ --mode=compile /home/revitale/mainline_750cl_test/new_bu

Wir haben etwas gegen Geruch!

2007-10-27 Thread Logistik Profi
Wir haben etwas gegen Geruch !!! http://www.olfex.de Frachtenbörse ! Freight Exchange http://www.frachtintern.com 180 Day FREE MEMBER !!! -

Re: optimising recursive functions

2007-10-27 Thread Zdenek Dvorak
Hi, > > > So I am guessing the Felix version is lucky there are > > > no gratuitous temporaries to be saved when this happens, > > > and the C code is unlucky and there are. > > > > > > Maybe someone who knows how the optimiser works can comment? > > > > One problem with departing from the ABI eve

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Florian Weimer
* Samuel Tardieu: > On 27/10, Florian Weimer wrote: > > | (I can't reproduce the conditional store with my GCC 4.2 installation, > | though.) > > You need "-O -fno-inline" to trigger it on this particular example > (you don't need "-fno-inline" if you put "Lock" in a separate package). Ah, thanks

Re: optimising recursive functions

2007-10-27 Thread skaller
On Sat, 2007-10-27 at 12:54 +0200, Richard Guenther wrote: > On 10/27/07, Robert Dewar <[EMAIL PROTECTED]> wrote: > > skaller wrote: > > > > > So I am guessing the Felix version is lucky there are > > > no gratuitous temporaries to be saved when this happens, > > > and the C code is unlucky and th

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Samuel Tardieu
On 27/10, Florian Weimer wrote: | (I can't reproduce the conditional store with my GCC 4.2 installation, | though.) You need "-O -fno-inline" to trigger it on this particular example (you don't need "-fno-inline" if you put "Lock" in a separate package).

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Florian Weimer
* Robert Dewar: >> In the following example, is the access to "Shared" considered >> unsynchronized even though what looks like a proper lock is used >> around it? > > Yes, it is unsynchronized. Why would you think otherwise? The signaling rules are dynamic, not static. Only the code path that i

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Florian Weimer
* Bart Van Assche: > On 10/27/07, Florian Weimer <[EMAIL PROTECTED]> wrote: > >> And this isn't really specific to threads. > > Hello Florian, > > What I was trying to explain is that it is not necessary to declare > shared variables volatile, not for any C/C++ compiler that is > compliant with th

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Andrew Haley
Bart Van Assche writes: > On 10/27/07, Florian Weimer <[EMAIL PROTECTED]> wrote: > > > And this isn't really specific to threads. > What I was trying to explain is that it is not necessary to declare > shared variables volatile, not for any C/C++ compiler that is > compliant with the langua

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Bart Van Assche
On 10/27/07, Florian Weimer <[EMAIL PROTECTED]> wrote: > And this isn't really specific to threads. Hello Florian, What I was trying to explain is that it is not necessary to declare shared variables volatile, not for any C/C++ compiler that is compliant with the language standard. Your reply di

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Florian Weimer
* Bart Van Assche: > As known the compiler may not reorder any access to any static > variable, global variable or dynamically allocated data with a call to > a function that is not declared inline. I assume you mean "defined in another translation unit" instead of "not declared inline". Still,

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Andrew Haley
skaller writes: > > On Fri, 2007-10-26 at 14:24 -0700, Ian Lance Taylor wrote: > > > This is basically a public relations exercise. I doubt this > > optimization is especially important, so I think it's OK to > > disable it to keep people happy. Even though the optimization > > has been

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Bart Van Assche
> > On 10/22/07, Andrew Haley wrote: > > > > > The core problem here seems to be that the "C with threads" memory > > > model isn't sufficiently well-defined to make a determination > > > possible. You're assuming that you have no responsibility to mark > > > shared memory protected by a mutex as

Re: Would you like to give me advice about how to compile gcc?

2007-10-27 Thread Jonathan Wakely
On 27/10/2007, L.Yan <[EMAIL PROTECTED]> wrote: > > I want to build the source of gcc and make '-msoft-float' available. But > I don't know how to build the source code. I just do it as the following > steps: Hi Peter, this list is for discussing the development of gcc. To get help building and u

Would you like to give me advice about how to compile gcc?

2007-10-27 Thread L.Yan
Dear all, I want to build the source of gcc and make '-msoft-float' available. But I don't know how to build the source code. I just do it as the following steps: 1. download the source code, gcc-4.1.2.tar.gz, from the mirror site; 2. tar -xzf gcc-4.1.2.tar.gz; 3. ./configure --prefix=/home/user/

Re: optimising recursive functions

2007-10-27 Thread Eric Botcazou
> If you make the function static then gcc can chose ABI-incompatible > calling conventions. Right, and the gain can be significant on x86. -- Eric Botcazou

Re: optimising recursive functions

2007-10-27 Thread Richard Guenther
On 10/27/07, Robert Dewar <[EMAIL PROTECTED]> wrote: > skaller wrote: > > > So I am guessing the Felix version is lucky there are > > no gratuitous temporaries to be saved when this happens, > > and the C code is unlucky and there are. > > > > Maybe someone who knows how the optimiser works can com

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Tomash Brechko
On Sat, Oct 27, 2007 at 09:25:09 +1000, skaller wrote: > Yes, but with a class: > > struct X { > int x; > void f() { if (C) x = 1; } > void f2() { reg = x; if (c) reg = 1; x = reg; } > }; Hmm, indeed, and the example may end right here, you do

Re: Optimization of conditional access to globals: thread-unsafe?

2007-10-27 Thread Robert Dewar
Samuel Tardieu wrote: On 26/10, Robert Dewar wrote: | Of course in Ada there is a clear notion of threads semantic, and | a clear definition of what the meaning of code is in the presence | of threads, so the specific situation discussed here is easy to | deal with (though Ada takes the view tha

Re: optimising recursive functions

2007-10-27 Thread Robert Dewar
skaller wrote: On Fri, 2007-10-26 at 20:26 -0400, Robert Dewar wrote: skaller wrote: So I am guessing the Felix version is lucky there are no gratuitous temporaries to be saved when this happens, and the C code is unlucky and there are. Maybe someone who knows how the optimiser works can comm

Re: GCC 4.3 release schedule

2007-10-27 Thread Martin Michlmayr
* Joe Buck <[EMAIL PROTECTED]> [2007-10-26 14:53]: > Can you estimate how many packages use or ? Not easily because I backed out those changes. -- Martin Michlmayr http://www.cyrius.com/