In the real world, this kind of approach is critical to making effective use of compute resources. This is the kind of stuff you want in production.