What problem are you trying to solve by keeping .o files in a processes’s memory without spilling to disk?
Specifically, to produce a .o file the compiler has already read through and created indexes of module::function/struct names, their layouts, dependencies, etc.
My understanding is that the .o files need to be re-parsed by the linker to create these indexes, layouts, and dependencies. Especially with LTOs I'd imagine there would be additional inlining work (stuff the compiler is already good at).
This is all just wasted time, including the IO bottlenecks - even if those are marginal.