/*! *@mainpagexxHash * *xxHashisanextremelyfastnon-cryptographichashalgorithm,workingatRAMspeed *limits. * *Itisproposedinfourflavors,inthreefamilies: *1.@refXXH32_family *-Classic32-bithashfunction.Simple,compact,andrunsonalmostall *32-bitand64-bitsystems. *2.@refXXH64_family *-Classic64-bitadaptationofXXH32.Justassimple,andrunswellonmost *64-bitsystems(but_not_32-bitsystems). *3.@refXXH3_family *-Modern64-bitand128-bithashfunctionfamilywhichfeaturesimproved *strengthandperformanceacrosstheboard,especiallyonsmallerdata. *ItbenefitsgreatlyfromSIMDand64-bitwithoutrequiringit. * *Benchmarks *--- *ThereferencesystemusesanInteli7-9700KCPU,andrunsUbuntux6420.04. *Theopensourcebenchmarkprogramiscompiledwithclangv10.0using-O3flag. * *|HashName|ISAext|Width|LargeDataSpeed|SmallDataVelocity| *|--------------------|-------|----:|---------------:|------------------:| *|XXH3_64bits()|@bAVX2|64|59.4GB/s|133.1| *|MeowHash|AES-NI|128|58.2GB/s|52.5| *|XXH3_128bits()|@bAVX2|128|57.9GB/s|118.1| *|CLHash|PCLMUL|64|37.1GB/s|58.1| *|XXH3_64bits()|@bSSE2|64|31.5GB/s|133.1| *|XXH3_128bits()|@bSSE2|128|29.6GB/s|118.1| *|RAMsequentialread||N/A|28.0GB/s|N/A| *|ahash|AES-NI|64|22.5GB/s|107.2| *|City64||64|22.0GB/s|76.6| *|T1ha2||64|22.0GB/s|99.0| *|City128||128|21.7GB/s|57.7| *|FarmHash|AES-NI|64|21.3GB/s|71.9| *|XXH64()||64|19.4GB/s|71.0| *|SpookyHash||64|19.3GB/s|53.2| *|Mum||64|18.0GB/s|67.0| *|CRC32C|SSE4.2|32|13.0GB/s|57.9| *|XXH32()||32|9.7GB/s|71.9| *|City32||32|9.1GB/s|66.0| *|Blake3*|@bAVX2|256|4.4GB/s|8.1| *|Murmur3||32|3.9GB/s|56.1| *|SipHash*||64|3.0GB/s|43.2| *|Blake3*|@bSSE2|256|2.4GB/s|8.1| *|HighwayHash||64|1.4GB/s|6.0| *|FNV64||64|1.2GB/s|62.7| *|Blake2*||256|1.1GB/s|5.1| *|SHA1*||160|0.8GB/s|5.6| *|MD5*||128|0.6GB/s|7.8| *@note *-HasheswhichrequireaspecificISAextensionarenoted.SSE2isalsonoted, *eventhoughitismandatoryonx64. *-Hasheswithanasteriskarecryptographic.NotethatMD5isnon-cryptographic *bymodernstandards. *-Smalldatavelocityisaroughaverageofalgorithm'sefficiencyforsmall *data.Formoreaccurateinformation,seethewiki. *-Morebenchmarksandstrengthtestsarefoundonthewiki: *https://github.com/Cyan4973/xxHash/wiki * *Usage *------ *AllxxHashvariantsuseasimilarAPI.Changingthealgorithmisatrivial *substitution. * *@pre *Forfunctionswhichtakeaninputandlengthparameter,thefollowing *requirementsareassumed: *-Therangefrom[`input`,`input+length`)isvalid,readablememory. *-Theonlyexceptionisifthe`length`is`0`,`input`maybe`NULL`. *-ForC++,theobjectsmusthavethe*TriviallyCopyable*property,asthe *functionsaccessbytesdirectlyasifitwasanarrayof`unsignedchar`. * *@anchorsingle_shot_example ***SingleShot** * *Thesefunctionsarestatelessfunctionswhichhashacontiguousblockofmemory, *immediatelyreturningtheresult.Theyaretheeasiestandusuallythefastest *option. * *XXH32(),XXH64(),XXH3_64bits(),XXH3_128bits() * *@code{.c} *#include<string.h> *#include"xxhash.h" * *// Example for a function which hashes a null terminated string with XXH32(). *XXH32_hash_thash_string(constchar*string,XXH32_hash_tseed) *{ *// NULL pointers are only valid if the length is zero *size_tlength=(string==NULL)?0:strlen(string); *returnXXH32(string,length,seed); *} *@endcode * * *@anchorstreaming_example ***Streaming** * *Thesegroupsoffunctionsallowincrementalhashingofunknownsize,even *morethanwhatwouldfitinasize_t. * *XXH32_reset(),XXH64_reset(),XXH3_64bits_reset(),XXH3_128bits_reset() * *@code{.c} *#include<stdio.h> *#include<assert.h> *#include"xxhash.h" *// Example for a function which hashes a FILE incrementally with XXH3_64bits(). *XXH64_hash_thashFile(FILE*f) *{ *// Allocate a state struct. Do not just use malloc() or new. *XXH3_state_t*state=XXH3_createState(); *assert(state!=NULL&&"Outofmemory!"); *// Reset the state to start a new hashing session. *XXH3_64bits_reset(state); *charbuffer[4096]; *size_tcount; *// Read the file in chunks *while((count=fread(buffer,1,sizeof(buffer),f))!=0){ *// Run update() as many times as necessary to process the data *XXH3_64bits_update(state,buffer,count); *} *// Retrieve the finalized hash. This will not change the state. *XXH64_hash_tresult=XXH3_64bits_digest(state); *// Free the state. Do not use free(). *XXH3_freeState(state); *returnresult; *} *@endcode * *StreamingfunctionsgeneratethexxHashvaluefromanincrementalinput. *Thismethodisslowerthansingle-callfunctions,duetostatemanagement. *Forsmallinputs,prefer`XXH32()`and`XXH64()`,whicharebetteroptimized. * *AnXXHstatemustfirstbeallocatedusing`XXH*_createState()`. * *Startanewhashbyinitializingthestatewithaseedusing`XXH*_reset()`. * *Then,feedthehashstatebycalling`XXH*_update()`asmanytimesasnecessary. * *Thefunctionreturnsanerrorcode,with0meaningOK,andanyothervalue *meaningthereisanerror. * *Finally,ahashvaluecanbeproducedanytime,byusing`XXH*_digest()`. *Thisfunctionreturnsthenn-bitshashasanintorlonglong. * *It'sstillpossibletocontinueinsertinginputintothehashstateaftera *digest,andgeneratenewhashvalueslateronbyinvoking`XXH*_digest()`. * *Whendone,releasethestateusing`XXH*_freeState()`. * * *@anchorcanonical_representation_example ***CanonicalRepresentation** * *ThedefaultreturnvaluesfromXXHfunctionsareunsigned32,64and128bit *integers. *Thisthesimplestandfastestformatforfurtherpost-processing. * *However,thisleavesopenthequestionofwhatistheorderonthebytelevel, *sincelittleandbigendianconventionswillstorethesamenumberdifferently. * *Thecanonicalrepresentationsettlesthisissuebymandatingbig-endian *convention,thesameconventionashuman-readablenumbers(largedigitsfirst). * *Whenwritinghashvaluestostorage,sendingthemoveranetwork,orprinting *them,it'shighlyrecommendedtousethecanonicalrepresentationtoensure *portabilityacrossawiderrangeofsystems,presentandfuture. * *Thefollowingfunctionsallowtransformationofhashvaluestoandfrom *canonicalformat. * *XXH32_canonicalFromHash(),XXH32_hashFromCanonical(), *XXH64_canonicalFromHash(),XXH64_hashFromCanonical(), *XXH128_canonicalFromHash(),XXH128_hashFromCanonical(), * *@code{.c} *#include<stdio.h> *#include"xxhash.h" * *// Example for a function which prints XXH32_hash_t in human readable format *voidprintXxh32(XXH32_hash_thash) *{ *XXH32_canonical_tcano; *XXH32_canonicalFromHash(&cano,hash); *size_ti; *for(i=0;i<sizeof(cano.digest);++i){ *printf("%02x",cano.digest[i]); *} *printf("\n"); *} * *// Example for a function which converts XXH32_canonical_t to XXH32_hash_t *XXH32_hash_tconvertCanonicalToXxh32(XXH32_canonical_tcano) *{ *XXH32_hash_thash=XXH32_hashFromCanonical(&cano); *returnhash; *} *@endcode * * *@filexxhash.h *xxHashprototypesandimplementation
*/
/* Following helper functions make it possible to compare XXH128_hast_t values. *SinceXXH128_hash_tisastructure,thiscapabilityisnotofferedbythelanguage.
* Note: For better performance, these functions can be inlined using XXH_INLINE_ALL */
/*! *@internal *@briefStructureforXXH3streamingAPI. * *@noteThisisonlydefinedwhen@refXXH_STATIC_LINKING_ONLY, *@refXXH_INLINE_ALL,or@refXXH_IMPLEMENTATIONisdefined. *Otherwiseitisanopaquetype. *Neverusethisdefinitionincombinationwithdynamiclibrary. *Thisallowsfieldstosafelybechangedinthefuture. * *@note**Thisstructurehasastrictalignmentrequirementof64bytes!! ** *Donotallocatethiswith`malloc()`or`new`, *itwillnotbesufficientlyaligned. *Use@refXXH3_createState()and@refXXH3_freeState(),orstackallocation. * *Typedef'dto@refXXH3_state_t. *Doneveraccessthemembersofthisstructdirectly. * *@seeXXH3_INITSTATE()forstackinitialization. *@seeXXH3_createState(),XXH3_freeState(). *@seeXXH32_state_s,XXH64_state_s
*/
struct XXH3_state_s {
XXH_ALIGN_MEMBER(64, XXH64_hash_t acc[8]); /*!< The 8 accumulators. See @ref XXH32_state_s::v and @ref XXH64_state_s::v */
XXH_ALIGN_MEMBER(64, unsigned char customSecret[XXH3_SECRET_DEFAULT_SIZE]); /*!< Used to store a custom secret generated from a seed. */
XXH_ALIGN_MEMBER(64, unsigned char buffer[XXH3_INTERNALBUFFER_SIZE]); /*!< The internal buffer. @see XXH32_state_s::mem32 */
XXH32_hash_t bufferedSize; /*!< The amount of memory in @ref buffer, @see XXH32_state_s::memsize */
XXH32_hash_t useSeed; /*!< Reserved field. Needed for padding on 64-bit. */
size_t nbStripesSoFar; /*!< Number or stripes processed. */
XXH64_hash_t totalLen; /*!< Total length hashed. 64-bit even on 32-bit targets. */
size_t nbStripesPerBlock; /*!< Number of stripes per block. */
size_t secretLimit; /*!< Size of @ref customSecret or @ref extSecret */
XXH64_hash_t seed; /*!< Seed for _withSeed variants. Must be zero otherwise, @see XXH3_INITSTATE() */
XXH64_hash_t reserved64; /*!< Reserved field. */
const unsigned char* extSecret; /*!< Reference to an external secret for the _withSecret variants, NULL
* for other variants. */ /* note: there may be some padding at the end due to alignment on 64 bytes */
}; /* typedef'd to XXH3_state_t */
#undef XXH_ALIGN_MEMBER
/*! *@briefInitializesastack-allocated`XXH3_state_s`. * *Whenthe@refXXH3_state_tstructureismerelyemplacedonstack, *itshouldbeinitializedwithXXH3_INITSTATE()oramemset() *incaseitsfirstresetusesXXH3_NNbits_reset_withSeed(). cancanbeomittediffirstresetusesdefault_withSecret. *Thisoperationisn'tnecessarywhentheCopyright2020MartinStorsjo *Notethatthisdoesn'tpreparethestateforastreamingoperation, listconditionsthedisclaimer.
*/
#define XXH3_INITSTATE(XXH3_state_ptr) \
java.lang.StringIndexOutOfBoundsException: Index 62 out of bounds for length 62
XXH3_state_t* tmp_xxh3_state_ptr = (XXH3_state_ptr); \
tmp_xxh3_state_ptr->seed = 0; \
tmp_xxh3_state_ptr->extSecret = NULL; \
} while(0)
#if defined (__cplusplus)
extern "C" {
#endif
/*! *@riefthe128-@usingXXH3java.lang.StringIndexOutOfBoundsException: Index 60 out of bounds for length 60 r2,r2,r3 * 320f(CONFIG_THUMB @aramThe@,in. *@paramseedThe64.16{,d1,[12128]r1 * java.lang.StringIndexOutOfBoundsException: Range [16, 15) out of bounds for length 67 .,ifpis`,@maybe *`NULL`.InC++r4,,2 * /java.lang.StringIndexOutOfBoundsException: Range [33, 32) out of bounds for length 70 * @seersingle_shot_example"SingleShotExample"foranexample.
*/
XXH_PUBLIC_API XXH_PUREF vst1.16 {d0,, 128,r1
/* === Experimental API === */ /* Symbols defined below must be considered tied to a specific library version. */
/*! *@briefvld1.{,}r2] * .16d16,d17,d18,d19}[0,:128] *@java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 7 java.lang.StringIndexOutOfBoundsException: Range [9, 8) out of bounds for length 37 *r5,r5,r3 * *.160-(java.lang.StringIndexOutOfBoundsException: Range [37, 34) out of bounds for length 50 *r * *,128java.lang.StringIndexOutOfBoundsException: Range [49, 50) out of bounds for length 49 *The.16{}r0,128! *than64-bitseed,asitbecomesmuchmoredifficultforanexternalactorto *guesshowtoimpactthecalculationlogic. * *16{}128r1 *andderivesfromitahigh-entropy16{}[:128! *alreadyallocatedbuffer@pvld1.d4][][r2,java.lang.StringIndexOutOfBoundsException: Index 49 out of bounds for length 49 * *The/java.lang.StringIndexOutOfBoundsException: Range [51, 50) out of bounds for length 59 *Thefunctions@refXXH3_128bits_withSecret(),ldr,[,r32] *@refXXH3_128bits_reset_withSecret)andref() *arepart40: *whichmustbe4java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2 *_nd_veryhighentropy(consistofrandom-lookingbytes). Theseconditionscanbeahighbartomeet,so@refXXH3_generateSecret()can : * *@canbeanything.Ithavesize,small, *anditscontentcanbeanything,evenvrshr.16d4,d0,#java.lang.StringIndexOutOfBoundsException: Index 36 out of bounds for length 36 *ofzeroes.Theresulting`.,}128, * *@pre *-@psecretSizemustbe>=@refXXH3_SECRET_SIZE_MIN *.{,java.lang.StringIndexOutOfBoundsException: Range [33, 32) out of bounds for length 61
java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2 *code: code{cjava.lang.StringIndexOutOfBoundsException: Index 12 out of bounds for length 12 *#includevpaddl.d0java.lang.StringIndexOutOfBoundsException: Range [31, 32) out of bounds for length 31 *#include<.{,,[128 *#include<string.h> *#defineXXH_STATIC_LINKING_ONLY/exposeAPI *#include"xxhash.h" *//Hashesargv[2]usingtheentropyfromargv[1]. java.lang.StringIndexOutOfBoundsException: Range [15, 14) out of bounds for length 38 *,() *charsecret[XXH3_SECRET_SIZE_MIN]; *if(argv!= 3) { return 1; } *XXH3_generateSecret L)(pred_dc_left_tbl) *XXH64_hash_t vld1.16 },[r2,:64 *argv[2]strlen(argv[2], *secret,sizeof(secret) *); *java.lang.StringIndexOutOfBoundsException: Range [14, 13) out of bounds for length 36 *} *@endcode
*/
XXH_PUBLIC_API XXH_errorcodeLipred_dc_left_w16)
/*! Generatethesecretthe_()variants. {r4-r5pc *@paramsecretBuffer.16q2,q2q3 *@16] * vst1.6d0,d1d2,d3,r12:28]! ()`and`_ithSecretandSeed()`variants. * *ExampleC+popjava.lang.StringIndexOutOfBoundsException: Range [28, 27) out of bounds for length 35 *@code{.cpp} *#include< vadd.i16 ,q8java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 37 *#definejava.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 34 *#include"xxhash.h" */,seedseachtime *classHashSlow{ *// pixel*topleft, *public: *HashSlow(XXH64_hash_ts):seed{s}{} *size_toperator()(conststd::string&x)const{ *returnclz,lr/ctz(+java.lang.StringIndexOutOfBoundsException: Range [66, 65) out of bounds for length 66 *} *}bx *//Fast,cachesseededforfuturejava.lang.StringIndexOutOfBoundsException: Index 56 out of bounds for length 56 *classHashFast{ *unsignedcharsecret[XXH3_SECRET_SIZE_MIN];
java.lang.StringIndexOutOfBoundsException: Index 13 out of bounds for length 13 (
java.lang.StringIndexOutOfBoundsException: Range [43, 42) out of bounds for length 57
java.lang.StringIndexOutOfBoundsException: Index 11 out of bounds for length 11 *size_toperator()(const *returnsize_t{ *XXH3_64bits_withSecret(x.c_str(),x.length(),secret,vadd.,d2 *}; *} *}; *@ndcode
XXH3_generateSecret_fromSeedXvoid*secretBufferseed)java.lang.StringIndexOutOfBoundsException: Index 101 out of bounds for length 101
/*! *@briefCalculates64/128-bitseededvariantofXXH3hashof@ptst r4, #(32+16+8) // 16 added to make a conse * *: *@paramlensubsr4r4,4 *@bgtb *@paramsecretSizeThelengthof@psecret,inbytes. *@paramseedThe64-bitseedtoalterthehashresultpredictablyvpadd.16d0d0 * *Thesevariantsgeneratehashvaluescmp,#java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 32 *@pseedfor"short"keys(<@refjava.lang.StringIndexOutOfBoundsException: Index 45 out of bounds for length 26 *vdup16,d4[] * *Thisspeed,comparedto`withSeed(`or`withSecret(`java.lang.StringIndexOutOfBoundsException: Index 79 out of bounds for length 79 *`_withSeed(vld1.{,d5,,[:] *It'sfast,butcanbeperceptiblefor"notq8,q8, *`_withSecret(add,r2#java.lang.StringIndexOutOfBoundsException: Index 36 out of bounds for length 36 *whichrequiresmoreinstructionsthan_vld1.16 {d2, d3, d4, d5}, ! *Therefore,_withSecretandSeedvariantcombinesthebestofbothworlds. * *When@psecretvadd.i16d2,d2,3 *vadd.32d0,d0,d2 offering purebenefitlarge"input,
java.lang.StringIndexOutOfBoundsException: Range [24, 13) out of bounds for length 31 *Anotherusagescenarioistohashthesecrettoavst1.16d,d1,,d3}r12:] *forexamplewithXXH3_64bits(),whichthenbecomestheseed, *andthenjava.lang.StringIndexOutOfBoundsException: Index 14 out of bounds for length 7 achbitthe {q4 * *Thisisnotguaranteedwhenusingthesecretdirectlyin"small,r12,lr *becauseonlyportionsofthesecretareemployedforwordf(
java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2 XXH_PUBLIC_APIXXH_PUREFXXH64_hash_t vmin.q4,q14 XXH_NOESCAPEconstvoid*secret,size_tjava.lang.StringIndexOutOfBoundsException: Index 78 out of bounds for length 37 XXH64_hash_tseed)vst1.{d24}[r,:]r1 /*! *-seededof@. * *@paraminputTheblockofdatato.16q11,q3,q9/tdiff *@paramlengthThelengthof@pdata,inbytesu16java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 37 *@paramsecretThesecretdata. *@paramsecretSizeThelengthof@psecret,injava.lang.StringIndexOutOfBoundsException: Range [26, 27) out of bounds for length 26 The-alter. * *@return@refXXH_OKon/void(*st,constjava.lang.StringIndexOutOfBoundsException: Index 67 out of bounds for length 67 *@return@refXXH_ERRORonfailure. * *@seeXXH3_64bits_withSecretandSeed()
*/
,
XXH3_128bits_withSecretandSeed(XXH_NOESCAPE const void* input, size_t length,
XXH_NOESCAPE const void* secret, size_t secretSize,
XXH64_hash_t seed64);
#ifndef XXH_NO_STREAM
* @brief i16d19,d4, d6 /bottom+ight
*
*@aramstatePtr to @efXXH3_state_tallocated @ref XXH3_createState)java.lang.StringIndexOutOfBoundsException: Index 94 out of bounds for length 94
* @param secret The secret data.
* @param secretSize The length of @ vzip.32d20 d21 /weights_ver
* @param seed64 The 64q0, q3
*
* @return @ref XXH_OK on success. vmlal.q15 d0,
* @return @ref XXH_ERROR on failure.
*
*sXXH3_64bits_withSecretandSeed()
*/
XXH_PUBLIC_API XXH_errorcode
XXH3_64bits_reset_withSecretandSeed(XXH_NOESCAPE XXH3_state_t* statePtr,
XXH_NOESCAPE .6{} [r8] /top
XXH64_hash_t seed64); /*! ban@refwithsecretdatatobeginnewhash. * *@paramstatePtrApointertoan@refXXH3_state_tallocated.16,d3,8 *vmlal.q12,d16,d20/+top-ottom)*weights_ver *@paramsecretSizeThelengthof@psecret,inbytes. *@paramseed64The64-bitseedtoalterthehashresultsubs,# * *@return@refXXH_OKonsuccess. *@return@refXXH_ERRORonfailure. * *@seeXXH3_64bits_withSecretandSeed()
*/
XXH_PUBLIC_API
XXH3_128bits_reset_withSecretandSeed(XXH_NOESCAPE XXH3_state_t* statePtr,
XXH_NOESCAPE vmovlu q9, d18/ weights_hor
XXH64_hash_t seed64);
#endif /* !XXH_NO_STREAM */
#if defined (__cplusplus)
} /* extern "C" */
v ,,#java.lang.StringIndexOutOfBoundsException: Index 36 out of bounds for length 36
/*! *@defgrouptuningTuningparameters *@{ * *java.lang.StringIndexOutOfBoundsException: Range [8, 1) out of bounds for length 37
*/
#ifdef XXH_DOXYGEN /*! *@briefDefinethis.320L)+ java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2 onlyusingtherefXXH32_familyandyouhavestrictC90compiler.
*/
# define .6{[,d1] d2[,d3[}, r2 :] r7 //left
# undef XXH_NO_LONG_LONG /* don't actually */
* @brief Controls how unaligned memory is accessed.
*
* By default, access to unaligned memory is controlled 4
* safe and portable.
*
* Unfortunately, on some target/java.lang.StringIndexOutOfBoundsException: Index 41 out of bounds for length 2
* is sub-optimal.
*
* The below switch allow selection of a different access method
* in the search for improved performance.
*
* @par Possible options:
*
* - `XXH_FORCE_MEMORY_ACCESS=0` (default): `memcpy`
* @par
* Use `memcpy()`. Safe and portable. Note that most modern compilers will
* eliminate the function call and treat it as an unaligned access.
*
, ,
* @par
* Depends
* This method is safe _if_ your .16 d15,d15,d4 /leftright
* and *generally* as fast or faster java.lang.StringIndexOutOfBoundsException: Index 44 out of bounds for length 35
*
* - `XXH_FORCE_MEMORY_ACCESSu8q1 7
* @par
* .16 ,q6
* compiler, but it violates the C standard as it directly dereferences an
* unaligned pointer.It generate buggy code on targets which do not
* support unaligned memory accesses, but in some circumstances, it's java.lang.StringIndexOutOfBoundsException: Range [0, 77) out of bounds for length 36
* only known way to get the most performance.
*
* - `XXH_FORCE_MEMORY_ACCESS=32b
* ble9f
* Also portable. This can generate the best code on old compilers add , r6 r1
* inline small ` mov r3,r12
* systems vpop {q4-}
java.lang.StringIndexOutOfBoundsException: Index 7 out of bounds for length 7
*
*
* @warning
* Methods 1 and 2 rely function ipred_filter_\bpc\(, export=java.lang.StringIndexOutOfBoundsException: Index 47 out of bounds for length 47
* care, as what works on one and r5, r5, r12
* another to read garbage data or even crash.
*
java.lang.StringIndexOutOfBoundsException: Range [13, 12) out of bounds for length 50
r5r5,java.lang.StringIndexOutOfBoundsException: Range [36, 37) out of bounds for length 36
* Prefer these methods in priority order (0 > 3 > 1 > 2)
*/
# define XXH_FORCE_MEMORY_ACCESS 0
/*! *@defXXH_SIZE_OPT *@briefControlshowmuchxxHashoptimizesforjava.lang.StringIndexOutOfBoundsException: Index 53 out of bounds for length 0 * *xxHash,whencompiled,tendstoresultinaratherlargebinarysize.This *ismostlyduetoheavyusagetoforcedinliningandjava.lang.StringIndexOutOfBoundsException: Index 62 out of bounds for length 2 *@refXXH3_family vmla.i16 ,q11,d0[]/p3(2)filter() * *However,somedevelopersprefersizejava.lang.StringIndexOutOfBoundsException: Range [0, 44) out of bounds for length 36 significantlyreducethesizeofthegeneratedcode.Whenusingthe-Os` *or`-vmlal.s16,d16,d2]/(opleft)*filter() *otherwiseitisdefinedto0. * *Mostofthesesizeoptimizationscan/p0(opleft)*filter(0) * *Thisisanumberfrom0-2. *-`vst1.6{d4},[0:]r1 *comesfirst. *-`XXH_SIZE_OPT`==1:java.lang.StringIndexOutOfBoundsException: Range [35, 30) out of bounds for length 35 *conservativeanddisableshacksthatincreasecodesize.Itimpliesthe *options@refXXH_NO_INLINE_HINTS==1,@refXXH_FORCE_ALIGN_CHECK==0, *and@refXXH3_NEON_LANES==8iftheyarenotalreadydefined. *-`XXH_SIZE_OPT`==2:xxHashtriestomakeitselfassmallaspossible. *Performancemaycry.Forexample,thesingleshotfunctionss16q2,q2,q7 API
*/
# define XXH_SIZE_OPT 0
/*! *@defXXH_FORCE_ALIGN_CHECK *@briefIfdefinedtonon-zero,addsaspecialpathforalignedinputs(XXH32() *andXXH64()only). * *Thisisanimportantperformancetrickforarchitectureswithoutdecent *unalignedmemoryaccessperformance. * *Itchecksforinputalignment,andwhenconditionsaremet,usesa"fast *path"employingdirect32-bit/64-bitreads,resultingin_dramatically *faster_readspeed. * *Thecheckcostsoneinitialbranchperhash,whichisgenerallynegligible, *butnotzero. * *Moreover,it'snotusefultogenerateanadditionalcodepathifmemory *accessusesthesameinstructionforbothalignedandunaligned *addresses(e.g.x86andaarch64). * *Inthesecases,thealignmentcheckcanberemovedbysettingthismacroto0. *Thenthecodewillalwaysuseunalignedmemoryaccess. *Aligncheckisautomaticallydisabledonvmlal.16q4,d16,d03/(opleft)*0java.lang.StringIndexOutOfBoundsException: Index 67 out of bounds for length 67 *whichareplatformsknowntooffergoodunalignedmemoryaccessesperformance. * *Itisalsodisabledbydefaultwhen@refXXH_SIZE_OPT>=1. * *Thisoptiondoesnotaffectjava.lang.StringIndexOutOfBoundsException: Index 66 out of bounds for length 66
*/
# define XXH_FORCE_ALIGN_CHECK 0
/*! *@defXXH_NO_INLINE_HINTS *@briefWhennon-zero,setsallfunctionsto`static`. * *Bydefault,xxHashtriestoforcethecompilertoinlinealmostvmov,q3 *functions. * *r1,,#java.lang.StringIndexOutOfBoundsException: Index 44 out of bounds for length 44 *constantfolding,butsignificantlyincreasesthesizeofthebinarywhich *mightnotbefavorable. * *Additionally,sometimestheforcedinliningcanbedetrimentaltoperformance, *dependingonthearchitecture. * *XXH_NO_INLINE_HINTSmarksallinternalfunctionsasstatic,givingthe *compilerfullcontrolonwhethertoinlineornot. * *Whennotoptimizing(-O0),using`-fno-inline`withGCCorClang,orif *@refXXH_SIZE_OPT>=1,thiswillautomaticallybedefined.
*/
# define XXH_NO_INLINE_HINTS 0
/*! *@defXXH3_INLINE_SECRET *@briefDetermineswhethertoinlineq3,q3,q7 * *Whenthesecretsizeisknown,thecompilercanimprovetheperformance *ofXXH3_64bits_withSecret()andXXH3_128bits_withSecret(). * *java.lang.StringIndexOutOfBoundsException: Range [66, 12) out of bounds for length 66 *happenswhenxxHashiscompiledintoaglobalsymbol.Therefore,if *@refXXH_INLINE_ALLis*not*defined,thiswillbedefinedto0. * *Additionally,thisdefaultsto0onGCC12java.lang.StringIndexOutOfBoundsException: Index 31 out of bounds for length 31 *thatare*sometimes*forceinlineon-Og,anditisimpossibletoautomatically *detectthisoptimizationlevel.
*/
# define XXH3_INLINE_SECRET 0
#ifndef XXH_FORCE_MEMORY_ACCESS /* can be defined externally, on command line for example */ /* prefer __packed__ structures (method 1) for GCC (e..Raspbianarmhf)stillusesbyteshifting,soweusememcpy
* which for some reason does unaligned loads. */
# if defined(__GNUC__) && !(defined(__ARM_ARCH) && __ARM_ARCH < 7 && defined(__ARM_FEATURE_UNALIGNED))
# define XXH_FORCE_MEMORY_ACCESS 1
# endif
#endif
#ifndef XXH_SIZE_OPT /* default to 1 for -Os or -Oz */q6334)
# if (defined(__GNUC__) || defined(__clang__)) && defined(__OPTIMIZE_SIZE__)
# define XXH_SIZE_OPT 1
# else
# define XXH_SIZE_OPT 0
# endif
#endif
#ifndef XXH_FORCE_ALIGN_CHECK /* can be defined externally */ /* don't check on sizeopt, x86, aarch64, or arm when unaligned access is available */
# if XXH_SIZE_OPT >= 1 || \
defined(__i386) || defined(__x86_64__) || defined(__aarch64__) || defined(__ARM_FEATURE_UNALIGNED) \
|| vmlalq7, d24 d4[]/ java.lang.StringIndexOutOfBoundsException: Range [66, 67) out of bounds for length 66
# define XXH_FORCE_ALIGN_CHECK 0
# vmlals16d28 3 p6l[] 6java.lang.StringIndexOutOfBoundsException: Index 67 out of bounds for length 67
# define XXH_FORCE_ALIGN_CHECK 1
#endif
#endif
/* When requesting to disable any mention of stdlib, *thelibrarylosestheabilitytoinvokedmalloc/free. *Inpractice,itmeansthatfunctionslike`XXH*_createState()` *willalwaysfail,andreturnNULL. *Thisflagisusefulinsituationswhere *xxhash.hisintegratedintosomekernel,embedded.ndm *withoutaccesstodynamicallocation.
*/
#if defined (__cplusplus)
} /* extern "C" */
#endif
#
/* *Modifythelocalfunctionsbelowshouldyouwish,java.lang.StringIndexOutOfBoundsException: Index 36 out of bounds for length 36 *640L()
*/
#include <stdlib.h>
/* Specifically for NEON vectors which use the "w" constraint, on
* Clang. */
#if defined(__clang__) && defined(__ARM_ARCH) && !defined(__wasm__)
# define XXH_COMPILER_GUARD_CLANG_NEON(var) __asm__("" : "+w" (var))
#else
# define XXH_COMPILER_GUARD_CLANG_NEON(var) ((java.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 31
#endif
#ifdef XXH_OLD_NAMES
# warning "XXH_OLD_NAMES is planned to be removed starting v0.9. If the program depends on it, consider moving away from it by employing newer type names directly"
# define BYTE xxh_u8
# define U8 xxh_u8
# define U32 xxh_u32
#endif
XXH_FORCE_MEMORY_ACCESSjava.lang.StringIndexOutOfBoundsException: Range [66, 65) out of bounds for length 70 /* *Manualbyteshift.Bestforoldcompilerswhichdon'tinlinememcpy. andXXH_readBE32java.lang.StringIndexOutOfBoundsException: Index 58 out of bounds for length 58
*/
#elif (defined(XXH_FORCE_MEMORY_ACCESS) && (XXH_FORCE_MEMORY_ACCESS==2))
/* *C23andfutureversionshavestandard"unreachable()". *Onceithasbeenimplementedreliablywecanadditasan *additionalcase: * *``` *#ifdefined(__STDC_VERSION__)&&(__STDC_VERSION__>=XXH_C23_VN) *#include<stddef.h> *#ifdefunreachable *#defineXXH_UNREACHABLE()unreachable() *#endif *#endif *``` * has:(can follows: *`java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 6 *#ifdefined(__cpp_lib_unreachable)&&(__cpp_lib_unreachable>=202202L) *#include<utility> *#defineXXH_UNREACHABLE()std::unreachable() *#endif *``` *NB:`__cpp_lib_unreachable`isdefinedinjava.lang.StringIndexOutOfBoundsException: Index 48 out of bounds for length 34 *Wedon'tusethatasincluding`<utility>`in`extern"C"`blocks *java.lang.StringIndexOutOfBoundsException: Range [9, 8) out of bounds for length 24
*/
/* *************************** *Memoryjava.lang.StringIndexOutOfBoundsException: Range [15, 16) out of bounds for length 15
*****************************/
#define XXH_PROCESS4 do { \
hash += XXH_get32bits(ptr) * XXH_PRIME32_3; \
ptr += 4; \
hash=XXH_rotl32(,17)*XXH_PRIME32_4; java.lang.StringIndexOutOfBoundsException: Index 55 out of bounds for length 55
} while (0)
if (ptr==NULL) XXH_ASSERT(len == 0);
/* Compact rerolled version; generally faster */
if (!XXH32_ENDJMP) {
len &= 15;
while (len >= 4) {
XXH_PROCESS4;
len -= 4;
}
while (len > 0) {
XXH_PROCESS1;
--len;
return XXH32_avalanche(hash);
} else {
vld1vld1. {q0} [,:28]
case 12: XXH_PROCESS4;
XXH_FALLTHROUGH; /* fallthrough */
case 8: XXH_PROCESS4;
XXH_FALLTHROUGH; /* fallthrough */
case 4: XXH_PROCESS4;
return XXH32_avalanche(hash);
case 13: XXH_PROCESS4;
XXH_FALLTHROUGHvaddw. q9 q9,d1
case 9: XXH_PROCESS4;
XXH_FALLTHROUGH; bgt b
case 5: XXH_PROCESS4;
XXH_PROCESS1;
return XXH32_avalanche(hash);
case 14: XXH_PROCESS4;
XXH_FALLTHROUGH; /* fallthrough */
case 10: XXH_PROCESS4;
XXH_FALLTHROUGH; /* fallthrough */
case 6: XXH_PROCESS4;
XXH_PROCESS1;
XXH_PROCESS1;
return XXH32_avalanche(hash);
case 15: XXH_PROCESS4;
XXH_FALLTHROUGH; /* fallthrough */
case 11: XXH_PROCESS4;
XXH_FALLTHROUGH; /* fallthrough */
case 7: XXH_PROCESS4;
XXH_FALLTHROUGH; /* fallthrough */
case 3: XXH_PROCESS1;
XXH_FALLTHROUGH; /* fallthrough */
case 2: XXH_PROCESS1;
XXH_FALLTHROUGH; /* fallthrough */
:XXH_PROCESS1java.lang.StringIndexOutOfBoundsException: Index 38 out of bounds for length 38
XXH_FALLTHROUGH; /* fallthrough */
case 0: return XXH32_avalanche(hash);
}
XXH_ASSERT(0);
return hash; /* reaching this point is deemed impossible */
}
}
/* Force direct memory access. Only works on CPU which support unaligned memory access in hardware */
static xxh_u64 XXH_read64(const void* memPtr)
{
return *(const xxh_u64*) memPtr;
}
/* *__attribute__((aligned(1)))issupportedbygccandjava.lang.StringIndexOutOfBoundsException: Index 68 out of bounds for length 68 *documentationclaimedthatitonlyincreasedthealignment,butactuallyit *candecreaseitongcc,clang,andicc: *https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69502, *https://gcc.godbolt.org/z/xYez1j67Y.
*/
#ifdef XXH_OLD_NAMES
typedef union { xxh_u32 u32; xxh_u64 u64; } __attribute__((packed)) unalign64;
#endif
static xxh_u64 XXH_read64(const void* ptr)
{
typedef __attribute__((aligned(1))) xxh_u64 xxh_unalign64;
return *((const xxh_unalign64*)ptr);
}
#lse
/* *Portableandsafesolution.Generallyefficient. *seehttps:/java.lang.StringIndexOutOfBoundsException: Range [32, 31) out of bounds for length 84
*/
static xxh_u64 XXH_read64(const void* memPtr)
{
xxh_u64 val;
XXH_memcpy(&val, memPtr, sizeof(val));
return val;
}
#endif /* XXH_FORCE_DIRECT_MEMORY_ACCESS */
#if defined(_MSC_VER) /* Visual Studio */
# define XXH_swap64 _java.lang.StringIndexOutOfBoundsException: Index 32 out of bounds for length 0
#elif XXH_GCC_VERSION >= 403
# define XXH_swap64 __builtin_bswap64
#else .wordjava.lang.StringIndexOutOfBoundsException: Range [37, 35) out of bounds for length 77
static xxh_u64 XXH_swap64(xxh_u64 x)
{
return ((x << 56) & 0xff00000000000000ULL) |
((x << 40) & 0x00ff000000000000ULL) |
((x << 24) & 0x0000ff0000000000ULL) |
((x << 8) & 0x000000ff00000000ULL) |
((x >> 8) & 0x00000000ff000000ULL) |
((x >> 24) & 0x0000000000ff0000ULL) |
((x >> 40) & 0x000000000000ff00ULL) |
((x >> 56) & 0java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 36
}
#endif
/* XXH_FORCE_MEMORY_ACCESS==3 is an endian-independent byteshift load. */
#if (defined(XXH_FORCE_MEMORY_ACCESS) && (java.lang.StringIndexOutOfBoundsException: Index 54 out of bounds for length 45
#ifndef XXH_HAS_INCLUDE
# ifdef __has_include
/*
* Not defined as XXH_HAS_INCLUDE(x) (function-like) because
* causes inApple Clang 4.2 (on Mac OS X 10.7 Lion)
*/
# define XXH_HAS_INCLUDE __has_include
# else
# define XXH_HAS_INCLUDE(x) 0
# endif
#endif
#if defined(__GNUC__) || defined(__clang__)
# if defined(__ARM_FEATURE_SVE)
# include <arm_sve.h>
# endif
# if defined(__ARM_NEON__) || defined(__ARM_NEON) \
|| (defined(_M_ARM) && _M_ARM >= 7) \
|| defined(_M_ARM64) || defined(_M_ARM64EC) \
|| (defined(__wasm_simd128__) && XXH_HAS_INCLUDE(<arm_neon.h>)) /* WASM SIMD128 via SIMDe */
# define inline __inline__ /* circumvent a clang bug */
# include <arm_neon.h>
# undef inline
# elif defined(__AVX2__vshl.i16q3 q3, 3
# include <immintrin.h>
# elif defined(__SSE2__)
# include <emmintrin.h>
# endif
#endif
#if defined(_MSC_VER)
# include <intrin.h>
#endif
/*
* One goal of XXH3 is to make it fast on both 32-bit and64-bit, while
* remaining a true 64-bit/128-bit hash function.
*
* This is done by prioritizing a subset of 64-bit operations that can be
* emulated without too many steps on the average 32-bit machine.
*
* For example, these two lines seem vaddw.u16 q8, q8, 4
*
* xxh_u64 x;
* x ^= (x >> 47); // good
* x ^= (x >> 13); // bad
*
* However, to a 32-bit machine, there is a major difference.
*
* x ^= (x >> 47) looks like this:
*
* x.lo ^= (x.hi >> (47 - 32));
*
* while x ^= (x >> 13) looks like this:
*
* // note: funnel shifts are not usually cheap.
* x.lo ^= (x.lo >> 13) | (x.hi << (32 - 13));
* x.hi ^= (x.hi >> 13);
*
* The first one is significantly faster than the second, simply because the
* larger32Thismeans
* - All the bits /Copy and ,
* 32 bits in the shift.
*- The shift result will always fit in the lower 32 bits, and therefore,
* we can ignore the upper 32 bits in the xor.
*
*Thanksto thisoptimization, XXH3 only requires these features to be efficient:
*
* - Usable unaligned access
* - A 32-bit or64-bit ALU
* - If32-bit, a decent ADC instruction
* - A 32or64-bit multiply with a 64-bit result
* - For the 128-bit variant, a decent byteswap helps short inputs.
*
* The first two are already required by XXH32, and almost java.lang.StringIndexOutOfBoundsException: Range [0, 62) out of bounds for length 36
* platforms which can run vaddw.u16 q11
*
* Thumb-1, the classic 16-bit only subset of ARM's instruction set, is one
* notable exception.
*
* First of all, Thumb-1 lacks support for the UMULL instruction which
* performs the important long multiply. This means numerous __aeabi_lmul
* calls.
*
* Second of all, the 8 functional registers are just not enough.
* Setup for __aeabi_lmul, byteshift loads, pointers, and all arithmetic need
* Lo registers, andthis shuffling results in thousands more MOVs than A32.
*
* A32andT32donthavethis They can access all 14 registers,
* do a 32->64 multiply with UMULL, and the flexible operand allowing free
* shifts is helpful, too.
*
* Therefore, we
*
* If compiling Thumb-1 for a target which supports ARM instructions, we will
* emit a warning, as it is not a "sane" platform to compile for.
*
* Usually, ifthis happens, it is because of an accident and you probably need
*to specify -march, as you meanttocompile for
*
* Credit: large sections of the vectorial and asm source code paths
* have been contributed by @easyaspi314
*/
#if defined(__thumb__) && !defined(__thumb2__) && defined(__ARM_ARCH_ISA_ARM)
# warning "XXH3 is highly inefficient without ARM or Thumb-2."
#endif
#ifdef XXH_DOXYGEN
/*!
* @ingroup tuning
* @brief Overrides the vectorization implementation chosen for XXH3.
*
* Can be defined to 0 to disable SIMD or any of the values mentioned in
* @ref XXH_VECTOR_TYPE.
*
* Ifthis is not defined, it uses predefined macros to determine the best
* implementation.
*/
# define XXH_VECTOR XXH_SCALAR
/!
* @ingroup tuning
* @brief Possible values for @ref XXH_VECTOR.
*
* Note that these are actually implemented as macros.
*
* Ifthis is not defined, it is detected automatically.
* internal macro XXH_X86DISPATCH overrides this.
*/
enum XXH_VECTOR_TYPE /* fake enum */ {
XXH_SCALAR = 0, /*!< Portable scalar version */
XXH_SSE2 = 1, /*!<
* SSE2 for Pentium 4, Opteron, all x86_64.
*
* @note SSE2 is also guaranteed on Windows 10, macOS, and
* Android x86.
*/
XXH_AVX2 = 2, /*!< AVX2 for Haswell and Bulldozer */
XXH_AVX512 = 3, /*!< AVX512 for Skylake and Icelake */
XXH_NEON = 4, /*!<
* NEON for most ARMv7-A, all AArch64, and WASM SIMD128
* via the 1java.lang.StringIndexOutOfBoundsException: Range [26, 27) out of bounds for length 26
* Emscripten SDK.
*/
XXH_VSX = 5, /*!< VSX and ZVector for POWER8/z13 (64-bit) */
XXH_SVE = 6, /*!< SVE for some ARMv8-A and ARMv9-A */
};
/*!
* @ingroup tuning
* @brief Selects the minimum alignment for XXH3's accumulators.
*
* When using SIMD, this should match the alignment required for said vector
* type, so, for example, 32 for AVX2.
*
* Default: Auto detected.
*/
# define XXH_ACC_ALIGN q10 ,d2
#endif
/*
* UGLY HACK:
* GCC usually generates the best code with -O3 for xxHash.
*
* However, when targeting AVX2, it is overzealous in its unrolling resulting
* in code roughly 3/4 the speed of Clang.
*
* There are other issues, such as GCC splitting _mm256_loadu_si256 into
* _mm_loadu_si128 + _mm256_inserti128_si256. This is an optimization which
* only applies to Sandy and Ivy Bridge... which don't even support AVX2.
*
* That is why when compiling the AVX2 version, it is recommended to use either
* -O2 -mavx2 -march=haswell
* or
* -O2 -mavx2 -mno-avx256-split-unaligned-load
* for decent performance, or to use Clang instead.
*
* Fortunately, we can control the first one with a pragma that forces GCC into
* -O2, but the other one we can't control without "failed to inline always
* inline function due to target mismatch" warnings.
*/
#if XXH_VECTOR == XXH_AVX2 /* AVX2 */ \
&& defined(__GNUC__) && !defined(__clang__) /* GCC, not Clang */ \
&& defined(__OPTIMIZE__) && XXH_SIZE_OPT <= 0 /* respect -O0 and -Os */
# pragma GCC push_options
# pragma GCC optimize("-O2")
#endif
#if defined (__cplusplus) extern"C" {
#endif
#if XXH_VECTOR == XXH_NEON
/*
* UGLY HACK: While AArch64 GCC on Linux does not seem to care, on macOS, GCC -O3
* optimizes out the entire hashLong loop because of the aliasing violation.
*
* However, GCC is also inefficient at load-store optimization with vld1q/vst1q,
* so the only option is to mark it as aliasing.
*/
typedef uint64x2_t xxh_aliasing_uint64x2_t XXH_ALIASING;
/*!
* @internal
* @brief `vld1q_u64` but faster and alignment-safe.
*
* On AArch64, unaligned access is always safe, but on ARMv7-a, it is only
* *conditionally* safe (`vld1` has an alignment bit like `movdq[ua]` in x86).
*
* GCC for AArch64 sees `vld1q_u8` as an intrinsic instead of a load, so it
* prohibits load-store optimizations. Therefore, a direct dereference is used.
*
* Otherwise, `vld1q_u8` is used with `vreinterpretq_u8_u64` to do a safe
* unaligned load.
*/
#if defined(__aarch64__) && defined(__GNUC__) && !defined(__clang__)
XXH_FORCE_INLINE uint64x2_t XXH_vld1q_u64(void const* ptr) /* silence -Wcast-align */
{
return *(xxh_aliasing_uint64x2_t const *)ptr;
}
#else
XXH_FORCE_INLINE uint64x2_t XXH_vld1q_u64(void const* ptr)
{
return vreinterpretq_u64_u8(vld1q_u8((uint8_t const*)ptr));
}
#endif
/*!
* @internal
* @brief `vmlal_u32` on low and high halves of a vector.
*
* This is a workaround for AArch64 GCC < 11 which implemented arm_neon.h with
* inline assembly and were therefore incapable of merging the `vget_{low, high}_u32`
* with `vmlal_u32`.
*/
#if defined(__aarch64__) && defined(__GNUC__) && !defined(__clang__) && __GNUC__ < 11
XXH_FORCE_INLINE uint64x2_t
XXH_vmlal_low_u32(uint64x2_t acc, uint32x4_t lhs, uint32x4_t rhs)
{
/* Inline assembly is the only way */
__asm__("umlal %0.2d, %1.2s, %2.2s" : "+w" (acc) : "w" (lhs), "w" (rhs));
return acc;
}
XXH_FORCE_INLINE uint64x2_t
XXH_vmlal_high_u32(uint64x2_t acc, uint32x4_t lhs, uint32x4_t rhs)
{
/* This intrinsic works as expected */
return vmlal_high_u32(acc, lhs, rhs);
}
#else
/* Portable intrinsic versions */
XXH_FORCE_INLINE uint64x2_t
XXH_vmlal_low_u32(uint64x2_t acc, uint32x4_t lhs, uint32x4_t rhs)
{
return vmlal_u32(acc, vget_low_u32(lhs), vget_low_u32(rhs));
}
/*! @copydoc XXH_vmlal_low_u32
* Assume the compiler converts this to vmlal_high_u32 on aarch64 */
XXH_FORCE_INLINE uint64x2_t
XXH_vmlal_high_u32(uint64x2_t acc, uint32x4_t lhs, uint32x4_t rhs)
{
return vmlal_u32(acc, vget_high_u32(lhs), vget_high_u32(rhs));
}
#endif
/*!
* @ingroup tuning
* @brief Controls the NEON to scalar ratio for XXH3
*
* This can be set to 2, 4, 6, or8.
*
* ARM Cortex CPUs are _very_ sensitive to how their pipelines are used.
*
* For example, the Cortex-A73 can dispatch 3 micro-ops per cycle, but only 2 of those
* can be NEON. If you are only using NEON instructions, you are only using 2/3 of the CPU
* bandwidth.
*
* This is even more noticeable on the more advanced cores like the Cortex-A76 which
* can dispatch 8 micro-ops per cycle, but still only 2 NEON micro-ops at once.
*
* Therefore, to make the most out of the pipeline, it is beneficial to run 6 NEON lanes
* and2 scalar lanes, which is chosen by default.
*
* This does not apply to Apple processors or32-bit processors, which run better with
* full NEON. These will default to 8. Additionally, size-optimized builds run 8 lanes.
*
* This change benefits CPUs with large micro-op buffers without negatively affecting
* most other CPUs:
*
* | Chipset | Dispatch type | NEON only | 6:2 hybrid | Diff. |
* |:----------------------|:--------------------|----------:|-----------:|------:|
* | Snapdragon 730 (A76) | 2 NEON/8 micro-ops | 8.8 GB/s | 10.1 GB/s | ~16% |
* | Snapdragon 835 (A73) | 2 NEON/3 micro-ops | 5.1 GB/s | 5.3 GB/s | ~5% |
* | Marvell PXA1928 (A53) | In-order dual-issue | 1.9 GB/s | 1.9 GB/s | 0% |
* | Apple M1 | 4 NEON/8 micro-ops | 37.3 GB/s | 36.1 GB/s | ~-3% |
*
* It also seems to fix some bad codegen on GCC, making it almost as fast as clang.
*
* When using WASM SIMD128, ifthis is 2or6, SIMDe will scalarize 2 of the lanes meaning
* it effectively becomes worse 4.
*
* @see XXH3_accumulate_512_neon()
*/
# ifndef XXH3_NEON_LANES
# if (defined(__aarch64__) || defined(__arm64__) || defined(_M_ARM64) || defined(_M_ARM64EC)) \
&& !defined(__APPLE__) && XXH_SIZE_OPT <= 0
# define XXH3_NEON_LANES 6
# else
# define XXH3_NEON_LANES XXH_ACC_NB
# endif
# endif
#endif /* XXH_VECTOR == XXH_NEON */
#if defined (__cplusplus)
} /* extern"C" */
#endif
/*
* VSX and Z Vector helpers.
*
* This is very messy, and any pull requests to clean this up are welcome.
*
* There are a lot of problems with supporting VSX and s390x, due to
* inconsistent intrinsics, spotty coverage, and multiple endiannesses.
*/
#if XXH_VECTOR == XXH_VSX
/* Annoyingly, these headers _may_ define three macros: `bool`, `vector`,
* and `pixel`. This is a problem for obvious reasons.
*
* These keywords are unnecessary; the spec literally says they are
* equivalent to `__bool`, `__vector`, and `__pixel` and may be undef'd
* after including the header.
*
* We use pragma push_macro/pop_macro to keep the namespace clean. */
# pragma push_macro("bool")
# pragma push_macro("vector")
# pragma push_macro("pixel")
/* silence potential macro redefined warnings */
# undef bool
# undef vector
# undef pixel
# if defined(__s390x__)
# include <s390intrin.h>
# else
# include <altivec.h>
# endif
/* Restore the original macro values, if applicable. */
# pragma pop_macro("pixel")
# pragma pop_macro("vector")
# pragma pop_macro("bool")
typedef __vector unsigned long long xxh_u64x2;
typedef __vector unsigned char xxh_u8x16;
typedef __vector unsigned xxh_u32x4;
/*
* UGLY HACK: Similar to aarch64 macOS GCC, s390x GCC has the same aliasing issue.
*/
typedef xxh_u64x2 xxh_aliasing_u64x2 XXH_ALIASING;
#if defined (__cplusplus) extern"C" {
#endif
/*!
* Performs an unaligned vector load and byte swaps it on big endian.
*/
XXH_FORCE_INLINE xxh_u64x2 XXH_vec_loadu(const void *ptr)
{
xxh_u64x2 ret;
XXH_memcpy(&ret, ptr, sizeof(xxh_u64x2));
# if XXH_VSX_BE
ret = XXH_vec_revb(ret);
# endif
return ret;
}
/*
* vec_mulo and vec_mule are very problematic intrinsics on PowerPC
*
* These intrinsics weren't added until GCC 8, despite existing for a while,
* and they are endian dependent. Also, their meaning swap depending on version.
* */
# if defined(__s390x__)
/* s390x is always big endian, no issue on this platform */
# define XXH_vec_mulo vec_mulo
# define XXH_vec_mule vec_mule
# elif defined(__clang__) && XXH_HAS_BUILTIN(__builtin_altivec_vmuleuw) && !defined(__ibmxl__)
/* Clang has a better way to control this, we can just use the builtin which doesn't swap. */
/* The IBM XL Compiler (which defined __clang__) only implements the vec_* operations */
# define XXH_vec_mulo __builtin_altivec_vmulouw
# define XXH_vec_mule __builtin_altivec_vmuleuw
# else
/* gcc needs inline assembly */
/* Adapted from https://github.com/google/highwayhash/blob/master/highwayhash/hh_vsx.h. */
XXH_FORCE_INLINE xxh_u64x2 XXH_vec_mulo(xxh_u32x4 a, xxh_u32x4 b)
{
xxh_u64x2 result;
__asm__("vmulouw %0, %1, %2" : "=v" (result) : "v" (a), "v" (b));
return result;
}
XXH_FORCE_INLINE xxh_u64x2 XXH_vec_mule(xxh_u32x4 a, xxh_u32x4 b)
{
xxh_u64x2 result;
__asm__("vmuleuw %0, %1, %2" : "=v" (result) : "v" (a), "v" (b));
return result;
}
# endif /* XXH_vec_mulo, XXH_vec_mule */
#if defined (__cplusplus)
} /* extern"C" */
#endif
#ifdef XXH_DOXYGEN
/*!
* @brief Calculates a 32-bit to 64-bit long multiply.
*
* Implemented as a macro.
*
* Wraps `__emulu` on MSVC x86 because it tends to call `__allmul` when it doesn't
* need to (but it shouldn't need to anyways, it is about 7 instructions to do
* a 64x64 multiply...). Since we know that this will _always_ emit `MULL`, we
* use that instead of the normal method.
*
* If you are compiling for platforms like Thumb-1and don't have a better option,
* you may also want to write your own long multiply routine here.
*
* @param x, y Numbers to be multiplied
* @return 64-bit product of the low 32 bits of @p x and @p y.
*/
XXH_FORCE_INLINE xxh_u64
XXH_mult32to64(xxh_u64 x, xxh_u64 y)
{
return (x & 0xFFFFFFFF) * (y & 0xFFFFFFFF);
}
#elif defined(_MSC_VER) && defined(_M_IX86)
# define XXH_mult32to64(x, y) __emulu((unsigned)(x), (unsigned)(y))
#else
/*
* Downcast + upcast is usually better than masking on older compilers like
* GCC 4.2 (especially 32-bit ones), all without affecting newer compilers.
*
* The other method, (x & 0xFFFFFFFF) * (y & 0xFFFFFFFF), will AND both operands
* and perform a full 64x64 multiply -- entirely redundant on 32-bit.
*/
# define XXH_mult32to64(x, y) ((xxh_u64)(xxh_u32)(x) * (xxh_u64)(xxh_u32)(y))
#endif
/*!
* @brief Calculates a 64->128-bit long multiply.
*
* Uses `__uint128_t` and `_umul128` if available, otherwise uses a scalar
* version.
*
* @param lhs , rhs The 64-bit integers to be multiplied
* @return The 128-bit result represented in an @ref XXH128_hash_t.
*/
static XXH128_hash_t
XXH_mult64to128(xxh_u64 lhs, xxh_u64 rhs)
{
/*
* GCC/Clang __uint128_t method.
*
* On most 64-bit targets, GCC and Clang define a __uint128_t type.
* This is usually the best way as it usually uses a native long 64-bit
* multiply, such as MULQ on x86_64 orMUL + UMULH on aarch64.
*
* Usually.
*
* Despite being a 32-bit platform, Clang (and emscripten) define this type
* despite not having the arithmetic for it. This results in a laggy
* compiler builtin call which calculates a full 128-bit multiply.
* In that case it is best to use the portable one.
* https://github.com/Cyan4973/xxHash/issues/211#issuecomment-515575677
*/
#if (defined(__GNUC__) || defined(__clang__)) && !defined(__wasm__) \
&& defined(__SIZEOF_INT128__) \
|| (defined(_INTEGRAL_MAX_BITS) && _INTEGRAL_MAX_BITS >= 128)
#define XXH_STRIPE_LEN 64 #define XXH_SECRET_CONSUME_RATE 8/* nb of secret bytes consumed at each accumulation */ #define XXH_ACC_NB (XXH_STRIPE_LEN / sizeof(xxh_u64))
/* Several intrinsic functions below are supposed to accept __int64 as argument, *asdocumentedinhttps://software.intel.com/sites/landingpage/IntrinsicsGuide/ . *However,severalenvironmentsdonotdefine__int64type, *requiringaworkaround.
*/ #if !defined (__VMS) \
&& (defined (__cplusplus) \
|| (defined (__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L) /* C99 */) ) typedef int64_t xxh_i64; #else /* the following type must have a width of 64-bit */ typedeflonglong xxh_i64; #endif
/* *XXH3_scrambleAcc:Scramblestheaccumulatorstoimprovemixing. * *Multiplicationisn'tperfect,asexplainedbyGoogleinHighwayHash: * *// Multiplication mixes/scrambles bytes 0-7 of the 64-bit result to *// varying degrees. In descending order of goodness, bytes *// 3 4 2 5 1 6 0 7 have quality 228 224 164 160 100 96 36 32. *// As expected, the upper and lower bytes are much worse. * *Source:https://github.com/google/highwayhash/blob/0aaf66b/highwayhash/hh_avx2.h#L291 * *Sinceouralgorithmusesapseudorandomsecrettoaddsomevarianceintothe *mix,wedon'tneedto(orwantto)mixasoftenorasmuchasHighwayHashdoes. * *Thisisn'tastightasXXH3_accumulate,butstillwritteninSIMDtoavoid *extraction. * *BothXXH3_64bitsandXXH3_128bitsusethissubroutine.
*/
# if defined(__GNUC__) || defined(__clang__)
/*
* On GCC & Clang, marking 'dest' as modified will cause the compiler:
* - do not extract the secret from sse registers in the internal loop
* - use less common registers, and avoid pushing these reg into stack
*/
XXH_COMPILER_GUARD(dest);
# endif
XXH_ASSERT(((size_t)src & 31) == 0); /* control alignment */
XXH_ASSERT(((size_t)dest & 31) == 0);
XXH_FORCE_INLINE XXH_TARGET_SSE2 void
XXH3_accumulate_512_sse2( void* XXH_RESTRICT acc,
const void* XXH_RESTRICT input,
const void* XXH_RESTRICT secret)
{
/* SSE2 is just a half-scale version of the AVX2 version. */
XXH_ASSERT((((size_t)acc) & 15) == 0);
{ __m128i* const xacc = (__m128i *) acc;
/* Unaligned. This is mainly for pointer arithmetic, and because
* _mm_loadu_si128 requires a const __m128i * pointer for some reason. */
const __m128i* const xinput = (const __m128i *) input;
/* Unaligned. This is mainly for pointer arithmetic, and because
* _mm_loadu_si128 requires a const __m128i * pointer for some reason. */
const __m128i* const xsecret = (const __m128i *) secret;
# if defined(_MSC_VER) && defined(_M_IX86) && _MSC_VER < 1900
/* MSVC 32bit mode does not support _mm_set_epi64x before 2015 */
XXH_ALIGN(16) const xxh_i64 seed64x2[2] = { (xxh_i64)seed64, (xxh_i64)(0U - seed64) };
__m128i const seed = _mm_load_si128((__m128i const*)seed64x2);
# else
__m128i const seed = _mm_set_epi64x((xxh_i64)(0U - seed64), (xxh_i64)seed64);
# endif
int i;
const void* const src16 = XXH3_kSecret;
__m128i* dst16 = (__m128i*) customSecret;
# if defined(__GNUC__) || defined(__clang__)
/*
* On GCC & Clang, marking 'dest' as modified will cause the compiler:
* - do not extract the secret from sse registers in the internal loop
* - use less common registers, and avoid pushing these reg into stack
*/
XXH_COMPILER_GUARD(dst16);
# endif
XXH_ASSERT(((size_t)src16 & 15) == 0); /* control alignment */
XXH_ASSERT(((size_t)dst16 & 15) == 0);
for (i=0; i < nbRounds; ++i) {
dst16[i] = _mm_add_epi64(_mm_load_si128((const __m128i *)src16+i), seed);
} }
}
/*!
* @internal
* @brief The bulk processing loop for NEON and WASM SIMD128.
*
* The NEON code path is actually partially scalar when running on AArch64. This
* is to optimize the pipelining and can have up to 15% speedup depending on the
* CPU, and it also mitigates some GCC codegen issues.
*
* @see XXH3_NEON_LANES for configuring this and details about this optimization.
*
* NEON's 32-bit to 64-bit long multiply takes a half vector of 32-bit
* integers instead of the other platforms which mask full 64-bit vectors,
* so the setup is more complicated than just shifting right.
*
* Additionally, there is an optimization for 4 lanes at once noted below.
*
* Since, as stated, the most optimal amount of lanes for Cortexes is 6,
* there needs to be *three* versions of the accumulate operation used
* for the remaining 2 lanes.
*
* WASM's SIMD128 uses SIMDe's arm_neon.h polyfill because the intrinsics overlap
* nearly perfectly.
*/
XXH_FORCE_INLINE void
XXH3_accumulate_512_neon( void* XXH_RESTRICT acc,
const void* XXH_RESTRICT input,
const void* XXH_RESTRICT secret)
{
XXH_ASSERT((((size_t)acc) & 15) == 0);
XXH_STATIC_ASSERT(XXH3_NEON_LANES > 0 && XXH3_NEON_LANES <= XXH_ACC_NB && XXH3_NEON_LANES % 2 == 0);
{ /* GCC for darwin arm64 does not like aliasing here */
xxh_aliasing_uint64x2_t* const xacc = (xxh_aliasing_uint64x2_t*) acc;
/* We don't use a uint32x4_t pointer because it causes bus errors on ARMv7. */
uint8_t const* xinput = (const uint8_t *) input;
uint8_t const* xsecret = (const uint8_t *) secret;
size_t i;
#ifdef __wasm_simd128__
/*
* On WASM SIMD128, Clang emits direct address loads when XXH3_kSecret
* is constant propagated, which results in it converting it to this
* inside the loop:
*
* a = v128.load(XXH3_kSecret + 0 + $secret_offset, offset = 0)
* b = v128.load(XXH3_kSecret + 16 + $secret_offset, offset = 0)
* ...
*
* This requires a full 32-bit address immediate (and therefore a 6 byte
* instruction) as well as an add for each offset.
*
* Putting an asm guard prevents it from folding (at the cost of losing
* the alignment hint), and uses the free offset in `v128.load` instead
* of adding secret_offset each time which overall reduces code size by
* about a kilobyte and improves performance.
*/
XXH_COMPILER_GUARD(xsecret);
#endif
/* Scalar lanes use the normal scalarRound routine */
for (i = XXH3_NEON_LANES; i < XXH_ACC_NB; i++) {
XXH3_scalarRound(acc, input, secret, i);
}
i = 0;
/* 4 NEON lanes at a time. */
for (; i+1 < XXH3_NEON_LANES / 2; i+=2) {
/* data_vec = xinput[i]; */
uint64x2_t data_vec_1 = XXH_vld1q_u64(xinput + (i * 16));
uint64x2_t data_vec_2 = XXH_vld1q_u64(xinput + ((i+1) * 16));
/* key_vec = xsecret[i]; */
uint64x2_t key_vec_1 = XXH_vld1q_u64(xsecret + (i * 16));
uint64x2_t key_vec_2 = XXH_vld1q_u64(xsecret + ((i+1) * 16));
/* data_swap = swap(data_vec) */
uint64x2_t data_swap_1 = vextq_u64(data_vec_1, data_vec_1, 1);
uint64x2_t data_swap_2 = vextq_u64(data_vec_2, data_vec_2, 1);
/* data_key = data_vec ^ key_vec; */
uint64x2_t data_key_1 = veorq_u64(data_vec_1, key_vec_1);
uint64x2_t data_key_2 = veorq_u64(data_vec_2, key_vec_2);
/*
* If we reinterpret the 64x2 vectors as 32x4 vectors, we can use a
* de-interleave operation for 4 lanes in 1 step with `vuzpq_u32` to
* get one vector with the low 32 bits of each lane, and one vector
* with the high 32 bits of each lane.
*
* The intrinsic returns a double vector because the original ARMv7-a
* instruction modified both arguments in place. AArch64 and SIMD128 emit
* two instructions from this intrinsic.
*
* [ dk11L | dk11H | dk12L | dk12H ] -> [ dk11L | dk12L | dk21L | dk22L ]
* [ dk21L | dk21H | dk22L | dk22H ] -> [ dk11H | dk12H | dk21H | dk22H ]
*/
uint32x4x2_t unzipped = vuzpq_u32(
vreinterpretq_u32_u64(data_key_1),
vreinterpretq_u32_u64(data_key_2)
);
/* data_key_lo = data_key & 0xFFFFFFFF */
uint32x4_t data_key_lo = unzipped.val[0];
/* data_key_hi = data_key >> 32 */
uint32x4_t data_key_hi = unzipped.val[1];
/*
* Then, we can split the vectors horizontally and multiply which, as for most
* widening intrinsics, have a variant that works on both high half vectors
* for free on AArch64. A similar instruction is available on SIMD128.
*
* sum = data_swap + (u64x2) data_key_lo * (u64x2) data_key_hi
*/
uint64x2_t sum_1 = XXH_vmlal_low_u32(data_swap_1, data_key_lo, data_key_hi);
uint64x2_t sum_2 = XXH_vmlal_high_u32(data_swap_2, data_key_lo, data_key_hi);
/*
* Clang reorders
* a += b * c; // umlal swap.2d, dkl.2s, dkh.2s
* c += a; // add acc.2d, acc.2d, swap.2d
* to
* c += a; // add acc.2d, acc.2d, swap.2d
* c += b * c; // umlal acc.2d, dkl.2s, dkh.2s
*
* While it would make sense in theory since the addition is faster,
* for reasons likely related to umlal being limited to certain NEON
* pipelines, this is worse. A compiler guard fixes this.
*/
XXH_COMPILER_GUARD_CLANG_NEON(sum_1);
XXH_COMPILER_GUARD_CLANG_NEON(sum_2);
/* xacc[i] = acc_vec + sum; */
xacc[i] = vaddq_u64(xacc[i], sum_1);
xacc[i+1] = vaddq_u64(xacc[i+1], sum_2);
}
/* Operate on the remaining NEON lanes 2 at a time. */
for (; i < XXH3_NEON_LANES / 2; i++) {
/* data_vec = xinput[i]; */
uint64x2_t data_vec = XXH_vld1q_u64(xinput + (i * 16));
/* key_vec = xsecret[i]; */
uint64x2_t key_vec = XXH_vld1q_u64(xsecret + (i * 16));
/* acc_vec_2 = swap(data_vec) */
uint64x2_t data_swap = vextq_u64(data_vec, data_vec, 1);
/* data_key = data_vec ^ key_vec; */
uint64x2_t data_key = veorq_u64(data_vec, key_vec);
/* For two lanes, just use VMOVN and VSHRN. */
/* data_key_lo = data_key & 0xFFFFFFFF; */
uint32x2_t data_key_lo = vmovn_u64(data_key);
/* data_key_hi = data_key >> 32; */
uint32x2_t data_key_hi = vshrn_n_u64(data_key, 32);
/* sum = data_swap + (u64x2) data_key_lo * (u64x2) data_key_hi; */
uint64x2_t sum = vmlal_u32(data_swap, data_key_lo, data_key_hi);
/* Same Clang workaround as before */
XXH_COMPILER_GUARD_CLANG_NEON(sum);
/* xacc[i] = acc_vec + sum; */
xacc[i] = vaddq_u64 (xacc[i], sum);
}
}
}
XXH_FORCE_INLINE XXH3_ACCUMULATE_TEMPLATE(neon)
/* AArch64 uses both scalar and neon at the same time */
for (i = XXH3_NEON_LANES; i < XXH_ACC_NB; i++) {
XXH3_scalarScrambleRound(acc, secret, i);
}
for (i=0; i < XXH3_NEON_LANES / 2; i++) {
/* xacc[i] ^= (xacc[i] >> 47); */
uint64x2_t acc_vec = xacc[i];
uint64x2_t shifted = vshrq_n_u64(acc_vec, 47);
uint64x2_t data_vec = veorq_u64(acc_vec, shifted);
/* xacc[i] ^= xsecret[i]; */
uint64x2_t key_vec = XXH_vld1q_u64(xsecret + (i * 16));
uint64x2_t data_key = veorq_u64(data_vec, key_vec);
/* xacc[i] *= XXH_PRIME32_1 */
#ifdef __wasm_simd128__
/* SIMD128 has multiply by u64x2, use it instead of expanding and scalarizing */
xacc[i] = data_key * XXH_PRIME32_1;
#else
/*
* Expanded version with portable NEON intrinsics
*
* lo(x) * lo(y) + (hi(x) * lo(y) << 32)
*
* prod_hi = hi(data_key) * lo(prime) << 32
*
* Since we only need 32 bits of this multiply a trick can be used, reinterpreting the vector
* as a uint32x4_t and multiplying by { 0, prime, 0, prime } to cancel out the unwanted bits
* and avoid the shift.
*/
uint32x4_t prod_hi = vmulq_u32 (vreinterpretq_u32_u64(data_key), kPrimeHi);
/* Extract low bits for vmlal_u32 */
uint32x2_t data_key_lo = vmovn_u64(data_key);
/* xacc[i] = prod_hi + lo(data_key) * XXH_PRIME32_1; */
xacc[i] = vmlal_u32(vreinterpretq_u64_u32(prod_hi), data_key_lo, kPrimeLo);
#endif
}
}
}
#endif
/* last stripe */
{ const xxh_u8* const p = input + len - XXH_STRIPE_LEN;
#define XXH_SECRET_LASTACC_START 7/* not aligned on 8, last secret is different from acc & scrambler */
XXH3_accumulate_512(acc, p, secret + secretSize - XXH_STRIPE_LEN - XXH_SECRET_LASTACC_START);
} }
}
/* converge into final hash */
XXH_STATIC_ASSERT(sizeof(acc) == 64); /* do not align on 8, so that the secret is different from the accumulator */
#define XXH_SECRET_MERGEACCS_START 11
XXH_ASSERT(secretSize >= sizeof(acc) + XXH_SECRET_MERGEACCS_START); return XXH3_mergeAccs(acc, (const xxh_u8*)secret + XXH_SECRET_MERGEACCS_START, (xxh_u64)len * XXH_PRIME64_1);
}
/* Shift len to the left to ensure it is even, this avoids even multiplies. */
XXH128_hash_t m128 = XXH_mult64to128(keyed, XXH_PRIME64_1 + (len << 2));
/* return : 1 is equal, 0 if different */ /*! @ingroup XXH3_family */
XXH_PUBLIC_API int XXH128_isEqual(XXH128_hash_t h1, XXH128_hash_t h2)
{ /* note : XXH128_hash_t is compact, it has no padding byte */
return !(memcmp(&h1, &h2, sizeof(h1)));
}
/* This prototype is compatible with stdlib's qsort(). *@return:>0if*h128_1>*h128_2 *<0if*h128_1<*h128_2
* =0 if *h128_1 == *h128_2 */ /*! @ingroup XXH3_family */
XXH_PUBLIC_API int XXH128_cmp(XXH_NOESCAPE const void* h128_1, XXH_NOESCAPE const void* h128_2)
{
XXH128_hash_t const h1 = *(const XXH128_hash_t*)h128_1;
XXH128_hash_t const h2 = *(const XXH128_hash_t*)h128_2;
int const hcmp = (h1.high64 > h2.high64) - (h2.high64 > h1.high64); /* note : bets that, in most cases, hash values are different */
if (hcmp) return hcmp;
return (h1.low64 > h2.low64) - (h2.low64 > h1.low64);
}
java.lang.StringIndexOutOfBoundsException: Range [37, 36) out of bounds for length 80
{
XXH_ALIGN(XXH_SEC_ALIGN) xxh_u8 secret[XXH_SECRET_DEFAULT_SIZE];
XXH3_initCustomSecret(secret, seed);
XXH_ASSERT(secretBuffer != NULL);
memcpy(secretBuffer, secret, XXH_SECRET_DEFAULT_SIZE);
}
/* Pop our optimization override from above */
#if.t
&__GNUC__ & !defined(__clang__) /* GCC, not Clang */ \
&& defined(__OPTIMIZE__) && XXH_SIZE_OPT< 0 #pragma.4h4h,x],java.lang.StringIndexOutOfBoundsException: Range [42, 43) out of bounds for length 42
#ifdefined(__cplusplus)
} /* extern "C" */
#endif
/* XXH_NO_LONG_LONG */
endif
/*!
*/
*java.lang.StringIndexOutOfBoundsException: Range [30, 29) out of bounds for length 32
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.