#include <errno.h>
#include <stdio.h>
#include <stdbool.h>
-#include <helper.h>
+#include <ust-helper.h>
#include <lttng/ust-events.h>
-#include <lttng/ust-context-provider.h>
+#include <ust-context-provider.h>
#include <stdint.h>
#include <assert.h>
#include <errno.h>
#include <limits.h>
#include <usterr-signal-safe.h>
#include "bytecode.h"
+#include "ust-events-internal.h"
/* Interpreter stack length, in number of entries */
#define INTERPRETER_STACK_LEN 10 /* includes 2 dummy */
/* Linked bytecode. Child of struct lttng_bytecode_runtime. */
struct bytecode_runtime {
- struct lttng_bytecode_runtime p;
+ struct lttng_ust_bytecode_runtime p;
size_t data_len;
size_t data_alloc_len;
char *data;
* interpreter needs to find it from the event fields and types to
* support variants.
*/
- const struct lttng_event_field *field;
+ const struct lttng_ust_event_field *field;
struct {
size_t len;
enum object_type type;
struct vstack_load {
enum load_type type;
enum object_type object_type;
- const struct lttng_event_field *field;
+ const struct lttng_ust_event_field *field;
bool rev_bo; /* reverse byte order */
};
uint64_t u64;
double d;
} u;
- const struct lttng_event_field *field;
+ const struct lttng_ust_event_field *field;
};
struct estack_entry {
size_t nr_elem;
/* Inner type. */
- const struct lttng_type *nested_type;
+ const struct lttng_ust_type_common *nested_type;
} sequence;
} u;
};
-/* Should be hidden but would break the ABI */
-const char *print_op(enum bytecode_op op);
-
-LTTNG_HIDDEN
-void lttng_bytecode_filter_sync_state(struct lttng_bytecode_runtime *runtime);
-LTTNG_HIDDEN
-void lttng_bytecode_capture_sync_state(struct lttng_bytecode_runtime *runtime);
-
-LTTNG_HIDDEN
-int lttng_bytecode_validate(struct bytecode_runtime *bytecode);
-LTTNG_HIDDEN
-int lttng_bytecode_specialize(const struct lttng_event_desc *event_desc,
- struct bytecode_runtime *bytecode);
-
-LTTNG_HIDDEN
-uint64_t lttng_bytecode_filter_interpret_false(void *filter_data,
- const char *filter_stack_data);
-LTTNG_HIDDEN
-uint64_t lttng_bytecode_filter_interpret(void *filter_data,
- const char *filter_stack_data);
-
-LTTNG_HIDDEN
-uint64_t lttng_bytecode_capture_interpret_false(void *capture_data,
- const char *capture_stack_data,
- struct lttng_interpreter_output *output);
-LTTNG_HIDDEN
-uint64_t lttng_bytecode_capture_interpret(void *capture_data,
- const char *capture_stack_data,
- struct lttng_interpreter_output *output);
+const char *lttng_bytecode_print_op(enum bytecode_op op)
+ __attribute__((visibility("hidden")));
+
+void lttng_bytecode_sync_state(struct lttng_ust_bytecode_runtime *runtime)
+ __attribute__((visibility("hidden")));
+
+int lttng_bytecode_validate(struct bytecode_runtime *bytecode)
+ __attribute__((visibility("hidden")));
+
+int lttng_bytecode_specialize(const struct lttng_ust_event_desc *event_desc,
+ struct bytecode_runtime *bytecode)
+ __attribute__((visibility("hidden")));
+
+int lttng_bytecode_interpret_error(struct lttng_ust_bytecode_runtime *bytecode_runtime,
+ const char *stack_data,
+ void *ctx)
+ __attribute__((visibility("hidden")));
+
+int lttng_bytecode_interpret(struct lttng_ust_bytecode_runtime *bytecode_runtime,
+ const char *stack_data,
+ void *ctx)
+ __attribute__((visibility("hidden")));
#endif /* _LTTNG_BYTECODE_H */