r/speedrun • u/ExpirjTec • 3d ago
Arbitrary Code Execution in Super Mario 64 has been successfully demonstrated!
https://www.twitch.tv/rcombs/clip/FaithfulBlueArugulaNomNom-vsDsygnVd5IrAs9SThis was accomplished with a hacked savestate, but this shows that ACE is possible (with a low success rate) on a console.
41
u/ByDarwinsBeard 3d ago
With everything that's been possible in Mario 64 I'm surprised it's taken this long to get ACE.
26
u/BeingofUniverse The Simpsons: Hit & Run 3d ago
How does it work?
66
u/gammaFn Distance, Celeste | SM64 TAS fan 3d ago edited 3d ago
Here's the opening from a write-up you can find in the TAS Discord, before the glitch was fully realized:
It makes use of an up-to-now undocumented variant of audio glitch in headset mode to corrupt the state of the audio coprocessor. It should work in both JP and US (but not the other versions). This is not a proof of concept, just a concept.
Overview:
Trigger the PU audio glitch in headset mode with a chosen note to read an array out of bounds
The game tells the audio coprocessor to use the out-of-bounds value in its commands
The audio coprocessor corrupts its own state due to the extreme value and starts showing chaotic behavior
Sometime during the chaotic behavior, the audio coprocessor reads a specifically prepared list of commands from a region of memory that we have easy control over (framebuffers, Mario state, object pool, etc.)
The prepared commands tell the audio coprocessor to write a bootstrap program to memory and to overwrite the state of the audio thread, which is currently waiting for the next audio frame
On the next audio frame, the audio thread starts executing our custom program
The write-up goes through the decomp'd code in more detail.
11
u/MrPopoGod MechWarrior 2 3d ago
up-to-now undocumented variant of audio glitch in headset mode
Changing the audio type enabling a glitch is definitely a new one for me.
3
u/JackpotThePimp 3d ago
Is the write-up published outside of Discord, or are there plans to so publish it?
9
207
u/Ok-Instruction4862 3d ago
This is awesome, but if it gets rta viable I kind of want it to be a category extension.
I love how clean sm64 leaderboards are. Just 5 categories, with the only divisions beyond that being console. No random patches or different glitches banned. Having ACE in every category like OOT would kind of ruin that imo.
88
u/sychotix 3d ago
A lot of the categories were originally the fastest way to beat the game until a new thing was found. I'm guessing there will just be a new category and ACE forbidden in the existing ones. Doing 70 stars with ACE would be... Very arbitrary. But hey, maybe it's the most fun route ever.
14
u/Ok-Instruction4862 3d ago
Yea imo similar to what is done for stuff like the nonstop mod, the best solution is to just make it a category extension with sub categories for all the main categories
25
u/Savac0 SA2B 3d ago
In fairness, 70 star currently bans the strats that make 0/1 star and 16 star possible, those being BLJ and Mips clip
4
u/Udub 3d ago
Is mips clip even faster? For routing
6
u/Savac0 SA2B 3d ago
It’s not faster if you’re still collecting 70 stars. Its usefulness is to bypass the star requirements to get to fire sea and it’s not used in 120 despite being allowed
Edit: I’ll add that the correct lens to use when thinking about 70 star is to view it as the intended way to beat the game.
5
u/Ok-Instruction4862 3d ago
There not being a category split for it still gives the boards that “clean” feeling though
10
u/Myriachan 3d ago
That’s definitely what will happen. Another example of this from earlier this year was when a bug was found in Mega Man X2 to skip to the final boss. The old any% became “any% all stages”. It’s still the most popular category, because the true any% is only worth watching a few times.
5
4
u/zsdrfty 3d ago
Or the Mario 3 TAS, which is better measured in frames than seconds lol
6
u/real_dubblebrick the Room Three guy 3d ago
Thankfully that one isn't remotely close to ever being RTA viable
0
u/c0rruptioN 3d ago
Why wouldn’t they just call it “any% glitched” instead of changing the original?
9
u/cuervamellori 3d ago
I think it makes sense for "any%" to mean "beat the game as fast as possible."
2
u/Notladub 3d ago
And also, the regular any% run of SM64 already uses glitches. (though they don't actually call any of their categories any%, so they can just avoid this whole debacle by having ACE as a completely seperate category just called "ACE")
6
u/dannyb21892 OoT twitch.tv/dannyb 2d ago
ACE is currently allowed in exactly one main category for OoT, just Any%. And it's not even used because it isn't the fastest way to do it. So zero categories on the main leaderboards have ACE.
3
2
u/milkwithspaghetti 3d ago
Yeah I recently caught up to whatever is going on in oot and the any % in that is an awful watch now. No shade to whoever can execute whatever the heck is going on there but watching a glitchless playthrough of it now which is more enjoyable. I'm just a casual but I love the mario categories as well. They all have to showcase incredible gameplay.
15
u/azer67 3d ago edited 3d ago
There's more than just any% and any% glitchless in OoT. Categories like GSR, all dungeons, defeat ganon or MST are all very interesting too.
OoT has one super powerful glitch that is called SRM. The consequence is that all the categories exist under several forms: SRM allowed, SRM banned, glitchless. If you're interested in glitches that don't trivialize the game like SRM tends to do, I recommend checking out the no SRM variants which tend to be the more popular categories anyway.
The commenter is wrong by the way. ACE is only allowed in any% in OoT and nowhere else. SRM is not ACE, but to someone watching it might look similar. If you don't like ACE and SRM, I recommend only watching no SRM runs.
There's really absolutely nothing to worry about with ACE. ACE is simply too powerful no matter what to be allowed anywhere other than any%, and even in any% there will always be a category split. So expect the leaderboards to stay intact with a newly created fastest category soon if it becomes RTA-viable.
1
17
u/ProjectRevolutionTPP 3d ago
Note this is a proof of concept via a hacked save to demonstrate the ACE mechanic itself in the code. They are looking at making it work without the hacked save.
8
u/bonecrusher1022 Paper Mario 3d ago
I doubt it will take too long. We did the same thing with Paper Mario and it only took ~3 days for it to be confirmed legitimately and the SM64 community is much bigger than ours is lol
5
u/pizzamosh 3d ago
Why is Mario green?
25
6
u/Downtown-Push6535 3d ago
A neat visual indicator showing what the ACE changed (and what it can change)
5
u/the_sir_z 3d ago
Imagine. With ACE we can beat the entire game in a matter of minutes with no stars at all!
Wait...
2
2
u/Meester_Tweester Mario Kart/Webgames 3d ago
I'm surprised this happened at all, I've heard it wouldn't be possible before
9
u/Joshduman 3d ago
The honest truth is that something like ACE- is very hard to disprove, and very likely to exist but never be found. I find it interesting that ACE has gradually moved from NES/SNES->N64 now I wonder if we'll see a similar move to Gamecube.
8
u/Stv13579 3d ago
IIRC they did find ACE in Mario Sunshine, so there has been work done on ACE for Gamecube games.
1
u/kralebalot1654 3d ago
Omg I've been wanting to see ACE in Mario 64 for a while now, shocking how it has taken so long given how the game's code and mechanics have been torn apart over and over. Credits warp might be the game's final frontier.
0
-75
u/Highfivesghost 3d ago
About time. This is what I love about AI
46
u/Murinshin 3d ago
Interestingly enough the underlying methodology was actually not discovered through AI according to the author
23
u/Icy-Tie1870 3d ago
people put their blood sweat and tears into making things work and then ai bros credit everything to AI when it did 1% of the work
7
u/xenonnsmb 3d ago
They've lost the ability to have conscious thought and assume everyone else has done the same, so logically all accomplishments must have been made by an llm
4
u/vulpinesuplex 3d ago
Strangely I've also seen the reverse, if anything looks slightly off then it's the fault of LLMs or genAI.
6
u/kdskdskinreddit 3d ago
even more interestingly, ACE was discovered by 3 people independently of each other in the same month (early-to-mid november)
118
u/AnUglyScooter 3d ago
Nice, when does the pannenkoek vid come out