FD.io VPP  v18.10-34-gcce845e
Vector Packet Processing
valgrind.h File Reference
+ Include dependency graph for valgrind.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  OrigFn
 

Macros

#define PLAT_amd64_linux   1
 
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request, _zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
 
#define VALGRIND_GET_NR_CONTEXT(_zzq_rlval)
 
#define VALGRIND_CALL_NOREDIR_RAX
 
#define VG_CONCAT4(_aa, _bb, _cc, _dd)   _aa##_bb##_cc##_dd
 
#define I_WRAP_SONAME_FNNAME_ZU(soname, fnname)   VG_CONCAT4(_vgwZU_,soname,_,fnname)
 
#define I_WRAP_SONAME_FNNAME_ZZ(soname, fnname)   VG_CONCAT4(_vgwZZ_,soname,_,fnname)
 
#define VALGRIND_GET_ORIG_FN(_lval)   VALGRIND_GET_NR_CONTEXT(_lval)
 
#define CALL_FN_v_v(fnptr)
 
#define CALL_FN_v_W(fnptr, arg1)
 
#define CALL_FN_v_WW(fnptr, arg1, arg2)
 
#define CALL_FN_v_WWW(fnptr, arg1, arg2, arg3)
 
#define CALL_FN_v_WWWW(fnptr, arg1, arg2, arg3, arg4)
 
#define CALL_FN_v_5W(fnptr, arg1, arg2, arg3, arg4, arg5)
 
#define CALL_FN_v_6W(fnptr, arg1, arg2, arg3, arg4, arg5, arg6)
 
#define CALL_FN_v_7W(fnptr, arg1, arg2, arg3, arg4, arg5, arg6, arg7)
 
#define CALL_FN_W_v(lval, orig)
 
#define CALL_FN_W_W(lval, orig, arg1)
 
#define CALL_FN_W_WW(lval, orig, arg1, arg2)
 
#define CALL_FN_W_WWW(lval, orig, arg1, arg2, arg3)
 
#define CALL_FN_W_WWWW(lval, orig, arg1, arg2, arg3, arg4)
 
#define CALL_FN_W_5W(lval, orig, arg1, arg2, arg3, arg4, arg5)
 
#define CALL_FN_W_6W(lval, orig, arg1, arg2, arg3, arg4, arg5, arg6)
 
#define CALL_FN_W_7W(lval, orig, arg1, arg2, arg3, arg4, arg5, arg6, arg7)
 
#define CALL_FN_W_8W(lval, orig, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8)
 
#define CALL_FN_W_9W(lval, orig, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9)
 
#define CALL_FN_W_10W(lval, orig, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10)
 
#define CALL_FN_W_11W(lval, orig, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11)
 
#define CALL_FN_W_12W(lval, orig, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9, arg10, arg11, arg12)
 
#define VG_USERREQ_TOOL_BASE(a, b)   ((unsigned int)(((a)&0xff) << 24 | ((b)&0xff) << 16))
 
#define VG_IS_TOOL_USERREQ(a, b, v)   (VG_USERREQ_TOOL_BASE(a,b) == ((v) & 0xffff0000))
 
#define RUNNING_ON_VALGRIND
 
#define VALGRIND_DISCARD_TRANSLATIONS(_qzz_addr, _qzz_len)
 
#define VALGRIND_NON_SIMD_CALL0(_qyy_fn)
 
#define VALGRIND_NON_SIMD_CALL1(_qyy_fn, _qyy_arg1)
 
#define VALGRIND_NON_SIMD_CALL2(_qyy_fn, _qyy_arg1, _qyy_arg2)
 
#define VALGRIND_NON_SIMD_CALL3(_qyy_fn, _qyy_arg1, _qyy_arg2, _qyy_arg3)
 
#define VALGRIND_COUNT_ERRORS
 
#define VALGRIND_MALLOCLIKE_BLOCK(addr, sizeB, rzB, is_zeroed)
 
#define VALGRIND_FREELIKE_BLOCK(addr, rzB)
 
#define VALGRIND_CREATE_MEMPOOL(pool, rzB, is_zeroed)
 
#define VALGRIND_DESTROY_MEMPOOL(pool)
 
#define VALGRIND_MEMPOOL_ALLOC(pool, addr, size)
 
#define VALGRIND_MEMPOOL_FREE(pool, addr)
 
#define VALGRIND_MEMPOOL_TRIM(pool, addr, size)
 
#define VALGRIND_MOVE_MEMPOOL(poolA, poolB)
 
#define VALGRIND_MEMPOOL_CHANGE(pool, addrA, addrB, size)
 
#define VALGRIND_MEMPOOL_EXISTS(pool)
 
#define VALGRIND_STACK_REGISTER(start, end)
 
#define VALGRIND_STACK_DEREGISTER(id)
 
#define VALGRIND_STACK_CHANGE(id, start, end)
 
#define VALGRIND_LOAD_PDB_DEBUGINFO(fd, ptr, total_size, delta)
 

Enumerations

enum  Vg_ClientRequest {
  VG_USERREQ__RUNNING_ON_VALGRIND = 0x1001, VG_USERREQ__DISCARD_TRANSLATIONS = 0x1002, VG_USERREQ__CLIENT_CALL0 = 0x1101, VG_USERREQ__CLIENT_CALL1 = 0x1102,
  VG_USERREQ__CLIENT_CALL2 = 0x1103, VG_USERREQ__CLIENT_CALL3 = 0x1104, VG_USERREQ__COUNT_ERRORS = 0x1201, VG_USERREQ__MALLOCLIKE_BLOCK = 0x1301,
  VG_USERREQ__FREELIKE_BLOCK = 0x1302, VG_USERREQ__CREATE_MEMPOOL = 0x1303, VG_USERREQ__DESTROY_MEMPOOL = 0x1304, VG_USERREQ__MEMPOOL_ALLOC = 0x1305,
  VG_USERREQ__MEMPOOL_FREE = 0x1306, VG_USERREQ__MEMPOOL_TRIM = 0x1307, VG_USERREQ__MOVE_MEMPOOL = 0x1308, VG_USERREQ__MEMPOOL_CHANGE = 0x1309,
  VG_USERREQ__MEMPOOL_EXISTS = 0x130a, VG_USERREQ__PRINTF = 0x1401, VG_USERREQ__PRINTF_BACKTRACE = 0x1402, VG_USERREQ__STACK_REGISTER = 0x1501,
  VG_USERREQ__STACK_DEREGISTER = 0x1502, VG_USERREQ__STACK_CHANGE = 0x1503, VG_USERREQ__LOAD_PDB_DEBUGINFO = 0x1601
}
 

Functions

static int VALGRIND_PRINTF (const char *format,...)
 
static int VALGRIND_PRINTF_BACKTRACE (const char *format,...)
 

Macro Definition Documentation

#define CALL_FN_v_5W (   fnptr,
  arg1,
  arg2,
  arg3,
  arg4,
  arg5 
)
Value:
do { volatile unsigned long _junk; \
CALL_FN_W_5W(_junk,fnptr,arg1,arg2,arg3,arg4,arg5); } while (0)
#define CALL_FN_W_5W(lval, orig, arg1, arg2, arg3, arg4, arg5)
Definition: valgrind.h:1176

Definition at line 623 of file valgrind.h.

#define CALL_FN_v_6W (   fnptr,
  arg1,
  arg2,
  arg3,
  arg4,
  arg5,
  arg6 
)
Value:
do { volatile unsigned long _junk; \
CALL_FN_W_6W(_junk,fnptr,arg1,arg2,arg3,arg4,arg5,arg6); } while (0)
#define CALL_FN_W_6W(lval, orig, arg1, arg2, arg3, arg4, arg5, arg6)
Definition: valgrind.h:1204

Definition at line 627 of file valgrind.h.

#define CALL_FN_v_7W (   fnptr,
  arg1,
  arg2,
  arg3,
  arg4,
  arg5,
  arg6,
  arg7 
)
Value:
do { volatile unsigned long _junk; \
CALL_FN_W_7W(_junk,fnptr,arg1,arg2,arg3,arg4,arg5,arg6,arg7); } while (0)
#define CALL_FN_W_7W(lval, orig, arg1, arg2, arg3, arg4, arg5, arg6,arg7)
Definition: valgrind.h:1234

Definition at line 631 of file valgrind.h.

#define CALL_FN_v_v (   fnptr)
Value:
do { volatile unsigned long _junk; \
CALL_FN_W_v(_junk,fnptr); } while (0)
#define CALL_FN_W_v(lval, orig)
Definition: valgrind.h:1066

Definition at line 603 of file valgrind.h.

#define CALL_FN_v_W (   fnptr,
  arg1 
)
Value:
do { volatile unsigned long _junk; \
CALL_FN_W_W(_junk,fnptr,arg1); } while (0)
#define CALL_FN_W_W(lval, orig, arg1)
Definition: valgrind.h:1084

Definition at line 607 of file valgrind.h.

#define CALL_FN_v_WW (   fnptr,
  arg1,
  arg2 
)
Value:
do { volatile unsigned long _junk; \
CALL_FN_W_WW(_junk,fnptr,arg1,arg2); } while (0)
#define CALL_FN_W_WW(lval, orig, arg1, arg2)
Definition: valgrind.h:1104

Definition at line 611 of file valgrind.h.

#define CALL_FN_v_WWW (   fnptr,
  arg1,
  arg2,
  arg3 
)
Value:
do { volatile unsigned long _junk; \
CALL_FN_W_WWW(_junk,fnptr,arg1,arg2,arg3); } while (0)
#define CALL_FN_W_WWW(lval, orig, arg1, arg2, arg3)
Definition: valgrind.h:1126

Definition at line 615 of file valgrind.h.

#define CALL_FN_v_WWWW (   fnptr,
  arg1,
  arg2,
  arg3,
  arg4 
)
Value:
do { volatile unsigned long _junk; \
CALL_FN_W_WWWW(_junk,fnptr,arg1,arg2,arg3,arg4); } while (0)
#define CALL_FN_W_WWWW(lval, orig, arg1, arg2, arg3, arg4)
Definition: valgrind.h:1150

Definition at line 619 of file valgrind.h.

#define CALL_FN_W_10W (   lval,
  orig,
  arg1,
  arg2,
  arg3,
  arg4,
  arg5,
  arg6,
  arg7,
  arg8,
  arg9,
  arg10 
)
Value:
do { \
volatile OrigFn _orig = (orig); \
volatile unsigned long _argvec[11]; \
volatile unsigned long _res; \
_argvec[0] = (unsigned long)_orig.nraddr; \
_argvec[1] = (unsigned long)(arg1); \
_argvec[2] = (unsigned long)(arg2); \
_argvec[3] = (unsigned long)(arg3); \
_argvec[4] = (unsigned long)(arg4); \
_argvec[5] = (unsigned long)(arg5); \
_argvec[6] = (unsigned long)(arg6); \
_argvec[7] = (unsigned long)(arg7); \
_argvec[8] = (unsigned long)(arg8); \
_argvec[9] = (unsigned long)(arg9); \
_argvec[10] = (unsigned long)(arg10); \
__asm__ volatile( \
"subq $128,%%rsp\n\t" \
"pushq 80(%%rax)\n\t" \
"pushq 72(%%rax)\n\t" \
"pushq 64(%%rax)\n\t" \
"pushq 56(%%rax)\n\t" \
"movq 48(%%rax), %%r9\n\t" \
"movq 40(%%rax), %%r8\n\t" \
"movq 32(%%rax), %%rcx\n\t" \
"movq 24(%%rax), %%rdx\n\t" \
"movq 16(%%rax), %%rsi\n\t" \
"movq 8(%%rax), %%rdi\n\t" \
"movq (%%rax), %%rax\n\t" /* target->%rax */ \
"addq $32, %%rsp\n" \
"addq $128,%%rsp\n\t" \
: /*out*/ "=a" (_res) \
: /*in*/ "a" (&_argvec[0]) \
: /*trash*/ "cc", "memory", __CALLER_SAVED_REGS \
); \
lval = (__typeof__(lval)) _res; \
} while (0)
unsigned long long int nraddr
Definition: valgrind.h:235
#define VALGRIND_CALL_NOREDIR_RAX
Definition: valgrind.h:277

Definition at line 1342 of file valgrind.h.

#define CALL_FN_W_11W (   lval,
  orig,
  arg1,
  arg2,
  arg3,
  arg4,
  arg5,
  arg6,
  arg7,
  arg8,
  arg9,
  arg10,
  arg11 
)
Value:
do { \
volatile OrigFn _orig = (orig); \
volatile unsigned long _argvec[12]; \
volatile unsigned long _res; \
_argvec[0] = (unsigned long)_orig.nraddr; \
_argvec[1] = (unsigned long)(arg1); \
_argvec[2] = (unsigned long)(arg2); \
_argvec[3] = (unsigned long)(arg3); \
_argvec[4] = (unsigned long)(arg4); \
_argvec[5] = (unsigned long)(arg5); \
_argvec[6] = (unsigned long)(arg6); \
_argvec[7] = (unsigned long)(arg7); \
_argvec[8] = (unsigned long)(arg8); \
_argvec[9] = (unsigned long)(arg9); \
_argvec[10] = (unsigned long)(arg10); \
_argvec[11] = (unsigned long)(arg11); \
__asm__ volatile( \
"subq $128,%%rsp\n\t" \
"pushq 88(%%rax)\n\t" \
"pushq 80(%%rax)\n\t" \
"pushq 72(%%rax)\n\t" \
"pushq 64(%%rax)\n\t" \
"pushq 56(%%rax)\n\t" \
"movq 48(%%rax), %%r9\n\t" \
"movq 40(%%rax), %%r8\n\t" \
"movq 32(%%rax), %%rcx\n\t" \
"movq 24(%%rax), %%rdx\n\t" \
"movq 16(%%rax), %%rsi\n\t" \
"movq 8(%%rax), %%rdi\n\t" \
"movq (%%rax), %%rax\n\t" /* target->%rax */ \
"addq $40, %%rsp\n" \
"addq $128,%%rsp\n\t" \
: /*out*/ "=a" (_res) \
: /*in*/ "a" (&_argvec[0]) \
: /*trash*/ "cc", "memory", __CALLER_SAVED_REGS \
); \
lval = (__typeof__(lval)) _res; \
} while (0)
unsigned long long int nraddr
Definition: valgrind.h:235
#define VALGRIND_CALL_NOREDIR_RAX
Definition: valgrind.h:277

Definition at line 1382 of file valgrind.h.

#define CALL_FN_W_12W (   lval,
  orig,
  arg1,
  arg2,
  arg3,
  arg4,
  arg5,
  arg6,
  arg7,
  arg8,
  arg9,
  arg10,
  arg11,
  arg12 
)
Value:
do { \
volatile OrigFn _orig = (orig); \
volatile unsigned long _argvec[13]; \
volatile unsigned long _res; \
_argvec[0] = (unsigned long)_orig.nraddr; \
_argvec[1] = (unsigned long)(arg1); \
_argvec[2] = (unsigned long)(arg2); \
_argvec[3] = (unsigned long)(arg3); \
_argvec[4] = (unsigned long)(arg4); \
_argvec[5] = (unsigned long)(arg5); \
_argvec[6] = (unsigned long)(arg6); \
_argvec[7] = (unsigned long)(arg7); \
_argvec[8] = (unsigned long)(arg8); \
_argvec[9] = (unsigned long)(arg9); \
_argvec[10] = (unsigned long)(arg10); \
_argvec[11] = (unsigned long)(arg11); \
_argvec[12] = (unsigned long)(arg12); \
__asm__ volatile( \
"subq $128,%%rsp\n\t" \
"pushq 96(%%rax)\n\t" \
"pushq 88(%%rax)\n\t" \
"pushq 80(%%rax)\n\t" \
"pushq 72(%%rax)\n\t" \
"pushq 64(%%rax)\n\t" \
"pushq 56(%%rax)\n\t" \
"movq 48(%%rax), %%r9\n\t" \
"movq 40(%%rax), %%r8\n\t" \
"movq 32(%%rax), %%rcx\n\t" \
"movq 24(%%rax), %%rdx\n\t" \
"movq 16(%%rax), %%rsi\n\t" \
"movq 8(%%rax), %%rdi\n\t" \
"movq (%%rax), %%rax\n\t" /* target->%rax */ \
"addq $48, %%rsp\n" \
"addq $128,%%rsp\n\t" \
: /*out*/ "=a" (_res) \
: /*in*/ "a" (&_argvec[0]) \
: /*trash*/ "cc", "memory", __CALLER_SAVED_REGS \
); \
lval = (__typeof__(lval)) _res; \
} while (0)
unsigned long long int nraddr
Definition: valgrind.h:235
#define VALGRIND_CALL_NOREDIR_RAX
Definition: valgrind.h:277

Definition at line 1424 of file valgrind.h.

#define CALL_FN_W_5W (   lval,
  orig,
  arg1,
  arg2,
  arg3,
  arg4,
  arg5 
)
Value:
do { \
volatile OrigFn _orig = (orig); \
volatile unsigned long _argvec[6]; \
volatile unsigned long _res; \
_argvec[0] = (unsigned long)_orig.nraddr; \
_argvec[1] = (unsigned long)(arg1); \
_argvec[2] = (unsigned long)(arg2); \
_argvec[3] = (unsigned long)(arg3); \
_argvec[4] = (unsigned long)(arg4); \
_argvec[5] = (unsigned long)(arg5); \
__asm__ volatile( \
"subq $128,%%rsp\n\t" \
"movq 40(%%rax), %%r8\n\t" \
"movq 32(%%rax), %%rcx\n\t" \
"movq 24(%%rax), %%rdx\n\t" \
"movq 16(%%rax), %%rsi\n\t" \
"movq 8(%%rax), %%rdi\n\t" \
"movq (%%rax), %%rax\n\t" /* target->%rax */ \
"addq $128,%%rsp\n\t" \
: /*out*/ "=a" (_res) \
: /*in*/ "a" (&_argvec[0]) \
: /*trash*/ "cc", "memory", __CALLER_SAVED_REGS \
); \
lval = (__typeof__(lval)) _res; \
} while (0)
unsigned long long int nraddr
Definition: valgrind.h:235
#define VALGRIND_CALL_NOREDIR_RAX
Definition: valgrind.h:277

Definition at line 1176 of file valgrind.h.

#define CALL_FN_W_6W (   lval,
  orig,
  arg1,
  arg2,
  arg3,
  arg4,
  arg5,
  arg6 
)
Value:
do { \
volatile OrigFn _orig = (orig); \
volatile unsigned long _argvec[7]; \
volatile unsigned long _res; \
_argvec[0] = (unsigned long)_orig.nraddr; \
_argvec[1] = (unsigned long)(arg1); \
_argvec[2] = (unsigned long)(arg2); \
_argvec[3] = (unsigned long)(arg3); \
_argvec[4] = (unsigned long)(arg4); \
_argvec[5] = (unsigned long)(arg5); \
_argvec[6] = (unsigned long)(arg6); \
__asm__ volatile( \
"subq $128,%%rsp\n\t" \
"movq 48(%%rax), %%r9\n\t" \
"movq 40(%%rax), %%r8\n\t" \
"movq 32(%%rax), %%rcx\n\t" \
"movq 24(%%rax), %%rdx\n\t" \
"movq 16(%%rax), %%rsi\n\t" \
"movq 8(%%rax), %%rdi\n\t" \
"movq (%%rax), %%rax\n\t" /* target->%rax */ \
"addq $128,%%rsp\n\t" \
: /*out*/ "=a" (_res) \
: /*in*/ "a" (&_argvec[0]) \
: /*trash*/ "cc", "memory", __CALLER_SAVED_REGS \
); \
lval = (__typeof__(lval)) _res; \
} while (0)
unsigned long long int nraddr
Definition: valgrind.h:235
#define VALGRIND_CALL_NOREDIR_RAX
Definition: valgrind.h:277

Definition at line 1204 of file valgrind.h.

#define CALL_FN_W_7W (   lval,
  orig,
  arg1,
  arg2,
  arg3,
  arg4,
  arg5,
  arg6,
  arg7 
)
Value:
do { \
volatile OrigFn _orig = (orig); \
volatile unsigned long _argvec[8]; \
volatile unsigned long _res; \
_argvec[0] = (unsigned long)_orig.nraddr; \
_argvec[1] = (unsigned long)(arg1); \
_argvec[2] = (unsigned long)(arg2); \
_argvec[3] = (unsigned long)(arg3); \
_argvec[4] = (unsigned long)(arg4); \
_argvec[5] = (unsigned long)(arg5); \
_argvec[6] = (unsigned long)(arg6); \
_argvec[7] = (unsigned long)(arg7); \
__asm__ volatile( \
"subq $128,%%rsp\n\t" \
"pushq 56(%%rax)\n\t" \
"movq 48(%%rax), %%r9\n\t" \
"movq 40(%%rax), %%r8\n\t" \
"movq 32(%%rax), %%rcx\n\t" \
"movq 24(%%rax), %%rdx\n\t" \
"movq 16(%%rax), %%rsi\n\t" \
"movq 8(%%rax), %%rdi\n\t" \
"movq (%%rax), %%rax\n\t" /* target->%rax */ \
"addq $8, %%rsp\n" \
"addq $128,%%rsp\n\t" \
: /*out*/ "=a" (_res) \
: /*in*/ "a" (&_argvec[0]) \
: /*trash*/ "cc", "memory", __CALLER_SAVED_REGS \
); \
lval = (__typeof__(lval)) _res; \
} while (0)
unsigned long long int nraddr
Definition: valgrind.h:235
#define VALGRIND_CALL_NOREDIR_RAX
Definition: valgrind.h:277

Definition at line 1234 of file valgrind.h.

#define CALL_FN_W_8W (   lval,
  orig,
  arg1,
  arg2,
  arg3,
  arg4,
  arg5,
  arg6,
  arg7,
  arg8 
)
Value:
do { \
volatile OrigFn _orig = (orig); \
volatile unsigned long _argvec[9]; \
volatile unsigned long _res; \
_argvec[0] = (unsigned long)_orig.nraddr; \
_argvec[1] = (unsigned long)(arg1); \
_argvec[2] = (unsigned long)(arg2); \
_argvec[3] = (unsigned long)(arg3); \
_argvec[4] = (unsigned long)(arg4); \
_argvec[5] = (unsigned long)(arg5); \
_argvec[6] = (unsigned long)(arg6); \
_argvec[7] = (unsigned long)(arg7); \
_argvec[8] = (unsigned long)(arg8); \
__asm__ volatile( \
"subq $128,%%rsp\n\t" \
"pushq 64(%%rax)\n\t" \
"pushq 56(%%rax)\n\t" \
"movq 48(%%rax), %%r9\n\t" \
"movq 40(%%rax), %%r8\n\t" \
"movq 32(%%rax), %%rcx\n\t" \
"movq 24(%%rax), %%rdx\n\t" \
"movq 16(%%rax), %%rsi\n\t" \
"movq 8(%%rax), %%rdi\n\t" \
"movq (%%rax), %%rax\n\t" /* target->%rax */ \
"addq $16, %%rsp\n" \
"addq $128,%%rsp\n\t" \
: /*out*/ "=a" (_res) \
: /*in*/ "a" (&_argvec[0]) \
: /*trash*/ "cc", "memory", __CALLER_SAVED_REGS \
); \
lval = (__typeof__(lval)) _res; \
} while (0)
unsigned long long int nraddr
Definition: valgrind.h:235
#define VALGRIND_CALL_NOREDIR_RAX
Definition: valgrind.h:277

Definition at line 1268 of file valgrind.h.

#define CALL_FN_W_9W (   lval,
  orig,
  arg1,
  arg2,
  arg3,
  arg4,
  arg5,
  arg6,
  arg7,
  arg8,
  arg9 
)
Value:
do { \
volatile OrigFn _orig = (orig); \
volatile unsigned long _argvec[10]; \
volatile unsigned long _res; \
_argvec[0] = (unsigned long)_orig.nraddr; \
_argvec[1] = (unsigned long)(arg1); \
_argvec[2] = (unsigned long)(arg2); \
_argvec[3] = (unsigned long)(arg3); \
_argvec[4] = (unsigned long)(arg4); \
_argvec[5] = (unsigned long)(arg5); \
_argvec[6] = (unsigned long)(arg6); \
_argvec[7] = (unsigned long)(arg7); \
_argvec[8] = (unsigned long)(arg8); \
_argvec[9] = (unsigned long)(arg9); \
__asm__ volatile( \
"subq $128,%%rsp\n\t" \
"pushq 72(%%rax)\n\t" \
"pushq 64(%%rax)\n\t" \
"pushq 56(%%rax)\n\t" \
"movq 48(%%rax), %%r9\n\t" \
"movq 40(%%rax), %%r8\n\t" \
"movq 32(%%rax), %%rcx\n\t" \
"movq 24(%%rax), %%rdx\n\t" \
"movq 16(%%rax), %%rsi\n\t" \
"movq 8(%%rax), %%rdi\n\t" \
"movq (%%rax), %%rax\n\t" /* target->%rax */ \
"addq $24, %%rsp\n" \
"addq $128,%%rsp\n\t" \
: /*out*/ "=a" (_res) \
: /*in*/ "a" (&_argvec[0]) \
: /*trash*/ "cc", "memory", __CALLER_SAVED_REGS \
); \
lval = (__typeof__(lval)) _res; \
} while (0)
unsigned long long int nraddr
Definition: valgrind.h:235
#define VALGRIND_CALL_NOREDIR_RAX
Definition: valgrind.h:277

Definition at line 1304 of file valgrind.h.

#define CALL_FN_W_v (   lval,
  orig 
)
Value:
do { \
volatile OrigFn _orig = (orig); \
volatile unsigned long _argvec[1]; \
volatile unsigned long _res; \
_argvec[0] = (unsigned long)_orig.nraddr; \
__asm__ volatile( \
"subq $128,%%rsp\n\t" \
"movq (%%rax), %%rax\n\t" /* target->%rax */ \
"addq $128,%%rsp\n\t" \
: /*out*/ "=a" (_res) \
: /*in*/ "a" (&_argvec[0]) \
: /*trash*/ "cc", "memory", __CALLER_SAVED_REGS \
); \
lval = (__typeof__(lval)) _res; \
} while (0)
unsigned long long int nraddr
Definition: valgrind.h:235
#define VALGRIND_CALL_NOREDIR_RAX
Definition: valgrind.h:277

Definition at line 1066 of file valgrind.h.

#define CALL_FN_W_W (   lval,
  orig,
  arg1 
)
Value:
do { \
volatile OrigFn _orig = (orig); \
volatile unsigned long _argvec[2]; \
volatile unsigned long _res; \
_argvec[0] = (unsigned long)_orig.nraddr; \
_argvec[1] = (unsigned long)(arg1); \
__asm__ volatile( \
"subq $128,%%rsp\n\t" \
"movq 8(%%rax), %%rdi\n\t" \
"movq (%%rax), %%rax\n\t" /* target->%rax */ \
"addq $128,%%rsp\n\t" \
: /*out*/ "=a" (_res) \
: /*in*/ "a" (&_argvec[0]) \
: /*trash*/ "cc", "memory", __CALLER_SAVED_REGS \
); \
lval = (__typeof__(lval)) _res; \
} while (0)
unsigned long long int nraddr
Definition: valgrind.h:235
#define VALGRIND_CALL_NOREDIR_RAX
Definition: valgrind.h:277

Definition at line 1084 of file valgrind.h.

#define CALL_FN_W_WW (   lval,
  orig,
  arg1,
  arg2 
)
Value:
do { \
volatile OrigFn _orig = (orig); \
volatile unsigned long _argvec[3]; \
volatile unsigned long _res; \
_argvec[0] = (unsigned long)_orig.nraddr; \
_argvec[1] = (unsigned long)(arg1); \
_argvec[2] = (unsigned long)(arg2); \
__asm__ volatile( \
"subq $128,%%rsp\n\t" \
"movq 16(%%rax), %%rsi\n\t" \
"movq 8(%%rax), %%rdi\n\t" \
"movq (%%rax), %%rax\n\t" /* target->%rax */ \
"addq $128,%%rsp\n\t" \
: /*out*/ "=a" (_res) \
: /*in*/ "a" (&_argvec[0]) \
: /*trash*/ "cc", "memory", __CALLER_SAVED_REGS \
); \
lval = (__typeof__(lval)) _res; \
} while (0)
unsigned long long int nraddr
Definition: valgrind.h:235
#define VALGRIND_CALL_NOREDIR_RAX
Definition: valgrind.h:277

Definition at line 1104 of file valgrind.h.

#define CALL_FN_W_WWW (   lval,
  orig,
  arg1,
  arg2,
  arg3 
)
Value:
do { \
volatile OrigFn _orig = (orig); \
volatile unsigned long _argvec[4]; \
volatile unsigned long _res; \
_argvec[0] = (unsigned long)_orig.nraddr; \
_argvec[1] = (unsigned long)(arg1); \
_argvec[2] = (unsigned long)(arg2); \
_argvec[3] = (unsigned long)(arg3); \
__asm__ volatile( \
"subq $128,%%rsp\n\t" \
"movq 24(%%rax), %%rdx\n\t" \
"movq 16(%%rax), %%rsi\n\t" \
"movq 8(%%rax), %%rdi\n\t" \
"movq (%%rax), %%rax\n\t" /* target->%rax */ \
"addq $128,%%rsp\n\t" \
: /*out*/ "=a" (_res) \
: /*in*/ "a" (&_argvec[0]) \
: /*trash*/ "cc", "memory", __CALLER_SAVED_REGS \
); \
lval = (__typeof__(lval)) _res; \
} while (0)
unsigned long long int nraddr
Definition: valgrind.h:235
#define VALGRIND_CALL_NOREDIR_RAX
Definition: valgrind.h:277

Definition at line 1126 of file valgrind.h.

#define CALL_FN_W_WWWW (   lval,
  orig,
  arg1,
  arg2,
  arg3,
  arg4 
)
Value:
do { \
volatile OrigFn _orig = (orig); \
volatile unsigned long _argvec[5]; \
volatile unsigned long _res; \
_argvec[0] = (unsigned long)_orig.nraddr; \
_argvec[1] = (unsigned long)(arg1); \
_argvec[2] = (unsigned long)(arg2); \
_argvec[3] = (unsigned long)(arg3); \
_argvec[4] = (unsigned long)(arg4); \
__asm__ volatile( \
"subq $128,%%rsp\n\t" \
"movq 32(%%rax), %%rcx\n\t" \
"movq 24(%%rax), %%rdx\n\t" \
"movq 16(%%rax), %%rsi\n\t" \
"movq 8(%%rax), %%rdi\n\t" \
"movq (%%rax), %%rax\n\t" /* target->%rax */ \
"addq $128,%%rsp\n\t" \
: /*out*/ "=a" (_res) \
: /*in*/ "a" (&_argvec[0]) \
: /*trash*/ "cc", "memory", __CALLER_SAVED_REGS \
); \
lval = (__typeof__(lval)) _res; \
} while (0)
unsigned long long int nraddr
Definition: valgrind.h:235
#define VALGRIND_CALL_NOREDIR_RAX
Definition: valgrind.h:277

Definition at line 1150 of file valgrind.h.

#define I_WRAP_SONAME_FNNAME_ZU (   soname,
  fnname 
)    VG_CONCAT4(_vgwZU_,soname,_,fnname)

Definition at line 588 of file valgrind.h.

#define I_WRAP_SONAME_FNNAME_ZZ (   soname,
  fnname 
)    VG_CONCAT4(_vgwZZ_,soname,_,fnname)

Definition at line 591 of file valgrind.h.

#define PLAT_amd64_linux   1

Definition at line 107 of file valgrind.h.

#define RUNNING_ON_VALGRIND
Value:
__extension__ \
({unsigned int _qzz_res; \
VALGRIND_DO_CLIENT_REQUEST(_qzz_res, 0 /* if not */, \
0, 0, 0, 0, 0); \
_qzz_res; \
})
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3662 of file valgrind.h.

#define VALGRIND_CALL_NOREDIR_RAX
Value:
__SPECIAL_INSTRUCTION_PREAMBLE \
/* call-noredir *%RAX */ \
"xchgq %%rdx,%%rdx\n\t"

Definition at line 277 of file valgrind.h.

#define VALGRIND_COUNT_ERRORS
Value:
__extension__ \
({unsigned int _qyy_res; \
VALGRIND_DO_CLIENT_REQUEST(_qyy_res, 0 /* default return */, \
0, 0, 0, 0, 0); \
_qyy_res; \
})
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3798 of file valgrind.h.

#define VALGRIND_CREATE_MEMPOOL (   pool,
  rzB,
  is_zeroed 
)
Value:
{unsigned int _qzz_res; \
pool, rzB, is_zeroed, 0, 0); \
}
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3914 of file valgrind.h.

#define VALGRIND_DESTROY_MEMPOOL (   pool)
Value:
{unsigned int _qzz_res; \
pool, 0, 0, 0, 0); \
}
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3922 of file valgrind.h.

#define VALGRIND_DISCARD_TRANSLATIONS (   _qzz_addr,
  _qzz_len 
)
Value:
{unsigned int _qzz_res; \
_qzz_addr, _qzz_len, 0, 0, 0); \
}
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3675 of file valgrind.h.

#define VALGRIND_DO_CLIENT_REQUEST (   _zzq_rlval,
  _zzq_default,
  _zzq_request,
  _zzq_arg1,
  _zzq_arg2,
  _zzq_arg3,
  _zzq_arg4,
  _zzq_arg5 
)
Value:
{ volatile unsigned long long int _zzq_args[6]; \
volatile unsigned long long int _zzq_result; \
_zzq_args[0] = (unsigned long long int)(_zzq_request); \
_zzq_args[1] = (unsigned long long int)(_zzq_arg1); \
_zzq_args[2] = (unsigned long long int)(_zzq_arg2); \
_zzq_args[3] = (unsigned long long int)(_zzq_arg3); \
_zzq_args[4] = (unsigned long long int)(_zzq_arg4); \
_zzq_args[5] = (unsigned long long int)(_zzq_arg5); \
__asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \
/* %RDX = client_request ( %RAX ) */ \
"xchgq %%rbx,%%rbx" \
: "=d" (_zzq_result) \
: "a" (&_zzq_args[0]), "0" (_zzq_default) \
: "cc", "memory" \
); \
_zzq_rlval = _zzq_result; \
}

Definition at line 243 of file valgrind.h.

#define VALGRIND_FREELIKE_BLOCK (   addr,
  rzB 
)
Value:
{unsigned int _qzz_res; \
addr, rzB, 0, 0, 0); \
(void) _qzz_res; /* compiler warning */ \
}
vhost_vring_addr_t addr
Definition: vhost_user.h:121
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3905 of file valgrind.h.

#define VALGRIND_GET_NR_CONTEXT (   _zzq_rlval)
Value:
{ volatile OrigFn* _zzq_orig = &(_zzq_rlval); \
volatile unsigned long long int __addr; \
__asm__ volatile(__SPECIAL_INSTRUCTION_PREAMBLE \
/* %RAX = guest_NRADDR */ \
"xchgq %%rcx,%%rcx" \
: "=a" (__addr) \
: \
: "cc", "memory" \
); \
_zzq_orig->nraddr = __addr; \
}

Definition at line 264 of file valgrind.h.

#define VALGRIND_GET_ORIG_FN (   _lval)    VALGRIND_GET_NR_CONTEXT(_lval)

Definition at line 598 of file valgrind.h.

#define VALGRIND_LOAD_PDB_DEBUGINFO (   fd,
  ptr,
  total_size,
  delta 
)
Value:
{unsigned int _qzz_res; \
fd, ptr, total_size, delta, 0); \
}
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 4007 of file valgrind.h.

#define VALGRIND_MALLOCLIKE_BLOCK (   addr,
  sizeB,
  rzB,
  is_zeroed 
)
Value:
{unsigned int _qzz_res; \
addr, sizeB, rzB, is_zeroed, 0); \
(void) _qzz_res; /* compiler warning */ \
}
vhost_vring_addr_t addr
Definition: vhost_user.h:121
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3894 of file valgrind.h.

#define VALGRIND_MEMPOOL_ALLOC (   pool,
  addr,
  size 
)
Value:
{unsigned int _qzz_res; \
pool, addr, size, 0, 0); \
}
vhost_vring_addr_t addr
Definition: vhost_user.h:121
uword size
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3930 of file valgrind.h.

#define VALGRIND_MEMPOOL_CHANGE (   pool,
  addrA,
  addrB,
  size 
)
Value:
{unsigned int _qzz_res; \
pool, addrA, addrB, size, 0); \
}
uword size
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3962 of file valgrind.h.

#define VALGRIND_MEMPOOL_EXISTS (   pool)
Value:
__extension__ \
({unsigned int _qzz_res; \
pool, 0, 0, 0, 0); \
_qzz_res; \
})
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3970 of file valgrind.h.

#define VALGRIND_MEMPOOL_FREE (   pool,
  addr 
)
Value:
{unsigned int _qzz_res; \
pool, addr, 0, 0, 0); \
}
vhost_vring_addr_t addr
Definition: vhost_user.h:121
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3938 of file valgrind.h.

#define VALGRIND_MEMPOOL_TRIM (   pool,
  addr,
  size 
)
Value:
{unsigned int _qzz_res; \
pool, addr, size, 0, 0); \
}
vhost_vring_addr_t addr
Definition: vhost_user.h:121
uword size
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3946 of file valgrind.h.

#define VALGRIND_MOVE_MEMPOOL (   poolA,
  poolB 
)
Value:
{unsigned int _qzz_res; \
poolA, poolB, 0, 0, 0); \
}
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3954 of file valgrind.h.

#define VALGRIND_NON_SIMD_CALL0 (   _qyy_fn)
Value:
__extension__ \
({unsigned long _qyy_res; \
VALGRIND_DO_CLIENT_REQUEST(_qyy_res, 0 /* default return */, \
_qyy_fn, \
0, 0, 0, 0); \
_qyy_res; \
})
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3753 of file valgrind.h.

#define VALGRIND_NON_SIMD_CALL1 (   _qyy_fn,
  _qyy_arg1 
)
Value:
__extension__ \
({unsigned long _qyy_res; \
VALGRIND_DO_CLIENT_REQUEST(_qyy_res, 0 /* default return */, \
_qyy_fn, \
_qyy_arg1, 0, 0, 0); \
_qyy_res; \
})
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3763 of file valgrind.h.

#define VALGRIND_NON_SIMD_CALL2 (   _qyy_fn,
  _qyy_arg1,
  _qyy_arg2 
)
Value:
__extension__ \
({unsigned long _qyy_res; \
VALGRIND_DO_CLIENT_REQUEST(_qyy_res, 0 /* default return */, \
_qyy_fn, \
_qyy_arg1, _qyy_arg2, 0, 0); \
_qyy_res; \
})
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3773 of file valgrind.h.

#define VALGRIND_NON_SIMD_CALL3 (   _qyy_fn,
  _qyy_arg1,
  _qyy_arg2,
  _qyy_arg3 
)
Value:
__extension__ \
({unsigned long _qyy_res; \
VALGRIND_DO_CLIENT_REQUEST(_qyy_res, 0 /* default return */, \
_qyy_fn, \
_qyy_arg1, _qyy_arg2, \
_qyy_arg3, 0); \
_qyy_res; \
})
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3783 of file valgrind.h.

#define VALGRIND_STACK_CHANGE (   id,
  start,
  end 
)
Value:
{unsigned int _qzz_res; \
id, start, end, 0, 0); \
}
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3999 of file valgrind.h.

#define VALGRIND_STACK_DEREGISTER (   id)
Value:
{unsigned int _qzz_res; \
id, 0, 0, 0, 0); \
}
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3991 of file valgrind.h.

#define VALGRIND_STACK_REGISTER (   start,
  end 
)
Value:
__extension__ \
({unsigned int _qzz_res; \
start, end, 0, 0, 0); \
_qzz_res; \
})
#define VALGRIND_DO_CLIENT_REQUEST(_zzq_rlval, _zzq_default, _zzq_request,_zzq_arg1, _zzq_arg2, _zzq_arg3, _zzq_arg4, _zzq_arg5)
Definition: valgrind.h:243

Definition at line 3980 of file valgrind.h.

#define VG_CONCAT4 (   _aa,
  _bb,
  _cc,
  _dd 
)    _aa##_bb##_cc##_dd

Definition at line 586 of file valgrind.h.

#define VG_IS_TOOL_USERREQ (   a,
  b,
  v 
)    (VG_USERREQ_TOOL_BASE(a,b) == ((v) & 0xffff0000))

Definition at line 3601 of file valgrind.h.

#define VG_USERREQ_TOOL_BASE (   a,
 
)    ((unsigned int)(((a)&0xff) << 24 | ((b)&0xff) << 16))

Definition at line 3599 of file valgrind.h.

Enumeration Type Documentation

Enumerator
VG_USERREQ__RUNNING_ON_VALGRIND 
VG_USERREQ__DISCARD_TRANSLATIONS 
VG_USERREQ__CLIENT_CALL0 
VG_USERREQ__CLIENT_CALL1 
VG_USERREQ__CLIENT_CALL2 
VG_USERREQ__CLIENT_CALL3 
VG_USERREQ__COUNT_ERRORS 
VG_USERREQ__MALLOCLIKE_BLOCK 
VG_USERREQ__FREELIKE_BLOCK 
VG_USERREQ__CREATE_MEMPOOL 
VG_USERREQ__DESTROY_MEMPOOL 
VG_USERREQ__MEMPOOL_ALLOC 
VG_USERREQ__MEMPOOL_FREE 
VG_USERREQ__MEMPOOL_TRIM 
VG_USERREQ__MOVE_MEMPOOL 
VG_USERREQ__MEMPOOL_CHANGE 
VG_USERREQ__MEMPOOL_EXISTS 
VG_USERREQ__PRINTF 
VG_USERREQ__PRINTF_BACKTRACE 
VG_USERREQ__STACK_REGISTER 
VG_USERREQ__STACK_DEREGISTER 
VG_USERREQ__STACK_CHANGE 
VG_USERREQ__LOAD_PDB_DEBUGINFO 

Definition at line 3608 of file valgrind.h.

Function Documentation

static int VALGRIND_PRINTF ( const char *  format,
  ... 
)
static

Definition at line 3700 of file valgrind.h.

+ Here is the call graph for this function:

static int VALGRIND_PRINTF_BACKTRACE ( const char *  format,
  ... 
)
static

Definition at line 3715 of file valgrind.h.

+ Here is the caller graph for this function: