Commit c6476cb3 authored by Christopher Dykes's avatar Christopher Dykes Committed by Facebook Github Bot 5

Only try to use the membarrier on Linux

Summary: It doesn't exist anywhere else, and `syscall` isn't even defined on Windows, so this completely failed to compile before.

Reviewed By: yfeldblum

Differential Revision: D3623382

fbshipit-source-id: 302093ddc96d6465e0dcc1883747229a7fb25a84
parent 6d9473d8
......@@ -21,7 +21,8 @@
#include <folly/Portability.h>
#include <folly/portability/Unistd.h>
#if !defined(__NR_membarrier) && FOLLY_X64 && !FOLLY_MOBILE
#if !defined(__NR_membarrier) && FOLLY_X64 && !FOLLY_MOBILE && \
defined(__linux__)
#define __NR_membarrier 324
#define MEMBARRIER_CMD_QUERY 0
#define MEMBARRIER_CMD_SHARED 1
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment