CompuServe Messages

need asm mavens' wisdom

    19-Jul-92 19:12:53
Fm: Shraddhan 70374,754
To: Bart Mathias 72017,1005
Bart, According to my book (I think – it's badly printed), both BCLR and a byte-size AND take the same amount of time. For either instruction, the processor fetches 8 bits of data. Then it does the work – clear one of the 8 bits or mask all 8 bits. Then it writes back the 8 bits. The thing is, the 8 operations of masking a bit each take just as long as clearing one bit, because the 8 are done at the same time. So you could well say that from a philosophical point of view the processor is doing more work for an AND, and that moreover a lot of this work is wasted; however from a practical point of view there is nothing in it. On a psychological level – I wonder if the processor feels p*****d off for having to do all this extra work? Or is it just happy to have something to do? (I read somewhere a few years back that the bulk of the computing power in the world is spent in hanging around idly waiting for somebody to hit a key on the keyboard. In which case, if processors were p*****d off from having to do useless work, they would have gone on strike long ago.) And yes, I _did_ once have a computer go on strike on me – a Commodore C64 point blank refused to carry out one particular instruction. I turned the power off for a few minutes. Tried again. Still didn't work. Turned the power off for a day, two days. Still didn't work. Left it for a week. The machine relented and worked fine ever since. I swear that I'm not making this up! Regards, Shraddhan – via Whap! from Hertfordshire in the UK