Optimizing DIV


Results 1 to 40 of 42

Thread: Optimizing DIV

Threaded View

  1. #18
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Jeeze...up in SkiShift3...
    Code:
    	movlw	8
    	subwf	R3, F
    	
    	movf	R3, W
    	btfss	STATUS, C	;if it's 1 (actually 1-8)
    	bra	Ski_Shift3	;jump out
    Not going to get much of a carry from that am I?
    The subwf should set STATUS as appropriate, should be able to remove movf R3, W above the branch.
    I'm still looking thru my code in MCS...
    Might not have to worry about the most-sig-bit in R0/R1 since it's preset to 0 by the code at the beginning, therefore, that'll negate checking bit 30 instead of bit 31 of R0/R1.
    Last edited by skimask; - 11th September 2008 at 23:18.

Similar Threads

  1. Optimizing LCD commands?
    By jblackann in forum mel PIC BASIC Pro
    Replies: 1
    Last Post: - 4th December 2007, 16:30

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts