Michael Rigby-Jones wrote: > Shift a 16 bit value right two bits, allegedly the PIC takes 40 > cycles! > > clrc ;1 > rrf val+1,f ;1 > rrf val,f ;1 > clrc ;1 > rrf val+1,f ;1 > rrf val,f ;1 > > I make that 6 cycles + a couple for initial bank setting if we are > being fussy. No, that's not what they wanted... They're doing an ARITHMETIC right shift, so the MSB gets preserved rather than being cleared to 0. Also, they explicitly say no bank switching was required. Still only takes 6 cycles, though: RLF HI,W RRF HI RRF LO RLF HI,W RRF HI RRF LO Interestingly, they've chosen to use "Bytes" as the unit of code space in all their comparisons. If you do the natural thing and convert from bytes to 14-bit PIC instruction words, you'll "discover" (as though you could have had any doubt) that the PIC code is always shorter than the MAXQ code. Also interesting was the absence of any example that involved reading I/O pins. Not that any of this matters, of course, since the chips apparently haven't even taped out yet. -Andy === Andrew Warren -- aiw@cypress.com === Principal Design Engineer === Cypress Semiconductor Corporation === === Opinions expressed above do not === necessarily represent those of === Cypress Semiconductor Corporation -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads