mirror of
https://github.com/jemalloc/jemalloc.git
synced 2026-08-25 16:43:33 +03:00
Use asm volatile during benchmarks.
This commit is contained in:
parent
e8b28908de
commit
09e4b38fb1
6 changed files with 51 additions and 7 deletions
|
|
@ -9,6 +9,7 @@ large_mallocx_free(void) {
|
|||
*/
|
||||
void *p = mallocx(SC_LARGE_MINCLASS, MALLOCX_TCACHE_NONE);
|
||||
assert_ptr_not_null(p, "mallocx shouldn't fail");
|
||||
p = no_opt_ptr(p);
|
||||
free(p);
|
||||
}
|
||||
|
||||
|
|
@ -16,6 +17,7 @@ static void
|
|||
small_mallocx_free(void) {
|
||||
void *p = mallocx(16, 0);
|
||||
assert_ptr_not_null(p, "mallocx shouldn't fail");
|
||||
p = no_opt_ptr(p);
|
||||
free(p);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue