I've had an M&P9 for 4 years. The pistol initially had a real accuracy problem. But I will say that the pistol has learned to shoot much more accurately and will now do sub 2" groups at 15 yards. The pistol is pretty insensitive to ammo. The POI will move a little with bullet weight and mv, but I haven't seen any problems with function over a variety of bullet/powder combinations. The trigger has been good out of the box.
Last year I bought an SR9. Getting a nice, smooth trigger took a little work. The pistol did not like the loads I was using in the M&P and needed higher velocity loads to cycle. The barrel leaded and the accuracy was no better than 6" at 15 yards. I found that 115gr FMJ (Montana Gold) loaded to produce ~1150 fps solved all the function problems and the pistol learned to be very accurate, maybe better than the M&P.
Although I'm not a great fan of 9mm, I like both my 9mm pistols. They are both reliable and know how to shoot accurately. I believe, overall, the M&P may be a better pistol, largely based on the ammo insensitivity.
These are defensive firearms and are not built to the exacting tolerances of target firearms. However, once you get out of the realm of ammo problems, accuracy is something done by the shooter.