G is the generation. The last HP servers I had control of were G5s. Generally the chipsets (and, as such, processor support, memory support, etc) change by generation. The XX### is the model number.
For example, where I used to work, we had a bunch of HP servers. Two of which were DL380s. (actually we had about 10.... but irrelevant)
However, One was a G3 and the other was a G5.
The G3 used a first generation Xeon (based on a pentium 4, I think). It could use a Max of 12gb ram. The G5 used two quad core XEON E5400s. It could use a max of 64gb.
Some of these numbers might be off (this is recollection from 2008, after all).
So, Like I said, the G# is the generational number... much like a 1995 Ford mustang and a 2005 Ford mustang are both Ford Mustangs... but really they are completely different machines.