X-Git-Url: http://git.lttng.org/?a=blobdiff_plain;f=include%2Flttng%2Fust-events.h;h=44b8d4c4878819d57b2a13b7130e9c28862540d7;hb=d37ecb3fc622dee6f80f84c21f38d32eef407262;hp=7fa992efd77d86a93464e73336c596703f773a4f;hpb=a56fd376c76b448c9f639b8ace821471a2fb7b40;p=lttng-ust.git diff --git a/include/lttng/ust-events.h b/include/lttng/ust-events.h index 7fa992ef..44b8d4c4 100644 --- a/include/lttng/ust-events.h +++ b/include/lttng/ust-events.h @@ -315,6 +315,7 @@ struct lttng_ctx_value { enum lttng_ust_dynamic_type sel; union { int64_t s64; + uint64_t u64; const char *str; double d; } u; @@ -426,14 +427,16 @@ struct ust_pending_probe; struct lttng_event; /* - * Filter return value masks. + * Bytecode interpreter return value masks. */ -enum lttng_filter_ret { - LTTNG_FILTER_DISCARD = 0, - LTTNG_FILTER_RECORD_FLAG = (1ULL << 0), +enum lttng_bytecode_interpreter_ret { + LTTNG_INTERPRETER_DISCARD = 0, + LTTNG_INTERPRETER_RECORD_FLAG = (1ULL << 0), /* Other bits are kept for future use. */ }; +struct lttng_interpreter_output; + /* * This structure is used in the probes. More specifically, the `filter` and * `node` fields are explicity used in the probes. When modifying this @@ -442,8 +445,14 @@ enum lttng_filter_ret { */ struct lttng_bytecode_runtime { /* Associated bytecode */ - struct lttng_ust_filter_bytecode_node *bc; - uint64_t (*filter)(void *filter_data, const char *filter_stack_data); + struct lttng_ust_bytecode_node *bc; + union { + uint64_t (*filter)(void *interpreter_data, + const char *interpreter_stack_data); + uint64_t (*capture)(void *interpreter_data, + const char *interpreter_stack_data, + struct lttng_interpreter_output *interpreter_output); + } interpreter_funcs; int link_failed; struct cds_list_head node; /* list of bytecode runtime in event */ /* @@ -503,7 +512,9 @@ struct lttng_event_notifier { uint64_t user_token; int enabled; int registered; /* has reg'd tracepoint probe */ + size_t num_captures; /* Needed to allocate the msgpack array. */ struct cds_list_head filter_bytecode_runtime_head; + struct cds_list_head capture_bytecode_runtime_head; int has_enablers_without_bytecode; struct cds_list_head enablers_ref_head; const struct lttng_event_desc *desc; @@ -691,7 +702,8 @@ int lttng_session_statedump(struct lttng_session *session); void lttng_session_destroy(struct lttng_session *session); void lttng_event_notifier_notification_send( - struct lttng_event_notifier *event_notifier); + struct lttng_event_notifier *event_notifier, + const char *stack_data); struct lttng_channel *lttng_channel_create(struct lttng_session *session, const char *transport_name, @@ -709,8 +721,6 @@ int lttng_channel_disable(struct lttng_channel *channel); int lttng_attach_context(struct lttng_ust_context *context_param, union ust_args *uargs, struct lttng_ctx **ctx, struct lttng_session *session); -int lttng_session_context_init(struct lttng_ctx **ctx); - void lttng_transport_register(struct lttng_transport *transport); void lttng_transport_unregister(struct lttng_transport *transport); @@ -811,7 +821,6 @@ struct lttng_ust_field_iter * lttng_ust_field_list_get_iter_next(struct lttng_ust_field_list *list); void lttng_free_event_filter_runtime(struct lttng_event *event); -void lttng_filter_sync_state(struct lttng_bytecode_runtime *runtime); struct cds_list_head *lttng_get_probe_list_head(void); int lttng_session_active(void); @@ -847,6 +856,9 @@ int lttng_enabler_attach_exclusion(struct lttng_enabler *enabler, struct lttng_ust_excluder_node *excluder); void lttng_enabler_event_link_bytecode(struct lttng_event *event, struct lttng_enabler *enabler); +void lttng_filter_sync_state(struct lttng_bytecode_runtime *runtime); +int lttng_session_context_init(struct lttng_ctx **ctx); + #ifdef __cplusplus }