+ if (folly::kIsDebug) {
+ // We can't do partial unmapping with Windows, so
+ // assert that we aren't trying to do that if we're
+ // in debug mode.
+ MEMORY_BASIC_INFORMATION inf;
+ VirtualQuery(addr, &inf, sizeof(inf));
+ assert(inf.AllocationBase == addr);
+
+ auto deb = (MemMapDebugTrailer*)((char*)addr + length);
+ assert(deb->length == length);
+ assert(deb->magic == kMMapLengthMagic);
+ }
+ if (!VirtualFree(addr, 0, MEM_RELEASE)) {