And regarding H1-B’s being intentionally underpaid..I can’t comment for every company, but I’ve found that at least the ones that I’ve worked with, the compensation was on par if not more with anyone else that gets hired.
My experience is, H1 people tend to be a bit overpaid for their positions, but more often than not they as professionals are a level or two above the requirements for positions they are holding. It’s quite common to see H1 programmers with MS and PhD degrees and decades of experience. Americans with such credentials just don’t seem to be interested in hands-on programming jobs, while immigrants readily take the opportunity. At least at the beginning.
And – believe you me – one great programmer can easily beat a mediocre software team of 20.