MCPcopy Create free account
hub / github.com/PaddlePaddle/Paddle / ptr

Method ptr

paddle/phi/core/allocator.h:62–62  ·  view source on GitHub ↗

Returns the holding pointer. NOTE(liujinnan): Make this method as a virtual method. Because we add memory compact func for VirtualMemoryAutoGrowthBestFitAllocator. it will change ptr_ for defragmentation.

Source from the content-addressed store, hash-verified

60 // memory compact func for VirtualMemoryAutoGrowthBestFitAllocator. it will
61 // change ptr_ for defragmentation.
62 virtual void* ptr() const noexcept { return ptr_; }
63 void set_ptr(void* new_ptr) noexcept { ptr_ = new_ptr; }
64
65 uint64_t id() const noexcept { return id_; }

Callers 15

initializedFunction · 0.45
mutable_dataMethod · 0.45
dataMethod · 0.45
init_holderMethod · 0.45
AllocateFromMethod · 0.45
mutable_dataMethod · 0.45
initializedFunction · 0.45
CopyToCPUHelperFunction · 0.45
CopyCPUDataToCUDAHelperFunction · 0.45
CUDADataMethod · 0.45
AllocateFromMethod · 0.45
dataMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected