> Here is a quick coding challenge. > > I have a loop that takes 35 cycles to execute. However, I need it to take an > average of 38.5 cycles. > > Any takers? assuming access to loop variable (incremented each loop cycle) btfsc lcv,1 goto label nop nop label: ; next line of your code If I understand correctly, the bit test will take 1 op, the goto counts at 2, which is 3 ops. Or, the bit test takes 2 ops and then 2 nops = 4. This alternates between 3 and 4 extra cycles. -Steve -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads