FreeBSD: add syscall wrapper for close_range
[valgrind.git] / memcheck / tests / freebsd / scalar_13_plus.c
blob6e58e418fb3a1cc6cf6128d27d769fdc26abbff3
1 #include "scalar.h"
2 #include <sys/mman.h>
4 int main(void)
6 long *px = malloc(2*sizeof(long));
7 x0 = px[0];
9 /* SYS_shm_open2 571 */
10 GO(SYS_shm_open2, " 5s 2m");
11 SY(SYS_shm_open2, x0+0xf00c, x0+1, x0+2, x0+3, x0+4); FAIL;
13 GO(SYS_shm_open2, " 5s 1m");
14 SY(SYS_shm_open2, x0+SHM_ANON, x0+1, x0+2, x0+3, x0+4); FAIL;
16 /* SYS___realpathat 574 */
17 GO(SYS___realpathat, " 5s 2m");
18 SY(SYS___realpathat, x0+0xffff, x0, x0, x0+100, x0+2); FAIL;
20 /* SYS_close_range 575 */
21 GO(SYS_close_range, "3s 0m");
22 SY(SYS_close_range, x0+5, x0+10, x0); SUCC;
24 /* SYS___specialfd 577 */
25 GO(SYS___specialfd, "3s 1m");
26 SY(SYS___specialfd, x0+0xf000, x0+1, x0+10); FAIL;
28 return(0);