J3/04-132 Date: 16 Dec. 2003 To: J3 From: Dan Nagle Subject: Better Description of Memory- Sequence Pointers Processor speeds have increased to very much faster rates than memory speeds, compilers have improved to the point where most code sequences are nearly perfectly optimized. Separate compilation confounds "application compilers", pointers and targets complicate aliasing analysis. Therefore, more information regarding aliasing is essential for very high computational rates. The "Better Description of Memory" features attempt to define features which may provide this missing information to compilers. Since several features combine to do so, they are broken into individual papers for consideration. Title: Better Description of Memory- Sequence Pointers Submitted By: J3 Status: For Consideration References: Basic Functionality: Reduce copying by indicating when a pointer pointers to contiguous memory. Rationale: Compilers must generate copy operations when pointer arrays are passed to procedures expecting contiguous arrays. Copies have disastrous effects on performance on modern cache-based hardware. A sequence declaration allows the compiler to avoid copying. Estimated Impact: Compilers would have to recognize the SEQUENCE keyword in a new situation, and process the new attribute. Detailed Specification: Allow the programmer to declare when a pointer will point to only contiguous memory. Allow a SEQUENCE keyword on pointer declarations to declare that the pointer points to contiguous memory. Check during compilation when erroroneous declarations are made. real, pointer, sequence, dimension( ... ) :: pa ! targets of a pointer real, pointer, sequence, dimension(:) :: ptr real, target, dimension( n) :: t1 ! compiled: ptr => t1( 1: n) ! compiled not: ptr => t1( 1: n: 2) ! compiled: ptr => t1( 1: n: inc) ! if compiler can't see inc ! compiled not: ptr => t1( 1: n: inc) ! if compiler can see inc /= 1 History: