The question is toxic to what. Not all chemicals which are toxic
to humans are toxic to bacteria, and some chemicals which are toxic
to bacteria are harmless to humans (which is why we can have
antibiotics).
There are chemicals (like Hydrogen Sulfide) which are very toxic
to mammals that SOME bacteria eat as food.
But there are other chemicals like chlorine which are toxic to
both humans and bacteria.
So the question does not have a simple answer.