< prev index next >
agent/src/os/solaris/proc/salibproc.h
Print this page
@@ -1,7 +1,7 @@
/*
- * Copyright (c) 2003, 2011, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation.
@@ -44,20 +44,32 @@
#ifdef __cplusplus
extern "C" {
#endif
+/* extended symbol table information */
+typedef struct {
+ const char *prs_object; /* object name */
+ const char *prs_name; /* symbol name */
+ Lmid_t prs_lmid; /* link map id */
+ uint_t prs_id; /* symbol id */
+ uint_t prs_table; /* symbol table id */
+} prsyminfo_t;
+
+typedef struct ps_prochandle ps_prochandle_t;
+
/*
* 'object_name' is the name of a load object obtained from an
* iteration over the process's address space mappings (Pmapping_iter),
* or an iteration over the process's mapped objects (Pobject_iter),
* or else it is one of the special PR_OBJ_* values above.
*/
-extern int Plookup_by_addr(struct ps_prochandle *,
- uintptr_t, char *, size_t, GElf_Sym *);
-
+extern int Plookup_by_addr(ps_prochandle_t *, uintptr_t, char *,
+ size_t, GElf_Sym *, prsyminfo_t *);
+extern ps_prochandle_t *proc_arg_grab(const char *, int, int,
+ int *, const char **);
typedef int proc_map_f(void *, const prmap_t *, const char *);
extern int Pobject_iter(struct ps_prochandle *, proc_map_f *, void *);
/*
* Utility functions for processing arguments which should be /proc files,
@@ -86,11 +98,10 @@
#define G_LP64 11 /* Process is _LP64, self is ILP32 */
#define G_FORMAT 12 /* File is not an ELF format core file */
#define G_ELF 13 /* Libelf error, elf_errno() is meaningful */
#define G_NOTE 14 /* Required PT_NOTE Phdr not present in core */
-extern struct ps_prochandle *proc_arg_grab(const char *, int, int, int *);
extern const pstatus_t *Pstatus(struct ps_prochandle *);
/* Flags accepted by Prelease (partial) */
#define PRELEASE_CLEAR 0x10 /* Clear all tracing flags */
@@ -99,26 +110,20 @@
extern int Pstop(struct ps_prochandle *, uint_t);
/*
* Stack frame iteration interface.
*/
-#ifdef SOLARIS_11_B159_OR_LATER
-/* building on Nevada-B159 or later so define the new callback */
typedef int proc_stack_f(
void *, /* the cookie given to Pstack_iter() */
const prgregset_t, /* the frame's registers */
uint_t, /* argc for the frame's function */
const long *, /* argv for the frame's function */
int, /* bitwise flags describing the frame (see below) */
int); /* a signal number */
#define PR_SIGNAL_FRAME 1 /* called by a signal handler */
#define PR_FOUND_SIGNAL 2 /* we found the corresponding signal number */
-#else
-/* building on Nevada-B158 or earlier so define the old callback */
-typedef int proc_stack_f(void *, const prgregset_t, uint_t, const long *);
-#endif
extern int Pstack_iter(struct ps_prochandle *,
const prgregset_t, proc_stack_f *, void *);
#define PR_OBJ_EVERY ((const char *)-1) /* search every load object */
< prev index next >