Bug fix for superslab meta-data (#302)
* Replace time measuring macro The DO_TIME macro was used originally to get performance numbers. The macro makes tests hard to debug. This commit replaces it with a proper C++ class with destructor. * Bug fix If the superslab meta data is large, then the calculation for the sizeclasses that could use the short slab was incorrect. This fixes that calculation. Co-authored-by: Nathaniel Wesley Filardo <nfilardo@microsoft.com>
This commit is contained in:
committed by
GitHub
parent
04a185e634
commit
63f231f484
@@ -64,7 +64,9 @@ namespace test
|
||||
#endif
|
||||
setup(r, alloc);
|
||||
|
||||
DO_TIME("External pointer queries ", {
|
||||
{
|
||||
MeasureTime m;
|
||||
m << "External pointer queries ";
|
||||
for (size_t i = 0; i < iterations; i++)
|
||||
{
|
||||
size_t rand = (size_t)r.next();
|
||||
@@ -77,7 +79,7 @@ namespace test
|
||||
if (calced_external != external_ptr)
|
||||
abort();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
teardown(alloc);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user