GDB (xrefs)
/tmp/gdb-8.1/gdb/stap-probe.h
Go to the documentation of this file.
1
/* SystemTap probe support for GDB.
2
3
Copyright (C) 2012-2018 Free Software Foundation, Inc.
4
5
This file is part of GDB.
6
7
This program is free software; you can redistribute it and/or modify
8
it under the terms of the GNU General Public License as published by
9
the Free Software Foundation; either version 3 of the License, or
10
(at your option) any later version.
11
12
This program is distributed in the hope that it will be useful,
13
but WITHOUT ANY WARRANTY; without even the implied warranty of
14
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
GNU General Public License for more details.
16
17
You should have received a copy of the GNU General Public License
18
along with this program. If not, see <http://www.gnu.org/licenses/>. */
19
20
#if !defined (STAP_PROBE_H)
21
#define STAP_PROBE_H 1
22
23
/* For `struct parser_state'. */
24
#include "
parser-defs.h
"
25
26
/* Structure which holds information about the parsing process of one probe's
27
argument. */
28
29
struct
stap_parse_info
30
{
31
stap_parse_info
(
const
char
*arg_,
struct
type
*arg_type_,
32
size_t
initial_size,
const
struct
language_defn
*lang,
33
struct
gdbarch
*
gdbarch
)
34
:
arg
(arg_),
35
pstate
(initial_size, lang,
gdbarch
),
36
saved_arg
(arg_),
37
arg_type
(arg_type_),
38
gdbarch
(
gdbarch
),
39
inside_paren_p
(0)
40
{
41
}
42
43
DISABLE_COPY_AND_ASSIGN
(
stap_parse_info
);
44
45
/* The probe's argument in a string format. */
46
const
char
*
arg
;
47
48
/* The parser state to be used when generating the expression. */
49
struct
parser_state
pstate
;
50
51
/* A pointer to the full chain of arguments. This is useful for printing
52
error messages. The parser functions should not modify this argument
53
directly; instead, they should use the ARG pointer above. */
54
const
char
*
saved_arg
;
55
56
/* The expected argument type (bitness), as defined in the probe's
57
argument. For instance, if the argument begins with `-8@', it means
58
the bitness is 64-bit signed. In this case, ARG_TYPE would represent
59
the type `int64_t'. */
60
struct
type
*
arg_type
;
61
62
/* A pointer to the current gdbarch. */
63
struct
gdbarch
*
gdbarch
;
64
65
/* Greater than zero if we are inside a parenthesized expression. Useful
66
for knowing when to skip spaces or not. */
67
int
inside_paren_p
;
68
};
69
70
#endif
/* !defined (STAP_PROBE_H) */
gdbarch
Definition:
gdbarch.c:127
stap_parse_info::gdbarch
struct gdbarch * gdbarch
Definition:
stap-probe.h:63
stap_parse_info::arg_type
struct type * arg_type
Definition:
stap-probe.h:60
stap_parse_info
Definition:
stap-probe.h:29
stap_parse_info::arg
const char * arg
Definition:
stap-probe.h:46
stap_parse_info::stap_parse_info
stap_parse_info(const char *arg_, struct type *arg_type_, size_t initial_size, const struct language_defn *lang, struct gdbarch *gdbarch)
Definition:
stap-probe.h:31
language_defn
Definition:
language.h:132
parser-defs.h
stap_parse_info::pstate
struct parser_state pstate
Definition:
stap-probe.h:49
type
Definition:
gdbtypes.h:749
stap_parse_info::saved_arg
const char * saved_arg
Definition:
stap-probe.h:54
stap_parse_info::inside_paren_p
int inside_paren_p
Definition:
stap-probe.h:67
parser_state
Definition:
parser-defs.h:38
stap_parse_info::DISABLE_COPY_AND_ASSIGN
DISABLE_COPY_AND_ASSIGN(stap_parse_info)
Generated by
1.8.14