| 366 | } |
| 367 | |
| 368 | bool DefaultMemoryManager::isUserLocked(const void *ptr) { |
| 369 | memory_info ¤t = this->getCurrentMemoryInfo(); |
| 370 | lock_guard_t lock(this->memory_mutex); |
| 371 | auto locked_iter = current.locked_map.find(const_cast<void *>(ptr)); |
| 372 | if (locked_iter == current.locked_map.end()) { return false; } |
| 373 | return locked_iter->second.user_lock; |
| 374 | } |
| 375 | |
| 376 | size_t DefaultMemoryManager::getMemStepSize() { |
| 377 | lock_guard_t lock(this->memory_mutex); |