8 lines
34 KiB
JavaScript
8 lines
34 KiB
JavaScript
|
|
/**
|
||
|
|
* Minified by jsDelivr using Terser v5.19.2.
|
||
|
|
* Original file: /npm/lzma@2.3.2/src/lzma_worker.js
|
||
|
|
*
|
||
|
|
* Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files
|
||
|
|
*/
|
||
|
|
var LZMA=function(){"use strict";var e=3,r="function"==typeof setImmediate?setImmediate:setTimeout,t=4294967296,o=[4294967295,-t],n=[0,-0x8000000000000000],s=[0,0],i=[1,0];function _(r,t){postMessage({action:e,cbn:t,result:r})}function a(e){var r=[];return r[e-1]=void 0,r}function c(e,r){return m(e[0]+r[0],e[1]+r[1])}function u(e,r){return function(e,r){var o;o=r,r<0&&(o+=t);return[o,e*t]}(~~Math.max(Math.min(e[1]/t,2147483647),-2147483648)&~~Math.max(Math.min(r[1]/t,2147483647),-2147483648),h(e)&h(r))}function f(e,r){var t,o;return e[0]==r[0]&&e[1]==r[1]?0:(t=e[1]<0,o=r[1]<0,t&&!o?-1:!t&&o?1:B(e,r)[1]<0?-1:1)}function m(e,r){var o,n;for(e%=0x10000000000000000,r=(r%=0x10000000000000000)-(o=r%t)+(n=Math.floor(e/t)*t),e=e-n+o;e<0;)e+=t,r-=t;for(;e>4294967295;)e-=t,r+=t;for(r%=0x10000000000000000;r>0x7fffffff00000000;)r-=0x10000000000000000;for(;r<-0x8000000000000000;)r+=0x10000000000000000;return[e,r]}function d(e,r){return e[0]==r[0]&&e[1]==r[1]}function p(e){return e>=0?[e,0]:[e+t,-t]}function h(e){return e[0]>=2147483648?~~Math.max(Math.min(e[0]-t,2147483647),-2147483648):~~Math.max(Math.min(e[0],2147483647),-2147483648)}function P(e){return e<=30?1<<e:P(30)*P(e-30)}function l(e,r){var o,i,_,a;if(r&=63,d(e,n))return r?s:e;if(e[1]<0)throw new Error("Neg");return a=P(r),i=e[1]*a%0x10000000000000000,(i+=o=(_=e[0]*a)-_%t)>=0x8000000000000000&&(i-=0x10000000000000000),[_-=o,i]}function v(e,r){var t;return t=P(r&=63),m(Math.floor(e[0]/t),e[1]/t)}function B(e,r){return m(e[0]-r[0],e[1]-r[1])}function S(e,r){return e.buf=r,e.pos=0,e.count=r.length,e}function g(e){return e.pos>=e.count?-1:255&e.buf[e.pos++]}function k(e,r,t,o){return e.pos>=e.count?-1:(o=Math.min(o,e.count-e.pos),w(e.buf,e.pos,r,t,o),e.pos+=o,o)}function R(e){return e.buf=a(32),e.count=0,e}function M(e){var r=e.buf;return r.length=e.count,r}function D(e,r){e.buf[e.count++]=r<<24>>24}function b(e,r,t,o){w(r,t,e.buf,e.count,o),e.count+=o}function w(e,r,t,o,n){for(var s=0;s<n;++s)t[o+s]=e[r+s]}function E(e,r,t,n,i){var _,c;if(f(n,o)<0)throw new Error("invalid length "+n);for(e.length_0=n,_=function(e){var r;for(e._repDistances=a(4),e._optimum=[],e._rangeEncoder={},e._isMatch=a(192),e._isRep=a(12),e._isRepG0=a(12),e._isRepG1=a(12),e._isRepG2=a(12),e._isRep0Long=a(192),e._posSlotEncoder=[],e._posEncoders=a(114),e._posAlignEncoder=Re({},4),e._lenEncoder=me({}),e._repMatchLenEncoder=me({}),e._literalEncoder={},e._matchDistances=[],e._posSlotPrices=[],e._distancesPrices=[],e._alignPrices=a(16),e.reps=a(4),e.repLens=a(4),e.processedInSize=[s],e.processedOutSize=[s],e.finished=[0],e.properties=a(5),e.tempPrices=a(128),e._longestMatchLength=0,e._matchFinderType=1,e._numDistancePairs=0,e._numFastBytesPrev=-1,e.backRes=0,r=0;r<4096;++r)e._optimum[r]={};for(r=0;r<4;++r)e._posSlotEncoder[r]=Re({},6);return e}({}),function(e,r){!function(e,r){e._dictionarySize=r;for(var t=0;r>1<<t;++t);e._distTableSize=2*t}(r,1<<e.s),r._numFastBytes=e.f,function(e,r){var t=e._matchFinderType;e._matchFinderType=r,e._matchFinder&&t!=e._matchFinderType&&(e._dictionarySizePrev=-1,e._matchFinder=null)}(r,e.m),r._numLiteralPosStateBits=0,r._numLiteralContextBits=3,r._posStateBits=2,r._posStateMask=3}(i,_),_._writeEndMark=void 0===LZMA.disableEndMark,function(e,r){e.properties[0]=9*(5*e._posStateBits+e._numLiteralPosStateBits)+e._numLiteralContextBits<<24>>24;for(var t=0;t<4;++t)e.properties[1+t]=e._dictionarySize>>8*t<<24>>24;b(r,e.properties,0,5)}(_,t),c=0;c<64;c+=8)D(t,255&h(v(n,c)));e.chunker=(_._needReleaseMFStream=0,_._inStream=r,_._finished=0,function(e){var r,t;e._matchFinder||(r={},t=4,e._matchFinderType||(t=2),function(e,r){e.HASH_ARRAY=r>2,e.HASH_ARRAY?(e.kNumHashDirectBytes=0,e.kMinMatchCheck=4,e.kFixHashSize=66560):(e.kNumHashDirectBytes=2,e.kMinMatchCheck=3,e.kFixHashSize=0)}(r,t),e._matchFinder=r);if(function(e,r,t){var o,n;if(null!=e.m_Coders&&e.m_NumPrevBits==t&&e.m_NumPosBits==r)return;for(e.m_NumPosBits=r,e.m_PosMask=(1<<r)-1,e.m_NumPrevBits=t,n=1<<e.m_NumPrevBits+e.m_NumPosBits,e.m_Coders=a(n),o=0;o<n;++o)e.m_Coders[o]=ve({})}(e._literalEncoder,e._numLiteralPosStateBits,e._numLite
|
||
|
|
//# sourceMappingURL=/sm/e097e612491159d2b644e1bf64912a2fc1068f0a3cd62fbd2e3c26230c7f0888.map
|