From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,d275ffeffdf83655 X-Google-Attributes: gid103376,public From: nabbasi@earthlink.net Subject: Re: Ada vs C++ vs Java Date: 1999/02/09 Message-ID: <79pn97$po8@drn.newsguy.com>#1/1 X-Deja-AN: 442480310 References: <369C1F31.AE5AF7EF@concentric.net> <369DDDC3.FDE09999@sea.ericsson.se> <369e309a.32671759@news.demon.co.uk> <77ledn$eu7$1@remarQ.com> <77pnqc$cgi$1@newnews.global.net.uk> <8p64spq5lo5.fsf@Eng.Sun.COM> <77t3ld$nou$1@nnrp1.dejanews.com> <79ce4s$lfq$1@nnrp1.dejanews.com> <79chc7$ko6@drn.newsguy.com> <79dodb$rhf$1@nnrp1.dejanews.com> <79jeos$bu4@bgtnsc01.worldnet.att.net> <79k65l$s0t@drn.newsguy.com> <79pdd1$3mj$1@nnrp1.dejanews.com> Organization: Newsguy News Service [http://www.newsguy.com] Newsgroups: comp.lang.ada Date: 1999-02-09T00:00:00+00:00 List-Id: In article <79pdd1$3mj$1@nnrp1.dejanews.com>, robert_dewar@my-dejanews.com says... > >I must say it is a big disappointment to us as Ada >implementors that the pthreads world is such a mess. There is also Windows threads, which is not pthreads. And this is another reason why using Ada, and Ada tasks would make life so much simpler, since the Ada run-time would take care of what threading is used on the platform. As for the issue that Rober Dewar raised about pthreads "standard" behaving differently on different platforms, I can give an example exactly to ilustrate this point. During recent port of some application that used pthreads: Calling sigtimedwait() from inside a signal handler. This worked Ok on Solaris (and few other platforms), when the code was ported to AIX, this introduced a subtle bug, where it turned that doing the above was not safe and did not work on AIX, and the code has to be changed so not to call sigtimedwait() when in a signal handler. Also, on AIX, sending a pthread_kill(SIGUSR2) to a thread who is in pthread_cond_wait() caused a problem, while on Solaris it seemed to work ok. These were not easy bugs to find and fix by the the developers, it took allot of time to fix. Using Ada and Ada tasks would have meant that this threaded code would have been more portable and since Ada gives a higher level of task abstraction and constructs, I would also say the design would have been easier to understand. But is any one in the commerical world listening? it does not seem so, people are still writing large complex applications in windows threads and in pthreads and in C and C++, and now also in Java threads. I became aware recently of a HUGE application being designed and developed now in some large finanical company that is heavlly threaded and real-time, and it is being done on NT and using window threads :( A smart person I would say, would use this well kept secret of Ada, and would go and build a better and more robust applications in Ada, and would not let any of the competition know that they used Ada, so that they would continue to waste their time and money as they wish. Why let the competition know about something that might be good for them if they used it? Nasser