blob: c53a41f48b63419fcdb078ab28fc4d5227f66d3e [file] [log] [blame]
Stephane Eranian209045a2015-11-30 10:02:22 +01001#ifndef __JVMTI_AGENT_H__
2#define __JVMTI_AGENT_H__
3
4#include <sys/types.h>
5#include <stdint.h>
6#include <jvmti.h>
7
Stephane Eranian209045a2015-11-30 10:02:22 +01008#if defined(__cplusplus)
9extern "C" {
10#endif
11
Stephane Eranian598b7c62015-11-30 10:02:23 +010012typedef struct {
13 unsigned long pc;
14 int line_number;
15 int discrim; /* discriminator -- 0 for now */
16} jvmti_line_info_t;
17
Stephane Eranian209045a2015-11-30 10:02:22 +010018void *jvmti_open(void);
19int jvmti_close(void *agent);
20int jvmti_write_code(void *agent, char const *symbol_name,
21 uint64_t vma, void const *code,
22 const unsigned int code_size);
Stephane Eranian598b7c62015-11-30 10:02:23 +010023
Stephane Eranian209045a2015-11-30 10:02:22 +010024int jvmti_write_debug_info(void *agent,
25 uint64_t code,
26 const char *file,
Stephane Eranian598b7c62015-11-30 10:02:23 +010027 jvmti_line_info_t *li,
28 int nr_lines);
Stephane Eranian209045a2015-11-30 10:02:22 +010029
30#if defined(__cplusplus)
31}
32
33#endif
34#endif /* __JVMTI_H__ */