Home
last modified time | relevance | path

Searched refs:max (Results 1 – 25 of 249) sorted by relevance

12345678910

/PHP-7.2/ext/standard/tests/array/
H A Dmax_variation2.phpt2 Test variations in usage of max()
12 var_dump(max(array(2,1,2)));
13 var_dump(max(array(-2,1,2)));
14 var_dump(max(array(2.1,2.11,2.09)));
15 var_dump(max(array("", "t", "b")));
16 var_dump(max(array(false, true, false)));
17 var_dump(max(array(true, false, true)));
18 var_dump(max(array(1, true, false, true)));
19 var_dump(max(array(0, true, false, true)));
20 var_dump(max(array(0, 1, array(2,3))));
[all …]
H A Dmax.phpt2 max() tests
8 var_dump(max());
9 var_dump(max(1));
10 var_dump(max(array()));
11 var_dump(max(new stdclass));
12 var_dump(max(2,1,2));
13 var_dump(max(2.1,2.11,2.09));
14 var_dump(max("", "t", "b"));
15 var_dump(max(false, true, false));
16 var_dump(max(true, false, true));
[all …]
H A Dmax_basic.phpt2 Test return type and value for expected input max()
6 * proto mixed max(mixed arg1 [, mixed arg2 [, mixed ...]])
12 var_dump(max(2,1,2));
13 var_dump(max(-2,1,2));
14 var_dump(max(2.1,2.11,2.09));
15 var_dump(max("", "t", "b"));
16 var_dump(max(false, true, false));
17 var_dump(max(true, false, true));
18 var_dump(max(1, true, false, true));
19 var_dump(max(0, true, false, true));
[all …]
H A Dmax_variation1.phpt2 Test variations in usage of max()
6 * proto mixed max(mixed arg1 [, mixed arg2 [, mixed ...]])
11 var_dump(max(2147483645, 2147483646) );
12 var_dump(max(2147483647, 2147483648) );
13 var_dump(max(2147483646, 2147483648) );
14 var_dump(max(-2147483647, -2147483646) );
15 var_dump(max(-2147483648, -2147483647) );
16 var_dump(max(-2147483649, -2147483647) );
20 var_dump(max(0, 1 , 2, 3, 4, 5, 6, 7, 8, 9, 0, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20,0, 1 , 2,…
H A Dmax_error.phpt13 var_dump(max());
14 var_dump(max(1));
15 var_dump(max(array()));
16 var_dump(max(new stdclass));
22 Warning: max() expects at least 1 parameter, 0 given in %s on line 10
25 Warning: max(): When only one parameter is given, it must be an array in %s on line 11
28 Warning: max(): Array must contain at least one element in %s on line 12
31 Warning: max(): When only one parameter is given, it must be an array in %s on line 13
/PHP-7.2/ext/standard/tests/math/
H A Dmt_rand_basic.phpt32 $max = array(100,
44 echo "FAILED: res = ", $res, " min = ", intval($min[$x]), " max = ", intval($max[$x]), "\n";
50 echo "PASSED: range min = ", intval($min[$x]), " max = ", intval($max[$x]), "\n";
72 echo "FAILED: res = ", $res, " min = ", intval($min[$x]), " max = ", intval($max[$x]), "\n";
87 PASSED: range min = 10 max = 100
89 PASSED: range min = 10 max = 19
95 PASSED range min = 1 max = 100
96 PASSED range min = 0 max = 100
97 PASSED range min = 0 max = 100
98 PASSED range min = 10 max = 100
[all …]
H A Drand_basic.phpt32 $max = array(100,
41 $res = rand($min[$x], $max[$x]);
44 echo "FAILED: res = ", $res, " min = ", intval($min[$x]), " max = ", intval($max[$x]), "\n";
50 echo "PASSED: range min = ", intval($min[$x]), " max = ", intval($max[$x]), "\n";
84 PASSED: range min = 0 max = %i
89 PASSED: range min = 10 max = 19
95 PASSED range min = 1 max = 100
96 PASSED range min = 0 max = 100
97 PASSED range min = 0 max = 100
98 PASSED range min = 10 max = 100
[all …]
H A Dbug75170.phpt11 $max = 0x66666666;
14 $halves[(mt_rand(0, $max - 1) >> 1) & 1]++;
22 $max = 0x66666666;
25 $halves[mt_rand(0, $max - 1) / ($max / 2)]++;
/PHP-7.2/sapi/fpm/fpm/events/
H A Ddevpoll.c35 static int fpm_event_devpoll_init(int max);
73 static int fpm_event_devpoll_init(int max) /* {{{ */ in fpm_event_devpoll_init() argument
84 if (max < 1) { in fpm_event_devpoll_init()
89 pollfds = malloc(sizeof(struct pollfd) * max); in fpm_event_devpoll_init()
91 zlog(ZLOG_ERROR, "poll: unable to allocate %d events", max); in fpm_event_devpoll_init()
94 memset(pollfds, 0, sizeof(struct pollfd) * max); in fpm_event_devpoll_init()
97 for (i = 0; i < max; i++) { in fpm_event_devpoll_init()
102 active_pollfds = malloc(sizeof(struct pollfd) * max); in fpm_event_devpoll_init()
105 zlog(ZLOG_ERROR, "poll: unable to allocate %d events", max); in fpm_event_devpoll_init()
108 memset(active_pollfds, 0, sizeof(struct pollfd) * max); in fpm_event_devpoll_init()
[all …]
H A Dpoll.c32 static int fpm_event_poll_init(int max);
72 static int fpm_event_poll_init(int max) /* {{{ */ in fpm_event_poll_init() argument
76 if (max < 1) { in fpm_event_poll_init()
81 pollfds = malloc(sizeof(struct pollfd) * max); in fpm_event_poll_init()
83 zlog(ZLOG_ERROR, "poll: unable to allocate %d events", max); in fpm_event_poll_init()
86 memset(pollfds, 0, sizeof(struct pollfd) * max); in fpm_event_poll_init()
89 for (i = 0; i < max; i++) { in fpm_event_poll_init()
94 active_pollfds = malloc(sizeof(struct pollfd) * max); in fpm_event_poll_init()
97 zlog(ZLOG_ERROR, "poll: unable to allocate %d events", max); in fpm_event_poll_init()
100 memset(active_pollfds, 0, sizeof(struct pollfd) * max); in fpm_event_poll_init()
[all …]
H A Depoll.c31 static int fpm_event_epoll_init(int max);
68 static int fpm_event_epoll_init(int max) /* {{{ */ in fpm_event_epoll_init() argument
70 if (max < 1) { in fpm_event_epoll_init()
75 epollfd = epoll_create(max + 1); in fpm_event_epoll_init()
82 epollfds = malloc(sizeof(struct epoll_event) * max); in fpm_event_epoll_init()
84 zlog(ZLOG_ERROR, "epoll: unable to allocate %d events", max); in fpm_event_epoll_init()
87 memset(epollfds, 0, sizeof(struct epoll_event) * max); in fpm_event_epoll_init()
90 nepollfds = max; in fpm_event_epoll_init()
H A Dkqueue.c34 static int fpm_event_kqueue_init(int max);
74 static int fpm_event_kqueue_init(int max) /* {{{ */ in fpm_event_kqueue_init() argument
76 if (max < 1) { in fpm_event_kqueue_init()
86 kevents = malloc(sizeof(struct kevent) * max); in fpm_event_kqueue_init()
88 zlog(ZLOG_ERROR, "epoll: unable to allocate %d events", max); in fpm_event_kqueue_init()
92 memset(kevents, 0, sizeof(struct kevent) * max); in fpm_event_kqueue_init()
94 nkevents = max; in fpm_event_kqueue_init()
H A Dport.c32 static int fpm_event_port_init(int max);
69 static int fpm_event_port_init(int max) /* {{{ */ in fpm_event_port_init() argument
78 if (max < 1) { in fpm_event_port_init()
83 events = malloc(sizeof(port_event_t) * max); in fpm_event_port_init()
85 zlog(ZLOG_ERROR, "port: Unable to allocate %d events", max); in fpm_event_port_init()
89 nevents = max; in fpm_event_port_init()
/PHP-7.2/ext/standard/
H A Drand.c53 zend_long max; in PHP_FUNCTION() local
62 Z_PARAM_LONG(max) in PHP_FUNCTION()
65 if (max < min) { in PHP_FUNCTION()
66 RETURN_LONG(php_mt_rand_common(max, min)); in PHP_FUNCTION()
69 RETURN_LONG(php_mt_rand_common(min, max)); in PHP_FUNCTION()
H A Dphp_random.h37 #define php_random_int_throw(min, max, result) \ argument
38 php_random_int((min), (max), (result), 1)
39 #define php_random_int_silent(min, max, result) \ argument
40 php_random_int((min), (max), (result), 0)
43 PHPAPI int php_random_int(zend_long min, zend_long max, zend_long *result, zend_bool should_throw);
H A Dmt_rand.c279 PHPAPI zend_long php_mt_rand_range(zend_long min, zend_long max) in php_mt_rand_range() argument
281 zend_ulong umax = max - min; in php_mt_rand_range()
295 PHPAPI zend_long php_mt_rand_common(zend_long min, zend_long max) in php_mt_rand_common() argument
300 return php_mt_rand_range(min, max); in php_mt_rand_common()
306 RAND_RANGE_BADSCALING(n, min, max, PHP_MT_RAND_MAX); in php_mt_rand_common()
317 zend_long max; in PHP_FUNCTION() local
327 Z_PARAM_LONG(max) in PHP_FUNCTION()
330 if (UNEXPECTED(max < min)) { in PHP_FUNCTION()
331 …docref(NULL, E_WARNING, "max(" ZEND_LONG_FMT ") is smaller than min(" ZEND_LONG_FMT ")", max, min); in PHP_FUNCTION()
335 RETURN_LONG(php_mt_rand_common(min, max)); in PHP_FUNCTION()
H A Drandom.c215 PHPAPI int php_random_int(zend_long min, zend_long max, zend_long *result, zend_bool should_throw) in php_random_int() argument
220 if (min == max) { in php_random_int()
225 umax = max - min; in php_random_int()
263 zend_long max; in PHP_FUNCTION() local
268 Z_PARAM_LONG(max) in PHP_FUNCTION()
271 if (min > max) { in PHP_FUNCTION()
276 if (php_random_int_throw(min, max, &result) == FAILURE) { in PHP_FUNCTION()
/PHP-7.2/ext/filter/tests/
H A D046.phpt7 $max = sprintf("%d", PHP_INT_MAX);
8 switch($max) {
32 test_validation($max, "max");
38 max filtered: int(%d)
39 max is_long: bool(true)
40 max equal: bool(true)
/PHP-7.2/ext/standard/tests/general_functions/
H A Dvar_export_basic1.phpt23 '-2147483648' => '-2147483648', // max negative integer value
25 '2147483647' => 2147483647, // max positive integer value
31 "-0x80000000" => -0x7FFFFFFF - 1, // max negative integer as hexadecimal
32 "'0x7fffffff'" => '0x7fffffff', // max positive integer as hexadecimal
33 "0x7FFFFFFF" => 0x7FFFFFFF, // max positive integer as hexadecimal
36 "-020000000000" => -017777777777 - 1, // max negative integer as octal
37 "017777777777" => 017777777777, // max positive integer as octal
H A Dvar_export_basic1_32.phpt23 '-2147483648' => '-2147483648', // max negative integer value
25 '2147483647' => 2147483647, // max positive integer value
31 "-0x80000000" => -0x7FFFFFFF - 1, // max negative integer as hexadecimal
32 "'0x7fffffff'" => '0x7fffffff', // max positive integer as hexadecimal
33 "0x7FFFFFFF" => 0x7FFFFFFF, // max positive integer as hexadecimal
36 "-020000000000" => -017777777777 - 1, // max negative integer as octal
37 "017777777777" => 017777777777, // max positive integer as octal
H A Dstrval.phpt35 -2147483648, // max negative integer value
37 2147483647, // max positive integer value
45 -0x80000000, // max negative integer as hexadecimal
46 0x7fffffff, // max positive integer as hexadecimal
47 0x7FFFFFFF, // max positive integer as hexadecimal
50 -020000000000, // max negative integer as octal
51 017777777777, // max positive integer as octal
54 -0x80000001, // float value, beyond max negative int
55 0x800000001, // float value, beyond max positive int
56 020000000001, // float value, beyond max positive int
[all …]
/PHP-7.2/ext/date/tests/
H A Dformat-negative-timestamp.phpt8 $max = getrandmax();
9 $max_2 = $max / 2;
12 $new_tm = rand(1, $max);
/PHP-7.2/ext/opcache/Optimizer/
H A Dzend_inference.c914 tmp->max = MIN(constraint->range.max, tmp->max); in zend_inference_calc_range()
919 …tmp->max = MIN(ssa->var_info[constraint->max_ssa_var].range.max + constraint->range.max, tmp->max); in zend_inference_calc_range()
943 tmp->max = constraint->range.max; in zend_inference_calc_range()
967 tmp->max = MAX(tmp->max, ssa->var_info[p->sources[i]].range.max); in zend_inference_calc_range()
1535 ssa->var_info[var].range.max = max; in zend_inference_init_range()
1553 r->max > var_info->range.max) { in zend_inference_widening_meet()
1558 var_info->range.max == r->max && in zend_inference_widening_meet()
1593 var_info->range.max > r->max) { in zend_inference_narrowing_meet()
1594 r->max = var_info->range.max; in zend_inference_narrowing_meet()
1603 var_info->range.max == r->max && in zend_inference_narrowing_meet()
[all …]
H A Doptimize_temp_vars_5.c38 if (i > max) { \
39 max = i; \
54 int max = -1; in zend_optimize_temporary_variables() local
88 var = max; in zend_optimize_temporary_variables()
92 max = MAX(max, var + num); in zend_optimize_temporary_variables()
131 i = ++max; in zend_optimize_temporary_variables()
200 op_array->T = max + 1; in zend_optimize_temporary_variables()
/PHP-7.2/Zend/
H A Dzend_ptr_stack.h26 int top, max; member
47 if (stack->top+count > stack->max) { \ in END_EXTERN_C()
50 stack->max += PTR_STACK_BLOCK_SIZE; \ in END_EXTERN_C()
51 } while (stack->top+count > stack->max); \ in END_EXTERN_C()
52 …stack->elements = (void **) perealloc(stack->elements, (sizeof(void *) * (stack->max)), stack->per… in END_EXTERN_C()

Completed in 61 milliseconds

12345678910