There is ongoing work to try to reduce the ability of outsourcing companies to get the no of visas they do. The recent H-1B rule, for example. They’re trying to make distinctions between the 2 groups. The first group do get suppressed wages, and don’t tend to go on to become permanent residents or citizens, as they’re treated so poorly.
The latter group really do tend to be exceptional technical talent.