There is another important issue that is not 'accuracy' as such, but rather the frequency at which elevation is recorded. For example, I did a couple of DIY 200s last month - one from London to Norfolk and the other the exact reverse of the journey. For the trip north I set the GPS track recording to 'high' resolution. This gave a total distance of 225km and total height gain of 1694m. For the return journey, I set the GPS track recording to 'medium'. The total recorded distance was again 225km, but elevation gain was 1215m. This is because as a proportion of the total distance travelled in the horizontal and vertical planes, the vertical profile tends to be much more sinuous than the planimetric profile.
In other words, there isn't a meaningfully 'true' elevation gain on a ride. Rather, we need to have an approximately agreed resolution at which we measure elevation before climbing figures can be compared. This is why I like AUK's 'contour counting' as a standardised way of describing climb. An alternative is to plot your route over a standard Digital Elevation Model (and I'd strongly recommend Ordnance Survey's, now free, 50m DEM) and use software to calculate gain.