#include #include #include #include #include #include "torch_npu/csrc/core/npu/NPUCachingAllocator.h" extern "C" { using c10_npu::NPUCachingAllocator::DeviceStats; static bool useflag = false; void* my_malloc(ssize_t size, int device, aclrtStream stream) { void *ptr; aclrtMallocAlign32(&ptr, size, aclrtMemMallocPolicy::ACL_MEM_MALLOC_HUGE_FIRST); std::cout<<"alloc ptr = "<