Home
last modified time | relevance | path

Searched refs:sval_t (Results 1 – 25 of 94) sorted by relevance

1234

/illumos-gate/usr/src/tools/smatch/src/
H A Dsmatch_sval.c33 __ALLOCATOR(sval_t, "svals", sval);
35 sval_t *sval_alloc(sval_t sval) in sval_alloc()
37 sval_t *ret; in sval_alloc()
44 sval_t *sval_alloc_permanent(sval_t sval) in sval_alloc_permanent()
46 sval_t *ret; in sval_alloc_permanent()
53 sval_t sval_blank(struct expression *expr) in sval_blank()
55 sval_t ret; in sval_blank()
65 sval_t sval_type_val(struct symbol *type, long long val) in sval_type_val()
67 sval_t ret; in sval_type_val()
77 sval_t sval_type_fval(struct symbol *type, long double fval) in sval_type_fval()
[all …]
H A Dsmatch.h45 } sval_t; typedef
192 void return_implies_state_sval(const char *look_for, sval_t start, sval_t end,
406 int get_const_value(struct expression *expr, sval_t *sval);
407 int get_value(struct expression *expr, sval_t *val);
408 int get_implied_value(struct expression *expr, sval_t *val);
409 int get_implied_value_fast(struct expression *expr, sval_t *sval);
410 int get_implied_min(struct expression *expr, sval_t *sval);
411 int get_implied_max(struct expression *expr, sval_t *val);
412 int get_hard_max(struct expression *expr, sval_t *sval);
413 int get_fuzzy_min(struct expression *expr, sval_t *min);
[all …]
H A Dsmatch_extra.h31 sval_t fuzzy_max;
49 struct data_range *alloc_range(sval_t min, sval_t max);
50 struct data_range *alloc_range_perm(sval_t min, sval_t max);
54 struct range_list *alloc_rl(sval_t min, sval_t max);
59 void add_range(struct range_list **list, sval_t min, sval_t max);
60 struct range_list *remove_range(struct range_list *list, sval_t min, sval_t max);
75 int rl_has_sval(struct range_list *rl, sval_t sval);
78 bool is_err_ptr(sval_t sval);
86 sval_t rl_min(struct range_list *rl);
87 sval_t rl_max(struct range_list *rl);
[all …]
H A Dsmatch_math.c23 …struct expression *expr, int implied, int *recurse_cnt, struct range_list **res, sval_t *sval_res);
25 …struct expression *expr, int implied, int *recurse_cnt, struct range_list **res, sval_t *res_sval);
28 static bool get_implied_value_internal(struct expression *expr, int *recurse_cnt, sval_t *res_sval);
31 static sval_t zero = {.type = &int_ctype, {.value = 0} };
32 static sval_t one = {.type = &int_ctype, {.value = 1} };
64 …l(struct statement *stmt, int implied, int *recurse_cnt, struct range_list **res, sval_t *res_sval) in last_stmt_rl()
87 int *recurse_cnt, struct range_list **res, sval_t *res_sval) in handle_expression_statement_rl()
92 …(struct expression *expr, int implied, int *recurse_cnt, struct range_list **res, sval_t *res_sval) in handle_address()
96 sval_t sval; in handle_address()
126 …(struct expression *expr, int implied, int *recurse_cnt, struct range_list **res, sval_t *res_sval) in handle_ampersand_rl()
[all …]
H A Dsmatch_ranges.c29 bool is_err_ptr(sval_t sval) in is_err_ptr()
108 static int sval_too_big(struct symbol *type, sval_t sval) in sval_too_big()
132 static int truncates_nicely(struct symbol *type, sval_t min, sval_t max) in truncates_nicely()
147 static void add_range_t(struct symbol *type, struct range_list **rl, sval_t min, sval_t max) in add_range_t()
300 …_max, struct symbol *type, const char *c, struct expression *call, const char **endp, sval_t *sval) in get_val_from_key()
304 sval_t ret, tmp; in get_val_from_key()
335 static sval_t add_one(sval_t sval) in add_one()
341 static sval_t sub_one(sval_t sval) in sub_one()
353 sval_t min, max; in filter_by_comparison()
433 static sval_t parse_val(int use_max, struct expression *call, struct symbol *type, const char *c, c… in parse_val()
[all …]
H A Dsmatch_estate.c86 sval_t estate_get_fuzzy_max(struct smatch_state *state) in estate_get_fuzzy_max()
88 sval_t empty = {}; in estate_get_fuzzy_max()
102 void estate_set_fuzzy_max(struct smatch_state *state, sval_t fuzzy_max) in estate_set_fuzzy_max()
118 sval_t empty = {}; in estate_clear_fuzzy_max()
143 int estate_get_hard_max(struct smatch_state *state, sval_t *sval) in estate_get_hard_max()
195 sval_t estate_min(struct smatch_state *state) in estate_min()
200 sval_t estate_max(struct smatch_state *state) in estate_max()
277 int estate_get_single_value(struct smatch_state *state, sval_t *sval) in estate_get_single_value()
279 sval_t min, max; in estate_get_single_value()
300 static struct data_info *alloc_dinfo_range(sval_t min, sval_t max) in alloc_dinfo_range()
[all …]
H A Dcheck_index_overflow.c30 sval_t sval; in definitely_just_used_as_limiter()
47 static int fake_get_hard_max(struct expression *expr, sval_t *sval) in fake_get_hard_max()
69 static int get_the_max(struct expression *expr, sval_t *sval) in get_the_max()
105 static int common_false_positives(struct expression *array, sval_t max) in common_false_positives()
209 sval_t hard_max = { .type = &int_ctype, }; in should_warn()
210 sval_t fuzzy_max = { .type = &int_ctype, }; in should_warn()
213 sval_t max; in should_warn()
267 sval_t hard_max = { .type = &int_ctype, }; in array_check()
268 sval_t fuzzy_max = { .type = &int_ctype, }; in array_check()
272 sval_t max; in array_check()
H A Dcheck_signed.c37 sval_t sval; in match_assign()
38 sval_t max; in match_assign()
39 sval_t min; in match_assign()
95 sval_t known; in cap_gt_zero_and_lt()
143 sval_t known; in cap_lt_zero_or_gt()
203 sval_t known; in compare_against_macro()
215 sval_t known; in print_unsigned_never_less_than_zero()
233 sval_t known; in match_condition()
234 sval_t min, max; in match_condition()
H A Dsmatch_buf_size.c65 sval_t sval; in estate_to_size()
75 sval_t sval; in size_to_estate()
85 sval_t sval; in size_to_rl()
272 sval_t sval; in db_returns_buf_size()
287 sval_t sval; in get_real_array_size_from_type()
354 sval_t sval; in remove_addr_fluff()
400 sval_t sval; in last_member_is_resizable()
465 sval_t sval = { in alloc_int_rl()
476 sval_t sval; in get_array_size_bytes_rl()
488 sval_t offset; in get_array_size_bytes_rl()
[all …]
H A Dcheck_err_ptr_deref.c27 static sval_t err_ptr_min = {
32 static sval_t err_ptr_max = {
176 sval_t sval; in match_err_ptr_positive_const()
191 sval_t tmp_min; in match_err_ptr()
192 sval_t tmp_max; in match_err_ptr()
193 sval_t min = sval_type_max(&llong_ctype); in match_err_ptr()
194 sval_t max = sval_type_min(&llong_ctype); in match_err_ptr()
H A Dsmatch_extra.c577 sval_t sval; in set_extra_expr_true_false()
596 … get_countdown_info(struct expression *condition, struct expression **unop, int *op, sval_t *right) in get_countdown_info()
600 sval_t limit; in get_countdown_info()
647 sval_t start, right; in handle_canonical_while_count_down()
704 sval_t start, end, max; in handle_canonical_for_inc()
758 sval_t start, end; in handle_canonical_for_dec()
851 sval_t limit, after_value; in while_count_down_after()
865 sval_t limit; in __extra_pre_loop_hook_after()
897 sval_t hmax = estate_get_fuzzy_max(sm->state); in __extra_pre_loop_hook_after()
898 sval_t max = estate_max(sm->state); in __extra_pre_loop_hook_after()
[all …]
H A Dcheck_kernel.c26 static sval_t err_ptr_min;
27 static sval_t err_ptr_max;
28 static sval_t null_ptr;
47 sval_t low_error; in hack_ERR_PTR()
48 sval_t minus_one; in hack_ERR_PTR()
49 sval_t zero; in hack_ERR_PTR()
210 sval_t min, max, tmp; in match_next_bit()
236 sval_t zero = {}; in match_fls()
237 sval_t start, end, sval; in match_fls()
H A Dcheck_arm64_tagged.c132 int rl_is_larger_or_equal(struct range_list *rl, sval_t sval) in rl_is_larger_or_equal()
143 int rl_range_has_min_value(struct range_list *rl, sval_t sval) in rl_range_has_min_value()
157 sval_t invalid; in rl_is_tagged()
158 sval_t invalid_kernel; in rl_is_tagged()
H A Dcheck_shift_to_zero.c25 sval_t bits; in match_binop()
47 sval_t mask, shift; in match_binop2()
73 sval_t bits; in match_assign()
H A Dsmatch_capped.c72 sval_t dummy; in is_capped()
97 sval_t sval; in is_capped()
150 sval_t sval; in match_condition()
222 sval_t sval; in match_caller_info()
239 sval_t sval; in struct_member_callback()
257 sval_t sval; in print_return_implies_capped()
H A Dcheck_impossible_mask.c25 sval_t sval;
66 sval_t sval; in get_possible_bits()
82 sval_t sval; in match_condition()
H A Dsmatch_common_functions.c48 sval_t fixed; in match_strnlen()
49 sval_t bound; in match_strnlen()
50 sval_t ulong_max = sval_type_val(&ulong_ctype, ULONG_MAX); in match_strnlen()
H A Dsmatch_strlen.c38 sval_t sval; in size_to_estate()
102 sval_t sval; in match_strlen_condition()
169 sval_t limit_size; in match_snprintf()
189 sval_t limit; in match_strlcpycat()
225 sval_t sval; in get_strlen_from_string()
280 sval_t max; in get_size_from_strlen()
H A Dsmatch_mtag.c97 sval_t sval; in get_allocator_info()
133 sval_t tag_sval; in get_mtag_return()
236 sval_t sval; in get_array_mtag_offset()
267 sval_t sval; in swap_mtag_seed()
314 sval_t sval; in get_implied_mtag_offset()
404 int get_mtag_sval(struct expression *expr, sval_t *sval) in get_mtag_sval()
H A Dcheck_bit_shift.c35 sval_t expr_value; in get_shifter()
118 sval_t sval; in match_binop_info()
138 sval_t sval; in match_call()
H A Dsmatch_parse_call_math.c170 sval_t sval; in read_var_num()
247 int parse_call_math(struct expression *call, char *math, sval_t *sval) in parse_call_math()
347 static int is_mtag_sval(sval_t sval) in is_mtag_sval()
359 sval_t sval; in format_expr_helper()
423 sval_t dummy; in get_value_in_terms_of_parameter_math()
448 sval_t sval; in get_value_in_terms_of_parameter_math_var_sym()
489 sval_t sval; in swap_format()
H A Dsmatch_bits.c60 sval_t sval; in rl_to_binfo()
247 sval_t known; in get_bit_info()
289 static int is_single_bit(sval_t sval) in is_single_bit()
306 sval_t val; in match_compare()
354 sval_t right; in match_condition()
425 sval_t sval; in struct_member_callback()
H A Dsmatch_type.c167 sval_t sval; in handle__builtin_choose_expr()
444 static sval_t fp_max(struct symbol *type) in fp_max()
446 sval_t ret = { .type = type }; in fp_max()
458 sval_t sval_type_max(struct symbol *base_type) in sval_type_max()
460 sval_t ret; in sval_type_max()
473 static sval_t fp_min(struct symbol *type) in fp_min()
475 sval_t ret = { .type = type }; in fp_min()
487 sval_t sval_type_min(struct symbol *base_type) in sval_type_min()
489 sval_t ret; in sval_type_min()
H A Dcheck_or_vs_and.c44 sval_t sval; in inconsistent_check()
143 sval_t sval; in match_condition()
168 sval_t left, right, sval; in match_binop()
H A Dcheck_snprintf.c33 sval_t buflen; in match_snprintf()
59 sval_t max; in match_call()

1234