File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed
Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -107,7 +107,7 @@ class geometric_stack {
107107 LF_ASSUME (push_bytes >= node_size);
108108 LF_ASSUME (push_bytes % node_size == 0 );
109109
110- // Optimized to just the subtrtaction because multiplication cancels the implicit division.
110+ // Optimized to just the subtraction because multiplication cancels the implicit division.
111111 diff_int free_bytes = node_size * (m_hi - m_sp);
112112
113113 if (push_bytes > free_bytes) [[unlikely]] {
@@ -148,7 +148,7 @@ class geometric_stack {
148148 }
149149
150150 [[nodiscard]]
151- constexpr auto prepare_release () const noexcept -> release_t {
151+ constexpr auto prepare_release () noexcept -> release_t {
152152
153153 // Guard against null release
154154 if (m_ctrl != nullptr ) {
Original file line number Diff line number Diff line change @@ -138,7 +138,7 @@ class slab_stack {
138138 }
139139
140140 [[nodiscard]]
141- constexpr auto prepare_release () const noexcept -> release_t {
141+ constexpr auto prepare_release () noexcept -> release_t {
142142 // Guard against null ctrl (failed prior allocation in release()).
143143 if (m_ctrl != nullptr ) {
144144 m_ctrl->sp_cache = m_sp;
@@ -165,6 +165,7 @@ class slab_stack {
165165
166166 constexpr void acquire (checkpoint_t ckpt) noexcept {
167167 LF_ASSUME (empty ());
168+ LF_ASSUME (ckpt.m_ctrl != m_ctrl);
168169
169170 if (ckpt.m_ctrl == nullptr ) {
170171 return ;
You can’t perform that action at this time.
0 commit comments