aboutsummaryrefslogtreecommitdiff
path: root/lib/System/Unix
diff options
context:
space:
mode:
authorReid Kleckner <reid@kleckner.net>2009-07-23 21:46:56 +0000
committerReid Kleckner <reid@kleckner.net>2009-07-23 21:46:56 +0000
commit10b4fc552f984dc978298d50c09c97c0764962fc (patch)
tree7176fba11d96f36811cc11aa39ce5bb23d217805 /lib/System/Unix
parent50340f666b5b1fceb2c781464779b4a0f583db9a (diff)
Re-committing r76828 with the JIT memory manager changes now that the build
bots like the BumpPtrAllocator changes. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76902 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/System/Unix')
-rw-r--r--lib/System/Unix/Memory.inc7
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/System/Unix/Memory.inc b/lib/System/Unix/Memory.inc
index b7a70135bc..a80f56fbc1 100644
--- a/lib/System/Unix/Memory.inc
+++ b/lib/System/Unix/Memory.inc
@@ -12,6 +12,7 @@
//===----------------------------------------------------------------------===//
#include "Unix.h"
+#include "llvm/Support/DataTypes.h"
#include "llvm/System/Process.h"
#ifdef HAVE_SYS_MMAN_H
@@ -28,12 +29,12 @@
/// is very OS specific.
///
llvm::sys::MemoryBlock
-llvm::sys::Memory::AllocateRWX(unsigned NumBytes, const MemoryBlock* NearBlock,
+llvm::sys::Memory::AllocateRWX(size_t NumBytes, const MemoryBlock* NearBlock,
std::string *ErrMsg) {
if (NumBytes == 0) return MemoryBlock();
- unsigned pageSize = Process::GetPageSize();
- unsigned NumPages = (NumBytes+pageSize-1)/pageSize;
+ size_t pageSize = Process::GetPageSize();
+ size_t NumPages = (NumBytes+pageSize-1)/pageSize;
int fd = -1;
#ifdef NEED_DEV_ZERO_FOR_MMAP