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.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!mx02.eternal-september.org!feeder.eternal-september.org!aioe.org!.POSTED!not-for-mail From: "Dmitry A. Kazakov" Newsgroups: comp.lang.ada Subject: Re: RFC: Prototype for a user threading library in Ada Date: Sat, 2 Jul 2016 15:18:44 +0200 Organization: Aioe.org NNTP Server Message-ID: References: <58b78af5-28d8-4029-8804-598b2b63013c@googlegroups.com> <1e32c714-34cf-4828-81fc-6b7fd77e4532@googlegroups.com> NNTP-Posting-Host: w/2xSGckQeJEFvqsQFNodA.user.gioia.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-Complaints-To: abuse@aioe.org User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 X-Notice: Filtered by postfilter v. 0.8.2 Xref: news.eternal-september.org comp.lang.ada:31005 Date: 2016-07-02T15:18:44+02:00 List-Id: On 2016-07-02 13:13, Hadrien Grasland wrote: > Le samedi 2 juillet 2016 06:36:09 UTC+2, Randy Brukardt a écrit : >> But I don't think that really helps the race and deadlock issues that are >> the real problem with programming with Ada tasks. I'd like to find some help >> there, too. > > Here's my view of this: people are heavily overusing shared mutable > data in multitasking programs, This is motivated by the hardware architecture of multi-cores with shared memory. > and that is the source of too many data > races, which in turn people attempt to fix with locks, thusly killing > their performance and introducing deadlocks. > > In many cases, better performance and correctness can be easily > achieved by moving to asynchronous tasking runtimes, where the runtime > internally manages an event-based dependency graph of tasks that can be > processed condurrently, and data is kept task-private but can be moved > around between tasks. Event-controlled architecture is exposed to generators (life-locks), and no less to dead-locks and race conditions. From the software developing POV it is far worse than shared memory architecture. The only advantage it has over the former that it can be truly scalable while shared memory is a bottle neck. -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de