Like if Google is struggling to hire L3 entry level engineers, can't they just offer $1 million/year salary? Then of course they will get the people they want.
To me, the point of H-1B and similar programs isn't "we can't get the individual staff we need". It's rather that at a society-wide level, having more software engineers at an overall lower salary can be more beneficial to the country than fewer engineers at a higher salary. And I feel that the success of Silicon Valley kind of shows this: if we didn't have any immigrants to the US, maybe the salaries would have been higher, but there is simply no chance SV would have reached the scale it has.