fixup; hw: always serialize rdtsc reads

Since rdtsc() provides ordered timestamps now, we should reordering of
statements by the compiler too.

Issues #5215, #5430
This commit is contained in:
Benjamin Lamowski
2025-01-22 09:57:44 +01:00
committed by Christian Helmuth
parent 27c2064a3c
commit 004aaf0235

View File

@@ -122,6 +122,8 @@ struct Hw::Tsc
"rdtsc;"
"lfence;"
: "=a"(low), "=d"(high)
:
: "memory"
);
return (Genode::uint64_t)(high) << 32 | low;
}