Prescription ibuprofen contains 600mg per tablet, so I don’t believe taking four per day would be a problem short term. You could contact your dentist or pharmacist to check with them.
Doctors use higher doses when they prescribe this type of medication. They have prescription strength. Over the Counter is sold in a lessor strength under the assumption that people are self medicating. Here's a guide: https://www.drugs.com/dosage/naproxen.html Aleve is actually naproxen but is a Nsaid like ibuprofen (different though but in that class of drugs). One thing to keep in mind as tabs can be immediate release, extended release and controlled release. Different maximums depending on that aspect. The OTC version for pain is a max dose of 660mg a day. You are within that. But do reach out as you sound to be in a lot of discomfort. When you getting the tooth fixed? That will be the ultimate fix to the pain.
If you have any problems with your liver or kidneys, please check with your doctor before taking any NSAIDs at any dose.
Also, taking too many over a period of time can lead to certain stomach issues, so please talk to your doctor before taking them if you have a history of stomach problems.