Home
last modified time | relevance | path

Searched refs:state (Results 1 – 25 of 255) sorted by relevance

1234567891011

/php-src/ext/random/
H A Dengine_xoshiro256starstar.c69 s0 ^= state->state[0]; in jump()
70 s1 ^= state->state[1]; in jump()
79 state->state[0] = s0; in jump()
80 state->state[1] = s1; in jump()
81 state->state[2] = s2; in jump()
82 state->state[3] = s3; in jump()
87 state->state[0] = s0; in php_random_xoshiro256starstar_seed256()
88 state->state[1] = s1; in php_random_xoshiro256starstar_seed256()
89 state->state[2] = s2; in php_random_xoshiro256starstar_seed256()
90 state->state[3] = s3; in php_random_xoshiro256starstar_seed256()
[all …]
H A Dengine_pcgoneseq128xslrr64.c32 s->state = php_random_uint128_add( in step()
40 s->state = php_random_uint128_constant(0ULL, 0ULL); in php_random_pcgoneseq128xslrr64_seed128()
42 s->state = php_random_uint128_add(s->state, seed); in php_random_pcgoneseq128xslrr64_seed128()
46 static php_random_result generate(void *state) in generate() argument
62 .state = state, in range()
66 static bool serialize(void *state, HashTable *data) in serialize() argument
72 u = php_random_uint128_hi(s->state); in serialize()
76 u = php_random_uint128_lo(s->state); in serialize()
135state->state = php_random_uint128_add(php_random_uint128_multiply(acc_mult, state->state), acc_plu… in php_random_pcgoneseq128xslrr64_advance()
143 php_random_status_state_pcgoneseq128xslrr64 *state = engine.state; in PHP_METHOD() local
[all …]
H A Dengine_mt19937.c105 uint32_t *p = state->state; in mt19937_reload()
114 *p = twist(p[M-N], p[0], state->state[0]); in mt19937_reload()
122 *p = twist_php(p[M-N], p[0], state->state[0]); in mt19937_reload()
125 state->count = 0; in mt19937_reload()
136 state->state[0] = seed; in php_random_mt19937_seed32()
138 prev_state = state->state[i - 1]; in php_random_mt19937_seed32()
141 state->count = i; in php_random_mt19937_seed32()
143 mt19937_reload(state); in php_random_mt19937_seed32()
155 s1 = s->state[s->count++]; in generate()
170 .state = state, in range()
[all …]
H A Dphp_random.h43 PHPAPI uint64_t php_random_generate_fallback_seed_ex(php_random_fallback_seed_state *state);
67 uint32_t state[624]; member
71 php_random_uint128_t state; member
75 uint64_t state[4]; member
90 php_random_result (*generate)(void *state);
91 zend_long (*range)(void *state, zend_long min, zend_long max);
92 bool (*serialize)(void *state, HashTable *data);
93 bool (*unserialize)(void *state, HashTable *data);
98 void *state; member
167 raws.state = php_random_default_status(); in php_random_default_engine()
[all …]
/php-src/ext/hash/
H A Dhash_whirlpool.c63 state[0] = block[0] ^ (K[0] = context->state[0]); in WhirlpoolTransform()
64 state[1] = block[1] ^ (K[1] = context->state[1]); in WhirlpoolTransform()
254 context->state[0] ^= state[0] ^ block[0]; in WhirlpoolTransform()
255 context->state[1] ^= state[1] ^ block[1]; in WhirlpoolTransform()
256 context->state[2] ^= state[2] ^ block[2]; in WhirlpoolTransform()
257 context->state[3] ^= state[3] ^ block[3]; in WhirlpoolTransform()
258 context->state[4] ^= state[4] ^ block[4]; in WhirlpoolTransform()
259 context->state[5] ^= state[5] ^ block[5]; in WhirlpoolTransform()
260 context->state[6] ^= state[6] ^ block[6]; in WhirlpoolTransform()
261 context->state[7] ^= state[7] ^ block[7]; in WhirlpoolTransform()
[all …]
H A Dhash_crc32.c25 context->state = ~0; in PHP_CRC32Init()
37 context->state = (context->state << 8) ^ crc32_table[(context->state >> 24) ^ (input[i] & 0xff)]; in PHP_CRC32Update()
50 context->state = (context->state >> 8) ^ crc32b_table[(context->state ^ input[i]) & 0xff]; in PHP_CRC32BUpdate()
63 context->state = (context->state >> 8) ^ crc32c_table[(context->state ^ input[i]) & 0xff]; in PHP_CRC32CUpdate()
69 context->state=~context->state; in PHP_CRC32LEFinal()
73 digest[0] = (unsigned char) (context->state & 0xff); in PHP_CRC32LEFinal()
74 context->state = 0; in PHP_CRC32LEFinal()
79 context->state=~context->state; in PHP_CRC32BEFinal()
83 digest[3] = (unsigned char) (context->state & 0xff); in PHP_CRC32BEFinal()
84 context->state = 0; in PHP_CRC32BEFinal()
[all …]
H A Dhash_haval.c343 context->state[3] += (context->state[7] & 0xFF000000) | in PHP_HAVAL128Final()
348 context->state[2] += (((context->state[7] & 0x00FF0000) | in PHP_HAVAL128Final()
396 context->state[4] += ((context->state[7] & 0xFE000000) | in PHP_HAVAL160Final()
400 context->state[3] += ((context->state[7] & 0x01F80000) | in PHP_HAVAL160Final()
404 context->state[2] += (context->state[7] & 0x0007F000) | in PHP_HAVAL160Final()
449 context->state[5] += ((context->state[7] & 0xFC000000) | (context->state[6] & 0x03E00000)) >> 21; in PHP_HAVAL192Final()
450 context->state[4] += ((context->state[7] & 0x03E00000) | (context->state[6] & 0x001F0000)) >> 16; in PHP_HAVAL192Final()
451 context->state[3] += ((context->state[7] & 0x001F0000) | (context->state[6] & 0x0000FC00)) >> 10; in PHP_HAVAL192Final()
452 context->state[2] += ((context->state[7] & 0x0000FC00) | (context->state[6] & 0x000003E0)) >> 5; in PHP_HAVAL192Final()
453 context->state[1] += (context->state[7] & 0x000003E0) | (context->state[6] & 0x0000001F); in PHP_HAVAL192Final()
[all …]
H A Dhash_sha.c182 uint32_t a = state[0], b = state[1], c = state[2], d = state[3]; in SHA256Transform()
183 uint32_t e = state[4], f = state[5], g = state[6], h = state[7]; in SHA256Transform()
204 state[0] += a; in SHA256Transform()
205 state[1] += b; in SHA256Transform()
206 state[2] += c; in SHA256Transform()
207 state[3] += d; in SHA256Transform()
208 state[4] += e; in SHA256Transform()
209 state[5] += f; in SHA256Transform()
210 state[6] += g; in SHA256Transform()
494 uint64_t a = state[0], b = state[1], c = state[2], d = state[3]; in SHA512Transform()
[all …]
H A Dhash_adler32.c23 context->state = 1; in PHP_ADLER32Init()
30 s[0] = context->state & 0xffff; in PHP_ADLER32Update()
31 s[1] = (context->state >> 16) & 0xffff; in PHP_ADLER32Update()
43 context->state = s[0] + (s[1] << 16); in PHP_ADLER32Update()
48 digest[0] = (unsigned char) ((context->state >> 24) & 0xff); in PHP_ADLER32Final()
49 digest[1] = (unsigned char) ((context->state >> 16) & 0xff); in PHP_ADLER32Final()
50 digest[2] = (unsigned char) ((context->state >> 8) & 0xff); in PHP_ADLER32Final()
51 digest[3] = (unsigned char) (context->state & 0xff); in PHP_ADLER32Final()
52 context->state = 0; in PHP_ADLER32Final()
57 copy_context->state = orig_context->state; in PHP_ADLER32Copy()
H A Dhash_ripemd.c221 uint32_t a = state[0], b = state[1], c = state[2], d = state[3]; in RIPEMD128Transform()
222 uint32_t aa = state[0], bb = state[1], cc = state[2], dd = state[3]; in RIPEMD128Transform()
257 state[1] = state[2] + d + aa; in RIPEMD128Transform()
258 state[2] = state[3] + a + bb; in RIPEMD128Transform()
259 state[3] = state[0] + b + cc; in RIPEMD128Transform()
313 uint32_t a = state[0], b = state[1], c = state[2], d = state[3]; in RIPEMD256Transform()
314 uint32_t aa = state[4], bb = state[5], cc = state[6], dd = state[7]; in RIPEMD256Transform()
412 uint32_t a = state[0], b = state[1], c = state[2], d = state[3], e = state[4]; in RIPEMD160Transform()
413 uint32_t aa = state[0], bb = state[1], cc = state[2], dd = state[3], ee = state[4]; in RIPEMD160Transform()
512 uint32_t a = state[0], b = state[1], c = state[2], d = state[3], e = state[4]; in RIPEMD320Transform()
[all …]
H A Dhash_fnv.c88 context->state = PHP_FNV1_32_INIT; in PHP_FNV132Init()
95 context->state = fnv_32_buf((void *)input, inputLen, context->state, 0); in PHP_FNV132Update()
101 context->state = fnv_32_buf((void *)input, inputLen, context->state, 1); in PHP_FNV1a32Update()
107 memcpy(digest, &context->state, 4); in PHP_FNV132Final()
110 unsigned char *c = (unsigned char *) &context->state; in PHP_FNV132Final()
123 context->state = PHP_FNV1_64_INIT; in PHP_FNV164Init()
130 context->state = fnv_64_buf((void *)input, inputLen, context->state, 0); in PHP_FNV164Update()
136 context->state = fnv_64_buf((void *)input, inputLen, context->state, 1); in PHP_FNV1a64Update()
142 memcpy(digest, &context->state, 8); in PHP_FNV164Final()
145 unsigned char *c = (unsigned char *) &context->state; in PHP_FNV164Final()
/php-src/ext/hash/sha3/generic64lc/
H A DKeccakP-1600-opt64.c86 void KeccakP1600_Initialize(void *state) in KeccakP1600_Initialize() argument
88 memset(state, 0, 200); in KeccakP1600_Initialize()
90 ((UINT64*)state)[ 1] = ~(UINT64)0; in KeccakP1600_Initialize()
91 ((UINT64*)state)[ 2] = ~(UINT64)0; in KeccakP1600_Initialize()
92 ((UINT64*)state)[ 8] = ~(UINT64)0; in KeccakP1600_Initialize()
93 ((UINT64*)state)[12] = ~(UINT64)0; in KeccakP1600_Initialize()
94 ((UINT64*)state)[17] = ~(UINT64)0; in KeccakP1600_Initialize()
95 ((UINT64*)state)[20] = ~(UINT64)0; in KeccakP1600_Initialize()
177 ((UINT64*)state)[i] ^= lane; in KeccakP1600_AddLanes()
235 memcpy(state, data, laneCount*8); in KeccakP1600_OverwriteLanes()
[all …]
H A DKeccakP-1600-SnP.h33 void KeccakP1600_Initialize(void *state);
35 #define KeccakP1600_AddByte(state, byte, offset) \ argument
36 ((unsigned char*)(state))[(offset)] ^= (byte)
38 void KeccakP1600_AddByte(void *state, unsigned char data, unsigned int offset);
40 void KeccakP1600_AddBytes(void *state, const unsigned char *data, unsigned int offset, unsigned int…
41 void KeccakP1600_OverwriteBytes(void *state, const unsigned char *data, unsigned int offset, unsign…
42 void KeccakP1600_OverwriteWithZeroes(void *state, unsigned int byteCount);
43 void KeccakP1600_Permute_Nrounds(void *state, unsigned int nrounds);
44 void KeccakP1600_Permute_12rounds(void *state);
45 void KeccakP1600_Permute_24rounds(void *state);
[all …]
H A DKeccakP-1600-64.macros461 X##ba = state[ 0]; \
462 X##be = state[ 1]; \
463 X##bi = state[ 2]; \
464 X##bo = state[ 3]; \
465 X##bu = state[ 4]; \
466 X##ga = state[ 5]; \
467 X##ge = state[ 6]; \
468 X##gi = state[ 7]; \
469 X##go = state[ 8]; \
470 X##gu = state[ 9]; \
[all …]
H A DSnP-Relaned.h19 #define SnP_AddBytes(state, data, offset, length, SnP_AddLanes, SnP_AddBytesInLane, SnP_laneLengthI… argument
22 SnP_AddLanes(state, data, (length)/SnP_laneLengthInBytes); \
23 SnP_AddBytesInLane(state, \
38 SnP_AddBytesInLane(state, _lanePosition, _curData, _offsetInLane, _bytesInLane); \
50 SnP_OverwriteLanes(state, data, (length)/SnP_laneLengthInBytes); \
51 SnP_OverwriteBytesInLane(state, \
78 SnP_ExtractLanes(state, data, (length)/SnP_laneLengthInBytes); \
79 SnP_ExtractBytesInLane(state, \
94 … SnP_ExtractBytesInLane(state, _lanePosition, _curData, _offsetInLane, _bytesInLane); \
106 SnP_ExtractAndAddLanes(state, input, output, (length)/SnP_laneLengthInBytes); \
[all …]
/php-src/sapi/cli/
H A Dphp_http_parser.c266 enum state state = (enum state) parser->state; in php_http_parser_execute() local
296 if (state == s_req_path) in php_http_parser_execute()
298 if (state == s_req_path || state == s_req_schema || state == s_req_schema_slash in php_http_parser_execute()
299 || state == s_req_schema_slash_slash || state == s_req_port in php_http_parser_execute()
300 || state == s_req_query_string_start || state == s_req_query_string in php_http_parser_execute()
302 || state == s_req_fragment_start || state == s_req_fragment) in php_http_parser_execute()
314 switch (state) { in php_http_parser_execute()
377 state = s_res_HT; in php_http_parser_execute()
382 state = s_res_HTT; in php_http_parser_execute()
1511 parser->state = state; in php_http_parser_execute()
[all …]
/php-src/ext/standard/tests/array/
H A Dbug35022.phpt5 $state = array("one" => 1, "two" => 2, "three" => 3);
6 function foo( &$state ) {
7 $contentDict = end( $state );
8 for ( $contentDict = end( $state ); $contentDict !== false; $contentDict = prev( $state ) ) {
9 echo key($state) . " => " . current($state) . "\n";
12 foo($state);
13 reset($state);
14 var_dump( key($state), current($state) );
/php-src/ext/hash/sha3/generic32lc/
H A DKeccakP-1600-SnP.h27 void KeccakP1600_Initialize(void *state);
28 void KeccakP1600_AddByte(void *state, unsigned char data, unsigned int offset);
29 void KeccakP1600_AddBytes(void *state, const unsigned char *data, unsigned int offset, unsigned int…
30 void KeccakP1600_OverwriteBytes(void *state, const unsigned char *data, unsigned int offset, unsign…
31 void KeccakP1600_OverwriteWithZeroes(void *state, unsigned int byteCount);
32 void KeccakP1600_Permute_Nrounds(void *state, unsigned int nrounds);
33 void KeccakP1600_Permute_12rounds(void *state);
34 void KeccakP1600_Permute_24rounds(void *state);
35 void KeccakP1600_ExtractBytes(const void *state, unsigned char *data, unsigned int offset, unsigned…
36 void KeccakP1600_ExtractAndAddBytes(const void *state, const unsigned char *input, unsigned char *o…
H A DSnP-Relaned.h19 #define SnP_AddBytes(state, data, offset, length, SnP_AddLanes, SnP_AddBytesInLane, SnP_laneLengthI… argument
22 SnP_AddLanes(state, data, (length)/SnP_laneLengthInBytes); \
23 SnP_AddBytesInLane(state, \
38 SnP_AddBytesInLane(state, _lanePosition, _curData, _offsetInLane, _bytesInLane); \
50 SnP_OverwriteLanes(state, data, (length)/SnP_laneLengthInBytes); \
51 SnP_OverwriteBytesInLane(state, \
78 SnP_ExtractLanes(state, data, (length)/SnP_laneLengthInBytes); \
79 SnP_ExtractBytesInLane(state, \
94 … SnP_ExtractBytesInLane(state, _lanePosition, _curData, _offsetInLane, _bytesInLane); \
106 SnP_ExtractAndAddLanes(state, input, output, (length)/SnP_laneLengthInBytes); \
[all …]
/php-src/ext/sodium/tests/
H A Dcrypto_generichash.phpt15 $state = sodium_crypto_generichash_init();
16 $q = sodium_crypto_generichash_final($state);
18 $state = sodium_crypto_generichash_init();
19 sodium_crypto_generichash_update($state, 'm');
20 sodium_crypto_generichash_update($state, 'sg');
21 $q = sodium_crypto_generichash_final($state);
24 sodium_crypto_generichash_update($state, 'm');
25 sodium_crypto_generichash_update($state, 'sg');
26 $q = sodium_crypto_generichash_final($state);
29 sodium_crypto_generichash_update($state, 'm');
[all …]
/php-src/ext/dom/lexbor/lexbor/html/tokenizer/
H A Dstate_comment.c100 tkz->state = lxb_html_tokenizer_state_data_before; in lxb_html_tokenizer_state_comment_start()
111 tkz->state = lxb_html_tokenizer_state_comment; in lxb_html_tokenizer_state_comment_start()
127 tkz->state = lxb_html_tokenizer_state_comment_end; in lxb_html_tokenizer_state_comment_start_dash()
160 tkz->state = lxb_html_tokenizer_state_comment; in lxb_html_tokenizer_state_comment_start_dash()
282 tkz->state = lxb_html_tokenizer_state_comment; in lxb_html_tokenizer_state_comment_less_than_sign()
302 tkz->state = lxb_html_tokenizer_state_comment; in lxb_html_tokenizer_state_comment_less_than_sign_bang()
318 tkz->state = in lxb_html_tokenizer_state_comment_less_than_sign_bang_dash()
356 tkz->state = lxb_html_tokenizer_state_comment_end; in lxb_html_tokenizer_state_comment_less_than_sign_bang_dash_dash()
390 tkz->state = lxb_html_tokenizer_state_comment; in lxb_html_tokenizer_state_comment_end_dash()
442 tkz->state = lxb_html_tokenizer_state_comment; in lxb_html_tokenizer_state_comment_end()
[all …]
H A Dstate_script.c163 tkz->state = in lxb_html_tokenizer_state_script_data()
476 tkz->state = in lxb_html_tokenizer_state_script_data_escaped()
565 tkz->state = in lxb_html_tokenizer_state_script_data_escaped_dash()
623 tkz->state = in lxb_html_tokenizer_state_script_data_escaped_dash_dash()
849 tkz->state = in lxb_html_tokenizer_state_script_data_double_escape_start()
897 tkz->state = in lxb_html_tokenizer_state_script_data_double_escaped()
906 tkz->state = in lxb_html_tokenizer_state_script_data_double_escaped()
986 tkz->state = in lxb_html_tokenizer_state_script_data_double_escaped_dash()
995 tkz->state = in lxb_html_tokenizer_state_script_data_double_escaped_dash()
1053 tkz->state = in lxb_html_tokenizer_state_script_data_double_escaped_dash_dash()
[all …]
H A Dstate.c864 tkz->state = in lxb_html_tokenizer_state_before_attribute_value()
871 tkz->state = in lxb_html_tokenizer_state_before_attribute_value()
922 tkz->state = in lxb_html_tokenizer_state_attribute_value_double_quoted()
1016 tkz->state = in lxb_html_tokenizer_state_attribute_value_single_quoted()
1266 tkz->state = tkz->state_return; in lxb_html_tokenizer_state_cr()
1790 tkz->state = tkz->state_return; in _lxb_html_tokenizer_state_char_ref()
1848 tkz->state = tkz->state_return; in lxb_html_tokenizer_state_char_ref_named()
1914 tkz->state = tkz->state_return; in lxb_html_tokenizer_state_char_ref_ambiguous_ampersand()
1962 tkz->state = tkz->state_return; in lxb_html_tokenizer_state_char_ref_hexademical_start()
1984 tkz->state = tkz->state_return; in lxb_html_tokenizer_state_char_ref_decimal_start()
[all …]
/php-src/ext/gd/libgd/
H A Dgdhelpers.c15 gd_strtok_r (char *s, char *sep, char **state) in gd_strtok_r() argument
28 s = *state; in gd_strtok_r()
33 *state = s; in gd_strtok_r()
47 *state = s; in gd_strtok_r()
58 *state = s; in gd_strtok_r()
72 *state = s; in gd_strtok_r()
/php-src/ext/pdo/
H A Dpdo_sqlstate.c28 const char state[5]; member
318 zend_hash_str_add_ptr(&err_hash, info->state, sizeof(info->state), (void *)info); in pdo_sqlstate_init_error_table()
322 const char *pdo_sqlstate_state_to_description(char *state) in pdo_sqlstate_state_to_description() argument
325 if ((info = zend_hash_str_find_ptr(&err_hash, state, sizeof(err_initializer[0].state))) != NULL) { in pdo_sqlstate_state_to_description()

Completed in 62 milliseconds

1234567891011