After one year, you qualify for what's called an L1B 'internal transfer' visa. You can then transfer to another team within the same company that's based in the US. In many cases the company will sponsor your visa application and even the cost of moving (e.g. plain ticket, cost of shipping your belongings, etc.)
Once in the US, you can start the application process for a green card. As long as you're not a citizen of either India or China, this should take 2-3 years.
I'm Dutch and this is the path I took.
Whats different with these two? Why does it take so long in general?
Of course if you're willing to take 20-30% less pay, immigrating to Canada and working for one of these tech companies in Vancouver or the Toronto area is much, much easier.
For instance, folks doing well-paid jobs in let's say China or Hong Kong aren't underpaid, they're paid well, relative to their local market. The same is true in Canada, it's just that Canadians live very close to a very different market with a very different cost structure and externalities - but 'feels' about the same from the other side of the fence. Consider 50% more folks live below the poverty line per capita in the US than in Canada so clearly it's not all bad.
Remember, Canadians can show up at the US border with $50USD and an offer letter in a SWE job and get a 3-year TN status adjudicated on the spot. There's clearly more to it.
The vast majority of employers will not sponsor you for a H1B, esp. if you don't currently work for them.