Calculator Community > ASM

GAME: Optimize this! (z80 assembly)

<< < (4/4)

calc84maniac:
What's with the "ld c,(hl) \ inc hl \ dec c"? You never use c for any reason whatsoever.

Fallen Ghost:
Well, what's the point of putting hl to 0 prior to loop and then using it as a counter like I use the acc. instead?

There's none, it's just a piece of code to optimize. If you want my opinion, this routine could be replaced by "ret" and it would output the same, but it seems we have to care about whatever the routine does.  

DJ Omnimaga:
Please quit complaining lol, fyi we just started those contests up, and they were planned in about 30 minutes (including the BASIC contest), and this is the very first piece of code. Just don't try to kill the contest project on its first piece of code lol, give it a chance. On next piece of code we'll take your suggestions into account

Halifax:
On the next piece of code someone else can make up something. As DJ_Omnimaga said this was done in > 30 minutes. It was at least more activity, then what was being output prior to our contests. Next time someone else can do it. If you think this is bad, then you should try being in my Computer Concepts class where you write programs that are meant to do nothing and you can't even build them to test them. This contest was meant to be an algorithmic contest as I said before. Better algorithms should be recognized even on non-working code.

@Fallen_Ghost: Obviously yes your routine is the best, and what I consider the most optimized.

Fallen_Ghost wins!

DJ Omnimaga:
COngrats!

Navigation

[0] Message Index

[*] Previous page

Go to full version