comp.lang.ada
 help / color / mirror / Atom feed
* Linux or FreeBSD a better choice for threads/tasking?
@ 2001-03-30  2:36 Mike Silva
  2001-03-30  7:14 ` Christopher Green
                   ` (2 more replies)
  0 siblings, 3 replies; 25+ messages in thread
From: Mike Silva @ 2001-03-30  2:36 UTC (permalink / raw)


Is either of these OSes (on x86) the preferred choice based on completeness
and performance of their threading implementations?  I'm looking to improve
my skills at both raw POSIX threads programming and Ada task programming
(GNAT) and want to make the right OS choice, if there is one.  Thanks for
any comments.

Mike






^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-03-30  2:36 Linux or FreeBSD a better choice for threads/tasking? Mike Silva
@ 2001-03-30  7:14 ` Christopher Green
  2001-03-30  9:55   ` Hans-Olof Danielsson
  2001-03-30 12:28   ` David C. Hoos, Sr.
  2001-03-30 20:35 ` Stefan Skoglund
  2001-04-01 19:41 ` David Schwartz
  2 siblings, 2 replies; 25+ messages in thread
From: Christopher Green @ 2001-03-30  7:14 UTC (permalink / raw)


On Thu, 29 Mar 2001 18:36:16 -0800, "Mike Silva" <mjsilva@jps.net>
wrote:

>Is either of these OSes (on x86) the preferred choice based on completeness
>and performance of their threading implementations?  I'm looking to improve
>my skills at both raw POSIX threads programming and Ada task programming
>(GNAT) and want to make the right OS choice, if there is one.  Thanks for
>any comments.
>
>Mike

Linux has the more mature and stable threads implementation. GNAT on
Linux works directly with Linux threads. Go with Linux unless you must
have a BSD-ish Unix.

However, watch out for Linux 2.4 kernels; Linux threads were broken in
these kernels (at least as of last September). Linux kernel 2.2-based
distributions, such as RedHat 7.0, are fine.

-- 
Chris Green



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-03-30  7:14 ` Christopher Green
@ 2001-03-30  9:55   ` Hans-Olof Danielsson
  2001-03-30 12:28   ` David C. Hoos, Sr.
  1 sibling, 0 replies; 25+ messages in thread
From: Hans-Olof Danielsson @ 2001-03-30  9:55 UTC (permalink / raw)
  To: comp.lang.ada

"Christopher Green" <cj.green@worldnet.att.net> skriver:
> On Thu, 29 Mar 2001 18:36:16 -0800, "Mike Silva" <mjsilva@jps.net>
> wrote:
>
> >Is either of these OSes (on x86) the preferred choice based on
completeness
> >and performance of their threading implementations?  I'm looking to
improve
> >my skills at both raw POSIX threads programming and Ada task programming
> >(GNAT) and want to make the right OS choice, if there is one.  Thanks for
> >any comments.
> >
> >Mike
>
> Linux has the more mature and stable threads implementation. GNAT on
> Linux works directly with Linux threads. Go with Linux unless you must
> have a BSD-ish Unix.
>
> However, watch out for Linux 2.4 kernels; Linux threads were broken in
> these kernels (at least as of last September). Linux kernel 2.2-based
> distributions, such as RedHat 7.0, are fine.
>
> --
> Chris Green
>
To this can be added that an implementation of GNAT using Linux naitve
threads doesn't fully support Annex C & D of the Ada Reference Manual, as
the Linux threads are not fully in conformance with POSIX threads. There is
an alternative threading implementation from the Florida State University
(FSU) that fully support thouse two annexes.

Hans-Olof









^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-03-30  7:14 ` Christopher Green
  2001-03-30  9:55   ` Hans-Olof Danielsson
@ 2001-03-30 12:28   ` David C. Hoos, Sr.
  1 sibling, 0 replies; 25+ messages in thread
From: David C. Hoos, Sr. @ 2001-03-30 12:28 UTC (permalink / raw)


To be fair, the 2.4 kernels before Jan 4, 2001 were not released kernels,
but test kernels.

We've been using the 2.4.1 kernel with a pair of gnat applications, of
which one has 23 threads, and the other 11 threads.

We had been using 2.2.16, but switched because 2.4 kernels
provide a generic SCSI driver which in the 2.2.16 kernel needed to
be replaced with another driver, making that kernel source tree
non-standard.

We found that the 2.4.1 kernel, beside being able to be used in
"standard" source tree form provided improved memory
management, and exhibited no negative attributes relative to 2.2.16.

"Christopher Green" <cj.green@worldnet.att.net> wrote in message
news:3ac426a6.736068@netnews.att.net...
> On Thu, 29 Mar 2001 18:36:16 -0800, "Mike Silva" <mjsilva@jps.net>
> wrote:
>
> >Is either of these OSes (on x86) the preferred choice based on
completeness
> >and performance of their threading implementations?  I'm looking to
improve
> >my skills at both raw POSIX threads programming and Ada task programming
> >(GNAT) and want to make the right OS choice, if there is one.  Thanks for
> >any comments.
> >
> >Mike
>
> Linux has the more mature and stable threads implementation. GNAT on
> Linux works directly with Linux threads. Go with Linux unless you must
> have a BSD-ish Unix.
>
> However, watch out for Linux 2.4 kernels; Linux threads were broken in
> these kernels (at least as of last September). Linux kernel 2.2-based
> distributions, such as RedHat 7.0, are fine.
>
> --
> Chris Green





^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-03-30  2:36 Linux or FreeBSD a better choice for threads/tasking? Mike Silva
  2001-03-30  7:14 ` Christopher Green
@ 2001-03-30 20:35 ` Stefan Skoglund
  2001-04-01  7:03   ` Arthur H. Gold
  2001-04-01 16:53   ` Patrick TJ McPhee
  2001-04-01 19:41 ` David Schwartz
  2 siblings, 2 replies; 25+ messages in thread
From: Stefan Skoglund @ 2001-03-30 20:35 UTC (permalink / raw)


Mike Silva wrote:
> and performance of their threading implementations?  I'm looking to improve
> my skills at both raw POSIX threads programming and Ada task programming
> (GNAT) and want to make the right OS choice, if there is one.  Thanks for

Personally i think that the thread model in Linux sucks.


The one in Solaris is much better.
Solaris has OS supported sync of threads in the same task.
You can create a mutex which works correctly between threads in the
same task. Linux DOESN't support that.





^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-03-30 20:35 ` Stefan Skoglund
@ 2001-04-01  7:03   ` Arthur H. Gold
  2001-04-01 16:53   ` Patrick TJ McPhee
  1 sibling, 0 replies; 25+ messages in thread
From: Arthur H. Gold @ 2001-04-01  7:03 UTC (permalink / raw)


Stefan Skoglund wrote:
> 
> Mike Silva wrote:
> > and performance of their threading implementations?  I'm looking to improve
> > my skills at both raw POSIX threads programming and Ada task programming
> > (GNAT) and want to make the right OS choice, if there is one.  Thanks for
> 
> Personally i think that the thread model in Linux sucks.

OK. Why? (outside of the non-standard signal delivery
semantics)
> 
> The one in Solaris is much better.
> Solaris has OS supported sync of threads in the same task.
> You can create a mutex which works correctly between threads in the
> same task. Linux DOESN't support that.
Huh? Would you be kind enough to explain this?

Thanks,
--ag

-- 
Artie Gold, Austin, TX  (finger the cs.utexas.edu account
for more info)
mailto:agold@bga.com or mailto:agold@cs.utexas.edu
--
Clone Bernie!



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-03-30 20:35 ` Stefan Skoglund
  2001-04-01  7:03   ` Arthur H. Gold
@ 2001-04-01 16:53   ` Patrick TJ McPhee
  2001-04-03 12:08     ` Florian Weimer
  1 sibling, 1 reply; 25+ messages in thread
From: Patrick TJ McPhee @ 2001-04-01 16:53 UTC (permalink / raw)


In article <3AC4EE29.424057F6@ebox.tninet.se>,
Stefan Skoglund  <stetson@ebox.tninet.se> wrote:

% Solaris has OS supported sync of threads in the same task.
% You can create a mutex which works correctly between threads in the
% same task. Linux DOESN't support that.

This is simply untrue. The only serious problem with the Linux thread
model is that each thread is assigned its own process id, contrary to
standards and common sense.
--

Patrick TJ McPhee
East York  Canada
ptjm@interlog.com



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-03-30  2:36 Linux or FreeBSD a better choice for threads/tasking? Mike Silva
  2001-03-30  7:14 ` Christopher Green
  2001-03-30 20:35 ` Stefan Skoglund
@ 2001-04-01 19:41 ` David Schwartz
  2001-04-01 19:57   ` Dima Volodin
  2 siblings, 1 reply; 25+ messages in thread
From: David Schwartz @ 2001-04-01 19:41 UTC (permalink / raw)



Mike Silva wrote:
> Is either of these OSes (on x86) the preferred choice based on completeness
> and performance of their threading implementations?  I'm looking to improve
> my skills at both raw POSIX threads programming and Ada task programming
> (GNAT) and want to make the right OS choice, if there is one.  Thanks for
> any comments.
> 
> Mike

	In my experience, multithreaded programs running agressively on FreeBSD
inevitably crash. The Linux threading model is much stabler. I've tried
both FreeBSD's libc_r and the port of LinuxThreads.

	DS



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-04-01 19:41 ` David Schwartz
@ 2001-04-01 19:57   ` Dima Volodin
  2001-04-02  1:26     ` David Schwartz
  2001-04-02 16:17     ` Sander Pilon
  0 siblings, 2 replies; 25+ messages in thread
From: Dima Volodin @ 2001-04-01 19:57 UTC (permalink / raw)


David Schwartz wrote:
> 
> Mike Silva wrote:
> > Is either of these OSes (on x86) the preferred choice based on completeness
> > and performance of their threading implementations?  I'm looking to improve
> > my skills at both raw POSIX threads programming and Ada task programming
> > (GNAT) and want to make the right OS choice, if there is one.  Thanks for
> > any comments.
> >
> > Mike
> 
>         In my experience, multithreaded programs running agressively on FreeBSD
> inevitably crash. The Linux threading model is much stabler. I've tried
> both FreeBSD's libc_r and the port of LinuxThreads.

What does it mean "running aggressively"? I have a multithreaded program
that runs on a 3.5-STABLE FreeBSD box for weeks at a time without
crashing at all. Am I not aggressive enough?

>         DS

Dima



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-04-01 19:57   ` Dima Volodin
@ 2001-04-02  1:26     ` David Schwartz
  2001-04-02 17:39       ` Dima Volodin
  2001-04-02 16:17     ` Sander Pilon
  1 sibling, 1 reply; 25+ messages in thread
From: David Schwartz @ 2001-04-02  1:26 UTC (permalink / raw)




Dima Volodin wrote:

> >         In my experience, multithreaded programs running agressively on FreeBSD
> > inevitably crash. The Linux threading model is much stabler. I've tried
> > both FreeBSD's libc_r and the port of LinuxThreads.

> What does it mean "running aggressively"? I have a multithreaded program
> that runs on a 3.5-STABLE FreeBSD box for weeks at a time without
> crashing at all. Am I not aggressive enough?

	By "running agressively" I mean performing a large number of tasks,
stressing all aspects of the system (especially vm and networking), on
an SMP machine.

	DS



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-04-01 19:57   ` Dima Volodin
  2001-04-02  1:26     ` David Schwartz
@ 2001-04-02 16:17     ` Sander Pilon
       [not found]       ` <3AC8B9DD.134B6562@dvv.org>
  1 sibling, 1 reply; 25+ messages in thread
From: Sander Pilon @ 2001-04-02 16:17 UTC (permalink / raw)



"Dima Volodin" <dvv@dvv.org> wrote in message
news:3AC7880C.24EE5D01@dvv.org...
> David Schwartz wrote:
> >
> > Mike Silva wrote:
> > > Is either of these OSes (on x86) the preferred choice based on
completeness
> > > and performance of their threading implementations?  I'm looking to
improve
> > > my skills at both raw POSIX threads programming and Ada task
programming
> > > (GNAT) and want to make the right OS choice, if there is one.  Thanks
for
> > > any comments.
> > >
> > > Mike
> >
> >         In my experience, multithreaded programs running agressively on
FreeBSD
> > inevitably crash. The Linux threading model is much stabler. I've tried
> > both FreeBSD's libc_r and the port of LinuxThreads.
>
> What does it mean "running aggressively"? I have a multithreaded program
> that runs on a 3.5-STABLE FreeBSD box for weeks at a time without
> crashing at all. Am I not aggressive enough?
>

Probably not.

I've got a application that uses threads (25 of them), and on linux it can
run for hours and hours without crashing, and on freebsd 4.2-stable it goes
down with buserrors or segfaults in minutes. ( we're developing it, so
"weeks" is not yet an option :)







^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-04-02  1:26     ` David Schwartz
@ 2001-04-02 17:39       ` Dima Volodin
  2001-04-03 11:36         ` Matthias Kretschmer
  0 siblings, 1 reply; 25+ messages in thread
From: Dima Volodin @ 2001-04-02 17:39 UTC (permalink / raw)


David Schwartz wrote:

> Dima Volodin wrote:
>
> > >         In my experience, multithreaded programs running agressively on FreeBSD
> > > inevitably crash. The Linux threading model is much stabler. I've tried
> > > both FreeBSD's libc_r and the port of LinuxThreads.
>
> > What does it mean "running aggressively"? I have a multithreaded program
> > that runs on a 3.5-STABLE FreeBSD box for weeks at a time without
> > crashing at all. Am I not aggressive enough?
>
>         By "running agressively" I mean performing a large number of tasks,
> stressing all aspects of the system (especially vm and networking), on
> an SMP machine.

Could you throw in some numbers here, please?

>         DS

Dima

^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
       [not found]       ` <3AC8B9DD.134B6562@dvv.org>
@ 2001-04-02 19:21         ` Marin David Condic
       [not found]           ` <3AC8DDA0.D4DF412B@dvv.org>
  2001-04-02 21:41         ` Sander Pilon
  1 sibling, 1 reply; 25+ messages in thread
From: Marin David Condic @ 2001-04-02 19:21 UTC (permalink / raw)


That's a little unfair. Multithreaded applications are sensitive to all
sorts of things that may have little or nothing to do with how well or badly
they are written. If the underlying OS is unstable & you can't count on the
primitives to work, you're hosed. If the application is sensitive to timing
and you don't have proper underlying hardware, you're hosed. Unless your
multithreaded app is trivial, you can always have problems in porting it no
matter what you do with the design.

MDC

--
Marin David Condic
Senior Software Engineer
Pace Micro Technology Americas    www.pacemicro.com
Enabling the digital revolution
e-Mail:    marin.condic@pacemicro.com
Web:      http://www.mcondic.com/


"Dima Volodin" <dvv@dvv.org> wrote in message
news:3AC8B9DD.134B6562@dvv.org...
> That's what sloppy written multithreaded applications do - they produce
> expected results in one environment and crash like mad in others. Not that
I'm
> saying that your application belongs to this class.
>






^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
       [not found]       ` <3AC8B9DD.134B6562@dvv.org>
  2001-04-02 19:21         ` Marin David Condic
@ 2001-04-02 21:41         ` Sander Pilon
  1 sibling, 0 replies; 25+ messages in thread
From: Sander Pilon @ 2001-04-02 21:41 UTC (permalink / raw)



"Dima Volodin" <dvv@dvv.org> wrote in message
news:3AC8B9DD.134B6562@dvv.org...
> Sander Pilon wrote:
>
> > "Dima Volodin" <dvv@dvv.org> wrote in message
> > news:3AC7880C.24EE5D01@dvv.org...
> > > What does it mean "running aggressively"? I have a multithreaded
program
> > > that runs on a 3.5-STABLE FreeBSD box for weeks at a time without
> > > crashing at all. Am I not aggressive enough?
> > >
> >
> > Probably not.
> >
> > I've got a application that uses threads (25 of them), and on linux it
can
> > run for hours and hours without crashing, and on freebsd 4.2-stable it
goes
> > down with buserrors or segfaults in minutes. ( we're developing it, so
> > "weeks" is not yet an option :)
>
> That's what sloppy written multithreaded applications do - they produce
> expected results in one environment and crash like mad in others. Not that
I'm
> saying that your application belongs to this class.
>

Yes I know. But we might as well be debugging the sloppy freebsd threads
implementation or the poor state of the c++ stl library of gcc.

I just wish we had some decent debugging tools with supports for threads....

-S





^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-04-02 17:39       ` Dima Volodin
@ 2001-04-03 11:36         ` Matthias Kretschmer
  2001-04-03 11:40           ` Matthias Kretschmer
  0 siblings, 1 reply; 25+ messages in thread
From: Matthias Kretschmer @ 2001-04-03 11:36 UTC (permalink / raw)




Dima Volodin wrote:

> David Schwartz wrote:
>
> > Dima Volodin wrote:
> >
> > > >         In my experience, multithreaded programs running agressively on FreeBSD
> > > > inevitably crash. The Linux threading model is much stabler. I've tried
> > > > both FreeBSD's libc_r and the port of LinuxThreads.
> >
> > > What does it mean "running aggressively"? I have a multithreaded program
> > > that runs on a 3.5-STABLE FreeBSD box for weeks at a time without
> > > crashing at all. Am I not aggressive enough?
> >
> >         By "running agressively" I mean performing a large number of tasks,
> > stressing all aspects of the system (especially vm and networking), on
> > an SMP machine.
>
> Could you throw in some numbers here, please?
>

I had never problems with FreeBSD 3.4 and 4.1-stable running on my dual PII box -
performed very well, even with a large load, which bloated my linux-2.2 - linux-2.4 is
much better, but the SMP code of freebsd 4-branch is definatevly faster than linux-2.4 in
my experience around 5% - so you have to benchmark a lot to see the differences :-) - My
box never hung with high load nor with low ... And I had it running for some time now ...

>
> >         DS
>
> Dima




^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-04-03 11:36         ` Matthias Kretschmer
@ 2001-04-03 11:40           ` Matthias Kretschmer
  0 siblings, 0 replies; 25+ messages in thread
From: Matthias Kretschmer @ 2001-04-03 11:40 UTC (permalink / raw)




Matthias Kretschmer schrieb:

> Dima Volodin wrote:
>
> > David Schwartz wrote:
> >
> > > Dima Volodin wrote:
> > >
> > > > >         In my experience, multithreaded programs running agressively on FreeBSD
> > > > > inevitably crash. The Linux threading model is much stabler. I've tried
> > > > > both FreeBSD's libc_r and the port of LinuxThreads.
> > >
> > > > What does it mean "running aggressively"? I have a multithreaded program
> > > > that runs on a 3.5-STABLE FreeBSD box for weeks at a time without
> > > > crashing at all. Am I not aggressive enough?
> > >
> > >         By "running agressively" I mean performing a large number of tasks,
> > > stressing all aspects of the system (especially vm and networking), on
> > > an SMP machine.
> >
> > Could you throw in some numbers here, please?
> >
>
> I had never problems with FreeBSD 3.4 and 4.1-stable running on my dual PII box -
> performed very well, even with a large load, which bloated my linux-2.2 - linux-2.4 is
> much better, but the SMP code of freebsd 4-branch is definatevly faster than linux-2.4 in
> my experience around 5% - so you have to benchmark a lot to see the differences :-) - My
> box never hung with high load nor with low ... And I had it running for some time now ...
>

forgot to say: do not use FreeBSD if you need gnat and wants to compile it out of the
ports-collection - this is true for the binary package lying on ftp.freebsd.org at the
beginning of this year ... - the gnat doesn't use native thread implementation, but instead
simulates threads and uses non-preemptive threads instead. 1. It doesn't support SMP
environments. 2. Non-preemptive sucks :-) - I myself switched OS, because I was too lazy to
get gnat properly working, if someone has some patches/binaries, please mail me.

>
> >
> > >         DS
> >
> > Dima




^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-04-01 16:53   ` Patrick TJ McPhee
@ 2001-04-03 12:08     ` Florian Weimer
  2001-04-03 18:25       ` Arthur H. Gold
  2001-04-04  3:22       ` Patrick TJ McPhee
  0 siblings, 2 replies; 25+ messages in thread
From: Florian Weimer @ 2001-04-03 12:08 UTC (permalink / raw)


ptjm@interlog.com (Patrick TJ McPhee) writes:

> % Solaris has OS supported sync of threads in the same task.
> % You can create a mutex which works correctly between threads in the
> % same task. Linux DOESN't support that.
> 
> This is simply untrue. The only serious problem with the Linux thread
> model is that each thread is assigned its own process id, contrary to
> standards and common sense.

IMHO, the Linux model makes signal delivery much more transparent.



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-04-03 12:08     ` Florian Weimer
@ 2001-04-03 18:25       ` Arthur H. Gold
  2001-04-03 18:41         ` David Schwartz
  2001-04-04  3:22       ` Patrick TJ McPhee
  1 sibling, 1 reply; 25+ messages in thread
From: Arthur H. Gold @ 2001-04-03 18:25 UTC (permalink / raw)


Florian Weimer wrote:
> 
> ptjm@interlog.com (Patrick TJ McPhee) writes:
> 
> > % Solaris has OS supported sync of threads in the same task.
> > % You can create a mutex which works correctly between threads in the
> > % same task. Linux DOESN't support that.
> >
> > This is simply untrue. The only serious problem with the Linux thread
> > model is that each thread is assigned its own process id, contrary to
> > standards and common sense.
> 
> IMHO, the Linux model makes signal delivery much more transparent.
No argument there; the only problem is that in this respect
linuxthreads contravenes the POSIX standard for threads,
resulting in portability problems.

--ag
-- 
Artie Gold, Austin, TX  (finger the cs.utexas.edu account
for more info)
mailto:agold@bga.com or mailto:agold@cs.utexas.edu
--
Clone Bernie!



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-04-03 18:25       ` Arthur H. Gold
@ 2001-04-03 18:41         ` David Schwartz
  2001-04-03 19:41           ` Florian Weimer
  2001-04-04  7:28           ` igor
  0 siblings, 2 replies; 25+ messages in thread
From: David Schwartz @ 2001-04-03 18:41 UTC (permalink / raw)




"Arthur H. Gold" wrote:

> No argument there; the only problem is that in this respect
> linuxthreads contravenes the POSIX standard for threads,
> resulting in portability problems.

	It's not that terribly difficult to avoid using signals in a
multithreaded program. This is one of the many cases where the standard
is lacking. 'set[re]uid' is another.

	DS



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-04-03 18:41         ` David Schwartz
@ 2001-04-03 19:41           ` Florian Weimer
  2001-04-04  7:28           ` igor
  1 sibling, 0 replies; 25+ messages in thread
From: Florian Weimer @ 2001-04-03 19:41 UTC (permalink / raw)


David Schwartz <davids@webmaster.com> writes:

> "Arthur H. Gold" wrote:
> 
> > No argument there; the only problem is that in this respect
> > linuxthreads contravenes the POSIX standard for threads,
> > resulting in portability problems.

If the standard is broken, there is some reason not to follow it.  For
example, when you implement a garbage collector and use some VM
feature to track data modification, it's probably a good idea if
SIGSEGV is sent to the thread which generated the signal.  Does the
standard mandate this?

> 	It's not that terribly difficult to avoid using signals in a
> multithreaded program. This is one of the many cases where the standard
> is lacking. 'set[re]uid' is another.

And symbolic links.



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
       [not found]           ` <3AC8DDA0.D4DF412B@dvv.org>
@ 2001-04-03 20:48             ` Dima Volodin
       [not found]             ` <x7v66gn2gfy.fsf@smaug.pushface.org>
  1 sibling, 0 replies; 25+ messages in thread
From: Dima Volodin @ 2001-04-03 20:48 UTC (permalink / raw)


Marin David Condic wrote:

> That's a little unfair. Multithreaded applications are sensitive to all
> sorts of things that may have little or nothing to do with how well or badly
> they are written. If the underlying OS is unstable & you can't count on the
> primitives to work, you're hosed.

That's understandable, but it's just as unfair to claim an OS is
unstable
providing your application's unstable behaviour as a proof of it.

> If the application is sensitive to timing
> and you don't have proper underlying hardware, you're hosed.

If your application _has_ to be time-sensitive, then no question about
it -
you've got to choose a hardware/OS combo that fits your real-time needs.
Otherwise, when there is no tight timing requirements, and your
application is
still timing-dependent, you're hosed thanks to the poor design and/or
implementation of your app.

> Unless your
> multithreaded app is trivial, you can always have problems in porting it no
> matter what you do with the design.

Or so it might seem. The whole point in pedantically systematic approach
to
threads programming and programming in general is to minimize platform
dependency to the absolutely necessary minimum and it works for me most
of the
time.

> MDC

Dima



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
       [not found]             ` <x7v66gn2gfy.fsf@smaug.pushface.org>
@ 2001-04-03 20:55               ` Dima Volodin
  2001-04-10  6:32                 ` Simon Wright
  0 siblings, 1 reply; 25+ messages in thread
From: Dima Volodin @ 2001-04-03 20:55 UTC (permalink / raw)


Simon Wright wrote:
> 
> Dima Volodin <dvv@dvv.org> writes:
> 
> > TWFyaW4gRGF2aWQgQ29uZGljIHdyb3RlOg0KDQo+IFRoYXQncyBhIGxpdHRsZSB1bmZhaXIu
> > IE11bHRpdGhyZWFkZWQgYXBwbGljYXRpb25zIGFyZSBzZW5zaXRpdmUgdG8gYWxsDQo+IHNv
> > [...]
> Huh? could you perhaps try posting in English? (have you got MIME
> enabled somewhere, perhaps?)

It is in English using perfectly legit base64, which is an intrinsic
feature of Mozilla 4.76 [en] (X11; U; SunOS 5.7 i86pc), and you cannot
really control it with any check boxes or settings in preferences.js.
And I've heard it's very easy to decode base64 (or anything) in Emacs.
Have I heard wrong?

Anyway, the plain text version of the same posting is out in the
newsgroups, see msg <3ACA370E.899C3546@dvv.org>


Dima



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-04-03 12:08     ` Florian Weimer
  2001-04-03 18:25       ` Arthur H. Gold
@ 2001-04-04  3:22       ` Patrick TJ McPhee
  1 sibling, 0 replies; 25+ messages in thread
From: Patrick TJ McPhee @ 2001-04-04  3:22 UTC (permalink / raw)


In article <871yranq1w.fsf@deneb.enyo.de>,
Florian Weimer  <fw@deneb.enyo.de> wrote:
% ptjm@interlog.com (Patrick TJ McPhee) writes:
% 
% > % Solaris has OS supported sync of threads in the same task.
% > % You can create a mutex which works correctly between threads in the
% > % same task. Linux DOESN't support that.
% > 
% > This is simply untrue. The only serious problem with the Linux thread
% > model is that each thread is assigned its own process id, contrary to
% > standards and common sense.
% 
% IMHO, the Linux model makes signal delivery much more transparent.

Fine, it is still contrary to standards and common sense for a process
to have n process IDs, where n is some number > 1, and it can be a
serious problem if you want to use either process IDs or signals
portably.

--

Patrick TJ McPhee
East York  Canada
ptjm@interlog.com



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-04-03 18:41         ` David Schwartz
  2001-04-03 19:41           ` Florian Weimer
@ 2001-04-04  7:28           ` igor
  1 sibling, 0 replies; 25+ messages in thread
From: igor @ 2001-04-04  7:28 UTC (permalink / raw)


In comp.programming.threads David Schwartz <davids@webmaster.com> wrote:
> 
> 
> "Arthur H. Gold" wrote:
> 
>> No argument there; the only problem is that in this respect
>> linuxthreads contravenes the POSIX standard for threads,
>> resulting in portability problems.
> 
> 	It's not that terribly difficult to avoid using signals in a
> multithreaded program. This is one of the many cases where the standard
> is lacking. 'set[re]uid' is another.
> 

Exactly. And one more, if my memory serve me correctly: with linuxthreads
pthread_attr_setstackaddr kill programm. Maybe this is fixed in new releases.

-- 
Igor Khasilev	                  |
PACO Links, igor at paco dot net  |



^ permalink raw reply	[flat|nested] 25+ messages in thread

* Re: Linux or FreeBSD a better choice for threads/tasking?
  2001-04-03 20:55               ` Dima Volodin
@ 2001-04-10  6:32                 ` Simon Wright
  0 siblings, 0 replies; 25+ messages in thread
From: Simon Wright @ 2001-04-10  6:32 UTC (permalink / raw)


Dima Volodin <dvv@dvv.org> writes:

> Simon Wright wrote:
> > 
> > Dima Volodin <dvv@dvv.org> writes:
> > 
> > > TWFyaW4gRGF2aWQgQ29uZGljIHdyb3RlOg0KDQo+IFRoYXQncyBhIGxpdHRsZSB1bmZhaXIu
> > > IE11bHRpdGhyZWFkZWQgYXBwbGljYXRpb25zIGFyZSBzZW5zaXRpdmUgdG8gYWxsDQo+IHNv
> > > [...]
> > Huh? could you perhaps try posting in English? (have you got MIME
> > enabled somewhere, perhaps?)
> 
> It is in English using perfectly legit base64, which is an intrinsic
> feature of Mozilla 4.76 [en] (X11; U; SunOS 5.7 i86pc), and you cannot
> really control it with any check boxes or settings in preferences.js.
> And I've heard it's very easy to decode base64 (or anything) in Emacs.
> Have I heard wrong?

Well - C-x o C-x h M-| metamail RET does decode it, but the much more
likely response is to hit n (=> "I can't be bothered to read this,
next posting please")



^ permalink raw reply	[flat|nested] 25+ messages in thread

end of thread, other threads:[~2001-04-10  6:32 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-03-30  2:36 Linux or FreeBSD a better choice for threads/tasking? Mike Silva
2001-03-30  7:14 ` Christopher Green
2001-03-30  9:55   ` Hans-Olof Danielsson
2001-03-30 12:28   ` David C. Hoos, Sr.
2001-03-30 20:35 ` Stefan Skoglund
2001-04-01  7:03   ` Arthur H. Gold
2001-04-01 16:53   ` Patrick TJ McPhee
2001-04-03 12:08     ` Florian Weimer
2001-04-03 18:25       ` Arthur H. Gold
2001-04-03 18:41         ` David Schwartz
2001-04-03 19:41           ` Florian Weimer
2001-04-04  7:28           ` igor
2001-04-04  3:22       ` Patrick TJ McPhee
2001-04-01 19:41 ` David Schwartz
2001-04-01 19:57   ` Dima Volodin
2001-04-02  1:26     ` David Schwartz
2001-04-02 17:39       ` Dima Volodin
2001-04-03 11:36         ` Matthias Kretschmer
2001-04-03 11:40           ` Matthias Kretschmer
2001-04-02 16:17     ` Sander Pilon
     [not found]       ` <3AC8B9DD.134B6562@dvv.org>
2001-04-02 19:21         ` Marin David Condic
     [not found]           ` <3AC8DDA0.D4DF412B@dvv.org>
2001-04-03 20:48             ` Dima Volodin
     [not found]             ` <x7v66gn2gfy.fsf@smaug.pushface.org>
2001-04-03 20:55               ` Dima Volodin
2001-04-10  6:32                 ` Simon Wright
2001-04-02 21:41         ` Sander Pilon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox