aboutsummaryrefslogtreecommitdiff
path: root/gdb/dwarf2loc.h
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2011-02-17 16:20:44 +0000
committerTom Tromey <tromey@redhat.com>2011-02-17 16:20:44 +0000
commit9f6f94ff251ac7faaed16ff4cc13b6e8a9ad8997 (patch)
tree3291ae5bd655545060156cb49a061a11f8fc0970 /gdb/dwarf2loc.h
parent98e16b7718cb6978c9a0bd1919bd1856a3b442cb (diff)
downloadgdb-9f6f94ff251ac7faaed16ff4cc13b6e8a9ad8997.zip
gdb-9f6f94ff251ac7faaed16ff4cc13b6e8a9ad8997.tar.gz
gdb-9f6f94ff251ac7faaed16ff4cc13b6e8a9ad8997.tar.bz2
* dwarf2loc.h (dwarf2_compile_expr_to_ax): Declare.
* dwarf2loc.c (dwarf2_compile_expr_to_ax): Rename from compile_dwarf_to_ax. No longer static. Call dwarf2_compile_cfa_to_ax. (locexpr_tracepoint_var_ref): Update. (loclist_tracepoint_var_ref): Update. * dwarf2-frame.h (dwarf2_compile_cfa_to_ax): Declare. * dwarf2-frame.c (execute_cfa_program): Remove 'this_frame' argument; add 'gdbarch' and 'pc'. (dwarf2_compile_cfa_to_ax): New function. (dwarf2_frame_cache): Update.
Diffstat (limited to 'gdb/dwarf2loc.h')
-rw-r--r--gdb/dwarf2loc.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/gdb/dwarf2loc.h b/gdb/dwarf2loc.h
index ee52506..96a490e 100644
--- a/gdb/dwarf2loc.h
+++ b/gdb/dwarf2loc.h
@@ -25,6 +25,8 @@ struct symbol_computed_ops;
struct objfile;
struct dwarf2_per_cu_data;
struct dwarf2_loclist_baton;
+struct agent_expr;
+struct axs_value;
/* This header is private to the DWARF-2 reader. It is shared between
dwarf2read.c and dwarf2loc.c. */
@@ -106,4 +108,25 @@ struct dwarf2_loclist_baton
extern const struct symbol_computed_ops dwarf2_locexpr_funcs;
extern const struct symbol_computed_ops dwarf2_loclist_funcs;
+/* Compile a DWARF location expression to an agent expression.
+
+ EXPR is the agent expression we are building.
+ LOC is the agent value we modify.
+ ARCH is the architecture.
+ ADDR_SIZE is the size of addresses, in bytes.
+ OP_PTR is the start of the location expression.
+ OP_END is one past the last byte of the location expression.
+
+ This will throw an exception for various kinds of errors -- for
+ example, if the expression cannot be compiled, or if the expression
+ is invalid. */
+
+extern void dwarf2_compile_expr_to_ax (struct agent_expr *expr,
+ struct axs_value *loc,
+ struct gdbarch *arch,
+ unsigned int addr_size,
+ const gdb_byte *op_ptr,
+ const gdb_byte *op_end,
+ struct dwarf2_per_cu_data *per_cu);
+
#endif /* dwarf2loc.h */