[Info-vax] nice for VMS
John Reagan
johnrreagan at earthlink.net
Tue Apr 14 00:31:39 EDT 2009
"Arne Vajhøj" <arne at vajhoej.dk> wrote in message
news:49e3a536$0$90263$14726298 at news.sunsite.dk...
> I were talking about /NOMEMBER_ALIGNMENT.
>
> I was not aware of that you actually had the compiler generate special
> code to get non aligned data instead of having the CPU do it.
>
> Interesting that a software solution is faster than a hardware
> solution.
>
> I assume that is because the unaligned access is treated more
> like a fault and completely messes up the pipeline, while the generated
> instructions keeps the pipeline flowing.
>
Don't forget that PAL code is just Alpha code running on the same CPU. So
when the alignment fault occurs, the hardware saves a few registers and some
state, transfers control to the PAL which fixes up the fault, then has to
restore that saved state and return back to the execution. Avoiding the
fault is always faster.
Plus on a multiprocessor system, the PAL code ensures that some other CPU
isn't deleting the virtual address at the same time its trying to fixup the
alignment fault. That maps onto the Itanium fixup code having to take out
the MMG spinlock.
John
More information about the Info-vax
mailing list