901
The Axe Parser Project / Re: Bug Reports
« on: January 20, 2012, 11:16:14 am »
The fact that tokens could be inside of the app would need to be dealt with.
This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to. 901
The Axe Parser Project / Re: Bug Reports« on: January 20, 2012, 11:16:14 am »
The fact that tokens could be inside of the app would need to be dealt with.
902
The Axe Parser Project / Re: Bug Reports« on: January 20, 2012, 11:04:51 am »* Runer112 checks documentation Oh, Disp ►Tok and Text ►Tok call for different arguments. That's a little confusing. But I see how printing the token pointed to would generally be more useful. Maybe Disp ►Tok should be changed to accept a pointer to a token as well for consistency? I think it would only need to be two bytes bigger; ld e,(hl) \ inc hl \ ld d,(hl) instead of ex de,hl. And this would actually be saving two bytes for printing tokens from a pointer. 903
Calculator C / Re: C Q&A Thread« on: January 19, 2012, 09:34:54 pm »
Lose the "void" since you're calling the function, not declaring it. As far as making sure you're calling the function with the proper arguments, I can't help you there because I don't know anything about device-specific C development.
904
The Axe Parser Project / Re: Axe Parser« on: January 17, 2012, 05:19:29 pm »Some things I'm particularly curious about: After searching around and not having found any existing list of token hook equates, I figured I should compile one myself, and I did. Feel free to include it in the next release of Axe. http://www.ticalc.org/archives/files/fileinfo/445/44517.html 905
Site Feedback and Questions / Re: why is there a black bar on the omnimaga banner?« on: January 15, 2012, 07:47:39 pm »
Click it.
906
The Axe Parser Project / Re: Bug Reports« on: January 15, 2012, 05:47:08 pm »
Not sure if this is a bug report or a feature request, but it appears that Axe will not "nest" peephole optimizations. I put "nest" in quotation marks because that's not a very accurate description of what I mean. This code example should hopefully better illustrate what I'm trying to say:
As you can see, the inc hl \ dec hl optimization was applied, but the sbc hl,hl \ ld a,h \ or l optimization was not applied. 907
Axe / Re: Axe Q&A« on: January 15, 2012, 04:54:12 pm »
Yes, that is a perfectly valid optimization. However, with the introduction of the peephole optimizer in Axe 1.0, Axe will perform simple optimizations like that automatically so you don't have to.
908
Axe / Re: How to display a Pic« on: January 15, 2012, 01:37:36 pm »
Don't use Bitmap() unless you absolutely need it, which you don't for just displaying full-screen pictures. The Bitmap() routine adds over 200 bytes to your program.
909
ASM / Re: Set by Address restrictions?« on: January 15, 2012, 01:39:28 am »
I think you mean:
Code: [Select] ld bc,(var1-1) ;c=(var1-1), b=(var1) And that's the same size as Hot_Dog's suggestion, but it's 3 cycles slower. 910
Axe / Re: Axe Q&A« on: January 13, 2012, 07:08:46 pm »
.Draw a byte of top border (88-95,1)
.Draw a byte of left border (0-7,2) ᴇC0FF→{L₆+23}ʳ .Copy byte (88-95,1) of top border to draw rest of top border (0-87,1) and (0-95,0) Copy(L₆+23,-1,23)ʳ .Copy byte (0-7,0) of top border to draw bottom border (0-95,62) and (0-95,63) Copy(,L₆+744,24) .Draw byte of right border (94-95,2) .Draw byte of middle (80-93,2) ᴇ0300→{L₆+34}ʳ .Copy byte (80-87,2) of middle to rest of third row middle (8-79,2) Copy(L₆+34,-1,9)ʳ .Copy third row (0-95,2) to fourth through sixty-second rows (0-95,3-61) Copy(-1,+12,59*12) 911
Axe / Re: Axe Q&A« on: January 13, 2012, 06:56:26 pm »
ᴇC0FF→{L₆+23}ʳ
Copy(L₆+23,-1,23)ʳ Copy(,L₆+744,24) ᴇ0300→{L₆+34}ʳ Copy(L₆+34,-1,9)ʳ Copy(-1,+12,59*12) 912
Axe / Re: Axe Q&A« on: January 12, 2012, 11:47:43 pm »
You started out pretty good with 68,006 cycles
Rect(0,0,96,64) RectI(1,1,94,62) Then you went way in the wrong direction with 2,614,503 cycles Rect(0,0,96,64) For(J,1,94) For(K,1,62) Pxl-Off(J,K) End End And here's my Runer-optimized™ speed/size blend, coming in at 16,303 cycles; that's faster than ClrDraw! ᴇ80FF→{L₆+11}ʳ Copy(L₆+11,-1,11)ʳ Copy(,L₆+756,12) ᴇ0100→{L₆+22}ʳ Copy(L₆+22,-1,9)ʳ Copy(-1,+12,61*12) 913
The Axe Parser Project / Re: Axe Parser« on: January 12, 2012, 06:29:05 pm »
Sorry for the double post again!
Well, I found a solution to the issue! The easy way to fix it would've been to simply add 5 or 10 bytes of code to the existing method. But I wanted to minimize as much code bloat as possible in fixing this bug, and I would say I certainly did. Not only did I fix the bug, but the hook is now a byte smaller! Code: [Select] .nolist EDIT: This code was changed at 11:15PM EST on 1/12 to fix a critical bug that made all key programming tokens in the PRGM menu inaccessible. Please do not use any copies of the code made before this time! EDIT 2: [10:00PM EST 1/13] Changed the "var" and "appv" token replacements to use the standard lowercase "v" instead of the recursive one. None of the OS tokens, including the recursive equation tokens themselves, actually use the recursive equation characters 02h-04h, so there's no reason why Axe should either. 914
The Axe Parser Project / Re: Axe Parser« on: January 12, 2012, 03:17:16 pm »
I just realized that the token hook has a very minor bug in it. I was relying on the indicator $00 to signal that there are no more tokens to be compared, but I seemed to forget that a couple of tokens actually have $00 as the low byte of the compare value. I suggest fixing this by making $FF signal the end of token comparisons, as this is an odd number and is thus not a valid low byte for the compare value. Fixing the code itself for this change is actually quite easy, and will only cost 1 byte and 4 cycles. Add an inc e before the comparison loop and change or a at the end of the comparison loop to inc a.
EDIT: Let me think this through a bit, this makes my Axiom token replacement cache generator less optimized... 915
The Axe Parser Project / Re: Features Wishlist« on: January 10, 2012, 09:16:59 pm »
How about the ability to use Pt-Mask()r with arbitrary buffers? Unlike Pt-Mask(), it only uses one buffer which is only referenced once, so arbitrary buffer support would be just as easy as with the three basic sprite drawing commands.
Also, the command list description for Pt-Mask()r should probably be changed a bit. The sprite argument isn't a "grayscale sprite" like with Pt-Mask(). |
||||||
|