Re: [10 PATCHES] inline functions to avoid stack overflow

2008-06-25 Thread Bart Van Assche
On Thu, Jun 26, 2008 at 12:09 AM, David Miller <[EMAIL PROTECTED]> wrote: > From: Mikulas Patocka <[EMAIL PROTECTED]> > Date: Wed, 25 Jun 2008 08:53:10 -0400 (EDT) > >> Even worse, gcc doesn't use these additional bytes. If you try this: >> >> extern void f(int *i); >> void g() >> { >> int

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

2007-10-26 Thread Bart Van Assche
ighly undesirable. This is why any variable that is shared over threads has to be declared volatile, even when using explicit locking calls. I hope the above brings more clarity in this discussion. Bart Van Assche.

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

2007-10-26 Thread Bart Van Assche
g in scalable shared-memory multiprocessors, International Symposium on Computer Architecture, 1990, http://portal.acm.org/citation.cfm?id=325102&dl=ACM&coll=GUIDE). Bart Van Assche.

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

2007-10-27 Thread Bart Van Assche
ynchronization function and accesses to variables. Maybe it's a good idea to add a chapter to the gcc manual about multithreaded programming, such that gcc users who did not follow this discussion can look up this kind of information easily ? Bart Van Assche.

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

2007-10-27 Thread Bart Van Assche
rd. Your reply did not acknowledge nor deny this. Bart Van Assche.

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

2007-10-28 Thread Bart Van Assche
er won't write code that triggers (2). And as you may have noted, I do not agree with Hans Boehm where he states that the combination of C/C++ with POSIX threads cannot result in correctly working programs. I believe that the issues raised by Hans Boehm can be solved. Bart Van Assche.

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

2007-10-28 Thread Bart Van Assche
On 10/28/07, Robert Dewar <[EMAIL PROTECTED]> wrote: > Bart Van Assche wrote: > > > My opinion is that, given the importance of multithreading, it should > > be documented in the gcc manual which optimizations can cause trouble > > in multithreaded software (such as (