This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: Coarray article for the upcoming GCC Summit.
- From: Janne Blomqvist <blomqvist dot janne at gmail dot com>
- To: longb at cray dot com
- Cc: MOENE Toon <toon dot moene at cnrm dot meteo dot fr>, fortran at gcc dot gnu dot org, j dot k dot reid at rl dot ac dot uk, dannagle at verizon dot net
- Date: Wed, 23 Apr 2008 23:01:27 +0300
- Subject: Re: Coarray article for the upcoming GCC Summit.
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:user-agent:mime-version:to:cc:subject:references:in-reply-to:content-type:content-transfer-encoding; bh=ShV88vCl0KMKSeI/HAzB2FyPHKbA3UndV2na/wZsoRs=; b=fVlXxvHwqiEGPIBwrfP0dsUc43K2ZQZcpqavrMo1C+VR2wA9Dd4ugW/yTPFInsdDGYxHL0OuQuh4lsuiYw1OcsKBhx1GEmF2ZM1dXtQ7Unlwnt7rmpZt31FgI7o/uaHtL5kSvvil/Hr5+r509rwnhdhllXKxFzb/8A/+W9NqdU8=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:cc:subject:references:in-reply-to:content-type:content-transfer-encoding; b=kKrvsWhfrgPKqkeG5iDPf+4iTFW0CfhRfozp6yQfL5z04ksG3TUXYwUOYb7n9b10OjEKm+2l6cLH83LCqZsxDf1T207tidOp3DmEMqvaZNM9po4CwN4+xe74oxxR+vns3o8scADsOw6UZVwXupqIQ0JYhmtg1y0QH5DQQ/mxRiM=
- References: <4809C31C.9080502@cnrm.meteo.fr> <480CC606.8090603@cray.com> <480F279E.9010908@cnrm.meteo.fr> <480F6834.50605@cray.com>
Bill Long wrote:
MOENE Toon wrote:
Is there some difficulty with coarrays here that I am overlooking ?
The Rice University group has had two problems in this area, though
neither affect our (Cray's) implementation. As background, our general
implementation of coarrays on our vector systems works like this:
Coarrays are placed in a separate "symmetric" heap that starts at the
same base address on each image and contains only coarrays. Because of
the restrictions on allocatable coarrays, it is always possible to store
coarrays such that the base address for a particular coarray is the same
on each image. This allows you to know the address of a remote coarray
reference using only the local address information for the same
coarray. For ordinary and allocatable coarrays this is pretty
straightforward, and Rice seems to have no problem addressing static
coarrays.
The second problem seems to have multiple names, one of which is
"pinning of memory" on the images. Even if you handle the symmetric heap
in some special way, the targets of pointer components and the actual
memory for allocatable components can be anywhere in the local memory of
each node. Some hardware DMA protocols evidently require that remotely
accessed memory has to be "registered" or "pinned" somehow so the
hardware in the network can access it. The Cray vector implementation
gets around this issue by doing two things: 1) we disable demand paging
on any node running a coarray (or UPC) image, and 2) we (effectively)
pin/register all of the physical memory on the node by using large pages
and remote address translation tables. This results in very good
performance, but is more restrictive than a generic implementation.
Considering that libraries like MPI need to get around this same issue,
I assume gfortran will have some solution available. But, I think it is
important to be aware of it from the start, and think about the best
solution when doing the basic design work.
This could be tricky, if we want something portable, performant and
robust (pick one, ha ha). Here's one article ranting about RDMA that got
quite a lot of press a few years ago:
http://www.hpcwire.com/hpc/815242.html
and the response
http://www.hpcwire.com/hpc/885757.html
I think the only sensible solution here would be to use some appropriate
abstraction layer like gasnet or armci. Do these also solve the first
problem you mention?
Is Cray planning to help out with coarray gfortran on portals? I suppose
most gfortran contributors have experience with programming and using
MPI applications, but MPP systems programming is somewhat outside our
experience. So I think any help in this are would be very welcome.
--
Janne Blomqvist