Home
last modified time | relevance | path

Searched refs:memcmp (Results 1 – 25 of 831) sorted by relevance

12345678910>>...34

/external/dropbear/libtomcrypt/demos/
Dmulti.c19 if (len != len2 || memcmp(buf[0], buf[1], len)) { in main()
25 if (len != len2 || memcmp(buf[0], buf[1], len)) { in main()
31 if (len != len2 || memcmp(buf[0], buf[1], len)) { in main()
41 if (len != len2 || memcmp(buf[0], buf[1], len)) { in main()
47 if (len != len2 || memcmp(buf[0], buf[1], len)) { in main()
53 if (len != len2 || memcmp(buf[0], buf[1], len)) { in main()
63 if (len != len2 || memcmp(buf[0], buf[1], len)) { in main()
69 if (len != len2 || memcmp(buf[0], buf[1], len)) { in main()
75 if (len != len2 || memcmp(buf[0], buf[1], len)) { in main()
85 if (len != len2 || memcmp(buf[0], buf[1], len)) { in main()
[all …]
/external/llvm/test/Transforms/InstCombine/
Dmemcmp-1.ll1 ; Test that the memcmp library call simplifier works correctly.
11 declare i32 @memcmp(i8*, i8*, i32)
13 ; Check memcmp(mem, mem, size) -> 0.
17 %ret = call i32 @memcmp(i8* %mem, i8* %mem, i32 %size)
22 ; Check memcmp(mem1, mem2, 0) -> 0.
26 %ret = call i32 @memcmp(i8* %mem1, i8* %mem2, i32 0)
31 ;; Check memcmp(mem1, mem2, 1) -> *(unsigned char*)mem1 - *(unsigned char*)mem2.
35 %ret = call i32 @memcmp(i8* %mem1, i8* %mem2, i32 1)
45 ; Check memcmp(mem1, mem2, size) -> cnst, where all arguments are constants.
51 %ret = call i32 @memcmp(i8* %mem1, i8* %mem2, i32 3)
[all …]
Dmemcmp-2.ll1 ; Test that the memcmp library call simplifier works correctly.
7 declare i32* @memcmp(i8*, i8*, i32)
9 ; Check that memcmp functions with the wrong prototype aren't simplified.
13 %ret = call i32* @memcmp(i8* %mem, i8* %mem, i32 %size)
14 ; CHECK-NEXT: call i32* @memcmp
/external/clang/test/Analysis/
Dbstring.c327 #define memcmp bcmp macro
331 #define memcmp BUILTIN(memcmp) macro
332 int memcmp(const void *s1, const void *s2, size_t n);
341 memcmp(a, b, 4); // no-warning in memcmp0()
348 memcmp(a, b, 5); // expected-warning{{out-of-bound}} in memcmp1()
355 memcmp(a, b, 4); // expected-warning{{out-of-bound}} in memcmp2()
361 clang_analyzer_eval(memcmp(a, a, 4) == 0); // expected-warning{{TRUE}} in memcmp3()
367 clang_analyzer_eval(memcmp(a, input, 4) == 0); // expected-warning{{UNKNOWN}} in memcmp4()
373 clang_analyzer_eval(memcmp(a, 0, 0) == 0); // expected-warning{{TRUE}} in memcmp5()
374 clang_analyzer_eval(memcmp(0, a, 0) == 0); // expected-warning{{TRUE}} in memcmp5()
[all …]
/external/openssl/crypto/des/
Ddestest.c393 if (memcmp(cbc_in,cbc_data,strlen((char *)cbc_data)+1) != 0) in main()
418 if (memcmp(out,cipher_data[i],8) != 0) in main()
425 if (memcmp(in,outin,8) != 0) in main()
446 if (memcmp(out,cipher_ecb2[i],8) != 0) in main()
453 if (memcmp(in,outin,8) != 0) in main()
473 if (memcmp(cbc_out,cbc_ok,32) != 0) in main()
482 if (memcmp(cbc_in,cbc_data,strlen((char *)cbc_data)) != 0) in main()
500 if (memcmp(cbc_out,xcbc_ok,32) != 0) in main()
508 if (memcmp(cbc_in,cbc_data,strlen((char *)cbc_data)+1) != 0) in main()
541 if (memcmp(cbc_out,cbc3_ok, in main()
[all …]
/external/compiler-rt/lib/asan/tests/
Dasan_mem_test.cc213 Ident(memcmp(s1, s2, size)); in TEST()
214 Ident(memcmp(s1 + size - 1, s2 + size - 1, 1)); in TEST()
215 Ident(memcmp(s1 - 1, s2 - 1, 0)); in TEST()
217 EXPECT_DEATH(Ident(memcmp)(s1 - 1, s2, 1), LeftOOBReadMessage(1)); in TEST()
218 EXPECT_DEATH(Ident(memcmp)(s1, s2 - 1, 1), LeftOOBReadMessage(1)); in TEST()
219 EXPECT_DEATH(Ident(memcmp)(s1 + size, s2, 1), RightOOBReadMessage(0)); in TEST()
220 EXPECT_DEATH(Ident(memcmp)(s1, s2 + size, 1), RightOOBReadMessage(0)); in TEST()
222 EXPECT_DEATH(Ident(memcmp)(s1 + 1, s2 + 1, size), RightOOBReadMessage(0)); in TEST()
223 EXPECT_DEATH(Ident(memcmp)(s1 + size - 1, s2, 2), RightOOBReadMessage(0)); in TEST()
227 EXPECT_DEATH(Ident(memcmp)(s1, s2, size + 1), RightOOBReadMessage(0)); in TEST()
[all …]
/external/openssl/crypto/sha/
Dsha256t.c65 if (memcmp(md,app_b1,sizeof(app_b1))) in main()
75 if (memcmp(md,app_b2,sizeof(app_b2))) in main()
95 if (memcmp(md,app_b3,sizeof(app_b3))) in main()
108 if (memcmp(md,addenum_1,sizeof(addenum_1))) in main()
118 if (memcmp(md,addenum_2,sizeof(addenum_2))) in main()
135 if (memcmp(md,addenum_3,sizeof(addenum_3))) in main()
Dsha512t.c94 if (memcmp(md,app_c1,sizeof(app_c1))) in main()
106 if (memcmp(md,app_c2,sizeof(app_c2))) in main()
130 if (memcmp(md,app_c3,sizeof(app_c3))) in main()
143 if (memcmp(md,app_d1,sizeof(app_d1))) in main()
155 if (memcmp(md,app_d2,sizeof(app_d2))) in main()
172 if (memcmp(md,app_d3,sizeof(app_d3))) in main()
/external/bison/lib/
Dmbchar.h195 ? memcmp ((mbc1).ptr, (mbc2).ptr, (mbc1).bytes) \
197 ? (memcmp ((mbc1).ptr, (mbc2).ptr, (mbc1).bytes) > 0 ? 1 : -1) \
198 : (memcmp ((mbc1).ptr, (mbc2).ptr, (mbc2).bytes) >= 0 ? 1 : -1)))
207 ? memcmp ((mbc1).ptr, (mbc2).ptr, (mbc1).bytes) \
209 ? (memcmp ((mbc1).ptr, (mbc2).ptr, (mbc1).bytes) > 0 ? 1 : -1) \
210 : (memcmp ((mbc1).ptr, (mbc2).ptr, (mbc2).bytes) >= 0 ? 1 : -1)))
215 && memcmp ((mbc1).ptr, (mbc2).ptr, (mbc1).bytes) == 0)
220 && memcmp ((mbc1).ptr, (mbc2).ptr, (mbc1).bytes) == 0)
/external/dropbear/libtomcrypt/testprof/
Dmodes_test.c45 if (l != 16 || memcmp(iv2, iv, 16)) { in modes_test()
55 if (memcmp(tmp, pt, 64) != 0) { in modes_test()
78 if (memcmp(tmp, pt, 64) != 0) { in modes_test()
90 if (l != 16 || memcmp(iv2, iv, 16)) { in modes_test()
100 if (memcmp(tmp, pt, 64) != 0) { in modes_test()
Dder_tests.c51 if (memcmp(strs[0], oct_str, sizeof(oct_str))) { in der_set_test()
56 if (memcmp(strs[1], bin_str, sizeof(bin_str))) { in der_set_test()
224 if (l->size != strlen(printable_str) || memcmp(printable_str, l->data, l->size)) { in der_flexi_test()
244 if (l->size != strlen(ia5_str) || memcmp(ia5_str, l->data, l->size)) { in der_flexi_test()
298 if (memcmp(l->data, &utctime, sizeof(utctime))) { in der_flexi_test()
332 if (l->size != sizeof(oct_str) || memcmp(oct_str, l->data, l->size)) { in der_flexi_test()
352 if (l->size != sizeof(bit_str) || memcmp(bit_str, l->data, l->size)) { in der_flexi_test()
386 …if (l->size != sizeof(oid_str)/sizeof(oid_str[0]) || memcmp(oid_str, l->data, l->size*sizeof(oid_s… in der_flexi_test()
428 if (l->size != strlen(set2_str) || memcmp(set2_str, l->data, l->size)) { in der_flexi_test()
443 if (l->size != strlen(set1_str) || memcmp(set1_str, l->data, l->size)) { in der_flexi_test()
[all …]
/external/webkit/Source/WebCore/platform/image-decoders/
DImageDecoder.cpp60 return !memcmp(contents, "GIF8", 4); in matchesGIFSignature()
65 return !memcmp(contents, "\x89\x50\x4E\x47", 4); in matchesPNGSignature()
70 return !memcmp(contents, "\xFF\xD8\xFF", 3); in matchesJPEGSignature()
76 return !memcmp(contents, "RIFF", 4) && !memcmp(contents + 8, "WEBPVP", 6); in matchesWebPSignature()
82 return !memcmp(contents, "BM", 2); in matchesBMPSignature()
87 return !memcmp(contents, "\x00\x00\x01\x00", 4); in matchesICOSignature()
92 return !memcmp(contents, "\x00\x00\x02\x00", 4); in matchesCURSignature()
/external/chromium/crypto/
Dhmac_unittest.cc60 EXPECT_EQ(0, memcmp(kReceivedHmac, calculated_hmac, kSHA1DigestSize)); in TEST()
130 EXPECT_EQ(0, memcmp(cases[i].digest, digest, kSHA1DigestSize)); in TEST()
155 EXPECT_EQ(0, memcmp(kKnownHMACSHA256, calculated_hmac, kSHA256DigestSize)); in TEST()
195 EXPECT_EQ(0, memcmp(kKnownHMACSHA1, calculated_hmac, kSHA1DigestSize)); in TEST()
202 EXPECT_EQ(0, memcmp(kKnownHMACSHA256, calculated_hmac2, kSHA256DigestSize)); in TEST()
234 EXPECT_EQ(0, memcmp(cases[i].digest, digest, kSHA1DigestSize)); in TEST()
Drsa_private_key_unittest.cc44 ASSERT_TRUE(0 == memcmp(&privkey1.front(), &privkey3.front(), in TEST()
46 ASSERT_TRUE(0 == memcmp(&privkey2.front(), &privkey4.front(), in TEST()
173 memcmp(expected_public_key_info, &output.front(), output.size()) == 0); in TEST()
382 ASSERT_TRUE(0 == memcmp(&output1.front(), &input1.front(), in TEST()
384 ASSERT_TRUE(0 == memcmp(&output2.front(), &input2.front(), in TEST()
/external/llvm/test/CodeGen/X86/
Dmemcmp.ll5 ; This tests codegen time inlining/optimization of memcmp
10 declare i32 @memcmp(...)
14 %0 = tail call i32 (...)* @memcmp(i8* %X, i8* %Y, i32 2) nounwind ; <i32> [#uses=1]
33 …%0 = tail call i32 (...)* @memcmp(i8* %X, i8* getelementptr inbounds ([23 x i8]* @.str, i32 0, i32…
50 %0 = tail call i32 (...)* @memcmp(i8* %X, i8* %Y, i32 4) nounwind ; <i32> [#uses=1]
67 …%0 = tail call i32 (...)* @memcmp(i8* %X, i8* getelementptr inbounds ([23 x i8]* @.str, i32 0, i32…
83 %0 = tail call i32 (...)* @memcmp(i8* %X, i8* %Y, i32 8) nounwind ; <i32> [#uses=1]
100 …%0 = tail call i32 (...)* @memcmp(i8* %X, i8* getelementptr inbounds ([23 x i8]* @.str, i32 0, i32…
/external/skia/legacy/src/animator/
DSkOperandIterpolator.cpp120 SkASSERT(memcmp(v, v1, sizeof(v)) == 0); in UnitTest()
124 SkASSERT(memcmp(v, v1, sizeof(v)) == 0); in UnitTest()
128 SkASSERT(memcmp(v, v1, sizeof(v)) == 0); in UnitTest()
132 SkASSERT(memcmp(v, v2, sizeof(v)) == 0); in UnitTest()
136 SkASSERT(memcmp(v, v2, sizeof(v)) == 0); in UnitTest()
140 SkASSERT(memcmp(v, iset(vv, 60, 120, 180), sizeof(v)) == 0); in UnitTest()
/external/skia/src/animator/
DSkOperandIterpolator.cpp120 SkASSERT(memcmp(v, v1, sizeof(v)) == 0); in UnitTest()
124 SkASSERT(memcmp(v, v1, sizeof(v)) == 0); in UnitTest()
128 SkASSERT(memcmp(v, v1, sizeof(v)) == 0); in UnitTest()
132 SkASSERT(memcmp(v, v2, sizeof(v)) == 0); in UnitTest()
136 SkASSERT(memcmp(v, v2, sizeof(v)) == 0); in UnitTest()
140 SkASSERT(memcmp(v, iset(vv, 60, 120, 180), sizeof(v)) == 0); in UnitTest()
/external/elfutils/tests/
Dsha1-tst.c45 if (memcmp (buf, expected1, SHA1_DIGEST_SIZE) != 0) in main()
58 if (memcmp (buf, expected2, SHA1_DIGEST_SIZE) != 0) in main()
72 if (memcmp (buf, expected3, SHA1_DIGEST_SIZE) != 0) in main()
/external/openssl/crypto/rc2/
Drc2test.c153 if (memcmp(&(RC2cipher[n][0]),buf,8) != 0) in main()
168 if (memcmp(&(RC2plain[n][0]),buf2,8) != 0) in main()
190 if (memcmp(text,out,strlen(text)+1) != 0) in main()
230 if (memcmp(cfb_cipher,cfb_buf1,CFB_TEST_SIZE) != 0) in cfb64_test()
244 if (memcmp(plain,cfb_buf2,CFB_TEST_SIZE) != 0) in cfb64_test()
/external/chromium/net/disk_cache/
Dbitmap_unittest.cc105 EXPECT_EQ(0, memcmp(local_map, bitmap.GetMap(), kMapSize)); in TEST()
110 EXPECT_EQ(0, memcmp(local_map, bitmap2.GetMap(), kMapSize)); in TEST()
113 EXPECT_EQ(0, memcmp(local_map, bitmap2.GetMap(), kMapSize)); in TEST()
114 EXPECT_NE(0, memcmp(local_map, bitmap.GetMap(), kMapSize)); in TEST()
126 EXPECT_EQ(0, memcmp(zeros, map.GetMap(), kMapSize)); in TEST()
128 EXPECT_EQ(0, memcmp(ones, map.GetMap(), kMapSize)); in TEST()
130 EXPECT_EQ(0, memcmp(zeros, map.GetMap(), kMapSize)); in TEST()
133 EXPECT_EQ(0, memcmp(zeros, map.GetMap(), kMapSize)); in TEST()
Dentry_unittest.cc101 EXPECT_EQ(0, memcmp(buffer2->data(), buffer3->data(), 1500)); in InternalSyncIOBackground()
231 EXPECT_EQ(0, memcmp(buffer2->data(), buffer3->data(), 1500)); in InternalAsyncIO()
318 EXPECT_EQ(0, memcmp(buffer2->data(), buffer2->data(), 10000)); in ExternalSyncIOBackground()
432 EXPECT_EQ(0, memcmp(buffer2->data(), buffer2->data(), 10000)); in ExternalAsyncIO()
494 EXPECT_EQ(0, memcmp(buffer1->data(), buffer2->data(), kBufferSize)); in StreamAccess()
632 EXPECT_TRUE(!memcmp(buffer1->data(), buffer2->data(), 2000)); in GrowData()
637 EXPECT_TRUE(!memcmp(buffer1->data(), buffer2->data(), kSize)); in GrowData()
652 EXPECT_TRUE(!memcmp(buffer1->data(), buffer2->data(), 2000)); in GrowData()
661 EXPECT_TRUE(!memcmp(buffer1->data(), buffer2->data(), kSize)); in GrowData()
727 EXPECT_TRUE(!memcmp(buffer1->data(), buffer2->data(), 20000)); in TruncateData()
[all …]
/external/skia/tests/
DGradientTest.cpp37 !memcmp(info->fColors, fColors, fColorCount * sizeof(SkColor))); in gradCheck()
39 !memcmp(info->fColorOffsets, fPos, fColorCount * sizeof(SkScalar))); in gradCheck()
69 REPORTER_ASSERT(reporter, !memcmp(info.fPoint, rec.fPoint, 2 * sizeof(SkPoint))); in linear_gradproc()
98 REPORTER_ASSERT(reporter, !memcmp(info.fPoint, rec.fPoint, 2 * sizeof(SkPoint))); in radial2_gradproc()
99 REPORTER_ASSERT(reporter, !memcmp(info.fRadius, rec.fRadius, 2 * sizeof(SkScalar))); in radial2_gradproc()
126 REPORTER_ASSERT(reporter, !memcmp(info.fPoint, rec.fPoint, 2 * sizeof(SkPoint))); in conical_gradproc()
127 REPORTER_ASSERT(reporter, !memcmp(info.fRadius, rec.fRadius, 2 * sizeof(SkScalar))); in conical_gradproc()
DPaintTest.cpp35 REPORTER_ASSERT(reporter, !memcmp(&paint, &copiedPaint, sizeof(paint))); in test_copy()
47 REPORTER_ASSERT(reporter, memcmp(&paint, &copiedPaint, sizeof(paint))); in test_copy()
61 REPORTER_ASSERT(reporter, memcmp(&cleanPaint, &paint, sizeof(cleanPaint))); in test_copy()
62 REPORTER_ASSERT(reporter, memcmp(&cleanPaint, &copiedPaint, sizeof(cleanPaint))); in test_copy()
/external/valgrind/main/none/tests/amd64/
Daes.c92 assert (0 == memcmp(&res, &exp, 16)); in AESDEC()
124 assert (0 == memcmp(&res, &exp, 16)); in AESDECLAST()
156 assert (0 == memcmp(&res, &exp, 16)); in AESENC()
188 assert (0 == memcmp(&res, &exp, 16)); in AESENCLAST()
218 assert (0 == memcmp(&res, &exp, 16)); in AESIMC()
273 assert (0 == memcmp(&res, &exp, 16)); in AESKEYGENASSIST()
/external/libsepol/src/
Dnodes.c191 if (!memcmp(addr, addr2, 4) && in sepol_node_exists()
192 !memcmp(mask, mask2, 4)) { in sepol_node_exists()
207 if (!memcmp(addr, addr2, 16) && in sepol_node_exists()
208 !memcmp(mask, mask2, 16)) { in sepol_node_exists()
251 if (!memcmp(addr, addr2, 4) && in sepol_node_query()
252 !memcmp(mask, mask2, 4)) { in sepol_node_query()
270 if (!memcmp(addr, addr2, 16) && in sepol_node_query()
271 !memcmp(mask, mask2, 16)) { in sepol_node_query()

12345678910>>...34