Speedhacks


Horscht

Banned?
Joined
Jan 5, 2004
Messages
1,612
Age
38
Location
Germany
Website
Visit site
Hi

I just recently took a look back into GBA emulation (emulators ON the GBA).

I got reminded of such great efforts as "PCEAdvance" and "SNESAdvance" (FluBBa's Homepage). Suprisingly, those two consoles were emulated very well on the tiny littel 16MHz beast that is the GBA. I remembered those releases where Flubba Released one PCEAdvancce Version after another (I am sure Reesy will remember :D ), always speeding up more games.

He even told us how he did it. Something wonderfull called "speedhacks".

To be specific, speed hacking mostly involves skipping out of idle loops in the top of the VBLANK cycle, at which point drawing for the current frame is done. Sometimes (rarely) these loops are complicated, or are subroutines rather than loops. See www.patmedia.net/dfreiday/tutorial.html or www.patmedia.net/dfreiday/tutorial2.html for more info, or (if you're technically inclined) read technotes.txt include with the debug version of SNESAdvance. Also, loopy has provided more efficient ways to skip out of loops than nop'ing them - see the technotes for more info.

In principle, yeah, speed hacks just break out of delay loops. Speed hacks are a little more than just adding NOPs though... you're inserting special instructions that tell the emulator when it's safe to skip an assload of cycles. NOPs still have to be emulated, so by themselves they don't really help out speedwise.

(as seen here)

Now I wondered: could the speedhack method be used in emulators like SquidgeSNES or Similar emulators that go very close to the edges of the capabilities of the nifty lottle GP2X handheld? I gathered from the pocketheaven forums, that speedhacks seem to be improbable for GB amulation for example

I've tried pretty hard to speedhack Gameboy Color games, but it simply isn't possible. Either the game is nice and uses the HALT instruction, or it's poorly coded and doesn't delay at all. I've only seen one game so far which could be speedhacked, which is Ninja Gaiden Shadow, but that game doesn't really need it on Goomba.
(source: http://boards.pocketheaven.com/viewtopic.p...light=speedhack )

But seeing as both PCEAdvance and SNESAdvance take profit speedhacks, surely PCE/SNES Emulators on GP2X could profit as well. Maybe GBA emus as well, but that, i dunno at all.

It would be great to hear from the devs about this idea.

regards

Horscht

(note: I am talking right out of my ass and am sorry if speedhacks have already been declared not possible/ too difficult for use in GP2X)
 
Yep its possible, we just have to code it ;) I believe it will involve fiddling around in the cpu core and as I'm not familiar with the core in squidgesnes it would probably be quite hard going. Its probably something I would look into once I've taken the rendering optimisation as far as I can be assed to.

and yes speedhacks are wonderfull!
 
Would these need, then, to be done on a game by game basis as and when they are implemented (assuming eventually they are)?
 
in PCEAdvance (not sure about SNESAdvance) they are on a game by game basis. I remember some sort of tutorial on the emuboards and pocketheaven forums. Allthough it's a lot of work, it would surely pay of for SNES emulation. The speedhacks do not necessarily be done by the hard working coders, but can be done by voluntary contributors as well :)

But seeing as Reesy says it's possible but hard, I wouldn't get my hopes up as off yet. It might turn out to be too hard. So, at leas now I know it's possible.
 
i was actually convinced flubba and loopy were not mortals under any circumstances. PocketNES and NESDS are shining examples of what NES emulation should be on portables. if it were possible under my own power, i'd port that software at the first chance i had. (though, instead i'm looking at the cores for an ARM7TDMI (the gba processor) and trying to learn ARM assembly on top of what i need to develop an ARM7tdmi compatable core.
 
I agree FluBBa, Loopy, Reesy and the like gave us the best emulators for use on our GBA flashcarts. It was thanks to those coders that I got into emulation and eventualy the GP32. I am very impressed by what Flubba did, though. Full speed NES emulation, Full Speed GB emulation, great PCE emulation.

And you wont belive what I just tried: Goomba Color. An *AWESOME* GBC emulator for GBA. SNESAdvance was more of a proof of concept as to the impossible SNES emulation to be achievable on GBA. GBC was similar. Everyone said "It can't be done". I was very impressed by Goomba Color, it emulated the few roms i've tried fullspeed (to my eye). And I can only imagine what FluBBa could have done to GP32/GP2X, unfortunately he wasn't interested.

Ressy's DrSMS also gave me a lot of fun on my GBA and it surely was a hell of a job. Not to mention the great achievement of the Godess that is DrMD (and now he's improving SquidgeSNES).

Many thanks to you all for giving me such a pleasure out of my handheld consoles :)
 
I agree FluBBa, Loopy, Reesy and the like gave us the best emulators for use on our GBA flashcarts. It was thanks to those coders that I got into emulation and eventualy the GP32. I am very impressed by what Flubba did, though. Full speed NES emulation, Full Speed GB emulation, great PCE emulation.

And you wont belive what I just tried: Goomba Color. An *AWESOME* GBC emulator for GBA. SNESAdvance was more of a proof of concept as to the impossible SNES emulation to be achievable on GBA. GBC was similar. Everyone said "It can't be done". I was very impressed by Goomba Color, it emulated the few roms i've tried fullspeed (to my eye). And I can only imagine what FluBBa could have done to GP32/GP2X, unfortunately he wasn't interested.

Ressy's DrSMS also gave me a lot of fun on my GBA and it surely was a hell of a job. Not to mention the great achievement of the Godess that is DrMD (and now he's improving SquidgeSNES).

Many thanks to you all for giving me such a pleasure out of my handheld consoles :)

Flubba's also released a SMS, Coleco Vision and MSX emulator, as well as arcade emulators. I'm convinced he does not sleep. He must just get home from work and program on his computer until its morning and then go back to work.
 
Last edited by a moderator:
yeah, but I haven't tried those. I hardly touched my GBA in ages and just did today to go "down memory lane" as to what got me started in homebrew/emulation. By that chance i found out about Goomba color, so I tried this as well. But indeed. Flubba throws out a lot of emulators. I think he gets fed with a feeding tube or a nurse. :)

EDIT: I think i'll have a look at FluBBas SMS emu right now.

EDIT2: this is turning into a "FluBBa is the allmighty"-thread :lol:
 
I agree FluBBa, Loopy, Reesy and the like gave us the best emulators for use on our GBA flashcarts. It was thanks to those coders that I got into emulation and eventualy the GP32. I am very impressed by what Flubba did, though. Full speed NES emulation, Full Speed GB emulation, great PCE emulation.

And you wont belive what I just tried: Goomba Color. An *AWESOME* GBC emulator for GBA. SNESAdvance was more of a proof of concept as to the impossible SNES emulation to be achievable on GBA. GBC was similar. Everyone said "It can't be done". I was very impressed by Goomba Color, it emulated the few roms i've tried fullspeed (to my eye). And I can only imagine what FluBBa could have done to GP32/GP2X, unfortunately he wasn't interested.

Ressy's DrSMS also gave me a lot of fun on my GBA and it surely was a hell of a job. Not to mention the great achievement of the Godess that is DrMD (and now he's improving SquidgeSNES).

Many thanks to you all for giving me such a pleasure out of my handheld consoles :)

Flubba's also released a SMS, Coleco Vision and MSX emulator, as well as arcade emulators. I'm convinced he does not sleep. He must just get home from work and program on his computer until its morning and then go back to work.
icemethamphetaminebagcustom6kw.jpg
 
Last edited by a moderator:
Its Meth(hylamphetamin), also called crystal/crsystal-speed.
The nazis gave that stuff to some soldiers to make them stay aaware longer.
 
Freebase?

BaseBall ?. :blink:

EDIT:

Methamphetamine is an addictive stimulant drug that strongly activates certain systems in the brain. Methamphetamine is chemically related to amphetamine, but the central nervous system effects of methamphetamine are greater. Both drugs have some limited therapeutic uses, primarily in the treatment of obesity.

Methamphetamine is made in illegal laboratories and has a high potential for abuse and addiction. Street methamphetamine is referred to by many names, such as "speed," "meth," and "chalk." Methamphetamine hydrochloride, clear chunky crystals resembling ice, which can be inhaled by smoking, is referred to as "ice," "crystal," "glass," and "tina."

More here.

http://www.nida.nih.gov/Infofacts/methamphetamine.html

Trooper
 
Last edited by a moderator:
Yeah, it's a horrible drug that's ruined the lives of more than a few of my friends. It does keep you awake for days, though, which is why I posted it (jokingly).
 
Hmm how can you make jokes about it if it has ruined the lives of friends of your's... oh well... back on topic, I think that these speed hacks are a very interesting method. Can this also be done on the psx emulator or is it just applicable with a certain kind of machines (because you already quoted somebody saying that it's near to impossible with gbc emulation)?
 
the fact that it's almost unusable on GBC emulation is the fact that GBC games either cut uneccessary cycles themselves or do not have uneccessary cycles.

Wether or not this could be applicable to PSX games, I don't know. Someone with knowledge would have to check that. I merely know what speedhacks are, what they do and that they are awesome. I remember reading a tutorial for Speedhacking PCE games in PCEAdvance as well.
 
ah! I get the picture... actually that means that gbc games are optimized quite well :D
 
Back
Top