Have both. The TX 22 is the first Taurus I have bought in a long time. It has been flawless. In my first two and a half weeks I have ran close to 1500 rounds through it and not one problem. Great trigger, feeds anything, very accurate,
16+1 round magazines. Solid little pistol.
M&P Compact. Thousands of rounds through it. Very seldom any problems with it. In fact I wore the firing pin and spring out I shot it so much. Smith sent me a shipping label. Had it back in two weeks fixed. Great customer service. My previous experience with Taurus Customer service is not good. Hope I don't need it.
Have several M&P's that I CCW. The Compact was to be a sub caliber trainer for the bigger guns. Trigger, sights, everything pretty much M&P. Except it is more like a single stack Shield in the grip department. Had to put some Talon grips on mine to get a good purchase. Grip really tiny for my hands.
The Taurus is a great sub caliber generic trainer for the current crop of G19 sized guns. So to me each one has it's own purpose. Either will be excellent for a fun plinker, trainer for beginners, trail gun. The M&P would be easier to carry do to it's smaller size on walks on the trails. The Taurus would give you 16+1 rounds in a larger package. Just have to figure out which would meet your needs better. Both excellent little .22's. And not picky on ammo like a lot of the newer .22's.