|
|
d5c145 |
diff --git a/README b/README
|
|
|
d5c145 |
index 414bdfb..a04b767 100644
|
|
|
d5c145 |
--- a/README
|
|
|
d5c145 |
+++ b/README
|
|
|
d5c145 |
@@ -24,6 +24,7 @@ The following targets are currently (at least somewhat) supported.
|
|
|
d5c145 |
Some of them may be more or less broken in reality, it is not feasible
|
|
|
d5c145 |
to test each release comprehensively on each target.
|
|
|
d5c145 |
|
|
|
d5c145 |
+ aarch64-*-linux-gnu
|
|
|
d5c145 |
armv6l-*-linux-gnueabi
|
|
|
d5c145 |
armv7l-*-linux-gnueabihf
|
|
|
d5c145 |
i[4567]86-*-linux-gnu
|
|
|
d5c145 |
@@ -81,7 +82,7 @@ quick one-liner), it is advisable to send an e-mail beforehand.
|
|
|
d5c145 |
|
|
|
d5c145 |
|
|
|
d5c145 |
-------------------------------------------------------------------------------
|
|
|
d5c145 |
-Copyright (C) 2012,2013 Petr Machata <pmachata@redhat.com>
|
|
|
d5c145 |
+Copyright (C) 2012-2014 Petr Machata <pmachata@redhat.com>
|
|
|
d5c145 |
Copyright (C) 1997-2009 Juan Cespedes <cespedes@debian.org>
|
|
|
d5c145 |
This file is part of ltrace.
|
|
|
d5c145 |
|
|
|
d5c145 |
diff --git a/configure.ac b/configure.ac
|
|
|
d5c145 |
index c6e6bf0..0e9a124 100644
|
|
|
d5c145 |
--- a/configure.ac
|
|
|
d5c145 |
+++ b/configure.ac
|
|
|
d5c145 |
@@ -1,6 +1,6 @@
|
|
|
d5c145 |
# -*- Autoconf -*-
|
|
|
d5c145 |
# This file is part of ltrace.
|
|
|
d5c145 |
-# Copyright (C) 2010,2012,2013 Petr Machata, Red Hat Inc.
|
|
|
d5c145 |
+# Copyright (C) 2010,2012,2013,2014 Petr Machata, Red Hat Inc.
|
|
|
d5c145 |
# Copyright (C) 2010,2011 Joe Damato
|
|
|
d5c145 |
# Copyright (C) 2010 Marc Kleine-Budde
|
|
|
d5c145 |
# Copyright (C) 2010 Zachary T Welch
|
|
|
d5c145 |
@@ -399,6 +399,7 @@ AC_CONFIG_FILES([
|
|
|
d5c145 |
Makefile
|
|
|
d5c145 |
sysdeps/Makefile
|
|
|
d5c145 |
sysdeps/linux-gnu/Makefile
|
|
|
d5c145 |
+ sysdeps/linux-gnu/aarch64/Makefile
|
|
|
d5c145 |
sysdeps/linux-gnu/alpha/Makefile
|
|
|
d5c145 |
sysdeps/linux-gnu/arm/Makefile
|
|
|
d5c145 |
sysdeps/linux-gnu/cris/Makefile
|
|
|
d5c145 |
diff --git a/etc/libc.so.conf b/etc/libc.so.conf
|
|
|
d5c145 |
index 669c50a..48b3b01 100644
|
|
|
d5c145 |
--- a/etc/libc.so.conf
|
|
|
d5c145 |
+++ b/etc/libc.so.conf
|
|
|
d5c145 |
@@ -1,5 +1,12 @@
|
|
|
d5c145 |
# See ltrace.conf(5) for description of syntax of this file.
|
|
|
d5c145 |
|
|
|
d5c145 |
+# XXX ltrace misses long double and long long support
|
|
|
d5c145 |
+typedef ldouble = double;
|
|
|
d5c145 |
+typedef llong = long;
|
|
|
d5c145 |
+typedef ullong = ulong;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+void __libc_start_main(hide(void*), hide(int), array(string, arg2));
|
|
|
d5c145 |
+
|
|
|
d5c145 |
# arpa/inet.h
|
|
|
d5c145 |
typedef in_addr = struct(hex(uint));
|
|
|
d5c145 |
int inet_aton(string, +in_addr*);
|
|
|
d5c145 |
@@ -233,9 +240,22 @@ void setbuffer(file,addr,ulong);
|
|
|
d5c145 |
void setlinebuf(file);
|
|
|
d5c145 |
int rename(string,string);
|
|
|
d5c145 |
|
|
|
d5c145 |
+# xlocale.h
|
|
|
d5c145 |
+typedef locale_t = void*;
|
|
|
d5c145 |
+locale_t newlocale(hex(int), string, locale_t);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
# stdlib.h
|
|
|
d5c145 |
-long __strtol_internal(string,addr,int);
|
|
|
d5c145 |
-ulong __strtoul_internal(string,addr,int);
|
|
|
d5c145 |
+long __strtol_internal(string, +string*, int);
|
|
|
d5c145 |
+ulong __strtoul_internal(string, +string*, int);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+double strtod(string, +string*);
|
|
|
d5c145 |
+float strtof(string, +string*);
|
|
|
d5c145 |
+ldouble strtold(string, +string*);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+double strtod_l(string, +string*, locale_t);
|
|
|
d5c145 |
+float strtof_l(string, +string*, locale_t);
|
|
|
d5c145 |
+ldouble strtold_l(string, +string*, locale_t);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
int atexit(addr);
|
|
|
d5c145 |
addr bsearch(string, addr, ulong, ulong, addr);
|
|
|
d5c145 |
addr calloc(ulong, ulong);
|
|
|
d5c145 |
@@ -343,6 +363,10 @@ addr gmtime(addr);
|
|
|
d5c145 |
addr localtime(addr);
|
|
|
d5c145 |
ulong strftime(+string2,ulong,string,addr);
|
|
|
d5c145 |
long time(addr);
|
|
|
d5c145 |
+# XXX in fact (time_t, long), which may be (llong, long) on 32-bit
|
|
|
d5c145 |
+# arches. We don't have llong as of this writing.
|
|
|
d5c145 |
+typedef timespec = struct(long, long);
|
|
|
d5c145 |
+int nanosleep(timespec*, timespec*);
|
|
|
d5c145 |
|
|
|
d5c145 |
# unistd.h
|
|
|
d5c145 |
void _exit(int);
|
|
|
d5c145 |
diff --git a/etc/syscalls.conf b/etc/syscalls.conf
|
|
|
d5c145 |
index 562f4e7..09d347d 100644
|
|
|
d5c145 |
--- a/etc/syscalls.conf
|
|
|
d5c145 |
+++ b/etc/syscalls.conf
|
|
|
d5c145 |
@@ -1,6 +1,10 @@
|
|
|
d5c145 |
# syscall.conf -- system call prototypes
|
|
|
d5c145 |
# See ltrace.conf(5) for description of syntax of this file.
|
|
|
d5c145 |
|
|
|
d5c145 |
+# Special value used to indicate the *at functions should use the
|
|
|
d5c145 |
+# current working directory.
|
|
|
d5c145 |
+typedef at_dirfd_t = enum[int](AT_FDCWD=-100);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
addr brk(addr);
|
|
|
d5c145 |
int close(int);
|
|
|
d5c145 |
int execve(string,addr,addr);
|
|
|
d5c145 |
@@ -14,7 +18,7 @@ int getpid();
|
|
|
d5c145 |
addr mmap(addr,ulong,int,int,int,long);
|
|
|
d5c145 |
|
|
|
d5c145 |
int munmap(addr,ulong);
|
|
|
d5c145 |
-int open(string,int,octal);
|
|
|
d5c145 |
+int open(string, hex(uint), oct(uint));
|
|
|
d5c145 |
int personality(uint);
|
|
|
d5c145 |
long read(int,+string0,ulong);
|
|
|
d5c145 |
int stat(string,addr);
|
|
|
d5c145 |
@@ -113,3 +117,30 @@ ulong writev(int,addr,int);
|
|
|
d5c145 |
int mprotect(addr,int,int);
|
|
|
d5c145 |
int access(string,octal);
|
|
|
d5c145 |
int getdents(uint, void *, uint);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+int openat(at_dirfd_t, string, hex(uint), oct(uint));
|
|
|
d5c145 |
+int mknodat(at_dirfd_t, string, oct(uint), ushort)
|
|
|
d5c145 |
+int mkdirat(at_dirfd_t, string, oct(uint));
|
|
|
d5c145 |
+int unlinkat(at_dirfd_t, string, hex(uint));
|
|
|
d5c145 |
+int symlinkat(string, at_dirfd_t, string);
|
|
|
d5c145 |
+int linkat(at_dirfd_t, string, at_dirfd_t, string, hex(uint));
|
|
|
d5c145 |
+int renameat(at_dirfd_t, string, at_dirfd_t, string);
|
|
|
d5c145 |
+int faccessat(at_dirfd_t, string, oct(uint), hex(uint));
|
|
|
d5c145 |
+int fchmodat(at_dirfd_t, string, oct(uint), hex(uint));
|
|
|
d5c145 |
+int fchownat(at_dirfd_t, string, int, int, hex(uint));
|
|
|
d5c145 |
+int readlinkat(at_dirfd_t, string, +string[arg4], ulong);
|
|
|
d5c145 |
+int fstatat(at_dirfd_t, string, addr, hex(uint));
|
|
|
d5c145 |
+int utimensat(at_dirfd_t, string, addr, hex(uint));
|
|
|
d5c145 |
+int futimens(int, addr);
|
|
|
d5c145 |
+int futimesat(at_dirfd_t, string, addr);
|
|
|
d5c145 |
+addr shmat(int, addr, hex(uint));
|
|
|
d5c145 |
+int shmdt(addr);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+typedef fid_type = enum(FILEID_ROOT=0, FILEID_INO32_GEN=1, FILEID_INO32_GEN_PARENT=2, FILEID_BTRFS_WITHOUT_PARENT=0x4d, FILEID_BTRFS_WITH_PARENT=0x4e, FILEID_BTRFS_WITH_PARENT_ROOT=0x4f, FILEID_UDF_WITHOUT_PARENT=0x51, FILEID_UDF_WITH_PARENT=0x52, FILEID_NILFS_WITHOUT_PARENT=0x61, FILEID_NILFS_WITH_PARENT=0x62);
|
|
|
d5c145 |
+typedef file_handle = struct(uint, fid_type, array(hex(char), elt1)*);
|
|
|
d5c145 |
+int name_to_handle_at(at_dirfd_t, string, file_handle, int*, hex(uint));
|
|
|
d5c145 |
+int open_by_handle_at(at_dirfd_t, file_handle, hex(uint));
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+int newfstatat(at_dirfd_t, string, addr, hex(uint));
|
|
|
d5c145 |
+int creat(string, oct(int));
|
|
|
d5c145 |
+int ustat(ushort, addr);
|
|
|
d5c145 |
diff --git a/sysdeps/linux-gnu/Makefile.am b/sysdeps/linux-gnu/Makefile.am
|
|
|
d5c145 |
index ecee577..ec26162 100644
|
|
|
d5c145 |
--- a/sysdeps/linux-gnu/Makefile.am
|
|
|
d5c145 |
+++ b/sysdeps/linux-gnu/Makefile.am
|
|
|
d5c145 |
@@ -1,4 +1,5 @@
|
|
|
d5c145 |
# This file is part of ltrace.
|
|
|
d5c145 |
+# Copyright (C) 2014 Petr Machata, Red Hat, Inc.
|
|
|
d5c145 |
# Copyright (C) 2010,2012 Marc Kleine-Budde, Pengutronix
|
|
|
d5c145 |
#
|
|
|
d5c145 |
# This program is free software; you can redistribute it and/or
|
|
|
d5c145 |
@@ -16,7 +17,8 @@
|
|
|
d5c145 |
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
|
|
|
d5c145 |
# 02110-1301 USA
|
|
|
d5c145 |
|
|
|
d5c145 |
-DIST_SUBDIRS = alpha arm cris ia64 m68k metag mips ppc s390 sparc x86
|
|
|
d5c145 |
+DIST_SUBDIRS = aarch64 alpha arm cris ia64 m68k metag mips ppc s390 \
|
|
|
d5c145 |
+ sparc x86
|
|
|
d5c145 |
|
|
|
d5c145 |
SUBDIRS = \
|
|
|
d5c145 |
$(HOST_CPU)
|
|
|
d5c145 |
diff --git a/sysdeps/linux-gnu/aarch64/Makefile.am b/sysdeps/linux-gnu/aarch64/Makefile.am
|
|
|
d5c145 |
new file mode 100644
|
|
|
d5c145 |
index 0000000..0af4e6e
|
|
|
d5c145 |
--- /dev/null
|
|
|
d5c145 |
+++ b/sysdeps/linux-gnu/aarch64/Makefile.am
|
|
|
d5c145 |
@@ -0,0 +1,25 @@
|
|
|
d5c145 |
+# This file is part of ltrace.
|
|
|
d5c145 |
+# Copyright (C) 2014 Petr Machata, Red Hat, Inc.
|
|
|
d5c145 |
+#
|
|
|
d5c145 |
+# This program is free software; you can redistribute it and/or
|
|
|
d5c145 |
+# modify it under the terms of the GNU General Public License as
|
|
|
d5c145 |
+# published by the Free Software Foundation; either version 2 of the
|
|
|
d5c145 |
+# License, or (at your option) any later version.
|
|
|
d5c145 |
+#
|
|
|
d5c145 |
+# This program is distributed in the hope that it will be useful, but
|
|
|
d5c145 |
+# WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
d5c145 |
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
d5c145 |
+# General Public License for more details.
|
|
|
d5c145 |
+#
|
|
|
d5c145 |
+# You should have received a copy of the GNU General Public License
|
|
|
d5c145 |
+# along with this program; if not, write to the Free Software
|
|
|
d5c145 |
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
|
|
|
d5c145 |
+# 02110-1301 USA
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+noinst_LTLIBRARIES = ../libcpu.la
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+___libcpu_la_SOURCES = fetch.c plt.c regs.c trace.c
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+noinst_HEADERS = arch.h ptrace.h signalent.h syscallent.h
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+MAINTAINERCLEANFILES = Makefile.in
|
|
|
d5c145 |
diff --git a/sysdeps/linux-gnu/aarch64/arch.h b/sysdeps/linux-gnu/aarch64/arch.h
|
|
|
d5c145 |
new file mode 100644
|
|
|
d5c145 |
index 0000000..4137613
|
|
|
d5c145 |
--- /dev/null
|
|
|
d5c145 |
+++ b/sysdeps/linux-gnu/aarch64/arch.h
|
|
|
d5c145 |
@@ -0,0 +1,37 @@
|
|
|
d5c145 |
+/*
|
|
|
d5c145 |
+ * This file is part of ltrace.
|
|
|
d5c145 |
+ * Copyright (C) 2014 Petr Machata, Red Hat, Inc.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is free software; you can redistribute it and/or
|
|
|
d5c145 |
+ * modify it under the terms of the GNU General Public License as
|
|
|
d5c145 |
+ * published by the Free Software Foundation; either version 2 of the
|
|
|
d5c145 |
+ * License, or (at your option) any later version.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is distributed in the hope that it will be useful, but
|
|
|
d5c145 |
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
d5c145 |
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
d5c145 |
+ * General Public License for more details.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * You should have received a copy of the GNU General Public License
|
|
|
d5c145 |
+ * along with this program; if not, write to the Free Software
|
|
|
d5c145 |
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
|
|
|
d5c145 |
+ * 02110-1301 USA
|
|
|
d5c145 |
+ */
|
|
|
d5c145 |
+#ifndef LTRACE_AARCH64_ARCH_H
|
|
|
d5c145 |
+#define LTRACE_AARCH64_ARCH_H
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+/* | 31 21 | 20 5 | 4 0 | *
|
|
|
d5c145 |
+ * | 1 1 0 1 0 1 0 0 0 0 1 | imm16 | 0 0 0 0 0 | */
|
|
|
d5c145 |
+#define BREAKPOINT_VALUE { 0xd4, 0x20, 0, 0 }
|
|
|
d5c145 |
+#define BREAKPOINT_LENGTH 4
|
|
|
d5c145 |
+#define DECR_PC_AFTER_BREAK 0
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+#define LT_ELFCLASS ELFCLASS64
|
|
|
d5c145 |
+#define LT_ELF_MACHINE EM_AARCH64
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+#define ARCH_HAVE_FETCH_ARG
|
|
|
d5c145 |
+#define ARCH_ENDIAN_BIG
|
|
|
d5c145 |
+#define ARCH_HAVE_SIZEOF
|
|
|
d5c145 |
+#define ARCH_HAVE_ALIGNOF
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+#endif /* LTRACE_AARCH64_ARCH_H */
|
|
|
d5c145 |
diff --git a/sysdeps/linux-gnu/aarch64/fetch.c b/sysdeps/linux-gnu/aarch64/fetch.c
|
|
|
d5c145 |
new file mode 100644
|
|
|
d5c145 |
index 0000000..8779f03
|
|
|
d5c145 |
--- /dev/null
|
|
|
d5c145 |
+++ b/sysdeps/linux-gnu/aarch64/fetch.c
|
|
|
d5c145 |
@@ -0,0 +1,365 @@
|
|
|
d5c145 |
+/*
|
|
|
d5c145 |
+ * This file is part of ltrace.
|
|
|
d5c145 |
+ * Copyright (C) 2014 Petr Machata, Red Hat, Inc.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is free software; you can redistribute it and/or
|
|
|
d5c145 |
+ * modify it under the terms of the GNU General Public License as
|
|
|
d5c145 |
+ * published by the Free Software Foundation; either version 2 of the
|
|
|
d5c145 |
+ * License, or (at your option) any later version.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is distributed in the hope that it will be useful, but
|
|
|
d5c145 |
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
d5c145 |
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
d5c145 |
+ * General Public License for more details.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * You should have received a copy of the GNU General Public License
|
|
|
d5c145 |
+ * along with this program; if not, write to the Free Software
|
|
|
d5c145 |
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
|
|
|
d5c145 |
+ * 02110-1301 USA
|
|
|
d5c145 |
+ */
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+#include <sys/ptrace.h>
|
|
|
d5c145 |
+#include <asm/ptrace.h>
|
|
|
d5c145 |
+#include <stdlib.h>
|
|
|
d5c145 |
+#include <string.h>
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+#include "fetch.h"
|
|
|
d5c145 |
+#include "proc.h"
|
|
|
d5c145 |
+#include "type.h"
|
|
|
d5c145 |
+#include "value.h"
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+int aarch64_read_gregs(struct process *proc, struct user_pt_regs *regs);
|
|
|
d5c145 |
+int aarch64_read_fregs(struct process *proc, struct user_fpsimd_state *regs);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+struct fetch_context
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ struct user_pt_regs gregs;
|
|
|
d5c145 |
+ struct user_fpsimd_state fpregs;
|
|
|
d5c145 |
+ arch_addr_t nsaa;
|
|
|
d5c145 |
+ unsigned ngrn;
|
|
|
d5c145 |
+ unsigned nsrn;
|
|
|
d5c145 |
+ arch_addr_t x8;
|
|
|
d5c145 |
+};
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+static int
|
|
|
d5c145 |
+context_init(struct fetch_context *context, struct process *proc)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ if (aarch64_read_gregs(proc, &context->gregs) < 0
|
|
|
d5c145 |
+ || aarch64_read_fregs(proc, &context->fpregs) < 0)
|
|
|
d5c145 |
+ return -1;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ context->ngrn = 0;
|
|
|
d5c145 |
+ context->nsrn = 0;
|
|
|
d5c145 |
+ /* XXX double cast */
|
|
|
d5c145 |
+ context->nsaa = (arch_addr_t) (uintptr_t) context->gregs.sp;
|
|
|
d5c145 |
+ context->x8 = 0;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ return 0;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+struct fetch_context *
|
|
|
d5c145 |
+arch_fetch_arg_clone(struct process *proc, struct fetch_context *context)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ struct fetch_context *ret = malloc(sizeof(*ret));
|
|
|
d5c145 |
+ if (ret == NULL)
|
|
|
d5c145 |
+ return NULL;
|
|
|
d5c145 |
+ return memcpy(ret, context, sizeof(*ret));
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+static void
|
|
|
d5c145 |
+fetch_next_gpr(struct fetch_context *context, unsigned char *buf)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ uint64_t u = context->gregs.regs[context->ngrn++];
|
|
|
d5c145 |
+ memcpy(buf, &u, 8);
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+static int
|
|
|
d5c145 |
+fetch_gpr(struct fetch_context *context, struct value *value, size_t sz)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ if (sz < 8)
|
|
|
d5c145 |
+ sz = 8;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ unsigned char *buf = value_reserve(value, sz);
|
|
|
d5c145 |
+ if (buf == NULL)
|
|
|
d5c145 |
+ return -1;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ size_t i;
|
|
|
d5c145 |
+ for (i = 0; i < sz; i += 8)
|
|
|
d5c145 |
+ fetch_next_gpr(context, buf + i);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ return 0;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+static void
|
|
|
d5c145 |
+fetch_next_sse(struct fetch_context *context, unsigned char *buf, size_t sz)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ __int128 u = context->fpregs.vregs[context->nsrn++];
|
|
|
d5c145 |
+ memcpy(buf, &u, sz);
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+static int
|
|
|
d5c145 |
+fetch_sse(struct fetch_context *context, struct value *value, size_t sz)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ unsigned char *buf = value_reserve(value, sz);
|
|
|
d5c145 |
+ if (buf == NULL)
|
|
|
d5c145 |
+ return -1;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ fetch_next_sse(context, buf, sz);
|
|
|
d5c145 |
+ return 0;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+static int
|
|
|
d5c145 |
+fetch_hfa(struct fetch_context *context,
|
|
|
d5c145 |
+ struct value *value, struct arg_type_info *hfa_t, size_t count)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ size_t sz = type_sizeof(value->inferior, hfa_t);
|
|
|
d5c145 |
+ unsigned char *buf = value_reserve(value, sz * count);
|
|
|
d5c145 |
+ if (buf == NULL)
|
|
|
d5c145 |
+ return -1;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ size_t i;
|
|
|
d5c145 |
+ for (i = 0; i < count; ++i) {
|
|
|
d5c145 |
+ fetch_next_sse(context, buf, sz);
|
|
|
d5c145 |
+ buf += sz;
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+ return 0;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+static int
|
|
|
d5c145 |
+fetch_stack(struct fetch_context *context, struct value *value,
|
|
|
d5c145 |
+ size_t align, size_t sz)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ if (align < 8)
|
|
|
d5c145 |
+ align = 8;
|
|
|
d5c145 |
+ size_t amount = ((sz + align - 1) / align) * align;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ /* XXX double casts */
|
|
|
d5c145 |
+ uintptr_t sp = (uintptr_t) context->nsaa;
|
|
|
d5c145 |
+ sp = ((sp + align - 1) / align) * align;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ value_in_inferior(value, (arch_addr_t) sp);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ sp += amount;
|
|
|
d5c145 |
+ context->nsaa = (arch_addr_t) sp;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ return 0;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+enum convert_method {
|
|
|
d5c145 |
+ CVT_ERR = -1,
|
|
|
d5c145 |
+ CVT_NOP = 0,
|
|
|
d5c145 |
+ CVT_BYREF,
|
|
|
d5c145 |
+};
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+enum fetch_method {
|
|
|
d5c145 |
+ FETCH_NOP,
|
|
|
d5c145 |
+ FETCH_STACK,
|
|
|
d5c145 |
+ FETCH_GPR,
|
|
|
d5c145 |
+ FETCH_SSE,
|
|
|
d5c145 |
+ FETCH_HFA,
|
|
|
d5c145 |
+};
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+struct fetch_script {
|
|
|
d5c145 |
+ enum convert_method c;
|
|
|
d5c145 |
+ enum fetch_method f;
|
|
|
d5c145 |
+ size_t sz;
|
|
|
d5c145 |
+ struct arg_type_info *hfa_t;
|
|
|
d5c145 |
+ size_t count;
|
|
|
d5c145 |
+};
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+static struct fetch_script
|
|
|
d5c145 |
+pass_arg(struct fetch_context const *context,
|
|
|
d5c145 |
+ struct process *proc, struct arg_type_info *info)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ enum fetch_method cvt = CVT_NOP;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ size_t sz = type_sizeof(proc, info);
|
|
|
d5c145 |
+ if (sz == (size_t) -1)
|
|
|
d5c145 |
+ return (struct fetch_script) { CVT_ERR, FETCH_NOP, sz };
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ switch (info->type) {
|
|
|
d5c145 |
+ case ARGTYPE_VOID:
|
|
|
d5c145 |
+ return (struct fetch_script) { cvt, FETCH_NOP, sz };
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ case ARGTYPE_STRUCT:
|
|
|
d5c145 |
+ case ARGTYPE_ARRAY:;
|
|
|
d5c145 |
+ size_t count;
|
|
|
d5c145 |
+ struct arg_type_info *hfa_t = type_get_hfa_type(info, &count);
|
|
|
d5c145 |
+ if (hfa_t != NULL && count <= 4) {
|
|
|
d5c145 |
+ if (context->nsrn + count <= 8)
|
|
|
d5c145 |
+ return (struct fetch_script)
|
|
|
d5c145 |
+ { cvt, FETCH_HFA, sz, hfa_t, count };
|
|
|
d5c145 |
+ return (struct fetch_script)
|
|
|
d5c145 |
+ { cvt, FETCH_STACK, sz, hfa_t, count };
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ if (sz <= 16) {
|
|
|
d5c145 |
+ size_t count = sz / 8;
|
|
|
d5c145 |
+ if (context->ngrn + count <= 8)
|
|
|
d5c145 |
+ return (struct fetch_script)
|
|
|
d5c145 |
+ { cvt, FETCH_GPR, sz };
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ cvt = CVT_BYREF;
|
|
|
d5c145 |
+ sz = 8;
|
|
|
d5c145 |
+ /* Fall through. */
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ case ARGTYPE_POINTER:
|
|
|
d5c145 |
+ case ARGTYPE_INT:
|
|
|
d5c145 |
+ case ARGTYPE_UINT:
|
|
|
d5c145 |
+ case ARGTYPE_LONG:
|
|
|
d5c145 |
+ case ARGTYPE_ULONG:
|
|
|
d5c145 |
+ case ARGTYPE_CHAR:
|
|
|
d5c145 |
+ case ARGTYPE_SHORT:
|
|
|
d5c145 |
+ case ARGTYPE_USHORT:
|
|
|
d5c145 |
+ if (context->ngrn < 8 && sz <= 8)
|
|
|
d5c145 |
+ return (struct fetch_script) { cvt, FETCH_GPR, sz };
|
|
|
d5c145 |
+ /* We don't support types wider than 8 bytes as of
|
|
|
d5c145 |
+ * now. */
|
|
|
d5c145 |
+ assert(sz <= 8);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ return (struct fetch_script) { cvt, FETCH_STACK, sz };
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ case ARGTYPE_FLOAT:
|
|
|
d5c145 |
+ case ARGTYPE_DOUBLE:
|
|
|
d5c145 |
+ if (context->nsrn < 8) {
|
|
|
d5c145 |
+ /* ltrace doesn't support float128. */
|
|
|
d5c145 |
+ assert(sz <= 8);
|
|
|
d5c145 |
+ return (struct fetch_script) { cvt, FETCH_SSE, sz };
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ return (struct fetch_script) { cvt, FETCH_STACK, sz };
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ assert(! "Failed to allocate argument.");
|
|
|
d5c145 |
+ abort();
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+static int
|
|
|
d5c145 |
+convert_arg(struct value *value, struct fetch_script how)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ switch (how.c) {
|
|
|
d5c145 |
+ case CVT_NOP:
|
|
|
d5c145 |
+ return 0;
|
|
|
d5c145 |
+ case CVT_BYREF:
|
|
|
d5c145 |
+ return value_pass_by_reference(value);
|
|
|
d5c145 |
+ case CVT_ERR:
|
|
|
d5c145 |
+ return -1;
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ assert(! "Don't know how to convert argument.");
|
|
|
d5c145 |
+ abort();
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+static int
|
|
|
d5c145 |
+fetch_arg(struct fetch_context *context,
|
|
|
d5c145 |
+ struct process *proc, struct arg_type_info *info,
|
|
|
d5c145 |
+ struct value *value, struct fetch_script how)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ if (convert_arg(value, how) < 0)
|
|
|
d5c145 |
+ return -1;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ switch (how.f) {
|
|
|
d5c145 |
+ case FETCH_NOP:
|
|
|
d5c145 |
+ return 0;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ case FETCH_STACK:
|
|
|
d5c145 |
+ if (how.hfa_t != NULL && how.count != 0 && how.count <= 8)
|
|
|
d5c145 |
+ context->nsrn = 8;
|
|
|
d5c145 |
+ return fetch_stack(context, value,
|
|
|
d5c145 |
+ type_alignof(proc, info), how.sz);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ case FETCH_GPR:
|
|
|
d5c145 |
+ return fetch_gpr(context, value, how.sz);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ case FETCH_SSE:
|
|
|
d5c145 |
+ return fetch_sse(context, value, how.sz);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ case FETCH_HFA:
|
|
|
d5c145 |
+ return fetch_hfa(context, value, how.hfa_t, how.count);
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ assert(! "Don't know how to fetch argument.");
|
|
|
d5c145 |
+ abort();
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+struct fetch_context *
|
|
|
d5c145 |
+arch_fetch_arg_init(enum tof type, struct process *proc,
|
|
|
d5c145 |
+ struct arg_type_info *ret_info)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ struct fetch_context *context = malloc(sizeof *context);
|
|
|
d5c145 |
+ if (context == NULL || context_init(context, proc) < 0) {
|
|
|
d5c145 |
+ fail:
|
|
|
d5c145 |
+ free(context);
|
|
|
d5c145 |
+ return NULL;
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ /* There's a provision in ARMv8 parameter passing convention
|
|
|
d5c145 |
+ * for returning types that, if passed as first argument to a
|
|
|
d5c145 |
+ * function, would be passed on stack. For those types, x8
|
|
|
d5c145 |
+ * contains an address where the return argument should be
|
|
|
d5c145 |
+ * placed. The callee doesn't need to preserve the value of
|
|
|
d5c145 |
+ * x8, so we need to fetch it now.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * To my knowledge, there are currently no types where this
|
|
|
d5c145 |
+ * holds, but the code is here, utterly untested. */
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ struct fetch_script how = pass_arg(context, proc, ret_info);
|
|
|
d5c145 |
+ if (how.c == CVT_ERR)
|
|
|
d5c145 |
+ goto fail;
|
|
|
d5c145 |
+ if (how.c == CVT_NOP && how.f == FETCH_STACK) {
|
|
|
d5c145 |
+ /* XXX double cast. */
|
|
|
d5c145 |
+ context->x8 = (arch_addr_t) (uintptr_t) context->gregs.regs[8];
|
|
|
d5c145 |
+ /* See the comment above about the assert. */
|
|
|
d5c145 |
+ assert(! "Unexpected: first argument passed on stack.");
|
|
|
d5c145 |
+ abort();
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ return context;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+int
|
|
|
d5c145 |
+arch_fetch_arg_next(struct fetch_context *context, enum tof type,
|
|
|
d5c145 |
+ struct process *proc, struct arg_type_info *info,
|
|
|
d5c145 |
+ struct value *value)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ return fetch_arg(context, proc, info, value,
|
|
|
d5c145 |
+ pass_arg(context, proc, info));
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+int
|
|
|
d5c145 |
+arch_fetch_retval(struct fetch_context *context, enum tof type,
|
|
|
d5c145 |
+ struct process *proc, struct arg_type_info *info,
|
|
|
d5c145 |
+ struct value *value)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ if (context->x8 != 0) {
|
|
|
d5c145 |
+ value_in_inferior(value, context->x8);
|
|
|
d5c145 |
+ return 0;
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ if (context_init(context, proc) < 0)
|
|
|
d5c145 |
+ return -1;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ return fetch_arg(context, proc, info, value,
|
|
|
d5c145 |
+ pass_arg(context, proc, info));
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+void
|
|
|
d5c145 |
+arch_fetch_arg_done(struct fetch_context *context)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ if (context != NULL)
|
|
|
d5c145 |
+ free(context);
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+size_t
|
|
|
d5c145 |
+arch_type_sizeof(struct process *proc, struct arg_type_info *arg)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ return (size_t) -2;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+size_t
|
|
|
d5c145 |
+arch_type_alignof(struct process *proc, struct arg_type_info *arg)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ return (size_t) -2;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
diff --git a/sysdeps/linux-gnu/aarch64/plt.c b/sysdeps/linux-gnu/aarch64/plt.c
|
|
|
d5c145 |
new file mode 100644
|
|
|
d5c145 |
index 0000000..29dc4c9
|
|
|
d5c145 |
--- /dev/null
|
|
|
d5c145 |
+++ b/sysdeps/linux-gnu/aarch64/plt.c
|
|
|
d5c145 |
@@ -0,0 +1,38 @@
|
|
|
d5c145 |
+/*
|
|
|
d5c145 |
+ * This file is part of ltrace.
|
|
|
d5c145 |
+ * Copyright (C) 2014 Petr Machata, Red Hat, Inc.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is free software; you can redistribute it and/or
|
|
|
d5c145 |
+ * modify it under the terms of the GNU General Public License as
|
|
|
d5c145 |
+ * published by the Free Software Foundation; either version 2 of the
|
|
|
d5c145 |
+ * License, or (at your option) any later version.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is distributed in the hope that it will be useful, but
|
|
|
d5c145 |
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
d5c145 |
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
d5c145 |
+ * General Public License for more details.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * You should have received a copy of the GNU General Public License
|
|
|
d5c145 |
+ * along with this program; if not, write to the Free Software
|
|
|
d5c145 |
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
|
|
|
d5c145 |
+ * 02110-1301 USA
|
|
|
d5c145 |
+ */
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+#include <gelf.h>
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+#include "backend.h"
|
|
|
d5c145 |
+#include "proc.h"
|
|
|
d5c145 |
+#include "library.h"
|
|
|
d5c145 |
+#include "ltrace-elf.h"
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+arch_addr_t
|
|
|
d5c145 |
+sym2addr(struct process *proc, struct library_symbol *sym)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ return sym->enter_addr;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+GElf_Addr
|
|
|
d5c145 |
+arch_plt_sym_val(struct ltelf *lte, size_t ndx, GElf_Rela *rela)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ return lte->plt_addr + 32 + ndx * 16;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
diff --git a/sysdeps/linux-gnu/aarch64/ptrace.h b/sysdeps/linux-gnu/aarch64/ptrace.h
|
|
|
d5c145 |
new file mode 100644
|
|
|
d5c145 |
index 0000000..283c314
|
|
|
d5c145 |
--- /dev/null
|
|
|
d5c145 |
+++ b/sysdeps/linux-gnu/aarch64/ptrace.h
|
|
|
d5c145 |
@@ -0,0 +1,22 @@
|
|
|
d5c145 |
+/*
|
|
|
d5c145 |
+ * This file is part of ltrace.
|
|
|
d5c145 |
+ * Copyright (C) 2014 Petr Machata, Red Hat, Inc.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is free software; you can redistribute it and/or
|
|
|
d5c145 |
+ * modify it under the terms of the GNU General Public License as
|
|
|
d5c145 |
+ * published by the Free Software Foundation; either version 2 of the
|
|
|
d5c145 |
+ * License, or (at your option) any later version.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is distributed in the hope that it will be useful, but
|
|
|
d5c145 |
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
d5c145 |
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
d5c145 |
+ * General Public License for more details.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * You should have received a copy of the GNU General Public License
|
|
|
d5c145 |
+ * along with this program; if not, write to the Free Software
|
|
|
d5c145 |
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
|
|
|
d5c145 |
+ * 02110-1301 USA
|
|
|
d5c145 |
+ */
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+#include <sys/ptrace.h>
|
|
|
d5c145 |
+#include <asm/ptrace.h>
|
|
|
d5c145 |
diff --git a/sysdeps/linux-gnu/aarch64/regs.c b/sysdeps/linux-gnu/aarch64/regs.c
|
|
|
d5c145 |
new file mode 100644
|
|
|
d5c145 |
index 0000000..06eb72b
|
|
|
d5c145 |
--- /dev/null
|
|
|
d5c145 |
+++ b/sysdeps/linux-gnu/aarch64/regs.c
|
|
|
d5c145 |
@@ -0,0 +1,130 @@
|
|
|
d5c145 |
+/*
|
|
|
d5c145 |
+ * This file is part of ltrace.
|
|
|
d5c145 |
+ * Copyright (C) 2014 Petr Machata, Red Hat, Inc.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is free software; you can redistribute it and/or
|
|
|
d5c145 |
+ * modify it under the terms of the GNU General Public License as
|
|
|
d5c145 |
+ * published by the Free Software Foundation; either version 2 of the
|
|
|
d5c145 |
+ * License, or (at your option) any later version.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is distributed in the hope that it will be useful, but
|
|
|
d5c145 |
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
d5c145 |
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
d5c145 |
+ * General Public License for more details.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * You should have received a copy of the GNU General Public License
|
|
|
d5c145 |
+ * along with this program; if not, write to the Free Software
|
|
|
d5c145 |
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
|
|
|
d5c145 |
+ * 02110-1301 USA
|
|
|
d5c145 |
+ */
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+#include <sys/ptrace.h>
|
|
|
d5c145 |
+#include <asm/ptrace.h>
|
|
|
d5c145 |
+#include <linux/uio.h>
|
|
|
d5c145 |
+#include <assert.h>
|
|
|
d5c145 |
+#include <stdlib.h>
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+#include "backend.h"
|
|
|
d5c145 |
+#include "proc.h"
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+#define PC_OFF (32 * 4)
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+int
|
|
|
d5c145 |
+aarch64_read_gregs(struct process *proc, struct user_pt_regs *regs)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ *regs = (struct user_pt_regs) {};
|
|
|
d5c145 |
+ struct iovec iovec;
|
|
|
d5c145 |
+ iovec.iov_base = regs;
|
|
|
d5c145 |
+ iovec.iov_len = sizeof *regs;
|
|
|
d5c145 |
+ return ptrace(PTRACE_GETREGSET, proc->pid, NT_PRSTATUS, &iovec) < 0
|
|
|
d5c145 |
+ ? -1 : 0;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+int
|
|
|
d5c145 |
+aarch64_write_gregs(struct process *proc, struct user_pt_regs *regs)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ struct iovec iovec;
|
|
|
d5c145 |
+ iovec.iov_base = regs;
|
|
|
d5c145 |
+ iovec.iov_len = sizeof *regs;
|
|
|
d5c145 |
+ return ptrace(PTRACE_SETREGSET, proc->pid, NT_PRSTATUS, &iovec) < 0
|
|
|
d5c145 |
+ ? -1 : 0;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+int
|
|
|
d5c145 |
+aarch64_read_fregs(struct process *proc, struct user_fpsimd_state *regs)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ *regs = (struct user_fpsimd_state) {};
|
|
|
d5c145 |
+ struct iovec iovec;
|
|
|
d5c145 |
+ iovec.iov_base = regs;
|
|
|
d5c145 |
+ iovec.iov_len = sizeof *regs;
|
|
|
d5c145 |
+ return ptrace(PTRACE_GETREGSET, proc->pid, NT_FPREGSET, &iovec) < 0
|
|
|
d5c145 |
+ ? -1 : 0;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+arch_addr_t
|
|
|
d5c145 |
+get_instruction_pointer(struct process *proc)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ struct user_pt_regs regs;
|
|
|
d5c145 |
+ if (aarch64_read_gregs(proc, ®s) < 0) {
|
|
|
d5c145 |
+ fprintf(stderr, "get_instruction_pointer: "
|
|
|
d5c145 |
+ "Couldn't read registers of %d.\n", proc->pid);
|
|
|
d5c145 |
+ return 0;
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ /*
|
|
|
d5c145 |
+ char buf[128];
|
|
|
d5c145 |
+ sprintf(buf, "cat /proc/%d/maps", proc->pid);
|
|
|
d5c145 |
+ system(buf);
|
|
|
d5c145 |
+ */
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ /* XXX double cast */
|
|
|
d5c145 |
+ return (arch_addr_t) (uintptr_t) regs.pc;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+void
|
|
|
d5c145 |
+set_instruction_pointer(struct process *proc, arch_addr_t addr)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ struct user_pt_regs regs;
|
|
|
d5c145 |
+ if (aarch64_read_gregs(proc, ®s) < 0) {
|
|
|
d5c145 |
+ fprintf(stderr, "get_instruction_pointer: "
|
|
|
d5c145 |
+ "Couldn't read registers of %d.\n", proc->pid);
|
|
|
d5c145 |
+ return;
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ /* XXX double cast */
|
|
|
d5c145 |
+ regs.pc = (uint64_t) (uintptr_t) addr;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ if (aarch64_write_gregs(proc, ®s) < 0) {
|
|
|
d5c145 |
+ fprintf(stderr, "get_instruction_pointer: "
|
|
|
d5c145 |
+ "Couldn't write registers of %d.\n", proc->pid);
|
|
|
d5c145 |
+ return;
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+arch_addr_t
|
|
|
d5c145 |
+get_stack_pointer(struct process *proc)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ struct user_pt_regs regs;
|
|
|
d5c145 |
+ if (aarch64_read_gregs(proc, ®s) < 0) {
|
|
|
d5c145 |
+ fprintf(stderr, "get_stack_pointer: "
|
|
|
d5c145 |
+ "Couldn't read registers of %d.\n", proc->pid);
|
|
|
d5c145 |
+ return 0;
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ /* XXX double cast */
|
|
|
d5c145 |
+ return (arch_addr_t) (uintptr_t) regs.sp;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+arch_addr_t
|
|
|
d5c145 |
+get_return_addr(struct process *proc, arch_addr_t stack_pointer)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ struct user_pt_regs regs;
|
|
|
d5c145 |
+ if (aarch64_read_gregs(proc, ®s) < 0) {
|
|
|
d5c145 |
+ fprintf(stderr, "get_return_addr: "
|
|
|
d5c145 |
+ "Couldn't read registers of %d.\n", proc->pid);
|
|
|
d5c145 |
+ return 0;
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ /* XXX double cast */
|
|
|
d5c145 |
+ return (arch_addr_t) (uintptr_t) regs.regs[30];
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
diff --git a/sysdeps/linux-gnu/aarch64/signalent.h b/sysdeps/linux-gnu/aarch64/signalent.h
|
|
|
d5c145 |
new file mode 100644
|
|
|
d5c145 |
index 0000000..bf56ebc
|
|
|
d5c145 |
--- /dev/null
|
|
|
d5c145 |
+++ b/sysdeps/linux-gnu/aarch64/signalent.h
|
|
|
d5c145 |
@@ -0,0 +1,52 @@
|
|
|
d5c145 |
+/*
|
|
|
d5c145 |
+ * This file is part of ltrace.
|
|
|
d5c145 |
+ * Copyright (C) 2006 Ian Wienand
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is free software; you can redistribute it and/or
|
|
|
d5c145 |
+ * modify it under the terms of the GNU General Public License as
|
|
|
d5c145 |
+ * published by the Free Software Foundation; either version 2 of the
|
|
|
d5c145 |
+ * License, or (at your option) any later version.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is distributed in the hope that it will be useful, but
|
|
|
d5c145 |
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
d5c145 |
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
d5c145 |
+ * General Public License for more details.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * You should have received a copy of the GNU General Public License
|
|
|
d5c145 |
+ * along with this program; if not, write to the Free Software
|
|
|
d5c145 |
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
|
|
|
d5c145 |
+ * 02110-1301 USA
|
|
|
d5c145 |
+ */
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ "SIG_0", /* 0 */
|
|
|
d5c145 |
+ "SIGHUP", /* 1 */
|
|
|
d5c145 |
+ "SIGINT", /* 2 */
|
|
|
d5c145 |
+ "SIGQUIT", /* 3 */
|
|
|
d5c145 |
+ "SIGILL", /* 4 */
|
|
|
d5c145 |
+ "SIGTRAP", /* 5 */
|
|
|
d5c145 |
+ "SIGABRT", /* 6 */
|
|
|
d5c145 |
+ "SIGBUS", /* 7 */
|
|
|
d5c145 |
+ "SIGFPE", /* 8 */
|
|
|
d5c145 |
+ "SIGKILL", /* 9 */
|
|
|
d5c145 |
+ "SIGUSR1", /* 10 */
|
|
|
d5c145 |
+ "SIGSEGV", /* 11 */
|
|
|
d5c145 |
+ "SIGUSR2", /* 12 */
|
|
|
d5c145 |
+ "SIGPIPE", /* 13 */
|
|
|
d5c145 |
+ "SIGALRM", /* 14 */
|
|
|
d5c145 |
+ "SIGTERM", /* 15 */
|
|
|
d5c145 |
+ "SIGSTKFLT", /* 16 */
|
|
|
d5c145 |
+ "SIGCHLD", /* 17 */
|
|
|
d5c145 |
+ "SIGCONT", /* 18 */
|
|
|
d5c145 |
+ "SIGSTOP", /* 19 */
|
|
|
d5c145 |
+ "SIGTSTP", /* 20 */
|
|
|
d5c145 |
+ "SIGTTIN", /* 21 */
|
|
|
d5c145 |
+ "SIGTTOU", /* 22 */
|
|
|
d5c145 |
+ "SIGURG", /* 23 */
|
|
|
d5c145 |
+ "SIGXCPU", /* 24 */
|
|
|
d5c145 |
+ "SIGXFSZ", /* 25 */
|
|
|
d5c145 |
+ "SIGVTALRM", /* 26 */
|
|
|
d5c145 |
+ "SIGPROF", /* 27 */
|
|
|
d5c145 |
+ "SIGWINCH", /* 28 */
|
|
|
d5c145 |
+ "SIGIO", /* 29 */
|
|
|
d5c145 |
+ "SIGPWR", /* 30 */
|
|
|
d5c145 |
+ "SIGSYS", /* 31 */
|
|
|
d5c145 |
diff --git a/sysdeps/linux-gnu/aarch64/syscallent.h b/sysdeps/linux-gnu/aarch64/syscallent.h
|
|
|
d5c145 |
new file mode 100644
|
|
|
d5c145 |
index 0000000..aca8191
|
|
|
d5c145 |
--- /dev/null
|
|
|
d5c145 |
+++ b/sysdeps/linux-gnu/aarch64/syscallent.h
|
|
|
d5c145 |
@@ -0,0 +1,1100 @@
|
|
|
d5c145 |
+/*
|
|
|
d5c145 |
+ * This file is part of ltrace.
|
|
|
d5c145 |
+ * Copyright (C) 2014 Petr Machata, Red Hat, Inc.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is free software; you can redistribute it and/or
|
|
|
d5c145 |
+ * modify it under the terms of the GNU General Public License as
|
|
|
d5c145 |
+ * published by the Free Software Foundation; either version 2 of the
|
|
|
d5c145 |
+ * License, or (at your option) any later version.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is distributed in the hope that it will be useful, but
|
|
|
d5c145 |
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
d5c145 |
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
d5c145 |
+ * General Public License for more details.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * You should have received a copy of the GNU General Public License
|
|
|
d5c145 |
+ * along with this program; if not, write to the Free Software
|
|
|
d5c145 |
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
|
|
|
d5c145 |
+ * 02110-1301 USA
|
|
|
d5c145 |
+ */
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ "io_setup", /* 0 */
|
|
|
d5c145 |
+ "io_destroy", /* 1 */
|
|
|
d5c145 |
+ "io_submit", /* 2 */
|
|
|
d5c145 |
+ "io_cancel", /* 3 */
|
|
|
d5c145 |
+ "io_getevents", /* 4 */
|
|
|
d5c145 |
+ "setxattr", /* 5 */
|
|
|
d5c145 |
+ "lsetxattr", /* 6 */
|
|
|
d5c145 |
+ "fsetxattr", /* 7 */
|
|
|
d5c145 |
+ "getxattr", /* 8 */
|
|
|
d5c145 |
+ "lgetxattr", /* 9 */
|
|
|
d5c145 |
+ "fgetxattr", /* 10 */
|
|
|
d5c145 |
+ "listxattr", /* 11 */
|
|
|
d5c145 |
+ "llistxattr", /* 12 */
|
|
|
d5c145 |
+ "flistxattr", /* 13 */
|
|
|
d5c145 |
+ "removexattr", /* 14 */
|
|
|
d5c145 |
+ "lremovexattr", /* 15 */
|
|
|
d5c145 |
+ "fremovexattr", /* 16 */
|
|
|
d5c145 |
+ "getcwd", /* 17 */
|
|
|
d5c145 |
+ "lookup_dcookie", /* 18 */
|
|
|
d5c145 |
+ "eventfd2", /* 19 */
|
|
|
d5c145 |
+ "epoll_create1", /* 20 */
|
|
|
d5c145 |
+ "epoll_ctl", /* 21 */
|
|
|
d5c145 |
+ "epoll_pwait", /* 22 */
|
|
|
d5c145 |
+ "dup", /* 23 */
|
|
|
d5c145 |
+ "dup3", /* 24 */
|
|
|
d5c145 |
+ "fcntl", /* 25 */
|
|
|
d5c145 |
+ "inotify_init1", /* 26 */
|
|
|
d5c145 |
+ "inotify_add_watch", /* 27 */
|
|
|
d5c145 |
+ "inotify_rm_watch", /* 28 */
|
|
|
d5c145 |
+ "ioctl", /* 29 */
|
|
|
d5c145 |
+ "ioprio_set", /* 30 */
|
|
|
d5c145 |
+ "ioprio_get", /* 31 */
|
|
|
d5c145 |
+ "flock", /* 32 */
|
|
|
d5c145 |
+ "mknodat", /* 33 */
|
|
|
d5c145 |
+ "mkdirat", /* 34 */
|
|
|
d5c145 |
+ "unlinkat", /* 35 */
|
|
|
d5c145 |
+ "symlinkat", /* 36 */
|
|
|
d5c145 |
+ "linkat", /* 37 */
|
|
|
d5c145 |
+ "renameat", /* 38 */
|
|
|
d5c145 |
+ "umount2", /* 39 */
|
|
|
d5c145 |
+ "mount", /* 40 */
|
|
|
d5c145 |
+ "pivot_root", /* 41 */
|
|
|
d5c145 |
+ "nfsservctl", /* 42 */
|
|
|
d5c145 |
+ "statfs", /* 43 */
|
|
|
d5c145 |
+ "fstatfs", /* 44 */
|
|
|
d5c145 |
+ "truncate", /* 45 */
|
|
|
d5c145 |
+ "ftruncate", /* 46 */
|
|
|
d5c145 |
+ "fallocate", /* 47 */
|
|
|
d5c145 |
+ "faccessat", /* 48 */
|
|
|
d5c145 |
+ "chdir", /* 49 */
|
|
|
d5c145 |
+ "fchdir", /* 50 */
|
|
|
d5c145 |
+ "chroot", /* 51 */
|
|
|
d5c145 |
+ "fchmod", /* 52 */
|
|
|
d5c145 |
+ "fchmodat", /* 53 */
|
|
|
d5c145 |
+ "fchownat", /* 54 */
|
|
|
d5c145 |
+ "fchown", /* 55 */
|
|
|
d5c145 |
+ "openat", /* 56 */
|
|
|
d5c145 |
+ "close", /* 57 */
|
|
|
d5c145 |
+ "vhangup", /* 58 */
|
|
|
d5c145 |
+ "pipe2", /* 59 */
|
|
|
d5c145 |
+ "quotactl", /* 60 */
|
|
|
d5c145 |
+ "getdents64", /* 61 */
|
|
|
d5c145 |
+ "lseek", /* 62 */
|
|
|
d5c145 |
+ "read", /* 63 */
|
|
|
d5c145 |
+ "write", /* 64 */
|
|
|
d5c145 |
+ "readv", /* 65 */
|
|
|
d5c145 |
+ "writev", /* 66 */
|
|
|
d5c145 |
+ "pread64", /* 67 */
|
|
|
d5c145 |
+ "pwrite64", /* 68 */
|
|
|
d5c145 |
+ "preadv", /* 69 */
|
|
|
d5c145 |
+ "pwritev", /* 70 */
|
|
|
d5c145 |
+ "sendfile", /* 71 */
|
|
|
d5c145 |
+ "pselect6", /* 72 */
|
|
|
d5c145 |
+ "ppoll", /* 73 */
|
|
|
d5c145 |
+ "signalfd4", /* 74 */
|
|
|
d5c145 |
+ "vmsplice", /* 75 */
|
|
|
d5c145 |
+ "splice", /* 76 */
|
|
|
d5c145 |
+ "tee", /* 77 */
|
|
|
d5c145 |
+ "readlinkat", /* 78 */
|
|
|
d5c145 |
+ "fstatat", /* 79 */
|
|
|
d5c145 |
+ "fstat", /* 80 */
|
|
|
d5c145 |
+ "sync", /* 81 */
|
|
|
d5c145 |
+ "fsync", /* 82 */
|
|
|
d5c145 |
+ "fdatasync", /* 83 */
|
|
|
d5c145 |
+ "sync_file_range", /* 84 */
|
|
|
d5c145 |
+ "timerfd_create", /* 85 */
|
|
|
d5c145 |
+ "timerfd_settime", /* 86 */
|
|
|
d5c145 |
+ "timerfd_gettime", /* 87 */
|
|
|
d5c145 |
+ "utimensat", /* 88 */
|
|
|
d5c145 |
+ "acct", /* 89 */
|
|
|
d5c145 |
+ "capget", /* 90 */
|
|
|
d5c145 |
+ "capset", /* 91 */
|
|
|
d5c145 |
+ "personality", /* 92 */
|
|
|
d5c145 |
+ "exit", /* 93 */
|
|
|
d5c145 |
+ "exit_group", /* 94 */
|
|
|
d5c145 |
+ "waitid", /* 95 */
|
|
|
d5c145 |
+ "set_tid_address", /* 96 */
|
|
|
d5c145 |
+ "unshare", /* 97 */
|
|
|
d5c145 |
+ "futex", /* 98 */
|
|
|
d5c145 |
+ "set_robust_list", /* 99 */
|
|
|
d5c145 |
+ "get_robust_list", /* 100 */
|
|
|
d5c145 |
+ "nanosleep", /* 101 */
|
|
|
d5c145 |
+ "getitimer", /* 102 */
|
|
|
d5c145 |
+ "setitimer", /* 103 */
|
|
|
d5c145 |
+ "kexec_load", /* 104 */
|
|
|
d5c145 |
+ "init_module", /* 105 */
|
|
|
d5c145 |
+ "delete_module", /* 106 */
|
|
|
d5c145 |
+ "timer_create", /* 107 */
|
|
|
d5c145 |
+ "timer_gettime", /* 108 */
|
|
|
d5c145 |
+ "timer_getoverrun", /* 109 */
|
|
|
d5c145 |
+ "timer_settime", /* 110 */
|
|
|
d5c145 |
+ "timer_delete", /* 111 */
|
|
|
d5c145 |
+ "clock_settime", /* 112 */
|
|
|
d5c145 |
+ "clock_gettime", /* 113 */
|
|
|
d5c145 |
+ "clock_getres", /* 114 */
|
|
|
d5c145 |
+ "clock_nanosleep", /* 115 */
|
|
|
d5c145 |
+ "syslog", /* 116 */
|
|
|
d5c145 |
+ "ptrace", /* 117 */
|
|
|
d5c145 |
+ "sched_setparam", /* 118 */
|
|
|
d5c145 |
+ "sched_setscheduler", /* 119 */
|
|
|
d5c145 |
+ "sched_getscheduler", /* 120 */
|
|
|
d5c145 |
+ "sched_getparam", /* 121 */
|
|
|
d5c145 |
+ "sched_setaffinity", /* 122 */
|
|
|
d5c145 |
+ "sched_getaffinity", /* 123 */
|
|
|
d5c145 |
+ "sched_yield", /* 124 */
|
|
|
d5c145 |
+ "sched_get_priority_max", /* 125 */
|
|
|
d5c145 |
+ "sched_get_priority_min", /* 126 */
|
|
|
d5c145 |
+ "sched_rr_get_interval", /* 127 */
|
|
|
d5c145 |
+ "restart_syscall", /* 128 */
|
|
|
d5c145 |
+ "kill", /* 129 */
|
|
|
d5c145 |
+ "tkill", /* 130 */
|
|
|
d5c145 |
+ "tgkill", /* 131 */
|
|
|
d5c145 |
+ "sigaltstack", /* 132 */
|
|
|
d5c145 |
+ "rt_sigsuspend", /* 133 */
|
|
|
d5c145 |
+ "rt_sigaction", /* 134 */
|
|
|
d5c145 |
+ "rt_sigprocmask", /* 135 */
|
|
|
d5c145 |
+ "rt_sigpending", /* 136 */
|
|
|
d5c145 |
+ "rt_sigtimedwait", /* 137 */
|
|
|
d5c145 |
+ "rt_sigqueueinfo", /* 138 */
|
|
|
d5c145 |
+ "rt_sigreturn", /* 139 */
|
|
|
d5c145 |
+ "setpriority", /* 140 */
|
|
|
d5c145 |
+ "getpriority", /* 141 */
|
|
|
d5c145 |
+ "reboot", /* 142 */
|
|
|
d5c145 |
+ "setregid", /* 143 */
|
|
|
d5c145 |
+ "setgid", /* 144 */
|
|
|
d5c145 |
+ "setreuid", /* 145 */
|
|
|
d5c145 |
+ "setuid", /* 146 */
|
|
|
d5c145 |
+ "setresuid", /* 147 */
|
|
|
d5c145 |
+ "getresuid", /* 148 */
|
|
|
d5c145 |
+ "setresgid", /* 149 */
|
|
|
d5c145 |
+ "getresgid", /* 150 */
|
|
|
d5c145 |
+ "setfsuid", /* 151 */
|
|
|
d5c145 |
+ "setfsgid", /* 152 */
|
|
|
d5c145 |
+ "times", /* 153 */
|
|
|
d5c145 |
+ "setpgid", /* 154 */
|
|
|
d5c145 |
+ "getpgid", /* 155 */
|
|
|
d5c145 |
+ "getsid", /* 156 */
|
|
|
d5c145 |
+ "setsid", /* 157 */
|
|
|
d5c145 |
+ "getgroups", /* 158 */
|
|
|
d5c145 |
+ "setgroups", /* 159 */
|
|
|
d5c145 |
+ "uname", /* 160 */
|
|
|
d5c145 |
+ "sethostname", /* 161 */
|
|
|
d5c145 |
+ "setdomainname", /* 162 */
|
|
|
d5c145 |
+ "getrlimit", /* 163 */
|
|
|
d5c145 |
+ "setrlimit", /* 164 */
|
|
|
d5c145 |
+ "getrusage", /* 165 */
|
|
|
d5c145 |
+ "umask", /* 166 */
|
|
|
d5c145 |
+ "prctl", /* 167 */
|
|
|
d5c145 |
+ "getcpu", /* 168 */
|
|
|
d5c145 |
+ "gettimeofday", /* 169 */
|
|
|
d5c145 |
+ "settimeofday", /* 170 */
|
|
|
d5c145 |
+ "adjtimex", /* 171 */
|
|
|
d5c145 |
+ "getpid", /* 172 */
|
|
|
d5c145 |
+ "getppid", /* 173 */
|
|
|
d5c145 |
+ "getuid", /* 174 */
|
|
|
d5c145 |
+ "geteuid", /* 175 */
|
|
|
d5c145 |
+ "getgid", /* 176 */
|
|
|
d5c145 |
+ "getegid", /* 177 */
|
|
|
d5c145 |
+ "gettid", /* 178 */
|
|
|
d5c145 |
+ "sysinfo", /* 179 */
|
|
|
d5c145 |
+ "mq_open", /* 180 */
|
|
|
d5c145 |
+ "mq_unlink", /* 181 */
|
|
|
d5c145 |
+ "mq_timedsend", /* 182 */
|
|
|
d5c145 |
+ "mq_timedreceive", /* 183 */
|
|
|
d5c145 |
+ "mq_notify", /* 184 */
|
|
|
d5c145 |
+ "mq_getsetattr", /* 185 */
|
|
|
d5c145 |
+ "msgget", /* 186 */
|
|
|
d5c145 |
+ "msgctl", /* 187 */
|
|
|
d5c145 |
+ "msgrcv", /* 188 */
|
|
|
d5c145 |
+ "msgsnd", /* 189 */
|
|
|
d5c145 |
+ "semget", /* 190 */
|
|
|
d5c145 |
+ "semctl", /* 191 */
|
|
|
d5c145 |
+ "semtimedop", /* 192 */
|
|
|
d5c145 |
+ "semop", /* 193 */
|
|
|
d5c145 |
+ "shmget", /* 194 */
|
|
|
d5c145 |
+ "shmctl", /* 195 */
|
|
|
d5c145 |
+ "shmat", /* 196 */
|
|
|
d5c145 |
+ "shmdt", /* 197 */
|
|
|
d5c145 |
+ "socket", /* 198 */
|
|
|
d5c145 |
+ "socketpair", /* 199 */
|
|
|
d5c145 |
+ "bind", /* 200 */
|
|
|
d5c145 |
+ "listen", /* 201 */
|
|
|
d5c145 |
+ "accept", /* 202 */
|
|
|
d5c145 |
+ "connect", /* 203 */
|
|
|
d5c145 |
+ "getsockname", /* 204 */
|
|
|
d5c145 |
+ "getpeername", /* 205 */
|
|
|
d5c145 |
+ "sendto", /* 206 */
|
|
|
d5c145 |
+ "recvfrom", /* 207 */
|
|
|
d5c145 |
+ "setsockopt", /* 208 */
|
|
|
d5c145 |
+ "getsockopt", /* 209 */
|
|
|
d5c145 |
+ "shutdown", /* 210 */
|
|
|
d5c145 |
+ "sendmsg", /* 211 */
|
|
|
d5c145 |
+ "recvmsg", /* 212 */
|
|
|
d5c145 |
+ "readahead", /* 213 */
|
|
|
d5c145 |
+ "brk", /* 214 */
|
|
|
d5c145 |
+ "munmap", /* 215 */
|
|
|
d5c145 |
+ "mremap", /* 216 */
|
|
|
d5c145 |
+ "add_key", /* 217 */
|
|
|
d5c145 |
+ "request_key", /* 218 */
|
|
|
d5c145 |
+ "keyctl", /* 219 */
|
|
|
d5c145 |
+ "clone", /* 220 */
|
|
|
d5c145 |
+ "execve", /* 221 */
|
|
|
d5c145 |
+ "mmap", /* 222 */
|
|
|
d5c145 |
+ "fadvise64", /* 223 */
|
|
|
d5c145 |
+ "swapon", /* 224 */
|
|
|
d5c145 |
+ "swapoff", /* 225 */
|
|
|
d5c145 |
+ "mprotect", /* 226 */
|
|
|
d5c145 |
+ "msync", /* 227 */
|
|
|
d5c145 |
+ "mlock", /* 228 */
|
|
|
d5c145 |
+ "munlock", /* 229 */
|
|
|
d5c145 |
+ "mlockall", /* 230 */
|
|
|
d5c145 |
+ "munlockall", /* 231 */
|
|
|
d5c145 |
+ "mincore", /* 232 */
|
|
|
d5c145 |
+ "madvise", /* 233 */
|
|
|
d5c145 |
+ "remap_file_pages", /* 234 */
|
|
|
d5c145 |
+ "mbind", /* 235 */
|
|
|
d5c145 |
+ "get_mempolicy", /* 236 */
|
|
|
d5c145 |
+ "set_mempolicy", /* 237 */
|
|
|
d5c145 |
+ "migrate_pages", /* 238 */
|
|
|
d5c145 |
+ "move_pages", /* 239 */
|
|
|
d5c145 |
+ "rt_tgsigqueueinfo", /* 240 */
|
|
|
d5c145 |
+ "perf_event_open", /* 241 */
|
|
|
d5c145 |
+ "accept4", /* 242 */
|
|
|
d5c145 |
+ "recvmmsg", /* 243 */
|
|
|
d5c145 |
+ "arch_specific_syscall", /* 244 */
|
|
|
d5c145 |
+ "245", /* 245 */
|
|
|
d5c145 |
+ "246", /* 246 */
|
|
|
d5c145 |
+ "247", /* 247 */
|
|
|
d5c145 |
+ "248", /* 248 */
|
|
|
d5c145 |
+ "249", /* 249 */
|
|
|
d5c145 |
+ "250", /* 250 */
|
|
|
d5c145 |
+ "251", /* 251 */
|
|
|
d5c145 |
+ "252", /* 252 */
|
|
|
d5c145 |
+ "253", /* 253 */
|
|
|
d5c145 |
+ "254", /* 254 */
|
|
|
d5c145 |
+ "255", /* 255 */
|
|
|
d5c145 |
+ "256", /* 256 */
|
|
|
d5c145 |
+ "257", /* 257 */
|
|
|
d5c145 |
+ "258", /* 258 */
|
|
|
d5c145 |
+ "259", /* 259 */
|
|
|
d5c145 |
+ "wait4", /* 260 */
|
|
|
d5c145 |
+ "prlimit64", /* 261 */
|
|
|
d5c145 |
+ "fanotify_init", /* 262 */
|
|
|
d5c145 |
+ "fanotify_mark", /* 263 */
|
|
|
d5c145 |
+ "name_to_handle_at", /* 264 */
|
|
|
d5c145 |
+ "open_by_handle_at", /* 265 */
|
|
|
d5c145 |
+ "clock_adjtime", /* 266 */
|
|
|
d5c145 |
+ "syncfs", /* 267 */
|
|
|
d5c145 |
+ "setns", /* 268 */
|
|
|
d5c145 |
+ "sendmmsg", /* 269 */
|
|
|
d5c145 |
+ "process_vm_readv", /* 270 */
|
|
|
d5c145 |
+ "process_vm_writev", /* 271 */
|
|
|
d5c145 |
+ "kcmp", /* 272 */
|
|
|
d5c145 |
+ "finit_module", /* 273 */
|
|
|
d5c145 |
+ "syscalls", /* 274 */
|
|
|
d5c145 |
+ "275", /* 275 */
|
|
|
d5c145 |
+ "276", /* 276 */
|
|
|
d5c145 |
+ "277", /* 277 */
|
|
|
d5c145 |
+ "278", /* 278 */
|
|
|
d5c145 |
+ "279", /* 279 */
|
|
|
d5c145 |
+ "280", /* 280 */
|
|
|
d5c145 |
+ "281", /* 281 */
|
|
|
d5c145 |
+ "282", /* 282 */
|
|
|
d5c145 |
+ "283", /* 283 */
|
|
|
d5c145 |
+ "284", /* 284 */
|
|
|
d5c145 |
+ "285", /* 285 */
|
|
|
d5c145 |
+ "286", /* 286 */
|
|
|
d5c145 |
+ "287", /* 287 */
|
|
|
d5c145 |
+ "288", /* 288 */
|
|
|
d5c145 |
+ "289", /* 289 */
|
|
|
d5c145 |
+ "290", /* 290 */
|
|
|
d5c145 |
+ "291", /* 291 */
|
|
|
d5c145 |
+ "292", /* 292 */
|
|
|
d5c145 |
+ "293", /* 293 */
|
|
|
d5c145 |
+ "294", /* 294 */
|
|
|
d5c145 |
+ "295", /* 295 */
|
|
|
d5c145 |
+ "296", /* 296 */
|
|
|
d5c145 |
+ "297", /* 297 */
|
|
|
d5c145 |
+ "298", /* 298 */
|
|
|
d5c145 |
+ "299", /* 299 */
|
|
|
d5c145 |
+ "300", /* 300 */
|
|
|
d5c145 |
+ "301", /* 301 */
|
|
|
d5c145 |
+ "302", /* 302 */
|
|
|
d5c145 |
+ "303", /* 303 */
|
|
|
d5c145 |
+ "304", /* 304 */
|
|
|
d5c145 |
+ "305", /* 305 */
|
|
|
d5c145 |
+ "306", /* 306 */
|
|
|
d5c145 |
+ "307", /* 307 */
|
|
|
d5c145 |
+ "308", /* 308 */
|
|
|
d5c145 |
+ "309", /* 309 */
|
|
|
d5c145 |
+ "310", /* 310 */
|
|
|
d5c145 |
+ "311", /* 311 */
|
|
|
d5c145 |
+ "312", /* 312 */
|
|
|
d5c145 |
+ "313", /* 313 */
|
|
|
d5c145 |
+ "314", /* 314 */
|
|
|
d5c145 |
+ "315", /* 315 */
|
|
|
d5c145 |
+ "316", /* 316 */
|
|
|
d5c145 |
+ "317", /* 317 */
|
|
|
d5c145 |
+ "318", /* 318 */
|
|
|
d5c145 |
+ "319", /* 319 */
|
|
|
d5c145 |
+ "320", /* 320 */
|
|
|
d5c145 |
+ "321", /* 321 */
|
|
|
d5c145 |
+ "322", /* 322 */
|
|
|
d5c145 |
+ "323", /* 323 */
|
|
|
d5c145 |
+ "324", /* 324 */
|
|
|
d5c145 |
+ "325", /* 325 */
|
|
|
d5c145 |
+ "326", /* 326 */
|
|
|
d5c145 |
+ "327", /* 327 */
|
|
|
d5c145 |
+ "328", /* 328 */
|
|
|
d5c145 |
+ "329", /* 329 */
|
|
|
d5c145 |
+ "330", /* 330 */
|
|
|
d5c145 |
+ "331", /* 331 */
|
|
|
d5c145 |
+ "332", /* 332 */
|
|
|
d5c145 |
+ "333", /* 333 */
|
|
|
d5c145 |
+ "334", /* 334 */
|
|
|
d5c145 |
+ "335", /* 335 */
|
|
|
d5c145 |
+ "336", /* 336 */
|
|
|
d5c145 |
+ "337", /* 337 */
|
|
|
d5c145 |
+ "338", /* 338 */
|
|
|
d5c145 |
+ "339", /* 339 */
|
|
|
d5c145 |
+ "340", /* 340 */
|
|
|
d5c145 |
+ "341", /* 341 */
|
|
|
d5c145 |
+ "342", /* 342 */
|
|
|
d5c145 |
+ "343", /* 343 */
|
|
|
d5c145 |
+ "344", /* 344 */
|
|
|
d5c145 |
+ "345", /* 345 */
|
|
|
d5c145 |
+ "346", /* 346 */
|
|
|
d5c145 |
+ "347", /* 347 */
|
|
|
d5c145 |
+ "348", /* 348 */
|
|
|
d5c145 |
+ "349", /* 349 */
|
|
|
d5c145 |
+ "350", /* 350 */
|
|
|
d5c145 |
+ "351", /* 351 */
|
|
|
d5c145 |
+ "352", /* 352 */
|
|
|
d5c145 |
+ "353", /* 353 */
|
|
|
d5c145 |
+ "354", /* 354 */
|
|
|
d5c145 |
+ "355", /* 355 */
|
|
|
d5c145 |
+ "356", /* 356 */
|
|
|
d5c145 |
+ "357", /* 357 */
|
|
|
d5c145 |
+ "358", /* 358 */
|
|
|
d5c145 |
+ "359", /* 359 */
|
|
|
d5c145 |
+ "360", /* 360 */
|
|
|
d5c145 |
+ "361", /* 361 */
|
|
|
d5c145 |
+ "362", /* 362 */
|
|
|
d5c145 |
+ "363", /* 363 */
|
|
|
d5c145 |
+ "364", /* 364 */
|
|
|
d5c145 |
+ "365", /* 365 */
|
|
|
d5c145 |
+ "366", /* 366 */
|
|
|
d5c145 |
+ "367", /* 367 */
|
|
|
d5c145 |
+ "368", /* 368 */
|
|
|
d5c145 |
+ "369", /* 369 */
|
|
|
d5c145 |
+ "370", /* 370 */
|
|
|
d5c145 |
+ "371", /* 371 */
|
|
|
d5c145 |
+ "372", /* 372 */
|
|
|
d5c145 |
+ "373", /* 373 */
|
|
|
d5c145 |
+ "374", /* 374 */
|
|
|
d5c145 |
+ "375", /* 375 */
|
|
|
d5c145 |
+ "376", /* 376 */
|
|
|
d5c145 |
+ "377", /* 377 */
|
|
|
d5c145 |
+ "378", /* 378 */
|
|
|
d5c145 |
+ "379", /* 379 */
|
|
|
d5c145 |
+ "380", /* 380 */
|
|
|
d5c145 |
+ "381", /* 381 */
|
|
|
d5c145 |
+ "382", /* 382 */
|
|
|
d5c145 |
+ "383", /* 383 */
|
|
|
d5c145 |
+ "384", /* 384 */
|
|
|
d5c145 |
+ "385", /* 385 */
|
|
|
d5c145 |
+ "386", /* 386 */
|
|
|
d5c145 |
+ "387", /* 387 */
|
|
|
d5c145 |
+ "388", /* 388 */
|
|
|
d5c145 |
+ "389", /* 389 */
|
|
|
d5c145 |
+ "390", /* 390 */
|
|
|
d5c145 |
+ "391", /* 391 */
|
|
|
d5c145 |
+ "392", /* 392 */
|
|
|
d5c145 |
+ "393", /* 393 */
|
|
|
d5c145 |
+ "394", /* 394 */
|
|
|
d5c145 |
+ "395", /* 395 */
|
|
|
d5c145 |
+ "396", /* 396 */
|
|
|
d5c145 |
+ "397", /* 397 */
|
|
|
d5c145 |
+ "398", /* 398 */
|
|
|
d5c145 |
+ "399", /* 399 */
|
|
|
d5c145 |
+ "400", /* 400 */
|
|
|
d5c145 |
+ "401", /* 401 */
|
|
|
d5c145 |
+ "402", /* 402 */
|
|
|
d5c145 |
+ "403", /* 403 */
|
|
|
d5c145 |
+ "404", /* 404 */
|
|
|
d5c145 |
+ "405", /* 405 */
|
|
|
d5c145 |
+ "406", /* 406 */
|
|
|
d5c145 |
+ "407", /* 407 */
|
|
|
d5c145 |
+ "408", /* 408 */
|
|
|
d5c145 |
+ "409", /* 409 */
|
|
|
d5c145 |
+ "410", /* 410 */
|
|
|
d5c145 |
+ "411", /* 411 */
|
|
|
d5c145 |
+ "412", /* 412 */
|
|
|
d5c145 |
+ "413", /* 413 */
|
|
|
d5c145 |
+ "414", /* 414 */
|
|
|
d5c145 |
+ "415", /* 415 */
|
|
|
d5c145 |
+ "416", /* 416 */
|
|
|
d5c145 |
+ "417", /* 417 */
|
|
|
d5c145 |
+ "418", /* 418 */
|
|
|
d5c145 |
+ "419", /* 419 */
|
|
|
d5c145 |
+ "420", /* 420 */
|
|
|
d5c145 |
+ "421", /* 421 */
|
|
|
d5c145 |
+ "422", /* 422 */
|
|
|
d5c145 |
+ "423", /* 423 */
|
|
|
d5c145 |
+ "424", /* 424 */
|
|
|
d5c145 |
+ "425", /* 425 */
|
|
|
d5c145 |
+ "426", /* 426 */
|
|
|
d5c145 |
+ "427", /* 427 */
|
|
|
d5c145 |
+ "428", /* 428 */
|
|
|
d5c145 |
+ "429", /* 429 */
|
|
|
d5c145 |
+ "430", /* 430 */
|
|
|
d5c145 |
+ "431", /* 431 */
|
|
|
d5c145 |
+ "432", /* 432 */
|
|
|
d5c145 |
+ "433", /* 433 */
|
|
|
d5c145 |
+ "434", /* 434 */
|
|
|
d5c145 |
+ "435", /* 435 */
|
|
|
d5c145 |
+ "436", /* 436 */
|
|
|
d5c145 |
+ "437", /* 437 */
|
|
|
d5c145 |
+ "438", /* 438 */
|
|
|
d5c145 |
+ "439", /* 439 */
|
|
|
d5c145 |
+ "440", /* 440 */
|
|
|
d5c145 |
+ "441", /* 441 */
|
|
|
d5c145 |
+ "442", /* 442 */
|
|
|
d5c145 |
+ "443", /* 443 */
|
|
|
d5c145 |
+ "444", /* 444 */
|
|
|
d5c145 |
+ "445", /* 445 */
|
|
|
d5c145 |
+ "446", /* 446 */
|
|
|
d5c145 |
+ "447", /* 447 */
|
|
|
d5c145 |
+ "448", /* 448 */
|
|
|
d5c145 |
+ "449", /* 449 */
|
|
|
d5c145 |
+ "450", /* 450 */
|
|
|
d5c145 |
+ "451", /* 451 */
|
|
|
d5c145 |
+ "452", /* 452 */
|
|
|
d5c145 |
+ "453", /* 453 */
|
|
|
d5c145 |
+ "454", /* 454 */
|
|
|
d5c145 |
+ "455", /* 455 */
|
|
|
d5c145 |
+ "456", /* 456 */
|
|
|
d5c145 |
+ "457", /* 457 */
|
|
|
d5c145 |
+ "458", /* 458 */
|
|
|
d5c145 |
+ "459", /* 459 */
|
|
|
d5c145 |
+ "460", /* 460 */
|
|
|
d5c145 |
+ "461", /* 461 */
|
|
|
d5c145 |
+ "462", /* 462 */
|
|
|
d5c145 |
+ "463", /* 463 */
|
|
|
d5c145 |
+ "464", /* 464 */
|
|
|
d5c145 |
+ "465", /* 465 */
|
|
|
d5c145 |
+ "466", /* 466 */
|
|
|
d5c145 |
+ "467", /* 467 */
|
|
|
d5c145 |
+ "468", /* 468 */
|
|
|
d5c145 |
+ "469", /* 469 */
|
|
|
d5c145 |
+ "470", /* 470 */
|
|
|
d5c145 |
+ "471", /* 471 */
|
|
|
d5c145 |
+ "472", /* 472 */
|
|
|
d5c145 |
+ "473", /* 473 */
|
|
|
d5c145 |
+ "474", /* 474 */
|
|
|
d5c145 |
+ "475", /* 475 */
|
|
|
d5c145 |
+ "476", /* 476 */
|
|
|
d5c145 |
+ "477", /* 477 */
|
|
|
d5c145 |
+ "478", /* 478 */
|
|
|
d5c145 |
+ "479", /* 479 */
|
|
|
d5c145 |
+ "480", /* 480 */
|
|
|
d5c145 |
+ "481", /* 481 */
|
|
|
d5c145 |
+ "482", /* 482 */
|
|
|
d5c145 |
+ "483", /* 483 */
|
|
|
d5c145 |
+ "484", /* 484 */
|
|
|
d5c145 |
+ "485", /* 485 */
|
|
|
d5c145 |
+ "486", /* 486 */
|
|
|
d5c145 |
+ "487", /* 487 */
|
|
|
d5c145 |
+ "488", /* 488 */
|
|
|
d5c145 |
+ "489", /* 489 */
|
|
|
d5c145 |
+ "490", /* 490 */
|
|
|
d5c145 |
+ "491", /* 491 */
|
|
|
d5c145 |
+ "492", /* 492 */
|
|
|
d5c145 |
+ "493", /* 493 */
|
|
|
d5c145 |
+ "494", /* 494 */
|
|
|
d5c145 |
+ "495", /* 495 */
|
|
|
d5c145 |
+ "496", /* 496 */
|
|
|
d5c145 |
+ "497", /* 497 */
|
|
|
d5c145 |
+ "498", /* 498 */
|
|
|
d5c145 |
+ "499", /* 499 */
|
|
|
d5c145 |
+ "500", /* 500 */
|
|
|
d5c145 |
+ "501", /* 501 */
|
|
|
d5c145 |
+ "502", /* 502 */
|
|
|
d5c145 |
+ "503", /* 503 */
|
|
|
d5c145 |
+ "504", /* 504 */
|
|
|
d5c145 |
+ "505", /* 505 */
|
|
|
d5c145 |
+ "506", /* 506 */
|
|
|
d5c145 |
+ "507", /* 507 */
|
|
|
d5c145 |
+ "508", /* 508 */
|
|
|
d5c145 |
+ "509", /* 509 */
|
|
|
d5c145 |
+ "510", /* 510 */
|
|
|
d5c145 |
+ "511", /* 511 */
|
|
|
d5c145 |
+ "512", /* 512 */
|
|
|
d5c145 |
+ "513", /* 513 */
|
|
|
d5c145 |
+ "514", /* 514 */
|
|
|
d5c145 |
+ "515", /* 515 */
|
|
|
d5c145 |
+ "516", /* 516 */
|
|
|
d5c145 |
+ "517", /* 517 */
|
|
|
d5c145 |
+ "518", /* 518 */
|
|
|
d5c145 |
+ "519", /* 519 */
|
|
|
d5c145 |
+ "520", /* 520 */
|
|
|
d5c145 |
+ "521", /* 521 */
|
|
|
d5c145 |
+ "522", /* 522 */
|
|
|
d5c145 |
+ "523", /* 523 */
|
|
|
d5c145 |
+ "524", /* 524 */
|
|
|
d5c145 |
+ "525", /* 525 */
|
|
|
d5c145 |
+ "526", /* 526 */
|
|
|
d5c145 |
+ "527", /* 527 */
|
|
|
d5c145 |
+ "528", /* 528 */
|
|
|
d5c145 |
+ "529", /* 529 */
|
|
|
d5c145 |
+ "530", /* 530 */
|
|
|
d5c145 |
+ "531", /* 531 */
|
|
|
d5c145 |
+ "532", /* 532 */
|
|
|
d5c145 |
+ "533", /* 533 */
|
|
|
d5c145 |
+ "534", /* 534 */
|
|
|
d5c145 |
+ "535", /* 535 */
|
|
|
d5c145 |
+ "536", /* 536 */
|
|
|
d5c145 |
+ "537", /* 537 */
|
|
|
d5c145 |
+ "538", /* 538 */
|
|
|
d5c145 |
+ "539", /* 539 */
|
|
|
d5c145 |
+ "540", /* 540 */
|
|
|
d5c145 |
+ "541", /* 541 */
|
|
|
d5c145 |
+ "542", /* 542 */
|
|
|
d5c145 |
+ "543", /* 543 */
|
|
|
d5c145 |
+ "544", /* 544 */
|
|
|
d5c145 |
+ "545", /* 545 */
|
|
|
d5c145 |
+ "546", /* 546 */
|
|
|
d5c145 |
+ "547", /* 547 */
|
|
|
d5c145 |
+ "548", /* 548 */
|
|
|
d5c145 |
+ "549", /* 549 */
|
|
|
d5c145 |
+ "550", /* 550 */
|
|
|
d5c145 |
+ "551", /* 551 */
|
|
|
d5c145 |
+ "552", /* 552 */
|
|
|
d5c145 |
+ "553", /* 553 */
|
|
|
d5c145 |
+ "554", /* 554 */
|
|
|
d5c145 |
+ "555", /* 555 */
|
|
|
d5c145 |
+ "556", /* 556 */
|
|
|
d5c145 |
+ "557", /* 557 */
|
|
|
d5c145 |
+ "558", /* 558 */
|
|
|
d5c145 |
+ "559", /* 559 */
|
|
|
d5c145 |
+ "560", /* 560 */
|
|
|
d5c145 |
+ "561", /* 561 */
|
|
|
d5c145 |
+ "562", /* 562 */
|
|
|
d5c145 |
+ "563", /* 563 */
|
|
|
d5c145 |
+ "564", /* 564 */
|
|
|
d5c145 |
+ "565", /* 565 */
|
|
|
d5c145 |
+ "566", /* 566 */
|
|
|
d5c145 |
+ "567", /* 567 */
|
|
|
d5c145 |
+ "568", /* 568 */
|
|
|
d5c145 |
+ "569", /* 569 */
|
|
|
d5c145 |
+ "570", /* 570 */
|
|
|
d5c145 |
+ "571", /* 571 */
|
|
|
d5c145 |
+ "572", /* 572 */
|
|
|
d5c145 |
+ "573", /* 573 */
|
|
|
d5c145 |
+ "574", /* 574 */
|
|
|
d5c145 |
+ "575", /* 575 */
|
|
|
d5c145 |
+ "576", /* 576 */
|
|
|
d5c145 |
+ "577", /* 577 */
|
|
|
d5c145 |
+ "578", /* 578 */
|
|
|
d5c145 |
+ "579", /* 579 */
|
|
|
d5c145 |
+ "580", /* 580 */
|
|
|
d5c145 |
+ "581", /* 581 */
|
|
|
d5c145 |
+ "582", /* 582 */
|
|
|
d5c145 |
+ "583", /* 583 */
|
|
|
d5c145 |
+ "584", /* 584 */
|
|
|
d5c145 |
+ "585", /* 585 */
|
|
|
d5c145 |
+ "586", /* 586 */
|
|
|
d5c145 |
+ "587", /* 587 */
|
|
|
d5c145 |
+ "588", /* 588 */
|
|
|
d5c145 |
+ "589", /* 589 */
|
|
|
d5c145 |
+ "590", /* 590 */
|
|
|
d5c145 |
+ "591", /* 591 */
|
|
|
d5c145 |
+ "592", /* 592 */
|
|
|
d5c145 |
+ "593", /* 593 */
|
|
|
d5c145 |
+ "594", /* 594 */
|
|
|
d5c145 |
+ "595", /* 595 */
|
|
|
d5c145 |
+ "596", /* 596 */
|
|
|
d5c145 |
+ "597", /* 597 */
|
|
|
d5c145 |
+ "598", /* 598 */
|
|
|
d5c145 |
+ "599", /* 599 */
|
|
|
d5c145 |
+ "600", /* 600 */
|
|
|
d5c145 |
+ "601", /* 601 */
|
|
|
d5c145 |
+ "602", /* 602 */
|
|
|
d5c145 |
+ "603", /* 603 */
|
|
|
d5c145 |
+ "604", /* 604 */
|
|
|
d5c145 |
+ "605", /* 605 */
|
|
|
d5c145 |
+ "606", /* 606 */
|
|
|
d5c145 |
+ "607", /* 607 */
|
|
|
d5c145 |
+ "608", /* 608 */
|
|
|
d5c145 |
+ "609", /* 609 */
|
|
|
d5c145 |
+ "610", /* 610 */
|
|
|
d5c145 |
+ "611", /* 611 */
|
|
|
d5c145 |
+ "612", /* 612 */
|
|
|
d5c145 |
+ "613", /* 613 */
|
|
|
d5c145 |
+ "614", /* 614 */
|
|
|
d5c145 |
+ "615", /* 615 */
|
|
|
d5c145 |
+ "616", /* 616 */
|
|
|
d5c145 |
+ "617", /* 617 */
|
|
|
d5c145 |
+ "618", /* 618 */
|
|
|
d5c145 |
+ "619", /* 619 */
|
|
|
d5c145 |
+ "620", /* 620 */
|
|
|
d5c145 |
+ "621", /* 621 */
|
|
|
d5c145 |
+ "622", /* 622 */
|
|
|
d5c145 |
+ "623", /* 623 */
|
|
|
d5c145 |
+ "624", /* 624 */
|
|
|
d5c145 |
+ "625", /* 625 */
|
|
|
d5c145 |
+ "626", /* 626 */
|
|
|
d5c145 |
+ "627", /* 627 */
|
|
|
d5c145 |
+ "628", /* 628 */
|
|
|
d5c145 |
+ "629", /* 629 */
|
|
|
d5c145 |
+ "630", /* 630 */
|
|
|
d5c145 |
+ "631", /* 631 */
|
|
|
d5c145 |
+ "632", /* 632 */
|
|
|
d5c145 |
+ "633", /* 633 */
|
|
|
d5c145 |
+ "634", /* 634 */
|
|
|
d5c145 |
+ "635", /* 635 */
|
|
|
d5c145 |
+ "636", /* 636 */
|
|
|
d5c145 |
+ "637", /* 637 */
|
|
|
d5c145 |
+ "638", /* 638 */
|
|
|
d5c145 |
+ "639", /* 639 */
|
|
|
d5c145 |
+ "640", /* 640 */
|
|
|
d5c145 |
+ "641", /* 641 */
|
|
|
d5c145 |
+ "642", /* 642 */
|
|
|
d5c145 |
+ "643", /* 643 */
|
|
|
d5c145 |
+ "644", /* 644 */
|
|
|
d5c145 |
+ "645", /* 645 */
|
|
|
d5c145 |
+ "646", /* 646 */
|
|
|
d5c145 |
+ "647", /* 647 */
|
|
|
d5c145 |
+ "648", /* 648 */
|
|
|
d5c145 |
+ "649", /* 649 */
|
|
|
d5c145 |
+ "650", /* 650 */
|
|
|
d5c145 |
+ "651", /* 651 */
|
|
|
d5c145 |
+ "652", /* 652 */
|
|
|
d5c145 |
+ "653", /* 653 */
|
|
|
d5c145 |
+ "654", /* 654 */
|
|
|
d5c145 |
+ "655", /* 655 */
|
|
|
d5c145 |
+ "656", /* 656 */
|
|
|
d5c145 |
+ "657", /* 657 */
|
|
|
d5c145 |
+ "658", /* 658 */
|
|
|
d5c145 |
+ "659", /* 659 */
|
|
|
d5c145 |
+ "660", /* 660 */
|
|
|
d5c145 |
+ "661", /* 661 */
|
|
|
d5c145 |
+ "662", /* 662 */
|
|
|
d5c145 |
+ "663", /* 663 */
|
|
|
d5c145 |
+ "664", /* 664 */
|
|
|
d5c145 |
+ "665", /* 665 */
|
|
|
d5c145 |
+ "666", /* 666 */
|
|
|
d5c145 |
+ "667", /* 667 */
|
|
|
d5c145 |
+ "668", /* 668 */
|
|
|
d5c145 |
+ "669", /* 669 */
|
|
|
d5c145 |
+ "670", /* 670 */
|
|
|
d5c145 |
+ "671", /* 671 */
|
|
|
d5c145 |
+ "672", /* 672 */
|
|
|
d5c145 |
+ "673", /* 673 */
|
|
|
d5c145 |
+ "674", /* 674 */
|
|
|
d5c145 |
+ "675", /* 675 */
|
|
|
d5c145 |
+ "676", /* 676 */
|
|
|
d5c145 |
+ "677", /* 677 */
|
|
|
d5c145 |
+ "678", /* 678 */
|
|
|
d5c145 |
+ "679", /* 679 */
|
|
|
d5c145 |
+ "680", /* 680 */
|
|
|
d5c145 |
+ "681", /* 681 */
|
|
|
d5c145 |
+ "682", /* 682 */
|
|
|
d5c145 |
+ "683", /* 683 */
|
|
|
d5c145 |
+ "684", /* 684 */
|
|
|
d5c145 |
+ "685", /* 685 */
|
|
|
d5c145 |
+ "686", /* 686 */
|
|
|
d5c145 |
+ "687", /* 687 */
|
|
|
d5c145 |
+ "688", /* 688 */
|
|
|
d5c145 |
+ "689", /* 689 */
|
|
|
d5c145 |
+ "690", /* 690 */
|
|
|
d5c145 |
+ "691", /* 691 */
|
|
|
d5c145 |
+ "692", /* 692 */
|
|
|
d5c145 |
+ "693", /* 693 */
|
|
|
d5c145 |
+ "694", /* 694 */
|
|
|
d5c145 |
+ "695", /* 695 */
|
|
|
d5c145 |
+ "696", /* 696 */
|
|
|
d5c145 |
+ "697", /* 697 */
|
|
|
d5c145 |
+ "698", /* 698 */
|
|
|
d5c145 |
+ "699", /* 699 */
|
|
|
d5c145 |
+ "700", /* 700 */
|
|
|
d5c145 |
+ "701", /* 701 */
|
|
|
d5c145 |
+ "702", /* 702 */
|
|
|
d5c145 |
+ "703", /* 703 */
|
|
|
d5c145 |
+ "704", /* 704 */
|
|
|
d5c145 |
+ "705", /* 705 */
|
|
|
d5c145 |
+ "706", /* 706 */
|
|
|
d5c145 |
+ "707", /* 707 */
|
|
|
d5c145 |
+ "708", /* 708 */
|
|
|
d5c145 |
+ "709", /* 709 */
|
|
|
d5c145 |
+ "710", /* 710 */
|
|
|
d5c145 |
+ "711", /* 711 */
|
|
|
d5c145 |
+ "712", /* 712 */
|
|
|
d5c145 |
+ "713", /* 713 */
|
|
|
d5c145 |
+ "714", /* 714 */
|
|
|
d5c145 |
+ "715", /* 715 */
|
|
|
d5c145 |
+ "716", /* 716 */
|
|
|
d5c145 |
+ "717", /* 717 */
|
|
|
d5c145 |
+ "718", /* 718 */
|
|
|
d5c145 |
+ "719", /* 719 */
|
|
|
d5c145 |
+ "720", /* 720 */
|
|
|
d5c145 |
+ "721", /* 721 */
|
|
|
d5c145 |
+ "722", /* 722 */
|
|
|
d5c145 |
+ "723", /* 723 */
|
|
|
d5c145 |
+ "724", /* 724 */
|
|
|
d5c145 |
+ "725", /* 725 */
|
|
|
d5c145 |
+ "726", /* 726 */
|
|
|
d5c145 |
+ "727", /* 727 */
|
|
|
d5c145 |
+ "728", /* 728 */
|
|
|
d5c145 |
+ "729", /* 729 */
|
|
|
d5c145 |
+ "730", /* 730 */
|
|
|
d5c145 |
+ "731", /* 731 */
|
|
|
d5c145 |
+ "732", /* 732 */
|
|
|
d5c145 |
+ "733", /* 733 */
|
|
|
d5c145 |
+ "734", /* 734 */
|
|
|
d5c145 |
+ "735", /* 735 */
|
|
|
d5c145 |
+ "736", /* 736 */
|
|
|
d5c145 |
+ "737", /* 737 */
|
|
|
d5c145 |
+ "738", /* 738 */
|
|
|
d5c145 |
+ "739", /* 739 */
|
|
|
d5c145 |
+ "740", /* 740 */
|
|
|
d5c145 |
+ "741", /* 741 */
|
|
|
d5c145 |
+ "742", /* 742 */
|
|
|
d5c145 |
+ "743", /* 743 */
|
|
|
d5c145 |
+ "744", /* 744 */
|
|
|
d5c145 |
+ "745", /* 745 */
|
|
|
d5c145 |
+ "746", /* 746 */
|
|
|
d5c145 |
+ "747", /* 747 */
|
|
|
d5c145 |
+ "748", /* 748 */
|
|
|
d5c145 |
+ "749", /* 749 */
|
|
|
d5c145 |
+ "750", /* 750 */
|
|
|
d5c145 |
+ "751", /* 751 */
|
|
|
d5c145 |
+ "752", /* 752 */
|
|
|
d5c145 |
+ "753", /* 753 */
|
|
|
d5c145 |
+ "754", /* 754 */
|
|
|
d5c145 |
+ "755", /* 755 */
|
|
|
d5c145 |
+ "756", /* 756 */
|
|
|
d5c145 |
+ "757", /* 757 */
|
|
|
d5c145 |
+ "758", /* 758 */
|
|
|
d5c145 |
+ "759", /* 759 */
|
|
|
d5c145 |
+ "760", /* 760 */
|
|
|
d5c145 |
+ "761", /* 761 */
|
|
|
d5c145 |
+ "762", /* 762 */
|
|
|
d5c145 |
+ "763", /* 763 */
|
|
|
d5c145 |
+ "764", /* 764 */
|
|
|
d5c145 |
+ "765", /* 765 */
|
|
|
d5c145 |
+ "766", /* 766 */
|
|
|
d5c145 |
+ "767", /* 767 */
|
|
|
d5c145 |
+ "768", /* 768 */
|
|
|
d5c145 |
+ "769", /* 769 */
|
|
|
d5c145 |
+ "770", /* 770 */
|
|
|
d5c145 |
+ "771", /* 771 */
|
|
|
d5c145 |
+ "772", /* 772 */
|
|
|
d5c145 |
+ "773", /* 773 */
|
|
|
d5c145 |
+ "774", /* 774 */
|
|
|
d5c145 |
+ "775", /* 775 */
|
|
|
d5c145 |
+ "776", /* 776 */
|
|
|
d5c145 |
+ "777", /* 777 */
|
|
|
d5c145 |
+ "778", /* 778 */
|
|
|
d5c145 |
+ "779", /* 779 */
|
|
|
d5c145 |
+ "780", /* 780 */
|
|
|
d5c145 |
+ "781", /* 781 */
|
|
|
d5c145 |
+ "782", /* 782 */
|
|
|
d5c145 |
+ "783", /* 783 */
|
|
|
d5c145 |
+ "784", /* 784 */
|
|
|
d5c145 |
+ "785", /* 785 */
|
|
|
d5c145 |
+ "786", /* 786 */
|
|
|
d5c145 |
+ "787", /* 787 */
|
|
|
d5c145 |
+ "788", /* 788 */
|
|
|
d5c145 |
+ "789", /* 789 */
|
|
|
d5c145 |
+ "790", /* 790 */
|
|
|
d5c145 |
+ "791", /* 791 */
|
|
|
d5c145 |
+ "792", /* 792 */
|
|
|
d5c145 |
+ "793", /* 793 */
|
|
|
d5c145 |
+ "794", /* 794 */
|
|
|
d5c145 |
+ "795", /* 795 */
|
|
|
d5c145 |
+ "796", /* 796 */
|
|
|
d5c145 |
+ "797", /* 797 */
|
|
|
d5c145 |
+ "798", /* 798 */
|
|
|
d5c145 |
+ "799", /* 799 */
|
|
|
d5c145 |
+ "800", /* 800 */
|
|
|
d5c145 |
+ "801", /* 801 */
|
|
|
d5c145 |
+ "802", /* 802 */
|
|
|
d5c145 |
+ "803", /* 803 */
|
|
|
d5c145 |
+ "804", /* 804 */
|
|
|
d5c145 |
+ "805", /* 805 */
|
|
|
d5c145 |
+ "806", /* 806 */
|
|
|
d5c145 |
+ "807", /* 807 */
|
|
|
d5c145 |
+ "808", /* 808 */
|
|
|
d5c145 |
+ "809", /* 809 */
|
|
|
d5c145 |
+ "810", /* 810 */
|
|
|
d5c145 |
+ "811", /* 811 */
|
|
|
d5c145 |
+ "812", /* 812 */
|
|
|
d5c145 |
+ "813", /* 813 */
|
|
|
d5c145 |
+ "814", /* 814 */
|
|
|
d5c145 |
+ "815", /* 815 */
|
|
|
d5c145 |
+ "816", /* 816 */
|
|
|
d5c145 |
+ "817", /* 817 */
|
|
|
d5c145 |
+ "818", /* 818 */
|
|
|
d5c145 |
+ "819", /* 819 */
|
|
|
d5c145 |
+ "820", /* 820 */
|
|
|
d5c145 |
+ "821", /* 821 */
|
|
|
d5c145 |
+ "822", /* 822 */
|
|
|
d5c145 |
+ "823", /* 823 */
|
|
|
d5c145 |
+ "824", /* 824 */
|
|
|
d5c145 |
+ "825", /* 825 */
|
|
|
d5c145 |
+ "826", /* 826 */
|
|
|
d5c145 |
+ "827", /* 827 */
|
|
|
d5c145 |
+ "828", /* 828 */
|
|
|
d5c145 |
+ "829", /* 829 */
|
|
|
d5c145 |
+ "830", /* 830 */
|
|
|
d5c145 |
+ "831", /* 831 */
|
|
|
d5c145 |
+ "832", /* 832 */
|
|
|
d5c145 |
+ "833", /* 833 */
|
|
|
d5c145 |
+ "834", /* 834 */
|
|
|
d5c145 |
+ "835", /* 835 */
|
|
|
d5c145 |
+ "836", /* 836 */
|
|
|
d5c145 |
+ "837", /* 837 */
|
|
|
d5c145 |
+ "838", /* 838 */
|
|
|
d5c145 |
+ "839", /* 839 */
|
|
|
d5c145 |
+ "840", /* 840 */
|
|
|
d5c145 |
+ "841", /* 841 */
|
|
|
d5c145 |
+ "842", /* 842 */
|
|
|
d5c145 |
+ "843", /* 843 */
|
|
|
d5c145 |
+ "844", /* 844 */
|
|
|
d5c145 |
+ "845", /* 845 */
|
|
|
d5c145 |
+ "846", /* 846 */
|
|
|
d5c145 |
+ "847", /* 847 */
|
|
|
d5c145 |
+ "848", /* 848 */
|
|
|
d5c145 |
+ "849", /* 849 */
|
|
|
d5c145 |
+ "850", /* 850 */
|
|
|
d5c145 |
+ "851", /* 851 */
|
|
|
d5c145 |
+ "852", /* 852 */
|
|
|
d5c145 |
+ "853", /* 853 */
|
|
|
d5c145 |
+ "854", /* 854 */
|
|
|
d5c145 |
+ "855", /* 855 */
|
|
|
d5c145 |
+ "856", /* 856 */
|
|
|
d5c145 |
+ "857", /* 857 */
|
|
|
d5c145 |
+ "858", /* 858 */
|
|
|
d5c145 |
+ "859", /* 859 */
|
|
|
d5c145 |
+ "860", /* 860 */
|
|
|
d5c145 |
+ "861", /* 861 */
|
|
|
d5c145 |
+ "862", /* 862 */
|
|
|
d5c145 |
+ "863", /* 863 */
|
|
|
d5c145 |
+ "864", /* 864 */
|
|
|
d5c145 |
+ "865", /* 865 */
|
|
|
d5c145 |
+ "866", /* 866 */
|
|
|
d5c145 |
+ "867", /* 867 */
|
|
|
d5c145 |
+ "868", /* 868 */
|
|
|
d5c145 |
+ "869", /* 869 */
|
|
|
d5c145 |
+ "870", /* 870 */
|
|
|
d5c145 |
+ "871", /* 871 */
|
|
|
d5c145 |
+ "872", /* 872 */
|
|
|
d5c145 |
+ "873", /* 873 */
|
|
|
d5c145 |
+ "874", /* 874 */
|
|
|
d5c145 |
+ "875", /* 875 */
|
|
|
d5c145 |
+ "876", /* 876 */
|
|
|
d5c145 |
+ "877", /* 877 */
|
|
|
d5c145 |
+ "878", /* 878 */
|
|
|
d5c145 |
+ "879", /* 879 */
|
|
|
d5c145 |
+ "880", /* 880 */
|
|
|
d5c145 |
+ "881", /* 881 */
|
|
|
d5c145 |
+ "882", /* 882 */
|
|
|
d5c145 |
+ "883", /* 883 */
|
|
|
d5c145 |
+ "884", /* 884 */
|
|
|
d5c145 |
+ "885", /* 885 */
|
|
|
d5c145 |
+ "886", /* 886 */
|
|
|
d5c145 |
+ "887", /* 887 */
|
|
|
d5c145 |
+ "888", /* 888 */
|
|
|
d5c145 |
+ "889", /* 889 */
|
|
|
d5c145 |
+ "890", /* 890 */
|
|
|
d5c145 |
+ "891", /* 891 */
|
|
|
d5c145 |
+ "892", /* 892 */
|
|
|
d5c145 |
+ "893", /* 893 */
|
|
|
d5c145 |
+ "894", /* 894 */
|
|
|
d5c145 |
+ "895", /* 895 */
|
|
|
d5c145 |
+ "896", /* 896 */
|
|
|
d5c145 |
+ "897", /* 897 */
|
|
|
d5c145 |
+ "898", /* 898 */
|
|
|
d5c145 |
+ "899", /* 899 */
|
|
|
d5c145 |
+ "900", /* 900 */
|
|
|
d5c145 |
+ "901", /* 901 */
|
|
|
d5c145 |
+ "902", /* 902 */
|
|
|
d5c145 |
+ "903", /* 903 */
|
|
|
d5c145 |
+ "904", /* 904 */
|
|
|
d5c145 |
+ "905", /* 905 */
|
|
|
d5c145 |
+ "906", /* 906 */
|
|
|
d5c145 |
+ "907", /* 907 */
|
|
|
d5c145 |
+ "908", /* 908 */
|
|
|
d5c145 |
+ "909", /* 909 */
|
|
|
d5c145 |
+ "910", /* 910 */
|
|
|
d5c145 |
+ "911", /* 911 */
|
|
|
d5c145 |
+ "912", /* 912 */
|
|
|
d5c145 |
+ "913", /* 913 */
|
|
|
d5c145 |
+ "914", /* 914 */
|
|
|
d5c145 |
+ "915", /* 915 */
|
|
|
d5c145 |
+ "916", /* 916 */
|
|
|
d5c145 |
+ "917", /* 917 */
|
|
|
d5c145 |
+ "918", /* 918 */
|
|
|
d5c145 |
+ "919", /* 919 */
|
|
|
d5c145 |
+ "920", /* 920 */
|
|
|
d5c145 |
+ "921", /* 921 */
|
|
|
d5c145 |
+ "922", /* 922 */
|
|
|
d5c145 |
+ "923", /* 923 */
|
|
|
d5c145 |
+ "924", /* 924 */
|
|
|
d5c145 |
+ "925", /* 925 */
|
|
|
d5c145 |
+ "926", /* 926 */
|
|
|
d5c145 |
+ "927", /* 927 */
|
|
|
d5c145 |
+ "928", /* 928 */
|
|
|
d5c145 |
+ "929", /* 929 */
|
|
|
d5c145 |
+ "930", /* 930 */
|
|
|
d5c145 |
+ "931", /* 931 */
|
|
|
d5c145 |
+ "932", /* 932 */
|
|
|
d5c145 |
+ "933", /* 933 */
|
|
|
d5c145 |
+ "934", /* 934 */
|
|
|
d5c145 |
+ "935", /* 935 */
|
|
|
d5c145 |
+ "936", /* 936 */
|
|
|
d5c145 |
+ "937", /* 937 */
|
|
|
d5c145 |
+ "938", /* 938 */
|
|
|
d5c145 |
+ "939", /* 939 */
|
|
|
d5c145 |
+ "940", /* 940 */
|
|
|
d5c145 |
+ "941", /* 941 */
|
|
|
d5c145 |
+ "942", /* 942 */
|
|
|
d5c145 |
+ "943", /* 943 */
|
|
|
d5c145 |
+ "944", /* 944 */
|
|
|
d5c145 |
+ "945", /* 945 */
|
|
|
d5c145 |
+ "946", /* 946 */
|
|
|
d5c145 |
+ "947", /* 947 */
|
|
|
d5c145 |
+ "948", /* 948 */
|
|
|
d5c145 |
+ "949", /* 949 */
|
|
|
d5c145 |
+ "950", /* 950 */
|
|
|
d5c145 |
+ "951", /* 951 */
|
|
|
d5c145 |
+ "952", /* 952 */
|
|
|
d5c145 |
+ "953", /* 953 */
|
|
|
d5c145 |
+ "954", /* 954 */
|
|
|
d5c145 |
+ "955", /* 955 */
|
|
|
d5c145 |
+ "956", /* 956 */
|
|
|
d5c145 |
+ "957", /* 957 */
|
|
|
d5c145 |
+ "958", /* 958 */
|
|
|
d5c145 |
+ "959", /* 959 */
|
|
|
d5c145 |
+ "960", /* 960 */
|
|
|
d5c145 |
+ "961", /* 961 */
|
|
|
d5c145 |
+ "962", /* 962 */
|
|
|
d5c145 |
+ "963", /* 963 */
|
|
|
d5c145 |
+ "964", /* 964 */
|
|
|
d5c145 |
+ "965", /* 965 */
|
|
|
d5c145 |
+ "966", /* 966 */
|
|
|
d5c145 |
+ "967", /* 967 */
|
|
|
d5c145 |
+ "968", /* 968 */
|
|
|
d5c145 |
+ "969", /* 969 */
|
|
|
d5c145 |
+ "970", /* 970 */
|
|
|
d5c145 |
+ "971", /* 971 */
|
|
|
d5c145 |
+ "972", /* 972 */
|
|
|
d5c145 |
+ "973", /* 973 */
|
|
|
d5c145 |
+ "974", /* 974 */
|
|
|
d5c145 |
+ "975", /* 975 */
|
|
|
d5c145 |
+ "976", /* 976 */
|
|
|
d5c145 |
+ "977", /* 977 */
|
|
|
d5c145 |
+ "978", /* 978 */
|
|
|
d5c145 |
+ "979", /* 979 */
|
|
|
d5c145 |
+ "980", /* 980 */
|
|
|
d5c145 |
+ "981", /* 981 */
|
|
|
d5c145 |
+ "982", /* 982 */
|
|
|
d5c145 |
+ "983", /* 983 */
|
|
|
d5c145 |
+ "984", /* 984 */
|
|
|
d5c145 |
+ "985", /* 985 */
|
|
|
d5c145 |
+ "986", /* 986 */
|
|
|
d5c145 |
+ "987", /* 987 */
|
|
|
d5c145 |
+ "988", /* 988 */
|
|
|
d5c145 |
+ "989", /* 989 */
|
|
|
d5c145 |
+ "990", /* 990 */
|
|
|
d5c145 |
+ "991", /* 991 */
|
|
|
d5c145 |
+ "992", /* 992 */
|
|
|
d5c145 |
+ "993", /* 993 */
|
|
|
d5c145 |
+ "994", /* 994 */
|
|
|
d5c145 |
+ "995", /* 995 */
|
|
|
d5c145 |
+ "996", /* 996 */
|
|
|
d5c145 |
+ "997", /* 997 */
|
|
|
d5c145 |
+ "998", /* 998 */
|
|
|
d5c145 |
+ "999", /* 999 */
|
|
|
d5c145 |
+ "1000", /* 1000 */
|
|
|
d5c145 |
+ "1001", /* 1001 */
|
|
|
d5c145 |
+ "1002", /* 1002 */
|
|
|
d5c145 |
+ "1003", /* 1003 */
|
|
|
d5c145 |
+ "1004", /* 1004 */
|
|
|
d5c145 |
+ "1005", /* 1005 */
|
|
|
d5c145 |
+ "1006", /* 1006 */
|
|
|
d5c145 |
+ "1007", /* 1007 */
|
|
|
d5c145 |
+ "1008", /* 1008 */
|
|
|
d5c145 |
+ "1009", /* 1009 */
|
|
|
d5c145 |
+ "1010", /* 1010 */
|
|
|
d5c145 |
+ "1011", /* 1011 */
|
|
|
d5c145 |
+ "1012", /* 1012 */
|
|
|
d5c145 |
+ "1013", /* 1013 */
|
|
|
d5c145 |
+ "1014", /* 1014 */
|
|
|
d5c145 |
+ "1015", /* 1015 */
|
|
|
d5c145 |
+ "1016", /* 1016 */
|
|
|
d5c145 |
+ "1017", /* 1017 */
|
|
|
d5c145 |
+ "1018", /* 1018 */
|
|
|
d5c145 |
+ "1019", /* 1019 */
|
|
|
d5c145 |
+ "1020", /* 1020 */
|
|
|
d5c145 |
+ "1021", /* 1021 */
|
|
|
d5c145 |
+ "1022", /* 1022 */
|
|
|
d5c145 |
+ "1023", /* 1023 */
|
|
|
d5c145 |
+ "open", /* 1024 */
|
|
|
d5c145 |
+ "link", /* 1025 */
|
|
|
d5c145 |
+ "unlink", /* 1026 */
|
|
|
d5c145 |
+ "mknod", /* 1027 */
|
|
|
d5c145 |
+ "chmod", /* 1028 */
|
|
|
d5c145 |
+ "chown", /* 1029 */
|
|
|
d5c145 |
+ "mkdir", /* 1030 */
|
|
|
d5c145 |
+ "rmdir", /* 1031 */
|
|
|
d5c145 |
+ "lchown", /* 1032 */
|
|
|
d5c145 |
+ "access", /* 1033 */
|
|
|
d5c145 |
+ "rename", /* 1034 */
|
|
|
d5c145 |
+ "readlink", /* 1035 */
|
|
|
d5c145 |
+ "symlink", /* 1036 */
|
|
|
d5c145 |
+ "utimes", /* 1037 */
|
|
|
d5c145 |
+ "stat", /* 1038 */
|
|
|
d5c145 |
+ "lstat", /* 1039 */
|
|
|
d5c145 |
+ "pipe", /* 1040 */
|
|
|
d5c145 |
+ "dup2", /* 1041 */
|
|
|
d5c145 |
+ "epoll_create", /* 1042 */
|
|
|
d5c145 |
+ "inotify_init", /* 1043 */
|
|
|
d5c145 |
+ "eventfd", /* 1044 */
|
|
|
d5c145 |
+ "signalfd", /* 1045 */
|
|
|
d5c145 |
+ "sendfile", /* 1046 */
|
|
|
d5c145 |
+ "ftruncate", /* 1047 */
|
|
|
d5c145 |
+ "truncate", /* 1048 */
|
|
|
d5c145 |
+ "stat", /* 1049 */
|
|
|
d5c145 |
+ "lstat", /* 1050 */
|
|
|
d5c145 |
+ "fstat", /* 1051 */
|
|
|
d5c145 |
+ "fcntl", /* 1052 */
|
|
|
d5c145 |
+ "fadvise64", /* 1053 */
|
|
|
d5c145 |
+ "newfstatat", /* 1054 */
|
|
|
d5c145 |
+ "fstatfs", /* 1055 */
|
|
|
d5c145 |
+ "statfs", /* 1056 */
|
|
|
d5c145 |
+ "lseek", /* 1057 */
|
|
|
d5c145 |
+ "mmap", /* 1058 */
|
|
|
d5c145 |
+ "alarm", /* 1059 */
|
|
|
d5c145 |
+ "getpgrp", /* 1060 */
|
|
|
d5c145 |
+ "pause", /* 1061 */
|
|
|
d5c145 |
+ "time", /* 1062 */
|
|
|
d5c145 |
+ "utime", /* 1063 */
|
|
|
d5c145 |
+ "creat", /* 1064 */
|
|
|
d5c145 |
+ "getdents", /* 1065 */
|
|
|
d5c145 |
+ "futimesat", /* 1066 */
|
|
|
d5c145 |
+ "select", /* 1067 */
|
|
|
d5c145 |
+ "poll", /* 1068 */
|
|
|
d5c145 |
+ "epoll_wait", /* 1069 */
|
|
|
d5c145 |
+ "ustat", /* 1070 */
|
|
|
d5c145 |
+ "vfork", /* 1071 */
|
|
|
d5c145 |
+ "oldwait4", /* 1072 */
|
|
|
d5c145 |
+ "recv", /* 1073 */
|
|
|
d5c145 |
+ "send", /* 1074 */
|
|
|
d5c145 |
+ "bdflush", /* 1075 */
|
|
|
d5c145 |
+ "umount", /* 1076 */
|
|
|
d5c145 |
+ "uselib", /* 1077 */
|
|
|
d5c145 |
+ "_sysctl", /* 1078 */
|
|
|
d5c145 |
+ "fork", /* 1079 */
|
|
|
d5c145 |
diff --git a/sysdeps/linux-gnu/aarch64/trace.c b/sysdeps/linux-gnu/aarch64/trace.c
|
|
|
d5c145 |
new file mode 100644
|
|
|
d5c145 |
index 0000000..5544b51
|
|
|
d5c145 |
--- /dev/null
|
|
|
d5c145 |
+++ b/sysdeps/linux-gnu/aarch64/trace.c
|
|
|
d5c145 |
@@ -0,0 +1,83 @@
|
|
|
d5c145 |
+/*
|
|
|
d5c145 |
+ * This file is part of ltrace.
|
|
|
d5c145 |
+ * Copyright (C) 2014 Petr Machata, Red Hat, Inc.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is free software; you can redistribute it and/or
|
|
|
d5c145 |
+ * modify it under the terms of the GNU General Public License as
|
|
|
d5c145 |
+ * published by the Free Software Foundation; either version 2 of the
|
|
|
d5c145 |
+ * License, or (at your option) any later version.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * This program is distributed in the hope that it will be useful, but
|
|
|
d5c145 |
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
d5c145 |
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
d5c145 |
+ * General Public License for more details.
|
|
|
d5c145 |
+ *
|
|
|
d5c145 |
+ * You should have received a copy of the GNU General Public License
|
|
|
d5c145 |
+ * along with this program; if not, write to the Free Software
|
|
|
d5c145 |
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
|
|
|
d5c145 |
+ * 02110-1301 USA
|
|
|
d5c145 |
+ */
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+#include <sys/ptrace.h>
|
|
|
d5c145 |
+#include <sys/types.h>
|
|
|
d5c145 |
+#include <sys/wait.h>
|
|
|
d5c145 |
+#include <asm/ptrace.h>
|
|
|
d5c145 |
+#include <string.h>
|
|
|
d5c145 |
+#include <errno.h>
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+#include "backend.h"
|
|
|
d5c145 |
+#include "proc.h"
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+void
|
|
|
d5c145 |
+get_arch_dep(struct process *proc)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+int aarch64_read_gregs(struct process *proc, struct user_pt_regs *regs);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+/* The syscall instruction is:
|
|
|
d5c145 |
+ * | 31 21 | 20 5 | 4 0 |
|
|
|
d5c145 |
+ * | 1 1 0 1 0 1 0 0 | 0 0 0 | imm16 | 0 0 0 0 1 | */
|
|
|
d5c145 |
+#define SVC_MASK 0xffe0001f
|
|
|
d5c145 |
+#define SVC_VALUE 0xd4000001
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+int
|
|
|
d5c145 |
+syscall_p(struct process *proc, int status, int *sysnum)
|
|
|
d5c145 |
+{
|
|
|
d5c145 |
+ if (WIFSTOPPED(status)
|
|
|
d5c145 |
+ && WSTOPSIG(status) == (SIGTRAP | proc->tracesysgood)) {
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ struct user_pt_regs regs;
|
|
|
d5c145 |
+ if (aarch64_read_gregs(proc, ®s) < 0) {
|
|
|
d5c145 |
+ fprintf(stderr, "syscall_p: "
|
|
|
d5c145 |
+ "Couldn't read registers of %d.\n", proc->pid);
|
|
|
d5c145 |
+ return -1;
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ errno = 0;
|
|
|
d5c145 |
+ unsigned long insn = (unsigned long) ptrace(PTRACE_PEEKTEXT,
|
|
|
d5c145 |
+ proc->pid,
|
|
|
d5c145 |
+ regs.pc - 4, 0);
|
|
|
d5c145 |
+ if (insn == -1UL && errno != 0) {
|
|
|
d5c145 |
+ fprintf(stderr, "syscall_p: "
|
|
|
d5c145 |
+ "Couldn't peek into %d: %s\n", proc->pid,
|
|
|
d5c145 |
+ strerror(errno));
|
|
|
d5c145 |
+ return -1;
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ insn &= 0xffffffffUL;
|
|
|
d5c145 |
+ if ((insn & SVC_MASK) == SVC_VALUE) {
|
|
|
d5c145 |
+ *sysnum = regs.regs[8];
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ size_t d1 = proc->callstack_depth - 1;
|
|
|
d5c145 |
+ if (proc->callstack_depth > 0
|
|
|
d5c145 |
+ && proc->callstack[d1].is_syscall
|
|
|
d5c145 |
+ && proc->callstack[d1].c_un.syscall == *sysnum)
|
|
|
d5c145 |
+ return 2;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ return 1;
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ return 0;
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
diff --git a/testsuite/ltrace.main/system_call_params.exp b/testsuite/ltrace.main/system_call_params.exp
|
|
|
d5c145 |
index 787e342..2ccf840 100644
|
|
|
d5c145 |
--- a/testsuite/ltrace.main/system_call_params.exp
|
|
|
d5c145 |
+++ b/testsuite/ltrace.main/system_call_params.exp
|
|
|
d5c145 |
@@ -1,5 +1,5 @@
|
|
|
d5c145 |
# This file is part of ltrace.
|
|
|
d5c145 |
-# Copyright (C) 2013 Petr Machata, Red Hat Inc.
|
|
|
d5c145 |
+# Copyright (C) 2013, 2014 Petr Machata, Red Hat Inc.
|
|
|
d5c145 |
#
|
|
|
d5c145 |
# This program is free software; you can redistribute it and/or
|
|
|
d5c145 |
# modify it under the terms of the GNU General Public License as
|
|
|
d5c145 |
@@ -17,11 +17,25 @@
|
|
|
d5c145 |
# 02110-1301 USA
|
|
|
d5c145 |
|
|
|
d5c145 |
set bin [ltraceCompile {} [ltraceSource c {
|
|
|
d5c145 |
+ #define _GNU_SOURCE
|
|
|
d5c145 |
#include <sys/types.h>
|
|
|
d5c145 |
#include <sys/stat.h>
|
|
|
d5c145 |
#include <fcntl.h>
|
|
|
d5c145 |
+ #include <unistd.h>
|
|
|
d5c145 |
+ #include <sys/syscall.h> /* For SYS_xxx definitions */
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ #ifndef SYS_open
|
|
|
d5c145 |
+ # if defined(__aarch64__)
|
|
|
d5c145 |
+ # /* Linux doesn't actually implement SYS_open on AArch64, but for merely
|
|
|
d5c145 |
+ # * recording the syscall, it's fine. */
|
|
|
d5c145 |
+ # define SYS_open 1024
|
|
|
d5c145 |
+ # else
|
|
|
d5c145 |
+ # error SYS_open not available.
|
|
|
d5c145 |
+ # endif
|
|
|
d5c145 |
+ #endif
|
|
|
d5c145 |
+
|
|
|
d5c145 |
int main(void) {
|
|
|
d5c145 |
- open("/some/path", O_RDONLY);
|
|
|
d5c145 |
+ syscall(SYS_open, "/some/path", O_RDONLY);
|
|
|
d5c145 |
write(1, "something", 10);
|
|
|
d5c145 |
mount("source", "target", "filesystemtype", 0, 0);
|
|
|
d5c145 |
}
|
|
|
d5c145 |
diff --git a/testsuite/ltrace.main/system_calls.c b/testsuite/ltrace.main/system_calls.c
|
|
|
d5c145 |
deleted file mode 100644
|
|
|
d5c145 |
index 7be3d04..0000000
|
|
|
d5c145 |
--- a/testsuite/ltrace.main/system_calls.c
|
|
|
d5c145 |
+++ /dev/null
|
|
|
d5c145 |
@@ -1,68 +0,0 @@
|
|
|
d5c145 |
-/* Ltrace Test : system_calls.c.
|
|
|
d5c145 |
- Objectives : Verify that Ltrace can trace all the system calls in
|
|
|
d5c145 |
- execution.
|
|
|
d5c145 |
-
|
|
|
d5c145 |
- You can add new system calls in it and add its verification in
|
|
|
d5c145 |
- system_calls correspondingly.
|
|
|
d5c145 |
-
|
|
|
d5c145 |
- This file was written by Yao Qi <qiyao@cn.ibm.com>. */
|
|
|
d5c145 |
-
|
|
|
d5c145 |
-#include <stdio.h>
|
|
|
d5c145 |
-#include <unistd.h>
|
|
|
d5c145 |
-#include <sys/syscall.h>
|
|
|
d5c145 |
-#include <sys/stat.h>
|
|
|
d5c145 |
-#include <errno.h>
|
|
|
d5c145 |
-
|
|
|
d5c145 |
-void exit (int);
|
|
|
d5c145 |
-
|
|
|
d5c145 |
-#define BUF_SIZE 100
|
|
|
d5c145 |
-
|
|
|
d5c145 |
-int
|
|
|
d5c145 |
-main ()
|
|
|
d5c145 |
-{
|
|
|
d5c145 |
- FILE* fp;
|
|
|
d5c145 |
- char s[]="system_calls";
|
|
|
d5c145 |
- char buffer[BUF_SIZE];
|
|
|
d5c145 |
- struct stat state;
|
|
|
d5c145 |
-
|
|
|
d5c145 |
- /* SYS_open. */
|
|
|
d5c145 |
- fp = fopen ("system_calls.tmp", "w");
|
|
|
d5c145 |
- if (fp == NULL)
|
|
|
d5c145 |
- {
|
|
|
d5c145 |
- printf("Can not create system_calls.tmp\n");
|
|
|
d5c145 |
- exit (0);
|
|
|
d5c145 |
- }
|
|
|
d5c145 |
- /* SYS_write. */
|
|
|
d5c145 |
- fwrite(s, sizeof(s), 1, fp);
|
|
|
d5c145 |
- /* SYS_lseek. */
|
|
|
d5c145 |
- fseek (fp, 0, SEEK_CUR);
|
|
|
d5c145 |
- /* SYS_read. */
|
|
|
d5c145 |
- fread(buffer, sizeof(s), 1, fp);
|
|
|
d5c145 |
- /* SYS_close. */
|
|
|
d5c145 |
- fclose(fp);
|
|
|
d5c145 |
-
|
|
|
d5c145 |
- /* SYS_getcwd. */
|
|
|
d5c145 |
- getcwd (buffer, BUF_SIZE);
|
|
|
d5c145 |
- /* SYS_chdir. */
|
|
|
d5c145 |
- chdir (".");
|
|
|
d5c145 |
- /* SYS_symlink. */
|
|
|
d5c145 |
- symlink ("system_calls.tmp", "system_calls.link");
|
|
|
d5c145 |
- /* SYS_unlink. */
|
|
|
d5c145 |
- remove("system_calls.link");
|
|
|
d5c145 |
- /* SYS_rename. */
|
|
|
d5c145 |
- rename ("system_calls.tmp", "system_calls.tmp1");
|
|
|
d5c145 |
- /* SYS_stat. */
|
|
|
d5c145 |
- stat ("system_calls.tmp", &state);
|
|
|
d5c145 |
- /* SYS_access. */
|
|
|
d5c145 |
- access ("system_calls.tmp", R_OK);
|
|
|
d5c145 |
- remove("system_calls.tmp1");
|
|
|
d5c145 |
-
|
|
|
d5c145 |
- /* SYS_mkdir. */
|
|
|
d5c145 |
- mkdir ("system_call_mkdir", 0777);
|
|
|
d5c145 |
- /* SYS_rmdir. */
|
|
|
d5c145 |
- rmdir ("system_call_mkdir");
|
|
|
d5c145 |
-
|
|
|
d5c145 |
- return 0;
|
|
|
d5c145 |
-}
|
|
|
d5c145 |
-
|
|
|
d5c145 |
-
|
|
|
d5c145 |
diff --git a/testsuite/ltrace.main/system_calls.exp b/testsuite/ltrace.main/system_calls.exp
|
|
|
d5c145 |
index a74fa04..f60e319 100644
|
|
|
d5c145 |
--- a/testsuite/ltrace.main/system_calls.exp
|
|
|
d5c145 |
+++ b/testsuite/ltrace.main/system_calls.exp
|
|
|
d5c145 |
@@ -1,67 +1,146 @@
|
|
|
d5c145 |
-# This file was written by Yao Qi <qiyao@cn.ibm.com>.
|
|
|
d5c145 |
+# This file is part of ltrace.
|
|
|
d5c145 |
+# Copyright (C) 2014 Petr Machata, Red Hat Inc.
|
|
|
d5c145 |
+# Copyright (C) 2006 Yao Qi <qiyao@cn.ibm.com>, IBM Corporation
|
|
|
d5c145 |
+#
|
|
|
d5c145 |
+# This program is free software; you can redistribute it and/or
|
|
|
d5c145 |
+# modify it under the terms of the GNU General Public License as
|
|
|
d5c145 |
+# published by the Free Software Foundation; either version 2 of the
|
|
|
d5c145 |
+# License, or (at your option) any later version.
|
|
|
d5c145 |
+#
|
|
|
d5c145 |
+# This program is distributed in the hope that it will be useful, but
|
|
|
d5c145 |
+# WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
d5c145 |
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
d5c145 |
+# General Public License for more details.
|
|
|
d5c145 |
+#
|
|
|
d5c145 |
+# You should have received a copy of the GNU General Public License
|
|
|
d5c145 |
+# along with this program; if not, write to the Free Software
|
|
|
d5c145 |
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
|
|
|
d5c145 |
+# 02110-1301 USA
|
|
|
d5c145 |
|
|
|
d5c145 |
-set testfile "system_calls"
|
|
|
d5c145 |
-set srcfile ${testfile}.c
|
|
|
d5c145 |
-set binfile ${testfile}
|
|
|
d5c145 |
+# Objectives: Verify that Ltrace can trace all the system calls in
|
|
|
d5c145 |
+# execution. Note that this test is necessarily noisy. Dynamic
|
|
|
d5c145 |
+# linker adds a bunch of system calls of its own.
|
|
|
d5c145 |
|
|
|
d5c145 |
+set empty [ltraceCompile {} [ltraceSource c {
|
|
|
d5c145 |
+ int main (void) { return 0; }
|
|
|
d5c145 |
+}]]
|
|
|
d5c145 |
|
|
|
d5c145 |
-verbose "compiling source file now....."
|
|
|
d5c145 |
-# Build the shared libraries this test case needs.
|
|
|
d5c145 |
-if { [ ltrace_compile "${srcdir}/${subdir}/${testfile}.c" "${objdir}/${subdir}/${binfile}" executable {debug} ] != "" } {
|
|
|
d5c145 |
- send_user "Testcase compile failed, so all tests in this file will automatically fail.\n"
|
|
|
d5c145 |
+set bin [ltraceCompile {} [ltraceSource c {
|
|
|
d5c145 |
+ #include <stdio.h>
|
|
|
d5c145 |
+ #include <unistd.h>
|
|
|
d5c145 |
+ #include <sys/syscall.h>
|
|
|
d5c145 |
+ #include <sys/stat.h>
|
|
|
d5c145 |
+ #include <errno.h>
|
|
|
d5c145 |
+ #include <stdlib.h>
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ int
|
|
|
d5c145 |
+ main ()
|
|
|
d5c145 |
+ {
|
|
|
d5c145 |
+ FILE* fp;
|
|
|
d5c145 |
+ char s[]="system_calls";
|
|
|
d5c145 |
+ char buffer[1024];
|
|
|
d5c145 |
+ struct stat state;
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ fp = fopen ("system_calls.tmp", "w");
|
|
|
d5c145 |
+ if (fp == NULL)
|
|
|
d5c145 |
+ {
|
|
|
d5c145 |
+ printf("Can not create system_calls.tmp\n");
|
|
|
d5c145 |
+ exit (0);
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+ fwrite(s, sizeof(s), 1, fp);
|
|
|
d5c145 |
+ fseek (fp, 0, SEEK_CUR);
|
|
|
d5c145 |
+ fread(buffer, sizeof(s), 1, fp);
|
|
|
d5c145 |
+ fclose(fp);
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ getcwd (buffer, sizeof buffer);
|
|
|
d5c145 |
+ chdir (".");
|
|
|
d5c145 |
+ symlink ("system_calls.tmp", "system_calls.link");
|
|
|
d5c145 |
+ remove("system_calls.link");
|
|
|
d5c145 |
+ rename ("system_calls.tmp", "system_calls.tmp1");
|
|
|
d5c145 |
+ stat ("system_calls.tmp", &state);
|
|
|
d5c145 |
+ access ("system_calls.tmp", R_OK);
|
|
|
d5c145 |
+ remove("system_calls.tmp1");
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ mkdir ("system_call_mkdir", 0777);
|
|
|
d5c145 |
+ rmdir ("system_call_mkdir");
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ return 0;
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+}]]
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+proc Calls {logfile} {
|
|
|
d5c145 |
+ set fp [open $logfile]
|
|
|
d5c145 |
+ set ret {}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ while {[gets $fp line] >= 0} {
|
|
|
d5c145 |
+ if [regexp -- {^[a-zA-Z0-9]*@SYS} $line] {
|
|
|
d5c145 |
+ set call [lindex [split $line @] 0]
|
|
|
d5c145 |
+ dict incr ret $call
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+ close $fp
|
|
|
d5c145 |
+ return $ret
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+proc GetDefault {d key def} {
|
|
|
d5c145 |
+ if {[dict exists $d $key]} {
|
|
|
d5c145 |
+ return [dict get $d $key]
|
|
|
d5c145 |
+ } else {
|
|
|
d5c145 |
+ return $def
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
}
|
|
|
d5c145 |
|
|
|
d5c145 |
-# set options for ltrace.
|
|
|
d5c145 |
-ltrace_options "-S"
|
|
|
d5c145 |
+proc Diff {d1 d2} {
|
|
|
d5c145 |
+ set keys [lsort -unique [concat [dict keys $d1] [dict keys $d2]]]
|
|
|
d5c145 |
+ set ret {}
|
|
|
d5c145 |
+ foreach key $keys {
|
|
|
d5c145 |
+ set n1 [GetDefault $d1 $key 0]
|
|
|
d5c145 |
+ set n2 [GetDefault $d2 $key 0]
|
|
|
d5c145 |
+ set sum [expr $n1 - $n2]
|
|
|
d5c145 |
+ if {[expr $sum != 0]} {
|
|
|
d5c145 |
+ dict set ret $key $sum
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+ return $ret
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
+
|
|
|
d5c145 |
+proc Match {d patterns} {
|
|
|
d5c145 |
+ foreach line $patterns {
|
|
|
d5c145 |
+ set pattern [lindex $line 0]
|
|
|
d5c145 |
+ set op [lindex $line 1]
|
|
|
d5c145 |
+ set expect [lindex $line 2]
|
|
|
d5c145 |
|
|
|
d5c145 |
-#Run PUT for ltarce.
|
|
|
d5c145 |
-set exec_output [ltrace_runtest $objdir/$subdir $objdir/$subdir/$binfile]
|
|
|
d5c145 |
+ set count 0
|
|
|
d5c145 |
+ foreach key [dict keys $d] {
|
|
|
d5c145 |
+ if [regexp -- $pattern $key] {
|
|
|
d5c145 |
+ incr count [dict get $d $key]
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
|
|
|
d5c145 |
-#check the output of this program.
|
|
|
d5c145 |
-verbose "ltrace runtest output: $exec_output\n"
|
|
|
d5c145 |
+ set msgMain "$pattern was recorded $count times"
|
|
|
d5c145 |
|
|
|
d5c145 |
-if [regexp {ELF from incompatible architecture} $exec_output] {
|
|
|
d5c145 |
- fail "32-bit ltrace can not perform on 64-bit PUTs and rebuild ltrace in 64 bit mode!"
|
|
|
d5c145 |
- return
|
|
|
d5c145 |
-} elseif [ regexp {Couldn't get .hash data} $exec_output ] {
|
|
|
d5c145 |
- fail "Couldn't get .hash data!"
|
|
|
d5c145 |
- return
|
|
|
d5c145 |
+ if {[eval expr $count $op $expect]} {
|
|
|
d5c145 |
+ pass $msgMain
|
|
|
d5c145 |
+ } else {
|
|
|
d5c145 |
+ fail "$msgMain, expected $op $expect"
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
+ }
|
|
|
d5c145 |
}
|
|
|
d5c145 |
|
|
|
d5c145 |
+Match [Diff [Calls [ltraceRun -L -S -- $bin]] \
|
|
|
d5c145 |
+ [Calls [ltraceRun -L -S -- $empty]]] {
|
|
|
d5c145 |
+ { {^write$} == 1 }
|
|
|
d5c145 |
+ { {^unlink(at)?$} >= 2 }
|
|
|
d5c145 |
+ { {^open(at)?$} == 1 }
|
|
|
d5c145 |
+ { {^(new|f)?stat(64)?$} == 1 }
|
|
|
d5c145 |
+ { {^close$} == 1 }
|
|
|
d5c145 |
+ { {^getcwd$} == 1 }
|
|
|
d5c145 |
+ { {^chdir$} == 1 }
|
|
|
d5c145 |
+ { {^symlink(at)?$} == 1 }
|
|
|
d5c145 |
+ { {^f?access(at)?$} == 1 }
|
|
|
d5c145 |
+ { {^rename(at)?$} == 1 }
|
|
|
d5c145 |
+ { {^mkdir(at)?$} == 1 }
|
|
|
d5c145 |
+}
|
|
|
d5c145 |
|
|
|
d5c145 |
-set pattern "^munmap@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 2
|
|
|
d5c145 |
-set pattern "^write@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1
|
|
|
d5c145 |
-set pattern "^unlink@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1
|
|
|
d5c145 |
-
|
|
|
d5c145 |
-set pattern "^brk@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1
|
|
|
d5c145 |
-set pattern "^open@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1
|
|
|
d5c145 |
-set pattern "^(new)?fstat(64)?@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1 egrep
|
|
|
d5c145 |
-set pattern "^(old_)?mmap2?@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1 egrep
|
|
|
d5c145 |
-set pattern "^close@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1
|
|
|
d5c145 |
-
|
|
|
d5c145 |
-set pattern "^getcwd@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1
|
|
|
d5c145 |
-set pattern "^chdir@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1
|
|
|
d5c145 |
-set pattern "^symlink@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1
|
|
|
d5c145 |
-set pattern "^unlink@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1
|
|
|
d5c145 |
-set pattern "^(new)?stat(64)?@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1 egrep
|
|
|
d5c145 |
-set pattern "^access@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1
|
|
|
d5c145 |
-set pattern "^rename@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1
|
|
|
d5c145 |
-set pattern "^mkdir@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1
|
|
|
d5c145 |
-set pattern "^rmdir@SYS"
|
|
|
d5c145 |
-ltrace_verify_output ${objdir}/${subdir}/${testfile}.ltrace $pattern 1
|
|
|
d5c145 |
+ltraceDone
|
|
|
d5c145 |
diff --git a/testsuite/ltrace.minor/trace-clone.c b/testsuite/ltrace.minor/trace-clone.c
|
|
|
d5c145 |
index db1936d..ded930c 100644
|
|
|
d5c145 |
--- a/testsuite/ltrace.minor/trace-clone.c
|
|
|
d5c145 |
+++ b/testsuite/ltrace.minor/trace-clone.c
|
|
|
d5c145 |
@@ -8,6 +8,7 @@
|
|
|
d5c145 |
#include <sys/types.h>
|
|
|
d5c145 |
#include <stdlib.h>
|
|
|
d5c145 |
#include <sched.h>
|
|
|
d5c145 |
+#include <unistd.h>
|
|
|
d5c145 |
|
|
|
d5c145 |
int child ()
|
|
|
d5c145 |
{
|
|
|
d5c145 |
@@ -22,7 +23,8 @@ typedef int (* myfunc)();
|
|
|
d5c145 |
int main ()
|
|
|
d5c145 |
{
|
|
|
d5c145 |
pid_t pid;
|
|
|
d5c145 |
- static char stack[STACK_SIZE];
|
|
|
d5c145 |
+ static __attribute__ ((aligned (16))) char stack[STACK_SIZE];
|
|
|
d5c145 |
+
|
|
|
d5c145 |
#ifdef __ia64__
|
|
|
d5c145 |
pid = __clone2((myfunc)&child, stack, STACK_SIZE, CLONE_FS, NULL);
|
|
|
d5c145 |
#else
|