case gdb_sys_exit:
{
int q;
+
target_terminal_ours ();
q = yquery (_("The next instruction is syscall exit. "
"It will make the program exit. "
case gdb_sys_read:
{
ULONGEST addr, count;
+
regcache_raw_read_unsigned (regcache, tdep->arg2, &addr);
regcache_raw_read_unsigned (regcache, tdep->arg3, &count);
if (record_arch_list_add_mem ((CORE_ADDR) addr, (int) count))
case gdb_sys_readlink:
{
ULONGEST len;
+
regcache_raw_read_unsigned (regcache, tdep->arg2,
&tmpulongest);
regcache_raw_read_unsigned (regcache, tdep->arg3, &len);
case gdb_sys_reboot:
{
int q;
+
target_terminal_ours ();
- q =
- yquery (_("The next instruction is syscall reboot. "
- "It will restart the computer. "
- "Do you want to stop the program?"));
+ q = yquery (_("The next instruction is syscall reboot. "
+ "It will restart the computer. "
+ "Do you want to stop the program?"));
target_terminal_inferior ();
if (q)
return 1;
case gdb_sys_getpeername:
{
ULONGEST len;
+
regcache_raw_read_unsigned (regcache, tdep->arg2, &tmpulongest);
regcache_raw_read_unsigned (regcache, tdep->arg3, &len);
if (record_linux_sockaddr (regcache, tdep, tmpulongest, len))
case gdb_sys_recvfrom:
{
ULONGEST len;
+
regcache_raw_read_unsigned (regcache, tdep->arg4, &tmpulongest);
regcache_raw_read_unsigned (regcache, tdep->arg5, &len);
if (record_linux_sockaddr (regcache, tdep, tmpulongest, len))
case gdb_sys_recv:
{
ULONGEST size;
+
regcache_raw_read_unsigned (regcache, tdep->arg2, &tmpulongest);
regcache_raw_read_unsigned (regcache, tdep->arg3, &size);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest, (int) size))
{
ULONGEST optvalp;
gdb_byte *optlenp = alloca (tdep->size_int);
+
if (target_read_memory ((CORE_ADDR) tmpulongest, optlenp,
tdep->size_int))
{
case RECORD_SYS_SOCKETPAIR:
{
gdb_byte *a = alloca (tdep->size_ulong);
+
regcache_raw_read_unsigned (regcache, tdep->arg2,
&tmpulongest);
if (tmpulongest)
case gdb_sys_msgrcv:
{
ULONGEST msgp;
+
regcache_raw_read_signed (regcache, tdep->arg3, &tmpulongest);
regcache_raw_read_unsigned (regcache, tdep->arg2, &msgp);
tmpint = (int) tmpulongest + tdep->size_long;
{
ULONGEST second;
ULONGEST ptr;
+
regcache_raw_read_signed (regcache, tdep->arg3, &second);
regcache_raw_read_unsigned (regcache, tdep->arg5, &ptr);
tmpint = (int) second + tdep->size_long;
if (tmpulongest == 0 || tmpulongest == 2)
{
ULONGEST ptr, bytecount;
+
regcache_raw_read_unsigned (regcache, tdep->arg2, &ptr);
regcache_raw_read_unsigned (regcache, tdep->arg3, &bytecount);
if (record_arch_list_add_mem ((CORE_ADDR) ptr, (int) bytecount))
case gdb_sys_getdents:
{
ULONGEST count;
+
regcache_raw_read_unsigned (regcache, tdep->arg2,
&tmpulongest);
regcache_raw_read_unsigned (regcache, tdep->arg3, &count);
if (tmpulongest)
{
ULONGEST nfds;
+
regcache_raw_read_unsigned (regcache, tdep->arg2, &nfds);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest,
tdep->size_pollfd * nfds))
if (tmpulongest == 7 || tmpulongest == 8)
{
int rsize;
+
if (tmpulongest == 7)
rsize = tdep->size_NFS_FHSIZE;
else
if (tmpulongest)
{
ULONGEST sigsetsize;
+
regcache_raw_read_unsigned (regcache, tdep->arg2,&sigsetsize);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest,
(int) sigsetsize))
if (tmpulongest)
{
ULONGEST count;
+
regcache_raw_read_unsigned (regcache, tdep->arg3,&count);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest, (int) count))
return -1;
if (tmpulongest)
{
ULONGEST size;
+
regcache_raw_read_unsigned (regcache, tdep->arg2, &size);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest, (int) size))
return -1;
if (tmpulongest)
{
ULONGEST gidsetsize;
+
regcache_raw_read_unsigned (regcache, tdep->arg1,
&gidsetsize);
tmpint = tdep->size_gid_t * (int) gidsetsize;
case gdb_sys_getdents64:
{
ULONGEST count;
+
regcache_raw_read_unsigned (regcache, tdep->arg2,
&tmpulongest);
regcache_raw_read_unsigned (regcache, tdep->arg3, &count);
if (tmpulongest)
{
ULONGEST size;
+
regcache_raw_read_unsigned (regcache, tdep->arg4, &size);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest, (int) size))
return -1;
if (tmpulongest)
{
ULONGEST size;
+
regcache_raw_read_unsigned (regcache, tdep->arg3, &size);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest, (int) size))
return -1;
if (tmpulongest)
{
ULONGEST len;
+
regcache_raw_read_unsigned (regcache, tdep->arg2, &len);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest, (int) len))
return -1;
if (tmpulongest)
{
ULONGEST nr;
+
regcache_raw_read_unsigned (regcache, tdep->arg3, &nr);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest,
nr * tdep->size_io_event))
case gdb_sys_exit_group:
{
int q;
+
target_terminal_ours ();
q = yquery (_("The next instruction is syscall exit_group. "
"It will make the program exit. "
if (tmpulongest)
{
ULONGEST len;
+
regcache_raw_read_unsigned (regcache, tdep->arg3, &len);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest, (int) len))
return -1;
if (tmpulongest)
{
ULONGEST maxevents;
+
regcache_raw_read_unsigned (regcache, tdep->arg3, &maxevents);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest,
maxevents * tdep->size_epoll_event))
if (tmpulongest)
{
ULONGEST maxnode;
+
regcache_raw_read_unsigned (regcache, tdep->arg3, &maxnode);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest,
maxnode * tdep->size_long))
if (tmpulongest)
{
ULONGEST msg_len;
+
regcache_raw_read_unsigned (regcache, tdep->arg3, &msg_len);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest,
(int) msg_len))
if (tmpulongest)
{
ULONGEST buflen;
+
regcache_raw_read_unsigned (regcache, tdep->arg4, &buflen);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest,
(int) buflen))
if (tmpulongest)
{
ULONGEST bufsiz;
+
regcache_raw_read_unsigned (regcache, tdep->arg4, &bufsiz);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest, (int) bufsiz))
return -1;
if (tmpulongest)
{
ULONGEST nfds;
+
regcache_raw_read_unsigned (regcache, tdep->arg2, &nfds);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest,
tdep->size_pollfd * nfds))
if (tmpulongest)
{
ULONGEST nr_pages;
+
regcache_raw_read_unsigned (regcache, tdep->arg2, &nr_pages);
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest,
nr_pages * tdep->size_int))
if (tmpulongest)
{
ULONGEST maxevents;
+
regcache_raw_read_unsigned (regcache, tdep->arg3, &maxevents);
tmpint = (int) maxevents * tdep->size_epoll_event;
if (record_arch_list_add_mem ((CORE_ADDR) tmpulongest, tmpint))