Share kStackAllocThreshold
This commit is contained in:
@@ -1297,6 +1297,8 @@ void VersionedMap::Impl::StepwiseFirstGeq::end() {
|
|||||||
loopEnd:;
|
loopEnd:;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
constexpr int kStackAllocThreshold = 2;
|
||||||
|
|
||||||
void VersionedMap::Impl::firstGeq(const weaselab::VersionedMap::Key *key,
|
void VersionedMap::Impl::firstGeq(const weaselab::VersionedMap::Key *key,
|
||||||
const int64_t *version, Iterator *iterator,
|
const int64_t *version, Iterator *iterator,
|
||||||
int count) const {
|
int count) const {
|
||||||
@@ -1306,7 +1308,6 @@ void VersionedMap::Impl::firstGeq(const weaselab::VersionedMap::Key *key,
|
|||||||
|
|
||||||
// Use stack allocation for small count
|
// Use stack allocation for small count
|
||||||
Arena arena;
|
Arena arena;
|
||||||
constexpr int kStackAllocThreshold = 2;
|
|
||||||
StepwiseFirstGeq stepwiseStackAlloc[kStackAllocThreshold];
|
StepwiseFirstGeq stepwiseStackAlloc[kStackAllocThreshold];
|
||||||
int nextJobStackAllocation[kStackAllocThreshold];
|
int nextJobStackAllocation[kStackAllocThreshold];
|
||||||
StepwiseFirstGeq *stepwise;
|
StepwiseFirstGeq *stepwise;
|
||||||
@@ -1354,7 +1355,6 @@ void VersionedMap::Impl::firstGeq(const weaselab::VersionedMap::Key *key,
|
|||||||
|
|
||||||
// Use stack allocation for small count
|
// Use stack allocation for small count
|
||||||
Arena arena;
|
Arena arena;
|
||||||
constexpr int kStackAllocThreshold = 2;
|
|
||||||
StepwiseFirstGeq stepwiseStackAlloc[kStackAllocThreshold];
|
StepwiseFirstGeq stepwiseStackAlloc[kStackAllocThreshold];
|
||||||
int nextJobStackAllocation[kStackAllocThreshold];
|
int nextJobStackAllocation[kStackAllocThreshold];
|
||||||
StepwiseFirstGeq *stepwise;
|
StepwiseFirstGeq *stepwise;
|
||||||
|
Reference in New Issue
Block a user