File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
compiler-rt/lib/scudo/standalone Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -1081,6 +1081,11 @@ class Allocator {
1081
1081
// An array of Size (at least one) elements of type Entry is immediately
1082
1082
// following to this struct.
1083
1083
};
1084
+ static_assert (sizeof (AllocationRingBuffer) %
1085
+ alignof(typename AllocationRingBuffer::Entry) ==
1086
+ 0,
1087
+ "invalid alignment");
1088
+
1084
1089
// Pointer to memory mapped area starting with AllocationRingBuffer struct,
1085
1090
// and immediately followed by Size elements of type Entry.
1086
1091
atomic_uptr RingBufferAddress = {};
@@ -1585,10 +1590,6 @@ class Allocator {
1585
1590
1586
1591
atomic_store (&RingBufferAddress, reinterpret_cast <uptr>(RB),
1587
1592
memory_order_release);
1588
- static_assert (sizeof (AllocationRingBuffer) %
1589
- alignof (typename AllocationRingBuffer::Entry) ==
1590
- 0 ,
1591
- " invalid alignment" );
1592
1593
}
1593
1594
1594
1595
void unmapRingBuffer () {
You can’t perform that action at this time.
0 commit comments