The problem is not overthinking, it is just a symptom, the underlying problem seems to be something else. We need to understand the root cause as to why are we overthinking at all. Talking to a good psychiatrist/therapist will help you understand the same.
About suicidal thoughts, thats an emergency and you should consider consulting a psychiatrist immediately for the same, whatsoever be the reason of such thoughts.
Next Steps
Consult a paychiatrist
Health Tips
Before you plan any suicide or self harm, seek out for help, communicate/talk to a psychiatrist.