X-Git-Url: http://git.efficios.com/?p=lttng-tools.git;a=blobdiff_plain;f=src%2Flib%2Flttng-ctl%2Ffilter%2Ffilter-bytecode.h;h=053bb08bb5ef2a2b6d0589ba447d541f1d4f3694;hp=627d0d6f0b6f58943b7326b8c59ba019f8682f11;hb=25357057de5ae4dd2a572e8f9b893c1b90cbd60a;hpb=9f449915b9d44ce3c9c9255f5d491a62545fee25 diff --git a/src/lib/lttng-ctl/filter/filter-bytecode.h b/src/lib/lttng-ctl/filter/filter-bytecode.h index 627d0d6f0..053bb08bb 100644 --- a/src/lib/lttng-ctl/filter/filter-bytecode.h +++ b/src/lib/lttng-ctl/filter/filter-bytecode.h @@ -6,23 +6,14 @@ * * LTTng filter bytecode * - * Copyright 2012 - Mathieu Desnoyers + * Copyright 2012 Mathieu Desnoyers * - * This library is free software; you can redistribute it and/or modify it - * under the terms of the GNU Lesser General Public License, version 2.1 only, - * as published by the Free Software Foundation. + * SPDX-License-Identifier: LGPL-2.1-only * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public License - * along with this library; if not, write to the Free Software Foundation, - * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA */ #include +#include #include "filter-ast.h" @@ -35,6 +26,19 @@ struct field_ref { uint16_t offset; } LTTNG_PACKED; +struct get_symbol { + /* Symbol offset. */ + uint16_t offset; +} LTTNG_PACKED; + +struct get_index_u16 { + uint16_t index; +} LTTNG_PACKED; + +struct get_index_u64 { + uint64_t index; +} LTTNG_PACKED; + struct literal_numeric { int64_t v; } LTTNG_PACKED; @@ -58,11 +62,11 @@ enum filter_op { FILTER_OP_MOD = 4, FILTER_OP_PLUS = 5, FILTER_OP_MINUS = 6, - FILTER_OP_RSHIFT = 7, - FILTER_OP_LSHIFT = 8, - FILTER_OP_BIN_AND = 9, - FILTER_OP_BIN_OR = 10, - FILTER_OP_BIN_XOR = 11, + FILTER_OP_BIT_RSHIFT = 7, + FILTER_OP_BIT_LSHIFT = 8, + FILTER_OP_BIT_AND = 9, + FILTER_OP_BIT_OR = 10, + FILTER_OP_BIT_XOR = 11, /* binary comparators */ FILTER_OP_EQ = 12, @@ -163,6 +167,35 @@ enum filter_op { FILTER_OP_EQ_STAR_GLOB_STRING = 77, FILTER_OP_NE_STAR_GLOB_STRING = 78, + /* + * Instructions for recursive traversal through composed types. + */ + FILTER_OP_GET_CONTEXT_ROOT = 79, + FILTER_OP_GET_APP_CONTEXT_ROOT = 80, + FILTER_OP_GET_PAYLOAD_ROOT = 81, + + FILTER_OP_GET_SYMBOL = 82, + FILTER_OP_GET_SYMBOL_FIELD = 83, + FILTER_OP_GET_INDEX_U16 = 84, + FILTER_OP_GET_INDEX_U64 = 85, + + FILTER_OP_LOAD_FIELD = 86, + FILTER_OP_LOAD_FIELD_S8 = 87, + FILTER_OP_LOAD_FIELD_S16 = 88, + FILTER_OP_LOAD_FIELD_S32 = 89, + FILTER_OP_LOAD_FIELD_S64 = 90, + FILTER_OP_LOAD_FIELD_U8 = 91, + FILTER_OP_LOAD_FIELD_U16 = 92, + FILTER_OP_LOAD_FIELD_U32 = 93, + FILTER_OP_LOAD_FIELD_U64 = 94, + FILTER_OP_LOAD_FIELD_STRING = 95, + FILTER_OP_LOAD_FIELD_SEQUENCE = 96, + FILTER_OP_LOAD_FIELD_DOUBLE = 97, + + FILTER_OP_UNARY_BIT_NOT = 98, + + FILTER_OP_RETURN_S64 = 99, + NR_FILTER_OPS, };