[Info-vax] Dave Cutler, Prism, DEC, Microsoft, etc.

John Reagan johnrreagan at earthlink.net
Tue Dec 1 15:25:21 EST 2009


"Bob Koehler" <koehler at eisner.nospam.encompasserve.org> wrote in message 
news:s+8diLx+uhSu at eisner.encompasserve.org...
> In article <fdWdnb4rXYpO_onWnZ2dnUVZ_q-dnZ2d at earthlink.com>, "John Reagan" 
> <johnrreagan at earthlink.net> writes:
>>
>> On the VAX, the compilers (at least the Pascal compiler and I believe the
>> Fortran compiler where I stole the code from) align targets of branches 
>> and
>> routine entry points on longword (or quadword boundaries, I forget 
>> which).
>> We pad with NOPs.  It made branches and CALLs *MUCH* faster.
>
>   IIRC, that Fortran compiler came out at about the same time as the VAX
>   6000 series (first NVAX?).  And I was left wondering just how fast my
>   MV II was running though all those NOPs on conditional branches not
>   taken.
>

That was indeed the tradeoff.  The hardware groups told us not to worry but 
it does take up space in the i-cache after all.  We decided the benefit was 
worth it at the time.  However, we didn't go back and remeasure on newer 
VAXen to see where the breakpoint was.

VAX Pascal also executes "useless" instructions (tstb #literal) at various 
places as flags to the RTL.  The main one is getting UNSIGNED arithmetic not 
to fault eventhough you want integer overflow enabled.  Since there is only 
one ADDL instruction, we followed unsigned adds with a tstb #literal.  The 
RTL's handler sees that special instruction, looks up the literal to see 
what to do, and then bumps the PC and continues.  In cases where the ADD 
didn't overflow, you execute the tstb #literal anyway.

John






More information about the Info-vax mailing list