The world has changed and Americans now have to compete with global workforce. Now, the global workforce (workforce in India, etc. and H1-Bs in USA) work for much less than what Americans want.
Now, the companies of USA want to increase their profits so they will use cheap labour. They actually don't care about Americans, they only care about their profits and revenues. It is quite evident that the companies want profits even if they have to layoff Americans.
By the way, these all are the side-effects of capitalism.
So, now the only way for Americans to not get laid off is to ask the management to reduce their salary but let them keep their jobs.