You must be easy to replace if some low caliber H1B visa worker replaced you. I never had that problem in 37 years in US manufacturing jobs.
You must not work in IT, nor have any American friends working in IT. Otherwise, you would have a very different opinion.
It doesn’t matter what you think.
It matters what the boss thinks.
You could be God’s gift to your employer, but if your employer thinks somebody only marginally good but way cheaper and easier to manage is a better choice, prepare to be ousted by the H1b.
And you’ll likely only find out the hard way.