• Home
  • Raw
  • Download

Lines Matching refs:expr

512 	char		*expr[TRACING_MAP_VARS_MAX];  member
1717 static void expr_field_str(struct hist_field *field, char *expr) in expr_field_str() argument
1720 strcat(expr, "$"); in expr_field_str()
1725 strcat(expr, str); in expr_field_str()
1728 strcat(expr, hist_field_name(field, 0)); in expr_field_str()
1734 strcat(expr, "."); in expr_field_str()
1735 strcat(expr, flags_str); in expr_field_str()
1742 char *expr; in expr_str() local
1747 expr = kzalloc(MAX_FILTER_STR_VAL, GFP_KERNEL); in expr_str()
1748 if (!expr) in expr_str()
1752 expr_field_str(field, expr); in expr_str()
1753 return expr; in expr_str()
1759 strcat(expr, "-("); in expr_str()
1762 kfree(expr); in expr_str()
1765 strcat(expr, subexpr); in expr_str()
1766 strcat(expr, ")"); in expr_str()
1770 return expr; in expr_str()
1773 expr_field_str(field->operands[0], expr); in expr_str()
1777 strcat(expr, "-"); in expr_str()
1780 strcat(expr, "+"); in expr_str()
1783 strcat(expr, "/"); in expr_str()
1786 strcat(expr, "*"); in expr_str()
1789 kfree(expr); in expr_str()
1793 expr_field_str(field->operands[1], expr); in expr_str()
1795 return expr; in expr_str()
2218 field = hist_data->attrs->var_defs.expr[i]; in field_name_from_var()
2501 struct hist_field *operand1, *expr = NULL; in parse_unary() local
2544 expr = create_hist_field(hist_data, NULL, flags, var_name); in parse_unary()
2545 if (!expr) { in parse_unary()
2564 expr->flags |= operand1->flags & in parse_unary()
2566 expr->fn_num = HIST_FIELD_FN_UMINUS; in parse_unary()
2567 expr->operands[0] = operand1; in parse_unary()
2568 expr->size = operand1->size; in parse_unary()
2569 expr->is_signed = operand1->is_signed; in parse_unary()
2570 expr->operator = FIELD_OP_UNARY_MINUS; in parse_unary()
2571 expr->name = expr_str(expr, 0); in parse_unary()
2572 expr->type = kstrdup_const(operand1->type, GFP_KERNEL); in parse_unary()
2573 if (!expr->type) { in parse_unary()
2578 return expr; in parse_unary()
2580 destroy_hist_field(expr, 0); in parse_unary()
2633 struct hist_field *operand1 = NULL, *operand2 = NULL, *expr = NULL; in parse_expr() local
2731 expr = create_hist_field(hist_data, NULL, flags, var_name); in parse_expr()
2732 if (!expr) { in parse_expr()
2741 expr->operands[0] = operand1; in parse_expr()
2742 expr->operands[1] = operand2; in parse_expr()
2762 expr->fn_num = op_fn; in parse_expr()
2766 expr->operands[0] = var1; in parse_expr()
2768 expr->operands[1] = var2; in parse_expr()
2770 expr->constant = hist_fn_call(expr, NULL, NULL, NULL, NULL); in parse_expr()
2771 expr->fn_num = HIST_FIELD_FN_CONST; in parse_expr()
2773 expr->operands[0] = NULL; in parse_expr()
2774 expr->operands[1] = NULL; in parse_expr()
2783 expr->name = expr_str(expr, 0); in parse_expr()
2786 expr->size = operand1->size; in parse_expr()
2787 expr->is_signed = operand1->is_signed; in parse_expr()
2789 expr->operator = field_op; in parse_expr()
2790 expr->type = kstrdup_const(operand1->type, GFP_KERNEL); in parse_expr()
2791 if (!expr->type) { in parse_expr()
2796 expr->name = expr_str(expr, 0); in parse_expr()
2799 return expr; in parse_expr()
2808 destroy_hist_field(expr, 0); in parse_expr()
4509 char *expr = hist_data->attrs->var_defs.expr[i]; in create_var_fields() local
4511 ret = create_var_field(hist_data, j++, file, var_name, expr); in create_var_fields()
4525 kfree(hist_data->attrs->var_defs.expr[i]); in free_var_defs()
4573 hist_data->attrs->var_defs.expr[n_vars++] = s; in parse_var_defs()