When I was looking to buy a gun, I shot a bunch of different guns. At one point, I had a fullsize XD 9mm and a fullsize Glock in 9mm. I shot them both back, to back, to back several times trying to figure out which I liked better. They were VERY similar. Granted, at the time, I was very new to guns and had never owned a handgun. I chose to buy an XD (XDM9 4.5 to be exact) I never could put my finger on why I liked the XD more than the Glock, but I did like it a little more.
The whole Glock vs XD thing is much like Camaro vs Mustang, Nikon vs Canon, etc.... Any time you have two different things that are compared that much and that closely, it's probably because they are both great items.
There is a reason that Glocks are EVERYWHERE! They are obviously great guns that have been proven the world over. Personally, I prefer an XD, but I wouldn't cry myself to sleep if my only option was a Glock.
On a related note, I just took my CHL class (Texas ver of CCW) yesterday. I've got a full size XDM. I'm going to get a holster and carry it for a bit, but I'm already planning on getting a smaller carry gun. I'd sort of considered something like a Kahr P9 (not the PM9, the P9 which is slightly larger) which is a single stack 9mm. Looking at the specs for the XD9SC and the P9, they are basically the same size except that the P9 is a fair amount thinner. Based on that, I'm thinking that I may just stick with a compact sized XD of some flavor. I hadn't been keeping up with what SA was doing with the XD and XDM line that closely for the last 6-8 months. Just today, I noticed that SA has just released an XDM9 compact. Other than the XD vs XDM differences, the main difference between the two seems to be that the XDM9C3.8 has a .8" longer barrel.
I have a feeling, that ultimately, I'm going to end up with the XDM9C 3.8. It'll be nice to have 2 guns that are basically the same gun other than size.