I think it is quite likely that there are many people in the US who are smart enough but lack the $100k to go to university for 4 years. Not saying that immigration is bad, but there are many US citizens who could participate if they had education.
The US skims some of the best students and programmers from around the world, but also people who are equivalent but cheaper, and also indentured.
There is a way to improve this situation -- allow H1B workers to easily change employers.
Alternatively, employing an H1B requires paying into a tuition scholarship fund. $50k/year sounds reasonable to me.