I've had periods where the idea of working another day with arrogant dickhead 'know it all' ex-Physics students turned developers who can solve tough problems with terrible to maintain code thus making themselves unsackable made me think of jacking it all in and moving to a third world country and living in a hut - even to the point of visiting the Vietnamese consulate for information.
Likewise I've had times where a young CS background developer who is eager to learn, very gracious, fun to be around and delivers makes me remember that it can be a great industry.
I'd recommend getting out of your current job if you can if its making you feel this way.
A few years ago I was working in finance, had experienced some workplace bullying so I overworked to prove myself to stop it despite it being about an Alpha boss picking a scapegoat, and I suffered from some mid strength burnout and in the end I wasn't fit to work for probably 5 months afterwards. I ended up going into a completely different industry (but still software) and managed to reboot myself over about 3 months and started to enjoy work again.
Earlier in my career I met someone who had completely burned out. He'd not worked in 18 months despite having lots of offers, had moved to the coast and was just doing spiritual stuff all the time and was burning through his savings. We asked him to come in for 1 day to interview others and after 2 hours he said he couldn't take it anymore and left, and that was it. It was quite shocking to see someone who was that way and quite scary when I felt it happening to me.
Don't wait until you completely burnout because it will damage more than just your career - your health, waistline, relationships, friendships, bank account, future employability etc.