Usenet comp.unix.osf.osf1 (1992-2004)
 help / color / mirror / Atom feed
* Has the Alpha an integer DIV instruction ?
@ 1999-11-29  5:00 Joe Leherbauer
  1999-11-29  5:00 ` Bob Koehler
  0 siblings, 1 reply; 2+ messages in thread
From: Joe Leherbauer @ 1999-11-29  5:00 UTC (permalink / raw)


I always thought it doesn't.

But GCC emits a "divqu" instruction for this code:

unsigned long a, b, c;
c = a / b;



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Has the Alpha an integer DIV instruction ?
  1999-11-29  5:00 Has the Alpha an integer DIV instruction ? Joe Leherbauer
@ 1999-11-29  5:00 ` Bob Koehler
  0 siblings, 0 replies; 2+ messages in thread
From: Bob Koehler @ 1999-11-29  5:00 UTC (permalink / raw)


In article <81u04d$ojq$1@fleetstreet.Austria.EU.net>, Joe Leherbauer <joe@takefive.co.at> writes:
> I always thought it doesn't.
> 
> But GCC emits a "divqu" instruction for this code:
> 
> unsigned long a, b, c;
> c = a / b;

It does not.  But GCC can claim it's generating just about anything.  

DEC Fortran claims to generate .displ, even though there's no such directive.
VAX Macro recognizes popl and generates the code that used to be in the 
macro library, but doesn't have to look up the macro (it's built into
the assembler, and it's no longer in the macro library).

What opcode does it actually assemble to?  (Try running /debug and displaying
the INST display in screen mode).  There are several instruction-like
macros in starlet.mlb and lib.mlb, and the assembler recognize several
stylized instruction forms, but not divqu.

GCC may be running code through it's own assembler (gas?), but more likley
it's generating the code internally.  It's almost certainly not dependent on
the formerly additional cost Macro 64 assembler.

----------------------------------------------------------------------
Bob Koehler                     | Computer Sciences Corporation
Hubble Space Telescope Payload  | Federal Sector, Civil Group
 Flight Software Team           | please remove ".aspm" when replying



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~1999-11-29  5:00 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1999-11-29  5:00 Has the Alpha an integer DIV instruction ? Joe Leherbauer
1999-11-29  5:00 ` Bob Koehler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox