God forgive me for getting sucked into this silly argument, but I just wanted to throw my 2 cents in. It so happens I am writing a book in which mechs will eventually both fight against and in support of tanks. First of all, I don't know if you're talking about mechs like the giant robots in animes like Gundam or Macross, or like the compact fighting vehicles in Matrix Revolutions and Avatar. The "mechs" in my book are similar to the latter - small vehicles that look more like a one-person tank with arms and legs rather than a giant, flying, metal samari. They belong to a race of good elf-like aliens called Tartarquians who ally with modern day, tank equipped humans to fight against the evil humanoid aliens called Nladisha who also use tanks.
The mechs have an advantage over tanks in several ways. They are light and manuverable, responding to the commands of thier pilots as easily as limbs respond to nerve impulses. They combine the electronics of a modern fighting vehicle with the mobility of an infantryman. They can dash across a battlefield, dodging shellfire and bombs to fire large calibre weapons (in my case, energy weapons) at enemy targets. It's like giving an infantryman a tank gun.
Now for the downside: armor - or lack of. To gain speed and mobility, the mechs in my book sacrifice armor. According to the back-story (still in progress so there are still holes in it), the Tartarquians leapt straight from crude ballistic weapons - rocks launched from mechanical contraptions such as trebuchettes and catapults - to energy weapons without first stopping at chemical explosives. Therefore, thier mechs originally had thin armor to protect the drivers from rocks and crossbow bolts, while using energy shields to protect themselves from blaster rifles and energy cannons. The Nladisha, on the other hand were still using chemical explosives when they first met the Tartarquians in battle - basically rocket assisted armor piercing sabots that bored through vehicle armor to deliver an explosive warhead into the hollow cavities of a vehicle. The results were as follows:
The Tartarquian mechs charged headlong into the Nladisha armored formations and proceeded to shoot them as piecemeal as hunters shooting a herd of buffalo. They dodged this way and that to avoid shell fire, and occasionally used thier limbs to overturn tanks or rip off thier turrets. The tanks were dragged down by thier armor and the inability of thier tracks to steer fast enough. Aiming was especially hard because of the lag time needed for the hydralics to adjust the turret orientation and the gun elevation. The mechs, on the other hand could swivel at all thier joints as easily as a person with a rifle. As I have seen from the few mech related media I have watched, this is what a mech does best.
Now for the bad part. Because the Tartarquians placed a greater emphisis on mobility and speed (plus thier reliance on energy shields, which, in my story are useless against kinetic energy from solid projectiles) the hypersonic, solid tank shells were able to pierce vital components of the mechs, including the driver's compartment, to explode and destroy the mech. The mechs' mobility was only as good as thier pilots' reflexes. Though the mechs could deflect the shells with solid parts of thier "bodies", the impact of the shell and the shock its detonation were enough to damage other parts of the mech and/or disable it - kinda like getting hit with a BB. Combined with other factors, in my story, the Tartarquians couldn't fully use the advantages of thier mechs and had to withdraw. By the time my story takes place, the Tartarquians had added some armor, but it was still not as thick as it should have been - just enough to stop thirty-millimeter shell fire. Thier emphasis was still on speed and mobility.
Now how does this rambling have anything to do with the question at hand? Mechs have the advantage in speed and mobility to fight in any terrain an infantryman can like a great metal giant. However, unless one can develop engines and servos powerful enough and a design capable enough to move and balance the incredible wieght of a mecha's armor in any position and configuration, a mech's survivability against massed tanks is only as good as its driver's ability to literally dodge bullets.
Note: I'd appreciate if any anime or military nerds out there do not attack me with thier attention to details and realistic facts. I do not saturate myself with research or war gaming, so I probably do not know as much as some of the others do about this subject. Again, God forgive me for getting sucked into this.