He Knew

This was quite a dilemma. 

The Nine Pillars worked well in the void, but Ryu knew they wouldn't have a single ounce of usefulness in front of Infinity Mist. It was currently relying on his comprehension of spatial qi and his Spacetime Soul Nature to be able to do this. 

From Ryu's understanding, the Nine Pillars were designed to prop up the Heavens, to find solidity within the Earth. However, these two concepts, Heaven and Earth, were figurative. The Earth represented the foundation of the cultivator using it, while the Heavens referred to what the cultivator aspired to. 

So, because Ryu had a foundation of Spacetime, his Earth, and aspired to enter the void through the use of it, his Heaven, it could work in this aspect.