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=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,292c095d622af1d0 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Received: by 10.68.125.201 with SMTP id ms9mr2777320pbb.3.1336298542733; Sun, 06 May 2012 03:02:22 -0700 (PDT) Path: pr3ni10177pbb.0!nntp.google.com!news2.google.com!news.glorb.com!feeder.erje.net!eternal-september.org!feeder.eternal-september.org!mx04.eternal-september.org!.POSTED!not-for-mail From: Simon Wright Newsgroups: comp.lang.ada Subject: Re: basic question on Ada tasks and running on different cores Date: Sun, 06 May 2012 11:02:22 +0100 Organization: A noiseless patient Spider Message-ID: References: Mime-Version: 1.0 Injection-Info: mx04.eternal-september.org; posting-host="wGnz5VUD6SAGzpXaqLQLYQ"; logging-data="28099"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19n+jlBYqQRQSh/GmBYhAcw3AgfCcuBRpE=" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.4 (darwin) Cancel-Lock: sha1:H6n1cWhVLplL8vHrd4vx0m+QLgw= sha1:ZIvr/93guei7MwHAY/sdG7vDxYY= Content-Type: text/plain; charset=us-ascii Date: 2012-05-06T11:02:22+01:00 List-Id: "Nasser M. Abbasi" writes: > If I use Ada, and create many, many tasks, will these tasks > automatically be scheduled to run on as many different cores as > possible so to spread the load and achieve the most parallelism > possible? > > Is this something that is controlled by Ada run-time automatically, or > is it the OS that that is in charge here with which task (i.e. thread) > runs on which core? > > Will the programmer have to do anything other than just creating the > tasks (and ofcourse protect any critical section as needed), but not > worry about the mapping of tasks to cores and all the other scheduling > issues. One imagines that Ada RTS's will offer the ability to map tasks to cores, building on the facilities offered by the OS's to specify processor affinities. Whether Ada 2020 will standardise an interface to this is to be determined! (ada-auth.org isn't responding at the moment, so I can't tell whether there's anything in Ada 2012).