Home
last modified time | relevance | path

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

123456

/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/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.c60 char buf1[K_1], buf2[K_1], buf3[K_1]; variable
66 {buf2, -1},
67 {(buf2 + CHUNK), CHUNK},
68 {(buf2 + CHUNK * 2), CHUNK},
71 {(buf2 + CHUNK * 3), G_1},
72 {(buf2 + CHUNK * 4), G_1},
73 {(buf2 + CHUNK * 5), G_1},
77 {(buf2 + CHUNK * 6), CHUNK},
78 {(buf2 + CHUNK * 8), CHUNK},
81 {(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 = ExpandEnvironmentStrings (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/syscalls/rename/
Drename05.c74 struct stat buf1, buf2; variable
153 if (stat(mdir, &buf2) != -1) { in setup()
161 if (stat(mdir, &buf2) == -1) { in setup()
168 olddev1 = buf2.st_dev; in setup()
169 oldino1 = buf2.st_ino; in setup()
Drename06.c75 struct stat buf1, buf2; variable
155 if (stat(mdir, &buf2) != -1) { in setup()
162 if (stat(mdir, &buf2) == -1) { in setup()
169 olddev1 = buf2.st_dev; in setup()
170 oldino1 = buf2.st_ino; in setup()
/external/ltp/testcases/kernel/io/direct_io/
Ddiotest4.c200 char *buf0, *buf1, *buf2; in main() local
236 if ((buf2 = valloc(bufsize)) == NULL) { in main()
266 if (write(fd, buf2, 4096) == -1) { in main()
276 ret = runtest_f(fd, buf2, offset, count, EINVAL, 3, "odd count"); in main()
293 ret = read(fd, buf2, count); in main()
309 ret = runtest_f(newfd, buf2, offset, count, EBADF, 5, "negative fd"); in main()
321 ret = runtest_f(newfd, buf2, offset, count, EBADF, 6, in main()
336 ret = runtest_f(fd, buf2, offset, count, EBADF, 7, "closed fd"); in main()
349 ret = runtest_s(newfd, buf2, offset, count, 9, "/dev/null"); in main()
373 ret = runtest_s(fd, buf2, offset, count, 10, "mmapped file"); in main()
[all …]
Ddiotest_routines.c116 char buf1[BUFSIZ], buf2[BUFSIZ]; in filecmp() local
133 ret2 = read(fd2, buf2, BUFSIZ); in filecmp()
143 if (strncmp(&buf1[i], &buf2[i], 1)) { in filecmp()
149 f2, i, buf2[i], in filecmp()
150 isprint(buf2[i]) ? buf2[i] : '.'); in filecmp()
/external/valgrind/memcheck/tests/x86/
Dfxsave.c107 unsigned char* buf2 = memalign16(512); in main() local
113 memset(buf2, 0x55, 512); in main()
124 do_fxsave(buf2); in main()
126 show(buf2, xx); in main()
134 free(buf1); free(buf2); free(buf3); in main()
/external/boringssl/src/crypto/pool/
Dpool_test.cc33 bssl::UniquePtr<CRYPTO_BUFFER> buf2(buf.get()); in TEST() local
53 bssl::UniquePtr<CRYPTO_BUFFER> buf2( in TEST() local
55 ASSERT_TRUE(buf2); in TEST()
57 EXPECT_EQ(buf.get(), buf2.get()) << "CRYPTO_BUFFER_POOL did not dedup data."; in TEST()
/external/libyuv/files/util/
Dcompare.cc33 uint8 buf2[kBlockSize]; in main() local
45 amt2 = static_cast<int>(fread(buf2, 1, kBlockSize, fin2)); in main()
47 hash2 = libyuv::HashDjb2(buf2, amt2, hash2); in main()
50 sum_square_err += libyuv::ComputeSumSquareError(buf1, buf2, amt_min); in main()

123456