Re: Operations on derived type arrays

"I get the impression that Richard is talking a bit past you." Most of the
information I read about is several bytes passed me but I am progressing up
the learning curve and appreciate the time people spent responding to
I'll look into SUN C SPEC CPU2000. I was interested in your comment about
arrays of structures versus structure of arrays. In my case, I need to
access all the elements of myArray (declared within a module) and USED
within many subroutines. I have no need to pass just myArray%x for example.
I didn't think that how myArray got passed to mySub was that important or if
copies were needed as compared to the many vector operations I need to
perform on the individual elements. My question was really about how memory
layout affects performance. All the elements of myArray are individual
vectors of myType x,y,z. Is an operation on myArray%x as efficient as an
operation on a vector x? I assume that myArray%x is not contiguous whereas
vector x is. So can I expect performance to be better if I pass the
individual vectors x,y,x compared to an array of defined types containing
the components x, y, z? Sorry for the confusion; just trying to use the
right terminology to get the question defined.


Relevant Pages

  • Can you dynamically resize an array?
    ... What do you do when you're dealing with arrays whose size you ... myarray: arrayof integer; ... myinteger, errx: integer; ... clear on how to automatically resize those either. ...
  • Re: Dim MyArray vs. Dim MyArray()
    ... from the errors thrown above it seems abundantly clear that the two ... > MyArray2are true Variant() arrays and not Variant variables ... > containing arrays (if they were the latter, then, as demonstrated above, ... Dim myArray() ...
  • Re: debugging code (was Re: semicolon adding nops?)
    ... should have about how to actually look at the data from arrays? ... see is isa, class, superclass, and all that stuff. ... can say, while stopped at a breakpoint, in the debugging console window: ... po [myArray objectAtIndex:3] ...
  • Re: Altering Array Sizes within Functions
    ... > Im having trouble with arrays ... > The function modifies the size and elements of myArray. ...