Home
last modified time | relevance | path

Searched refs:MmapHandle (Results 1 – 6 of 6) sorted by relevance

/external/libtextclassifier/utils/memory/
Dmmap.h40 class MmapHandle {
42 MmapHandle(void *start, size_t num_bytes, void *unmap_addr = nullptr)
99 MmapHandle MmapFile(const std::string &filename);
102 MmapHandle MmapFile(int fd);
109 MmapHandle MmapFile(int fd, int64 segment_offset, int64 segment_size);
113 bool Unmap(MmapHandle mmap_handle);
133 const MmapHandle &handle() { return handle_; } in handle()
136 MmapHandle handle_;
Dmmap.cc35 inline MmapHandle GetErrorMmapHandle() { return MmapHandle(nullptr, 0); } in GetErrorMmapHandle()
56 MmapHandle MmapFile(const std::string &filename) { in MmapFile()
73 MmapHandle MmapFile(int fd) { in MmapFile()
85 MmapHandle MmapFile(int fd, int64 segment_offset, int64 segment_size) { in MmapFile()
118 return MmapHandle(static_cast<char *>(mmap_addr) + alignment_shift, in MmapFile()
122 bool Unmap(MmapHandle mmap_handle) { in Unmap()
/external/libtextclassifier/lang_id/common/file/
Dmmap.h40 class MmapHandle {
42 MmapHandle(void *start, size_t num_bytes) in MmapHandle() function
86 MmapHandle MmapFile(const string &filename);
89 MmapHandle MmapFile(int fd);
93 bool Unmap(MmapHandle mmap_handle);
111 const MmapHandle &handle() { return handle_; } in handle()
114 MmapHandle handle_;
Dmmap.cc38 inline MmapHandle GetErrorMmapHandle() { in GetErrorMmapHandle()
39 return MmapHandle(nullptr, 0); in GetErrorMmapHandle()
59 MmapHandle MmapFile(const string &filename) { in MmapFile()
76 MmapHandle MmapFile(int fd) { in MmapFile()
116 return MmapHandle(mmap_addr, file_size_in_bytes); in MmapFile()
119 bool Unmap(MmapHandle mmap_handle) { in Unmap()
Dfile-utils.cc34 const MmapHandle &handle = scoped_mmap.handle(); in GetFileContent()
Dfile-utils.h63 const MmapHandle &handle = scoped_mmap.handle(); in ReadProtoFromFile()