× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



I would tend to think that was true, but that would also mean that variables in 
a DS could be possibly accessed slower by the machine than one not.

The reason being that the variables are not aligned, and so the system must do 
two memory reads and some finagling instead of one to get the same variable.

Unless, on the other hand, the variables are still stored with alignment and 
the compiler does some finagling to make it appear to us as if they were 
contiguous.

I would tend to think the first case would apply, since there would have to be 
a heck of a lot of manipulation behind the scenes to make our pointer math work 
out.

Regards,

Jim Langston

-----Original Message-----
From: Barbara Morris [mailto:bmorris@ca.ibm.com]

Hans Boldt wrote:
>
> How much space is being wasted?  Taking alignment considerations
> into account, the overhead on average is probably just a couple of
> bytes per standalone field or data structure.
>

In case Hans' statement is alarming, alignment only applies to fields
that have alignment considerations (*, I, U, F types).  And the system
does seem to align data structures.

But it seems to me that forcing fields to be contiguous by coding them
in a data structure would tend to conserve storage, not waste it.


As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.