I shopped the G17 vs the XD9 a while back (bought the XD). FYI - I'm not 100% sure how the G19 measures...
XD is slightly larger (good for me)
XD has much heavier/thicker slide (good for me)
XD has much better ergo (for my hand specifically)
Glock has cheaper accessories (wish the XD had cheaper aftermarket stuff)
Glock has great ergos (if your hand fits the finger grooves)
Glock is lighter (good for carry, etc)
Glock comes with hi-caps
If you're considering purchasing one or the other, PLEASE do yourself a favor and shoot both of them before buying one. I bought the G17, shot about 100 rounds and went back and traded for an XD 9. The glock was great, but just didn't fit my hand well. The XD was everything I wanted, minus the availability for aftermarket parts (most of which are available now).