• A
    On crash memory test rewrote so that it actaully works. · cd99c14e
    antirez 提交于
    1) We no longer test location by location, otherwise the CPU write cache
    completely makes our business useless.
    2) We still need a memory test that operates in steps from the first to
    the last location in order to never hit the cache, but that is still
    able to retain the memory content.
    
    This was tested using a Linux box containing a bad memory module with a
    zingle bit error (always zero).
    
    So the final solution does has an error propagation step that is:
    
    1) Invert bits at every location.
    2) Swap adiacent locations.
    3) Swap adiacent locations again.
    4) Invert bits at every location.
    5) Swap adiacent locations.
    6) Swap adiacent locations again.
    
    Before and after these steps, and after step 4, a CRC64 checksum is computed.
    If the three CRC64 checksums don't match, a memory error was detected.
    cd99c14e
memtest.c 9.2 KB