gdb/x86-linux-nat.h - gdb

Macros defined

Source code

  1. /* Native-dependent code for GNU/Linux x86 (i386 and x86-64).

  2.    Copyright (C) 1999-2015 Free Software Foundation, Inc.

  3.    This file is part of GDB.

  4.    This program is free software; you can redistribute it and/or modify
  5.    it under the terms of the GNU General Public License as published by
  6.    the Free Software Foundation; either version 3 of the License, or
  7.    (at your option) any later version.

  8.    This program is distributed in the hope that it will be useful,
  9.    but WITHOUT ANY WARRANTY; without even the implied warranty of
  10.    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  11.    GNU General Public License for more details.

  12.    You should have received a copy of the GNU General Public License
  13.    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */

  14. #ifndef X86_LINUX_NAT_H
  15. #define X86_LINUX_NAT_H 1

  16. #ifndef PTRACE_GETREGSET
  17. #define PTRACE_GETREGSET        0x4204
  18. #endif

  19. #ifndef PTRACE_SETREGSET
  20. #define PTRACE_SETREGSET        0x4205
  21. #endif

  22. /* Does the current host support PTRACE_GETREGSET?  */
  23. extern int have_ptrace_getregset;


  24. /* Helper for ps_get_thread_area.  Sets BASE_ADDR to a pointer to
  25.    the thread local storage (or its descriptor) and returns PS_OK
  26.    on success.  Returns PS_ERR on failure.  */

  27. extern ps_err_e x86_linux_get_thread_area (pid_t pid, void *addr,
  28.                                            unsigned int *base_addr);


  29. /* Create an x86 GNU/Linux target.  */

  30. extern struct target_ops *x86_linux_create_target (void);

  31. /* Add an x86 GNU/Linux target.  */

  32. extern void x86_linux_add_target (struct target_ops *t);

  33. #endif