This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Use of Dual Core causes random failures building OpenJDK


On 11/21/09, Corinna Vinschen <corinna-cygwin@cygwin.com> wrote:
> On Nov 20 14:04, mike marchywka wrote:
>> On 11/20/09, Christopher Faylor wrote:
>> > On Fri, Nov 20, 2009 at 01:19:57PM -0500, mike marchywka wrote:
>> >>On 11/20/09, Corinna Vinschen  wrote:
>> >>> And given POSIX, if so, it would be an application bug if the
>> >>> application
>> >>> doesn't care by itself to use setenv/getenv in a thread-safe manner.
>> >>
>> >>Why does the OS let this happen?  I thought windoze should avoid
>> >>garbage.
>> >
>> > Er, I think you're a little confused about what we're talking about.
>> > The
>> > OS doesn't enforce thread safety.  There's really no way that it can.
>>
>> We are talking about windoze env variables right? I did ask previously
>> I thought.
>
> We're only talking about Windows env variables if non-Cygwin processes
> are involved.  As long as only Cygwin processes are involved in the
> process, env variables are inherited via a Cygwin mechanism, not via
> the Windows environment.
>
>> The OS is the only place you can when the threads are in different
>> processes unknown to each other. Or, can two different processes share
>> the
>> same thread?
>
> No, never.  If there is a concurrency problem with the envionment, it's
> between threads of the same process.  In that case, we can make getenv,
> setenv and friends thread-safe, but it's still actually a problem of the
> application, given that getenv, setenv and friends are not thread-safe
> per POSIX.  See
> http://www.opengroup.org/onlinepubs/9699919799/functions/setenv.html
> http://www.opengroup.org/onlinepubs/9699919799/functions/getenv.html
> http://www.opengroup.org/onlinepubs/9699919799/functions/unsetenv.html
>

well, the question was somewhat rhetorical/disingenuous but
I don't see how in the general case then the OS can allow two
simultaneous processes to modify windoze env variables in a way
that corrupts them. The app is responsible for itself but I'm not sure
what it can do with respect to other processes. If you wanted an emulation
layer to be safe you are still limited by the OS( but you may have already
known that LOL).

>
> Corinna
>
> --
> Corinna Vinschen                  Please, send mails regarding Cygwin to
> Cygwin Project Co-Leader          cygwin AT cygwin DOT com
> Red Hat
>
> --
> Problem reports:       http://cygwin.com/problems.html
> FAQ:                   http://cygwin.com/faq/
> Documentation:         http://cygwin.com/docs.html
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
>
>


-- 

marchywka@gmail.com
Mike Marchywka
586 Saint James Walk
Marietta GA 30067-7165
415-264-8477 (w)<- use this
404-788-1216 (C)<- leave message
989-348-4796 (P)<- emergency only
marchywka@hotmail.com
Note: If I am asking for free stuff, I normally use for hobby/non-profit
information but may use in investment forums, public and private.
Please indicate any concerns if applicable.
Note: hotmail is censoring incoming mail using random criteria beyond
my control and often hangs my browser
but all my subscriptions are here..., try also marchywka@yahoo.com

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]