Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re^2: I prefer my indexes to start at:

by afoken (Chancellor)
on Sep 09, 2022 at 19:24 UTC ( [id://11146795]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
        mov r1,0     // sometimes, xor r1,r1 needs less program space and/
    +or time
        mov r2,N
    ...
        inc r1       // may or may not set flags, depending on the impleme
    +ntation
        cmp r1,r2    // often imlemented as sub r1,r2 but without actually
    + writing the result back to the register, just setting flags
        jne loop     // if implemented as sub r1,r2, jne (jump if not rqua
    +l) is equal to jnz (jump if not zero)
    
  2. or download this
        xor r1,r1
    loop:
    ...
        inc r1  
        cmp r1,N
        jne loop
    
  3. or download this
        mov r1,N
    loop:
        // do something with r1
        dec r1     // must set/clear zero flag depending on value of r1
        jnz loop
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11146795]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others scrutinizing the Monastery: (2)
As of 2024-04-25 05:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found