||[CAF] uhcaf fix to handle different source formats and gasnet-everthing fix
This commit makes the following fixes:
* Fixes in uhcaf script to handle various source, IR, and object files.
* Forgot to init heap start address for everything config. The start address
of the local heap needs to be stored in the global variable
everything_heap_start, so that it may be accessed by other images on first
Patch level updated to 3.0.8.
||[CAF] Supports save coarrays + misc. fixes
The main change in this commit is added support for save coarrays. In order to
efficiently support remotely accessible save coarrays, they must be allocated
on the managed symmetric heap as allocatable coarrays are. This requires the
compiler to gather all save coarrays declared throughout the program and
allocate them on the heap at the start of the program. OpenUH now does this.
This commit also fixes a number of bugs:
* Fix for created LCB assignment statement during the coarray prelowering
* Fix for uhcaf return status and command line option parsing
* Fixes for handling OPR_CVT WHIRL nodes during coarray lowering phase.
* Fixes bug when writing a scalar value to a remote array section.
* Corrects the data type for a remote access within structured control flow
* Fixes dope vector temp variable created for calling a procedure with an
assumed shape coarray dummy argument. Specifically, the temp needed to be
declared with codimensions matching the dummy argument.
Also, increasing patch level to 3.0.7
||Revert previous open64 merge and change inline functions
This reverts the open64 merge r3774:3875, since it wasn't stable.
Also, changing some inline functions back to macros. The inline functions
caused the coarray lowering phase to crash when not building a debug compiler.
||adding missing files for previous open64 merge
||open64 merge r3774:3875
Adds many fixes and improvements made for Open64 5.0 release to OpenUH.
enabling of Nystrom alias analyzer for IPA phase
the siloed reference analysis to IPA phase,
x86-ppc32 cross compiler support,
Other enhancements include improve build where the default target architecture is
detected, and support for variable length arrays in structs. This commit
purposely does not include -r3876 from open64 main trunk, because OpenUH has
existing dependencies on PROMPF feature and that commit attempts to eliminate
See the open64 (main trunk) commit log for more details.
||[CAF] fix for handling statements with remote access on both sides
This fixes handling of statements where there is a coindexed reference on both
the LHS and RHS, of the form:
A(...)[p] = B(...)[q]
||[CAF] Improvements for strided accesses + more
This commit adds several improvements to the handling of strided coarray
accesses. Currently handled accesses fall into 3 categories:
(1) non-strided (or contiguous data) accesses
e.g. a(1:10) = b( 1:10, 5)[p]
b(1:10)[p] = a(1:10, 2)
(2) simple strided accesses (subscripts are not strided)
e.g. a(1:3, 1:5) = b(1:3, 6:10)[p]
b(2, 1:5)[p] = a(1:5)
(3) strided accesses with strided subscripts
e.g. a(5, 1:4) = b(1:8:2)[p]
b(1:10:2,1:4:2)[p] = a(1:5, 4:7:2)
It should now handle more general strided transfers without requiring the
extra LCB copy. Also, subscript extents need not match, so long as the array
shapes of the left and right sides are conforming. These are all accepted and
translated without needing to introduce an intermediate LCB buffer.
b(1:10, 5) = a(1, 1:10)
b(1, 2, 1:10:2) = a(1:5, 3)
b(1:10:2, 1, 1:4) = a(1:5, 1:8;2, 1)
Improvements are listed:
* runtime checks for contiguous accesses
* will convert strided access to contiguous access if the remote side is
contiguous while the local side is strided.
* compiler configure checks that gasnet-root path is valid
* compiler options can be specified for uhcaf just as with uhf90 (i.e. no need
to specify these options after -- )
* added --show-info option to uhcaf to get more informatoin about the default
compiler flags and the libraries linked in.
||[CAF] new coarray prelowering phase + misc fixes
This commit reorganizes the coarray prelowering phase in the back-end. It also
adds a number of fixes to the CAF implementation.
Prelowering has been split into 2 distinct phases. The first phase will
identify places in which an intermediate communication buffer should be
introduced to hold data to write out to read into and generate assignment
statements for this. The second phase will traverse the tree and replace
coindexed references with GET/PUT runtime calls.
Additionally, ths following fixes/enhancements are added:
* adding reduction routines for 1d arrays in libcaf-extra
* distinguish scalar from 1D arrays in libcaf-extra broadcast routines
* fixed link order for MPI libs in uhcaf script
* setting the num_codim field of the dope vector associated with coarray dummy
(patch level now at 3.0.6)
||[CAF] fix bug in copying command-line arguments for gasnet_init
When allocating buffer for command-line arg, it did not allocate the extra
byte for the terminating NULL character.
||support OpenUH build in Linux Mint distro
From Open64 commit log:
Open64 currently does not build from source on Linux Mint 12 due to this
distro using yet another layout for 64-bit libraries and objects.
The following change corrects the issue by adding another case to the
Note: If trying to execute a prebuilt OpenUH in Linux Mint, it may require
manully copying crt1.o, crti.o, and crtn.o from /usr/lib/x86_64-linux-gnu to
/usr/lib (and possibly /usr/lib64).
Contributor: David Coakley (AMD)
||[CAF] Fixes DV for allocatable scalar coarrays
This includes a fix for allocatable scalar coarrays ("coscalars"):
The dope vector for allocatable coscalars was not being initialized correctly
after recent change which did away with using the VAR_TMP_IDX for storing PE
bound information. The routine which generates the dope vector wasn't
correctly recognzing the existence of the cobounds in the declaration.
Also, for intrinsic functions which take in a coarray dope vector (e.g.
this_image), it was creating a temp dope vector for the actual argument. This
temp did not contain the cobounds information for coscalars. I modified this
so that it will instead use the original dope vector created for the coscalar.
When trying to determine the address on a remote image, we add the appropriate
offset only if it falls within the RMA heap. Coarrays that aren't in the heap
(e.g. save coarrays that have not been mapped into static coarray section of
heap) do not need an address adjustment so this check is added. Note,
accessing coarrays currently allocated outside the heap (e.g. save coarrays)
will not work unless using GASNet's everything segment configuration.
||adds macro __OPENUH__ which indicates version of OpenUH that is used.
||[CAF] changing ENABLE_TRACES to ENABLE_LIBCAF_TRACES
||[CAF] correcting uhcaf.in error for GASNET_CONDUITS
||[CAF] fix typo which caused seg fault for strided reads
||Misc. fixes for allocatable components
Allow allocatable components in derived types.
Technically, components with allocatable attribute should be allowed in
derived types even though in the initial Fortran 95 standard it wasn't. This
fixes some issues so that it will work in our compiler.
(1) set alignment to Pointer_size for derived types with allocatable component
(2) fix bug in constructing IR when there is an allocatable array section in a
This commit also fixes some issues with defining and allocating coarray
components of derived types.
- allow allocatable coscalar component in derived type
- support allocation of allocatable coarray components
- remove unnecessary code for storing PE bounds info in temps on allocate
Moreover, this commit fixes parsing of coarray-spec, ensuring that they are
either "explicit shape" or "deferred shape", as per Fortran 2008 standard.
||[CAF] various fixes for coscalars and libfortran bug
coscalar front-end fixes:
- allow local accesses on coscalars of derived type with pointer components
- fix size calculation for coscalar types
Also, in libfortran we were using the wrong function name for allocating data
in non-symmetric, remotely accessibly heap, resulting in a run-time error.
This was fixed.
||[CAF] Fixes file name DST info generated in wgen
If compiling a source code not in the current directory with -g, it couldn't
be stepped through in a debugger. It turns out that the DWARF symbol table
(DST) information for the file name was not appending the relative path. This
prevents the relative path from being stripped by wgen before writing out the
DST information. This fix enables us to build all the runtime libraries (e.g.
libfortran) with debug info.
- adds --keep option for uhcaf script
- increases patch level, now at 3.0.3
||[CAF] fix to allow use of uhcaf in makefiles
The uhcaf script will run the make command to determine the communication libs
from GASNet and ARMCI makefiles. If uhcaf is invoked from within another
makefile, the output of the nested makefile will include a printing of working
directory. To avoid this, we use --no-print-directory command in the script.
Also, there was a bug during coarray prelowering phase (undefined variable
ty1) that was fixed.
||increasing patch level, now at 3.0.1