From 0f18dd8be6b20ebb8b6e5904032cc7ead305e88c Mon Sep 17 00:00:00 2001 From: Douglas Rumbaugh Date: Thu, 8 Feb 2024 13:10:29 -0500 Subject: Added compiler fence to block reordering I'm reasonably certain that this is a compiler bug... --- include/shard/ISAMTree.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/shard') diff --git a/include/shard/ISAMTree.h b/include/shard/ISAMTree.h index 33ba82f..b52887a 100644 --- a/include/shard/ISAMTree.h +++ b/include/shard/ISAMTree.h @@ -65,6 +65,8 @@ public: sizeof(Wrapped), (byte**) &m_data); + asm volatile ("" ::: "memory"); + auto res = sorted_array_from_bufferview(std::move(buffer), m_data, m_bf); m_reccnt = res.record_count; m_tombstone_cnt = res.tombstone_count; -- cgit v1.2.3