|Summary:||KASAN: instrument atomicops/bitops|
|Product:||Memory Management||Reporter:||Dmitry Vyukov (dvyukov)|
|Component:||Sanitizers||Assignee:||Dmitry Vyukov (dvyukov)|
Description Dmitry Vyukov 2018-01-10 14:27:46 UTC
KASAN currently does not instrument atomic operations implemented in assembly. They can lead to silent, undetected memory corruptions. It should. There is a reference patch for this: https://groups.google.com/forum/#!msg/kasan-dev/3r3Wa8C4RHA/yn2M1B3mAQAJ It was even merged once, but then reverted. Need to update and resubmit.
Comment 1 Dmitry Vyukov 2018-04-10 09:49:34 UTC
Atomic operations are done in a35353bb9eb19. But we also need to handle bitops as lots of them are in asm.
Comment 2 Dmitry Vyukov 2018-09-13 12:45:45 UTC
FTR, here is an old bitops patch: https://lore.kernel.org/patchwork/patch/772571/ Most likely needs to be all redone now, but at least can serve as a base list of what needs to be instrumented.
Comment 3 Marco Elver 2019-06-19 14:10:46 UTC
Comment 4 Dmitry Vyukov 2019-06-20 09:41:54 UTC