I was part of Intel's mass layoffs in 2016. I hated my job at the time, but looking back now I wish I was back in the spot where my compensation was not quite "ridiculous", but great.
I went to a startup after and it was terrible. Luckily I've transitioned to the parent company, but it's still not as ideal.
Can you deal with it for a few more years? Surely you can get to a point where you can retire early?