[Info-vax] SAMBA really sloooow on OVMS Integrity. Any Ideas????

VAXman- at SendSpamHere.ORG VAXman- at SendSpamHere.ORG
Wed Aug 18 16:00:29 EDT 2010


In article <ebqdndZbSPxxrPHRnZ2dnUVZ_umdnZ2d at giganews.com>, "Richard B. Gilbert" <rgilbert88 at comcast.net> writes:
>Bob Koehler wrote:
>> In article <b10eda82-8d64-428b-805b-71ccd0ca40e9 at x20g2000pro.googlegroups.com>, Len Whitwer <len at psds.com> writes:
>>> We build from Samba download on HP's site. (What is an alignment fault
>>> and how can I tell if we are getting them?)
>> 
>>    An alignment fault happens when you access an address that is not
>>    an even multiple of the data size.  When a compiler can see that
>>    you're going to do this, it should generate the necessary code
>>    to access the surrounding larger data size and then strip off the
>>    desired data.  When a compiler can't see this, or if the compiler
>>    just isn't that robust, the instruction that accesses the data will
>>    cause an alignment fault, which will get trapped, the data fetch
>>    will be fixed up, and then the fault dismissed.  This takes longer
>>    than just fixing up the access in the first place.
>> 
>>    Sometimes code must interface to external data streams that are
>>    defined in poorly aligned manners.  Internal data stores should
>>    always be allowed to be aligned (compilers like to do that for you).
>> 
>>    The best way to access a poorly alined external data stream is to
>>    grab the whole thing, then code the movement from an unaligned to
>>    an aligned copy (or back) in such a manner as not to create alignment
>>    faults.
>> 
>>    There are tools in VMS to monitor alignment faults, but I've never
>>    used them so someone else will have to chime in here.
>> 
>
>Usually, alignment errors have to be forced or something like that.  The 
>compilers will align everything properly unless the programmer 
>deliberately creates a data structure with non-aligned components. 

It's far easier than you think!!!


>There may, occasionally, be good reason to do something like this but I 
>can't think of one and I think best practice is to avoid it like the plague!

I can.

-- 
VAXman- A Bored Certified VMS Kernel Mode Hacker    VAXman(at)TMESIS(dot)ORG

All your spirit rack abuses, come to haunt you back by day.
All your Byzantine excuses, given time, given you away.



More information about the Info-vax mailing list