[Beowulf] bizarre scaling behavior on a Nehalem
Many of your questions may have already been answered in earlier discussions or in the FAQ. The search results page will indicate current discussions as well as past list serves, articles, and papers.
Christian Bell christian at myri.comWed Aug 12 08:36:35 PDT 2009
- Previous message: [Beowulf] bizarre scaling behavior on a Nehalem
- Next message: [Beowulf] bizarre scaling behavior on a Nehalem
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Aug 12, 2009, at 11:14 AM, Bill Broadley wrote: > * For the compilers that tend to be better at stream (open64 and > pathscale), > you lose the performance if you just replace double a[],b[],c[] with > double *a,*b,*c. Patch[1] available. I don't have a work around for > this, suggestions welcome. Is it really necessary for dynamic arrays > to be substantially slower than static? Yes -- when pointers, the compiler assumes (by default) that the pointers can alias each other, which can prevent aggressive optimizations that are otherwise possible with arrays. C99 has introduced the 'restrict' keyword to allow programmers to assert that pointers of the same type cannot alias each other. However, restrict is just a hint and some compilers may or may not take advantage of it. You can also consult your compiler's documentation to see if there are other compiler-specific hints (asserting no loop-carried dependencies, loop fusion/fission). I remember stacking half a dozen pragmas over a 3-line loop on a Cray C compiler years ago to ensure that accesses where suitably optimized (or in this case, vectorized). . . christian
- Previous message: [Beowulf] bizarre scaling behavior on a Nehalem
- Next message: [Beowulf] bizarre scaling behavior on a Nehalem
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Beowulf mailing list
