Hi, > I'm working on a project where ROM space is at an abolute minimum, > and I've tried every trick I can think of to squeeze everything in. > Unfortunately, I'm still a bit over the limit. > > Has anyone got a tight routine to subtract a 16 bit number from a 32 > bit number. The result is placed back in the 32 bit number. > > TIA > > Tony > What about: ;Subtract 16 bit number in A1,A0 from 32 bit number in B3,B2,B1,B0 ;Answer is left in B3,B2,B1,B0 movf B0, W subwf A0, F movf B1, W skpc incfsz B1, W subwf A1, F movlw 0FFh skpc addwf A2, F skpc addwf A3, F Niki