Home
last modified time | relevance | path

Searched +full:buffer +full:- +full:crc32 (Results 1 – 25 of 1112) sorted by relevance

12345678910>>...45

/aosp_15_r20/external/zlib/patches/
H A D0011-avx512.patch4 Subject: [PATCH] Enabled AVX512 for CRC32
6 Enabled AVX512 for CRC32 that provide best of known performance
8 operations and AVX512 new instructions, providing ~3.5X CRC32
10 ---
11 CMakeLists.txt | 8 +-
14 crc32.c | 14 +++-
15 crc32_simd.c | 198 ++++++++++++++++++++++++++++++++++++++++++++++++-
17 6 files changed, 230 insertions(+), 6 deletions(-)
19 diff --git a/CMakeLists.txt b/CMakeLists.txt
21 --- a/CMakeLists.txt
[all …]
/aosp_15_r20/external/aws-sdk-java-v2/core/sdk-core/src/test/java/software/amazon/awssdk/core/internal/async/
H A DChecksumCalculatingAsyncRequestBodyTest.java54 "x-amz-checksum-crc32:i9aeUg==\r\n\r\n";
57 "x-amz-checksum-crc32:AAAAAA==\r\n\r\n";
82 Arguments.of("RequestBody from buffer, 0 pos, test string", in publishers()
85 Arguments.of("RequestBody from buffer, random pos, test string", in publishers()
95 Arguments.of("RequestBody from buffer, 0 pos, empty string", in publishers()
106 .algorithm(Algorithm.CRC32) in checksumPublisher()
107 .trailerHeader("x-amz-checksum-crc32").build(); in checksumPublisher()
137 Subscriber<ByteBuffer> subscriber = new SimpleSubscriber(buffer -> { in publish_differentAsyncRequestBodiesAndSources_produceCorrectData()
138 byte[] bytes = new byte[buffer.remaining()]; in publish_differentAsyncRequestBodiesAndSources_produceCorrectData()
139 buffer.get(bytes); in publish_differentAsyncRequestBodiesAndSources_produceCorrectData()
[all …]
/aosp_15_r20/external/pigweed/pw_checksum/
H A Dcrc32_test.cc7 // https://www.apache.org/licenses/LICENSE-2.0
14 #include "pw_checksum/crc32.h"
18 #include "public/pw_checksum/crc32.h"
26 // The expected CRC32 values were calculated using
42 TEST(Crc32, Empty) { in TEST() argument
43 EXPECT_EQ(Crc32::Calculate(span<std::byte>()), PW_CHECKSUM_EMPTY_CRC32); in TEST()
51 TEST(Crc32, Buffer) { in TEST() argument
52 EXPECT_EQ(Crc32::Calculate(as_bytes(span(kBytes))), kBufferCrc); in TEST()
58 TEST(Crc32, String) { in TEST() argument
59 EXPECT_EQ(Crc32::Calculate(as_bytes(span(kString))), kStringCrc); in TEST()
[all …]
/aosp_15_r20/prebuilts/go/linux-x86/src/archive/zip/
Dwriter_test.go2 // Use of this source code is governed by a BSD-style
12 "hash/crc32"
88 buf := new(bytes.Buffer)
123 buf := new(bytes.Buffer)
202 flags: 0x008, // UTF-8 must not be set
207 buf := new(bytes.Buffer)
242 var buf bytes.Buffer
245 Modified: time.Date(2017, 10, 31, 21, 11, 57, 0, timeZone(-7*time.Hour)),
255 want, err := os.ReadFile("testdata/time-go.zip")
261 t.Error("contents of time-go.zip differ")
[all …]
/aosp_15_r20/external/apache-commons-compress/src/main/java/org/apache/commons/compress/archivers/arj/
H A DArjArchiveInputStream.java9 * http://www.apache.org/licenses/LICENSE-2.0
26 import java.util.zip.CRC32;
68 throw new ArchiveException("Multi-volume ARJ files are unsupported"); in ArjArchiveInputStream()
110 final ByteArrayOutputStream buffer = new ByteArrayOutputStream(); in readString() local
113 buffer.write(nextByte); in readString()
116 return new String(buffer.toByteArray(), charsetName); in readString()
119 return new String(buffer.toByteArray()); in readString()
147 final CRC32 crc32 = new CRC32(); in readHeader() local
148 crc32.update(basicHeaderBytes); in readHeader()
149 if (basicHeaderCrc32 == crc32.getValue()) { in readHeader()
[all …]
/aosp_15_r20/external/apache-commons-compress/src/main/java/org/apache/commons/compress/archivers/sevenz/
H A DSevenZOutputFile.java9 * http://www.apache.org/licenses/LICENSE-2.0
41 import java.util.zip.CRC32;
54 private final CRC32 crc32 = new CRC32(); field in SevenZOutputFile
55 private final CRC32 compressedCrc32 = new CRC32();
81 * allows you to write to an in-memory archive.</p>
93 * Sets the default compression method to use for entry contents - the
100 * <p>This is a short form for passing a single-element iterable
109 * Sets the default (compression) methods to use for entry contents - the
184 final SevenZArchiveEntry entry = files.get(files.size() - 1); in closeArchiveEntry()
190 entry.setCrcValue(crc32.getValue()); in closeArchiveEntry()
[all …]
/aosp_15_r20/external/pigweed/pw_hdlc/java/main/dev/pigweed/pw_hdlc/
H A DEncoder.java7 // https://www.apache.org/licenses/LICENSE-2.0
22 import java.util.zip.CRC32;
26 private final CRC32 crc32 = new CRC32(); field in Encoder
97 crc32.reset(); in startFrame()
110 long crc = crc32.getValue(); in writeCrc()
111 byte[] buffer = {(byte) crc, (byte) (crc >> 8), (byte) (crc >> 16), (byte) (crc >> 24)}; in writeCrc()
112 writeData(ByteBuffer.wrap(buffer)); in writeCrc()
116 ByteBuffer buffer = ByteBuffer.allocate(CustomVarInt.varLongSize(data)); in writeVarLong() local
117 CustomVarInt.putVarLong(data, buffer); in writeVarLong()
118 buffer.rewind(); in writeVarLong()
[all …]
H A DDecoder.java7 // https://www.apache.org/licenses/LICENSE-2.0
22 import java.util.zip.CRC32;
36 private final byte[] buffer = new byte[MAX_FRAME_SIZE_BYTES]; field in Decoder
53 public void process(ByteBuffer buffer) { in process() argument
54 while (buffer.hasRemaining()) { in process()
55 process(buffer.get()); in process()
59 public void process(byte[] buffer) { in process() argument
60 for (byte b : buffer) { in process()
71 // Report an error if non-flag bytes were read between frames. in process()
84 ByteBuffer message = ByteBuffer.wrap(buffer, 0, currentFrameSize); in process()
[all …]
/aosp_15_r20/external/apache-commons-compress/src/main/java/org/apache/commons/compress/archivers/zip/
H A DAbstractUnicodeExtraField.java9 * http://www.apache.org/licenses/LICENSE-2.0
22 import java.util.zip.CRC32;
52 final CRC32 crc32 = new CRC32(); in AbstractUnicodeExtraField() local
53 crc32.update(bytes, off, len); in AbstractUnicodeExtraField()
54 nameCRC32 = crc32.getValue(); in AbstractUnicodeExtraField()
59 throw new RuntimeException("FATAL: UTF-8 encoding not supported.", e); //NOSONAR in AbstractUnicodeExtraField()
88 * @return The CRC32 checksum of the filename or comment as
96 * @param nameCRC32 The CRC32 checksum of the filename as encoded
105 * @return The UTF-8 encoded name.
117 * @param unicodeName The UTF-8 encoded name to set.
[all …]
/aosp_15_r20/prebuilts/go/linux-x86/src/hash/crc32/
Dcrc32_amd64.go2 // Use of this source code is governed by a BSD-style
5 // AMD64-specific hardware-assisted CRC32 algorithms. See crc32.go for a
6 // description of the interface that each architecture-specific file
9 package crc32 package
19 // castagnoliSSE42 is defined in crc32_amd64.s and uses the SSE 4.2 CRC32
25 // castagnoliSSE42Triple is defined in crc32_amd64.s and uses the SSE 4.2 CRC32
55 panic("arch-specific Castagnoli not available")
75 // castagnoliShift computes the CRC32-C of K1 or K2 zeroes (depending on the
91 // "Fast CRC Computation for iSCSI Polynomial Using CRC32 Instruction"
92 // The same strategy of splitting the buffer in three is used but the
[all …]
/aosp_15_r20/packages/apps/TV/tuner/src/com/android/tv/tuner/hdhomerun/
DHdHomeRunUtils.java8 * http://www.apache.org/licenses/LICENSE-2.0
33 import java.util.zip.CRC32;
46 static final short HDHOMERUN_TYPE_INVALID = -1;
95 /** Returns {@code true} if the given IP is a multi-cast IP. */
124 ByteBuffer buffer = ByteBuffer.wrap(data); in openFrame() local
125 short resultType = buffer.getShort(); in openFrame()
126 int dataLength = buffer.getShort() & 0xffff; in openFrame()
133 buffer.get(result); in openFrame()
136 buffer.get(packetCrc); in openFrame()
148 ByteBuffer buffer = ByteBuffer.wrap(result); in sealFrame() local
[all …]
/aosp_15_r20/external/xz-embedded/linux/lib/xz/
H A Dxz_dec_stream.c1 // SPDX-License-Identifier: 0BSD
22 uint32_t crc32; member
41 /* Position in variable-length integers and Check fields */
44 /* Variable-length integer decoded by dec_vli() */
52 /* CRC32 or CRC64 value in Block or CRC32 value in Index */
55 /* CRC32 value in Block or Index */
130 * Temporary buffer needed to hold Stream Header, Block Header,
163 * Fill s->temp by copying data starting from b->in[b->in_pos]. Caller
164 * must have set s->temp.pos to indicate how much data we are supposed
165 * to copy into s->temp.buf. Return true once s->temp.pos has reached
[all …]
/aosp_15_r20/external/mobile-data-download/java/com/google/android/libraries/mobiledatadownload/internal/util/
H A DProtoLiteUtil.java8 * http://www.apache.org/licenses/LICENSE-2.0
34 import java.util.zip.CRC32;
65 * @param buf MUST be a 0 based array buffer (aka, buf.arrayOffset() must return 0) and be mutable
70 * @return A list of proto messages read from the buffer, or null on failure.
82 int crcPos = buf.limit() - CRC_LEN; in readFromBuffer()
101 int end = tailCrc ? buf.limit() - CRC_LEN : buf.limit(); in readFromBuffer()
130 String.format("Invalid message size: %d (buffer end is %d)", bytesInMessage, end)); in readFromBuffer()
153 // Advance the buffer manually, since we read from it "raw" from the array above in readFromBuffer()
174 * content at the end of the buffer (tail CRC) or a CRC of every message at the end of the
213 // As we called getSerializedSize above, this is assured to give us a non-bogus answer in dumpIntoBuffer()
[all …]
/aosp_15_r20/external/zlib/
H A Dcrc32_simd.c4 * Use of this source code is governed by a BSD-style license that can be
12 * crc32_avx512_simd_(): compute the crc32 of the buffer, where the buffer
30 * Definitions of the bit-reflected domain constants k1,k2,k3,k4 in crc32_avx512_simd_()
32 * constants and CRC32+Barrett polynomials remain unchanged. in crc32_avx512_simd_()
36 * k2 = ( x ^ ( 512 * 4 - 32 ) mod P(x) << 32 )' << 1 = 0x01322d1430 in crc32_avx512_simd_()
38 * k4 = ( x ^ ( 512 - 32 ) mod P(x) << 32 )' << 1 = 0x01c6e41596 in crc32_avx512_simd_()
67 len -= 256; in crc32_avx512_simd_()
101 len -= 256; in crc32_avx512_simd_()
105 * Fold into 512-bits. in crc32_avx512_simd_()
137 len -= 64; in crc32_avx512_simd_()
[all …]
/aosp_15_r20/external/rust/android-crates-io/crates/libz-sys/src/zlib/contrib/ada/
Dzlib.adb1 ----------------------------------------------------------------
2 -- ZLib for Ada thick binding. --
3 -- --
4 -- Copyright (C) 2002-2004 Dmitriy Anisimkov --
5 -- --
6 -- Open source license information is in the zlib.ads file. --
7 ----------------------------------------------------------------
9 -- $Id: zlib.adb,v 1.31 2004/09/06 06:53:19 vagul Exp $
52 := (16#1f#, 16#8b#, -- Magic header
53 16#08#, -- Z_DEFLATED
[all …]
/aosp_15_r20/cts/tests/media/common/src/android/mediav2/common/cts/
H A DOutputManager.java8 * http://www.apache.org/licenses/LICENSE-2.0
39 import java.util.zip.CRC32;
45 * be overwhelming as it is uncompressed YUV. For them we compute the CRC32 checksum of the
46 * output image and buffer and store it instead.
52 * to set option name="cleanup-apks" to "false" in AndroidTest.xml.
60 private final CRC32 mCrc32UsingImage;
61 private final CRC32 mCrc32UsingBuffer;
79 mCrc32UsingImage = new CRC32(); in OutputManager()
80 mCrc32UsingBuffer = new CRC32(); in OutputManager()
89 // Add only unique timeStamp, discarding any duplicate frame / non-display frame in saveInPTS()
[all …]
/aosp_15_r20/device/google/contexthub/util/nanotool/
Dnanopacket.cpp8 * http://www.apache.org/licenses/LICENSE-2.0
43 // Computes the CRC32 of a buffer given a starting CRC.
44 uint32_t Crc32(const uint8_t *buffer, int length) { in Crc32() function
48 // Word by word crc32 in Crc32()
50 crc = Crc32Word(crc, ((uint32_t *)buffer)[i], 8); in Crc32()
58 word |= buffer[i] << ((i & 0x3) * 8); in Crc32()
74 // Resize the buffer to accomodate header, footer and data content. in NanoPacket()
75 size_t data_size = data ? data->size() : 0; in NanoPacket()
99 std::copy(data->begin(), data->end(), packet_buffer_.begin() + 10); in NanoPacket()
100 std::copy(data->begin(), data->end(), packet_content_.begin()); in NanoPacket()
[all …]
/aosp_15_r20/external/icing/icing/index/lite/
H A Dlite-index.cc7 // http://www.apache.org/licenses/LICENSE-2.0
15 #include "icing/index/lite/lite-index.h"
36 #include "icing/index/hit/doc-hit-info.h"
38 #include "icing/index/lite/lite-index-header.h"
39 #include "icing/index/lite/term-id-hit-pair.h"
40 #include "icing/index/term-id-codec.h"
41 #include "icing/index/term-property-id.h"
42 #include "icing/legacy/core/icing-string-util.h"
43 #include "icing/legacy/core/icing-timer.h"
44 #include "icing/legacy/index/icing-array-storage.h"
[all …]
/aosp_15_r20/tools/apksig/src/main/java/com/android/apksig/internal/zip/
H A DZipUtils.java8 * http://www.apache.org/licenses/LICENSE-2.0
31 import java.util.zip.CRC32;
38 * order of these buffers is little-endian.
61 * <p>NOTE: Byte order of {@code zipEndOfCentralDirectory} must be little-endian.
75 * <p>NOTE: Byte order of {@code zipEndOfCentralDirectory} must be little-endian.
79 int commentLen = zipEndOfCentralDirectory.remaining() - ZIP_EOCD_REC_MIN_SIZE; in updateZipEocdCommentLen()
89 * <p>NOTE: Byte order of {@code zipEndOfCentralDirectory} must be little-endian.
101 * <p>NOTE: Byte order of {@code zipEndOfCentralDirectory} must be little-endian.
113 * <p>NOTE: Byte order of {@code zipEndOfCentralDirectory} must be little-endian.
135 // The record can be identified by its 4-byte signature/magic which is located at the very in findZipEndOfCentralDirectoryRecord()
[all …]
/aosp_15_r20/external/coreboot/src/lib/
H A Dlibgcov.c1 /* SPDX-License-Identifier: GPL-3.0-only WITH GCC-exception-3.1 */
35 #include "gcov-glue.c"
61 #define IN_LIBGCOV (-1)
71 #include "gcov-io.h"
111 #include "gcov-io.c"
120 /* Chain of per-object gcov structures. */
128 Returns zero on success, or -1 if an error occurred. */
139 return -1; in create_file_directory()
155 if (access(filename, F_OK) == -1 in create_file_directory()
157 && mkdir(filename, 0755) == -1 in create_file_directory()
[all …]
/aosp_15_r20/prebuilts/vndk/v34/arm64/include/external/zlib/
Dcrc32_simd.h4 * Use of this source code is governed by a BSD-style license that can be
15 * crc32_sse42_simd_(): compute the crc32 of the buffer, where the buffer
23 * crc32_sse42_simd_ buffer size constraints: see the use in zlib/crc32.c
24 * for computing the crc32 of an arbitrary length buffer.
30 * CRC32 checksums using ARMv8-a crypto instructions.
44 * CRC32 checksums using ARMv8-a PMULL instructions, where the buffer
/aosp_15_r20/prebuilts/vndk/v34/x86/include/external/zlib/
Dcrc32_simd.h4 * Use of this source code is governed by a BSD-style license that can be
15 * crc32_sse42_simd_(): compute the crc32 of the buffer, where the buffer
23 * crc32_sse42_simd_ buffer size constraints: see the use in zlib/crc32.c
24 * for computing the crc32 of an arbitrary length buffer.
30 * CRC32 checksums using ARMv8-a crypto instructions.
44 * CRC32 checksums using ARMv8-a PMULL instructions, where the buffer
/aosp_15_r20/prebuilts/vndk/v34/x86_64/include/external/zlib/
Dcrc32_simd.h4 * Use of this source code is governed by a BSD-style license that can be
15 * crc32_sse42_simd_(): compute the crc32 of the buffer, where the buffer
23 * crc32_sse42_simd_ buffer size constraints: see the use in zlib/crc32.c
24 * for computing the crc32 of an arbitrary length buffer.
30 * CRC32 checksums using ARMv8-a crypto instructions.
44 * CRC32 checksums using ARMv8-a PMULL instructions, where the buffer
/aosp_15_r20/prebuilts/module_sdk/art/7/common_os/include/external/zlib/
Dcrc32_simd.h4 * Use of this source code is governed by a BSD-style license that can be
15 * crc32_sse42_simd_(): compute the crc32 of the buffer, where the buffer
23 * crc32_sse42_simd_ buffer size constraints: see the use in zlib/crc32.c
24 * for computing the crc32 of an arbitrary length buffer.
30 * CRC32 checksums using ARMv8-a crypto instructions.
44 * CRC32 checksums using ARMv8-a PMULL instructions, where the buffer
/aosp_15_r20/prebuilts/vndk/v34/arm/include/external/zlib/
Dcrc32_simd.h4 * Use of this source code is governed by a BSD-style license that can be
15 * crc32_sse42_simd_(): compute the crc32 of the buffer, where the buffer
23 * crc32_sse42_simd_ buffer size constraints: see the use in zlib/crc32.c
24 * for computing the crc32 of an arbitrary length buffer.
30 * CRC32 checksums using ARMv8-a crypto instructions.
44 * CRC32 checksums using ARMv8-a PMULL instructions, where the buffer

12345678910>>...45