Re: choice of operation (-- or =-1)
- From: Eric Sosman <esosman@xxxxxxxxxxxxxxxxxxxx>
- Date: Mon, 06 Apr 2009 09:13:04 -0400
pete wrote:
A long long time ago,
one of my instructors told me of a system where it was faster
to bitwise xor a register with itself
(resulting with a value of zero in that register),
than it was to assign a value of zero to that register,
but I have never seen a system like that.
<off-topic severity="marginal">
IBM S/360 was like that. As on most systems, there were
several ways to get a zero into a register, but the XR opcode
had the advantage of being a two-byte instruction rather than
a four- or six-byte instruction, and of requiring no memory
reference beyond the instruction fetch itself.
</off-topic>
--
Eric Sosman
esosman@xxxxxxxxxxxxxxxxxxxx
.
- References:
- choice of operation (-- or =-1)
- From: Cross
- Re: choice of operation (-- or =-1)
- From: pete
- choice of operation (-- or =-1)
- Prev by Date: Re: Increment Operator
- Next by Date: Re: choice of operation (-- or =-1)
- Previous by thread: Re: choice of operation (-- or =-1)
- Next by thread: Re: choice of operation (-- or =-1)
- Index(es):
Relevant Pages
|