Calculator Community > Axe

The Optimization Compilation

<< < (22/24) > >>

calc84maniac:

--- Quote from: Happybobjr on October 21, 2011, 08:12:21 pm ---also, i think 'number less than 256' /256 might be more efficient than just 0

--- End quote ---
Actually no, both of those are 3 bytes. But 'number less than 256' and 0 is only 2 bytes and it does the same thing :)

epic7:
I'm going to see how many bytes I can save now.

kindermoumoute:
Currently, is this tutorial efficient yet ?

squidgetx:
Umm it's a little outdated atm, though much of it is still OK.
Axe's peephole optimizer removes the need for things like

--- Code: ---If A+1->A
--- End code ---
instead of
--- Code: ---A+1->A
If A
--- End code ---
Also DispGraph is just as fast as DispGraphr
I'm planning to sit down sometime in the near future and update this a bit

squidgetx:
Done.

For those of you who don't want to scan through, I've made a list of most of the new additions/changes

* The HL section is quasi-obsolete
* DispGraphr is no longer faster than DispGraph
* The !If A xor EXP structure is now better than the !If A - EXP unless you are using an optimized addition/subrtraction
* When storing 0 to a 1 byte variable, and 0-> is better than 0->
* I linked to Runer's index thread as well as stole the math opts table from him to be included here.
* Otherwise cleaned up and reformatted

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version