summaryrefslogtreecommitdiffstats
path: root/MdeModulePkg/Library
diff options
context:
space:
mode:
Diffstat (limited to 'MdeModulePkg/Library')
-rw-r--r--MdeModulePkg/Library/DeviceManagerUiLib/DeviceManagerVfr.Vfr2
-rw-r--r--MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/7zTypes.h4
-rw-r--r--MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/Bra.h8
-rw-r--r--MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzFind.c70
-rw-r--r--MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzFind.h4
-rw-r--r--MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzmaDec.c30
-rw-r--r--MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzmaDec.h4
-rw-r--r--MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/DOC/lzma-history.txt92
-rw-r--r--MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/DOC/lzma-sdk.txt102
9 files changed, 158 insertions, 158 deletions
diff --git a/MdeModulePkg/Library/DeviceManagerUiLib/DeviceManagerVfr.Vfr b/MdeModulePkg/Library/DeviceManagerUiLib/DeviceManagerVfr.Vfr
index a8ed217400..d81c580fe7 100644
--- a/MdeModulePkg/Library/DeviceManagerUiLib/DeviceManagerVfr.Vfr
+++ b/MdeModulePkg/Library/DeviceManagerUiLib/DeviceManagerVfr.Vfr
@@ -4,7 +4,7 @@
//
// Copyright (c) 2004 - 2015, Intel Corporation. All rights reserved.<BR>
// SPDX-License-Identifier: BSD-2-Clause-Patent
-//
+//
//**/
#define FORMSET_GUID { 0x3ebfa8e6, 0x511d, 0x4b5b, 0xa9, 0x5f, 0xfb, 0x38, 0x26, 0xf, 0x1c, 0x27 }
diff --git a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/7zTypes.h b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/7zTypes.h
index a5fcb50bae..ac06278002 100644
--- a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/7zTypes.h
+++ b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/7zTypes.h
@@ -245,10 +245,10 @@ typedef struct
{
ILookInStream vt;
const ISeekInStream *realStream;
-
+
size_t pos;
size_t size; /* it's data size */
-
+
/* the following variables must be set outside */
Byte *buf;
size_t bufSize;
diff --git a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/Bra.h b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/Bra.h
index aba8dce14f..ecf7b0c447 100644
--- a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/Bra.h
+++ b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/Bra.h
@@ -11,23 +11,23 @@ EXTERN_C_BEGIN
/*
These functions convert relative addresses to absolute addresses
in CALL instructions to increase the compression ratio.
-
+
In:
data - data buffer
size - size of data
ip - current virtual Instruction Pinter (IP) value
state - state variable for x86 converter
encoding - 0 (for decoding), 1 (for encoding)
-
+
Out:
state - state variable for x86 converter
Returns:
The number of processed bytes. If you call these functions with multiple calls,
you must start next call with first byte after block of processed bytes.
-
+
Type Endian Alignment LookAhead
-
+
x86 little 1 4
ARMT little 2 2
ARM little 4 0
diff --git a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzFind.c b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzFind.c
index 5128fc9518..8765cbebfc 100644
--- a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzFind.c
+++ b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzFind.c
@@ -75,7 +75,7 @@ static void MatchFinder_ReadBlock(CMatchFinder *p)
p->streamEndWasReached = 1;
return;
}
-
+
for (;;)
{
Byte *dest = p->buffer + (p->streamPos - p->pos);
@@ -182,24 +182,24 @@ int MatchFinder_Create(CMatchFinder *p, UInt32 historySize,
ISzAllocPtr alloc)
{
UInt32 sizeReserv;
-
+
if (historySize > kMaxHistorySize)
{
MatchFinder_Free(p, alloc);
return 0;
}
-
+
sizeReserv = historySize >> 1;
if (historySize >= ((UInt32)3 << 30)) sizeReserv = historySize >> 3;
else if (historySize >= ((UInt32)2 << 30)) sizeReserv = historySize >> 2;
-
+
sizeReserv += (keepAddBufferBefore + matchMaxLen + keepAddBufferAfter) / 2 + (1 << 19);
p->keepSizeBefore = historySize + keepAddBufferBefore + 1;
p->keepSizeAfter = matchMaxLen + keepAddBufferAfter;
-
+
/* we need one additional byte, since we use MoveBlock after pos++ and before dictionary using */
-
+
if (LzInWindow_Create(p, sizeReserv, alloc))
{
UInt32 newCyclicBufferSize = historySize + 1;
@@ -245,7 +245,7 @@ int MatchFinder_Create(CMatchFinder *p, UInt32 historySize,
p->historySize = historySize;
p->hashSizeSum = hs;
p->cyclicBufferSize = newCyclicBufferSize;
-
+
numSons = newCyclicBufferSize;
if (p->btMode)
numSons <<= 1;
@@ -253,11 +253,11 @@ int MatchFinder_Create(CMatchFinder *p, UInt32 historySize,
if (p->hash && p->numRefs == newSize)
return 1;
-
+
MatchFinder_FreeThisClassMemory(p, alloc);
p->numRefs = newSize;
p->hash = AllocRefs(newSize, alloc);
-
+
if (p->hash)
{
p->son = p->hash + p->hashSizeSum;
@@ -274,11 +274,11 @@ static void MatchFinder_SetLimits(CMatchFinder *p)
{
UInt32 limit = kMaxValForNormalize - p->pos;
UInt32 limit2 = p->cyclicBufferSize - p->cyclicBufferPos;
-
+
if (limit2 < limit)
limit = limit2;
limit2 = p->streamPos - p->pos;
-
+
if (limit2 <= p->keepSizeAfter)
{
if (limit2 > 0)
@@ -286,10 +286,10 @@ static void MatchFinder_SetLimits(CMatchFinder *p)
}
else
limit2 -= p->keepSizeAfter;
-
+
if (limit2 < limit)
limit = limit2;
-
+
{
UInt32 lenLimit = p->streamPos - p->pos;
if (lenLimit > p->matchMaxLen)
@@ -328,10 +328,10 @@ void MatchFinder_Init_3(CMatchFinder *p, int readData)
p->streamPos = p->cyclicBufferSize;
p->result = SZ_OK;
p->streamEndWasReached = 0;
-
+
if (readData)
MatchFinder_ReadBlock(p);
-
+
MatchFinder_SetLimits(p);
}
@@ -343,7 +343,7 @@ void MatchFinder_Init(CMatchFinder *p)
MatchFinder_Init_3(p, True);
}
-
+
static UInt32 MatchFinder_GetSubValue(CMatchFinder *p)
{
return (p->pos - p->historySize - 1) & kNormalizeMask;
@@ -586,7 +586,7 @@ static UInt32 Bt3_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
d2 = pos - hash[h2];
curMatch = (hash + kFix3HashSize)[hv];
-
+
hash[h2] = pos;
(hash + kFix3HashSize)[hv] = pos;
@@ -605,7 +605,7 @@ static UInt32 Bt3_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
MOVE_POS_RET;
}
}
-
+
GET_MATCHES_FOOTER(offset, maxLen)
}
@@ -631,14 +631,14 @@ static UInt32 Bt4_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
maxLen = 0;
offset = 0;
-
+
if (d2 < p->cyclicBufferSize && *(cur - d2) == *cur)
{
distances[0] = maxLen = 2;
distances[1] = d2 - 1;
offset = 2;
}
-
+
if (d2 != d3 && d3 < p->cyclicBufferSize && *(cur - d3) == *cur)
{
maxLen = 3;
@@ -646,7 +646,7 @@ static UInt32 Bt4_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
offset += 2;
d2 = d3;
}
-
+
if (offset != 0)
{
UPDATE_maxLen
@@ -657,10 +657,10 @@ static UInt32 Bt4_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
MOVE_POS_RET;
}
}
-
+
if (maxLen < 3)
maxLen = 3;
-
+
GET_MATCHES_FOOTER(offset, maxLen)
}
@@ -712,7 +712,7 @@ static UInt32 Bt5_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
offset = 2;
d2 = d3;
}
-
+
if (d2 != d4 && d4 < p->cyclicBufferSize
&& *(cur - d4) == *cur
&& *(cur - d4 + 3) == *(cur + 3))
@@ -722,7 +722,7 @@ static UInt32 Bt5_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
offset += 2;
d2 = d4;
}
-
+
if (offset != 0)
{
UPDATE_maxLen
@@ -736,7 +736,7 @@ static UInt32 Bt5_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
if (maxLen < 4)
maxLen = 4;
-
+
GET_MATCHES_FOOTER(offset, maxLen)
}
*/
@@ -751,10 +751,10 @@ static UInt32 Hc4_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
hash = p->hash;
pos = p->pos;
-
+
d2 = pos - hash[ h2];
d3 = pos - (hash + kFix3HashSize)[h3];
-
+
curMatch = (hash + kFix4HashSize)[hv];
hash[ h2] = pos;
@@ -770,7 +770,7 @@ static UInt32 Hc4_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
distances[1] = d2 - 1;
offset = 2;
}
-
+
if (d2 != d3 && d3 < p->cyclicBufferSize && *(cur - d3) == *cur)
{
maxLen = 3;
@@ -778,7 +778,7 @@ static UInt32 Hc4_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
offset += 2;
d2 = d3;
}
-
+
if (offset != 0)
{
UPDATE_maxLen
@@ -789,7 +789,7 @@ static UInt32 Hc4_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
MOVE_POS_RET;
}
}
-
+
if (maxLen < 3)
maxLen = 3;
@@ -809,7 +809,7 @@ static UInt32 Hc5_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
hash = p->hash;
pos = p->pos;
-
+
d2 = pos - hash[ h2];
d3 = pos - (hash + kFix3HashSize)[h3];
d4 = pos - (hash + kFix4HashSize)[h4];
@@ -846,7 +846,7 @@ static UInt32 Hc5_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
offset = 2;
d2 = d3;
}
-
+
if (d2 != d4 && d4 < p->cyclicBufferSize
&& *(cur - d4) == *cur
&& *(cur - d4 + 3) == *(cur + 3))
@@ -856,7 +856,7 @@ static UInt32 Hc5_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
offset += 2;
d2 = d4;
}
-
+
if (offset != 0)
{
UPDATE_maxLen
@@ -867,7 +867,7 @@ static UInt32 Hc5_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances)
MOVE_POS_RET;
}
}
-
+
if (maxLen < 4)
maxLen = 4;
diff --git a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzFind.h b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzFind.h
index c77added7b..61bb9dd302 100644
--- a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzFind.h
+++ b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzFind.h
@@ -34,7 +34,7 @@ typedef struct _CMatchFinder
Byte *bufferBase;
ISeqInStream *stream;
-
+
UInt32 blockSize;
UInt32 keepSizeBefore;
UInt32 keepSizeAfter;
@@ -59,7 +59,7 @@ typedef struct _CMatchFinder
((p)->streamEndWasReached \
&& (p)->streamPos == (p)->pos \
&& (!(p)->directInput || (p)->directInputRem == 0))
-
+
int MatchFinder_NeedMove(CMatchFinder *p);
Byte *MatchFinder_GetPointerToCurrentPos(CMatchFinder *p);
void MatchFinder_MoveBlock(CMatchFinder *p);
diff --git a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzmaDec.c b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzmaDec.c
index 6d8c6eb6d9..a262319928 100644
--- a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzmaDec.c
+++ b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzmaDec.c
@@ -229,7 +229,7 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit
Byte *dic = p->dic;
SizeT dicBufSize = p->dicBufSize;
SizeT dicPos = p->dicPos;
-
+
UInt32 processedPos = p->processedPos;
UInt32 checkDicSize = p->checkDicSize;
unsigned len = 0;
@@ -305,7 +305,7 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit
dic[dicPos++] = (Byte)symbol;
continue;
}
-
+
{
UPDATE_1(prob);
prob = probs + IsRep + state;
@@ -372,7 +372,7 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit
state = state < kNumLitStates ? 8 : 11;
prob = probs + RepLenCoder;
}
-
+
#ifdef _LZMA_SIZE_OPT
{
unsigned lim, offset;
@@ -476,7 +476,7 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit
{
NORMALIZE
range >>= 1;
-
+
{
UInt32 t;
code -= range;
@@ -512,7 +512,7 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit
}
}
}
-
+
rep3 = rep2;
rep2 = rep1;
rep1 = rep0;
@@ -531,13 +531,13 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit
SizeT rem;
unsigned curLen;
SizeT pos;
-
+
if ((rem = limit - dicPos) == 0)
{
p->dicPos = dicPos;
return SZ_ERROR_DATA;
}
-
+
curLen = ((rem < len) ? (unsigned)rem : len);
pos = dicPos - rep0 + (dicPos < rep0 ? dicBufSize : 0);
@@ -570,7 +570,7 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit
while (dicPos < limit && buf < bufLimit);
NORMALIZE;
-
+
p->buf = buf;
p->range = range;
p->code = code;
@@ -640,10 +640,10 @@ static int MY_FAST_CALL LzmaDec_DecodeReal2(CLzmaDec *p, SizeT limit, const Byte
}
RINOK(LZMA_DECODE_REAL(p, limit2, bufLimit));
-
+
if (p->checkDicSize == 0 && p->processedPos >= p->prop.dicSize)
p->checkDicSize = p->prop.dicSize;
-
+
LzmaDec_WriteRem(p, limit);
}
while (p->dicPos < limit && p->buf < bufLimit && p->remainLen < kMatchSpecLenStart);
@@ -879,7 +879,7 @@ SRes LzmaDec_DecodeToDic(CLzmaDec *p, SizeT dicLimit, const Byte *src, SizeT *sr
{
SizeT inSize = *srcLen;
(*srcLen) = 0;
-
+
*status = LZMA_STATUS_NOT_SPECIFIED;
if (p->remainLen > kMatchSpecLenStart)
@@ -997,7 +997,7 @@ SRes LzmaDec_DecodeToDic(CLzmaDec *p, SizeT dicLimit, const Byte *src, SizeT *sr
p->buf = p->tempBuf;
if (LzmaDec_DecodeReal2(p, dicLimit, p->buf) != 0)
return SZ_ERROR_DATA;
-
+
{
unsigned kkk = (unsigned)(p->buf - p->tempBuf);
if (rem < kkk)
@@ -1013,7 +1013,7 @@ SRes LzmaDec_DecodeToDic(CLzmaDec *p, SizeT dicLimit, const Byte *src, SizeT *sr
p->tempBufSize = 0;
}
}
-
+
if (p->code != 0)
return SZ_ERROR_DATA;
*status = LZMA_STATUS_FINISHED_WITH_MARK;
@@ -1083,12 +1083,12 @@ SRes LzmaProps_Decode(CLzmaProps *p, const Byte *data, unsigned size)
{
UInt32 dicSize;
Byte d;
-
+
if (size < LZMA_PROPS_SIZE)
return SZ_ERROR_UNSUPPORTED;
else
dicSize = data[1] | ((UInt32)data[2] << 8) | ((UInt32)data[3] << 16) | ((UInt32)data[4] << 24);
-
+
if (dicSize < LZMA_DIC_MIN)
dicSize = LZMA_DIC_MIN;
p->dicSize = dicSize;
diff --git a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzmaDec.h b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzmaDec.h
index 28ce60c3ea..ebc568cb4f 100644
--- a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzmaDec.h
+++ b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzmaDec.h
@@ -135,7 +135,7 @@ LzmaDec_Allocate* can return:
SZ_ERROR_MEM - Memory allocation error
SZ_ERROR_UNSUPPORTED - Unsupported properties
*/
-
+
SRes LzmaDec_AllocateProbs(CLzmaDec *p, const Byte *props, unsigned propsSize, ISzAllocPtr alloc);
void LzmaDec_FreeProbs(CLzmaDec *p, ISzAllocPtr alloc);
@@ -164,7 +164,7 @@ void LzmaDec_Free(CLzmaDec *p, ISzAllocPtr alloc);
*/
/* LzmaDec_DecodeToDic
-
+
The decoding to internal dictionary buffer (CLzmaDec::dic).
You must manually update CLzmaDec::dicPos, if it reaches CLzmaDec::dicBufSize !!!
diff --git a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/DOC/lzma-history.txt b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/DOC/lzma-history.txt
index f4793264a5..5ad9a5b1b9 100644
--- a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/DOC/lzma-history.txt
+++ b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/DOC/lzma-history.txt
@@ -3,11 +3,11 @@ HISTORY of the LZMA SDK
18.05 2018-04-30
-------------------------
-- The speed for LZMA/LZMA2 compressing was increased
- by 8% for fastest/fast compression levels and
+- The speed for LZMA/LZMA2 compressing was increased
+ by 8% for fastest/fast compression levels and
by 3% for normal/maximum compression levels.
- Previous versions of 7-Zip could work incorrectly in "Large memory pages" mode in
- Windows 10 because of some BUG with "Large Pages" in Windows 10.
+ Windows 10 because of some BUG with "Large Pages" in Windows 10.
Now 7-Zip doesn't use "Large Pages" on Windows 10 up to revision 1709 (16299).
- The BUG was fixed in Lzma2Enc.c
Lzma2Enc_Encode2() function worked incorretly,
@@ -16,7 +16,7 @@ HISTORY of the LZMA SDK
18.03 beta 2018-03-04
-------------------------
-- Asm\x86\LzmaDecOpt.asm: new optimized LZMA decoder written in asm
+- Asm\x86\LzmaDecOpt.asm: new optimized LZMA decoder written in asm
for x64 with about 30% higher speed than main version of LZMA decoder written in C.
- The speed for single-thread LZMA/LZMA2 decoder written in C was increased by 3%.
- 7-Zip now can use multi-threading for 7z/LZMA2 decoding,
@@ -35,7 +35,7 @@ HISTORY of the LZMA SDK
18.00 beta 2019-01-10
-------------------------
- The BUG in xz encoder was fixed:
- There was memory leak of 16 KB for each file compressed with
+ There was memory leak of 16 KB for each file compressed with
xz compression method, if additional filter was used.
@@ -44,7 +44,7 @@ HISTORY of the LZMA SDK
- Minor speed optimization for LZMA2 (xz and 7z) multi-threading compression.
7-Zip now uses additional memory buffers for multi-block LZMA2 compression.
CPU utilization was slightly improved.
-- 7-zip now creates multi-block xz archives by default. Block size can be
+- 7-zip now creates multi-block xz archives by default. Block size can be
specified with -ms[Size]{m|g} switch.
- xz decoder now can unpack random block from multi-block xz archives.
- 7-Zip command line: @listfile now doesn't work after -- switch.
@@ -55,7 +55,7 @@ HISTORY of the LZMA SDK
17.00 beta 2017-04-29
-------------------------
-- NewHandler.h / NewHandler.cpp:
+- NewHandler.h / NewHandler.cpp:
now it redefines operator new() only for old MSVC compilers (_MSC_VER < 1900).
- C/7zTypes.h : the names of variables in interface structures were changed (vt).
- Some bugs were fixed. 7-Zip could crash in some cases.
@@ -76,51 +76,51 @@ HISTORY of the LZMA SDK
16.02 2016-05-21
-------------------------
- The BUG in 16.00 - 16.01 was fixed:
- Split Handler (SplitHandler.cpp) returned incorrect
+ Split Handler (SplitHandler.cpp) returned incorrect
total size value (kpidSize) for split archives.
16.01 2016-05-19
--------------------------
+-------------------------
- Some internal changes to reduce the number of compiler warnings.
16.00 2016-05-10
--------------------------
+-------------------------
- Some bugs were fixed.
15.12 2015-11-19
--------------------------
+-------------------------
- The BUG in C version of 7z decoder was fixed:
7zDec.c : SzDecodeLzma2()
7z decoder could mistakenly report about decoding error for some 7z archives
that use LZMA2 compression method.
- The probability to get that mistaken decoding error report was about
- one error per 16384 solid blocks for solid blocks larger than 16 KB (compressed size).
+ The probability to get that mistaken decoding error report was about
+ one error per 16384 solid blocks for solid blocks larger than 16 KB (compressed size).
- The BUG (in 9.26-15.11) in C version of 7z decoder was fixed:
7zArcIn.c : SzReadHeader2()
- 7z decoder worked incorrectly for 7z archives that contain
- empty solid blocks, that can be placed to 7z archive, if some file is
+ 7z decoder worked incorrectly for 7z archives that contain
+ empty solid blocks, that can be placed to 7z archive, if some file is
unavailable for reading during archive creation.
15.09 beta 2015-10-16
--------------------------
+-------------------------
- The BUG in LZMA / LZMA2 encoding code was fixed.
The BUG in LzFind.c::MatchFinder_ReadBlock() function.
If input data size is larger than (4 GiB - dictionary_size),
the following code worked incorrectly:
- - LZMA : LzmaEnc_MemEncode(), LzmaEncode() : LZMA encoding functions
- for compressing from memory to memory.
+ - LZMA : LzmaEnc_MemEncode(), LzmaEncode() : LZMA encoding functions
+ for compressing from memory to memory.
That BUG is not related to LZMA encoder version that works via streams.
- - LZMA2 : multi-threaded version of LZMA2 encoder worked incorrectly, if
- default value of chunk size (CLzma2EncProps::blockSize) is changed
+ - LZMA2 : multi-threaded version of LZMA2 encoder worked incorrectly, if
+ default value of chunk size (CLzma2EncProps::blockSize) is changed
to value larger than (4 GiB - dictionary_size).
9.38 beta 2015-01-03
--------------------------
+-------------------------
- The BUG in 9.31-9.37 was fixed:
IArchiveGetRawProps interface was disabled for 7z archives.
- The BUG in 9.26-9.36 was fixed:
@@ -128,10 +128,10 @@ HISTORY of the LZMA SDK
9.36 beta 2014-12-26
--------------------------
+-------------------------
- The BUG in command line version was fixed:
7-Zip created temporary archive in current folder during update archive
- operation, if -w{Path} switch was not specified.
+ operation, if -w{Path} switch was not specified.
The fixed 7-Zip creates temporary archive in folder that contains updated archive.
- The BUG in 9.33-9.35 was fixed:
7-Zip silently ignored file reading errors during 7z or gz archive creation,
@@ -140,14 +140,14 @@ HISTORY of the LZMA SDK
9.35 beta 2014-12-07
--------------------------
+-------------------------
- 7zr.exe now support AES encryption.
- SFX mudules were added to LZMA SDK
- Some bugs were fixed.
9.21 beta 2011-04-11
--------------------------
+-------------------------
- New class FString for file names at file systems.
- Speed optimization in CRC code for big-endian CPUs.
- The BUG in Lzma2Dec.c was fixed:
@@ -155,7 +155,7 @@ HISTORY of the LZMA SDK
9.18 beta 2010-11-02
--------------------------
+-------------------------
- New small SFX module for installers (SfxSetup).
@@ -168,7 +168,7 @@ HISTORY of the LZMA SDK
9.11 beta 2010-03-15
-------------------------
- PPMd compression method support
-
+
9.09 2009-12-12
-------------------------
@@ -202,7 +202,7 @@ HISTORY of the LZMA SDK
4.61 beta 2008-11-23
-------------------------
- The bug in ANSI-C LZMA Decoder was fixed:
- If encoded stream was corrupted, decoder could access memory
+ If encoded stream was corrupted, decoder could access memory
outside of allocated range.
- Some changes in ANSI-C 7z Decoder interfaces.
- LZMA SDK is placed in the public domain.
@@ -216,7 +216,7 @@ HISTORY of the LZMA SDK
4.59 beta 2008-08-13
-------------------------
- The bug was fixed:
- LZMA Encoder in fast compression mode could access memory outside of
+ LZMA Encoder in fast compression mode could access memory outside of
allocated range in some rare cases.
@@ -229,7 +229,7 @@ HISTORY of the LZMA SDK
4.57 2007-12-12
-------------------------
-- Speed optimizations in ?++ LZMA Decoder.
+- Speed optimizations in ?++ LZMA Decoder.
- Small changes for more compatibility with some C/C++ compilers.
@@ -239,36 +239,36 @@ HISTORY of the LZMA SDK
- now it supports BCJ and BCJ2 filters
- now it supports files larger than 4 GB.
- now it supports "Last Write Time" field for files.
-- C++ code for .7z archives compressing/decompressing from 7-zip
+- C++ code for .7z archives compressing/decompressing from 7-zip
was included to LZMA SDK.
-
+
4.43 2006-06-04
-------------------------
- Small changes for more compatibility with some C/C++ compilers.
-
+
4.42 2006-05-15
-------------------------
- Small changes in .h files in ANSI-C version.
-
+
4.39 beta 2006-04-14
-------------------------
- The bug in versions 4.33b:4.38b was fixed:
- C++ version of LZMA encoder could not correctly compress
+ C++ version of LZMA encoder could not correctly compress
files larger than 2 GB with HC4 match finder (-mfhc4).
-
+
4.37 beta 2005-04-06
-------------------------
-- Fixes in C++ code: code could no be compiled if _NO_EXCEPTIONS was defined.
+- Fixes in C++ code: code could no be compiled if _NO_EXCEPTIONS was defined.
4.35 beta 2005-03-02
-------------------------
- The bug was fixed in C++ version of LZMA Decoder:
- If encoded stream was corrupted, decoder could access memory
+ If encoded stream was corrupted, decoder could access memory
outside of allocated range.
@@ -339,7 +339,7 @@ HISTORY of the LZMA SDK
4.17 2005-04-18
-------------------------
-- New example for RAM->RAM compressing/decompressing:
+- New example for RAM->RAM compressing/decompressing:
LZMA + BCJ (filter for x86 code):
- LzmaRam.h
- LzmaRam.cpp
@@ -350,11 +350,11 @@ HISTORY of the LZMA SDK
4.16 2005-03-29
-------------------------
-- The bug was fixed in LzmaDecode.c (ANSI-C LZMA Decoder):
+- The bug was fixed in LzmaDecode.c (ANSI-C LZMA Decoder):
If _LZMA_OUT_READ was defined, and if encoded stream was corrupted,
decoder could access memory outside of allocated range.
- Speed optimization of ANSI-C LZMA Decoder (now it's about 20% faster).
- Old version of LZMA Decoder now is in file LzmaDecodeSize.c.
+ Old version of LZMA Decoder now is in file LzmaDecodeSize.c.
LzmaDecodeSize.c can provide slightly smaller code than LzmaDecode.c
- Small speed optimization in LZMA C++ code
- filter for SPARC's code was added
@@ -369,7 +369,7 @@ HISTORY of the LZMA SDK
4.05 2004-08-25
-------------------------
-- Source code of filters for x86, IA-64, ARM, ARM-Thumb
+- Source code of filters for x86, IA-64, ARM, ARM-Thumb
and PowerPC code was included to SDK
- Some internal minor changes
@@ -381,8 +381,8 @@ HISTORY of the LZMA SDK
4.03 2004-06-18
-------------------------
-- "Benchmark" command was added. It measures compressing
- and decompressing speed and shows rating values.
+- "Benchmark" command was added. It measures compressing
+ and decompressing speed and shows rating values.
Also it checks hardware errors.
@@ -411,7 +411,7 @@ HISTORY of the LZMA SDK
HISTORY of the LZMA
-------------------
- 2001-2008: Improvements to LZMA compressing/decompressing code,
+ 2001-2008: Improvements to LZMA compressing/decompressing code,
keeping compatibility with original LZMA format
1996-2001: Development of LZMA compression format
@@ -419,6 +419,6 @@ HISTORY of the LZMA
2001-08-30: LZMA compression was added to 7-Zip
1999-01-02: First version of 7-Zip was released
-
+
End of document
diff --git a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/DOC/lzma-sdk.txt b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/DOC/lzma-sdk.txt
index 01521e9398..bf0b3a5ee6 100644
--- a/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/DOC/lzma-sdk.txt
+++ b/MdeModulePkg/Library/LzmaCustomDecompressLib/Sdk/DOC/lzma-sdk.txt
@@ -2,15 +2,15 @@ LZMA SDK 18.05
--------------
LZMA SDK provides the documentation, samples, header files,
-libraries, and tools you need to develop applications that
+libraries, and tools you need to develop applications that
use 7z / LZMA / LZMA2 / XZ compression.
-LZMA is an improved version of famous LZ77 compression algorithm.
+LZMA is an improved version of famous LZ77 compression algorithm.
It was improved in way of maximum increasing of compression ratio,
-keeping high decompression speed and low memory requirements for
+keeping high decompression speed and low memory requirements for
decompressing.
-LZMA2 is a LZMA based compression method. LZMA2 provides better
+LZMA2 is a LZMA based compression method. LZMA2 provides better
multithreading support for compression than LZMA and some other improvements.
7z is a file format for data compression and file archiving.
@@ -19,7 +19,7 @@ multithreading support for compression than LZMA and some other improvements.
7z also supports AES-256 based encryption.
XZ is a file format for data compression that uses LZMA2 compression.
-XZ format provides additional features: SHA/CRC check, filters for
+XZ format provides additional features: SHA/CRC check, filters for
improved compression ratio, splitting to blocks and streams,
@@ -33,11 +33,11 @@ Some code in LZMA SDK is based on public domain code from another developers:
1) PPMd var.H (2001): Dmitry Shkarin
2) SHA-256: Wei Dai (Crypto++ library)
-Anyone is free to copy, modify, publish, use, compile, sell, or distribute the
-original LZMA SDK code, either in source code form or as a compiled binary, for
+Anyone is free to copy, modify, publish, use, compile, sell, or distribute the
+original LZMA SDK code, either in source code form or as a compiled binary, for
any purpose, commercial or non-commercial, and by any means.
-LZMA SDK code is compatible with open source licenses, for example, you can
+LZMA SDK code is compatible with open source licenses, for example, you can
include it to GNU GPL or GNU LGPL code.
@@ -60,7 +60,7 @@ LZMA SDK Contents
- SFX modules for installers.
-UNIX/Linux version
+UNIX/Linux version
------------------
To compile C++ version of file->file LZMA encoding, go to directory
CPP/7zip/Bundles/LzmaCon
@@ -68,11 +68,11 @@ and call make to recompile it:
make -f makefile.gcc clean all
In some UNIX/Linux versions you must compile LZMA with static libraries.
-To compile with static libraries, you can use
+To compile with static libraries, you can use
LIB = -lm -static
Also you can use p7zip (port of 7-Zip for POSIX systems like Unix or Linux):
-
+
http://p7zip.sourceforge.net/
@@ -120,7 +120,7 @@ C/ - C files (compression / decompression and other)
7z - 7z decoder program (decoding 7z files)
Lzma - LZMA program (file->file LZMA encoder/decoder).
LzmaLib - LZMA library (.DLL for Windows)
- SfxSetup - small SFX module for installers
+ SfxSetup - small SFX module for installers
CPP/ -- CPP files
@@ -135,7 +135,7 @@ CPP/ -- CPP files
7z - 7z C++ Encoder/Decoder
Bundles - Modules that are bundles of other modules (files)
-
+
Alone7z - 7zr.exe: Standalone 7-Zip console program (reduced version)
Format7zExtractR - 7zxr.dll: Reduced version of 7z DLL: extracting from 7z/LZMA/BCJ/BCJ2.
Format7zR - 7zr.dll: Reduced version of 7z DLL: extracting/compressing to 7z/LZMA/BCJ/BCJ2
@@ -152,7 +152,7 @@ CPP/ -- CPP files
Crypto - files for encryption / decompression
UI - User Interface files
-
+
Client7z - Test application for 7za.dll, 7zr.dll, 7zxr.dll
Common - Common UI files
Console - Code for console program (7z.exe)
@@ -178,7 +178,7 @@ Java/ - Java files
RangeCoder - Range Coder (special code of compression/decompression)
-Note:
+Note:
Asm / C / C++ source code of LZMA SDK is part of 7-Zip's source code.
7-Zip's source code can be downloaded from 7-Zip's SourceForge page:
@@ -190,13 +190,13 @@ LZMA features
-------------
- Variable dictionary size (up to 1 GB)
- Estimated compressing speed: about 2 MB/s on 2 GHz CPU
- - Estimated decompressing speed:
+ - Estimated decompressing speed:
- 20-30 MB/s on modern 2 GHz cpu
- 1-2 MB/s on 200 MHz simple RISC cpu: (ARM, MIPS, PowerPC)
- Small memory requirements for decompressing (16 KB + DictionarySize)
- Small code size for decompressing: 5-8 KB
-LZMA decoder uses only integer operations and can be
+LZMA decoder uses only integer operations and can be
implemented in any modern 32-bit CPU (or on 16-bit CPU with some conditions).
Some critical operations that affect the speed of LZMA decompression:
@@ -205,7 +205,7 @@ Some critical operations that affect the speed of LZMA decompression:
3) 32-bit shift and arithmetic operations
The speed of LZMA decompressing mostly depends from CPU speed.
-Memory speed has no big meaning. But if your CPU has small data cache,
+Memory speed has no big meaning. But if your CPU has small data cache,
overall weight of memory speed will slightly increase.
@@ -221,53 +221,53 @@ Usage: LZMA <e|d> inputFile outputFile [<switches>...]
d: decode file
- b: Benchmark. There are two tests: compressing and decompressing
- with LZMA method. Benchmark shows rating in MIPS (million
- instructions per second). Rating value is calculated from
+ b: Benchmark. There are two tests: compressing and decompressing
+ with LZMA method. Benchmark shows rating in MIPS (million
+ instructions per second). Rating value is calculated from
measured speed and it is normalized with Intel's Core 2 results.
- Also Benchmark checks possible hardware errors (RAM
+ Also Benchmark checks possible hardware errors (RAM
errors in most cases). Benchmark uses these settings:
- (-a1, -d21, -fb32, -mfbt4). You can change only -d parameter.
+ (-a1, -d21, -fb32, -mfbt4). You can change only -d parameter.
Also you can change the number of iterations. Example for 30 iterations:
LZMA b 30
Default number of iterations is 10.
<Switches>
-
+
-a{N}: set compression mode 0 = fast, 1 = normal
default: 1 (normal)
d{N}: Sets Dictionary size - [0, 30], default: 23 (8MB)
The maximum value for dictionary size is 1 GB = 2^30 bytes.
- Dictionary size is calculated as DictionarySize = 2^N bytes.
- For decompressing file compressed by LZMA method with dictionary
+ Dictionary size is calculated as DictionarySize = 2^N bytes.
+ For decompressing file compressed by LZMA method with dictionary
size D = 2^N you need about D bytes of memory (RAM).
-fb{N}: set number of fast bytes - [5, 273], default: 128
- Usually big number gives a little bit better compression ratio
+ Usually big number gives a little bit better compression ratio
and slower compression process.
-lc{N}: set number of literal context bits - [0, 8], default: 3
Sometimes lc=4 gives gain for big files.
-lp{N}: set number of literal pos bits - [0, 4], default: 0
- lp switch is intended for periodical data when period is
- equal 2^N. For example, for 32-bit (4 bytes)
- periodical data you can use lp=2. Often it's better to set lc0,
+ lp switch is intended for periodical data when period is
+ equal 2^N. For example, for 32-bit (4 bytes)
+ periodical data you can use lp=2. Often it's better to set lc0,
if you change lp switch.
-pb{N}: set number of pos bits - [0, 4], default: 2
- pb switch is intended for periodical data
+ pb switch is intended for periodical data
when period is equal 2^N.
- -mf{MF_ID}: set Match Finder. Default: bt4.
- Algorithms from hc* group doesn't provide good compression
- ratio, but they often works pretty fast in combination with
+ -mf{MF_ID}: set Match Finder. Default: bt4.
+ Algorithms from hc* group doesn't provide good compression
+ ratio, but they often works pretty fast in combination with
fast mode (-a0).
- Memory requirements depend from dictionary size
- (parameter "d" in table below).
+ Memory requirements depend from dictionary size
+ (parameter "d" in table below).
MF_ID Memory Description
@@ -276,8 +276,8 @@ Usage: LZMA <e|d> inputFile outputFile [<switches>...]
bt4 d * 11.5 + 4MB Binary Tree with 4 bytes hashing.
hc4 d * 7.5 + 4MB Hash Chain with 4 bytes hashing.
- -eos: write End Of Stream marker. By default LZMA doesn't write
- eos marker, since LZMA decoder knows uncompressed size
+ -eos: write End Of Stream marker. By default LZMA doesn't write
+ eos marker, since LZMA decoder knows uncompressed size
stored in .lzma file header.
-si: Read data from stdin (it will write End Of Stream marker).
@@ -286,16 +286,16 @@ Usage: LZMA <e|d> inputFile outputFile [<switches>...]
Examples:
-1) LZMA e file.bin file.lzma -d16 -lc0
+1) LZMA e file.bin file.lzma -d16 -lc0
-compresses file.bin to file.lzma with 64 KB dictionary (2^16=64K)
-and 0 literal context bits. -lc0 allows to reduce memory requirements
+compresses file.bin to file.lzma with 64 KB dictionary (2^16=64K)
+and 0 literal context bits. -lc0 allows to reduce memory requirements
for decompression.
2) LZMA e file.bin file.lzma -lc0 -lp2
-compresses file.bin to file.lzma with settings suitable
+compresses file.bin to file.lzma with settings suitable
for 32-bit periodical data (for example, ARM or MIPS code).
3) LZMA d file.lzma file.bin
@@ -309,9 +309,9 @@ Compression ratio hints
Recommendations
---------------
-To increase the compression ratio for LZMA compressing it's desirable
+To increase the compression ratio for LZMA compressing it's desirable
to have aligned data (if it's possible) and also it's desirable to locate
-data in such order, where code is grouped in one place and data is
+data in such order, where code is grouped in one place and data is
grouped in other place (it's better than such mixing: code, data, code,
data, ...).
@@ -319,19 +319,19 @@ data, ...).
Filters
-------
You can increase the compression ratio for some data types, using
-special filters before compressing. For example, it's possible to
-increase the compression ratio on 5-10% for code for those CPU ISAs:
+special filters before compressing. For example, it's possible to
+increase the compression ratio on 5-10% for code for those CPU ISAs:
x86, IA-64, ARM, ARM-Thumb, PowerPC, SPARC.
You can find C source code of such filters in C/Bra*.* files
-You can check the compression ratio gain of these filters with such
+You can check the compression ratio gain of these filters with such
7-Zip commands (example for ARM code):
No filter:
7z a a1.7z a.bin -m0=lzma
With filter for little-endian ARM code:
- 7z a a2.7z a.bin -m0=arm -m1=lzma
+ 7z a a2.7z a.bin -m0=arm -m1=lzma
It works in such manner:
Compressing = Filter_encoding + LZMA_encoding
@@ -339,11 +339,11 @@ Decompressing = LZMA_decoding + Filter_decoding
Compressing and decompressing speed of such filters is very high,
so it will not increase decompressing time too much.
-Moreover, it reduces decompression time for LZMA_decoding,
+Moreover, it reduces decompression time for LZMA_decoding,
since compression ratio with filtering is higher.
-These filters convert CALL (calling procedure) instructions
-from relative offsets to absolute addresses, so such data becomes more
+These filters convert CALL (calling procedure) instructions
+from relative offsets to absolute addresses, so such data becomes more
compressible.
For some ISAs (for example, for MIPS) it's impossible to get gain from such filter.