A couple points for consideration:
1. There seems to be a consensus that introductory education in the sciences is not terribly good in the United States. Advanced education in the sciences, however, attracts some of the best and brightest both within the United States and from around the world. This is a function of both money and opportunity, given the large number of universities and research centers within the U.S.
2. For decades, those who've come to the United States often stayed. It was a simple matter of the economic opportunities being so much greater in the U.S. than in their home countries. In some cases, e.g., India, the difference was 10,000% or more.
Concerning the second point, however, we've begun to see that international communications, such as the internet, are now sophisticated enough that these graduates can return to their home countries and still earn a very comfortable living - often doing work for American and European companies and even governments.
This is not intended to be an "outsourcing is bad" observation. I'm simply wondering how much effect it will have on U.S. scientific advancement if this trend continues. A little? A lot?