static void
dd_dump_dmesg(FILE *f)
{
-#ifdef PIPE_OS_LINUX
+#if DETECT_OS_LINUX
char line[2000];
FILE *p = popen("dmesg | tail -n60", "r");
static void
dd_kill_process(void)
{
-#ifdef PIPE_OS_UNIX
+#if DETECT_OS_UNIX
sync();
#endif
fprintf(stderr, "dd: Aborting the process...\n");
lp_native_vector_width = debug_get_num_option("LP_NATIVE_VECTOR_WIDTH",
lp_native_vector_width);
-#ifdef PIPE_ARCH_PPC_64
+#if DETECT_ARCH_PPC_64
/* Set the NJ bit in VSCR to 0 so denormalized values are handled as
* specified by IEEE standard (PowerISA 2.06 - Section 6.3). This guarantees
* that some rounding and half-float to float handling does not round
* can't handle. Not entirely sure if we really need to do anything yet.
*/
-#ifdef PIPE_ARCH_PPC_64
+#if DETECT_ARCH_PPC_64
/*
* Large programs, e.g. gnome-shell and firefox, may tax the addressability
* of the Medium code model once dynamically generated JIT-compiled shader
static int hud_scale = 1;
-#ifdef PIPE_OS_UNIX
+#if DETECT_OS_UNIX
static void
signal_visible_handler(int sig, siginfo_t *siginfo, void *context)
{
struct hud_context *hud;
unsigned i;
const char *env = debug_get_option("GALLIUM_HUD", NULL);
-#ifdef PIPE_OS_UNIX
+#if DETECT_OS_UNIX
unsigned signo = debug_get_num_option("GALLIUM_HUD_TOGGLE_SIGNAL", 0);
static boolean sig_handled = FALSE;
struct sigaction action;
list_inithead(&hud->pane_list);
/* setup sig handler once for all hud contexts */
-#ifdef PIPE_OS_UNIX
+#if DETECT_OS_UNIX
if (!sig_handled && signo != 0) {
action.sa_sigaction = &signal_visible_handler;
action.sa_flags = SA_SIGINFO;
#include "util/u_queue.h"
#include <stdio.h>
#include <inttypes.h>
-#ifdef PIPE_OS_WINDOWS
+#if DETECT_OS_WINDOWS
#include <windows.h>
#endif
#if DETECT_OS_BSD
#endif
-#ifdef PIPE_OS_WINDOWS
+#if DETECT_OS_WINDOWS
static inline uint64_t
filetime_to_scalar(FILETIME ft)
/* make this read a member of x86_function if target != host is desired */
static inline enum x86_target x86_target( struct x86_function* p )
{
-#ifdef PIPE_ARCH_X86
+#if DETECT_ARCH_X86
return X86_32;
#elif (DETECT_OS_CYGWIN || DETECT_OS_WINDOWS) && DETECT_ARCH_X86_64
return X86_64_WIN64_ABI;
#define TAG(x) x##_32_4
#define NR_PLANES 4
-#ifdef PIPE_ARCH_SSE
+#if DETECT_ARCH_SSE
#define TRI_16 lp_rast_triangle_32_4_16
#endif
#include "lp_rast_tri_tmp.h"
#include "nouveau_fence.h"
#include "util/os_time.h"
-#ifdef PIPE_OS_UNIX
+#if DETECT_OS_UNIX
#include <sched.h>
#endif
if (!spins)
NOUVEAU_DRV_STAT(screen, any_non_kernel_fence_sync_count, 1);
spins++;
-#ifdef PIPE_OS_UNIX
+#if DETECT_OS_UNIX
if (!(spins % 8)) /* donate a few cycles */
sched_yield();
#endif
group->map = pipe_buffer_map_range(upload->pipe, group->resource,
0, upload->buffers_size,
PIPE_MAP_WRITE |
-#ifdef PIPE_ARCH_X86
+#if DETECT_ARCH_X86
PIPE_MAP_ONCE |
#endif
PIPE_MAP_PERSISTENT |
buf->map = pipe_buffer_map_range(upload->pipe, buf->resource,
0, buffer_size,
PIPE_MAP_WRITE |
-#ifdef PIPE_ARCH_X86
+#if DETECT_ARCH_X86
PIPE_MAP_ONCE |
#endif
PIPE_MAP_PERSISTENT |
#define PIPE_UUID_SIZE 16
#define PIPE_LUID_SIZE 8
-#ifdef PIPE_OS_UNIX
+#if DETECT_OS_UNIX
#define PIPE_MEMORY_FD
#endif
/* armhf builds default to vfp, not neon, and refuses to compile neon intrinsics
* unless you tell it "no really".
*/
-#ifdef PIPE_ARCH_ARM
+#if DETECT_ARCH_ARM
#pragma GCC target ("fpu=neon")
#endif
util_format_unpack_description_neon(enum pipe_format format)
{
/* CPU detect for NEON support. On arm64, it's implied. */
-#ifdef PIPE_ARCH_ARM
+#if DETECT_ARCH_ARM
if (!util_get_cpu_caps()->has_neon)
return NULL;
#endif
#include <elf.h>
#endif
-#ifdef PIPE_OS_UNIX
+#if DETECT_OS_UNIX
#include <unistd.h>
#endif
}
#endif
-#ifdef PIPE_ARCH_X86
+#if DETECT_ARCH_X86
#if DETECT_CC_GCC && (PIPE_CC_GCC_VERSION > 404) || defined(__clang__)
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wframe-address"
return NULL;
}
-#ifdef PIPE_CC_GCC
+#if DETECT_CC_GCC
/*
* DbgHelp does not understand the debug information generated by MinGW toolchain.
*