diff options
author | Ben Gamari <bgamari.foss@gmail.com> | 2016-11-29 16:51:30 -0500 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2016-11-29 16:51:30 -0500 |
commit | 428e152be6bb0fd3867e41cee82a6d5968a11a26 (patch) | |
tree | e43d217c10c052704f872cd7e1df4d335c12d376 /rts/posix/OSMem.c | |
parent | 56d74515396c8b6360ba7898cbc4b68f0f1fb2ea (diff) | |
download | haskell-428e152be6bb0fd3867e41cee82a6d5968a11a26.tar.gz |
Use C99's bool
Test Plan: Validate on lots of platforms
Reviewers: erikd, simonmar, austin
Reviewed By: erikd, simonmar
Subscribers: michalt, thomie
Differential Revision: https://phabricator.haskell.org/D2699
Diffstat (limited to 'rts/posix/OSMem.c')
-rw-r--r-- | rts/posix/OSMem.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/rts/posix/OSMem.c b/rts/posix/OSMem.c index febeffbd98..5291745d53 100644 --- a/rts/posix/OSMem.c +++ b/rts/posix/OSMem.c @@ -130,10 +130,10 @@ my_mmap (void *addr, W_ size, int operation) { if(addr) // try to allocate at address err = vm_allocate(mach_task_self(),(vm_address_t*) &ret, - size, FALSE); + size, false); if(!addr || err) // try to allocate anywhere err = vm_allocate(mach_task_self(),(vm_address_t*) &ret, - size, TRUE); + size, true); } if(err) { @@ -145,7 +145,7 @@ my_mmap (void *addr, W_ size, int operation) } if(operation & MEM_COMMIT) { - vm_protect(mach_task_self(), (vm_address_t)ret, size, FALSE, + vm_protect(mach_task_self(), (vm_address_t)ret, size, false, VM_PROT_READ|VM_PROT_WRITE); } @@ -399,7 +399,7 @@ StgWord64 getPhysicalMemorySize (void) return physMemSize; } -void setExecutable (void *p, W_ len, rtsBool exec) +void setExecutable (void *p, W_ len, bool exec) { StgWord pageSize = getPageSize(); @@ -562,12 +562,12 @@ void osReleaseHeapMemory(void) #endif -rtsBool osNumaAvailable(void) +bool osNumaAvailable(void) { #if HAVE_LIBNUMA return (numa_available() != -1); #else - return rtsFalse; + return false; #endif } |