You can already do that, with any of a large number of multi-platform game engines. Code once, run many places. Unity is probably the most well-known.
Additiionally, CPU architecture isn't really that important. Most games are written in high-level languages like C. In high-level languages the OS matters muc more than the CPU architecture.