[PATCH] D68455: [builtins][test] Avoid unportable mmap call in clear_cache_test.c

Rainer Orth via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 22 01:44:50 PDT 2019


This revision was automatically updated to reflect the committed changes.
Closed by commit rG1876e6c83c7a: [builtins][test] Avoid unportable mmap call in clear_cache_test.c (authored by ro).

Changed prior to commit:
  https://reviews.llvm.org/D68455?vs=223183&id=226005#toc

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D68455/new/

https://reviews.llvm.org/D68455

Files:
  compiler-rt/test/builtins/Unit/clear_cache_test.c


Index: compiler-rt/test/builtins/Unit/clear_cache_test.c
===================================================================
--- compiler-rt/test/builtins/Unit/clear_cache_test.c
+++ compiler-rt/test/builtins/Unit/clear_cache_test.c
@@ -49,7 +49,7 @@
 #if !defined(_WIN32)
     uint8_t *execution_buffer = mmap(0, kSize,
                                      PROT_READ | PROT_WRITE | PROT_EXEC,
-                                     MAP_ANON | MAP_PRIVATE, 0, 0);
+                                     MAP_ANON | MAP_PRIVATE, -1, 0);
     if (execution_buffer == MAP_FAILED)
       return 1;
 #else


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D68455.226005.patch
Type: text/x-patch
Size: 599 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20191022/4ad505f7/attachment.bin>


More information about the llvm-commits mailing list