gba2k icon indicating copy to clipboard operation
gba2k copied to clipboard

Provide faster memory functions

Open Lokathor opened this issue 2 years ago • 2 comments

  • __agbabi_memset
  • __agbabi_memcpy
  • possibly others?

These functions are provided by compiler_builtins with weak linkage. They're rather poor by default, so we should provide something better in our assembly runtime code.

Lokathor avatar Jun 23 '22 18:06 Lokathor

All the appropriate signatures that we need to match are here: https://github.com/rust-lang/compiler-builtins/blob/master/src/arm.rs

Lokathor avatar Jun 23 '22 18:06 Lokathor

https://github.com/felixjones/agbabi/tree/2.0 has Zlib licensed samples of seemingly all the functions.

Probably we just need to bring them in and slot them in our existing folder of assembly stuff. The code isn't so commented, so we might want to add more notes inside each function.

Lokathor avatar Jun 27 '22 16:06 Lokathor