• Paul E. McKenney's avatar
    doc: Remove arrayRCU.rst · ef2555cf
    Paul E. McKenney authored
    Although RCU can in theory be used to protect array indexes in a manner
    similar to the way it protects pointers, doing so is extremely risky
    because of the huge number of optimizations that modern compilers can
    apply to integral types.
    
    For but one example, if your code can be configured such that your array
    contains only a single element, then indexing that array with any integer
    other than zero invokes undefined behavior, which in turn means that
    the compiler is within its rights to assume (without checking!) that any
    integer used as an index to that array has the value zero.  Therefore,
    the compiler can index the array with the constant zero, which breaks
    any dependencies that might have otherwise existed between the time the
    actual value was loaded and the time that the array was indexed.
    
    This commit therefore removes the arrayRCU.rst file that describes how
    to go about carrying dependencies through array indexes.
    Signed-off-by: default avatarPaul E. McKenney <paulmck@kernel.org>
    ef2555cf
index.rst 563 Bytes