qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* plugins: Missing Store Exclusive Memory Accesses
@ 2021-09-16 20:44 Aaron Lindsay
  2021-09-17 11:05 ` Alex Bennée
  0 siblings, 1 reply; 11+ messages in thread
From: Aaron Lindsay @ 2021-09-16 20:44 UTC (permalink / raw)
  To: qemu-devel, Alex Bennée; +Cc: cota, richard.henderson

Hello,

I recently noticed that the plugin interface does not appear to be
emitting callbacks to functions registered via
`qemu_plugin_register_vcpu_mem_cb` for AArch64 store exclusives. This
would include instructions like `stxp  w16, x2, x3, [x4]` (encoding:
0xc8300c82). Seeing as how I'm only running with a single CPU, I don't
see how this could be due to losing exclusivity after the preceding
`ldxp`.

In looking at QEMU's source, I *think* this is because the
`gen_store_exclusive` function in translate-a64.c is not making the same
calls to `plugin_gen_mem_callbacks` & company that are being made by
"normal" stores handled by functions like `tcg_gen_qemu_st_i64` (at
least in my case; I do see some code paths under `gen_store_exclusive`
call down into `tcg_gen_qemu_st_i64` eventually, but it appears not all
of them do?).

Does my initial guess check out? And, if so, does anyone have insight
into how to fix this issue most cleanly/generically? I suspect if/when I
debug my particular case I can discover one code path to fix, but I'm
wondering if my discovery may be part of a larger class of cases which
fell through the cracks and ought to be fixed together.

Thanks for any help,

Aaron


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2021-10-22  8:58 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-16 20:44 plugins: Missing Store Exclusive Memory Accesses Aaron Lindsay
2021-09-17 11:05 ` Alex Bennée
2021-09-17 14:44   ` Aaron Lindsay via
2021-09-21 20:28   ` Aaron Lindsay via
2021-09-22 20:22     ` Aaron Lindsay via
2021-10-20 17:12       ` Aaron Lindsay via
2021-10-20 17:54         ` Alex Bennée
2021-10-20 20:49           ` Aaron Lindsay via
2021-10-21 12:28             ` Alex Bennée
2021-10-21 20:40               ` Aaron Lindsay via
2021-10-22  8:37                 ` Alex Bennée

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).