llvm.org GIT mirror llvm / 799ed10
Stub out some sys::Path::MapInFilePages/UnMapFilePages methods. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49030 91177308-0d34-0410-b5e6-96231b3b80d8 Chris Lattner 12 years ago
3 changed file(s) with 45 addition(s) and 2 deletion(s). Raw diff Collapse all Expand all
543543 /// @brief Removes the file or directory from the filesystem.
544544 bool eraseFromDisk(bool destroy_contents = false,
545545 std::string *Err = 0) const;
546
547
548 /// MapInFilePages - This is a low level system API to map in the file
549 /// that is currently opened as FD into the current processes' address
550 /// space for read only access. This function may return null on failure
551 /// or if the system cannot provide the following constraints:
552 /// 1) The pages must be valid after the FD is closed, until
553 /// UnMapFilePages is called.
554 /// 2) Any padding after the end of the file must be zero filled, if
555 /// present.
556 /// 3) The pages must be contiguous.
557 ///
558 /// This API is not intended for general use, clients should use
559 /// MemoryBuffer::getFile instead.
560 static const char *MapInFilePages(int FD, uint64_t FileSize);
561
562 /// UnMapFilePages - Free pages mapped into the current process by
563 /// MapInFilePages.
564 ///
565 /// This API is not intended for general use, clients should use
566 /// MemoryBuffer::getFile instead.
567 static void UnMapFilePages(const char *Base, uint64_t FileSize);
568
546569 /// @}
547570 /// @name Data
548571 /// @{
744744 return false;
745745 }
746746
747 /// MapInFilePages - Not yet implemented on win32.
748 const char *Path::MapInFilePages(int FD, uint64_t FileSize) {
749 return 0;
750 }
751
752 /// MapInFilePages - Not yet implemented on win32.
753 void Path::UnMapFilePages(const char *Base, uint64_t FileSize) {
754 assert(0 && "NOT IMPLEMENTED");
755 }
756
747757 } // end llvm namespace
748758
772772 return false;
773773 }
774774
775 }
776 }
775 /// MapInFilePages - Not yet implemented on win32.
776 const char *Path::MapInFilePages(int FD, uint64_t FileSize) {
777 return 0;
778 }
779
780 /// MapInFilePages - Not yet implemented on win32.
781 void Path::UnMapFilePages(const char *Base, uint64_t FileSize) {
782 assert(0 && "NOT IMPLEMENTED");
783 }
784
785 }
786 }