I really don't recall the original details. But after the Sigma debacle, Smith had to come up with a new design or they were going to be left behind by the LE market. In my opinion, it was a do or die time in their history. They went back to the drawing board and came up with a gun that addressed the weaknesses in the Glock design. Namely the grip angle and control designs. The trigger was comparable, but didn't have the reset of the Glock, because the M&P is fully cocked after cycling. As
@ArtVandelay referred, it was supposed to be a product improved Glock. The locking block and sear block are beefier too, incorporating the slide rails into the blocks, instead of molding them into the frame.
The trigger has always been the weak point of the M&P. But the most recent revisions are pretty darn good. They're using the performance center sear, which is similar to the Apex Duty sear. And improvements to the trigger bar have improved reset considerably. It's very usable right out of the box. But for a little more coin, you can drop in an Apex DCAEK or FSS. The FSS is the best striker trigger I've ever used. And with a new M&P selling for $399, even with a replacement trigger, you're in Gen4 Glock territory.
My father has an xdm. God, I hate that gun...