Home
last modified time | relevance | path

Searched refs:buf2 (Results 1 – 25 of 156) sorted by relevance

1234567

/external/ltp/testcases/kernel/syscalls/times/
Dtimes03.c94 struct tms buf1, buf2, buf3; in verify_times() local
112 if (times(&buf2) == -1) in verify_times()
115 if (buf2.tms_utime == 0) in verify_times()
118 tst_res(TPASS, "buf2.tms_utime = %li", buf2.tms_utime); in verify_times()
120 if (buf1.tms_utime >= buf2.tms_utime) { in verify_times()
122 buf1.tms_utime, buf2.tms_utime); in verify_times()
125 buf1.tms_utime, buf2.tms_utime); in verify_times()
128 if (buf2.tms_stime == 0) in verify_times()
131 tst_res(TPASS, "buf2.tms_stime = %li", buf2.tms_stime); in verify_times()
133 if (buf1.tms_stime >= buf2.tms_stime) { in verify_times()
[all …]
/external/webrtc/webrtc/base/
Dbuffer_unittest.cc68 Buffer buf1(kTestData), buf2(buf1); in TEST() local
69 EXPECT_EQ(buf2.size(), 16u); in TEST()
70 EXPECT_EQ(buf2.capacity(), 16u); in TEST()
71 EXPECT_EQ(0, memcmp(buf2.data(), kTestData, 16)); in TEST()
72 EXPECT_NE(buf1.data(), buf2.data()); in TEST()
73 EXPECT_EQ(buf1, buf2); in TEST()
77 Buffer buf1, buf2(kTestData, sizeof(kTestData), 256); in TEST() local
78 EXPECT_NE(buf1, buf2); in TEST()
79 buf1 = buf2; in TEST()
80 EXPECT_EQ(buf1, buf2); in TEST()
[all …]
/external/swiftshader/third_party/subzero/crosstest/
Dmem_intrin.cpp43 int memcpy_test(uint8_t *buf, uint8_t *buf2, uint8_t init, SizeT length) { in memcpy_test() argument
45 memcpy((void *)buf2, (void *)buf, length); in memcpy_test()
46 return fletcher_checksum(buf2, length); in memcpy_test()
49 int memmove_test(uint8_t *buf, uint8_t *buf2, uint8_t init, SizeT length) { in memmove_test() argument
63 memmove((void *)buf2, (void *)buf, length); in memmove_test()
64 sum2 = fletcher_checksum(buf2, length); in memmove_test()
68 int memset_test(uint8_t *buf, uint8_t *buf2, uint8_t init, SizeT length) { in memset_test() argument
70 memset((void *)buf2, init + 4, length); in memset_test()
71 return fletcher_checksum(buf, length) + fletcher_checksum(buf2, length); in memset_test()
77 uint8_t buf2[NBYTES]; \
[all …]
/external/valgrind/none/tests/amd64/
Dasorep.c5 char buf1[64], buf2[64]; variable
11 uintptr_t b1 = (uintptr_t) buf1, b2 = (uintptr_t) buf2; in main()
23 if (memcmp (buf2, "abcd", 5) != 0 in main()
24 || rdi != (uintptr_t) buf2 + 4 in main()
34 if (memcmp (buf2, "0 0 0 ", 7) != 0 in main()
35 || rdi != (uintptr_t) buf2 + 6 in main()
43 if (rsi != (uintptr_t) buf2 + 4 in main()
48 memcpy (buf2, "abcdefghijklmnO", 16); in main()
52 if (rdi != (uintptr_t) buf2 + 15 in main()
57 memcpy (buf2, "ababababababababcdab", 20); in main()
[all …]
/external/adhd/cras/src/tests/
Daudio_area_unittest.cc24 static uint16_t buf2[32]; variable
44 cras_audio_area_config_buf_pointers(a2, &fmt, (uint8_t *)buf2); in TEST()
50 buf2[i] = rand(); in TEST()
53 EXPECT_EQ(buf1[i], buf2[i]); in TEST()
75 cras_audio_area_config_buf_pointers(a2, &fmt, (uint8_t *)buf2); in TEST()
83 buf2[i] = rand() % 3270; in TEST()
85 buf2[i] = 3280 + rand() % 3200; in TEST()
88 int32_t expected_value = buf2[i] * gain_scaler; in TEST()
111 cras_audio_area_config_buf_pointers(a2, &fmt, (uint8_t *)buf2); in TEST()
117 buf2[i] = rand(); in TEST()
[all …]
/external/vboot_reference/tests/
Dvb21_common2_tests.c118 uint8_t *buf2; in test_verify_signature() local
123 buf2 = malloc(size); in test_verify_signature()
124 sig2 = (struct vb2_signature *)buf2; in test_verify_signature()
126 memcpy(buf2, sig, size); in test_verify_signature()
132 memcpy(buf2, sig, size); in test_verify_signature()
137 memcpy(buf2, sig, size); in test_verify_signature()
144 memcpy(buf2, sig, size); in test_verify_signature()
150 memcpy(buf2, sig, size); in test_verify_signature()
155 memcpy(buf2, sig, size); in test_verify_signature()
160 memcpy(buf2, sig, size); in test_verify_signature()
[all …]
Dvb21_common_tests.c260 uint8_t *buf, *buf2; in test_verify_keyblock() local
286 buf2 = malloc(buf_size); in test_verify_keyblock()
287 memcpy(buf2, buf, buf_size); in test_verify_keyblock()
295 memcpy(buf, buf2, buf_size); in test_verify_keyblock()
299 memcpy(buf, buf2, buf_size); in test_verify_keyblock()
304 memcpy(buf, buf2, buf_size); in test_verify_keyblock()
310 memcpy(buf, buf2, buf_size); in test_verify_keyblock()
316 memcpy(buf, buf2, buf_size); in test_verify_keyblock()
322 memcpy(buf, buf2, buf_size); in test_verify_keyblock()
331 memcpy(buf, buf2, buf_size); in test_verify_keyblock()
[all …]
Dtlcl_tests.c110 uint8_t buf[32], buf2[32]; in TlclTest() local
132 TEST_EQ(TlclSendReceive(buf, buf2, sizeof(buf2)), 0, "SendReceive"); in TlclTest()
139 TEST_EQ(TlclSendReceive(buf, buf2, sizeof(buf2)), VBERROR_SIMULATED, in TlclTest()
145 TEST_EQ(TlclSendReceive(buf, buf2, sizeof(buf2)), 123, in TlclTest()
273 uint8_t buf[kPcrDigestLength], buf2[kPcrDigestLength]; in PcrTest() local
284 TEST_EQ(TlclExtend(1, buf, buf2), 0, "Extend"); in PcrTest()
Dvb21_host_key_tests.c43 uint8_t *buf, *buf2; in private_key_tests() local
97 buf2 = malloc(bufsize); in private_key_tests()
98 memcpy(buf2, buf, bufsize); in private_key_tests()
104 memcpy(buf, buf2, bufsize); in private_key_tests()
111 memcpy(buf, buf2, bufsize); in private_key_tests()
117 memcpy(buf, buf2, bufsize); in private_key_tests()
123 memcpy(buf, buf2, bufsize); in private_key_tests()
129 memcpy(buf, buf2, bufsize); in private_key_tests()
135 memcpy(buf, buf2, bufsize); in private_key_tests()
141 memcpy(buf, buf2, bufsize); in private_key_tests()
[all …]
/external/volley/src/test/java/com/android/volley/toolbox/
DByteArrayPoolTest.java31 byte[] buf2 = pool.getBuf(16); in reusesBuffer()
34 pool.returnBuf(buf2); in reusesBuffer()
38 assertTrue(buf3 == buf1 || buf3 == buf2); in reusesBuffer()
39 assertTrue(buf4 == buf1 || buf4 == buf2); in reusesBuffer()
47 byte[] buf2 = pool.getBuf(16); in obeysSizeLimit()
51 pool.returnBuf(buf2); in obeysSizeLimit()
58 assertTrue(buf4 == buf2 || buf4 == buf3); in obeysSizeLimit()
59 assertTrue(buf5 == buf2 || buf5 == buf3); in obeysSizeLimit()
61 assertTrue(buf6 != buf1 && buf6 != buf2 && buf6 != buf3); in obeysSizeLimit()
70 byte[] buf2 = pool.getBuf(17); in returnsBufferWithRightSize()
[all …]
/external/libnetfilter_conntrack/include/internal/
Dbitops.h28 set_bitmask_u32(uint32_t *buf1, const uint32_t *buf2, int len) in set_bitmask_u32() argument
33 buf1[i] |= buf2[i]; in set_bitmask_u32()
37 unset_bitmask_u32(uint32_t *buf1, const uint32_t *buf2, int len) in unset_bitmask_u32() argument
42 buf1[i] &= ~buf2[i]; in unset_bitmask_u32()
51 test_bitmask_u32(const uint32_t *buf1, const uint32_t *buf2, int len) in test_bitmask_u32() argument
56 if ((buf1[i] & buf2[i]) != buf2[i]) { in test_bitmask_u32()
64 test_bitmask_u32_or(const uint32_t *buf1, const uint32_t *buf2, int len) in test_bitmask_u32_or() argument
69 if (buf1[i] & buf2[i]) { in test_bitmask_u32_or()
/external/ltp/testcases/kernel/syscalls/readv/
Dreadv02.c61 char buf1[K_1], buf2[K_1], buf3[K_1]; variable
67 {buf2, -1},
68 {(buf2 + CHUNK), CHUNK},
69 {(buf2 + CHUNK * 2), CHUNK},
72 {(buf2 + CHUNK * 3), G_1},
73 {(buf2 + CHUNK * 4), G_1},
74 {(buf2 + CHUNK * 5), G_1},
78 {(buf2 + CHUNK * 6), CHUNK},
79 {(buf2 + CHUNK * 8), CHUNK},
82 {(buf2 + CHUNK * 9), CHUNK}
[all …]
/external/ltp/testcases/kernel/controllers/cpuset/cpuset_load_balance_test/
Dcpuset_sched_domains_check.c54 char buf1[128], buf2[128]; in check_sched_domains() local
93 bitmask_displaylist(buf2, sizeof(buf2), in check_sched_domains()
100 cpu, buf1, buf2); in check_sched_domains()
108 bitmask_displaylist(buf2, sizeof(buf2), in check_sched_domains()
112 cpu, buf1, buf2); in check_sched_domains()
/external/curl/src/
Dtool_homedir.c36 char buf1[1024], buf2[1024]; in GetEnv() local
49 rc = ExpandEnvironmentStringsA(variable, buf2, sizeof(buf2)); in GetEnv()
50 if(rc > 0 && rc < sizeof(buf2) && in GetEnv()
51 !strchr(buf2, '%')) /* no vars still unexpanded */ in GetEnv()
52 env = buf2; in GetEnv()
/external/valgrind/none/tests/s390x/
Dxc.c8 char buf2[20] = "*U\0*\0\0UU*\0U*AUAA*UU\n"; in test_oc() local
18 "Q"(*buf2):"memory"); in test_oc()
26 char buf2[20] = "*U\0*\0\0UU*\0U*AUAA*UU\n"; in test_nc() local
36 "Q"(*buf2):"memory"); in test_nc()
45 char buf2[20] = "*U\0*\0\0UU*\0U*AUAA*UU\n"; in test_xc() local
86 "a"(buf2):"memory"); in test_xc()
Dex_clone.c17 char buf2[40]; in threadfunc() local
20 memset(buf2, 0, sizeof(buf2)); in threadfunc()
32 ::"a" (buf2), "a" (source) in threadfunc()
34 printf("%s\n", buf2); in threadfunc()
/external/ltp/tools/pounder21/
Drun.c468 char buf[TEST_PATH_LEN], buf2[TEST_PATH_LEN]; in spawn_test() local
494 snprintf(buf2, TEST_PATH_LEN, "%s|%s", in spawn_test()
497 fd = strlen(buf2); in spawn_test()
498 for (tmp = (index(buf2, '|') - buf2); tmp < fd; tmp++) { in spawn_test()
499 if (buf2[tmp] == '/') { in spawn_test()
500 buf2[tmp] = '-'; in spawn_test()
501 } else if (buf2[tmp] == '|') { in spawn_test()
502 buf2[tmp] = '/'; in spawn_test()
514 fd = open(buf2, O_RDWR | O_CREAT | O_TRUNC | O_SYNC, in spawn_test()
517 perror(buf2); in spawn_test()
[all …]
/external/guava/guava-tests/test/com/google/common/io/
DCharSequenceReaderTest.java212 CharBuffer buf2 = CharBuffer.allocate(expected.length()); in assertReadsCorrectly() local
213 assertEquals(expected.length() == 0 ? -1 : expected.length(), reader.read(buf2)); in assertReadsCorrectly()
214 buf2.flip(); in assertReadsCorrectly()
215 assertEquals(expected, buf2.toString()); in assertReadsCorrectly()
220 buf2 = CharBuffer.allocate(5); in assertReadsCorrectly()
222 while (reader.read(buf2) != -1) { in assertReadsCorrectly()
223 buf2.flip(); in assertReadsCorrectly()
224 builder.append(buf2); in assertReadsCorrectly()
225 buf2.clear(); in assertReadsCorrectly()
/external/valgrind/memcheck/tests/amd64/
Dfxsave-amd64.c160 unsigned char* buf2 = memalign16(512); in main() local
169 memset(buf2, 0x55, 512); in main()
180 do_fxsave(buf2, 0); in main()
182 show(buf2, xx); in main()
193 memset(buf2, 0x55, 512); in main()
204 do_fxsave(buf2, 1); in main()
206 show(buf2, xx); in main()
215 free(buf1); free(buf2); free(buf3); in main()
/external/ltp/testcases/kernel/io/direct_io/
Ddiotest4.c201 char *buf0, *buf1, *buf2; in main() local
237 if ((buf2 = valloc(bufsize)) == NULL) { in main()
267 if (write(fd, buf2, 4096) == -1) { in main()
277 ret = runtest_f(fd, buf2, offset, count, EINVAL, 3, "odd count"); in main()
294 ret = read(fd, buf2, count); in main()
310 ret = runtest_f(newfd, buf2, offset, count, EBADF, 5, "negative fd"); in main()
322 ret = runtest_f(newfd, buf2, offset, count, EBADF, 6, in main()
334 ret = runtest_f(fd, buf2, offset, count, EBADF, 7, "closed fd"); in main()
347 ret = runtest_s(newfd, buf2, offset, count, 9, "/dev/null"); in main()
371 ret = runtest_s(fd, buf2, offset, count, 10, "mmapped file"); in main()
[all …]
/external/ltp/testcases/kernel/syscalls/rename/
Drename05.c75 struct stat buf1, buf2; variable
150 if (stat(mdir, &buf2) != -1) { in setup()
156 SAFE_STAT(cleanup, mdir, &buf2); in setup()
159 olddev1 = buf2.st_dev; in setup()
160 oldino1 = buf2.st_ino; in setup()
Drename06.c76 struct stat buf1, buf2; variable
150 if (stat(mdir, &buf2) != -1) { in setup()
155 SAFE_STAT(cleanup, mdir, &buf2); in setup()
158 olddev1 = buf2.st_dev; in setup()
159 oldino1 = buf2.st_ino; in setup()
/external/puffin/src/
Dstream_unittest.cc117 Buffer buf2(size); in TestWrite() local
124 ASSERT_TRUE(read_stream->Read(buf2.data(), buf2.size())); in TestWrite()
125 ASSERT_EQ(buf1, buf2); in TestWrite()
127 std::fill(buf2.begin(), buf2.end(), 0); in TestWrite()
131 for (size_t idx = 0; idx < buf2.size(); idx++) { in TestWrite()
132 ASSERT_TRUE(write_stream->Write(&buf2[idx], 1)); in TestWrite()
137 ASSERT_EQ(buf1, buf2); in TestWrite()
261 auto buf2 = buf; in TEST_F() local
268 MemoryStream::CreateForWrite(&buf2), extents); in TEST_F()
271 EXPECT_EQ(buf2, buf); in TEST_F()
/external/libevent/test/
Dregress_buffer.c1860 struct evbuffer *buf1 = NULL, *buf2 = NULL; in test_evbuffer_add_reference() local
1895 buf2 = evbuffer_new(); in test_evbuffer_add_reference()
1896 tt_assert(buf2); in test_evbuffer_add_reference()
1898 evbuffer_add(buf2, "I ", 2); in test_evbuffer_add_reference()
1900 evbuffer_add_buffer(buf2, buf1); in test_evbuffer_add_reference()
1902 evbuffer_remove(buf2, tmp, 16); in test_evbuffer_add_reference()
1904 evbuffer_drain(buf2, evbuffer_get_length(buf2)); in test_evbuffer_add_reference()
1907 evbuffer_validate(buf2); in test_evbuffer_add_reference()
1923 if (buf2) in test_evbuffer_add_reference()
1924 evbuffer_free(buf2); in test_evbuffer_add_reference()
[all …]
/external/libxaac/decoder/armv7/
Dixheaacd_fft_15_ld.s48 STR r2, [lr], #4 @ *buf2++ = temp1@
80 STR r3, [lr], #4 @ *buf2++ = temp2@
100 ADD r3, r1, r7 @ buf2[2] = r1 + s2
101 SUB r9, r6, r2 @ buf2[3] = s1 - r2
102 SUB r10, r12, r8 @ buf2[4] = r3 - s4
103 ADD r11, r5, r4 @ buf2[5] = s3 + r4
104 ADD r12, r12, r8 @ buf2[6] = r3 + s4
105 SUB r4, r5, r4 @ buf2[7] = s3 - r4
106 SUB r5, r1, r7 @ buf2[8] = r1 - s2
107 ADD r6, r6, r2 @ buf2[9] = s1 + r2
[all …]

1234567