From 34cc6d00668c51d0cb8f1959a2e38a56b147a6c9 Mon Sep 17 00:00:00 2001 From: Mathieu Desnoyers Date: Mon, 16 Jul 2012 11:18:14 -0400 Subject: [PATCH] Filter: cleanup macros Signed-off-by: Mathieu Desnoyers --- liblttng-ust/lttng-filter.c | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/liblttng-ust/lttng-filter.c b/liblttng-ust/lttng-filter.c index f9d512c9..fa306f07 100644 --- a/liblttng-ust/lttng-filter.c +++ b/liblttng-ust/lttng-filter.c @@ -275,20 +275,20 @@ int lttng_filter_false(void *filter_data, * Fallback for compilers that do not support taking address of labels. */ -#define START_OP \ - start_pc = &bytecode->data[0]; \ - for (pc = next_pc = start_pc; pc - start_pc < bytecode->len; \ - pc = next_pc) { \ - dbg_printf("Executing op %s (%u)\n", \ +#define START_OP \ + start_pc = &bytecode->data[0]; \ + for (pc = next_pc = start_pc; pc - start_pc < bytecode->len; \ + pc = next_pc) { \ + dbg_printf("Executing op %s (%u)\n", \ print_op((unsigned int) *(filter_opcode_t *) pc), \ - (unsigned int) *(filter_opcode_t *) pc); \ - switch (*(filter_opcode_t *) pc) { + (unsigned int) *(filter_opcode_t *) pc); \ + switch (*(filter_opcode_t *) pc) { #define OP(name) case name #define PO break -#define END_OP } \ +#define END_OP } \ } #else @@ -297,18 +297,18 @@ int lttng_filter_false(void *filter_data, * Dispatch-table based interpreter. */ -#define START_OP \ - start_pc = &bytecode->data[0]; \ - pc = next_pc = start_pc; \ - if (unlikely(pc - start_pc >= bytecode->len)) \ - goto end; \ +#define START_OP \ + start_pc = &bytecode->data[0]; \ + pc = next_pc = start_pc; \ + if (unlikely(pc - start_pc >= bytecode->len)) \ + goto end; \ goto *dispatch[*(filter_opcode_t *) pc]; -#define OP(name) \ +#define OP(name) \ LABEL_##name -#define PO \ - pc = next_pc; \ +#define PO \ + pc = next_pc; \ goto *dispatch[*(filter_opcode_t *) pc]; #define END_OP -- 2.34.1