What if we DONT switch to GBA mode... wouldn't it be possible to just have a copy of the GBA BIOS and use that bios image to play the GBA game in NDS mode, rather then switching to GBA mode to use it? If the GBA's BIOS takes up 16 KBs and then the GBA has 256 KBs of ram, that gives us 3824 KBs of RAM free to do whatever else we need to do.
Another option is to enter GBA mode via a patched copy of the BIOS that won't clear the RAM.