• Tom Lane's avatar
    Work around gcc 4.6.0 bug that breaks WAL replay. · c2ba0121
    Tom Lane authored
    ReadRecord's habit of using both direct references to tmpRecPtr and
    references to *RecPtr (which is pointing at tmpRecPtr) triggers an
    optimization bug in gcc 4.6.0, which apparently has forgotten about
    aliasing rules.  Avoid the compiler bug, and make the code more readable
    to boot, by getting rid of the direct references.  Improve the comments
    while at it.
    
    Back-patch to all supported versions, in case they get built with 4.6.0.
    
    Tom Lane, with some cosmetic suggestions from Alex Hunsaker
    c2ba0121
xlog_internal.h 9.05 KB