I looked more into the full screen crash bug, and there are two separate issues:
- a race condition inside Allegro that can it to crash outright;
- Allegro does not restore the screen buffer to the proper color depth, for reasons I don't fully understand.
I tried replacing the system direct draw library with the version at
https://github.com/narzoul/DDrawCompat/issues, but while it fixed the alt-tab issue, it garbles NSF playback. Go figure.
One possible fix is to switch to windowed mode before alt-tabbing on windows, and the restore full screen mode when switching back. I will test if this works.