Skip to content

Commit 185236a

Browse files
yoneymeta-codesync[bot]
authored andcommitted
Fix minor issues
Summary: Add missing log parameter and moved misplaced '}' Reviewed By: alexmalyshev Differential Revision: D91694841 fbshipit-source-id: 42ece55a1d66e81421d8d242196eef7a2cd9afc9
1 parent 5ec5965 commit 185236a

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

cinderx/Jit/code_allocator.cpp

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,10 @@ bool setHugePages([[maybe_unused]] void* ptr, [[maybe_unused]] size_t size) {
6161

6262
auto end = static_cast<void*>(static_cast<uint8_t*>(ptr) + size);
6363
JIT_LOG(
64-
"Failed to madvise [{}, {}) with MADV_HUGEPAGE, errno=", ptr, end, errno);
64+
"Failed to madvise [{}, {}) with MADV_HUGEPAGE, errno={}",
65+
ptr,
66+
end,
67+
errno);
6568
#endif
6669

6770
return false;
@@ -126,10 +129,10 @@ CodeAllocatorCinder::~CodeAllocatorCinder() {
126129
#ifndef WIN32
127130
JIT_CHECK(
128131
munmap(alloc.data(), alloc.size()) == 0, "Freeing code memory failed");
129-
}
130132
#else
131133
VirtualFree(alloc.data(), 0, MEM_RELEASE);
132134
#endif
135+
}
133136
}
134137

135138
AllocateResult CodeAllocatorCinder::addCode(asmjit::CodeHolder* code) {
@@ -209,7 +212,7 @@ MultipleSectionCodeAllocator::~MultipleSectionCodeAllocator() {
209212
munmap(code_alloc_, total_allocation_size_) == 0,
210213
"Freeing code sections failed");
211214
#else
212-
VirtualFree(code_alloc_, 0, MEM_RELEASE);
215+
VirtualFree(code_alloc_, 0, MEM_RELEASE);
213216
#endif
214217
}
215218

0 commit comments

Comments
 (0)