README 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. This directory contains the following litmus tests:
  2. CoRR+poonceonce+Once.litmus
  3. Test of read-read coherence, that is, whether or not two
  4. successive reads from the same variable are ordered.
  5. CoRW+poonceonce+Once.litmus
  6. Test of read-write coherence, that is, whether or not a read
  7. from a given variable followed by a write to that same variable
  8. are ordered.
  9. CoWR+poonceonce+Once.litmus
  10. Test of write-read coherence, that is, whether or not a write
  11. to a given variable followed by a read from that same variable
  12. are ordered.
  13. CoWW+poonceonce.litmus
  14. Test of write-write coherence, that is, whether or not two
  15. successive writes to the same variable are ordered.
  16. IRIW+fencembonceonces+OnceOnce.litmus
  17. Test of independent reads from independent writes with smp_mb()
  18. between each pairs of reads. In other words, is smp_mb()
  19. sufficient to cause two different reading processes to agree on
  20. the order of a pair of writes, where each write is to a different
  21. variable by a different process? This litmus test is forbidden
  22. by LKMM's propagation rule.
  23. IRIW+poonceonces+OnceOnce.litmus
  24. Test of independent reads from independent writes with nothing
  25. between each pairs of reads. In other words, is anything at all
  26. needed to cause two different reading processes to agree on the
  27. order of a pair of writes, where each write is to a different
  28. variable by a different process?
  29. ISA2+pooncelock+pooncelock+pombonce.litmus
  30. Tests whether the ordering provided by a lock-protected S
  31. litmus test is visible to an external process whose accesses are
  32. separated by smp_mb(). This addition of an external process to
  33. S is otherwise known as ISA2.
  34. ISA2+poonceonces.litmus
  35. As below, but with store-release replaced with WRITE_ONCE()
  36. and load-acquire replaced with READ_ONCE().
  37. ISA2+pooncerelease+poacquirerelease+poacquireonce.litmus
  38. Can a release-acquire chain order a prior store against
  39. a later load?
  40. LB+fencembonceonce+ctrlonceonce.litmus
  41. Does a control dependency and an smp_mb() suffice for the
  42. load-buffering litmus test, where each process reads from one
  43. of two variables then writes to the other?
  44. LB+poacquireonce+pooncerelease.litmus
  45. Does a release-acquire pair suffice for the load-buffering
  46. litmus test, where each process reads from one of two variables then
  47. writes to the other?
  48. LB+poonceonces.litmus
  49. As above, but with store-release replaced with WRITE_ONCE()
  50. and load-acquire replaced with READ_ONCE().
  51. MP+onceassign+derefonce.litmus
  52. As below, but with rcu_assign_pointer() and an rcu_dereference().
  53. MP+polockmbonce+poacquiresilsil.litmus
  54. Protect the access with a lock and an smp_mb__after_spinlock()
  55. in one process, and use an acquire load followed by a pair of
  56. spin_is_locked() calls in the other process.
  57. MP+polockonce+poacquiresilsil.litmus
  58. Protect the access with a lock in one process, and use an
  59. acquire load followed by a pair of spin_is_locked() calls
  60. in the other process.
  61. MP+polocks.litmus
  62. As below, but with the second access of the writer process
  63. and the first access of reader process protected by a lock.
  64. MP+poonceonces.litmus
  65. As below, but without the smp_rmb() and smp_wmb().
  66. MP+pooncerelease+poacquireonce.litmus
  67. As below, but with a release-acquire chain.
  68. MP+porevlocks.litmus
  69. As below, but with the first access of the writer process
  70. and the second access of reader process protected by a lock.
  71. MP+fencewmbonceonce+fencermbonceonce.litmus
  72. Does a smp_wmb() (between the stores) and an smp_rmb() (between
  73. the loads) suffice for the message-passing litmus test, where one
  74. process writes data and then a flag, and the other process reads
  75. the flag and then the data. (This is similar to the ISA2 tests,
  76. but with two processes instead of three.)
  77. R+fencembonceonces.litmus
  78. This is the fully ordered (via smp_mb()) version of one of
  79. the classic counterintuitive litmus tests that illustrates the
  80. effects of store propagation delays.
  81. R+poonceonces.litmus
  82. As above, but without the smp_mb() invocations.
  83. SB+fencembonceonces.litmus
  84. This is the fully ordered (again, via smp_mb() version of store
  85. buffering, which forms the core of Dekker's mutual-exclusion
  86. algorithm.
  87. SB+poonceonces.litmus
  88. As above, but without the smp_mb() invocations.
  89. SB+rfionceonce-poonceonces.litmus
  90. This litmus test demonstrates that LKMM is not fully multicopy
  91. atomic. (Neither is it other multicopy atomic.) This litmus test
  92. also demonstrates the "locations" debugging aid, which designates
  93. additional registers and locations to be printed out in the dump
  94. of final states in the herd7 output. Without the "locations"
  95. statement, only those registers and locations mentioned in the
  96. "exists" clause will be printed.
  97. S+poonceonces.litmus
  98. As below, but without the smp_wmb() and acquire load.
  99. S+fencewmbonceonce+poacquireonce.litmus
  100. Can a smp_wmb(), instead of a release, and an acquire order
  101. a prior store against a subsequent store?
  102. WRC+poonceonces+Once.litmus
  103. WRC+pooncerelease+fencermbonceonce+Once.litmus
  104. These two are members of an extension of the MP litmus-test
  105. class in which the first write is moved to a separate process.
  106. The second is forbidden because smp_store_release() is
  107. A-cumulative in LKMM.
  108. Z6.0+pooncelock+pooncelock+pombonce.litmus
  109. Is the ordering provided by a spin_unlock() and a subsequent
  110. spin_lock() sufficient to make ordering apparent to accesses
  111. by a process not holding the lock?
  112. Z6.0+pooncelock+poonceLock+pombonce.litmus
  113. As above, but with smp_mb__after_spinlock() immediately
  114. following the spin_lock().
  115. Z6.0+pooncerelease+poacquirerelease+fencembonceonce.litmus
  116. Is the ordering provided by a release-acquire chain sufficient
  117. to make ordering apparent to accesses by a process that does
  118. not participate in that release-acquire chain?
  119. A great many more litmus tests are available here:
  120. https://github.com/paulmckrcu/litmus