drd/tests: Fix remaining gcc 8 compiler warnings
[valgrind.git] / coregrind / m_syswrap / priv_syswrap-solaris.h
blob76f6cf3a599224415d2b25d6e67b57bf0ff34075
2 /*--------------------------------------------------------------------*/
3 /*--- Solaris-specific syscalls stuff. priv_syswrap-solaris.h ---*/
4 /*--------------------------------------------------------------------*/
6 /*
7 This file is part of Valgrind, a dynamic binary instrumentation
8 framework.
10 Copyright (C) 2011-2017 Petr Pavlu
11 setup@dagobah.cz
13 This program is free software; you can redistribute it and/or
14 modify it under the terms of the GNU General Public License as
15 published by the Free Software Foundation; either version 2 of the
16 License, or (at your option) any later version.
18 This program is distributed in the hope that it will be useful, but
19 WITHOUT ANY WARRANTY; without even the implied warranty of
20 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
21 General Public License for more details.
23 You should have received a copy of the GNU General Public License
24 along with this program; if not, write to the Free Software
25 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
26 02111-1307, USA.
28 The GNU General Public License is contained in the file COPYING.
31 #ifndef __PRIV_SYSWRAP_SOLARIS_H
32 #define __PRIV_SYSWRAP_SOLARIS_H
34 #include "pub_core_basics.h" // VG_ macro
35 #include "priv_types_n_macros.h" // DECL_TEMPLATE
36 #include "pub_core_tooliface.h" // CorePart
38 /* Macro to join a syscall name with a syscall variant. */
39 #define SC2(name, subname) \
40 name "_" subname
42 /* Macro to join a syscall name with its variant and sub-variant. */
43 #define SC3(name, subname, subsubname) \
44 name "_" subname "_" subsubname
46 extern void ML_(call_on_new_stack_0_1)(Addr stack, Addr retaddr,
47 void (*f)(Word), Word arg1);
48 extern Word ML_(start_thread_NORETURN)(void *arg);
49 extern Addr ML_(allocstack) (ThreadId tid);
50 extern void ML_(setup_start_thread_context)(ThreadId tid, vki_ucontext_t *uc);
52 extern UInt ML_(fletcher32)(UShort *buf, SizeT blocks);
53 extern ULong ML_(fletcher64)(UInt *buf, SizeT blocks);
54 extern void ML_(save_machine_context)(ThreadId tid, vki_ucontext_t *uc,
55 CorePart part);
56 extern void ML_(restore_machine_context)(ThreadId tid, vki_ucontext_t *uc,
57 CorePart part, Bool esp_is_thrptr);
59 #if defined(VGP_x86_solaris)
61 extern void ML_(setup_gdt)(VexGuestX86State *vex);
62 extern void ML_(cleanup_gdt)(VexGuestX86State *vex);
63 extern void ML_(update_gdt_lwpgs)(ThreadId tid);
65 /* prototypes */
66 DECL_TEMPLATE(x86_solaris, sys_fstatat64);
67 DECL_TEMPLATE(x86_solaris, sys_openat64);
68 DECL_TEMPLATE(x86_solaris, sys_llseek32);
69 DECL_TEMPLATE(x86_solaris, sys_mmap64);
70 DECL_TEMPLATE(x86_solaris, sys_stat64);
71 DECL_TEMPLATE(x86_solaris, sys_lstat64);
72 DECL_TEMPLATE(x86_solaris, sys_fstat64);
73 DECL_TEMPLATE(x86_solaris, sys_statvfs64);
74 DECL_TEMPLATE(x86_solaris, sys_fstatvfs64);
75 DECL_TEMPLATE(x86_solaris, sys_setrlimit64);
76 DECL_TEMPLATE(x86_solaris, sys_getrlimit64);
77 DECL_TEMPLATE(x86_solaris, sys_pread64);
78 DECL_TEMPLATE(x86_solaris, sys_pwrite64);
79 DECL_TEMPLATE(x86_solaris, sys_open64);
81 #elif defined(VGP_amd64_solaris)
82 /* Nothing yet. */
84 #else
85 # error "Unknown platform"
86 #endif
88 #endif // __PRIV_SYSWRAP_SOLARIS_H
90 /*--------------------------------------------------------------------*/
91 /*--- end ---*/
92 /*--------------------------------------------------------------------*/