diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index cc3a2f9..6ff6995 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -11,7 +11,7 @@ jobs: # Release builds build_release_macos: name: Release build (macOS universal, static Qt 6.5.0) - runs-on: macos-12 + runs-on: macos-latest steps: - uses: actions/checkout@v3 - name: Get Qt @@ -35,26 +35,48 @@ jobs: run: cmake --build . --config Release - name: Create dist directory run: cmake -E make_directory ${{runner.workspace}}/UEFITool/dist + - name: Signed archive everything + if: github.repository_owner == 'LongSoft' + working-directory: ${{runner.workspace}}/build + env: + MAC_CERTIFICATE_PASSWORD: ${{ secrets.MAC_CERTIFICATE_PASSWORD }} + MAC_ACCOUNT_NAME: ${{ secrets.MAC_ACCOUNT_NAME }} + MAC_ACCOUNT_PASSWORD: ${{ secrets.MAC_ACCOUNT_PASSWORD }} + shell: bash + run: | + UEFITOOL_VER=$(cat ../UEFITool/version.h | grep PROGRAM_VERSION | cut -d'"' -f2 | sed 's/NE alpha /A/') ; \ + codesign -fs - UEFIExtract/UEFIExtract + codesign -fs - UEFIFind/UEFIFind + zip -qryj ../UEFITool/dist/UEFIExtract_NE_${UEFITOOL_VER}_universal_mac.zip ./UEFIExtract/UEFIExtract + zip -qryj ../UEFITool/dist/UEFIFind_NE_${UEFITOOL_VER}_universal_mac.zip ./UEFIFind/UEFIFind + brew install create-dmg || exit 1 + curl -OL "https://github.com/acidanthera/ocbuild/raw/master/codesign/appsign.sh" || exit 1 + chmod a+x appsign.sh || exit 1 + "$(pwd)/appsign.sh" ./UEFITool/UEFITool.app ../UEFITool/dist/UEFITool_NE_${UEFITOOL_VER}_universal_mac.dmg - name: Archive everything + if: github.repository_owner != 'LongSoft' working-directory: ${{runner.workspace}}/build shell: bash run: | UEFITOOL_VER=$(cat ../UEFITool/version.h | grep PROGRAM_VERSION | cut -d'"' -f2 | sed 's/NE alpha /A/') ; \ + codesign -fs - UEFIExtract/UEFIExtract + codesign -fs - UEFIFind/UEFIFind zip -qryj ../UEFITool/dist/UEFIExtract_NE_${UEFITOOL_VER}_universal_mac.zip ./UEFIExtract/UEFIExtract zip -qryj ../UEFITool/dist/UEFIFind_NE_${UEFITOOL_VER}_universal_mac.zip ./UEFIFind/UEFIFind cd UEFITool + codesign -fs - --deep UEFITool.app zip -qry ../../UEFITool/dist/UEFITool_NE_${UEFITOOL_VER}_universal_mac.zip ./UEFITool.app - name: Upload to artifacts - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: macOS builds - path: dist/*.zip + path: dist/* - name: Upload to releases if: github.event_name == 'release' uses: svenstaro/upload-release-action@v2 with: repo_token: ${{ secrets.GITHUB_TOKEN }} - file: dist/*.zip + file: dist/* tag: ${{ github.ref }} file_glob: true @@ -87,7 +109,7 @@ jobs: zip -qryj ../UEFITool/dist/UEFIFind_NE_${UEFITOOL_VER}_x64_linux.zip ./UEFIFind/uefifind zip -qryj ../UEFITool/dist/UEFITool_NE_${UEFITOOL_VER}_x64_linux.zip ./UEFITool/uefitool - name: Upload to artifacts - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: Linux builds path: dist/*.zip @@ -102,17 +124,18 @@ jobs: build_release_freebsd: name: Release build (FreeBSD x64, shared Qt 6) - runs-on: macos-12 + runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 - - name: Build on FreeBSD inside macOS VM + - name: Build on FreeBSD inside Ubuntu VM id: test - uses: vmactions/freebsd-vm@v0 + uses: cross-platform-actions/action@v0.27.0 with: - usesh: true - prepare: | - pkg install -y zip cmake qt6-base + operating_system: freebsd + version: '13.3' + shell: sh run: | + sudo pkg install -y zip cmake qt6-base mkdir dist mkdir build cd build @@ -123,7 +146,7 @@ jobs: zip -qryj ../dist/UEFIFind_NE_${UEFITOOL_VER}_x64_freebsd.zip ./UEFIFind/uefifind zip -qryj ../dist/UEFITool_NE_${UEFITOOL_VER}_x64_freebsd.zip ./UEFITool/uefitool - name: Upload to artifacts - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: FreeBSD builds path: dist/*.zip @@ -205,7 +228,7 @@ jobs: UEFITOOL_VER=$(cat ../../../UEFITool/version.h | grep PROGRAM_VERSION | cut -d'"' -f2 | sed 's/NE alpha /A/') ; \ 7z a ../../../UEFITool/dist/UEFITool_NE_${UEFITOOL_VER}_win32.zip UEFITool.exe - name: Upload to artifacts - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: Windows 32-bit builds path: dist/*.zip @@ -254,7 +277,7 @@ jobs: 7z a ../UEFITool/dist/UEFIFind_NE_${UEFITOOL_VER}_win64.zip ./UEFIFind/Release/UEFIFind.exe 7z a ../UEFITool/dist/UEFITool_NE_${UEFITOOL_VER}_win64.zip ./UEFITool/Release/UEFITool.exe - name: Upload to artifacts - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: Windows 64-bit builds path: dist/*.zip @@ -298,7 +321,35 @@ jobs: run: | cmake -G "MinGW Makefiles" -B build . cmake --build build --parallel - + + build_test_linux_fuzzer: + name: Fuzzer build test (Clang, Linux x64) + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v3 + - name: Create build directory + run: cmake -E make_directory ${{runner.workspace}}/build + - name: Configure everything + working-directory: ${{runner.workspace}}/build + run: CC=/usr/bin/clang CXX=/usr/bin/clang++ cmake ../UEFITool/fuzzing + - name: Build everything + working-directory: ${{runner.workspace}}/build + shell: bash + run: cmake --build . + - name: Create dist directory + run: cmake -E make_directory ${{runner.workspace}}/dist + - name: Archive everything + working-directory: ${{runner.workspace}}/build + shell: bash + run: | + UEFITOOL_VER=$(cat ../UEFITool/version.h | grep PROGRAM_VERSION | cut -d'"' -f2 | sed 's/NE alpha /A/') ; \ + zip -qryj ../dist/ffsparser_fuzzer_NE_${UEFITOOL_VER}_x64_linux.zip ./ffsparser_fuzzer + - name: Upload to artifacts + uses: actions/upload-artifact@v4 + with: + name: Fuzzer + path: ${{runner.workspace}}/dist/*.zip + # Static Analysis build_analyze_linux_coverity: env: @@ -329,56 +380,11 @@ jobs: COVERITY_SCAN_EMAIL: ${{ secrets.COVERITY_SCAN_EMAIL }} COVERITY_BUILD_COMMAND: cmake --build . - build_analyze_linux_pvs_studio_and_codeql: - if: github.repository_owner == 'LongSoft' && github.event_name != 'pull_request' - name: PVS-Studio and CodeQL Static Analysis (shared Qt 6.5.0) - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - name: Install Qt - uses: jurplel/install-qt-action@v3 - with: - version: '6.5.0' - host: 'linux' - target: 'desktop' - - name: Install PVS-Studio - run: | - wget -q -O - https://files.pvs-studio.com/etc/pubkey.txt \ - | sudo apt-key add - - sudo wget -O /etc/apt/sources.list.d/viva64.list \ - https://files.pvs-studio.com/etc/viva64.list - sudo apt update - sudo apt install pvs-studio - pvs-studio-analyzer credentials ${{ secrets.PVS_STUDIO_CREDENTIALS }} - - name: Initialize CodeQL - uses: github/codeql-action/init@v2 - with: - languages: cpp - - name: Build everything - run: | - cmake -DCMAKE_EXPORT_COMPILE_COMMANDS=On -B build . - cmake --build build - - name: Perform CodeQL analysis - uses: github/codeql-action/analyze@v2 - - name: Perform PVS-Studio analysis - run: | - pvs-studio-analyzer analyze -f build/compile_commands.json -j - - name: Convert PVS-Studio report - run: | - plog-converter -t sarif -o pvs-report.sarif PVS-Studio.log - - name: Publish PVS-Studio report - uses: github/codeql-action/upload-sarif@v2 - with: - sarif_file: pvs-report.sarif - category: PVS-Studio - build_analyze_linux_sonarcloud: if: github.repository_owner == 'LongSoft' && github.event_name != 'pull_request' name: SonarCloud Static Analysis (shared Qt 6.5.0) runs-on: ubuntu-latest env: - SONAR_SCANNER_VERSION: 4.7.0.2747 - SONAR_SERVER_URL: "https://sonarcloud.io" BUILD_WRAPPER_OUT_DIR: build_wrapper_output_directory # Directory where build-wrapper output will be placed steps: - uses: actions/checkout@v3 @@ -390,33 +396,23 @@ jobs: version: '6.5.0' host: 'linux' target: 'desktop' - - name: Set up JDK 11 + - name: Install JDK 17 uses: actions/setup-java@v3 with: distribution: 'zulu' - java-version: 11 - - name: Download and set up sonar-scanner - env: - SONAR_SCANNER_DOWNLOAD_URL: https://binaries.sonarsource.com/Distribution/sonar-scanner-cli/sonar-scanner-cli-${{ env.SONAR_SCANNER_VERSION }}-linux.zip - run: | - mkdir -p $HOME/.sonar - curl -sSLo $HOME/.sonar/sonar-scanner.zip ${{ env.SONAR_SCANNER_DOWNLOAD_URL }} - unzip -o $HOME/.sonar/sonar-scanner.zip -d $HOME/.sonar/ - echo "$HOME/.sonar/sonar-scanner-${{ env.SONAR_SCANNER_VERSION }}-linux/bin" >> $GITHUB_PATH - - name: Download and set up build-wrapper - env: - BUILD_WRAPPER_DOWNLOAD_URL: ${{ env.SONAR_SERVER_URL }}/static/cpp/build-wrapper-linux-x86.zip - run: | - curl -sSLo $HOME/.sonar/build-wrapper-linux-x86.zip ${{ env.BUILD_WRAPPER_DOWNLOAD_URL }} - unzip -o $HOME/.sonar/build-wrapper-linux-x86.zip -d $HOME/.sonar/ - echo "$HOME/.sonar/build-wrapper-linux-x86" >> $GITHUB_PATH + java-version: 17 + - name: Install build-wrapper + uses: SonarSource/sonarcloud-github-c-cpp@v2 - name: Run build-wrapper run: | cmake -B build . build-wrapper-linux-x86-64 --out-dir ${{ env.BUILD_WRAPPER_OUT_DIR }} cmake --build build - - name: Run sonar-scanner + - name: SonarQube Scan + uses: SonarSource/sonarqube-scan-action@v4.2.1 env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - run: | - sonar-scanner --define sonar.host.url="${{ env.SONAR_SERVER_URL }}" --define sonar.cfamily.build-wrapper-output="${{ env.BUILD_WRAPPER_OUT_DIR }}" + SONAR_ROOT_CERT: ${{ secrets.SONAR_ROOT_CERT }} + with: + # Consult https://docs.sonarsource.com/sonarqube-server/latest/analyzing-source-code/scanners/sonarscanner/ for more information and options + args: > + --define sonar.cfamily.compile-commands="${{ env.BUILD_WRAPPER_OUT_DIR }}/compile_commands.json" diff --git a/README.md b/README.md index d040d7a..1f5a9f4 100644 --- a/README.md +++ b/README.md @@ -29,7 +29,7 @@ The missing parts are in development and the version with a new engine will be m There are some other projects that use UEFITool's engine: * UEFIExtract, which uses ffsParser to parse supplied firmware image into a tree structure and dumps the parsed structure recursively on the FS. Jethro Beekman's [tree](https://github.com/jethrogb/uefireverse) utility can be used to work with the extracted tree. -* UEFIFind, which uses ffsParser to find image elements containing a specified pattern. It was developed for [UBU](http://www.win-raid.com/t154f16-Tool-Guide-News-quot-UEFI-BIOS-Updater-quot-UBU.html) project. +* UEFIFind, which uses ffsParser to find image elements containing a specified pattern. It was developed for [UBU](https://winraid.level1techs.com/t/tool-guide-news-uefi-bios-updater-ubu/30357) project. ## Alternatives @@ -42,19 +42,24 @@ Right now there are some alternatives to UEFITool that you could find useful too ## Installation -You can either use [pre-built binaries for Windows and macOS](https://github.com/LongSoft/UEFITool/releases) or build a binary yourself. +You can either use [pre-built binaries](https://github.com/LongSoft/UEFITool/releases) or build a binary yourself. * To build a binary that uses Qt library (UEFITool) you need a C++ compiler and an instance of [Qt5 or Qt6](https://www.qt.io) library. Install both of them, get the sources, generate makefiles using qmake (`qmake ./UEFITool/uefitool.pro`) and use your system's make command on that generated files (i.e. `nmake release`, `make release` and so on). Qt6-based builds can also use CMAKE as an altearnative build system. * To build a binary that doesn't use Qt (UEFIExtract, UEFIFind), you need a C++ compiler and [CMAKE](https://cmake.org) utility to generate a makefile for your OS and build environment. Install both of them, get the sources, generate makefiles using cmake (`cmake UEFIExtract`) and use your system's make command on that generated files (i.e. `nmake release`, `make release` and so on). Non-Qt builds can also use Meson as an alternative build system. ## Known issues + * Image editing is currently only possible using an outdated and unsupported UEFITool 0.28 (`old_engine` branch) and the tools based on it (`UEFIReplace`, `UEFIPatch`). This is the top priority [issue #67](https://github.com/LongSoft/UEFITool/issues/67), which is being worked on, albeit slowly (due to the amount of coding and testing required to implement it correctly). * Some vendor-specific firmware update files can be opened incorrectly or can't be opened at all. This includes encrypted HP update files, Dell HDR and EXE files, some InsydeFlash FD files and so on. Enabling support for such files will require massive amount of reverse-engineering which is almost pointless because the updated image can be obtained from BIOS chip where it's already decrypted and unpacked. * Intel Firmware Interface Table (FIT) editing is not supported right now. FIT contains pointers to various image components that must be loaded before executing the first CPU instruction from the BIOS chip. Those components include CPU microcode updates, binaries and settings used by BIOS Guard and Boot Guard technologies and some other stuff. More information on FIT can be obtained [here](https://edc.intel.com/content/www/us/en/design/products-and-solutions/software-and-services/firmware-and-bios/firmware-interface-table/firmware-interface-table/). -* Windows builds of `UEFIExtract` might encouter an issue with folder paths being longer than 260 bytes (`MAX_PATH`) on some input files (see [issue #363](https://github.com/LongSoft/UEFITool/issues/363)). This is a [known Windows limitation](https://learn.microsoft.com/en-us/windows/win32/fileio/maximum-file-path-limitation?tabs=registry), that can be fixed by enabling long paths support via Windows Registry and adding a manifest to the executable file that requires such support. `UEFIExtract` has the required manifest additions since version `A67`, and the required registry file is provided by Microsoft on the page linked above, but this workaround is only awailable starting with Windows 10 build 1067. +* Windows builds of `UEFIExtract` and `UEFIFind` might encouter an issue with folder paths being longer than 260 bytes (`MAX_PATH`) on some input files (see [issue #363](https://github.com/LongSoft/UEFITool/issues/363)). This is a [known Windows limitation](https://learn.microsoft.com/en-us/windows/win32/fileio/maximum-file-path-limitation?tabs=registry), that can be fixed by enabling long paths support via Windows Registry and adding a manifest to the executable file that requires such support. `UEFIExtract` has the required manifest additions since version `A67`, and the required registry file is provided by Microsoft on the page linked above, but this workaround is only awailable starting with Windows 10 build 1067. ## Bug repellents -* [Coverity Scan](https://scan.coverity.com/projects/17209) - static analyzer for C, C++, C#, JavaScript, Ruby, or Python code. -* [SonarCloud](https://sonarcloud.io/project/overview?id=LongSoft_UEFITool) - cloud-based code analysis service. -* [PVS-Studio](https://pvs-studio.com/en/pvs-studio/?utm_source=github&utm_medium=organic&utm_campaign=open_source) - static analyzer for C, C++, C#, and Java code. -* [CodeQL](https://codeql.github.com/docs/codeql-overview/about-codeql) - code analysis engine developed by GitHub to automate security checks. +* [Coverity Scan](https://scan.coverity.com/projects/17209) - static analyzer for C, C++, C#, JavaScript, Ruby, or Python code. +* [SonarCloud](https://sonarcloud.io/project/overview?id=LongSoft_UEFITool) - cloud-based source code analysis service. + +## GUID Database + +Every new release includes an update to the database of known UEFI-related GUIDs build with help of [Linux Vendor Firmware Service](https://fwupd.org). + +You can download the up-to-date version of that database using [this link](https://fwupd.org/lvfs/shards/export/csv). diff --git a/UEFIExtract/CMakeLists.txt b/UEFIExtract/CMakeLists.txt index 850a74d..ac174d7 100644 --- a/UEFIExtract/CMakeLists.txt +++ b/UEFIExtract/CMakeLists.txt @@ -1,4 +1,4 @@ -CMAKE_MINIMUM_REQUIRED(VERSION 3.1.0 FATAL_ERROR) +CMAKE_MINIMUM_REQUIRED(VERSION 3.22) PROJECT(UEFIExtract) @@ -35,6 +35,17 @@ SET(PROJECT_SOURCES ../common/bstrlib/bstrlib.c ../common/bstrlib/bstrwrap.cpp ../common/generated/ami_nvar.cpp + ../common/generated/apple_sysf.cpp + ../common/generated/dell_dvar.cpp + ../common/generated/edk2_vss.cpp + ../common/generated/edk2_vss2.cpp + ../common/generated/edk2_ftw.cpp + ../common/generated/insyde_fdc.cpp + ../common/generated/insyde_fdm.cpp + ../common/generated/ms_slic_marker.cpp + ../common/generated/ms_slic_pubkey.cpp + ../common/generated/phoenix_flm.cpp + ../common/generated/phoenix_evsa.cpp ../common/generated/intel_acbp_v1.cpp ../common/generated/intel_acbp_v2.cpp ../common/generated/intel_keym_v1.cpp diff --git a/UEFIExtract/ffsdumper.cpp b/UEFIExtract/ffsdumper.cpp index 44e639b..030904a 100644 --- a/UEFIExtract/ffsdumper.cpp +++ b/UEFIExtract/ffsdumper.cpp @@ -59,7 +59,7 @@ USTATUS FfsDumper::recursiveDump(const UModelIndex & index, const UString & path } if (currentPath != path) { - counterHeader = counterBody = counterRaw = counterInfo = 0; + counterHeader = counterBody = counterUncData = counterRaw = counterInfo = 0; currentPath = path; } @@ -68,7 +68,7 @@ USTATUS FfsDumper::recursiveDump(const UModelIndex & index, const UString & path && (sectionType == IgnoreSectionType || model->subtype(index) == sectionType)) { if ((dumpMode == DUMP_ALL || dumpMode == DUMP_CURRENT || dumpMode == DUMP_HEADER) - && !model->header(index).isEmpty()) { + && !model->hasEmptyHeader(index)) { fileList.insert(index); UString filename; @@ -91,7 +91,7 @@ USTATUS FfsDumper::recursiveDump(const UModelIndex & index, const UString & path } if ((dumpMode == DUMP_ALL || dumpMode == DUMP_CURRENT || dumpMode == DUMP_BODY) - && !model->body(index).isEmpty()) { + && !model->hasEmptyBody(index)) { fileList.insert(index); UString filename; if (counterBody == 0) @@ -112,6 +112,28 @@ USTATUS FfsDumper::recursiveDump(const UModelIndex & index, const UString & path dumped = true; } + if ((dumpMode == DUMP_ALL || dumpMode == DUMP_CURRENT || dumpMode == DUMP_UNC_DATA) + && !model->hasEmptyUncompressedData(index)) { + fileList.insert(index); + UString filename; + if (counterUncData == 0) + filename = usprintf("%s/unc_data.bin", path.toLocal8Bit()); + else + filename = usprintf("%s/unc_data_%d.bin", path.toLocal8Bit(), counterUncData); + counterUncData++; + + std::ofstream file(filename.toLocal8Bit(), std::ofstream::binary); + if (!file) { + printf("Cannot open uncompressed data \"%s\".\n", (const char*)filename.toLocal8Bit()); + return U_FILE_OPEN; + } + + const UByteArray &data = model->uncompressedData(index); + file.write(data.constData(), data.size()); + + dumped = true; + } + if (dumpMode == DUMP_FILE) { UModelIndex fileIndex = index; if (model->type(fileIndex) != Types::File) { diff --git a/UEFIExtract/ffsdumper.h b/UEFIExtract/ffsdumper.h index 8b2a7ec..007cf11 100644 --- a/UEFIExtract/ffsdumper.h +++ b/UEFIExtract/ffsdumper.h @@ -30,6 +30,7 @@ public: DUMP_CURRENT, DUMP_ALL, DUMP_BODY, + DUMP_UNC_DATA, DUMP_HEADER, DUMP_INFO, DUMP_FILE @@ -38,7 +39,7 @@ public: static const UINT8 IgnoreSectionType = 0xFF; explicit FfsDumper(TreeModel * treeModel) : model(treeModel), dumped(false), - counterHeader(0), counterBody(0), counterRaw(0), counterInfo(0) {} + counterHeader(0), counterBody(0), counterUncData(0), counterRaw(0), counterInfo(0) {} ~FfsDumper() {}; USTATUS dump(const UModelIndex & root, const UString & path, const DumpMode dumpMode = DUMP_CURRENT, const UINT8 sectionType = IgnoreSectionType, const UString & guid = UString()); @@ -48,7 +49,7 @@ private: TreeModel* model; UString currentPath; bool dumped; - int counterHeader, counterBody, counterRaw, counterInfo; + int counterHeader, counterBody, counterUncData, counterRaw, counterInfo; std::set fileList; }; #endif // FFSDUMPER_H diff --git a/UEFIExtract/uefiextract_main.cpp b/UEFIExtract/uefiextract_main.cpp index 78db042..e0ccab2 100644 --- a/UEFIExtract/uefiextract_main.cpp +++ b/UEFIExtract/uefiextract_main.cpp @@ -42,7 +42,7 @@ void print_usage() << " UEFIExtract imagefile guids - only generate GUID database, no dump or report needed." << std::endl << " UEFIExtract imagefile GUID_1 ... [ -o FILE_1 ... ] [ -m MODE_1 ... ] [ -t TYPE_1 ... ] -" << std::endl << " Dump only FFS file(s) with specific GUID(s), without report or GUID database." << std::endl - << " Type is section type or FF to ignore. Mode is one of: all, body, header, info, file." << std::endl + << " Type is section type or FF to ignore. Mode is one of: all, body, unc_data, header, info, file." << std::endl << " Return value is a bit mask where 0 at position N means that file with GUID_N was found and unpacked, 1 otherwise." << std::endl; } @@ -87,7 +87,7 @@ int main(int argc, char *argv[]) // Parse input buffer result = ffsParser.parse(buffer); if (result) - return result; + return (int)result; ffsParser.outputInfo(); @@ -102,7 +102,7 @@ int main(int argc, char *argv[]) else if (argc == 3 && !std::strcmp(argv[2], "guids")) { GuidDatabase db = guidDatabaseFromTreeRecursive(&model, model.index(0, 0)); if (!db.empty()) { - return guidDatabaseExportToFile(path + UString(".guids.csv"), db); + return (int)guidDatabaseExportToFile(path + UString(".guids.csv"), db); } } // Generate report, no dump or GUID database @@ -175,6 +175,8 @@ int main(int argc, char *argv[]) modes.push_back(FfsDumper::DUMP_ALL); else if (!std::strcmp(arg, "body")) modes.push_back(FfsDumper::DUMP_BODY); + else if (!std::strcmp(arg, "unc_data")) + modes.push_back(FfsDumper::DUMP_UNC_DATA); else if (!std::strcmp(arg, "header")) modes.push_back(FfsDumper::DUMP_HEADER); else if (!std::strcmp(arg, "info")) @@ -208,7 +210,7 @@ int main(int argc, char *argv[]) } } - return lastError; + return (int)lastError; } // If parameters are different, show version and usage information diff --git a/UEFIFind/CMakeLists.txt b/UEFIFind/CMakeLists.txt index 477e38d..c7f0a8f 100644 --- a/UEFIFind/CMakeLists.txt +++ b/UEFIFind/CMakeLists.txt @@ -1,4 +1,4 @@ -CMAKE_MINIMUM_REQUIRED(VERSION 3.1.0 FATAL_ERROR) +CMAKE_MINIMUM_REQUIRED(VERSION 3.22) PROJECT(UEFIFind) @@ -32,6 +32,17 @@ SET(PROJECT_SOURCES ../common/bstrlib/bstrlib.c ../common/bstrlib/bstrwrap.cpp ../common/generated/ami_nvar.cpp + ../common/generated/apple_sysf.cpp + ../common/generated/dell_dvar.cpp + ../common/generated/edk2_vss.cpp + ../common/generated/edk2_vss2.cpp + ../common/generated/edk2_ftw.cpp + ../common/generated/insyde_fdc.cpp + ../common/generated/insyde_fdm.cpp + ../common/generated/ms_slic_marker.cpp + ../common/generated/ms_slic_pubkey.cpp + ../common/generated/phoenix_flm.cpp + ../common/generated/phoenix_evsa.cpp ../common/generated/intel_acbp_v1.cpp ../common/generated/intel_acbp_v2.cpp ../common/generated/intel_keym_v1.cpp @@ -59,7 +70,7 @@ SET(PROJECT_SOURCES ../common/zlib/zutil.c ) -ADD_EXECUTABLE(UEFIFind ${PROJECT_SOURCES}) +ADD_EXECUTABLE(UEFIFind ${PROJECT_SOURCES} uefifind.manifest) IF(UNIX) SET_TARGET_PROPERTIES(UEFIFind PROPERTIES OUTPUT_NAME uefifind) diff --git a/UEFIFind/uefifind.manifest b/UEFIFind/uefifind.manifest new file mode 100644 index 0000000..af77ac4 --- /dev/null +++ b/UEFIFind/uefifind.manifest @@ -0,0 +1,8 @@ + + + + + true + + + \ No newline at end of file diff --git a/UEFITool/CMakeLists.txt b/UEFITool/CMakeLists.txt index aef60d0..363f5c1 100644 --- a/UEFITool/CMakeLists.txt +++ b/UEFITool/CMakeLists.txt @@ -23,7 +23,6 @@ SET(PROJECT_HEADERS hexviewdialog.h gotobasedialog.h gotoaddressdialog.h - qhexview5/qhexview.h ) SET(PROJECT_SOURCES @@ -36,19 +35,6 @@ SET(PROJECT_SOURCES hexlineedit.cpp ffsfinder.cpp hexspinbox.cpp - qhexview5/model/buffer/qhexbuffer.cpp - qhexview5/model/buffer/qdevicebuffer.cpp - qhexview5/model/buffer/qmemorybuffer.cpp - qhexview5/model/commands/hexcommand.cpp - qhexview5/model/commands/insertcommand.cpp - qhexview5/model/commands/removecommand.cpp - qhexview5/model/commands/replacecommand.cpp - qhexview5/model/qhexcursor.cpp - qhexview5/model/qhexdelegate.cpp - qhexview5/model/qhexdocument.cpp - qhexview5/model/qhexmetadata.cpp - qhexview5/model/qhexutils.cpp - qhexview5/qhexview.cpp ../common/fitparser.cpp ../common/guiddatabase.cpp ../common/nvram.cpp @@ -82,6 +68,17 @@ SET(PROJECT_SOURCES ../common/digest/sha512.c ../common/digest/sm3.c ../common/generated/ami_nvar.cpp + ../common/generated/apple_sysf.cpp + ../common/generated/dell_dvar.cpp + ../common/generated/edk2_vss.cpp + ../common/generated/edk2_vss2.cpp + ../common/generated/edk2_ftw.cpp + ../common/generated/insyde_fdc.cpp + ../common/generated/insyde_fdm.cpp + ../common/generated/ms_slic_marker.cpp + ../common/generated/ms_slic_pubkey.cpp + ../common/generated/phoenix_evsa.cpp + ../common/generated/phoenix_flm.cpp ../common/generated/intel_acbp_v1.cpp ../common/generated/intel_acbp_v2.cpp ../common/generated/intel_keym_v1.cpp @@ -124,6 +121,9 @@ TARGET_INCLUDE_DIRECTORIES(UEFITool PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}") TARGET_LINK_LIBRARIES(UEFITool PRIVATE Qt6::Widgets) +ADD_SUBDIRECTORY(QHexView) +TARGET_LINK_LIBRARIES(UEFITool PRIVATE QHexView) + SET_TARGET_PROPERTIES(UEFITool PROPERTIES WIN32_EXECUTABLE ON MACOSX_BUNDLE ON diff --git a/UEFITool/Info.plist b/UEFITool/Info.plist index b34bd7a..b63e115 100644 --- a/UEFITool/Info.plist +++ b/UEFITool/Info.plist @@ -22,7 +22,7 @@ CFBundleIconFile uefitool CFBundleIdentifier - $(PRODUCT_BUNDLE_IDENTIFIER) + me.coderush.UEFITool CFBundlePackageType APPL CFBundleSignature diff --git a/UEFITool/QHexView/CMakeLists.txt b/UEFITool/QHexView/CMakeLists.txt new file mode 100644 index 0000000..8fbb2a8 --- /dev/null +++ b/UEFITool/QHexView/CMakeLists.txt @@ -0,0 +1,91 @@ +cmake_minimum_required(VERSION 3.13) + +project(QHexView) + +option(QHEXVIEW_BUILD_EXAMPLE "Build Example Application" OFF) +option(QHEXVIEW_USE_QT5 "Enable Qt5 build" OFF) +option(QHEXVIEW_ENABLE_DIALOGS "BuiltIn dialogs" OFF) + +if(QHEXVIEW_USE_QT5) + find_package(Qt5 REQUIRED COMPONENTS Widgets) +else() + find_package(Qt6 COMPONENTS Widgets) + + if(NOT Qt6_FOUND) + find_package(Qt5 REQUIRED COMPONENTS Widgets) + endif() +endif() + +add_library(${PROJECT_NAME} STATIC) + +set_target_properties(${PROJECT_NAME} + PROPERTIES + CXX_STANDARD_REQUIRED YES + CXX_STANDARD 11 + AUTOMOC ON +) + +target_link_libraries(${PROJECT_NAME} + PUBLIC + Qt::Widgets +) + +target_include_directories(${PROJECT_NAME} + PUBLIC + "${PROJECT_SOURCE_DIR}/include" +) + +target_sources(${PROJECT_NAME} + PRIVATE + include/QHexView/model/buffer/qdevicebuffer.h + include/QHexView/model/buffer/qhexbuffer.h + include/QHexView/model/buffer/qmappedfilebuffer.h + include/QHexView/model/buffer/qmemorybuffer.h + include/QHexView/model/buffer/qmemoryrefbuffer.h + include/QHexView/model/commands/hexcommand.h + include/QHexView/model/commands/insertcommand.h + include/QHexView/model/commands/removecommand.h + include/QHexView/model/commands/replacecommand.h + include/QHexView/model/commands/replacecommand.h + include/QHexView/model/qhexcursor.h + include/QHexView/model/qhexdelegate.h + include/QHexView/model/qhexdocument.h + include/QHexView/model/qhexmetadata.h + include/QHexView/model/qhexoptions.h + include/QHexView/model/qhexutils.h + include/QHexView/qhexview.h + + PRIVATE + src/model/commands/hexcommand.cpp + src/model/commands/insertcommand.cpp + src/model/commands/removecommand.cpp + src/model/commands/replacecommand.cpp + src/model/buffer/qdevicebuffer.cpp + src/model/buffer/qhexbuffer.cpp + src/model/buffer/qmemorybuffer.cpp + src/model/buffer/qmemoryrefbuffer.cpp + src/model/buffer/qmappedfilebuffer.cpp + src/model/qhexdelegate.cpp + src/model/qhexutils.cpp + src/model/qhexcursor.cpp + src/model/qhexmetadata.cpp + src/model/qhexdocument.cpp + src/qhexview.cpp +) + +if(QHEXVIEW_ENABLE_DIALOGS) + target_sources(${PROJECT_NAME} + PRIVATE + include/QHexView/dialogs/hexfinddialog.h + src/dialogs/hexfinddialog.cpp + ) + + target_compile_definitions(${PROJECT_NAME} + PUBLIC + QHEXVIEW_ENABLE_DIALOGS + ) +endif() + +if(QHEXVIEW_BUILD_EXAMPLE) + add_subdirectory(example) +endif() diff --git a/UEFITool/qhexview5/LICENSE b/UEFITool/QHexView/LICENSE similarity index 100% rename from UEFITool/qhexview5/LICENSE rename to UEFITool/QHexView/LICENSE diff --git a/UEFITool/QHexView/include/QHexView/dialogs/hexfinddialog.h b/UEFITool/QHexView/include/QHexView/dialogs/hexfinddialog.h new file mode 100644 index 0000000..d041db9 --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/dialogs/hexfinddialog.h @@ -0,0 +1,56 @@ +#pragma once + +#include +#include + +class QRegularExpressionValidator; +class QDoubleValidator; +class QIntValidator; +class QHexView; + +class HexFindDialog: public QDialog { + Q_OBJECT + +public: + enum class Type { Find, Replace }; + +public: + explicit HexFindDialog(HexFindDialog::Type type = Type::Find, + QHexView* parent = nullptr); + QHexView* hexView() const; + +private Q_SLOTS: + void updateFindOptions(int); + void validateActions(); + void replace(); + void find(); + +private: + bool prepareOptions(QString& q, QHexFindMode& mode, QHexFindDirection& fd); + bool validateIntRange(uint v) const; + void checkResult(const QString& q, qint64 offset, QHexFindDirection fd); + void prepareTextMode(QLayout* l); + void prepareHexMode(QLayout* l); + void prepareIntMode(QLayout* l); + void prepareFloatMode(QLayout* l); + +private: + QRegularExpressionValidator *m_hexvalidator, *m_hexpvalidator; + QDoubleValidator* m_dblvalidator; + QIntValidator* m_intvalidator; + int m_oldidxbits{-1}, m_oldidxendian{-1}; + unsigned int m_findoptions{0}; + qint64 m_startoffset{-1}; + Type m_type; + +private: + static const QString BUTTONBOX; + static const QString CBFINDMODE; + static const QString LEFIND; + static const QString LEREPLACE; + static const QString HLAYOUT; + static const QString GBOPTIONS; + static const QString RBALL; + static const QString RBFORWARD; + static const QString RBBACKWARD; +}; diff --git a/UEFITool/QHexView/include/QHexView/model/buffer/qdevicebuffer.h b/UEFITool/QHexView/include/QHexView/model/buffer/qdevicebuffer.h new file mode 100644 index 0000000..39fccef --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/model/buffer/qdevicebuffer.h @@ -0,0 +1,24 @@ +#pragma once + +#include + +class QDeviceBuffer: public QHexBuffer { + Q_OBJECT + +public: + explicit QDeviceBuffer(QObject* parent = nullptr); + virtual ~QDeviceBuffer(); + uchar at(qint64 idx) override; + qint64 length() const override; + void insert(qint64 offset, const QByteArray& data) override; + void replace(qint64 offset, const QByteArray& data) override; + void remove(qint64 offset, int length) override; + QByteArray read(qint64 offset, int length) override; + bool read(QIODevice* device) override; + void write(QIODevice* device) override; + qint64 indexOf(const QByteArray& ba, qint64 from) override; + qint64 lastIndexOf(const QByteArray& ba, qint64 from) override; + +protected: + QIODevice* m_device{nullptr}; +}; diff --git a/UEFITool/QHexView/include/QHexView/model/buffer/qhexbuffer.h b/UEFITool/QHexView/include/QHexView/model/buffer/qhexbuffer.h new file mode 100644 index 0000000..0c6424f --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/model/buffer/qhexbuffer.h @@ -0,0 +1,29 @@ +#pragma once + +#include +#include + +class QHexBuffer: public QObject { + Q_OBJECT + +public: + explicit QHexBuffer(QObject* parent = nullptr); + bool isEmpty() const; + +public: + virtual uchar at(qint64 idx); + virtual bool accept(qint64 idx) const; + virtual void replace(qint64 offset, const QByteArray& data); + virtual void read(char* data, int size); + virtual void read(const QByteArray& ba); + +public: + virtual qint64 length() const = 0; + virtual void insert(qint64 offset, const QByteArray& data) = 0; + virtual void remove(qint64 offset, int length) = 0; + virtual QByteArray read(qint64 offset, int length) = 0; + virtual bool read(QIODevice* iodevice) = 0; + virtual void write(QIODevice* iodevice) = 0; + virtual qint64 indexOf(const QByteArray& ba, qint64 from) = 0; + virtual qint64 lastIndexOf(const QByteArray& ba, qint64 from) = 0; +}; diff --git a/UEFITool/QHexView/include/QHexView/model/buffer/qmappedfilebuffer.h b/UEFITool/QHexView/include/QHexView/model/buffer/qmappedfilebuffer.h new file mode 100644 index 0000000..f4f9239 --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/model/buffer/qmappedfilebuffer.h @@ -0,0 +1,20 @@ +#pragma once + +#include + +class QMappedFileBuffer: public QDeviceBuffer { +public: + explicit QMappedFileBuffer(QObject* parent = nullptr); + virtual ~QMappedFileBuffer(); + +public: + QByteArray read(qint64 offset, int length) override; + bool read(QIODevice* iodevice) override; + void write(QIODevice* iodevice) override; + +private: + void remap(); + +private: + uchar* m_mappeddata{nullptr}; +}; diff --git a/UEFITool/QHexView/include/QHexView/model/buffer/qmemorybuffer.h b/UEFITool/QHexView/include/QHexView/model/buffer/qmemorybuffer.h new file mode 100644 index 0000000..b8f4c5b --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/model/buffer/qmemorybuffer.h @@ -0,0 +1,22 @@ +#pragma once + +#include + +class QMemoryBuffer: public QHexBuffer { + Q_OBJECT + +public: + explicit QMemoryBuffer(QObject* parent = nullptr); + uchar at(qint64 idx) override; + qint64 length() const override; + void insert(qint64 offset, const QByteArray& data) override; + void remove(qint64 offset, int length) override; + QByteArray read(qint64 offset, int length) override; + bool read(QIODevice* device) override; + void write(QIODevice* device) override; + qint64 indexOf(const QByteArray& ba, qint64 from) override; + qint64 lastIndexOf(const QByteArray& ba, qint64 from) override; + +private: + QByteArray m_buffer; +}; diff --git a/UEFITool/QHexView/include/QHexView/model/buffer/qmemoryrefbuffer.h b/UEFITool/QHexView/include/QHexView/model/buffer/qmemoryrefbuffer.h new file mode 100644 index 0000000..d1f29b5 --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/model/buffer/qmemoryrefbuffer.h @@ -0,0 +1,12 @@ +#pragma once + +#include + +class QMemoryRefBuffer: public QDeviceBuffer { + Q_OBJECT + +public: + explicit QMemoryRefBuffer(QObject* parent = nullptr); + bool read(QIODevice* device) override; + void write(QIODevice* device) override; +}; diff --git a/UEFITool/QHexView/include/QHexView/model/commands/hexcommand.h b/UEFITool/QHexView/include/QHexView/model/commands/hexcommand.h new file mode 100644 index 0000000..16637f4 --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/model/commands/hexcommand.h @@ -0,0 +1,19 @@ +#pragma once + +#include +#include + +class QHexDocument; + +class HexCommand: public QUndoCommand { +public: + HexCommand(QHexBuffer* buffer, QHexDocument* document, + QUndoCommand* parent = nullptr); + +protected: + QHexDocument* m_hexdocument; + QHexBuffer* m_buffer; + qint64 m_offset; + int m_length; + QByteArray m_data; +}; diff --git a/UEFITool/QHexView/include/QHexView/model/commands/insertcommand.h b/UEFITool/QHexView/include/QHexView/model/commands/insertcommand.h new file mode 100644 index 0000000..971a4d9 --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/model/commands/insertcommand.h @@ -0,0 +1,11 @@ +#pragma once + +#include + +class InsertCommand: public HexCommand { +public: + InsertCommand(QHexBuffer* buffer, QHexDocument* document, qint64 offset, + const QByteArray& data, QUndoCommand* parent = nullptr); + void undo() override; + void redo() override; +}; diff --git a/UEFITool/QHexView/include/QHexView/model/commands/removecommand.h b/UEFITool/QHexView/include/QHexView/model/commands/removecommand.h new file mode 100644 index 0000000..a1bf13b --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/model/commands/removecommand.h @@ -0,0 +1,11 @@ +#pragma once + +#include + +class RemoveCommand: public HexCommand { +public: + RemoveCommand(QHexBuffer* buffer, QHexDocument* document, qint64 offset, + int length, QUndoCommand* parent = nullptr); + void undo() override; + void redo() override; +}; diff --git a/UEFITool/QHexView/include/QHexView/model/commands/replacecommand.h b/UEFITool/QHexView/include/QHexView/model/commands/replacecommand.h new file mode 100644 index 0000000..13912d7 --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/model/commands/replacecommand.h @@ -0,0 +1,14 @@ +#pragma once + +#include + +class ReplaceCommand: public HexCommand { +public: + ReplaceCommand(QHexBuffer* buffer, QHexDocument* document, qint64 offset, + const QByteArray& data, QUndoCommand* parent = nullptr); + void undo() override; + void redo() override; + +private: + QByteArray m_olddata; +}; diff --git a/UEFITool/QHexView/include/QHexView/model/qhexcursor.h b/UEFITool/QHexView/include/QHexView/model/qhexcursor.h new file mode 100644 index 0000000..3651398 --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/model/qhexcursor.h @@ -0,0 +1,73 @@ +#pragma once + +#include +#include +#include + +class QHexView; + +class QHexCursor: public QObject { + Q_OBJECT + +public: + enum class Mode { Overwrite, Insert }; + +private: + explicit QHexCursor(const QHexOptions* options, QHexView* parent = nullptr); + +public: + QHexView* hexView() const; + Mode mode() const; + qint64 line() const; + qint64 column() const; + qint64 offset() const; + qint64 address() const; + quint64 lineAddress() const; + qint64 selectionStartOffset() const; + qint64 selectionEndOffset() const; + qint64 selectionLength() const; + QHexPosition position() const; + QHexPosition selectionStart() const; + QHexPosition selectionEnd() const; + QByteArray selectedBytes() const; + bool hasSelection() const; + bool isSelected(qint64 line, qint64 column) const; + void setMode(Mode m); + void move(qint64 offset); + void move(qint64 line, qint64 column); + void move(QHexPosition pos); + void select(qint64 offset); + void select(qint64 line, qint64 column); + void select(QHexPosition pos); + void selectSize(qint64 length); + qint64 replace(const QVariant& oldvalue, const QVariant& newvalue, + qint64 offset, QHexFindMode mode = QHexFindMode::Text, + unsigned int options = QHexFindOptions::None, + QHexFindDirection fd = QHexFindDirection::Forward) const; + qint64 find(const QVariant& value, qint64 offset, + QHexFindMode mode = QHexFindMode::Text, + unsigned int options = QHexFindOptions::None, + QHexFindDirection fd = QHexFindDirection::Forward) const; + qint64 positionToOffset(QHexPosition pos) const; + QHexPosition offsetToPosition(qint64 offset) const; + +public Q_SLOTS: + void cut(bool hex = false); + void copy(bool hex = false) const; + void paste(bool hex = false); + void selectAll(); + void removeSelection(); + void clearSelection(); + void switchMode(); + +Q_SIGNALS: + void positionChanged(); + void modeChanged(); + +private: + const QHexOptions* m_options; + Mode m_mode{Mode::Overwrite}; + QHexPosition m_position{}, m_selection{}; + + friend class QHexView; +}; diff --git a/UEFITool/QHexView/include/QHexView/model/qhexdelegate.h b/UEFITool/QHexView/include/QHexView/model/qhexdelegate.h new file mode 100644 index 0000000..c698589 --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/model/qhexdelegate.h @@ -0,0 +1,30 @@ +#pragma once + +#include +#include +#include + +class QHexView; + +class QHexDelegate: public QObject { + Q_OBJECT + +public: + explicit QHexDelegate(QObject* parent = nullptr); + virtual ~QHexDelegate() = default; + virtual QString addressHeader(const QHexView* hexview) const; + virtual QString hexHeader(const QHexView* hexview) const; + virtual QString asciiHeader(const QHexView* hexview) const; + virtual void renderAddress(quint64 address, QTextCharFormat& cf, + const QHexView* hexview) const; + virtual void renderHeader(QTextBlockFormat& bf, + const QHexView* hexview) const; + virtual void renderHeaderPart(const QString& s, QHexArea area, + QTextCharFormat& cf, + const QHexView* hexview) const; + virtual bool render(quint64 offset, quint8 b, QTextCharFormat& outcf, + const QHexView* hexview) const; + virtual bool paintSeparator(QPainter* painter, QLineF line, + const QHexView* hexview) const; + virtual void paint(QPainter* painter, const QHexView* hexview) const; +}; diff --git a/UEFITool/QHexView/include/QHexView/model/qhexdocument.h b/UEFITool/QHexView/include/QHexView/model/qhexdocument.h new file mode 100644 index 0000000..30f9d99 --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/model/qhexdocument.h @@ -0,0 +1,102 @@ +#pragma once + +#include +#include +#include + +class QHexCursor; + +class QHexDocument: public QObject { + Q_OBJECT + +public: + enum class ChangeReason { Insert, Remove, Replace }; + enum class FindDirection { Forward, Backward }; + Q_ENUM(ChangeReason); + Q_ENUM(FindDirection); + +private: + explicit QHexDocument(QHexBuffer* buffer, QObject* parent = nullptr); + bool accept(qint64 idx) const; + +public: + bool isEmpty() const; + bool isModified() const; + bool canUndo() const; + bool canRedo() const; + void setData(const QByteArray& ba); + void setData(QHexBuffer* buffer); + qint64 length() const; + qint64 indexOf(const QByteArray& ba, qint64 from = 0); + qint64 lastIndexOf(const QByteArray& ba, qint64 from = 0); + QByteArray read(qint64 offset, int len = 0) const; + uchar at(int offset) const; + +public Q_SLOTS: + void clearModified(); + void undo(); + void redo(); + void insert(qint64 offset, uchar b); + void replace(qint64 offset, uchar b); + void insert(qint64 offset, const QByteArray& data); + void replace(qint64 offset, const QByteArray& data); + void remove(qint64 offset, int len); + bool saveTo(QIODevice* device); + +public: + template + static QHexDocument* fromDevice(QIODevice* iodevice, + QObject* parent = nullptr); + template + static QHexDocument* fromMemory(char* data, int size, + QObject* parent = nullptr); + template + static QHexDocument* fromMemory(const QByteArray& ba, + QObject* parent = nullptr); + static QHexDocument* fromBuffer(QHexBuffer* buffer, + QObject* parent = nullptr); + static QHexDocument* fromLargeFile(QString filename, + QObject* parent = nullptr); + static QHexDocument* fromMappedFile(QString filename, + QObject* parent = nullptr); + static QHexDocument* fromFile(QString filename, QObject* parent = nullptr); + static QHexDocument* create(QObject* parent = nullptr); + +Q_SIGNALS: + void modifiedChanged(bool modified); + void canUndoChanged(bool canundo); + void canRedoChanged(bool canredo); + void dataChanged(const QByteArray& data, quint64 offset, + QHexDocument::ChangeReason reason); + void changed(); + void reset(); + +private: + QHexBuffer* m_buffer; + QUndoStack m_undostack; + + friend class QHexView; +}; + +template +QHexDocument* QHexDocument::fromDevice(QIODevice* iodevice, QObject* parent) { + QHexBuffer* hexbuffer = new T(parent); + if(Owned) + iodevice->setParent(hexbuffer); + return hexbuffer->read(iodevice) ? new QHexDocument(hexbuffer, parent) + : nullptr; +} + +template +QHexDocument* QHexDocument::fromMemory(char* data, int size, QObject* parent) { + QHexBuffer* hexbuffer = new T(); + hexbuffer->read(data, size); + return new QHexDocument(hexbuffer, parent); +} + +template +QHexDocument* QHexDocument::fromMemory(const QByteArray& ba, QObject* parent) { + QHexBuffer* hexbuffer = new T(); + hexbuffer->read(ba); + return new QHexDocument(hexbuffer, parent); +} diff --git a/UEFITool/QHexView/include/QHexView/model/qhexmetadata.h b/UEFITool/QHexView/include/QHexView/model/qhexmetadata.h new file mode 100644 index 0000000..f4a1517 --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/model/qhexmetadata.h @@ -0,0 +1,92 @@ +#pragma once + +#include +#include +#include +#include +#include +#include + +struct QHexMetadataItem { + qint64 begin, end; + QColor foreground, background; + QString comment; +}; + +using QHexMetadataLine = QList; + +class QHexMetadata: public QObject { + Q_OBJECT + +private: + using ClearMetadataCallback = std::function; + +private: + explicit QHexMetadata(const QHexOptions* options, + QObject* parent = nullptr); + +public: + const QHexMetadataLine* find(qint64 line) const; + QString getComment(qint64 line, qint64 column) const; + void removeMetadata(qint64 line); + void removeBackground(qint64 line); + void removeForeground(qint64 line); + void removeComments(qint64 line); + void unhighlight(qint64 line); + void clear(); + +public: + inline void setMetadata(qint64 begin, qint64 end, const QColor& fgcolor, + const QColor& bgcolor, const QString& comment) { + this->setMetadata({begin, end, fgcolor, bgcolor, comment}); + } + + inline void setForeground(qint64 begin, qint64 end, const QColor& fgcolor) { + this->setMetadata(begin, end, fgcolor, QColor(), QString()); + } + + inline void setBackground(qint64 begin, qint64 end, const QColor& bgcolor) { + this->setMetadata(begin, end, QColor(), bgcolor, QString()); + } + + inline void setComment(qint64 begin, qint64 end, const QString& comment) { + this->setMetadata(begin, end, QColor(), QColor(), comment); + }; + + inline void setMetadataSize(qint64 begin, qint64 length, + const QColor& fgcolor, const QColor& bgcolor, + const QString& comment) { + this->setMetadata({begin, begin + length, fgcolor, bgcolor, comment}); + } + + inline void setForegroundSize(qint64 begin, qint64 length, + const QColor& fgcolor) { + this->setForeground(begin, begin + length, fgcolor); + } + + inline void setBackgroundSize(qint64 begin, qint64 length, + const QColor& bgcolor) { + this->setBackground(begin, begin + length, bgcolor); + } + + inline void setCommentSize(qint64 begin, qint64 length, + const QString& comment) { + this->setComment(begin, begin + length, comment); + }; + +private: + void copy(const QHexMetadata* metadata); + void clearMetadata(qint64 line, ClearMetadataCallback&& cb); + void setMetadata(const QHexMetadataItem& mi); + void invalidate(); + +Q_SIGNALS: + void changed(); + void cleared(); + +private: + QHash m_metadata; + const QHexOptions* m_options; + + friend class QHexView; +}; diff --git a/UEFITool/qhexview5/model/qhexoptions.h b/UEFITool/QHexView/include/QHexView/model/qhexoptions.h similarity index 60% rename from UEFITool/qhexview5/model/qhexoptions.h rename to UEFITool/QHexView/include/QHexView/model/qhexoptions.h index 8505a40..07a2a3a 100644 --- a/UEFITool/qhexview5/model/qhexoptions.h +++ b/UEFITool/QHexView/include/QHexView/model/qhexoptions.h @@ -1,35 +1,36 @@ #pragma once -#include -#include #include +#include +#include namespace QHexFlags { - enum: unsigned int { - None = (1 << 0), - HSeparator = (1 << 1), - VSeparator = (1 << 2), - StyledHeader = (1 << 3), - StyledAddress = (1 << 4), - NoHeader = (1 << 5), - HighlightAddress = (1 << 6), - HighlightColumn = (1 << 7), - Separators = HSeparator | VSeparator, - Styled = StyledHeader | StyledAddress, - }; +enum : unsigned int { + None = (1 << 0), + HSeparator = (1 << 1), + VSeparator = (1 << 2), + StyledHeader = (1 << 3), + StyledAddress = (1 << 4), + NoHeader = (1 << 5), + HighlightAddress = (1 << 6), + HighlightColumn = (1 << 7), + + Separators = HSeparator | VSeparator, + Styled = StyledHeader | StyledAddress, +}; + } -struct QHexColor -{ +struct QHexColor { QColor foreground; QColor background; }; -struct QHexOptions -{ +struct QHexOptions { // Appearance QChar unprintablechar{'.'}; + QChar invalidchar{'?'}; QString addresslabel{""}; QString hexlabel; QString asciilabel; @@ -38,7 +39,7 @@ struct QHexOptions unsigned int linelength{0x10}; unsigned int addresswidth{0}; unsigned int grouplength{1}; - unsigned int scrollsteps{1}; + int scrollsteps{1}; // Colors & Styles QHash bytecolors; diff --git a/UEFITool/QHexView/include/QHexView/model/qhexutils.h b/UEFITool/QHexView/include/QHexView/model/qhexutils.h new file mode 100644 index 0000000..b591479 --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/model/qhexutils.h @@ -0,0 +1,66 @@ +#pragma once + +#include +#include +#include +#include + +struct QHexOptions; +class QHexView; + +namespace QHexFindOptions { + +enum : unsigned int { + None = (1 << 0), + CaseSensitive = (1 << 1), + Int8 = (1 << 2), + Int16 = (1 << 3), + Int32 = (1 << 4), + Int64 = (1 << 5), + Float = (1 << 6), + Double = (1 << 7), + + BigEndian = (1 << 11), +}; + +} + +enum class QHexFindMode { Text, Hex, Int, Float }; +enum class QHexFindDirection { All, Forward, Backward }; +enum class QHexArea { Header, Address, Hex, Ascii, Extra }; + +struct QHexPosition { + qint64 line; + qint64 column; + static inline QHexPosition invalid() { return {-1, -1}; } + inline bool isValid() const { return line >= 0 && column >= 0; } + inline bool operator==(const QHexPosition& rhs) const { + return (line == rhs.line) && (column == rhs.column); + } + inline bool operator!=(const QHexPosition& rhs) const { + return (line != rhs.line) || (column != rhs.column); + } +}; + +namespace QHexUtils { + +bool isHex(char ch); +QByteArray toHex(const QByteArray& ba, char sep); +QByteArray toHex(const QByteArray& ba); +qint64 positionToOffset(const QHexOptions* options, QHexPosition pos); +QHexPosition offsetToPosition(const QHexOptions* options, qint64 offset); +bool checkPattern(QString pattern); + +QPair find(const QHexView* hexview, QVariant value, + qint64 startoffset = 0, + QHexFindMode mode = QHexFindMode::Text, + unsigned int options = QHexFindOptions::None, + QHexFindDirection fd = QHexFindDirection::Forward); + +QPair +replace(const QHexView* hexview, QVariant oldvalue, QVariant newvalue, + qint64 startoffset = 0, QHexFindMode mode = QHexFindMode::Text, + unsigned int options = QHexFindOptions::None, + QHexFindDirection fd = QHexFindDirection::Forward); + +} // namespace QHexUtils diff --git a/UEFITool/QHexView/include/QHexView/qhexview.h b/UEFITool/QHexView/include/QHexView/qhexview.h new file mode 100644 index 0000000..0e3c8c8 --- /dev/null +++ b/UEFITool/QHexView/include/QHexView/qhexview.h @@ -0,0 +1,184 @@ +#pragma once + +#define QHEXVIEW_VERSION 5.0 + +#include +#include +#include +#include +#include +#include +#include +#include + +#if defined(QHEXVIEW_ENABLE_DIALOGS) +class HexFindDialog; +#endif + +class QHexView: public QAbstractScrollArea { + Q_OBJECT + +public: + enum class CopyMode { Visual, HexArraySquare, HexArrayCurly, HexArrayChar }; + Q_ENUM(CopyMode); + +public: + explicit QHexView(QWidget* parent = nullptr); + QRectF headerRect() const; + QRectF addressRect() const; + QRectF hexRect() const; + QRectF asciiRect() const; + QHexDocument* hexDocument() const; + QHexCursor* hexCursor() const; + const QHexMetadata* hexMetadata() const; + QHexOptions options() const; + QColor getReadableColor(QColor c) const; + QByteArray selectedBytes() const; + QByteArray getLine(qint64 line) const; + unsigned int addressWidth() const; + unsigned int lineLength() const; + bool isModified() const; + bool canUndo() const; + bool canRedo() const; + quint64 offset() const; + quint64 address() const; + QHexPosition positionFromOffset(quint64 offset) const; + QHexPosition positionFromAddress(quint64 address) const; + QHexPosition position() const; + QHexPosition selectionStart() const; + QHexPosition selectionEnd() const; + quint64 selectionStartOffset() const; + quint64 selectionEndOffset() const; + quint64 baseAddress() const; + quint64 lines() const; + qint64 replace(const QVariant& oldvalue, const QVariant& newvalue, + qint64 offset, QHexFindMode mode = QHexFindMode::Text, + unsigned int options = QHexFindOptions::None, + QHexFindDirection fd = QHexFindDirection::Forward) const; + qint64 find(const QVariant& value, qint64 offset, + QHexFindMode mode = QHexFindMode::Text, + unsigned int options = QHexFindOptions::None, + QHexFindDirection fd = QHexFindDirection::Forward) const; + void setOptions(const QHexOptions& options); + void setBaseAddress(quint64 baseaddress); + void setDelegate(QHexDelegate* rd); + void setDocument(QHexDocument* doc); + void setData(const QByteArray& ba); + void setData(QHexBuffer* buffer); + void setCursorMode(QHexCursor::Mode mode); + void setByteColor(quint8 b, QHexColor c); + void setByteForeground(quint8 b, QColor c); + void setByteBackground(quint8 b, QColor c); + void setMetadata(qint64 begin, qint64 end, const QColor& fgcolor, + const QColor& bgcolor, const QString& comment); + void setForeground(qint64 begin, qint64 end, const QColor& fgcolor); + void setBackground(qint64 begin, qint64 end, const QColor& bgcolor); + void setComment(qint64 begin, qint64 end, const QString& comment); + void setMetadataSize(qint64 begin, qint64 length, const QColor& fgcolor, + const QColor& bgcolor, const QString& comment); + void setForegroundSize(qint64 begin, qint64 length, const QColor& fgcolor); + void setBackgroundSize(qint64 begin, qint64 length, const QColor& bgcolor); + void setCommentSize(qint64 begin, qint64 length, const QString& comment); + void removeMetadata(qint64 line); + void removeBackground(qint64 line); + void removeForeground(qint64 line); + void removeComments(qint64 line); + void unhighlight(qint64 line); + void clearMetadata(); + +public Q_SLOTS: +#if defined(QHEXVIEW_ENABLE_DIALOGS) + void showFind(); + void showReplace(); +#endif + void undo(); + void redo(); + void cut(bool hex = false); + void copyAs(CopyMode mode = CopyMode::Visual) const; + void copy(bool hex = false) const; + void paste(bool hex = false); + void clearModified(); + void selectAll(); + void removeSelection(); + void switchMode(); + void setAddressWidth(unsigned int w); + void setLineLength(unsigned int l); + void setGroupLength(unsigned int l); + void setScrollSteps(int scrollsteps); + void setReadOnly(bool r); + void setAutoWidth(bool r); + +private: + void paint(QPainter* painter) const; + void checkOptions(); + void checkState(); + void checkAndUpdate(bool calccolumns = false); + void calcColumns(); + void ensureVisible(); + void drawSeparators(QPainter* p) const; + void drawHeader(QTextCursor& c) const; + void drawDocument(QTextCursor& c) const; + QTextCharFormat drawFormat(QTextCursor& c, quint8 b, const QString& s, + QHexArea area, qint64 line, qint64 column, + bool applyformat) const; + unsigned int calcAddressWidth() const; + int visibleLines(bool absolute = false) const; + qint64 getLastColumn(qint64 line) const; + qint64 lastLine() const; + qreal getNCellsWidth(int n) const; + qreal hexColumnWidth() const; + qreal hexColumnX() const; + qreal asciiColumnX() const; + qreal endColumnX() const; + qreal cellWidth() const; + qreal lineHeight() const; + qint64 positionFromLineCol(qint64 line, qint64 col) const; + QHexPosition positionFromPoint(QPoint pt) const; + QPoint absolutePoint(QPoint pt) const; + QHexArea areaFromPoint(QPoint pt) const; + void moveNext(bool select = false); + void movePrevious(bool select = false); + bool keyPressMove(QKeyEvent* e); + bool keyPressTextInput(QKeyEvent* e); + bool keyPressAction(QKeyEvent* e); + +protected: + bool event(QEvent* e) override; + void showEvent(QShowEvent* e) override; + void paintEvent(QPaintEvent*) override; + void resizeEvent(QResizeEvent* e) override; + void focusInEvent(QFocusEvent* e) override; + void focusOutEvent(QFocusEvent* e) override; + void mousePressEvent(QMouseEvent* e) override; + void mouseMoveEvent(QMouseEvent* e) override; + void wheelEvent(QWheelEvent* e) override; + void keyPressEvent(QKeyEvent* e) override; + +private: + static QString reduced(const QString& s, int maxlen); + static bool isColorLight(QColor c); + +Q_SIGNALS: + void dataChanged(const QByteArray& data, quint64 offset, + QHexDocument::ChangeReason reason); + void modifiedChanged(bool modified); + void positionChanged(); + void modeChanged(); + +private: + bool m_readonly{false}, m_writing{false}, m_autowidth{false}; + QHexArea m_currentarea{QHexArea::Ascii}; + QList m_hexcolumns; + QFontMetricsF m_fontmetrics; + QHexOptions m_options; + QHexCursor* m_hexcursor{nullptr}; + QHexDocument* m_hexdocument{nullptr}; + QHexMetadata* m_hexmetadata{nullptr}; + QHexDelegate* m_hexdelegate{nullptr}; +#if defined(QHEXVIEW_ENABLE_DIALOGS) + HexFindDialog *m_hexdlgfind{nullptr}, *m_hexdlgreplace{nullptr}; +#endif + + friend class QHexDelegate; + friend class QHexCursor; +}; diff --git a/UEFITool/QHexView/src/dialogs/hexfinddialog.cpp b/UEFITool/QHexView/src/dialogs/hexfinddialog.cpp new file mode 100644 index 0000000..ce42092 --- /dev/null +++ b/UEFITool/QHexView/src/dialogs/hexfinddialog.cpp @@ -0,0 +1,418 @@ +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +const QString HexFindDialog::BUTTONBOX = "qhexview_buttonbox"; +const QString HexFindDialog::CBFINDMODE = "qhexview_cbfindmode"; +const QString HexFindDialog::LEFIND = "qhexview_lefind"; +const QString HexFindDialog::LEREPLACE = "qhexview_lereplace"; +const QString HexFindDialog::HLAYOUT = "qhexview_hlayout"; +const QString HexFindDialog::GBOPTIONS = "qhexview_gboptions"; +const QString HexFindDialog::RBALL = "qhexview_rball"; +const QString HexFindDialog::RBFORWARD = "qhexview_rbforward"; +const QString HexFindDialog::RBBACKWARD = "qhexview_rbbackward"; + +HexFindDialog::HexFindDialog(Type type, QHexView* parent) + : QDialog{parent}, m_type{type} { + m_hexvalidator = new QRegularExpressionValidator( + QRegularExpression{"[0-9A-Fa-f ]+"}, this); + m_hexpvalidator = new QRegularExpressionValidator( + QRegularExpression{"[0-9A-Fa-f \\?]+"}, this); + m_dblvalidator = new QDoubleValidator(this); + m_intvalidator = new QIntValidator(this); + + this->setWindowTitle(type == Type::Replace ? tr("Replace...") + : tr("Find...")); + + auto* vlayout = new QVBoxLayout(this); + auto* gridlayout = new QGridLayout(); + + auto* cbfindmode = new QComboBox(this); + cbfindmode->setObjectName(HexFindDialog::CBFINDMODE); + cbfindmode->addItem("Text", static_cast(QHexFindMode::Text)); + cbfindmode->addItem("Hex", static_cast(QHexFindMode::Hex)); + cbfindmode->addItem("Int", static_cast(QHexFindMode::Int)); + cbfindmode->addItem("Float", static_cast(QHexFindMode::Float)); + + QLineEdit *lereplace = nullptr, *lefind = new QLineEdit(this); + lefind->setObjectName(HexFindDialog::LEFIND); + + gridlayout->addWidget(new QLabel(tr("Mode:"), this), 0, 0, Qt::AlignRight); + gridlayout->addWidget(cbfindmode, 0, 1); + gridlayout->addWidget(new QLabel(tr("Find:"), this), 1, 0, Qt::AlignRight); + gridlayout->addWidget(lefind, 1, 1); + + if(type == Type::Replace) { + lereplace = new QLineEdit(this); + lereplace->setObjectName(HexFindDialog::LEREPLACE); + + gridlayout->addWidget(new QLabel(tr("Replace:"), this), 2, 0, + Qt::AlignRight); + gridlayout->addWidget(lereplace, 2, 1); + } + + vlayout->addLayout(gridlayout); + + auto* gboptions = new QGroupBox(this); + gboptions->setObjectName(HexFindDialog::GBOPTIONS); + gboptions->setTitle(tr("Options")); + gboptions->setLayout(new QStackedLayout()); + + QGroupBox* gbdirection = new QGroupBox(this); + gbdirection->setTitle(tr("Find direction")); + auto* gbvlayout = new QVBoxLayout(gbdirection); + + auto* rball = new QRadioButton("All", gbdirection); + rball->setObjectName(HexFindDialog::RBALL); + auto* rbforward = new QRadioButton("Forward", gbdirection); + rbforward->setObjectName(HexFindDialog::RBFORWARD); + rbforward->setChecked(true); + auto* rbbackward = new QRadioButton("Backward", gbdirection); + rbbackward->setObjectName(HexFindDialog::RBBACKWARD); + + gbvlayout->addWidget(rball); + gbvlayout->addWidget(rbforward); + gbvlayout->addWidget(rbbackward); + gbvlayout->addSpacerItem( + new QSpacerItem(0, 0, QSizePolicy::Minimum, QSizePolicy::Expanding)); + + auto* hlayout = new QHBoxLayout(); + hlayout->setObjectName(HexFindDialog::HLAYOUT); + hlayout->addWidget(gboptions, 1); + hlayout->addWidget(gbdirection); + vlayout->addLayout(hlayout, 1); + + auto* buttonbox = new QDialogButtonBox(this); + buttonbox->setOrientation(Qt::Horizontal); + + if(type == Type::Replace) + buttonbox->setStandardButtons(QDialogButtonBox::Ok | + QDialogButtonBox::Apply | + QDialogButtonBox::Cancel); + else + buttonbox->setStandardButtons(QDialogButtonBox::Ok | + QDialogButtonBox::Cancel); + + buttonbox->setObjectName(HexFindDialog::BUTTONBOX); + buttonbox->button(QDialogButtonBox::Ok)->setEnabled(false); + buttonbox->button(QDialogButtonBox::Ok)->setText(tr("Find")); + + if(type == Type::Replace) { + buttonbox->button(QDialogButtonBox::Apply)->setEnabled(false); + buttonbox->button(QDialogButtonBox::Apply)->setText(tr("Replace")); + } + + vlayout->addWidget(buttonbox); + + connect(lefind, &QLineEdit::textChanged, this, + &HexFindDialog::validateActions); + connect(cbfindmode, QOverload::of(&QComboBox::currentIndexChanged), + this, &HexFindDialog::updateFindOptions); + connect(buttonbox, &QDialogButtonBox::accepted, this, &HexFindDialog::find); + connect(buttonbox, &QDialogButtonBox::rejected, this, &QDialog::reject); + connect(parent, &QHexView::positionChanged, this, + [this]() { m_startoffset = -1; }); + + if(lereplace) { + connect(buttonbox->button(QDialogButtonBox::Apply), + &QPushButton::clicked, this, &HexFindDialog::replace); + connect(lereplace, &QLineEdit::textChanged, this, + &HexFindDialog::validateActions); + } + + this->prepareTextMode(gboptions->layout()); + this->prepareHexMode(gboptions->layout()); + this->prepareIntMode(gboptions->layout()); + this->prepareFloatMode(gboptions->layout()); + this->updateFindOptions(-1); +} + +QHexView* HexFindDialog::hexView() const { + return qobject_cast(this->parentWidget()); +} + +void HexFindDialog::updateFindOptions(int) { + QGroupBox* gboptions = + this->findChild(HexFindDialog::GBOPTIONS); + + QLineEdit* lefind = this->findChild(HexFindDialog::LEFIND); + QLineEdit* lereplace = + this->findChild(HexFindDialog::LEREPLACE); + lefind->clear(); + if(lereplace) + lereplace->clear(); + + bool ok = false; + QHexFindMode mode = static_cast( + this->findChild(HexFindDialog::CBFINDMODE) + ->currentData() + .toInt(&ok)); + if(!ok) + return; + + m_findoptions = QHexFindOptions::None; + m_oldidxbits = m_oldidxendian = -1; + + auto* stack = qobject_cast(gboptions->layout()); + + switch(mode) { + case QHexFindMode::Text: { + lefind->setValidator(nullptr); + if(lereplace) + lereplace->setValidator(nullptr); + + stack->setCurrentIndex(0); + gboptions->setVisible(true); + break; + } + + case QHexFindMode::Hex: { + lefind->setValidator(m_hexpvalidator); + if(lereplace) + lereplace->setValidator(m_hexvalidator); + stack->setCurrentIndex(1); + gboptions->setVisible(false); + break; + } + + case QHexFindMode::Int: { + lefind->setValidator(m_intvalidator); + if(lereplace) + lereplace->setValidator(m_intvalidator); + + stack->setCurrentIndex(2); + gboptions->setVisible(true); + break; + } + + case QHexFindMode::Float: { + lefind->setValidator(m_dblvalidator); + if(lereplace) + lereplace->setValidator(m_dblvalidator); + + stack->setCurrentIndex(3); + gboptions->setVisible(true); + break; + } + } +} + +bool HexFindDialog::validateIntRange(uint v) const { + if(m_findoptions & QHexFindOptions::Int8) + return !(v > std::numeric_limits::max()); + if(m_findoptions & QHexFindOptions::Int16) + return !(v > std::numeric_limits::max()); + if(m_findoptions & QHexFindOptions::Int32) + return !(v > std::numeric_limits::max()); + return true; +} + +void HexFindDialog::checkResult(const QString& q, qint64 offset, + QHexFindDirection fd) { + if(offset == -1) { + QMessageBox::information(this, tr("Not found"), + tr("Cannot find '%1'").arg(q)); + return; + } + + if(fd == QHexFindDirection::Backward) + m_startoffset = this->hexView()->selectionStartOffset() - 1; + else + m_startoffset = this->hexView()->selectionEndOffset() + 1; +} + +void HexFindDialog::validateActions() { + auto mode = static_cast( + this->findChild(HexFindDialog::CBFINDMODE) + ->currentData() + .toUInt()); + auto* lefind = this->findChild(HexFindDialog::LEFIND); + auto* lereplace = this->findChild(HexFindDialog::LEREPLACE); + auto* buttonbox = + this->findChild(HexFindDialog::BUTTONBOX); + + bool findenable = false, replaceenable = false; + + switch(mode) { + case QHexFindMode::Hex: + findenable = QHexUtils::checkPattern(lefind->text()); + replaceenable = findenable; + break; + + case QHexFindMode::Float: { + lefind->text().toFloat(&findenable); + if(lereplace && findenable) + lereplace->text().toFloat(&replaceenable); + break; + } + + case QHexFindMode::Int: { + auto v = lefind->text().toUInt(&findenable); + if(findenable && !this->validateIntRange(v)) + findenable = false; + if(lereplace && findenable) + lereplace->text().toUInt(&replaceenable); + break; + } + + default: + findenable = !lefind->text().isEmpty(); + replaceenable = findenable; + break; + } + + if(lereplace) + buttonbox->button(QDialogButtonBox::Apply)->setEnabled(replaceenable); + buttonbox->button(QDialogButtonBox::Ok)->setEnabled(findenable); +} + +void HexFindDialog::replace() { + QString q1; + QHexFindMode mode; + QHexFindDirection fd; + + if(!this->prepareOptions(q1, mode, fd)) + return; + + QString q2 = this->findChild(HexFindDialog::LEREPLACE)->text(); + auto offset = this->hexView()->hexCursor()->replace( + q1, q2, m_startoffset > -1 ? m_startoffset : this->hexView()->offset(), + mode, m_findoptions, fd); + this->checkResult(q1, offset, fd); +} + +void HexFindDialog::find() { + QString q; + QHexFindMode mode; + QHexFindDirection fd; + + if(!this->prepareOptions(q, mode, fd)) + return; + + auto offset = this->hexView()->hexCursor()->find( + q, m_startoffset > -1 ? m_startoffset : this->hexView()->offset(), mode, + m_findoptions, fd); + this->checkResult(q, offset, fd); +} + +bool HexFindDialog::prepareOptions(QString& q, QHexFindMode& mode, + QHexFindDirection& fd) { + q = this->findChild(HexFindDialog::LEFIND)->text(); + mode = static_cast( + this->findChild(HexFindDialog::CBFINDMODE) + ->currentData() + .toUInt()); + + if(mode == QHexFindMode::Hex && !QHexUtils::checkPattern(q)) { + QMessageBox::warning(this, tr("Pattern Error"), + tr("Hex pattern '%1' is not valid").arg(q)); + return false; + } + + if(this->findChild(HexFindDialog::RBBACKWARD)->isChecked()) + fd = QHexFindDirection::Backward; + else if(this->findChild(HexFindDialog::RBFORWARD) + ->isChecked()) + fd = QHexFindDirection::Forward; + else + fd = QHexFindDirection::All; + return true; +} + +void HexFindDialog::prepareTextMode(QLayout* l) { + auto* cbcasesensitive = new QCheckBox("Case sensitive"); + + connect(cbcasesensitive, &QCheckBox::stateChanged, this, [this](int state) { + if(state == Qt::Checked) + m_findoptions |= QHexFindOptions::CaseSensitive; + else + m_findoptions &= ~QHexFindOptions::CaseSensitive; + }); + + auto* vlayout = new QVBoxLayout(new QWidget()); + vlayout->addWidget(cbcasesensitive); + l->addWidget(vlayout->parentWidget()); +} + +void HexFindDialog::prepareHexMode(QLayout* l) { l->addWidget(new QWidget()); } + +void HexFindDialog::prepareIntMode(QLayout* l) { + static const QList> INT_TYPES = { + qMakePair("(any)", 0), + qMakePair("8", QHexFindOptions::Int8), + qMakePair("16", QHexFindOptions::Int16), + qMakePair("32", QHexFindOptions::Int32), + qMakePair("64", QHexFindOptions::Int64)}; + + auto* cbbits = new QComboBox(); + for(const auto& it : INT_TYPES) + cbbits->addItem(it.first, it.second); + + connect(cbbits, QOverload::of(&QComboBox::currentIndexChanged), this, + [this, cbbits](int index) { + if(m_oldidxbits > -1) + m_findoptions &= ~cbbits->itemData(m_oldidxbits).toUInt(); + m_findoptions |= cbbits->itemData(index).toUInt(); + m_oldidxbits = index; + }); + + auto* cbendian = new QComboBox(); + cbendian->addItem("Little Endian", 0); + cbendian->addItem("Big Endian", QHexFindOptions::BigEndian); + + connect(cbendian, QOverload::of(&QComboBox::currentIndexChanged), this, + [this, cbendian](int index) { + if(m_oldidxendian > -1) + m_findoptions &= + ~cbendian->itemData(m_oldidxendian).toUInt(); + m_findoptions |= cbendian->itemData(index).toUInt(); + m_oldidxendian = index; + }); + + auto* vlayout = new QVBoxLayout(new QWidget()); + + QGridLayout* gl = new QGridLayout(); + gl->addWidget(new QLabel("Type:"), 0, 0, Qt::AlignRight); + gl->addWidget(cbbits, 0, 1); + gl->addWidget(new QLabel("Endian:"), 1, 0, Qt::AlignRight); + gl->addWidget(cbendian, 1, 1); + vlayout->addLayout(gl); + + l->addWidget(vlayout->parentWidget()); +} + +void HexFindDialog::prepareFloatMode(QLayout* l) { + static const QList> FLOAT_TYPES = { + qMakePair("float", QHexFindOptions::Float), + qMakePair("double", QHexFindOptions::Double)}; + + bool first = true; + auto* vlayout = new QVBoxLayout(new QWidget()); + + for(const auto& ft : FLOAT_TYPES) { + auto* rb = new QRadioButton(ft.first); + rb->setChecked(first); + vlayout->addWidget(rb); + first = false; + } + + l->addWidget(vlayout->parentWidget()); +} diff --git a/UEFITool/qhexview5/model/buffer/qdevicebuffer.cpp b/UEFITool/QHexView/src/model/buffer/qdevicebuffer.cpp similarity index 61% rename from UEFITool/qhexview5/model/buffer/qdevicebuffer.cpp rename to UEFITool/QHexView/src/model/buffer/qdevicebuffer.cpp index 1ba59d0..24413e4 100644 --- a/UEFITool/qhexview5/model/buffer/qdevicebuffer.cpp +++ b/UEFITool/QHexView/src/model/buffer/qdevicebuffer.cpp @@ -1,24 +1,23 @@ -#include "qdevicebuffer.h" +#include #include #include -QDeviceBuffer::QDeviceBuffer(QObject *parent) : QHexBuffer{parent} { } +QDeviceBuffer::QDeviceBuffer(QObject* parent): QHexBuffer{parent} {} -QDeviceBuffer::~QDeviceBuffer() -{ - if(!m_device) return; +QDeviceBuffer::~QDeviceBuffer() { + if(!m_device) + return; - if(m_device->parent() == this) - { - if(m_device->isOpen()) m_device->close(); + if(m_device->parent() == this) { + if(m_device->isOpen()) + m_device->close(); m_device->deleteLater(); } m_device = nullptr; } -uchar QDeviceBuffer::at(qint64 idx) -{ +uchar QDeviceBuffer::at(qint64 idx) { m_device->seek(idx); char c = '\0'; @@ -28,68 +27,61 @@ uchar QDeviceBuffer::at(qint64 idx) qint64 QDeviceBuffer::length() const { return m_device->size(); } -void QDeviceBuffer::insert(qint64 offset, const QByteArray &data) -{ +void QDeviceBuffer::insert(qint64 offset, const QByteArray& data) { Q_UNUSED(offset) Q_UNUSED(data) // Not implemented } -void QDeviceBuffer::replace(qint64 offset, const QByteArray& data) -{ +void QDeviceBuffer::replace(qint64 offset, const QByteArray& data) { m_device->seek(offset); m_device->write(data); } -void QDeviceBuffer::remove(qint64 offset, int length) -{ +void QDeviceBuffer::remove(qint64 offset, int length) { Q_UNUSED(offset) Q_UNUSED(length) // Not implemented } -QByteArray QDeviceBuffer::read(qint64 offset, int length) -{ +QByteArray QDeviceBuffer::read(qint64 offset, int length) { m_device->seek(offset); return m_device->read(length); } -bool QDeviceBuffer::read(QIODevice *device) -{ +bool QDeviceBuffer::read(QIODevice* device) { m_device = device; - if(!m_device) return false; - if(!m_device->isOpen()) m_device->open(QIODevice::ReadWrite); + if(!m_device) + return false; + if(!m_device->isOpen()) + m_device->open(QIODevice::ReadWrite); return m_device->isOpen(); } -void QDeviceBuffer::write(QIODevice *device) -{ +void QDeviceBuffer::write(QIODevice* device) { Q_UNUSED(device) // Not implemented } -qint64 QDeviceBuffer::indexOf(const QByteArray& ba, qint64 from) -{ +qint64 QDeviceBuffer::indexOf(const QByteArray& ba, qint64 from) { const auto MAX = std::numeric_limits::max(); qint64 idx = -1; - if(from < m_device->size()) - { + if(from < m_device->size()) { idx = from; m_device->seek(from); - while(idx < m_device->size()) - { + while(idx < m_device->size()) { QByteArray data = m_device->read(MAX); int sidx = data.indexOf(ba); - if(sidx >= 0) - { + if(sidx >= 0) { idx += sidx; break; } - if(idx + data.size() >= m_device->size()) return -1; + if(idx + data.size() >= m_device->size()) + return -1; m_device->seek(m_device->pos() + data.size() - ba.size()); } } @@ -97,33 +89,29 @@ qint64 QDeviceBuffer::indexOf(const QByteArray& ba, qint64 from) return idx; } -qint64 QDeviceBuffer::lastIndexOf(const QByteArray& ba, qint64 from) -{ +qint64 QDeviceBuffer::lastIndexOf(const QByteArray& ba, qint64 from) { const auto MAX = std::numeric_limits::max(); qint64 idx = -1; - if(from >= 0 && ba.size() < MAX) - { + if(from >= 0 && ba.size() < MAX) { qint64 currpos = from; - while(currpos >= 0) - { + while(currpos >= 0) { qint64 readpos = (currpos < MAX) ? 0 : currpos - MAX; m_device->seek(readpos); QByteArray data = m_device->read(currpos - readpos); int lidx = data.lastIndexOf(ba, from); - if(lidx >= 0) - { + if(lidx >= 0) { idx = readpos + lidx; break; } - if(readpos <= 0) break; + if(readpos <= 0) + break; currpos = readpos + ba.size(); } - } return idx; diff --git a/UEFITool/qhexview5/model/buffer/qhexbuffer.cpp b/UEFITool/QHexView/src/model/buffer/qhexbuffer.cpp similarity index 62% rename from UEFITool/qhexview5/model/buffer/qhexbuffer.cpp rename to UEFITool/QHexView/src/model/buffer/qhexbuffer.cpp index b50081d..1d07b8a 100644 --- a/UEFITool/qhexview5/model/buffer/qhexbuffer.cpp +++ b/UEFITool/QHexView/src/model/buffer/qhexbuffer.cpp @@ -1,18 +1,21 @@ -#include "qhexbuffer.h" #include +#include -QHexBuffer::QHexBuffer(QObject *parent) : QObject{parent} { } +QHexBuffer::QHexBuffer(QObject* parent): QObject{parent} {} uchar QHexBuffer::at(qint64 idx) { return this->read(idx, 1).at(0); } bool QHexBuffer::isEmpty() const { return this->length() <= 0; } -void QHexBuffer::replace(qint64 offset, const QByteArray &data) -{ +void QHexBuffer::replace(qint64 offset, const QByteArray& data) { this->remove(offset, data.length()); this->insert(offset, data); } -void QHexBuffer::read(char *data, int size) -{ +bool QHexBuffer::accept(qint64 idx) const { + Q_UNUSED(idx); + return true; +} + +void QHexBuffer::read(char* data, int size) { QBuffer* buffer = new QBuffer(this); buffer->setData(data, size); @@ -22,8 +25,7 @@ void QHexBuffer::read(char *data, int size) this->read(buffer); } -void QHexBuffer::read(const QByteArray &ba) -{ +void QHexBuffer::read(const QByteArray& ba) { QBuffer* buffer = new QBuffer(this); buffer->setData(ba); @@ -32,4 +34,3 @@ void QHexBuffer::read(const QByteArray &ba) this->read(buffer); } - diff --git a/UEFITool/QHexView/src/model/buffer/qmappedfilebuffer.cpp b/UEFITool/QHexView/src/model/buffer/qmappedfilebuffer.cpp new file mode 100644 index 0000000..a870d0a --- /dev/null +++ b/UEFITool/QHexView/src/model/buffer/qmappedfilebuffer.cpp @@ -0,0 +1,51 @@ +#include +#include + +QMappedFileBuffer::QMappedFileBuffer(QObject* parent): QDeviceBuffer{parent} {} + +QMappedFileBuffer::~QMappedFileBuffer() { + if((m_device && (m_device->parent() == this)) && m_mappeddata) { + QFile* f = qobject_cast(m_device); + f->unmap(m_mappeddata); + } + + m_mappeddata = nullptr; +} + +QByteArray QMappedFileBuffer::read(qint64 offset, int length) { + if(offset >= this->length()) + return {}; + + if(offset + length >= this->length()) + length = this->length() - offset; + + return QByteArray::fromRawData( + reinterpret_cast(m_mappeddata + offset), length); +} + +bool QMappedFileBuffer::read(QIODevice* iodevice) { + m_device = qobject_cast(iodevice); + if(!m_device || !QDeviceBuffer::read(iodevice)) + return false; + + this->remap(); + return m_mappeddata; +} + +void QMappedFileBuffer::write(QIODevice* iodevice) { + if(iodevice == m_device) + this->remap(); + else + iodevice->write(reinterpret_cast(m_mappeddata), + m_device->size()); +} + +void QMappedFileBuffer::remap() { + QFile* f = qobject_cast(m_device); + if(!f) + return; + + if(m_mappeddata) + f->unmap(m_mappeddata); + m_mappeddata = f->map(0, f->size()); +} diff --git a/UEFITool/QHexView/src/model/buffer/qmemorybuffer.cpp b/UEFITool/QHexView/src/model/buffer/qmemorybuffer.cpp new file mode 100644 index 0000000..220cebf --- /dev/null +++ b/UEFITool/QHexView/src/model/buffer/qmemorybuffer.cpp @@ -0,0 +1,39 @@ +#include +#include + +QMemoryBuffer::QMemoryBuffer(QObject* parent): QHexBuffer{parent} {} + +uchar QMemoryBuffer::at(qint64 idx) { + return static_cast(m_buffer.at(idx)); +} + +qint64 QMemoryBuffer::length() const { + return static_cast(m_buffer.length()); +} + +void QMemoryBuffer::insert(qint64 offset, const QByteArray& data) { + m_buffer.insert(static_cast(offset), data); +} + +void QMemoryBuffer::remove(qint64 offset, int length) { + m_buffer.remove(static_cast(offset), length); +} + +QByteArray QMemoryBuffer::read(qint64 offset, int length) { + return m_buffer.mid(static_cast(offset), length); +} + +bool QMemoryBuffer::read(QIODevice* device) { + m_buffer = device->readAll(); + return true; +} + +void QMemoryBuffer::write(QIODevice* device) { device->write(m_buffer); } + +qint64 QMemoryBuffer::indexOf(const QByteArray& ba, qint64 from) { + return m_buffer.indexOf(ba, static_cast(from)); +} + +qint64 QMemoryBuffer::lastIndexOf(const QByteArray& ba, qint64 from) { + return m_buffer.lastIndexOf(ba, static_cast(from)); +} diff --git a/UEFITool/QHexView/src/model/buffer/qmemoryrefbuffer.cpp b/UEFITool/QHexView/src/model/buffer/qmemoryrefbuffer.cpp new file mode 100644 index 0000000..2598b85 --- /dev/null +++ b/UEFITool/QHexView/src/model/buffer/qmemoryrefbuffer.cpp @@ -0,0 +1,26 @@ +#include +#include + +QMemoryRefBuffer::QMemoryRefBuffer(QObject* parent): QDeviceBuffer{parent} {} + +bool QMemoryRefBuffer::read(QIODevice* device) { + m_device = qobject_cast(device); + + if(m_device) { + m_device->setParent(this); + return QDeviceBuffer::read(device); + } + + return false; +} + +void QMemoryRefBuffer::write(QIODevice* device) { + if(!m_device || m_device == device) + return; + + static const int CHUNK_SIZE = 4096; + m_device->seek(0); + + while(!m_device->atEnd()) + device->write(m_device->read(CHUNK_SIZE)); +} diff --git a/UEFITool/QHexView/src/model/commands/hexcommand.cpp b/UEFITool/QHexView/src/model/commands/hexcommand.cpp new file mode 100644 index 0000000..ce27843 --- /dev/null +++ b/UEFITool/QHexView/src/model/commands/hexcommand.cpp @@ -0,0 +1,6 @@ +#include + +HexCommand::HexCommand(QHexBuffer* buffer, QHexDocument* document, + QUndoCommand* parent) + : QUndoCommand(parent), m_hexdocument(document), m_buffer(buffer), + m_offset(0), m_length(0) {} diff --git a/UEFITool/QHexView/src/model/commands/insertcommand.cpp b/UEFITool/QHexView/src/model/commands/insertcommand.cpp new file mode 100644 index 0000000..eaec5bc --- /dev/null +++ b/UEFITool/QHexView/src/model/commands/insertcommand.cpp @@ -0,0 +1,18 @@ +#include +#include + +InsertCommand::InsertCommand(QHexBuffer* buffer, QHexDocument* document, + qint64 offset, const QByteArray& data, + QUndoCommand* parent) + : HexCommand(buffer, document, parent) { + m_offset = offset; + m_data = data; +} + +void InsertCommand::undo() { + m_buffer->remove(m_offset, m_data.length()); + Q_EMIT m_hexdocument->dataChanged(m_data, m_offset, + QHexDocument::ChangeReason::Remove); +} + +void InsertCommand::redo() { m_buffer->insert(m_offset, m_data); } diff --git a/UEFITool/QHexView/src/model/commands/removecommand.cpp b/UEFITool/QHexView/src/model/commands/removecommand.cpp new file mode 100644 index 0000000..a71b37e --- /dev/null +++ b/UEFITool/QHexView/src/model/commands/removecommand.cpp @@ -0,0 +1,20 @@ +#include +#include + +RemoveCommand::RemoveCommand(QHexBuffer* buffer, QHexDocument* document, + qint64 offset, int length, QUndoCommand* parent) + : HexCommand(buffer, document, parent) { + m_offset = offset; + m_length = length; +} + +void RemoveCommand::undo() { + m_buffer->insert(m_offset, m_data); + Q_EMIT m_hexdocument->dataChanged(m_data, m_offset, + QHexDocument::ChangeReason::Insert); +} + +void RemoveCommand::redo() { + m_data = m_buffer->read(m_offset, m_length); // Backup data + m_buffer->remove(m_offset, m_length); +} diff --git a/UEFITool/QHexView/src/model/commands/replacecommand.cpp b/UEFITool/QHexView/src/model/commands/replacecommand.cpp new file mode 100644 index 0000000..6a193ea --- /dev/null +++ b/UEFITool/QHexView/src/model/commands/replacecommand.cpp @@ -0,0 +1,21 @@ +#include +#include + +ReplaceCommand::ReplaceCommand(QHexBuffer* buffer, QHexDocument* document, + qint64 offset, const QByteArray& data, + QUndoCommand* parent) + : HexCommand(buffer, document, parent) { + m_offset = offset; + m_data = data; +} + +void ReplaceCommand::undo() { + m_buffer->replace(m_offset, m_olddata); + Q_EMIT m_hexdocument->dataChanged(m_olddata, m_offset, + QHexDocument::ChangeReason::Replace); +} + +void ReplaceCommand::redo() { + m_olddata = m_buffer->read(m_offset, m_data.length()); + m_buffer->replace(m_offset, m_data); +} diff --git a/UEFITool/QHexView/src/model/qhexcursor.cpp b/UEFITool/QHexView/src/model/qhexcursor.cpp new file mode 100644 index 0000000..1b702cc --- /dev/null +++ b/UEFITool/QHexView/src/model/qhexcursor.cpp @@ -0,0 +1,182 @@ +#include +#include +#include + +/* + * https://stackoverflow.com/questions/10803043/inverse-column-row-major-order-transformation + * + * If the index is calculated as: + * offset = row + column*NUMROWS + * then the inverse would be: + * row = offset % NUMROWS + * column = offset / NUMROWS + * where % is modulus, and / is integer division. + */ + +QHexCursor::QHexCursor(const QHexOptions* options, QHexView* parent) + : QObject(parent), m_options(options) {} + +QHexView* QHexCursor::hexView() const { + return qobject_cast(this->parent()); +} + +QHexCursor::Mode QHexCursor::mode() const { return m_mode; } +qint64 QHexCursor::offset() const { return this->positionToOffset(m_position); } + +qint64 QHexCursor::address() const { + return m_options->baseaddress + this->offset(); +} + +quint64 QHexCursor::lineAddress() const { + return m_options->baseaddress + (m_position.line * m_options->linelength); +} + +qint64 QHexCursor::selectionStartOffset() const { + return this->positionToOffset(this->selectionStart()); +} + +qint64 QHexCursor::selectionEndOffset() const { + return this->positionToOffset(this->selectionEnd()); +} + +qint64 QHexCursor::line() const { return m_position.line; } +qint64 QHexCursor::column() const { return m_position.column; } + +QHexPosition QHexCursor::selectionStart() const { + if(m_position.line < m_selection.line) + return m_position; + + if(m_position.line == m_selection.line) { + if(m_position.column < m_selection.column) + return m_position; + } + + return m_selection; +} + +QHexPosition QHexCursor::selectionEnd() const { + if(m_position.line > m_selection.line) + return m_position; + + if(m_position.line == m_selection.line) { + if(m_position.column > m_selection.column) + return m_position; + } + + return m_selection; +} + +qint64 QHexCursor::selectionLength() const { + auto selstart = this->selectionStartOffset(), + selend = this->selectionEndOffset(); + return selstart == selend ? 0 : selend - selstart + 1; +} + +QHexPosition QHexCursor::position() const { return m_position; } + +QByteArray QHexCursor::selectedBytes() const { + return this->hexView()->selectedBytes(); +} + +bool QHexCursor::hasSelection() const { return m_position != m_selection; } + +bool QHexCursor::isSelected(qint64 line, qint64 column) const { + if(!this->hasSelection()) + return false; + + auto selstart = this->selectionStart(), selend = this->selectionEnd(); + if(line > selstart.line && line < selend.line) + return true; + if(line == selstart.line && line == selend.line) + return column >= selstart.column && column <= selend.column; + if(line == selstart.line) + return column >= selstart.column; + if(line == selend.line) + return column <= selend.column; + return false; +} + +void QHexCursor::setMode(Mode m) { + if(m_mode == m) + return; + m_mode = m; + Q_EMIT modeChanged(); +} + +void QHexCursor::switchMode() { + switch(m_mode) { + case Mode::Insert: this->setMode(Mode::Overwrite); break; + case Mode::Overwrite: this->setMode(Mode::Insert); break; + } +} + +void QHexCursor::move(qint64 offset) { + this->move(this->offsetToPosition(offset)); +} + +void QHexCursor::move(qint64 line, qint64 column) { + return this->move({line, column}); +} + +void QHexCursor::move(QHexPosition pos) { + if(pos.line >= 0) + m_selection.line = pos.line; + if(pos.column >= 0) + m_selection.column = pos.column; + this->select(pos); +} + +void QHexCursor::select(qint64 offset) { + this->select(this->offsetToPosition(offset)); +} + +void QHexCursor::select(qint64 line, qint64 column) { + this->select({line, column}); +} + +void QHexCursor::select(QHexPosition pos) { + if(pos.line >= 0) + m_position.line = pos.line; + if(pos.column >= 0) + m_position.column = pos.column; + Q_EMIT positionChanged(); +} + +void QHexCursor::selectSize(qint64 length) { + if(length > 0) + length--; + else if(length < 0) + length++; + if(length) + this->select(this->offset() + length); +} + +qint64 QHexCursor::replace(const QVariant& oldvalue, const QVariant& newvalue, + qint64 offset, QHexFindMode mode, + unsigned int options, QHexFindDirection fd) const { + return this->hexView()->replace(oldvalue, newvalue, offset, mode, options, + fd); +} +qint64 QHexCursor::find(const QVariant& value, qint64 offset, QHexFindMode mode, + unsigned int options, QHexFindDirection fd) const { + return this->hexView()->find(value, offset, mode, options, fd); +} + +void QHexCursor::cut(bool hex) { this->hexView()->cut(hex); } +void QHexCursor::copy(bool hex) const { this->hexView()->copy(hex); } +void QHexCursor::paste(bool hex) { this->hexView()->paste(hex); } +void QHexCursor::selectAll() { this->hexView()->selectAll(); } +void QHexCursor::removeSelection() { this->hexView()->removeSelection(); } + +void QHexCursor::clearSelection() { + m_position = m_selection; + Q_EMIT positionChanged(); +} + +qint64 QHexCursor::positionToOffset(QHexPosition pos) const { + return QHexUtils::positionToOffset(m_options, pos); +} + +QHexPosition QHexCursor::offsetToPosition(qint64 offset) const { + return QHexUtils::offsetToPosition(m_options, offset); +} diff --git a/UEFITool/qhexview5/model/qhexdelegate.cpp b/UEFITool/QHexView/src/model/qhexdelegate.cpp similarity index 60% rename from UEFITool/qhexview5/model/qhexdelegate.cpp rename to UEFITool/QHexView/src/model/qhexdelegate.cpp index 62114e8..fe2a1d0 100644 --- a/UEFITool/qhexview5/model/qhexdelegate.cpp +++ b/UEFITool/QHexView/src/model/qhexdelegate.cpp @@ -1,50 +1,48 @@ -#include "../qhexview.h" -#include "qhexdelegate.h" +#include +#include -QHexDelegate::QHexDelegate(QObject* parent): QObject{parent} { } +QHexDelegate::QHexDelegate(QObject* parent): QObject{parent} {} -QString QHexDelegate::addressHeader(const QHexView* hexview) const -{ +QString QHexDelegate::addressHeader(const QHexView* hexview) const { Q_UNUSED(hexview); return QString(); } -QString QHexDelegate::hexHeader(const QHexView* hexview) const -{ +QString QHexDelegate::hexHeader(const QHexView* hexview) const { Q_UNUSED(hexview); return QString(); } -QString QHexDelegate::asciiHeader(const QHexView* hexview) const -{ +QString QHexDelegate::asciiHeader(const QHexView* hexview) const { Q_UNUSED(hexview); return QString(); } -void QHexDelegate::renderAddress(quint64 address, QTextCharFormat& cf, const QHexView* hexview) const -{ +void QHexDelegate::renderAddress(quint64 address, QTextCharFormat& cf, + const QHexView* hexview) const { Q_UNUSED(address); Q_UNUSED(hexview); Q_UNUSED(cf); Q_UNUSED(hexview); } -void QHexDelegate::renderHeader(QTextBlockFormat& bf, const QHexView* hexview) const -{ +void QHexDelegate::renderHeader(QTextBlockFormat& bf, + const QHexView* hexview) const { Q_UNUSED(bf); Q_UNUSED(hexview); } -void QHexDelegate::renderHeaderPart(const QString& s, QHexArea area, QTextCharFormat& cf, const QHexView* hexview) const -{ +void QHexDelegate::renderHeaderPart(const QString& s, QHexArea area, + QTextCharFormat& cf, + const QHexView* hexview) const { Q_UNUSED(s); Q_UNUSED(area); Q_UNUSED(cf); Q_UNUSED(hexview); } -bool QHexDelegate::render(quint64 offset, quint8 b, QTextCharFormat& outcf, const QHexView* hexview) const -{ +bool QHexDelegate::render(quint64 offset, quint8 b, QTextCharFormat& outcf, + const QHexView* hexview) const { Q_UNUSED(offset); Q_UNUSED(b); Q_UNUSED(outcf); @@ -53,16 +51,15 @@ bool QHexDelegate::render(quint64 offset, quint8 b, QTextCharFormat& outcf, cons return false; } -bool QHexDelegate::paintSeparator(QPainter* painter, QLineF line, const QHexView* hexview) const -{ +bool QHexDelegate::paintSeparator(QPainter* painter, QLineF line, + const QHexView* hexview) const { Q_UNUSED(painter); Q_UNUSED(line); Q_UNUSED(hexview); return false; } -void QHexDelegate::paint(QPainter* painter, const QHexView* hexview) const -{ +void QHexDelegate::paint(QPainter* painter, const QHexView* hexview) const { Q_UNUSED(hexview); hexview->paint(painter); } diff --git a/UEFITool/QHexView/src/model/qhexdocument.cpp b/UEFITool/QHexView/src/model/qhexdocument.cpp new file mode 100644 index 0000000..0933b6b --- /dev/null +++ b/UEFITool/QHexView/src/model/qhexdocument.cpp @@ -0,0 +1,142 @@ +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +QHexDocument::QHexDocument(QHexBuffer* buffer, QObject* parent) + : QObject(parent) { + m_buffer = buffer; + m_buffer->setParent(this); // Take Ownership + + connect(&m_undostack, &QUndoStack::canUndoChanged, this, + &QHexDocument::canUndoChanged); + connect(&m_undostack, &QUndoStack::canRedoChanged, this, + &QHexDocument::canRedoChanged); + connect(&m_undostack, &QUndoStack::cleanChanged, this, + [&](bool clean) { Q_EMIT modifiedChanged(!clean); }); +} + +qint64 QHexDocument::indexOf(const QByteArray& ba, qint64 from) { + return m_buffer->indexOf(ba, from); +} + +qint64 QHexDocument::lastIndexOf(const QByteArray& ba, qint64 from) { + return m_buffer->lastIndexOf(ba, from); +} + +bool QHexDocument::accept(qint64 idx) const { return m_buffer->accept(idx); } +bool QHexDocument::isEmpty() const { return m_buffer->isEmpty(); } +bool QHexDocument::isModified() const { return !m_undostack.isClean(); } +bool QHexDocument::canUndo() const { return m_undostack.canUndo(); } +bool QHexDocument::canRedo() const { return m_undostack.canRedo(); } + +void QHexDocument::setData(const QByteArray& ba) { + QHexBuffer* mb = new QMemoryBuffer(); + mb->read(ba); + this->setData(mb); +} + +void QHexDocument::setData(QHexBuffer* buffer) { + if(!buffer) + return; + + m_undostack.clear(); + buffer->setParent(this); + + auto* oldbuffer = m_buffer; + m_buffer = buffer; + if(oldbuffer) + oldbuffer->deleteLater(); + + Q_EMIT canUndoChanged(false); + Q_EMIT canRedoChanged(false); + Q_EMIT changed(); + Q_EMIT reset(); +} + +void QHexDocument::clearModified() { m_undostack.setClean(); } + +qint64 QHexDocument::length() const { + return m_buffer ? m_buffer->length() : 0; +} + +uchar QHexDocument::at(int offset) const { return m_buffer->at(offset); } + +QHexDocument* QHexDocument::fromFile(QString filename, QObject* parent) { + QFile f(filename); + f.open(QFile::ReadOnly); + return QHexDocument::fromMemory(f.readAll(), parent); +} + +void QHexDocument::undo() { + m_undostack.undo(); + Q_EMIT changed(); +} + +void QHexDocument::redo() { + m_undostack.redo(); + Q_EMIT changed(); +} + +void QHexDocument::insert(qint64 offset, uchar b) { + this->insert(offset, QByteArray(1, b)); +} + +void QHexDocument::replace(qint64 offset, uchar b) { + this->replace(offset, QByteArray(1, b)); +} + +void QHexDocument::insert(qint64 offset, const QByteArray& data) { + m_undostack.push(new InsertCommand(m_buffer, this, offset, data)); + + Q_EMIT changed(); + Q_EMIT dataChanged(data, offset, ChangeReason::Insert); +} + +void QHexDocument::replace(qint64 offset, const QByteArray& data) { + m_undostack.push(new ReplaceCommand(m_buffer, this, offset, data)); + Q_EMIT changed(); + Q_EMIT dataChanged(data, offset, ChangeReason::Replace); +} + +void QHexDocument::remove(qint64 offset, int len) { + QByteArray data = m_buffer->read(offset, len); + + m_undostack.push(new RemoveCommand(m_buffer, this, offset, len)); + Q_EMIT changed(); + Q_EMIT dataChanged(data, offset, ChangeReason::Remove); +} + +QByteArray QHexDocument::read(qint64 offset, int len) const { + return m_buffer->read(offset, len); +} + +bool QHexDocument::saveTo(QIODevice* device) { + if(!device->isWritable()) + return false; + m_buffer->write(device); + return true; +} + +QHexDocument* QHexDocument::fromBuffer(QHexBuffer* buffer, QObject* parent) { + return new QHexDocument(buffer, parent); +} + +QHexDocument* QHexDocument::fromLargeFile(QString filename, QObject* parent) { + return QHexDocument::fromDevice(new QFile(filename), parent); +} + +QHexDocument* QHexDocument::fromMappedFile(QString filename, QObject* parent) { + return QHexDocument::fromDevice(new QFile(filename), + parent); +} + +QHexDocument* QHexDocument::create(QObject* parent) { + return QHexDocument::fromMemory({}, parent); +} diff --git a/UEFITool/qhexview5/model/qhexmetadata.cpp b/UEFITool/QHexView/src/model/qhexmetadata.cpp similarity index 56% rename from UEFITool/qhexview5/model/qhexmetadata.cpp rename to UEFITool/QHexView/src/model/qhexmetadata.cpp index a65f95a..8fa4864 100644 --- a/UEFITool/qhexview5/model/qhexmetadata.cpp +++ b/UEFITool/QHexView/src/model/qhexmetadata.cpp @@ -1,44 +1,44 @@ -#include "qhexmetadata.h" -#include "qhexcursor.h" +#include +#include -QHexMetadata::QHexMetadata(const QHexOptions* options, QObject *parent) : QObject(parent), m_options(options) { } +QHexMetadata::QHexMetadata(const QHexOptions* options, QObject* parent) + : QObject(parent), m_options(options) {} -const QHexMetadataLine* QHexMetadata::find(qint64 line) const -{ +const QHexMetadataLine* QHexMetadata::find(qint64 line) const { auto it = m_metadata.find(line); return it != m_metadata.end() ? std::addressof(it.value()) : nullptr; } -QString QHexMetadata::getComment(qint64 line, qint64 column) const -{ +QString QHexMetadata::getComment(qint64 line, qint64 column) const { auto* metadataline = this->find(line); - if(!metadataline) return QString(); + if(!metadataline) + return QString(); auto offset = QHexUtils::positionToOffset(m_options, {line, column}); QStringList comments; - for(auto& mi : *metadataline) - { - if((offset < mi.begin || offset > mi.end) || mi.comment.isEmpty()) continue; + for(auto& mi : *metadataline) { + if((offset < mi.begin || offset > mi.end) || mi.comment.isEmpty()) + continue; comments.push_back(mi.comment); } return comments.join("\n"); } -void QHexMetadata::removeMetadata(qint64 line) -{ +void QHexMetadata::removeMetadata(qint64 line) { auto it = m_metadata.find(line); - if(it == m_metadata.end()) return; + if(it == m_metadata.end()) + return; m_metadata.erase(it); Q_EMIT changed(); } -void QHexMetadata::removeBackground(qint64 line) -{ +void QHexMetadata::removeBackground(qint64 line) { this->clearMetadata(line, [](QHexMetadataItem& mi) -> bool { - if(!mi.background.isValid()) return false; + if(!mi.background.isValid()) + return false; if(mi.foreground.isValid() || !mi.comment.isEmpty()) { mi.background = QColor(); @@ -49,10 +49,10 @@ void QHexMetadata::removeBackground(qint64 line) }); } -void QHexMetadata::removeForeground(qint64 line) -{ +void QHexMetadata::removeForeground(qint64 line) { this->clearMetadata(line, [](QHexMetadataItem& mi) -> bool { - if(!mi.foreground.isValid()) return false; + if(!mi.foreground.isValid()) + return false; if(mi.background.isValid() || !mi.comment.isEmpty()) { mi.foreground = QColor(); @@ -63,10 +63,10 @@ void QHexMetadata::removeForeground(qint64 line) }); } -void QHexMetadata::removeComments(qint64 line) -{ +void QHexMetadata::removeComments(qint64 line) { this->clearMetadata(line, [](QHexMetadataItem& mi) -> bool { - if(mi.comment.isEmpty()) return false; + if(mi.comment.isEmpty()) + return false; if(mi.foreground.isValid() || mi.background.isValid()) { mi.comment.clear(); @@ -77,10 +77,10 @@ void QHexMetadata::removeComments(qint64 line) }); } -void QHexMetadata::unhighlight(qint64 line) -{ +void QHexMetadata::unhighlight(qint64 line) { this->clearMetadata(line, [](QHexMetadataItem& mi) -> bool { - if(!mi.foreground.isValid() && !mi.background.isValid()) return false; + if(!mi.foreground.isValid() && !mi.background.isValid()) + return false; if(!mi.comment.isEmpty()) { mi.foreground = QColor(); @@ -92,54 +92,63 @@ void QHexMetadata::unhighlight(qint64 line) }); } -void QHexMetadata::clear() { m_metadata.clear(); Q_EMIT changed(); } -void QHexMetadata::copy(const QHexMetadata* metadata) { m_metadata = metadata->m_metadata; } +void QHexMetadata::clear() { + m_metadata.clear(); + Q_EMIT changed(); +} -void QHexMetadata::clearMetadata(qint64 line, ClearMetadataCallback&& cb) -{ +void QHexMetadata::copy(const QHexMetadata* metadata) { + m_metadata = metadata->m_metadata; +} + +void QHexMetadata::clearMetadata(qint64 line, ClearMetadataCallback&& cb) { auto iit = m_metadata.find(line); - if(iit == m_metadata.end()) return; + if(iit == m_metadata.end()) + return; auto oldsize = iit->size(); - for(auto it = iit->begin(); it != iit->end(); ) - { - if(cb(*it)) it = iit->erase(it); - else it++; + for(auto it = iit->begin(); it != iit->end();) { + if(cb(*it)) + it = iit->erase(it); + else + it++; } - if(iit->empty()) - { + if(iit->empty()) { this->removeMetadata(line); return; } - if(oldsize != iit->size()) Q_EMIT changed(); + if(oldsize != iit->size()) + Q_EMIT changed(); } -void QHexMetadata::setMetadata(const QHexMetadataItem& mi) -{ - if(!m_options->linelength) return; +void QHexMetadata::setMetadata(const QHexMetadataItem& mi) { + if(!m_options->linelength) + return; const qint64 firstline = mi.begin / m_options->linelength; const qint64 lastline = mi.end / m_options->linelength; bool notify = false; - for(auto line = firstline; line <= lastline; line++) - { + for(auto line = firstline; line <= lastline; line++) { auto start = line == firstline ? mi.begin % m_options->linelength : 0; - auto length = line == lastline ? (mi.end % m_options->linelength) - start : m_options->linelength; - if(length <= 0) continue; + auto length = line == lastline + ? (mi.end % m_options->linelength) - start + : m_options->linelength; + if(length <= 0) + continue; notify = true; m_metadata[line].push_back(mi); } - if(notify) Q_EMIT changed(); + if(notify) + Q_EMIT changed(); } -void QHexMetadata::invalidate() -{ +void QHexMetadata::invalidate() { auto oldmetadata = m_metadata; m_metadata.clear(); diff --git a/UEFITool/QHexView/src/model/qhexutils.cpp b/UEFITool/QHexView/src/model/qhexutils.cpp new file mode 100644 index 0000000..13350ba --- /dev/null +++ b/UEFITool/QHexView/src/model/qhexutils.cpp @@ -0,0 +1,384 @@ +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) +#define QHEXVIEW_VARIANT_EQ(x, t) ((x).metaType().id() == QMetaType::Q##t) +#else +#define QHEXVIEW_VARIANT_EQ(x, t) ((x).type() == QVariant::t) +#endif + +#if defined(_WIN32) && _MSC_VER <= 1916 // v141_xp +#include +namespace std { +using ::tolower; +} +#else +#include +#endif + +namespace QHexUtils { + +Q_GLOBAL_STATIC_WITH_ARGS(QList, HEXMAP, + ({'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', + 'a', 'b', 'c', 'd', 'e', 'f'})); + +bool isHex(char ch) { + return (ch >= '0' && ch <= '9') || (ch >= 'A' && ch <= 'F') || + (ch >= 'a' && ch <= 'f'); +} + +namespace PatternUtils { + +Q_GLOBAL_STATIC_WITH_ARGS(QString, WILDCARD_BYTE, ("??")) + +bool check(QString& p, qint64& len) { + static QHash> + processed; // Cache processed patterns + + auto it = processed.find(p); + + if(it != processed.end()) { + p = it.value().first; + len = it.value().second; + return true; + } + + QString op = p; // Store unprocessed pattern + p = p.simplified().replace(" ", ""); + if(p.isEmpty() || (p.size() % 2)) + return false; + + int wccount = 0; + + for(auto i = 0; i < p.size() - 2; i += 2) { + const auto& hexb = p.mid(i, 2); + + if(hexb == *WILDCARD_BYTE) { + wccount++; + continue; + } + + if(!QHexUtils::isHex(hexb.at(0).toLatin1()) || + !QHexUtils::isHex(hexb.at(1).toLatin1())) + return false; + } + + if(wccount >= p.size()) + return false; + len = p.size() / 2; + processed[op] = qMakePair(p, len); // Cache processed pattern + return true; +} + +bool match(const QByteArray& data, const QString& pattern) { + for(qint64 i = 0, idx = 0; (i <= (pattern.size() - 2)); i += 2, idx++) { + if(idx >= data.size()) + return false; + +#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) + QStringView hexb = QStringView{pattern}.mid(i, 2); +#else + const QStringRef& hexb = pattern.midRef(i, 2); +#endif + + if(hexb == *WILDCARD_BYTE) + continue; + + bool ok = false; + auto b = static_cast(hexb.toUInt(&ok, 16)); + if(!ok || (b != data.at(idx))) + return false; + } + + return true; +} + +} // namespace PatternUtils + +namespace { + +unsigned int countBits(uint val) { + if(val <= std::numeric_limits::max()) + return QHexFindOptions::Int8; + if(val <= std::numeric_limits::max()) + return QHexFindOptions::Int16; + if(val <= std::numeric_limits::max()) + return QHexFindOptions::Int32; + + return QHexFindOptions::Int64; +} + +template +qint64 findIter(qint64 startoffset, QHexFindDirection fd, + const QHexView* hexview, Function&& f) { + QHexDocument* hexdocument = hexview->hexDocument(); + qint64 offset = -1; + + QHexFindDirection cfd = fd; + if(cfd == QHexFindDirection::All) + cfd = QHexFindDirection::Forward; + + qint64 i = startoffset; + + bool restartLoopOnce = true; + + while(offset == -1 && + (cfd == QHexFindDirection::Backward ? (i >= 0) + : (i < hexdocument->length()))) { + if(!f(i, offset)) + break; + + if(cfd == QHexFindDirection::Backward) + i--; + else + i++; + + if(fd == QHexFindDirection::All && i >= hexdocument->length() && + restartLoopOnce) { + i = 0; + restartLoopOnce = false; + } + } + + return offset; +} + +qint64 findDefault(const QByteArray& value, qint64 startoffset, + const QHexView* hexview, unsigned int options, + QHexFindDirection fd) { + QHexDocument* hexdocument = hexview->hexDocument(); + if(value.size() > hexdocument->length()) + return -1; + + return findIter( + startoffset, fd, hexview, + [options, value, hexdocument](qint64 idx, qint64& offset) -> bool { + for(auto i = 0; i < value.size(); i++) { + qint64 curroffset = idx + i; + + if(curroffset >= hexdocument->length()) { + offset = -1; + return false; + } + + uchar ch1 = hexdocument->at(curroffset); + uchar ch2 = value.at(i); + + if(!(options & QHexFindOptions::CaseSensitive)) { + ch1 = std::tolower(ch1); + ch2 = std::tolower(ch2); + } + + if(ch1 != ch2) + break; + if(i == value.size() - 1) + offset = idx; + } + + return true; + }); +} + +qint64 findWildcard(QString pattern, qint64 startoffset, + const QHexView* hexview, QHexFindDirection fd, + qint64& patternlen) { + QHexDocument* hexdocument = hexview->hexDocument(); + if(!PatternUtils::check(pattern, patternlen) || + (patternlen >= hexdocument->length())) + return -1; + + return findIter( + startoffset, fd, hexview, + [hexdocument, pattern, patternlen](qint64 idx, qint64& offset) -> bool { + if(PatternUtils::match(hexdocument->read(idx, patternlen), pattern)) + offset = idx; + return true; + }); +} + +QByteArray variantToByteArray(QVariant value, QHexFindMode mode, + unsigned int options) { + QByteArray v; + + switch(mode) { + case QHexFindMode::Text: + if(QHEXVIEW_VARIANT_EQ(value, String)) + v = value.toString().toUtf8(); + else if(QHEXVIEW_VARIANT_EQ(value, ByteArray)) + v = value.toByteArray(); + break; + + case QHexFindMode::Hex: { + if(QHEXVIEW_VARIANT_EQ(value, String)) { + qint64 len = 0; + auto s = value.toString(); + if(!PatternUtils::check(s, len)) + return {}; + + bool ok = true; + +#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) + for(auto i = 0; ok && i < s.size(); i += 2) + v.push_back(static_cast( + QStringView{s}.mid(i, 2).toUInt(&ok, 16))); +#else + for(auto i = 0; ok && i < s.size(); i += 2) + v.push_back( + static_cast(s.midRef(i, 2).toUInt(&ok, 16))); +#endif + + if(!ok) + return {}; + } + else if(QHEXVIEW_VARIANT_EQ(value, ByteArray)) + v = value.toByteArray(); + break; + } + + case QHexFindMode::Int: { + bool ok = false; + uint val = value.toUInt(&ok); + if(!ok) + return QByteArray{}; + + QDataStream ds(&v, QIODevice::WriteOnly); + + if(options & QHexFindOptions::BigEndian) { + if(options & QHexFindOptions::Int8) + ds << qToBigEndian(val); + else if(options & QHexFindOptions::Int16) + ds << qToBigEndian(val); + else if(options & QHexFindOptions::Int32) + ds << qToBigEndian(val); + else if(options & QHexFindOptions::Int64) + ds << qToBigEndian(val); + else + return variantToByteArray(value, mode, + options | countBits(val)); + } + else { + if(options & QHexFindOptions::Int8) + ds << static_cast(val); + else if(options & QHexFindOptions::Int16) + ds << static_cast(val); + else if(options & QHexFindOptions::Int32) + ds << static_cast(val); + else if(options & QHexFindOptions::Int64) + ds << static_cast(val); + else + return variantToByteArray(value, mode, + options | countBits(val)); + } + + break; + } + + case QHexFindMode::Float: { + bool ok = false; + QDataStream ds(&v, QIODevice::WriteOnly); + if(options & QHexFindOptions::Float) + ds << value.toFloat(&ok); + else if(options & QHexFindOptions::Double) + ds << value.toDouble(&ok); + if(!ok) + return {}; + } + + default: break; + } + + return v; +} + +} // namespace + +QByteArray toHex(const QByteArray& ba, char sep) { + if(ba.isEmpty()) { + return QByteArray(); + } + + QByteArray hex(sep ? (ba.size() * 3 - 1) : (ba.size() * 2), + Qt::Uninitialized); + + for(auto i = 0, o = 0; i < ba.size(); i++) { + if(sep && i) + hex[o++] = static_cast(sep); + hex[o++] = HEXMAP->at((ba.at(i) & 0xf0) >> 4); + hex[o++] = HEXMAP->at(ba.at(i) & 0x0f); + } + + return hex; +} + +QByteArray toHex(const QByteArray& ba) { return QHexUtils::toHex(ba, '\0'); } +qint64 positionToOffset(const QHexOptions* options, QHexPosition pos) { + return options->linelength * pos.line + pos.column; +} +QHexPosition offsetToPosition(const QHexOptions* options, qint64 offset) { + return {offset / options->linelength, offset % options->linelength}; +} + +QPair find(const QHexView* hexview, QVariant value, + qint64 startoffset, QHexFindMode mode, + unsigned int options, QHexFindDirection fd) { + qint64 offset = -1, size = 0; + if(startoffset == -1) + startoffset = static_cast(hexview->offset()); + + if(mode == QHexFindMode::Hex && QHEXVIEW_VARIANT_EQ(value, String)) { + offset = QHexUtils::findWildcard(value.toString(), startoffset, hexview, + fd, size); + } + else { + auto ba = variantToByteArray(value, mode, options); + + if(!ba.isEmpty()) { + offset = + QHexUtils::findDefault(ba, startoffset, hexview, options, fd); + size = ba.size(); + } + else + offset = -1; + } + + return {offset, offset > -1 ? size : 0}; +} + +bool checkPattern(QString pattern) { + qint64 len = 0; + return PatternUtils::check(pattern, len); +} + +QPair replace(const QHexView* hexview, QVariant oldvalue, + QVariant newvalue, qint64 startoffset, + QHexFindMode mode, unsigned int options, + QHexFindDirection fd) { + auto res = + QHexUtils::find(hexview, oldvalue, startoffset, mode, options, fd); + + if(res.first != -1 && res.second > 0) { + QHexDocument* hexdocument = hexview->hexDocument(); + auto ba = variantToByteArray(newvalue, mode, options); + + if(!ba.isEmpty()) { + hexdocument->remove(res.first, res.second); + hexdocument->insert(res.first, ba); + res.second = ba.size(); + } + else { + res.first = -1; + res.second = 0; + } + } + + return res; +} + +} // namespace QHexUtils diff --git a/UEFITool/QHexView/src/qhexview.cpp b/UEFITool/QHexView/src/qhexview.cpp new file mode 100644 index 0000000..4055317 --- /dev/null +++ b/UEFITool/QHexView/src/qhexview.cpp @@ -0,0 +1,1583 @@ +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#if defined(QHEXVIEW_ENABLE_DIALOGS) +#include +#endif + +#if defined(QHEXVIEW_DEBUG) +#include +#define qhexview_fmtprint(fmt, ...) qDebug("%s " fmt, __func__, __VA_ARGS__) +#else +#define qhexview_fmtprint(fmt, ...) +#endif + +QHexView::QHexView(QWidget* parent) + : QAbstractScrollArea(parent), m_fontmetrics(this->font()) { + QFont f = QFontDatabase::systemFont(QFontDatabase::FixedFont); + + if(f.styleHint() != QFont::TypeWriter) { + f.setFamily("Monospace"); // Force Monospaced font + f.setStyleHint(QFont::TypeWriter); + } + + this->setFont(f); + this->setMouseTracking(true); + this->setFocusPolicy(Qt::StrongFocus); + this->viewport()->setCursor(Qt::IBeamCursor); + + QPalette p = this->palette(); + p.setBrush(QPalette::Window, p.base()); + + connect(this->verticalScrollBar(), &QScrollBar::valueChanged, this, + [=](int) { this->viewport()->update(); }); + + m_hexmetadata = new QHexMetadata(&m_options, this); + connect(m_hexmetadata, &QHexMetadata::changed, this, + [=]() { this->viewport()->update(); }); + + m_hexcursor = new QHexCursor(&m_options, this); + this->setDocument( + QHexDocument::fromMemory(QByteArray(), this)); + this->checkState(); + + connect(m_hexcursor, &QHexCursor::positionChanged, this, [=]() { + m_writing = false; + this->ensureVisible(); + Q_EMIT positionChanged(); + }); + + connect(m_hexcursor, &QHexCursor::modeChanged, this, [=]() { + m_writing = false; + this->viewport()->update(); + Q_EMIT modeChanged(); + }); +} + +QRectF QHexView::headerRect() const { + if(m_options.hasFlag(QHexFlags::NoHeader)) + return QRectF(); + + return QRectF(0, 0, this->endColumnX(), this->lineHeight()); +} + +QRectF QHexView::addressRect() const { + qreal y = m_options.hasFlag(QHexFlags::NoHeader) ? 0 : this->lineHeight(); + + return QRectF(0, y, this->endColumnX(), this->height() - y); +} + +QRectF QHexView::hexRect() const { + qreal y = m_options.hasFlag(QHexFlags::NoHeader) ? 0 : this->lineHeight(); + + return QRectF(this->hexColumnX(), y, + this->asciiColumnX() - this->hexColumnX(), + this->height() - y); +} + +QRectF QHexView::asciiRect() const { + qreal y = m_options.hasFlag(QHexFlags::NoHeader) ? 0 : this->lineHeight(); + + return QRectF(this->asciiColumnX(), y, + this->endColumnX() - this->asciiColumnX(), + this->height() - y); +} + +QHexDocument* QHexView::hexDocument() const { return m_hexdocument; } +QHexCursor* QHexView::hexCursor() const { + return m_hexdocument ? m_hexcursor : nullptr; +} +const QHexMetadata* QHexView::hexMetadata() const { return m_hexmetadata; } +QHexOptions QHexView::options() const { return m_options; } + +void QHexView::setOptions(const QHexOptions& options) { + auto oldlinelength = m_options.linelength; + m_options = options; + + if(oldlinelength != m_options.linelength) + m_hexmetadata->invalidate(); + + this->checkAndUpdate(); +} + +void QHexView::setBaseAddress(quint64 baseaddress) { + if(m_options.baseaddress == baseaddress) + return; + + m_options.baseaddress = baseaddress; + this->checkAndUpdate(); +} + +void QHexView::setDelegate(QHexDelegate* rd) { + if(m_hexdelegate == rd) + return; + m_hexdelegate = rd; + this->checkAndUpdate(); +} + +void QHexView::setDocument(QHexDocument* doc) { + if(!doc) + doc = QHexDocument::fromMemory(QByteArray(), this); + if(!doc->parent()) + doc->setParent(this); + + m_writing = false; + m_hexmetadata->clear(); + m_hexcursor->move(0); + + if(m_hexdocument) { + disconnect(m_hexdocument, &QHexDocument::changed, this, nullptr); + disconnect(m_hexdocument, &QHexDocument::dataChanged, this, nullptr); + disconnect(m_hexdocument, &QHexDocument::reset, this, nullptr); + disconnect(m_hexdocument, &QHexDocument::modifiedChanged, this, + nullptr); + } + + m_hexdocument = doc; + + connect(m_hexdocument, &QHexDocument::reset, this, [=]() { + m_writing = false; + m_hexcursor->move(0); + this->checkAndUpdate(true); + }); + + connect(m_hexdocument, &QHexDocument::dataChanged, this, + &QHexView::dataChanged); + + connect(m_hexdocument, &QHexDocument::modifiedChanged, this, + &QHexView::modifiedChanged); + + connect(m_hexdocument, &QHexDocument::changed, this, + [=]() { this->checkAndUpdate(true); }); + + this->checkAndUpdate(true); +} + +void QHexView::setData(const QByteArray& ba) { m_hexdocument->setData(ba); } +void QHexView::setData(QHexBuffer* buffer) { m_hexdocument->setData(buffer); } + +void QHexView::setCursorMode(QHexCursor::Mode mode) { + m_hexcursor->setMode(mode); +} + +void QHexView::setByteColor(quint8 b, QHexColor c) { + m_options.bytecolors[b] = c; + this->checkAndUpdate(); +} + +void QHexView::setByteForeground(quint8 b, QColor c) { + m_options.bytecolors[b].foreground = c; + this->checkAndUpdate(); +} + +void QHexView::setByteBackground(quint8 b, QColor c) { + m_options.bytecolors[b].background = c; + this->checkAndUpdate(); +} + +void QHexView::setMetadata(qint64 begin, qint64 end, const QColor& fgcolor, + const QColor& bgcolor, const QString& comment) { + m_hexmetadata->setMetadata(begin, end, fgcolor, bgcolor, comment); +} +void QHexView::setForeground(qint64 begin, qint64 end, const QColor& fgcolor) { + m_hexmetadata->setForeground(begin, end, fgcolor); +} +void QHexView::setBackground(qint64 begin, qint64 end, const QColor& bgcolor) { + m_hexmetadata->setBackground(begin, end, bgcolor); +} +void QHexView::setComment(qint64 begin, qint64 end, const QString& comment) { + m_hexmetadata->setComment(begin, end, comment); +} +void QHexView::setMetadataSize(qint64 begin, qint64 length, + const QColor& fgcolor, const QColor& bgcolor, + const QString& comment) { + m_hexmetadata->setMetadataSize(begin, length, fgcolor, bgcolor, comment); +} +void QHexView::setForegroundSize(qint64 begin, qint64 length, + const QColor& fgcolor) { + m_hexmetadata->setForegroundSize(begin, length, fgcolor); +} +void QHexView::setBackgroundSize(qint64 begin, qint64 length, + const QColor& bgcolor) { + m_hexmetadata->setBackgroundSize(begin, length, bgcolor); +} +void QHexView::setCommentSize(qint64 begin, qint64 length, + const QString& comment) { + m_hexmetadata->setCommentSize(begin, length, comment); +} +void QHexView::removeMetadata(qint64 line) { + m_hexmetadata->removeMetadata(line); +} +void QHexView::removeBackground(qint64 line) { + m_hexmetadata->removeBackground(line); +} +void QHexView::removeForeground(qint64 line) { + m_hexmetadata->removeForeground(line); +} +void QHexView::removeComments(qint64 line) { + m_hexmetadata->removeComments(line); +} +void QHexView::unhighlight(qint64 line) { m_hexmetadata->unhighlight(line); } +void QHexView::clearMetadata() { m_hexmetadata->clear(); } + +#if defined(QHEXVIEW_ENABLE_DIALOGS) +void QHexView::showFind() { + if(!m_hexdlgfind) + m_hexdlgfind = new HexFindDialog(HexFindDialog::Type::Find, this); + m_hexdlgfind->show(); +} + +void QHexView::showReplace() { + if(!m_hexdlgreplace) + m_hexdlgreplace = new HexFindDialog(HexFindDialog::Type::Replace, this); + m_hexdlgreplace->show(); +} +#endif + +void QHexView::undo() { + if(m_hexdocument) + m_hexdocument->undo(); +} +void QHexView::redo() { + if(m_hexdocument) + m_hexdocument->redo(); +} + +void QHexView::cut(bool hex) { + this->copy(hex); + if(m_readonly) + return; + + if(m_hexcursor->hasSelection()) + this->removeSelection(); + else + m_hexdocument->remove(m_hexcursor->offset(), 1); +} + +void QHexView::copyAs(CopyMode mode) const { + QClipboard* c = qApp->clipboard(); + + QByteArray bytes = m_hexcursor->hasSelection() + ? m_hexcursor->selectedBytes() + : m_hexdocument->read(m_hexcursor->offset(), 1); + + switch(mode) { + case CopyMode::HexArrayCurly: + case CopyMode::HexArraySquare: { + QString hexchar; + int i = 0; + + for(char b : bytes) { + if(!hexchar.isEmpty()) { + hexchar += ", "; + if(m_options.copybreak && !(++i % m_options.linelength)) + hexchar += "\n"; + } + + hexchar += + "0x" + QString::number(static_cast(b), 16).toUpper(); + } + + c->setText( + QString(mode == CopyMode::HexArraySquare ? "[%1]" : "{%1}") + .arg(hexchar)); + break; + } + + case CopyMode::HexArrayChar: { + QString hexchar; + + for(char b : bytes) + hexchar += + "\\x" + QString::number(static_cast(b), 16).toUpper(); + + c->setText(QString("\"%1\"").arg(hexchar)); + break; + } + + default: { + QString hexchar; + + for(int i = 0; i < bytes.size(); i++) { + if(!(i % m_options.grouplength)) { + if(!hexchar.isEmpty()) { + hexchar += ", "; + if(m_options.copybreak && !(i % m_options.linelength)) + hexchar += "\n"; + } + + hexchar += "0x"; + } + + hexchar += QString("%1") + .arg(static_cast(bytes[i]), 2, 16, + QLatin1Char('0')) + .toUpper(); + } + + c->setText(hexchar); + break; + } + } +} + +void QHexView::copy(bool hex) const { + QClipboard* c = qApp->clipboard(); + + QByteArray bytes = m_hexcursor->hasSelection() + ? m_hexcursor->selectedBytes() + : m_hexdocument->read(m_hexcursor->offset(), 1); + + if(hex) + bytes = QHexUtils::toHex(bytes, ' ').toUpper(); + c->setText(bytes); +} + +void QHexView::paste(bool hex) { + if(m_readonly) + return; + + QClipboard* c = qApp->clipboard(); + QByteArray pastedata = c->text().toUtf8(); + if(pastedata.isEmpty()) + return; + + this->removeSelection(); + if(hex) + pastedata = QByteArray::fromHex(pastedata); + + if(m_hexcursor->mode() == QHexCursor::Mode::Insert) + m_hexdocument->insert(m_hexcursor->offset(), pastedata); + else + m_hexdocument->replace(m_hexcursor->offset(), pastedata); +} + +void QHexView::clearModified() { + if(m_hexdocument) + m_hexdocument->clearModified(); +} + +void QHexView::selectAll() { + m_hexcursor->move(0); + m_hexcursor->select(m_hexdocument->length()); +} + +void QHexView::removeSelection() { + if(!m_hexcursor->hasSelection()) + return; + if(!m_readonly) + m_hexdocument->remove(m_hexcursor->selectionStartOffset(), + m_hexcursor->selectionLength() - 1); + m_hexcursor->clearSelection(); +} + +void QHexView::switchMode() { m_hexcursor->switchMode(); } + +void QHexView::setAddressWidth(unsigned int w) { + if(w == m_options.addresswidth) + return; + m_options.addresswidth = w; + this->checkState(); +} + +void QHexView::setScrollSteps(int scrollsteps) { + m_options.scrollsteps = scrollsteps; +} + +void QHexView::setReadOnly(bool r) { m_readonly = r; } + +void QHexView::setAutoWidth(bool r) { + if(m_autowidth == r) + return; + m_autowidth = r; + this->checkState(); +} + +void QHexView::paint(QPainter* painter) const { + QTextDocument doc; + doc.setDocumentMargin(0); + doc.setUndoRedoEnabled(false); + doc.setDefaultFont(this->font()); + + QTextCursor c(&doc); + + this->drawHeader(c); + this->drawDocument(c); + + painter->translate(-this->horizontalScrollBar()->value(), 0); + doc.drawContents(painter); + this->drawSeparators(painter); +} + +void QHexView::checkOptions() { + if(m_options.grouplength > m_options.linelength) + m_options.grouplength = m_options.linelength; + + m_options.addresswidth = + qMax(m_options.addresswidth, this->calcAddressWidth()); + + // Round to nearest multiple of 2 + m_options.grouplength = + 1u << (static_cast(qFloor(m_options.grouplength / 2.0))); + + if(m_options.grouplength <= 1) + m_options.grouplength = 1; + + if(!m_options.headercolor.isValid()) + m_options.headercolor = + this->palette().color(QPalette::Normal, QPalette::Highlight); +} + +void QHexView::setLineLength(unsigned int l) { + if(l == m_options.linelength) + return; + m_options.linelength = l; + m_hexmetadata->invalidate(); + this->checkAndUpdate(true); +} + +void QHexView::setGroupLength(unsigned int l) { + if(l == m_options.grouplength) + return; + m_options.grouplength = l; + this->checkAndUpdate(true); +} + +void QHexView::checkState() { + if(!m_hexdocument) + return; + this->checkOptions(); + + int doclines = static_cast(this->lines()), + vislines = this->visibleLines(true); + qint64 vscrollmax = doclines - vislines + 1; // UEFITool: ensure the very last line is visible on macOS + if(doclines >= vislines) + vscrollmax++; + + this->verticalScrollBar()->setRange(0, qMax(0, vscrollmax)); + this->verticalScrollBar()->setPageStep(vislines - 1); + this->verticalScrollBar()->setSingleStep(m_options.scrollsteps); + + int vw = this->verticalScrollBar()->isVisible() + ? this->verticalScrollBar()->width() + : 0; + + static int oldmw = 0; + if(!oldmw) + oldmw = this->maximumWidth(); + this->setMaximumWidth(m_autowidth ? qCeil(this->endColumnX() + vw + 3) + : oldmw); + + this->horizontalScrollBar()->setRange( + 0, qMax(0, this->endColumnX() - this->width() + vw + 3)); + this->horizontalScrollBar()->setPageStep(this->width()); +} + +void QHexView::checkAndUpdate(bool calccolumns) { + this->checkState(); + if(calccolumns) + this->calcColumns(); + this->viewport()->update(); +} + +void QHexView::calcColumns() { + if(!m_hexdocument) + return; + + m_hexcolumns.clear(); + m_hexcolumns.reserve(m_options.linelength); + + auto x = this->hexColumnX(), cw = this->cellWidth() * 2; + + for(auto i = 0u; i < m_options.linelength; i++) { + for(auto j = 0u; j < m_options.grouplength; j++, x += cw) + m_hexcolumns.push_back(QRect(x, 0, cw, 0)); + + x += this->cellWidth(); + } +} + +void QHexView::ensureVisible() { + if(!m_hexdocument) + return; + + auto pos = m_hexcursor->position(); + auto vlines = this->visibleLines(); + + if(pos.line >= (this->verticalScrollBar()->value() + vlines)) + this->verticalScrollBar()->setValue(pos.line - vlines + 1); + else if(pos.line < this->verticalScrollBar()->value()) + this->verticalScrollBar()->setValue(pos.line); + else + this->viewport()->update(); +} + +void QHexView::drawSeparators(QPainter* p) const { + if(!m_options.hasFlag(QHexFlags::Separators)) + return; + + auto oldpen = p->pen(); + p->setPen(m_options.separatorcolor.isValid() + ? m_options.separatorcolor + : this->palette().color(QPalette::Dark)); + + if(m_options.hasFlag(QHexFlags::HSeparator)) { + QLineF l(0, m_fontmetrics.lineSpacing(), this->endColumnX(), + m_fontmetrics.lineSpacing()); + if(!m_hexdelegate || !m_hexdelegate->paintSeparator(p, l, this)) + p->drawLine(l); + } + + if(m_options.hasFlag(QHexFlags::VSeparator)) { + QLineF l1(this->hexColumnX(), 0, this->hexColumnX(), this->height()); + QLineF l2(this->asciiColumnX(), 0, this->asciiColumnX(), + this->height()); + + if(!m_hexdelegate || + (m_hexdelegate && !m_hexdelegate->paintSeparator(p, l1, this))) + p->drawLine(l1); + + if(!m_hexdelegate || + (m_hexdelegate && !m_hexdelegate->paintSeparator(p, l2, this))) + p->drawLine(l2); + } + + p->setPen(oldpen); +} + +void QHexView::drawHeader(QTextCursor& c) const { + if(m_options.hasFlag(QHexFlags::NoHeader)) + return; + + static const auto RESET_FORMAT = [](const QHexOptions& options, + QTextCharFormat& cf) { + cf = {}; + cf.setForeground(options.headercolor); + }; + + QString addresslabel; + if(m_hexdelegate) + addresslabel = m_hexdelegate->addressHeader(this); + if(addresslabel.isEmpty() && !m_options.addresslabel.isEmpty()) + addresslabel = m_options.addresslabel; + + QTextCharFormat cf; + RESET_FORMAT(m_options, cf); + if(m_hexdelegate) + m_hexdelegate->renderHeaderPart(addresslabel, QHexArea::Address, cf, + this); + c.insertText( + " " + QHexView::reduced(addresslabel, this->addressWidth()) + " ", cf); + + if(m_hexdelegate) + RESET_FORMAT(m_options, cf); + + QString hexlabel; + if(m_hexdelegate) + hexlabel = m_hexdelegate->hexHeader(this); + if(hexlabel.isEmpty()) + hexlabel = m_options.hexlabel; + + if(hexlabel.isNull()) { + c.insertText(" ", {}); + + for(auto i = 0u; i < m_options.linelength; i += m_options.grouplength) { + QString h = QString::number(i, 16) + .rightJustified(m_options.grouplength * 2, '0') + .toUpper(); + + if(m_hexdelegate) { + RESET_FORMAT(m_options, cf); + m_hexdelegate->renderHeaderPart(h, QHexArea::Hex, cf, this); + } + + if(m_hexcursor->column() == static_cast(i) && + m_options.hasFlag(QHexFlags::HighlightColumn)) { + cf.setBackground(this->palette().color(QPalette::Highlight)); + cf.setForeground( + this->palette().color(QPalette::HighlightedText)); + } + + c.insertText(h, cf); + c.insertText(" ", {}); + RESET_FORMAT(m_options, cf); + } + } + else { + if(m_hexdelegate) + m_hexdelegate->renderHeaderPart(hexlabel, QHexArea::Hex, cf, this); + c.insertText( + " " + + QHexView::reduced( + hexlabel, (this->hexColumnWidth() / this->cellWidth()) - 1) + + " "); + } + + if(m_hexdelegate) + RESET_FORMAT(m_options, cf); + + QString asciilabel; + if(m_hexdelegate) + asciilabel = m_hexdelegate->asciiHeader(this); + if(asciilabel.isEmpty()) + asciilabel = m_options.asciilabel; + + if(asciilabel.isNull()) { + c.insertText(" ", {}); + + for(unsigned int i = 0; i < m_options.linelength; i++) { + QString a = QString::number(i, 16).toUpper(); + + if(m_hexdelegate) { + RESET_FORMAT(m_options, cf); + m_hexdelegate->renderHeaderPart(a, QHexArea::Ascii, cf, this); + } + + if(m_hexcursor->column() == static_cast(i) && + m_options.hasFlag(QHexFlags::HighlightColumn)) { + cf.setBackground(this->palette().color(QPalette::Highlight)); + cf.setForeground( + this->palette().color(QPalette::HighlightedText)); + } + + c.insertText(a, cf); + RESET_FORMAT(m_options, cf); + } + + c.insertText(" ", {}); + } + else { + if(m_hexdelegate) + m_hexdelegate->renderHeaderPart(asciilabel, QHexArea::Ascii, cf, + this); + c.insertText(" " + + QHexView::reduced(asciilabel, ((this->endColumnX() - + this->asciiColumnX() - + this->cellWidth()) / + this->cellWidth()) - + 1) + + " "); + } + + QTextBlockFormat bf; + if(m_options.hasFlag(QHexFlags::StyledHeader)) + bf.setBackground(this->palette().color(QPalette::Window)); + if(m_hexdelegate) + m_hexdelegate->renderHeader(bf, this); + c.setBlockFormat(bf); + c.insertBlock(); +} + +void QHexView::drawDocument(QTextCursor& c) const { + if(!m_hexdocument) + return; + + qreal y = !m_options.hasFlag(QHexFlags::NoHeader) ? this->lineHeight() : 0; + quint64 line = static_cast(this->verticalScrollBar()->value()); + + QTextCharFormat addrformat; + addrformat.setForeground( + this->palette().color(QPalette::Normal, QPalette::Highlight)); + + for(qint64 l = 0; m_hexdocument->isEmpty() || + (line < this->lines() && l < this->visibleLines()); + l++, line++, y += this->lineHeight()) { + quint64 address = line * m_options.linelength + this->baseAddress(); + QString addrstr = QString::number(address, 16) + .rightJustified(this->addressWidth(), '0') + .toUpper(); + + // Address Part + QTextCharFormat acf; + acf.setForeground(m_options.headercolor); + + if(m_options.hasFlag(QHexFlags::StyledAddress)) + acf.setBackground(this->palette().color(QPalette::Window)); + + if(m_hexdelegate) + m_hexdelegate->renderAddress(address, acf, this); + + if(m_hexcursor->line() == static_cast(line) && + m_options.hasFlag(QHexFlags::HighlightAddress)) { + acf.setBackground(this->palette().color(QPalette::Highlight)); + acf.setForeground(this->palette().color(QPalette::HighlightedText)); + } + + c.insertText(" " + addrstr + " ", acf); + + QByteArray linebytes = this->getLine(line); + c.insertText(" ", {}); + + // Hex Part + for(unsigned int column = 0u; column < m_options.linelength;) { + QTextCharFormat cf; + + for(unsigned int byteidx = 0u; byteidx < m_options.grouplength; + byteidx++, column++) { + QString s; + quint8 b{}; + + if(m_hexdocument->accept( + this->positionFromLineCol(line, column))) { + s = linebytes.isEmpty() || + column >= static_cast(linebytes.size()) + ? " " + : QString(QHexUtils::toHex(linebytes.mid(column, 1)) + .toUpper()); + b = static_cast(column) < linebytes.size() + ? linebytes.at(column) + : 0x00; + } + else + s = QString(m_options.invalidchar).repeated(2); + + cf = this->drawFormat(c, b, s, QHexArea::Hex, line, column, + static_cast(column) < + linebytes.size()); + } + + c.insertText(" ", cf); + } + + c.insertText(" ", {}); + + // Ascii Part + for(unsigned int column = 0u; column < m_options.linelength; column++) { + QString s; + quint8 b{}; + + if(m_hexdocument->accept(this->positionFromLineCol(line, column))) { + s = linebytes.isEmpty() || + column >= static_cast(linebytes.size()) + ? QChar(' ') + : (QChar::isPrint(linebytes.at(column)) + ? QChar(linebytes.at(column)) + : m_options.unprintablechar); + + b = static_cast(column) < linebytes.size() + ? linebytes.at(column) + : 0x00; + } + else + s = m_options.invalidchar; + + this->drawFormat(c, b, s, QHexArea::Ascii, line, column, + static_cast(column) < linebytes.size()); + } + + QTextBlockFormat bf; + + if(m_options.linealternatebackground.isValid() && line % 2) + bf.setBackground(m_options.linealternatebackground); + else if(m_options.linebackground.isValid() && !(line % 2)) + bf.setBackground(m_options.linebackground); + + bf.setLineHeight(this->lineHeight(), QTextBlockFormat::FixedHeight); // UEFITool: added to fix an issue with Hi-DPI displays on Windows + c.setBlockFormat(bf); + c.insertBlock({}); + if(m_hexdocument->isEmpty()) + break; + } +} + +unsigned int QHexView::calcAddressWidth() const { + if(!m_hexdocument) + return 0; + + auto maxaddr = + static_cast(m_options.baseaddress + m_hexdocument->length()); + if(maxaddr <= std::numeric_limits::max()) + return 8; + return QString::number(maxaddr, 16).size(); +} + +int QHexView::visibleLines(bool absolute) const { + int vl = static_cast( + qCeil(this->viewport()->height() / this->lineHeight())); + if(!m_options.hasFlag(QHexFlags::NoHeader)) + vl--; + return absolute ? vl : qMin(this->lines(), vl); +} + +qint64 QHexView::getLastColumn(qint64 line) const { + return this->getLine(line).size() - 1; +} +qint64 QHexView::lastLine() const { return qMax(0, this->lines() - 1); } + +qreal QHexView::hexColumnWidth() const { + int l = 0; + + for(auto i = 0u; i < m_options.linelength; i += m_options.grouplength) + l += (2 * m_options.grouplength) + 1; + + return this->getNCellsWidth(l); +} + +unsigned int QHexView::addressWidth() const { + if(!m_hexdocument || m_options.addresswidth) + return m_options.addresswidth; + return this->calcAddressWidth(); +} + +unsigned int QHexView::lineLength() const { return m_options.linelength; } + +bool QHexView::isModified() const { + return m_hexdocument && m_hexdocument->isModified(); +} + +bool QHexView::canUndo() const { + return m_hexdocument && m_hexdocument->canUndo(); +} + +bool QHexView::canRedo() const { + return m_hexdocument && m_hexdocument->canRedo(); +} + +quint64 QHexView::offset() const { return m_hexcursor->offset(); } +quint64 QHexView::address() const { return m_hexcursor->address(); } + +QHexPosition QHexView::positionFromOffset(quint64 offset) const { + QHexPosition opt = QHexPosition::invalid(); + + if(offset < static_cast(m_hexdocument->length())) { + opt.line = offset / m_options.linelength; + opt.column = offset % m_options.linelength; + } + + return opt; +} + +QHexPosition QHexView::positionFromAddress(quint64 address) const { + return this->positionFromOffset(address - m_options.baseaddress); +} + +QHexPosition QHexView::position() const { return m_hexcursor->position(); } + +QHexPosition QHexView::selectionStart() const { + return m_hexcursor->selectionStart(); +} + +QHexPosition QHexView::selectionEnd() const { + return m_hexcursor->selectionEnd(); +} + +quint64 QHexView::selectionStartOffset() const { + return m_hexcursor->selectionStartOffset(); +} + +quint64 QHexView::selectionEndOffset() const { + return m_hexcursor->selectionEndOffset(); +} + +quint64 QHexView::baseAddress() const { return m_options.baseaddress; } + +quint64 QHexView::lines() const { + if(!m_hexdocument) + return 0; + + auto lines = static_cast(qCeil( + m_hexdocument->length() / static_cast(m_options.linelength))); + return !m_hexdocument->isEmpty() && !lines ? 1 : lines; +} + +qint64 QHexView::replace(const QVariant& oldvalue, const QVariant& newvalue, + qint64 offset, QHexFindMode mode, unsigned int options, + QHexFindDirection fd) const { + auto res = + QHexUtils::replace(this, oldvalue, newvalue, offset, mode, options, fd); + + if(res.first > -1) { + m_hexcursor->move(res.first); + m_hexcursor->selectSize(res.second); + } + + return res.first; +} + +qint64 QHexView::find(const QVariant& value, qint64 offset, QHexFindMode mode, + unsigned int options, QHexFindDirection fd) const { + auto res = QHexUtils::find(this, value, offset, mode, options, fd); + + if(res.first > -1) { + m_hexcursor->move(res.first); + m_hexcursor->selectSize(res.second); + } + + return res.first; +} + +qreal QHexView::hexColumnX() const { + return this->getNCellsWidth(this->addressWidth() + 2); +} +qreal QHexView::asciiColumnX() const { + return this->hexColumnX() + this->hexColumnWidth() + this->cellWidth(); +} +qreal QHexView::endColumnX() const { + return this->asciiColumnX() + + this->getNCellsWidth(m_options.linelength + 1) + this->cellWidth(); +} +qreal QHexView::getNCellsWidth(int n) const { return n * this->cellWidth(); } + +qreal QHexView::cellWidth() const { +#if QT_VERSION >= QT_VERSION_CHECK(5, 11, 0) + return m_fontmetrics.horizontalAdvance(" "); +#else + return m_fontmetrics.width(" "); +#endif +} + +qreal QHexView::lineHeight() const { return m_fontmetrics.height(); } + +qint64 QHexView::positionFromLineCol(qint64 line, qint64 col) const { + if(m_hexdocument) { + return qMin((line * m_options.linelength) + col, + m_hexdocument->length()); + } + + return 0; +} + +QHexPosition QHexView::positionFromPoint(QPoint pt) const { + QHexPosition pos = QHexPosition::invalid(); + auto abspt = this->absolutePoint(pt); + + switch(this->areaFromPoint(pt)) { + case QHexArea::Hex: { + pos.column = -1; + + for(qint64 i = 0; i < m_hexcolumns.size(); i++) { + if(m_hexcolumns.at(i).left() > abspt.x()) + break; + pos.column = i; + } + + break; + } + + case QHexArea::Ascii: + pos.column = qMax( + qFloor((abspt.x() - this->asciiColumnX()) / this->cellWidth()) - + 1, + 0); + break; + case QHexArea::Address: pos.column = 0; break; + case QHexArea::Header: return QHexPosition::invalid(); + default: break; + } + + pos.line = qMin(this->verticalScrollBar()->value() + + (abspt.y() / this->lineHeight()), + this->lines()); + if(!m_options.hasFlag(QHexFlags::NoHeader)) + pos.line = qMax(0, pos.line - 1); + + auto docline = this->getLine(pos.line); + pos.column = + qMin(pos.column, docline.isEmpty() ? 0 : docline.size()); + + qhexview_fmtprint("line: %lld, col: %lld", pos.line, pos.column); + return pos; +} + +QPoint QHexView::absolutePoint(QPoint pt) const { + return pt + QPoint(this->horizontalScrollBar()->value(), 0); +} + +QHexArea QHexView::areaFromPoint(QPoint pt) const { + pt = this->absolutePoint(pt); + qreal line = + this->verticalScrollBar()->value() + pt.y() / this->lineHeight(); + + if(!m_options.hasFlag(QHexFlags::NoHeader) && !qFloor(line)) + return QHexArea::Header; + if(pt.x() < this->hexColumnX()) + return QHexArea::Address; + if(pt.x() < this->asciiColumnX()) + return QHexArea::Hex; + if(pt.x() < this->endColumnX()) + return QHexArea::Ascii; + return QHexArea::Extra; +} + +QTextCharFormat QHexView::drawFormat(QTextCursor& c, quint8 b, const QString& s, + QHexArea area, qint64 line, qint64 column, + bool applyformat) const { + QTextCharFormat cf, selcf; + QHexPosition pos{line, column}; + + if(applyformat) { + auto offset = m_hexcursor->positionToOffset(pos); + bool hasdelegate = + m_hexdelegate && m_hexdelegate->render(offset, b, cf, this); + + if(!hasdelegate) { + auto it = m_options.bytecolors.find(b); + + if(it != m_options.bytecolors.end()) { + if(it->background.isValid()) + cf.setBackground(it->background); + if(it->foreground.isValid()) + cf.setForeground(it->foreground); + } + } + + const auto* metadataline = m_hexmetadata->find(line); + + if(metadataline) { + for(const auto& metadata : *metadataline) { + if(offset < metadata.begin || offset >= metadata.end) + continue; + + if(!hasdelegate) { + if(metadata.foreground.isValid()) + cf.setForeground(metadata.foreground); + + if(metadata.background.isValid()) { + cf.setBackground(metadata.background); + + if(!metadata.foreground.isValid()) + cf.setForeground( + this->getReadableColor(metadata.background)); + } + } + + if(!metadata.comment.isEmpty()) { + cf.setUnderlineColor( + m_options.commentcolor.isValid() + ? m_options.commentcolor + : this->palette().color(QPalette::WindowText)); + cf.setUnderlineStyle( + QTextCharFormat::UnderlineStyle::SingleUnderline); + } + + if(offset == metadata.begin) // Remove previous metadata's + // style, if needed + { + if(metadata.comment.isEmpty()) + selcf.setUnderlineStyle( + QTextCharFormat::UnderlineStyle::NoUnderline); + if(!metadata.foreground.isValid()) + selcf.setForeground(Qt::color1); + if(!metadata.background.isValid()) + selcf.setBackground(Qt::transparent); + } + + if(offset < metadata.end - 1 && + column < this->getLastColumn(line)) + selcf = cf; + } + } + + if(hasdelegate && column < this->getLastColumn(line)) + selcf = cf; + } + + if(this->hexCursor()->isSelected(line, column)) { + auto offset = this->hexCursor()->positionToOffset(pos); + auto selend = this->hexCursor()->selectionEndOffset(); + + cf.setBackground( + this->palette().color(QPalette::Normal, QPalette::Highlight)); + cf.setForeground( + this->palette().color(QPalette::Normal, QPalette::HighlightedText)); + if(offset < selend && column < this->getLastColumn(line)) + selcf = cf; + } + + if(this->hexCursor()->position() == pos) { + auto cursorbg = this->palette().color( + this->hasFocus() ? QPalette::Normal : QPalette::Disabled, + QPalette::WindowText); + auto cursorfg = this->palette().color( + this->hasFocus() ? QPalette::Normal : QPalette::Disabled, + QPalette::Base); + auto discursorbg = + this->palette().color(QPalette::Disabled, QPalette::WindowText); + auto discursorfg = + this->palette().color(QPalette::Disabled, QPalette::Base); + + switch(m_hexcursor->mode()) { + case QHexCursor::Mode::Insert: + cf.setUnderlineColor(m_currentarea == area ? cursorbg + : discursorbg); + cf.setUnderlineStyle( + QTextCharFormat::UnderlineStyle::SingleUnderline); + break; + + case QHexCursor::Mode::Overwrite: + cf.setBackground(m_currentarea == area ? cursorbg + : discursorbg); + cf.setForeground(m_currentarea == area ? cursorfg + : discursorfg); + break; + } + } + + c.insertText(s, cf); + return selcf; +} + +void QHexView::moveNext(bool select) { + auto line = this->hexCursor()->line(), column = this->hexCursor()->column(); + + if(column >= m_options.linelength - 1) { + line++; + column = 0; + } + else + column++; + + qint64 offset = + this->hexCursor()->mode() == QHexCursor::Mode::Insert ? 1 : 0; + if(select) + this->hexCursor()->select( + qMin(line, this->lines()), + qMin(column, this->getLastColumn(line) + offset)); + else + this->hexCursor()->move( + qMin(line, this->lines()), + qMin(column, this->getLastColumn(line) + offset)); +} + +void QHexView::movePrevious(bool select) { + auto line = this->hexCursor()->line(), column = this->hexCursor()->column(); + + if(column <= 0) { + if(!line) + return; + column = this->getLine(--line).size() - 1; + } + else + column--; + + if(select) + this->hexCursor()->select( + qMin(line, this->lines()), + qMin(column, this->getLastColumn(line))); + else + this->hexCursor()->move( + qMin(line, this->lines()), + qMin(column, this->getLastColumn(line))); +} + +bool QHexView::keyPressMove(QKeyEvent* e) { + if(e->matches(QKeySequence::MoveToNextChar) || + e->matches(QKeySequence::SelectNextChar)) + this->moveNext(e->matches(QKeySequence::SelectNextChar)); + else if(e->matches(QKeySequence::MoveToPreviousChar) || + e->matches(QKeySequence::SelectPreviousChar)) + this->movePrevious(e->matches(QKeySequence::SelectPreviousChar)); + else if(e->matches(QKeySequence::MoveToNextLine) || + e->matches(QKeySequence::SelectNextLine)) { + if(this->hexCursor()->line() == this->lastLine()) + return true; + auto nextline = this->hexCursor()->line() + 1; + if(e->matches(QKeySequence::MoveToNextLine)) + this->hexCursor()->move(nextline, this->hexCursor()->column()); + else + this->hexCursor()->select(nextline, this->hexCursor()->column()); + } + else if(e->matches(QKeySequence::MoveToPreviousLine) || + e->matches(QKeySequence::SelectPreviousLine)) { + if(!this->hexCursor()->line()) + return true; + auto prevline = this->hexCursor()->line() - 1; + if(e->matches(QKeySequence::MoveToPreviousLine)) + this->hexCursor()->move(prevline, this->hexCursor()->column()); + else + this->hexCursor()->select(prevline, this->hexCursor()->column()); + } + else if(e->matches(QKeySequence::MoveToNextPage) || + e->matches(QKeySequence::SelectNextPage)) { + if(this->lastLine() == this->hexCursor()->line()) + return true; + auto pageline = qMin(this->lastLine(), + this->hexCursor()->line() + this->visibleLines()); + if(e->matches(QKeySequence::MoveToNextPage)) + this->hexCursor()->move(pageline, this->hexCursor()->column()); + else + this->hexCursor()->select(pageline, this->hexCursor()->column()); + } + else if(e->matches(QKeySequence::MoveToPreviousPage) || + e->matches(QKeySequence::SelectPreviousPage)) { + if(!this->hexCursor()->line()) + return true; + auto pageline = + qMax(0, this->hexCursor()->line() - this->visibleLines()); + if(e->matches(QKeySequence::MoveToPreviousPage)) + this->hexCursor()->move(pageline, this->hexCursor()->column()); + else + this->hexCursor()->select(pageline, this->hexCursor()->column()); + } + else if(e->matches(QKeySequence::MoveToStartOfDocument) || + e->matches(QKeySequence::SelectStartOfDocument)) { + if(!this->hexCursor()->line()) + return true; + if(e->matches(QKeySequence::MoveToStartOfDocument)) + this->hexCursor()->move(0, 0); + else + this->hexCursor()->select(0, 0); + } + else if(e->matches(QKeySequence::MoveToEndOfDocument) || + e->matches(QKeySequence::SelectEndOfDocument)) { + if(this->lastLine() == this->hexCursor()->line()) + return true; + if(e->matches(QKeySequence::MoveToEndOfDocument)) + this->hexCursor()->move( + this->lastLine(), + this->getLastColumn(this->hexCursor()->line())); + else + this->hexCursor()->select(this->lastLine(), + this->getLastColumn(this->lastLine())); + } + else if(e->matches(QKeySequence::MoveToStartOfLine) || + e->matches(QKeySequence::SelectStartOfLine)) { + auto offset = + this->hexCursor()->positionToOffset({this->hexCursor()->line(), 0}); + if(e->matches(QKeySequence::MoveToStartOfLine)) + this->hexCursor()->move(offset); + else + this->hexCursor()->select(offset); + } + else if(e->matches(QKeySequence::SelectEndOfLine) || + e->matches(QKeySequence::MoveToEndOfLine)) { + auto offset = this->hexCursor()->positionToOffset( + {this->hexCursor()->line(), + this->getLastColumn(this->hexCursor()->line())}); + if(e->matches(QKeySequence::SelectEndOfLine)) + this->hexCursor()->select(offset); + else + this->hexCursor()->move(offset); + } + else + return false; + + return true; +} + +bool QHexView::keyPressTextInput(QKeyEvent* e) { + if(m_readonly || e->text().isEmpty() || + (e->modifiers() & Qt::ControlModifier)) + return false; + + bool atend = m_hexcursor->offset() >= m_hexdocument->length(); + if(atend && m_hexcursor->mode() == QHexCursor::Mode::Overwrite) + return false; + + char key = e->text().at(0).toLatin1(); + + switch(m_currentarea) { + case QHexArea::Hex: { + if(!QHexUtils::isHex(key)) + return false; + + bool ok = false; + auto val = static_cast(QString(key).toUInt(&ok, 16)); + if(!ok) + return false; + m_hexcursor->removeSelection(); + + quint8 ch = m_hexdocument->isEmpty() || + m_hexcursor->offset() >= m_hexdocument->length() + ? '\x00' + : m_hexdocument->at(m_hexcursor->offset()); + ch = m_writing ? (ch << 4) | val : val; + + if(!m_writing && (m_hexcursor->mode() == QHexCursor::Mode::Insert)) + m_hexdocument->insert(m_hexcursor->offset(), val); + else + m_hexdocument->replace(m_hexcursor->offset(), ch); + + m_writing = !m_writing; + if(!m_writing) + this->moveNext(); + + break; + } + + case QHexArea::Ascii: { + if(!QChar::isPrint(key)) + return false; + m_hexcursor->removeSelection(); + if(m_hexcursor->mode() == QHexCursor::Mode::Insert) + m_hexdocument->insert(m_hexcursor->offset(), key); + else + m_hexdocument->replace(m_hexcursor->offset(), key); + this->moveNext(); + break; + } + + default: return false; + } + + return true; +} + +bool QHexView::keyPressAction(QKeyEvent* e) { + if(e->modifiers() != Qt::NoModifier) { + if(e->matches(QKeySequence::SelectAll)) + this->selectAll(); + else if(!m_readonly && e->matches(QKeySequence::Undo)) + this->undo(); + else if(!m_readonly && e->matches(QKeySequence::Redo)) + this->redo(); + else if(!m_readonly && e->matches(QKeySequence::Cut)) + this->cut(m_currentarea != QHexArea::Ascii); + else if(e->matches(QKeySequence::Copy)) + this->copy(m_currentarea != QHexArea::Ascii); + else if(!m_readonly && e->matches(QKeySequence::Paste)) + this->paste(m_currentarea != QHexArea::Ascii); + else + return false; + + return true; + } + + if(m_readonly) + return false; + + switch(e->key()) { + case Qt::Key_Backspace: + case Qt::Key_Delete: { + if(!m_hexcursor->hasSelection()) { + auto offset = m_hexcursor->offset(); + if(offset <= 0) + return true; + + if(e->key() == Qt::Key_Backspace) + m_hexdocument->remove(offset - 1, 1); + else + m_hexdocument->remove(offset, 1); + } + else { + auto oldpos = m_hexcursor->selectionStart(); + m_hexcursor->removeSelection(); + m_hexcursor->move(oldpos); + } + + if(e->key() == Qt::Key_Backspace) + this->movePrevious(); + m_writing = false; + break; + } + + case Qt::Key_Insert: + m_writing = false; + m_hexcursor->switchMode(); + break; + + default: return false; + } + + return true; +} + +bool QHexView::event(QEvent* e) { + switch(e->type()) { + case QEvent::FontChange: + m_fontmetrics = QFontMetricsF(this->font()); + this->checkAndUpdate(true); + return true; + + case QEvent::ToolTip: { + if(m_hexdocument && (m_currentarea == QHexArea::Hex || + m_currentarea == QHexArea::Ascii)) { + auto* helpevent = static_cast(e); + auto pos = this->positionFromPoint(helpevent->pos()); + auto comment = m_hexmetadata->getComment(pos.line, pos.column); + if(!comment.isEmpty()) + QToolTip::showText(helpevent->globalPos(), comment); + return true; + } + + break; + } + + default: break; + } + + return QAbstractScrollArea::event(e); +} + +void QHexView::showEvent(QShowEvent* e) { + QAbstractScrollArea::showEvent(e); + this->checkAndUpdate(true); +} + +void QHexView::paintEvent(QPaintEvent*) { + if(!m_hexdocument) + return; + + QPainter painter(this->viewport()); + if(m_hexdelegate) + m_hexdelegate->paint(&painter, this); + else + this->paint(&painter); +} + +void QHexView::resizeEvent(QResizeEvent* e) { + this->checkState(); + QAbstractScrollArea::resizeEvent(e); +} + +void QHexView::focusInEvent(QFocusEvent* e) { + QAbstractScrollArea::focusInEvent(e); + if(m_hexdocument) + this->viewport()->update(); +} + +void QHexView::focusOutEvent(QFocusEvent* e) { + QAbstractScrollArea::focusOutEvent(e); + if(m_hexdocument) + this->viewport()->update(); +} + +void QHexView::mousePressEvent(QMouseEvent* e) { + QAbstractScrollArea::mousePressEvent(e); + if(!m_hexdocument || e->button() != Qt::LeftButton) + return; + + auto pos = this->positionFromPoint(e->pos()); + if(!pos.isValid()) + return; + + auto area = this->areaFromPoint(e->pos()); + qhexview_fmtprint("%d", static_cast(area)); + + switch(area) { + case QHexArea::Address: this->hexCursor()->move(pos.line, 0); break; + case QHexArea::Hex: + m_currentarea = area; + this->hexCursor()->move(pos); + break; + case QHexArea::Ascii: + m_currentarea = area; + this->hexCursor()->move(pos.line, pos.column); + break; + default: return; + } + + this->viewport()->update(); +} + +void QHexView::mouseMoveEvent(QMouseEvent* e) { + QAbstractScrollArea::mouseMoveEvent(e); + if(!this->hexCursor()) + return; + + e->accept(); + auto area = this->areaFromPoint(e->pos()); + + switch(area) { + case QHexArea::Header: + this->viewport()->setCursor(Qt::ArrowCursor); + return; + case QHexArea::Address: + this->viewport()->setCursor(Qt::ArrowCursor); + break; + default: this->viewport()->setCursor(Qt::IBeamCursor); break; + } + + if(e->buttons() == Qt::LeftButton) { + auto pos = this->positionFromPoint(e->pos()); + if(!pos.isValid()) + return; + if(area == QHexArea::Ascii || area == QHexArea::Hex) + m_currentarea = area; + this->hexCursor()->select(pos); + } +} + +void QHexView::wheelEvent(QWheelEvent* e) { + e->ignore(); + +#if defined(Q_OS_OSX) + // In macOS scrollbar invisibility should not prevent scrolling from working + if(!m_hexdocument) + return; +#else + if(!m_hexdocument || !this->verticalScrollBar()->isVisible()) + return; +#endif + + // https://doc.qt.io/qt-6/qwheelevent.html + // "Returns the relative amount that the wheel was rotated, in eighths of a + // degree." "Most mouse types work in steps of 15 degrees, in which case the + // delta value is a multiple of 120; i.e., 120 units * 1/8 = 15 degrees." + int const ydelta = e->angleDelta().y(); + if(0 != ydelta) { + int const ydeltaAbsolute = qAbs(ydelta); + int const numberOfLinesToMove = + (ydeltaAbsolute * m_options.scrollsteps + 119) / + 120; // always move at least 1 line + int const ydeltaSign = ydelta / ydeltaAbsolute; + + int const oldValue = this->verticalScrollBar()->value(); + int const newValue = oldValue - ydeltaSign * numberOfLinesToMove; + this->verticalScrollBar()->setValue(newValue); + } +} + +void QHexView::keyPressEvent(QKeyEvent* e) { + bool handled = false; + + if(this->hexCursor()) { + handled = this->keyPressMove(e); + if(!handled) + handled = this->keyPressAction(e); + if(!handled) + handled = this->keyPressTextInput(e); + } + + if(handled) + e->accept(); + else + QAbstractScrollArea::keyPressEvent(e); +} + +QString QHexView::reduced(const QString& s, int maxlen) { + if(s.length() <= maxlen) + return s.leftJustified(maxlen); + return s.mid(0, maxlen - 1) + "\u2026"; +} + +bool QHexView::isColorLight(QColor c) { + return std::sqrt(0.299 * std::pow(c.red(), 2) + + 0.587 * std::pow(c.green(), 2) + + 0.114 * std::pow(c.blue(), 2)) > 127.5; +} + +QColor QHexView::getReadableColor(QColor c) const { + QPalette palette = this->palette(); + return QHexView::isColorLight(c) + ? palette.color(QPalette::Normal, QPalette::WindowText) + : palette.color(QPalette::Normal, QPalette::HighlightedText); +} + +QByteArray QHexView::selectedBytes() const { + return m_hexcursor->hasSelection() + ? m_hexdocument->read(m_hexcursor->selectionStartOffset(), + m_hexcursor->selectionLength()) + : QByteArray{}; +} +QByteArray QHexView::getLine(qint64 line) const { + return m_hexdocument ? m_hexdocument->read(line * m_options.linelength, + m_options.linelength) + : QByteArray{}; +} diff --git a/UEFITool/ffsfinder.cpp b/UEFITool/ffsfinder.cpp index 8cab34d..51a2f0e 100644 --- a/UEFITool/ffsfinder.cpp +++ b/UEFITool/ffsfinder.cpp @@ -19,6 +19,14 @@ #include #endif +USTATUS FfsFinder::findHexPattern(const UByteArray & hexPattern, const UINT8 mode) { + const UModelIndex rootIndex = model->index(0, 0); + USTATUS ret = findHexPattern(rootIndex, hexPattern, mode); + if (ret != U_SUCCESS) + msg(UString("Hex pattern \"") + UString(hexPattern) + UString("\" could not be found"), rootIndex); + return ret; +} + USTATUS FfsFinder::findHexPattern(const UModelIndex & index, const UByteArray & hexPattern, const UINT8 mode) { if (!index.isValid()) @@ -31,9 +39,11 @@ USTATUS FfsFinder::findHexPattern(const UModelIndex & index, const UByteArray & if (hexPattern.count('.') == hexPattern.length()) return U_SUCCESS; + USTATUS ret = U_ITEM_NOT_FOUND; bool hasChildren = (model->rowCount(index) > 0); for (int i = 0; i < model->rowCount(index); i++) { - findHexPattern(index.model()->index(i, index.column(), index), hexPattern, mode); + if (U_SUCCESS == findHexPattern(index.model()->index(i, index.column(), index), hexPattern, mode)) + ret = U_SUCCESS; } UByteArray data; @@ -83,6 +93,7 @@ USTATUS FfsFinder::findHexPattern(const UModelIndex & index, const UByteArray & + UString("\" in ") + name + usprintf(" at %s-offset %02Xh", mode == SEARCH_MODE_BODY ? "body" : "header", offset / 2), index); + ret = U_SUCCESS; } } @@ -93,7 +104,15 @@ USTATUS FfsFinder::findHexPattern(const UModelIndex & index, const UByteArray & #endif } - return U_SUCCESS; + return ret; +} + +USTATUS FfsFinder::findGuidPattern(const UByteArray & guidPattern, const UINT8 mode) { + const UModelIndex rootIndex = model->index(0, 0); + USTATUS ret = findGuidPattern(rootIndex, guidPattern, mode); + if (ret != U_SUCCESS) + msg(UString("GUID pattern \"") + UString(guidPattern) + UString("\" could not be found"), rootIndex); + return ret; } USTATUS FfsFinder::findGuidPattern(const UModelIndex & index, const UByteArray & guidPattern, const UINT8 mode) @@ -104,9 +123,11 @@ USTATUS FfsFinder::findGuidPattern(const UModelIndex & index, const UByteArray & if (!index.isValid()) return U_SUCCESS; + USTATUS ret = U_ITEM_NOT_FOUND; bool hasChildren = (model->rowCount(index) > 0); for (int i = 0; i < model->rowCount(index); i++) { - findGuidPattern(index.model()->index(i, index.column(), index), guidPattern, mode); + if (U_SUCCESS == findGuidPattern(index.model()->index(i, index.column(), index), guidPattern, mode)) + ret = U_SUCCESS; } UByteArray data; @@ -174,6 +195,7 @@ USTATUS FfsFinder::findGuidPattern(const UModelIndex & index, const UByteArray & + UString("\" in ") + name + usprintf(" at %s-offset %02Xh", mode == SEARCH_MODE_BODY ? "body" : "header", offset / 2), index); + ret = U_SUCCESS; } #if QT_VERSION_MAJOR >= 6 @@ -183,7 +205,16 @@ USTATUS FfsFinder::findGuidPattern(const UModelIndex & index, const UByteArray & #endif } - return U_SUCCESS; + return ret; +} + +USTATUS FfsFinder::findTextPattern(const UString & pattern, const UINT8 mode, const bool unicode, const Qt::CaseSensitivity caseSensitive) { + const UModelIndex rootIndex = model->index(0, 0); + USTATUS ret = findTextPattern(rootIndex, pattern, mode, unicode, caseSensitive); + if (ret != U_SUCCESS) + msg((unicode ? UString("Unicode") : UString("ASCII")) + UString(" text \"") + + UString(pattern) + UString("\" could not be found"), rootIndex); + return ret; } USTATUS FfsFinder::findTextPattern(const UModelIndex & index, const UString & pattern, const UINT8 mode, const bool unicode, const Qt::CaseSensitivity caseSensitive) @@ -194,9 +225,11 @@ USTATUS FfsFinder::findTextPattern(const UModelIndex & index, const UString & pa if (!index.isValid()) return U_SUCCESS; + USTATUS ret = U_ITEM_NOT_FOUND; bool hasChildren = (model->rowCount(index) > 0); for (int i = 0; i < model->rowCount(index); i++) { - findTextPattern(index.model()->index(i, index.column(), index), pattern, mode, unicode, caseSensitive); + if (U_SUCCESS == findTextPattern(index.model()->index(i, index.column(), index), pattern, mode, unicode, caseSensitive)) + ret = U_SUCCESS; } UByteArray body; @@ -236,7 +269,8 @@ USTATUS FfsFinder::findTextPattern(const UModelIndex & index, const UString & pa + UString("\" found in ") + name + usprintf(" at %s-offset %02Xh", mode == SEARCH_MODE_BODY ? "body" : "header", offset), index); + ret = U_SUCCESS; } - return U_SUCCESS; + return ret; } diff --git a/UEFITool/ffsfinder.h b/UEFITool/ffsfinder.h index d9ea2b1..059f376 100644 --- a/UEFITool/ffsfinder.h +++ b/UEFITool/ffsfinder.h @@ -30,9 +30,9 @@ public: std::vector > getMessages() const { return messagesVector; } void clearMessages() { messagesVector.clear(); } - USTATUS findHexPattern(const UModelIndex & index, const UByteArray & hexPattern, const UINT8 mode); - USTATUS findGuidPattern(const UModelIndex & index, const UByteArray & guidPattern, const UINT8 mode); - USTATUS findTextPattern(const UModelIndex & index, const UString & pattern, const UINT8 mode, const bool unicode, const Qt::CaseSensitivity caseSensitive); + USTATUS findHexPattern(const UByteArray & hexPattern, const UINT8 mode); + USTATUS findGuidPattern(const UByteArray & guidPattern, const UINT8 mode); + USTATUS findTextPattern(const UString & pattern, const UINT8 mode, const bool unicode, const Qt::CaseSensitivity caseSensitive); private: const TreeModel* model; @@ -41,6 +41,10 @@ private: void msg(const UString & message, const UModelIndex &index = UModelIndex()) { messagesVector.push_back(std::pair(message, index)); } + + USTATUS findHexPattern(const UModelIndex & index, const UByteArray & hexPattern, const UINT8 mode); + USTATUS findGuidPattern(const UModelIndex & index, const UByteArray & guidPattern, const UINT8 mode); + USTATUS findTextPattern(const UModelIndex & index, const UString & pattern, const UINT8 mode, const bool unicode, const Qt::CaseSensitivity caseSensitive); }; #endif // FFSFINDER_H diff --git a/UEFITool/gotoaddressdialog.h b/UEFITool/gotoaddressdialog.h index 403c6e7..1d2948a 100644 --- a/UEFITool/gotoaddressdialog.h +++ b/UEFITool/gotoaddressdialog.h @@ -1,3 +1,16 @@ +/* gotoaddressdialog.h + + Copyright (c) 2018, Nikolaj Schlej. All rights reserved. + This program and the accompanying materials + are licensed and made available under the terms and conditions of the BSD License + which accompanies this distribution. The full text of the license may be found at + http://opensource.org/licenses/bsd-license.php + + THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, + WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. + + */ + #ifndef GOTOADDRESSDIALOG_H #define GOTOADDRESSDIALOG_H diff --git a/UEFITool/gotobasedialog.h b/UEFITool/gotobasedialog.h index 8023e86..806eedf 100644 --- a/UEFITool/gotobasedialog.h +++ b/UEFITool/gotobasedialog.h @@ -1,3 +1,16 @@ +/* gotobasedialog.h + + Copyright (c) 2018, Nikolaj Schlej. All rights reserved. + This program and the accompanying materials + are licensed and made available under the terms and conditions of the BSD License + which accompanies this distribution. The full text of the license may be found at + http://opensource.org/licenses/bsd-license.php + + THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, + WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. + + */ + #ifndef GOTOBASEDIALOG_H #define GOTOBASEDIALOG_H diff --git a/UEFITool/hexviewdialog.h b/UEFITool/hexviewdialog.h index 9a0e138..18eaacc 100644 --- a/UEFITool/hexviewdialog.h +++ b/UEFITool/hexviewdialog.h @@ -15,8 +15,8 @@ #define HEXVIEWDIALOG_H #include +#include #include "../common/treemodel.h" -#include "qhexview5/qhexview.h" #include "ui_hexviewdialog.h" class HexViewDialog : public QDialog diff --git a/UEFITool/qhexview5/model/buffer/qdevicebuffer.h b/UEFITool/qhexview5/model/buffer/qdevicebuffer.h deleted file mode 100644 index 0115c67..0000000 --- a/UEFITool/qhexview5/model/buffer/qdevicebuffer.h +++ /dev/null @@ -1,25 +0,0 @@ -#pragma once - -#include "qhexbuffer.h" - -class QDeviceBuffer : public QHexBuffer -{ - Q_OBJECT - - public: - explicit QDeviceBuffer(QObject *parent = nullptr); - virtual ~QDeviceBuffer(); - uchar at(qint64 idx) override; - qint64 length() const override; - void insert(qint64 offset, const QByteArray& data) override; - void replace(qint64 offset, const QByteArray& data) override; - void remove(qint64 offset, int length) override; - QByteArray read(qint64 offset, int length) override; - bool read(QIODevice* device) override; - void write(QIODevice* device) override; - qint64 indexOf(const QByteArray& ba, qint64 from) override; - qint64 lastIndexOf(const QByteArray& ba, qint64 from) override; - - protected: - QIODevice* m_device{nullptr}; -}; diff --git a/UEFITool/qhexview5/model/buffer/qhexbuffer.h b/UEFITool/qhexview5/model/buffer/qhexbuffer.h deleted file mode 100644 index c00bbbd..0000000 --- a/UEFITool/qhexview5/model/buffer/qhexbuffer.h +++ /dev/null @@ -1,30 +0,0 @@ -#pragma once - -#include -#include - -class QHexBuffer : public QObject -{ - Q_OBJECT - - public: - explicit QHexBuffer(QObject *parent = nullptr); - bool isEmpty() const; - - public: - virtual uchar at(qint64 idx); - virtual void replace(qint64 offset, const QByteArray& data); - virtual void read(char* data, int size); - virtual void read(const QByteArray& ba); - - public: - virtual qint64 length() const = 0; - virtual void insert(qint64 offset, const QByteArray& data) = 0; - virtual void remove(qint64 offset, int length) = 0; - virtual QByteArray read(qint64 offset, int length) = 0; - virtual bool read(QIODevice* iodevice) = 0; - virtual void write(QIODevice* iodevice) = 0; - virtual qint64 indexOf(const QByteArray& ba, qint64 from) = 0; - virtual qint64 lastIndexOf(const QByteArray& ba, qint64 from) = 0; - -}; diff --git a/UEFITool/qhexview5/model/buffer/qmemorybuffer.cpp b/UEFITool/qhexview5/model/buffer/qmemorybuffer.cpp deleted file mode 100644 index b0d6a02..0000000 --- a/UEFITool/qhexview5/model/buffer/qmemorybuffer.cpp +++ /dev/null @@ -1,19 +0,0 @@ -#include "qmemorybuffer.h" -#include - -QMemoryBuffer::QMemoryBuffer(QObject *parent) : QHexBuffer{parent} { } -uchar QMemoryBuffer::at(qint64 idx) { return static_cast(m_buffer.at(idx)); } -qint64 QMemoryBuffer::length() const { return static_cast(m_buffer.length()); } -void QMemoryBuffer::insert(qint64 offset, const QByteArray &data) { m_buffer.insert(static_cast(offset), data); } -void QMemoryBuffer::remove(qint64 offset, int length) { m_buffer.remove(static_cast(offset), length); } -QByteArray QMemoryBuffer::read(qint64 offset, int length) { return m_buffer.mid(static_cast(offset), length); } - -bool QMemoryBuffer::read(QIODevice *device) -{ - m_buffer = device->readAll(); - return true; -} - -void QMemoryBuffer::write(QIODevice *device) { device->write(m_buffer); } -qint64 QMemoryBuffer::indexOf(const QByteArray& ba, qint64 from) { return m_buffer.indexOf(ba, static_cast(from)); } -qint64 QMemoryBuffer::lastIndexOf(const QByteArray& ba, qint64 from) { return m_buffer.lastIndexOf(ba, static_cast(from)); } diff --git a/UEFITool/qhexview5/model/buffer/qmemorybuffer.h b/UEFITool/qhexview5/model/buffer/qmemorybuffer.h deleted file mode 100644 index 4e096d2..0000000 --- a/UEFITool/qhexview5/model/buffer/qmemorybuffer.h +++ /dev/null @@ -1,23 +0,0 @@ -#pragma once - -#include "qhexbuffer.h" - -class QMemoryBuffer : public QHexBuffer -{ - Q_OBJECT - - public: - explicit QMemoryBuffer(QObject *parent = nullptr); - uchar at(qint64 idx) override; - qint64 length() const override; - void insert(qint64 offset, const QByteArray& data) override; - void remove(qint64 offset, int length) override; - QByteArray read(qint64 offset, int length) override; - bool read(QIODevice* device) override; - void write(QIODevice* device) override; - qint64 indexOf(const QByteArray& ba, qint64 from) override; - qint64 lastIndexOf(const QByteArray& ba, qint64 from) override; - - private: - QByteArray m_buffer; -}; diff --git a/UEFITool/qhexview5/model/commands/hexcommand.cpp b/UEFITool/qhexview5/model/commands/hexcommand.cpp deleted file mode 100644 index c4ca0ff..0000000 --- a/UEFITool/qhexview5/model/commands/hexcommand.cpp +++ /dev/null @@ -1,3 +0,0 @@ -#include "hexcommand.h" - -HexCommand::HexCommand(QHexBuffer *buffer, QHexDocument* document, QUndoCommand *parent): QUndoCommand(parent), m_hexdocument(document), m_buffer(buffer), m_offset(0), m_length(0) { } diff --git a/UEFITool/qhexview5/model/commands/hexcommand.h b/UEFITool/qhexview5/model/commands/hexcommand.h deleted file mode 100644 index f43c758..0000000 --- a/UEFITool/qhexview5/model/commands/hexcommand.h +++ /dev/null @@ -1,19 +0,0 @@ -#pragma once - -#include -#include "../buffer/qhexbuffer.h" - -class QHexDocument; - -class HexCommand: public QUndoCommand -{ - public: - HexCommand(QHexBuffer* buffer, QHexDocument* document, QUndoCommand* parent = nullptr); - - protected: - QHexDocument* m_hexdocument; - QHexBuffer* m_buffer; - qint64 m_offset; - int m_length; - QByteArray m_data; -}; diff --git a/UEFITool/qhexview5/model/commands/insertcommand.cpp b/UEFITool/qhexview5/model/commands/insertcommand.cpp deleted file mode 100644 index 122dbb8..0000000 --- a/UEFITool/qhexview5/model/commands/insertcommand.cpp +++ /dev/null @@ -1,16 +0,0 @@ -#include "insertcommand.h" -#include "../qhexdocument.h" - -InsertCommand::InsertCommand(QHexBuffer *buffer, QHexDocument* document, qint64 offset, const QByteArray &data, QUndoCommand *parent): HexCommand(buffer, document, parent) -{ - m_offset = offset; - m_data = data; -} - -void InsertCommand::undo() -{ - m_buffer->remove(m_offset, m_data.length()); - Q_EMIT m_hexdocument->dataChanged(m_data, m_offset, QHexDocument::ChangeReason::Remove); -} - -void InsertCommand::redo() { m_buffer->insert(m_offset, m_data); } diff --git a/UEFITool/qhexview5/model/commands/insertcommand.h b/UEFITool/qhexview5/model/commands/insertcommand.h deleted file mode 100644 index f1394a8..0000000 --- a/UEFITool/qhexview5/model/commands/insertcommand.h +++ /dev/null @@ -1,11 +0,0 @@ -#pragma once - -#include "hexcommand.h" - -class InsertCommand: public HexCommand -{ - public: - InsertCommand(QHexBuffer* buffer, QHexDocument* document, qint64 offset, const QByteArray& data, QUndoCommand* parent = nullptr); - void undo() override; - void redo() override; -}; diff --git a/UEFITool/qhexview5/model/commands/removecommand.cpp b/UEFITool/qhexview5/model/commands/removecommand.cpp deleted file mode 100644 index 42fe553..0000000 --- a/UEFITool/qhexview5/model/commands/removecommand.cpp +++ /dev/null @@ -1,20 +0,0 @@ -#include "removecommand.h" -#include "../qhexdocument.h" - -RemoveCommand::RemoveCommand(QHexBuffer *buffer, QHexDocument* document, qint64 offset, int length, QUndoCommand *parent): HexCommand(buffer, document, parent) -{ - m_offset = offset; - m_length = length; -} - -void RemoveCommand::undo() -{ - m_buffer->insert(m_offset, m_data); - Q_EMIT m_hexdocument->dataChanged(m_data, m_offset, QHexDocument::ChangeReason::Insert); -} - -void RemoveCommand::redo() -{ - m_data = m_buffer->read(m_offset, m_length); // Backup data - m_buffer->remove(m_offset, m_length); -} diff --git a/UEFITool/qhexview5/model/commands/removecommand.h b/UEFITool/qhexview5/model/commands/removecommand.h deleted file mode 100644 index e707e6c..0000000 --- a/UEFITool/qhexview5/model/commands/removecommand.h +++ /dev/null @@ -1,11 +0,0 @@ -#pragma once - -#include "hexcommand.h" - -class RemoveCommand: public HexCommand -{ - public: - RemoveCommand(QHexBuffer* buffer, QHexDocument* document, qint64 offset, int length, QUndoCommand* parent = nullptr); - void undo() override; - void redo() override; -}; diff --git a/UEFITool/qhexview5/model/commands/replacecommand.cpp b/UEFITool/qhexview5/model/commands/replacecommand.cpp deleted file mode 100644 index 6e0ec93..0000000 --- a/UEFITool/qhexview5/model/commands/replacecommand.cpp +++ /dev/null @@ -1,20 +0,0 @@ -#include "replacecommand.h" -#include "../qhexdocument.h" - -ReplaceCommand::ReplaceCommand(QHexBuffer *buffer, QHexDocument* document, qint64 offset, const QByteArray &data, QUndoCommand *parent): HexCommand(buffer, document, parent) -{ - m_offset = offset; - m_data = data; -} - -void ReplaceCommand::undo() -{ - m_buffer->replace(m_offset, m_olddata); - Q_EMIT m_hexdocument->dataChanged(m_olddata, m_offset, QHexDocument::ChangeReason::Replace); -} - -void ReplaceCommand::redo() -{ - m_olddata = m_buffer->read(m_offset, m_data.length()); - m_buffer->replace(m_offset, m_data); -} diff --git a/UEFITool/qhexview5/model/commands/replacecommand.h b/UEFITool/qhexview5/model/commands/replacecommand.h deleted file mode 100644 index c4a2418..0000000 --- a/UEFITool/qhexview5/model/commands/replacecommand.h +++ /dev/null @@ -1,14 +0,0 @@ -#pragma once - -#include "hexcommand.h" - -class ReplaceCommand: public HexCommand -{ - public: - ReplaceCommand(QHexBuffer* buffer, QHexDocument* document, qint64 offset, const QByteArray& data, QUndoCommand* parent = nullptr); - void undo() override; - void redo() override; - - private: - QByteArray m_olddata; -}; diff --git a/UEFITool/qhexview5/model/qhexcursor.cpp b/UEFITool/qhexview5/model/qhexcursor.cpp deleted file mode 100644 index 6042128..0000000 --- a/UEFITool/qhexview5/model/qhexcursor.cpp +++ /dev/null @@ -1,129 +0,0 @@ -#include "../qhexview.h" -#include "qhexcursor.h" -#include "qhexdocument.h" - -/* - * https://stackoverflow.com/questions/10803043/inverse-column-row-major-order-transformation - * - * If the index is calculated as: - * offset = row + column*NUMROWS - * then the inverse would be: - * row = offset % NUMROWS - * column = offset / NUMROWS - * where % is modulus, and / is integer division. - */ - -QHexCursor::QHexCursor(const QHexOptions* options, QHexView* parent) : QObject(parent), m_options(options) { } -QHexView* QHexCursor::hexView() const { return qobject_cast(this->parent()); } -QHexCursor::Mode QHexCursor::mode() const { return m_mode; } -qint64 QHexCursor::offset() const { return this->positionToOffset(m_position); } -qint64 QHexCursor::address() const { return m_options->baseaddress + this->offset(); } -quint64 QHexCursor::lineAddress() const { return m_options->baseaddress + (m_position.line * m_options->linelength); } -qint64 QHexCursor::selectionStartOffset() const { return this->positionToOffset(this->selectionStart()); } -qint64 QHexCursor::selectionEndOffset() const { return this->positionToOffset(this->selectionEnd()); } -qint64 QHexCursor::line() const { return m_position.line; } -qint64 QHexCursor::column() const { return m_position.column; } - -QHexPosition QHexCursor::selectionStart() const -{ - if(m_position.line < m_selection.line) - return m_position; - - if(m_position.line == m_selection.line) - { - if(m_position.column < m_selection.column) - return m_position; - } - - return m_selection; -} - -QHexPosition QHexCursor::selectionEnd() const -{ - if(m_position.line > m_selection.line) - return m_position; - - if(m_position.line == m_selection.line) - { - if(m_position.column > m_selection.column) - return m_position; - } - - return m_selection; -} - -qint64 QHexCursor::selectionLength() const -{ - auto selstart = this->selectionStartOffset(), selend = this->selectionEndOffset(); - return selstart == selend ? 0 : selend - selstart + 1; -} - -QHexPosition QHexCursor::position() const { return m_position; } -QByteArray QHexCursor::selectedBytes() const { return this->hexView()->selectedBytes(); } -bool QHexCursor::hasSelection() const { return m_position != m_selection; } - -bool QHexCursor::isSelected(qint64 line, qint64 column) const -{ - if(!this->hasSelection()) return false; - - auto selstart = this->selectionStart(), selend = this->selectionEnd(); - if(line > selstart.line && line < selend.line) return true; - if(line == selstart.line && line == selend.line) return column >= selstart.column && column <= selend.column; - if(line == selstart.line) return column >= selstart.column; - if(line == selend.line) return column <= selend.column; - return false; -} - -void QHexCursor::setMode(Mode m) -{ - if(m_mode == m) return; - m_mode = m; - Q_EMIT modeChanged(); -} - -void QHexCursor::switchMode() -{ - switch(m_mode) - { - case Mode::Insert: this->setMode(Mode::Overwrite); break; - case Mode::Overwrite: this->setMode(Mode::Insert); break; - } -} - -void QHexCursor::move(qint64 offset) { this->move(this->offsetToPosition(offset)); } -void QHexCursor::move(qint64 line, qint64 column) { return this->move({line, column}); } - -void QHexCursor::move(QHexPosition pos) -{ - if(pos.line >= 0) m_selection.line = pos.line; - if(pos.column >= 0) m_selection.column = pos.column; - this->select(pos); -} - -void QHexCursor::select(qint64 offset) { this->select(this->offsetToPosition(offset)); } -void QHexCursor::select(qint64 line, qint64 column) { this->select({line, column}); } - -void QHexCursor::select(QHexPosition pos) -{ - if(pos.line >= 0) m_position.line = pos.line; - if(pos.column >= 0) m_position.column = pos.column; - Q_EMIT positionChanged(); -} - -void QHexCursor::selectSize(qint64 length) -{ - if(length > 0) length--; - else if(length < 0) length++; - if(length) this->select(this->offset() + length); -} - -qint64 QHexCursor::replace(const QVariant& oldvalue, const QVariant& newvalue, qint64 offset, QHexFindMode mode, unsigned int options, QHexFindDirection fd) const { return this->hexView()->replace(oldvalue, newvalue, offset, mode, options, fd); } -qint64 QHexCursor::find(const QVariant& value, qint64 offset, QHexFindMode mode, unsigned int options, QHexFindDirection fd) const { return this->hexView()->find(value, offset, mode, options, fd); } -void QHexCursor::cut(bool hex) { this->hexView()->cut(hex); } -void QHexCursor::copy(bool hex) const { this->hexView()->copy(hex); } -void QHexCursor::paste(bool hex) { this->hexView()->paste(hex); } -void QHexCursor::selectAll() { this->hexView()->selectAll(); } -void QHexCursor::removeSelection() { this->hexView()->removeSelection(); } -void QHexCursor::clearSelection() { m_position = m_selection; Q_EMIT positionChanged(); } -qint64 QHexCursor::positionToOffset(QHexPosition pos) const { return QHexUtils::positionToOffset(m_options, pos); } -QHexPosition QHexCursor::offsetToPosition(qint64 offset) const { return QHexUtils::offsetToPosition(m_options, offset); } diff --git a/UEFITool/qhexview5/model/qhexcursor.h b/UEFITool/qhexview5/model/qhexcursor.h deleted file mode 100644 index 46f1067..0000000 --- a/UEFITool/qhexview5/model/qhexcursor.h +++ /dev/null @@ -1,69 +0,0 @@ -#pragma once - -#include -#include "qhexoptions.h" -#include "qhexutils.h" - -class QHexView; - -class QHexCursor : public QObject -{ - Q_OBJECT - - public: - enum class Mode { Overwrite, Insert }; - - private: - explicit QHexCursor(const QHexOptions* options, QHexView *parent = nullptr); - - public: - QHexView* hexView() const; - Mode mode() const; - qint64 line() const; - qint64 column() const; - qint64 offset() const; - qint64 address() const; - quint64 lineAddress() const; - qint64 selectionStartOffset() const; - qint64 selectionEndOffset() const; - qint64 selectionLength() const; - QHexPosition position() const; - QHexPosition selectionStart() const; - QHexPosition selectionEnd() const; - QByteArray selectedBytes() const; - bool hasSelection() const; - bool isSelected(qint64 line, qint64 column) const; - void setMode(Mode m); - void move(qint64 offset); - void move(qint64 line, qint64 column); - void move(QHexPosition pos); - void select(qint64 offset); - void select(qint64 line, qint64 column); - void select(QHexPosition pos); - void selectSize(qint64 length); - qint64 replace(const QVariant& oldvalue, const QVariant& newvalue, qint64 offset, QHexFindMode mode = QHexFindMode::Text, unsigned int options = QHexFindOptions::None, QHexFindDirection fd = QHexFindDirection::Forward) const; - qint64 find(const QVariant& value, qint64 offset, QHexFindMode mode = QHexFindMode::Text, unsigned int options = QHexFindOptions::None, QHexFindDirection fd = QHexFindDirection::Forward) const; - qint64 positionToOffset(QHexPosition pos) const; - QHexPosition offsetToPosition(qint64 offset) const; - - public Q_SLOTS: - void cut(bool hex = false); - void copy(bool hex = false) const; - void paste(bool hex = false); - void selectAll(); - void removeSelection(); - void clearSelection(); - void switchMode(); - - Q_SIGNALS: - void positionChanged(); - void modeChanged(); - - private: - const QHexOptions* m_options; - Mode m_mode{Mode::Overwrite}; - QHexPosition m_position{}, m_selection{}; - - friend class QHexView; -}; - diff --git a/UEFITool/qhexview5/model/qhexdelegate.h b/UEFITool/qhexview5/model/qhexdelegate.h deleted file mode 100644 index b122890..0000000 --- a/UEFITool/qhexview5/model/qhexdelegate.h +++ /dev/null @@ -1,25 +0,0 @@ -#pragma once - -#include -#include -#include "qhexutils.h" - -class QHexView; - -class QHexDelegate: public QObject -{ - Q_OBJECT - - public: - explicit QHexDelegate(QObject* parent = nullptr); - virtual ~QHexDelegate() = default; - virtual QString addressHeader(const QHexView* hexview) const; - virtual QString hexHeader(const QHexView* hexview) const; - virtual QString asciiHeader(const QHexView* hexview) const; - virtual void renderAddress(quint64 address, QTextCharFormat& cf, const QHexView* hexview) const; - virtual void renderHeader(QTextBlockFormat& bf, const QHexView* hexview) const; - virtual void renderHeaderPart(const QString& s, QHexArea area, QTextCharFormat& cf, const QHexView* hexview) const; - virtual bool render(quint64 offset, quint8 b, QTextCharFormat& outcf, const QHexView* hexview) const; - virtual bool paintSeparator(QPainter* painter, QLineF line, const QHexView* hexview) const; - virtual void paint(QPainter* painter, const QHexView* hexview) const; -}; diff --git a/UEFITool/qhexview5/model/qhexdocument.cpp b/UEFITool/qhexview5/model/qhexdocument.cpp deleted file mode 100644 index a4f1a76..0000000 --- a/UEFITool/qhexview5/model/qhexdocument.cpp +++ /dev/null @@ -1,92 +0,0 @@ -#include "qhexdocument.h" -#include "buffer/qmemorybuffer.h" -#include "commands/insertcommand.h" -#include "commands/replacecommand.h" -#include "commands/removecommand.h" -#include "qhexutils.h" -#include -#include -#include - -QHexDocument::QHexDocument(QHexBuffer *buffer, QObject* parent): QObject(parent) -{ - m_buffer = buffer; - m_buffer->setParent(this); // Take Ownership - - connect(&m_undostack, &QUndoStack::canUndoChanged, this, &QHexDocument::canUndoChanged); - connect(&m_undostack, &QUndoStack::canRedoChanged, this, &QHexDocument::canRedoChanged); -} - -qint64 QHexDocument::indexOf(const QByteArray& ba, qint64 from) { return m_buffer->indexOf(ba, from); } -qint64 QHexDocument::lastIndexOf(const QByteArray& ba, qint64 from) { return m_buffer->lastIndexOf(ba, from); } -bool QHexDocument::isEmpty() const { return m_buffer->isEmpty(); } -bool QHexDocument::canUndo() const { return m_undostack.canUndo(); } -bool QHexDocument::canRedo() const { return m_undostack.canRedo(); } - -void QHexDocument::setData(const QByteArray& ba) -{ - QHexBuffer* mb = new QMemoryBuffer(); - mb->read(ba); - this->setData(mb); -} - -void QHexDocument::setData(QHexBuffer* buffer) -{ - if(!buffer) return; - - m_undostack.clear(); - buffer->setParent(this); - - auto* oldbuffer = m_buffer; - m_buffer = buffer; - if(oldbuffer) oldbuffer->deleteLater(); - - Q_EMIT canUndoChanged(false); - Q_EMIT canRedoChanged(false); - Q_EMIT changed(); - Q_EMIT reset(); -} - -qint64 QHexDocument::length() const { return m_buffer ? m_buffer->length() : 0; } -uchar QHexDocument::at(int offset) const { return m_buffer->at(offset); } - -void QHexDocument::undo() { m_undostack.undo(); Q_EMIT changed(); } -void QHexDocument::redo() { m_undostack.redo(); Q_EMIT changed(); } -void QHexDocument::insert(qint64 offset, uchar b) { this->insert(offset, QByteArray(1, b)); } -void QHexDocument::replace(qint64 offset, uchar b) { this->replace(offset, QByteArray(1, b)); } - -void QHexDocument::insert(qint64 offset, const QByteArray &data) -{ - m_undostack.push(new InsertCommand(m_buffer, this, offset, data)); - - Q_EMIT changed(); - Q_EMIT dataChanged(data, offset, ChangeReason::Insert); -} - -void QHexDocument::replace(qint64 offset, const QByteArray &data) -{ - m_undostack.push(new ReplaceCommand(m_buffer, this, offset, data)); - Q_EMIT changed(); - Q_EMIT dataChanged(data, offset, ChangeReason::Replace); -} - -void QHexDocument::remove(qint64 offset, int len) -{ - QByteArray data = m_buffer->read(offset, len); - - m_undostack.push(new RemoveCommand(m_buffer, this, offset, len)); - Q_EMIT changed(); - Q_EMIT dataChanged(data, offset, ChangeReason::Remove); -} - -QByteArray QHexDocument::read(qint64 offset, int len) const { return m_buffer->read(offset, len); } - -bool QHexDocument::saveTo(QIODevice *device) -{ - if(!device->isWritable()) return false; - m_buffer->write(device); - return true; -} - -QHexDocument* QHexDocument::fromBuffer(QHexBuffer* buffer, QObject* parent) { return new QHexDocument(buffer, parent); } -QHexDocument* QHexDocument::create(QObject* parent) { return QHexDocument::fromMemory({}, parent); } diff --git a/UEFITool/qhexview5/model/qhexdocument.h b/UEFITool/qhexview5/model/qhexdocument.h deleted file mode 100644 index bc05b6d..0000000 --- a/UEFITool/qhexview5/model/qhexdocument.h +++ /dev/null @@ -1,88 +0,0 @@ -#pragma once - -#include -#include "buffer/qhexbuffer.h" -#include "qhexmetadata.h" -#include "qhexoptions.h" - -class QHexCursor; - -class QHexDocument: public QObject -{ - Q_OBJECT - - public: - enum class ChangeReason { Insert, Remove, Replace }; - enum class FindDirection { Forward, Backward }; - Q_ENUM(ChangeReason); - Q_ENUM(FindDirection); - - private: - explicit QHexDocument(QHexBuffer* buffer, QObject *parent = nullptr); - - public: - bool isEmpty() const; - bool canUndo() const; - bool canRedo() const; - void setData(const QByteArray& ba); - void setData(QHexBuffer* buffer); - qint64 length() const; - qint64 indexOf(const QByteArray& ba, qint64 from = 0); - qint64 lastIndexOf(const QByteArray& ba, qint64 from = 0); - QByteArray read(qint64 offset, int len = 0) const; - uchar at(int offset) const; - - public Q_SLOTS: - void undo(); - void redo(); - void insert(qint64 offset, uchar b); - void replace(qint64 offset, uchar b); - void insert(qint64 offset, const QByteArray& data); - void replace(qint64 offset, const QByteArray& data); - void remove(qint64 offset, int len); - bool saveTo(QIODevice* device); - - public: - template static QHexDocument* fromDevice(QIODevice* iodevice, QObject* parent = nullptr); - template static QHexDocument* fromMemory(char *data, int size, QObject* parent = nullptr); - template static QHexDocument* fromMemory(const QByteArray& ba, QObject* parent = nullptr); - static QHexDocument* fromBuffer(QHexBuffer* buffer, QObject* parent = nullptr); - static QHexDocument* create(QObject* parent = nullptr); - - Q_SIGNALS: - void canUndoChanged(bool canundo); - void canRedoChanged(bool canredo); - void dataChanged(const QByteArray& data, quint64 offset, QHexDocument::ChangeReason reason); - void changed(); - void reset(); - - private: - QHexBuffer* m_buffer; - QUndoStack m_undostack; - - friend class QHexView; -}; - -template -QHexDocument* QHexDocument::fromDevice(QIODevice* iodevice, QObject *parent) -{ - QHexBuffer* hexbuffer = new T(parent); - if(Owned) iodevice->setParent(hexbuffer); - return hexbuffer->read(iodevice) ? new QHexDocument(hexbuffer, parent) : nullptr; -} - -template -QHexDocument* QHexDocument::fromMemory(char *data, int size, QObject *parent) -{ - QHexBuffer* hexbuffer = new T(); - hexbuffer->read(data, size); - return new QHexDocument(hexbuffer, parent); -} - -template -QHexDocument* QHexDocument::fromMemory(const QByteArray& ba, QObject *parent) -{ - QHexBuffer* hexbuffer = new T(); - hexbuffer->read(ba); - return new QHexDocument(hexbuffer, parent); -} diff --git a/UEFITool/qhexview5/model/qhexmetadata.h b/UEFITool/qhexview5/model/qhexmetadata.h deleted file mode 100644 index 70f4fb2..0000000 --- a/UEFITool/qhexview5/model/qhexmetadata.h +++ /dev/null @@ -1,64 +0,0 @@ -#pragma once - -#include -#include -#include -#include -#include -#include "qhexoptions.h" - -struct QHexMetadataItem -{ - qint64 begin, end; - QColor foreground, background; - QString comment; -}; - -using QHexMetadataLine = QList; - -class QHexMetadata : public QObject -{ - Q_OBJECT - - private: - using ClearMetadataCallback = std::function; - - private: - explicit QHexMetadata(const QHexOptions* options, QObject *parent = nullptr); - - public: - const QHexMetadataLine* find(qint64 line) const; - QString getComment(qint64 line, qint64 column) const; - void removeMetadata(qint64 line); - void removeBackground(qint64 line); - void removeForeground(qint64 line); - void removeComments(qint64 line); - void unhighlight(qint64 line); - void clear(); - - public: - inline void setMetadata(qint64 begin, qint64 end, const QColor &fgcolor, const QColor &bgcolor, const QString &comment) { this->setMetadata({begin, end, fgcolor, bgcolor, comment}); } - inline void setForeground(qint64 begin, qint64 end, const QColor &fgcolor) { this->setMetadata(begin, end, fgcolor, QColor(), QString()); } - inline void setBackground(qint64 begin, qint64 end, const QColor &bgcolor) { this->setMetadata(begin, end, QColor(), bgcolor, QString()); } - inline void setComment(qint64 begin, qint64 end, const QString& comment) { this->setMetadata(begin, end, QColor(), QColor(), comment); }; - inline void setMetadataSize(qint64 begin, qint64 length, const QColor &fgcolor, const QColor &bgcolor, const QString &comment) { this->setMetadata({begin, begin + length, fgcolor, bgcolor, comment}); } - inline void setForegroundSize(qint64 begin, qint64 length, const QColor &fgcolor) { this->setForeground(begin, begin + length, fgcolor); } - inline void setBackgroundSize(qint64 begin, qint64 length, const QColor &bgcolor) { this->setBackground(begin, begin + length, bgcolor); } - inline void setCommentSize(qint64 begin, qint64 length, const QString& comment) { this->setComment(begin, begin + length, comment); }; - - private: - void copy(const QHexMetadata* metadata); - void clearMetadata(qint64 line, ClearMetadataCallback&& cb); - void setMetadata(const QHexMetadataItem& mi); - void invalidate(); - - Q_SIGNALS: - void changed(); - void cleared(); - - private: - QHash m_metadata; - const QHexOptions* m_options; - - friend class QHexView; -}; diff --git a/UEFITool/qhexview5/model/qhexutils.cpp b/UEFITool/qhexview5/model/qhexutils.cpp deleted file mode 100644 index 0fab0c9..0000000 --- a/UEFITool/qhexview5/model/qhexutils.cpp +++ /dev/null @@ -1,314 +0,0 @@ -#include "qhexutils.h" -#include "qhexoptions.h" -#include "../qhexview.h" -#include -#include -#include -#include -#include -#include -#include - -#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) - #define QHEXVIEW_VARIANT_EQ(x, t) ((x).metaType().id() == QMetaType::Q##t) -#else - #define QHEXVIEW_VARIANT_EQ(x, t) ((x).type() == QVariant::t) -#endif - -namespace QHexUtils { - -Q_GLOBAL_STATIC_WITH_ARGS(QList, HEXMAP, ({ - '0', '1', '2', '3', '4', '5', '6', '7', - '8', '9', 'a', 'b', 'c', 'd', 'e', 'f' -})); - -namespace PatternUtils { - -Q_GLOBAL_STATIC_WITH_ARGS(QString, WILDCARD_BYTE, ("??")) - -bool check(QString& p, qint64& len) -{ - static QHash> processed; // Cache processed patterns - - auto it = processed.find(p); - - if(it != processed.end()) - { - p = it.value().first; - len = it.value().second; - return true; - } - - QString op = p; // Store unprocessed pattern - p = p.simplified().replace(" ", ""); - if(p.isEmpty() || (p.size() % 2)) return false; - - int wccount = 0; - - for(auto i = 0; i < p.size() - 2; i += 2) - { - const auto& hexb = p.mid(i, 2); - - if(hexb == *WILDCARD_BYTE) - { - wccount++; - continue; - } - - if(!isxdigit(hexb.at(0).toLatin1()) || !isxdigit(hexb.at(1).toLatin1())) - return false; - } - - if(wccount >= p.size()) return false; - len = p.size() / 2; - processed[op] = qMakePair(p, len); // Cache processed pattern - return true; -} - -bool match(const QByteArray& data, const QString& pattern) -{ - for(qint64 i = 0, idx = 0; (i <= (pattern.size() - 2)); i += 2, idx++) - { - if(idx >= data.size()) return false; - -#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) - QStringView hexb = QStringView{pattern}.mid(i, 2); -#else - const QStringRef& hexb = pattern.midRef(i, 2); -#endif - - if(hexb == *WILDCARD_BYTE) continue; - - bool ok = false; - auto b = static_cast(hexb.toUInt(&ok, 16)); - if(!ok || (b != data.at(idx))) return false; - } - - return true; -} - -} - -namespace { - -unsigned int countBits(quint64 val) -{ - if(val <= std::numeric_limits::max()) return QHexFindOptions::Int8; - if(val <= std::numeric_limits::max()) return QHexFindOptions::Int16; - if(val <= std::numeric_limits::max()) return QHexFindOptions::Int32; - - return QHexFindOptions::Int64; -} - -template -qint64 findIter(qint64 startoffset, QHexFindDirection fd, const QHexView* hexview, Function&& f) -{ - QHexDocument* hexdocument = hexview->hexDocument(); - qint64 offset = -1; - - QHexFindDirection cfd = fd; - if(cfd == QHexFindDirection::All) cfd = QHexFindDirection::Forward; - - qint64 i = startoffset; - - while(offset == -1 && (cfd == QHexFindDirection::Backward ? (i >= 0) : (i < hexdocument->length()))) - { - if(!f(i, offset)) break; - - if(cfd == QHexFindDirection::Backward) i--; - else i++; - - if(fd == QHexFindDirection::All && i >= hexdocument->length()) i = 0; - } - - return offset; -} - -qint64 findDefault(const QByteArray& value, qint64 startoffset, const QHexView* hexview, unsigned int options, QHexFindDirection fd) -{ - QHexDocument* hexdocument = hexview->hexDocument(); - if(value.size() > hexdocument->length()) return -1; - - return findIter(startoffset, fd, hexview, [options, value, hexdocument](qint64 idx, qint64& offset) -> bool { - for(auto i = 0; i < value.size(); i++) { - qint64 curroffset = idx + i; - - if(curroffset >= hexdocument->length()) { - offset = -1; - return false; - } - - uchar ch1 = hexdocument->at(curroffset); - uchar ch2 = value.at(i); - - if(!(options & QHexFindOptions::CaseSensitive)) { - ch1 = std::tolower(ch1); - ch2 = std::tolower(ch2); - } - - if(ch1 != ch2) break; - if(i == value.size() - 1) offset = idx; - } - - return true; - }); -} - -qint64 findWildcard(QString pattern, qint64 startoffset, const QHexView* hexview, QHexFindDirection fd, qint64& patternlen) -{ - QHexDocument* hexdocument = hexview->hexDocument(); - if(!PatternUtils::check(pattern, patternlen) || (patternlen >= hexdocument->length())) return -1; - - return findIter(startoffset, fd, hexview, [hexdocument, pattern, patternlen](qint64 idx, qint64& offset) -> bool { - if(PatternUtils::match(hexdocument->read(idx, patternlen), pattern)) offset = idx; - return true; - }); -} - -QByteArray variantToByteArray(QVariant value, QHexFindMode mode, unsigned int options) -{ - QByteArray v; - - switch(mode) - { - case QHexFindMode::Text: - if(QHEXVIEW_VARIANT_EQ(value, String)) v = value.toString().toUtf8(); - else if(QHEXVIEW_VARIANT_EQ(value, ByteArray)) v = value.toByteArray(); - break; - - case QHexFindMode::Hex: { - if(QHEXVIEW_VARIANT_EQ(value, String)) { - qint64 len = 0; - auto s = value.toString(); - if(!PatternUtils::check(s, len)) return { }; - - bool ok = true; - -#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) - for(auto i = 0; ok && i < s.size(); i += 2) v.push_back(static_cast(QStringView{s}.mid(i, 2).toUInt(&ok, 16))); -#else - for(auto i = 0; ok && i < s.size(); i += 2) v.push_back(static_cast(s.midRef(i, 2).toUInt(&ok, 16))); -#endif - - if(!ok) return { }; - } - else if(QHEXVIEW_VARIANT_EQ(value, ByteArray)) v = value.toByteArray(); - break; - } - - case QHexFindMode::Int: { - bool ok = false; - uint val = value.toUInt(&ok); - if(!ok) return QByteArray{ }; - - QDataStream ds(&v, QIODevice::WriteOnly); - - if(options & QHexFindOptions::BigEndian) { - if(options & QHexFindOptions::Int8) ds << qToBigEndian(val); - else if(options & QHexFindOptions::Int16) ds << qToBigEndian(val); - else if(options & QHexFindOptions::Int32) ds << qToBigEndian(val); - else if(options & QHexFindOptions::Int64) ds << qToBigEndian(val); - else return variantToByteArray(value, mode, options | countBits(val)); - } - else { - if(options & QHexFindOptions::Int8) ds << static_cast(val); - else if(options & QHexFindOptions::Int16) ds << static_cast(val); - else if(options & QHexFindOptions::Int32) ds << static_cast(val); - else if(options & QHexFindOptions::Int64) ds << static_cast(val); - else return variantToByteArray(value, mode, options | countBits(val)); - } - - break; - } - - case QHexFindMode::Float: { - bool ok = false; - QDataStream ds(&v, QIODevice::WriteOnly); - if(options & QHexFindOptions::Float) ds << value.toFloat(&ok); - else if(options & QHexFindOptions::Double) ds << value.toDouble(&ok); - if(!ok) return { }; - } - - default: break; - } - - return v; -} - -} // namespace - -QByteArray toHex(const QByteArray& ba, char sep) -{ - QByteArray hex(sep ? (ba.size() * 3 - 1) : (ba.size() * 2), Qt::Uninitialized); - - for(auto i = 0, o = 0; i < ba.size(); i++) - { - if(sep && i) hex[o++] = static_cast(sep); - hex[o++] = HEXMAP->at((ba.at(i) & 0xf0) >> 4); - hex[o++] = HEXMAP->at(ba.at(i) & 0x0f); - } - - return hex; -} - -QByteArray toHex(const QByteArray& ba) { return QHexUtils::toHex(ba, '\0'); } -qint64 positionToOffset(const QHexOptions* options, QHexPosition pos) { return options->linelength * pos.line + pos.column; } -QHexPosition offsetToPosition(const QHexOptions* options, qint64 offset) { return { offset / options->linelength, offset % options->linelength }; } - -QPair find(const QHexView* hexview, QVariant value, qint64 startoffset, QHexFindMode mode, unsigned int options, QHexFindDirection fd) -{ - qint64 offset, size = 0; - if(startoffset == -1) startoffset = static_cast(hexview->offset()); - - if(mode == QHexFindMode::Hex && QHEXVIEW_VARIANT_EQ(value, String)) - { - offset = QHexUtils::findWildcard(value.toString(), startoffset, hexview, fd, size); - } - else - { - auto ba = variantToByteArray(value, mode, options); - - if(!ba.isEmpty()) - { - offset = QHexUtils::findDefault(ba, startoffset, hexview, options, fd); - size = ba.size(); - } - else - offset = -1; - } - - return {offset, offset > -1 ? size : 0}; -} - -bool checkPattern(QString pattern) -{ - qint64 len = 0; - return PatternUtils::check(pattern, len); -} - -QPair replace(const QHexView* hexview, QVariant oldvalue, QVariant newvalue, qint64 startoffset, QHexFindMode mode, unsigned int options, QHexFindDirection fd) -{ - auto res = QHexUtils::find(hexview, oldvalue, startoffset, mode, options, fd); - - if(res.first != -1 && res.second > 0) - { - QHexDocument* hexdocument = hexview->hexDocument(); - auto ba = variantToByteArray(newvalue, mode, options); - - if(!ba.isEmpty()) - { - hexdocument->remove(res.first, res.second); - hexdocument->insert(res.first, ba); - res.second = ba.size(); - } - else - { - res.first = -1; - res.second = 0; - } - } - - return res; -} - -} diff --git a/UEFITool/qhexview5/model/qhexutils.h b/UEFITool/qhexview5/model/qhexutils.h deleted file mode 100644 index 170e9e1..0000000 --- a/UEFITool/qhexview5/model/qhexutils.h +++ /dev/null @@ -1,48 +0,0 @@ -#pragma once - -#include -#include -#include -#include - -struct QHexOptions; -class QHexView; - -namespace QHexFindOptions { - enum: unsigned int { - None = (1 << 0), - CaseSensitive = (1 << 1), - Int8 = (1 << 2), - Int16 = (1 << 3), - Int32 = (1 << 4), - Int64 = (1 << 5), - Float = (1 << 6), - Double = (1 << 7), - - BigEndian = (1 << 11), - }; -} - -enum class QHexFindMode { Text, Hex, Int, Float }; -enum class QHexFindDirection { All, Forward, Backward }; -enum class QHexArea { Header, Address, Hex, Ascii, Extra }; - -struct QHexPosition { - qint64 line; qint64 column; - static inline QHexPosition invalid() { return {-1, -1}; } - inline bool isValid() const { return line >= 0 && column >= 0; } - inline bool operator==(const QHexPosition& rhs) const { return (line == rhs.line) && (column == rhs.column); } - inline bool operator!=(const QHexPosition& rhs) const { return (line != rhs.line) || (column != rhs.column); } -}; - -namespace QHexUtils { - -QByteArray toHex(const QByteArray& ba, char sep); -QByteArray toHex(const QByteArray& ba); -qint64 positionToOffset(const QHexOptions* options, QHexPosition pos); -QPair find(const QHexView* hexview, QVariant value, qint64 startoffset = 0, QHexFindMode mode = QHexFindMode::Text, unsigned int options = QHexFindOptions::None, QHexFindDirection fd = QHexFindDirection::Forward); -QPair replace(const QHexView* hexview, QVariant oldvalue, QVariant newvalue, qint64 startoffset = 0, QHexFindMode mode = QHexFindMode::Text, unsigned int options = QHexFindOptions::None, QHexFindDirection fd = QHexFindDirection::Forward); -QHexPosition offsetToPosition(const QHexOptions* options, qint64 offset); -bool checkPattern(QString pattern); - -} diff --git a/UEFITool/qhexview5/qhexview.cpp b/UEFITool/qhexview5/qhexview.cpp deleted file mode 100644 index d5b82b6..0000000 --- a/UEFITool/qhexview5/qhexview.cpp +++ /dev/null @@ -1,1264 +0,0 @@ -#include "qhexview.h" -#include "model/buffer/qmemorybuffer.h" -#include "model/qhexcursor.h" -#include "model/qhexutils.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#if defined(QHEXVIEW_ENABLE_DIALOGS) - #include "dialogs/hexfinddialog.h" -#endif - -#if defined(QHEXVIEW_DEBUG) - #include - #define qhexview_fmtprint(fmt, ...) qDebug("%s " fmt, __func__, __VA_ARGS__) -#else - #define qhexview_fmtprint(fmt, ...) -#endif - -QHexView::QHexView(QWidget *parent) : QAbstractScrollArea(parent), m_fontmetrics(this->font()) -{ - QFont f = QFontDatabase::systemFont(QFontDatabase::FixedFont); - - if (f.styleHint() != QFont::TypeWriter) { - f.setFamily("Monospace"); // Force Monospaced font - f.setStyleHint(QFont::TypeWriter); - } - - this->setFont(f); - this->setMouseTracking(true); - this->setFocusPolicy(Qt::StrongFocus); - this->viewport()->setCursor(Qt::IBeamCursor); - - QPalette p = this->palette(); - p.setBrush(QPalette::Window, p.base()); - - connect(this->verticalScrollBar(), &QScrollBar::valueChanged, this, [=](int) { this->viewport()->update(); }); - - m_hexmetadata = new QHexMetadata(&m_options, this); - connect(m_hexmetadata, &QHexMetadata::changed, this, [=]() { this->viewport()->update(); }); - - m_hexcursor = new QHexCursor(&m_options, this); - this->setDocument(QHexDocument::fromMemory(QByteArray(), this)); - this->checkState(); - - connect(m_hexcursor, &QHexCursor::positionChanged, this, [=]() { - m_writing = false; - this->ensureVisible(); - Q_EMIT positionChanged(); - }); - - connect(m_hexcursor, &QHexCursor::modeChanged, this, [=]() { - m_writing = false; - this->viewport()->update(); - Q_EMIT modeChanged(); - }); -} - -QRectF QHexView::headerRect() const -{ - if(m_options.hasFlag(QHexFlags::NoHeader)) return QRectF(); - - return QRectF(0, - 0, - this->endColumnX(), - this->lineHeight()); -} - -QRectF QHexView::addressRect() const -{ - qreal y = m_options.hasFlag(QHexFlags::NoHeader) ? 0 : this->lineHeight(); - - return QRectF(0, - y, - this->endColumnX(), - this->height() - y); -} - -QRectF QHexView::hexRect() const -{ - qreal y = m_options.hasFlag(QHexFlags::NoHeader) ? 0 : this->lineHeight(); - - return QRectF(this->hexColumnX(), - y, - this->asciiColumnX() - this->hexColumnX(), - this->height() - y); -} - -QRectF QHexView::asciiRect() const -{ - qreal y = m_options.hasFlag(QHexFlags::NoHeader) ? 0 : this->lineHeight(); - - return QRectF(this->asciiColumnX(), - y, - this->endColumnX() - this->asciiColumnX(), - this->height() - y); -} - -QHexDocument* QHexView::hexDocument() const { return m_hexdocument; } -QHexCursor* QHexView::hexCursor() const { return m_hexdocument ? m_hexcursor : nullptr; } -const QHexMetadata* QHexView::hexMetadata() const { return m_hexmetadata; } -QHexOptions QHexView::options() const { return m_options; } - -void QHexView::setOptions(const QHexOptions& options) -{ - auto oldlinelength = m_options.linelength; - m_options = options; - - if(oldlinelength != m_options.linelength) - m_hexmetadata->invalidate(); - - this->checkAndUpdate(); -} - -void QHexView::setBaseAddress(quint64 baseaddress) -{ - if(m_options.baseaddress == baseaddress) return; - - m_options.baseaddress = baseaddress; - this->checkAndUpdate(); -} - -void QHexView::setDelegate(QHexDelegate* rd) -{ - if(m_hexdelegate == rd) return; - m_hexdelegate = rd; - this->checkAndUpdate(); -} - -void QHexView::setDocument(QHexDocument* doc) -{ - if(!doc) doc = QHexDocument::fromMemory(QByteArray(), this); - if(!doc->parent()) doc->setParent(this); - - m_writing = false; - m_hexmetadata->clear(); - m_hexcursor->move(0); - - if(m_hexdocument) - { - disconnect(m_hexdocument, &QHexDocument::changed, this, nullptr); - disconnect(m_hexdocument, &QHexDocument::dataChanged, this, nullptr); - disconnect(m_hexdocument, &QHexDocument::reset, this, nullptr); - } - - m_hexdocument = doc; - - connect(m_hexdocument, &QHexDocument::reset, this, [=]() { - m_writing = false; - m_hexcursor->move(0); - this->checkAndUpdate(true); - }); - - connect(m_hexdocument, &QHexDocument::dataChanged, this, &QHexView::dataChanged); - connect(m_hexdocument, &QHexDocument::changed, this, [=]() { this->checkAndUpdate(true); }); - this->checkAndUpdate(true); -} - -void QHexView::setData(const QByteArray& ba) { m_hexdocument->setData(ba); } -void QHexView::setData(QHexBuffer* buffer) { m_hexdocument->setData(buffer); } -void QHexView::setCursorMode(QHexCursor::Mode mode) { m_hexcursor->setMode(mode); } - -void QHexView::setByteColor(quint8 b, QHexColor c) -{ - m_options.bytecolors[b] = c; - this->checkAndUpdate(); -} - -void QHexView::setByteForeground(quint8 b, QColor c) -{ - m_options.bytecolors[b].foreground = c; - this->checkAndUpdate(); -} - -void QHexView::setByteBackground(quint8 b, QColor c) -{ - m_options.bytecolors[b].background = c; - this->checkAndUpdate(); -} - -void QHexView::setMetadata(qint64 begin, qint64 end, const QColor& fgcolor, const QColor& bgcolor, const QString& comment) { m_hexmetadata->setMetadata(begin, end, fgcolor, bgcolor, comment); } -void QHexView::setForeground(qint64 begin, qint64 end, const QColor& fgcolor) { m_hexmetadata->setForeground(begin, end, fgcolor); } -void QHexView::setBackground(qint64 begin, qint64 end, const QColor& bgcolor) { m_hexmetadata->setBackground(begin, end, bgcolor); } -void QHexView::setComment(qint64 begin, qint64 end, const QString& comment) { m_hexmetadata->setComment(begin, end, comment); } -void QHexView::setMetadataSize(qint64 begin, qint64 length, const QColor& fgcolor, const QColor& bgcolor, const QString& comment) { m_hexmetadata->setMetadataSize(begin, length, fgcolor, bgcolor, comment); } -void QHexView::setForegroundSize(qint64 begin, qint64 length, const QColor& fgcolor) { m_hexmetadata->setForegroundSize(begin, length, fgcolor); } -void QHexView::setBackgroundSize(qint64 begin, qint64 length, const QColor& bgcolor) { m_hexmetadata->setBackgroundSize(begin, length, bgcolor); } -void QHexView::setCommentSize(qint64 begin, qint64 length, const QString& comment) { m_hexmetadata->setCommentSize(begin, length, comment); } -void QHexView::removeMetadata(qint64 line) { m_hexmetadata->removeMetadata(line); } -void QHexView::removeBackground(qint64 line) { m_hexmetadata->removeBackground(line); } -void QHexView::removeForeground(qint64 line) { m_hexmetadata->removeForeground(line); } -void QHexView::removeComments(qint64 line) { m_hexmetadata->removeComments(line); } -void QHexView::unhighlight(qint64 line) { m_hexmetadata->unhighlight(line); } -void QHexView::clearMetadata() { m_hexmetadata->clear(); } - -#if defined(QHEXVIEW_ENABLE_DIALOGS) -void QHexView::showFind() -{ - if(!m_hexdlgfind) m_hexdlgfind = new HexFindDialog(HexFindDialog::Type::Find, this); - m_hexdlgfind->show(); -} - -void QHexView::showReplace() -{ - if(!m_hexdlgreplace) m_hexdlgreplace = new HexFindDialog(HexFindDialog::Type::Replace, this); - m_hexdlgreplace->show(); -} -#endif - -void QHexView::undo() { if(m_hexdocument) m_hexdocument->undo(); } -void QHexView::redo() { if(m_hexdocument) m_hexdocument->redo(); } - -void QHexView::cut(bool hex) -{ - this->copy(hex); - if(m_readonly) return; - - if(m_hexcursor->hasSelection()) this->removeSelection(); - else m_hexdocument->remove(m_hexcursor->offset(), 1); -} - -void QHexView::copyAs(CopyMode mode) const -{ - QClipboard* c = qApp->clipboard(); - - QByteArray bytes = m_hexcursor->hasSelection() ? m_hexcursor->selectedBytes() : - m_hexdocument->read(m_hexcursor->offset(), 1); - - switch(mode) - { - case CopyMode::HexArrayCurly: - case CopyMode::HexArraySquare: { - QString hexchar; - int i = 0; - - for(char b : bytes) { - if(!hexchar.isEmpty()) { - hexchar += ", "; - if(m_options.copybreak && !(++i % m_options.linelength)) hexchar += "\n"; - } - - hexchar += "0x" + QString::number(static_cast(b), 16).toUpper(); - } - - c->setText(QString(mode == CopyMode::HexArraySquare ? "[%1]" : "{%1}").arg(hexchar)); - break; - } - - case CopyMode::HexArrayChar: { - QString hexchar; - - for(char b : bytes) - hexchar += "\\x" + QString::number(static_cast(b), 16).toUpper(); - - c->setText(QString("\"%1\"").arg(hexchar)); - break; - } - - default: { - QString hexchar; - - for(int i = 0; i < bytes.size(); i++) { - if(!(i % m_options.grouplength)) { - if(!hexchar.isEmpty()) { - hexchar += ", "; - if(m_options.copybreak && !(i % m_options.linelength)) hexchar += "\n"; - } - - hexchar += "0x"; - } - - hexchar += QString("%1").arg(static_cast(bytes[i]), 2, 16, QLatin1Char('0')).toUpper(); - } - - c->setText(hexchar); - break; - } - } -} - -void QHexView::copy(bool hex) const -{ - QClipboard* c = qApp->clipboard(); - - QByteArray bytes = m_hexcursor->hasSelection() ? m_hexcursor->selectedBytes() : - m_hexdocument->read(m_hexcursor->offset(), 1); - - if(hex) bytes = QHexUtils::toHex(bytes, ' ').toUpper(); - c->setText(bytes); -} - -void QHexView::paste(bool hex) -{ - if(m_readonly) return; - - QClipboard* c = qApp->clipboard(); - QByteArray pastedata = c->text().toUtf8(); - if(pastedata.isEmpty()) return; - - this->removeSelection(); - if(hex) pastedata = QByteArray::fromHex(pastedata); - - if(m_hexcursor->mode() == QHexCursor::Mode::Insert) m_hexdocument->insert(m_hexcursor->offset(), pastedata); - else m_hexdocument->replace(m_hexcursor->offset(), pastedata); -} - -void QHexView::selectAll() -{ - m_hexcursor->move(0); - m_hexcursor->select(m_hexdocument->length()); -} - -void QHexView::removeSelection() -{ - if(!m_hexcursor->hasSelection()) return; - if(!m_readonly) m_hexdocument->remove(m_hexcursor->selectionStartOffset(), m_hexcursor->selectionLength() - 1); - m_hexcursor->clearSelection(); -} - -void QHexView::switchMode() { m_hexcursor->switchMode(); } - -void QHexView::setAddressWidth(unsigned int w) -{ - if(w == m_options.addresswidth) return; - m_options.addresswidth = w; - this->checkState(); -} - -void QHexView::setScrollSteps(unsigned int l) -{ - if(l == m_options.scrollsteps) return; - m_options.scrollsteps = qMax(1u, l); -} - -void QHexView::setReadOnly(bool r) { m_readonly = r; } - -void QHexView::setAutoWidth(bool r) -{ - if(m_autowidth == r) return; - m_autowidth = r; - this->checkState(); -} - -void QHexView::paint(QPainter* painter) const -{ - QTextDocument doc; - doc.setDocumentMargin(0); - doc.setUndoRedoEnabled(false); - doc.setDefaultFont(this->font()); - - QTextCursor c(&doc); - - this->drawHeader(c); - this->drawDocument(c); - - painter->translate(-this->horizontalScrollBar()->value(), 0); - doc.drawContents(painter); - this->drawSeparators(painter); -} - -void QHexView::checkOptions() -{ - if(m_options.grouplength > m_options.linelength) m_options.grouplength = m_options.linelength; - if(!m_options.scrollsteps) m_options.scrollsteps = 1; - - m_options.addresswidth = qMax(m_options.addresswidth, this->calcAddressWidth()); - - // Round to nearest multiple of 2 - m_options.grouplength = 1u << (static_cast(qFloor(m_options.grouplength / 2.0))); - - if(m_options.grouplength <= 1) m_options.grouplength = 1; - - if(!m_options.headercolor.isValid()) - m_options.headercolor = this->palette().color(QPalette::Normal, QPalette::Highlight); -} - -void QHexView::setLineLength(unsigned int l) -{ - if(l == m_options.linelength) return; - m_options.linelength = l; - m_hexmetadata->invalidate(); - this->checkAndUpdate(true); -} - -void QHexView::setGroupLength(unsigned int l) -{ - if(l == m_options.grouplength) return; - m_options.grouplength = l; - this->checkAndUpdate(true); -} - -void QHexView::checkState() -{ - if(!m_hexdocument) return; - this->checkOptions(); - - int doclines = static_cast(this->lines()), vislines = this->visibleLines(true); - qint64 vscrollmax = doclines - vislines; - if(doclines >= vislines) vscrollmax++; - - this->verticalScrollBar()->setRange(0, qMax(0, vscrollmax)); - this->verticalScrollBar()->setPageStep(vislines - 1); - this->verticalScrollBar()->setSingleStep(m_options.scrollsteps); - - int vw = this->verticalScrollBar()->isVisible() ? this->verticalScrollBar()->width() : 0; - - static int oldmw = 0; - if(!oldmw) oldmw = this->maximumWidth(); - this->setMaximumWidth(m_autowidth ? qCeil(this->endColumnX() + vw + 3) : oldmw); - - this->horizontalScrollBar()->setRange(0, qMax(0, this->endColumnX() - this->width() + vw + 3)); - this->horizontalScrollBar()->setPageStep(this->width()); -} - -void QHexView::checkAndUpdate(bool calccolumns) -{ - this->checkState(); - if(calccolumns) this->calcColumns(); - this->viewport()->update(); -} - -void QHexView::calcColumns() -{ - if(!m_hexdocument) return; - - m_hexcolumns.clear(); - m_hexcolumns.reserve(m_options.linelength); - - auto x = this->hexColumnX(), cw = this->cellWidth() * 2; - - for(auto i = 0u; i < m_options.linelength; i++) - { - for(auto j = 0u; j < m_options.grouplength; j++, x += cw) - m_hexcolumns.push_back(QRect(x, 0, cw, 0)); - - x += this->cellWidth(); - } -} - -void QHexView::ensureVisible() -{ - if(!m_hexdocument) return; - - auto pos = m_hexcursor->position(); - auto vlines = this->visibleLines(); - - if(pos.line >= (this->verticalScrollBar()->value() + vlines)) - this->verticalScrollBar()->setValue(pos.line - vlines + 1); - else if(pos.line < this->verticalScrollBar()->value()) - this->verticalScrollBar()->setValue(pos.line); - else - this->viewport()->update(); -} - -void QHexView::drawSeparators(QPainter* p) const -{ - if(!m_options.hasFlag(QHexFlags::Separators)) return; - - auto oldpen = p->pen(); - p->setPen(m_options.separatorcolor.isValid() ? m_options.separatorcolor : this->palette().color(QPalette::Dark)); - - if(m_options.hasFlag(QHexFlags::HSeparator)) - { - QLineF l(0, m_fontmetrics.lineSpacing(), this->endColumnX(), m_fontmetrics.lineSpacing()); - if(!m_hexdelegate || !m_hexdelegate->paintSeparator(p, l, this)) p->drawLine(l); - } - - if(m_options.hasFlag(QHexFlags::VSeparator)) - { - QLineF l1(this->hexColumnX(), 0, this->hexColumnX(), this->height()); - QLineF l2(this->asciiColumnX(), 0, this->asciiColumnX(), this->height()); - - if(!m_hexdelegate || !m_hexdelegate->paintSeparator(p, l1, this)) - p->drawLine(l1); - - if(!m_hexdelegate || !m_hexdelegate->paintSeparator(p, l2, this)) - p->drawLine(l2); - } - - p->setPen(oldpen); -} - -void QHexView::drawHeader(QTextCursor& c) const -{ - if(m_options.hasFlag(QHexFlags::NoHeader)) return; - - static const auto RESET_FORMAT = [](const QHexOptions& options, QTextCharFormat& cf) { - cf = { }; - cf.setForeground(options.headercolor); - }; - - QString addresslabel; - if(m_hexdelegate) addresslabel = m_hexdelegate->addressHeader(this); - if(addresslabel.isEmpty() && !m_options.addresslabel.isEmpty()) addresslabel = m_options.addresslabel; - - QTextCharFormat cf; - RESET_FORMAT(m_options, cf); - if(m_hexdelegate) m_hexdelegate->renderHeaderPart(addresslabel, QHexArea::Address, cf, this); - c.insertText(" " + QHexView::reduced(addresslabel, this->addressWidth()) + " ", cf); - - if(m_hexdelegate) RESET_FORMAT(m_options, cf); - - QString hexlabel; - if(m_hexdelegate) hexlabel = m_hexdelegate->hexHeader(this); - if(hexlabel.isEmpty()) hexlabel = m_options.hexlabel; - - if(hexlabel.isNull()) - { - c.insertText(" ", { }); - - for(auto i = 0u; i < m_options.linelength; i += m_options.grouplength) - { - QString h = QString::number(i, 16).rightJustified(m_options.grouplength * 2, '0').toUpper(); - - if(m_hexdelegate) - { - RESET_FORMAT(m_options, cf); - m_hexdelegate->renderHeaderPart(h, QHexArea::Hex, cf, this); - } - - if(m_hexcursor->column() == static_cast(i) && m_options.hasFlag(QHexFlags::HighlightColumn)) - { - cf.setBackground(this->palette().color(QPalette::Highlight)); - cf.setForeground(this->palette().color(QPalette::HighlightedText)); - } - - c.insertText(h, cf); - c.insertText(" ", { }); - RESET_FORMAT(m_options, cf); - } - } - else - { - if(m_hexdelegate) m_hexdelegate->renderHeaderPart(hexlabel, QHexArea::Hex, cf, this); - c.insertText(" " + QHexView::reduced(hexlabel, (this->hexColumnWidth() / this->cellWidth()) - 1) + " "); - } - - if(m_hexdelegate) RESET_FORMAT(m_options, cf); - - QString asciilabel; - if(m_hexdelegate) asciilabel = m_hexdelegate->asciiHeader(this); - if(asciilabel.isEmpty()) asciilabel = m_options.asciilabel; - - if(asciilabel.isNull()) - { - c.insertText(" ", { }); - - for(unsigned int i = 0; i < m_options.linelength; i++) - { - QString a = QString::number(i, 16).toUpper(); - - if(m_hexdelegate) - { - RESET_FORMAT(m_options, cf); - m_hexdelegate->renderHeaderPart(a, QHexArea::Ascii, cf, this); - } - - if(m_hexcursor->column() == static_cast(i) && m_options.hasFlag(QHexFlags::HighlightColumn)) - { - cf.setBackground(this->palette().color(QPalette::Highlight)); - cf.setForeground(this->palette().color(QPalette::HighlightedText)); - } - - c.insertText(a, cf); - RESET_FORMAT(m_options, cf); - } - - c.insertText(" ", { }); - } - else - { - if(m_hexdelegate) m_hexdelegate->renderHeaderPart(asciilabel, QHexArea::Ascii, cf, this); - c.insertText(" " + QHexView::reduced(asciilabel, ((this->endColumnX() - this->asciiColumnX() - this->cellWidth()) / this->cellWidth()) - 1) + " "); - } - - QTextBlockFormat bf; - if(m_options.hasFlag(QHexFlags::StyledHeader)) bf.setBackground(this->palette().color(QPalette::Window)); - if(m_hexdelegate) m_hexdelegate->renderHeader(bf, this); - c.setBlockFormat(bf); - c.insertBlock(); -} - -void QHexView::drawDocument(QTextCursor& c) const -{ - if(!m_hexdocument) return; - - qreal y = !m_options.hasFlag(QHexFlags::NoHeader) ? this->lineHeight() : 0; - quint64 line = static_cast(this->verticalScrollBar()->value()); - - QTextCharFormat addrformat; - addrformat.setForeground(this->palette().color(QPalette::Normal, QPalette::Highlight)); - - for(qint64 l = 0; m_hexdocument->isEmpty() || (line < this->lines() && l < this->visibleLines()); l++, line++, y += this->lineHeight()) - { - quint64 address = line * m_options.linelength + this->baseAddress(); - QString addrstr = QString::number(address, 16).rightJustified(this->addressWidth(), '0').toUpper(); - - // Address Part - QTextCharFormat acf; - acf.setForeground(m_options.headercolor); - - if(m_options.hasFlag(QHexFlags::StyledAddress)) - acf.setBackground(this->palette().color(QPalette::Window)); - - if(m_hexdelegate) m_hexdelegate->renderAddress(address, acf, this); - - if(m_hexcursor->line() == static_cast(line) && m_options.hasFlag(QHexFlags::HighlightAddress)) - { - acf.setBackground(this->palette().color(QPalette::Highlight)); - acf.setForeground(this->palette().color(QPalette::HighlightedText)); - } - - c.insertText(" " + addrstr + " ", acf); - - auto linebytes = this->getLine(line); - c.insertText(" ", { }); - - // Hex Part - for(auto column = 0u; column < m_options.linelength; ) - { - QTextCharFormat cf; - - for(auto byteidx = 0u; byteidx < m_options.grouplength; byteidx++, column++) - { - QString s = linebytes.isEmpty() || column >= static_cast(linebytes.size()) ? " " : QString(QHexUtils::toHex(linebytes.mid(column, 1)).toUpper()); - quint8 b = static_cast(column) < linebytes.size() ? linebytes.at(column) : 0x00; - cf = this->drawFormat(c, b, s, QHexArea::Hex, line, column, static_cast(column) < linebytes.size()); - } - - c.insertText(" ", cf); - } - - c.insertText(" ", { }); - - // Ascii Part - for(auto column = 0u; column < m_options.linelength; column++) - { - auto s = linebytes.isEmpty() || - column >= static_cast(linebytes.size()) ? QChar(' ') : - (QChar::isPrint(linebytes.at(column)) ? QChar(linebytes.at(column)) : m_options.unprintablechar); - - quint8 b = static_cast(column) < linebytes.size() ? linebytes.at(column) : 0x00; - this->drawFormat(c, b, s, QHexArea::Ascii, line, column, static_cast(column) < linebytes.size()); - } - - QTextBlockFormat bf; - - if(m_options.linealternatebackground.isValid() && line % 2) - bf.setBackground(m_options.linealternatebackground); - else if(m_options.linebackground.isValid() && !(line % 2)) - bf.setBackground(m_options.linebackground); - - c.setBlockFormat(bf); - c.insertBlock({}); - if(m_hexdocument->isEmpty()) break; - } -} - -unsigned int QHexView::calcAddressWidth() const -{ - if(!m_hexdocument) return 0; - - auto maxaddr = static_cast(m_options.baseaddress + m_hexdocument->length()); - if(maxaddr <= std::numeric_limits::max()) return 8; - return QString::number(maxaddr, 16).size(); -} - -int QHexView::visibleLines(bool absolute) const -{ - int vl = static_cast(qCeil(this->viewport()->height() / this->lineHeight())); - if(!m_options.hasFlag(QHexFlags::NoHeader)) vl--; - return absolute ? vl : qMin(this->lines(), vl); -} - -qint64 QHexView::getLastColumn(qint64 line) const { return this->getLine(line).size() - 1; } -qint64 QHexView::lastLine() const { return qMax(0, this->lines() - 1); } - -qreal QHexView::hexColumnWidth() const -{ - int l = 0; - - for(auto i = 0u; i < m_options.linelength; i += m_options.grouplength) - l += (2 * m_options.grouplength) + 1; - - return this->getNCellsWidth(l); -} - -unsigned int QHexView::addressWidth() const -{ - if(!m_hexdocument || m_options.addresswidth) return m_options.addresswidth; - return this->calcAddressWidth(); -} - -unsigned int QHexView::lineLength() const { return m_options.linelength; } -bool QHexView::canUndo() const { return m_hexdocument && m_hexdocument->canUndo(); } -bool QHexView::canRedo() const { return m_hexdocument && m_hexdocument->canRedo(); } -quint64 QHexView::offset() const { return m_hexcursor->offset(); } -quint64 QHexView::address() const { return m_hexcursor->address(); } -QHexPosition QHexView::position() const { return m_hexcursor->position(); } -QHexPosition QHexView::selectionStart() const { return m_hexcursor->selectionStart(); } -QHexPosition QHexView::selectionEnd() const { return m_hexcursor->selectionEnd(); } -quint64 QHexView::selectionStartOffset() const { return m_hexcursor->selectionStartOffset(); } -quint64 QHexView::selectionEndOffset() const { return m_hexcursor->selectionEndOffset(); } -quint64 QHexView::baseAddress() const { return m_options.baseaddress; } - -quint64 QHexView::lines() const -{ - if(!m_hexdocument) return 0; - - auto lines = static_cast(qCeil(m_hexdocument->length() / static_cast(m_options.linelength))); - return !m_hexdocument->isEmpty() && !lines ? 1 : lines; -} - -qint64 QHexView::replace(const QVariant& oldvalue, const QVariant& newvalue, qint64 offset, QHexFindMode mode, unsigned int options, QHexFindDirection fd) const -{ - auto res = QHexUtils::replace(this, oldvalue, newvalue, offset, mode, options, fd); - - if(res.first > -1) - { - m_hexcursor->move(res.first); - m_hexcursor->selectSize(res.second); - } - - return res.first; -} - -qint64 QHexView::find(const QVariant& value, qint64 offset, QHexFindMode mode, unsigned int options, QHexFindDirection fd) const -{ - auto res = QHexUtils::find(this, value, offset, mode, options, fd); - - if(res.first > -1) - { - m_hexcursor->move(res.first); - m_hexcursor->selectSize(res.second); - } - - return res.first; -} - -qreal QHexView::hexColumnX() const { return this->getNCellsWidth(this->addressWidth() + 2); } -qreal QHexView::asciiColumnX() const { return this->hexColumnX() + this->hexColumnWidth() + this->cellWidth(); } -qreal QHexView::endColumnX() const { return this->asciiColumnX() + this->getNCellsWidth(m_options.linelength + 1) + this->cellWidth(); } -qreal QHexView::getNCellsWidth(int n) const { return n * this->cellWidth(); } - -qreal QHexView::cellWidth() const -{ -#if QT_VERSION >= QT_VERSION_CHECK(5, 11, 0) - return m_fontmetrics.horizontalAdvance(" "); -#else - return m_fontmetrics.width(" "); -#endif -} - -qreal QHexView::lineHeight() const { return m_fontmetrics.height(); } - -QHexPosition QHexView::positionFromPoint(QPoint pt) const -{ - QHexPosition pos = QHexPosition::invalid(); - auto abspt = this->absolutePoint(pt); - - switch(this->areaFromPoint(pt)) - { - case QHexArea::Hex: { - pos.column = -1; - - for(qint64 i = 0; i < m_hexcolumns.size(); i++) { - if(m_hexcolumns.at(i).left() > abspt.x()) break; - pos.column = i; - } - - break; - } - - case QHexArea::Ascii: pos.column = qMax(qFloor((abspt.x() - this->asciiColumnX()) / this->cellWidth()) - 1, 0); break; - case QHexArea::Address: pos.column = 0; break; - case QHexArea::Header: return QHexPosition::invalid(); - default: break; - } - - pos.line = qMin(this->verticalScrollBar()->value() + (abspt.y() / this->lineHeight()), this->lines()); - if(!m_options.hasFlag(QHexFlags::NoHeader)) pos.line = qMax(0, pos.line - 1); - - auto docline = this->getLine(pos.line); - pos.column = qMin(pos.column, docline.isEmpty() ? 0 : docline.size()); - - qhexview_fmtprint("line: %lld, col: %lld", pos.line, pos.column); - return pos; -} - -QPoint QHexView::absolutePoint(QPoint pt) const { return pt + QPoint(this->horizontalScrollBar()->value(), 0); } - -QHexArea QHexView::areaFromPoint(QPoint pt) const -{ - pt = this->absolutePoint(pt); - qreal line = this->verticalScrollBar()->value() + pt.y() / this->lineHeight(); - - if(!m_options.hasFlag(QHexFlags::NoHeader) && !qFloor(line)) return QHexArea::Header; - if(pt.x() < this->hexColumnX()) return QHexArea::Address; - if(pt.x() < this->asciiColumnX()) return QHexArea::Hex; - if(pt.x() < this->endColumnX()) return QHexArea::Ascii; - return QHexArea::Extra; -} - -QTextCharFormat QHexView::drawFormat(QTextCursor& c, quint8 b, const QString& s, QHexArea area, qint64 line, qint64 column, bool applyformat) const -{ - QTextCharFormat cf, selcf; - QHexPosition pos{line, column}; - - if(applyformat) - { - auto offset = m_hexcursor->positionToOffset(pos); - bool hasdelegate = m_hexdelegate && m_hexdelegate->render(offset, b, cf, this); - - if(!hasdelegate) - { - auto it = m_options.bytecolors.find(b); - - if(it != m_options.bytecolors.end()) - { - if(it->background.isValid()) cf.setBackground(it->background); - if(it->foreground.isValid()) cf.setForeground(it->foreground); - } - } - - const auto* metadataline = m_hexmetadata->find(line); - - if(metadataline) - { - for(const auto& metadata : *metadataline) - { - if(offset < metadata.begin || offset >= metadata.end) continue; - - if(!hasdelegate) - { - if(metadata.foreground.isValid()) cf.setForeground(metadata.foreground); - - if(metadata.background.isValid()) - { - cf.setBackground(metadata.background); - - if(!metadata.foreground.isValid()) - cf.setForeground(this->getReadableColor(metadata.background)); - } - } - - if(!metadata.comment.isEmpty()) - { - cf.setUnderlineColor(m_options.commentcolor.isValid() ? m_options.commentcolor : this->palette().color(QPalette::WindowText)); - cf.setUnderlineStyle(QTextCharFormat::UnderlineStyle::SingleUnderline); - } - - if(offset == metadata.begin) // Remove previous metadata's style, if needed - { - if(metadata.comment.isEmpty()) selcf.setUnderlineStyle(QTextCharFormat::UnderlineStyle::NoUnderline); - if(!metadata.foreground.isValid()) selcf.setForeground(Qt::color1); - if(!metadata.background.isValid()) selcf.setBackground(Qt::transparent); - } - - if(offset < metadata.end - 1 && column < this->getLastColumn(line)) - selcf = cf; - } - } - - if(hasdelegate && column < this->getLastColumn(line)) selcf = cf; - } - - if(this->hexCursor()->isSelected(line, column)) - { - auto offset = this->hexCursor()->positionToOffset(pos); - auto selend = this->hexCursor()->selectionEndOffset(); - - cf.setBackground(this->palette().color(QPalette::Normal, QPalette::Highlight)); - cf.setForeground(this->palette().color(QPalette::Normal, QPalette::HighlightedText)); - if(offset < selend && column < this->getLastColumn(line)) selcf = cf; - } - - if(this->hexCursor()->position() == pos) - { - auto cursorbg = this->palette().color(this->hasFocus() ? QPalette::Normal : QPalette::Disabled, QPalette::WindowText); - auto cursorfg = this->palette().color(this->hasFocus() ? QPalette::Normal : QPalette::Disabled, QPalette::Base); - auto discursorbg = this->palette().color(QPalette::Disabled, QPalette::WindowText); - auto discursorfg = this->palette().color(QPalette::Disabled, QPalette::Base); - - switch(m_hexcursor->mode()) - { - case QHexCursor::Mode::Insert: - cf.setUnderlineColor(m_currentarea == area ? cursorbg : discursorbg); - cf.setUnderlineStyle(QTextCharFormat::UnderlineStyle::SingleUnderline); - break; - - case QHexCursor::Mode::Overwrite: - cf.setBackground(m_currentarea == area ? cursorbg : discursorbg); - cf.setForeground(m_currentarea == area ? cursorfg : discursorfg); - break; - } - } - - c.insertText(s, cf); - return selcf; -} - -void QHexView::moveNext(bool select) -{ - auto line = this->hexCursor()->line(), column = this->hexCursor()->column(); - - if(column >= m_options.linelength - 1) - { - line++; - column = 0; - } - else - column++; - - qint64 offset = this->hexCursor()->mode() == QHexCursor::Mode::Insert ? 1 : 0; - if(select) this->hexCursor()->select(qMin(line, this->lines()), qMin(column, this->getLastColumn(line) + offset)); - else this->hexCursor()->move(qMin(line, this->lines()), qMin(column, this->getLastColumn(line) + offset)); -} - -void QHexView::movePrevious(bool select) -{ - auto line = this->hexCursor()->line(), column = this->hexCursor()->column(); - - if(column <= 0) - { - if(!line) return; - column = this->getLine(--line).size() - 1; - } - else - column--; - - if(select) this->hexCursor()->select(qMin(line, this->lines()), qMin(column, this->getLastColumn(line))); - else this->hexCursor()->move(qMin(line, this->lines()), qMin(column, this->getLastColumn(line))); -} - -bool QHexView::keyPressMove(QKeyEvent* e) -{ - if(e->matches(QKeySequence::MoveToNextChar) || e->matches(QKeySequence::SelectNextChar)) - this->moveNext(e->matches(QKeySequence::SelectNextChar)); - else if(e->matches(QKeySequence::MoveToPreviousChar) || e->matches(QKeySequence::SelectPreviousChar)) - this->movePrevious(e->matches(QKeySequence::SelectPreviousChar)); - else if(e->matches(QKeySequence::MoveToNextLine) || e->matches(QKeySequence::SelectNextLine)) - { - if(this->hexCursor()->line() == this->lastLine()) return true; - auto nextline = this->hexCursor()->line() + 1; - if(e->matches(QKeySequence::MoveToNextLine)) this->hexCursor()->move(nextline, this->hexCursor()->column()); - else this->hexCursor()->select(nextline, this->hexCursor()->column()); - } - else if(e->matches(QKeySequence::MoveToPreviousLine) || e->matches(QKeySequence::SelectPreviousLine)) - { - if(!this->hexCursor()->line()) return true; - auto prevline = this->hexCursor()->line() - 1; - if(e->matches(QKeySequence::MoveToPreviousLine)) this->hexCursor()->move(prevline, this->hexCursor()->column()); - else this->hexCursor()->select(prevline, this->hexCursor()->column()); - } - else if(e->matches(QKeySequence::MoveToNextPage) || e->matches(QKeySequence::SelectNextPage)) - { - if(this->lastLine() == this->hexCursor()->line()) return true; - auto pageline = qMin(this->lastLine(), this->hexCursor()->line() + this->visibleLines()); - if(e->matches(QKeySequence::MoveToNextPage)) this->hexCursor()->move(pageline, this->hexCursor()->column()); - else this->hexCursor()->select(pageline, this->hexCursor()->column()); - } - else if(e->matches(QKeySequence::MoveToPreviousPage) || e->matches(QKeySequence::SelectPreviousPage)) - { - if(!this->hexCursor()->line()) return true; - auto pageline = qMax(0, this->hexCursor()->line() - this->visibleLines()); - if(e->matches(QKeySequence::MoveToPreviousPage)) this->hexCursor()->move(pageline, this->hexCursor()->column()); - else this->hexCursor()->select(pageline, this->hexCursor()->column()); - } - else if(e->matches(QKeySequence::MoveToStartOfDocument) || e->matches(QKeySequence::SelectStartOfDocument)) - { - if(!this->hexCursor()->line()) return true; - if(e->matches(QKeySequence::MoveToStartOfDocument)) this->hexCursor()->move(0, 0); - else this->hexCursor()->select(0, 0); - } - else if(e->matches(QKeySequence::MoveToEndOfDocument) || e->matches(QKeySequence::SelectEndOfDocument)) - { - if(this->lastLine() == this->hexCursor()->line()) return true; - if(e->matches(QKeySequence::MoveToEndOfDocument)) this->hexCursor()->move(this->lastLine(), this->getLastColumn(this->hexCursor()->line())); - else this->hexCursor()->select(this->lastLine(), this->getLastColumn(this->lastLine())); - } - else if(e->matches(QKeySequence::MoveToStartOfLine) || e->matches(QKeySequence::SelectStartOfLine)) - { - auto offset = this->hexCursor()->positionToOffset({this->hexCursor()->line(), 0}); - if(e->matches(QKeySequence::MoveToStartOfLine)) this->hexCursor()->move(offset); - else this->hexCursor()->select(offset); - } - else if(e->matches(QKeySequence::SelectEndOfLine) || e->matches(QKeySequence::MoveToEndOfLine)) - { - auto offset = this->hexCursor()->positionToOffset({this->hexCursor()->line(), this->getLastColumn(this->hexCursor()->line())}); - if(e->matches(QKeySequence::SelectEndOfLine)) this->hexCursor()->select(offset); - else this->hexCursor()->move(offset); - } - else - return false; - - return true; -} - -bool QHexView::keyPressTextInput(QKeyEvent* e) -{ - if(m_readonly || e->text().isEmpty() || (e->modifiers() & Qt::ControlModifier)) return false; - - bool atend = m_hexcursor->offset() >= m_hexdocument->length(); - if(atend && m_hexcursor->mode() == QHexCursor::Mode::Overwrite) return false; - - char key = e->text().at(0).toLatin1(); - - switch(m_currentarea) - { - case QHexArea::Hex: { - if(!isxdigit(key)) return false; - - bool ok = false; - auto val = static_cast(QString(key).toUInt(&ok, 16)); - if(!ok) return false; - m_hexcursor->removeSelection(); - - quint8 ch = m_hexdocument->isEmpty() || m_hexcursor->offset() >= m_hexdocument->length() ? '\x00' : m_hexdocument->at(m_hexcursor->offset()); - ch = m_writing ? (ch << 4) | val : val; - - if(!m_writing && (m_hexcursor->mode() == QHexCursor::Mode::Insert)) m_hexdocument->insert(m_hexcursor->offset(), val); - else m_hexdocument->replace(m_hexcursor->offset(), ch); - - m_writing = !m_writing; - if(!m_writing) - this->moveNext(); - - break; - } - - case QHexArea::Ascii: { - if(!QChar::isPrint(key)) return false; - m_hexcursor->removeSelection(); - if(m_hexcursor->mode() == QHexCursor::Mode::Insert) m_hexdocument->insert(m_hexcursor->offset(), key); - else m_hexdocument->replace(m_hexcursor->offset(), key); - this->moveNext(); - break; - } - - default: return false; - } - - return true; -} - -bool QHexView::keyPressAction(QKeyEvent* e) -{ - if(e->modifiers() != Qt::NoModifier) - { - if(e->matches(QKeySequence::SelectAll)) this->selectAll(); - else if(!m_readonly && e->matches(QKeySequence::Undo)) this->undo(); - else if(!m_readonly && e->matches(QKeySequence::Redo)) this->redo(); - else if(!m_readonly && e->matches(QKeySequence::Cut)) this->cut(m_currentarea != QHexArea::Ascii); - else if(e->matches(QKeySequence::Copy)) this->copy(m_currentarea != QHexArea::Ascii); - else if(!m_readonly && e->matches(QKeySequence::Paste)) this->paste(m_currentarea != QHexArea::Ascii); - else return false; - - return true; - } - - if(m_readonly) return false; - - switch(e->key()) - { - case Qt::Key_Backspace: - case Qt::Key_Delete: { - if(!m_hexcursor->hasSelection()) { - auto offset = m_hexcursor->offset(); - if(offset <= 0) return true; - - if(e->key() == Qt::Key_Backspace) m_hexdocument->remove(offset - 1, 1); - else m_hexdocument->remove(offset, 1); - } - else - { - auto oldpos = m_hexcursor->selectionStart(); - m_hexcursor->removeSelection(); - m_hexcursor->move(oldpos); - } - - if(e->key() == Qt::Key_Backspace) this->movePrevious(); - m_writing = false; - break; - } - - case Qt::Key_Insert: - m_writing = false; - m_hexcursor->switchMode(); - break; - - default: return false; - } - - return true; -} - -bool QHexView::event(QEvent* e) -{ - switch(e->type()) - { - case QEvent::FontChange: - m_fontmetrics = QFontMetricsF(this->font()); - this->checkAndUpdate(true); - return true; - - case QEvent::ToolTip: { - if(m_hexdocument && (m_currentarea == QHexArea::Hex || m_currentarea == QHexArea::Ascii)) { - auto* helpevent = static_cast(e); - auto pos = this->positionFromPoint(helpevent->pos()); - auto comment = m_hexmetadata->getComment(pos.line, pos.column); - if(!comment.isEmpty()) QToolTip::showText(helpevent->globalPos(), comment); - return true; - } - - break; - } - - default: break; - } - - return QAbstractScrollArea::event(e); -} - -void QHexView::showEvent(QShowEvent* e) -{ - QAbstractScrollArea::showEvent(e); - this->checkAndUpdate(true); -} - -void QHexView::paintEvent(QPaintEvent*) -{ - if(!m_hexdocument) return; - - QPainter painter(this->viewport()); - if(m_hexdelegate) m_hexdelegate->paint(&painter, this); - else this->paint(&painter); -} - -void QHexView::resizeEvent(QResizeEvent* e) -{ - this->checkState(); - QAbstractScrollArea::resizeEvent(e); -} - -void QHexView::focusInEvent(QFocusEvent* e) -{ - QAbstractScrollArea::focusInEvent(e); - if(m_hexdocument) this->viewport()->update(); -} - -void QHexView::focusOutEvent(QFocusEvent* e) -{ - QAbstractScrollArea::focusOutEvent(e); - if(m_hexdocument) this->viewport()->update(); -} - -void QHexView::mousePressEvent(QMouseEvent* e) -{ - QAbstractScrollArea::mousePressEvent(e); - if(!m_hexdocument || e->button() != Qt::LeftButton) return; - - auto pos = this->positionFromPoint(e->pos()); - if(!pos.isValid()) return; - - auto area = this->areaFromPoint(e->pos()); - qhexview_fmtprint("%d", static_cast(area)); - - switch(area) - { - case QHexArea::Address: this->hexCursor()->move(pos.line, 0); break; - case QHexArea::Hex: m_currentarea = area; this->hexCursor()->move(pos); break; - case QHexArea::Ascii: m_currentarea = area; this->hexCursor()->move(pos.line, pos.column); break; - default: return; - } - - this->viewport()->update(); -} - -void QHexView::mouseMoveEvent(QMouseEvent* e) -{ - QAbstractScrollArea::mouseMoveEvent(e); - if(!this->hexCursor()) return; - - e->accept(); - auto area = this->areaFromPoint(e->pos()); - - switch(area) - { - case QHexArea::Header: this->viewport()->setCursor(Qt::ArrowCursor); return; - case QHexArea::Address: this->viewport()->setCursor(Qt::ArrowCursor); break; - default: this->viewport()->setCursor(Qt::IBeamCursor); break; - } - - if(e->buttons() == Qt::LeftButton) - { - auto pos = this->positionFromPoint(e->pos()); - if(!pos.isValid()) return; - if(area == QHexArea::Ascii || area == QHexArea::Hex) m_currentarea = area; - this->hexCursor()->select(pos); - } -} - -void QHexView::wheelEvent(QWheelEvent* e) -{ - e->ignore(); -#if defined Q_OS_OSX - // In macOS scrollbar invisibility should not prevent scrolling from working - if(!m_hexdocument) return; -#else - if(!m_hexdocument || !this->verticalScrollBar()->isVisible()) return; -#endif - auto ydelta = e->angleDelta().y(); - if(ydelta > 0) this->verticalScrollBar()->setValue(this->verticalScrollBar()->value() - m_options.scrollsteps); - else if(ydelta < 0) this->verticalScrollBar()->setValue(this->verticalScrollBar()->value() + m_options.scrollsteps); -} - -void QHexView::keyPressEvent(QKeyEvent* e) -{ - bool handled = false; - - if(this->hexCursor()) - { - handled = this->keyPressMove(e); - if(!handled) handled = this->keyPressAction(e); - if(!handled) handled = this->keyPressTextInput(e); - } - - if(handled) e->accept(); - else QAbstractScrollArea::keyPressEvent(e); -} - -QString QHexView::reduced(const QString& s, int maxlen) -{ - if(s.length() <= maxlen) return s.leftJustified(maxlen); - return s.mid(0, maxlen - 1) + "\u2026"; -} - -bool QHexView::isColorLight(QColor c) -{ - return std::sqrt(0.299 * std::pow(c.red(), 2) + - 0.587 * std::pow(c.green(), 2) + - 0.114 * std::pow(c.blue(), 2)) > 127.5; -} - -QColor QHexView::getReadableColor(QColor c) const -{ - QPalette palette = this->palette(); - return QHexView::isColorLight(c) ? palette.color(QPalette::Normal, QPalette::WindowText) : palette.color(QPalette::Normal, QPalette::HighlightedText); -} - -QByteArray QHexView::selectedBytes() const { return m_hexcursor->hasSelection() ? m_hexdocument->read(m_hexcursor->selectionStartOffset(), m_hexcursor->selectionLength()) : QByteArray{ }; } -QByteArray QHexView::getLine(qint64 line) const { return m_hexdocument ? m_hexdocument->read(line * m_options.linelength, m_options.linelength) : QByteArray{ }; } diff --git a/UEFITool/qhexview5/qhexview.h b/UEFITool/qhexview5/qhexview.h deleted file mode 100644 index 6ecafa7..0000000 --- a/UEFITool/qhexview5/qhexview.h +++ /dev/null @@ -1,169 +0,0 @@ -#pragma once - -#define QHEXVIEW_VERSION 5.0 - -#include -#include -#include -#include -#include -#include "model/qhexdelegate.h" -#include "model/qhexdocument.h" -#include "model/qhexcursor.h" - -#if defined(QHEXVIEW_ENABLE_DIALOGS) -class HexFindDialog; -#endif - -class QHexView : public QAbstractScrollArea -{ - Q_OBJECT - - public: - enum class CopyMode { Visual, HexArraySquare, HexArrayCurly, HexArrayChar }; - Q_ENUM(CopyMode); - - public: - explicit QHexView(QWidget *parent = nullptr); - QRectF headerRect() const; - QRectF addressRect() const; - QRectF hexRect() const; - QRectF asciiRect() const; - QHexDocument* hexDocument() const; - QHexCursor* hexCursor() const; - const QHexMetadata* hexMetadata() const; - QHexOptions options() const; - QColor getReadableColor(QColor c) const; - QByteArray selectedBytes() const; - QByteArray getLine(qint64 line) const; - unsigned int addressWidth() const; - unsigned int lineLength() const; - bool canUndo() const; - bool canRedo() const; - quint64 offset() const; - quint64 address() const; - QHexPosition position() const; - QHexPosition selectionStart() const; - QHexPosition selectionEnd() const; - quint64 selectionStartOffset() const; - quint64 selectionEndOffset() const; - quint64 baseAddress() const; - quint64 lines() const; - qint64 replace(const QVariant& oldvalue, const QVariant& newvalue, qint64 offset, QHexFindMode mode = QHexFindMode::Text, unsigned int options = QHexFindOptions::None, QHexFindDirection fd = QHexFindDirection::Forward) const; - qint64 find(const QVariant& value, qint64 offset, QHexFindMode mode = QHexFindMode::Text, unsigned int options = QHexFindOptions::None, QHexFindDirection fd = QHexFindDirection::Forward) const; - void setOptions(const QHexOptions& options); - void setBaseAddress(quint64 baseaddress); - void setDelegate(QHexDelegate* rd); - void setDocument(QHexDocument* doc); - void setData(const QByteArray& ba); - void setData(QHexBuffer* buffer); - void setCursorMode(QHexCursor::Mode mode); - void setByteColor(quint8 b, QHexColor c); - void setByteForeground(quint8 b, QColor c); - void setByteBackground(quint8 b, QColor c); - void setMetadata(qint64 begin, qint64 end, const QColor &fgcolor, const QColor &bgcolor, const QString &comment); - void setForeground(qint64 begin, qint64 end, const QColor &fgcolor); - void setBackground(qint64 begin, qint64 end, const QColor &bgcolor); - void setComment(qint64 begin, qint64 end, const QString& comment); - void setMetadataSize(qint64 begin, qint64 length, const QColor &fgcolor, const QColor &bgcolor, const QString &comment); - void setForegroundSize(qint64 begin, qint64 length, const QColor &fgcolor); - void setBackgroundSize(qint64 begin, qint64 length, const QColor &bgcolor); - void setCommentSize(qint64 begin, qint64 length, const QString& comment); - void removeMetadata(qint64 line); - void removeBackground(qint64 line); - void removeForeground(qint64 line); - void removeComments(qint64 line); - void unhighlight(qint64 line); - void clearMetadata(); - - public Q_SLOTS: -#if defined(QHEXVIEW_ENABLE_DIALOGS) - void showFind(); - void showReplace(); -#endif - void undo(); - void redo(); - void cut(bool hex = false); - void copyAs(CopyMode mode = CopyMode::Visual) const; - void copy(bool hex = false) const; - void paste(bool hex = false); - void selectAll(); - void removeSelection(); - void switchMode(); - void setAddressWidth(unsigned int w); - void setLineLength(unsigned int l); - void setGroupLength(unsigned int l); - void setScrollSteps(unsigned int l); - void setReadOnly(bool r); - void setAutoWidth(bool r); - - private: - void paint(QPainter* painter) const; - void checkOptions(); - void checkState(); - void checkAndUpdate(bool calccolumns = false); - void calcColumns(); - void ensureVisible(); - void drawSeparators(QPainter* p) const; - void drawHeader(QTextCursor& c) const; - void drawDocument(QTextCursor& c) const; - QTextCharFormat drawFormat(QTextCursor& c, quint8 b, const QString& s, QHexArea area, qint64 line, qint64 column, bool applyformat) const; - unsigned int calcAddressWidth() const; - int visibleLines(bool absolute = false) const; - qint64 getLastColumn(qint64 line) const; - qint64 lastLine() const; - qreal getNCellsWidth(int n) const; - qreal hexColumnWidth() const; - qreal hexColumnX() const; - qreal asciiColumnX() const; - qreal endColumnX() const; - qreal cellWidth() const; - qreal lineHeight() const; - QHexPosition positionFromPoint(QPoint pt) const; - QPoint absolutePoint(QPoint pt) const; - QHexArea areaFromPoint(QPoint pt) const; - void moveNext(bool select = false); - void movePrevious(bool select = false); - bool keyPressMove(QKeyEvent* e); - bool keyPressTextInput(QKeyEvent* e); - bool keyPressAction(QKeyEvent* e); - - protected: - bool event(QEvent* e) override; - void showEvent(QShowEvent* e) override; - void paintEvent(QPaintEvent*) override; - void resizeEvent(QResizeEvent* e) override; - void focusInEvent(QFocusEvent* e) override; - void focusOutEvent(QFocusEvent* e) override; - void mousePressEvent(QMouseEvent* e) override; - void mouseMoveEvent(QMouseEvent* e) override; - void wheelEvent(QWheelEvent* e) override; - void keyPressEvent(QKeyEvent *e) override; - - private: - static QString reduced(const QString& s, int maxlen); - static bool isColorLight(QColor c); - - Q_SIGNALS: - void dataChanged(const QByteArray& data, quint64 offset, QHexDocument::ChangeReason reason); - void positionChanged(); - void modeChanged(); - - private: - bool m_readonly{false}, m_writing{false}, m_autowidth{false}; - QHexArea m_currentarea{QHexArea::Ascii}; - QList m_hexcolumns; - QFontMetricsF m_fontmetrics; - QHexOptions m_options; - QHexCursor* m_hexcursor{nullptr}; - QHexDocument* m_hexdocument{nullptr}; - QHexMetadata* m_hexmetadata{nullptr}; - QHexDelegate* m_hexdelegate{nullptr}; -#if defined(QHEXVIEW_ENABLE_DIALOGS) - HexFindDialog *m_hexdlgfind{nullptr}, *m_hexdlgreplace{nullptr}; -#endif - - friend class QHexDelegate; - friend class QHexCursor; -}; - diff --git a/UEFITool/uefitool.cpp b/UEFITool/uefitool.cpp index ea3f309..aa6ac32 100644 --- a/UEFITool/uefitool.cpp +++ b/UEFITool/uefitool.cpp @@ -245,9 +245,11 @@ void UEFITool::populateUi(const QModelIndex ¤t) || type == Types::SlicData || type == Types::NvarEntry || type == Types::VssEntry - || type == Types::FsysEntry + || type == Types::SysFEntry || type == Types::EvsaEntry - || type == Types::FlashMapEntry + || type == Types::PhoenixFlashMapEntry + || type == Types::InsydeFlashDeviceMapEntry + || type == Types::DellDvarEntry || type == Types::IfwiHeader || type == Types::IfwiPartition || type == Types::FptPartition @@ -263,10 +265,12 @@ void UEFITool::populateUi(const QModelIndex ¤t) ui->menuStoreActions->setEnabled(type == Types::VssStore || type == Types::Vss2Store || type == Types::FdcStore - || type == Types::FsysStore + || type == Types::SysFStore || type == Types::EvsaStore || type == Types::FtwStore - || type == Types::FlashMapStore + || type == Types::PhoenixFlashMapStore + || type == Types::InsydeFlashDeviceMapStore + || type == Types::DellDvarStore || type == Types::NvarGuidStore || type == Types::CmdbStore || type == Types::FptStore @@ -305,8 +309,6 @@ void UEFITool::search() if (searchDialog->exec() != QDialog::Accepted) return; - QModelIndex rootIndex = model->index(0, 0); - int index = searchDialog->ui->tabWidget->currentIndex(); if (index == 0) { // Hex pattern searchDialog->ui->hexEdit->setFocus(); @@ -320,7 +322,7 @@ void UEFITool::search() mode = SEARCH_MODE_BODY; else mode = SEARCH_MODE_ALL; - ffsFinder->findHexPattern(rootIndex, pattern, mode); + ffsFinder->findHexPattern(pattern, mode); showFinderMessages(); } else if (index == 1) { // GUID @@ -336,7 +338,7 @@ void UEFITool::search() mode = SEARCH_MODE_BODY; else mode = SEARCH_MODE_ALL; - ffsFinder->findGuidPattern(rootIndex, pattern, mode); + ffsFinder->findGuidPattern(pattern, mode); showFinderMessages(); } else if (index == 2) { // Text string @@ -351,7 +353,7 @@ void UEFITool::search() mode = SEARCH_MODE_BODY; else mode = SEARCH_MODE_ALL; - ffsFinder->findTextPattern(rootIndex, pattern, mode, searchDialog->ui->textUnicodeCheckBox->isChecked(), + ffsFinder->findTextPattern(pattern, mode, searchDialog->ui->textUnicodeCheckBox->isChecked(), (Qt::CaseSensitivity) searchDialog->ui->textCaseSensitiveCheckBox->isChecked()); showFinderMessages(); } @@ -583,7 +585,7 @@ void UEFITool::about() QMessageBox::about(this, tr("About UEFITool"), tr("UEFITool %1.

" - "Copyright (c) 2013-2023, Nikolaj Schlej.

" + "Copyright (c) 2013-2025, Nikolaj (CodeRush) Schlej, Vitaly (vit9696) Cheptsov, et al.

" "Program icon made by Alexander Zhidkov.

" "GUI uses QHexView made by Antonio Davide.
" "Qt-less engine uses Bstrlib made by Paul Hsieh.
" @@ -909,10 +911,12 @@ void UEFITool::contextMenuEvent(QContextMenuEvent* event) case Types::VssStore: case Types::Vss2Store: case Types::FdcStore: - case Types::FsysStore: + case Types::SysFStore: case Types::EvsaStore: case Types::FtwStore: - case Types::FlashMapStore: + case Types::PhoenixFlashMapStore: + case Types::InsydeFlashDeviceMapStore: + case Types::DellDvarStore: case Types::NvarGuidStore: case Types::CmdbStore: case Types::FptStore: @@ -945,7 +949,7 @@ void UEFITool::readSettings() // Set monospace font QString fontName; int fontSize; -#if defined Q_OS_OSX +#if defined Q_OS_MACOS fontName = settings.value("mainWindow/fontName", QString("Menlo")).toString(); fontSize = settings.value("mainWindow/fontSize", 10).toInt(); #elif defined Q_OS_WIN diff --git a/UEFITool/uefitool.pro b/UEFITool/uefitool.pro index 44f23ce..0f396f1 100644 --- a/UEFITool/uefitool.pro +++ b/UEFITool/uefitool.pro @@ -51,6 +51,17 @@ HEADERS += uefitool.h \ ../common/digest/sha2.h \ ../common/digest/sm3.h \ ../common/generated/ami_nvar.h \ + ../common/generated/apple_sysf.h \ + ../common/generated/dell_dvar.h \ + ../common/generated/edk2_vss.h \ + ../common/generated/edk2_vss2.h \ + ../common/generated/edk2_ftw.h \ + ../common/generated/insyde_fdc.h \ + ../common/generated/insyde_fdm.h \ + ../common/generated/ms_slic_marker.h \ + ../common/generated/ms_slic_pubkey.h \ + ../common/generated/phoenix_flm.h \ + ../common/generated/phoenix_evsa.h \ ../common/generated/intel_acbp_v1.h \ ../common/generated/intel_acbp_v2.h \ ../common/generated/intel_keym_v1.h \ @@ -62,20 +73,21 @@ HEADERS += uefitool.h \ ../common/zlib/zlib.h \ ../common/zlib/crc32.h \ ../version.h \ - qhexview5/model/buffer/qhexbuffer.h \ - qhexview5/model/buffer/qdevicebuffer.h \ - qhexview5/model/buffer/qmemorybuffer.h \ - qhexview5/model/commands/hexcommand.h \ - qhexview5/model/commands/insertcommand.h \ - qhexview5/model/commands/removecommand.h \ - qhexview5/model/commands/replacecommand.h \ - qhexview5/model/qhexcursor.h \ - qhexview5/model/qhexdelegate.h \ - qhexview5/model/qhexdocument.h \ - qhexview5/model/qhexmetadata.h \ - qhexview5/model/qhexoptions.h \ - qhexview5/model/qhexutils.h \ - qhexview5/qhexview.h + QHexView/include/QHexView/model/buffer/qhexbuffer.h \ + QHexView/include/QHexView/model/buffer/qdevicebuffer.h \ + QHexView/include/QHexView/model/buffer/qmemorybuffer.h \ + QHexView/include/QHexView/model/buffer/qmappedfilebuffer.h \ + QHexView/include/QHexView/model/commands/hexcommand.h \ + QHexView/include/QHexView/model/commands/insertcommand.h \ + QHexView/include/QHexView/model/commands/removecommand.h \ + QHexView/include/QHexView/model/commands/replacecommand.h \ + QHexView/include/QHexView/model/qhexcursor.h \ + QHexView/include/QHexView/model/qhexdelegate.h \ + QHexView/include/QHexView/model/qhexdocument.h \ + QHexView/include/QHexView/model/qhexmetadata.h \ + QHexView/include/QHexView/model/qhexoptions.h \ + QHexView/include/QHexView/model/qhexutils.h \ + QHexView/include/QHexView/qhexview.h SOURCES += uefitool_main.cpp \ uefitool.cpp \ @@ -117,6 +129,17 @@ SOURCES += uefitool_main.cpp \ ../common/digest/sha512.c \ ../common/digest/sm3.c \ ../common/generated/ami_nvar.cpp \ + ../common/generated/apple_sysf.cpp \ + ../common/generated/dell_dvar.cpp \ + ../common/generated/edk2_vss.cpp \ + ../common/generated/edk2_vss2.cpp \ + ../common/generated/edk2_ftw.cpp \ + ../common/generated/insyde_fdc.cpp \ + ../common/generated/insyde_fdm.cpp \ + ../common/generated/ms_slic_marker.cpp \ + ../common/generated/ms_slic_pubkey.cpp \ + ../common/generated/phoenix_flm.cpp \ + ../common/generated/phoenix_evsa.cpp \ ../common/generated/intel_acbp_v1.cpp \ ../common/generated/intel_acbp_v2.cpp \ ../common/generated/intel_keym_v1.cpp \ @@ -138,19 +161,22 @@ SOURCES += uefitool_main.cpp \ ../common/zlib/trees.c \ ../common/zlib/uncompr.c \ ../common/zlib/zutil.c \ - qhexview5/model/buffer/qhexbuffer.cpp \ - qhexview5/model/buffer/qdevicebuffer.cpp \ - qhexview5/model/buffer/qmemorybuffer.cpp \ - qhexview5/model/commands/hexcommand.cpp \ - qhexview5/model/commands/insertcommand.cpp \ - qhexview5/model/commands/removecommand.cpp \ - qhexview5/model/commands/replacecommand.cpp \ - qhexview5/model/qhexcursor.cpp \ - qhexview5/model/qhexdelegate.cpp \ - qhexview5/model/qhexdocument.cpp \ - qhexview5/model/qhexmetadata.cpp \ - qhexview5/model/qhexutils.cpp \ - qhexview5/qhexview.cpp + QHexView/src/model/buffer/qhexbuffer.cpp \ + QHexView/src/model/buffer/qdevicebuffer.cpp \ + QHexView/src/model/buffer/qmemorybuffer.cpp \ + QHexView/src/model/buffer/qmappedfilebuffer.cpp \ + QHexView/src/model/commands/hexcommand.cpp \ + QHexView/src/model/commands/insertcommand.cpp \ + QHexView/src/model/commands/removecommand.cpp \ + QHexView/src/model/commands/replacecommand.cpp \ + QHexView/src/model/qhexcursor.cpp \ + QHexView/src/model/qhexdelegate.cpp \ + QHexView/src/model/qhexdocument.cpp \ + QHexView/src/model/qhexmetadata.cpp \ + QHexView/src/model/qhexutils.cpp \ + QHexView/src/qhexview.cpp + +INCLUDEPATH += QHexView/include/ FORMS += uefitool.ui \ searchdialog.ui \ diff --git a/UEFITool/uefitool_main.cpp b/UEFITool/uefitool_main.cpp index 3f83971..a932a9b 100644 --- a/UEFITool/uefitool_main.cpp +++ b/UEFITool/uefitool_main.cpp @@ -26,7 +26,9 @@ public: setOrganizationName("CodeRush"); setOrganizationDomain("coderush.me"); setApplicationName("UEFITool"); - +#if QT_VERSION >= QT_VERSION_CHECK(5, 7, 0) + setDesktopFileName("uefitool"); +#endif tool = new UEFITool(); } diff --git a/appstream/appdata.xml b/appstream/appdata.xml index f2309b3..c67deaa 100644 --- a/appstream/appdata.xml +++ b/appstream/appdata.xml @@ -13,7 +13,7 @@ - + https://github.com/LongSoft/UEFITool LongSoft diff --git a/common/LZMA/SDK/C/7zTypes.h b/common/LZMA/SDK/C/7zTypes.h index f7d7071..5b77420 100644 --- a/common/LZMA/SDK/C/7zTypes.h +++ b/common/LZMA/SDK/C/7zTypes.h @@ -1,8 +1,8 @@ /* 7zTypes.h -- Basic types -2022-04-01 : Igor Pavlov : Public domain */ +2024-01-24 : Igor Pavlov : Public domain */ -#ifndef __7Z_TYPES_H -#define __7Z_TYPES_H +#ifndef ZIP7_7Z_TYPES_H +#define ZIP7_7Z_TYPES_H #ifdef _WIN32 /* #include */ @@ -52,6 +52,11 @@ typedef int SRes; #define MY_ALIGN(n) #endif #else + /* + // C11/C++11: + #include + #define MY_ALIGN(n) alignas(n) + */ #define MY_ALIGN(n) __attribute__ ((aligned(n))) #endif @@ -62,7 +67,7 @@ typedef int SRes; typedef unsigned WRes; #define MY_SRes_HRESULT_FROM_WRes(x) HRESULT_FROM_WIN32(x) -// #define MY_HRES_ERROR__INTERNAL_ERROR MY_SRes_HRESULT_FROM_WRes(ERROR_INTERNAL_ERROR) +// #define MY_HRES_ERROR_INTERNAL_ERROR MY_SRes_HRESULT_FROM_WRes(ERROR_INTERNAL_ERROR) #else // _WIN32 @@ -70,13 +75,13 @@ typedef unsigned WRes; typedef int WRes; // (FACILITY_ERRNO = 0x800) is 7zip's FACILITY constant to represent (errno) errors in HRESULT -#define MY__FACILITY_ERRNO 0x800 -#define MY__FACILITY_WIN32 7 -#define MY__FACILITY__WRes MY__FACILITY_ERRNO +#define MY_FACILITY_ERRNO 0x800 +#define MY_FACILITY_WIN32 7 +#define MY_FACILITY_WRes MY_FACILITY_ERRNO #define MY_HRESULT_FROM_errno_CONST_ERROR(x) ((HRESULT)( \ ( (HRESULT)(x) & 0x0000FFFF) \ - | (MY__FACILITY__WRes << 16) \ + | (MY_FACILITY_WRes << 16) \ | (HRESULT)0x80000000 )) #define MY_SRes_HRESULT_FROM_WRes(x) \ @@ -120,17 +125,17 @@ typedef int WRes; #define ERROR_INVALID_REPARSE_DATA ((HRESULT)0x80071128L) #define ERROR_REPARSE_TAG_INVALID ((HRESULT)0x80071129L) -// if (MY__FACILITY__WRes != FACILITY_WIN32), +// if (MY_FACILITY_WRes != FACILITY_WIN32), // we use FACILITY_WIN32 for COM errors: #define E_OUTOFMEMORY ((HRESULT)0x8007000EL) #define E_INVALIDARG ((HRESULT)0x80070057L) -#define MY__E_ERROR_NEGATIVE_SEEK ((HRESULT)0x80070083L) +#define MY_E_ERROR_NEGATIVE_SEEK ((HRESULT)0x80070083L) /* // we can use FACILITY_ERRNO for some COM errors, that have errno equivalents: #define E_OUTOFMEMORY MY_HRESULT_FROM_errno_CONST_ERROR(ENOMEM) #define E_INVALIDARG MY_HRESULT_FROM_errno_CONST_ERROR(EINVAL) -#define MY__E_ERROR_NEGATIVE_SEEK MY_HRESULT_FROM_errno_CONST_ERROR(EINVAL) +#define MY_E_ERROR_NEGATIVE_SEEK MY_HRESULT_FROM_errno_CONST_ERROR(EINVAL) */ #define TEXT(quote) quote @@ -156,18 +161,18 @@ typedef int WRes; #ifndef RINOK -#define RINOK(x) { int __result__ = (x); if (__result__ != 0) return __result__; } +#define RINOK(x) { const int _result_ = (x); if (_result_ != 0) return _result_; } #endif #ifndef RINOK_WRes -#define RINOK_WRes(x) { WRes __result__ = (x); if (__result__ != 0) return __result__; } +#define RINOK_WRes(x) { const WRes _result_ = (x); if (_result_ != 0) return _result_; } #endif typedef unsigned char Byte; typedef short Int16; typedef unsigned short UInt16; -#ifdef _LZMA_UINT32_IS_ULONG +#ifdef Z7_DECL_Int32_AS_long typedef long Int32; typedef unsigned long UInt32; #else @@ -206,37 +211,51 @@ typedef size_t SIZE_T; #endif // _WIN32 -#define MY_HRES_ERROR__INTERNAL_ERROR ((HRESULT)0x8007054FL) +#define MY_HRES_ERROR_INTERNAL_ERROR ((HRESULT)0x8007054FL) -#ifdef _SZ_NO_INT_64 - -/* define _SZ_NO_INT_64, if your compiler doesn't support 64-bit integers. - NOTES: Some code will work incorrectly in that case! */ +#ifdef Z7_DECL_Int64_AS_long typedef long Int64; typedef unsigned long UInt64; #else -#if defined(_MSC_VER) || defined(__BORLANDC__) +#if (defined(_MSC_VER) || defined(__BORLANDC__)) && !defined(__clang__) typedef __int64 Int64; typedef unsigned __int64 UInt64; -#define UINT64_CONST(n) n +#else +#if defined(__clang__) || defined(__GNUC__) +#include +typedef int64_t Int64; +typedef uint64_t UInt64; #else typedef long long int Int64; typedef unsigned long long int UInt64; -#define UINT64_CONST(n) n ## ULL +// #define UINT64_CONST(n) n ## ULL +#endif #endif #endif -#ifdef _LZMA_NO_SYSTEM_SIZE_T -typedef UInt32 SizeT; +#define UINT64_CONST(n) n + + +#ifdef Z7_DECL_SizeT_AS_unsigned_int +typedef unsigned int SizeT; #else typedef size_t SizeT; #endif +/* +#if (defined(_MSC_VER) && _MSC_VER <= 1200) +typedef size_t MY_uintptr_t; +#else +#include +typedef uintptr_t MY_uintptr_t; +#endif +*/ + typedef int BoolInt; /* typedef BoolInt Bool; */ #define True 1 @@ -244,23 +263,23 @@ typedef int BoolInt; #ifdef _WIN32 -#define MY_STD_CALL __stdcall +#define Z7_STDCALL __stdcall #else -#define MY_STD_CALL +#define Z7_STDCALL #endif #ifdef _MSC_VER #if _MSC_VER >= 1300 -#define MY_NO_INLINE __declspec(noinline) +#define Z7_NO_INLINE __declspec(noinline) #else -#define MY_NO_INLINE +#define Z7_NO_INLINE #endif -#define MY_FORCE_INLINE __forceinline +#define Z7_FORCE_INLINE __forceinline -#define MY_CDECL __cdecl -#define MY_FAST_CALL __fastcall +#define Z7_CDECL __cdecl +#define Z7_FASTCALL __fastcall #else // _MSC_VER @@ -268,27 +287,25 @@ typedef int BoolInt; || (defined(__clang__) && (__clang_major__ >= 4)) \ || defined(__INTEL_COMPILER) \ || defined(__xlC__) -#define MY_NO_INLINE __attribute__((noinline)) -// #define MY_FORCE_INLINE __attribute__((always_inline)) inline +#define Z7_NO_INLINE __attribute__((noinline)) +#define Z7_FORCE_INLINE __attribute__((always_inline)) inline #else -#define MY_NO_INLINE +#define Z7_NO_INLINE +#define Z7_FORCE_INLINE #endif -#define MY_FORCE_INLINE - - -#define MY_CDECL +#define Z7_CDECL #if defined(_M_IX86) \ || defined(__i386__) -// #define MY_FAST_CALL __attribute__((fastcall)) -// #define MY_FAST_CALL __attribute__((cdecl)) -#define MY_FAST_CALL +// #define Z7_FASTCALL __attribute__((fastcall)) +// #define Z7_FASTCALL __attribute__((cdecl)) +#define Z7_FASTCALL #elif defined(MY_CPU_AMD64) -// #define MY_FAST_CALL __attribute__((ms_abi)) -#define MY_FAST_CALL +// #define Z7_FASTCALL __attribute__((ms_abi)) +#define Z7_FASTCALL #else -#define MY_FAST_CALL +#define Z7_FASTCALL #endif #endif // _MSC_VER @@ -296,41 +313,49 @@ typedef int BoolInt; /* The following interfaces use first parameter as pointer to structure */ -typedef struct IByteIn IByteIn; -struct IByteIn +// #define Z7_C_IFACE_CONST_QUAL +#define Z7_C_IFACE_CONST_QUAL const + +#define Z7_C_IFACE_DECL(a) \ + struct a ## _; \ + typedef Z7_C_IFACE_CONST_QUAL struct a ## _ * a ## Ptr; \ + typedef struct a ## _ a; \ + struct a ## _ + + +Z7_C_IFACE_DECL (IByteIn) { - Byte (*Read)(const IByteIn *p); /* reads one byte, returns 0 in case of EOF or error */ + Byte (*Read)(IByteInPtr p); /* reads one byte, returns 0 in case of EOF or error */ }; #define IByteIn_Read(p) (p)->Read(p) -typedef struct IByteOut IByteOut; -struct IByteOut +Z7_C_IFACE_DECL (IByteOut) { - void (*Write)(const IByteOut *p, Byte b); + void (*Write)(IByteOutPtr p, Byte b); }; #define IByteOut_Write(p, b) (p)->Write(p, b) -typedef struct ISeqInStream ISeqInStream; -struct ISeqInStream +Z7_C_IFACE_DECL (ISeqInStream) { - SRes (*Read)(const ISeqInStream *p, void *buf, size_t *size); + SRes (*Read)(ISeqInStreamPtr p, void *buf, size_t *size); /* if (input(*size) != 0 && output(*size) == 0) means end_of_stream. (output(*size) < input(*size)) is allowed */ }; #define ISeqInStream_Read(p, buf, size) (p)->Read(p, buf, size) +/* try to read as much as avail in stream and limited by (*processedSize) */ +SRes SeqInStream_ReadMax(ISeqInStreamPtr stream, void *buf, size_t *processedSize); /* it can return SZ_ERROR_INPUT_EOF */ -SRes SeqInStream_Read(const ISeqInStream *stream, void *buf, size_t size); -SRes SeqInStream_Read2(const ISeqInStream *stream, void *buf, size_t size, SRes errorType); -SRes SeqInStream_ReadByte(const ISeqInStream *stream, Byte *buf); +// SRes SeqInStream_Read(ISeqInStreamPtr stream, void *buf, size_t size); +// SRes SeqInStream_Read2(ISeqInStreamPtr stream, void *buf, size_t size, SRes errorType); +SRes SeqInStream_ReadByte(ISeqInStreamPtr stream, Byte *buf); -typedef struct ISeqOutStream ISeqOutStream; -struct ISeqOutStream +Z7_C_IFACE_DECL (ISeqOutStream) { - size_t (*Write)(const ISeqOutStream *p, const void *buf, size_t size); + size_t (*Write)(ISeqOutStreamPtr p, const void *buf, size_t size); /* Returns: result - the number of actually written bytes. (result < size) means error */ }; @@ -344,29 +369,26 @@ typedef enum } ESzSeek; -typedef struct ISeekInStream ISeekInStream; -struct ISeekInStream +Z7_C_IFACE_DECL (ISeekInStream) { - SRes (*Read)(const ISeekInStream *p, void *buf, size_t *size); /* same as ISeqInStream::Read */ - SRes (*Seek)(const ISeekInStream *p, Int64 *pos, ESzSeek origin); + SRes (*Read)(ISeekInStreamPtr p, void *buf, size_t *size); /* same as ISeqInStream::Read */ + SRes (*Seek)(ISeekInStreamPtr p, Int64 *pos, ESzSeek origin); }; #define ISeekInStream_Read(p, buf, size) (p)->Read(p, buf, size) #define ISeekInStream_Seek(p, pos, origin) (p)->Seek(p, pos, origin) -typedef struct ILookInStream ILookInStream; -struct ILookInStream +Z7_C_IFACE_DECL (ILookInStream) { - SRes (*Look)(const ILookInStream *p, const void **buf, size_t *size); + SRes (*Look)(ILookInStreamPtr p, const void **buf, size_t *size); /* if (input(*size) != 0 && output(*size) == 0) means end_of_stream. (output(*size) > input(*size)) is not allowed (output(*size) < input(*size)) is allowed */ - SRes (*Skip)(const ILookInStream *p, size_t offset); + SRes (*Skip)(ILookInStreamPtr p, size_t offset); /* offset must be <= output(*size) of Look */ - - SRes (*Read)(const ILookInStream *p, void *buf, size_t *size); + SRes (*Read)(ILookInStreamPtr p, void *buf, size_t *size); /* reads directly (without buffer). It's same as ISeqInStream::Read */ - SRes (*Seek)(const ILookInStream *p, Int64 *pos, ESzSeek origin); + SRes (*Seek)(ILookInStreamPtr p, Int64 *pos, ESzSeek origin); }; #define ILookInStream_Look(p, buf, size) (p)->Look(p, buf, size) @@ -375,19 +397,18 @@ struct ILookInStream #define ILookInStream_Seek(p, pos, origin) (p)->Seek(p, pos, origin) -SRes LookInStream_LookRead(const ILookInStream *stream, void *buf, size_t *size); -SRes LookInStream_SeekTo(const ILookInStream *stream, UInt64 offset); +SRes LookInStream_LookRead(ILookInStreamPtr stream, void *buf, size_t *size); +SRes LookInStream_SeekTo(ILookInStreamPtr stream, UInt64 offset); /* reads via ILookInStream::Read */ -SRes LookInStream_Read2(const ILookInStream *stream, void *buf, size_t size, SRes errorType); -SRes LookInStream_Read(const ILookInStream *stream, void *buf, size_t size); - +SRes LookInStream_Read2(ILookInStreamPtr stream, void *buf, size_t size, SRes errorType); +SRes LookInStream_Read(ILookInStreamPtr stream, void *buf, size_t size); typedef struct { ILookInStream vt; - const ISeekInStream *realStream; + ISeekInStreamPtr realStream; size_t pos; size_t size; /* it's data size */ @@ -399,13 +420,13 @@ typedef struct void LookToRead2_CreateVTable(CLookToRead2 *p, int lookahead); -#define LookToRead2_Init(p) { (p)->pos = (p)->size = 0; } +#define LookToRead2_INIT(p) { (p)->pos = (p)->size = 0; } typedef struct { ISeqInStream vt; - const ILookInStream *realStream; + ILookInStreamPtr realStream; } CSecToLook; void SecToLook_CreateVTable(CSecToLook *p); @@ -415,20 +436,19 @@ void SecToLook_CreateVTable(CSecToLook *p); typedef struct { ISeqInStream vt; - const ILookInStream *realStream; + ILookInStreamPtr realStream; } CSecToRead; void SecToRead_CreateVTable(CSecToRead *p); -typedef struct ICompressProgress ICompressProgress; - -struct ICompressProgress +Z7_C_IFACE_DECL (ICompressProgress) { - SRes (*Progress)(const ICompressProgress *p, UInt64 inSize, UInt64 outSize); + SRes (*Progress)(ICompressProgressPtr p, UInt64 inSize, UInt64 outSize); /* Returns: result. (result != SZ_OK) means break. Value (UInt64)(Int64)-1 for size means unknown value. */ }; + #define ICompressProgress_Progress(p, inSize, outSize) (p)->Progress(p, inSize, outSize) @@ -466,13 +486,13 @@ struct ISzAlloc -#ifndef MY_container_of +#ifndef Z7_container_of /* -#define MY_container_of(ptr, type, m) container_of(ptr, type, m) -#define MY_container_of(ptr, type, m) CONTAINING_RECORD(ptr, type, m) -#define MY_container_of(ptr, type, m) ((type *)((char *)(ptr) - offsetof(type, m))) -#define MY_container_of(ptr, type, m) (&((type *)0)->m == (ptr), ((type *)(((char *)(ptr)) - MY_offsetof(type, m)))) +#define Z7_container_of(ptr, type, m) container_of(ptr, type, m) +#define Z7_container_of(ptr, type, m) CONTAINING_RECORD(ptr, type, m) +#define Z7_container_of(ptr, type, m) ((type *)((char *)(ptr) - offsetof(type, m))) +#define Z7_container_of(ptr, type, m) (&((type *)0)->m == (ptr), ((type *)(((char *)(ptr)) - MY_offsetof(type, m)))) */ /* @@ -481,24 +501,64 @@ struct ISzAlloc GCC 4.8.1 : classes with non-public variable members" */ -#define MY_container_of(ptr, type, m) ((type *)(void *)((char *)(void *)(1 ? (ptr) : &((type *)0)->m) - MY_offsetof(type, m))) +#define Z7_container_of(ptr, type, m) \ + ((type *)(void *)((char *)(void *) \ + (1 ? (ptr) : &((type *)NULL)->m) - MY_offsetof(type, m))) + +#define Z7_container_of_CONST(ptr, type, m) \ + ((const type *)(const void *)((const char *)(const void *) \ + (1 ? (ptr) : &((type *)NULL)->m) - MY_offsetof(type, m))) + +/* +#define Z7_container_of_NON_CONST_FROM_CONST(ptr, type, m) \ + ((type *)(void *)(const void *)((const char *)(const void *) \ + (1 ? (ptr) : &((type *)NULL)->m) - MY_offsetof(type, m))) +*/ #endif -#define CONTAINER_FROM_VTBL_SIMPLE(ptr, type, m) ((type *)(void *)(ptr)) +#define Z7_CONTAINER_FROM_VTBL_SIMPLE(ptr, type, m) ((type *)(void *)(ptr)) +// #define Z7_CONTAINER_FROM_VTBL(ptr, type, m) Z7_CONTAINER_FROM_VTBL_SIMPLE(ptr, type, m) +#define Z7_CONTAINER_FROM_VTBL(ptr, type, m) Z7_container_of(ptr, type, m) +// #define Z7_CONTAINER_FROM_VTBL(ptr, type, m) Z7_container_of_NON_CONST_FROM_CONST(ptr, type, m) + +#define Z7_CONTAINER_FROM_VTBL_CONST(ptr, type, m) Z7_container_of_CONST(ptr, type, m) + +#define Z7_CONTAINER_FROM_VTBL_CLS(ptr, type, m) Z7_CONTAINER_FROM_VTBL_SIMPLE(ptr, type, m) /* -#define CONTAINER_FROM_VTBL(ptr, type, m) CONTAINER_FROM_VTBL_SIMPLE(ptr, type, m) +#define Z7_CONTAINER_FROM_VTBL_CLS(ptr, type, m) Z7_CONTAINER_FROM_VTBL(ptr, type, m) */ -#define CONTAINER_FROM_VTBL(ptr, type, m) MY_container_of(ptr, type, m) +#if defined (__clang__) || defined(__GNUC__) +#define Z7_DIAGNOSTIC_IGNORE_BEGIN_CAST_QUAL \ + _Pragma("GCC diagnostic push") \ + _Pragma("GCC diagnostic ignored \"-Wcast-qual\"") +#define Z7_DIAGNOSTIC_IGNORE_END_CAST_QUAL \ + _Pragma("GCC diagnostic pop") +#else +#define Z7_DIAGNOSTIC_IGNORE_BEGIN_CAST_QUAL +#define Z7_DIAGNOSTIC_IGNORE_END_CAST_QUAL +#endif -#define CONTAINER_FROM_VTBL_CLS(ptr, type, m) CONTAINER_FROM_VTBL_SIMPLE(ptr, type, m) -/* -#define CONTAINER_FROM_VTBL_CLS(ptr, type, m) CONTAINER_FROM_VTBL(ptr, type, m) -*/ +#define Z7_CONTAINER_FROM_VTBL_TO_DECL_VAR(ptr, type, m, p) \ + Z7_DIAGNOSTIC_IGNORE_BEGIN_CAST_QUAL \ + type *p = Z7_CONTAINER_FROM_VTBL(ptr, type, m); \ + Z7_DIAGNOSTIC_IGNORE_END_CAST_QUAL + +#define Z7_CONTAINER_FROM_VTBL_TO_DECL_VAR_pp_vt_p(type) \ + Z7_CONTAINER_FROM_VTBL_TO_DECL_VAR(pp, type, vt, p) -#define MY_memset_0_ARRAY(a) memset((a), 0, sizeof(a)) +// #define ZIP7_DECLARE_HANDLE(name) typedef void *name; +#define Z7_DECLARE_HANDLE(name) struct name##_dummy{int unused;}; typedef struct name##_dummy *name; + + +#define Z7_memset_0_ARRAY(a) memset((a), 0, sizeof(a)) + +#ifndef Z7_ARRAY_SIZE +#define Z7_ARRAY_SIZE(a) (sizeof(a) / sizeof((a)[0])) +#endif + #ifdef _WIN32 @@ -527,3 +587,11 @@ struct ISzAlloc EXTERN_C_END #endif + +/* +#ifndef Z7_ST +#ifdef _7ZIP_ST +#define Z7_ST +#endif +#endif +*/ diff --git a/common/LZMA/SDK/C/7zVersion.h b/common/LZMA/SDK/C/7zVersion.h index 49ea81d..e82ba0b 100644 --- a/common/LZMA/SDK/C/7zVersion.h +++ b/common/LZMA/SDK/C/7zVersion.h @@ -1,7 +1,7 @@ -#define MY_VER_MAJOR 22 -#define MY_VER_MINOR 01 +#define MY_VER_MAJOR 24 +#define MY_VER_MINOR 9 #define MY_VER_BUILD 0 -#define MY_VERSION_NUMBERS "22.01" +#define MY_VERSION_NUMBERS "24.09" #define MY_VERSION MY_VERSION_NUMBERS #ifdef MY_CPU_NAME @@ -10,12 +10,12 @@ #define MY_VERSION_CPU MY_VERSION #endif -#define MY_DATE "2022-07-15" +#define MY_DATE "2024-11-29" #undef MY_COPYRIGHT #undef MY_VERSION_COPYRIGHT_DATE #define MY_AUTHOR_NAME "Igor Pavlov" #define MY_COPYRIGHT_PD "Igor Pavlov : Public domain" -#define MY_COPYRIGHT_CR "Copyright (c) 1999-2022 Igor Pavlov" +#define MY_COPYRIGHT_CR "Copyright (c) 1999-2024 Igor Pavlov" #ifdef USE_COPYRIGHT_CR #define MY_COPYRIGHT MY_COPYRIGHT_CR diff --git a/common/LZMA/SDK/C/7zWindows.h b/common/LZMA/SDK/C/7zWindows.h new file mode 100644 index 0000000..42c6db8 --- /dev/null +++ b/common/LZMA/SDK/C/7zWindows.h @@ -0,0 +1,101 @@ +/* 7zWindows.h -- StdAfx +2023-04-02 : Igor Pavlov : Public domain */ + +#ifndef ZIP7_INC_7Z_WINDOWS_H +#define ZIP7_INC_7Z_WINDOWS_H + +#ifdef _WIN32 + +#if defined(__clang__) +# pragma clang diagnostic push +#endif + +#if defined(_MSC_VER) + +#pragma warning(push) +#pragma warning(disable : 4668) // '_WIN32_WINNT' is not defined as a preprocessor macro, replacing with '0' for '#if/#elif' + +#if _MSC_VER == 1900 +// for old kit10 versions +// #pragma warning(disable : 4255) // winuser.h(13979): warning C4255: 'GetThreadDpiAwarenessContext': +#endif +// win10 Windows Kit: +#endif // _MSC_VER + +#if defined(_MSC_VER) && _MSC_VER <= 1200 && !defined(_WIN64) +// for msvc6 without sdk2003 +#define RPC_NO_WINDOWS_H +#endif + +#if defined(__MINGW32__) || defined(__MINGW64__) +// #if defined(__GNUC__) && !defined(__clang__) +#include +#else +#include +#endif +// #include +// #include + +// but if precompiled with clang-cl then we need +// #include +#if defined(_MSC_VER) +#pragma warning(pop) +#endif + +#if defined(__clang__) +# pragma clang diagnostic pop +#endif + +#if defined(_MSC_VER) && _MSC_VER <= 1200 && !defined(_WIN64) +#ifndef _W64 + +typedef long LONG_PTR, *PLONG_PTR; +typedef unsigned long ULONG_PTR, *PULONG_PTR; +typedef ULONG_PTR DWORD_PTR, *PDWORD_PTR; + +#define Z7_OLD_WIN_SDK +#endif // _W64 +#endif // _MSC_VER == 1200 + +#ifdef Z7_OLD_WIN_SDK + +#ifndef INVALID_FILE_ATTRIBUTES +#define INVALID_FILE_ATTRIBUTES ((DWORD)-1) +#endif +#ifndef INVALID_SET_FILE_POINTER +#define INVALID_SET_FILE_POINTER ((DWORD)-1) +#endif +#ifndef FILE_SPECIAL_ACCESS +#define FILE_SPECIAL_ACCESS (FILE_ANY_ACCESS) +#endif + +// ShlObj.h: +// #define BIF_NEWDIALOGSTYLE 0x0040 + +#pragma warning(disable : 4201) +// #pragma warning(disable : 4115) + +#undef VARIANT_TRUE +#define VARIANT_TRUE ((VARIANT_BOOL)-1) +#endif + +#endif // Z7_OLD_WIN_SDK + +#ifdef UNDER_CE +#undef VARIANT_TRUE +#define VARIANT_TRUE ((VARIANT_BOOL)-1) +#endif + + +#if defined(_MSC_VER) +#if _MSC_VER >= 1400 && _MSC_VER <= 1600 + // BaseTsd.h(148) : 'HandleToULong' : unreferenced inline function has been removed + // string.h + // #pragma warning(disable : 4514) +#endif +#endif + + +/* #include "7zTypes.h" */ + +#endif diff --git a/common/LZMA/SDK/C/Bra.c b/common/LZMA/SDK/C/Bra.c index 3b854d9..e61edf8 100644 --- a/common/LZMA/SDK/C/Bra.c +++ b/common/LZMA/SDK/C/Bra.c @@ -1,230 +1,709 @@ -/* Bra.c -- Converters for RISC code -2021-02-09 : Igor Pavlov : Public domain */ +/* Bra.c -- Branch converters for RISC code +2024-01-20 : Igor Pavlov : Public domain */ #include "Precomp.h" -#include "CpuArch.h" #include "Bra.h" +#include "RotateDefs.h" +#include "CpuArch.h" -SizeT ARM_Convert(Byte *data, SizeT size, UInt32 ip, int encoding) +#if defined(MY_CPU_SIZEOF_POINTER) \ + && ( MY_CPU_SIZEOF_POINTER == 4 \ + || MY_CPU_SIZEOF_POINTER == 8) + #define BR_CONV_USE_OPT_PC_PTR +#endif + +#ifdef BR_CONV_USE_OPT_PC_PTR +#define BR_PC_INIT pc -= (UInt32)(SizeT)p; +#define BR_PC_GET (pc + (UInt32)(SizeT)p) +#else +#define BR_PC_INIT pc += (UInt32)size; +#define BR_PC_GET (pc - (UInt32)(SizeT)(lim - p)) +// #define BR_PC_INIT +// #define BR_PC_GET (pc + (UInt32)(SizeT)(p - data)) +#endif + +#define BR_CONVERT_VAL(v, c) if (encoding) v += c; else v -= c; +// #define BR_CONVERT_VAL(v, c) if (!encoding) c = (UInt32)0 - c; v += c; + +#define Z7_BRANCH_CONV(name) z7_ ## name + +#define Z7_BRANCH_FUNC_MAIN(name) \ +static \ +Z7_FORCE_INLINE \ +Z7_ATTRIB_NO_VECTOR \ +Byte *Z7_BRANCH_CONV(name)(Byte *p, SizeT size, UInt32 pc, int encoding) + +#define Z7_BRANCH_FUNC_IMP(name, m, encoding) \ +Z7_NO_INLINE \ +Z7_ATTRIB_NO_VECTOR \ +Byte *m(name)(Byte *data, SizeT size, UInt32 pc) \ + { return Z7_BRANCH_CONV(name)(data, size, pc, encoding); } \ + +#ifdef Z7_EXTRACT_ONLY +#define Z7_BRANCH_FUNCS_IMP(name) \ + Z7_BRANCH_FUNC_IMP(name, Z7_BRANCH_CONV_DEC_2, 0) +#else +#define Z7_BRANCH_FUNCS_IMP(name) \ + Z7_BRANCH_FUNC_IMP(name, Z7_BRANCH_CONV_DEC_2, 0) \ + Z7_BRANCH_FUNC_IMP(name, Z7_BRANCH_CONV_ENC_2, 1) +#endif + +#if defined(__clang__) +#define BR_EXTERNAL_FOR +#define BR_NEXT_ITERATION continue; +#else +#define BR_EXTERNAL_FOR for (;;) +#define BR_NEXT_ITERATION break; +#endif + +#if defined(__clang__) && (__clang_major__ >= 8) \ + || defined(__GNUC__) && (__GNUC__ >= 1000) \ + // GCC is not good for __builtin_expect() here + /* || defined(_MSC_VER) && (_MSC_VER >= 1920) */ + // #define Z7_unlikely [[unlikely]] + // #define Z7_LIKELY(x) (__builtin_expect((x), 1)) + #define Z7_UNLIKELY(x) (__builtin_expect((x), 0)) + // #define Z7_likely [[likely]] +#else + // #define Z7_LIKELY(x) (x) + #define Z7_UNLIKELY(x) (x) + // #define Z7_likely +#endif + + +Z7_BRANCH_FUNC_MAIN(BranchConv_ARM64) { - Byte *p; + // Byte *p = data; const Byte *lim; - size &= ~(size_t)3; - ip += 4; - p = data; - lim = data + size; - - if (encoding) - - for (;;) + const UInt32 flag = (UInt32)1 << (24 - 4); + const UInt32 mask = ((UInt32)1 << 24) - (flag << 1); + size &= ~(SizeT)3; + // if (size == 0) return p; + lim = p + size; + BR_PC_INIT + pc -= 4; // because (p) will point to next instruction + + BR_EXTERNAL_FOR { + // Z7_PRAGMA_OPT_DISABLE_LOOP_UNROLL_VECTORIZE for (;;) { - if (p >= lim) - return (SizeT)(p - data); + UInt32 v; + if Z7_UNLIKELY(p == lim) + return p; + v = GetUi32a(p); p += 4; - if (p[-1] == 0xEB) - break; - } - { - UInt32 v = GetUi32(p - 4); - v <<= 2; - v += ip + (UInt32)(p - data); - v >>= 2; - v &= 0x00FFFFFF; - v |= 0xEB000000; - SetUi32(p - 4, v); - } - } - - for (;;) - { - for (;;) - { - if (p >= lim) - return (SizeT)(p - data); - p += 4; - if (p[-1] == 0xEB) - break; - } - { - UInt32 v = GetUi32(p - 4); - v <<= 2; - v -= ip + (UInt32)(p - data); - v >>= 2; - v &= 0x00FFFFFF; - v |= 0xEB000000; - SetUi32(p - 4, v); + if Z7_UNLIKELY(((v - 0x94000000) & 0xfc000000) == 0) + { + UInt32 c = BR_PC_GET >> 2; + BR_CONVERT_VAL(v, c) + v &= 0x03ffffff; + v |= 0x94000000; + SetUi32a(p - 4, v) + BR_NEXT_ITERATION + } + // v = rotlFixed(v, 8); v += (flag << 8) - 0x90; if Z7_UNLIKELY((v & ((mask << 8) + 0x9f)) == 0) + v -= 0x90000000; if Z7_UNLIKELY((v & 0x9f000000) == 0) + { + UInt32 z, c; + // v = rotrFixed(v, 8); + v += flag; if Z7_UNLIKELY(v & mask) continue; + z = (v & 0xffffffe0) | (v >> 26); + c = (BR_PC_GET >> (12 - 3)) & ~(UInt32)7; + BR_CONVERT_VAL(z, c) + v &= 0x1f; + v |= 0x90000000; + v |= z << 26; + v |= 0x00ffffe0 & ((z & (((flag << 1) - 1))) - flag); + SetUi32a(p - 4, v) + } } } } +Z7_BRANCH_FUNCS_IMP(BranchConv_ARM64) -SizeT ARMT_Convert(Byte *data, SizeT size, UInt32 ip, int encoding) +Z7_BRANCH_FUNC_MAIN(BranchConv_ARM) { - Byte *p; + // Byte *p = data; const Byte *lim; - size &= ~(size_t)1; - p = data; - lim = data + size - 4; - - if (encoding) + size &= ~(SizeT)3; + lim = p + size; + BR_PC_INIT + /* in ARM: branch offset is relative to the +2 instructions from current instruction. + (p) will point to next instruction */ + pc += 8 - 4; for (;;) { - UInt32 b1; for (;;) { - UInt32 b3; - if (p > lim) - return (SizeT)(p - data); - b1 = p[1]; - b3 = p[3]; - p += 2; - b1 ^= 8; - if ((b3 & b1) >= 0xF8) - break; + if Z7_UNLIKELY(p >= lim) { return p; } p += 4; if Z7_UNLIKELY(p[-1] == 0xeb) break; + if Z7_UNLIKELY(p >= lim) { return p; } p += 4; if Z7_UNLIKELY(p[-1] == 0xeb) break; } { - UInt32 v = - ((UInt32)b1 << 19) - + (((UInt32)p[1] & 0x7) << 8) - + (((UInt32)p[-2] << 11)) - + (p[0]); - - p += 2; - { - UInt32 cur = (ip + (UInt32)(p - data)) >> 1; - v += cur; - } - - p[-4] = (Byte)(v >> 11); - p[-3] = (Byte)(0xF0 | ((v >> 19) & 0x7)); - p[-2] = (Byte)v; - p[-1] = (Byte)(0xF8 | (v >> 8)); - } - } - - for (;;) - { - UInt32 b1; - for (;;) - { - UInt32 b3; - if (p > lim) - return (SizeT)(p - data); - b1 = p[1]; - b3 = p[3]; - p += 2; - b1 ^= 8; - if ((b3 & b1) >= 0xF8) - break; - } - { - UInt32 v = - ((UInt32)b1 << 19) - + (((UInt32)p[1] & 0x7) << 8) - + (((UInt32)p[-2] << 11)) - + (p[0]); - - p += 2; - { - UInt32 cur = (ip + (UInt32)(p - data)) >> 1; - v -= cur; - } - - /* - SetUi16(p - 4, (UInt16)(((v >> 11) & 0x7FF) | 0xF000)); - SetUi16(p - 2, (UInt16)(v | 0xF800)); - */ - - p[-4] = (Byte)(v >> 11); - p[-3] = (Byte)(0xF0 | ((v >> 19) & 0x7)); - p[-2] = (Byte)v; - p[-1] = (Byte)(0xF8 | (v >> 8)); + UInt32 v = GetUi32a(p - 4); + UInt32 c = BR_PC_GET >> 2; + BR_CONVERT_VAL(v, c) + v &= 0x00ffffff; + v |= 0xeb000000; + SetUi32a(p - 4, v) } } } +Z7_BRANCH_FUNCS_IMP(BranchConv_ARM) -SizeT PPC_Convert(Byte *data, SizeT size, UInt32 ip, int encoding) +Z7_BRANCH_FUNC_MAIN(BranchConv_PPC) { - Byte *p; + // Byte *p = data; const Byte *lim; - size &= ~(size_t)3; - ip -= 4; - p = data; - lim = data + size; - + size &= ~(SizeT)3; + lim = p + size; + BR_PC_INIT + pc -= 4; // because (p) will point to next instruction + for (;;) { + UInt32 v; for (;;) { - if (p >= lim) - return (SizeT)(p - data); + if Z7_UNLIKELY(p == lim) + return p; + // v = GetBe32a(p); + v = *(UInt32 *)(void *)p; p += 4; - /* if ((v & 0xFC000003) == 0x48000001) */ - if ((p[-4] & 0xFC) == 0x48 && (p[-1] & 3) == 1) - break; + // if ((v & 0xfc000003) == 0x48000001) break; + // if ((p[-4] & 0xFC) == 0x48 && (p[-1] & 3) == 1) break; + if Z7_UNLIKELY( + ((v - Z7_CONV_BE_TO_NATIVE_CONST32(0x48000001)) + & Z7_CONV_BE_TO_NATIVE_CONST32(0xfc000003)) == 0) break; } { - UInt32 v = GetBe32(p - 4); - if (encoding) - v += ip + (UInt32)(p - data); - else - v -= ip + (UInt32)(p - data); - v &= 0x03FFFFFF; + v = Z7_CONV_NATIVE_TO_BE_32(v); + { + UInt32 c = BR_PC_GET; + BR_CONVERT_VAL(v, c) + } + v &= 0x03ffffff; v |= 0x48000000; - SetBe32(p - 4, v); + SetBe32a(p - 4, v) } } } +Z7_BRANCH_FUNCS_IMP(BranchConv_PPC) -SizeT SPARC_Convert(Byte *data, SizeT size, UInt32 ip, int encoding) +#ifdef Z7_CPU_FAST_ROTATE_SUPPORTED +#define BR_SPARC_USE_ROTATE +#endif + +Z7_BRANCH_FUNC_MAIN(BranchConv_SPARC) { - Byte *p; + // Byte *p = data; const Byte *lim; - size &= ~(size_t)3; - ip -= 4; - p = data; - lim = data + size; - + const UInt32 flag = (UInt32)1 << 22; + size &= ~(SizeT)3; + lim = p + size; + BR_PC_INIT + pc -= 4; // because (p) will point to next instruction for (;;) { + UInt32 v; for (;;) { - if (p >= lim) - return (SizeT)(p - data); - /* - v = GetBe32(p); - p += 4; - m = v + ((UInt32)5 << 29); - m ^= (UInt32)7 << 29; - m += (UInt32)1 << 22; - if ((m & ((UInt32)0x1FF << 23)) == 0) - break; + if Z7_UNLIKELY(p == lim) + return p; + /* // the code without GetBe32a(): + { const UInt32 v = GetUi16a(p) & 0xc0ff; p += 4; if (v == 0x40 || v == 0xc07f) break; } */ + v = GetBe32a(p); p += 4; - if ((p[-4] == 0x40 && (p[-3] & 0xC0) == 0) || - (p[-4] == 0x7F && (p[-3] >= 0xC0))) + #ifdef BR_SPARC_USE_ROTATE + v = rotlFixed(v, 2); + v += (flag << 2) - 1; + if Z7_UNLIKELY((v & (3 - (flag << 3))) == 0) + #else + v += (UInt32)5 << 29; + v ^= (UInt32)7 << 29; + v += flag; + if Z7_UNLIKELY((v & (0 - (flag << 1))) == 0) + #endif break; } { - UInt32 v = GetBe32(p - 4); + // UInt32 v = GetBe32a(p - 4); + #ifndef BR_SPARC_USE_ROTATE v <<= 2; - if (encoding) - v += ip + (UInt32)(p - data); - else - v -= ip + (UInt32)(p - data); - - v &= 0x01FFFFFF; - v -= (UInt32)1 << 24; - v ^= 0xFF000000; + #endif + { + UInt32 c = BR_PC_GET; + BR_CONVERT_VAL(v, c) + } + v &= (flag << 3) - 1; + #ifdef BR_SPARC_USE_ROTATE + v -= (flag << 2) - 1; + v = rotrFixed(v, 2); + #else + v -= (flag << 2); v >>= 2; - v |= 0x40000000; - SetBe32(p - 4, v); + v |= (UInt32)1 << 30; + #endif + SetBe32a(p - 4, v) } } } +Z7_BRANCH_FUNCS_IMP(BranchConv_SPARC) + + +Z7_BRANCH_FUNC_MAIN(BranchConv_ARMT) +{ + // Byte *p = data; + Byte *lim; + size &= ~(SizeT)1; + // if (size == 0) return p; + if (size <= 2) return p; + size -= 2; + lim = p + size; + BR_PC_INIT + /* in ARM: branch offset is relative to the +2 instructions from current instruction. + (p) will point to the +2 instructions from current instruction */ + // pc += 4 - 4; + // if (encoding) pc -= 0xf800 << 1; else pc += 0xf800 << 1; + // #define ARMT_TAIL_PROC { goto armt_tail; } + #define ARMT_TAIL_PROC { return p; } + + do + { + /* in MSVC 32-bit x86 compilers: + UInt32 version : it loads value from memory with movzx + Byte version : it loads value to 8-bit register (AL/CL) + movzx version is slightly faster in some cpus + */ + unsigned b1; + // Byte / unsigned + b1 = p[1]; + // optimized version to reduce one (p >= lim) check: + // unsigned a1 = p[1]; b1 = p[3]; p += 2; if Z7_LIKELY((b1 & (a1 ^ 8)) < 0xf8) + for (;;) + { + unsigned b3; // Byte / UInt32 + /* (Byte)(b3) normalization can use low byte computations in MSVC. + It gives smaller code, and no loss of speed in some compilers/cpus. + But new MSVC 32-bit x86 compilers use more slow load + from memory to low byte register in that case. + So we try to use full 32-bit computations for faster code. + */ + // if (p >= lim) { ARMT_TAIL_PROC } b3 = b1 + 8; b1 = p[3]; p += 2; if ((b3 & b1) >= 0xf8) break; + if Z7_UNLIKELY(p >= lim) { ARMT_TAIL_PROC } b3 = p[3]; p += 2; if Z7_UNLIKELY((b3 & (b1 ^ 8)) >= 0xf8) break; + if Z7_UNLIKELY(p >= lim) { ARMT_TAIL_PROC } b1 = p[3]; p += 2; if Z7_UNLIKELY((b1 & (b3 ^ 8)) >= 0xf8) break; + } + { + /* we can adjust pc for (0xf800) to rid of (& 0x7FF) operation. + But gcc/clang for arm64 can use bfi instruction for full code here */ + UInt32 v = + ((UInt32)GetUi16a(p - 2) << 11) | + ((UInt32)GetUi16a(p) & 0x7FF); + /* + UInt32 v = + ((UInt32)p[1 - 2] << 19) + + (((UInt32)p[1] & 0x7) << 8) + + (((UInt32)p[-2] << 11)) + + (p[0]); + */ + p += 2; + { + UInt32 c = BR_PC_GET >> 1; + BR_CONVERT_VAL(v, c) + } + SetUi16a(p - 4, (UInt16)(((v >> 11) & 0x7ff) | 0xf000)) + SetUi16a(p - 2, (UInt16)(v | 0xf800)) + /* + p[-4] = (Byte)(v >> 11); + p[-3] = (Byte)(0xf0 | ((v >> 19) & 0x7)); + p[-2] = (Byte)v; + p[-1] = (Byte)(0xf8 | (v >> 8)); + */ + } + } + while (p < lim); + return p; + // armt_tail: + // if ((Byte)((lim[1] & 0xf8)) != 0xf0) { lim += 2; } return lim; + // return (Byte *)(lim + ((Byte)((lim[1] ^ 0xf0) & 0xf8) == 0 ? 0 : 2)); + // return (Byte *)(lim + (((lim[1] ^ ~0xfu) & ~7u) == 0 ? 0 : 2)); + // return (Byte *)(lim + 2 - (((((unsigned)lim[1] ^ 8) + 8) >> 7) & 2)); +} +Z7_BRANCH_FUNCS_IMP(BranchConv_ARMT) + + +// #define BR_IA64_NO_INLINE + +Z7_BRANCH_FUNC_MAIN(BranchConv_IA64) +{ + // Byte *p = data; + const Byte *lim; + size &= ~(SizeT)15; + lim = p + size; + pc -= 1 << 4; + pc >>= 4 - 1; + // pc -= 1 << 1; + + for (;;) + { + unsigned m; + for (;;) + { + if Z7_UNLIKELY(p == lim) + return p; + m = (unsigned)((UInt32)0x334b0000 >> (*p & 0x1e)); + p += 16; + pc += 1 << 1; + if (m &= 3) + break; + } + { + p += (ptrdiff_t)m * 5 - 20; // negative value is expected here. + do + { + const UInt32 t = + #if defined(MY_CPU_X86_OR_AMD64) + // we use 32-bit load here to reduce code size on x86: + GetUi32(p); + #else + GetUi16(p); + #endif + UInt32 z = GetUi32(p + 1) >> m; + p += 5; + if (((t >> m) & (0x70 << 1)) == 0 + && ((z - (0x5000000 << 1)) & (0xf000000 << 1)) == 0) + { + UInt32 v = (UInt32)((0x8fffff << 1) | 1) & z; + z ^= v; + #ifdef BR_IA64_NO_INLINE + v |= (v & ((UInt32)1 << (23 + 1))) >> 3; + { + UInt32 c = pc; + BR_CONVERT_VAL(v, c) + } + v &= (0x1fffff << 1) | 1; + #else + { + if (encoding) + { + // pc &= ~(0xc00000 << 1); // we just need to clear at least 2 bits + pc &= (0x1fffff << 1) | 1; + v += pc; + } + else + { + // pc |= 0xc00000 << 1; // we need to set at least 2 bits + pc |= ~(UInt32)((0x1fffff << 1) | 1); + v -= pc; + } + } + v &= ~(UInt32)(0x600000 << 1); + #endif + v += (0x700000 << 1); + v &= (0x8fffff << 1) | 1; + z |= v; + z <<= m; + SetUi32(p + 1 - 5, z) + } + m++; + } + while (m &= 3); // while (m < 4); + } + } +} +Z7_BRANCH_FUNCS_IMP(BranchConv_IA64) + + +#define BR_CONVERT_VAL_ENC(v) v += BR_PC_GET; +#define BR_CONVERT_VAL_DEC(v) v -= BR_PC_GET; + +#if 1 && defined(MY_CPU_LE_UNALIGN) + #define RISCV_USE_UNALIGNED_LOAD +#endif + +#ifdef RISCV_USE_UNALIGNED_LOAD + #define RISCV_GET_UI32(p) GetUi32(p) + #define RISCV_SET_UI32(p, v) { SetUi32(p, v) } +#else + #define RISCV_GET_UI32(p) \ + ((UInt32)GetUi16a(p) + \ + ((UInt32)GetUi16a((p) + 2) << 16)) + #define RISCV_SET_UI32(p, v) { \ + SetUi16a(p, (UInt16)(v)) \ + SetUi16a((p) + 2, (UInt16)(v >> 16)) } +#endif + +#if 1 && defined(MY_CPU_LE) + #define RISCV_USE_16BIT_LOAD +#endif + +#ifdef RISCV_USE_16BIT_LOAD + #define RISCV_LOAD_VAL(p) GetUi16a(p) +#else + #define RISCV_LOAD_VAL(p) (*(p)) +#endif + +#define RISCV_INSTR_SIZE 2 +#define RISCV_STEP_1 (4 + RISCV_INSTR_SIZE) +#define RISCV_STEP_2 4 +#define RISCV_REG_VAL (2 << 7) +#define RISCV_CMD_VAL 3 +#if 1 + // for code size optimization: + #define RISCV_DELTA_7F 0x7f +#else + #define RISCV_DELTA_7F 0 +#endif + +#define RISCV_CHECK_1(v, b) \ + (((((b) - RISCV_CMD_VAL) ^ ((v) << 8)) & (0xf8000 + RISCV_CMD_VAL)) == 0) + +#if 1 + #define RISCV_CHECK_2(v, r) \ + ((((v) - ((RISCV_CMD_VAL << 12) | RISCV_REG_VAL | 8)) \ + << 18) \ + < ((r) & 0x1d)) +#else + // this branch gives larger code, because + // compilers generate larger code for big constants. + #define RISCV_CHECK_2(v, r) \ + ((((v) - ((RISCV_CMD_VAL << 12) | RISCV_REG_VAL)) \ + & ((RISCV_CMD_VAL << 12) | RISCV_REG_VAL)) \ + < ((r) & 0x1d)) +#endif + + +#define RISCV_SCAN_LOOP \ + Byte *lim; \ + size &= ~(SizeT)(RISCV_INSTR_SIZE - 1); \ + if (size <= 6) return p; \ + size -= 6; \ + lim = p + size; \ + BR_PC_INIT \ + for (;;) \ + { \ + UInt32 a, v; \ + /* Z7_PRAGMA_OPT_DISABLE_LOOP_UNROLL_VECTORIZE */ \ + for (;;) \ + { \ + if Z7_UNLIKELY(p >= lim) { return p; } \ + a = (RISCV_LOAD_VAL(p) ^ 0x10u) + 1; \ + if ((a & 0x77) == 0) break; \ + a = (RISCV_LOAD_VAL(p + RISCV_INSTR_SIZE) ^ 0x10u) + 1; \ + p += RISCV_INSTR_SIZE * 2; \ + if ((a & 0x77) == 0) \ + { \ + p -= RISCV_INSTR_SIZE; \ + if Z7_UNLIKELY(p >= lim) { return p; } \ + break; \ + } \ + } +// (xx6f ^ 10) + 1 = xx7f + 1 = xx80 : JAL +// (xxef ^ 10) + 1 = xxff + 1 = xx00 + 100 : JAL +// (xx17 ^ 10) + 1 = xx07 + 1 = xx08 : AUIPC +// (xx97 ^ 10) + 1 = xx87 + 1 = xx88 : AUIPC + +Byte * Z7_BRANCH_CONV_ENC(RISCV)(Byte *p, SizeT size, UInt32 pc) +{ + RISCV_SCAN_LOOP + v = a; + a = RISCV_GET_UI32(p); +#ifndef RISCV_USE_16BIT_LOAD + v += (UInt32)p[1] << 8; +#endif + + if ((v & 8) == 0) // JAL + { + if ((v - (0x100 /* - RISCV_DELTA_7F */)) & 0xd80) + { + p += RISCV_INSTR_SIZE; + continue; + } + { + v = ((a & 1u << 31) >> 11) + | ((a & 0x3ff << 21) >> 20) + | ((a & 1 << 20) >> 9) + | (a & 0xff << 12); + BR_CONVERT_VAL_ENC(v) + // ((v & 1) == 0) + // v: bits [1 : 20] contain offset bits +#if 0 && defined(RISCV_USE_UNALIGNED_LOAD) + a &= 0xfff; + a |= ((UInt32)(v << 23)) + | ((UInt32)(v << 7) & ((UInt32)0xff << 16)) + | ((UInt32)(v >> 5) & ((UInt32)0xf0 << 8)); + RISCV_SET_UI32(p, a) +#else // aligned +#if 0 + SetUi16a(p, (UInt16)(((v >> 5) & 0xf000) | (a & 0xfff))) +#else + p[1] = (Byte)(((v >> 13) & 0xf0) | ((a >> 8) & 0xf)); +#endif + +#if 1 && defined(Z7_CPU_FAST_BSWAP_SUPPORTED) && defined(MY_CPU_LE) + v <<= 15; + v = Z7_BSWAP32(v); + SetUi16a(p + 2, (UInt16)v) +#else + p[2] = (Byte)(v >> 9); + p[3] = (Byte)(v >> 1); +#endif +#endif // aligned + } + p += 4; + continue; + } // JAL + + { + // AUIPC + if (v & 0xe80) // (not x0) and (not x2) + { + const UInt32 b = RISCV_GET_UI32(p + 4); + if (RISCV_CHECK_1(v, b)) + { + { + const UInt32 temp = (b << 12) | (0x17 + RISCV_REG_VAL); + RISCV_SET_UI32(p, temp) + } + a &= 0xfffff000; + { +#if 1 + const int t = -1 >> 1; + if (t != -1) + a += (b >> 20) - ((b >> 19) & 0x1000); // arithmetic right shift emulation + else +#endif + a += (UInt32)((Int32)b >> 20); // arithmetic right shift (sign-extension). + } + BR_CONVERT_VAL_ENC(a) +#if 1 && defined(Z7_CPU_FAST_BSWAP_SUPPORTED) && defined(MY_CPU_LE) + a = Z7_BSWAP32(a); + RISCV_SET_UI32(p + 4, a) +#else + SetBe32(p + 4, a) +#endif + p += 8; + } + else + p += RISCV_STEP_1; + } + else + { + UInt32 r = a >> 27; + if (RISCV_CHECK_2(v, r)) + { + v = RISCV_GET_UI32(p + 4); + r = (r << 7) + 0x17 + (v & 0xfffff000); + a = (a >> 12) | (v << 20); + RISCV_SET_UI32(p, r) + RISCV_SET_UI32(p + 4, a) + p += 8; + } + else + p += RISCV_STEP_2; + } + } + } // for +} + + +Byte * Z7_BRANCH_CONV_DEC(RISCV)(Byte *p, SizeT size, UInt32 pc) +{ + RISCV_SCAN_LOOP +#ifdef RISCV_USE_16BIT_LOAD + if ((a & 8) == 0) + { +#else + v = a; + a += (UInt32)p[1] << 8; + if ((v & 8) == 0) + { +#endif + // JAL + a -= 0x100 - RISCV_DELTA_7F; + if (a & 0xd80) + { + p += RISCV_INSTR_SIZE; + continue; + } + { + const UInt32 a_old = (a + (0xef - RISCV_DELTA_7F)) & 0xfff; +#if 0 // unaligned + a = GetUi32(p); + v = (UInt32)(a >> 23) & ((UInt32)0xff << 1) + | (UInt32)(a >> 7) & ((UInt32)0xff << 9) +#elif 1 && defined(Z7_CPU_FAST_BSWAP_SUPPORTED) && defined(MY_CPU_LE) + v = GetUi16a(p + 2); + v = Z7_BSWAP32(v) >> 15 +#else + v = (UInt32)p[3] << 1 + | (UInt32)p[2] << 9 +#endif + | (UInt32)((a & 0xf000) << 5); + BR_CONVERT_VAL_DEC(v) + a = a_old + | (v << 11 & 1u << 31) + | (v << 20 & 0x3ff << 21) + | (v << 9 & 1 << 20) + | (v & 0xff << 12); + RISCV_SET_UI32(p, a) + } + p += 4; + continue; + } // JAL + + { + // AUIPC + v = a; +#if 1 && defined(RISCV_USE_UNALIGNED_LOAD) + a = GetUi32(p); +#else + a |= (UInt32)GetUi16a(p + 2) << 16; +#endif + if ((v & 0xe80) == 0) // x0/x2 + { + const UInt32 r = a >> 27; + if (RISCV_CHECK_2(v, r)) + { + UInt32 b; +#if 1 && defined(Z7_CPU_FAST_BSWAP_SUPPORTED) && defined(MY_CPU_LE) + b = RISCV_GET_UI32(p + 4); + b = Z7_BSWAP32(b); +#else + b = GetBe32(p + 4); +#endif + v = a >> 12; + BR_CONVERT_VAL_DEC(b) + a = (r << 7) + 0x17; + a += (b + 0x800) & 0xfffff000; + v |= b << 20; + RISCV_SET_UI32(p, a) + RISCV_SET_UI32(p + 4, v) + p += 8; + } + else + p += RISCV_STEP_2; + } + else + { + const UInt32 b = RISCV_GET_UI32(p + 4); + if (!RISCV_CHECK_1(v, b)) + p += RISCV_STEP_1; + else + { + v = (a & 0xfffff000) | (b >> 20); + a = (b << 12) | (0x17 + RISCV_REG_VAL); + RISCV_SET_UI32(p, a) + RISCV_SET_UI32(p + 4, v) + p += 8; + } + } + } + } // for +} diff --git a/common/LZMA/SDK/C/Bra.h b/common/LZMA/SDK/C/Bra.h index 855e37a..b47112c 100644 --- a/common/LZMA/SDK/C/Bra.h +++ b/common/LZMA/SDK/C/Bra.h @@ -1,64 +1,105 @@ /* Bra.h -- Branch converters for executables -2013-01-18 : Igor Pavlov : Public domain */ +2024-01-20 : Igor Pavlov : Public domain */ -#ifndef __BRA_H -#define __BRA_H +#ifndef ZIP7_INC_BRA_H +#define ZIP7_INC_BRA_H #include "7zTypes.h" 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 +/* #define PPC BAD_PPC_11 // for debug */ - 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. +#define Z7_BRANCH_CONV_DEC_2(name) z7_ ## name ## _Dec +#define Z7_BRANCH_CONV_ENC_2(name) z7_ ## name ## _Enc +#define Z7_BRANCH_CONV_DEC(name) Z7_BRANCH_CONV_DEC_2(BranchConv_ ## name) +#define Z7_BRANCH_CONV_ENC(name) Z7_BRANCH_CONV_ENC_2(BranchConv_ ## name) +#define Z7_BRANCH_CONV_ST_DEC(name) z7_BranchConvSt_ ## name ## _Dec +#define Z7_BRANCH_CONV_ST_ENC(name) z7_BranchConvSt_ ## name ## _Enc + +#define Z7_BRANCH_CONV_DECL(name) Byte * name(Byte *data, SizeT size, UInt32 pc) +#define Z7_BRANCH_CONV_ST_DECL(name) Byte * name(Byte *data, SizeT size, UInt32 pc, UInt32 *state) + +typedef Z7_BRANCH_CONV_DECL( (*z7_Func_BranchConv)); +typedef Z7_BRANCH_CONV_ST_DECL((*z7_Func_BranchConvSt)); + +#define Z7_BRANCH_CONV_ST_X86_STATE_INIT_VAL 0 +Z7_BRANCH_CONV_ST_DECL (Z7_BRANCH_CONV_ST_DEC(X86)); +Z7_BRANCH_CONV_ST_DECL (Z7_BRANCH_CONV_ST_ENC(X86)); + +#define Z7_BRANCH_FUNCS_DECL(name) \ +Z7_BRANCH_CONV_DECL (Z7_BRANCH_CONV_DEC_2(name)); \ +Z7_BRANCH_CONV_DECL (Z7_BRANCH_CONV_ENC_2(name)); + +Z7_BRANCH_FUNCS_DECL (BranchConv_ARM64) +Z7_BRANCH_FUNCS_DECL (BranchConv_ARM) +Z7_BRANCH_FUNCS_DECL (BranchConv_ARMT) +Z7_BRANCH_FUNCS_DECL (BranchConv_PPC) +Z7_BRANCH_FUNCS_DECL (BranchConv_SPARC) +Z7_BRANCH_FUNCS_DECL (BranchConv_IA64) +Z7_BRANCH_FUNCS_DECL (BranchConv_RISCV) + +/* +These functions convert data that contain CPU instructions. +Each such function converts relative addresses to absolute addresses in some +branch instructions: CALL (in all converters) and JUMP (X86 converter only). +Such conversion allows to increase compression ratio, if we compress that data. + +There are 2 types of converters: + Byte * Conv_RISC (Byte *data, SizeT size, UInt32 pc); + Byte * ConvSt_X86(Byte *data, SizeT size, UInt32 pc, UInt32 *state); +Each Converter supports 2 versions: one for encoding +and one for decoding (_Enc/_Dec postfixes in function name). + +In params: + data : data buffer + size : size of data + pc : current virtual Program Counter (Instruction Pointer) value +In/Out param: + state : pointer to state variable (for X86 converter only) + +Return: + The pointer to position in (data) buffer after last byte that was processed. + If the caller calls converter again, it must call it starting with that position. + But the caller is allowed to move data in buffer. So pointer to + current processed position also will be changed for next call. + Also the caller must increase internal (pc) value for next call. +Each converter has some characteristics: Endian, Alignment, LookAhead. Type Endian Alignment LookAhead - x86 little 1 4 + X86 little 1 4 ARMT little 2 2 + RISCV little 2 6 ARM little 4 0 + ARM64 little 4 0 PPC big 4 0 SPARC big 4 0 IA64 little 16 0 - size must be >= Alignment + LookAhead, if it's not last block. - If (size < Alignment + LookAhead), converter returns 0. + (data) must be aligned for (Alignment). + processed size can be calculated as: + SizeT processed = Conv(data, size, pc) - data; + if (processed == 0) + it means that converter needs more data for processing. + If (size < Alignment + LookAhead) + then (processed == 0) is allowed. - Example: - - UInt32 ip = 0; - for () - { - ; size must be >= Alignment + LookAhead, if it's not last block - SizeT processed = Convert(data, size, ip, 1); - data += processed; - size -= processed; - ip += processed; - } +Example code for conversion in loop: + UInt32 pc = 0; + size = 0; + for (;;) + { + size += Load_more_input_data(data + size); + SizeT processed = Conv(data, size, pc) - data; + if (processed == 0 && no_more_input_data_after_size) + break; // we stop convert loop + data += processed; + size -= processed; + pc += processed; + } */ -#define x86_Convert_Init(state) { state = 0; } -SizeT x86_Convert(Byte *data, SizeT size, UInt32 ip, UInt32 *state, int encoding); -SizeT ARM_Convert(Byte *data, SizeT size, UInt32 ip, int encoding); -SizeT ARMT_Convert(Byte *data, SizeT size, UInt32 ip, int encoding); -SizeT PPC_Convert(Byte *data, SizeT size, UInt32 ip, int encoding); -SizeT SPARC_Convert(Byte *data, SizeT size, UInt32 ip, int encoding); -SizeT IA64_Convert(Byte *data, SizeT size, UInt32 ip, int encoding); - EXTERN_C_END #endif diff --git a/common/LZMA/SDK/C/Bra86.c b/common/LZMA/SDK/C/Bra86.c index 10a0fbd..d81f392 100644 --- a/common/LZMA/SDK/C/Bra86.c +++ b/common/LZMA/SDK/C/Bra86.c @@ -1,82 +1,187 @@ -/* Bra86.c -- Converter for x86 code (BCJ) -2021-02-09 : Igor Pavlov : Public domain */ +/* Bra86.c -- Branch converter for X86 code (BCJ) +2023-04-02 : Igor Pavlov : Public domain */ #include "Precomp.h" #include "Bra.h" +#include "CpuArch.h" -#define Test86MSByte(b) ((((b) + 1) & 0xFE) == 0) -SizeT x86_Convert(Byte *data, SizeT size, UInt32 ip, UInt32 *state, int encoding) +#if defined(MY_CPU_SIZEOF_POINTER) \ + && ( MY_CPU_SIZEOF_POINTER == 4 \ + || MY_CPU_SIZEOF_POINTER == 8) + #define BR_CONV_USE_OPT_PC_PTR +#endif + +#ifdef BR_CONV_USE_OPT_PC_PTR +#define BR_PC_INIT pc -= (UInt32)(SizeT)p; // (MY_uintptr_t) +#define BR_PC_GET (pc + (UInt32)(SizeT)p) +#else +#define BR_PC_INIT pc += (UInt32)size; +#define BR_PC_GET (pc - (UInt32)(SizeT)(lim - p)) +// #define BR_PC_INIT +// #define BR_PC_GET (pc + (UInt32)(SizeT)(p - data)) +#endif + +#define BR_CONVERT_VAL(v, c) if (encoding) v += c; else v -= c; +// #define BR_CONVERT_VAL(v, c) if (!encoding) c = (UInt32)0 - c; v += c; + +#define Z7_BRANCH_CONV_ST(name) z7_BranchConvSt_ ## name + +#define BR86_NEED_CONV_FOR_MS_BYTE(b) ((((b) + 1) & 0xfe) == 0) + +#ifdef MY_CPU_LE_UNALIGN + #define BR86_PREPARE_BCJ_SCAN const UInt32 v = GetUi32(p) ^ 0xe8e8e8e8; + #define BR86_IS_BCJ_BYTE(n) ((v & ((UInt32)0xfe << (n) * 8)) == 0) +#else + #define BR86_PREPARE_BCJ_SCAN + // bad for MSVC X86 (partial write to byte reg): + #define BR86_IS_BCJ_BYTE(n) ((p[n - 4] & 0xfe) == 0xe8) + // bad for old MSVC (partial write to byte reg): + // #define BR86_IS_BCJ_BYTE(n) (((*p ^ 0xe8) & 0xfe) == 0) +#endif + +static +Z7_FORCE_INLINE +Z7_ATTRIB_NO_VECTOR +Byte *Z7_BRANCH_CONV_ST(X86)(Byte *p, SizeT size, UInt32 pc, UInt32 *state, int encoding) { - SizeT pos = 0; - UInt32 mask = *state & 7; if (size < 5) - return 0; - size -= 4; - ip += 5; + return p; + { + // Byte *p = data; + const Byte *lim = p + size - 4; + unsigned mask = (unsigned)*state; // & 7; +#ifdef BR_CONV_USE_OPT_PC_PTR + /* if BR_CONV_USE_OPT_PC_PTR is defined: we need to adjust (pc) for (+4), + because call/jump offset is relative to the next instruction. + if BR_CONV_USE_OPT_PC_PTR is not defined : we don't need to adjust (pc) for (+4), + because BR_PC_GET uses (pc - (lim - p)), and lim was adjusted for (-4) before. + */ + pc += 4; +#endif + BR_PC_INIT + goto start; - for (;;) + for (;; mask |= 4) { - Byte *p = data + pos; - const Byte *limit = data + size; - for (; p < limit; p++) - if ((*p & 0xFE) == 0xE8) - break; - + // cont: mask |= 4; + start: + if (p >= lim) + goto fin; { - SizeT d = (SizeT)(p - data) - pos; - pos = (SizeT)(p - data); - if (p >= limit) - { - *state = (d > 2 ? 0 : mask >> (unsigned)d); - return pos; - } - if (d > 2) - mask = 0; - else - { - mask >>= (unsigned)d; - if (mask != 0 && (mask > 4 || mask == 3 || Test86MSByte(p[(size_t)(mask >> 1) + 1]))) - { - mask = (mask >> 1) | 4; - pos++; - continue; - } - } + BR86_PREPARE_BCJ_SCAN + p += 4; + if (BR86_IS_BCJ_BYTE(0)) { goto m0; } mask >>= 1; + if (BR86_IS_BCJ_BYTE(1)) { goto m1; } mask >>= 1; + if (BR86_IS_BCJ_BYTE(2)) { goto m2; } mask = 0; + if (BR86_IS_BCJ_BYTE(3)) { goto a3; } } + goto main_loop; - if (Test86MSByte(p[4])) + m0: p--; + m1: p--; + m2: p--; + if (mask == 0) + goto a3; + if (p > lim) + goto fin_p; + + // if (((0x17u >> mask) & 1) == 0) + if (mask > 4 || mask == 3) { - UInt32 v = ((UInt32)p[4] << 24) | ((UInt32)p[3] << 16) | ((UInt32)p[2] << 8) | ((UInt32)p[1]); - UInt32 cur = ip + (UInt32)pos; - pos += 5; - if (encoding) - v += cur; - else - v -= cur; - if (mask != 0) + mask >>= 1; + continue; // goto cont; + } + mask >>= 1; + if (BR86_NEED_CONV_FOR_MS_BYTE(p[mask])) + continue; // goto cont; + // if (!BR86_NEED_CONV_FOR_MS_BYTE(p[3])) continue; // goto cont; + { + UInt32 v = GetUi32(p); + UInt32 c; + v += (1 << 24); if (v & 0xfe000000) continue; // goto cont; + c = BR_PC_GET; + BR_CONVERT_VAL(v, c) { - unsigned sh = (mask & 6) << 2; - if (Test86MSByte((Byte)(v >> sh))) + mask <<= 3; + if (BR86_NEED_CONV_FOR_MS_BYTE(v >> mask)) { - v ^= (((UInt32)0x100 << sh) - 1); - if (encoding) - v += cur; - else - v -= cur; + v ^= (((UInt32)0x100 << mask) - 1); + #ifdef MY_CPU_X86 + // for X86 : we can recalculate (c) to reduce register pressure + c = BR_PC_GET; + #endif + BR_CONVERT_VAL(v, c) } mask = 0; } - p[1] = (Byte)v; - p[2] = (Byte)(v >> 8); - p[3] = (Byte)(v >> 16); - p[4] = (Byte)(0 - ((v >> 24) & 1)); + // v = (v & ((1 << 24) - 1)) - (v & (1 << 24)); + v &= (1 << 25) - 1; v -= (1 << 24); + SetUi32(p, v) + p += 4; + goto main_loop; } - else + + main_loop: + if (p >= lim) + goto fin; + for (;;) { - mask = (mask >> 1) | 4; - pos++; + BR86_PREPARE_BCJ_SCAN + p += 4; + if (BR86_IS_BCJ_BYTE(0)) { goto a0; } + if (BR86_IS_BCJ_BYTE(1)) { goto a1; } + if (BR86_IS_BCJ_BYTE(2)) { goto a2; } + if (BR86_IS_BCJ_BYTE(3)) { goto a3; } + if (p >= lim) + goto fin; + } + + a0: p--; + a1: p--; + a2: p--; + a3: + if (p > lim) + goto fin_p; + // if (!BR86_NEED_CONV_FOR_MS_BYTE(p[3])) continue; // goto cont; + { + UInt32 v = GetUi32(p); + UInt32 c; + v += (1 << 24); if (v & 0xfe000000) continue; // goto cont; + c = BR_PC_GET; + BR_CONVERT_VAL(v, c) + // v = (v & ((1 << 24) - 1)) - (v & (1 << 24)); + v &= (1 << 25) - 1; v -= (1 << 24); + SetUi32(p, v) + p += 4; + goto main_loop; } } + +fin_p: + p--; +fin: + // the following processing for tail is optional and can be commented + /* + lim += 4; + for (; p < lim; p++, mask >>= 1) + if ((*p & 0xfe) == 0xe8) + break; + */ + *state = (UInt32)mask; + return p; + } } + + +#define Z7_BRANCH_CONV_ST_FUNC_IMP(name, m, encoding) \ +Z7_NO_INLINE \ +Z7_ATTRIB_NO_VECTOR \ +Byte *m(name)(Byte *data, SizeT size, UInt32 pc, UInt32 *state) \ + { return Z7_BRANCH_CONV_ST(name)(data, size, pc, state, encoding); } + +Z7_BRANCH_CONV_ST_FUNC_IMP(X86, Z7_BRANCH_CONV_ST_DEC, 0) +#ifndef Z7_EXTRACT_ONLY +Z7_BRANCH_CONV_ST_FUNC_IMP(X86, Z7_BRANCH_CONV_ST_ENC, 1) +#endif diff --git a/common/LZMA/SDK/C/Compiler.h b/common/LZMA/SDK/C/Compiler.h index a9816fa..2a9c2b7 100644 --- a/common/LZMA/SDK/C/Compiler.h +++ b/common/LZMA/SDK/C/Compiler.h @@ -1,12 +1,105 @@ -/* Compiler.h -2021-01-05 : Igor Pavlov : Public domain */ +/* Compiler.h : Compiler specific defines and pragmas +2024-01-22 : Igor Pavlov : Public domain */ -#ifndef __7Z_COMPILER_H -#define __7Z_COMPILER_H +#ifndef ZIP7_INC_COMPILER_H +#define ZIP7_INC_COMPILER_H - #ifdef __clang__ - #pragma clang diagnostic ignored "-Wunused-private-field" +#if defined(__clang__) +# define Z7_CLANG_VERSION (__clang_major__ * 10000 + __clang_minor__ * 100 + __clang_patchlevel__) +#endif +#if defined(__clang__) && defined(__apple_build_version__) +# define Z7_APPLE_CLANG_VERSION Z7_CLANG_VERSION +#elif defined(__clang__) +# define Z7_LLVM_CLANG_VERSION Z7_CLANG_VERSION +#elif defined(__GNUC__) +# define Z7_GCC_VERSION (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__) +#endif + +#ifdef _MSC_VER +#if !defined(__clang__) && !defined(__GNUC__) +#define Z7_MSC_VER_ORIGINAL _MSC_VER +#endif +#endif + +#if defined(__MINGW32__) || defined(__MINGW64__) +#define Z7_MINGW +#endif + +#if defined(__LCC__) && (defined(__MCST__) || defined(__e2k__)) +#define Z7_MCST_LCC +#define Z7_MCST_LCC_VERSION (__LCC__ * 100 + __LCC_MINOR__) +#endif + +/* +#if defined(__AVX2__) \ + || defined(Z7_GCC_VERSION) && (Z7_GCC_VERSION >= 40900) \ + || defined(Z7_APPLE_CLANG_VERSION) && (Z7_APPLE_CLANG_VERSION >= 40600) \ + || defined(Z7_LLVM_CLANG_VERSION) && (Z7_LLVM_CLANG_VERSION >= 30100) \ + || defined(Z7_MSC_VER_ORIGINAL) && (Z7_MSC_VER_ORIGINAL >= 1800) \ + || defined(__INTEL_COMPILER) && (__INTEL_COMPILER >= 1400) + #define Z7_COMPILER_AVX2_SUPPORTED #endif +#endif +*/ + +// #pragma GCC diagnostic ignored "-Wunknown-pragmas" + +#ifdef __clang__ +// padding size of '' with 4 bytes to alignment boundary +#pragma GCC diagnostic ignored "-Wpadded" + +#if defined(Z7_LLVM_CLANG_VERSION) && (__clang_major__ == 13) \ + && defined(__FreeBSD__) +// freebsd: +#pragma GCC diagnostic ignored "-Wexcess-padding" +#endif + +#if __clang_major__ >= 16 +#pragma GCC diagnostic ignored "-Wunsafe-buffer-usage" +#endif + +#if __clang_major__ == 13 +#if defined(__SIZEOF_POINTER__) && (__SIZEOF_POINTER__ == 16) +// cheri +#pragma GCC diagnostic ignored "-Wcapability-to-integer-cast" +#endif +#endif + +#if __clang_major__ == 13 + // for + #pragma GCC diagnostic ignored "-Wreserved-identifier" +#endif + +#endif // __clang__ + +#if defined(_WIN32) && defined(__clang__) && __clang_major__ >= 16 +// #pragma GCC diagnostic ignored "-Wcast-function-type-strict" +#define Z7_DIAGNOSTIC_IGNORE_CAST_FUNCTION \ + _Pragma("GCC diagnostic ignored \"-Wcast-function-type-strict\"") +#else +#define Z7_DIAGNOSTIC_IGNORE_CAST_FUNCTION +#endif + +typedef void (*Z7_void_Function)(void); +#if defined(__clang__) || defined(__GNUC__) +#define Z7_CAST_FUNC_C (Z7_void_Function) +#elif defined(_MSC_VER) && _MSC_VER > 1920 +#define Z7_CAST_FUNC_C (void *) +// #pragma warning(disable : 4191) // 'type cast': unsafe conversion from 'FARPROC' to 'void (__cdecl *)()' +#else +#define Z7_CAST_FUNC_C +#endif +/* +#if (defined(__GNUC__) && (__GNUC__ >= 8)) || defined(__clang__) + // #pragma GCC diagnostic ignored "-Wcast-function-type" +#endif +*/ +#ifdef __GNUC__ +#if defined(Z7_GCC_VERSION) && (Z7_GCC_VERSION >= 40000) && (Z7_GCC_VERSION < 70000) +#pragma GCC diagnostic ignored "-Wstrict-aliasing" +#endif +#endif + #ifdef _MSC_VER @@ -17,24 +110,124 @@ #pragma warning(disable : 4214) // nonstandard extension used : bit field types other than int #endif - #if _MSC_VER >= 1300 - #pragma warning(disable : 4996) // This function or variable may be unsafe - #else - #pragma warning(disable : 4511) // copy constructor could not be generated - #pragma warning(disable : 4512) // assignment operator could not be generated - #pragma warning(disable : 4514) // unreferenced inline function has been removed - #pragma warning(disable : 4702) // unreachable code - #pragma warning(disable : 4710) // not inlined - #pragma warning(disable : 4714) // function marked as __forceinline not inlined - #pragma warning(disable : 4786) // identifier was truncated to '255' characters in the debug information - #endif +#if defined(_MSC_VER) && _MSC_VER >= 1800 +#pragma warning(disable : 4464) // relative include path contains '..' +#endif - #ifdef __clang__ - #pragma clang diagnostic ignored "-Wdeprecated-declarations" - #pragma clang diagnostic ignored "-Wmicrosoft-exception-spec" - // #pragma clang diagnostic ignored "-Wreserved-id-macro" - #endif +// == 1200 : -O1 : for __forceinline +// >= 1900 : -O1 : for printf +#pragma warning(disable : 4710) // function not inlined +#if _MSC_VER < 1900 +// winnt.h: 'Int64ShllMod32' +#pragma warning(disable : 4514) // unreferenced inline function has been removed +#endif + +#if _MSC_VER < 1300 +// #pragma warning(disable : 4702) // unreachable code +// Bra.c : -O1: +#pragma warning(disable : 4714) // function marked as __forceinline not inlined +#endif + +/* +#if _MSC_VER > 1400 && _MSC_VER <= 1900 +// strcat: This function or variable may be unsafe +// sysinfoapi.h: kit10: GetVersion was declared deprecated +#pragma warning(disable : 4996) +#endif +*/ + +#if _MSC_VER > 1200 +// -Wall warnings + +#pragma warning(disable : 4711) // function selected for automatic inline expansion +#pragma warning(disable : 4820) // '2' bytes padding added after data member + +#if _MSC_VER >= 1400 && _MSC_VER < 1920 +// 1400: string.h: _DBG_MEMCPY_INLINE_ +// 1600 - 191x : smmintrin.h __cplusplus' +// is not defined as a preprocessor macro, replacing with '0' for '#if/#elif' +#pragma warning(disable : 4668) + +// 1400 - 1600 : WinDef.h : 'FARPROC' : +// 1900 - 191x : immintrin.h: _readfsbase_u32 +// no function prototype given : converting '()' to '(void)' +#pragma warning(disable : 4255) +#endif + +#if _MSC_VER >= 1914 +// Compiler will insert Spectre mitigation for memory load if /Qspectre switch specified +#pragma warning(disable : 5045) +#endif + +#endif // _MSC_VER > 1200 +#endif // _MSC_VER + + +#if defined(__clang__) && (__clang_major__ >= 4) + #define Z7_PRAGMA_OPT_DISABLE_LOOP_UNROLL_VECTORIZE \ + _Pragma("clang loop unroll(disable)") \ + _Pragma("clang loop vectorize(disable)") + #define Z7_ATTRIB_NO_VECTORIZE +#elif defined(__GNUC__) && (__GNUC__ >= 5) \ + && (!defined(Z7_MCST_LCC_VERSION) || (Z7_MCST_LCC_VERSION >= 12610)) + #define Z7_ATTRIB_NO_VECTORIZE __attribute__((optimize("no-tree-vectorize"))) + // __attribute__((optimize("no-unroll-loops"))); + #define Z7_PRAGMA_OPT_DISABLE_LOOP_UNROLL_VECTORIZE +#elif defined(_MSC_VER) && (_MSC_VER >= 1920) + #define Z7_PRAGMA_OPT_DISABLE_LOOP_UNROLL_VECTORIZE \ + _Pragma("loop( no_vector )") + #define Z7_ATTRIB_NO_VECTORIZE +#else + #define Z7_PRAGMA_OPT_DISABLE_LOOP_UNROLL_VECTORIZE + #define Z7_ATTRIB_NO_VECTORIZE +#endif + +#if defined(MY_CPU_X86_OR_AMD64) && ( \ + defined(__clang__) && (__clang_major__ >= 4) \ + || defined(__GNUC__) && (__GNUC__ >= 5)) + #define Z7_ATTRIB_NO_SSE __attribute__((__target__("no-sse"))) +#else + #define Z7_ATTRIB_NO_SSE +#endif + +#define Z7_ATTRIB_NO_VECTOR \ + Z7_ATTRIB_NO_VECTORIZE \ + Z7_ATTRIB_NO_SSE + + +#if defined(__clang__) && (__clang_major__ >= 8) \ + || defined(__GNUC__) && (__GNUC__ >= 1000) \ + /* || defined(_MSC_VER) && (_MSC_VER >= 1920) */ + // GCC is not good for __builtin_expect() + #define Z7_LIKELY(x) (__builtin_expect((x), 1)) + #define Z7_UNLIKELY(x) (__builtin_expect((x), 0)) + // #define Z7_unlikely [[unlikely]] + // #define Z7_likely [[likely]] +#else + #define Z7_LIKELY(x) (x) + #define Z7_UNLIKELY(x) (x) + // #define Z7_likely +#endif + + +#if (defined(Z7_CLANG_VERSION) && (Z7_CLANG_VERSION >= 30600)) + +#if (Z7_CLANG_VERSION < 130000) +#define Z7_DIAGNOSTIC_IGNORE_BEGIN_RESERVED_MACRO_IDENTIFIER \ + _Pragma("GCC diagnostic push") \ + _Pragma("GCC diagnostic ignored \"-Wreserved-id-macro\"") +#else +#define Z7_DIAGNOSTIC_IGNORE_BEGIN_RESERVED_MACRO_IDENTIFIER \ + _Pragma("GCC diagnostic push") \ + _Pragma("GCC diagnostic ignored \"-Wreserved-macro-identifier\"") +#endif + +#define Z7_DIAGNOSTIC_IGNORE_END_RESERVED_MACRO_IDENTIFIER \ + _Pragma("GCC diagnostic pop") +#else +#define Z7_DIAGNOSTIC_IGNORE_BEGIN_RESERVED_MACRO_IDENTIFIER +#define Z7_DIAGNOSTIC_IGNORE_END_RESERVED_MACRO_IDENTIFIER #endif #define UNUSED_VAR(x) (void)x; diff --git a/common/LZMA/SDK/C/CpuArch.c b/common/LZMA/SDK/C/CpuArch.c index 1d4d28b..6e02551 100644 --- a/common/LZMA/SDK/C/CpuArch.c +++ b/common/LZMA/SDK/C/CpuArch.c @@ -1,187 +1,357 @@ /* CpuArch.c -- CPU specific code -2021-07-13 : Igor Pavlov : Public domain */ +Igor Pavlov : Public domain */ #include "Precomp.h" +// #include + #include "CpuArch.h" #ifdef MY_CPU_X86_OR_AMD64 -#if (defined(_MSC_VER) && !defined(MY_CPU_AMD64)) || defined(__GNUC__) -#define USE_ASM +#undef NEED_CHECK_FOR_CPUID +#if !defined(MY_CPU_AMD64) +#define NEED_CHECK_FOR_CPUID #endif -#if !defined(USE_ASM) && _MSC_VER >= 1500 -#include +/* + cpuid instruction supports (subFunction) parameter in ECX, + that is used only with some specific (function) parameter values. + most functions use only (subFunction==0). +*/ +/* + __cpuid(): MSVC and GCC/CLANG use same function/macro name + but parameters are different. + We use MSVC __cpuid() parameters style for our z7_x86_cpuid() function. +*/ + +#if defined(__GNUC__) /* && (__GNUC__ >= 10) */ \ + || defined(__clang__) /* && (__clang_major__ >= 10) */ + +/* there was some CLANG/GCC compilers that have issues with + rbx(ebx) handling in asm blocks in -fPIC mode (__PIC__ is defined). + compiler's contains the macro __cpuid() that is similar to our code. + The history of __cpuid() changes in CLANG/GCC: + GCC: + 2007: it preserved ebx for (__PIC__ && __i386__) + 2013: it preserved rbx and ebx for __PIC__ + 2014: it doesn't preserves rbx and ebx anymore + we suppose that (__GNUC__ >= 5) fixed that __PIC__ ebx/rbx problem. + CLANG: + 2014+: it preserves rbx, but only for 64-bit code. No __PIC__ check. + Why CLANG cares about 64-bit mode only, and doesn't care about ebx (in 32-bit)? + Do we need __PIC__ test for CLANG or we must care about rbx even if + __PIC__ is not defined? +*/ + +#define ASM_LN "\n" + +#if defined(MY_CPU_AMD64) && defined(__PIC__) \ + && ((defined (__GNUC__) && (__GNUC__ < 5)) || defined(__clang__)) + + /* "=&r" selects free register. It can select even rbx, if that register is free. + "=&D" for (RDI) also works, but the code can be larger with "=&D" + "2"(subFun) : 2 is (zero-based) index in the output constraint list "=c" (ECX). */ + +#define x86_cpuid_MACRO_2(p, func, subFunc) { \ + __asm__ __volatile__ ( \ + ASM_LN "mov %%rbx, %q1" \ + ASM_LN "cpuid" \ + ASM_LN "xchg %%rbx, %q1" \ + : "=a" ((p)[0]), "=&r" ((p)[1]), "=c" ((p)[2]), "=d" ((p)[3]) : "0" (func), "2"(subFunc)); } + +#elif defined(MY_CPU_X86) && defined(__PIC__) \ + && ((defined (__GNUC__) && (__GNUC__ < 5)) || defined(__clang__)) + +#define x86_cpuid_MACRO_2(p, func, subFunc) { \ + __asm__ __volatile__ ( \ + ASM_LN "mov %%ebx, %k1" \ + ASM_LN "cpuid" \ + ASM_LN "xchg %%ebx, %k1" \ + : "=a" ((p)[0]), "=&r" ((p)[1]), "=c" ((p)[2]), "=d" ((p)[3]) : "0" (func), "2"(subFunc)); } + +#else + +#define x86_cpuid_MACRO_2(p, func, subFunc) { \ + __asm__ __volatile__ ( \ + ASM_LN "cpuid" \ + : "=a" ((p)[0]), "=b" ((p)[1]), "=c" ((p)[2]), "=d" ((p)[3]) : "0" (func), "2"(subFunc)); } + #endif -#if defined(USE_ASM) && !defined(MY_CPU_AMD64) -static UInt32 CheckFlag(UInt32 flag) +#define x86_cpuid_MACRO(p, func) x86_cpuid_MACRO_2(p, func, 0) + +void Z7_FASTCALL z7_x86_cpuid(UInt32 p[4], UInt32 func) { - #ifdef _MSC_VER - __asm pushfd; - __asm pop EAX; - __asm mov EDX, EAX; - __asm xor EAX, flag; - __asm push EAX; - __asm popfd; - __asm pushfd; - __asm pop EAX; - __asm xor EAX, EDX; - __asm push EDX; - __asm popfd; - __asm and flag, EAX; - #else - __asm__ __volatile__ ( - "pushf\n\t" - "pop %%EAX\n\t" - "movl %%EAX,%%EDX\n\t" - "xorl %0,%%EAX\n\t" - "push %%EAX\n\t" - "popf\n\t" - "pushf\n\t" - "pop %%EAX\n\t" - "xorl %%EDX,%%EAX\n\t" - "push %%EDX\n\t" - "popf\n\t" - "andl %%EAX, %0\n\t": - "=c" (flag) : "c" (flag) : - "%eax", "%edx"); - #endif - return flag; + x86_cpuid_MACRO(p, func) } -#define CHECK_CPUID_IS_SUPPORTED if (CheckFlag(1 << 18) == 0 || CheckFlag(1 << 21) == 0) return False; + +static +void Z7_FASTCALL z7_x86_cpuid_subFunc(UInt32 p[4], UInt32 func, UInt32 subFunc) +{ + x86_cpuid_MACRO_2(p, func, subFunc) +} + + +Z7_NO_INLINE +UInt32 Z7_FASTCALL z7_x86_cpuid_GetMaxFunc(void) +{ + #if defined(NEED_CHECK_FOR_CPUID) + #define EFALGS_CPUID_BIT 21 + UInt32 a; + __asm__ __volatile__ ( + ASM_LN "pushf" + ASM_LN "pushf" + ASM_LN "pop %0" + // ASM_LN "movl %0, %1" + // ASM_LN "xorl $0x200000, %0" + ASM_LN "btc %1, %0" + ASM_LN "push %0" + ASM_LN "popf" + ASM_LN "pushf" + ASM_LN "pop %0" + ASM_LN "xorl (%%esp), %0" + + ASM_LN "popf" + ASM_LN + : "=&r" (a) // "=a" + : "i" (EFALGS_CPUID_BIT) + ); + if ((a & (1 << EFALGS_CPUID_BIT)) == 0) + return 0; + #endif + { + UInt32 p[4]; + x86_cpuid_MACRO(p, 0) + return p[0]; + } +} + +#undef ASM_LN + +#elif !defined(_MSC_VER) + +/* +// for gcc/clang and other: we can try to use __cpuid macro: +#include +void Z7_FASTCALL z7_x86_cpuid(UInt32 p[4], UInt32 func) +{ + __cpuid(func, p[0], p[1], p[2], p[3]); +} +UInt32 Z7_FASTCALL z7_x86_cpuid_GetMaxFunc(void) +{ + return (UInt32)__get_cpuid_max(0, NULL); +} +*/ +// for unsupported cpuid: +void Z7_FASTCALL z7_x86_cpuid(UInt32 p[4], UInt32 func) +{ + UNUSED_VAR(func) + p[0] = p[1] = p[2] = p[3] = 0; +} +UInt32 Z7_FASTCALL z7_x86_cpuid_GetMaxFunc(void) +{ + return 0; +} + +#else // _MSC_VER + +#if !defined(MY_CPU_AMD64) + +UInt32 __declspec(naked) Z7_FASTCALL z7_x86_cpuid_GetMaxFunc(void) +{ + #if defined(NEED_CHECK_FOR_CPUID) + #define EFALGS_CPUID_BIT 21 + __asm pushfd + __asm pushfd + /* + __asm pop eax + // __asm mov edx, eax + __asm btc eax, EFALGS_CPUID_BIT + __asm push eax + */ + __asm btc dword ptr [esp], EFALGS_CPUID_BIT + __asm popfd + __asm pushfd + __asm pop eax + // __asm xor eax, edx + __asm xor eax, [esp] + // __asm push edx + __asm popfd + __asm and eax, (1 shl EFALGS_CPUID_BIT) + __asm jz end_func + #endif + __asm push ebx + __asm xor eax, eax // func + __asm xor ecx, ecx // subFunction (optional) for (func == 0) + __asm cpuid + __asm pop ebx + #if defined(NEED_CHECK_FOR_CPUID) + end_func: + #endif + __asm ret 0 +} + +void __declspec(naked) Z7_FASTCALL z7_x86_cpuid(UInt32 p[4], UInt32 func) +{ + UNUSED_VAR(p) + UNUSED_VAR(func) + __asm push ebx + __asm push edi + __asm mov edi, ecx // p + __asm mov eax, edx // func + __asm xor ecx, ecx // subfunction (optional) for (func == 0) + __asm cpuid + __asm mov [edi ], eax + __asm mov [edi + 4], ebx + __asm mov [edi + 8], ecx + __asm mov [edi + 12], edx + __asm pop edi + __asm pop ebx + __asm ret 0 +} + +static +void __declspec(naked) Z7_FASTCALL z7_x86_cpuid_subFunc(UInt32 p[4], UInt32 func, UInt32 subFunc) +{ + UNUSED_VAR(p) + UNUSED_VAR(func) + UNUSED_VAR(subFunc) + __asm push ebx + __asm push edi + __asm mov edi, ecx // p + __asm mov eax, edx // func + __asm mov ecx, [esp + 12] // subFunc + __asm cpuid + __asm mov [edi ], eax + __asm mov [edi + 4], ebx + __asm mov [edi + 8], ecx + __asm mov [edi + 12], edx + __asm pop edi + __asm pop ebx + __asm ret 4 +} + +#else // MY_CPU_AMD64 + + #if _MSC_VER >= 1600 + #include + #define MY_cpuidex __cpuidex + +static +void Z7_FASTCALL z7_x86_cpuid_subFunc(UInt32 p[4], UInt32 func, UInt32 subFunc) +{ + __cpuidex((int *)p, func, subFunc); +} + + #else +/* + __cpuid (func == (0 or 7)) requires subfunction number in ECX. + MSDN: The __cpuid intrinsic clears the ECX register before calling the cpuid instruction. + __cpuid() in new MSVC clears ECX. + __cpuid() in old MSVC (14.00) x64 doesn't clear ECX + We still can use __cpuid for low (func) values that don't require ECX, + but __cpuid() in old MSVC will be incorrect for some func values: (func == 7). + So here we use the hack for old MSVC to send (subFunction) in ECX register to cpuid instruction, + where ECX value is first parameter for FASTCALL / NO_INLINE func. + So the caller of MY_cpuidex_HACK() sets ECX as subFunction, and + old MSVC for __cpuid() doesn't change ECX and cpuid instruction gets (subFunction) value. + +DON'T remove Z7_NO_INLINE and Z7_FASTCALL for MY_cpuidex_HACK(): !!! +*/ +static +Z7_NO_INLINE void Z7_FASTCALL MY_cpuidex_HACK(Int32 subFunction, Int32 func, Int32 *CPUInfo) +{ + UNUSED_VAR(subFunction) + __cpuid(CPUInfo, func); +} + #define MY_cpuidex(info, func, func2) MY_cpuidex_HACK(func2, func, info) + #pragma message("======== MY_cpuidex_HACK WAS USED ========") +static +void Z7_FASTCALL z7_x86_cpuid_subFunc(UInt32 p[4], UInt32 func, UInt32 subFunc) +{ + MY_cpuidex_HACK(subFunc, func, (Int32 *)p); +} + #endif // _MSC_VER >= 1600 + +#if !defined(MY_CPU_AMD64) +/* inlining for __cpuid() in MSVC x86 (32-bit) produces big ineffective code, + so we disable inlining here */ +Z7_NO_INLINE +#endif +void Z7_FASTCALL z7_x86_cpuid(UInt32 p[4], UInt32 func) +{ + MY_cpuidex((Int32 *)p, (Int32)func, 0); +} + +Z7_NO_INLINE +UInt32 Z7_FASTCALL z7_x86_cpuid_GetMaxFunc(void) +{ + Int32 a[4]; + MY_cpuidex(a, 0, 0); + return a[0]; +} + +#endif // MY_CPU_AMD64 +#endif // _MSC_VER + +#if defined(NEED_CHECK_FOR_CPUID) +#define CHECK_CPUID_IS_SUPPORTED { if (z7_x86_cpuid_GetMaxFunc() == 0) return 0; } #else #define CHECK_CPUID_IS_SUPPORTED #endif +#undef NEED_CHECK_FOR_CPUID -#ifndef USE_ASM - #ifdef _MSC_VER - #if _MSC_VER >= 1600 - #define MY__cpuidex __cpuidex - #else - -/* - __cpuid (function == 4) requires subfunction number in ECX. - MSDN: The __cpuid intrinsic clears the ECX register before calling the cpuid instruction. - __cpuid() in new MSVC clears ECX. - __cpuid() in old MSVC (14.00) doesn't clear ECX - We still can use __cpuid for low (function) values that don't require ECX, - but __cpuid() in old MSVC will be incorrect for some function values: (function == 4). - So here we use the hack for old MSVC to send (subFunction) in ECX register to cpuid instruction, - where ECX value is first parameter for FAST_CALL / NO_INLINE function, - So the caller of MY__cpuidex_HACK() sets ECX as subFunction, and - old MSVC for __cpuid() doesn't change ECX and cpuid instruction gets (subFunction) value. - - DON'T remove MY_NO_INLINE and MY_FAST_CALL for MY__cpuidex_HACK() !!! -*/ static -MY_NO_INLINE -void MY_FAST_CALL MY__cpuidex_HACK(UInt32 subFunction, int *CPUInfo, UInt32 function) -{ - UNUSED_VAR(subFunction); - __cpuid(CPUInfo, function); -} - - #define MY__cpuidex(info, func, func2) MY__cpuidex_HACK(func2, info, func) - #pragma message("======== MY__cpuidex_HACK WAS USED ========") - #endif - #else - #define MY__cpuidex(info, func, func2) __cpuid(info, func) - #pragma message("======== (INCORRECT ?) cpuid WAS USED ========") - #endif -#endif - - - - -void MyCPUID(UInt32 function, UInt32 *a, UInt32 *b, UInt32 *c, UInt32 *d) -{ - #ifdef USE_ASM - - #ifdef _MSC_VER - - UInt32 a2, b2, c2, d2; - __asm xor EBX, EBX; - __asm xor ECX, ECX; - __asm xor EDX, EDX; - __asm mov EAX, function; - __asm cpuid; - __asm mov a2, EAX; - __asm mov b2, EBX; - __asm mov c2, ECX; - __asm mov d2, EDX; - - *a = a2; - *b = b2; - *c = c2; - *d = d2; - - #else - - __asm__ __volatile__ ( - #if defined(MY_CPU_AMD64) && defined(__PIC__) - "mov %%rbx, %%rdi;" - "cpuid;" - "xchg %%rbx, %%rdi;" - : "=a" (*a) , - "=D" (*b) , - #elif defined(MY_CPU_X86) && defined(__PIC__) - "mov %%ebx, %%edi;" - "cpuid;" - "xchgl %%ebx, %%edi;" - : "=a" (*a) , - "=D" (*b) , - #else - "cpuid" - : "=a" (*a) , - "=b" (*b) , - #endif - "=c" (*c) , - "=d" (*d) - : "0" (function), "c"(0) ) ; - - #endif - - #else - - int CPUInfo[4]; - - MY__cpuidex(CPUInfo, (int)function, 0); - - *a = (UInt32)CPUInfo[0]; - *b = (UInt32)CPUInfo[1]; - *c = (UInt32)CPUInfo[2]; - *d = (UInt32)CPUInfo[3]; - - #endif -} - -BoolInt x86cpuid_CheckAndRead(Cx86cpuid *p) +BoolInt x86cpuid_Func_1(UInt32 *p) { CHECK_CPUID_IS_SUPPORTED - MyCPUID(0, &p->maxFunc, &p->vendor[0], &p->vendor[2], &p->vendor[1]); - MyCPUID(1, &p->ver, &p->b, &p->c, &p->d); + z7_x86_cpuid(p, 1); return True; } -static const UInt32 kVendors[][3] = +/* +static const UInt32 kVendors[][1] = { - { 0x756E6547, 0x49656E69, 0x6C65746E}, - { 0x68747541, 0x69746E65, 0x444D4163}, - { 0x746E6543, 0x48727561, 0x736C7561} + { 0x756E6547 }, // , 0x49656E69, 0x6C65746E }, + { 0x68747541 }, // , 0x69746E65, 0x444D4163 }, + { 0x746E6543 } // , 0x48727561, 0x736C7561 } }; +*/ + +/* +typedef struct +{ + UInt32 maxFunc; + UInt32 vendor[3]; + UInt32 ver; + UInt32 b; + UInt32 c; + UInt32 d; +} Cx86cpuid; + +enum +{ + CPU_FIRM_INTEL, + CPU_FIRM_AMD, + CPU_FIRM_VIA +}; +int x86cpuid_GetFirm(const Cx86cpuid *p); +#define x86cpuid_ver_GetFamily(ver) (((ver >> 16) & 0xff0) | ((ver >> 8) & 0xf)) +#define x86cpuid_ver_GetModel(ver) (((ver >> 12) & 0xf0) | ((ver >> 4) & 0xf)) +#define x86cpuid_ver_GetStepping(ver) (ver & 0xf) int x86cpuid_GetFirm(const Cx86cpuid *p) { unsigned i; - for (i = 0; i < sizeof(kVendors) / sizeof(kVendors[i]); i++) + for (i = 0; i < sizeof(kVendors) / sizeof(kVendors[0]); i++) { const UInt32 *v = kVendors[i]; - if (v[0] == p->vendor[0] && - v[1] == p->vendor[1] && - v[2] == p->vendor[2]) + if (v[0] == p->vendor[0] + // && v[1] == p->vendor[1] + // && v[2] == p->vendor[2] + ) return (int)i; } return -1; @@ -190,41 +360,55 @@ int x86cpuid_GetFirm(const Cx86cpuid *p) BoolInt CPU_Is_InOrder() { Cx86cpuid p; - int firm; UInt32 family, model; if (!x86cpuid_CheckAndRead(&p)) return True; - family = x86cpuid_GetFamily(p.ver); - model = x86cpuid_GetModel(p.ver); - - firm = x86cpuid_GetFirm(&p); + family = x86cpuid_ver_GetFamily(p.ver); + model = x86cpuid_ver_GetModel(p.ver); - switch (firm) + switch (x86cpuid_GetFirm(&p)) { case CPU_FIRM_INTEL: return (family < 6 || (family == 6 && ( - /* In-Order Atom CPU */ - model == 0x1C /* 45 nm, N4xx, D4xx, N5xx, D5xx, 230, 330 */ - || model == 0x26 /* 45 nm, Z6xx */ - || model == 0x27 /* 32 nm, Z2460 */ - || model == 0x35 /* 32 nm, Z2760 */ - || model == 0x36 /* 32 nm, N2xxx, D2xxx */ + // In-Order Atom CPU + model == 0x1C // 45 nm, N4xx, D4xx, N5xx, D5xx, 230, 330 + || model == 0x26 // 45 nm, Z6xx + || model == 0x27 // 32 nm, Z2460 + || model == 0x35 // 32 nm, Z2760 + || model == 0x36 // 32 nm, N2xxx, D2xxx ))); case CPU_FIRM_AMD: return (family < 5 || (family == 5 && (model < 6 || model == 0xA))); case CPU_FIRM_VIA: return (family < 6 || (family == 6 && model < 0xF)); } - return True; + return False; // v23 : unknown processors are not In-Order } +*/ + +#ifdef _WIN32 +#include "7zWindows.h" +#endif #if !defined(MY_CPU_AMD64) && defined(_WIN32) -#include -static BoolInt CPU_Sys_Is_SSE_Supported() + +/* for legacy SSE ia32: there is no user-space cpu instruction to check + that OS supports SSE register storing/restoring on context switches. + So we need some OS-specific function to check that it's safe to use SSE registers. +*/ + +Z7_FORCE_INLINE +static BoolInt CPU_Sys_Is_SSE_Supported(void) { - OSVERSIONINFO vi; - vi.dwOSVersionInfoSize = sizeof(vi); - if (!GetVersionEx(&vi)) - return False; - return (vi.dwMajorVersion >= 5); +#ifdef _MSC_VER + #pragma warning(push) + #pragma warning(disable : 4996) // `GetVersion': was declared deprecated +#endif + /* low byte is major version of Windows + We suppose that any Windows version since + Windows2000 (major == 5) supports SSE registers */ + return (Byte)GetVersion() >= 5; +#if defined(_MSC_VER) + #pragma warning(pop) +#endif } #define CHECK_SYS_SSE_SUPPORT if (!CPU_Sys_Is_SSE_Supported()) return False; #else @@ -232,117 +416,364 @@ static BoolInt CPU_Sys_Is_SSE_Supported() #endif -static UInt32 X86_CPUID_ECX_Get_Flags() +#if !defined(MY_CPU_AMD64) + +BoolInt CPU_IsSupported_CMOV(void) { - Cx86cpuid p; - CHECK_SYS_SSE_SUPPORT - if (!x86cpuid_CheckAndRead(&p)) + UInt32 a[4]; + if (!x86cpuid_Func_1(&a[0])) return 0; - return p.c; + return (BoolInt)(a[3] >> 15) & 1; } -BoolInt CPU_IsSupported_AES() +BoolInt CPU_IsSupported_SSE(void) { - return (X86_CPUID_ECX_Get_Flags() >> 25) & 1; -} - -BoolInt CPU_IsSupported_SSSE3() -{ - return (X86_CPUID_ECX_Get_Flags() >> 9) & 1; -} - -BoolInt CPU_IsSupported_SSE41() -{ - return (X86_CPUID_ECX_Get_Flags() >> 19) & 1; -} - -BoolInt CPU_IsSupported_SHA() -{ - Cx86cpuid p; + UInt32 a[4]; CHECK_SYS_SSE_SUPPORT - if (!x86cpuid_CheckAndRead(&p)) - return False; - - if (p.maxFunc < 7) - return False; - { - UInt32 d[4] = { 0 }; - MyCPUID(7, &d[0], &d[1], &d[2], &d[3]); - return (d[1] >> 29) & 1; - } + if (!x86cpuid_Func_1(&a[0])) + return 0; + return (BoolInt)(a[3] >> 25) & 1; } -// #include +BoolInt CPU_IsSupported_SSE2(void) +{ + UInt32 a[4]; + CHECK_SYS_SSE_SUPPORT + if (!x86cpuid_Func_1(&a[0])) + return 0; + return (BoolInt)(a[3] >> 26) & 1; +} -#ifdef _WIN32 -#include #endif -BoolInt CPU_IsSupported_AVX2() + +static UInt32 x86cpuid_Func_1_ECX(void) +{ + UInt32 a[4]; + CHECK_SYS_SSE_SUPPORT + if (!x86cpuid_Func_1(&a[0])) + return 0; + return a[2]; +} + +BoolInt CPU_IsSupported_AES(void) +{ + return (BoolInt)(x86cpuid_Func_1_ECX() >> 25) & 1; +} + +BoolInt CPU_IsSupported_SSSE3(void) +{ + return (BoolInt)(x86cpuid_Func_1_ECX() >> 9) & 1; +} + +BoolInt CPU_IsSupported_SSE41(void) +{ + return (BoolInt)(x86cpuid_Func_1_ECX() >> 19) & 1; +} + +BoolInt CPU_IsSupported_SHA(void) { - Cx86cpuid p; CHECK_SYS_SSE_SUPPORT - #ifdef _WIN32 - #define MY__PF_XSAVE_ENABLED 17 - if (!IsProcessorFeaturePresent(MY__PF_XSAVE_ENABLED)) - return False; - #endif - - if (!x86cpuid_CheckAndRead(&p)) - return False; - if (p.maxFunc < 7) + if (z7_x86_cpuid_GetMaxFunc() < 7) return False; { - UInt32 d[4] = { 0 }; - MyCPUID(7, &d[0], &d[1], &d[2], &d[3]); - // printf("\ncpuid(7): ebx=%8x ecx=%8x\n", d[1], d[2]); - return 1 - & (d[1] >> 5); // avx2 + UInt32 d[4]; + z7_x86_cpuid(d, 7); + return (BoolInt)(d[1] >> 29) & 1; } } -BoolInt CPU_IsSupported_VAES_AVX2() + +BoolInt CPU_IsSupported_SHA512(void) { - Cx86cpuid p; - CHECK_SYS_SSE_SUPPORT + if (!CPU_IsSupported_AVX2()) return False; // maybe CPU_IsSupported_AVX() is enough here - #ifdef _WIN32 - #define MY__PF_XSAVE_ENABLED 17 - if (!IsProcessorFeaturePresent(MY__PF_XSAVE_ENABLED)) - return False; - #endif - - if (!x86cpuid_CheckAndRead(&p)) - return False; - if (p.maxFunc < 7) + if (z7_x86_cpuid_GetMaxFunc() < 7) return False; { - UInt32 d[4] = { 0 }; - MyCPUID(7, &d[0], &d[1], &d[2], &d[3]); - // printf("\ncpuid(7): ebx=%8x ecx=%8x\n", d[1], d[2]); - return 1 - & (d[1] >> 5) // avx2 - // & (d[1] >> 31) // avx512vl - & (d[2] >> 9); // vaes // VEX-256/EVEX + UInt32 d[4]; + z7_x86_cpuid_subFunc(d, 7, 0); + if (d[0] < 1) // d[0] - is max supported subleaf value + return False; + z7_x86_cpuid_subFunc(d, 7, 1); + return (BoolInt)(d[0]) & 1; } } -BoolInt CPU_IsSupported_PageGB() +/* +MSVC: _xgetbv() intrinsic is available since VS2010SP1. + MSVC also defines (_XCR_XFEATURE_ENABLED_MASK) macro in + that we can use or check. + For any 32-bit x86 we can use asm code in MSVC, + but MSVC asm code is huge after compilation. + So _xgetbv() is better + +ICC: _xgetbv() intrinsic is available (in what version of ICC?) + ICC defines (__GNUC___) and it supports gnu assembler + also ICC supports MASM style code with -use-msasm switch. + but ICC doesn't support __attribute__((__target__)) + +GCC/CLANG 9: + _xgetbv() is macro that works via __builtin_ia32_xgetbv() + and we need __attribute__((__target__("xsave")). + But with __target__("xsave") the function will be not + inlined to function that has no __target__("xsave") attribute. + If we want _xgetbv() call inlining, then we should use asm version + instead of calling _xgetbv(). + Note:intrinsic is broke before GCC 8.2: + https://gcc.gnu.org/bugzilla/show_bug.cgi?id=85684 +*/ + +#if defined(__INTEL_COMPILER) && (__INTEL_COMPILER >= 1100) \ + || defined(_MSC_VER) && (_MSC_VER >= 1600) && (_MSC_FULL_VER >= 160040219) \ + || defined(__GNUC__) && (__GNUC__ >= 9) \ + || defined(__clang__) && (__clang_major__ >= 9) +// we define ATTRIB_XGETBV, if we want to use predefined _xgetbv() from compiler +#if defined(__INTEL_COMPILER) +#define ATTRIB_XGETBV +#elif defined(__GNUC__) || defined(__clang__) +// we don't define ATTRIB_XGETBV here, because asm version is better for inlining. +// #define ATTRIB_XGETBV __attribute__((__target__("xsave"))) +#else +#define ATTRIB_XGETBV +#endif +#endif + +#if defined(ATTRIB_XGETBV) +#include +#endif + + +// XFEATURE_ENABLED_MASK/XCR0 +#define MY_XCR_XFEATURE_ENABLED_MASK 0 + +#if defined(ATTRIB_XGETBV) +ATTRIB_XGETBV +#endif +static UInt64 x86_xgetbv_0(UInt32 num) { - Cx86cpuid cpuid; - if (!x86cpuid_CheckAndRead(&cpuid)) +#if defined(ATTRIB_XGETBV) + { + return + #if (defined(_MSC_VER)) + _xgetbv(num); + #else + __builtin_ia32_xgetbv( + #if !defined(__clang__) + (int) + #endif + num); + #endif + } + +#elif defined(__GNUC__) || defined(__clang__) || defined(__SUNPRO_CC) + + UInt32 a, d; + #if defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4)) + __asm__ + ( + "xgetbv" + : "=a"(a), "=d"(d) : "c"(num) : "cc" + ); + #else // is old gcc + __asm__ + ( + ".byte 0x0f, 0x01, 0xd0" "\n\t" + : "=a"(a), "=d"(d) : "c"(num) : "cc" + ); + #endif + return ((UInt64)d << 32) | a; + // return a; + +#elif defined(_MSC_VER) && !defined(MY_CPU_AMD64) + + UInt32 a, d; + __asm { + push eax + push edx + push ecx + mov ecx, num; + // xor ecx, ecx // = MY_XCR_XFEATURE_ENABLED_MASK + _emit 0x0f + _emit 0x01 + _emit 0xd0 + mov a, eax + mov d, edx + pop ecx + pop edx + pop eax + } + return ((UInt64)d << 32) | a; + // return a; + +#else // it's unknown compiler + // #error "Need xgetbv function" + UNUSED_VAR(num) + // for MSVC-X64 we could call external function from external file. + /* Actually we had checked OSXSAVE/AVX in cpuid before. + So it's expected that OS supports at least AVX and below. */ + // if (num != MY_XCR_XFEATURE_ENABLED_MASK) return 0; // if not XCR0 + return + // (1 << 0) | // x87 + (1 << 1) // SSE + | (1 << 2); // AVX + +#endif +} + +#ifdef _WIN32 +/* + Windows versions do not know about new ISA extensions that + can be introduced. But we still can use new extensions, + even if Windows doesn't report about supporting them, + But we can use new extensions, only if Windows knows about new ISA extension + that changes the number or size of registers: SSE, AVX/XSAVE, AVX512 + So it's enough to check + MY_PF_AVX_INSTRUCTIONS_AVAILABLE + instead of + MY_PF_AVX2_INSTRUCTIONS_AVAILABLE +*/ +#define MY_PF_XSAVE_ENABLED 17 +// #define MY_PF_SSSE3_INSTRUCTIONS_AVAILABLE 36 +// #define MY_PF_SSE4_1_INSTRUCTIONS_AVAILABLE 37 +// #define MY_PF_SSE4_2_INSTRUCTIONS_AVAILABLE 38 +// #define MY_PF_AVX_INSTRUCTIONS_AVAILABLE 39 +// #define MY_PF_AVX2_INSTRUCTIONS_AVAILABLE 40 +// #define MY_PF_AVX512F_INSTRUCTIONS_AVAILABLE 41 +#endif + +BoolInt CPU_IsSupported_AVX(void) +{ + #ifdef _WIN32 + if (!IsProcessorFeaturePresent(MY_PF_XSAVE_ENABLED)) + return False; + /* PF_AVX_INSTRUCTIONS_AVAILABLE probably is supported starting from + some latest Win10 revisions. But we need AVX in older Windows also. + So we don't use the following check: */ + /* + if (!IsProcessorFeaturePresent(MY_PF_AVX_INSTRUCTIONS_AVAILABLE)) + return False; + */ + #endif + + /* + OS must use new special XSAVE/XRSTOR instructions to save + AVX registers when it required for context switching. + At OS statring: + OS sets CR4.OSXSAVE flag to signal the processor that OS supports the XSAVE extensions. + Also OS sets bitmask in XCR0 register that defines what + registers will be processed by XSAVE instruction: + XCR0.SSE[bit 0] - x87 registers and state + XCR0.SSE[bit 1] - SSE registers and state + XCR0.AVX[bit 2] - AVX registers and state + CR4.OSXSAVE is reflected to CPUID.1:ECX.OSXSAVE[bit 27]. + So we can read that bit in user-space. + XCR0 is available for reading in user-space by new XGETBV instruction. + */ + { + const UInt32 c = x86cpuid_Func_1_ECX(); + if (0 == (1 + & (c >> 28) // AVX instructions are supported by hardware + & (c >> 27))) // OSXSAVE bit: XSAVE and related instructions are enabled by OS. + return False; + } + + /* also we can check + CPUID.1:ECX.XSAVE [bit 26] : that shows that + XSAVE, XRESTOR, XSETBV, XGETBV instructions are supported by hardware. + But that check is redundant, because if OSXSAVE bit is set, then XSAVE is also set */ + + /* If OS have enabled XSAVE extension instructions (OSXSAVE == 1), + in most cases we expect that OS also will support storing/restoring + for AVX and SSE states at least. + But to be ensure for that we call user-space instruction + XGETBV(0) to get XCR0 value that contains bitmask that defines + what exact states(registers) OS have enabled for storing/restoring. + */ + + { + const UInt32 bm = (UInt32)x86_xgetbv_0(MY_XCR_XFEATURE_ENABLED_MASK); + // printf("\n=== XGetBV=0x%x\n", bm); + return 1 + & (BoolInt)(bm >> 1) // SSE state is supported (set by OS) for storing/restoring + & (BoolInt)(bm >> 2); // AVX state is supported (set by OS) for storing/restoring + } + // since Win7SP1: we can use GetEnabledXStateFeatures(); +} + + +BoolInt CPU_IsSupported_AVX2(void) +{ + if (!CPU_IsSupported_AVX()) + return False; + if (z7_x86_cpuid_GetMaxFunc() < 7) return False; { - UInt32 d[4] = { 0 }; - MyCPUID(0x80000000, &d[0], &d[1], &d[2], &d[3]); - if (d[0] < 0x80000001) + UInt32 d[4]; + z7_x86_cpuid(d, 7); + // printf("\ncpuid(7): ebx=%8x ecx=%8x\n", d[1], d[2]); + return 1 + & (BoolInt)(d[1] >> 5); // avx2 + } +} + +#if 0 +BoolInt CPU_IsSupported_AVX512F_AVX512VL(void) +{ + if (!CPU_IsSupported_AVX()) + return False; + if (z7_x86_cpuid_GetMaxFunc() < 7) + return False; + { + UInt32 d[4]; + BoolInt v; + z7_x86_cpuid(d, 7); + // printf("\ncpuid(7): ebx=%8x ecx=%8x\n", d[1], d[2]); + v = 1 + & (BoolInt)(d[1] >> 16) // avx512f + & (BoolInt)(d[1] >> 31); // avx512vl + if (!v) return False; } { - UInt32 d[4] = { 0 }; - MyCPUID(0x80000001, &d[0], &d[1], &d[2], &d[3]); - return (d[3] >> 26) & 1; + const UInt32 bm = (UInt32)x86_xgetbv_0(MY_XCR_XFEATURE_ENABLED_MASK); + // printf("\n=== XGetBV=0x%x\n", bm); + return 1 + & (BoolInt)(bm >> 5) // OPMASK + & (BoolInt)(bm >> 6) // ZMM upper 256-bit + & (BoolInt)(bm >> 7); // ZMM16 ... ZMM31 + } +} +#endif + +BoolInt CPU_IsSupported_VAES_AVX2(void) +{ + if (!CPU_IsSupported_AVX()) + return False; + if (z7_x86_cpuid_GetMaxFunc() < 7) + return False; + { + UInt32 d[4]; + z7_x86_cpuid(d, 7); + // printf("\ncpuid(7): ebx=%8x ecx=%8x\n", d[1], d[2]); + return 1 + & (BoolInt)(d[1] >> 5) // avx2 + // & (d[1] >> 31) // avx512vl + & (BoolInt)(d[2] >> 9); // vaes // VEX-256/EVEX + } +} + +BoolInt CPU_IsSupported_PageGB(void) +{ + CHECK_CPUID_IS_SUPPORTED + { + UInt32 d[4]; + z7_x86_cpuid(d, 0x80000000); + if (d[0] < 0x80000001) + return False; + z7_x86_cpuid(d, 0x80000001); + return (BoolInt)(d[3] >> 26) & 1; } } @@ -351,11 +782,11 @@ BoolInt CPU_IsSupported_PageGB() #ifdef _WIN32 -#include +#include "7zWindows.h" -BoolInt CPU_IsSupported_CRC32() { return IsProcessorFeaturePresent(PF_ARM_V8_CRC32_INSTRUCTIONS_AVAILABLE) ? 1 : 0; } -BoolInt CPU_IsSupported_CRYPTO() { return IsProcessorFeaturePresent(PF_ARM_V8_CRYPTO_INSTRUCTIONS_AVAILABLE) ? 1 : 0; } -BoolInt CPU_IsSupported_NEON() { return IsProcessorFeaturePresent(PF_ARM_NEON_INSTRUCTIONS_AVAILABLE) ? 1 : 0; } +BoolInt CPU_IsSupported_CRC32(void) { return IsProcessorFeaturePresent(PF_ARM_V8_CRC32_INSTRUCTIONS_AVAILABLE) ? 1 : 0; } +BoolInt CPU_IsSupported_CRYPTO(void) { return IsProcessorFeaturePresent(PF_ARM_V8_CRYPTO_INSTRUCTIONS_AVAILABLE) ? 1 : 0; } +BoolInt CPU_IsSupported_NEON(void) { return IsProcessorFeaturePresent(PF_ARM_NEON_INSTRUCTIONS_AVAILABLE) ? 1 : 0; } #else @@ -378,30 +809,41 @@ static void Print_sysctlbyname(const char *name) } } */ +/* + Print_sysctlbyname("hw.pagesize"); + Print_sysctlbyname("machdep.cpu.brand_string"); +*/ -static BoolInt My_sysctlbyname_Get_BoolInt(const char *name) +static BoolInt z7_sysctlbyname_Get_BoolInt(const char *name) { UInt32 val = 0; - if (My_sysctlbyname_Get_UInt32(name, &val) == 0 && val == 1) + if (z7_sysctlbyname_Get_UInt32(name, &val) == 0 && val == 1) return 1; return 0; } - /* - Print_sysctlbyname("hw.pagesize"); - Print_sysctlbyname("machdep.cpu.brand_string"); - */ - BoolInt CPU_IsSupported_CRC32(void) { - return My_sysctlbyname_Get_BoolInt("hw.optional.armv8_crc32"); + return z7_sysctlbyname_Get_BoolInt("hw.optional.armv8_crc32"); } BoolInt CPU_IsSupported_NEON(void) { - return My_sysctlbyname_Get_BoolInt("hw.optional.neon"); + return z7_sysctlbyname_Get_BoolInt("hw.optional.neon"); } +BoolInt CPU_IsSupported_SHA512(void) +{ + return z7_sysctlbyname_Get_BoolInt("hw.optional.armv8_2_sha512"); +} + +/* +BoolInt CPU_IsSupported_SHA3(void) +{ + return z7_sysctlbyname_Get_BoolInt("hw.optional.armv8_2_sha3"); +} +*/ + #ifdef MY_CPU_ARM64 #define APPLE_CRYPTO_SUPPORT_VAL 1 #else @@ -415,45 +857,70 @@ BoolInt CPU_IsSupported_AES (void) { return APPLE_CRYPTO_SUPPORT_VAL; } #else // __APPLE__ -#include +#if defined(__GLIBC__) && (__GLIBC__ * 100 + __GLIBC_MINOR__ >= 216) + #define Z7_GETAUXV_AVAILABLE +#else +// #pragma message("=== is not NEW GLIBC === ") + #if defined __has_include + #if __has_include () +// #pragma message("=== sys/auxv.h is avail=== ") + #define Z7_GETAUXV_AVAILABLE + #endif + #endif +#endif +#ifdef Z7_GETAUXV_AVAILABLE +// #pragma message("=== Z7_GETAUXV_AVAILABLE === ") +#include #define USE_HWCAP +#endif #ifdef USE_HWCAP -#ifdef __linux__ +#if defined(__FreeBSD__) +static unsigned long MY_getauxval(int aux) +{ + unsigned long val; + if (elf_aux_info(aux, &val, sizeof(val))) + return 0; + return val; +} +#else +#define MY_getauxval getauxval + #if defined __has_include + #if __has_include () #include + #endif + #endif #endif -#ifdef __linux__ #define MY_HWCAP_CHECK_FUNC_2(name1, name2) \ - BoolInt CPU_IsSupported_ ## name1() { return (getauxval(AT_HWCAP) & (HWCAP_ ## name2)) ? 1 : 0; } -#elif defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__DragonFly__) - #define MY_HWCAP_CHECK_FUNC_2(name1, name2) \ - BoolInt CPU_IsSupported_ ## name1() { uint32_t hwcaps = 0; elf_aux_info(AT_HWCAP, &hwcaps, sizeof(hwcaps)); return (hwcaps & (HWCAP_ ## name2)) ? 1 : 0; } -#endif + BoolInt CPU_IsSupported_ ## name1(void) { return (MY_getauxval(AT_HWCAP) & (HWCAP_ ## name2)); } #ifdef MY_CPU_ARM64 #define MY_HWCAP_CHECK_FUNC(name) \ MY_HWCAP_CHECK_FUNC_2(name, name) +#if 1 || defined(__ARM_NEON) + BoolInt CPU_IsSupported_NEON(void) { return True; } +#else MY_HWCAP_CHECK_FUNC_2(NEON, ASIMD) +#endif // MY_HWCAP_CHECK_FUNC (ASIMD) #elif defined(MY_CPU_ARM) -#ifdef __linux__ #define MY_HWCAP_CHECK_FUNC(name) \ - BoolInt CPU_IsSupported_ ## name() { return (getauxval(AT_HWCAP2) & (HWCAP2_ ## name)) ? 1 : 0; } -#elif defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__DragonFly__) - #define MY_HWCAP_CHECK_FUNC(name) \ - BoolInt CPU_IsSupported_ ## name() { uint32_t hwcaps = 0; elf_aux_info(AT_HWCAP2, &hwcaps, sizeof(hwcaps)); return (hwcaps & (HWCAP2_ ## name)) ? 1 : 0; } -#endif + BoolInt CPU_IsSupported_ ## name(void) { return (MY_getauxval(AT_HWCAP2) & (HWCAP2_ ## name)); } MY_HWCAP_CHECK_FUNC_2(NEON, NEON) #endif #else // USE_HWCAP #define MY_HWCAP_CHECK_FUNC(name) \ - BoolInt CPU_IsSupported_ ## name() { return 0; } + BoolInt CPU_IsSupported_ ## name(void) { return 0; } +#if defined(__ARM_NEON) + BoolInt CPU_IsSupported_NEON(void) { return True; } +#else MY_HWCAP_CHECK_FUNC(NEON) +#endif #endif // USE_HWCAP @@ -461,6 +928,19 @@ MY_HWCAP_CHECK_FUNC (CRC32) MY_HWCAP_CHECK_FUNC (SHA1) MY_HWCAP_CHECK_FUNC (SHA2) MY_HWCAP_CHECK_FUNC (AES) +#ifdef MY_CPU_ARM64 +// supports HWCAP_SHA512 and HWCAP_SHA3 since 2017. +// we define them here, if they are not defined +#ifndef HWCAP_SHA3 +// #define HWCAP_SHA3 (1 << 17) +#endif +#ifndef HWCAP_SHA512 +// #pragma message("=== HWCAP_SHA512 define === ") +#define HWCAP_SHA512 (1 << 21) +#endif +MY_HWCAP_CHECK_FUNC (SHA512) +// MY_HWCAP_CHECK_FUNC (SHA3) +#endif #endif // __APPLE__ #endif // _WIN32 @@ -473,15 +953,15 @@ MY_HWCAP_CHECK_FUNC (AES) #include -int My_sysctlbyname_Get(const char *name, void *buf, size_t *bufSize) +int z7_sysctlbyname_Get(const char *name, void *buf, size_t *bufSize) { return sysctlbyname(name, buf, bufSize, NULL, 0); } -int My_sysctlbyname_Get_UInt32(const char *name, UInt32 *val) +int z7_sysctlbyname_Get_UInt32(const char *name, UInt32 *val) { size_t bufSize = sizeof(*val); - int res = My_sysctlbyname_Get(name, val, &bufSize); + const int res = z7_sysctlbyname_Get(name, val, &bufSize); if (res == 0 && bufSize != sizeof(*val)) return EFAULT; return res; diff --git a/common/LZMA/SDK/C/CpuArch.h b/common/LZMA/SDK/C/CpuArch.h index 4856fbb..a6297ea 100644 --- a/common/LZMA/SDK/C/CpuArch.h +++ b/common/LZMA/SDK/C/CpuArch.h @@ -1,8 +1,8 @@ /* CpuArch.h -- CPU specific code -2022-07-15 : Igor Pavlov : Public domain */ +Igor Pavlov : Public domain */ -#ifndef __CPU_ARCH_H -#define __CPU_ARCH_H +#ifndef ZIP7_INC_CPU_ARCH_H +#define ZIP7_INC_CPU_ARCH_H #include "7zTypes.h" @@ -20,6 +20,7 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. MY_CPU_64BIT doesn't mean that (sizeof(void *) == 8) */ +#if !defined(_M_ARM64EC) #if defined(_M_X64) \ || defined(_M_AMD64) \ || defined(__x86_64__) \ @@ -35,6 +36,7 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. #endif #define MY_CPU_64BIT #endif +#endif #if defined(_M_IX86) \ @@ -47,11 +49,26 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. #if defined(_M_ARM64) \ + || defined(_M_ARM64EC) \ || defined(__AARCH64EL__) \ || defined(__AARCH64EB__) \ || defined(__aarch64__) #define MY_CPU_ARM64 - #define MY_CPU_NAME "arm64" +#if defined(__ILP32__) \ + || defined(__SIZEOF_POINTER__) && (__SIZEOF_POINTER__ == 4) + #define MY_CPU_NAME "arm64-32" + #define MY_CPU_SIZEOF_POINTER 4 +#elif defined(__SIZEOF_POINTER__) && (__SIZEOF_POINTER__ == 16) + #define MY_CPU_NAME "arm64-128" + #define MY_CPU_SIZEOF_POINTER 16 +#else +#if defined(_M_ARM64EC) + #define MY_CPU_NAME "arm64ec" +#else + #define MY_CPU_NAME "arm64" +#endif + #define MY_CPU_SIZEOF_POINTER 8 +#endif #define MY_CPU_64BIT #endif @@ -68,8 +85,10 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. #define MY_CPU_ARM #if defined(__thumb__) || defined(__THUMBEL__) || defined(_M_ARMT) + #define MY_CPU_ARMT #define MY_CPU_NAME "armt" #else + #define MY_CPU_ARM32 #define MY_CPU_NAME "arm" #endif /* #define MY_CPU_32BIT */ @@ -103,6 +122,8 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. || defined(__PPC__) \ || defined(_POWER) +#define MY_CPU_PPC_OR_PPC64 + #if defined(__ppc64__) \ || defined(__powerpc64__) \ || defined(_LP64) \ @@ -123,8 +144,36 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. #endif +#if defined(__sparc__) \ + || defined(__sparc) + #define MY_CPU_SPARC + #if defined(__LP64__) \ + || defined(_LP64) \ + || defined(__SIZEOF_POINTER__) && (__SIZEOF_POINTER__ == 8) + #define MY_CPU_NAME "sparcv9" + #define MY_CPU_SIZEOF_POINTER 8 + #define MY_CPU_64BIT + #elif defined(__sparc_v9__) \ + || defined(__sparcv9) + #define MY_CPU_64BIT + #if defined(__SIZEOF_POINTER__) && (__SIZEOF_POINTER__ == 4) + #define MY_CPU_NAME "sparcv9-32" + #else + #define MY_CPU_NAME "sparcv9m" + #endif + #elif defined(__sparc_v8__) \ + || defined(__sparcv8) + #define MY_CPU_NAME "sparcv8" + #define MY_CPU_SIZEOF_POINTER 4 + #else + #define MY_CPU_NAME "sparc" + #endif +#endif + + #if defined(__riscv) \ || defined(__riscv__) + #define MY_CPU_RISCV #if __riscv_xlen == 32 #define MY_CPU_NAME "riscv32" #elif __riscv_xlen == 64 @@ -135,6 +184,39 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. #endif +#if defined(__loongarch__) + #define MY_CPU_LOONGARCH + #if defined(__loongarch64) || defined(__loongarch_grlen) && (__loongarch_grlen == 64) + #define MY_CPU_64BIT + #endif + #if defined(__loongarch64) + #define MY_CPU_NAME "loongarch64" + #define MY_CPU_LOONGARCH64 + #else + #define MY_CPU_NAME "loongarch" + #endif +#endif + + +// #undef MY_CPU_NAME +// #undef MY_CPU_SIZEOF_POINTER +// #define __e2k__ +// #define __SIZEOF_POINTER__ 4 +#if defined(__e2k__) + #define MY_CPU_E2K + #if defined(__ILP32__) || defined(__SIZEOF_POINTER__) && (__SIZEOF_POINTER__ == 4) + #define MY_CPU_NAME "e2k-32" + #define MY_CPU_SIZEOF_POINTER 4 + #else + #define MY_CPU_NAME "e2k" + #if defined(__LP64__) || defined(__SIZEOF_POINTER__) && (__SIZEOF_POINTER__ == 8) + #define MY_CPU_SIZEOF_POINTER 8 + #endif + #endif + #define MY_CPU_64BIT +#endif + + #if defined(MY_CPU_X86) || defined(MY_CPU_AMD64) #define MY_CPU_X86_OR_AMD64 #endif @@ -165,6 +247,7 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. || defined(MY_CPU_ARM_LE) \ || defined(MY_CPU_ARM64_LE) \ || defined(MY_CPU_IA64_LE) \ + || defined(_LITTLE_ENDIAN) \ || defined(__LITTLE_ENDIAN__) \ || defined(__ARMEL__) \ || defined(__THUMBEL__) \ @@ -197,6 +280,9 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. #error Stop_Compiling_Bad_Endian #endif +#if !defined(MY_CPU_LE) && !defined(MY_CPU_BE) + #error Stop_Compiling_CPU_ENDIAN_must_be_detected_at_compile_time +#endif #if defined(MY_CPU_32BIT) && defined(MY_CPU_64BIT) #error Stop_Compiling_Bad_32_64_BIT @@ -238,6 +324,7 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. #ifndef MY_CPU_NAME + // #define MY_CPU_IS_UNKNOWN #ifdef MY_CPU_LE #define MY_CPU_NAME "LE" #elif defined(MY_CPU_BE) @@ -253,15 +340,121 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. +#ifdef __has_builtin + #define Z7_has_builtin(x) __has_builtin(x) +#else + #define Z7_has_builtin(x) 0 +#endif + + +#define Z7_BSWAP32_CONST(v) \ + ( (((UInt32)(v) << 24) ) \ + | (((UInt32)(v) << 8) & (UInt32)0xff0000) \ + | (((UInt32)(v) >> 8) & (UInt32)0xff00 ) \ + | (((UInt32)(v) >> 24) )) + + +#if defined(_MSC_VER) && (_MSC_VER >= 1300) + +#include + +/* Note: these macros will use bswap instruction (486), that is unsupported in 386 cpu */ + +#pragma intrinsic(_byteswap_ushort) +#pragma intrinsic(_byteswap_ulong) +#pragma intrinsic(_byteswap_uint64) + +#define Z7_BSWAP16(v) _byteswap_ushort(v) +#define Z7_BSWAP32(v) _byteswap_ulong (v) +#define Z7_BSWAP64(v) _byteswap_uint64(v) +#define Z7_CPU_FAST_BSWAP_SUPPORTED + +/* GCC can generate slow code that calls function for __builtin_bswap32() for: + - GCC for RISCV, if Zbb/XTHeadBb extension is not used. + - GCC for SPARC. + The code from CLANG for SPARC also is not fastest. + So we don't define Z7_CPU_FAST_BSWAP_SUPPORTED in some cases. +*/ +#elif (!defined(MY_CPU_RISCV) || defined (__riscv_zbb) || defined(__riscv_xtheadbb)) \ + && !defined(MY_CPU_SPARC) \ + && ( \ + (defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3))) \ + || (defined(__clang__) && Z7_has_builtin(__builtin_bswap16)) \ + ) + +#define Z7_BSWAP16(v) __builtin_bswap16(v) +#define Z7_BSWAP32(v) __builtin_bswap32(v) +#define Z7_BSWAP64(v) __builtin_bswap64(v) +#define Z7_CPU_FAST_BSWAP_SUPPORTED + +#else + +#define Z7_BSWAP16(v) ((UInt16) \ + ( ((UInt32)(v) << 8) \ + | ((UInt32)(v) >> 8) \ + )) + +#define Z7_BSWAP32(v) Z7_BSWAP32_CONST(v) + +#define Z7_BSWAP64(v) \ + ( ( ( (UInt64)(v) ) << 8 * 7 ) \ + | ( ( (UInt64)(v) & ((UInt32)0xff << 8 * 1) ) << 8 * 5 ) \ + | ( ( (UInt64)(v) & ((UInt32)0xff << 8 * 2) ) << 8 * 3 ) \ + | ( ( (UInt64)(v) & ((UInt32)0xff << 8 * 3) ) << 8 * 1 ) \ + | ( ( (UInt64)(v) >> 8 * 1 ) & ((UInt32)0xff << 8 * 3) ) \ + | ( ( (UInt64)(v) >> 8 * 3 ) & ((UInt32)0xff << 8 * 2) ) \ + | ( ( (UInt64)(v) >> 8 * 5 ) & ((UInt32)0xff << 8 * 1) ) \ + | ( ( (UInt64)(v) >> 8 * 7 ) ) \ + ) + +#endif + + + #ifdef MY_CPU_LE #if defined(MY_CPU_X86_OR_AMD64) \ - || defined(MY_CPU_ARM64) + || defined(MY_CPU_ARM64) \ + || defined(MY_CPU_RISCV) && defined(__riscv_misaligned_fast) \ + || defined(MY_CPU_E2K) && defined(__iset__) && (__iset__ >= 6) #define MY_CPU_LE_UNALIGN #define MY_CPU_LE_UNALIGN_64 #elif defined(__ARM_FEATURE_UNALIGNED) - /* gcc9 for 32-bit arm can use LDRD instruction that requires 32-bit alignment. - So we can't use unaligned 64-bit operations. */ - #define MY_CPU_LE_UNALIGN +/* === ALIGNMENT on 32-bit arm and LDRD/STRD/LDM/STM instructions. + Description of problems: +problem-1 : 32-bit ARM architecture: + multi-access (pair of 32-bit accesses) instructions (LDRD/STRD/LDM/STM) + require 32-bit (WORD) alignment (by 32-bit ARM architecture). + So there is "Alignment fault exception", if data is not aligned for 32-bit. + +problem-2 : 32-bit kernels and arm64 kernels: + 32-bit linux kernels provide fixup for these "paired" instruction "Alignment fault exception". + So unaligned paired-access instructions work via exception handler in kernel in 32-bit linux. + + But some arm64 kernels do not handle these faults in 32-bit programs. + So we have unhandled exception for such instructions. + Probably some new arm64 kernels have fixed it, and unaligned + paired-access instructions work in new kernels? + +problem-3 : compiler for 32-bit arm: + Compilers use LDRD/STRD/LDM/STM for UInt64 accesses + and for another cases where two 32-bit accesses are fused + to one multi-access instruction. + So UInt64 variables must be aligned for 32-bit, and each + 32-bit access must be aligned for 32-bit, if we want to + avoid "Alignment fault" exception (handled or unhandled). + +problem-4 : performace: + Even if unaligned access is handled by kernel, it will be slow. + So if we allow unaligned access, we can get fast unaligned + single-access, and slow unaligned paired-access. + + We don't allow unaligned access on 32-bit arm, because compiler + genarates paired-access instructions that require 32-bit alignment, + and some arm64 kernels have no handler for these instructions. + Also unaligned paired-access instructions will be slow, if kernel handles them. +*/ + // it must be disabled: + // #define MY_CPU_LE_UNALIGN #endif #endif @@ -272,13 +465,11 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. #define GetUi32(p) (*(const UInt32 *)(const void *)(p)) #ifdef MY_CPU_LE_UNALIGN_64 #define GetUi64(p) (*(const UInt64 *)(const void *)(p)) +#define SetUi64(p, v) { *(UInt64 *)(void *)(p) = (v); } #endif #define SetUi16(p, v) { *(UInt16 *)(void *)(p) = (v); } #define SetUi32(p, v) { *(UInt32 *)(void *)(p) = (v); } -#ifdef MY_CPU_LE_UNALIGN_64 -#define SetUi64(p, v) { *(UInt64 *)(void *)(p) = (v); } -#endif #else @@ -305,50 +496,33 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. #endif -#ifndef MY_CPU_LE_UNALIGN_64 - +#ifndef GetUi64 #define GetUi64(p) (GetUi32(p) | ((UInt64)GetUi32(((const Byte *)(p)) + 4) << 32)) +#endif +#ifndef SetUi64 #define SetUi64(p, v) { Byte *_ppp2_ = (Byte *)(p); UInt64 _vvv2_ = (v); \ - SetUi32(_ppp2_ , (UInt32)_vvv2_); \ - SetUi32(_ppp2_ + 4, (UInt32)(_vvv2_ >> 32)); } - + SetUi32(_ppp2_ , (UInt32)_vvv2_) \ + SetUi32(_ppp2_ + 4, (UInt32)(_vvv2_ >> 32)) } #endif +#if defined(MY_CPU_LE_UNALIGN) && defined(Z7_CPU_FAST_BSWAP_SUPPORTED) - -#ifdef __has_builtin - #define MY__has_builtin(x) __has_builtin(x) +#if 0 +// Z7_BSWAP16 can be slow for x86-msvc +#define GetBe16_to32(p) (Z7_BSWAP16 (*(const UInt16 *)(const void *)(p))) #else - #define MY__has_builtin(x) 0 +#define GetBe16_to32(p) (Z7_BSWAP32 (*(const UInt16 *)(const void *)(p)) >> 16) #endif -#if defined(MY_CPU_LE_UNALIGN) && /* defined(_WIN64) && */ defined(_MSC_VER) && (_MSC_VER >= 1300) +#define GetBe32(p) Z7_BSWAP32 (*(const UInt32 *)(const void *)(p)) +#define SetBe32(p, v) { (*(UInt32 *)(void *)(p)) = Z7_BSWAP32(v); } -/* Note: we use bswap instruction, that is unsupported in 386 cpu */ - -#include - -#pragma intrinsic(_byteswap_ushort) -#pragma intrinsic(_byteswap_ulong) -#pragma intrinsic(_byteswap_uint64) - -/* #define GetBe16(p) _byteswap_ushort(*(const UInt16 *)(const Byte *)(p)) */ -#define GetBe32(p) _byteswap_ulong (*(const UInt32 *)(const void *)(p)) -#define GetBe64(p) _byteswap_uint64(*(const UInt64 *)(const void *)(p)) - -#define SetBe32(p, v) (*(UInt32 *)(void *)(p)) = _byteswap_ulong(v) - -#elif defined(MY_CPU_LE_UNALIGN) && ( \ - (defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3))) \ - || (defined(__clang__) && MY__has_builtin(__builtin_bswap16)) ) - -/* #define GetBe16(p) __builtin_bswap16(*(const UInt16 *)(const void *)(p)) */ -#define GetBe32(p) __builtin_bswap32(*(const UInt32 *)(const void *)(p)) -#define GetBe64(p) __builtin_bswap64(*(const UInt64 *)(const void *)(p)) - -#define SetBe32(p, v) (*(UInt32 *)(void *)(p)) = __builtin_bswap32(v) +#if defined(MY_CPU_LE_UNALIGN_64) +#define GetBe64(p) Z7_BSWAP64 (*(const UInt64 *)(const void *)(p)) +#define SetBe64(p, v) { (*(UInt64 *)(void *)(p)) = Z7_BSWAP64(v); } +#endif #else @@ -358,8 +532,6 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. ((UInt32)((const Byte *)(p))[2] << 8) | \ ((const Byte *)(p))[3] ) -#define GetBe64(p) (((UInt64)GetBe32(p) << 32) | GetBe32(((const Byte *)(p)) + 4)) - #define SetBe32(p, v) { Byte *_ppp_ = (Byte *)(p); UInt32 _vvv_ = (v); \ _ppp_[0] = (Byte)(_vvv_ >> 24); \ _ppp_[1] = (Byte)(_vvv_ >> 16); \ @@ -368,53 +540,113 @@ MY_CPU_64BIT means that processor can work with 64-bit registers. #endif +#ifndef GetBe64 +#define GetBe64(p) (((UInt64)GetBe32(p) << 32) | GetBe32(((const Byte *)(p)) + 4)) +#endif + +#ifndef SetBe64 +#define SetBe64(p, v) { Byte *_ppp_ = (Byte *)(p); UInt64 _vvv_ = (v); \ + _ppp_[0] = (Byte)(_vvv_ >> 56); \ + _ppp_[1] = (Byte)(_vvv_ >> 48); \ + _ppp_[2] = (Byte)(_vvv_ >> 40); \ + _ppp_[3] = (Byte)(_vvv_ >> 32); \ + _ppp_[4] = (Byte)(_vvv_ >> 24); \ + _ppp_[5] = (Byte)(_vvv_ >> 16); \ + _ppp_[6] = (Byte)(_vvv_ >> 8); \ + _ppp_[7] = (Byte)_vvv_; } +#endif #ifndef GetBe16 - +#ifdef GetBe16_to32 +#define GetBe16(p) ( (UInt16) GetBe16_to32(p)) +#else #define GetBe16(p) ( (UInt16) ( \ ((UInt16)((const Byte *)(p))[0] << 8) | \ ((const Byte *)(p))[1] )) - +#endif #endif +#if defined(MY_CPU_BE) +#define Z7_CONV_BE_TO_NATIVE_CONST32(v) (v) +#define Z7_CONV_LE_TO_NATIVE_CONST32(v) Z7_BSWAP32_CONST(v) +#define Z7_CONV_NATIVE_TO_BE_32(v) (v) +#elif defined(MY_CPU_LE) +#define Z7_CONV_BE_TO_NATIVE_CONST32(v) Z7_BSWAP32_CONST(v) +#define Z7_CONV_LE_TO_NATIVE_CONST32(v) (v) +#define Z7_CONV_NATIVE_TO_BE_32(v) Z7_BSWAP32(v) +#else +#error Stop_Compiling_Unknown_Endian_CONV +#endif + + +#if defined(MY_CPU_BE) + +#define GetBe64a(p) (*(const UInt64 *)(const void *)(p)) +#define GetBe32a(p) (*(const UInt32 *)(const void *)(p)) +#define GetBe16a(p) (*(const UInt16 *)(const void *)(p)) +#define SetBe32a(p, v) { *(UInt32 *)(void *)(p) = (v); } +#define SetBe16a(p, v) { *(UInt16 *)(void *)(p) = (v); } + +#define GetUi64a(p) GetUi64(p) +#define GetUi32a(p) GetUi32(p) +#define GetUi16a(p) GetUi16(p) +#define SetUi32a(p, v) SetUi32(p, v) +#define SetUi16a(p, v) SetUi16(p, v) + +#elif defined(MY_CPU_LE) + +#define GetUi64a(p) (*(const UInt64 *)(const void *)(p)) +#define GetUi32a(p) (*(const UInt32 *)(const void *)(p)) +#define GetUi16a(p) (*(const UInt16 *)(const void *)(p)) +#define SetUi32a(p, v) { *(UInt32 *)(void *)(p) = (v); } +#define SetUi16a(p, v) { *(UInt16 *)(void *)(p) = (v); } + +#define GetBe64a(p) GetBe64(p) +#define GetBe32a(p) GetBe32(p) +#define GetBe16a(p) GetBe16(p) +#define SetBe32a(p, v) SetBe32(p, v) +#define SetBe16a(p, v) SetBe16(p, v) + +#else +#error Stop_Compiling_Unknown_Endian_CPU_a +#endif + + +#ifndef GetBe16_to32 +#define GetBe16_to32(p) GetBe16(p) +#endif + + +#if defined(MY_CPU_X86_OR_AMD64) \ + || defined(MY_CPU_ARM_OR_ARM64) \ + || defined(MY_CPU_PPC_OR_PPC64) + #define Z7_CPU_FAST_ROTATE_SUPPORTED +#endif + #ifdef MY_CPU_X86_OR_AMD64 -typedef struct -{ - UInt32 maxFunc; - UInt32 vendor[3]; - UInt32 ver; - UInt32 b; - UInt32 c; - UInt32 d; -} Cx86cpuid; - -enum -{ - CPU_FIRM_INTEL, - CPU_FIRM_AMD, - CPU_FIRM_VIA -}; - -void MyCPUID(UInt32 function, UInt32 *a, UInt32 *b, UInt32 *c, UInt32 *d); - -BoolInt x86cpuid_CheckAndRead(Cx86cpuid *p); -int x86cpuid_GetFirm(const Cx86cpuid *p); - -#define x86cpuid_GetFamily(ver) (((ver >> 16) & 0xFF0) | ((ver >> 8) & 0xF)) -#define x86cpuid_GetModel(ver) (((ver >> 12) & 0xF0) | ((ver >> 4) & 0xF)) -#define x86cpuid_GetStepping(ver) (ver & 0xF) - -BoolInt CPU_Is_InOrder(void); +void Z7_FASTCALL z7_x86_cpuid(UInt32 a[4], UInt32 function); +UInt32 Z7_FASTCALL z7_x86_cpuid_GetMaxFunc(void); +#if defined(MY_CPU_AMD64) +#define Z7_IF_X86_CPUID_SUPPORTED +#else +#define Z7_IF_X86_CPUID_SUPPORTED if (z7_x86_cpuid_GetMaxFunc()) +#endif BoolInt CPU_IsSupported_AES(void); +BoolInt CPU_IsSupported_AVX(void); BoolInt CPU_IsSupported_AVX2(void); +BoolInt CPU_IsSupported_AVX512F_AVX512VL(void); BoolInt CPU_IsSupported_VAES_AVX2(void); +BoolInt CPU_IsSupported_CMOV(void); +BoolInt CPU_IsSupported_SSE(void); +BoolInt CPU_IsSupported_SSE2(void); BoolInt CPU_IsSupported_SSSE3(void); BoolInt CPU_IsSupported_SSE41(void); BoolInt CPU_IsSupported_SHA(void); +BoolInt CPU_IsSupported_SHA512(void); BoolInt CPU_IsSupported_PageGB(void); #elif defined(MY_CPU_ARM_OR_ARM64) @@ -432,12 +664,13 @@ BoolInt CPU_IsSupported_SHA1(void); BoolInt CPU_IsSupported_SHA2(void); BoolInt CPU_IsSupported_AES(void); #endif +BoolInt CPU_IsSupported_SHA512(void); #endif #if defined(__APPLE__) -int My_sysctlbyname_Get(const char *name, void *buf, size_t *bufSize); -int My_sysctlbyname_Get_UInt32(const char *name, UInt32 *val); +int z7_sysctlbyname_Get(const char *name, void *buf, size_t *bufSize); +int z7_sysctlbyname_Get_UInt32(const char *name, UInt32 *val); #endif EXTERN_C_END diff --git a/common/LZMA/SDK/C/LzFind.c b/common/LZMA/SDK/C/LzFind.c index 1b73c28..1ce4046 100644 --- a/common/LZMA/SDK/C/LzFind.c +++ b/common/LZMA/SDK/C/LzFind.c @@ -1,5 +1,5 @@ /* LzFind.c -- Match finder for LZ algorithms -2021-11-29 : Igor Pavlov : Public domain */ +2024-03-01 : Igor Pavlov : Public domain */ #include "Precomp.h" @@ -17,7 +17,7 @@ #define kEmptyHashValue 0 #define kMaxValForNormalize ((UInt32)0) -// #define kMaxValForNormalize ((UInt32)(1 << 20) + 0xFFF) // for debug +// #define kMaxValForNormalize ((UInt32)(1 << 20) + 0xfff) // for debug // #define kNormalizeAlign (1 << 7) // alignment for speculated accesses @@ -67,10 +67,10 @@ static void LzInWindow_Free(CMatchFinder *p, ISzAllocPtr alloc) { - if (!p->directInput) + // if (!p->directInput) { - ISzAlloc_Free(alloc, p->bufferBase); - p->bufferBase = NULL; + ISzAlloc_Free(alloc, p->bufBase); + p->bufBase = NULL; } } @@ -79,7 +79,7 @@ static int LzInWindow_Create2(CMatchFinder *p, UInt32 blockSize, ISzAllocPtr all { if (blockSize == 0) return 0; - if (!p->bufferBase || p->blockSize != blockSize) + if (!p->bufBase || p->blockSize != blockSize) { // size_t blockSizeT; LzInWindow_Free(p, alloc); @@ -101,19 +101,25 @@ static int LzInWindow_Create2(CMatchFinder *p, UInt32 blockSize, ISzAllocPtr all #endif */ - p->bufferBase = (Byte *)ISzAlloc_Alloc(alloc, blockSize); - // printf("\nbufferBase = %p\n", p->bufferBase); + p->bufBase = (Byte *)ISzAlloc_Alloc(alloc, blockSize); + // printf("\nbufferBase = %p\n", p->bufBase); // return 0; // for debug } - return (p->bufferBase != NULL); + return (p->bufBase != NULL); } -static const Byte *MatchFinder_GetPointerToCurrentPos(CMatchFinder *p) { return p->buffer; } +static const Byte *MatchFinder_GetPointerToCurrentPos(void *p) +{ + return ((CMatchFinder *)p)->buffer; +} -static UInt32 MatchFinder_GetNumAvailableBytes(CMatchFinder *p) { return GET_AVAIL_BYTES(p); } +static UInt32 MatchFinder_GetNumAvailableBytes(void *p) +{ + return GET_AVAIL_BYTES((CMatchFinder *)p); +} -MY_NO_INLINE +Z7_NO_INLINE static void MatchFinder_ReadBlock(CMatchFinder *p) { if (p->streamEndWasReached || p->result != SZ_OK) @@ -127,8 +133,8 @@ static void MatchFinder_ReadBlock(CMatchFinder *p) UInt32 curSize = 0xFFFFFFFF - GET_AVAIL_BYTES(p); if (curSize > p->directInputRem) curSize = (UInt32)p->directInputRem; - p->directInputRem -= curSize; p->streamPos += curSize; + p->directInputRem -= curSize; if (p->directInputRem == 0) p->streamEndWasReached = 1; return; @@ -136,8 +142,8 @@ static void MatchFinder_ReadBlock(CMatchFinder *p) for (;;) { - Byte *dest = p->buffer + GET_AVAIL_BYTES(p); - size_t size = (size_t)(p->bufferBase + p->blockSize - dest); + const Byte *dest = p->buffer + GET_AVAIL_BYTES(p); + size_t size = (size_t)(p->bufBase + p->blockSize - dest); if (size == 0) { /* we call ReadBlock() after NeedMove() and MoveBlock(). @@ -153,7 +159,14 @@ static void MatchFinder_ReadBlock(CMatchFinder *p) // #define kRead 3 // if (size > kRead) size = kRead; // for debug - p->result = ISeqInStream_Read(p->stream, dest, &size); + /* + // we need cast (Byte *)dest. + #ifdef __clang__ + #pragma GCC diagnostic ignored "-Wcast-qual" + #endif + */ + p->result = ISeqInStream_Read(p->stream, + p->bufBase + (dest - p->bufBase), &size); if (p->result != SZ_OK) return; if (size == 0) @@ -173,14 +186,14 @@ static void MatchFinder_ReadBlock(CMatchFinder *p) -MY_NO_INLINE +Z7_NO_INLINE void MatchFinder_MoveBlock(CMatchFinder *p) { - const size_t offset = (size_t)(p->buffer - p->bufferBase) - p->keepSizeBefore; + const size_t offset = (size_t)(p->buffer - p->bufBase) - p->keepSizeBefore; const size_t keepBefore = (offset & (kBlockMoveAlign - 1)) + p->keepSizeBefore; - p->buffer = p->bufferBase + keepBefore; - memmove(p->bufferBase, - p->bufferBase + (offset & ~((size_t)kBlockMoveAlign - 1)), + p->buffer = p->bufBase + keepBefore; + memmove(p->bufBase, + p->bufBase + (offset & ~((size_t)kBlockMoveAlign - 1)), keepBefore + (size_t)GET_AVAIL_BYTES(p)); } @@ -198,7 +211,7 @@ int MatchFinder_NeedMove(CMatchFinder *p) return 0; if (p->streamEndWasReached || p->result != SZ_OK) return 0; - return ((size_t)(p->bufferBase + p->blockSize - p->buffer) <= p->keepSizeAfter); + return ((size_t)(p->bufBase + p->blockSize - p->buffer) <= p->keepSizeAfter); } void MatchFinder_ReadIfRequired(CMatchFinder *p) @@ -214,6 +227,8 @@ static void MatchFinder_SetDefaultSettings(CMatchFinder *p) p->cutValue = 32; p->btMode = 1; p->numHashBytes = 4; + p->numHashBytes_Min = 2; + p->numHashOutBits = 0; p->bigHash = 0; } @@ -222,8 +237,10 @@ static void MatchFinder_SetDefaultSettings(CMatchFinder *p) void MatchFinder_Construct(CMatchFinder *p) { unsigned i; - p->bufferBase = NULL; + p->buffer = NULL; + p->bufBase = NULL; p->directInput = 0; + p->stream = NULL; p->hash = NULL; p->expectedDataSize = (UInt64)(Int64)-1; MatchFinder_SetDefaultSettings(p); @@ -238,6 +255,8 @@ void MatchFinder_Construct(CMatchFinder *p) } } +#undef kCrcPoly + static void MatchFinder_FreeThisClassMemory(CMatchFinder *p, ISzAllocPtr alloc) { ISzAlloc_Free(alloc, p->hash); @@ -252,7 +271,7 @@ void MatchFinder_Free(CMatchFinder *p, ISzAllocPtr alloc) static CLzRef* AllocRefs(size_t num, ISzAllocPtr alloc) { - size_t sizeInBytes = (size_t)num * sizeof(CLzRef); + const size_t sizeInBytes = (size_t)num * sizeof(CLzRef); if (sizeInBytes / sizeof(CLzRef) != num) return NULL; return (CLzRef *)ISzAlloc_Alloc(alloc, sizeInBytes); @@ -298,6 +317,62 @@ static UInt32 GetBlockSize(CMatchFinder *p, UInt32 historySize) } +// input is historySize +static UInt32 MatchFinder_GetHashMask2(CMatchFinder *p, UInt32 hs) +{ + if (p->numHashBytes == 2) + return (1 << 16) - 1; + if (hs != 0) + hs--; + hs |= (hs >> 1); + hs |= (hs >> 2); + hs |= (hs >> 4); + hs |= (hs >> 8); + // we propagated 16 bits in (hs). Low 16 bits must be set later + if (hs >= (1 << 24)) + { + if (p->numHashBytes == 3) + hs = (1 << 24) - 1; + /* if (bigHash) mode, GetHeads4b() in LzFindMt.c needs (hs >= ((1 << 24) - 1))) */ + } + // (hash_size >= (1 << 16)) : Required for (numHashBytes > 2) + hs |= (1 << 16) - 1; /* don't change it! */ + // bt5: we adjust the size with recommended minimum size + if (p->numHashBytes >= 5) + hs |= (256 << kLzHash_CrcShift_2) - 1; + return hs; +} + +// input is historySize +static UInt32 MatchFinder_GetHashMask(CMatchFinder *p, UInt32 hs) +{ + if (p->numHashBytes == 2) + return (1 << 16) - 1; + if (hs != 0) + hs--; + hs |= (hs >> 1); + hs |= (hs >> 2); + hs |= (hs >> 4); + hs |= (hs >> 8); + // we propagated 16 bits in (hs). Low 16 bits must be set later + hs >>= 1; + if (hs >= (1 << 24)) + { + if (p->numHashBytes == 3) + hs = (1 << 24) - 1; + else + hs >>= 1; + /* if (bigHash) mode, GetHeads4b() in LzFindMt.c needs (hs >= ((1 << 24) - 1))) */ + } + // (hash_size >= (1 << 16)) : Required for (numHashBytes > 2) + hs |= (1 << 16) - 1; /* don't change it! */ + // bt5: we adjust the size with recommended minimum size + if (p->numHashBytes >= 5) + hs |= (256 << kLzHash_CrcShift_2) - 1; + return hs; +} + + int MatchFinder_Create(CMatchFinder *p, UInt32 historySize, UInt32 keepAddBufferBefore, UInt32 matchMaxLen, UInt32 keepAddBufferAfter, ISzAllocPtr alloc) @@ -318,78 +393,91 @@ int MatchFinder_Create(CMatchFinder *p, UInt32 historySize, p->blockSize = 0; if (p->directInput || LzInWindow_Create2(p, GetBlockSize(p, historySize), alloc)) { - const UInt32 newCyclicBufferSize = historySize + 1; // do not change it - UInt32 hs; - p->matchMaxLen = matchMaxLen; + size_t hashSizeSum; { - // UInt32 hs4; - p->fixedHashSize = 0; - hs = (1 << 16) - 1; - if (p->numHashBytes != 2) + UInt32 hs; + UInt32 hsCur; + + if (p->numHashOutBits != 0) { - hs = historySize; - if (hs > p->expectedDataSize) - hs = (UInt32)p->expectedDataSize; - if (hs != 0) - hs--; - hs |= (hs >> 1); - hs |= (hs >> 2); - hs |= (hs >> 4); - hs |= (hs >> 8); - // we propagated 16 bits in (hs). Low 16 bits must be set later - hs >>= 1; - if (hs >= (1 << 24)) - { - if (p->numHashBytes == 3) - hs = (1 << 24) - 1; - else - hs >>= 1; - /* if (bigHash) mode, GetHeads4b() in LzFindMt.c needs (hs >= ((1 << 24) - 1))) */ - } - - // hs = ((UInt32)1 << 25) - 1; // for test - + unsigned numBits = p->numHashOutBits; + const unsigned nbMax = + (p->numHashBytes == 2 ? 16 : + (p->numHashBytes == 3 ? 24 : 32)); + if (numBits > nbMax) + numBits = nbMax; + if (numBits >= 32) + hs = (UInt32)0 - 1; + else + hs = ((UInt32)1 << numBits) - 1; // (hash_size >= (1 << 16)) : Required for (numHashBytes > 2) hs |= (1 << 16) - 1; /* don't change it! */ - - // bt5: we adjust the size with recommended minimum size if (p->numHashBytes >= 5) hs |= (256 << kLzHash_CrcShift_2) - 1; + { + const UInt32 hs2 = MatchFinder_GetHashMask2(p, historySize); + if (hs > hs2) + hs = hs2; + } + hsCur = hs; + if (p->expectedDataSize < historySize) + { + const UInt32 hs2 = MatchFinder_GetHashMask2(p, (UInt32)p->expectedDataSize); + if (hsCur > hs2) + hsCur = hs2; + } + } + else + { + hs = MatchFinder_GetHashMask(p, historySize); + hsCur = hs; + if (p->expectedDataSize < historySize) + { + hsCur = MatchFinder_GetHashMask(p, (UInt32)p->expectedDataSize); + if (hsCur > hs) // is it possible? + hsCur = hs; + } } - p->hashMask = hs; - hs++; - /* - hs4 = (1 << 20); - if (hs4 > hs) - hs4 = hs; - // hs4 = (1 << 16); // for test - p->hash4Mask = hs4 - 1; - */ + p->hashMask = hsCur; - if (p->numHashBytes > 2) p->fixedHashSize += kHash2Size; - if (p->numHashBytes > 3) p->fixedHashSize += kHash3Size; - // if (p->numHashBytes > 4) p->fixedHashSize += hs4; // kHash4Size; - hs += p->fixedHashSize; + hashSizeSum = hs; + hashSizeSum++; + if (hashSizeSum < hs) + return 0; + { + UInt32 fixedHashSize = 0; + if (p->numHashBytes > 2 && p->numHashBytes_Min <= 2) fixedHashSize += kHash2Size; + if (p->numHashBytes > 3 && p->numHashBytes_Min <= 3) fixedHashSize += kHash3Size; + // if (p->numHashBytes > 4) p->fixedHashSize += hs4; // kHash4Size; + hashSizeSum += fixedHashSize; + p->fixedHashSize = fixedHashSize; + } } + p->matchMaxLen = matchMaxLen; + { size_t newSize; size_t numSons; + const UInt32 newCyclicBufferSize = historySize + 1; // do not change it p->historySize = historySize; - p->hashSizeSum = hs; p->cyclicBufferSize = newCyclicBufferSize; // it must be = (historySize + 1) numSons = newCyclicBufferSize; if (p->btMode) numSons <<= 1; - newSize = hs + numSons; + newSize = hashSizeSum + numSons; + + if (numSons < newCyclicBufferSize || newSize < numSons) + return 0; // aligned size is not required here, but it can be better for some loops #define NUM_REFS_ALIGN_MASK 0xF newSize = (newSize + NUM_REFS_ALIGN_MASK) & ~(size_t)NUM_REFS_ALIGN_MASK; - if (p->hash && p->numRefs == newSize) + // 22.02: we don't reallocate buffer, if old size is enough + if (p->hash && p->numRefs >= newSize) return 1; MatchFinder_FreeThisClassMemory(p, alloc); @@ -398,7 +486,7 @@ int MatchFinder_Create(CMatchFinder *p, UInt32 historySize, if (p->hash) { - p->son = p->hash + p->hashSizeSum; + p->son = p->hash + hashSizeSum; return 1; } } @@ -470,7 +558,8 @@ void MatchFinder_Init_HighHash(CMatchFinder *p) void MatchFinder_Init_4(CMatchFinder *p) { - p->buffer = p->bufferBase; + if (!p->directInput) + p->buffer = p->bufBase; { /* kEmptyHashValue = 0 (Zero) is used in hash tables as NO-VALUE marker. the code in CMatchFinderMt expects (pos = 1) */ @@ -488,8 +577,9 @@ void MatchFinder_Init_4(CMatchFinder *p) #define CYC_TO_POS_OFFSET 0 // #define CYC_TO_POS_OFFSET 1 // for debug -void MatchFinder_Init(CMatchFinder *p) +void MatchFinder_Init(void *_p) { + CMatchFinder *p = (CMatchFinder *)_p; MatchFinder_Init_HighHash(p); MatchFinder_Init_LowHash(p); MatchFinder_Init_4(p); @@ -507,42 +597,42 @@ void MatchFinder_Init(CMatchFinder *p) #ifdef MY_CPU_X86_OR_AMD64 - #if defined(__clang__) && (__clang_major__ >= 8) \ - || defined(__GNUC__) && (__GNUC__ >= 8) \ - || defined(__INTEL_COMPILER) && (__INTEL_COMPILER >= 1900) - #define USE_SATUR_SUB_128 - #define USE_AVX2 - #define ATTRIB_SSE41 __attribute__((__target__("sse4.1"))) - #define ATTRIB_AVX2 __attribute__((__target__("avx2"))) + #if defined(__clang__) && (__clang_major__ >= 4) \ + || defined(Z7_GCC_VERSION) && (Z7_GCC_VERSION >= 40701) + // || defined(__INTEL_COMPILER) && (__INTEL_COMPILER >= 1900) + + #define USE_LZFIND_SATUR_SUB_128 + #define USE_LZFIND_SATUR_SUB_256 + #define LZFIND_ATTRIB_SSE41 __attribute__((__target__("sse4.1"))) + #define LZFIND_ATTRIB_AVX2 __attribute__((__target__("avx2"))) #elif defined(_MSC_VER) #if (_MSC_VER >= 1600) - #define USE_SATUR_SUB_128 - #if (_MSC_VER >= 1900) - #define USE_AVX2 - #include // avx - #endif + #define USE_LZFIND_SATUR_SUB_128 + #endif + #if (_MSC_VER >= 1900) + #define USE_LZFIND_SATUR_SUB_256 #endif #endif -// #elif defined(MY_CPU_ARM_OR_ARM64) -#elif defined(MY_CPU_ARM64) +#elif defined(MY_CPU_ARM64) \ + /* || (defined(__ARM_ARCH) && (__ARM_ARCH >= 7)) */ - #if defined(__clang__) && (__clang_major__ >= 8) \ - || defined(__GNUC__) && (__GNUC__ >= 8) - #define USE_SATUR_SUB_128 + #if defined(Z7_CLANG_VERSION) && (Z7_CLANG_VERSION >= 30800) \ + || defined(__GNUC__) && (__GNUC__ >= 6) + #define USE_LZFIND_SATUR_SUB_128 #ifdef MY_CPU_ARM64 - // #define ATTRIB_SSE41 __attribute__((__target__(""))) + // #define LZFIND_ATTRIB_SSE41 __attribute__((__target__(""))) #else - // #define ATTRIB_SSE41 __attribute__((__target__("fpu=crypto-neon-fp-armv8"))) + #define LZFIND_ATTRIB_SSE41 __attribute__((__target__("fpu=neon"))) #endif #elif defined(_MSC_VER) #if (_MSC_VER >= 1910) - #define USE_SATUR_SUB_128 + #define USE_LZFIND_SATUR_SUB_128 #endif #endif - #if defined(_MSC_VER) && defined(MY_CPU_ARM64) + #if defined(Z7_MSC_VER_ORIGINAL) && defined(MY_CPU_ARM64) #include #else #include @@ -550,121 +640,130 @@ void MatchFinder_Init(CMatchFinder *p) #endif -/* -#ifndef ATTRIB_SSE41 - #define ATTRIB_SSE41 -#endif -#ifndef ATTRIB_AVX2 - #define ATTRIB_AVX2 -#endif -*/ -#ifdef USE_SATUR_SUB_128 +#ifdef USE_LZFIND_SATUR_SUB_128 -// #define _SHOW_HW_STATUS +// #define Z7_SHOW_HW_STATUS -#ifdef _SHOW_HW_STATUS +#ifdef Z7_SHOW_HW_STATUS #include -#define _PRF(x) x -_PRF(;) +#define PRF(x) x +PRF(;) #else -#define _PRF(x) +#define PRF(x) #endif + #ifdef MY_CPU_ARM_OR_ARM64 #ifdef MY_CPU_ARM64 -// #define FORCE_SATUR_SUB_128 +// #define FORCE_LZFIND_SATUR_SUB_128 #endif +typedef uint32x4_t LzFind_v128; +#define SASUB_128_V(v, s) \ + vsubq_u32(vmaxq_u32(v, s), s) -typedef uint32x4_t v128; -#define SASUB_128(i) \ - *(v128 *)(void *)(items + (i) * 4) = \ - vsubq_u32(vmaxq_u32(*(const v128 *)(const void *)(items + (i) * 4), sub2), sub2); - -#else +#else // MY_CPU_ARM_OR_ARM64 #include // sse4.1 -typedef __m128i v128; +typedef __m128i LzFind_v128; +// SSE 4.1 +#define SASUB_128_V(v, s) \ + _mm_sub_epi32(_mm_max_epu32(v, s), s) + +#endif // MY_CPU_ARM_OR_ARM64 + + #define SASUB_128(i) \ - *(v128 *)(void *)(items + (i) * 4) = \ - _mm_sub_epi32(_mm_max_epu32(*(const v128 *)(const void *)(items + (i) * 4), sub2), sub2); // SSE 4.1 - -#endif + *( LzFind_v128 *)( void *)(items + (i) * 4) = SASUB_128_V( \ + *(const LzFind_v128 *)(const void *)(items + (i) * 4), sub2); - -MY_NO_INLINE +Z7_NO_INLINE static -#ifdef ATTRIB_SSE41 -ATTRIB_SSE41 +#ifdef LZFIND_ATTRIB_SSE41 +LZFIND_ATTRIB_SSE41 #endif void -MY_FAST_CALL +Z7_FASTCALL LzFind_SaturSub_128(UInt32 subValue, CLzRef *items, const CLzRef *lim) { - v128 sub2 = + const LzFind_v128 sub2 = #ifdef MY_CPU_ARM_OR_ARM64 vdupq_n_u32(subValue); #else _mm_set_epi32((Int32)subValue, (Int32)subValue, (Int32)subValue, (Int32)subValue); #endif + Z7_PRAGMA_OPT_DISABLE_LOOP_UNROLL_VECTORIZE do { - SASUB_128(0) - SASUB_128(1) - SASUB_128(2) - SASUB_128(3) - items += 4 * 4; + SASUB_128(0) SASUB_128(1) items += 2 * 4; + SASUB_128(0) SASUB_128(1) items += 2 * 4; } while (items != lim); } -#ifdef USE_AVX2 +#ifdef USE_LZFIND_SATUR_SUB_256 #include // avx +/* +clang :immintrin.h uses +#if !(defined(_MSC_VER) || defined(__SCE__)) || __has_feature(modules) || \ + defined(__AVX2__) +#include +#endif +so we need for clang-cl */ -#define SASUB_256(i) *(__m256i *)(void *)(items + (i) * 8) = _mm256_sub_epi32(_mm256_max_epu32(*(const __m256i *)(const void *)(items + (i) * 8), sub2), sub2); // AVX2 +#if defined(__clang__) +#include +#include +#endif -MY_NO_INLINE +// AVX2: +#define SASUB_256(i) \ + *( __m256i *)( void *)(items + (i) * 8) = \ + _mm256_sub_epi32(_mm256_max_epu32( \ + *(const __m256i *)(const void *)(items + (i) * 8), sub2), sub2); + +Z7_NO_INLINE static -#ifdef ATTRIB_AVX2 -ATTRIB_AVX2 +#ifdef LZFIND_ATTRIB_AVX2 +LZFIND_ATTRIB_AVX2 #endif void -MY_FAST_CALL +Z7_FASTCALL LzFind_SaturSub_256(UInt32 subValue, CLzRef *items, const CLzRef *lim) { - __m256i sub2 = _mm256_set_epi32( + const __m256i sub2 = _mm256_set_epi32( (Int32)subValue, (Int32)subValue, (Int32)subValue, (Int32)subValue, (Int32)subValue, (Int32)subValue, (Int32)subValue, (Int32)subValue); + Z7_PRAGMA_OPT_DISABLE_LOOP_UNROLL_VECTORIZE do { - SASUB_256(0) - SASUB_256(1) - items += 2 * 8; + SASUB_256(0) SASUB_256(1) items += 2 * 8; + SASUB_256(0) SASUB_256(1) items += 2 * 8; } while (items != lim); } -#endif // USE_AVX2 +#endif // USE_LZFIND_SATUR_SUB_256 -#ifndef FORCE_SATUR_SUB_128 -typedef void (MY_FAST_CALL *LZFIND_SATUR_SUB_CODE_FUNC)( +#ifndef FORCE_LZFIND_SATUR_SUB_128 +typedef void (Z7_FASTCALL *LZFIND_SATUR_SUB_CODE_FUNC)( UInt32 subValue, CLzRef *items, const CLzRef *lim); static LZFIND_SATUR_SUB_CODE_FUNC g_LzFind_SaturSub; -#endif // FORCE_SATUR_SUB_128 +#endif // FORCE_LZFIND_SATUR_SUB_128 -#endif // USE_SATUR_SUB_128 +#endif // USE_LZFIND_SATUR_SUB_128 // kEmptyHashValue must be zero -// #define SASUB_32(i) v = items[i]; m = v - subValue; if (v < subValue) m = kEmptyHashValue; items[i] = m; -#define SASUB_32(i) v = items[i]; if (v < subValue) v = subValue; items[i] = v - subValue; +// #define SASUB_32(i) { UInt32 v = items[i]; UInt32 m = v - subValue; if (v < subValue) m = kEmptyHashValue; items[i] = m; } +#define SASUB_32(i) { UInt32 v = items[i]; if (v < subValue) v = subValue; items[i] = v - subValue; } -#ifdef FORCE_SATUR_SUB_128 +#ifdef FORCE_LZFIND_SATUR_SUB_128 #define DEFAULT_SaturSub LzFind_SaturSub_128 @@ -672,24 +771,19 @@ static LZFIND_SATUR_SUB_CODE_FUNC g_LzFind_SaturSub; #define DEFAULT_SaturSub LzFind_SaturSub_32 -MY_NO_INLINE +Z7_NO_INLINE static void -MY_FAST_CALL +Z7_FASTCALL LzFind_SaturSub_32(UInt32 subValue, CLzRef *items, const CLzRef *lim) { + Z7_PRAGMA_OPT_DISABLE_LOOP_UNROLL_VECTORIZE do { - UInt32 v; - SASUB_32(0) - SASUB_32(1) - SASUB_32(2) - SASUB_32(3) - SASUB_32(4) - SASUB_32(5) - SASUB_32(6) - SASUB_32(7) - items += 8; + SASUB_32(0) SASUB_32(1) items += 2; + SASUB_32(0) SASUB_32(1) items += 2; + SASUB_32(0) SASUB_32(1) items += 2; + SASUB_32(0) SASUB_32(1) items += 2; } while (items != lim); } @@ -697,27 +791,23 @@ LzFind_SaturSub_32(UInt32 subValue, CLzRef *items, const CLzRef *lim) #endif -MY_NO_INLINE +Z7_NO_INLINE void MatchFinder_Normalize3(UInt32 subValue, CLzRef *items, size_t numItems) { - #define K_NORM_ALIGN_BLOCK_SIZE (1 << 6) - - CLzRef *lim; - - for (; numItems != 0 && ((unsigned)(ptrdiff_t)items & (K_NORM_ALIGN_BLOCK_SIZE - 1)) != 0; numItems--) + #define LZFIND_NORM_ALIGN_BLOCK_SIZE (1 << 7) + Z7_PRAGMA_OPT_DISABLE_LOOP_UNROLL_VECTORIZE + for (; numItems != 0 && ((unsigned)(ptrdiff_t)items & (LZFIND_NORM_ALIGN_BLOCK_SIZE - 1)) != 0; numItems--) { - UInt32 v; - SASUB_32(0); + SASUB_32(0) items++; } - { - #define K_NORM_ALIGN_MASK (K_NORM_ALIGN_BLOCK_SIZE / 4 - 1) - lim = items + (numItems & ~(size_t)K_NORM_ALIGN_MASK); - numItems &= K_NORM_ALIGN_MASK; + const size_t k_Align_Mask = (LZFIND_NORM_ALIGN_BLOCK_SIZE / 4 - 1); + CLzRef *lim = items + (numItems & ~(size_t)k_Align_Mask); + numItems &= k_Align_Mask; if (items != lim) { - #if defined(USE_SATUR_SUB_128) && !defined(FORCE_SATUR_SUB_128) + #if defined(USE_LZFIND_SATUR_SUB_128) && !defined(FORCE_LZFIND_SATUR_SUB_128) if (g_LzFind_SaturSub) g_LzFind_SaturSub(subValue, items, lim); else @@ -726,12 +816,10 @@ void MatchFinder_Normalize3(UInt32 subValue, CLzRef *items, size_t numItems) } items = lim; } - - + Z7_PRAGMA_OPT_DISABLE_LOOP_UNROLL_VECTORIZE for (; numItems != 0; numItems--) { - UInt32 v; - SASUB_32(0); + SASUB_32(0) items++; } } @@ -740,7 +828,7 @@ void MatchFinder_Normalize3(UInt32 subValue, CLzRef *items, size_t numItems) // call MatchFinder_CheckLimits() only after (p->pos++) update -MY_NO_INLINE +Z7_NO_INLINE static void MatchFinder_CheckLimits(CMatchFinder *p) { if (// !p->streamEndWasReached && p->result == SZ_OK && @@ -768,11 +856,14 @@ static void MatchFinder_CheckLimits(CMatchFinder *p) const UInt32 subValue = (p->pos - p->historySize - 1) /* & ~(UInt32)(kNormalizeAlign - 1) */; // const UInt32 subValue = (1 << 15); // for debug // printf("\nMatchFinder_Normalize() subValue == 0x%x\n", subValue); - size_t numSonRefs = p->cyclicBufferSize; - if (p->btMode) - numSonRefs <<= 1; - Inline_MatchFinder_ReduceOffsets(p, subValue); - MatchFinder_Normalize3(subValue, p->hash, (size_t)p->hashSizeSum + numSonRefs); + MatchFinder_REDUCE_OFFSETS(p, subValue) + MatchFinder_Normalize3(subValue, p->hash, (size_t)p->hashMask + 1 + p->fixedHashSize); + { + size_t numSonRefs = p->cyclicBufferSize; + if (p->btMode) + numSonRefs <<= 1; + MatchFinder_Normalize3(subValue, p->son, numSonRefs); + } } if (p->cyclicBufferPos == p->cyclicBufferSize) @@ -785,7 +876,7 @@ static void MatchFinder_CheckLimits(CMatchFinder *p) /* (lenLimit > maxLen) */ -MY_FORCE_INLINE +Z7_FORCE_INLINE static UInt32 * Hc_GetMatchesSpec(size_t lenLimit, UInt32 curMatch, UInt32 pos, const Byte *cur, CLzRef *son, size_t _cyclicBufferPos, UInt32 _cyclicBufferSize, UInt32 cutValue, UInt32 *d, unsigned maxLen) @@ -867,7 +958,7 @@ static UInt32 * Hc_GetMatchesSpec(size_t lenLimit, UInt32 curMatch, UInt32 pos, } -MY_FORCE_INLINE +Z7_FORCE_INLINE UInt32 * GetMatchesSpec1(UInt32 lenLimit, UInt32 curMatch, UInt32 pos, const Byte *cur, CLzRef *son, size_t _cyclicBufferPos, UInt32 _cyclicBufferSize, UInt32 cutValue, UInt32 *d, UInt32 maxLen) @@ -998,13 +1089,15 @@ static void SkipMatchesSpec(UInt32 lenLimit, UInt32 curMatch, UInt32 pos, const #define MOVE_POS \ - ++p->cyclicBufferPos; \ + p->cyclicBufferPos++; \ p->buffer++; \ - { const UInt32 pos1 = p->pos + 1; p->pos = pos1; if (pos1 == p->posLimit) MatchFinder_CheckLimits(p); } + { const UInt32 pos1 = p->pos + 1; \ + p->pos = pos1; \ + if (pos1 == p->posLimit) MatchFinder_CheckLimits(p); } #define MOVE_POS_RET MOVE_POS return distances; -MY_NO_INLINE +Z7_NO_INLINE static void MatchFinder_MovePos(CMatchFinder *p) { /* we go here at the end of stream data, when (avail < num_hash_bytes) @@ -1015,24 +1108,30 @@ static void MatchFinder_MovePos(CMatchFinder *p) if (p->btMode) p->sons[(p->cyclicBufferPos << p->btMode) + 1] = 0; // kEmptyHashValue */ - MOVE_POS; + MOVE_POS } #define GET_MATCHES_HEADER2(minLen, ret_op) \ - unsigned lenLimit; UInt32 hv; Byte *cur; UInt32 curMatch; \ - lenLimit = (unsigned)p->lenLimit; { if (lenLimit < minLen) { MatchFinder_MovePos(p); ret_op; }} \ + UInt32 hv; const Byte *cur; UInt32 curMatch; \ + UInt32 lenLimit = p->lenLimit; \ + if (lenLimit < minLen) { MatchFinder_MovePos(p); ret_op; } \ cur = p->buffer; #define GET_MATCHES_HEADER(minLen) GET_MATCHES_HEADER2(minLen, return distances) -#define SKIP_HEADER(minLen) do { GET_MATCHES_HEADER2(minLen, continue) +#define SKIP_HEADER(minLen) \ + do { GET_MATCHES_HEADER2(minLen, continue) -#define MF_PARAMS(p) lenLimit, curMatch, p->pos, p->buffer, p->son, p->cyclicBufferPos, p->cyclicBufferSize, p->cutValue +#define MF_PARAMS(p) lenLimit, curMatch, p->pos, p->buffer, p->son, \ + p->cyclicBufferPos, p->cyclicBufferSize, p->cutValue -#define SKIP_FOOTER SkipMatchesSpec(MF_PARAMS(p)); MOVE_POS; } while (--num); +#define SKIP_FOOTER \ + SkipMatchesSpec(MF_PARAMS(p)); \ + MOVE_POS \ + } while (--num); #define GET_MATCHES_FOOTER_BASE(_maxLen_, func) \ - distances = func(MF_PARAMS(p), \ - distances, (UInt32)_maxLen_); MOVE_POS_RET; + distances = func(MF_PARAMS(p), distances, (UInt32)_maxLen_); \ + MOVE_POS_RET #define GET_MATCHES_FOOTER_BT(_maxLen_) \ GET_MATCHES_FOOTER_BASE(_maxLen_, GetMatchesSpec1) @@ -1049,10 +1148,11 @@ static void MatchFinder_MovePos(CMatchFinder *p) for (; c != lim; c++) if (*(c + diff) != *c) break; \ maxLen = (unsigned)(c - cur); } -static UInt32* Bt2_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) +static UInt32* Bt2_MatchFinder_GetMatches(void *_p, UInt32 *distances) { + CMatchFinder *p = (CMatchFinder *)_p; GET_MATCHES_HEADER(2) - HASH2_CALC; + HASH2_CALC curMatch = p->hash[hv]; p->hash[hv] = p->pos; GET_MATCHES_FOOTER_BT(1) @@ -1061,7 +1161,7 @@ static UInt32* Bt2_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) UInt32* Bt3Zip_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) { GET_MATCHES_HEADER(3) - HASH_ZIP_CALC; + HASH_ZIP_CALC curMatch = p->hash[hv]; p->hash[hv] = p->pos; GET_MATCHES_FOOTER_BT(2) @@ -1074,15 +1174,16 @@ UInt32* Bt3Zip_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) mmm = pos; -static UInt32* Bt3_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) +static UInt32* Bt3_MatchFinder_GetMatches(void *_p, UInt32 *distances) { + CMatchFinder *p = (CMatchFinder *)_p; UInt32 mmm; UInt32 h2, d2, pos; unsigned maxLen; UInt32 *hash; GET_MATCHES_HEADER(3) - HASH3_CALC; + HASH3_CALC hash = p->hash; pos = p->pos; @@ -1107,7 +1208,7 @@ static UInt32* Bt3_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) if (maxLen == lenLimit) { SkipMatchesSpec(MF_PARAMS(p)); - MOVE_POS_RET; + MOVE_POS_RET } } @@ -1115,15 +1216,16 @@ static UInt32* Bt3_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) } -static UInt32* Bt4_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) +static UInt32* Bt4_MatchFinder_GetMatches(void *_p, UInt32 *distances) { + CMatchFinder *p = (CMatchFinder *)_p; UInt32 mmm; UInt32 h2, h3, d2, d3, pos; unsigned maxLen; UInt32 *hash; GET_MATCHES_HEADER(4) - HASH4_CALC; + HASH4_CALC hash = p->hash; pos = p->pos; @@ -1183,14 +1285,16 @@ static UInt32* Bt4_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) } -static UInt32* Bt5_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) +static UInt32* Bt5_MatchFinder_GetMatches(void *_p, UInt32 *distances) { + CMatchFinder *p = (CMatchFinder *)_p; UInt32 mmm; - UInt32 h2, h3, d2, d3, maxLen, pos; + UInt32 h2, h3, d2, d3, pos; + unsigned maxLen; UInt32 *hash; GET_MATCHES_HEADER(5) - HASH5_CALC; + HASH5_CALC hash = p->hash; pos = p->pos; @@ -1246,7 +1350,7 @@ static UInt32* Bt5_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) if (maxLen == lenLimit) { SkipMatchesSpec(MF_PARAMS(p)); - MOVE_POS_RET; + MOVE_POS_RET } break; } @@ -1255,15 +1359,16 @@ static UInt32* Bt5_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) } -static UInt32* Hc4_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) +static UInt32* Hc4_MatchFinder_GetMatches(void *_p, UInt32 *distances) { + CMatchFinder *p = (CMatchFinder *)_p; UInt32 mmm; UInt32 h2, h3, d2, d3, pos; unsigned maxLen; UInt32 *hash; GET_MATCHES_HEADER(4) - HASH4_CALC; + HASH4_CALC hash = p->hash; pos = p->pos; @@ -1314,23 +1419,25 @@ static UInt32* Hc4_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) if (maxLen == lenLimit) { p->son[p->cyclicBufferPos] = curMatch; - MOVE_POS_RET; + MOVE_POS_RET } break; } - GET_MATCHES_FOOTER_HC(maxLen); + GET_MATCHES_FOOTER_HC(maxLen) } -static UInt32 * Hc5_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) +static UInt32 * Hc5_MatchFinder_GetMatches(void *_p, UInt32 *distances) { + CMatchFinder *p = (CMatchFinder *)_p; UInt32 mmm; - UInt32 h2, h3, d2, d3, maxLen, pos; + UInt32 h2, h3, d2, d3, pos; + unsigned maxLen; UInt32 *hash; GET_MATCHES_HEADER(5) - HASH5_CALC; + HASH5_CALC hash = p->hash; pos = p->pos; @@ -1382,34 +1489,35 @@ static UInt32 * Hc5_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) if (*(cur - d2 + 3) != cur[3]) break; UPDATE_maxLen - distances[-2] = maxLen; + distances[-2] = (UInt32)maxLen; if (maxLen == lenLimit) { p->son[p->cyclicBufferPos] = curMatch; - MOVE_POS_RET; + MOVE_POS_RET } break; } - GET_MATCHES_FOOTER_HC(maxLen); + GET_MATCHES_FOOTER_HC(maxLen) } UInt32* Hc3Zip_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances) { GET_MATCHES_HEADER(3) - HASH_ZIP_CALC; + HASH_ZIP_CALC curMatch = p->hash[hv]; p->hash[hv] = p->pos; GET_MATCHES_FOOTER_HC(2) } -static void Bt2_MatchFinder_Skip(CMatchFinder *p, UInt32 num) +static void Bt2_MatchFinder_Skip(void *_p, UInt32 num) { + CMatchFinder *p = (CMatchFinder *)_p; SKIP_HEADER(2) { - HASH2_CALC; + HASH2_CALC curMatch = p->hash[hv]; p->hash[hv] = p->pos; } @@ -1420,20 +1528,21 @@ void Bt3Zip_MatchFinder_Skip(CMatchFinder *p, UInt32 num) { SKIP_HEADER(3) { - HASH_ZIP_CALC; + HASH_ZIP_CALC curMatch = p->hash[hv]; p->hash[hv] = p->pos; } SKIP_FOOTER } -static void Bt3_MatchFinder_Skip(CMatchFinder *p, UInt32 num) +static void Bt3_MatchFinder_Skip(void *_p, UInt32 num) { + CMatchFinder *p = (CMatchFinder *)_p; SKIP_HEADER(3) { UInt32 h2; UInt32 *hash; - HASH3_CALC; + HASH3_CALC hash = p->hash; curMatch = (hash + kFix3HashSize)[hv]; hash[h2] = @@ -1442,13 +1551,14 @@ static void Bt3_MatchFinder_Skip(CMatchFinder *p, UInt32 num) SKIP_FOOTER } -static void Bt4_MatchFinder_Skip(CMatchFinder *p, UInt32 num) +static void Bt4_MatchFinder_Skip(void *_p, UInt32 num) { + CMatchFinder *p = (CMatchFinder *)_p; SKIP_HEADER(4) { UInt32 h2, h3; UInt32 *hash; - HASH4_CALC; + HASH4_CALC hash = p->hash; curMatch = (hash + kFix4HashSize)[hv]; hash [h2] = @@ -1458,13 +1568,14 @@ static void Bt4_MatchFinder_Skip(CMatchFinder *p, UInt32 num) SKIP_FOOTER } -static void Bt5_MatchFinder_Skip(CMatchFinder *p, UInt32 num) +static void Bt5_MatchFinder_Skip(void *_p, UInt32 num) { + CMatchFinder *p = (CMatchFinder *)_p; SKIP_HEADER(5) { UInt32 h2, h3; UInt32 *hash; - HASH5_CALC; + HASH5_CALC hash = p->hash; curMatch = (hash + kFix5HashSize)[hv]; hash [h2] = @@ -1478,7 +1589,7 @@ static void Bt5_MatchFinder_Skip(CMatchFinder *p, UInt32 num) #define HC_SKIP_HEADER(minLen) \ do { if (p->lenLimit < minLen) { MatchFinder_MovePos(p); num--; continue; } { \ - Byte *cur; \ + const Byte *cur; \ UInt32 *hash; \ UInt32 *son; \ UInt32 pos = p->pos; \ @@ -1505,12 +1616,13 @@ static void Bt5_MatchFinder_Skip(CMatchFinder *p, UInt32 num) }} while(num); \ -static void Hc4_MatchFinder_Skip(CMatchFinder *p, UInt32 num) +static void Hc4_MatchFinder_Skip(void *_p, UInt32 num) { + CMatchFinder *p = (CMatchFinder *)_p; HC_SKIP_HEADER(4) UInt32 h2, h3; - HASH4_CALC; + HASH4_CALC curMatch = (hash + kFix4HashSize)[hv]; hash [h2] = (hash + kFix3HashSize)[h3] = @@ -1520,8 +1632,9 @@ static void Hc4_MatchFinder_Skip(CMatchFinder *p, UInt32 num) } -static void Hc5_MatchFinder_Skip(CMatchFinder *p, UInt32 num) +static void Hc5_MatchFinder_Skip(void *_p, UInt32 num) { + CMatchFinder *p = (CMatchFinder *)_p; HC_SKIP_HEADER(5) UInt32 h2, h3; @@ -1540,7 +1653,7 @@ void Hc3Zip_MatchFinder_Skip(CMatchFinder *p, UInt32 num) { HC_SKIP_HEADER(3) - HASH_ZIP_CALC; + HASH_ZIP_CALC curMatch = hash[hv]; hash[hv] = pos; @@ -1550,57 +1663,57 @@ void Hc3Zip_MatchFinder_Skip(CMatchFinder *p, UInt32 num) void MatchFinder_CreateVTable(CMatchFinder *p, IMatchFinder2 *vTable) { - vTable->Init = (Mf_Init_Func)MatchFinder_Init; - vTable->GetNumAvailableBytes = (Mf_GetNumAvailableBytes_Func)MatchFinder_GetNumAvailableBytes; - vTable->GetPointerToCurrentPos = (Mf_GetPointerToCurrentPos_Func)MatchFinder_GetPointerToCurrentPos; + vTable->Init = MatchFinder_Init; + vTable->GetNumAvailableBytes = MatchFinder_GetNumAvailableBytes; + vTable->GetPointerToCurrentPos = MatchFinder_GetPointerToCurrentPos; if (!p->btMode) { if (p->numHashBytes <= 4) { - vTable->GetMatches = (Mf_GetMatches_Func)Hc4_MatchFinder_GetMatches; - vTable->Skip = (Mf_Skip_Func)Hc4_MatchFinder_Skip; + vTable->GetMatches = Hc4_MatchFinder_GetMatches; + vTable->Skip = Hc4_MatchFinder_Skip; } else { - vTable->GetMatches = (Mf_GetMatches_Func)Hc5_MatchFinder_GetMatches; - vTable->Skip = (Mf_Skip_Func)Hc5_MatchFinder_Skip; + vTable->GetMatches = Hc5_MatchFinder_GetMatches; + vTable->Skip = Hc5_MatchFinder_Skip; } } else if (p->numHashBytes == 2) { - vTable->GetMatches = (Mf_GetMatches_Func)Bt2_MatchFinder_GetMatches; - vTable->Skip = (Mf_Skip_Func)Bt2_MatchFinder_Skip; + vTable->GetMatches = Bt2_MatchFinder_GetMatches; + vTable->Skip = Bt2_MatchFinder_Skip; } else if (p->numHashBytes == 3) { - vTable->GetMatches = (Mf_GetMatches_Func)Bt3_MatchFinder_GetMatches; - vTable->Skip = (Mf_Skip_Func)Bt3_MatchFinder_Skip; + vTable->GetMatches = Bt3_MatchFinder_GetMatches; + vTable->Skip = Bt3_MatchFinder_Skip; } else if (p->numHashBytes == 4) { - vTable->GetMatches = (Mf_GetMatches_Func)Bt4_MatchFinder_GetMatches; - vTable->Skip = (Mf_Skip_Func)Bt4_MatchFinder_Skip; + vTable->GetMatches = Bt4_MatchFinder_GetMatches; + vTable->Skip = Bt4_MatchFinder_Skip; } else { - vTable->GetMatches = (Mf_GetMatches_Func)Bt5_MatchFinder_GetMatches; - vTable->Skip = (Mf_Skip_Func)Bt5_MatchFinder_Skip; + vTable->GetMatches = Bt5_MatchFinder_GetMatches; + vTable->Skip = Bt5_MatchFinder_Skip; } } -void LzFindPrepare() +void LzFindPrepare(void) { - #ifndef FORCE_SATUR_SUB_128 - #ifdef USE_SATUR_SUB_128 + #ifndef FORCE_LZFIND_SATUR_SUB_128 + #ifdef USE_LZFIND_SATUR_SUB_128 LZFIND_SATUR_SUB_CODE_FUNC f = NULL; #ifdef MY_CPU_ARM_OR_ARM64 { if (CPU_IsSupported_NEON()) { // #pragma message ("=== LzFind NEON") - _PRF(printf("\n=== LzFind NEON\n")); + PRF(printf("\n=== LzFind NEON\n")); f = LzFind_SaturSub_128; } // f = 0; // for debug @@ -1609,20 +1722,25 @@ void LzFindPrepare() if (CPU_IsSupported_SSE41()) { // #pragma message ("=== LzFind SSE41") - _PRF(printf("\n=== LzFind SSE41\n")); + PRF(printf("\n=== LzFind SSE41\n")); f = LzFind_SaturSub_128; - #ifdef USE_AVX2 + #ifdef USE_LZFIND_SATUR_SUB_256 if (CPU_IsSupported_AVX2()) { // #pragma message ("=== LzFind AVX2") - _PRF(printf("\n=== LzFind AVX2\n")); + PRF(printf("\n=== LzFind AVX2\n")); f = LzFind_SaturSub_256; } #endif } #endif // MY_CPU_ARM_OR_ARM64 g_LzFind_SaturSub = f; - #endif // USE_SATUR_SUB_128 - #endif // FORCE_SATUR_SUB_128 + #endif // USE_LZFIND_SATUR_SUB_128 + #endif // FORCE_LZFIND_SATUR_SUB_128 } + + +#undef MOVE_POS +#undef MOVE_POS_RET +#undef PRF diff --git a/common/LZMA/SDK/C/LzFind.h b/common/LZMA/SDK/C/LzFind.h index eea873f..67e8a6e 100644 --- a/common/LZMA/SDK/C/LzFind.h +++ b/common/LZMA/SDK/C/LzFind.h @@ -1,8 +1,8 @@ /* LzFind.h -- Match finder for LZ algorithms -2021-07-13 : Igor Pavlov : Public domain */ +2024-01-22 : Igor Pavlov : Public domain */ -#ifndef __LZ_FIND_H -#define __LZ_FIND_H +#ifndef ZIP7_INC_LZ_FIND_H +#define ZIP7_INC_LZ_FIND_H #include "7zTypes.h" @@ -10,9 +10,9 @@ EXTERN_C_BEGIN typedef UInt32 CLzRef; -typedef struct _CMatchFinder +typedef struct { - Byte *buffer; + const Byte *buffer; UInt32 pos; UInt32 posLimit; UInt32 streamPos; /* wrap over Zero is allowed (streamPos < pos). Use (UInt32)(streamPos - pos) */ @@ -32,8 +32,8 @@ typedef struct _CMatchFinder UInt32 hashMask; UInt32 cutValue; - Byte *bufferBase; - ISeqInStream *stream; + Byte *bufBase; + ISeqInStreamPtr stream; UInt32 blockSize; UInt32 keepSizeBefore; @@ -43,7 +43,9 @@ typedef struct _CMatchFinder size_t directInputRem; UInt32 historySize; UInt32 fixedHashSize; - UInt32 hashSizeSum; + Byte numHashBytes_Min; + Byte numHashOutBits; + Byte _pad2_[2]; SRes result; UInt32 crc[256]; size_t numRefs; @@ -69,24 +71,45 @@ void MatchFinder_ReadIfRequired(CMatchFinder *p); void MatchFinder_Construct(CMatchFinder *p); -/* Conditions: - historySize <= 3 GB - keepAddBufferBefore + matchMaxLen + keepAddBufferAfter < 511MB +/* (directInput = 0) is default value. + It's required to provide correct (directInput) value + before calling MatchFinder_Create(). + You can set (directInput) by any of the following calls: + - MatchFinder_SET_DIRECT_INPUT_BUF() + - MatchFinder_SET_STREAM() + - MatchFinder_SET_STREAM_MODE() */ + +#define MatchFinder_SET_DIRECT_INPUT_BUF(p, _src_, _srcLen_) { \ + (p)->stream = NULL; \ + (p)->directInput = 1; \ + (p)->buffer = (_src_); \ + (p)->directInputRem = (_srcLen_); } + +/* +#define MatchFinder_SET_STREAM_MODE(p) { \ + (p)->directInput = 0; } +*/ + +#define MatchFinder_SET_STREAM(p, _stream_) { \ + (p)->stream = _stream_; \ + (p)->directInput = 0; } + + int MatchFinder_Create(CMatchFinder *p, UInt32 historySize, UInt32 keepAddBufferBefore, UInt32 matchMaxLen, UInt32 keepAddBufferAfter, ISzAllocPtr alloc); void MatchFinder_Free(CMatchFinder *p, ISzAllocPtr alloc); void MatchFinder_Normalize3(UInt32 subValue, CLzRef *items, size_t numItems); -// void MatchFinder_ReduceOffsets(CMatchFinder *p, UInt32 subValue); /* -#define Inline_MatchFinder_InitPos(p, val) \ +#define MatchFinder_INIT_POS(p, val) \ (p)->pos = (val); \ (p)->streamPos = (val); */ -#define Inline_MatchFinder_ReduceOffsets(p, subValue) \ +// void MatchFinder_ReduceOffsets(CMatchFinder *p, UInt32 subValue); +#define MatchFinder_REDUCE_OFFSETS(p, subValue) \ (p)->pos -= (subValue); \ (p)->streamPos -= (subValue); @@ -107,7 +130,7 @@ typedef const Byte * (*Mf_GetPointerToCurrentPos_Func)(void *object); typedef UInt32 * (*Mf_GetMatches_Func)(void *object, UInt32 *distances); typedef void (*Mf_Skip_Func)(void *object, UInt32); -typedef struct _IMatchFinder +typedef struct { Mf_Init_Func Init; Mf_GetNumAvailableBytes_Func GetNumAvailableBytes; @@ -121,7 +144,8 @@ void MatchFinder_CreateVTable(CMatchFinder *p, IMatchFinder2 *vTable); void MatchFinder_Init_LowHash(CMatchFinder *p); void MatchFinder_Init_HighHash(CMatchFinder *p); void MatchFinder_Init_4(CMatchFinder *p); -void MatchFinder_Init(CMatchFinder *p); +// void MatchFinder_Init(CMatchFinder *p); +void MatchFinder_Init(void *p); UInt32* Bt3Zip_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances); UInt32* Hc3Zip_MatchFinder_GetMatches(CMatchFinder *p, UInt32 *distances); diff --git a/common/LZMA/SDK/C/LzHash.h b/common/LZMA/SDK/C/LzHash.h index 77b898c..2b6290b 100644 --- a/common/LZMA/SDK/C/LzHash.h +++ b/common/LZMA/SDK/C/LzHash.h @@ -1,8 +1,8 @@ -/* LzHash.h -- HASH functions for LZ algorithms -2019-10-30 : Igor Pavlov : Public domain */ +/* LzHash.h -- HASH constants for LZ algorithms +2023-03-05 : Igor Pavlov : Public domain */ -#ifndef __LZ_HASH_H -#define __LZ_HASH_H +#ifndef ZIP7_INC_LZ_HASH_H +#define ZIP7_INC_LZ_HASH_H /* (kHash2Size >= (1 << 8)) : Required diff --git a/common/LZMA/SDK/C/LzmaDec.c b/common/LZMA/SDK/C/LzmaDec.c index d6742e5..69bb8bb 100644 --- a/common/LZMA/SDK/C/LzmaDec.c +++ b/common/LZMA/SDK/C/LzmaDec.c @@ -1,5 +1,5 @@ /* LzmaDec.c -- LZMA Decoder -2021-04-01 : Igor Pavlov : Public domain */ +2023-04-07 : Igor Pavlov : Public domain */ #include "Precomp.h" @@ -8,15 +8,15 @@ /* #include "CpuArch.h" */ #include "LzmaDec.h" -#define kNumTopBits 24 -#define kTopValue ((UInt32)1 << kNumTopBits) +// #define kNumTopBits 24 +#define kTopValue ((UInt32)1 << 24) #define kNumBitModelTotalBits 11 #define kBitModelTotal (1 << kNumBitModelTotalBits) #define RC_INIT_SIZE 5 -#ifndef _LZMA_DEC_OPT +#ifndef Z7_LZMA_DEC_OPT #define kNumMoveBits 5 #define NORMALIZE if (range < kTopValue) { range <<= 8; code = (code << 8) | (*buf++); } @@ -25,14 +25,14 @@ #define UPDATE_0(p) range = bound; *(p) = (CLzmaProb)(ttt + ((kBitModelTotal - ttt) >> kNumMoveBits)); #define UPDATE_1(p) range -= bound; code -= bound; *(p) = (CLzmaProb)(ttt - (ttt >> kNumMoveBits)); #define GET_BIT2(p, i, A0, A1) IF_BIT_0(p) \ - { UPDATE_0(p); i = (i + i); A0; } else \ - { UPDATE_1(p); i = (i + i) + 1; A1; } + { UPDATE_0(p) i = (i + i); A0; } else \ + { UPDATE_1(p) i = (i + i) + 1; A1; } #define TREE_GET_BIT(probs, i) { GET_BIT2(probs + i, i, ;, ;); } #define REV_BIT(p, i, A0, A1) IF_BIT_0(p + i) \ - { UPDATE_0(p + i); A0; } else \ - { UPDATE_1(p + i); A1; } + { UPDATE_0(p + i) A0; } else \ + { UPDATE_1(p + i) A1; } #define REV_BIT_VAR( p, i, m) REV_BIT(p, i, i += m; m += m, m += m; i += m; ) #define REV_BIT_CONST(p, i, m) REV_BIT(p, i, i += m; , i += m * 2; ) #define REV_BIT_LAST( p, i, m) REV_BIT(p, i, i -= m , ; ) @@ -40,19 +40,19 @@ #define TREE_DECODE(probs, limit, i) \ { i = 1; do { TREE_GET_BIT(probs, i); } while (i < limit); i -= limit; } -/* #define _LZMA_SIZE_OPT */ +/* #define Z7_LZMA_SIZE_OPT */ -#ifdef _LZMA_SIZE_OPT +#ifdef Z7_LZMA_SIZE_OPT #define TREE_6_DECODE(probs, i) TREE_DECODE(probs, (1 << 6), i) #else #define TREE_6_DECODE(probs, i) \ { i = 1; \ - TREE_GET_BIT(probs, i); \ - TREE_GET_BIT(probs, i); \ - TREE_GET_BIT(probs, i); \ - TREE_GET_BIT(probs, i); \ - TREE_GET_BIT(probs, i); \ - TREE_GET_BIT(probs, i); \ + TREE_GET_BIT(probs, i) \ + TREE_GET_BIT(probs, i) \ + TREE_GET_BIT(probs, i) \ + TREE_GET_BIT(probs, i) \ + TREE_GET_BIT(probs, i) \ + TREE_GET_BIT(probs, i) \ i -= 0x40; } #endif @@ -64,25 +64,25 @@ probLit = prob + (offs + bit + symbol); \ GET_BIT2(probLit, symbol, offs ^= bit; , ;) -#endif // _LZMA_DEC_OPT +#endif // Z7_LZMA_DEC_OPT #define NORMALIZE_CHECK if (range < kTopValue) { if (buf >= bufLimit) return DUMMY_INPUT_EOF; range <<= 8; code = (code << 8) | (*buf++); } -#define IF_BIT_0_CHECK(p) ttt = *(p); NORMALIZE_CHECK; bound = (range >> kNumBitModelTotalBits) * (UInt32)ttt; if (code < bound) +#define IF_BIT_0_CHECK(p) ttt = *(p); NORMALIZE_CHECK bound = (range >> kNumBitModelTotalBits) * (UInt32)ttt; if (code < bound) #define UPDATE_0_CHECK range = bound; #define UPDATE_1_CHECK range -= bound; code -= bound; #define GET_BIT2_CHECK(p, i, A0, A1) IF_BIT_0_CHECK(p) \ - { UPDATE_0_CHECK; i = (i + i); A0; } else \ - { UPDATE_1_CHECK; i = (i + i) + 1; A1; } + { UPDATE_0_CHECK i = (i + i); A0; } else \ + { UPDATE_1_CHECK i = (i + i) + 1; A1; } #define GET_BIT_CHECK(p, i) GET_BIT2_CHECK(p, i, ; , ;) #define TREE_DECODE_CHECK(probs, limit, i) \ { i = 1; do { GET_BIT_CHECK(probs + i, i) } while (i < limit); i -= limit; } #define REV_BIT_CHECK(p, i, m) IF_BIT_0_CHECK(p + i) \ - { UPDATE_0_CHECK; i += m; m += m; } else \ - { UPDATE_1_CHECK; m += m; i += m; } + { UPDATE_0_CHECK i += m; m += m; } else \ + { UPDATE_1_CHECK m += m; i += m; } #define kNumPosBitsMax 4 @@ -224,14 +224,14 @@ Out: */ -#ifdef _LZMA_DEC_OPT +#ifdef Z7_LZMA_DEC_OPT -int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit); +int Z7_FASTCALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit); #else static -int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit) +int Z7_FASTCALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit) { CLzmaProb *probs = GET_PROBS; unsigned state = (unsigned)p->state; @@ -263,7 +263,7 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit IF_BIT_0(prob) { unsigned symbol; - UPDATE_0(prob); + UPDATE_0(prob) prob = probs + Literal; if (processedPos != 0 || checkDicSize != 0) prob += (UInt32)3 * ((((processedPos << 8) + dic[(dicPos == 0 ? dicBufSize : dicPos) - 1]) & lpMask) << lc); @@ -273,7 +273,7 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit { state -= (state < 4) ? state : 3; symbol = 1; - #ifdef _LZMA_SIZE_OPT + #ifdef Z7_LZMA_SIZE_OPT do { NORMAL_LITER_DEC } while (symbol < 0x100); #else NORMAL_LITER_DEC @@ -292,7 +292,7 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit unsigned offs = 0x100; state -= (state < 10) ? 3 : 6; symbol = 1; - #ifdef _LZMA_SIZE_OPT + #ifdef Z7_LZMA_SIZE_OPT do { unsigned bit; @@ -321,25 +321,25 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit } { - UPDATE_1(prob); + UPDATE_1(prob) prob = probs + IsRep + state; IF_BIT_0(prob) { - UPDATE_0(prob); + UPDATE_0(prob) state += kNumStates; prob = probs + LenCoder; } else { - UPDATE_1(prob); + UPDATE_1(prob) prob = probs + IsRepG0 + state; IF_BIT_0(prob) { - UPDATE_0(prob); + UPDATE_0(prob) prob = probs + IsRep0Long + COMBINED_PS_STATE; IF_BIT_0(prob) { - UPDATE_0(prob); + UPDATE_0(prob) // that case was checked before with kBadRepCode // if (checkDicSize == 0 && processedPos == 0) { len = kMatchSpecLen_Error_Data + 1; break; } @@ -353,30 +353,30 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit state = state < kNumLitStates ? 9 : 11; continue; } - UPDATE_1(prob); + UPDATE_1(prob) } else { UInt32 distance; - UPDATE_1(prob); + UPDATE_1(prob) prob = probs + IsRepG1 + state; IF_BIT_0(prob) { - UPDATE_0(prob); + UPDATE_0(prob) distance = rep1; } else { - UPDATE_1(prob); + UPDATE_1(prob) prob = probs + IsRepG2 + state; IF_BIT_0(prob) { - UPDATE_0(prob); + UPDATE_0(prob) distance = rep2; } else { - UPDATE_1(prob); + UPDATE_1(prob) distance = rep3; rep3 = rep2; } @@ -389,37 +389,37 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit prob = probs + RepLenCoder; } - #ifdef _LZMA_SIZE_OPT + #ifdef Z7_LZMA_SIZE_OPT { unsigned lim, offset; CLzmaProb *probLen = prob + LenChoice; IF_BIT_0(probLen) { - UPDATE_0(probLen); + UPDATE_0(probLen) probLen = prob + LenLow + GET_LEN_STATE; offset = 0; lim = (1 << kLenNumLowBits); } else { - UPDATE_1(probLen); + UPDATE_1(probLen) probLen = prob + LenChoice2; IF_BIT_0(probLen) { - UPDATE_0(probLen); + UPDATE_0(probLen) probLen = prob + LenLow + GET_LEN_STATE + (1 << kLenNumLowBits); offset = kLenNumLowSymbols; lim = (1 << kLenNumLowBits); } else { - UPDATE_1(probLen); + UPDATE_1(probLen) probLen = prob + LenHigh; offset = kLenNumLowSymbols * 2; lim = (1 << kLenNumHighBits); } } - TREE_DECODE(probLen, lim, len); + TREE_DECODE(probLen, lim, len) len += offset; } #else @@ -427,32 +427,32 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit CLzmaProb *probLen = prob + LenChoice; IF_BIT_0(probLen) { - UPDATE_0(probLen); + UPDATE_0(probLen) probLen = prob + LenLow + GET_LEN_STATE; len = 1; - TREE_GET_BIT(probLen, len); - TREE_GET_BIT(probLen, len); - TREE_GET_BIT(probLen, len); + TREE_GET_BIT(probLen, len) + TREE_GET_BIT(probLen, len) + TREE_GET_BIT(probLen, len) len -= 8; } else { - UPDATE_1(probLen); + UPDATE_1(probLen) probLen = prob + LenChoice2; IF_BIT_0(probLen) { - UPDATE_0(probLen); + UPDATE_0(probLen) probLen = prob + LenLow + GET_LEN_STATE + (1 << kLenNumLowBits); len = 1; - TREE_GET_BIT(probLen, len); - TREE_GET_BIT(probLen, len); - TREE_GET_BIT(probLen, len); + TREE_GET_BIT(probLen, len) + TREE_GET_BIT(probLen, len) + TREE_GET_BIT(probLen, len) } else { - UPDATE_1(probLen); + UPDATE_1(probLen) probLen = prob + LenHigh; - TREE_DECODE(probLen, (1 << kLenNumHighBits), len); + TREE_DECODE(probLen, (1 << kLenNumHighBits), len) len += kLenNumLowSymbols * 2; } } @@ -464,7 +464,7 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit UInt32 distance; prob = probs + PosSlot + ((len < kNumLenToPosStates ? len : kNumLenToPosStates - 1) << kNumPosSlotBits); - TREE_6_DECODE(prob, distance); + TREE_6_DECODE(prob, distance) if (distance >= kStartPosModelIndex) { unsigned posSlot = (unsigned)distance; @@ -479,7 +479,7 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit distance++; do { - REV_BIT_VAR(prob, distance, m); + REV_BIT_VAR(prob, distance, m) } while (--numDirectBits); distance -= m; @@ -514,10 +514,10 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit distance <<= kNumAlignBits; { unsigned i = 1; - REV_BIT_CONST(prob, i, 1); - REV_BIT_CONST(prob, i, 2); - REV_BIT_CONST(prob, i, 4); - REV_BIT_LAST (prob, i, 8); + REV_BIT_CONST(prob, i, 1) + REV_BIT_CONST(prob, i, 2) + REV_BIT_CONST(prob, i, 4) + REV_BIT_LAST (prob, i, 8) distance |= i; } if (distance == (UInt32)0xFFFFFFFF) @@ -592,7 +592,7 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit } while (dicPos < limit && buf < bufLimit); - NORMALIZE; + NORMALIZE p->buf = buf; p->range = range; @@ -613,7 +613,7 @@ int MY_FAST_CALL LZMA_DECODE_REAL(CLzmaDec *p, SizeT limit, const Byte *bufLimit -static void MY_FAST_CALL LzmaDec_WriteRem(CLzmaDec *p, SizeT limit) +static void Z7_FASTCALL LzmaDec_WriteRem(CLzmaDec *p, SizeT limit) { unsigned len = (unsigned)p->remainLen; if (len == 0 /* || len >= kMatchSpecLenStart */) @@ -683,7 +683,7 @@ and we support the following state of (p->checkDicSize): (p->checkDicSize == p->prop.dicSize) */ -static int MY_FAST_CALL LzmaDec_DecodeReal2(CLzmaDec *p, SizeT limit, const Byte *bufLimit) +static int Z7_FASTCALL LzmaDec_DecodeReal2(CLzmaDec *p, SizeT limit, const Byte *bufLimit) { if (p->checkDicSize == 0) { @@ -767,54 +767,54 @@ static ELzmaDummy LzmaDec_TryDummy(const CLzmaDec *p, const Byte *buf, const Byt else { unsigned len; - UPDATE_1_CHECK; + UPDATE_1_CHECK prob = probs + IsRep + state; IF_BIT_0_CHECK(prob) { - UPDATE_0_CHECK; + UPDATE_0_CHECK state = 0; prob = probs + LenCoder; res = DUMMY_MATCH; } else { - UPDATE_1_CHECK; + UPDATE_1_CHECK res = DUMMY_REP; prob = probs + IsRepG0 + state; IF_BIT_0_CHECK(prob) { - UPDATE_0_CHECK; + UPDATE_0_CHECK prob = probs + IsRep0Long + COMBINED_PS_STATE; IF_BIT_0_CHECK(prob) { - UPDATE_0_CHECK; + UPDATE_0_CHECK break; } else { - UPDATE_1_CHECK; + UPDATE_1_CHECK } } else { - UPDATE_1_CHECK; + UPDATE_1_CHECK prob = probs + IsRepG1 + state; IF_BIT_0_CHECK(prob) { - UPDATE_0_CHECK; + UPDATE_0_CHECK } else { - UPDATE_1_CHECK; + UPDATE_1_CHECK prob = probs + IsRepG2 + state; IF_BIT_0_CHECK(prob) { - UPDATE_0_CHECK; + UPDATE_0_CHECK } else { - UPDATE_1_CHECK; + UPDATE_1_CHECK } } } @@ -826,31 +826,31 @@ static ELzmaDummy LzmaDec_TryDummy(const CLzmaDec *p, const Byte *buf, const Byt const CLzmaProb *probLen = prob + LenChoice; IF_BIT_0_CHECK(probLen) { - UPDATE_0_CHECK; + UPDATE_0_CHECK probLen = prob + LenLow + GET_LEN_STATE; offset = 0; limit = 1 << kLenNumLowBits; } else { - UPDATE_1_CHECK; + UPDATE_1_CHECK probLen = prob + LenChoice2; IF_BIT_0_CHECK(probLen) { - UPDATE_0_CHECK; + UPDATE_0_CHECK probLen = prob + LenLow + GET_LEN_STATE + (1 << kLenNumLowBits); offset = kLenNumLowSymbols; limit = 1 << kLenNumLowBits; } else { - UPDATE_1_CHECK; + UPDATE_1_CHECK probLen = prob + LenHigh; offset = kLenNumLowSymbols * 2; limit = 1 << kLenNumHighBits; } } - TREE_DECODE_CHECK(probLen, limit, len); + TREE_DECODE_CHECK(probLen, limit, len) len += offset; } @@ -860,7 +860,7 @@ static ELzmaDummy LzmaDec_TryDummy(const CLzmaDec *p, const Byte *buf, const Byt prob = probs + PosSlot + ((len < kNumLenToPosStates - 1 ? len : kNumLenToPosStates - 1) << kNumPosSlotBits); - TREE_DECODE_CHECK(prob, 1 << kNumPosSlotBits, posSlot); + TREE_DECODE_CHECK(prob, 1 << kNumPosSlotBits, posSlot) if (posSlot >= kStartPosModelIndex) { unsigned numDirectBits = ((posSlot >> 1) - 1); @@ -888,7 +888,7 @@ static ELzmaDummy LzmaDec_TryDummy(const CLzmaDec *p, const Byte *buf, const Byt unsigned m = 1; do { - REV_BIT_CHECK(prob, i, m); + REV_BIT_CHECK(prob, i, m) } while (--numDirectBits); } @@ -897,7 +897,7 @@ static ELzmaDummy LzmaDec_TryDummy(const CLzmaDec *p, const Byte *buf, const Byt } break; } - NORMALIZE_CHECK; + NORMALIZE_CHECK *bufOut = buf; return res; @@ -943,7 +943,7 @@ When the decoder lookahead, and the lookahead symbol is not end_marker, we have */ -#define RETURN__NOT_FINISHED__FOR_FINISH \ +#define RETURN_NOT_FINISHED_FOR_FINISH \ *status = LZMA_STATUS_NOT_FINISHED; \ return SZ_ERROR_DATA; // for strict mode // return SZ_OK; // for relaxed mode @@ -1029,7 +1029,7 @@ SRes LzmaDec_DecodeToDic(CLzmaDec *p, SizeT dicLimit, const Byte *src, SizeT *sr } if (p->remainLen != 0) { - RETURN__NOT_FINISHED__FOR_FINISH; + RETURN_NOT_FINISHED_FOR_FINISH } checkEndMarkNow = 1; } @@ -1072,7 +1072,7 @@ SRes LzmaDec_DecodeToDic(CLzmaDec *p, SizeT dicLimit, const Byte *src, SizeT *sr for (i = 0; i < (unsigned)dummyProcessed; i++) p->tempBuf[i] = src[i]; // p->remainLen = kMatchSpecLen_Error_Data; - RETURN__NOT_FINISHED__FOR_FINISH; + RETURN_NOT_FINISHED_FOR_FINISH } bufLimit = src; @@ -1150,7 +1150,7 @@ SRes LzmaDec_DecodeToDic(CLzmaDec *p, SizeT dicLimit, const Byte *src, SizeT *sr (*srcLen) += (unsigned)dummyProcessed - p->tempBufSize; p->tempBufSize = (unsigned)dummyProcessed; // p->remainLen = kMatchSpecLen_Error_Data; - RETURN__NOT_FINISHED__FOR_FINISH; + RETURN_NOT_FINISHED_FOR_FINISH } } @@ -1299,8 +1299,8 @@ static SRes LzmaDec_AllocateProbs2(CLzmaDec *p, const CLzmaProps *propNew, ISzAl SRes LzmaDec_AllocateProbs(CLzmaDec *p, const Byte *props, unsigned propsSize, ISzAllocPtr alloc) { CLzmaProps propNew; - RINOK(LzmaProps_Decode(&propNew, props, propsSize)); - RINOK(LzmaDec_AllocateProbs2(p, &propNew, alloc)); + RINOK(LzmaProps_Decode(&propNew, props, propsSize)) + RINOK(LzmaDec_AllocateProbs2(p, &propNew, alloc)) p->prop = propNew; return SZ_OK; } @@ -1309,14 +1309,14 @@ SRes LzmaDec_Allocate(CLzmaDec *p, const Byte *props, unsigned propsSize, ISzAll { CLzmaProps propNew; SizeT dicBufSize; - RINOK(LzmaProps_Decode(&propNew, props, propsSize)); - RINOK(LzmaDec_AllocateProbs2(p, &propNew, alloc)); + RINOK(LzmaProps_Decode(&propNew, props, propsSize)) + RINOK(LzmaDec_AllocateProbs2(p, &propNew, alloc)) { UInt32 dictSize = propNew.dicSize; SizeT mask = ((UInt32)1 << 12) - 1; if (dictSize >= ((UInt32)1 << 30)) mask = ((UInt32)1 << 22) - 1; - else if (dictSize >= ((UInt32)1 << 22)) mask = ((UInt32)1 << 20) - 1;; + else if (dictSize >= ((UInt32)1 << 22)) mask = ((UInt32)1 << 20) - 1; dicBufSize = ((SizeT)dictSize + mask) & ~mask; if (dicBufSize < dictSize) dicBufSize = dictSize; @@ -1348,8 +1348,8 @@ SRes LzmaDecode(Byte *dest, SizeT *destLen, const Byte *src, SizeT *srcLen, *status = LZMA_STATUS_NOT_SPECIFIED; if (inSize < RC_INIT_SIZE) return SZ_ERROR_INPUT_EOF; - LzmaDec_Construct(&p); - RINOK(LzmaDec_AllocateProbs(&p, propData, propSize, alloc)); + LzmaDec_CONSTRUCT(&p) + RINOK(LzmaDec_AllocateProbs(&p, propData, propSize, alloc)) p.dic = dest; p.dicBufSize = outSize; LzmaDec_Init(&p); diff --git a/common/LZMA/SDK/C/LzmaDec.h b/common/LZMA/SDK/C/LzmaDec.h index 6f12962..b0ce28f 100644 --- a/common/LZMA/SDK/C/LzmaDec.h +++ b/common/LZMA/SDK/C/LzmaDec.h @@ -1,19 +1,19 @@ /* LzmaDec.h -- LZMA Decoder -2020-03-19 : Igor Pavlov : Public domain */ +2023-04-02 : Igor Pavlov : Public domain */ -#ifndef __LZMA_DEC_H -#define __LZMA_DEC_H +#ifndef ZIP7_INC_LZMA_DEC_H +#define ZIP7_INC_LZMA_DEC_H #include "7zTypes.h" EXTERN_C_BEGIN -/* #define _LZMA_PROB32 */ -/* _LZMA_PROB32 can increase the speed on some CPUs, +/* #define Z7_LZMA_PROB32 */ +/* Z7_LZMA_PROB32 can increase the speed on some CPUs, but memory usage for CLzmaDec::probs will be doubled in that case */ typedef -#ifdef _LZMA_PROB32 +#ifdef Z7_LZMA_PROB32 UInt32 #else UInt16 @@ -25,7 +25,7 @@ typedef #define LZMA_PROPS_SIZE 5 -typedef struct _CLzmaProps +typedef struct { Byte lc; Byte lp; @@ -73,7 +73,8 @@ typedef struct Byte tempBuf[LZMA_REQUIRED_INPUT_MAX]; } CLzmaDec; -#define LzmaDec_Construct(p) { (p)->dic = NULL; (p)->probs = NULL; } +#define LzmaDec_CONSTRUCT(p) { (p)->dic = NULL; (p)->probs = NULL; } +#define LzmaDec_Construct(p) LzmaDec_CONSTRUCT(p) void LzmaDec_Init(CLzmaDec *p); diff --git a/common/LZMA/SDK/C/LzmaEnc.c b/common/LZMA/SDK/C/LzmaEnc.c index c8b31a1..088b78f 100644 --- a/common/LZMA/SDK/C/LzmaEnc.c +++ b/common/LZMA/SDK/C/LzmaEnc.c @@ -1,5 +1,5 @@ /* LzmaEnc.c -- LZMA Encoder -2022-07-15: Igor Pavlov : Public domain */ +Igor Pavlov : Public domain */ #include "Precomp.h" @@ -16,22 +16,22 @@ #include "LzmaEnc.h" #include "LzFind.h" -#ifndef _7ZIP_ST +#ifndef Z7_ST #include "LzFindMt.h" #endif /* the following LzmaEnc_* declarations is internal LZMA interface for LZMA2 encoder */ -SRes LzmaEnc_PrepareForLzma2(CLzmaEncHandle pp, ISeqInStream *inStream, UInt32 keepWindowSize, +SRes LzmaEnc_PrepareForLzma2(CLzmaEncHandle p, ISeqInStreamPtr inStream, UInt32 keepWindowSize, ISzAllocPtr alloc, ISzAllocPtr allocBig); -SRes LzmaEnc_MemPrepare(CLzmaEncHandle pp, const Byte *src, SizeT srcLen, +SRes LzmaEnc_MemPrepare(CLzmaEncHandle p, const Byte *src, SizeT srcLen, UInt32 keepWindowSize, ISzAllocPtr alloc, ISzAllocPtr allocBig); -SRes LzmaEnc_CodeOneMemBlock(CLzmaEncHandle pp, BoolInt reInit, +SRes LzmaEnc_CodeOneMemBlock(CLzmaEncHandle p, BoolInt reInit, Byte *dest, size_t *destLen, UInt32 desiredPackSize, UInt32 *unpackSize); -const Byte *LzmaEnc_GetCurBuf(CLzmaEncHandle pp); -void LzmaEnc_Finish(CLzmaEncHandle pp); -void LzmaEnc_SaveState(CLzmaEncHandle pp); -void LzmaEnc_RestoreState(CLzmaEncHandle pp); +const Byte *LzmaEnc_GetCurBuf(CLzmaEncHandle p); +void LzmaEnc_Finish(CLzmaEncHandle p); +void LzmaEnc_SaveState(CLzmaEncHandle p); +void LzmaEnc_RestoreState(CLzmaEncHandle p); #ifdef SHOW_STAT static unsigned g_STAT_OFFSET = 0; @@ -40,8 +40,8 @@ static unsigned g_STAT_OFFSET = 0; /* for good normalization speed we still reserve 256 MB before 4 GB range */ #define kLzmaMaxHistorySize ((UInt32)15 << 28) -#define kNumTopBits 24 -#define kTopValue ((UInt32)1 << kNumTopBits) +// #define kNumTopBits 24 +#define kTopValue ((UInt32)1 << 24) #define kNumBitModelTotalBits 11 #define kBitModelTotal (1 << kNumBitModelTotalBits) @@ -60,6 +60,7 @@ void LzmaEncProps_Init(CLzmaEncProps *p) p->dictSize = p->mc = 0; p->reduceSize = (UInt64)(Int64)-1; p->lc = p->lp = p->pb = p->algo = p->fb = p->btMode = p->numHashBytes = p->numThreads = -1; + p->numHashOutBits = 0; p->writeEndMark = 0; p->affinity = 0; } @@ -71,11 +72,11 @@ void LzmaEncProps_Normalize(CLzmaEncProps *p) p->level = level; if (p->dictSize == 0) - p->dictSize = - ( level <= 3 ? ((UInt32)1 << (level * 2 + 16)) : - ( level <= 6 ? ((UInt32)1 << (level + 19)) : - ( level <= 7 ? ((UInt32)1 << 25) : ((UInt32)1 << 26) - ))); + p->dictSize = (unsigned)level <= 4 ? + (UInt32)1 << (level * 2 + 16) : + (unsigned)level <= sizeof(size_t) / 2 + 4 ? + (UInt32)1 << (level + 20) : + (UInt32)1 << (sizeof(size_t) / 2 + 24); if (p->dictSize > p->reduceSize) { @@ -91,15 +92,15 @@ void LzmaEncProps_Normalize(CLzmaEncProps *p) if (p->lp < 0) p->lp = 0; if (p->pb < 0) p->pb = 2; - if (p->algo < 0) p->algo = (level < 5 ? 0 : 1); - if (p->fb < 0) p->fb = (level < 7 ? 32 : 64); + if (p->algo < 0) p->algo = (unsigned)level < 5 ? 0 : 1; + if (p->fb < 0) p->fb = (unsigned)level < 7 ? 32 : 64; if (p->btMode < 0) p->btMode = (p->algo == 0 ? 0 : 1); if (p->numHashBytes < 0) p->numHashBytes = (p->btMode ? 4 : 5); if (p->mc == 0) p->mc = (16 + ((unsigned)p->fb >> 1)) >> (p->btMode ? 0 : 1); if (p->numThreads < 0) p->numThreads = - #ifndef _7ZIP_ST + #ifndef Z7_ST ((p->btMode && p->algo) ? 2 : 1); #else 1; @@ -194,11 +195,11 @@ unsigned GetPosSlot1(UInt32 pos); unsigned GetPosSlot1(UInt32 pos) { unsigned res; - BSR2_RET(pos, res); + BSR2_RET(pos, res) return res; } -#define GetPosSlot2(pos, res) { BSR2_RET(pos, res); } -#define GetPosSlot(pos, res) { if (pos < 2) res = pos; else BSR2_RET(pos, res); } +#define GetPosSlot2(pos, res) { BSR2_RET(pos, res) } +#define GetPosSlot(pos, res) { if (pos < 2) res = pos; else BSR2_RET(pos, res) } #else // ! LZMA_LOG_BSR @@ -293,7 +294,7 @@ typedef struct #define kNumFullDistances (1 << (kEndPosModelIndex >> 1)) typedef -#ifdef _LZMA_PROB32 +#ifdef Z7_LZMA_PROB32 UInt32 #else UInt16 @@ -350,7 +351,7 @@ typedef struct Byte *buf; Byte *bufLim; Byte *bufBase; - ISeqOutStream *outStream; + ISeqOutStreamPtr outStream; UInt64 processed; SRes res; } CRangeEnc; @@ -383,7 +384,7 @@ typedef struct typedef UInt32 CProbPrice; -typedef struct +struct CLzmaEnc { void *matchFinderObj; IMatchFinder2 matchFinder; @@ -426,7 +427,7 @@ typedef struct UInt32 dictSize; SRes result; - #ifndef _7ZIP_ST + #ifndef Z7_ST BoolInt mtMode; // begin of CMatchFinderMt is used in LZ thread CMatchFinderMt matchFinderMt; @@ -439,7 +440,7 @@ typedef struct // we suppose that we have 8-bytes alignment after CMatchFinder - #ifndef _7ZIP_ST + #ifndef Z7_ST Byte pad[128]; #endif @@ -479,77 +480,59 @@ typedef struct CSaveState saveState; // BoolInt mf_Failure; - #ifndef _7ZIP_ST + #ifndef Z7_ST Byte pad2[128]; #endif -} CLzmaEnc; +}; #define MFB (p->matchFinderBase) /* -#ifndef _7ZIP_ST +#ifndef Z7_ST #define MFB (p->matchFinderMt.MatchFinder) #endif */ -#define COPY_ARR(dest, src, arr) memcpy(dest->arr, src->arr, sizeof(src->arr)); +// #define GET_CLzmaEnc_p CLzmaEnc *p = (CLzmaEnc*)(void *)p; +// #define GET_const_CLzmaEnc_p const CLzmaEnc *p = (const CLzmaEnc*)(const void *)p; -void LzmaEnc_SaveState(CLzmaEncHandle pp) +#define COPY_ARR(dest, src, arr) memcpy((dest)->arr, (src)->arr, sizeof((src)->arr)); + +#define COPY_LZMA_ENC_STATE(d, s, p) \ + (d)->state = (s)->state; \ + COPY_ARR(d, s, reps) \ + COPY_ARR(d, s, posAlignEncoder) \ + COPY_ARR(d, s, isRep) \ + COPY_ARR(d, s, isRepG0) \ + COPY_ARR(d, s, isRepG1) \ + COPY_ARR(d, s, isRepG2) \ + COPY_ARR(d, s, isMatch) \ + COPY_ARR(d, s, isRep0Long) \ + COPY_ARR(d, s, posSlotEncoder) \ + COPY_ARR(d, s, posEncoders) \ + (d)->lenProbs = (s)->lenProbs; \ + (d)->repLenProbs = (s)->repLenProbs; \ + memcpy((d)->litProbs, (s)->litProbs, ((size_t)0x300 * sizeof(CLzmaProb)) << (p)->lclp); + +void LzmaEnc_SaveState(CLzmaEncHandle p) { - CLzmaEnc *p = (CLzmaEnc *)pp; - CSaveState *dest = &p->saveState; - - dest->state = p->state; - - dest->lenProbs = p->lenProbs; - dest->repLenProbs = p->repLenProbs; + // GET_CLzmaEnc_p + CSaveState *v = &p->saveState; + COPY_LZMA_ENC_STATE(v, p, p) +} - COPY_ARR(dest, p, reps); - - COPY_ARR(dest, p, posAlignEncoder); - COPY_ARR(dest, p, isRep); - COPY_ARR(dest, p, isRepG0); - COPY_ARR(dest, p, isRepG1); - COPY_ARR(dest, p, isRepG2); - COPY_ARR(dest, p, isMatch); - COPY_ARR(dest, p, isRep0Long); - COPY_ARR(dest, p, posSlotEncoder); - COPY_ARR(dest, p, posEncoders); - - memcpy(dest->litProbs, p->litProbs, ((UInt32)0x300 << p->lclp) * sizeof(CLzmaProb)); +void LzmaEnc_RestoreState(CLzmaEncHandle p) +{ + // GET_CLzmaEnc_p + const CSaveState *v = &p->saveState; + COPY_LZMA_ENC_STATE(p, v, p) } -void LzmaEnc_RestoreState(CLzmaEncHandle pp) +Z7_NO_INLINE +SRes LzmaEnc_SetProps(CLzmaEncHandle p, const CLzmaEncProps *props2) { - CLzmaEnc *dest = (CLzmaEnc *)pp; - const CSaveState *p = &dest->saveState; - - dest->state = p->state; - - dest->lenProbs = p->lenProbs; - dest->repLenProbs = p->repLenProbs; - - COPY_ARR(dest, p, reps); - - COPY_ARR(dest, p, posAlignEncoder); - COPY_ARR(dest, p, isRep); - COPY_ARR(dest, p, isRepG0); - COPY_ARR(dest, p, isRepG1); - COPY_ARR(dest, p, isRepG2); - COPY_ARR(dest, p, isMatch); - COPY_ARR(dest, p, isRep0Long); - COPY_ARR(dest, p, posSlotEncoder); - COPY_ARR(dest, p, posEncoders); - - memcpy(dest->litProbs, p->litProbs, ((UInt32)0x300 << dest->lclp) * sizeof(CLzmaProb)); -} - - - -SRes LzmaEnc_SetProps(CLzmaEncHandle pp, const CLzmaEncProps *props2) -{ - CLzmaEnc *p = (CLzmaEnc *)pp; + // GET_CLzmaEnc_p CLzmaEncProps props = *props2; LzmaEncProps_Normalize(&props); @@ -585,6 +568,7 @@ SRes LzmaEnc_SetProps(CLzmaEncHandle pp, const CLzmaEncProps *props2) p->fastMode = (props.algo == 0); // p->_maxMode = True; MFB.btMode = (Byte)(props.btMode ? 1 : 0); + // MFB.btMode = (Byte)(props.btMode); { unsigned numHashBytes = 4; if (props.btMode) @@ -595,13 +579,15 @@ SRes LzmaEnc_SetProps(CLzmaEncHandle pp, const CLzmaEncProps *props2) if (props.numHashBytes >= 5) numHashBytes = 5; MFB.numHashBytes = numHashBytes; + // MFB.numHashBytes_Min = 2; + MFB.numHashOutBits = (Byte)props.numHashOutBits; } MFB.cutValue = props.mc; p->writeEndMark = (BoolInt)props.writeEndMark; - #ifndef _7ZIP_ST + #ifndef Z7_ST /* if (newMultiThread != _multiThread) { @@ -618,9 +604,9 @@ SRes LzmaEnc_SetProps(CLzmaEncHandle pp, const CLzmaEncProps *props2) } -void LzmaEnc_SetDataSize(CLzmaEncHandle pp, UInt64 expectedDataSiize) +void LzmaEnc_SetDataSize(CLzmaEncHandle p, UInt64 expectedDataSiize) { - CLzmaEnc *p = (CLzmaEnc *)pp; + // GET_CLzmaEnc_p MFB.expectedDataSize = expectedDataSiize; } @@ -684,7 +670,7 @@ static void RangeEnc_Init(CRangeEnc *p) p->res = SZ_OK; } -MY_NO_INLINE static void RangeEnc_FlushStream(CRangeEnc *p) +Z7_NO_INLINE static void RangeEnc_FlushStream(CRangeEnc *p) { const size_t num = (size_t)(p->buf - p->bufBase); if (p->res == SZ_OK) @@ -696,7 +682,7 @@ MY_NO_INLINE static void RangeEnc_FlushStream(CRangeEnc *p) p->buf = p->bufBase; } -MY_NO_INLINE static void MY_FAST_CALL RangeEnc_ShiftLow(CRangeEnc *p) +Z7_NO_INLINE static void Z7_FASTCALL RangeEnc_ShiftLow(CRangeEnc *p) { UInt32 low = (UInt32)p->low; unsigned high = (unsigned)(p->low >> 32); @@ -741,9 +727,9 @@ static void RangeEnc_FlushData(CRangeEnc *p) ttt = *(prob); \ newBound = (range >> kNumBitModelTotalBits) * ttt; -// #define _LZMA_ENC_USE_BRANCH +// #define Z7_LZMA_ENC_USE_BRANCH -#ifdef _LZMA_ENC_USE_BRANCH +#ifdef Z7_LZMA_ENC_USE_BRANCH #define RC_BIT(p, prob, bit) { \ RC_BIT_PRE(p, prob) \ @@ -811,7 +797,7 @@ static void LitEnc_Encode(CRangeEnc *p, CLzmaProb *probs, UInt32 sym) CLzmaProb *prob = probs + (sym >> 8); UInt32 bit = (sym >> 7) & 1; sym <<= 1; - RC_BIT(p, prob, bit); + RC_BIT(p, prob, bit) } while (sym < 0x10000); p->range = range; @@ -833,7 +819,7 @@ static void LitEnc_EncodeMatched(CRangeEnc *p, CLzmaProb *probs, UInt32 sym, UIn bit = (sym >> 7) & 1; sym <<= 1; offs &= ~(matchByte ^ sym); - RC_BIT(p, prob, bit); + RC_BIT(p, prob, bit) } while (sym < 0x10000); p->range = range; @@ -867,10 +853,10 @@ static void LzmaEnc_InitPriceTables(CProbPrice *ProbPrices) #define GET_PRICE(prob, bit) \ - p->ProbPrices[((prob) ^ (unsigned)(((-(int)(bit))) & (kBitModelTotal - 1))) >> kNumMoveReducingBits]; + p->ProbPrices[((prob) ^ (unsigned)(((-(int)(bit))) & (kBitModelTotal - 1))) >> kNumMoveReducingBits] #define GET_PRICEa(prob, bit) \ - ProbPrices[((prob) ^ (unsigned)((-((int)(bit))) & (kBitModelTotal - 1))) >> kNumMoveReducingBits]; + ProbPrices[((prob) ^ (unsigned)((-((int)(bit))) & (kBitModelTotal - 1))) >> kNumMoveReducingBits] #define GET_PRICE_0(prob) p->ProbPrices[(prob) >> kNumMoveReducingBits] #define GET_PRICE_1(prob) p->ProbPrices[((prob) ^ (kBitModelTotal - 1)) >> kNumMoveReducingBits] @@ -921,7 +907,7 @@ static void RcTree_ReverseEncode(CRangeEnc *rc, CLzmaProb *probs, unsigned numBi unsigned bit = sym & 1; // RangeEnc_EncodeBit(rc, probs + m, bit); sym >>= 1; - RC_BIT(rc, probs + m, bit); + RC_BIT(rc, probs + m, bit) m = (m << 1) | bit; } while (--numBits); @@ -944,15 +930,15 @@ static void LenEnc_Encode(CLenEnc *p, CRangeEnc *rc, unsigned sym, unsigned posS UInt32 range, ttt, newBound; CLzmaProb *probs = p->low; range = rc->range; - RC_BIT_PRE(rc, probs); + RC_BIT_PRE(rc, probs) if (sym >= kLenNumLowSymbols) { - RC_BIT_1(rc, probs); + RC_BIT_1(rc, probs) probs += kLenNumLowSymbols; - RC_BIT_PRE(rc, probs); + RC_BIT_PRE(rc, probs) if (sym >= kLenNumLowSymbols * 2) { - RC_BIT_1(rc, probs); + RC_BIT_1(rc, probs) rc->range = range; // RcTree_Encode(rc, p->high, kLenNumHighBits, sym - kLenNumLowSymbols * 2); LitEnc_Encode(rc, p->high, sym - kLenNumLowSymbols * 2); @@ -965,11 +951,11 @@ static void LenEnc_Encode(CLenEnc *p, CRangeEnc *rc, unsigned sym, unsigned posS { unsigned m; unsigned bit; - RC_BIT_0(rc, probs); + RC_BIT_0(rc, probs) probs += (posState << (1 + kLenNumLowBits)); - bit = (sym >> 2) ; RC_BIT(rc, probs + 1, bit); m = (1 << 1) + bit; - bit = (sym >> 1) & 1; RC_BIT(rc, probs + m, bit); m = (m << 1) + bit; - bit = sym & 1; RC_BIT(rc, probs + m, bit); + bit = (sym >> 2) ; RC_BIT(rc, probs + 1, bit) m = (1 << 1) + bit; + bit = (sym >> 1) & 1; RC_BIT(rc, probs + m, bit) m = (m << 1) + bit; + bit = sym & 1; RC_BIT(rc, probs + m, bit) rc->range = range; } } @@ -990,7 +976,7 @@ static void SetPrices_3(const CLzmaProb *probs, UInt32 startPrice, UInt32 *price } -MY_NO_INLINE static void MY_FAST_CALL LenPriceEnc_UpdateTables( +Z7_NO_INLINE static void Z7_FASTCALL LenPriceEnc_UpdateTables( CLenPriceEnc *p, unsigned numPosStates, const CLenEnc *enc, @@ -1054,14 +1040,14 @@ MY_NO_INLINE static void MY_FAST_CALL LenPriceEnc_UpdateTables( UInt32 price = b; do { - unsigned bit = sym & 1; + const unsigned bit = sym & 1; sym >>= 1; price += GET_PRICEa(probs[sym], bit); } while (sym >= 2); { - unsigned prob = probs[(size_t)i + (1 << (kLenNumHighBits - 1))]; + const unsigned prob = probs[(size_t)i + (1 << (kLenNumHighBits - 1))]; prices[(size_t)i * 2 ] = price + GET_PRICEa_0(prob); prices[(size_t)i * 2 + 1] = price + GET_PRICEa_1(prob); } @@ -1070,7 +1056,7 @@ MY_NO_INLINE static void MY_FAST_CALL LenPriceEnc_UpdateTables( { unsigned posState; - size_t num = (p->tableSize - kLenNumLowSymbols * 2) * sizeof(p->prices[0][0]); + const size_t num = (p->tableSize - kLenNumLowSymbols * 2) * sizeof(p->prices[0][0]); for (posState = 1; posState < numPosStates; posState++) memcpy(p->prices[posState] + kLenNumLowSymbols * 2, p->prices[0] + kLenNumLowSymbols * 2, num); } @@ -1152,7 +1138,7 @@ static unsigned ReadMatchDistances(CLzmaEnc *p, unsigned *numPairsRes) + GET_PRICE_1(p->isRep[state]) \ + GET_PRICE_0(p->isRepG0[state]) -MY_FORCE_INLINE +Z7_FORCE_INLINE static UInt32 GetPrice_PureRep(const CLzmaEnc *p, unsigned repIndex, size_t state, size_t posState) { UInt32 price; @@ -1331,7 +1317,7 @@ static unsigned GetOptimum(CLzmaEnc *p, UInt32 position) LitEnc_GetPrice(probs, curByte, p->ProbPrices)); } - MakeAs_Lit(&p->opt[1]); + MakeAs_Lit(&p->opt[1]) matchPrice = GET_PRICE_1(p->isMatch[p->state][posState]); repMatchPrice = matchPrice + GET_PRICE_1(p->isRep[p->state]); @@ -1343,7 +1329,7 @@ static unsigned GetOptimum(CLzmaEnc *p, UInt32 position) if (shortRepPrice < p->opt[1].price) { p->opt[1].price = shortRepPrice; - MakeAs_ShortRep(&p->opt[1]); + MakeAs_ShortRep(&p->opt[1]) } if (last < 2) { @@ -1410,7 +1396,7 @@ static unsigned GetOptimum(CLzmaEnc *p, UInt32 position) else { unsigned slot; - GetPosSlot2(dist, slot); + GetPosSlot2(dist, slot) price += p->alignPrices[dist & kAlignMask]; price += p->posSlotPrices[lenToPosState][slot]; } @@ -1486,7 +1472,7 @@ static unsigned GetOptimum(CLzmaEnc *p, UInt32 position) unsigned delta = best - cur; if (delta != 0) { - MOVE_POS(p, delta); + MOVE_POS(p, delta) } } cur = best; @@ -1633,7 +1619,7 @@ static unsigned GetOptimum(CLzmaEnc *p, UInt32 position) { nextOpt->price = litPrice; nextOpt->len = 1; - MakeAs_Lit(nextOpt); + MakeAs_Lit(nextOpt) nextIsLit = True; } } @@ -1667,7 +1653,7 @@ static unsigned GetOptimum(CLzmaEnc *p, UInt32 position) { nextOpt->price = shortRepPrice; nextOpt->len = 1; - MakeAs_ShortRep(nextOpt); + MakeAs_ShortRep(nextOpt) nextIsLit = False; } } @@ -1871,7 +1857,7 @@ static unsigned GetOptimum(CLzmaEnc *p, UInt32 position) dist = MATCHES[(size_t)offs + 1]; // if (dist >= kNumFullDistances) - GetPosSlot2(dist, posSlot); + GetPosSlot2(dist, posSlot) for (len = /*2*/ startLen; ; len++) { @@ -1962,7 +1948,7 @@ static unsigned GetOptimum(CLzmaEnc *p, UInt32 position) break; dist = MATCHES[(size_t)offs + 1]; // if (dist >= kNumFullDistances) - GetPosSlot2(dist, posSlot); + GetPosSlot2(dist, posSlot) } } } @@ -2138,7 +2124,7 @@ static void WriteEndMarker(CLzmaEnc *p, unsigned posState) { UInt32 ttt, newBound; RC_BIT_PRE(p, probs + m) - RC_BIT_1(&p->rc, probs + m); + RC_BIT_1(&p->rc, probs + m) m = (m << 1) + 1; } while (m < (1 << kNumPosSlotBits)); @@ -2163,7 +2149,7 @@ static void WriteEndMarker(CLzmaEnc *p, unsigned posState) { UInt32 ttt, newBound; RC_BIT_PRE(p, probs + m) - RC_BIT_1(&p->rc, probs + m); + RC_BIT_1(&p->rc, probs + m) m = (m << 1) + 1; } while (m < kAlignTableSize); @@ -2179,7 +2165,7 @@ static SRes CheckErrors(CLzmaEnc *p) if (p->rc.res != SZ_OK) p->result = SZ_ERROR_WRITE; - #ifndef _7ZIP_ST + #ifndef Z7_ST if ( // p->mf_Failure || (p->mtMode && @@ -2187,7 +2173,7 @@ static SRes CheckErrors(CLzmaEnc *p) p->matchFinderMt.failure_LZ_BT)) ) { - p->result = MY_HRES_ERROR__INTERNAL_ERROR; + p->result = MY_HRES_ERROR_INTERNAL_ERROR; // printf("\nCheckErrors p->matchFinderMt.failureLZ\n"); } #endif @@ -2201,7 +2187,7 @@ static SRes CheckErrors(CLzmaEnc *p) } -MY_NO_INLINE static SRes Flush(CLzmaEnc *p, UInt32 nowPos) +Z7_NO_INLINE static SRes Flush(CLzmaEnc *p, UInt32 nowPos) { /* ReleaseMFStream(); */ p->finished = True; @@ -2213,7 +2199,7 @@ MY_NO_INLINE static SRes Flush(CLzmaEnc *p, UInt32 nowPos) } -MY_NO_INLINE static void FillAlignPrices(CLzmaEnc *p) +Z7_NO_INLINE static void FillAlignPrices(CLzmaEnc *p) { unsigned i; const CProbPrice *ProbPrices = p->ProbPrices; @@ -2237,7 +2223,7 @@ MY_NO_INLINE static void FillAlignPrices(CLzmaEnc *p) } -MY_NO_INLINE static void FillDistancesPrices(CLzmaEnc *p) +Z7_NO_INLINE static void FillDistancesPrices(CLzmaEnc *p) { // int y; for (y = 0; y < 100; y++) { @@ -2337,7 +2323,7 @@ static void LzmaEnc_Construct(CLzmaEnc *p) RangeEnc_Construct(&p->rc); MatchFinder_Construct(&MFB); - #ifndef _7ZIP_ST + #ifndef Z7_ST p->matchFinderMt.MatchFinder = &MFB; MatchFinderMt_Construct(&p->matchFinderMt); #endif @@ -2345,7 +2331,7 @@ static void LzmaEnc_Construct(CLzmaEnc *p) { CLzmaEncProps props; LzmaEncProps_Init(&props); - LzmaEnc_SetProps(p, &props); + LzmaEnc_SetProps((CLzmaEncHandle)(void *)p, &props); } #ifndef LZMA_LOG_BSR @@ -2376,7 +2362,7 @@ static void LzmaEnc_FreeLits(CLzmaEnc *p, ISzAllocPtr alloc) static void LzmaEnc_Destruct(CLzmaEnc *p, ISzAllocPtr alloc, ISzAllocPtr allocBig) { - #ifndef _7ZIP_ST + #ifndef Z7_ST MatchFinderMt_Destruct(&p->matchFinderMt, allocBig); #endif @@ -2387,21 +2373,22 @@ static void LzmaEnc_Destruct(CLzmaEnc *p, ISzAllocPtr alloc, ISzAllocPtr allocBi void LzmaEnc_Destroy(CLzmaEncHandle p, ISzAllocPtr alloc, ISzAllocPtr allocBig) { - LzmaEnc_Destruct((CLzmaEnc *)p, alloc, allocBig); + // GET_CLzmaEnc_p + LzmaEnc_Destruct(p, alloc, allocBig); ISzAlloc_Free(alloc, p); } -MY_NO_INLINE +Z7_NO_INLINE static SRes LzmaEnc_CodeOneBlock(CLzmaEnc *p, UInt32 maxPackSize, UInt32 maxUnpackSize) { UInt32 nowPos32, startPos32; if (p->needInit) { - #ifndef _7ZIP_ST + #ifndef Z7_ST if (p->mtMode) { - RINOK(MatchFinderMt_InitMt(&p->matchFinderMt)); + RINOK(MatchFinderMt_InitMt(&p->matchFinderMt)) } #endif p->matchFinder.Init(p->matchFinderObj); @@ -2410,7 +2397,7 @@ static SRes LzmaEnc_CodeOneBlock(CLzmaEnc *p, UInt32 maxPackSize, UInt32 maxUnpa if (p->finished) return p->result; - RINOK(CheckErrors(p)); + RINOK(CheckErrors(p)) nowPos32 = (UInt32)p->nowPos64; startPos32 = nowPos32; @@ -2473,7 +2460,7 @@ static SRes LzmaEnc_CodeOneBlock(CLzmaEnc *p, UInt32 maxPackSize, UInt32 maxUnpa const Byte *data; unsigned state; - RC_BIT_0(&p->rc, probs); + RC_BIT_0(&p->rc, probs) p->rc.range = range; data = p->matchFinder.GetPointerToCurrentPos(p->matchFinderObj) - p->additionalOffset; probs = LIT_PROBS(nowPos32, *(data - 1)); @@ -2487,53 +2474,53 @@ static SRes LzmaEnc_CodeOneBlock(CLzmaEnc *p, UInt32 maxPackSize, UInt32 maxUnpa } else { - RC_BIT_1(&p->rc, probs); + RC_BIT_1(&p->rc, probs) probs = &p->isRep[p->state]; RC_BIT_PRE(&p->rc, probs) if (dist < LZMA_NUM_REPS) { - RC_BIT_1(&p->rc, probs); + RC_BIT_1(&p->rc, probs) probs = &p->isRepG0[p->state]; RC_BIT_PRE(&p->rc, probs) if (dist == 0) { - RC_BIT_0(&p->rc, probs); + RC_BIT_0(&p->rc, probs) probs = &p->isRep0Long[p->state][posState]; RC_BIT_PRE(&p->rc, probs) if (len != 1) { - RC_BIT_1_BASE(&p->rc, probs); + RC_BIT_1_BASE(&p->rc, probs) } else { - RC_BIT_0_BASE(&p->rc, probs); + RC_BIT_0_BASE(&p->rc, probs) p->state = kShortRepNextStates[p->state]; } } else { - RC_BIT_1(&p->rc, probs); + RC_BIT_1(&p->rc, probs) probs = &p->isRepG1[p->state]; RC_BIT_PRE(&p->rc, probs) if (dist == 1) { - RC_BIT_0_BASE(&p->rc, probs); + RC_BIT_0_BASE(&p->rc, probs) dist = p->reps[1]; } else { - RC_BIT_1(&p->rc, probs); + RC_BIT_1(&p->rc, probs) probs = &p->isRepG2[p->state]; RC_BIT_PRE(&p->rc, probs) if (dist == 2) { - RC_BIT_0_BASE(&p->rc, probs); + RC_BIT_0_BASE(&p->rc, probs) dist = p->reps[2]; } else { - RC_BIT_1_BASE(&p->rc, probs); + RC_BIT_1_BASE(&p->rc, probs) dist = p->reps[3]; p->reps[3] = p->reps[2]; } @@ -2557,7 +2544,7 @@ static SRes LzmaEnc_CodeOneBlock(CLzmaEnc *p, UInt32 maxPackSize, UInt32 maxUnpa else { unsigned posSlot; - RC_BIT_0(&p->rc, probs); + RC_BIT_0(&p->rc, probs) p->rc.range = range; p->state = kMatchNextStates[p->state]; @@ -2571,7 +2558,7 @@ static SRes LzmaEnc_CodeOneBlock(CLzmaEnc *p, UInt32 maxPackSize, UInt32 maxUnpa p->reps[0] = dist + 1; p->matchPriceCount++; - GetPosSlot(dist, posSlot); + GetPosSlot(dist, posSlot) // RcTree_Encode_PosSlot(&p->rc, p->posSlotEncoder[GetLenToPosState(len)], posSlot); { UInt32 sym = (UInt32)posSlot + (1 << kNumPosSlotBits); @@ -2582,7 +2569,7 @@ static SRes LzmaEnc_CodeOneBlock(CLzmaEnc *p, UInt32 maxPackSize, UInt32 maxUnpa CLzmaProb *prob = probs + (sym >> kNumPosSlotBits); UInt32 bit = (sym >> (kNumPosSlotBits - 1)) & 1; sym <<= 1; - RC_BIT(&p->rc, prob, bit); + RC_BIT(&p->rc, prob, bit) } while (sym < (1 << kNumPosSlotBits * 2)); p->rc.range = range; @@ -2626,10 +2613,10 @@ static SRes LzmaEnc_CodeOneBlock(CLzmaEnc *p, UInt32 maxPackSize, UInt32 maxUnpa { unsigned m = 1; unsigned bit; - bit = dist & 1; dist >>= 1; RC_BIT(&p->rc, p->posAlignEncoder + m, bit); m = (m << 1) + bit; - bit = dist & 1; dist >>= 1; RC_BIT(&p->rc, p->posAlignEncoder + m, bit); m = (m << 1) + bit; - bit = dist & 1; dist >>= 1; RC_BIT(&p->rc, p->posAlignEncoder + m, bit); m = (m << 1) + bit; - bit = dist & 1; RC_BIT(&p->rc, p->posAlignEncoder + m, bit); + bit = dist & 1; dist >>= 1; RC_BIT(&p->rc, p->posAlignEncoder + m, bit) m = (m << 1) + bit; + bit = dist & 1; dist >>= 1; RC_BIT(&p->rc, p->posAlignEncoder + m, bit) m = (m << 1) + bit; + bit = dist & 1; dist >>= 1; RC_BIT(&p->rc, p->posAlignEncoder + m, bit) m = (m << 1) + bit; + bit = dist & 1; RC_BIT(&p->rc, p->posAlignEncoder + m, bit) p->rc.range = range; // p->alignPriceCount++; } @@ -2704,17 +2691,17 @@ static SRes LzmaEnc_Alloc(CLzmaEnc *p, UInt32 keepWindowSize, ISzAllocPtr alloc, if (!RangeEnc_Alloc(&p->rc, alloc)) return SZ_ERROR_MEM; - #ifndef _7ZIP_ST + #ifndef Z7_ST p->mtMode = (p->multiThread && !p->fastMode && (MFB.btMode != 0)); #endif { - unsigned lclp = p->lc + p->lp; + const unsigned lclp = p->lc + p->lp; if (!p->litProbs || !p->saveState.litProbs || p->lclp != lclp) { LzmaEnc_FreeLits(p, alloc); - p->litProbs = (CLzmaProb *)ISzAlloc_Alloc(alloc, ((UInt32)0x300 << lclp) * sizeof(CLzmaProb)); - p->saveState.litProbs = (CLzmaProb *)ISzAlloc_Alloc(alloc, ((UInt32)0x300 << lclp) * sizeof(CLzmaProb)); + p->litProbs = (CLzmaProb *)ISzAlloc_Alloc(alloc, ((size_t)0x300 * sizeof(CLzmaProb)) << lclp); + p->saveState.litProbs = (CLzmaProb *)ISzAlloc_Alloc(alloc, ((size_t)0x300 * sizeof(CLzmaProb)) << lclp); if (!p->litProbs || !p->saveState.litProbs) { LzmaEnc_FreeLits(p, alloc); @@ -2748,15 +2735,14 @@ static SRes LzmaEnc_Alloc(CLzmaEnc *p, UInt32 keepWindowSize, ISzAllocPtr alloc, (numFastBytes + LZMA_MATCH_LEN_MAX + 1) */ - #ifndef _7ZIP_ST + #ifndef Z7_ST if (p->mtMode) { RINOK(MatchFinderMt_Create(&p->matchFinderMt, dictSize, beforeSize, p->numFastBytes, LZMA_MATCH_LEN_MAX + 1 /* 18.04 */ - , allocBig)); + , allocBig)) p->matchFinderObj = &p->matchFinderMt; - MFB.bigHash = (Byte)( - (p->dictSize > kBigHashDicLimit && MFB.hashMask >= 0xFFFFFF) ? 1 : 0); + MFB.bigHash = (Byte)(MFB.hashMask >= 0xFFFFFF ? 1 : 0); MatchFinderMt_CreateVTable(&p->matchFinderMt, &p->matchFinder); } else @@ -2816,8 +2802,8 @@ static void LzmaEnc_Init(CLzmaEnc *p) } { - UInt32 num = (UInt32)0x300 << (p->lp + p->lc); - UInt32 k; + const size_t num = (size_t)0x300 << (p->lp + p->lc); + size_t k; CLzmaProb *probs = p->litProbs; for (k = 0; k < num; k++) probs[k] = kProbInitValue; @@ -2872,59 +2858,53 @@ static SRes LzmaEnc_AllocAndInit(CLzmaEnc *p, UInt32 keepWindowSize, ISzAllocPtr p->finished = False; p->result = SZ_OK; - RINOK(LzmaEnc_Alloc(p, keepWindowSize, alloc, allocBig)); + p->nowPos64 = 0; + p->needInit = 1; + RINOK(LzmaEnc_Alloc(p, keepWindowSize, alloc, allocBig)) LzmaEnc_Init(p); LzmaEnc_InitPrices(p); - p->nowPos64 = 0; return SZ_OK; } -static SRes LzmaEnc_Prepare(CLzmaEncHandle pp, ISeqOutStream *outStream, ISeqInStream *inStream, +static SRes LzmaEnc_Prepare(CLzmaEncHandle p, + ISeqOutStreamPtr outStream, + ISeqInStreamPtr inStream, ISzAllocPtr alloc, ISzAllocPtr allocBig) { - CLzmaEnc *p = (CLzmaEnc *)pp; - MFB.stream = inStream; - p->needInit = 1; + // GET_CLzmaEnc_p + MatchFinder_SET_STREAM(&MFB, inStream) p->rc.outStream = outStream; return LzmaEnc_AllocAndInit(p, 0, alloc, allocBig); } -SRes LzmaEnc_PrepareForLzma2(CLzmaEncHandle pp, - ISeqInStream *inStream, UInt32 keepWindowSize, +SRes LzmaEnc_PrepareForLzma2(CLzmaEncHandle p, + ISeqInStreamPtr inStream, UInt32 keepWindowSize, ISzAllocPtr alloc, ISzAllocPtr allocBig) { - CLzmaEnc *p = (CLzmaEnc *)pp; - MFB.stream = inStream; - p->needInit = 1; + // GET_CLzmaEnc_p + MatchFinder_SET_STREAM(&MFB, inStream) return LzmaEnc_AllocAndInit(p, keepWindowSize, alloc, allocBig); } -static void LzmaEnc_SetInputBuf(CLzmaEnc *p, const Byte *src, SizeT srcLen) +SRes LzmaEnc_MemPrepare(CLzmaEncHandle p, + const Byte *src, SizeT srcLen, + UInt32 keepWindowSize, + ISzAllocPtr alloc, ISzAllocPtr allocBig) { - MFB.directInput = 1; - MFB.bufferBase = (Byte *)src; - MFB.directInputRem = srcLen; -} - -SRes LzmaEnc_MemPrepare(CLzmaEncHandle pp, const Byte *src, SizeT srcLen, - UInt32 keepWindowSize, ISzAllocPtr alloc, ISzAllocPtr allocBig) -{ - CLzmaEnc *p = (CLzmaEnc *)pp; - LzmaEnc_SetInputBuf(p, src, srcLen); - p->needInit = 1; - - LzmaEnc_SetDataSize(pp, srcLen); + // GET_CLzmaEnc_p + MatchFinder_SET_DIRECT_INPUT_BUF(&MFB, src, srcLen) + LzmaEnc_SetDataSize(p, srcLen); return LzmaEnc_AllocAndInit(p, keepWindowSize, alloc, allocBig); } -void LzmaEnc_Finish(CLzmaEncHandle pp) +void LzmaEnc_Finish(CLzmaEncHandle p) { - #ifndef _7ZIP_ST - CLzmaEnc *p = (CLzmaEnc *)pp; + #ifndef Z7_ST + // GET_CLzmaEnc_p if (p->mtMode) MatchFinderMt_ReleaseStream(&p->matchFinderMt); #else - UNUSED_VAR(pp); + UNUSED_VAR(p) #endif } @@ -2933,13 +2913,13 @@ typedef struct { ISeqOutStream vt; Byte *data; - SizeT rem; + size_t rem; BoolInt overflow; } CLzmaEnc_SeqOutStreamBuf; -static size_t SeqOutStreamBuf_Write(const ISeqOutStream *pp, const void *data, size_t size) +static size_t SeqOutStreamBuf_Write(ISeqOutStreamPtr pp, const void *data, size_t size) { - CLzmaEnc_SeqOutStreamBuf *p = CONTAINER_FROM_VTBL(pp, CLzmaEnc_SeqOutStreamBuf, vt); + Z7_CONTAINER_FROM_VTBL_TO_DECL_VAR_pp_vt_p(CLzmaEnc_SeqOutStreamBuf) if (p->rem < size) { size = p->rem; @@ -2956,25 +2936,25 @@ static size_t SeqOutStreamBuf_Write(const ISeqOutStream *pp, const void *data, s /* -UInt32 LzmaEnc_GetNumAvailableBytes(CLzmaEncHandle pp) +UInt32 LzmaEnc_GetNumAvailableBytes(CLzmaEncHandle p) { - const CLzmaEnc *p = (CLzmaEnc *)pp; + GET_const_CLzmaEnc_p return p->matchFinder.GetNumAvailableBytes(p->matchFinderObj); } */ -const Byte *LzmaEnc_GetCurBuf(CLzmaEncHandle pp) +const Byte *LzmaEnc_GetCurBuf(CLzmaEncHandle p) { - const CLzmaEnc *p = (CLzmaEnc *)pp; + // GET_const_CLzmaEnc_p return p->matchFinder.GetPointerToCurrentPos(p->matchFinderObj) - p->additionalOffset; } // (desiredPackSize == 0) is not allowed -SRes LzmaEnc_CodeOneMemBlock(CLzmaEncHandle pp, BoolInt reInit, +SRes LzmaEnc_CodeOneMemBlock(CLzmaEncHandle p, BoolInt reInit, Byte *dest, size_t *destLen, UInt32 desiredPackSize, UInt32 *unpackSize) { - CLzmaEnc *p = (CLzmaEnc *)pp; + // GET_CLzmaEnc_p UInt64 nowPos64; SRes res; CLzmaEnc_SeqOutStreamBuf outStream; @@ -3006,12 +2986,12 @@ SRes LzmaEnc_CodeOneMemBlock(CLzmaEncHandle pp, BoolInt reInit, } -MY_NO_INLINE -static SRes LzmaEnc_Encode2(CLzmaEnc *p, ICompressProgress *progress) +Z7_NO_INLINE +static SRes LzmaEnc_Encode2(CLzmaEnc *p, ICompressProgressPtr progress) { SRes res = SZ_OK; - #ifndef _7ZIP_ST + #ifndef Z7_ST Byte allocaDummy[0x300]; allocaDummy[0] = 0; allocaDummy[1] = allocaDummy[0]; @@ -3033,7 +3013,7 @@ static SRes LzmaEnc_Encode2(CLzmaEnc *p, ICompressProgress *progress) } } - LzmaEnc_Finish(p); + LzmaEnc_Finish((CLzmaEncHandle)(void *)p); /* if (res == SZ_OK && !Inline_MatchFinder_IsFinishedOK(&MFB)) @@ -3045,21 +3025,22 @@ static SRes LzmaEnc_Encode2(CLzmaEnc *p, ICompressProgress *progress) } -SRes LzmaEnc_Encode(CLzmaEncHandle pp, ISeqOutStream *outStream, ISeqInStream *inStream, ICompressProgress *progress, +SRes LzmaEnc_Encode(CLzmaEncHandle p, ISeqOutStreamPtr outStream, ISeqInStreamPtr inStream, ICompressProgressPtr progress, ISzAllocPtr alloc, ISzAllocPtr allocBig) { - RINOK(LzmaEnc_Prepare(pp, outStream, inStream, alloc, allocBig)); - return LzmaEnc_Encode2((CLzmaEnc *)pp, progress); + // GET_CLzmaEnc_p + RINOK(LzmaEnc_Prepare(p, outStream, inStream, alloc, allocBig)) + return LzmaEnc_Encode2(p, progress); } -SRes LzmaEnc_WriteProperties(CLzmaEncHandle pp, Byte *props, SizeT *size) +SRes LzmaEnc_WriteProperties(CLzmaEncHandle p, Byte *props, SizeT *size) { if (*size < LZMA_PROPS_SIZE) return SZ_ERROR_PARAM; *size = LZMA_PROPS_SIZE; { - const CLzmaEnc *p = (const CLzmaEnc *)pp; + // GET_CLzmaEnc_p const UInt32 dictSize = p->dictSize; UInt32 v; props[0] = (Byte)((p->pb * 5 + p->lp) * 9 + p->lc); @@ -3083,23 +3064,24 @@ SRes LzmaEnc_WriteProperties(CLzmaEncHandle pp, Byte *props, SizeT *size) while (v < dictSize); } - SetUi32(props + 1, v); + SetUi32(props + 1, v) return SZ_OK; } } -unsigned LzmaEnc_IsWriteEndMark(CLzmaEncHandle pp) +unsigned LzmaEnc_IsWriteEndMark(CLzmaEncHandle p) { - return (unsigned)((CLzmaEnc *)pp)->writeEndMark; + // GET_CLzmaEnc_p + return (unsigned)p->writeEndMark; } -SRes LzmaEnc_MemEncode(CLzmaEncHandle pp, Byte *dest, SizeT *destLen, const Byte *src, SizeT srcLen, - int writeEndMark, ICompressProgress *progress, ISzAllocPtr alloc, ISzAllocPtr allocBig) +SRes LzmaEnc_MemEncode(CLzmaEncHandle p, Byte *dest, SizeT *destLen, const Byte *src, SizeT srcLen, + int writeEndMark, ICompressProgressPtr progress, ISzAllocPtr alloc, ISzAllocPtr allocBig) { SRes res; - CLzmaEnc *p = (CLzmaEnc *)pp; + // GET_CLzmaEnc_p CLzmaEnc_SeqOutStreamBuf outStream; @@ -3111,7 +3093,7 @@ SRes LzmaEnc_MemEncode(CLzmaEncHandle pp, Byte *dest, SizeT *destLen, const Byte p->writeEndMark = writeEndMark; p->rc.outStream = &outStream.vt; - res = LzmaEnc_MemPrepare(pp, src, srcLen, 0, alloc, allocBig); + res = LzmaEnc_MemPrepare(p, src, srcLen, 0, alloc, allocBig); if (res == SZ_OK) { @@ -3120,7 +3102,7 @@ SRes LzmaEnc_MemEncode(CLzmaEncHandle pp, Byte *dest, SizeT *destLen, const Byte res = SZ_ERROR_FAIL; } - *destLen -= outStream.rem; + *destLen -= (SizeT)outStream.rem; if (outStream.overflow) return SZ_ERROR_OUTPUT_EOF; return res; @@ -3129,9 +3111,9 @@ SRes LzmaEnc_MemEncode(CLzmaEncHandle pp, Byte *dest, SizeT *destLen, const Byte SRes LzmaEncode(Byte *dest, SizeT *destLen, const Byte *src, SizeT srcLen, const CLzmaEncProps *props, Byte *propsEncoded, SizeT *propsSize, int writeEndMark, - ICompressProgress *progress, ISzAllocPtr alloc, ISzAllocPtr allocBig) + ICompressProgressPtr progress, ISzAllocPtr alloc, ISzAllocPtr allocBig) { - CLzmaEnc *p = (CLzmaEnc *)LzmaEnc_Create(alloc); + CLzmaEncHandle p = LzmaEnc_Create(alloc); SRes res; if (!p) return SZ_ERROR_MEM; @@ -3151,10 +3133,10 @@ SRes LzmaEncode(Byte *dest, SizeT *destLen, const Byte *src, SizeT srcLen, /* -#ifndef _7ZIP_ST -void LzmaEnc_GetLzThreads(CLzmaEncHandle pp, HANDLE lz_threads[2]) +#ifndef Z7_ST +void LzmaEnc_GetLzThreads(CLzmaEncHandle p, HANDLE lz_threads[2]) { - const CLzmaEnc *p = (CLzmaEnc *)pp; + GET_const_CLzmaEnc_p lz_threads[0] = p->matchFinderMt.hashSync.thread; lz_threads[1] = p->matchFinderMt.btSync.thread; } diff --git a/common/LZMA/SDK/C/LzmaEnc.h b/common/LZMA/SDK/C/LzmaEnc.h index bc2ed50..9f8039a 100644 --- a/common/LZMA/SDK/C/LzmaEnc.h +++ b/common/LZMA/SDK/C/LzmaEnc.h @@ -1,8 +1,8 @@ /* LzmaEnc.h -- LZMA Encoder -2019-10-30 : Igor Pavlov : Public domain */ +2023-04-13 : Igor Pavlov : Public domain */ -#ifndef __LZMA_ENC_H -#define __LZMA_ENC_H +#ifndef ZIP7_INC_LZMA_ENC_H +#define ZIP7_INC_LZMA_ENC_H #include "7zTypes.h" @@ -10,7 +10,7 @@ EXTERN_C_BEGIN #define LZMA_PROPS_SIZE 5 -typedef struct _CLzmaEncProps +typedef struct { int level; /* 0 <= level <= 9 */ UInt32 dictSize; /* (1 << 12) <= dictSize <= (1 << 27) for 32-bit version @@ -23,10 +23,13 @@ typedef struct _CLzmaEncProps int fb; /* 5 <= fb <= 273, default = 32 */ int btMode; /* 0 - hashChain Mode, 1 - binTree mode - normal, default = 1 */ int numHashBytes; /* 2, 3 or 4, default = 4 */ + unsigned numHashOutBits; /* default = ? */ UInt32 mc; /* 1 <= mc <= (1 << 30), default = 32 */ unsigned writeEndMark; /* 0 - do not write EOPM, 1 - write EOPM, default = 0 */ int numThreads; /* 1 or 2, default = 2 */ + // int _pad; + UInt64 reduceSize; /* estimated size of data that will be compressed. default = (UInt64)(Int64)-1. Encoder uses this value to reduce dictionary size */ @@ -51,7 +54,9 @@ SRes: SZ_ERROR_THREAD - error in multithreading functions (only for Mt version) */ -typedef void * CLzmaEncHandle; +typedef struct CLzmaEnc CLzmaEnc; +typedef CLzmaEnc * CLzmaEncHandle; +// Z7_DECLARE_HANDLE(CLzmaEncHandle) CLzmaEncHandle LzmaEnc_Create(ISzAllocPtr alloc); void LzmaEnc_Destroy(CLzmaEncHandle p, ISzAllocPtr alloc, ISzAllocPtr allocBig); @@ -61,17 +66,17 @@ void LzmaEnc_SetDataSize(CLzmaEncHandle p, UInt64 expectedDataSiize); SRes LzmaEnc_WriteProperties(CLzmaEncHandle p, Byte *properties, SizeT *size); unsigned LzmaEnc_IsWriteEndMark(CLzmaEncHandle p); -SRes LzmaEnc_Encode(CLzmaEncHandle p, ISeqOutStream *outStream, ISeqInStream *inStream, - ICompressProgress *progress, ISzAllocPtr alloc, ISzAllocPtr allocBig); +SRes LzmaEnc_Encode(CLzmaEncHandle p, ISeqOutStreamPtr outStream, ISeqInStreamPtr inStream, + ICompressProgressPtr progress, ISzAllocPtr alloc, ISzAllocPtr allocBig); SRes LzmaEnc_MemEncode(CLzmaEncHandle p, Byte *dest, SizeT *destLen, const Byte *src, SizeT srcLen, - int writeEndMark, ICompressProgress *progress, ISzAllocPtr alloc, ISzAllocPtr allocBig); + int writeEndMark, ICompressProgressPtr progress, ISzAllocPtr alloc, ISzAllocPtr allocBig); /* ---------- One Call Interface ---------- */ SRes LzmaEncode(Byte *dest, SizeT *destLen, const Byte *src, SizeT srcLen, const CLzmaEncProps *props, Byte *propsEncoded, SizeT *propsSize, int writeEndMark, - ICompressProgress *progress, ISzAllocPtr alloc, ISzAllocPtr allocBig); + ICompressProgressPtr progress, ISzAllocPtr alloc, ISzAllocPtr allocBig); EXTERN_C_END diff --git a/common/LZMA/SDK/C/Precomp.h b/common/LZMA/SDK/C/Precomp.h index fc663b6..98a0a33 100644 --- a/common/LZMA/SDK/C/Precomp.h +++ b/common/LZMA/SDK/C/Precomp.h @@ -1,12 +1,130 @@ -/* Precomp.h -- StdAfx -2013-11-12 : Igor Pavlov : Public domain */ +/* Precomp.h -- precompilation file +2024-01-25 : Igor Pavlov : Public domain */ -#ifndef __7Z_PRECOMP_H -#define __7Z_PRECOMP_H +#ifndef ZIP7_INC_PRECOMP_H +#define ZIP7_INC_PRECOMP_H + +/* + this file must be included before another *.h files and before . + this file is included from the following files: + C\*.c + C\Util\*\Precomp.h <- C\Util\*\*.c + CPP\Common\Common.h <- *\StdAfx.h <- *\*.cpp + + this file can set the following macros: + Z7_LARGE_PAGES 1 + Z7_LONG_PATH 1 + Z7_WIN32_WINNT_MIN 0x0500 (or higher) : we require at least win2000+ for 7-Zip + _WIN32_WINNT 0x0500 (or higher) + WINVER _WIN32_WINNT + UNICODE 1 + _UNICODE 1 +*/ #include "Compiler.h" -/* #include "7zTypes.h" */ -#define _7ZIP_ST +// UEFITool: use single-threaded LzFind +#define Z7_ST + +#ifdef _MSC_VER +// #pragma warning(disable : 4206) // nonstandard extension used : translation unit is empty +#if _MSC_VER >= 1912 +// #pragma warning(disable : 5039) // pointer or reference to potentially throwing function passed to 'extern "C"' function under - EHc.Undefined behavior may occur if this function throws an exception. +#endif +#endif + +/* +// for debug: +#define UNICODE 1 +#define _UNICODE 1 +#define _WIN32_WINNT 0x0500 // win2000 +#ifndef WINVER + #define WINVER _WIN32_WINNT +#endif +*/ + +#ifdef _WIN32 +/* + this "Precomp.h" file must be included before , + if we want to define _WIN32_WINNT before . +*/ + +#ifndef Z7_LARGE_PAGES +#ifndef Z7_NO_LARGE_PAGES +#define Z7_LARGE_PAGES 1 +#endif +#endif + +#ifndef Z7_LONG_PATH +#ifndef Z7_NO_LONG_PATH +#define Z7_LONG_PATH 1 +#endif +#endif + +#ifndef Z7_DEVICE_FILE +#ifndef Z7_NO_DEVICE_FILE +// #define Z7_DEVICE_FILE 1 +#endif +#endif + +// we don't change macros if included after +#ifndef _WINDOWS_ + +#ifndef Z7_WIN32_WINNT_MIN + #if defined(_M_ARM64) || defined(__aarch64__) + // #define Z7_WIN32_WINNT_MIN 0x0a00 // win10 + #define Z7_WIN32_WINNT_MIN 0x0600 // vista + #elif defined(_M_ARM) && defined(_M_ARMT) && defined(_M_ARM_NT) + // #define Z7_WIN32_WINNT_MIN 0x0602 // win8 + #define Z7_WIN32_WINNT_MIN 0x0600 // vista + #elif defined(_M_X64) || defined(_M_AMD64) || defined(__x86_64__) || defined(_M_IA64) + #define Z7_WIN32_WINNT_MIN 0x0503 // win2003 + // #elif defined(_M_IX86) || defined(__i386__) + // #define Z7_WIN32_WINNT_MIN 0x0500 // win2000 + #else // x86 and another(old) systems + #define Z7_WIN32_WINNT_MIN 0x0500 // win2000 + // #define Z7_WIN32_WINNT_MIN 0x0502 // win2003 // for debug + #endif +#endif // Z7_WIN32_WINNT_MIN + + +#ifndef Z7_DO_NOT_DEFINE_WIN32_WINNT +#ifdef _WIN32_WINNT + // #error Stop_Compiling_Bad_WIN32_WINNT +#else + #ifndef Z7_NO_DEFINE_WIN32_WINNT +Z7_DIAGNOSTIC_IGNORE_BEGIN_RESERVED_MACRO_IDENTIFIER + #define _WIN32_WINNT Z7_WIN32_WINNT_MIN +Z7_DIAGNOSTIC_IGNORE_END_RESERVED_MACRO_IDENTIFIER + #endif +#endif // _WIN32_WINNT + +#ifndef WINVER + #define WINVER _WIN32_WINNT +#endif +#endif // Z7_DO_NOT_DEFINE_WIN32_WINNT + + +#ifndef _MBCS +#ifndef Z7_NO_UNICODE +// UNICODE and _UNICODE are used by and by 7-zip code. + +#ifndef UNICODE +#define UNICODE 1 +#endif + +#ifndef _UNICODE +Z7_DIAGNOSTIC_IGNORE_BEGIN_RESERVED_MACRO_IDENTIFIER +#define _UNICODE 1 +Z7_DIAGNOSTIC_IGNORE_END_RESERVED_MACRO_IDENTIFIER +#endif + +#endif // Z7_NO_UNICODE +#endif // _MBCS +#endif // _WINDOWS_ + +// #include "7zWindows.h" + +#endif // _WIN32 #endif diff --git a/common/LZMA/SDK/C/RotateDefs.h b/common/LZMA/SDK/C/RotateDefs.h new file mode 100644 index 0000000..c16b4f8 --- /dev/null +++ b/common/LZMA/SDK/C/RotateDefs.h @@ -0,0 +1,50 @@ +/* RotateDefs.h -- Rotate functions +2023-06-18 : Igor Pavlov : Public domain */ + +#ifndef ZIP7_INC_ROTATE_DEFS_H +#define ZIP7_INC_ROTATE_DEFS_H + +#ifdef _MSC_VER + +#include + +/* don't use _rotl with old MINGW. It can insert slow call to function. */ + +/* #if (_MSC_VER >= 1200) */ +#pragma intrinsic(_rotl) +#pragma intrinsic(_rotr) +/* #endif */ + +#define rotlFixed(x, n) _rotl((x), (n)) +#define rotrFixed(x, n) _rotr((x), (n)) + +#if (_MSC_VER >= 1300) +#define Z7_ROTL64(x, n) _rotl64((x), (n)) +#define Z7_ROTR64(x, n) _rotr64((x), (n)) +#else +#define Z7_ROTL64(x, n) (((x) << (n)) | ((x) >> (64 - (n)))) +#define Z7_ROTR64(x, n) (((x) >> (n)) | ((x) << (64 - (n)))) +#endif + +#else + +/* new compilers can translate these macros to fast commands. */ + +#if defined(__clang__) && (__clang_major__ >= 4) \ + || defined(__GNUC__) && (__GNUC__ >= 5) +/* GCC 4.9.0 and clang 3.5 can recognize more correct version: */ +#define rotlFixed(x, n) (((x) << (n)) | ((x) >> (-(n) & 31))) +#define rotrFixed(x, n) (((x) >> (n)) | ((x) << (-(n) & 31))) +#define Z7_ROTL64(x, n) (((x) << (n)) | ((x) >> (-(n) & 63))) +#define Z7_ROTR64(x, n) (((x) >> (n)) | ((x) << (-(n) & 63))) +#else +/* for old GCC / clang: */ +#define rotlFixed(x, n) (((x) << (n)) | ((x) >> (32 - (n)))) +#define rotrFixed(x, n) (((x) >> (n)) | ((x) << (32 - (n)))) +#define Z7_ROTL64(x, n) (((x) << (n)) | ((x) >> (64 - (n)))) +#define Z7_ROTR64(x, n) (((x) >> (n)) | ((x) << (64 - (n)))) +#endif + +#endif + +#endif diff --git a/common/LZMA/UefiLzma.h b/common/LZMA/UefiLzma.h deleted file mode 100644 index 2ef4b0e..0000000 --- a/common/LZMA/UefiLzma.h +++ /dev/null @@ -1,31 +0,0 @@ -/* LZMA UEFI header file - - Copyright (c) 2009, Intel Corporation. All rights reserved. - This program and the accompanying materials - are licensed and made available under the terms and conditions of the BSD License - which accompanies this distribution. The full text of the license may be found at - http://opensource.org/licenses/bsd-license.php - - THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, - WITHWARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. - -*/ - -#ifndef __UEFILZMA_H__ -#define __UEFILZMA_H__ - -#include "../basetypes.h" - -#ifdef _WIN32 -#undef _WIN32 -#endif - -#ifdef _WIN64 -#undef _WIN64 -#endif - -#define _LZMA_SIZE_OPT -#define _7ZIP_ST - -#endif // __UEFILZMA_H__ - diff --git a/common/descriptor.cpp b/common/descriptor.cpp index db452c2..324b005 100644 --- a/common/descriptor.cpp +++ b/common/descriptor.cpp @@ -1,11 +1,11 @@ /* descriptor.cpp - + Copyright (c) 2015, Nikolaj Schlej. All rights reserved. This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at http://opensource.org/licenses/bsd-license.php - + THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, WITHWARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. */ @@ -72,7 +72,7 @@ UString jedecIdToUString(UINT8 vendorId, UINT8 deviceId0, UINT8 deviceId1) case 0xEF6019: return UString("Winbond W25Q256"); case 0xEF7118: return UString("Winbond W25M256"); case 0xEF7119: return UString("Winbond W25M512"); - + // Macronix case 0xC22013: return UString("Macronix MX25L40"); case 0xC22014: return UString("Macronix MX25L80"); @@ -94,8 +94,9 @@ UString jedecIdToUString(UINT8 vendorId, UINT8 deviceId0, UINT8 deviceId1) case 0xC22617: return UString("Macronix MX25L64"); case 0xC22618: return UString("Macronix MX25L128"); case 0xC25E16: return UString("Macronix MX25L32"); + case 0xC27518: return UString("Macronix MX77L12850F"); case 0xC29517: return UString("Macronix MX25L64"); - + // Micron case 0x202014: return UString("Micron M25P80"); case 0x202015: return UString("Micron M25P16"); @@ -110,6 +111,7 @@ UString jedecIdToUString(UINT8 vendorId, UINT8 deviceId0, UINT8 deviceId1) case 0x204017: return UString("Micron XM25QH64C"); case 0x204018: return UString("Micron XM25QH128C"); case 0x204019: return UString("Micron XM25QH256C"); + case 0x204318: return UString("Micron XM25RH128C"); case 0x207114: return UString("Micron M25PX80"); case 0x207115: return UString("Micron M25PX16"); case 0x207116: return UString("Micron M25PX32"); @@ -132,7 +134,7 @@ UString jedecIdToUString(UINT8 vendorId, UINT8 deviceId0, UINT8 deviceId1) case 0x20BB18: return UString("Micron MT25Q128"); case 0x20BB19: return UString("Micron MT25Q256"); case 0x20BB20: return UString("Micron MT25Q512"); - + // Intel case 0x898911: return UString("Intel 25F160S33B8"); case 0x898912: return UString("Intel 25F320S33B8"); @@ -140,7 +142,7 @@ UString jedecIdToUString(UINT8 vendorId, UINT8 deviceId0, UINT8 deviceId1) case 0x898915: return UString("Intel 25F160S33T8"); case 0x898916: return UString("Intel 25F320S33T8"); case 0x898917: return UString("Intel 25F640S33T8"); - + // Atmel / Adesto case 0x1F3217: return UString("Atmel AT25SF641"); case 0x1F4216: return UString("Atmel AT25SL321"); @@ -158,14 +160,14 @@ UString jedecIdToUString(UINT8 vendorId, UINT8 deviceId0, UINT8 deviceId1) case 0x1F7018: return UString("Atmel AT25QF128"); case 0x1F8600: return UString("Atmel AT25DQ161"); case 0x1F8800: return UString("Atmel AT25DQ641"); - + // Microchip case 0xBF2541: return UString("Microchip SST25VF016B"); case 0xBF254A: return UString("Microchip SST25VF032B"); case 0xBF258D: return UString("Microchip SST25VF040B"); case 0xBF258E: return UString("Microchip SST25VF080B"); case 0xBF254B: return UString("Microchip SST25VF064C"); - + // EON / ESMT case 0x1C3013: return UString("EON EN25Q40"); case 0x1C3014: return UString("EON EN25Q80"); @@ -190,7 +192,7 @@ UString jedecIdToUString(UINT8 vendorId, UINT8 deviceId0, UINT8 deviceId1) case 0x1C7017: return UString("EON EN25QH64"); case 0x1C7018: return UString("EON EN25QH128"); case 0x1C7019: return UString("EON EN25QH256"); - + // GigaDevice case 0xC84014: return UString("GigaDevice GD25x80"); case 0xC84015: return UString("GigaDevice GD25x16"); @@ -202,24 +204,25 @@ UString jedecIdToUString(UINT8 vendorId, UINT8 deviceId0, UINT8 deviceId1) case 0xC86017: return UString("GigaDevice GD25Lx64"); case 0xC86018: return UString("GigaDevice GD25Lx128"); case 0xC86019: return UString("GigaDevice GD25LQ256C"); - + // Fidelix case 0xF83215: return UString("Fidelix FM25Q16"); case 0xF83216: return UString("Fidelix FM25Q32"); case 0xF83217: return UString("Fidelix FM25Q64"); case 0xF83218: return UString("Fidelix FM25Q128"); - + // Spansion case 0x014015: return UString("Spansion S25FL116K"); case 0x014016: return UString("Spansion S25FL132K"); case 0x014017: return UString("Spansion S25FL164K"); - + // AMIC Technology case 0x373015: return UString("AMIC A25L016"); case 0x373016: return UString("AMIC A25L032"); case 0x374015: return UString("AMIC A25LQ16"); case 0x374016: return UString("AMIC A25LQ32A"); - + case 0x374017: return UString("AMIC A25LQ64"); + // PMC case 0x9DF713: return UString("PMC Pm25LV080B"); case 0x9DF714: return UString("PMC Pm25LV016B"); @@ -230,7 +233,7 @@ UString jedecIdToUString(UINT8 vendorId, UINT8 deviceId0, UINT8 deviceId1) case 0x9DF77C: return UString("PMC Pm25LV010A"); case 0x9DF77D: return UString("PMC Pm25LV020"); case 0x9DF77E: return UString("PMC Pm25LV040"); - + // ISSI case 0x9D6014: return UString("ISSI Ix25LP080"); case 0x9D6015: return UString("ISSI Ix25LP016"); @@ -245,6 +248,6 @@ UString jedecIdToUString(UINT8 vendorId, UINT8 deviceId0, UINT8 deviceId1) case 0x9D7018: return UString("ISSI Ix25WP128"); case 0x9D7019: return UString("ISSI Ix25WP256"); } - + return usprintf("Unknown %08Xh", jedecId); } diff --git a/common/descriptor.h b/common/descriptor.h index c4e04c7..0254ce4 100644 --- a/common/descriptor.h +++ b/common/descriptor.h @@ -72,43 +72,18 @@ typedef struct FLASH_DESCRIPTOR_MAP_ { UINT32 DescriptorVersion; // Reserved prior to Coffee Lake } FLASH_DESCRIPTOR_MAP; -// Component section +// Component section structure // Flash parameters DWORD structure typedef struct FLASH_PARAMETERS_ { - UINT8 FirstChipDensity : 4; - UINT8 SecondChipDensity : 4; - UINT8 : 8; + UINT16 : 16; UINT8 : 1; UINT8 ReadClockFrequency : 3; // Hardcoded value of 20 Mhz (000b) in v1 descriptors - UINT8 FastReadEnabled : 1; - UINT8 FastReadFrequency : 3; - UINT8 FlashWriteFrequency : 3; - UINT8 FlashReadStatusFrequency : 3; - UINT8 DualOutputFastReadSupported : 1; - UINT8 : 1; + UINT8 : 4; + UINT8 : 8; } FLASH_PARAMETERS; -// Flash densities -#define FLASH_DENSITY_512KB 0x00 -#define FLASH_DENSITY_1MB 0x01 -#define FLASH_DENSITY_2MB 0x02 -#define FLASH_DENSITY_4MB 0x03 -#define FLASH_DENSITY_8MB 0x04 -#define FLASH_DENSITY_16MB 0x05 -#define FLASH_DENSITY_32MB 0x06 -#define FLASH_DENSITY_64MB 0x07 -#define FLASH_DENSITY_UNUSED 0x0F - -// Flash frequencies -#define FLASH_FREQUENCY_20MHZ 0x00 -#define FLASH_FREQUENCY_33MHZ 0x01 -#define FLASH_FREQUENCY_48MHZ 0x02 -#define FLASH_FREQUENCY_50MHZ_30MHZ 0x04 -#define FLASH_FREQUENCY_17MHZ 0x06 - -// Component section structure typedef struct FLASH_DESCRIPTOR_COMPONENT_SECTION_ { - FLASH_PARAMETERS FlashParameters; + FLASH_PARAMETERS FlashParameters; // Bit field with SPI flash parameters, changes almost every CPU generation, so will remain mostly undefined for now UINT8 InvalidInstruction0; // Instructions for SPI chip, that must not be executed, like FLASH ERASE UINT8 InvalidInstruction1; // UINT8 InvalidInstruction2; // diff --git a/common/ffs.cpp b/common/ffs.cpp index 3025df1..c9b7ac2 100644 --- a/common/ffs.cpp +++ b/common/ffs.cpp @@ -81,6 +81,52 @@ extern const UByteArray AMI_CORE_DXE_GUID // 5AE3F37E-4EAE-41AE-8240-35465B5E81E // EDK2 DXE core file extern const UByteArray EFI_DXE_CORE_GUID // D6A2CB7F-6A18-4E2F-B43B-9920A733700A ("\x7F\xCB\xA2\xD6\x18\x6A\x2F\x4E\xB4\x3B\x99\x20\xA7\x33\x70\x0A", 16); +// AMD compressed raw file +extern const UByteArray AMD_COMPRESSED_RAW_FILE_GUID //20BC8AC9-94D1-4208-AB28-5D673FD73487 +("\xC9\x8A\xBC\x20\xD1\x94\x08\x42\xAB\x28\x5D\x67\x3F\xD7\x34\x87", 16); + +// Insyde Flash Device Map GUIDs +extern const UByteArray INSYDE_FLASH_MAP_REGION_BOOT_FV_GUID +("\x56\x6d\xd7\xe3\x8a\x98\x6b\x4d\x89\x13\x64\xf2\xdf\x1d\xf6\xa6", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_BVDT_GUID +("\xFC\x5D\x41\x32\x06\xD1\xC7\x48\x9E\xB5\x80\x6C\x11\x4D\xD1\x07", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_EC_GUID +("\xBF\xF3\x3E\xA7\xCC\x33\xA9\x43\xB3\x9C\xA9\x12\xC7\x48\x9A\x57", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_FTW_BACKUP_GUID +("\xD3\x15\x8E\xB7\xA5\xF0\x48\x42\x8E\x2F\xD3\x15\x7A\xEF\x88\x36", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_FTW_STATE_GUID +("\x04\x6E\x41\xC8\x34\x99\x79\x40\xBE\x9A\x39\xF8\xD6\x02\x84\x98", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_FV_GUID +("\x58\xE7\xE8\xB5\xE6\xA7\x8B\x4C\xAB\x85\xFF\x2A\x95\x9B\x99\xBA", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_FLASH_DEVICE_MAP_GUID +("\xA0\xC1\x78\xF0\x52\xFC\x3F\x4C\xBE\x1F\xD6\x88\x81\x5A\x62\xC0", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_LOGO_GUID +("\x69\xAB\xCF\xDA\x77\xF9\x84\x47\x8A\xD8\x77\x24\xA6\xF4\xB4\x40", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_MICROCODE_GUID +("\xF8\x66\x98\xB4\xD2\x8C\xE4\x49\xA1\x6D\xB6\x0F\xBE\xC3\x1C\x4B", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_MSDM_TABLE_GUID +("\x1A\xEB\x44\xB3\x7E\xF9\x14\x4F\xA1\xE1\x7E\x63\xBC\x40\xC8\xCE", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_MULTI_CONFIG_GUID +("\x92\xB5\x94\x59\x14\x2F\xD5\x48\xBB\x40\xBD\x27\x96\x9C\x77\x80", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_VAR_DEFAULT_GUID +("\xA2\xAC\xDD\xD9\x16\x08\xF3\x48\xAD\xED\x6B\x71\x65\x6B\x24\x8A", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_SMBIOS_UPDATE_GUID +("\xDC\xFE\x64\x89\xE7\x6F\x1E\x4E\xA5\x5E\xFF\x82\x1D\x71\xFF\xCF", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_VAR_GUID +("\x74\x53\x3C\x77\xD1\x81\x43\x4D\xB2\x93\xF3\xD7\x4F\x18\x1D\x6B", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_UNKNOWN_GUID +("\xE5\x65\x1D\x20\x23\xBE\x75\x48\x80\xF8\xB1\xD4\x79\x5E\x7E\x08", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_UNUSED_GUID +("\x20\xB0\xC8\x13\x27\x4F\x3B\x45\x8F\x80\x1B\xFC\xA1\x87\x38\x0F", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_USB_OPTION_ROM_GUID +("\x0F\xF3\x7B\x60\x2B\x5F\xA2\x4D\xAE\xED\x56\xF9\xBD\xCD\x2D\x21", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_DXE_FV_GUID +("\xCE\xBA\xD0\x1F\x0A\x6F\x85\x40\x90\x1E\xF6\x21\x03\x85\xCB\x6F", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_PEI_FV_GUID +("\xC5\x06\x14\xCF\xEC\x3F\xEB\x47\xA6\xC3\xB7\x1A\x3E\xE0\x0B\x95", 16); +extern const UByteArray INSYDE_FLASH_MAP_REGION_UNSIGNED_FV_GUID +("\xB6\x16\xA0\xF2\x14\xE8\x2E\x40\xA3\x95\x46\xD3\xCF\x75\x26\x4A", 16); + // GUIDs of GUID-defined sections extern const UByteArray EFI_GUIDED_SECTION_CRC32 // FC1BCDB0-7D31-49AA-936A-A4600D9DD083 ("\xB0\xCD\x1B\xFC\x31\x7D\xAA\x49\x93\x6A\xA4\x60\x0D\x9D\xD0\x83", 16); @@ -90,12 +136,16 @@ extern const UByteArray EFI_GUIDED_SECTION_LZMA // EE4E5898-3914-4259-9D6E-DC7BD ("\x98\x58\x4E\xEE\x14\x39\x59\x42\x9D\x6E\xDC\x7B\xD7\x94\x03\xCF", 16); extern const UByteArray EFI_GUIDED_SECTION_LZMA_HP // 0ED85E23-F253-413F-A03C-901987B04397 ("\x23\x5E\xD8\x0E\x53\xF2\x3F\x41\xA0\x3C\x90\x19\x87\xB0\x43\x97", 16); +extern const UByteArray EFI_GUIDED_SECTION_LZMA_MS // BD9921EA-ED91-404A-8B2F-B4D724747C8C +("\xEA\x21\x99\xBD\x91\xED\x4A\x40\x8B\x2F\xB4\xD7\x24\x74\x7C\x8C", 16); extern const UByteArray EFI_GUIDED_SECTION_LZMAF86 // D42AE6BD-1352-4BFB-909A-CA72A6EAE889 ("\xBD\xE6\x2A\xD4\x52\x13\xFB\x4B\x90\x9A\xCA\x72\xA6\xEA\xE8\x89", 16); extern const UByteArray EFI_GUIDED_SECTION_GZIP // 1D301FE9-BE79-4353-91C2-D23BC959AE0C ("\xE9\x1F\x30\x1D\x79\xBE\x53\x43\x91\xC2\xD2\x3B\xC9\x59\xAE\x0C", 16); extern const UByteArray EFI_GUIDED_SECTION_ZLIB_AMD // CE3233F5-2CD6-4D87-9152-4A238BB6D1C4 ("\xF5\x33\x32\xCE\xD6\x2C\x87\x4D\x91\x52\x4A\x23\x8B\xB6\xD1\xC4", 16); +extern const UByteArray EFI_GUIDED_SECTION_ZLIB_AMD2 // 991EFAC0-E260-416B-A4B8-3B153072B804 +("\xC0\xFA\x1E\x99\x60\xE2\x6B\x41\xA4\xB8\x3B\x15\x30\x72\xB8\x04", 16); extern const UByteArray EFI_FIRMWARE_CONTENTS_SIGNED_GUID // 0F9D89E8-9259-4F76-A5AF-0C89E34023DF ("\xE8\x89\x9D\x0F\x59\x92\x76\x4F\xA5\xAF\x0C\x89\xE3\x40\x23\xDF", 16); extern const UByteArray EFI_CERT_TYPE_RSA2048_SHA256_GUID // A7717414-C616-4977-9420-844712A735BF diff --git a/common/ffs.h b/common/ffs.h index eeb8c44..e515421 100644 --- a/common/ffs.h +++ b/common/ffs.h @@ -367,6 +367,9 @@ extern const UByteArray AMI_CORE_DXE_GUID; // 5AE3F37E-4EAE-41AE-8240-35465B5E81 // EDK2 DXE core file extern const UByteArray EFI_DXE_CORE_GUID; // D6A2CB7F-6A18-4E2F-B43B-9920A733700A +// AMD compressed raw file +extern const UByteArray AMD_COMPRESSED_RAW_FILE_GUID; //20BC8AC9-94D1-4208-AB28-5D673FD73487 + // FFS size conversion routines extern VOID uint32ToUint24(UINT32 size, UINT8* ffsSize); extern UINT32 uint24ToUint32(const UINT8* ffsSize); @@ -442,9 +445,11 @@ extern const UByteArray EFI_GUIDED_SECTION_CRC32; // FC1BCDB0-7D31-49AA-936A-A46 extern const UByteArray EFI_GUIDED_SECTION_TIANO; // A31280AD-481E-41B6-95E8-127F4C984779 extern const UByteArray EFI_GUIDED_SECTION_LZMA; // EE4E5898-3914-4259-9D6E-DC7BD79403CF extern const UByteArray EFI_GUIDED_SECTION_LZMA_HP; // 0ED85E23-F253-413F-A03C-901987B04397 +extern const UByteArray EFI_GUIDED_SECTION_LZMA_MS; // BD9921EA-ED91-404A-8B2F-B4D724747C8C extern const UByteArray EFI_GUIDED_SECTION_LZMAF86; // D42AE6BD-1352-4BFB-909A-CA72A6EAE889 extern const UByteArray EFI_GUIDED_SECTION_GZIP; // 1D301FE9-BE79-4353-91C2-D23BC959AE0C extern const UByteArray EFI_GUIDED_SECTION_ZLIB_AMD; // CE3233F5-2CD6-4D87-9152-4A238BB6D1C4 +extern const UByteArray EFI_GUIDED_SECTION_ZLIB_AMD2; // 991EFAC0-E260-416B-A4B8-3B153072B804 extern const UByteArray EFI_FIRMWARE_CONTENTS_SIGNED_GUID; // 0F9D89E8-9259-4F76-A5AF-0C89E34023DF #define WIN_CERT_TYPE_EFI_GUID 0x0EF1 @@ -580,7 +585,7 @@ typedef struct BPDT_ENTRY_ { UINT32 SplitSubPartitionFirstPart : 1; UINT32 SplitSubPartitionSecondPart : 1; UINT32 CodeSubPartition : 1; - UINT32 UmaCachable : 1; + UINT32 UmaCacheable : 1; UINT32 Reserved: 12; UINT32 Offset; UINT32 Size; @@ -841,22 +846,121 @@ typedef struct PROTECTED_RANGE_VENDOR_HASH_FILE_HEADER_AMI_V3_ // // AMI ROM Hole files // -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_0; //05CA01FC-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_1; //05CA01FD-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_2; //05CA01FE-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_3; //05CA01FF-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_4; //05CA0200-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_5; //05CA0201-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_6; //05CA0202-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_7; //05CA0203-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_8; //05CA0204-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_9; //05CA0205-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_10; //05CA0206-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_11; //05CA0207-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_12; //05CA0208-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_13; //05CA0209-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_14; //05CA020A-0FC1-11DC-9011-00173153EBA8 -extern const UByteArray AMI_ROM_HOLE_FILE_GUID_15; //05CA020B-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_0; // 05CA01FC-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_1; // 05CA01FD-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_2; // 05CA01FE-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_3; // 05CA01FF-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_4; // 05CA0200-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_5; // 05CA0201-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_6; // 05CA0202-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_7; // 05CA0203-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_8; // 05CA0204-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_9; // 05CA0205-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_10; // 05CA0206-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_11; // 05CA0207-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_12; // 05CA0208-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_13; // 05CA0209-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_14; // 05CA020A-0FC1-11DC-9011-00173153EBA8 +extern const UByteArray AMI_ROM_HOLE_FILE_GUID_15; // 05CA020B-0FC1-11DC-9011-00173153EBA8 + +// +// Insyde Flash Device Map +// +#define INSYDE_FLASH_DEVICE_MAP_SIGNATURE 0x4D444648 // HFDM + +typedef struct _INSYDE_FLASH_DEVICE_MAP_HEADER { + UINT32 Signature; + UINT32 Size; + UINT32 DataOffset; + UINT32 EntrySize; + UINT8 EntryFormat; + UINT8 Revision; + UINT8 ExtensionCount; + UINT8 Checksum; + UINT64 FdBaseAddress; +//INSYDE_FLASH_DEVICE_MAP_EXTENSION Extensions[ExtensionCount]; +} INSYDE_FLASH_DEVICE_MAP_HEADER; + +typedef struct _INSYDE_FLASH_DEVICE_MAP_EXTENSION { + UINT16 EntryOffset; + UINT16 EntryCount; +} INSYDE_FLASH_DEVICE_MAP_EXTENSION; + +typedef struct _INSYDE_FLASH_DEVICE_MAP_ENTRY { + EFI_GUID RegionTypeGuid; + UINT8 RegionId[16]; + UINT64 RegionOffset; + UINT64 RegionSize; + UINT32 Attributes; +//UINT8 Hash[]; // Size depends on EntryFormat and EntrySize of the header +} INSYDE_FLASH_DEVICE_MAP_ENTRY; + +typedef struct _INSYDE_FLASH_DEVICE_MAP_BOARD_ID_MAP { + UINT32 BoardIdIndex; + UINT32 BoardIdCount; +//UINT64 BoardIds[Count]; +} INSYDE_FLASH_DEVICE_MAP_BOARD_ID_MAP; + +#define INSYDE_FLASH_DEVICE_MAP_ENTRY_ATTRIBUTE_MODIFIABLE 0x00000001 + +extern const UByteArray INSYDE_FLASH_MAP_REGION_BOOT_FV_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_BVDT_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_EC_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_FTW_BACKUP_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_FTW_STATE_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_FV_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_FLASH_DEVICE_MAP_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_LOGO_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_MICROCODE_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_MSDM_TABLE_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_MULTI_CONFIG_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_VAR_DEFAULT_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_SMBIOS_UPDATE_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_VAR_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_UNKNOWN_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_UNUSED_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_USB_OPTION_ROM_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_DXE_FV_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_PEI_FV_GUID; +extern const UByteArray INSYDE_FLASH_MAP_REGION_UNSIGNED_FV_GUID; + +// +// Dell variables +// +#define DVAR_STORE_SIGNATURE 0x52415644 + +typedef struct _DVAR_STORE_HEADER { + UINT32 Signature; + UINT32 StoreSizeC; + UINT8 FlagsC; + // DVAR_ENTRY Entries[]; +} DVAR_STORE_HEADER; + +typedef struct _DVAR_ENTRY_HEADER { + UINT8 StateC; // Values are stored in 2-complement format, can be converted with (Val = 0xFF - ValC) + UINT8 FlagsC; + UINT8 TypeC; + UINT8 AttributesC; + UINT8 NamespaceIdC; + // The rest is variable depending on Flags and Types + // EFI_GUID NamespaceGuid; + // UINT8 or UINT16 NameId; + // UINT8 or UINT16 DataSize; + // UINT8 Data[DataSize]; +} DVAR_ENTRY_HEADER; + +#define DVAR_ENTRY_STATE_STORING 0x01 +#define DVAR_ENTRY_STATE_STORED 0x05 +#define DVAR_ENTRY_STATE_DELETING 0x15 +#define DVAR_ENTRY_STATE_DELETED 0x55 + +//#define DVAR_ENTRY_FLAG_NAME_UTF8 0x01 // Haven't seen any samples yet, so this is a guesswork for now +#define DVAR_ENTRY_FLAG_NAME_ID 0x02 +#define DVAR_ENTRY_FLAG_NAMESPACE_GUID 0x04 // This kind of variables is used to store namespace guids, the "deleted" state for them is ignored + +#define DVAR_ENTRY_TYPE_NAME_ID_8_DATA_SIZE_8 0x00 // Both NameId and DataSize are UINT8 +#define DVAR_ENTRY_TYPE_NAME_ID_16_DATA_SIZE_8 0x04 // NameId is UINT16, DataSize is UINT8 +#define DVAR_ENTRY_TYPE_NAME_ID_16_DATA_SIZE_16 0x05 // Both NameId and DataSize are UINT16 // Restore previous packing rules #pragma pack(pop) diff --git a/common/ffsparser.cpp b/common/ffsparser.cpp index 93d3e6c..a1af649 100644 --- a/common/ffsparser.cpp +++ b/common/ffsparser.cpp @@ -35,6 +35,14 @@ #include "digest/sha2.h" #include "digest/sm3.h" +#include "umemstream.h" +#include "kaitai/kaitaistream.h" +#include "generated/insyde_fdm.h" + +#ifdef U_ENABLE_NVRAM_PARSING_SUPPORT +#include "generated/dell_dvar.h" +#endif + // Constructor FfsParser::FfsParser(TreeModel* treeModel) : model(treeModel), imageBase(0), addressDiff(0x100000000ULL), protectedRegionsBase(0) { @@ -322,8 +330,8 @@ USTATUS FfsParser::parseIntelImage(const UByteArray & intelImage, const UINT32 l const FLASH_DESCRIPTOR_COMPONENT_SECTION* componentSection = (const FLASH_DESCRIPTOR_COMPONENT_SECTION*)calculateAddress8((UINT8*)descriptor, descriptorMap->ComponentBase); UINT8 descriptorVersion = 2; - // Check descriptor version by getting hardcoded value of FlashParameters.ReadClockFrequency - if (componentSection->FlashParameters.ReadClockFrequency == FLASH_FREQUENCY_20MHZ) + // Check descriptor version by getting hardcoded value of zero in FlashParameters.ReadClockFrequency + if (componentSection->FlashParameters.ReadClockFrequency == 0) descriptorVersion = 1; // Regions @@ -531,7 +539,10 @@ USTATUS FfsParser::parseIntelImage(const UByteArray & intelImage, const UINT32 l else if (descriptorVersion == 2) { const FLASH_DESCRIPTOR_MASTER_SECTION_V2* masterSection = (const FLASH_DESCRIPTOR_MASTER_SECTION_V2*)calculateAddress8((UINT8*)descriptor, descriptorMap->MasterBase); info += UString("\nRegion access settings:"); - info += usprintf("\nBIOS: %03Xh %03Xh ME: %03Xh %03Xh\nGbE: %03Xh %03Xh EC: %03Xh %03Xh", + info += usprintf("\nBIOS: %03Xh %03Xh" + "\nME: %03Xh %03Xh" + "\nGbE: %03Xh %03Xh" + "\nEC: %03Xh %03Xh", masterSection->BiosRead, masterSection->BiosWrite, masterSection->MeRead, @@ -692,10 +703,15 @@ USTATUS FfsParser::parseMeRegion(const UByteArray & me, const UINT32 localOffset bool versionFound = true; bool emptyRegion = false; // Check for empty region - if (me.size() == me.count('\xFF') || me.size() == me.count('\x00')) { + if (me.size() == me.count('\xFF')) { // Further parsing not needed emptyRegion = true; - info += ("\nState: empty"); + info += ("\nState: empty (0xFF)"); + } + else if (me.size() == me.count('\x00')) { + // Further parsing not needed + emptyRegion = true; + info += ("\nState: empty (0x00)"); } else { // Search for new signature @@ -713,12 +729,11 @@ USTATUS FfsParser::parseMeRegion(const UByteArray & me, const UINT32 localOffset } } - // Check sanity - if ((UINT32)me.size() < (UINT32)versionOffset + sizeof(ME_VERSION)) - return U_INVALID_REGION; - // Add version information if (versionFound) { + if ((UINT32)me.size() < (UINT32)versionOffset + sizeof(ME_VERSION)) + return U_INVALID_REGION; + const ME_VERSION* version = (const ME_VERSION*)(me.constData() + versionOffset); info += usprintf("\nVersion: %u.%u.%u.%u", version->Major, @@ -755,13 +770,28 @@ USTATUS FfsParser::parsePdrRegion(const UByteArray & pdr, const UINT32 localOffs UString name("PDR region"); UString info = usprintf("Full size: %Xh (%u)", (UINT32)pdr.size(), (UINT32)pdr.size()); + // Check for empty region + bool emptyRegion = false; + if (pdr.size() == pdr.count('\xFF')) { + // Further parsing not needed + emptyRegion = true; + info += ("\nState: empty (0xFF)"); + } + else if (pdr.size() == pdr.count('\x00')) { + // Further parsing not needed + emptyRegion = true; + info += ("\nState: empty (0x00)"); + } + // Add tree item index = model->addItem(localOffset, Types::Region, Subtypes::PdrRegion, name, UString(), info, UByteArray(), pdr, UByteArray(), Fixed, parent); - // Parse PDR region as BIOS space - USTATUS result = parseRawArea(index); - if (result && result != U_VOLUMES_NOT_FOUND && result != U_INVALID_VOLUME && result != U_STORES_NOT_FOUND) - return result; + if (!emptyRegion) { + // Parse PDR region as BIOS space + USTATUS result = parseRawArea(index); + if (result && result != U_VOLUMES_NOT_FOUND && result != U_INVALID_VOLUME && result != U_STORES_NOT_FOUND) + return result; + } return U_SUCCESS; } @@ -776,12 +806,17 @@ USTATUS FfsParser::parseDevExp1Region(const UByteArray & devExp1, const UINT32 l UString name("DevExp1 region"); UString info = usprintf("Full size: %Xh (%u)", (UINT32)devExp1.size(), (UINT32)devExp1.size()); - bool emptyRegion = false; // Check for empty region - if (devExp1.size() == devExp1.count('\xFF') || devExp1.size() == devExp1.count('\x00')) { + bool emptyRegion = false; + if (devExp1.size() == devExp1.count('\xFF')) { // Further parsing not needed emptyRegion = true; - info += ("\nState: empty"); + info += ("\nState: empty (0xFF)"); + } + else if (devExp1.size() == devExp1.count('\x00')) { + // Further parsing not needed + emptyRegion = true; + info += ("\nState: empty (0x00)"); } // Add tree item @@ -803,6 +838,19 @@ USTATUS FfsParser::parseGenericRegion(const UINT8 subtype, const UByteArray & re UString name = itemSubtypeToUString(Types::Region, subtype) + UString(" region"); UString info = usprintf("Full size: %Xh (%u)", (UINT32)region.size(), (UINT32)region.size()); + // Check for empty region + bool emptyRegion = false; + if (region.size() == region.count('\xFF')) { + // Further parsing not needed + emptyRegion = true; + info += ("\nState: empty (0xFF)"); + } + else if (region.size() == region.count('\x00')) { + // Further parsing not needed + emptyRegion = true; + info += ("\nState: empty (0x00)"); + } + // Add tree item index = model->addItem(localOffset, Types::Region, subtype, name, UString(), info, UByteArray(), region, UByteArray(), Fixed, parent); @@ -835,6 +883,15 @@ USTATUS FfsParser::parseRawArea(const UModelIndex & index) UByteArray data = model->body(index); UINT32 headerSize = (UINT32)model->header(index).size(); + // Obtain required information from parent volume, if it exists + UINT8 emptyByte = 0xFF; + UModelIndex parentVolumeIndex = model->findParentOfType(index, Types::Volume); + if (parentVolumeIndex.isValid() && model->hasEmptyParsingData(parentVolumeIndex) == false) { + UByteArray data = model->parsingData(parentVolumeIndex); + const VOLUME_PARSING_DATA* pdata = (const VOLUME_PARSING_DATA*)data.constData(); + emptyByte = pdata->emptyByte; + } + USTATUS result; UString name; UString info; @@ -918,9 +975,7 @@ USTATUS FfsParser::parseRawArea(const UModelIndex & index) } else { // Show messages if (itemSize != itemAltSize) - msg(usprintf("%s: volume size stored in header %Xh differs from calculated using block map %Xh", __FUNCTION__, - itemSize, itemAltSize), - volumeIndex); + msg(usprintf("%s: volume size stored in header %Xh differs from calculated using block map %Xh", __FUNCTION__, itemSize, itemAltSize), volumeIndex); } } else if (itemType == Types::Microcode) { @@ -948,6 +1003,310 @@ USTATUS FfsParser::parseRawArea(const UModelIndex & index) msg(usprintf("%s: BPDT store parsing failed with error ", __FUNCTION__) + errorCodeToUString(result), index); } } + else if (itemType == Types::InsydeFlashDeviceMapStore) { + try { + UByteArray fdm = data.mid(itemOffset, itemSize); + umemstream is(fdm.constData(), fdm.size()); + kaitai::kstream ks(&is); + insyde_fdm_t parsed(&ks); + UINT32 storeSize = (UINT32)fdm.size(); + + // Construct header and body + UByteArray header = fdm.left(parsed.data_offset()); + UByteArray body = fdm.mid(header.size(), storeSize - header.size()); + + // Add info + UString name = UString("Insyde H2O FlashDeviceMap"); + UString info = usprintf("Signature: HFDM\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nEntry size: %Xh (%u)\nEntry format: %02Xh\nRevision: %02Xh\nExtension count: %u\nFlash descriptor base address: %08Xh\nChecksum: %02Xh", + storeSize, storeSize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + parsed.entry_size(), parsed.entry_size(), + parsed.entry_format(), + parsed.revision(), + parsed.num_extensions(), + (UINT32)parsed.fd_base_address(), + parsed.checksum()); + + // Check header checksum + { + UByteArray tempHeader = data.mid(itemOffset, sizeof(INSYDE_FLASH_DEVICE_MAP_HEADER)); + INSYDE_FLASH_DEVICE_MAP_HEADER* tempFdmHeader = (INSYDE_FLASH_DEVICE_MAP_HEADER*)tempHeader.data(); + tempFdmHeader->Checksum = 0; + UINT8 calculated = calculateChecksum8((const UINT8*)tempFdmHeader, (UINT32)tempHeader.size()); + if (calculated == parsed.checksum()) { + info += UString(", valid"); + } + else { + info += usprintf(", invalid, should be %02Xh", calculated); + } + } + + // Add board IDs + if (!parsed._is_null_board_ids()) { + info += usprintf("\nRegion index: %Xh\nBoardId Count: %u", + parsed.board_ids()->region_index(), + parsed.board_ids()->num_board_ids()); + UINT32 i = 0; + for (const auto & boardId : *parsed.board_ids()->board_ids()) { + info += usprintf("\nBoardId #%u: %" PRIX64 "\n", i++, boardId); + } + } + + // Add header tree item + UModelIndex headerIndex = model->addItem(headerSize + itemOffset, Types::InsydeFlashDeviceMapStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, index); + + // Add entries + UINT32 entryOffset = parsed.data_offset(); + bool protectedRangeFound = false; + for (const auto & entry : *parsed.entries()->entries()) { + const EFI_GUID guid = readUnaligned((const EFI_GUID*)entry->guid().c_str()); + name = insydeFlashDeviceMapEntryTypeGuidToUString(guid); + UString text; + header = data.mid(itemOffset + entryOffset, sizeof(INSYDE_FLASH_DEVICE_MAP_ENTRY)); + body = data.mid(itemOffset + entryOffset + header.size(), parsed.entry_size() - header.size()); + + // Add info + UINT32 entrySize = (UINT32)header.size() + (UINT32)body.size(); + info = UString("Region type: ") + guidToUString(guid, false) + "\n"; + info += UString("Region id: "); + for (UINT8 i = 0; i < 16; i++) { + info += usprintf("%02X", *(const UINT8*)(entry->region_id().c_str() + i)); + } + info += usprintf("\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nRegion address: %08Xh\nRegion size: %08Xh\nAttributes: %08Xh", + entrySize, entrySize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + (UINT32)entry->region_base(), + (UINT32)entry->region_size(), + entry->attributes()); + + if ((entry->attributes() & INSYDE_FLASH_DEVICE_MAP_ENTRY_ATTRIBUTE_MODIFIABLE) == 0) { + if (!protectedRangeFound) { + securityInfo += usprintf("Insyde Flash Device Map found at base %08Xh\nProtected ranges:\n", model->base(headerIndex)); + protectedRangeFound = true; + } + + // TODO: make sure that the only hash possible here is SHA256 + + // Add this region to the list of Insyde protected regions + PROTECTED_RANGE range = {}; + range.Offset = (UINT32)entry->region_base(); + range.Size = (UINT32)entry->region_size(); + range.AlgorithmId = TCG_HASH_ALGORITHM_ID_SHA256; + range.Type = PROTECTED_RANGE_VENDOR_HASH_INSYDE; + range.Hash = body; + protectedRanges.push_back(range); + + securityInfo += usprintf("Address: %08Xh Size: %Xh\nHash: ", range.Offset, range.Size) + UString(body.toHex().constData()) + "\n"; + } + + // Add tree item + model->addItem(entryOffset, Types::InsydeFlashDeviceMapEntry, 0, name, text, info, header, body, UByteArray(), Fixed, headerIndex); + + entryOffset += entrySize; + } + + if (protectedRangeFound) { + securityInfo += "\n"; + } + } + catch (...) { + // Parsing failed, need to add the candidate as Padding + UByteArray padding = data.mid(itemOffset, itemSize); + + // Get info + name = UString("Padding"); + info = usprintf("Full size: %Xh (%u)", (UINT32)padding.size(), (UINT32)padding.size()); + + // Add tree item + model->addItem(headerSize + itemOffset, Types::Padding, getPaddingType(padding), name, UString(), info, UByteArray(), padding, UByteArray(), Fixed, index); + } + } +#ifdef U_ENABLE_NVRAM_PARSING_SUPPORT + else if (itemType == Types::DellDvarStore) { + try { + UByteArray dvar = data.mid(itemOffset, itemSize); + umemstream is(dvar.constData(), dvar.size()); + kaitai::kstream ks(&is); + dell_dvar_t parsed(&ks); + UINT32 storeSize = (UINT32)dvar.size(); + + // Construct header and body + UByteArray header = dvar.left(parsed.data_offset()); + UByteArray body = dvar.mid(header.size(), storeSize - header.size()); + + // Add info + UString name = UString("Dell DVAR Store"); + UString info = usprintf("Signature: DVAR\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nFlags: %02Xh", + storeSize, storeSize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + parsed.flags()); + + // Add header tree item + UModelIndex headerIndex = model->addItem(headerSize + itemOffset, Types::DellDvarStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, index); + + // Add entries + UINT32 entryOffset = parsed.data_offset(); + for (const auto & entry : *parsed.entries()) { + // This is the terminating entry, needs special processing + if (entry->_is_null_flags_c()) { + // Add free space or padding after all entries, if needed + if (entryOffset < storeSize) { + UByteArray freeSpace = dvar.mid(entryOffset, storeSize - entryOffset); + // Add info + info = usprintf("Full size: %Xh (%u)", (UINT32)freeSpace.size(), (UINT32)freeSpace.size()); + + // Check that remaining unparsed bytes are actually empty + if (freeSpace.count(emptyByte) == freeSpace.size()) { // Free space + // Add tree item + model->addItem(entryOffset, Types::FreeSpace, 0, UString("Free space"), UString(), info, UByteArray(), freeSpace, UByteArray(), Fixed, headerIndex); + } + else { + // Add tree item + model->addItem(entryOffset, Types::Padding, getPaddingType(freeSpace), UString("Padding"), UString(), info, UByteArray(), freeSpace, UByteArray(), Fixed, headerIndex); + } + } + break; + } + + // This is a normal entry + // Check state to be known + if (entry->state() != DVAR_ENTRY_STATE_STORING && + entry->state() != DVAR_ENTRY_STATE_STORED && + entry->state() != DVAR_ENTRY_STATE_DELETING && + entry->state() != DVAR_ENTRY_STATE_DELETED){ + // TODO: Add the rest as padding, as we encountered an unexpected entry and can't guarantee that the rest got parsed correctly + } + + // Check flags to be known + if (entry->flags() != DVAR_ENTRY_FLAG_NAME_ID && + entry->flags() != DVAR_ENTRY_FLAG_NAME_ID + DVAR_ENTRY_FLAG_NAMESPACE_GUID) { + // TODO: Add the rest as padding, as we encountered an unexpected entry and can't guarantee that the rest got parsed correctly + } + + // Check type to be known + if (entry->type() != DVAR_ENTRY_TYPE_NAME_ID_8_DATA_SIZE_8 && + entry->type() != DVAR_ENTRY_TYPE_NAME_ID_16_DATA_SIZE_8 && + entry->type() != DVAR_ENTRY_TYPE_NAME_ID_16_DATA_SIZE_16) { + // TODO: Add the rest as padding, as we encountered an unexpected entry and can't guarantee that the rest got parsed correctly + } + + UINT32 headerSize; + UINT32 bodySize; + UINT32 entrySize; + UINT32 nameId; + UINT8 subtype; + UString text; + + // TODO: find a Dell image with NameUtf8 entries + + // NamespaceGUID entry + if (entry->flags() == DVAR_ENTRY_FLAG_NAME_ID + DVAR_ENTRY_FLAG_NAMESPACE_GUID) { + // State of this variable only applies to the NameId part, not the NamespaceGuid part + // This kind of variables with deleted state till need to be shown as valid + subtype = Subtypes::NamespaceGuidDvarEntry; + EFI_GUID guid = *(const EFI_GUID*)(entry->namespace_guid().c_str()); + headerSize = sizeof(DVAR_ENTRY_HEADER) + sizeof(EFI_GUID); + if (entry->type() == DVAR_ENTRY_TYPE_NAME_ID_8_DATA_SIZE_8) { + nameId = entry->name_id_8(); + bodySize = entry->len_data_8(); + headerSize += sizeof(UINT8) + sizeof(UINT8); + } + else if (entry->type() == DVAR_ENTRY_TYPE_NAME_ID_16_DATA_SIZE_8) { + nameId = entry->name_id_16(); + bodySize = entry->len_data_8(); + headerSize += sizeof(UINT16) + sizeof(UINT8); + } + else if (entry->type() == DVAR_ENTRY_TYPE_NAME_ID_16_DATA_SIZE_16) { + nameId = entry->name_id_16(); + bodySize = entry->len_data_16(); + headerSize += sizeof(UINT16) + sizeof(UINT16); + } + + entrySize = headerSize + bodySize; + header = dvar.mid(entryOffset, headerSize); + body = dvar.mid(entryOffset + headerSize, bodySize); + + name = usprintf("%X:%X", entry->namespace_id(), nameId); + text = guidToUString(guid); + info = usprintf("Full size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nState: %02Xh\nFlags: %02Xh\nType: %02Xh\nNamespaceId: %Xh\nNameId: %Xh\n", + entrySize, entrySize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + entry->state(), + entry->flags(), + entry->type(), + entry->namespace_id(), + nameId) + + UString("NamespaceGuid: ") + guidToUString(guid, false); + } + // NameId entry + else { + subtype = Subtypes::NameIdDvarEntry; + headerSize = sizeof(DVAR_ENTRY_HEADER); + if (entry->type() == DVAR_ENTRY_TYPE_NAME_ID_8_DATA_SIZE_8) { + nameId = entry->name_id_8(); + bodySize = entry->len_data_8(); + headerSize += sizeof(UINT8) + sizeof(UINT8); + } + else if (entry->type() == DVAR_ENTRY_TYPE_NAME_ID_16_DATA_SIZE_8) { + nameId = entry->name_id_16(); + bodySize = entry->len_data_8(); + headerSize += sizeof(UINT16) + sizeof(UINT8); + } + else if (entry->type() == DVAR_ENTRY_TYPE_NAME_ID_16_DATA_SIZE_16) { + nameId = entry->name_id_16(); + bodySize = entry->len_data_16(); + headerSize += sizeof(UINT16) + sizeof(UINT16); + } + + entrySize = headerSize + bodySize; + header = dvar.mid(entryOffset, headerSize); + body = dvar.mid(entryOffset + headerSize, bodySize); + + name = usprintf("%X:%X", entry->namespace_id(), nameId); + info = usprintf("Full size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nState: %02Xh\nFlags: %02Xh\nType: %02Xh\nNamespaceId: %Xh\nNameId: %Xh\n", + entrySize, entrySize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + entry->state(), + entry->flags(), + entry->type(), + entry->namespace_id(), + nameId); + } + + // Mark NameId entries that are not stored as Invalid + if (entry->flags() != DVAR_ENTRY_FLAG_NAME_ID + DVAR_ENTRY_FLAG_NAMESPACE_GUID && + (entry->state() == DVAR_ENTRY_STATE_STORING || + entry->state() == DVAR_ENTRY_STATE_DELETING || + entry->state() == DVAR_ENTRY_STATE_DELETED)) { + subtype = Subtypes::InvalidDvarEntry; + name = UString("Invalid"); + text.clear(); + } + + // Add tree item + model->addItem(entryOffset, Types::DellDvarEntry, subtype, name, text, info, header, body, UByteArray(), Fixed, headerIndex); + + entryOffset += entrySize; + } + } + catch (...) { + // Parsing failed, need to add the candidate as Padding + UByteArray padding = data.mid(itemOffset, itemSize); + + // Get info + name = UString("Padding"); + info = usprintf("Full size: %Xh (%u)", (UINT32)padding.size(), (UINT32)padding.size()); + + // Add tree item + model->addItem(headerSize + itemOffset, Types::Padding, getPaddingType(padding), name, UString(), info, UByteArray(), padding, UByteArray(), Fixed, index); + } + } +#endif else { return U_UNKNOWN_ITEM_TYPE; } @@ -962,7 +1321,7 @@ USTATUS FfsParser::parseRawArea(const UModelIndex & index) (void)prevItemType; } - // Padding at the end of RAW area + // Padding at the end of raw area itemOffset = prevItemOffset + prevItemSize; if ((UINT32)data.size() > itemOffset) { UByteArray padding = data.mid(itemOffset); @@ -992,6 +1351,12 @@ USTATUS FfsParser::parseRawArea(const UModelIndex & index) case Types::BpdtPartition: // Parsing already done break; + case Types::InsydeFlashDeviceMapStore: + // Parsing already done + break; + case Types::DellDvarStore: + // Parsing already done + break; case Types::Padding: // No parsing required break; @@ -1158,13 +1523,36 @@ USTATUS FfsParser::parseVolumeHeader(const UByteArray & volume, const UINT32 loc volumeHeader->Checksum) + (msgInvalidChecksum ? usprintf(", invalid, should be %04Xh", calculated) : UString(", valid")); - // Extended header present - - // volumeHeader->ExtHeaderOffset should be aligned to 4 bytes - if (volumeHeader->ExtHeaderOffset % 4) { - msg(usprintf("%s: ExtHeaderOffset %04Xh (%hu) is not aligned by 4 bytes", __FUNCTION__, volumeHeader->ExtHeaderOffset, volumeHeader->ExtHeaderOffset)); - return U_INVALID_VOLUME; + // Block size and blocks number + const EFI_FV_BLOCK_MAP_ENTRY* entry = (const EFI_FV_BLOCK_MAP_ENTRY*)(volume.constData() + sizeof(EFI_FIRMWARE_VOLUME_HEADER)); + UString infoNumBlocks = usprintf("NumBlocks: %Xh (%u)", entry->NumBlocks, entry->NumBlocks); + UString infoLength = usprintf("Length: %Xh (%u)", entry->Length, entry->Length); + if (entry->NumBlocks == 0) { + infoNumBlocks += UString(", invalid, can not be zero"); } + if (entry->Length == 0) { + infoLength += UString(", invalid, can not be zero"); + } + if (entry->NumBlocks != 0 && entry->Length != 0) { + UINT32 volumeAltSize = entry->NumBlocks * entry->Length; + if (volumeSize != volumeAltSize) { + if (volumeAltSize % entry->Length == 0 && volumeSize % entry->Length == 0) { + infoNumBlocks += usprintf(", invalid, should be %Xh", volumeSize / entry->Length); + infoLength += ", valid"; + } + else if (volumeAltSize % entry->NumBlocks == 0 && volumeSize % entry->NumBlocks == 0) { + infoNumBlocks += ", valid"; + infoLength += usprintf(", invalid, should be %Xh", volumeSize / entry->NumBlocks); + } + } + else { + infoNumBlocks += ", valid"; + infoLength += ", valid"; + } + } + info += "\n" + infoNumBlocks + "\n" + infoLength; + + // Extended header if (volumeHeader->Revision > 1 && volumeHeader->ExtHeaderOffset) { if ((UINT32)volume.size() < volumeHeader->ExtHeaderOffset + sizeof(EFI_FIRMWARE_VOLUME_EXT_HEADER)) { return U_INVALID_VOLUME; @@ -1226,17 +1614,6 @@ USTATUS FfsParser::parseVolumeHeader(const UByteArray & volume, const UINT32 loc bool FfsParser::microcodeHeaderValid(const INTEL_MICROCODE_HEADER* ucodeHeader) { bool reservedBytesValid = true; - - // Check CpuFlags reserved bytes to be zero - for (UINT32 i = 0; i < sizeof(ucodeHeader->ProcessorFlagsReserved); i++) { - if (ucodeHeader->ProcessorFlagsReserved[i] != 0x00) { - reservedBytesValid = false; - break; - } - } - if (!reservedBytesValid) { - return false; - } // Check data size to be multiple of 4 and less than 0x1000000 if (ucodeHeader->DataSize % 4 != 0 || @@ -1275,8 +1652,8 @@ bool FfsParser::microcodeHeaderValid(const INTEL_MICROCODE_HEADER* ucodeHeader) ucodeHeader->DateYear > 0x2049) { return FALSE; } - // Check HeaderVersion to be 1. - if (ucodeHeader->HeaderVersion != 1) { + // Check HeaderType to be 1. + if (ucodeHeader->HeaderType != 1) { return FALSE; } // Check LoaderRevision to be 1. @@ -1299,7 +1676,7 @@ USTATUS FfsParser::findNextRawAreaItem(const UModelIndex & index, const UINT32 l for (; offset < dataSize - sizeof(UINT32); offset++) { const UINT32* currentPos = (const UINT32*)(data.constData() + offset); UINT32 restSize = dataSize - offset; - if (readUnaligned(currentPos) == INTEL_MICROCODE_HEADER_VERSION_1) {// Intel microcode + if (readUnaligned(currentPos) == INTEL_MICROCODE_HEADER_VERSION_1) { // Intel microcode // Check data size if (restSize < sizeof(INTEL_MICROCODE_HEADER)) { continue; @@ -1409,8 +1786,10 @@ continue_searching: {} } // Check size candidate - if (sizeCandidate == 0) + if (sizeCandidate == 0 || sizeCandidate > restSize) { + msg(usprintf("%s: invalid BpdtStore size (sizeCandidate = %Xh, restSize = %Xh)", __FUNCTION__, sizeCandidate, restSize), index); continue; + } // All checks passed, BPDT found nextItemType = Types::BpdtStore; @@ -1419,6 +1798,47 @@ continue_searching: {} nextItemOffset = offset; break; } + else if (readUnaligned(currentPos) == INSYDE_FLASH_DEVICE_MAP_SIGNATURE) { + // Check data size + if (restSize < sizeof(INSYDE_FLASH_DEVICE_MAP_HEADER)) + continue; + + const INSYDE_FLASH_DEVICE_MAP_HEADER *fdmHeader = (const INSYDE_FLASH_DEVICE_MAP_HEADER *)currentPos; + + if (restSize < fdmHeader->Size) + continue; + + if (fdmHeader->Revision > 4) { + msg(usprintf("%s: Insyde Flash Device Map candidate with unknown revision %u", __FUNCTION__, fdmHeader->Revision), index); + continue; + } + + // All checks passed, FDM found + nextItemType = Types::InsydeFlashDeviceMapStore; + nextItemSize = fdmHeader->Size; + nextItemAlternativeSize = fdmHeader->Size; + nextItemOffset = offset; + break; + } +#ifdef U_ENABLE_NVRAM_PARSING_SUPPORT + else if (readUnaligned(currentPos) == DVAR_STORE_SIGNATURE) { + // Check data size + if (restSize < sizeof(DVAR_STORE_HEADER)) + continue; + + const DVAR_STORE_HEADER *dvarHeader = (const DVAR_STORE_HEADER *)currentPos; + UINT32 storeSize = 0xFFFFFFFF - dvarHeader->StoreSizeC; + if (restSize < storeSize) + continue; + + // All checks passed, FDM found + nextItemType = Types::DellDvarStore; + nextItemSize = storeSize; + nextItemAlternativeSize = storeSize; + nextItemOffset = offset; + break; + } +#endif } // No more stores found @@ -1440,9 +1860,9 @@ USTATUS FfsParser::parseVolumeNonUefiData(const UByteArray & data, const UINT32 // Add padding tree item UModelIndex paddingIndex = model->addItem(localOffset, Types::Padding, Subtypes::DataPadding, UString("Non-UEFI data"), UString(), info, UByteArray(), data, UByteArray(), Fixed, index); - msg(usprintf("%s: non-UEFI data found in volume's free space", __FUNCTION__), paddingIndex); + msg(usprintf("%s: non-UEFI data found in volume free space", __FUNCTION__), paddingIndex); - // Parse contents as RAW area + // Parse contents as raw area return parseRawArea(paddingIndex); } @@ -1457,7 +1877,7 @@ USTATUS FfsParser::parseVolumeBody(const UModelIndex & index) UByteArray volumeBody = model->body(index); UINT32 volumeHeaderSize = (UINT32)model->header(index).size(); - // Parse VSS NVRAM volumes with a dedicated function + // Parse NVRAM volume with a dedicated function if (model->subtype(index) == Subtypes::NvramVolume) { return nvramParser->parseNvramVolumeBody(index); } @@ -2376,6 +2796,7 @@ USTATUS FfsParser::parseGuidedSectionHeader(const UByteArray & section, const UI } else if (baGuid == EFI_GUIDED_SECTION_LZMA || baGuid == EFI_GUIDED_SECTION_LZMA_HP + || baGuid == EFI_GUIDED_SECTION_LZMA_MS || baGuid == EFI_GUIDED_SECTION_LZMAF86 || baGuid == EFI_GUIDED_SECTION_TIANO || baGuid == EFI_GUIDED_SECTION_GZIP) { @@ -2865,7 +3286,8 @@ USTATUS FfsParser::parseGuidedSectionBody(const UModelIndex & index) } // LZMA compressed section else if (baGuid == EFI_GUIDED_SECTION_LZMA - || baGuid == EFI_GUIDED_SECTION_LZMA_HP) { + || baGuid == EFI_GUIDED_SECTION_LZMA_HP + || baGuid == EFI_GUIDED_SECTION_LZMA_MS) { USTATUS result = decompress(model->body(index), EFI_CUSTOMIZED_COMPRESSION, algorithm, dictionarySize, processed, efiDecompressed); if (result) { msg(usprintf("%s: decompression failed with error ", __FUNCTION__) + errorCodeToUString(result), index); @@ -3768,6 +4190,26 @@ USTATUS FfsParser::checkProtectedRanges(const UModelIndex & index) // Do nothing, this range is likely not found in the image } } + else if (protectedRanges[i].Type == PROTECTED_RANGE_VENDOR_HASH_INSYDE) { + try { + protectedRanges[i].Offset -= (UINT32)addressDiff; + protectedParts = openedImage.mid(protectedRanges[i].Offset, protectedRanges[i].Size); + + UByteArray digest(SHA256_HASH_SIZE, '\x00'); + sha256(protectedParts.constData(), protectedParts.size(), digest.data()); + + if (digest != protectedRanges[i].Hash) { + msg(usprintf("%s: Insyde protected range [%Xh:%Xh] hash mismatch, opened image may refuse to boot", __FUNCTION__, + protectedRanges[i].Offset, protectedRanges[i].Offset + protectedRanges[i].Size), + model->findByBase(protectedRanges[i].Offset)); + } + + markProtectedRangeRecursive(index, protectedRanges[i]); + } + catch(...) { + // Do nothing, this range is likely not found in the image + } + } } return U_SUCCESS; @@ -4108,13 +4550,13 @@ USTATUS FfsParser::parseIntelMicrocodeHeader(const UByteArray & microcode, const // Recalculate checksum after patching tempUcodeHeader->Checksum = 0; - tempUcodeHeader->ProcessorFlags = entry->ProcessorFlags; + tempUcodeHeader->PlatformIds = entry->PlatformIds; tempUcodeHeader->ProcessorSignature = entry->ProcessorSignature; UINT32 entryCalculated = calculateChecksum32((const UINT32*)tempMicrocode.constData(), sizeof(INTEL_MICROCODE_HEADER) + dataSize); - extendedHeaderInfo += usprintf("\nCPU signature #%u: %08Xh\nCPU flags #%u: %02Xh\nChecksum #%u: %08Xh, ", + extendedHeaderInfo += usprintf("\nCPU signature #%u: %08Xh\nCPU platform Id #%u: %08Xh\nChecksum #%u: %08Xh, ", i + 1, entry->ProcessorSignature, - i + 1, entry->ProcessorFlags, + i + 1, entry->PlatformIds, i + 1, entry->Checksum) + (entry->Checksum == entryCalculated ? UString("valid") : usprintf("invalid, should be %08Xh", entryCalculated)); } @@ -4133,7 +4575,7 @@ USTATUS FfsParser::parseIntelMicrocodeHeader(const UByteArray & microcode, const // Add info UString name("Intel microcode"); UString info = usprintf("Full size: %Xh (%u)\nHeader size: 0h (0u)\nBody size: %Xh (%u)\nTail size: 0h (0u)\n" - "Date: %02X.%02X.%04x\nCPU signature: %08Xh\nRevision: %08Xh\nCPU flags: %02Xh\nChecksum: %08Xh, ", + "Date: %02X.%02X.%04x\nCPU signature: %08Xh\nRevision: %08Xh\nMinimal update revision: %08Xh\nCPU platform Id: %08Xh\nChecksum: %08Xh, ", (UINT32)microcodeBinary.size(), (UINT32)microcodeBinary.size(), (UINT32)microcodeBinary.size(), (UINT32)microcodeBinary.size(), ucodeHeader->DateDay, @@ -4141,7 +4583,8 @@ USTATUS FfsParser::parseIntelMicrocodeHeader(const UByteArray & microcode, const ucodeHeader->DateYear, ucodeHeader->ProcessorSignature, ucodeHeader->UpdateRevision, - ucodeHeader->ProcessorFlags, + ucodeHeader->UpdateRevisionMin, + ucodeHeader->PlatformIds, ucodeHeader->Checksum) + (ucodeHeader->Checksum == calculated ? UString("valid") : usprintf("invalid, should be %08Xh", calculated)) + extendedHeaderInfo; @@ -4219,7 +4662,7 @@ USTATUS FfsParser::parseBpdtRegion(const UByteArray & region, const UINT32 local UString("\nSplit sub-partition first part: ") + (ptEntry->SplitSubPartitionFirstPart ? "Yes" : "No") + UString("\nSplit sub-partition second part: ") + (ptEntry->SplitSubPartitionSecondPart ? "Yes" : "No") + UString("\nCode sub-partition: ") + (ptEntry->CodeSubPartition ? "Yes" : "No") + - UString("\nUMA cachable: ") + (ptEntry->UmaCachable ? "Yes" : "No"); + UString("\nUMA cacheable: ") + (ptEntry->UmaCacheable ? "Yes" : "No"); // Add tree item UModelIndex entryIndex = model->addItem(localOffset + offset, Types::BpdtEntry, 0, name, UString(), info, UByteArray(), UByteArray((const char*)ptEntry, sizeof(BPDT_ENTRY)), UByteArray(), Fixed, index); @@ -4299,7 +4742,7 @@ make_partition_table_consistent: goto make_partition_table_consistent; } else { - msg(usprintf("%s: BPDT partition intersects with prevous one, skipped", __FUNCTION__), + msg(usprintf("%s: BPDT partition intersects with previous one, skipped", __FUNCTION__), partitions[i].index); partitions.erase(partitions.begin() + i); goto make_partition_table_consistent; @@ -4331,7 +4774,7 @@ make_partition_table_consistent: UString("\nSplit sub-partition first part: ") + (partitions[i].ptEntry.SplitSubPartitionFirstPart ? "Yes" : "No") + UString("\nSplit sub-partition second part: ") + (partitions[i].ptEntry.SplitSubPartitionSecondPart ? "Yes" : "No") + UString("\nCode sub-partition: ") + (partitions[i].ptEntry.CodeSubPartition ? "Yes" : "No") + - UString("\nUMA cachable: ") + (partitions[i].ptEntry.UmaCachable ? "Yes" : "No"); + UString("\nUMA cacheable: ") + (partitions[i].ptEntry.UmaCacheable ? "Yes" : "No"); UString text = bpdtEntryTypeToUString(partitions[i].ptEntry.Type); @@ -4680,7 +5123,9 @@ make_partition_table_consistent: UModelIndex partitionIndex = model->addItem(localOffset + partitions[i].ptEntry.Offset.Offset, Types::CpdPartition, Subtypes::ManifestCpdPartition, name, UString(), info, header, body, UByteArray(), Fixed, parent); // Parse data as extensions area - parseCpdExtensionsArea(partitionIndex); + // Add the header size as a local offset + // Since the body starts after the header length + parseCpdExtensionsArea(partitionIndex, (UINT32)header.size()); } } } @@ -4699,7 +5144,7 @@ make_partition_table_consistent: UModelIndex partitionIndex = model->addItem(localOffset + partitions[i].ptEntry.Offset.Offset, Types::CpdPartition, Subtypes::MetadataCpdPartition, name, UString(), info, UByteArray(), partition, UByteArray(), Fixed, parent); // Parse data as extensions area - parseCpdExtensionsArea(partitionIndex); + parseCpdExtensionsArea(partitionIndex, 0); } // It's a code else { @@ -4735,7 +5180,7 @@ make_partition_table_consistent: return U_SUCCESS; } -USTATUS FfsParser::parseCpdExtensionsArea(const UModelIndex & index) +USTATUS FfsParser::parseCpdExtensionsArea(const UModelIndex & index, const UINT32 localOffset) { if (!index.isValid()) { return U_INVALID_PARAMETER; @@ -4776,7 +5221,7 @@ USTATUS FfsParser::parseCpdExtensionsArea(const UModelIndex & index) infoHeader->UsageBitmap[12], infoHeader->UsageBitmap[13], infoHeader->UsageBitmap[14], infoHeader->UsageBitmap[15]); // Add tree item - extIndex = model->addItem(offset, Types::CpdExtension, 0, name, UString(), info, header, data, UByteArray(), Fixed, index); + extIndex = model->addItem(offset + localOffset, Types::CpdExtension, 0, name, UString(), info, header, data, UByteArray(), Fixed, index); parseSignedPackageInfoData(extIndex); } // Parse IFWI Partition Manifest a bit further @@ -4819,7 +5264,7 @@ USTATUS FfsParser::parseCpdExtensionsArea(const UModelIndex & index) + UString("\nPartition hash: ") + UString(hash.toHex().constData()); // Add tree item - extIndex = model->addItem(offset, Types::CpdExtension, 0, name, UString(), info, UByteArray(), partition, UByteArray(), Fixed, index); + extIndex = model->addItem(offset + localOffset, Types::CpdExtension, 0, name, UString(), info, UByteArray(), partition, UByteArray(), Fixed, index); if (msgHashSizeMismatch) { msg(usprintf("%s: IFWI Partition Manifest hash size is %u, maximum allowed is %u, truncated", __FUNCTION__, attrHeader->HashSize, (UINT32)sizeof(attrHeader->CompletePartitionHash)), extIndex); } @@ -4844,12 +5289,12 @@ USTATUS FfsParser::parseCpdExtensionsArea(const UModelIndex & index) attrHeader->GlobalModuleId) + UString(hash.toHex().constData()); // Add tree item - extIndex = model->addItem(offset, Types::CpdExtension, 0, name, UString(), info, UByteArray(), partition, UByteArray(), Fixed, index); + extIndex = model->addItem(offset + localOffset, Types::CpdExtension, 0, name, UString(), info, UByteArray(), partition, UByteArray(), Fixed, index); } // Parse everything else else { // Add tree item, if needed - extIndex = model->addItem(offset, Types::CpdExtension, 0, name, UString(), info, UByteArray(), partition, UByteArray(), Fixed, index); + extIndex = model->addItem(offset + localOffset, Types::CpdExtension, 0, name, UString(), info, UByteArray(), partition, UByteArray(), Fixed, index); } // There needs to be a more generic way to do it, but it is fine for now @@ -4859,7 +5304,7 @@ USTATUS FfsParser::parseCpdExtensionsArea(const UModelIndex & index) && extHeader->Type != CPD_EXT_TYPE_KEY_MANIFEST_EXT && extHeader->Type != CPD_EXT_TYPE_SIGNED_PACKAGE_INFO_EXT && extHeader->Type != CPD_EXT_TYPE_SPS_PLATFORM_ID) { - msg(usprintf("%s: CPD extention of unknown type found", __FUNCTION__), extIndex); + msg(usprintf("%s: CPD extension of unknown type found", __FUNCTION__), extIndex); } offset += extHeader->Length; diff --git a/common/ffsparser.h b/common/ffsparser.h index b62367f..ef7ccc4 100644 --- a/common/ffsparser.h +++ b/common/ffsparser.h @@ -67,6 +67,7 @@ typedef struct PROTECTED_RANGE_ { #define PROTECTED_RANGE_VENDOR_HASH_AMI_V2 0x06 #define PROTECTED_RANGE_VENDOR_HASH_AMI_V3 0x07 #define PROTECTED_RANGE_VENDOR_HASH_MICROSOFT_PMDA 0x08 +#define PROTECTED_RANGE_VENDOR_HASH_INSYDE 0x09 class FitParser; class NvramParser; @@ -130,7 +131,7 @@ private: USTATUS parseBpdtRegion(const UByteArray & region, const UINT32 localOffset, const UINT32 sbpdtOffsetFixup, const UModelIndex & parent, UModelIndex & index); USTATUS parseCpdRegion(const UByteArray & region, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index); - USTATUS parseCpdExtensionsArea(const UModelIndex & index); + USTATUS parseCpdExtensionsArea(const UModelIndex & index, const UINT32 localOffset); USTATUS parseSignedPackageInfoData(const UModelIndex & index); USTATUS parseRawArea(const UModelIndex & index); diff --git a/common/ffsreport.cpp b/common/ffsreport.cpp index 0954185..901fe35 100644 --- a/common/ffsreport.cpp +++ b/common/ffsreport.cpp @@ -33,7 +33,7 @@ std::vector FfsReport::generate() } // Generate report recursive - report.push_back(UString(" Type | Subtype | Base | Size | CRC32 | Name ")); + report.push_back(UString(" Type | Subtype | Base | Size | CRC32 | Name ")); USTATUS result = generateRecursive(report, root); if (result) { report.push_back(usprintf("%s: generateRecursive returned ", __FUNCTION__) + errorCodeToUString(result)); @@ -59,7 +59,7 @@ USTATUS FfsReport::generateRecursive(std::vector & report, const UModel } report.push_back( - UString(" ") + itemTypeToUString(model->type(index)).leftJustified(16) + UString(" ") + itemTypeToUString(model->type(index)).leftJustified(20) + UString("| ") + itemSubtypeToUString(model->type(index), model->subtype(index)).leftJustified(22) + offset + usprintf("| %08X | %08X | ", (UINT32)data.size(), crc) diff --git a/common/filesystem.cpp b/common/filesystem.cpp index b2b8d65..766ee5c 100644 --- a/common/filesystem.cpp +++ b/common/filesystem.cpp @@ -75,6 +75,9 @@ UString getAbsPath(const UString & path) #else #include #include +#if !defined(ACCESSPERMS) +#define ACCESSPERMS (S_IRWXU|S_IRWXG|S_IRWXO) +#endif bool isExistOnFs(const UString & path) { struct stat buf; @@ -97,10 +100,14 @@ bool changeDirectory(const UString & dir) } UString getAbsPath(const UString & path) { - char abs[PATH_MAX] = {}; + char * abs = realpath(path.toLocal8Bit(), nullptr); // Last is a non-standard extension for non-existent files - if (realpath(path.toLocal8Bit(), abs) || abs[0] != '\0') - return UString(abs); - return path; + UString new_path; + if (abs) + new_path = UString(abs); + else + new_path = path; + free(abs); + return new_path; } -#endif \ No newline at end of file +#endif diff --git a/common/generated/ami_nvar.cpp b/common/generated/ami_nvar.cpp index edd42d0..c41427c 100644 --- a/common/generated/ami_nvar.cpp +++ b/common/generated/ami_nvar.cpp @@ -361,7 +361,7 @@ int32_t ami_nvar_t::nvar_entry_body_t::data_end_offset() { uint16_t ami_nvar_t::nvar_entry_body_t::extended_header_size() { if (f_extended_header_size) return m_extended_header_size; - m_extended_header_size = ((_parent()->attributes()->extended_header()) ? (((extended_header_size_field() >= (1 + 2)) ? (extended_header_size_field()) : (0))) : (0)); + m_extended_header_size = (( ((_parent()->attributes()->extended_header()) && (_parent()->attributes()->valid()) && (_parent()->size() > (((4 + 2) + 4) + 2))) ) ? (((extended_header_size_field() >= (1 + 2)) ? (extended_header_size_field()) : (0))) : (0)); f_extended_header_size = true; return m_extended_header_size; } diff --git a/common/generated/apple_sysf.cpp b/common/generated/apple_sysf.cpp new file mode 100644 index 0000000..580d84e --- /dev/null +++ b/common/generated/apple_sysf.cpp @@ -0,0 +1,108 @@ +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "apple_sysf.h" + +apple_sysf_t::apple_sysf_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent, apple_sysf_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = this; (void)p__root; + m_body = nullptr; + m__io__raw_body = nullptr; + f_len_sysf_store_header = false; + _read(); +} + +void apple_sysf_t::_read() { + m_signature = m__io->read_u4le(); + m_unknown = m__io->read_u1(); + m_unknown1 = m__io->read_u4le(); + m_sysf_size = m__io->read_u2le(); + m__raw_body = m__io->read_bytes(((sysf_size() - len_sysf_store_header()) - 4)); + m__io__raw_body = std::unique_ptr(new kaitai::kstream(m__raw_body)); + m_body = std::unique_ptr(new sysf_store_body_t(m__io__raw_body.get(), this, m__root)); + m_crc = m__io->read_u4le(); +} + +apple_sysf_t::~apple_sysf_t() { + _clean_up(); +} + +void apple_sysf_t::_clean_up() { +} + +apple_sysf_t::sysf_store_body_t::sysf_store_body_t(kaitai::kstream* p__io, apple_sysf_t* p__parent, apple_sysf_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + m_variables = nullptr; + m_zeroes = nullptr; + _read(); +} + +void apple_sysf_t::sysf_store_body_t::_read() { + m_variables = std::unique_ptr>>(new std::vector>()); + { + int i = 0; + sysf_variable_t* _; + do { + _ = new sysf_variable_t(m__io, this, m__root); + m_variables->push_back(std::move(std::unique_ptr(_))); + i++; + } while (!( (( ((_->len_name() == 3) && (_->name() == (std::string("EOF")))) ) || (_io()->is_eof())) )); + } + m_zeroes = std::unique_ptr>(new std::vector()); + { + int i = 0; + while (!m__io->is_eof()) { + m_zeroes->push_back(std::move(m__io->read_u1())); + i++; + } + } +} + +apple_sysf_t::sysf_store_body_t::~sysf_store_body_t() { + _clean_up(); +} + +void apple_sysf_t::sysf_store_body_t::_clean_up() { +} + +apple_sysf_t::sysf_variable_t::sysf_variable_t(kaitai::kstream* p__io, apple_sysf_t::sysf_store_body_t* p__parent, apple_sysf_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + _read(); +} + +void apple_sysf_t::sysf_variable_t::_read() { + m_len_name = m__io->read_bits_int_le(7); + m_invalid_flag = m__io->read_bits_int_le(1); + m__io->align_to_byte(); + m_name = kaitai::kstream::bytes_to_str(kaitai::kstream::bytes_terminate(m__io->read_bytes(len_name()), 0, false), std::string("ascii")); + n_len_data = true; + if (name() != std::string("EOF")) { + n_len_data = false; + m_len_data = m__io->read_u2le(); + } + n_data = true; + if (name() != std::string("EOF")) { + n_data = false; + m_data = m__io->read_bytes(len_data()); + } +} + +apple_sysf_t::sysf_variable_t::~sysf_variable_t() { + _clean_up(); +} + +void apple_sysf_t::sysf_variable_t::_clean_up() { + if (!n_len_data) { + } + if (!n_data) { + } +} + +int8_t apple_sysf_t::len_sysf_store_header() { + if (f_len_sysf_store_header) + return m_len_sysf_store_header; + m_len_sysf_store_header = 11; + f_len_sysf_store_header = true; + return m_len_sysf_store_header; +} diff --git a/common/generated/apple_sysf.h b/common/generated/apple_sysf.h new file mode 100644 index 0000000..8de0be8 --- /dev/null +++ b/common/generated/apple_sysf.h @@ -0,0 +1,129 @@ +#pragma once + +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "../kaitai/kaitaistruct.h" +#include +#include +#include + +#if KAITAI_STRUCT_VERSION < 9000L +#error "Incompatible Kaitai Struct C++/STL API: version 0.9 or later is required" +#endif + +class apple_sysf_t : public kaitai::kstruct { + +public: + class sysf_store_body_t; + class sysf_variable_t; + + apple_sysf_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent = nullptr, apple_sysf_t* p__root = nullptr); + +private: + void _read(); + void _clean_up(); + +public: + ~apple_sysf_t(); + + class sysf_store_body_t : public kaitai::kstruct { + + public: + + sysf_store_body_t(kaitai::kstream* p__io, apple_sysf_t* p__parent = nullptr, apple_sysf_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~sysf_store_body_t(); + + private: + std::unique_ptr>> m_variables; + std::unique_ptr> m_zeroes; + apple_sysf_t* m__root; + apple_sysf_t* m__parent; + + public: + std::vector>* variables() const { return m_variables.get(); } + std::vector* zeroes() const { return m_zeroes.get(); } + apple_sysf_t* _root() const { return m__root; } + apple_sysf_t* _parent() const { return m__parent; } + }; + + class sysf_variable_t : public kaitai::kstruct { + + public: + + sysf_variable_t(kaitai::kstream* p__io, apple_sysf_t::sysf_store_body_t* p__parent = nullptr, apple_sysf_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~sysf_variable_t(); + + private: + uint64_t m_len_name; + bool m_invalid_flag; + std::string m_name; + uint16_t m_len_data; + bool n_len_data; + + public: + bool _is_null_len_data() { len_data(); return n_len_data; }; + + private: + std::string m_data; + bool n_data; + + public: + bool _is_null_data() { data(); return n_data; }; + + private: + apple_sysf_t* m__root; + apple_sysf_t::sysf_store_body_t* m__parent; + + public: + uint64_t len_name() const { return m_len_name; } + bool invalid_flag() const { return m_invalid_flag; } + std::string name() const { return m_name; } + uint16_t len_data() const { return m_len_data; } + std::string data() const { return m_data; } + apple_sysf_t* _root() const { return m__root; } + apple_sysf_t::sysf_store_body_t* _parent() const { return m__parent; } + }; + +private: + bool f_len_sysf_store_header; + int8_t m_len_sysf_store_header; + +public: + int8_t len_sysf_store_header(); + +private: + uint32_t m_signature; + uint8_t m_unknown; + uint32_t m_unknown1; + uint16_t m_sysf_size; + std::unique_ptr m_body; + uint32_t m_crc; + apple_sysf_t* m__root; + kaitai::kstruct* m__parent; + std::string m__raw_body; + std::unique_ptr m__io__raw_body; + +public: + uint32_t signature() const { return m_signature; } + uint8_t unknown() const { return m_unknown; } + uint32_t unknown1() const { return m_unknown1; } + uint16_t sysf_size() const { return m_sysf_size; } + sysf_store_body_t* body() const { return m_body.get(); } + uint32_t crc() const { return m_crc; } + apple_sysf_t* _root() const { return m__root; } + kaitai::kstruct* _parent() const { return m__parent; } + std::string _raw_body() const { return m__raw_body; } + kaitai::kstream* _io__raw_body() const { return m__io__raw_body.get(); } +}; diff --git a/common/generated/dell_dvar.cpp b/common/generated/dell_dvar.cpp new file mode 100644 index 0000000..cc35e93 --- /dev/null +++ b/common/generated/dell_dvar.cpp @@ -0,0 +1,235 @@ +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "dell_dvar.h" + +dell_dvar_t::dell_dvar_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent, dell_dvar_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = this; (void)p__root; + m_entries = nullptr; + f_len_store = false; + f_flags = false; + f_data_offset = false; + _read(); +} + +void dell_dvar_t::_read() { + m_signature = m__io->read_bytes(4); + m_len_store_c = m__io->read_u4le(); + m_flags_c = m__io->read_u1(); + m_entries = std::unique_ptr>>(new std::vector>()); + { + int i = 0; + dvar_entry_t* _; + do { + _ = new dvar_entry_t(m__io, this, m__root); + m_entries->push_back(std::move(std::unique_ptr(_))); + i++; + } while (!(_->state_c() == 255)); + } +} + +dell_dvar_t::~dell_dvar_t() { + _clean_up(); +} + +void dell_dvar_t::_clean_up() { +} + +dell_dvar_t::dvar_entry_t::dvar_entry_t(kaitai::kstream* p__io, dell_dvar_t* p__parent, dell_dvar_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + f_namespace_id = false; + f_len_data_8 = false; + f_state = false; + f_len_data_16 = false; + f_attributes = false; + f_flags = false; + f_name_id_8 = false; + f_name_id_16 = false; + f_type = false; + _read(); +} + +void dell_dvar_t::dvar_entry_t::_read() { + m_state_c = m__io->read_u1(); + n_flags_c = true; + if (state_c() != 255) { + n_flags_c = false; + m_flags_c = m__io->read_u1(); + } + n_type_c = true; + if (state_c() != 255) { + n_type_c = false; + m_type_c = m__io->read_u1(); + } + n_attributes_c = true; + if (state_c() != 255) { + n_attributes_c = false; + m_attributes_c = m__io->read_u1(); + } + n_namespace_id_c = true; + if ( ((state_c() != 255) && ( ((flags() == 2) || (flags() == 6)) )) ) { + n_namespace_id_c = false; + m_namespace_id_c = m__io->read_u1(); + } + n_namespace_guid = true; + if ( ((state_c() != 255) && (flags() == 6)) ) { + n_namespace_guid = false; + m_namespace_guid = m__io->read_bytes(16); + } + n_name_id_8_c = true; + if ( ((state_c() != 255) && (type() == 0)) ) { + n_name_id_8_c = false; + m_name_id_8_c = m__io->read_u1(); + } + n_name_id_16_c = true; + if ( ((state_c() != 255) && ( ((type() == 4) || (type() == 5)) )) ) { + n_name_id_16_c = false; + m_name_id_16_c = m__io->read_u2le(); + } + n_len_data_8_c = true; + if ( ((state_c() != 255) && ( ((type() == 0) || (type() == 4)) )) ) { + n_len_data_8_c = false; + m_len_data_8_c = m__io->read_u1(); + } + n_len_data_16_c = true; + if ( ((state_c() != 255) && (type() == 5)) ) { + n_len_data_16_c = false; + m_len_data_16_c = m__io->read_u2le(); + } + n_data_8 = true; + if ( ((state_c() != 255) && ( ((type() == 0) || (type() == 4)) )) ) { + n_data_8 = false; + m_data_8 = m__io->read_bytes(len_data_8()); + } + n_data_16 = true; + if ( ((state_c() != 255) && (type() == 5)) ) { + n_data_16 = false; + m_data_16 = m__io->read_bytes(len_data_16()); + } +} + +dell_dvar_t::dvar_entry_t::~dvar_entry_t() { + _clean_up(); +} + +void dell_dvar_t::dvar_entry_t::_clean_up() { + if (!n_flags_c) { + } + if (!n_type_c) { + } + if (!n_attributes_c) { + } + if (!n_namespace_id_c) { + } + if (!n_namespace_guid) { + } + if (!n_name_id_8_c) { + } + if (!n_name_id_16_c) { + } + if (!n_len_data_8_c) { + } + if (!n_len_data_16_c) { + } + if (!n_data_8) { + } + if (!n_data_16) { + } +} + +int32_t dell_dvar_t::dvar_entry_t::namespace_id() { + if (f_namespace_id) + return m_namespace_id; + m_namespace_id = (255 - namespace_id_c()); + f_namespace_id = true; + return m_namespace_id; +} + +int32_t dell_dvar_t::dvar_entry_t::len_data_8() { + if (f_len_data_8) + return m_len_data_8; + m_len_data_8 = (255 - len_data_8_c()); + f_len_data_8 = true; + return m_len_data_8; +} + +int32_t dell_dvar_t::dvar_entry_t::state() { + if (f_state) + return m_state; + m_state = (255 - state_c()); + f_state = true; + return m_state; +} + +int32_t dell_dvar_t::dvar_entry_t::len_data_16() { + if (f_len_data_16) + return m_len_data_16; + m_len_data_16 = (65535 - len_data_16_c()); + f_len_data_16 = true; + return m_len_data_16; +} + +int32_t dell_dvar_t::dvar_entry_t::attributes() { + if (f_attributes) + return m_attributes; + m_attributes = (255 - attributes_c()); + f_attributes = true; + return m_attributes; +} + +int32_t dell_dvar_t::dvar_entry_t::flags() { + if (f_flags) + return m_flags; + m_flags = (255 - flags_c()); + f_flags = true; + return m_flags; +} + +int32_t dell_dvar_t::dvar_entry_t::name_id_8() { + if (f_name_id_8) + return m_name_id_8; + m_name_id_8 = (255 - name_id_8_c()); + f_name_id_8 = true; + return m_name_id_8; +} + +int32_t dell_dvar_t::dvar_entry_t::name_id_16() { + if (f_name_id_16) + return m_name_id_16; + m_name_id_16 = (65535 - name_id_16_c()); + f_name_id_16 = true; + return m_name_id_16; +} + +int32_t dell_dvar_t::dvar_entry_t::type() { + if (f_type) + return m_type; + m_type = (255 - type_c()); + f_type = true; + return m_type; +} + +int32_t dell_dvar_t::len_store() { + if (f_len_store) + return m_len_store; + m_len_store = (4294967295UL - len_store_c()); + f_len_store = true; + return m_len_store; +} + +int32_t dell_dvar_t::flags() { + if (f_flags) + return m_flags; + m_flags = (255 - flags_c()); + f_flags = true; + return m_flags; +} + +int8_t dell_dvar_t::data_offset() { + if (f_data_offset) + return m_data_offset; + m_data_offset = 9; + f_data_offset = true; + return m_data_offset; +} diff --git a/common/generated/dell_dvar.h b/common/generated/dell_dvar.h new file mode 100644 index 0000000..e50af45 --- /dev/null +++ b/common/generated/dell_dvar.h @@ -0,0 +1,239 @@ +#pragma once + +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "../kaitai/kaitaistruct.h" +#include +#include +#include + +#if KAITAI_STRUCT_VERSION < 9000L +#error "Incompatible Kaitai Struct C++/STL API: version 0.9 or later is required" +#endif + +class dell_dvar_t : public kaitai::kstruct { + +public: + class dvar_entry_t; + + dell_dvar_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent = nullptr, dell_dvar_t* p__root = nullptr); + +private: + void _read(); + void _clean_up(); + +public: + ~dell_dvar_t(); + + class dvar_entry_t : public kaitai::kstruct { + + public: + + dvar_entry_t(kaitai::kstream* p__io, dell_dvar_t* p__parent = nullptr, dell_dvar_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~dvar_entry_t(); + + private: + bool f_namespace_id; + int32_t m_namespace_id; + + public: + int32_t namespace_id(); + + private: + bool f_len_data_8; + int32_t m_len_data_8; + + public: + int32_t len_data_8(); + + private: + bool f_state; + int32_t m_state; + + public: + int32_t state(); + + private: + bool f_len_data_16; + int32_t m_len_data_16; + + public: + int32_t len_data_16(); + + private: + bool f_attributes; + int32_t m_attributes; + + public: + int32_t attributes(); + + private: + bool f_flags; + int32_t m_flags; + + public: + int32_t flags(); + + private: + bool f_name_id_8; + int32_t m_name_id_8; + + public: + int32_t name_id_8(); + + private: + bool f_name_id_16; + int32_t m_name_id_16; + + public: + int32_t name_id_16(); + + private: + bool f_type; + int32_t m_type; + + public: + int32_t type(); + + private: + uint8_t m_state_c; + uint8_t m_flags_c; + bool n_flags_c; + + public: + bool _is_null_flags_c() { flags_c(); return n_flags_c; }; + + private: + uint8_t m_type_c; + bool n_type_c; + + public: + bool _is_null_type_c() { type_c(); return n_type_c; }; + + private: + uint8_t m_attributes_c; + bool n_attributes_c; + + public: + bool _is_null_attributes_c() { attributes_c(); return n_attributes_c; }; + + private: + uint8_t m_namespace_id_c; + bool n_namespace_id_c; + + public: + bool _is_null_namespace_id_c() { namespace_id_c(); return n_namespace_id_c; }; + + private: + std::string m_namespace_guid; + bool n_namespace_guid; + + public: + bool _is_null_namespace_guid() { namespace_guid(); return n_namespace_guid; }; + + private: + uint8_t m_name_id_8_c; + bool n_name_id_8_c; + + public: + bool _is_null_name_id_8_c() { name_id_8_c(); return n_name_id_8_c; }; + + private: + uint16_t m_name_id_16_c; + bool n_name_id_16_c; + + public: + bool _is_null_name_id_16_c() { name_id_16_c(); return n_name_id_16_c; }; + + private: + uint8_t m_len_data_8_c; + bool n_len_data_8_c; + + public: + bool _is_null_len_data_8_c() { len_data_8_c(); return n_len_data_8_c; }; + + private: + uint16_t m_len_data_16_c; + bool n_len_data_16_c; + + public: + bool _is_null_len_data_16_c() { len_data_16_c(); return n_len_data_16_c; }; + + private: + std::string m_data_8; + bool n_data_8; + + public: + bool _is_null_data_8() { data_8(); return n_data_8; }; + + private: + std::string m_data_16; + bool n_data_16; + + public: + bool _is_null_data_16() { data_16(); return n_data_16; }; + + private: + dell_dvar_t* m__root; + dell_dvar_t* m__parent; + + public: + uint8_t state_c() const { return m_state_c; } + uint8_t flags_c() const { return m_flags_c; } + uint8_t type_c() const { return m_type_c; } + uint8_t attributes_c() const { return m_attributes_c; } + uint8_t namespace_id_c() const { return m_namespace_id_c; } + std::string namespace_guid() const { return m_namespace_guid; } + uint8_t name_id_8_c() const { return m_name_id_8_c; } + uint16_t name_id_16_c() const { return m_name_id_16_c; } + uint8_t len_data_8_c() const { return m_len_data_8_c; } + uint16_t len_data_16_c() const { return m_len_data_16_c; } + std::string data_8() const { return m_data_8; } + std::string data_16() const { return m_data_16; } + dell_dvar_t* _root() const { return m__root; } + dell_dvar_t* _parent() const { return m__parent; } + }; + +private: + bool f_len_store; + int32_t m_len_store; + +public: + int32_t len_store(); + +private: + bool f_flags; + int32_t m_flags; + +public: + int32_t flags(); + +private: + bool f_data_offset; + int8_t m_data_offset; + +public: + int8_t data_offset(); + +private: + std::string m_signature; + uint32_t m_len_store_c; + uint8_t m_flags_c; + std::unique_ptr>> m_entries; + dell_dvar_t* m__root; + kaitai::kstruct* m__parent; + +public: + std::string signature() const { return m_signature; } + uint32_t len_store_c() const { return m_len_store_c; } + uint8_t flags_c() const { return m_flags_c; } + std::vector>* entries() const { return m_entries.get(); } + dell_dvar_t* _root() const { return m__root; } + kaitai::kstruct* _parent() const { return m__parent; } +}; diff --git a/common/generated/edk2_ftw.cpp b/common/generated/edk2_ftw.cpp new file mode 100644 index 0000000..60aa199 --- /dev/null +++ b/common/generated/edk2_ftw.cpp @@ -0,0 +1,63 @@ +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "edk2_ftw.h" + +edk2_ftw_t::edk2_ftw_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent, edk2_ftw_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = this; (void)p__root; + f_len_ftw_store_header_32 = false; + f_len_ftw_store_header_64 = false; + _read(); +} + +void edk2_ftw_t::_read() { + m_signature = m__io->read_bytes(16); + m_crc = m__io->read_u4le(); + m_state = m__io->read_u1(); + m_reserved = m__io->read_bytes(3); + m_len_write_queue_32 = m__io->read_u4le(); + n_len_write_queue_64 = true; + if (kaitai::kstream::mod(len_write_queue_32(), 16) == 0) { + n_len_write_queue_64 = false; + m_len_write_queue_64 = m__io->read_u4le(); + } + n_write_queue_32 = true; + if (kaitai::kstream::mod(len_write_queue_32(), 16) == 4) { + n_write_queue_32 = false; + m_write_queue_32 = m__io->read_bytes(len_write_queue_32()); + } + n_write_queue_64 = true; + if (kaitai::kstream::mod(len_write_queue_32(), 16) == 0) { + n_write_queue_64 = false; + m_write_queue_64 = m__io->read_bytes(((static_cast(len_write_queue_64()) << 32) + len_write_queue_32())); + } +} + +edk2_ftw_t::~edk2_ftw_t() { + _clean_up(); +} + +void edk2_ftw_t::_clean_up() { + if (!n_len_write_queue_64) { + } + if (!n_write_queue_32) { + } + if (!n_write_queue_64) { + } +} + +int8_t edk2_ftw_t::len_ftw_store_header_32() { + if (f_len_ftw_store_header_32) + return m_len_ftw_store_header_32; + m_len_ftw_store_header_32 = 28; + f_len_ftw_store_header_32 = true; + return m_len_ftw_store_header_32; +} + +int8_t edk2_ftw_t::len_ftw_store_header_64() { + if (f_len_ftw_store_header_64) + return m_len_ftw_store_header_64; + m_len_ftw_store_header_64 = 32; + f_len_ftw_store_header_64 = true; + return m_len_ftw_store_header_64; +} diff --git a/common/generated/edk2_ftw.h b/common/generated/edk2_ftw.h new file mode 100644 index 0000000..dc03753 --- /dev/null +++ b/common/generated/edk2_ftw.h @@ -0,0 +1,81 @@ +#pragma once + +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "../kaitai/kaitaistruct.h" +#include +#include + +#if KAITAI_STRUCT_VERSION < 9000L +#error "Incompatible Kaitai Struct C++/STL API: version 0.9 or later is required" +#endif + +class edk2_ftw_t : public kaitai::kstruct { + +public: + + edk2_ftw_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent = nullptr, edk2_ftw_t* p__root = nullptr); + +private: + void _read(); + void _clean_up(); + +public: + ~edk2_ftw_t(); + +private: + bool f_len_ftw_store_header_32; + int8_t m_len_ftw_store_header_32; + +public: + int8_t len_ftw_store_header_32(); + +private: + bool f_len_ftw_store_header_64; + int8_t m_len_ftw_store_header_64; + +public: + int8_t len_ftw_store_header_64(); + +private: + std::string m_signature; + uint32_t m_crc; + uint8_t m_state; + std::string m_reserved; + uint32_t m_len_write_queue_32; + uint32_t m_len_write_queue_64; + bool n_len_write_queue_64; + +public: + bool _is_null_len_write_queue_64() { len_write_queue_64(); return n_len_write_queue_64; }; + +private: + std::string m_write_queue_32; + bool n_write_queue_32; + +public: + bool _is_null_write_queue_32() { write_queue_32(); return n_write_queue_32; }; + +private: + std::string m_write_queue_64; + bool n_write_queue_64; + +public: + bool _is_null_write_queue_64() { write_queue_64(); return n_write_queue_64; }; + +private: + edk2_ftw_t* m__root; + kaitai::kstruct* m__parent; + +public: + std::string signature() const { return m_signature; } + uint32_t crc() const { return m_crc; } + uint8_t state() const { return m_state; } + std::string reserved() const { return m_reserved; } + uint32_t len_write_queue_32() const { return m_len_write_queue_32; } + uint32_t len_write_queue_64() const { return m_len_write_queue_64; } + std::string write_queue_32() const { return m_write_queue_32; } + std::string write_queue_64() const { return m_write_queue_64; } + edk2_ftw_t* _root() const { return m__root; } + kaitai::kstruct* _parent() const { return m__parent; } +}; diff --git a/common/generated/edk2_vss.cpp b/common/generated/edk2_vss.cpp new file mode 100644 index 0000000..6a5eced --- /dev/null +++ b/common/generated/edk2_vss.cpp @@ -0,0 +1,341 @@ +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "edk2_vss.h" +#include "../kaitai/exceptions.h" + +edk2_vss_t::edk2_vss_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent, edk2_vss_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = this; (void)p__root; + m_body = nullptr; + m__io__raw_body = nullptr; + f_len_vss_store_header = false; + _read(); +} + +void edk2_vss_t::_read() { + m_signature = m__io->read_u4le(); + m_vss_size = m__io->read_u4le(); + { + uint32_t _ = vss_size(); + if (!( ((_ > static_cast(len_vss_store_header())) && (_ < 4294967295UL)) )) { + throw kaitai::validation_expr_error(vss_size(), _io(), std::string("/seq/1")); + } + } + m_format = m__io->read_u1(); + m_state = m__io->read_u1(); + m_reserved = m__io->read_u2le(); + m_reserved1 = m__io->read_u4le(); + m__raw_body = m__io->read_bytes((vss_size() - len_vss_store_header())); + m__io__raw_body = std::unique_ptr(new kaitai::kstream(m__raw_body)); + m_body = std::unique_ptr(new vss_store_body_t(m__io__raw_body.get(), this, m__root)); +} + +edk2_vss_t::~edk2_vss_t() { + _clean_up(); +} + +void edk2_vss_t::_clean_up() { +} + +edk2_vss_t::vss_store_body_t::vss_store_body_t(kaitai::kstream* p__io, edk2_vss_t* p__parent, edk2_vss_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + m_variables = nullptr; + _read(); +} + +void edk2_vss_t::vss_store_body_t::_read() { + m_variables = std::unique_ptr>>(new std::vector>()); + { + int i = 0; + vss_variable_t* _; + do { + _ = new vss_variable_t(m__io, this, m__root); + m_variables->push_back(std::move(std::unique_ptr(_))); + i++; + } while (!( ((_->signature_first() != 170) || (_io()->is_eof())) )); + } +} + +edk2_vss_t::vss_store_body_t::~vss_store_body_t() { + _clean_up(); +} + +void edk2_vss_t::vss_store_body_t::_clean_up() { +} + +edk2_vss_t::vss_variable_attributes_t::vss_variable_attributes_t(kaitai::kstream* p__io, edk2_vss_t::vss_variable_t* p__parent, edk2_vss_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + _read(); +} + +void edk2_vss_t::vss_variable_attributes_t::_read() { + m_non_volatile = m__io->read_bits_int_le(1); + m_boot_service = m__io->read_bits_int_le(1); + m_runtime = m__io->read_bits_int_le(1); + m_hw_error_record = m__io->read_bits_int_le(1); + m_auth_write = m__io->read_bits_int_le(1); + m_time_based_auth = m__io->read_bits_int_le(1); + m_append_write = m__io->read_bits_int_le(1); + m_reserved = m__io->read_bits_int_le(24); + m_apple_data_checksum = m__io->read_bits_int_le(1); +} + +edk2_vss_t::vss_variable_attributes_t::~vss_variable_attributes_t() { + _clean_up(); +} + +void edk2_vss_t::vss_variable_attributes_t::_clean_up() { +} + +edk2_vss_t::vss_variable_t::vss_variable_t(kaitai::kstream* p__io, edk2_vss_t::vss_store_body_t* p__parent, edk2_vss_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + m_attributes = nullptr; + f_is_auth = false; + f_len_standard_header = false; + f_is_intel_legacy = false; + f_len_auth_header = false; + f_len_apple_header = false; + f_len_intel_legacy_header = false; + f_is_valid = false; + _read(); +} + +void edk2_vss_t::vss_variable_t::_read() { + m_signature_first = m__io->read_u1(); + n_signature_last = true; + if (signature_first() == 170) { + n_signature_last = false; + m_signature_last = m__io->read_u1(); + { + uint8_t _ = signature_last(); + if (!(_ == 85)) { + throw kaitai::validation_expr_error(signature_last(), _io(), std::string("/types/vss_variable/seq/1")); + } + } + } + n_state = true; + if (signature_first() == 170) { + n_state = false; + m_state = m__io->read_u1(); + } + n_reserved = true; + if (signature_first() == 170) { + n_reserved = false; + m_reserved = m__io->read_u1(); + } + n_attributes = true; + if (signature_first() == 170) { + n_attributes = false; + m_attributes = std::unique_ptr(new vss_variable_attributes_t(m__io, this, m__root)); + } + n_len_total = true; + if ( ((signature_first() == 170) && (is_intel_legacy())) ) { + n_len_total = false; + m_len_total = m__io->read_u4le(); + { + uint32_t _ = len_total(); + if (!(_ >= ((static_cast(len_intel_legacy_header()) + 4) + 1))) { + throw kaitai::validation_expr_error(len_total(), _io(), std::string("/types/vss_variable/seq/5")); + } + } + } + n_len_name = true; + if ( ((signature_first() == 170) && (!(is_intel_legacy()))) ) { + n_len_name = false; + m_len_name = m__io->read_u4le(); + } + n_len_data = true; + if ( ((signature_first() == 170) && (!(is_intel_legacy()))) ) { + n_len_data = false; + m_len_data = m__io->read_u4le(); + } + n_timestamp = true; + if ( ((signature_first() == 170) && (is_auth())) ) { + n_timestamp = false; + m_timestamp = m__io->read_bytes(16); + } + n_pubkey_index = true; + if ( ((signature_first() == 170) && (is_auth())) ) { + n_pubkey_index = false; + m_pubkey_index = m__io->read_u4le(); + } + n_len_name_auth = true; + if ( ((signature_first() == 170) && (is_auth())) ) { + n_len_name_auth = false; + m_len_name_auth = m__io->read_u4le(); + { + uint32_t _ = len_name_auth(); + if (!( ((_ >= 4) && (kaitai::kstream::mod(_, 2) == 0)) )) { + throw kaitai::validation_expr_error(len_name_auth(), _io(), std::string("/types/vss_variable/seq/10")); + } + } + } + n_len_data_auth = true; + if ( ((signature_first() == 170) && (is_auth())) ) { + n_len_data_auth = false; + m_len_data_auth = m__io->read_u4le(); + { + uint32_t _ = len_data_auth(); + if (!(_ > 0)) { + throw kaitai::validation_expr_error(len_data_auth(), _io(), std::string("/types/vss_variable/seq/11")); + } + } + } + n_vendor_guid = true; + if (signature_first() == 170) { + n_vendor_guid = false; + m_vendor_guid = m__io->read_bytes(16); + } + n_name_auth = true; + if ( ((signature_first() == 170) && (is_auth())) ) { + n_name_auth = false; + m_name_auth = m__io->read_bytes(len_name_auth()); + } + n_data_auth = true; + if ( ((signature_first() == 170) && (is_auth())) ) { + n_data_auth = false; + m_data_auth = m__io->read_bytes(len_data_auth()); + } + n_apple_data_crc32 = true; + if ( ((signature_first() == 170) && (!(is_intel_legacy())) && (!(is_auth())) && (attributes()->apple_data_checksum())) ) { + n_apple_data_crc32 = false; + m_apple_data_crc32 = m__io->read_u4le(); + } + n_intel_legacy_data = true; + if ( ((signature_first() == 170) && (is_intel_legacy())) ) { + n_intel_legacy_data = false; + m_intel_legacy_data = m__io->read_bytes((len_total() - len_intel_legacy_header())); + } + n_name = true; + if ( ((signature_first() == 170) && (!(is_intel_legacy())) && (!(is_auth()))) ) { + n_name = false; + m_name = m__io->read_bytes(len_name()); + { + std::string _ = name(); + if (!( ((len_name() >= 4) && (kaitai::kstream::mod(len_name(), 2) == 0)) )) { + throw kaitai::validation_expr_error(name(), _io(), std::string("/types/vss_variable/seq/17")); + } + } + } + n_data = true; + if ( ((signature_first() == 170) && (!(is_intel_legacy())) && (!(is_auth()))) ) { + n_data = false; + m_data = m__io->read_bytes(len_data()); + { + std::string _ = data(); + if (!(len_name() > 0)) { + throw kaitai::validation_expr_error(data(), _io(), std::string("/types/vss_variable/seq/18")); + } + } + } +} + +edk2_vss_t::vss_variable_t::~vss_variable_t() { + _clean_up(); +} + +void edk2_vss_t::vss_variable_t::_clean_up() { + if (!n_signature_last) { + } + if (!n_state) { + } + if (!n_reserved) { + } + if (!n_attributes) { + } + if (!n_len_total) { + } + if (!n_len_name) { + } + if (!n_len_data) { + } + if (!n_timestamp) { + } + if (!n_pubkey_index) { + } + if (!n_len_name_auth) { + } + if (!n_len_data_auth) { + } + if (!n_vendor_guid) { + } + if (!n_name_auth) { + } + if (!n_data_auth) { + } + if (!n_apple_data_crc32) { + } + if (!n_intel_legacy_data) { + } + if (!n_name) { + } + if (!n_data) { + } +} + +bool edk2_vss_t::vss_variable_t::is_auth() { + if (f_is_auth) + return m_is_auth; + m_is_auth = ((state() != 248) && (state() != 252) && ( (( ((attributes()->auth_write()) || (attributes()->time_based_auth()) || (attributes()->append_write())) ) || ( ((len_name() == 0) || (len_data() == 0)) )) )) ; + f_is_auth = true; + return m_is_auth; +} + +int8_t edk2_vss_t::vss_variable_t::len_standard_header() { + if (f_len_standard_header) + return m_len_standard_header; + m_len_standard_header = 32; + f_len_standard_header = true; + return m_len_standard_header; +} + +bool edk2_vss_t::vss_variable_t::is_intel_legacy() { + if (f_is_intel_legacy) + return m_is_intel_legacy; + m_is_intel_legacy = ((state() == 248) || (state() == 252)) ; + f_is_intel_legacy = true; + return m_is_intel_legacy; +} + +int8_t edk2_vss_t::vss_variable_t::len_auth_header() { + if (f_len_auth_header) + return m_len_auth_header; + m_len_auth_header = 60; + f_len_auth_header = true; + return m_len_auth_header; +} + +int8_t edk2_vss_t::vss_variable_t::len_apple_header() { + if (f_len_apple_header) + return m_len_apple_header; + m_len_apple_header = 36; + f_len_apple_header = true; + return m_len_apple_header; +} + +int8_t edk2_vss_t::vss_variable_t::len_intel_legacy_header() { + if (f_len_intel_legacy_header) + return m_len_intel_legacy_header; + m_len_intel_legacy_header = 28; + f_len_intel_legacy_header = true; + return m_len_intel_legacy_header; +} + +bool edk2_vss_t::vss_variable_t::is_valid() { + if (f_is_valid) + return m_is_valid; + m_is_valid = ((state() == 252) || (state() == 127) || (state() == 63)) ; + f_is_valid = true; + return m_is_valid; +} + +int8_t edk2_vss_t::len_vss_store_header() { + if (f_len_vss_store_header) + return m_len_vss_store_header; + m_len_vss_store_header = 16; + f_len_vss_store_header = true; + return m_len_vss_store_header; +} diff --git a/common/generated/edk2_vss.h b/common/generated/edk2_vss.h new file mode 100644 index 0000000..22b9162 --- /dev/null +++ b/common/generated/edk2_vss.h @@ -0,0 +1,343 @@ +#pragma once + +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "../kaitai/kaitaistruct.h" +#include +#include +#include + +#if KAITAI_STRUCT_VERSION < 9000L +#error "Incompatible Kaitai Struct C++/STL API: version 0.9 or later is required" +#endif + +class edk2_vss_t : public kaitai::kstruct { + +public: + class vss_store_body_t; + class vss_variable_attributes_t; + class vss_variable_t; + + edk2_vss_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent = nullptr, edk2_vss_t* p__root = nullptr); + +private: + void _read(); + void _clean_up(); + +public: + ~edk2_vss_t(); + + class vss_store_body_t : public kaitai::kstruct { + + public: + + vss_store_body_t(kaitai::kstream* p__io, edk2_vss_t* p__parent = nullptr, edk2_vss_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~vss_store_body_t(); + + private: + std::unique_ptr>> m_variables; + edk2_vss_t* m__root; + edk2_vss_t* m__parent; + + public: + std::vector>* variables() const { return m_variables.get(); } + edk2_vss_t* _root() const { return m__root; } + edk2_vss_t* _parent() const { return m__parent; } + }; + + class vss_variable_attributes_t : public kaitai::kstruct { + + public: + + vss_variable_attributes_t(kaitai::kstream* p__io, edk2_vss_t::vss_variable_t* p__parent = nullptr, edk2_vss_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~vss_variable_attributes_t(); + + private: + bool m_non_volatile; + bool m_boot_service; + bool m_runtime; + bool m_hw_error_record; + bool m_auth_write; + bool m_time_based_auth; + bool m_append_write; + uint64_t m_reserved; + bool m_apple_data_checksum; + edk2_vss_t* m__root; + edk2_vss_t::vss_variable_t* m__parent; + + public: + bool non_volatile() const { return m_non_volatile; } + bool boot_service() const { return m_boot_service; } + bool runtime() const { return m_runtime; } + bool hw_error_record() const { return m_hw_error_record; } + bool auth_write() const { return m_auth_write; } + bool time_based_auth() const { return m_time_based_auth; } + bool append_write() const { return m_append_write; } + uint64_t reserved() const { return m_reserved; } + bool apple_data_checksum() const { return m_apple_data_checksum; } + edk2_vss_t* _root() const { return m__root; } + edk2_vss_t::vss_variable_t* _parent() const { return m__parent; } + }; + + class vss_variable_t : public kaitai::kstruct { + + public: + + vss_variable_t(kaitai::kstream* p__io, edk2_vss_t::vss_store_body_t* p__parent = nullptr, edk2_vss_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~vss_variable_t(); + + private: + bool f_is_auth; + bool m_is_auth; + + public: + bool is_auth(); + + private: + bool f_len_standard_header; + int8_t m_len_standard_header; + + public: + int8_t len_standard_header(); + + private: + bool f_is_intel_legacy; + bool m_is_intel_legacy; + + public: + bool is_intel_legacy(); + + private: + bool f_len_auth_header; + int8_t m_len_auth_header; + + public: + int8_t len_auth_header(); + + private: + bool f_len_apple_header; + int8_t m_len_apple_header; + + public: + int8_t len_apple_header(); + + private: + bool f_len_intel_legacy_header; + int8_t m_len_intel_legacy_header; + + public: + int8_t len_intel_legacy_header(); + + private: + bool f_is_valid; + bool m_is_valid; + + public: + bool is_valid(); + + private: + uint8_t m_signature_first; + uint8_t m_signature_last; + bool n_signature_last; + + public: + bool _is_null_signature_last() { signature_last(); return n_signature_last; }; + + private: + uint8_t m_state; + bool n_state; + + public: + bool _is_null_state() { state(); return n_state; }; + + private: + uint8_t m_reserved; + bool n_reserved; + + public: + bool _is_null_reserved() { reserved(); return n_reserved; }; + + private: + std::unique_ptr m_attributes; + bool n_attributes; + + public: + bool _is_null_attributes() { attributes(); return n_attributes; }; + + private: + uint32_t m_len_total; + bool n_len_total; + + public: + bool _is_null_len_total() { len_total(); return n_len_total; }; + + private: + uint32_t m_len_name; + bool n_len_name; + + public: + bool _is_null_len_name() { len_name(); return n_len_name; }; + + private: + uint32_t m_len_data; + bool n_len_data; + + public: + bool _is_null_len_data() { len_data(); return n_len_data; }; + + private: + std::string m_timestamp; + bool n_timestamp; + + public: + bool _is_null_timestamp() { timestamp(); return n_timestamp; }; + + private: + uint32_t m_pubkey_index; + bool n_pubkey_index; + + public: + bool _is_null_pubkey_index() { pubkey_index(); return n_pubkey_index; }; + + private: + uint32_t m_len_name_auth; + bool n_len_name_auth; + + public: + bool _is_null_len_name_auth() { len_name_auth(); return n_len_name_auth; }; + + private: + uint32_t m_len_data_auth; + bool n_len_data_auth; + + public: + bool _is_null_len_data_auth() { len_data_auth(); return n_len_data_auth; }; + + private: + std::string m_vendor_guid; + bool n_vendor_guid; + + public: + bool _is_null_vendor_guid() { vendor_guid(); return n_vendor_guid; }; + + private: + std::string m_name_auth; + bool n_name_auth; + + public: + bool _is_null_name_auth() { name_auth(); return n_name_auth; }; + + private: + std::string m_data_auth; + bool n_data_auth; + + public: + bool _is_null_data_auth() { data_auth(); return n_data_auth; }; + + private: + uint32_t m_apple_data_crc32; + bool n_apple_data_crc32; + + public: + bool _is_null_apple_data_crc32() { apple_data_crc32(); return n_apple_data_crc32; }; + + private: + std::string m_intel_legacy_data; + bool n_intel_legacy_data; + + public: + bool _is_null_intel_legacy_data() { intel_legacy_data(); return n_intel_legacy_data; }; + + private: + std::string m_name; + bool n_name; + + public: + bool _is_null_name() { name(); return n_name; }; + + private: + std::string m_data; + bool n_data; + + public: + bool _is_null_data() { data(); return n_data; }; + + private: + edk2_vss_t* m__root; + edk2_vss_t::vss_store_body_t* m__parent; + + public: + uint8_t signature_first() const { return m_signature_first; } + uint8_t signature_last() const { return m_signature_last; } + uint8_t state() const { return m_state; } + uint8_t reserved() const { return m_reserved; } + vss_variable_attributes_t* attributes() const { return m_attributes.get(); } + uint32_t len_total() const { return m_len_total; } + uint32_t len_name() const { return m_len_name; } + uint32_t len_data() const { return m_len_data; } + std::string timestamp() const { return m_timestamp; } + uint32_t pubkey_index() const { return m_pubkey_index; } + uint32_t len_name_auth() const { return m_len_name_auth; } + uint32_t len_data_auth() const { return m_len_data_auth; } + std::string vendor_guid() const { return m_vendor_guid; } + std::string name_auth() const { return m_name_auth; } + std::string data_auth() const { return m_data_auth; } + uint32_t apple_data_crc32() const { return m_apple_data_crc32; } + std::string intel_legacy_data() const { return m_intel_legacy_data; } + std::string name() const { return m_name; } + std::string data() const { return m_data; } + edk2_vss_t* _root() const { return m__root; } + edk2_vss_t::vss_store_body_t* _parent() const { return m__parent; } + }; + +private: + bool f_len_vss_store_header; + int8_t m_len_vss_store_header; + +public: + int8_t len_vss_store_header(); + +private: + uint32_t m_signature; + uint32_t m_vss_size; + uint8_t m_format; + uint8_t m_state; + uint16_t m_reserved; + uint32_t m_reserved1; + std::unique_ptr m_body; + edk2_vss_t* m__root; + kaitai::kstruct* m__parent; + std::string m__raw_body; + std::unique_ptr m__io__raw_body; + +public: + uint32_t signature() const { return m_signature; } + uint32_t vss_size() const { return m_vss_size; } + uint8_t format() const { return m_format; } + uint8_t state() const { return m_state; } + uint16_t reserved() const { return m_reserved; } + uint32_t reserved1() const { return m_reserved1; } + vss_store_body_t* body() const { return m_body.get(); } + edk2_vss_t* _root() const { return m__root; } + kaitai::kstruct* _parent() const { return m__parent; } + std::string _raw_body() const { return m__raw_body; } + kaitai::kstream* _io__raw_body() const { return m__io__raw_body.get(); } +}; diff --git a/common/generated/edk2_vss2.cpp b/common/generated/edk2_vss2.cpp new file mode 100644 index 0000000..7e2e3f5 --- /dev/null +++ b/common/generated/edk2_vss2.cpp @@ -0,0 +1,342 @@ +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "edk2_vss2.h" +#include "../kaitai/exceptions.h" + +edk2_vss2_t::edk2_vss2_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent, edk2_vss2_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = this; (void)p__root; + m_body = nullptr; + m__io__raw_body = nullptr; + f_len_vss2_store_header = false; + _read(); +} + +void edk2_vss2_t::_read() { + m_signature = m__io->read_bytes(16); + m_vss2_size = m__io->read_u4le(); + { + uint32_t _ = vss2_size(); + if (!( ((_ > static_cast(len_vss2_store_header())) && (_ < 4294967295UL)) )) { + throw kaitai::validation_expr_error(vss2_size(), _io(), std::string("/seq/1")); + } + } + m_format = m__io->read_u1(); + m_state = m__io->read_u1(); + m_reserved = m__io->read_u2le(); + m_reserved1 = m__io->read_u4le(); + m__raw_body = m__io->read_bytes((vss2_size() - len_vss2_store_header())); + m__io__raw_body = std::unique_ptr(new kaitai::kstream(m__raw_body)); + m_body = std::unique_ptr(new vss2_store_body_t(m__io__raw_body.get(), this, m__root)); +} + +edk2_vss2_t::~edk2_vss2_t() { + _clean_up(); +} + +void edk2_vss2_t::_clean_up() { +} + +edk2_vss2_t::vss2_store_body_t::vss2_store_body_t(kaitai::kstream* p__io, edk2_vss2_t* p__parent, edk2_vss2_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + m_variables = nullptr; + _read(); +} + +void edk2_vss2_t::vss2_store_body_t::_read() { + m_variables = std::unique_ptr>>(new std::vector>()); + { + int i = 0; + vss2_variable_t* _; + do { + _ = new vss2_variable_t(m__io, this, m__root); + m_variables->push_back(std::move(std::unique_ptr(_))); + i++; + } while (!( ((_->signature_first() != 170) || (_io()->is_eof())) )); + } +} + +edk2_vss2_t::vss2_store_body_t::~vss2_store_body_t() { + _clean_up(); +} + +void edk2_vss2_t::vss2_store_body_t::_clean_up() { +} + +edk2_vss2_t::vss2_variable_attributes_t::vss2_variable_attributes_t(kaitai::kstream* p__io, edk2_vss2_t::vss2_variable_t* p__parent, edk2_vss2_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + _read(); +} + +void edk2_vss2_t::vss2_variable_attributes_t::_read() { + m_non_volatile = m__io->read_bits_int_le(1); + m_boot_service = m__io->read_bits_int_le(1); + m_runtime = m__io->read_bits_int_le(1); + m_hw_error_record = m__io->read_bits_int_le(1); + m_auth_write = m__io->read_bits_int_le(1); + m_time_based_auth = m__io->read_bits_int_le(1); + m_append_write = m__io->read_bits_int_le(1); + m_reserved = m__io->read_bits_int_le(25); +} + +edk2_vss2_t::vss2_variable_attributes_t::~vss2_variable_attributes_t() { + _clean_up(); +} + +void edk2_vss2_t::vss2_variable_attributes_t::_clean_up() { +} + +edk2_vss2_t::vss2_variable_t::vss2_variable_t(kaitai::kstream* p__io, edk2_vss2_t::vss2_store_body_t* p__parent, edk2_vss2_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + m_attributes = nullptr; + f_is_auth = false; + f_len_standard_header = false; + f_end_offset_auth = false; + f_len_alignment_padding = false; + f_len_auth_header = false; + f_end_offset = false; + f_len_alignment_padding_auth = false; + f_is_valid = false; + f_offset = false; + _read(); +} + +void edk2_vss2_t::vss2_variable_t::_read() { + n_invoke_offset = true; + if (offset() >= 0) { + n_invoke_offset = false; + m_invoke_offset = m__io->read_bytes(0); + } + m_signature_first = m__io->read_u1(); + n_signature_last = true; + if (signature_first() == 170) { + n_signature_last = false; + m_signature_last = m__io->read_u1(); + { + uint8_t _ = signature_last(); + if (!(_ == 85)) { + throw kaitai::validation_expr_error(signature_last(), _io(), std::string("/types/vss2_variable/seq/2")); + } + } + } + n_state = true; + if (signature_first() == 170) { + n_state = false; + m_state = m__io->read_u1(); + } + n_reserved = true; + if (signature_first() == 170) { + n_reserved = false; + m_reserved = m__io->read_u1(); + } + n_attributes = true; + if (signature_first() == 170) { + n_attributes = false; + m_attributes = std::unique_ptr(new vss2_variable_attributes_t(m__io, this, m__root)); + } + n_len_name = true; + if (signature_first() == 170) { + n_len_name = false; + m_len_name = m__io->read_u4le(); + } + n_len_data = true; + if (signature_first() == 170) { + n_len_data = false; + m_len_data = m__io->read_u4le(); + } + n_timestamp = true; + if ( ((signature_first() == 170) && (is_auth())) ) { + n_timestamp = false; + m_timestamp = m__io->read_bytes(16); + } + n_pubkey_index = true; + if ( ((signature_first() == 170) && (is_auth())) ) { + n_pubkey_index = false; + m_pubkey_index = m__io->read_u4le(); + } + n_len_name_auth = true; + if ( ((signature_first() == 170) && (is_auth())) ) { + n_len_name_auth = false; + m_len_name_auth = m__io->read_u4le(); + } + n_len_data_auth = true; + if ( ((signature_first() == 170) && (is_auth())) ) { + n_len_data_auth = false; + m_len_data_auth = m__io->read_u4le(); + } + n_vendor_guid = true; + if (signature_first() == 170) { + n_vendor_guid = false; + m_vendor_guid = m__io->read_bytes(16); + } + n_name_auth = true; + if ( ((signature_first() == 170) && (is_auth())) ) { + n_name_auth = false; + m_name_auth = m__io->read_bytes(len_name_auth()); + } + n_data_auth = true; + if ( ((signature_first() == 170) && (is_auth())) ) { + n_data_auth = false; + m_data_auth = m__io->read_bytes(len_data_auth()); + } + n_invoke_end_offset_auth = true; + if ( ((signature_first() == 170) && (is_auth()) && (end_offset_auth() >= 0)) ) { + n_invoke_end_offset_auth = false; + m_invoke_end_offset_auth = m__io->read_bytes(0); + } + n_alignment_padding_auth = true; + if ( ((signature_first() == 170) && (is_auth())) ) { + n_alignment_padding_auth = false; + m_alignment_padding_auth = m__io->read_bytes(len_alignment_padding_auth()); + } + n_name = true; + if ( ((signature_first() == 170) && (!(is_auth()))) ) { + n_name = false; + m_name = m__io->read_bytes(len_name()); + } + n_data = true; + if ( ((signature_first() == 170) && (!(is_auth()))) ) { + n_data = false; + m_data = m__io->read_bytes(len_data()); + } + n_invoke_end_offset = true; + if ( ((signature_first() == 170) && (!(is_auth())) && (end_offset() >= 0)) ) { + n_invoke_end_offset = false; + m_invoke_end_offset = m__io->read_bytes(0); + } + n_alignment_padding = true; + if ( ((signature_first() == 170) && (!(is_auth()))) ) { + n_alignment_padding = false; + m_alignment_padding = m__io->read_bytes(len_alignment_padding()); + } +} + +edk2_vss2_t::vss2_variable_t::~vss2_variable_t() { + _clean_up(); +} + +void edk2_vss2_t::vss2_variable_t::_clean_up() { + if (!n_invoke_offset) { + } + if (!n_signature_last) { + } + if (!n_state) { + } + if (!n_reserved) { + } + if (!n_attributes) { + } + if (!n_len_name) { + } + if (!n_len_data) { + } + if (!n_timestamp) { + } + if (!n_pubkey_index) { + } + if (!n_len_name_auth) { + } + if (!n_len_data_auth) { + } + if (!n_vendor_guid) { + } + if (!n_name_auth) { + } + if (!n_data_auth) { + } + if (!n_invoke_end_offset_auth) { + } + if (!n_alignment_padding_auth) { + } + if (!n_name) { + } + if (!n_data) { + } + if (!n_invoke_end_offset) { + } + if (!n_alignment_padding) { + } +} + +bool edk2_vss2_t::vss2_variable_t::is_auth() { + if (f_is_auth) + return m_is_auth; + m_is_auth = (( ((attributes()->auth_write()) || (attributes()->time_based_auth()) || (attributes()->append_write())) ) || ( ((len_name() == 0) || (len_data() == 0)) )) ; + f_is_auth = true; + return m_is_auth; +} + +int8_t edk2_vss2_t::vss2_variable_t::len_standard_header() { + if (f_len_standard_header) + return m_len_standard_header; + m_len_standard_header = 32; + f_len_standard_header = true; + return m_len_standard_header; +} + +int32_t edk2_vss2_t::vss2_variable_t::end_offset_auth() { + if (f_end_offset_auth) + return m_end_offset_auth; + m_end_offset_auth = (int32_t)_io()->pos(); + f_end_offset_auth = true; + return m_end_offset_auth; +} + +int32_t edk2_vss2_t::vss2_variable_t::len_alignment_padding() { + if (f_len_alignment_padding) + return m_len_alignment_padding; + m_len_alignment_padding = ((((end_offset() - offset()) + 3) & ~3) - (end_offset() - offset())); + f_len_alignment_padding = true; + return m_len_alignment_padding; +} + +int8_t edk2_vss2_t::vss2_variable_t::len_auth_header() { + if (f_len_auth_header) + return m_len_auth_header; + m_len_auth_header = 60; + f_len_auth_header = true; + return m_len_auth_header; +} + +int32_t edk2_vss2_t::vss2_variable_t::end_offset() { + if (f_end_offset) + return m_end_offset; + m_end_offset = (int32_t)_io()->pos(); + f_end_offset = true; + return m_end_offset; +} + +int32_t edk2_vss2_t::vss2_variable_t::len_alignment_padding_auth() { + if (f_len_alignment_padding_auth) + return m_len_alignment_padding_auth; + m_len_alignment_padding_auth = ((((end_offset_auth() - offset()) + 3) & ~3) - (end_offset_auth() - offset())); + f_len_alignment_padding_auth = true; + return m_len_alignment_padding_auth; +} + +bool edk2_vss2_t::vss2_variable_t::is_valid() { + if (f_is_valid) + return m_is_valid; + m_is_valid = ((state() == 127) || (state() == 63)) ; + f_is_valid = true; + return m_is_valid; +} + +int32_t edk2_vss2_t::vss2_variable_t::offset() { + if (f_offset) + return m_offset; + m_offset = (int32_t)_io()->pos(); + f_offset = true; + return m_offset; +} + +int32_t edk2_vss2_t::len_vss2_store_header() { + if (f_len_vss2_store_header) + return m_len_vss2_store_header; + m_len_vss2_store_header = (7 * 4); + f_len_vss2_store_header = true; + return m_len_vss2_store_header; +} diff --git a/common/generated/edk2_vss2.h b/common/generated/edk2_vss2.h new file mode 100644 index 0000000..3053a8e --- /dev/null +++ b/common/generated/edk2_vss2.h @@ -0,0 +1,371 @@ +#pragma once + +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "../kaitai/kaitaistruct.h" +#include +#include +#include + +#if KAITAI_STRUCT_VERSION < 9000L +#error "Incompatible Kaitai Struct C++/STL API: version 0.9 or later is required" +#endif + +class edk2_vss2_t : public kaitai::kstruct { + +public: + class vss2_store_body_t; + class vss2_variable_attributes_t; + class vss2_variable_t; + + edk2_vss2_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent = nullptr, edk2_vss2_t* p__root = nullptr); + +private: + void _read(); + void _clean_up(); + +public: + ~edk2_vss2_t(); + + class vss2_store_body_t : public kaitai::kstruct { + + public: + + vss2_store_body_t(kaitai::kstream* p__io, edk2_vss2_t* p__parent = nullptr, edk2_vss2_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~vss2_store_body_t(); + + private: + std::unique_ptr>> m_variables; + edk2_vss2_t* m__root; + edk2_vss2_t* m__parent; + + public: + std::vector>* variables() const { return m_variables.get(); } + edk2_vss2_t* _root() const { return m__root; } + edk2_vss2_t* _parent() const { return m__parent; } + }; + + class vss2_variable_attributes_t : public kaitai::kstruct { + + public: + + vss2_variable_attributes_t(kaitai::kstream* p__io, edk2_vss2_t::vss2_variable_t* p__parent = nullptr, edk2_vss2_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~vss2_variable_attributes_t(); + + private: + bool m_non_volatile; + bool m_boot_service; + bool m_runtime; + bool m_hw_error_record; + bool m_auth_write; + bool m_time_based_auth; + bool m_append_write; + uint64_t m_reserved; + edk2_vss2_t* m__root; + edk2_vss2_t::vss2_variable_t* m__parent; + + public: + bool non_volatile() const { return m_non_volatile; } + bool boot_service() const { return m_boot_service; } + bool runtime() const { return m_runtime; } + bool hw_error_record() const { return m_hw_error_record; } + bool auth_write() const { return m_auth_write; } + bool time_based_auth() const { return m_time_based_auth; } + bool append_write() const { return m_append_write; } + uint64_t reserved() const { return m_reserved; } + edk2_vss2_t* _root() const { return m__root; } + edk2_vss2_t::vss2_variable_t* _parent() const { return m__parent; } + }; + + class vss2_variable_t : public kaitai::kstruct { + + public: + + vss2_variable_t(kaitai::kstream* p__io, edk2_vss2_t::vss2_store_body_t* p__parent = nullptr, edk2_vss2_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~vss2_variable_t(); + + private: + bool f_is_auth; + bool m_is_auth; + + public: + bool is_auth(); + + private: + bool f_len_standard_header; + int8_t m_len_standard_header; + + public: + int8_t len_standard_header(); + + private: + bool f_end_offset_auth; + int32_t m_end_offset_auth; + + public: + int32_t end_offset_auth(); + + private: + bool f_len_alignment_padding; + int32_t m_len_alignment_padding; + + public: + int32_t len_alignment_padding(); + + private: + bool f_len_auth_header; + int8_t m_len_auth_header; + + public: + int8_t len_auth_header(); + + private: + bool f_end_offset; + int32_t m_end_offset; + + public: + int32_t end_offset(); + + private: + bool f_len_alignment_padding_auth; + int32_t m_len_alignment_padding_auth; + + public: + int32_t len_alignment_padding_auth(); + + private: + bool f_is_valid; + bool m_is_valid; + + public: + bool is_valid(); + + private: + bool f_offset; + int32_t m_offset; + + public: + int32_t offset(); + + private: + std::string m_invoke_offset; + bool n_invoke_offset; + + public: + bool _is_null_invoke_offset() { invoke_offset(); return n_invoke_offset; }; + + private: + uint8_t m_signature_first; + uint8_t m_signature_last; + bool n_signature_last; + + public: + bool _is_null_signature_last() { signature_last(); return n_signature_last; }; + + private: + uint8_t m_state; + bool n_state; + + public: + bool _is_null_state() { state(); return n_state; }; + + private: + uint8_t m_reserved; + bool n_reserved; + + public: + bool _is_null_reserved() { reserved(); return n_reserved; }; + + private: + std::unique_ptr m_attributes; + bool n_attributes; + + public: + bool _is_null_attributes() { attributes(); return n_attributes; }; + + private: + uint32_t m_len_name; + bool n_len_name; + + public: + bool _is_null_len_name() { len_name(); return n_len_name; }; + + private: + uint32_t m_len_data; + bool n_len_data; + + public: + bool _is_null_len_data() { len_data(); return n_len_data; }; + + private: + std::string m_timestamp; + bool n_timestamp; + + public: + bool _is_null_timestamp() { timestamp(); return n_timestamp; }; + + private: + uint32_t m_pubkey_index; + bool n_pubkey_index; + + public: + bool _is_null_pubkey_index() { pubkey_index(); return n_pubkey_index; }; + + private: + uint32_t m_len_name_auth; + bool n_len_name_auth; + + public: + bool _is_null_len_name_auth() { len_name_auth(); return n_len_name_auth; }; + + private: + uint32_t m_len_data_auth; + bool n_len_data_auth; + + public: + bool _is_null_len_data_auth() { len_data_auth(); return n_len_data_auth; }; + + private: + std::string m_vendor_guid; + bool n_vendor_guid; + + public: + bool _is_null_vendor_guid() { vendor_guid(); return n_vendor_guid; }; + + private: + std::string m_name_auth; + bool n_name_auth; + + public: + bool _is_null_name_auth() { name_auth(); return n_name_auth; }; + + private: + std::string m_data_auth; + bool n_data_auth; + + public: + bool _is_null_data_auth() { data_auth(); return n_data_auth; }; + + private: + std::string m_invoke_end_offset_auth; + bool n_invoke_end_offset_auth; + + public: + bool _is_null_invoke_end_offset_auth() { invoke_end_offset_auth(); return n_invoke_end_offset_auth; }; + + private: + std::string m_alignment_padding_auth; + bool n_alignment_padding_auth; + + public: + bool _is_null_alignment_padding_auth() { alignment_padding_auth(); return n_alignment_padding_auth; }; + + private: + std::string m_name; + bool n_name; + + public: + bool _is_null_name() { name(); return n_name; }; + + private: + std::string m_data; + bool n_data; + + public: + bool _is_null_data() { data(); return n_data; }; + + private: + std::string m_invoke_end_offset; + bool n_invoke_end_offset; + + public: + bool _is_null_invoke_end_offset() { invoke_end_offset(); return n_invoke_end_offset; }; + + private: + std::string m_alignment_padding; + bool n_alignment_padding; + + public: + bool _is_null_alignment_padding() { alignment_padding(); return n_alignment_padding; }; + + private: + edk2_vss2_t* m__root; + edk2_vss2_t::vss2_store_body_t* m__parent; + + public: + std::string invoke_offset() const { return m_invoke_offset; } + uint8_t signature_first() const { return m_signature_first; } + uint8_t signature_last() const { return m_signature_last; } + uint8_t state() const { return m_state; } + uint8_t reserved() const { return m_reserved; } + vss2_variable_attributes_t* attributes() const { return m_attributes.get(); } + uint32_t len_name() const { return m_len_name; } + uint32_t len_data() const { return m_len_data; } + std::string timestamp() const { return m_timestamp; } + uint32_t pubkey_index() const { return m_pubkey_index; } + uint32_t len_name_auth() const { return m_len_name_auth; } + uint32_t len_data_auth() const { return m_len_data_auth; } + std::string vendor_guid() const { return m_vendor_guid; } + std::string name_auth() const { return m_name_auth; } + std::string data_auth() const { return m_data_auth; } + std::string invoke_end_offset_auth() const { return m_invoke_end_offset_auth; } + std::string alignment_padding_auth() const { return m_alignment_padding_auth; } + std::string name() const { return m_name; } + std::string data() const { return m_data; } + std::string invoke_end_offset() const { return m_invoke_end_offset; } + std::string alignment_padding() const { return m_alignment_padding; } + edk2_vss2_t* _root() const { return m__root; } + edk2_vss2_t::vss2_store_body_t* _parent() const { return m__parent; } + }; + +private: + bool f_len_vss2_store_header; + int32_t m_len_vss2_store_header; + +public: + int32_t len_vss2_store_header(); + +private: + std::string m_signature; + uint32_t m_vss2_size; + uint8_t m_format; + uint8_t m_state; + uint16_t m_reserved; + uint32_t m_reserved1; + std::unique_ptr m_body; + edk2_vss2_t* m__root; + kaitai::kstruct* m__parent; + std::string m__raw_body; + std::unique_ptr m__io__raw_body; + +public: + std::string signature() const { return m_signature; } + uint32_t vss2_size() const { return m_vss2_size; } + uint8_t format() const { return m_format; } + uint8_t state() const { return m_state; } + uint16_t reserved() const { return m_reserved; } + uint32_t reserved1() const { return m_reserved1; } + vss2_store_body_t* body() const { return m_body.get(); } + edk2_vss2_t* _root() const { return m__root; } + kaitai::kstruct* _parent() const { return m__parent; } + std::string _raw_body() const { return m__raw_body; } + kaitai::kstream* _io__raw_body() const { return m__io__raw_body.get(); } +}; diff --git a/common/generated/insyde_fdc.cpp b/common/generated/insyde_fdc.cpp new file mode 100644 index 0000000..7a3080e --- /dev/null +++ b/common/generated/insyde_fdc.cpp @@ -0,0 +1,38 @@ +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "insyde_fdc.h" +#include "../kaitai/exceptions.h" + +insyde_fdc_t::insyde_fdc_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent, insyde_fdc_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = this; (void)p__root; + f_len_fdc_store_header = false; + _read(); +} + +void insyde_fdc_t::_read() { + m_signature = m__io->read_u4le(); + m_fdc_size = m__io->read_u4le(); + { + uint32_t _ = fdc_size(); + if (!( ((_ > static_cast(len_fdc_store_header())) && (_ < 4294967295UL)) )) { + throw kaitai::validation_expr_error(fdc_size(), _io(), std::string("/seq/1")); + } + } + m_body = m__io->read_bytes((fdc_size() - len_fdc_store_header())); +} + +insyde_fdc_t::~insyde_fdc_t() { + _clean_up(); +} + +void insyde_fdc_t::_clean_up() { +} + +int8_t insyde_fdc_t::len_fdc_store_header() { + if (f_len_fdc_store_header) + return m_len_fdc_store_header; + m_len_fdc_store_header = 80; + f_len_fdc_store_header = true; + return m_len_fdc_store_header; +} diff --git a/common/generated/insyde_fdc.h b/common/generated/insyde_fdc.h new file mode 100644 index 0000000..3e8d8a7 --- /dev/null +++ b/common/generated/insyde_fdc.h @@ -0,0 +1,46 @@ +#pragma once + +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "../kaitai/kaitaistruct.h" +#include +#include + +#if KAITAI_STRUCT_VERSION < 9000L +#error "Incompatible Kaitai Struct C++/STL API: version 0.9 or later is required" +#endif + +class insyde_fdc_t : public kaitai::kstruct { + +public: + + insyde_fdc_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent = nullptr, insyde_fdc_t* p__root = nullptr); + +private: + void _read(); + void _clean_up(); + +public: + ~insyde_fdc_t(); + +private: + bool f_len_fdc_store_header; + int8_t m_len_fdc_store_header; + +public: + int8_t len_fdc_store_header(); + +private: + uint32_t m_signature; + uint32_t m_fdc_size; + std::string m_body; + insyde_fdc_t* m__root; + kaitai::kstruct* m__parent; + +public: + uint32_t signature() const { return m_signature; } + uint32_t fdc_size() const { return m_fdc_size; } + std::string body() const { return m_body; } + insyde_fdc_t* _root() const { return m__root; } + kaitai::kstruct* _parent() const { return m__parent; } +}; diff --git a/common/generated/insyde_fdm.cpp b/common/generated/insyde_fdm.cpp new file mode 100644 index 0000000..e5942d0 --- /dev/null +++ b/common/generated/insyde_fdm.cpp @@ -0,0 +1,175 @@ +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "insyde_fdm.h" + +insyde_fdm_t::insyde_fdm_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent, insyde_fdm_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = this; (void)p__root; + m_extensions = nullptr; + m__io__raw_extensions = nullptr; + m_board_ids = nullptr; + m_entries = nullptr; + m__io__raw_entries = nullptr; + _read(); +} + +void insyde_fdm_t::_read() { + m_signature = m__io->read_u4le(); + m_store_size = m__io->read_u4le(); + m_data_offset = m__io->read_u4le(); + m_entry_size = m__io->read_u4le(); + m_entry_format = m__io->read_u1(); + m_revision = m__io->read_u1(); + m_num_extensions = m__io->read_u1(); + m_checksum = m__io->read_u1(); + m_fd_base_address = m__io->read_u8le(); + n_extensions = true; + if (revision() > 2) { + n_extensions = false; + m__raw_extensions = m__io->read_bytes((num_extensions() * 4)); + m__io__raw_extensions = std::unique_ptr(new kaitai::kstream(m__raw_extensions)); + m_extensions = std::unique_ptr(new fdm_extensions_t(m__io__raw_extensions.get(), this, m__root)); + } + n_board_ids = true; + if ( ((revision() > 2) && (extensions()->extensions()->at(1)->count() > 0)) ) { + n_board_ids = false; + m_board_ids = std::unique_ptr(new fdm_board_ids_t(m__io, this, m__root)); + } + m__raw_entries = m__io->read_bytes((store_size() - data_offset())); + m__io__raw_entries = std::unique_ptr(new kaitai::kstream(m__raw_entries)); + m_entries = std::unique_ptr(new fdm_entries_t(m__io__raw_entries.get(), this, m__root)); +} + +insyde_fdm_t::~insyde_fdm_t() { + _clean_up(); +} + +void insyde_fdm_t::_clean_up() { + if (!n_extensions) { + } + if (!n_board_ids) { + } +} + +insyde_fdm_t::fdm_entries_t::fdm_entries_t(kaitai::kstream* p__io, insyde_fdm_t* p__parent, insyde_fdm_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + m_entries = nullptr; + _read(); +} + +void insyde_fdm_t::fdm_entries_t::_read() { + m_entries = std::unique_ptr>>(new std::vector>()); + { + int i = 0; + while (!m__io->is_eof()) { + m_entries->push_back(std::move(std::unique_ptr(new fdm_entry_t(m__io, this, m__root)))); + i++; + } + } +} + +insyde_fdm_t::fdm_entries_t::~fdm_entries_t() { + _clean_up(); +} + +void insyde_fdm_t::fdm_entries_t::_clean_up() { +} + +insyde_fdm_t::fdm_extension_t::fdm_extension_t(kaitai::kstream* p__io, insyde_fdm_t::fdm_extensions_t* p__parent, insyde_fdm_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + _read(); +} + +void insyde_fdm_t::fdm_extension_t::_read() { + m_offset = m__io->read_u2le(); + m_count = m__io->read_u2le(); +} + +insyde_fdm_t::fdm_extension_t::~fdm_extension_t() { + _clean_up(); +} + +void insyde_fdm_t::fdm_extension_t::_clean_up() { +} + +insyde_fdm_t::fdm_board_ids_t::fdm_board_ids_t(kaitai::kstream* p__io, insyde_fdm_t* p__parent, insyde_fdm_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + m_board_ids = nullptr; + _read(); +} + +void insyde_fdm_t::fdm_board_ids_t::_read() { + m_region_index = m__io->read_u4le(); + m_num_board_ids = m__io->read_u4le(); + m_board_ids = std::unique_ptr>(new std::vector()); + const int l_board_ids = num_board_ids(); + for (int i = 0; i < l_board_ids; i++) { + m_board_ids->push_back(std::move(m__io->read_u8le())); + } +} + +insyde_fdm_t::fdm_board_ids_t::~fdm_board_ids_t() { + _clean_up(); +} + +void insyde_fdm_t::fdm_board_ids_t::_clean_up() { +} + +insyde_fdm_t::fdm_extensions_t::fdm_extensions_t(kaitai::kstream* p__io, insyde_fdm_t* p__parent, insyde_fdm_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + m_extensions = nullptr; + _read(); +} + +void insyde_fdm_t::fdm_extensions_t::_read() { + m_extensions = std::unique_ptr>>(new std::vector>()); + { + int i = 0; + while (!m__io->is_eof()) { + m_extensions->push_back(std::move(std::unique_ptr(new fdm_extension_t(m__io, this, m__root)))); + i++; + } + } +} + +insyde_fdm_t::fdm_extensions_t::~fdm_extensions_t() { + _clean_up(); +} + +void insyde_fdm_t::fdm_extensions_t::_clean_up() { +} + +insyde_fdm_t::fdm_entry_t::fdm_entry_t(kaitai::kstream* p__io, insyde_fdm_t::fdm_entries_t* p__parent, insyde_fdm_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + f_region_base = false; + _read(); +} + +void insyde_fdm_t::fdm_entry_t::_read() { + m_guid = m__io->read_bytes(16); + m_region_id = m__io->read_bytes(16); + m_region_offset = m__io->read_u8le(); + m_region_size = m__io->read_u8le(); + m_attributes = m__io->read_u4le(); + m_hash = m__io->read_bytes((((((_parent()->_parent()->entry_size() - 16) - 16) - 8) - 8) - 4)); +} + +insyde_fdm_t::fdm_entry_t::~fdm_entry_t() { + _clean_up(); +} + +void insyde_fdm_t::fdm_entry_t::_clean_up() { +} + +int32_t insyde_fdm_t::fdm_entry_t::region_base() { + if (f_region_base) + return m_region_base; + m_region_base = (static_cast(_root()->fd_base_address()) + static_cast(region_offset())); + f_region_base = true; + return m_region_base; +} diff --git a/common/generated/insyde_fdm.h b/common/generated/insyde_fdm.h new file mode 100644 index 0000000..7bbd056 --- /dev/null +++ b/common/generated/insyde_fdm.h @@ -0,0 +1,232 @@ +#pragma once + +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "../kaitai/kaitaistruct.h" +#include +#include +#include + +#if KAITAI_STRUCT_VERSION < 9000L +#error "Incompatible Kaitai Struct C++/STL API: version 0.9 or later is required" +#endif + +class insyde_fdm_t : public kaitai::kstruct { + +public: + class fdm_entries_t; + class fdm_extension_t; + class fdm_board_ids_t; + class fdm_extensions_t; + class fdm_entry_t; + + insyde_fdm_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent = nullptr, insyde_fdm_t* p__root = nullptr); + +private: + void _read(); + void _clean_up(); + +public: + ~insyde_fdm_t(); + + class fdm_entries_t : public kaitai::kstruct { + + public: + + fdm_entries_t(kaitai::kstream* p__io, insyde_fdm_t* p__parent = nullptr, insyde_fdm_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~fdm_entries_t(); + + private: + std::unique_ptr>> m_entries; + insyde_fdm_t* m__root; + insyde_fdm_t* m__parent; + + public: + std::vector>* entries() const { return m_entries.get(); } + insyde_fdm_t* _root() const { return m__root; } + insyde_fdm_t* _parent() const { return m__parent; } + }; + + class fdm_extension_t : public kaitai::kstruct { + + public: + + fdm_extension_t(kaitai::kstream* p__io, insyde_fdm_t::fdm_extensions_t* p__parent = nullptr, insyde_fdm_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~fdm_extension_t(); + + private: + uint16_t m_offset; + uint16_t m_count; + insyde_fdm_t* m__root; + insyde_fdm_t::fdm_extensions_t* m__parent; + + public: + uint16_t offset() const { return m_offset; } + uint16_t count() const { return m_count; } + insyde_fdm_t* _root() const { return m__root; } + insyde_fdm_t::fdm_extensions_t* _parent() const { return m__parent; } + }; + + class fdm_board_ids_t : public kaitai::kstruct { + + public: + + fdm_board_ids_t(kaitai::kstream* p__io, insyde_fdm_t* p__parent = nullptr, insyde_fdm_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~fdm_board_ids_t(); + + private: + uint32_t m_region_index; + uint32_t m_num_board_ids; + std::unique_ptr> m_board_ids; + insyde_fdm_t* m__root; + insyde_fdm_t* m__parent; + + public: + uint32_t region_index() const { return m_region_index; } + uint32_t num_board_ids() const { return m_num_board_ids; } + std::vector* board_ids() const { return m_board_ids.get(); } + insyde_fdm_t* _root() const { return m__root; } + insyde_fdm_t* _parent() const { return m__parent; } + }; + + class fdm_extensions_t : public kaitai::kstruct { + + public: + + fdm_extensions_t(kaitai::kstream* p__io, insyde_fdm_t* p__parent = nullptr, insyde_fdm_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~fdm_extensions_t(); + + private: + std::unique_ptr>> m_extensions; + insyde_fdm_t* m__root; + insyde_fdm_t* m__parent; + + public: + std::vector>* extensions() const { return m_extensions.get(); } + insyde_fdm_t* _root() const { return m__root; } + insyde_fdm_t* _parent() const { return m__parent; } + }; + + class fdm_entry_t : public kaitai::kstruct { + + public: + + fdm_entry_t(kaitai::kstream* p__io, insyde_fdm_t::fdm_entries_t* p__parent = nullptr, insyde_fdm_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~fdm_entry_t(); + + private: + bool f_region_base; + int32_t m_region_base; + + public: + int32_t region_base(); + + private: + std::string m_guid; + std::string m_region_id; + uint64_t m_region_offset; + uint64_t m_region_size; + uint32_t m_attributes; + std::string m_hash; + insyde_fdm_t* m__root; + insyde_fdm_t::fdm_entries_t* m__parent; + + public: + std::string guid() const { return m_guid; } + std::string region_id() const { return m_region_id; } + uint64_t region_offset() const { return m_region_offset; } + uint64_t region_size() const { return m_region_size; } + uint32_t attributes() const { return m_attributes; } + std::string hash() const { return m_hash; } + insyde_fdm_t* _root() const { return m__root; } + insyde_fdm_t::fdm_entries_t* _parent() const { return m__parent; } + }; + +private: + uint32_t m_signature; + uint32_t m_store_size; + uint32_t m_data_offset; + uint32_t m_entry_size; + uint8_t m_entry_format; + uint8_t m_revision; + uint8_t m_num_extensions; + uint8_t m_checksum; + uint64_t m_fd_base_address; + std::unique_ptr m_extensions; + bool n_extensions; + +public: + bool _is_null_extensions() { extensions(); return n_extensions; }; + +private: + std::unique_ptr m_board_ids; + bool n_board_ids; + +public: + bool _is_null_board_ids() { board_ids(); return n_board_ids; }; + +private: + std::unique_ptr m_entries; + insyde_fdm_t* m__root; + kaitai::kstruct* m__parent; + std::string m__raw_extensions; + bool n__raw_extensions; + +public: + bool _is_null__raw_extensions() { _raw_extensions(); return n__raw_extensions; }; + +private: + std::unique_ptr m__io__raw_extensions; + std::string m__raw_entries; + std::unique_ptr m__io__raw_entries; + +public: + uint32_t signature() const { return m_signature; } + uint32_t store_size() const { return m_store_size; } + uint32_t data_offset() const { return m_data_offset; } + uint32_t entry_size() const { return m_entry_size; } + uint8_t entry_format() const { return m_entry_format; } + uint8_t revision() const { return m_revision; } + uint8_t num_extensions() const { return m_num_extensions; } + uint8_t checksum() const { return m_checksum; } + uint64_t fd_base_address() const { return m_fd_base_address; } + fdm_extensions_t* extensions() const { return m_extensions.get(); } + fdm_board_ids_t* board_ids() const { return m_board_ids.get(); } + fdm_entries_t* entries() const { return m_entries.get(); } + insyde_fdm_t* _root() const { return m__root; } + kaitai::kstruct* _parent() const { return m__parent; } + std::string _raw_extensions() const { return m__raw_extensions; } + kaitai::kstream* _io__raw_extensions() const { return m__io__raw_extensions.get(); } + std::string _raw_entries() const { return m__raw_entries; } + kaitai::kstream* _io__raw_entries() const { return m__io__raw_entries.get(); } +}; diff --git a/common/generated/ms_slic_marker.cpp b/common/generated/ms_slic_marker.cpp new file mode 100644 index 0000000..ad7aa00 --- /dev/null +++ b/common/generated/ms_slic_marker.cpp @@ -0,0 +1,28 @@ +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "ms_slic_marker.h" + +ms_slic_marker_t::ms_slic_marker_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent, ms_slic_marker_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = this; (void)p__root; + _read(); +} + +void ms_slic_marker_t::_read() { + m_type = m__io->read_u4le(); + m_len_marker = m__io->read_u4le(); + m_version = m__io->read_u4le(); + m_oem_id = m__io->read_bytes(6); + m_oem_table_id = m__io->read_bytes(8); + m_windows_flag = m__io->read_u8le(); + m_slic_version = m__io->read_u4le(); + m_reserved = m__io->read_bytes(16); + m_signature = m__io->read_bytes(128); +} + +ms_slic_marker_t::~ms_slic_marker_t() { + _clean_up(); +} + +void ms_slic_marker_t::_clean_up() { +} diff --git a/common/generated/ms_slic_marker.h b/common/generated/ms_slic_marker.h new file mode 100644 index 0000000..a5935dc --- /dev/null +++ b/common/generated/ms_slic_marker.h @@ -0,0 +1,51 @@ +#pragma once + +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "../kaitai/kaitaistruct.h" +#include +#include + +#if KAITAI_STRUCT_VERSION < 9000L +#error "Incompatible Kaitai Struct C++/STL API: version 0.9 or later is required" +#endif + +class ms_slic_marker_t : public kaitai::kstruct { + +public: + + ms_slic_marker_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent = nullptr, ms_slic_marker_t* p__root = nullptr); + +private: + void _read(); + void _clean_up(); + +public: + ~ms_slic_marker_t(); + +private: + uint32_t m_type; + uint32_t m_len_marker; + uint32_t m_version; + std::string m_oem_id; + std::string m_oem_table_id; + uint64_t m_windows_flag; + uint32_t m_slic_version; + std::string m_reserved; + std::string m_signature; + ms_slic_marker_t* m__root; + kaitai::kstruct* m__parent; + +public: + uint32_t type() const { return m_type; } + uint32_t len_marker() const { return m_len_marker; } + uint32_t version() const { return m_version; } + std::string oem_id() const { return m_oem_id; } + std::string oem_table_id() const { return m_oem_table_id; } + uint64_t windows_flag() const { return m_windows_flag; } + uint32_t slic_version() const { return m_slic_version; } + std::string reserved() const { return m_reserved; } + std::string signature() const { return m_signature; } + ms_slic_marker_t* _root() const { return m__root; } + kaitai::kstruct* _parent() const { return m__parent; } +}; diff --git a/common/generated/ms_slic_pubkey.cpp b/common/generated/ms_slic_pubkey.cpp new file mode 100644 index 0000000..bfe2fb9 --- /dev/null +++ b/common/generated/ms_slic_pubkey.cpp @@ -0,0 +1,29 @@ +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "ms_slic_pubkey.h" + +ms_slic_pubkey_t::ms_slic_pubkey_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent, ms_slic_pubkey_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = this; (void)p__root; + _read(); +} + +void ms_slic_pubkey_t::_read() { + m_type = m__io->read_u4le(); + m_len_pubkey = m__io->read_u4le(); + m_key_type = m__io->read_u1(); + m_version = m__io->read_u1(); + m_reserved = m__io->read_u2le(); + m_algorithm = m__io->read_u4le(); + m_magic = m__io->read_u4le(); + m_bit_length = m__io->read_u4le(); + m_exponent = m__io->read_u4le(); + m_modulus = m__io->read_bytes(128); +} + +ms_slic_pubkey_t::~ms_slic_pubkey_t() { + _clean_up(); +} + +void ms_slic_pubkey_t::_clean_up() { +} diff --git a/common/generated/ms_slic_pubkey.h b/common/generated/ms_slic_pubkey.h new file mode 100644 index 0000000..75e7361 --- /dev/null +++ b/common/generated/ms_slic_pubkey.h @@ -0,0 +1,53 @@ +#pragma once + +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "../kaitai/kaitaistruct.h" +#include +#include + +#if KAITAI_STRUCT_VERSION < 9000L +#error "Incompatible Kaitai Struct C++/STL API: version 0.9 or later is required" +#endif + +class ms_slic_pubkey_t : public kaitai::kstruct { + +public: + + ms_slic_pubkey_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent = nullptr, ms_slic_pubkey_t* p__root = nullptr); + +private: + void _read(); + void _clean_up(); + +public: + ~ms_slic_pubkey_t(); + +private: + uint32_t m_type; + uint32_t m_len_pubkey; + uint8_t m_key_type; + uint8_t m_version; + uint16_t m_reserved; + uint32_t m_algorithm; + uint32_t m_magic; + uint32_t m_bit_length; + uint32_t m_exponent; + std::string m_modulus; + ms_slic_pubkey_t* m__root; + kaitai::kstruct* m__parent; + +public: + uint32_t type() const { return m_type; } + uint32_t len_pubkey() const { return m_len_pubkey; } + uint8_t key_type() const { return m_key_type; } + uint8_t version() const { return m_version; } + uint16_t reserved() const { return m_reserved; } + uint32_t algorithm() const { return m_algorithm; } + uint32_t magic() const { return m_magic; } + uint32_t bit_length() const { return m_bit_length; } + uint32_t exponent() const { return m_exponent; } + std::string modulus() const { return m_modulus; } + ms_slic_pubkey_t* _root() const { return m__root; } + kaitai::kstruct* _parent() const { return m__parent; } +}; diff --git a/common/generated/phoenix_evsa.cpp b/common/generated/phoenix_evsa.cpp new file mode 100644 index 0000000..c586711 --- /dev/null +++ b/common/generated/phoenix_evsa.cpp @@ -0,0 +1,259 @@ +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "phoenix_evsa.h" +#include "../kaitai/exceptions.h" + +phoenix_evsa_t::phoenix_evsa_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent, phoenix_evsa_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = this; (void)p__root; + m_body = nullptr; + m__io__raw_body = nullptr; + _read(); +} + +void phoenix_evsa_t::_read() { + m_type = m__io->read_u1(); + m_checksum = m__io->read_u1(); + m_len_evsa_store_header = m__io->read_u2le(); + m_signature = m__io->read_u4le(); + m_attributes = m__io->read_u4le(); + m_len_evsa_store = m__io->read_u4le(); + m_reserved = m__io->read_u4le(); + m__raw_body = m__io->read_bytes((len_evsa_store() - len_evsa_store_header())); + m__io__raw_body = std::unique_ptr(new kaitai::kstream(m__raw_body)); + m_body = std::unique_ptr(new evsa_body_t(m__io__raw_body.get(), this, m__root)); +} + +phoenix_evsa_t::~phoenix_evsa_t() { + _clean_up(); +} + +void phoenix_evsa_t::_clean_up() { +} + +phoenix_evsa_t::evsa_entry_t::evsa_entry_t(kaitai::kstream* p__io, phoenix_evsa_t::evsa_body_t* p__parent, phoenix_evsa_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + _read(); +} + +void phoenix_evsa_t::evsa_entry_t::_read() { + m_entry_type = m__io->read_u1(); + n_checksum = true; + if ( ((entry_type() == 225) || (entry_type() == 226) || (entry_type() == 227) || (entry_type() == 237) || (entry_type() == 238) || (entry_type() == 239) || (entry_type() == 131)) ) { + n_checksum = false; + m_checksum = m__io->read_u1(); + } + n_len_evsa_entry = true; + if ( ((entry_type() == 225) || (entry_type() == 226) || (entry_type() == 227) || (entry_type() == 237) || (entry_type() == 238) || (entry_type() == 239) || (entry_type() == 131)) ) { + n_len_evsa_entry = false; + m_len_evsa_entry = m__io->read_u2le(); + } + switch (entry_type()) { + case 239: { + m_body = std::unique_ptr(new evsa_data_t(m__io, this, m__root)); + break; + } + case 131: { + m_body = std::unique_ptr(new evsa_data_t(m__io, this, m__root)); + break; + } + case 227: { + m_body = std::unique_ptr(new evsa_data_t(m__io, this, m__root)); + break; + } + case 237: { + m_body = std::unique_ptr(new evsa_guid_t(m__io, this, m__root)); + break; + } + case 226: { + m_body = std::unique_ptr(new evsa_name_t(m__io, this, m__root)); + break; + } + case 225: { + m_body = std::unique_ptr(new evsa_guid_t(m__io, this, m__root)); + break; + } + case 238: { + m_body = std::unique_ptr(new evsa_name_t(m__io, this, m__root)); + break; + } + default: { + m_body = std::unique_ptr(new evsa_unknown_t(m__io, this, m__root)); + break; + } + } +} + +phoenix_evsa_t::evsa_entry_t::~evsa_entry_t() { + _clean_up(); +} + +void phoenix_evsa_t::evsa_entry_t::_clean_up() { + if (!n_checksum) { + } + if (!n_len_evsa_entry) { + } +} + +phoenix_evsa_t::evsa_unknown_t::evsa_unknown_t(kaitai::kstream* p__io, phoenix_evsa_t::evsa_entry_t* p__parent, phoenix_evsa_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + _read(); +} + +void phoenix_evsa_t::evsa_unknown_t::_read() { + m_unknown = m__io->read_bytes(0); +} + +phoenix_evsa_t::evsa_unknown_t::~evsa_unknown_t() { + _clean_up(); +} + +void phoenix_evsa_t::evsa_unknown_t::_clean_up() { +} + +phoenix_evsa_t::evsa_body_t::evsa_body_t(kaitai::kstream* p__io, phoenix_evsa_t* p__parent, phoenix_evsa_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + m_entries = nullptr; + m_free_space = nullptr; + _read(); +} + +void phoenix_evsa_t::evsa_body_t::_read() { + m_entries = std::unique_ptr>>(new std::vector>()); + { + int i = 0; + evsa_entry_t* _; + do { + _ = new evsa_entry_t(m__io, this, m__root); + m_entries->push_back(std::move(std::unique_ptr(_))); + i++; + } while (!( (( ((_->entry_type() != 237) && (_->entry_type() != 238) && (_->entry_type() != 239) && (_->entry_type() != 225) && (_->entry_type() != 226) && (_->entry_type() != 227) && (_->entry_type() != 131)) ) || (_io()->is_eof())) )); + } + m_free_space = std::unique_ptr>(new std::vector()); + { + int i = 0; + while (!m__io->is_eof()) { + m_free_space->push_back(std::move(m__io->read_u1())); + i++; + } + } +} + +phoenix_evsa_t::evsa_body_t::~evsa_body_t() { + _clean_up(); +} + +void phoenix_evsa_t::evsa_body_t::_clean_up() { +} + +phoenix_evsa_t::evsa_name_t::evsa_name_t(kaitai::kstream* p__io, phoenix_evsa_t::evsa_entry_t* p__parent, phoenix_evsa_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + _read(); +} + +void phoenix_evsa_t::evsa_name_t::_read() { + m_var_id = m__io->read_u2le(); + m_name = m__io->read_bytes((_parent()->len_evsa_entry() - 6)); +} + +phoenix_evsa_t::evsa_name_t::~evsa_name_t() { + _clean_up(); +} + +void phoenix_evsa_t::evsa_name_t::_clean_up() { +} + +phoenix_evsa_t::evsa_guid_t::evsa_guid_t(kaitai::kstream* p__io, phoenix_evsa_t::evsa_entry_t* p__parent, phoenix_evsa_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + _read(); +} + +void phoenix_evsa_t::evsa_guid_t::_read() { + m_guid_id = m__io->read_u2le(); + m_guid = m__io->read_bytes(16); + { + std::string _ = guid(); + if (!(_parent()->len_evsa_entry() == 22)) { + throw kaitai::validation_expr_error(guid(), _io(), std::string("/types/evsa_guid/seq/1")); + } + } +} + +phoenix_evsa_t::evsa_guid_t::~evsa_guid_t() { + _clean_up(); +} + +void phoenix_evsa_t::evsa_guid_t::_clean_up() { +} + +phoenix_evsa_t::evsa_variable_attributes_t::evsa_variable_attributes_t(kaitai::kstream* p__io, phoenix_evsa_t::evsa_data_t* p__parent, phoenix_evsa_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + _read(); +} + +void phoenix_evsa_t::evsa_variable_attributes_t::_read() { + m_non_volatile = m__io->read_bits_int_le(1); + m_boot_service = m__io->read_bits_int_le(1); + m_runtime = m__io->read_bits_int_le(1); + m_hw_error_record = m__io->read_bits_int_le(1); + m_auth_write = m__io->read_bits_int_le(1); + m_time_based_auth = m__io->read_bits_int_le(1); + m_append_write = m__io->read_bits_int_le(1); + m_reserved = m__io->read_bits_int_le(21); + m_extended_header = m__io->read_bits_int_le(1); + m_reserved1 = m__io->read_bits_int_le(3); +} + +phoenix_evsa_t::evsa_variable_attributes_t::~evsa_variable_attributes_t() { + _clean_up(); +} + +void phoenix_evsa_t::evsa_variable_attributes_t::_clean_up() { +} + +phoenix_evsa_t::evsa_data_t::evsa_data_t(kaitai::kstream* p__io, phoenix_evsa_t::evsa_entry_t* p__parent, phoenix_evsa_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + m_attributes = nullptr; + _read(); +} + +void phoenix_evsa_t::evsa_data_t::_read() { + m_guid_id = m__io->read_u2le(); + m_var_id = m__io->read_u2le(); + m_attributes = std::unique_ptr(new evsa_variable_attributes_t(m__io, this, m__root)); + n_len_data_ext = true; + if (attributes()->extended_header()) { + n_len_data_ext = false; + m_len_data_ext = m__io->read_u4le(); + } + n_data = true; + if (!(attributes()->extended_header())) { + n_data = false; + m_data = m__io->read_bytes((_parent()->len_evsa_entry() - 12)); + } + n_data_ext = true; + if (attributes()->extended_header()) { + n_data_ext = false; + m_data_ext = m__io->read_bytes(len_data_ext()); + } +} + +phoenix_evsa_t::evsa_data_t::~evsa_data_t() { + _clean_up(); +} + +void phoenix_evsa_t::evsa_data_t::_clean_up() { + if (!n_len_data_ext) { + } + if (!n_data) { + } + if (!n_data_ext) { + } +} diff --git a/common/generated/phoenix_evsa.h b/common/generated/phoenix_evsa.h new file mode 100644 index 0000000..694b39b --- /dev/null +++ b/common/generated/phoenix_evsa.h @@ -0,0 +1,299 @@ +#pragma once + +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "../kaitai/kaitaistruct.h" +#include +#include +#include + +#if KAITAI_STRUCT_VERSION < 9000L +#error "Incompatible Kaitai Struct C++/STL API: version 0.9 or later is required" +#endif + +class phoenix_evsa_t : public kaitai::kstruct { + +public: + class evsa_entry_t; + class evsa_unknown_t; + class evsa_body_t; + class evsa_name_t; + class evsa_guid_t; + class evsa_variable_attributes_t; + class evsa_data_t; + + phoenix_evsa_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent = nullptr, phoenix_evsa_t* p__root = nullptr); + +private: + void _read(); + void _clean_up(); + +public: + ~phoenix_evsa_t(); + + class evsa_entry_t : public kaitai::kstruct { + + public: + + evsa_entry_t(kaitai::kstream* p__io, phoenix_evsa_t::evsa_body_t* p__parent = nullptr, phoenix_evsa_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~evsa_entry_t(); + + private: + uint8_t m_entry_type; + uint8_t m_checksum; + bool n_checksum; + + public: + bool _is_null_checksum() { checksum(); return n_checksum; }; + + private: + uint16_t m_len_evsa_entry; + bool n_len_evsa_entry; + + public: + bool _is_null_len_evsa_entry() { len_evsa_entry(); return n_len_evsa_entry; }; + + private: + std::unique_ptr m_body; + phoenix_evsa_t* m__root; + phoenix_evsa_t::evsa_body_t* m__parent; + + public: + uint8_t entry_type() const { return m_entry_type; } + uint8_t checksum() const { return m_checksum; } + uint16_t len_evsa_entry() const { return m_len_evsa_entry; } + kaitai::kstruct* body() const { return m_body.get(); } + phoenix_evsa_t* _root() const { return m__root; } + phoenix_evsa_t::evsa_body_t* _parent() const { return m__parent; } + }; + + class evsa_unknown_t : public kaitai::kstruct { + + public: + + evsa_unknown_t(kaitai::kstream* p__io, phoenix_evsa_t::evsa_entry_t* p__parent = nullptr, phoenix_evsa_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~evsa_unknown_t(); + + private: + std::string m_unknown; + phoenix_evsa_t* m__root; + phoenix_evsa_t::evsa_entry_t* m__parent; + + public: + std::string unknown() const { return m_unknown; } + phoenix_evsa_t* _root() const { return m__root; } + phoenix_evsa_t::evsa_entry_t* _parent() const { return m__parent; } + }; + + class evsa_body_t : public kaitai::kstruct { + + public: + + evsa_body_t(kaitai::kstream* p__io, phoenix_evsa_t* p__parent = nullptr, phoenix_evsa_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~evsa_body_t(); + + private: + std::unique_ptr>> m_entries; + std::unique_ptr> m_free_space; + phoenix_evsa_t* m__root; + phoenix_evsa_t* m__parent; + + public: + std::vector>* entries() const { return m_entries.get(); } + std::vector* free_space() const { return m_free_space.get(); } + phoenix_evsa_t* _root() const { return m__root; } + phoenix_evsa_t* _parent() const { return m__parent; } + }; + + class evsa_name_t : public kaitai::kstruct { + + public: + + evsa_name_t(kaitai::kstream* p__io, phoenix_evsa_t::evsa_entry_t* p__parent = nullptr, phoenix_evsa_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~evsa_name_t(); + + private: + uint16_t m_var_id; + std::string m_name; + phoenix_evsa_t* m__root; + phoenix_evsa_t::evsa_entry_t* m__parent; + + public: + uint16_t var_id() const { return m_var_id; } + std::string name() const { return m_name; } + phoenix_evsa_t* _root() const { return m__root; } + phoenix_evsa_t::evsa_entry_t* _parent() const { return m__parent; } + }; + + class evsa_guid_t : public kaitai::kstruct { + + public: + + evsa_guid_t(kaitai::kstream* p__io, phoenix_evsa_t::evsa_entry_t* p__parent = nullptr, phoenix_evsa_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~evsa_guid_t(); + + private: + uint16_t m_guid_id; + std::string m_guid; + phoenix_evsa_t* m__root; + phoenix_evsa_t::evsa_entry_t* m__parent; + + public: + uint16_t guid_id() const { return m_guid_id; } + std::string guid() const { return m_guid; } + phoenix_evsa_t* _root() const { return m__root; } + phoenix_evsa_t::evsa_entry_t* _parent() const { return m__parent; } + }; + + class evsa_variable_attributes_t : public kaitai::kstruct { + + public: + + evsa_variable_attributes_t(kaitai::kstream* p__io, phoenix_evsa_t::evsa_data_t* p__parent = nullptr, phoenix_evsa_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~evsa_variable_attributes_t(); + + private: + bool m_non_volatile; + bool m_boot_service; + bool m_runtime; + bool m_hw_error_record; + bool m_auth_write; + bool m_time_based_auth; + bool m_append_write; + uint64_t m_reserved; + bool m_extended_header; + uint64_t m_reserved1; + phoenix_evsa_t* m__root; + phoenix_evsa_t::evsa_data_t* m__parent; + + public: + bool non_volatile() const { return m_non_volatile; } + bool boot_service() const { return m_boot_service; } + bool runtime() const { return m_runtime; } + bool hw_error_record() const { return m_hw_error_record; } + bool auth_write() const { return m_auth_write; } + bool time_based_auth() const { return m_time_based_auth; } + bool append_write() const { return m_append_write; } + uint64_t reserved() const { return m_reserved; } + bool extended_header() const { return m_extended_header; } + uint64_t reserved1() const { return m_reserved1; } + phoenix_evsa_t* _root() const { return m__root; } + phoenix_evsa_t::evsa_data_t* _parent() const { return m__parent; } + }; + + class evsa_data_t : public kaitai::kstruct { + + public: + + evsa_data_t(kaitai::kstream* p__io, phoenix_evsa_t::evsa_entry_t* p__parent = nullptr, phoenix_evsa_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~evsa_data_t(); + + private: + uint16_t m_guid_id; + uint16_t m_var_id; + std::unique_ptr m_attributes; + uint32_t m_len_data_ext; + bool n_len_data_ext; + + public: + bool _is_null_len_data_ext() { len_data_ext(); return n_len_data_ext; }; + + private: + std::string m_data; + bool n_data; + + public: + bool _is_null_data() { data(); return n_data; }; + + private: + std::string m_data_ext; + bool n_data_ext; + + public: + bool _is_null_data_ext() { data_ext(); return n_data_ext; }; + + private: + phoenix_evsa_t* m__root; + phoenix_evsa_t::evsa_entry_t* m__parent; + + public: + uint16_t guid_id() const { return m_guid_id; } + uint16_t var_id() const { return m_var_id; } + evsa_variable_attributes_t* attributes() const { return m_attributes.get(); } + uint32_t len_data_ext() const { return m_len_data_ext; } + std::string data() const { return m_data; } + std::string data_ext() const { return m_data_ext; } + phoenix_evsa_t* _root() const { return m__root; } + phoenix_evsa_t::evsa_entry_t* _parent() const { return m__parent; } + }; + +private: + uint8_t m_type; + uint8_t m_checksum; + uint16_t m_len_evsa_store_header; + uint32_t m_signature; + uint32_t m_attributes; + uint32_t m_len_evsa_store; + uint32_t m_reserved; + std::unique_ptr m_body; + phoenix_evsa_t* m__root; + kaitai::kstruct* m__parent; + std::string m__raw_body; + std::unique_ptr m__io__raw_body; + +public: + uint8_t type() const { return m_type; } + uint8_t checksum() const { return m_checksum; } + uint16_t len_evsa_store_header() const { return m_len_evsa_store_header; } + uint32_t signature() const { return m_signature; } + uint32_t attributes() const { return m_attributes; } + uint32_t len_evsa_store() const { return m_len_evsa_store; } + uint32_t reserved() const { return m_reserved; } + evsa_body_t* body() const { return m_body.get(); } + phoenix_evsa_t* _root() const { return m__root; } + kaitai::kstruct* _parent() const { return m__parent; } + std::string _raw_body() const { return m__raw_body; } + kaitai::kstream* _io__raw_body() const { return m__io__raw_body.get(); } +}; diff --git a/common/generated/phoenix_flm.cpp b/common/generated/phoenix_flm.cpp new file mode 100644 index 0000000..babbbb3 --- /dev/null +++ b/common/generated/phoenix_flm.cpp @@ -0,0 +1,68 @@ +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "phoenix_flm.h" + +phoenix_flm_t::phoenix_flm_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent, phoenix_flm_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = this; (void)p__root; + m_entries = nullptr; + f_len_flm_store_header = false; + f_len_flm_entry = false; + _read(); +} + +void phoenix_flm_t::_read() { + m_signature = m__io->read_bytes(10); + m_num_entries = m__io->read_u2le(); + m_reserved = m__io->read_u4le(); + m_entries = std::unique_ptr>>(new std::vector>()); + const int l_entries = num_entries(); + for (int i = 0; i < l_entries; i++) { + m_entries->push_back(std::move(std::unique_ptr(new flm_entry_t(m__io, this, m__root)))); + } +} + +phoenix_flm_t::~phoenix_flm_t() { + _clean_up(); +} + +void phoenix_flm_t::_clean_up() { +} + +phoenix_flm_t::flm_entry_t::flm_entry_t(kaitai::kstream* p__io, phoenix_flm_t* p__parent, phoenix_flm_t* p__root) : kaitai::kstruct(p__io) { + m__parent = p__parent; + m__root = p__root; + _read(); +} + +void phoenix_flm_t::flm_entry_t::_read() { + m_guid = m__io->read_bytes(16); + m_data_type = m__io->read_u2le(); + m_entry_type = m__io->read_u2le(); + m_physical_address = m__io->read_u8le(); + m_size = m__io->read_u4le(); + m_offset = m__io->read_u4le(); +} + +phoenix_flm_t::flm_entry_t::~flm_entry_t() { + _clean_up(); +} + +void phoenix_flm_t::flm_entry_t::_clean_up() { +} + +int8_t phoenix_flm_t::len_flm_store_header() { + if (f_len_flm_store_header) + return m_len_flm_store_header; + m_len_flm_store_header = 16; + f_len_flm_store_header = true; + return m_len_flm_store_header; +} + +int8_t phoenix_flm_t::len_flm_entry() { + if (f_len_flm_entry) + return m_len_flm_entry; + m_len_flm_entry = 36; + f_len_flm_entry = true; + return m_len_flm_entry; +} diff --git a/common/generated/phoenix_flm.h b/common/generated/phoenix_flm.h new file mode 100644 index 0000000..2faeba3 --- /dev/null +++ b/common/generated/phoenix_flm.h @@ -0,0 +1,91 @@ +#pragma once + +// This is a generated file! Please edit source .ksy file and use kaitai-struct-compiler to rebuild + +#include "../kaitai/kaitaistruct.h" +#include +#include +#include + +#if KAITAI_STRUCT_VERSION < 9000L +#error "Incompatible Kaitai Struct C++/STL API: version 0.9 or later is required" +#endif + +class phoenix_flm_t : public kaitai::kstruct { + +public: + class flm_entry_t; + + phoenix_flm_t(kaitai::kstream* p__io, kaitai::kstruct* p__parent = nullptr, phoenix_flm_t* p__root = nullptr); + +private: + void _read(); + void _clean_up(); + +public: + ~phoenix_flm_t(); + + class flm_entry_t : public kaitai::kstruct { + + public: + + flm_entry_t(kaitai::kstream* p__io, phoenix_flm_t* p__parent = nullptr, phoenix_flm_t* p__root = nullptr); + + private: + void _read(); + void _clean_up(); + + public: + ~flm_entry_t(); + + private: + std::string m_guid; + uint16_t m_data_type; + uint16_t m_entry_type; + uint64_t m_physical_address; + uint32_t m_size; + uint32_t m_offset; + phoenix_flm_t* m__root; + phoenix_flm_t* m__parent; + + public: + std::string guid() const { return m_guid; } + uint16_t data_type() const { return m_data_type; } + uint16_t entry_type() const { return m_entry_type; } + uint64_t physical_address() const { return m_physical_address; } + uint32_t size() const { return m_size; } + uint32_t offset() const { return m_offset; } + phoenix_flm_t* _root() const { return m__root; } + phoenix_flm_t* _parent() const { return m__parent; } + }; + +private: + bool f_len_flm_store_header; + int8_t m_len_flm_store_header; + +public: + int8_t len_flm_store_header(); + +private: + bool f_len_flm_entry; + int8_t m_len_flm_entry; + +public: + int8_t len_flm_entry(); + +private: + std::string m_signature; + uint16_t m_num_entries; + uint32_t m_reserved; + std::unique_ptr>> m_entries; + phoenix_flm_t* m__root; + kaitai::kstruct* m__parent; + +public: + std::string signature() const { return m_signature; } + uint16_t num_entries() const { return m_num_entries; } + uint32_t reserved() const { return m_reserved; } + std::vector>* entries() const { return m_entries.get(); } + phoenix_flm_t* _root() const { return m__root; } + kaitai::kstruct* _parent() const { return m__parent; } +}; diff --git a/common/guids.csv b/common/guids.csv index da2ee91..db963e1 100644 --- a/common/guids.csv +++ b/common/guids.csv @@ -2,6 +2,7 @@ 00000000-0ED6-4E09-BBF9-28325DB6BA30,BSODDxeRuntime 00026AEB-F334-4C15-A7F0-E1E897E9FE91,NvmeRecovery 000AC7B6-F44D-4220-BD8B-521D30DEA80F,HpGraphicsDetectDxe +000F42D0-283C-46AB-9287-ACB6C9941FCD,SmmSupvErrorReport 0013BE6B-2198-43F1-93BA-2A7ED7B1E1CC,SystemUsbSwitchDxe 00160F8D-2B35-4DF2-BBE0-B272A8D631F0,FirmwarePerformanceDxe 001D24D1-4AB1-B202-42D1-0FB9F4E4AD36,BiosPowerOnPortingSmm @@ -10,6 +11,7 @@ 003443BE-0997-42D9-BB92-FCDF6926DCEE,FchSmbusDxe 00364A4C-6A0A-4F08-8FFD-0937F3DBB13E,IdeBusBoard 0049858F-8CA7-4CCD-918B-D952CBF32975,VirtioFdtDxe +004E6CC2-D60F-4726-BE22-D3D8020C4687,AsusSmartHsioDxe 00504624-8A59-4EEB-BD0F-6B36E96128E0,FpNvStorage 0053D9D6-2659-4599-A26B-EF4536E631A9,ShellAliasGuid 0062F7D1-F7DB-44FA-ABEE-F7A3CC636E0B,PhStallPpi @@ -71,13 +73,16 @@ 018A5C7A-12EB-429D-9DEF-6FCC410B04E8,IioCfgUpdateDxeLightningRidgeEXECB4 018AA4F0-773E-46F3-B62D-2C70EA32E0D0,EfiSystemPartCapsuleStorage 018E1925-D6A2-4A2A-8958-817610A15ADF,PeiS3LibNull +018E4D93-E8CF-4F51-9170-2658ECA4C9E3,AmdMiniRasStxKrkServiceDxe 018F3936-3A40-459D-9C82-3F1F78A90164,DellControlVaultDxe 019FB1CA-D411-4948-B73C-4C054ABA9E8E,FastBootFunctionEnabledHob 01AB1829-CECD-4CFA-A18C-EA75D66F3E74,IntelMebxProtocol +01AFCA2F-5089-4559-BEF3-6163AE15AE90,FRUSelfRepair 01B95206-CD66-4C0D-A867-ED42960E07DC,SystemFirmwareDeviceSmmProtocol 01C827C2-7765-42E9-B31C-E03E89A09113,AmdSocFp5RvPei 01CF676F-6F01-4FA3-9789-B6322D890394,AmdCcxZen4Pei 01D127EA-F6F1-4EF6-9415-8A000093F89D,UEfiCorebootPayloadPkgTokenSpaceGuid +01D6940E-06A2-455C-A0CA-DD380B3CEA31,SDSecureFlash 01D8F749-FD74-4F70-A393-6FED1D2C8D32,AsusWmiToProtocol 01ED6C55-0D2E-4859-BB57-3044737A3679,PhConSplitterDxe 01F34D25-4DE2-23AD-3FF3-36353FF323F1,EfiPeiPcdPpiGuid @@ -86,6 +91,7 @@ 02005ACC-AD91-42B9-8636-403B4F5799C2,LenovoFlashDeviceInterfaceSmm 02049744-32D9-4338-A64B-FDC42C836F9A,FchDxe 02049744-32D9-4338-CCCB-FDC42C836F9C,FchPromontoryPlusDxe +02061E01-BEBD-4DF5-81B6-DFC4F23D1D00,SensorI2C 020BC7C9-80E5-476D-B187-0FB754850CAB,PvnvramDxe 020BCB33-7EA7-4E48-9AF8-1B6AC52CE83F,MeBackDoorSMI 021722D8-522B-4079-852A-FE44C2C13F49,SataController @@ -98,13 +104,17 @@ 0246E0B3-E8EA-4E03-B2A5-39FA937FD122,SsidPei 024DEE41-33E7-11D3-9D69-0008C781F39F,EfiPartTypeLegacyMbrGuid 02509C17-DD0B-4915-81F6-1DE4BA954B14,FanTableSmm +0250B201-273B-4A64-9CAC-4FE9FB56F65E,AmdRAIDCoreDxe +0250D7AB-AADE-4691-8909-8DC184822D1D,SmbiosTpmDeviceInfo 0253F9FA-129A-4A8D-B12E-7DC2B6376302,dpDynamicCommand 0255DED3-BF9C-4155-8DDB-6E8609EE0482,AmdGopPlatformToDriver 025BBFC7-E6A9-4B8B-82AD-6815A1AEAF4A,MnpDxe 025F738B-4EBD-4D55-B728-5F421B601F1F,PlatformInfoDxe 025F738B-4EBD-4D55-B728-5F421B601F20,PlatformCpuInfoDxe 0273146C-96C4-45A1-A7AF-78E0524A0AE2,AmiBoardInfoProtocol +02814228-57C8-405C-8A67-C928E4B50992,EepromInterfaceCoreSmm 0284F846-2CB7-4960-8DB2-47AA71513AD5,menu_selection +02955B8D-DF90-4ACB-B242-78D06B3FA6CA,TrackPointJYT 029D4C32-51E8-4866-BF51-FD0ED9A2DC55,DellBiosDimmLocation 02A6DE33-3EA9-4C17-8EA2-5681CC7AFDED,VMDDxeEfi 02AC0805-155F-473A-A302-0D89D6E1E6CC,AsusSLP2 @@ -120,6 +130,7 @@ 02C5A102-58EA-4E53-8BE1-6ED1ACAA708A,AmdMemoryHobInfoPeim 02CE967A-DD7E-4FFC-9EE7-810CF0470880,EfiEndOfDxeEventGroupGuid 02D46AF0-78A0-43FD-A9D6-25B094E0BA93,LEN0130Driver +02D7DFE6-CB36-4FF9-9ED9-31806B797251,FchSmmDiagDispatcher 02E800BE-8F01-4AA6-946B-D71388E1833F,EFI_MTFTP4_SERVICE_BINDING_PROTOCOL_GUID 02EEA107-98DB-400E-9830-460A1542D799,Ip6ConfigNvDataGuid 02EEC6CF-FDF5-4FF0-A6AF-DF569BCD6828,HpDimmIdDxe @@ -128,9 +139,11 @@ 0301BE48-7D25-443C-AA77-D5E753DB416A,EfiRsaBmcCommandsProtocol 0302DCB7-A6A3-467C-B85E-F21DB7E8533B,SmmDispatchEngine 03068297-DDA5-4CCD-BBFA-7E09AE025177,I2cTouchPanelDxe +0317F4CE-AD43-4461-8D14-B9F2543FD839,SataDriveInfoDxe 0325A554-05BE-466B-BC8C-70BE3C9DAFB1,AmiTcg2InfoProtocolGuid 0325B5A1-0937-4A4F-B8AF-EC3F80EE6B35,SataControllerLite 032DE3F1-1362-45A5-A5C2-44A0E63CC263,FjGabiSystemTableSmm +03327D04-C807-4B76-965F-B30046F15391,VtioSetup 033FF0BE-ABFB-40AC-87E3-C22A69BD7FA7,TransparentUnlockDXE 03417BF3-6D95-41DF-88EF-0DDA6E86DC34,AsfPei 0347E9D2-3778-46DC-B8B5-F1687C703973,FjWwanRfSettingUIDxe @@ -140,13 +153,16 @@ 0369593A-BA9B-457D-B46F-31D83A96D6FE,DehSmmProtocolVer3 036B6292-2793-4DC0-9A7F-D6B5F034558C,FjSystemHooks 036F84E1-7F37-428C-A79E-575FDFAA84EC,EfiIommuDMArErrorSectionGuid +03721EF2-1801-4C91-A213-147323F75132,AsfTableAsl 0379BE4E-D706-437D-B037-EDB82FB772A4,EfiDevicePathUtilitiesProtocolGuid 037B547A-97E8-4FF2-8CD1-DCB7A1B4915A,SetupConfigUpdateDxeArcherCityModular 0387F555-20A8-4FC2-BB94-CD30DA1B4008,EfiWindowsInt10Workaround 038CE287-B806-45B6-A819-514DAF4B91B9,DellErrorLogConfig +038EF9A9-5969-4793-964F-FF12FA18393E,AmdCpmOemInitPeim 0393D0C4-6B0C-4B96-B4C3-8C7EB718F348,CsrPseudoOffsetInitSmm 0397B0C9-22E8-459E-A4FF-99BC65270929,Tpm2StartupLocalityHobGuid 03A8E402-2AB7-46B3-B591-740383796B82,AmdMemChanXLatDummyPei +03ADF4A1-A27A-45E3-B211-3177C6C2E7ED,SmbiosBasic 03AF477A-8336-0142-8A65-B4BD93B1A1A9,FirmwareExtension 03BF5679-5749-4BC5-A53F-47471DA767C8,IsscSmm 03C1F5C8-48F1-416E-A6B6-992DF3BBACA6,A01SmmServiceBody @@ -161,6 +177,7 @@ 03EBDB4B-96BA-4F40-8329-7F3AA8865707,EcIoSmm 03FA15BF-A5C8-4006-81B5-B836E7A70030,GnbSummitRouting 03FDF171-1D67-4ACE-A904-3E36D338FA74,SeCPlatformReadyToBootGuid +04062BAD-2117-46DF-AEB9-8E468D8326E5,OemCheckRtcBattery 0412A7A1-C050-42C2-877A-77C379F9F5F1,FirewireOhciDxe 0419E4C6-4E8E-4436-8509-38B7AE50BFFD,ReadyBootSMI 0419F582-0625-4531-8A33-85A9965C95BC,WinNtBusDriverGuid @@ -187,12 +204,14 @@ 047CA5C8-EFA6-64CA-98EC-A01DF3BCC6A8,A01BootDeviceServiceSmm 048520E2-46BC-829D-5683-329BF1162CD2,BiosPowerOnSmm 04877BE8-FAC0-448E-801D-F0F895CCB012,SmbiosDmiEditSsi +04970E59-FCCC-47CC-B945-7976EE7DBB7A,OKRConfig 04A0D644-5599-430A-A4E1-C8FEE8CBF46A,SmbiosType142 04A76C80-06B9-445E-B73E-CB8C61A6A964,SIO791 04AFC94A-73AF-432F-BECB-B794568AC985,DellOnboardNicSmm 04B37FE8-F6AE-480B-BDD5-37D98C5E89AA,EdkiiVarErrorFlagGuid 04C332FD-14D3-411C-A1EF-6512E260339E,FjNvsAreaSmm 04DD0ECD-4844-426D-AE59-1EF632C5EA4C,SystemDxeToSmmEventDxe +04DD1EE1-4C38-41C7-83C6-4ED6BB692CFD,AaeonDioDxe 04E86DFA-6FA9-4749-A069-5A708F416AF7,OemPDAutoFlash 04EAAAA1-29A1-11D7-8838-00500473D4EB,UsbRtSmm 04F5B0F1-73E2-4CC4-9741-662DBC3AB78B,ErrorCodeHandlerSmm @@ -226,22 +245,28 @@ 0589E077-93C8-470E-9B90-958B4E2FE686,DevUpdateProgress 05913B1B-DB0C-4679-94B1-F8AA09B4A971,FjPcieCardReaderRTS5250 05984E1A-D8BB-5D8A-A8E6-90E6FB2AB7DA,AlertUI +05ABE46F-BFA5-4C68-B305-3D545C58D805,Vby1PeiPreGop +05ABE46F-BFA5-4C68-B305-3D545C58D806,Vby1PeiPostBuffer 05AD34BA-6F02-4214-952E-4DA0398E2BB9,EfiDxeServicesTableGuid 05B0A258-308A-445E-B669-A854549D225C,SmmCpuProtocol 05B17EF3-26CB-444A-82F7-92705CFB6B1E,DellSetupFormSets 05C99A21-C70F-4AD2-8A5F-35DF3343F51E,EfiDevicePathFromTextProtocolGuid 05CA01FC-0FC1-11DC-9011-00173153EBA8,OemRomHole_0 05CA01FD-0FC1-11DC-9011-00173153EBA8,OemRomHole_1 +05CDF411-F3C1-4B12-AA64-21416E18A13C,AmdCpmSharedBSmm 05DB6CC9-E9E4-4209-9D46-AA52C4052937,CNVISetupSmm 05DDA141-2DFA-48BB-B09D-D922344947FE,ApobZpRvPei 05DFCA46-141F-11DF-8508-E38C0891C4E2,HfsPlusDxe 05E9CF0F-4BE3-87F4-7265-B796A76959C3,S5MaxPowerSavingsSmm 05F7AA70-A64A-432C-8CEE-4CDECB8671D7,A01ODMDxeDriver 05FC0C8E-276A-422D-BAE1-645CFD7B786B,Cf9Reset +05FE1BB1-41D3-43DD-ABB0-91860B4AB185,AsusBackupSync 05FFB44D-EE01-40E1-9866-FD27FD4FBE92,ThunderboltDeviceDxe +060644B6-6A7F-4A97-900C-49645DA956D7,FchYuntaiDxe 060CC026-4C0D-4DDA-8F41-595FEF00A502,MemoryStatusCodeRecordGuid 0619F5C2-4858-4CAA-A86A-73A21A18DF6B,GenericWatchdogDxe 0625FEA6-F95F-498D-8789-3EA053A06D7E,Cf9Reset +062A6204-8C80-4A27-9D09-96654C965894,AsusHwmSensorPortingDxe 062ACC82-1D1E-4F61-AA94-8B0C47236A3D,BootScriptSaveOnS3SaveStateThunk 062FDFE6-2C0F-462C-9572-92018E6E52E3,HpIcicleRepSet 0633A0F1-78FE-4139-B878-0045E81CB8AB,EfiVolatileMemModeVariable @@ -252,17 +277,20 @@ 067B1F5F-CF26-44C5-8554-93D777912D42,ConfidentialComputingSevSnpBlob 067E2381-7234-4798-B49C-D5FECBFF6D07,VariableAuthSmmRuntimeDxe 06818C78-1C8A-4591-9833-DC0E4B9566E4,TdtAm +06830AC0-75D7-4933-B6AF-4D3AA317D2AF,FJPhysicalPresencePage 0683FB88-664C-4BA6-9ED4-1C0916EE43A4,UserAuthenticationDxe 0684C591-19E8-499D-978A-D715636F1DAB,AmdRasRvDxe 0693BAA5-35D0-4360-83F6-1DF26D3C53CE,SiCpuInitPei 06968B6E-F620-4E8D-A6A6-52552354DD75,LenovoDxeRicohInit 069887DE-145C-404C-9B23-E262A88789AF,RfVlan 06B5947E-FF53-457D-98BC-C5ABC777FD5A,SetupMouseDxe +06BE9C49-717C-46C8-9848-E626B79FAA36,FchYuntaiSmmInit 06D1F4F5-B131-4F7C-A983-20E4BE9E8A3D,DellPSBFuseDxe 06D20D84-A032-4E25-969A-346D255E46D1,CpuCsrAccess 06DE824A-A4E2-4295-A3F6-03B3FEF5B109,LenovoSecurityVariableDxe 06E81C58-4AD7-44BC-8390-F10265F72480,PcdPpiGuid 06ECAF57-1A95-44DD-AE09-AB9B9BD681E9,MpmAsfDxe +06F00EDE-198C-0217-2416-4299BCE072CA,OemMfgdoneDcfg 06F73F04-36C0-4CBC-A3B0-9F16FB603350,OemPxeLoader 07013588-C789-4E12-A7C3-88FAFAE79F7C,EfiSocketProcessorCoreVar 0702269D-380C-4873-BFEB-32F5BC44DD16,AmtLockI2cConInDxe @@ -271,7 +299,10 @@ 071A3DBE-CFF4-4B73-83F0-598C13DCFDD5,Slp21Markers 0723F88B-810F-4E44-92A0-A5C83B433698,PchFlashControllerDxe 07261C8F-9F27-4409-BD78-2BB0B691F331,DetectWlan +072A957A-2A7A-4DB1-A35D-21C9795ACD6E,SetupUtilitySilicon1 +07309A59-462F-4251-BF5F-324E80CD5B05,WtTimestamp 0732BD39-D6B0-4039-B6C2-9654466DE525,MeudError +0736595D-88AB-483E-9886-8132018980FE,SioChip1InitDxe 0738958D-A35A-4175-ACE9-D32445501D34,FjTpmPhysicalPresenceLockSkip 0739CE30-2E1A-449A-B575-FD64F1B4321D,SystemSetupCapsuleFromInternetDxe 073E2576-F6C1-4B91-92A9-D4675DDA34B1,PttPassThruProtocolGuid @@ -280,6 +311,7 @@ 074E1E48-8132-47A1-8C2C-3F14AD9A66DC,EfiGlobalNvsAreaProtocolGuid 07525079-2616-4599-93FA-5EE9E3F0295C,CsmPolicy 0755BB58-3362-4E3C-8D4C-8E0F28366E21,EcGbeSmm +0764AAD8-9D82-441F-80F3-21AFA56F807C,Afu32MOfbd 07683700-036B-440B-8EBA-637F9ECB3DEB,SioSmbusAccessSmm 076E4FF4-AFB4-4B74-8D94-0517BEC86361,FchSmbusPei 076FBF50-EF83-4B77-912C-D5BB77075AE3,CompalThermalDxe @@ -289,6 +321,7 @@ 077700FC-1F81-4FD2-8EA8-BE9258884D45,PostScreenInfo 077A3100-1667-45FA-B98C-37651B5073EE,TpmSmbiosDxe 077F6FC5-2D7C-4F58-B12C-F5287E5F5843,DellTagsDxe +0780F2B5-EEA8-4A94-97B8-59C8275D5692,Ccg4ControllerDetectPortingSmm 078485F1-0C1F-4B1B-AFB3-4A09C0EF87A1,It8728SmmFeatures 0784924F-E296-11D4-9A49-0090273FC14D,EfiDriverDiagnosticsProtocolGuid 0787C598-F9C6-4B7F-8C85-0C96C4E1E531,FjHookFormBrowserDxe @@ -299,12 +332,15 @@ 07A50B13-7539-41CB-B924-9E72B870C6D3,UsbVhcDxe 07A9330A-F347-11D4-9A49-0090273FC14D,LegacyMetronome 07AD733A-0DDB-4244-BD82-071F39E2A420,PlatformSmm +07B348F3-2187-4035-AEAF-F07A85D9754B,AmdEdidOverrideDxe 07B37006-9302-408E-B416-B524D110DD7F,AppleHidInterface 07B58AD3-EB7B-4233-9044-9C9E65A4973B,RZ616_MtkSuppDex +07BDE155-616C-4291-BD0B-24411F3BB908,AmdRAIDCoreDxe 07BEF20E-5E47-4A69-B228-27C6C870EAE1,AmdSocFp7r2PhxDxe 07D1E0C7-1262-481F-95C0-3E05DA38F766,FchTacomaSmmInit 07D279A1-34E4-4168-993B-178B3ACC68EF,AodSetupDxe 07D75280-27D4-4D69-90D0-5643E238B341,EfiPciPlatformProtocolGuid +07DCCAE1-A9AE-4EF4-AA10-468B1C37BECC,OemDxeShp 07DFA0D2-2AC5-4CAB-AC14-305C624887E4,PlatformTokenSpace 07EDEF55-24EC-43F3-8E3E-8C0831E21E68,EzTpmUpdStTpmFwUpdDrv 07F1B357-4270-4122-A32A-7EAB3C013BAC,DfciManager @@ -324,6 +360,7 @@ 08497E75-0BF6-40E2-8ABF-B98DFB464C93,SpiFlashPeiLibNull 084A92B2-036A-414C-ADEA-620ACF547664,RasMiscDxe 0859BA18-7DD7-4ED7-A88E-109C63917BDD,EfiPlatformMemtestProtocol +085A786C-5CFF-4762-81CF-D7CBFECA77D4,AmdPlatformRasBrhSmm 085DDD80-CE41-4FA8-B298-6071E8F62BC5,SmcOobPlatformPolicyDxe 085E8CC2-8EC9-4666-BD2A-49D481E95FA7,FjEvteLaunch 086147FA-4C0D-4781-AD27-0A3725F03F2B,DxeDg2OpregionInit @@ -346,6 +383,7 @@ 08EFD15D-EC55-4023-B648-7BA40DF7D05D,PeiRamBootPei 08F2C63B-08DE-4CCD-8670-ACFE644A1C48,PchS3Support 08F74BAA-EA36-41D9-9521-21A70F8780BC,EfiDiskInfoScsiInterfaceGuid +08FA7EC9-60D4-47C8-B299-9F83B4A9DAC3,AcpiOverride 08FBD32F-867F-452B-B134-705161F73333,LenovoCryptServiceSmm 0903DD14-2CA0-458A-B5EB-0C0CA30D785C,AmiSmbiosBoardProtocolGuid 0914DE08-434D-4F9F-93B3-6FA48AEAF7E0,DellSpiPartMicron @@ -353,6 +391,7 @@ 091AAEA3-09A9-40F6-9864-0139388A9F8C,XhciPei 0922E604-F5EC-42EF-980D-A35E9A2B1844,IpSecConfig 09286371-5FF2-4065-B3D2-B81C882898AB,HpIcicleSmm +0939A4CC-DC2B-48A0-909B-30994D39D82C,ReportStatusCodeRouterSmm 093E0245-BDA6-48C7-A0B4-C3C9BFB87C79,WLANDxe 093E0FAE-A6C4-4F50-9F1B-D41E2B89C19A,EfiCertSha512Guid 094325E0-4DA2-4912-990B-D6DB19077573,HeciAccessDxe @@ -394,7 +433,10 @@ 0A18976F-6CA6-405B-AF4B-27B8F7F6DB98,AmiUsbIadProtocol 0A1C30D2-7821-4FD2-B3C1-D24FA4C84B6A,DellCfgChangeReport 0A1D4FD8-4704-4501-85EB-93399492CBED,DevShell +0A249BB5-5918-45F5-B220-76A3B6C89529,FjLvdsFwDownPei +0A24A50A-C148-42B6-9302-8ED31D334E73,ASRockNetFtp 0A2FBD15-1C25-407E-8915-60C5652BC2AA,SystemFirmwareUpdateDxe +0A32A803-ACDF-4C89-8293-91011548CD91,MicrocodeMeasurementDxe 0A457A6C-178E-438C-AC96-D9C0EC52BE66,DellTcgPeiPolicy 0A496AAC-8C56-4DA0-A960-E417247A6183,BroadcomLomSmm 0A4D622D-01F4-4974-B3F5-2BFE9888EF92,SLP20OEMPublicKeyVariableGuid @@ -421,6 +463,7 @@ 0AC12AB3-DD33-4460-87F5-82694D3D7402,SmcOFBDNull 0AC2D35D-1C77-1033-A6F8-7CA55DF7D0AA,CpuPolicyPei 0AC742BF-07C6-4C87-A87D-A3B2918AFD00,TileDxe +0AC7D82C-9BAD-419F-B8FF-B39BA18737FD,Rtk8852CEWifiSupDriver 0AD3D31B-B3D8-4506-AE71-2EF11006D90F,UefiAcpiBoardInfoGuid 0AD4F13B-D197-44EC-FFFF-FFFF62C8C689,XnoteVariableDxe 0ADFB62D-FF74-484C-8944-F85C4BEA87A8,AmiEfiKeycodeProtocolGuid @@ -429,6 +472,7 @@ 0AEF5579-3700-41D2-A53E-DABD55E22432,DellUsbBusSmm 0AF0B742-63EC-45BD-8DB6-71AD7F2FE8E8,ShellDriver1HiiGuid 0AF7C79C-65B5-4319-B0AE-44EC484E4AD7,EfiHashAlgorithmMD5Guid +0AFD2FA7-5EF2-4B3B-A65E-B6F276D082A1,AdvBootOptionPolicyDxe 0B04B2ED-861C-42CD-A22F-C3AAFACCB896,BiosVideoDxe 0B0D3C7E-473A-22E2-8428-3DAE5CCEAC64,CableDetectDxe 0B1E645F-5E5C-48A1-FFFF-FFFF5804E747,XnotePlatformResetRuntimeDxe @@ -456,9 +500,12 @@ 0BA38E92-154A-4BE2-A5E0-BE80571CDB71,DellDtwlanSmm 0BA8263C-A8BD-4AAD-B402-6A6AF2F7E77D,BlockDeviceCapsuleGuid 0BA8630D-B1F9-4CED-887D-DD013A0C6B4A,UsbTypeCChargingPei +0BAED1B4-B14B-40F1-9D67-B8CD96F923E4,AsusTCONDxe 0BB12CAC-CFA9-4839-A4C2-1797248109D0,DellLegacy16Rom 0BB51CDD-A750-442F-A15E-7DEADFBA30FF,Mtftp4Dxe +0BB60340-8865-4584-A32D-7F839903DF4E,MmioSerialUart1 0BBC6CAB-F228-4F20-8C6A-847CDEE3FF24,OFCDxe +0BBC88DE-17D1-4DBA-BA54-734B01DE421F,OEMPlatformGopPolicy 0BC22608-ECC5-47B9-A038-4F0A68372E44,DellDeviceNameConfig 0BC7E05C-C88A-4254-BCBB-D42638D28AAD,PlatformMilestoneSmm 0BCAF6F4-5A78-4818-82BC-5594D175943C,FchSmbusPei @@ -466,6 +513,7 @@ 0BD7EBBF-F1A9-4C0B-9941-636D102AA48A,FchBixbyDxe 0BE3D6AE-6D2C-41AD-9869-A97364E7C1F1,FjIbvSfuSecFlashAbstractionSmmProtocol 0BE98320-5634-4AAB-B2B7-FCBC9777151E,FjTerraSmm +0BF06027-29A4-447D-8FA4-D8A289F1DDDC,CxlManager 0BF13AFB-98B6-4B77-96E3-0868917C2D2E,I2cBusConfigurationManagement 0BF70067-D53B-42DF-B770-E92C91C61411,EfiTdtProtocolGuid 0BF89093-3E5E-457A-8CA6-62352915A3B4,PHashDPei @@ -483,6 +531,7 @@ 0C3798AA-D22E-4DD6-8CB4-3C9CFB1D86D3,NCT6126DSmm 0C396FCA-6BDA-4A15-B6A3-A6FA4544BDB7,EcFwUpdateDxe 0C3B7B59-28E5-4C99-85E5-D0116DBFAAF2,IsctWakeReason +0C4F81C5-309F-4941-85A2-8C6A44B4F4F6,AmdVariableProtectionSmm 0C556BFF-B16A-439D-A3EC-1164378E2C2A,AmdPspPeiV2 0C5FCE90-1C03-4ED2-9EFE-B1D02E72B3B0,menu_bottom_mid 0C8050B7-D2F0-42F8-852B-D1DEB2F2E9B0,SetupIoDetect @@ -507,18 +556,25 @@ 0CCA1898-D936-4386-872B-734FE850DC49,FjIbvSfuOverrideAbstractionDxeProtocol 0CCF27CF-E68D-4279-96B0-8A4E1CDFF10C,SettingsManagerDxe 0CD3D2FA-B21D-47B5-BA95-D8C00B38F324,DellAi13Rom +0CD80A60-46D9-48B3-A8B9-61E5598AB054,MultiPdtDxe +0CD9632B-A19C-4488-8917-4E1C8E75DC1A,ncm865x64 0CDA5D94-951A-4C61-8DD5-E5BF34BA69EC,SlotDataUpdateDxeLightningRidgeEXECB1 0CE47609-0E04-4EE5-A192-F410A1995E0A,b57undix64 0CE5EA44-BED3-49CA-AECC-B50AB9C5B0E9,DellRecoverySiDxe 0CEFD645-588E-4ED7-9943-054808CD7572,SiFirmwareVersionDxe +0CF7AEE6-3BD4-48A3-97E2-E7E5B83F67FD,CbsBasePeiRS 0D024887-B489-4E9F-884B-A4B6BB8A576B,ODMCompuTraceDxe +0D05D4DB-4A1D-4DCD-89B5-87B36C6DD180,SDEmmcInfoDxe 0D1B9C8E-F77B-4632-8343-91F43D9A8560,EfiCpuHtCapable 0D1CE46B-72D9-4BA7-95DA-23511865E661,CryptoPei 0D1ED2F7-E92B-4562-92DD-5C82EC917EAE,CrbPei +0D1ED2F7-E92B-4562-92DD-5C82EC917EBF,EcsPlatformPei +0D22D223-E9A7-00C5-BE84-3FCAF25EC1A7,InstallMadtDxe 0D244DF9-6CE3-4133-A1CF-53200AB663AC,FspsWrapperPeim 0D24A235-9C12-446C-8ECB-EFC1F5280209,DellJpegDecoder 0D275C72-10C6-4D8C-8B2C-6610E69E3403,Uart16550SerialDxe 0D28C529-87D4-4298-8A54-40F22A9FE24A,DellDaHddProtection +0D2B85C0-D468-4ADB-93BF-E53AE203C034,OemErpPolicy 0D3FB176-9569-4D51-A3EF-7D61C64FEABA,EfiSecurityPkgTokenSpaceGuid 0D42E9AB-5DDE-4CAC-A485-0215C252717F,AmdSmmControl 0D4BBF18-C2CC-4C23-BD63-BFDAD4C710D0,Tcg2Acpi @@ -550,11 +606,13 @@ 0DCF3594-318C-4596-B00F-BE61842DE3E2,SystemBootTypePeiPei 0DDE9636-8321-4EDF-9F14-0BFCA3B473F5,DellIntrusionDetectSmm 0DDF623A-9F60-4AF2-B5C7-EFE4A637290E,FjDtDiagnosticsDxe +0DE19141-7AEB-46CA-9F87-2D19FEBC99C3,OemBootMiscDxe 0DE2CE25-446A-45A7-BFC9-37DA26344B37,EfiPeiDeviceRecoveryModulePpiGuid 0DE8BACF-E00A-4538-BE0D-81AF9374FCC9,EmulatedEepromSmmProtocol 0DED86EE-6E79-4764-AA83-37A472F48123,ChkrecoveryFile 0E00B084-2D16-4A27-B172-B1F68C2CC55D,MicrocodeUpdates 0E06A80E-D726-4BAF-A0CF-211260FE69D8,OemSSIDUpdate +0E0885B3-07A2-41AA-82E7-806A47A9215E,Parade_Retimer_FmpDxe_FwUpd 0E109C7B-8790-4B9D-981C-9D4B079E98D4,MsiSGSmm 0E135E4D-E63E-45C6-A9A2-E9363477DDFC,AmdNbioBaseMdnDxe 0E1B2F3C-DD5F-44CE-8D37-5AEC2B339B5C,BiosConnectSOSLauncher @@ -592,6 +650,7 @@ 0EDEF0B3-EF91-4935-859E-2338DFFAC099,MpdtUpdateDxe 0EEC96BC-0B82-4573-9791-C414E4DCEE64,IhisiService 0EECB4A5-7B9F-4707-81D7-9C045E98CA95,AmiPlatformInfoUncompressedFfsSection +0EF3C867-459B-41D8-8541-DD7DC277EBC0,PdHostInterfaceRtkPei 0EF53039-3A38-42D1-BCEC-CE966E87061A,PeiFrb 0EF84C20-D178-490B-9FCD-122739FAAEFC,FchSmmDiagDispatcher 0EF8A3B1-388A-4B62-8BE6-C7877D50AEDF,UefiPxeBcDxe @@ -599,11 +658,14 @@ 0EFC6282-F1E5-469A-8A70-194A8761F9AA,XenAcpiPlatformDxe 0F03D285-6614-4DDC-86DC-DAE5E375443A,EndOfFirstPowerOn 0F0B1735-87A0-4193-B266-538C38AF48CE,EfiIfrTianoGuid +0F0DA838-E678-432E-9AEE-CB606E89B3DA,FchSmbusPei 0F17CECC-653A-C343-9CFA-FAA27A07EFE5,AppleCrypto 0F23C1F8-4BAC-470C-B6B8-B392D544290A,FmpCapsuleUpdate 0F2FADAB-E401-63ED-7E29-69F215C60511,OemUSBGetSetupData +0F411BE5-B10C-4DDA-B28C-868FC24789F8,AmdVariableProtection 0F492340-21B3-4E23-9140-8C14476292CD,SetupRepSetSmm 0F500BE6-ECE4-4ED8-9081-9AA9A523FB7B,HstiPublishCompleteProtocolGuid +0F5DD251-6C8B-4752-8110-FCDF57EEDFB2,DxeReportStatusConOut 0F5EF786-17A0-40C6-BC18-1B3272A00987,IccInit 0F647B12-5FA2-4B5E-9D61-2AB3C51F224E,BctBaseSmmSSP 0F6499B1-E9AD-493D-B9C2-2F90815C6CBC,EfiPhysicalPresenceGuid @@ -613,6 +675,8 @@ 0F7BDE7C-AAF3-48D0-931F-475750DDE210,OemWwanPei 0F7EC77A-1EE1-400F-A99D-7CBD1FEB181E,PcatPciRootBridge 0F886E75-3029-4ECF-B694-22894D3F2143,PLEDDXE +0F8E91FD-9964-4A65-B052-C4639C5A9EF0,SioRfTestWmiSmm +0F92508B-F17C-4EFB-8722-BCA5531F8B53,CpuDeviceInfoDxe 0F99E33C-CA0C-4AA2-887D-B57EC9050278,SaveMemoryConfig 0F9D89E8-9259-4F76-A5AF-0C89E34023DF,EfiFirmwareContentsSignedGuid 0F9DD4B0-599E-4D66-8565-22FBEA1E028C,AmdFabricPhxPei @@ -647,9 +711,12 @@ 10149626-5583-4364-822F-A459B8121302,SystemFirmwareDeviceDxe 1015EA63-7421-417D-BB51-E5193061C551,DxeIpmiUsb 10164673-D365-4BE2-8513-1497CC07611D,ScPolicyPpiGuid +101DF54A-10FF-4E0D-94C0-A89D5546DD6C,AmdFabricStxhPei 102287B4-6B12-4D41-91E1-EBEE1F3AA614,UefiDebugLibDebugPortProtocol 1034183F-AF0A-4716-BE0E-4CB5319D6193,PciHotPlugNonRpDxe +103D3C97-CE0F-4DF0-97B0-194C61BD540C,FchEspiCmdDxe 1051EC65-F6FC-41EA-BA51-344C37F60CDF,BoardConfigInitPreMem +1054B2FA-3DF0-41FC-A7CE-D59379F3988E,AsusSIBoardPei 105884E1-57DA-4F36-9104-8D092339D234,DellThermInfoConfigDxe 105FF0EA-A0C0-48A8-B8F7-E8B4D62A1019,FmpAuthenticationLibRsa2048Sha256 1062CB92-72A9-4FDC-9694-B1FE817EFAAF,DustFilterAlertDxe @@ -661,6 +728,8 @@ 107A772C-D5E1-11D4-9A46-0090273FC14D,EfiComponentNameProtocolGuid 10811F41-037E-4EBE-9872-771D7646FFFA,LEMSAPAMLock 108343B1-3F5B-4908-9525-E25E62D5729A,LegacyPciUcrDxe +10921D66-281D-496E-A3B4-A8D47FD6DE9E,HpVpinSelectionSmm +1093A6F0-37ED-49BA-9DCC-4F6999807315,MmioSerialUart2 10952220-AA32-11DF-A438-0002A5D5C51B,PL35xSmc 10B12ADD-F5E2-CC78-5CA0-B77F76223ACD,AmiCpuFeaturesDxe 10B7F979-741C-467E-8764-8DD50D8AD6C5,SdioInt13 @@ -668,6 +737,7 @@ 10BA6BBE-A97E-41C3-9A07-607AD9BD60E5,EfiVlv2VariableGuid 10C22623-DB6F-4721-AA30-4C12AF4230A7,IdeRecovery 10C22623-DB6F-4721-AA30-9C12AF4230F8,ExtRecovery +10D72AD4-F4D5-4F35-A5A3-001F6ED81E1E,DxeSerialTextOut 10D93A56-2D64-47D3-828D-7A5066915292,AmdRasBrApeiDxe 10DB0A54-F6F9-4CA2-A75E-F9AACAE70970,BiosGuardConfigGuid 10E26DF1-8775-4EE1-B50A-3AE82893703A,SeCfTPMPpiGuid @@ -689,6 +759,7 @@ 113B2126-FC8A-11E3-BD6C-B8E8562CBAFA,EfiBootManagerPolicyConnectAllGuid 113FD31A-BE8B-418B-B034-7EAFE5C60C99,EsaInterfacesForTseProtocolGuid 1144265E-F049-45B9-8778-752F12A1365A,IntelTechSetup +11472071-A5CA-4281-9779-DF2C839A455A,DxeSndwBeep 114B7105-6CC9-453C-BADC-16DF227BB4EF,TrEESmm 114BA15A-6189-180D-BFC0-2053B3480949,EfiBoardSelectGuid 114CA60C-D965-4C13-BEF7-C4062248E1FA,EcIoDxe @@ -696,6 +767,7 @@ 11527125-78B2-4D3E-A0DF-41E75C221F5A,CpuS3 1156EFC6-EA32-4396-B5D5-26932E83C313,EfiSpiProtocolGuid 115F8F4F-7899-4154-9C1D-B6E12B320BE1,EcCommunicationSmm +11650C26-915A-40AC-829C-A1E1B6333D79,PwrButtonCtrlPei 11668FCA-73BA-4B58-85A2-98AC4DF59A2C,SystemSmmCommunicationBufferManagerDxe 11681F03-6B8B-4CAD-83E7-588A64BC64EA,FjPowerOverEthernetD2927 116E1ACF-2533-4CC2-820A-BBC10A2AB07C,CpuSpSmi @@ -710,11 +782,13 @@ 11822C42-79E4-48C9-9F73-700D3556B0C0,MyAsusAutoInstallItem 1183FB2D-DFBD-40CD-945B-3FA630879BCD,FjEvteServicesDxe 1188F1FC-06E9-49B8-A615-F5A0886FCF89,UhciInitPei +118FE494-0699-42AA-AACA-62E849359B17,FspRsc2PostCodeMapServicePei 1191BBF5-DCB9-44F4-827E-95359744C987,PlatformStage2Pei 119BFA16-911B-4F1F-B1B2-69F43B759448,DellPcdUpdatePei 119F3764-A7C2-4329-B25C-E6305E743049,DellSmmSecurityVault 11A03A8E-A9C5-4DB9-90CF-4434B01586C4,BootPerformanceLog 11A51DAF-6834-4BA1-AD5E-4A58633B343E,AmdPspDxeV2Rmb +11A687C0-EDBF-4ACF-8FD5-32A0BD5D76AA,RZ6xxLauncher 11A6EDF6-A9BE-426D-A6CC-B22FE51D9224,PciHotPlugInitDxe 11ADE65F-956B-4D0E-B368-86DBC92F01AA,VariableSmiInt15Dxe 11AF0D83-0784-4C1E-9A1B-9CF43127555E,CrbModernStandby @@ -730,9 +804,12 @@ 11DD0F6C-209B-47CE-8A98-418C9B7CC756,DxeSwSmi 11E32C34-60B5-4991-8DEA-63D3E8C876DE,UsbRndisDriverSrc 11EE12F3-4B62-172F-37A6-A6BEDAB1FF62,Pca9545aPei +11F6C2EA-E21F-5ACF-A5DF-32C12E5E0E70,PlatformPreInit 11FBFDFB-10D2-43E6-B5B1-B4386EDCCB9A,EfiSeCRcInfoProtocolGuid 12025686-3984-466C-980B-8B5E89DA0319,AmiReadyToLoadDxeCorePpiGuid +12067096-18AF-41DD-B4F1-D29592283062,SystemDeviceModePrivateWmiSmm 1206F7CA-A475-4624-A83E-E6FC9BB38E49,SmmControl2Dxe +120992F2-0339-402C-BAB6-16122DB2EC7E,PeiMemoryDiagnosticTest 120D28AA-6630-46F0-8157-C0ADC2383BF5,AmiLegacyBootProtocolGuid 1216BD2A-C05E-4C6D-91E7-EB8E37AD3B7A,aDefaultDXE 12199730-7D13-4C92-97D5-1562515A1E48,OemThermalPolicy @@ -767,12 +844,15 @@ 12CADD30-6007-4C83-89D7-FF237F7B947A,SetupCompleteRedrawGuid 12CD8A4D-93FD-E81C-72FC-D931EBBC04D4,DellTouchScreen 12D1D3A2-99F7-420B-BC69-8BB1D492A355,Logoid +12D43AAE-DDC1-4615-B0BC-E115F9D17FC1,FjPowerButtonSmm 12E082F4-0DCE-444B-B89A-EF3328428D64,ArmaniSmm +12E1529B-B6A0-4D7F-8B15-5036C9BC2DE3,Fji210LanControl 12E2306C-1EBD-3140-B92E-EFA9099E82D2,CacheManager 12E5A97F-98D1-4C1F-87DA-FB67CFFBD9DA,EfiLanDriverDxe 12E7691F-1EEE-4ED4-8793-69E2801D602A,LenovoFpPba 12E7691F-1EEE-4ED4-8793-69E2801D6123,AsixPxe 12F38E73-B34D-4559-99E5-AE2DCD002156,BaseFspWrapperPlatformLibSample +12F70DB2-8585-49A6-A1E5-20F0363B05B0,WCN7850 12F75401-5415-4FF3-A981-A39BEE9F369E,SerialRecovery 12FF2998-429F-400B-B9EE-FEA8287A1DFE,FjAbtDxe 130B8BA5-E63E-44A0-85DB-4D4E571C526A,IioCfgUpdateDxeNeonCityEPECB @@ -810,8 +890,10 @@ 13B00AAE-4FD2-964E-B30F-94627017370A,BmpConvert 13B03F00-18B8-48DA-8B1C-B290C69BAAFE,EzFileBrowser 13BEAD28-488D-9112-5B0E-40B67EDD800C,AmdRasSmm +13C4BBE0-422C-4CAC-804F-FACDBA6F1A28,SuperIoExPei 13C5506E-8231-415E-9EBC-88DD115E3818,SmbiosElog 13D3B72A-8047-47B8-A4C4-4E814F6B25A1,DnxDxe +13E58E55-E1E1-4CA7-BE88-2D8FE72664DC,DashManagementPei 13E828E8-41A9-4D36-98DE-FD3968E2C18E,LnvPdrSmm 13ECD928-87AB-4460-BBE0-B520F9EB1D32,IconNetBoot 13F37218-70DF-45DD-8883-D4E6F5BE4255,NvidiaGpuAcpitables @@ -821,20 +903,24 @@ 13FA7698-C831-49C7-87EA-8F43FCC25196,EfiEventVirtualAddressChangeGuid 1400F9E6-4BAB-4B68-A53F-58FD240818E6,Reset_Modify 14045170-CA65-47BC-9C15-2DE36D44AEE9,SmcInBandDxe +1405AD5E-5BED-11E3-866A-047D7B99E097,Slp20ServiceDxe 140E8004-16E1-4DE1-A352-C6EF51110ECF,ArmSmcLibNull 1410C6AC-9F4B-495B-9C23-8A5AEB0165E9,SmmSwDispatch2OnSmmSwDispatchThunk 1410C6AD-9F4B-495B-9C23-8A5AEB0165E9,SmmUsbDispatch2OnSmmUsbDispatchThunk 14186114-B990-4734-898E-5F86FAE49784,DellHwmIoDxe 141B0F7F-E241-4659-91BF-4505D79A7714,FjCpuInfo +1421D662-67BF-4A23-8B32-607E1C9E3AEE,MacAddressPassThroughDxe 142204E2-C7B1-4AF9-A729-923758D96D03,AmiLegx16Bin 14257B56-BDA2-4FAF-8E4F-C885DF75583C,IccPlatformDxe 1428F772-B64A-441E-B8C3-9EBDD7F893C7,QemuKernelLoaderFsMedia 143B7632-B81B-4CB7-ABD3-B625A5B9BFFE,EfiExtScsiPassThruProtocolGuid +143C715E-E903-4667-BF15-03F5A542F58E,ClientronShowSystemInfoDxe 1440F976-2332-4DF3-B77F-62F8C6C1EFFA,AmdNbioBaseRmbDxe 1448C340-0202-4711-9C4B-2D063AA6475B,ProgressBarEmptyLeftEndcap 144C3319-5F75-4A9F-A939-882A7AB29979,FjM2WlanEnableDisableDxe 1450464F-EB36-4AC6-ACEB-DAACC8FC3218,BoardSelectPei 145372BC-66B9-476D-81BC-2127C376BB66,FFS_pad +14575E7C-03D7-4A62-9C01-4EBFBD48BA48,SmbiosTypeAdd 145971E9-AD52-4094-A8C8-BE5B3FECC82D,CpuPeim 145E152B-3DDE-4EB4-99A7-77083C2BCBEC,DellFmpMcu 14610837-4E97-4427-96E0-21D9B2956996,EsalVariableDxeSal @@ -844,6 +930,7 @@ 147B4839-5DBE-413F-917F-DFEB687C6312,PchResetPeim 14814579-D905-4A3B-8874-410B518674E7,RstNvmExpressSmm 1484EBE8-2681-45F1-A2E5-12ECAD893B62,ArmJunoDxe +14862240-96E5-4986-AB8E-9CEC8BC2AB57,ShowBmcIp 148C8945-F4A2-4586-A508-42F5470B2D47,DellSpdSmbusAccessDxe 14982A4F-B0ED-45B8-A811-5A7A9BC232DF,EfiHiiKeyBoardLayoutGuid 149A6B53-FAFA-44F9-8BAF-F50C68A05236,ScInitDxe @@ -854,6 +941,7 @@ 14BD268F-76FC-4EDB-87F0-F0D4EBB256B4,VfsFingerPrintDevice 14D159A2-52ED-465D-9353-F239C5464BF5,DellSmmLomProtocol 14E7D9BE-7834-477E-A942-FF5F823EE249,DellSpiPartAtmel +14E9734F-3644-4F3F-ADFE-AB80BF5B48BC,SMBGlobalAcpiNvs 14F95E01-D562-432E-844A-95A43905107E,GuidBase 14FC52BE-01DC-426C-91AE-A23C3E220AE8,EfiSmmSxDispatchProtocolGuid 14FF38A8-ACBA-4228-A7D7-A73260C7559B,PiSmmStatusCodeOnFrameworkSmmStatusCodeThunk @@ -876,6 +964,7 @@ 1551A247-BB31-4393-8BB4-10509AE2F18F,ChargeLedDebugPei 15551AF8-56A3-43DF-B0BD-22422AD2F08D,DeviceStatusDxe 1555ACF3-BD07-4685-B668-A86945A4124D,CpuPeiBeforeMem +15721C79-5720-4838-A544-052563708E24,AlderLakeSmm 157C666C-7C74-4E4A-B639-7BBA21487CE1,QFanDXE 15853D7C-3DDF-43E0-A1CB-EBF85B8F872C,EfiDeferredImageLoadProtocolGuid 158B59E5-DE4B-4964-8306-40C03F5B5D57,FjMeDataRecoveryEventLogDxe @@ -883,8 +972,11 @@ 158DEF5A-F656-419C-B027-7A3192C079D2,ShellVariableGuid 158E2079-23F3-4E83-8A35-657A76408C0A,ApobSspPei 1597AB4F-D542-4EFE-9AF7-B244EC544C0B,EdkiiPeiPciDevicePpi +15A02416-DC90-4F8C-B687-093FFA8BB966,AMIProjectDxePriori 15A450BE-5D20-47E9-8B3B-856058CCD408,AsusNct6796DHwmPei 15A5BAF6-1C91-467D-9DFB-319D178D4BB4,UniversalPayloadExtraData +15AF363B-7C41-4D1A-800D-8BCEE473FF3B,AdlMiscellaneous +15AFBE86-E7F9-42F9-A02D-E95043E62F98,AdlSmbios 15B985C5-7103-4F35-B59D-2235FC5F3FFE,UsbTypeCDxe 15B9B6DA-00A9-4DE7-B8E8-ED7AFB88F16E,CpuPolicyInitDxe 15C5E761-58D8-461A-9173-CAB020916264,VAminiPort @@ -892,6 +984,7 @@ 15C80344-F980-4BF5-AAA0-BFBE027AEF16,LenovoEcService 15CCACBE-2A4A-45ED-9EC2-53135F98AB24,BmcAcpi 15CF24A9-F9AB-46D0-8DCF-83664C632FD8,MemDetect +15D101A9-60C5-4577-9672-DE91842D01D5,FjRTS52500S 15DD5676-2679-4E24-9CAA-85B22DD893EB,LenovoSecureFlashVerifySmm 15E4C005-52C0-444C-8C94-56FFA04C7B36,SmuV12Dxe 15EB6248-FB67-4690-B368-270B73B6ED2C,OemUniversalDxe @@ -906,11 +999,13 @@ 16259EDB-3A84-4FC1-34BA-BA5AC23256DC,OemWwanDxe 16271FCA-55D9-4A33-93FC-5A3EB128DE21,MiscSubclassDxe 16271FCA-55D9-4A33-93FC-5A3EB128DEB6,CrbDxe +16271FCA-55D9-4A33-93FC-5A3EB128DEC7,EcsPlatformDxe 16271FCA-55D9-4A33-93FC-5A3EB128DEE6,OemDxe 162793AA-0FE7-4010-9818-45F55C5CCC3E,AmdCpmInitDxe 16287BA4-5B9D-4D98-919F-7B7B78CB2BE0,AmiLoadCsm 162CCA7D-DB17-4CD4-99C4-15F16282206E,GoodixTouchpadUpdate 163699CA-FFD9-4EFA-9901-A7B2DF3DE7D1,Class3Smm +163BA792-F811-4FBA-AE8C-101732F0328F,AdlSemaThermalControl 16449EDB-3A84-4FC1-88BA-BA5AC23256DC,OemWwanPei 164B86BF-B265-4033-92F9-BCB6D4ADC0C9,OobProvisionDxe 164CE56B-5EBC-4984-B0DA-C12B4F21D2EC,AmdRasRvSmm @@ -932,6 +1027,7 @@ 16A4ADD0-EF11-4C86-B159-88A2A8C4501C,wifi_3bars 16A66E14-40A3-4A0C-B569-1C6822373345,AmdSocFp7r2PhxPei 16AD4FE0-B5B1-11DF-8CBF-0002A5D5C51B,PL310L2Cache +16B14E2B-DAD9-4618-ACE2-7D324A26F9A0,FjGpioResetPDPei 16B45DA2-7D70-4AEA-A58D-760E9ECB841D,FD_Drv_X86 16B6109E-194C-440F-94F8-C7CCCCC32DEB,EfiCseEndofPostProtocolGuid 16C368FE-F174-4881-92CE-388699D34D95,SmmGpioPolicy @@ -940,9 +1036,12 @@ 16D0A23E-C09C-407D-A14A-AD058FDD0CA1,ACPI 16D11030-71BA-4E5E-A9F9-B475A549048A,EfiRedirElogProtocol 16DBCD0A-ED77-442C-A4AB-3DCADE378A1C,ThunderboltNhi +16E9BA4E-9EE9-48A8-A9A0-8E5F529911DA,Pca6107Pei +1705E39E-C353-11E2-A187-047D7B99E097,SetupMenuService 17088572-377F-44EF-8F4E-B09FFF46A070,Microcode 170D9568-C969-4FA1-A533-DB6779BFBE62,LenovoEn25Qh128FlashPartSmm 170E13C0-BF1B-4218-871D-2ABDC6F887BC,EfiOEMBadgingProtocolGuid +171148F3-6CF6-4C58-85D6-73013E19D90E,DriveEraseInterfaceCoreDxe 17119241-1153-970D-6509-75DCDFA41774,SbSocRavenDxe 171272DD-45CF-45E8-BCD9-F3891BF22975,BiosAuditLogDefaultsAndWmi 171E9188-31D3-40F5-B10C-539B2DB940CD,EfiShellPkgTokenSpaceGuid @@ -954,7 +1053,7 @@ 17390333-4CE6-48A8-AFB9-0EF55B666B74,RunTimeAcpiDxe 174005F5-3663-4305-9062-904B2BE2D07A,ApobPhxPei 174A8F8A-7B53-48B4-ACA9-D955AB1B5E90,SrSetupPure -174CF46D-B167-4E6A-B1CD-D41E24EFA0F9,ASUSBackupSmm +174CF46D-B167-4E6A-B1CD-D41E24EFA0F9,AsusBackupSmm 1755E35E-3B29-4F3A-AD20-80788159DA1F,LEMPasswordStoreProtocolSmm 17565311-4B71-4340-88AA-DC9F4422E53A,SmmBiosGuardProtocol 175A5BB0-1508-4714-A1CF-34BD56C825DF,FjHobFlexIOSave @@ -963,7 +1062,7 @@ 17689034-F11B-468B-8CC4-E114C77F41B1,AsusPTTDxe 17706D27-83FE-4770-875F-4CEF4CB8F63D,AmiAhciPlatformPolicyProtocolGuid 17772369-D262-4B90-9F31-BDC41F2663A5,mebx_main -177B2C74-9674-45F4-AAEB-43F5506AE0FE,ASUSPOSTMessage +177B2C74-9674-45F4-AAEB-43F5506AE0FE,AsusPostMessageDxe 177D39D2-43B8-40C8-9AE1-3C5198D6941E,PeiTcgPpiGuid 177E63C1-AED6-4D88-917E-9B4FB9FE4092,PhoenixSmmCoreServicesProtocolGuid 17851FBF-45C4-4FF7-A2A0-C3B12D63C27E,SdBlockIoPei @@ -978,14 +1077,19 @@ 17CCF600-3AA4-4FF7-82D0-19CBEB78F443,MePolicyHelper 17D09362-326C-4920-A50C-76F8A116A093,SeCPolicyInitDxe 17D290E7-49BE-41FC-BF62-912C17152FA8,DellSimulatedECDxe +17E9EC9E-4036-4237-B074-D1F29464599C,OemDataRegionFlashSmm 17ED0DA9-EAC5-4613-BDE7-C3A506917676,LoadPartialDefault 17EE496A-D8E4-4B9A-94D1-CE8272300850,EfiPeiBootInRecoveryModePpiGuid +17F76387-DE12-4E59-A107-485BB133B4D6,SecureBioDxe +17FE14B6-9ABA-43C3-BEB0-D12F81AAA883,AmdCpmDiscreteUSB4Smm 180636A5-871B-496D-B8F3-E83EF196D100,menu_top_right 1807040D-5934-41A2-A088-8E0F777F71AB,NvramDxe 180D765F-C489-4F7A-8A3F-596018499EAF,DTbtDxe 1810AB4A-2314-4DF6-81EB-67C6EC058591,BootScriptTableBaseGuid +1812EFD5-0DFB-44D7-9AD6-74FCBB33B192,UiAppWrapper 181E874D-C089-4C99-8EC2-6D6761348220,AmiPllOverVotageFlagHob 18231874-2933-4A4C-AAF1-65B4A752A409,FwHealthReporterDxe +1826B10E-ECE1-4BD1-B351-BC469D17FC59,DellPlatformSwSmi 182F61F3-A6B7-4B56-AB1C-6EF6DDE09798,FjGabiFlashBiosRegionCtrlSmm 1830A6DD-E03D-4BC0-B115-94D91950FE4A,SioDynamicSetup 1834A306-0D70-470E-901F-2370FF30DDAB,DxeSpiNorFlash @@ -995,14 +1099,17 @@ 18435CD7-8003-4CED-AFA4-ECBC440C0F30,FwBlockServiceDxe 1849BDA2-6952-4E86-A1DB-559A3C479DF1,EdkiiFirmwareManagementProgressProtocol 18578E75-D073-4203-90D2-8788A871E44D,LenovoComputraceSmiServices +1859044F-C25A-4AA8-965A-2410D06A603F,ApobBrhPei 18633BFC-1735-4217-8AC9-17239282D3F8,EfiBttAbstractionGuid 1879BFDD-47FF-485B-88FB-4FCD206E49F4,AmdSocFp7r2RmbDxe 188DAED4-939D-4FAA-9F47-F01D5C16DD82,H19ErrorLog 189641F9-4F75-423F-9427-6457E8ED095D,DashSmm 18968E73-3C45-4333-B97F-8764C23923AC,FjAutoBiosUpdateInterfaceProtocol 18A031AB-B443-4D1A-A5C0-0C09261E9F71,EfiDriverBindingProtocolGuid +18A3B667-14AF-4AE7-840F-CD6317EA0CBD,NbRsRouting 18A3C6DC-5EEA-48C8-A1C1-B53389F98999,EfiSmmSwDispatch2ProtocolGuid 18AF0E1A-CDB4-48C2-B111-14CB070417BF,SyncCBSconfigPei +18BD198C-ECF5-40F2-98ED-C388C3FD9136,DRAMPei 18C040D4-15E4-4148-B7B3-582764710BBC,FprValidityRaptorDriver 18CB2CF0-40CD-11E5-B970-0800200C9A66,DellDptfChipsetDxe 18CC225E-8799-4945-9F92-EBB96423D6C1,FjGabiFlashCommonGbeRegionCtrlSmm @@ -1017,18 +1124,24 @@ 1905FCF3-DDB6-49BB-A785-1E50C807160D,SystemSlotInfoDxe 19123709-F770-4FAA-858E-3BD5FB18464D,OemSmi 1916F73E-C824-4F91-AC9C-BF1FD28E4431,DellServiceMenu +1925903D-3FAA-4A91-A257-448F4513B309,AmdNbioPciePei 192AFAB3-55F8-44B8-B49E-275A9DFDD03F,SetupFunction 19342D99-FF4E-4798-A3E0-FA36C961CCFE,PdtCapsuleDxe 1944F611-FBCC-40BC-88C8-850D0FE514E3,WCN6855 +194D473A-01F6-48AE-9429-FD395813BE47,AdlinkNxpPei 194EE52B-02FE-418D-AA10-2E61E51CB894,DellMonotonicCounter +19618BCE-55AE-09C6-37E9-4CE04084C7A1,httpDynamicCommand 1964A5A5-91DF-4B2A-B3C4-8B4BF238D0BF,SystemVirtualKeyboardDxe 1967167B-A13D-4E45-801B-A605D11946D5,AmiTseOemPortingVar15 1967DD9B-B72C-4328-8C80-D4ACFC83FDF8,PciHotPlugDxe 196BFE1F-51FC-43E6-8E14-D421552BF0C7,FjFlashMapRt 196CA3D8-9A5A-4735-B328-8FFC1D93D188,TcgPlatformSetupPolicy 197DB236-F856-4924-90F8-CDF12FB875F3,Microcode +197E8644-1C26-7644-B5B4-978ED7301AD7,PlanarSelfRepair 198251A4-DE06-442A-AAB7-B0EE1E6DB8FF,GenericVar +1983E991-5033-43DA-8EA1-16D03AE895C8,MemoryMarginToolHookSmmShp 1988A1D8-04FC-4D68-B58D-636F36F30D82,SoftStrapsPeim +19984B85-18A1-468C-AF3E-C3D93F18C9FA,AsusSetupRestorePei 199C1EF0-6400-41C5-B0A4-FFBF219DCBAE,QuarkPlatformTokenSpaceGuid 199FD111-0785-4132-A9B3-1F66573F0060,GenericComponentsSmm 19A84692-4AAD-C04B-90E9-E017360A9860,DiskImage @@ -1038,6 +1151,7 @@ 19B23409-85BD-44B0-897F-ECFE8AA7A145,SmbiosElogType15 19B4BEAE-54DA-4AA9-98B0-41ED75D805BA,EcRotTpmRecoveryDxe 19B6F165-7855-42E8-AA6F-2361CA87E024,LenovoSmmVideoInt10 +19C2A1DC-73CB-46BF-A420-4C5558F958E8,DmiEditorDxe 19C4B49D-28DA-4232-996A-D175BBF6AFF7,SystemBiosSelfHealingPremiumDxe 19CB87AB-2CB9-4665-8360-DDCF6054F79D,EfiPciHotPlugRequestProtocolGuid 19CE57CC-628E-4F96-93D4-3C21F823C343,LEMPhyPresenceSet20 @@ -1074,15 +1188,22 @@ 1A931FB8-C466-454A-B684-73ADA2CB050B,AsusPostMessagePei 1AA34862-C1D3-49D1-9281-9F261545C09C,FjSystemDataFvDriverSmm 1AA6D900-89D1-4C21-9C50-EDC7390A67C3,SlotDataUpdateDxeNeonCityFPGA +1AA719F3-10A8-47BB-983F-3A03BABBB1EB,JGPIOCtrlPei 1AAF6A9B-CB1B-469E-9420-0D3912B8E376,MrcHooksChipServicesPpi +1AB9B2FC-7A50-4FA2-A190-EEB35797571D,OpromUpdateDxeSierra +1ABCB349-299B-46E8-99D1-582D91B3AB54,RstEraseDxe 1ACED566-76ED-4218-BC81-767F1F977A89,EfiNetworkInterfaceIdentifierProtocolGuid_31 +1AD5B195-44D9-4917-9BAE-E14784979306,Fji210LanDriver 1AE42876-008F-4161-B2B7-1C0D15C5EF43,DefaultDataFile 1AE856C8-1C5A-45F0-8FC2-0093292DB915,IteOnlySmm 1AEA4E7D-D6F8-491E-BB5C-4BEC10C98C99,FchSmmDispatcher 1AEC7EDF-3287-4669-B114-33A1198A60C0,OemAcpiDriver 1AEC89FC-DB8D-48EF-A6CC-C87A0B63E934,XnoteSwSmiServiceSmm 1AFE6BD0-C9C5-44D4-B7BD-8F5E7D0F2560,DellDiagsSbControlSmm +1B037083-5F15-4437-BE09-6C68AC675B85,MtkWiFiDxeGen2 +1B04374D-FA9C-420F-AC62-FEE6D45E8443,FspDebugServicePei 1B05DE41-C93B-4BB4-AD47-2A78AC0FC9E4,HstiProtocolGuid +1B06C65D-466E-35C9-154D-4D91BC4B9F8F,AmdPspDtpmPei 1B06FA46-E65B-4257-8855-5828B7591E61,FingerPrintHDDPasswordChecking 1B08A1DB-F91A-4FA1-A911-255C417F1CF7,ServerMgmtSetup 1B0FB9BF-699D-4FDD-A7C3-2546681BF63B,EfiWiFi2ProtocolGuid @@ -1091,6 +1212,7 @@ 1B2042F7-5CE0-4360-B98F-2973CAE22B97,FjSysmanTeutatesSmmBin 1B26C724-C7D4-4DE6-B0B1-C622BC2937FF,SmartCoverPortingDxe 1B2C4952-D778-4B64-BDA1-15A36F5FA545,Slp20PubKey +1B31A273-217E-3377-23D1-AB0CF19B9D47,ChgbootDxe 1B346098-AB0B-4AE7-DDBE-88AB3CD6220D,BatteryIdm 1B417388-B6B7-4026-B849-30060477A2AD,BootDeviceOptionsWmi 1B45CC0A-156A-428A-AF62-49864DA0E6E6,AprioriPei @@ -1107,6 +1229,7 @@ 1B76B808-B90A-42A4-B0A0-BE61B121E114,FjTpmMisc 1B799E86-28CC-4DBF-A763-F7F33FFD2772,SmuV13Dxe 1B838190-4625-4EAD-ABC9-CD5E6AF18FE0,EfiHiiExportDatabase +1B8B5F2B-605A-4D09-AFDA-842C3933A050,AmiFchUart1Dxe 1B8DDEA4-DEB2-4152-91C2-B73CB16CE464,PeiAtaPolicyPpi 1B9CD864-DA7C-483E-8D69-D35CB4AD27C9,EfiWheaPlatformNonStandardErrorSection 1BA0062E-C779-4582-8566-336AE8F78F09,SecCore_VolumeTopFile @@ -1121,6 +1244,7 @@ 1BE9A477-92E6-4BA4-9496-C9DE8E152534,SbSocStarshipSp3Dxe 1BF06AEA-5BEC-4A8D-9576-749B09562D30,ProcessorProducerGuid 1BFC532E-F48A-4EBE-B2FB-2B286D70A6EB,IconUsbHD +1C015629-00CF-473D-BE1C-3561024F0569,AdlSemaDxe 1C0C34F6-D380-41FA-A049-8AD06C1A66AA,EfiEdidDiscoveredProtocolGuid 1C0D835F-C0C5-4848-B42B-95FEDBCC815C,GnbBristolRouting 1C110D74-159B-46B3-B47E-7B7AD22FA6D6,DellResetReduction @@ -1139,16 +1263,21 @@ 1C5FDAF2-9FB3-431B-8ECD-B7D35CBEFAE9,EfiAfterPlatformLocksEvent 1C606E42-F267-4A2F-95EA-A081B62E3F4B,H19CheckPointHddService 1C675C27-6FB1-4170-94E7-3DFFE8BEADBA,LaunchPad3Drv +1C6A6DBE-CA59-44E4-8D42-68FAC524A89C,SystemAudioDxe 1C6B2FAF-D8BD-44D1-A91E-7321B4C2F3D1,ScriptSaveDxe 1C728BAF-96B6-46E6-B549-E50C45898E3A,TamperEventProtection 1C733CB5-4C8F-44D9-BBF0-95477089EB08,DellSmBiosStrucDa 1C7B1FD9-373C-4569-8DC1-8DB2FFFA7639,NistDxe +1C8020B7-D2F2-42F8-852B-CBC232CCC9BC,AsusROGLiveServiceSupportDxe 1C83550A-7E5B-4A30-9E93-E2153771AA25,FjDmiCpu +1C871D93-BA95-474D-BA2A-397CCF9D2691,OemTurnOnAmp 1C8B7F78-1699-40E6-AF33-9B995D16B043,PiSmmCommunicationPei 1C98780A-C67D-4D9B-A9D8-4AC0487A6D6E,PcdRecoveryPei 1CA0E202-FE9E-4776-9FAA-570C19617A06,EfiPciCallbackProtocol +1CA7E5F3-2385-427D-A4AF-F6E28BB8BBEC,AmdMemAm5Pei 1CAE7577-D662-4727-BAEC-777631D3A958,SystemVspCmosPei 1CB1ADDA-D8DD-4C6E-8DEF-A0DACB2AEC83,RetimerCapsuleUpdate +1CBC61DC-3D35-41ED-8E92-9147A0D68E77,AmdMemFp8StxDxe 1CBFC9B6-7F1E-4E9E-801F-FBCE4D92A76D,AmiTseBeforeTimeOutGuid 1CC640E2-28EE-4D0C-8211-5D0E30967EE6,DellRecoveryMgmtDxe 1CC6FA21-4A9D-46B4-9EBF-9E42F5D044F2,FjCapsuleResetHookSmm @@ -1157,6 +1286,8 @@ 1CE692F0-3317-4574-8B57-4800ED091F40,DellDxeComputrace 1CE7C25E-02E0-4CB8-9410-766EEE8B8A97,FjMfgTpmDxe 1CE9B08D-7649-4EE6-AEF5-729A4DA7E469,EcIoDxe +1CEBDD17-1325-42BB-8A7A-22857CF10A5E,AmdFabricRsDxe +1CEC16EC-1C60-449B-9775-23CA66B93F52,AmdBoardIdPei 1CEE181A-DF5C-4391-BCA8-CDE5A5A1A0BA,OemHooks 1CF369C2-3C8F-4D75-AAED-45CFEB8E9B6C,UsbPortDisable 1CF3F8B3-C5B1-49A2-AA59-5EEF92FFA63C,EfiIa32X64ErrorTypeBusCheckGuid @@ -1184,10 +1315,11 @@ 1D82219F-386F-4F26-AFAC-613F242C0760,DellSmmStatusCode 1D85CD7F-F43D-11D2-9A0C-0090273FC14D,EfiUnicodeCollationProtocolGuid 1D88C542-9DF7-424A-AA90-02B61F286938,WdtPei +1DA02C3C-62E5-438B-B0DB-9E5128379661,EarlySmmDevices 1DA353A3-6400-4241-9AB0-E3E65C690EF7,IchSmbusArpDisabled 1DA69AFD-C297-4EE2-A086-0A41EB2B4DC8,XnoteGopVbtPei 1DA97072-BDDC-4B30-99F1-72A0B56FFF2A,EfiMonotonicCounterArchProtocolGuid -1DACE8EE-CD97-491E-8A0C-305D6437323C,OnBrdDevDXE +1DACE8EE-CD97-491E-8A0C-305D6437323C,AsusOnBoardDeviceDxe 1DB184AE-81F5-4E72-8544-2BAB0C2CAC5C,AmiBbsDevicePath 1DB29AE0-9DCB-43BC-8D87-5DA14964DDE2,EfiUserInfoAccessSetupNormalGuid 1DB43EC9-DF5F-4CF5-AAF0-0E85DB4E149A,BootGuardDxe @@ -1196,9 +1328,11 @@ 1DCFF17C-AA53-4B78-B234-864027555035,LibUefi 1DD1D619-F9B8-463E-8681-D1DC7C07B72C,EdkiiNonDiscoverableSdhciDeviceGuid 1DDA5978-B29A-4EA7-AEFB-8B0BAA982E22,ExReportStatusCodeRouterPei +1DDBB0E2-6FB5-4B1F-A14C-F2E5B5E59168,aqnicdxe 1DDBFD6A-3423-462F-9150-A7FFA66FF0CA,StaticSkuDataDxeLightningRidgeEXRP 1DE0B8C2-FFB6-4BDF-97F5-0FFB33979038,BaseReportStatusCodeLibNull 1DE25879-6E2A-4D72-A768-288CCB9FA719,EfiMemoryConfigDataHob +1DE2AB60-EB98-4D6B-9DCE-A7EF2202B3AE,AmdAgesaParameterGroupPei 1DE64B8E-138B-4258-B7DD-F2D8EC142A9E,AmiFwUpdateBmc 1DE6EF1D-DB01-4C27-AD29-C582887E2E18,OemSataInitDxe 1DF18DA0-A18B-11DF-8C3A-0002A5D5C51B,SataSiI3132 @@ -1214,7 +1348,9 @@ 1E2ACC41-E26A-483D-AFC7-A056C34E087C,EfiNorthPeakGuid 1E2ED096-30E2-4254-BD89-863BBEF82325,EfiTcg2FinalEventsTableGuid 1E30E33D-1854-437A-BD68-FC1553AA8BE4,CseEmmcSelectPpiGuid +1E321458-2CF2-4AFD-8102-C86423ECD18D,FjMiniCardModePei 1E43298F-3478-41A7-B577-86064635C728,OptionRomPkgTokenSpaceGuid +1E463F9D-4CFB-4396-A784-68C350BADCF1,AmdSpiHcProtocolDxe 1E469095-EFC8-4147-97DB-4D68B727E2E0,FwBlockService 1E4EAAB1-E637-443E-A5D6-56E60D97C619,UsbComboPeimPei 1E5668E2-8481-11D4-BCF1-0080C73C8881,EfiVariableArchProtocolGuid @@ -1230,8 +1366,10 @@ 1E93E633-D65A-459E-AB84-93D9EC266D18,EfiTapeIoProtocolGuid 1E93F29B-A3B2-F340-A605-DE31EE3DA031,EdkTerminal 1E97097A-C884-4BE4-A530-299F85BDC894,MediaSanitize +1E97E5F2-F850-0FD9-8191-C18FE43B0405,WnameDxe 1EA09F16-1A28-435B-8E8E-8AB7C1DE04D3,FjHiiString 1EA81BEC-F01A-4D98-A201-4A61CE2FC022,PerformanceExProtocolGuid +1EAF8A37-CD36-4267-831E-AC69789C5CCA,mSupplicantDriver 1EB667B3-3DD6-4F19-BA60-7C4638AC4062,AcerPortingDxe 1EBE5AB9-2129-49E7-84D7-EEB9FCE5DEDD,EfiEmmcCardInfoProtocolGuid 1EC0EFC9-C93A-4B62-9B27-C059ABD80E92,VlvPlatformInitDxe @@ -1314,6 +1452,7 @@ 20DF5C15-5E32-42D7-BB67-3390A0E51FFD,HpErrorLoggingPei 20E28787-DF32-4BDA-B7E7-CBBDA3371EF8,IdeControllerProtocol 20E687BE-B09B-4DA1-BCFE-E804B3B97CE4,CsmeHealthDxe +20EA66CA-17C3-4DD4-A51F-956CC9E4FC26,AmdIspCamera 20F8FD36-6D00-40FB-B704-D12C153C62EB,CcEventEntryHob 21073EF1-FF66-41FF-9BF4-A3E936DB1901,FchHuashanPei 21094ECB-9F20-4781-AE4B-50728B389A6E,IchInit @@ -1328,6 +1467,9 @@ 2167F964-7298-4A8F-9A2A-BFE498D600A8,HddReadySmi 216A681C-9E51-415F-9ADA-CB9FBCD05F5D,DellFlashIoDxe 21729246-5DF1-46A1-A5C6-2484BCD706FB,LEMSetVariablePreInit +21782819-FDA0-4ADE-BD36-C95F079F057D,AsusBackupAccess +217FA926-F494-4B3F-AC45-D213C2A0294D,PostLogo +21834F44-9201-4AA3-9B15-AFD794D93BC4,OemWakeOnRtcPolicy 218596FC-6EBD-4D19-A79B-41B13448021C,OemSWBoardIDDxe 21877E2F-F86E-4E8A-9C9B-D7B152DD40D8,EfiPeiPlatformTypeNeonCityEpecbPpi 21891A9E-763E-4377-8841-8D5C90D88C51,NetworkStackSetupScreen @@ -1343,12 +1485,14 @@ 21B0CB55-4330-4343-AFF8-A68089124118,DellServiceMenuConfig 21B564BF-53EA-40D1-85AE-EFFC93D28640,FchKeithMdnDxe 21BE6180-733A-443B-DF46-41C008047687,AmdNbioPciePei +21BF3644-1CE7-4E87-8C60-0A5C607173A6,RemoteFWConfiguration 21C3B115-4E0B-470C-85C7-E105A575C97B,EdkiiEmbeddedGpioPpi 21CCF0B7-246B-412C-A334-0B65A07B28DF,SmmBaseOnSmmBase2Thunk 21D04395-96A0-4FD5-B477-A922648EDAF3,AsusSampleDxeWrapperPkg 21E173D6-C221-48EE-A18F-B73D9810FBF6,AsusApmPei 21E34727-3881-4DEE-8020-D8908A980311,EpuHwModeDxe 21E70404-DF72-4122-B030-281306EB7BE3,VbtEdpTypeCGuid +21F2A221-0CF9-4E0A-9FD0-2DADDC025E31,BctBaseSmmSTX 21F302AD-6E94-471B-84BC-B14800403A1D,EfiSmmCpuSaveStateProtocolGuid 21FF1FEE-D33A-4FCE-A65E-955EA3C41F40,QNCMemoryInitPpiGuid 22046D50-F390-498C-92E5-5BA4F8E7F8B6,SBSATAIDE @@ -1361,12 +1505,15 @@ 221D6760-4AC0-4C12-BA96-9C63E4D9C1C8,HwmInitPei 221F1D4F-034C-4BEA-B2BB-B7A9672B06D7,CrbSmi 222C386D-5ABC-4FB4-B124-FBB82488ACF4,PlatformPei +2236B8BC-E488-4424-BEB9-97C8A1483693,PlatformOpalDxe 2237C798-93E7-4119-B10C-CF75CD22BFE0,AmdApcbZpDxe +2240157B-A45A-46EB-9A7E-1E79C4781FD7,HWChangeWarning 224453CE-FED2-49CC-A42F-443FF9CCB6C7,Ast2600VgaDriverX64 224FBFE4-ADB6-4DF2-B835-602182AEEF20,Clock 22597239-6107-DF44-AD3F-5F053E92222E,EmuSnpDxe 225C3A5A-5902-4307-968A-AF8DEFFE61E8,UsbPwrCtrlSmm 226824A3-1989-4D6C-BD17-C863845F7E99,DellSmiCpuDecodeProtocol +226A500A-E14F-414A-A956-40E5762D3D1E,PrmLoaderDxe 226D28E1-7672-48D5-ADDC-E5F91F398A3E,SetupConfigUpdateDxeExpertWorkStationRP 2272865B-EBF6-4047-B008-7889497F53BD,SuperMDriverProtocol 22766CBA-D444-4A04-9E77-50BB240F00A6,VPMSmm @@ -1376,9 +1523,11 @@ 228F7D4F-231C-6BAA-BDCB-BEA9875B04D3,AmiCpmWrapperSmi 22951F5E-4F7B-405B-8ADA-ECDC431C616F,UefiWindowsInt10Workaround 229832D3-7A30-4B36-B827-F40CB7D45436,EfiPeiStatusCodePpiGuid +229B7EFD-DA02-46B9-93F4-E20C009F94E9,CpuS3DataDxe 229F268F-23B0-4436-83E3-8B7AE08A6BD8,EfiMfgUuidHob 22A5BB4D-F962-4D33-9CD6-FDAD39ACD153,PlatformBoardIdPei 22A8C2C1-9F75-4B9D-B037-22CC43E6929E,SioDummyPei +22AAB6B3-FDAD-4383-A6D4-1CBAD157C895,AcpiI3cSlaveSsdt 22AAFFEA-2358-4C53-9AF0-CC0CCB06E2EF,PanelResolution 22B194B4-CC0E-46C7-9FCE-DA10D6ED1731,PchSmbusArpEnabled 22BDEE84-C807-452E-B56E-F683FD76C989,BuslogicDxe @@ -1393,13 +1542,17 @@ 22F8B88D-4E9E-4DA3-8CD5-74463593EF13,DellPeiDiagLeds 22FBD744-CA98-4F6D-9882-954201312DA0,H2OVarCheckRuntimeDxe 22FDFF5D-EF58-4E45-B515-A41067D5C80B,AssetQrCode +22FF12F3-4B62-172F-37A6-A6BEDAB1FF63,I2CcontrolPei 230F6679-F703-4DC2-B2B7-41C670BCC0D1,BiosInfoRecovery 231BE53D-B6E3-44D8-A8D5-E0566E55663D,EsrtOverrideDxe 231CDC65-129E-4870-A882-79244127BDE3,SkipStoragePwdPrompt 231D3A65-9442-4507-A4E4-E9D2176578F1,DellSmBiosStrucB1 2325F2FC-5683-4648-97C4-9A520DFBE325,AmiTcgPermFlags +232D6306-B70C-48BB-88BB-9FA6D47C8208,RtcStatus 232FB018-F308-4081-B280-812E6164123B,PasswordMgrDxe 23321FFD-1F8E-4597-84EC-4DAD0E2BA995,SmmLockS3 +2333A860-A228-462E-8121-7B49895C11C5,ASRockSIDxe +2336A93D-08D7-41C5-AFC1-CDB60C94CDA4,CaseOpenPei 2338337A-47B0-4C41-9CA7-0160FB94DFF4,PlatformFlashDxe 233C2592-1CEC-494A-A097-15DC96379777,FwVolDxe 233DF097-3218-47B2-9E09-FE58C2B20D22,LenovoPlatformStage2Pei @@ -1416,6 +1569,7 @@ 2374EDDF-F203-4FC0-A20E-61BAD73089D6,IoTrap 237CC158-6032-4832-B0BA-1F83C0FCA609,CoreHotKeyProtocol 2383608E-C6D0-4E3E-858D-45DFAC3543D5,PciHostBridge +2386622C-FC1A-4B5B-AE3A-C81FB30AF128,FjDxeLeg 2386E231-A9CF-4F52-946A-6F6B6C133B46,DellSmBiosTableLoaderDxe 238D654D-A6AD-41C8-A31B-67A3208625C3,LenovoMx25L3206EflashPartSmm 239421F6-F025-429C-9889-AB854E00EEE6,CheckRaid @@ -1427,7 +1581,9 @@ 23A7B657-077F-4ABC-AB7E-B70D8A389DBE,DellVariableProtocol 23AF8BFA-1D89-47CB-876C-1BE11FA0F4B0,AtaIdentifyData 23B461D0-3C94-490D-9A4B-4AE1916BD425,DellAtaAtapiIoProtocol +23B4BD04-198C-4A11-B65A-A52B33C98C18,AmiHspFtpmAcpi 23C29286-947D-4270-B061-7FE5D0758B63,Legacy2Region +23CACE14-EBA4-49F6-9681-C697FF0B649E,VirtioSerialDxe 23D1280D-43F0-4713-90B2-0E5E4221AF4C,BatteryState1 23D93EAA-0723-4559-B768-5E22DF762DE4,LenovoTpmEnablerDxe 23EED05D-1B93-4A1A-8E1B-931D69E37952,Omap35xxBoardInterruptDxe @@ -1441,9 +1597,11 @@ 240612B7-A063-11D4-9A3A-0090273FC14D,SystemUsbBusDxe 240612B7-A063-11D4-9A3A-0090273FC14E,SystemUsbSupportPolicyDxe 24092BED-2736-40A7-8D87-515E8594F6B3,FjGabiOsEntryGateDxe +240C89B9-5BB1-494D-A0A6-8F0E1935B45B,AmdFabricStxKrkSmm 240E9BEF-B64B-4760-A05F-50027564EF1D,VariableBackupRestoreSmm 2413D304-AA41-4079-A81E-31B8D7C3FD6B,GpioV2PpiInitPei 24169E35-2454-4940-92BC-82321A2C7562,VlvInitPeim +242B3D0C-5FB8-4A75-9CD3-710DDFE42703,AmdNbioDxe 243373D3-C183-4F6A-9AE4-E38419FCDCCC,WarmResetFlagSmi 2433EC61-17BE-4B98-895C-333950C62318,RtkUndiDxe_2057 243C8C8A-BBD0-4AA9-BE17-CF9B583130EC,SmmOEMInt15 @@ -1455,6 +1613,7 @@ 245CB4DA-8E15-4A1B-87E3-9878FFA07520,Legacy8259 245DCA21-FB7B-11D3-8F01-00A0C969723B,EfiPxeBaseCodeCallbackProtocolGuid 246F9F0A-11E3-459A-AE06-372BDC4DE806,LenovoSystemStatusCodeGenericRt +2476ACB7-D4C7-48D3-AB73-7513B03BB5DF,AmdOemRasRsSmm 2477BE9E-8E1A-431E-B705-14E663717377,PsmiComboBufferGuid 2480271C-09C6-4F36-AD75-5E1390BD9929,QNCSmmDispatcher 24848D1D-A637-45DD-974F-BEBA0340FF96,RemotePlatformErase @@ -1464,38 +1623,48 @@ 249EDD7D-346D-4C90-B94F-16079EF061D5,AmdCpuPolicy 24A2D66F-EEDD-4086-9042-F26E4797EE69,RootBridgesConnectedEventGroupGuid 24A44CAF-0BF2-4514-90C4-C794B3E778F5,MePolicyInitDxe +24A6AB96-8A00-4CC6-BAE7-63A9D3DD3B42,SuperIoExDxe 24B09ABE-4E47-481C-A9AD-CEF12C392327,Omap35xxTokenSpaceGuid 24B14CB4-A14A-4E9A-AAD2-853335FA3297,AmdCpmModernStandbyFeatureDxe 24B4980D-3F4D-4529-B326-CBE87E35013C,AmdDmarControlPei 24BB68E0-0922-44C4-84EA-95FD75E59DE2,AsusGpnvVersion +24C33F98-505D-4177-90F7-A20CF8FF3020,ReTimerFmpDummy 24C5DC2F-53E2-40CA-9ED6-A5D9A49F463B,EfiHashAlgorithmSha1NoPadGuid 24C6F3E2-6ACD-436B-A604-56A5CF742A55,BaseFspPlatformInfoLibSample 24C856A9-46E7-4635-8017-0FDCCA1FF9C9,AmdFabricMdnSmm 24CCD374-3DF6-4181-86F6-E3C66920A145,UpdateMemoryRecord 24D7AC91-3A1A-44B7-8CD5-0800A66BCFE5,OemBadgingSupport +24DC0658-F2CD-4034-B50D-2634640C35BA,AsusHardwareSignature 24DDC83F-9F06-44AB-B696-60FE7DF2C948,RstVmdPeim 24E24F91-2E6D-4525-BAE9-B977DE2005D6,AepLogDrv 24E70042-D5C5-4260-8C39-0AD3AA32E93D,EfiSmmEndOfDxeProtocolGuid 24E9A512-3A25-4CBA-A0AE-67C053BDF3B6,DxeVideoTextOut +24FF7176-8B2A-4138-9509-3D5E3059BCF4,ExtendOperatingAmbientTemperatureModeDXE +25053BB9-01AE-4AF7-82A7-CDA6D9545921,TouchPad_Synaptics_2nd 25075106-F537-4BD4-AFA5-CFF0E6F3B2A6,AmdFabricRvDxe 2509B2F1-A022-4CCA-AF70-F9D321FB6649,EdkiiDeviceIdentifierTypePci 2515F54F-3277-47DA-86A5-484510DD08E1,AmdPspDxeV2Mdn 25247A74-9440-47D5-BF0A-ED92A4D6EBA4,DellComputraceBinary 2525B0F0-80C2-4AF7-BC68-3BE4BB42C11E,PermanentlyDisabled 2525C3F2-E255-4375-A7C9-92D1054D62B8,MsiBoardECPei +25264B72-7A80-4856-A7EC-15802270EE1B,CheckBootGuardKeyDxe 252E599F-D604-4BEA-8FEB-347668E93B8F,FjRTS54xx 25330D5D-5474-4EB8-8192-E6DE3D5ED0B6,DellVariable2Smm 253E85E9-993B-439B-B74C-6120F77B4723,PlatformReset 25462CDA-221F-47DF-AC1D-259CFAA4E326,DtPlatformDefaultDtbFile 254901AD-7DB7-45F8-93C8-93D579398D9F,PeiPciSegmentLibPciCfg2 254B4A79-772C-45CC-05C9-17F84C2EA197,HpAmdXhciDxe +254BAFFE-F25E-45F1-A06F-5EF11443ACA4,AmdMcaZen5Dxe 2554EF5E-C9CA-4A48-9D94-249EB1E87C2D,LenovoCryptService 2555A2A2-101B-4775-B11E-47674F446628,FjPostManagerProtocolAbstractionReference 25566B03-B577-4CBF-958C-ED663EA24380,EfiSmmGpiDispatch2ProtocolGuid 255D96A8-1579-4ADF-8575-56D4B0467117,DellTcg2EarlyPlatformPei +256A381E-0165-4909-8663-EE317819292E,AIMT 258A5F45-00D5-485B-84DB-0B6D4AAB5E2F,TbtSsdt 258B415E-3E8E-4B82-8067-9EFC7949EAC8,ResetSystemDxe 258B77C1-5989-45A4-BFFF-7DAF147B2CE0,FjAddingFlexIoToSmBios +259311F9-A268-46C9-8DB4-79ACFB2B7DC1,EarlyDevices +259495EA-2DD9-4EA5-A111-61F58781499D,I2cMasterSmm 25A4FD4A-9703-4BA9-A190-B7C84EFB3E57,FdtVariableGuid 25A8824E-6BBF-4FB2-A200-84B0F7BECE6B,B57785 25AC458A-CF60-476E-861A-211C757657A6,SnpDxePort @@ -1518,10 +1687,12 @@ 2601C96E-243B-4509-AB14-DF2228E5B401,DellSbSmm 2605C8B7-EF64-475D-90F5-E767339F4D3E,OemUsbLightBarDxe 260AA875-0EED-4EE1-8A14-046B4FB17EF5,DetectRecoveryModePei +261230E3-22A4-3E55-40C6-50486D9F8D67,RTL8111dxe 2619EA76-4599-4978-8649-E7371170C256,OpticalDiskIdm 261E97B4-FBB5-4DB1-B25C-13270BA7BB60,EmulatedEepromDxe 262B2E3F-DA2D-4B81-8D1D-F938E851FDED,SmcBoardInfoVariable 263631D7-5836-4B74-BE48-EE22E92CE5D3,WinNtConsoleDxe +2636FCAC-B54E-4AA5-A720-49887CE228D2,ClearCmosPei 26452F27-45DE-4A94-807A-0E6FDC1CB962,EmuPeiGateDxe 266E31CC-13C5-4807-B9DC-39A6BA88FF1A,CpuInitDataHobGuid 26703ED8-9171-40A3-95C2-56436F8A5E56,EfiBpCommonPkgTokenSpaceGuid @@ -1532,22 +1703,27 @@ 2686340E-665C-427F-8819-05BA54F030F5,IdeController2 2688B232-9C02-4C12-BE1F-857C0FF2AAE3,TcgDxeplatform 268F33A9-CCCD-48BE-8817-86053AC32ED6,PeiSmmAccessPpiGuid +2696F127-44B2-4E14-8BFF-804AA177FE41,SDJpegDecoder 26A2481E-4424-46A2-9943-CC4039EAD8F8,S3Save 26BACCB1-6F42-11D4-BCE7-0080C73C8881,EfiCpuArchProtocolGuid 26BACCB2-6F42-11D4-BCE7-0080C73C8881,EfiMetronomeArchProtocolGuid 26BACCB3-6F42-11D4-BCE7-0080C73C8881,EfiTimerArchProtocolGuid 26C04CF3-F5FB-4968-8D57-C7FA0A932783,DellSbServicesSmm 26C628F2-CED5-466C-8237-433CA4D24241,MemoryEvContent +26C9D769-9167-4537-8219-D9F5FC2378BE,OemUsbTypeCDxe 26CC0FAD-BEB3-478A-91B2-0C188F726198,EfiPeiVirtualBlockIo2PpiGuid 26CC7C04-4E9D-4FED-AFBA-CBF23334DC0D,AmtWrapperDxe 26DC4851-195F-4AE1-9A19-FBF883BBB35E,AmiAptioSigOwner 26DDBA9F-5B0D-4E80-86B2-80DAE4D01B0E,FdiskOemDxe +26EBEC07-930B-4B92-81B7-2BC104D1CDBC,Nct5124dPeiInit 26EEB3DE-B689-492E-80F0-BE8BD7DA4BA7,EfiSmmConfigurationProtocolGuid 26F8AB01-D3CD-489C-984F-DFDEF768395B,PeiStatusCodeMemoryPpi +26FD847A-DC93-4D93-917C-6041A3856CBC,FchHuangshanDxe 26FDEB7E-B8AF-4CCF-AA97-02633CE48CA7,EfiProcessorSubClassGuid 2700F72F-E0EA-4767-9A1E-D172F0704778,PeiSelStatusCode 270279D6-2554-47BE-97D0-6AE5AD18B973,OemEeprom 2707E46D-DBD7-41C2-9C04-C9FDB8BAD86C,JpegDecoderDxe +2709A182-0DDA-4A91-BA53-11032B713633,AmiPspOfbd 271565A5-6E05-4948-BAE7-39AF389FFB97,DMBMPEI 2717997B-ABAC-4733-ADAF-9C19D8FBB7A1,CbmrDriver 271B424E-A4CC-4E0E-90A2-7EA4841F12F3,ExportHiiDb @@ -1557,6 +1733,7 @@ 27270327-D3EC-4237-974D-D71ABB2EBFEA,FjMasterPasswordDxe 27287751-867A-46CD-91AF-416FF6AE3DFE,DellSystemIdConfigDxe 273820DB-55D9-5B44-93FC-6A4EC138EEC6,DellSpecialBootControlDxe +273D3086-65A3-463D-B5D6-AAC7CCC18445,PlatformTcg2Dxe 274365EF-0893-480C-9160-472A26D2DC0F,FjGabiGpioAbstraction 27470DBA-64DD-4C71-9CE5-5E3272207598,SioSmiSmbAlertDispatcher 274F0C8F-9E57-41D8-9966-29CCD48D31C2,SmmAccess @@ -1569,7 +1746,9 @@ 2785ED8A-795F-43A1-AE2D-6BFFECCBA646,AcpiUpdateCpuInfo 2786B637-5E93-4E57-B1D4-B69D8D496580,FjSysmanTeutatesSmmFjFextBin 278D0017-1F07-4F5E-A3EC-21D04DCC3A6F,IncompatiblePciDevice +279851D7-65A8-4009-A5B8-1F56BAB7E99D,AmdMemAm5Dxe 2799A453-FC10-4334-9E66-D3D6EF09D0EE,AmiTseOemPortingVar5Guid +279D52CB-5BD9-4BF7-99ED-5D365F73BEBB,AmdMiniRasRplServiceDxe 279DB133-B4C6-4A34-9BE3-C98326DC27DC,LEMHddSecurityEndProtocolHook 27A5159D-5E61-4809-919A-422E887101EF,PcatSingleSegmentPciCfgPei 27A71B1E-73EE-43D6-ACE3-521A2DC5D092,RepublishSecPpiPpi @@ -1590,14 +1769,18 @@ 27E569D5-0AFC-4D8F-8C90-783AC4A318AB,SaAcpiTables 27E94A0B-6E3C-4B4B-B876-176AE521CE60,DellHotSosDxe 27EEDF2D-469E-478C-805E-993CCFB5C0C1,CrbPxeLoader +27EEEC71-D849-4B64-A04B-5643CCEAC876,FchKunlunPei 27F05AF5-1644-4EF4-8944-48C4F75675A0,RealTimeClockDxe 27F3838F-BA27-4FFA-B374-35BEA28A431B,DellSmsc5544Dxe 27F4917B-A707-4AAD-9676-26DF168CBF0D,PchSpiSmm 27F51949-1577-4CF6-B2E2-AE9392A4EBB7,BootPriority 27F85559-359F-4B25-9B73-3EE5DE399121,DellSmbusHcSmm 27F9093F-527A-42AB-AE55-5C56DA8D9AB8,BootOrderDefaultSettings +280251C4-1D09-4035-9062-839ACB5F18C1,CpuMpPei 280BCC15-2CD7-467C-9647-1B30307D7ED5,AmiFriVariable +280DA667-74B6-410E-8ACD-D06C3F32EA20,IntelLANPei 2818256A-6BDB-4871-993C-95315854012E,EdidOverrideDxe +28260FD2-975F-48B4-B1A8-8F7919F55746,AmdOemRasBrhDxe 28324EF7-6BB3-4BAB-A2EC-18D5F7940F23,FjMaptDxe 28374747-76FF-41B3-9740-381EFAEF13BC,PspPlatform 283C945F-3FF5-4588-AD80-86E8708B942C,DellSimulatedECPei @@ -1606,7 +1789,9 @@ 283FA2EE-532C-484D-9383-9F93B36F0B7E,EfiUpdateDataFileGuid 28451AA4-B4C4-4AA9-BE3A-1BBCC2E5553A,GptRecovery 2846412B-F50F-4A5B-8C8B-76644324AA66,FchSmbusDxe +2848A12F-3F86-47C7-81D8-D3FD47B205B2,CbsSetupDxeRPL 28638CFA-EA88-456C-92A5-F249CA488535,EfiRedirFruProtocol +2864CA7A-632C-456D-A4FB-B5B718566956,ReportStatusCodeRouterRuntimeDxe 286BF25A-C2C3-408C-B3B4-25E6758B7317,EfiTpmDeviceInstanceTpm20DtpmGuid 286EE96A-5B1F-484A-9689-CF770DC89185,SioShmLock 28758215-0D0D-4136-A8C8-68AB6711DF46,EcFwUpdateDxe @@ -1620,9 +1805,11 @@ 2892389C-FBE9-43D7-B9FC-6C5D90D18456,TisDxe 2893CAF8-B638-41D6-8864-D924D189C0E8,SafeBatteryModeDxe 2894EC46-C67A-4256-87DE-34A741D85982,Mct +2896DAE0-778A-4231-86DF-1F54F752DB7B,FreeSpaceSkipFvCopyLib 2899C94A-1FB6-4B1A-B96B-8364975303E0,Ps2MouseAbsolutePointerDxe 28A02147-19D6-491C-AFEF-DB351BF46124,DiagnosticsJumper 28A03FF4-12B3-4305-A417-BB1A4F94081E,RamDiskDxe +28A76FE5-43D7-48A3-9714-C1B7BDD6DFB6,RedfishDiscoverDxe 28A88A39-DD84-483F-9BEF-BA1168C2F850,UbaInitPei 28AB63A9-5FB0-4C93-9C44-0DD8A1E9101D,AmdNbioAlibRVDxe 28B225EF-E6B1-4DC0-8D4D-49EFC857CCDF,FpgaSocketBbsGbe @@ -1633,6 +1820,7 @@ 28BE27E5-66CC-4A31-A315-DB14C3744D85,IscsiV6Private 28BF2E78-AD2D-4616-ABAD-7644CD7E47C8,FvBb1Pei 28C17F2E-4B7B-4708-885F-4784092C6254,ExBootItemDispatcher +28C7F2B1-B80B-4EEB-8DC7-0EA34954926E,FjEventLog 28D0232B-D26C-4B5F-94FF-B1340FC160B8,AmdCpuIdentifyPei 28D46803-7646-4DFE-90ED-8575584ED6E6,AmtDxePolicyInit 28D4DD89-169E-49DD-8486-A200A2FD3C21,AmiPerformanceProfiling @@ -1640,10 +1828,15 @@ 28E50D66-A0EA-4A44-977D-D07319B9304A,HeciControlSmm 28E59971-3F7E-4E34-8DED-0745907B484D,FingerPrintBindingDriver 28EBF627-9BF1-4719-A676-4AF8362FEB23,RTS5242Dxe +28EEC887-BE28-4B44-9FC5-41C70784D3E1,SwSmi534D0040Shp 28F6EFF7-0A9F-4BE3-B12E-B59A04266ABA,MeIgnitionFsp 28F6FD2C-EFF2-42F0-9E9F-CAC87509DC46,OemSmi 28F7B66E-DF6B-4D34-A420-91CA108E9D00,SecureFlashAuthenticationPei +28FB2B1C-90FA-4D2E-BB97-B104A96DE97D,AmdDisableDashDxe 28FD5211-3777-4A13-9A2E-66A7341D15E4,FjClearsureDxe +29010E46-1CF4-465F-BEE5-0FD9E5535AD7,FjLvdsFwDownPei +29018044-0EC2-4650-891F-0813797863B7,MeLock +29019496-1EE5-4ABD-9CC5-74A210CE77C6,Ax88772UsbNetDriver 2906CC1F-09CA-4457-9A4F-C212C545D3D3,AppleEpidGroupPublicKeysRl 290A4467-9F89-4F1F-A73C-E10B9FAFBD1B,FjFlexIoDxe 290B026F-6905-4612-BA0F-F635DDE35285,ErrorTriangle @@ -1664,6 +1857,7 @@ 294B196A-A3CC-4A43-857F-EEC26147857B,Tpm2DeviceLibSeC 294B1CEF-9BEB-42D5-9971-0C8963CDAF02,SmLogo 294B6514-CFCB-4CF4-8851-3F35330EAE60,RmtcPEI +294E3134-59C5-4C21-B59E-4A8F30515091,AmdPspPeiV2Shp 295B1031-F0B5-44F4-A75E-1CD2145C4D18,BreakpointCallbackDxe 296088B0-5AD7-46B7-A42B-004C2A0F00BB,AmdMemSmbiosV2SspPei 296E5F5A-3F3E-4B54-8395-98EBCC9407A6,AmiUsbCcid @@ -1690,6 +1884,7 @@ 29E0564F-B702-4352-A3A1-15FABD4A4E4A,IioCfgUpdateDxeLightningRidgeEXECB3 29E3DB8C-3B30-49D7-9262-53FB917B9A6B,BochsVga 29EA0DA2-84A0-4FC1-80E4-0531C7466EF6,DellSupportAssistUi +29F639F3-4BDA-49BA-89BF-BEC53CE48C2F,Tca9548aDxe 29FCFBE7-4B1E-3CB2-6D57-A994E8D044B0,AmdPlatformRasSspPei 2A0168CC-4320-452F-BACA-8BAEC7DAFBCA,AmdI2CMasterPei 2A1961E8-099E-4701-AEE0-F58C1ECF5B11,FjMiscControlSmm @@ -1706,8 +1901,10 @@ 2A4224A1-2609-40A7-88E2-A68DC0F1D180,SpiFlashProDxe 2A43BA5F-AC29-4FDC-8A3B-0328D0256F8C,SocketDxe 2A46715F-3581-4A55-8E73-2B769AAA30C5,RamDiskFormSetGuid +2A46A149-5F3A-41BE-87E7-982A68369D4A,AmdMemFp11StxhPei 2A4D1ADF-21DC-4B81-A42F-8B8EE2380060,EfiSmartCardReaderProtocolGuid 2A4DC6B7-41F5-45DD-B46F-2DD334C1CF65,LenovoConfigVariable +2A4EDBDD-CE8A-46C3-98AC-D1AD3DEE9D85,RepairResult 2A500CFB-920E-49F4-9988-5CE4C0EFD3AB,SmbiosDmiEditAfriSmi 2A534210-9280-41D8-AE79-CADA01A2B127,EfiDriverHealthProtocolGuid 2A537C0E-5D9C-45D3-A6CE-3AD02D3E3B53,ReserveMem @@ -1724,7 +1921,9 @@ 2A8EB7B1-4913-4B5C-A0C7-E70791A715BC,SystemMemoryManagerRt 2A9A39D5-95D8-4E2E-9793-BFAAF0B6820C,EarlySetPlatformHardwareSwitchPei 2A9D5E7F-A43A-4FC7-A25E-6E28D412FA6F,efi_pop_RT +2AA040F7-A1A3-4EEA-89CA-707E1A7E86B8,Int15Smm 2AA290DB-6B3D-40D0-9FED-89E004BB0CF2,LenovoSmmMeConfig +2AA8F59B-102D-4096-8FCD-B64422C637B5,UefiDiagnosticsApp 2AAEBE5F-BD22-4E05-B714-1B2B2338CD6A,RecoveryControl 2AAEC318-E84B-4E0B-BF41-AC65F17E9E2F,AmiTseOemPortingVar14 2AB4A35F-C2AF-ABCD-A22B-4AD3C58B7960,LogDataDxe @@ -1743,6 +1942,7 @@ 2AE9D80F-3FB2-4095-B7B1-E93157B946B6,EfiHashAlgorithmSha1Guid 2AEDA0EB-1392-4232-A4F9-C57A3C2FA2D9,BindingsSmm 2AF54A50-EE6D-4F12-BCFF-F0234FF57CA0,RTSCallbackHandleSmm +2B00C709-782F-4879-A59A-8E2FCE2271F8,AmdCdmaDsmDxe 2B0585EB-D8B8-49A9-8B8C-E21B01AEF2B7,AppleLegacyLoad 2B1D0832-2184-4C8F-A90D-8E4AF9DE5BCD,BootModePeim 2B268417-CFD4-4C29-85FC-4959300E4969,BcmCvUsbSmall @@ -1755,10 +1955,13 @@ 2B3685C5-CF90-4A67-8A48-9134BA32D677,PlatformStage1Pei 2B3FE36D-BE59-4110-8F42-7BAD910C9663,SsidDxe 2B4034AE-8566-412F-9CA5-67FD698FC261,TcoSmi +2B440005-2829-412F-B085-DD012BBE8A9F,AdvBootConfigDxe 2B475251-13C6-4547-B2F2-40762FEF9B89,SystemBootMenuDxeGui 2B4A109C-9ED7-47FE-80AA-2087E4E0301E,EcRotLockEcDxe +2B657C46-9AD6-45A5-AB5C-71CE3364AA3D,HQEepromSmm 2B72FC60-6D4F-42D5-8FF0-ABEFD5CDF859,HDCPSwSmi 2B73B074-2E67-498B-82AC-CE38FB770FFC,DxeSalLibEsal +2B798455-13A0-4910-B49D-2EB1FB5F77C8,ApobStxKrkDxe 2B7A240D-D5AD-4FD6-BE1C-DFA4415F5526,DtPlatformFormSet 2B7C4182-81B0-4AAA-9E70-B88AEC29B853,PeimBoardInit 2B872B22-6C11-4DFD-994A-96BC13920A43,fTPMTcg2Smm @@ -1772,17 +1975,21 @@ 2B9FFB52-1B13-416F-A87B-BC930DEF92A8,TcgEventEntryHobGuid 2BA071C0-B884-4D08-BCFF-518E16364C8B,PciHostBridge 2BA0D612-C3AD-4249-915D-AA0E8709485F,SdioDriver +2BA36F7A-F5E7-4D35-9149-60894CB37431,Nfa765Launcher 2BB5AFA9-FF33-417B-8497-CB773C2B93BF,CpuPei 2BBED685-6633-455F-A840-43A22B791FFF,AcpiFPDTSupport 2BC18FFC-7CF6-47C1-AF19-A4076DC00470,CbsBasePeiZP 2BC1C74A-122F-40B2-B223-082B7465225D,FspWrapperTokenSpaceGuid 2BD51C9B-EB2E-4CFB-95B7-0C5765FDCBC3,AtaDeviceService 2BD56418-461E-545A-8E24-A0BC15D40525,AsfUi +2BD66684-A214-493C-BAF9-70D9706E278A,DualModeDxe 2BD77D17-3771-4974-8644-F99CF5B266A7,IntelGigabitLanPolicyProtocol 2BD77D17-3771-4974-8644-F99CF5B266A8,Intel_10gLanPolicyProtocol 2BDED685-F733-455F-A840-43A22B791FB3,AcpiS3SaveDxe 2BE1E4A6-6505-43B3-9FFC-A3C8330E0432,TcgPei 2BE1E789-3548-43B3-9EEA-B4C8875E0321,A01ServiceBodyPei +2BF5D013-4E75-45FC-ACB4-9247145C1743,GigUndiDxe +2BFE7B9B-767A-44BE-80F9-6E0212899FE0,Pca9555aPei 2C009288-9C14-4AD9-8877-F0C2CBAA9893,HpKeyboardLayout 2C03C536-4594-4515-9E7A-D3D204FE1363,EfiFileExplorerProtocolGuid 2C056F2D-993B-4A54-8ADD-84ACE5D9CCE7,HpAcpiCore @@ -1791,12 +1998,14 @@ 2C194230-54B6-4C95-B809-877E83309358,ASUSGamingBoard 2C20B724-C903-435D-A5E5-2899E291D94E,AmdCpmPmfBoardDxe 2C2275C9-3A7B-426F-BE54-2D22BD9D1092,EdkiiCryptoProtocol +2C2694BC-FDD8-452C-8899-2A1A6B401D56,SndwInstallDevTopology 2C29929E-27CF-4DD5-BB97-E5525791F5BA,DRYDXE 2C3FFC0D-0AB4-4D75-B8EE-0086D76B8A0C,CxlPostMemInit 2C6B9CB7-A13B-4EEE-80C0-1A240C8A69EE,IccOverClocking 2C6CACC6-6C3C-4AA7-B2DE-384DAE2B0352,RegAccessPeim 2C6FF095-525C-4128-BD00-B8DA5E52A76E,AmdCpmSocAm4SmbRDxe 2C7087F9-B414-4969-B616-6B13BFEC0E38,FjSystemResetSmm +2C7314B0-A18E-4DAF-8B23-1F21D41572A8,HddSpinDownSmm 2C75A2A2-101B-4775-B11E-47674EEF6628,FjPowerButtonAbstractionReference 2C824F87-0F2C-45D7-81A6-4F39E042BDDF,EfiPlatformTypeHedtCrbProtocol 2C82AB3C-A734-4C7E-A790-F379BBF88F9B,PlatformMilestoneHookSmm @@ -1809,7 +2018,9 @@ 2CB67ED1-5498-45AA-9971-214964509195,SecurityEventPei 2CBC152B-B48A-4060-B009-DCB9379E5015,RcPolicyOverridePei 2CBF0E0E-B445-48BE-ABDD-B09A71303FC5,FjRtcWakeupSmm +2CC14F4D-6D85-4EDD-FEA3-4BC66D083AD7,HpModernStandbySetupConfigSmm 2CC4C70B-0312-4CD7-BFC2-A7A89C88C08A,DriveLockDxe +2CC919D9-5995-4F3F-9169-62301A6C72AC,ECUpdateFramework 2CCAF69C-6261-47BD-AC46-E6F471D654D9,StorageInfoProtocolDxe 2CDF679F-7AA0-4D0F-AFE1-1ADAE27061C9,FjMfgFirstPowerOnDxe 2CE0E430-A83D-4045-9040-D6BF6EC86300,CustomLogoDxe @@ -1829,7 +2040,9 @@ 2D3F7085-BA63-4739-A15F-C8802B6B807B,NCT3933Pei 2D408713-4023-4324-B8EA-53C02A83D941,PeCoffExtraActionLibSmm 2D4AAC1B-91A5-4CD5-9B5C-B40F5D2851A1,SpiFlashInfo +2D4F898E-2A20-446F-9D90-CBF6B46D45CB,AmdRaidPassword 2D513AE1-714B-4F93-A57A-0A0CDDF48ECC,BiosUpdateFaultToleranceDxe +2D586AF2-47C4-47BB-A860-89495D5BBFEB,IntelVTdDmarPei 2D58A07F-38A7-490B-86A0-D39F60ED7939,FjGabiEntryDxeBin 2D59F041-53A4-40D0-A6CD-844DC0DFEF17,SmmS3SaveState 2D61B52A-69EF-497D-8317-5574AEC89BE4,FirmwarePassword @@ -1846,6 +2059,7 @@ 2D9BD72A-B238-4BFF-9BB9-B51E0D4D553C,SlotDataUpdateDxeLightningRidgeEXECB3 2DA064D8-5A52-4DAC-B60F-54471A7FC372,CspFlashLibNull 2DBC8099-1A2C-0361-BB80-B9CC4F7F50D2,FlashPatchTableDxe +2DC22D1C-2B4D-4D04-9AD2-BC1D8FDE20FF,IsaAcpiDxe 2DCBE49A-1E5B-486E-BC23-48156B8282C9,X11DxeDriver 2DCD8815-74CB-4BED-A485-4B3928BF50EE,RsaBmcCommands 2DCE8BB1-BDD7-450E-B9AD-9CF4EBD4F890,EfiEventNotificationTypeCmcGuid @@ -1854,6 +2068,7 @@ 2DE2AE4B-7489-4D91-9B63-9B12CC564540,A01ServiceBodyDxe 2DE648CB-3102-43CA-A02E-42E38EA5E789,ProcessorErrorHandler 2DEAE482-5796-40F2-8DF5-D87419D6F362,ASUSHDDPW +2DEBAA89-2D51-485F-A2FA-2A62F9422364,HiiStringLanguageService 2DED8109-2355-41F8-A657-D608D5CC1022,SdxcDxe 2DEE4B44-C08E-4E60-9AEB-A11E2ADAA4B5,FchPeiAux 2DF10014-CF21-4280-8C3F-E539B8EE5150,PpmPolicyInitDxe @@ -1866,7 +2081,10 @@ 2E0F6A1D-B08E-456D-8815-77AEF39D4941,OemSlic 2E1128A1-18EC-419D-A058-1076E243E323,HpSioSecuritySmmProtocol 2E13E5F1-B86D-4CF8-990F-243B6B9B8C61,NvmeRaidDxe +2E1B8E61-9D16-466B-A802-3B1E92EA95EC,CbsSetupDxeSTP +2E1BB677-B167-4E39-9BB6-2F91467AC4CD,PciDxeInit 2E1C3FF9-DC75-41C5-BD48-26087B5DC92A,EdkiiVariableStorageIoCompletionProtocolGuid +2E226D21-7668-4A6C-916A-778AFA55A874,ClientronPeiDriver 2E2D1233-435E-F56F-7CC3-348CE660D1CF,SystemErrorEventsDxe 2E3044AC-879F-490F-9760-BBDFAF695F50,EfiLegacyBiosGuid 2E3AB8B6-AC9D-4D70-A675-54F52FB22D66,AtaPassThru @@ -1874,6 +2092,7 @@ 2E3D2E75-9B2E-412D-B4B1-70416B8700FF,RecoveryOnFatFloppyDiskGuid 2E3F2275-89CD-4DE4-BD84-BEBFD94BCDCC,DellSmBiosDaCiSmm 2E551A63-E2F8-4401-B617-ECDE2338463C,PlatformMilestoneHookDxe +2E58E381-3D7C-43D4-9A89-8D331362A2C0,BiosPostLogoDiyDxe 2E5CFC2C-9CC0-4D78-BEAF-D84CBF20D1C8,efi_pop_LF 2E67047C-7647-40F8-886C-5C333C73272F,InitSerialPortPei 2E694472-97F9-4D3E-940B-360A2731DEBD,RegulatoryInfoSupportDxe @@ -1883,10 +2102,13 @@ 2E7472A2-D7BF-4F5E-8FE4-BF19247856D0,SecCore 2E7D322C-0E5C-11DF-A0DE-1BF2A44EDC7E,VmwExtCfgDevDxe 2E7DB7A7-608E-4041-B45F-00359E0766C6,FvbServicesSmm +2E85FC4F-7050-4F09-9C5D-9A5DD01D3CB5,LegacyToEfiSmm 2E89AF61-6E76-42E6-8F3E-BCEE83C9526E,H19ServiceBodySmm +2E8A3B3E-F26C-11EA-BDE5-6726AD8F88BD,BootProgressPeim 2E8CD01A-BDB7-40B4-8376-E7C26EAC21FF,PciPlatform 2E8FF74E-8BA4-4CD6-814F-F96962DDFE27,DellDiagUtilityProtocol 2E97EA24-5866-4240-A891-D20AFC6074FF,AmdFabricZpSmm +2E9C3108-7C31-4728-8D61-F9EC77692383,AmdNbioGfxRPLPei 2EA77912-80A8-4947-BE69-CDD00AFBE556,EdkiiNonDiscoverableUfsDeviceGuid 2EA84160-ABA0-11DF-9896-0002A5D5C51B,PL301Axi 2EA9743A-23D9-425E-872C-F615AA195788,AppleRemovableMediaProtocol @@ -1900,7 +2122,10 @@ 2EC918ED-4DC2-4D77-BB83-A5912130F5B4,FchKTSataD3ColdSmm 2EC9DA37-EE35-4DE9-86C5-6D9A81DC38A7,AmdSevDxe 2ECED69B-2793-4388-BA3C-823040EBCCD2,EfiOSInfo +2ED4D0C3-809D-40A0-AEF6-52D683C86F23,AsusPTTPei +2ED74D39-F9D5-485D-8357-0E00FE871C12,TouchPad_Synaptics 2ED8BC59-0671-49ED-A86F-1B6760B380A8,SmuV13Pei +2EDBC810-AA96-4C83-B743-5ED9CFF79833,CnvDxe 2EE72E7C-FB9E-4318-B888-33A315C7A91D,PpmPolicy 2EE81ACB-64B2-41AE-8635-7030D16C4AA8,PchBiosWriteProtect 2EF1BA1A-C836-4A50-BF89-525FF29FF787,Mxm30Pei @@ -1915,20 +2140,26 @@ 2F1E20D4-17B6-434A-974B-CFAE19062CC2,DellMemorySlotConfigDxe 2F2295B6-1BB6-4CB7-BB9E-15C2C3424277,PcieSataController 2F240E12-E14D-475C-83B0-EFFF22D77BE7,EfiKmsFormatSha512512Guid +2F30DA26-F51B-4B6F-85C4-31873C281BCA,LinuxInitrdDynamicShellCommand 2F3962B2-57C5-44EC-9EFC-A69FD302032B,TopOfTemporaryRamPpiGuid 2F3B1D78-060E-4D5B-AC7E-1E1DB2128559,OemDevInit +2F46F5EF-F9B9-4E45-9ACC-B14C2AE072BA,SystemShutdownEvent 2F4DDD35-F8C0-46D2-B0E3-A701360D7499,PcieLaneDXE +2F56AEDE-B753-4A08-8A8B-5765931B9724,HpIntelChipsetAcpiArea 2F5AB7EA-DA90-4E84-83EE-5F7397254531,BindingsPei 2F62A818-4A72-CD40-90B9-FF00DAABEE7B,EmuThunk 2F707EBB-4A1A-11D4-9A38-0090273FC14D,EfiPciRootBridgeIoProtocolGuid 2F70E1E7-4F99-4401-851B-2042AE38FB74,AsusSetupHookDxe 2F72309E-D5B0-4A9D-84A9-1AB38C698F78,EcPs2Kbd 2F7673E9-7C0B-435A-9B22-A801BF25FCE5,SioThermalErrorDxe +2F7E0C26-A57F-5F4F-AFCC-CD3D5EE07CED,PlanarSelfRepairApplication 2F841C60-1B1F-4007-BE6D-753CCBE05740,ODMSMBIOSTypeCASmm 2F87BA6A-5C04-4385-A780-F3BF78A97BEC,EfiBlockIoCryptoAlgoAesXtsGuid 2F8CDF1D-80E6-4FF0-95DB-2C3E071A1774,000_X64 2F9AC9E5-E3E9-4096-9EE9-28AA6F763E59,DellHttpsBootManagerSmm +2F9C1C3D-28AA-469F-85C0-193DB9D50678,DeferredPsbFuseDxe 2FA2A6DA-11D5-4DC3-999A-749648B03C56,PiSmmIpl +2FA5F75C-BF60-472F-AD9A-FD23AD5B937E,SmmUartModeGpioInit 2FA66F37-8D93-4023-B6A2-BC5049ACCF0B,DellPasswordPolicySmmProtocol 2FB216ED-4A67-4833-9F5C-248124CD9AAC,DxeGpioPolicy 2FB92EFA-2EE0-4BAE-9EB6-7444125E1EF7,DellGset @@ -1952,26 +2183,32 @@ 2FF3EBE7-F9BB-4230-89E6-154D2B22656F,DiagnosticTestInterfaceDxe 2FFDAF4A-A9B5-4EF6-AA3B-A89611AAB284,DellSpiPartPromJet 300DE6C5-765C-4F89-BD6D-A623785ABC27,PchLibNull +30101AD1-A99E-4175-907F-7A8A561A8750,FjNvramMerge 301A0BC3-BA16-49F9-858B-DEE05F91E7B8,TpAcpiNvsInitDxe 301AF449-E0D7-43A3-8B1B-BC16725D374B,DxeDebugDispatchProtocolGuid 3020484F-4582-406E-B20F-89EACC93DC6A,DellSmmLegacyRegionProtocol 3022E512-B94A-4F12-806D-7EF1177899D8,PciHotPlug +3035F2C2-48EB-46BB-A599-B2338DD58867,AMIProjectPEI +304003EA-7A75-4776-83D4-6B784B6E1900,MemoryInfoSetupUtilityDxe 30461A00-DEEC-4EF1-B7B2-6CA9511B5982,AmiAgesaAcpi 30499E37-FC01-4DD6-8E07-2E3853DEBE60,AmdLegacyInterrupt 3054D6BF-E71D-4818-8E1F-17B012B58788,H19RecordLog 30572445-4C9B-4726-B080-D9AEA2B03DF1,PspPei 305DE41E-EA19-4D20-9A93-0E0DD42A3F67,Mec5107Pei 3065B008-5E9B-47A9-9FE0-001CDA3C5F68,CcgxFwUpdate +306C96E6-7613-44E9-A588-95609EBA01A1,BctBaseSmmBRH 3073D8AC-EFAB-4055-9B37-F62CD93A200A,IrqAllocatorDxe 3079818C-46D4-4A73-AEF3-E3E46CF1EEDB,EfiBootScriptExecutorVariableGuid 307D4A1D-DDD8-4E2F-AC68-D8B213C198FE,BiosAuditLogHandlerDxe 307F86DA-031F-4527-8EC4-2AE82DDFC086,OemAcpiDriver 30806658-1E9C-4A13-971E-707A69E958C8,Int15MicrocodeSmm 308DD02C-092B-4123-A2AF-3EF4440A6B4A,AmiResetTypeVariable +3090CDC2-5EFD-4FBE-B22D-584EBD3D08BA,TouchDriver 3095CD79-5B45-49DF-B27F-EF43843B8480,IrqBoardInfoSct 30965142-FC5A-4E6E-94DB-BBA441B36851,AmiPciOpromDataProtocol 309DE7F1-7F5E-4ACE-B49C-531BE5AA95EF,EfiGenericMemTestProtocolGuid 30A48939-C8F9-4018-BED7-9F9228F16781,BatteryHealthControlDxe +30A5E718-39CA-441C-BED3-F4A3A931458D,FchProm21SmmInit 30AC275E-BB30-4B84-A1CD-0AF1322C89C0,PeiSpeakerInterfacePpiGuid 30AD2B83-ADD0-414B-B11C-F93CC1D0B79B,AmiProcessTcgPpiRequestGuid 30ADD18D-E143-4329-A977-B49A659573AD,SpiAccessSmm @@ -1980,6 +2217,7 @@ 30B6EB8F-08A3-4E66-8279-D8681D127F59,LenovoTpmFwWufuDxe 30B7AA80-44B5-477E-8AC3-21493F5B9D43,FjClearRtcDayLight 30B851D3-90FA-4180-A702-97F4114F3076,FjGabiSettingsCoreAbstractionDxe +30CB00F8-2E45-4C18-BD3E-EE7AD3C02576,SECWDTPEI 30CC8A21-0476-4C80-B5C5-B26947E1891D,XhciDebugger 30CFE3E7-3DE1-4586-BE20-DEABA1B3B793,EfiPciEnumerationCompleteProtocolGuid 30D6ED39-28BD-4C0C-A799-6305A4FE8A6A,WatchDogTableDxe @@ -1999,14 +2237,17 @@ 3137130C-D0A7-467E-9E8F-513816F159D8,OpromUpdateDxeNeonCityEPRP 3138C825-83ED-064A-A62A-CD13674E3F89,AppleDhcp4 3138E8DC-B9A9-45BB-A5E8-6EBACD005E4C,TouchPadDriver +313C8DEC-DF8D-4502-92B5-1FF4883A55AE,FlashControllerNvsSmm 31401EE7-1600-437C-A11C-B1035D8E6070,PchAcpiTables 3141FD4D-EA02-4A70-9BCE-97EE837319AC,TrEEConfigDxe 314A7E73-EAF2-40F3-81B5-61FC83C468CF,EcdBoardId 314EE04C-1106-4DC6-ACBC-CF19C0DBC5CC,PlatformInitAdvancedPostMem 31519EC4-65F1-4790-B223-AA9330DD75FD,Secure96Dxe 3152BCA5-EADE-433D-862E-C01CDC291F44,EfiRngProtocolGuid +31609F3D-4C94-4FF0-B7E4-5B6CA2302DB3,GlobalAcpiNvs 316190C1-5E48-4C15-AC72-37532F3A1EC1,SystemUsbDatabaseSmm 316190D1-5E48-4C15-AC72-37532F3A1EC1,LenovoSystemUsbDatabaseSmm +316A13C6-B0CA-4CC9-8599-5415BADF1923,AaeonUartOverridePrs 316AFD2F-8F25-4642-B0CC-411F67FC0C47,AaeonPowerModePei 316B1230-0500-4592-8C09-EABA0FB6B078,SmmPcieSataController 316B1230-0500-4592-8C09-EABA0FB6B07F,SmmHddSecurity @@ -2017,11 +2258,15 @@ 317BC006-9056-42C8-A1C1-92A1AABBC9EE,AmdCcxZenZpSmm 317CCC63-FDE4-48CE-BA03-D08CD45567CC,AtaDeviceDriverPei 31878C87-0B75-11D5-9A4F-0090273FC14D,EfiSimplePointerProtocolGuid +3188D183-D154-4DC3-8EC6-59804A623CCD,PCA9535Pei 319CE8BB-DA2E-4FF2-B69B-0A854146B489,SystemUsbHidParserDxe +319D0E01-0F72-4BFA-91D8-EBA049C5582F,Npce285xFlashSmm 31A0B6EF-A400-4419-8327-0FB134AA59E7,Mxm30Nbci 31A4878F-230D-4FC2-90BB-DA5F41A44B1B,DxeDebugportExtProtocolGuid 31A6406A-6BDF-4E46-B2A2-EBAA89C40920,EfiHiiImageProtocolGuid 31A8CB18-5C76-4668-839D-9FE804B419BB,CrbLastFfsPei +31A913BC-795F-4522-A28F-82A18CFB816A,SndwInitDxe +31AD0D89-75B3-4CF3-A1C2-877394EDC601,AmdNbioIOMMURPLPei 31AD1E44-9D60-4B15-B60E-8E70BE156323,UpekFingerPrintDevice 31C8F5D2-B558-41BE-9971-30ED8CB990C6,FjGabiFlashCommon10GbeRegionCtrlSmm 31CA5D1A-D511-4931-B782-AE6B2B178CD7,EfiIfrFrameworkGuid @@ -2057,6 +2302,7 @@ 32898322-2DA1-474A-BAAA-F3F7CF569470,HardwareInterrupt2Protocol 328A35E4-F0C5-4456-A4E4-936EFDE8CEF6,AmiI2cMasterBinrary 3291E91D-C5D9-42B7-B3B1-8EC54B03F043,OemPeiSample +3297DA1A-161B-4D35-BCAC-D1597B6BDC01,CbsBasePeiPHX 329F126F-299E-4BC5-8310-179F10EB46C9,DellSmbProtocolAccess 32B8AB1B-07E3-4B42-8EE7-02902A293BCC,AmdFchWheaDxe 32C1C9F8-D53F-41C8-94D0-F6739F231011,BiosExtensionLoader @@ -2065,6 +2311,7 @@ 32CBA21F-F308-4CBC-9AB5-F5A3699F044A,EfiUserCredentialClassFingerprintGuid 32D2963A-FE5D-4F30-B633-6E5DC55803CC,EfiUsbFunctionIoProtocolGuid 32D4B2DD-1DB3-4AF9-91B0-FBAE6E6EA259,RtkUndiDxe +32D4B2DD-1DB3-4AF9-91B0-FBAE6E6EA25A,RtkUndiDxe 32D9116A-AF15-4976-908C-2C6E05CB789A,AmiMultiPlatformProtocol 32EA828B-523B-44CB-B7A4-7E0A2A49956C,FmacDriver 32EE5672-C9F9-4926-8228-0C4E3B0E69FE,AsusTopSwap @@ -2073,11 +2320,13 @@ 32FF59CD-0C33-48D0-A244-4BB811336403,EslUdp6ServiceGuid 32FF9F5C-56B4-4149-81A8-E748645E9551,HpSioSecuritySmm 330183C4-F848-4C88-AE5A-2248F91DF773,DellExtendedBatteryLifeSmm +3305B3F7-0ACF-49E9-9124-341760F467EB,AmdNbioBaseRplDxe 33065910-FE56-49AB-B03D-ED1AFF65B596,DeviceImageInterface 3307DD15-23BA-4546-A004-FCBCC47D4A49,SiliconPolicyPeiPreMem 330AA623-79E7-467C-81AA-DE9EE0F96A52,SmmThunk 330BE755-FBED-4F18-B9A8-495856D3D7A1,EfiCpuHotAddDataProtocol 330D4706-F2A0-4E4F-A369-B66FA8D54385,EfiHiiConfigAccessProtocolGuid +330E57C8-4E71-493F-91B9-0F7F820A1DA3,BatteryFwUpdateDxe 3316A5D0-FE16-40E2-8114-75E5724449F8,IntelLANDxe 33195652-2C4F-4B55-B6CB-63D3C38598D3,PchHsUartDxe 331BE2A7-BD90-4A81-A128-36B0B2057997,EfiPlatformTypeBuchananPassProtocol @@ -2089,6 +2338,7 @@ 332CCFED-E5E7-49AB-820D-E34A54ED3F57,DellSmmMfgModeProtocol 333BB2A3-4F20-4C8B-AC38-0672D74315F8,AcpiPlatformPei 333BB2A3-4F20-4CCC-AC38-0672D7412345,FastBootPei +333F3A12-11DE-4014-9E53-0E15878C7268,AmdI2cTouchPadDxe 334D5254-6160-4E4A-A78C-E15D3B3B3334,MmcHost 3358F97F-63BE-47A8-89BB-ED63612E6C9F,LinUptpPure 335984BD-E805-409A-B8F8-D27ECE5FF7A6,EfiStatusCodeSpecificDataGuid @@ -2100,6 +2350,7 @@ 3364E8EE-91B8-4428-9FBC-1E9C5DCA398D,DellMemorySlotInfo 336CDDEA-AB28-4C4C-9F64-5FE0391FEBB8,DellAudioConfigPei 3370A4BD-8C23-4565-A2A2-065FEEDE6080,SecSMIFlash +3374B583-7A96-496E-9B8C-2BEFE911ADB7,AaeonUartOverride 337F4407-5AEE-4B83-B2A7-4EADCA3088CD,EfiHiiUserCredentialFormsetGuid 3381FC3F-8791-41E5-8871-A960A4ED24B7,MemoryInit 338695EA-CA84-4FA2-9DA8-5C4BB87905C6,XenioFdtDxe @@ -2110,6 +2361,7 @@ 339EC458-9B6A-4CEC-A47A-712873653299,StdFlashLibNull 33AE969B-E7CA-4BCD-9C4D-4531C18A5DFA,TouchDriver 33BA5130-2255-4802-9019-C875D5D66E77,OpalBlockSidWmi +33C27A86-0A39-48DA-9424-6813E5C3928D,CompalEcAutoFlash 33C27A86-0A39-48DA-9424-6813E5C3939D,A31CMFCDxe 33C27B86-0A39-48DA-9497-68A3E5C3928D,CompalPlatformHookDxe 33C6406D-2F6B-41B5-8705-52BAFB633C09,AlertStandardFormatDxe @@ -2119,6 +2371,7 @@ 33CDC56C-B1EF-4B21-87E4-225F42C67F4A,SystemProgressIndicator 33D33BF3-349E-4768-9459-836A9F7558FB,DxeIoLibCpuIo2 33D6ABF9-6CFB-4FFE-9E68-6FC63FE60252,AmdPspIntrusionDetectionDxe +33D87F26-E58C-983F-F14C-A5FE58B10B64,AmdMemSmbiosV2PhxLpd5Pei 33F12300-FBF2-45E6-B6B7-79AF6029C7D4,CmosButtonLoadDefaultsPei 33FB3535-F15E-4C17-B303-5EB94595ECB6,SmmLockBox 340436B0-EBFA-408A-9B8B-565B1F77CF2C,Lpc47N20x @@ -2129,15 +2382,18 @@ 343FF38A-32E2-48B3-910F-37E7FE9EF72E,MeCapsuleDxe 3458636B-9A94-44E7-BCA9-F8DFA1F5D894,LenovoSecureWipeLoader 345ECC0E-0CB6-4B75-BB57-1B129C47333E,EfiPlatformToDriverConfigurationClpGuid +346ACA3D-86AF-444E-BCB8-C56E6538BDE3,AmdCpmLpcUartPeim 346B093A-9002-4E99-A2F2-27A16C3DCD89,OemModifyOpRegion 3470CCF0-6054-11DD-AD8B-0800200C9A66,EzFlash 347B85F0-E917-4E74-85BA-F494071EEE52,FchSHSataD3ColdSmm 347CBF13-9C36-4E36-91F9-5BC76E5042D1,MacAddressPassThrough 347CC502-EB6C-44A0-9498-605888C94E0D,HandleStatusInSMM +34891F9C-54DA-44EA-8313-CAB8AAB1BD0C,FchProm21SsdtDxe 348C4D62-BFBD-4882-9ECE-C80BB1C4783B,HiiDatabase 348CA223-637B-4430-BAF3-1CE5D322B3FD,SetupBoot 3496A19A-2E99-41BA-833E-0FDE2EBF2A55,AmiFastBootProtocol 34989D8E-930A-4A95-AB04-2E6CFDFF6631,TcgPei +349BABBE-7159-4E58-9462-0EEFD8EAFB86,SocCrashLogAgent 349CF818-C0BA-4C43-929A-C8A1B1B3D255,InternalTpm2DeviceInterfaceGuid 34A66FCF-8F26-4F93-81E3-918F5F717DE3,FjS5WakePei 34B78650-B0BA-428F-87B1-A1AC762F7FBF,EfiHeciRuntimeProtocolGuid @@ -2145,12 +2401,14 @@ 34C8C28F-B61C-45A2-8F2E-89E46BECC63B,PeiVariable 34CC6167-7AE7-403E-8AB2-23837F398A30,PlatformInfo 34D51EB9-76DB-4CAF-94AE-934856E895F6,LenovoAtpDxe +34D8C727-FA83-4FDE-BF51-02426E4533DB,FjGpnvPei +34DF9766-19C0-44BD-BA4F-D2006A0C3DA5,CbsSetupSmmRPL 34E5798E-F44F-4526-A08C-39BCA6E8D7D5,EarlyProgramGpioPei 34E74B1B-8794-4402-AA43-99B5249B1CFD,DellSbSmm 34EB9E3F-9318-4CE7-99AD-9E7289038C52,WifiBootDevAuthList 34ECEADC-9229-44D1-85B1-B84071A13187,MebxDisplay 34F60DB9-D3E4-428B-B770-3541C8E05112,SgxConfig -34F85EE2-93C2-4481-B710-D3490CCA6333,ACPIRAMSMM +34F85EE2-93C2-4481-B710-D3490CCA6333,AsusAcpiRamSmm 34FB0259-BD92-41CF-811B-17C9AD60518A,RemoteWakeUpPei 34FB5A1B-E3CD-4893-9403-0A39BA62FDA0,SvSmmSupport 35034CE2-A6E5-4FB4-BABE-A0156E9B2549,PlatDriOverrideDxe @@ -2161,14 +2419,18 @@ 35269008-CF21-4A7C-A58C-5CBF2BDE4AA6,EmulatedEepromSmm 352C6AF8-315B-4BD6-B04F-31D4ED1EBE57,CbSupportPeim 35302F55-51C3-40DE-B68F-1EF144CCF1E8,LegacyUsbDxe +3538C287-F7D0-4C2A-BE3C-2D7E27A57A3F,BmcThermalPei +3542FFD8-ABDE-45ED-9847-0719EDA139DD,AsusAmdCpustringDxe 3543EC9D-4B27-4FA9-ADBD-1DE118078FA7,AmdSb900Pei 3543EC9D-4B27-4FA9-ADBD-1DF118078FA7,AmdSb800_PeiPei 3548423A-2B2C-4393-9826-B202959D2362,AbtCryptoDriver 35574ED4-E011-4F40-9FEC-6941C39CB549,OemPDFWUpdateFlagClean 355FBDA9-4572-49BC-95B9-545E71DEF9F9,FpgaSmm +3561188E-D848-4406-8F11-267097132BD5,FjLvdsRTD213xR_Dxe 35628CFC-3CFF-444F-99C1-D5F06A069914,EfiDevicePathPropertyDatabase 356471B1-B483-42AE-B6E7-3B2EBAB14E15,ServerCommonTokenSpace 356C2B12-3124-4451-BF66-B502D88A0074,XhciDxe +3578F929-7184-4275-B941-AAA906C8854F,WlanSuplct 357970A0-FF5D-4C36-AF68-0A29A46FF2D5,OemAfterMemDxe 35868FB1-4E8F-4C4E-93B4-F229CD89A927,PxeDriverRt 358E9F0F-DDC0-42D1-957B-DBF11497ECD8,EcCommunication @@ -2249,12 +2511,15 @@ 3749AC96-24B8-44E2-B895-4FABEC4CF40F,ErrorLogWmi 374CEED1-AD67-40C0-B2C9-3DBCC5A5D30A,PwByPassSmm 374DE830-81C5-4CC8-B2AB-28F0AB73710B,SmmCpuFeaturesLibStm +3750F0F4-480B-4FCD-A153-62A4BEB5D114,CrashLogPei 37542F9C-24E8-4834-8B1D-7C3E0645245D,EcMpmSmm 375EA976-3CCD-4E74-A845-26B9B324B13C,EfiUxixSystemConfig +3770BCE9-F09D-4446-9533-7948414F6CC0,FjGpioGHOPei 377766A3-A6D6-444B-B98F-012694C28653,SerialPortTypePei 377C66A3-8FE7-4EE8-85B8-F1A282569E3B,EfiPlatformIdeInitProtocolGuid 377C79B2-1A40-441E-B6F5-A170E3753725,LenovoTpmMeasureDxe 3780B594-32A4-4593-B8CE-8A3F404F61F4,PlatformToDriver +37813270-948F-4096-A2D8-98D321381F0C,PasswordInterfaceCoreDxe 378D7B65-8DA9-4773-B6E4-A47826A833E1,PcRtc 378D7B65-8DA9-4773-B6E4-A47826A833E2,PcRtcSmm 378DAEDC-F06B-4446-8314-40AB933C87A3,EfiMmCommunication2Protocol @@ -2269,6 +2534,7 @@ 37AED342-1F52-44A3-8DBA-EF2BDDF471D5,GabiSettingAbstractionSmm 37AFCF55-2E8C-4722-B950-B48B9165C56B,LenovoSetupMainDxe 37B1100E-4C66-9B44-D736-9BBBF169CE2F,xGbEI2cMasterDxe +37B30BC4-873C-4541-8B65-DEA370B674DD,WMISwSmiShp 37CAA14D-5072-4753-ACB2-CADA3E99A9E7,KeyBoardIdm 37D3E8E0-8858-4B84-A106-244BB8CBFDC3,LenovoLoggingVariable 37D43B2A-43A0-4AEA-AB79-E4FEF53C0F12,MicroCodepointerGuid @@ -2277,6 +2543,7 @@ 37DDC7E9-7C1D-4E1B-B2CB-4ED5D12527B3,LenovoMePciUpdate 37EB4355-1FC5-42E6-9039-D575D5051C2C,HpFlashMeDxe 37ECDF24-8453-476A-AB58-F4CF8BFE6742,LenovoPhxGopDxe +380D2287-A41F-4702-98DF-EF8857A5CDDE,PepOvrDxe 3812723D-7E48-4E29-BC27-F5A39AC94EF1,ItkDataVarGuid 38133149-14F1-4179-B187-EFE7D3F7479D,FjGabiFlashCommonMeRegionCtrlSmm 381CE2A5-C603-48D2-9515-9B4141F4FDE7,AbtDebugDriver @@ -2299,6 +2566,7 @@ 38802700-868A-4B4E-81D4-4F1BDCCFB46F,EfiExtendedSalSst 388278D3-7B85-42F0-ABA9-FB4BFD69F5AB,EfiBluetoothIoServiceBindingProtocolGuid 3885474D-8395-4AAB-8AA4-3743CE287646,FnWinKeySwap +38857C30-D9B8-4CBE-82C0-F9D8020CE5E3,PostCodePei 38871BF0-C64A-4896-B8E4-62D4850C7E68,DellOemSxSmm 38871BF0-C64A-4896-B8E4-62D7750C7D68,DellAcLossSmm 389244DB-3D6E-4E50-835D-5A775A325D89,LenovoMx25L64XflashPartDxe @@ -2313,16 +2581,21 @@ 38CDD10B-767D-4F6E-A744-67EE1DFE2FA5,PeiTxtMemoryUnlockedPpi 38D51B46-D275-475C-A951-80A7E1CF38B1,AmdCpmSensorFusionDxe 38D65EC3-8F39-4660-B8A6-F36AA3925475,AmiBdsConnectPolicyProtocolGuid +38DCB38F-D51E-11E3-9129-047D7B99E097,ProjectServiceSmm 38DDFE8F-8991-44AA-9889-83F4918465B0,EfiGpioOperationProtocolGuid 38E7E3DB-1211-4EFB-8709-9E41AB2810D1,FjHiddenAdminPage +38E8BEF9-E526-492B-990A-517428B37D06,FmpDxe 38E93FAE-C5F4-4700-940D-DC10E2FDB6C0,OemPeiRuntime 38ED731E-6A1B-441B-BF97-A7854C4A2B7F,EgsFhfPolicyOverridePei 38EF2B8B-CF3D-47E2-97E3-557115E43985,DellDiagsSbControlDxe +38F80EEE-FFA3-417B-ABF1-F713399007E8,WufuDxe +38FAB09C-2851-444C-9A43-F82725E4671F,AcpiDsdtDynamicCpu 39045756-FCA3-49BD-8DAE-C7BAE8389AFF,Tcg2Dxe 390712E4-0EDC-447D-9492-3FBC996DD044,H19CapsuleSystemFirmware 390C4486-C026-4083-8869-D8F260A49760,OemSyncSetupRN 390D8CDC-F738-46D9-82E4-BB0DCEEE3F9D,UsbBusSmm 390F84B3-221C-4D9E-B506-6DB9423E0A7E,ShellHttpHii +3911946A-7B2F-43AE-86BE-8EC5A8A356CD,AmdPspPeiV2Brh 39136FC7-1A11-49DE-BF35-0E78DDB524FC,EfiLegacySpiControllerProtocolGuid 3915886B-D833-4C23-B3ED-1453CCE7C5F2,IioCfgUpdateDxeLightningRidgeEXECB2 391626DB-3CEC-4339-A3D6-9CDFF4690E12,PrepareWhiteListSmm @@ -2331,9 +2604,12 @@ 3922DFF9-C892-45EB-A4CC-4F4EA2FCF05B,AicCcgFwUpdate 3924C33A-125E-40A8-8450-38C6671E021D,AmdNbioPei 392744DA-DF68-4C3B-966B-F20F0F47BC23,acer_SetupUtility_interface +392D4DAE-D3BD-4CAF-B1EF-57A78B6E39BC,NVMeInfoDxe 392DE324-E962-4A7A-B62D-10414AF6B9C8,HousingMonitoringDxe 39342586-4E0E-4833-B4BA-1256B0FFB471,FmpDxe 3935B0A1-A182-4887-BC56-675528E78877,SetupUtilityApp +395B0181-C9B9-4E2E-A82E-6B0D027119F9,AmdCcxZen5Smm +395BAA99-E4FC-4821-ACC3-B56E5246E066,RestoreCbsDxe 395C33FE-287F-413E-A055-8088C0E1D43E,SmmRsTableGuid 3961B4D9-1385-43F7-B9C8-6C3A389FBF99,MobileDiag 3962DEB5-FDF6-4829-889C-D544918E84D9,SmmLegacyRegion @@ -2358,9 +2634,12 @@ 39C28A86-9097-48DA-B424-6C13E3D391FA,CompalEcDxe 39C28A86-9197-481A-B424-6C13E3D391FA,CompalEcSmm 39C2AE2A-33AC-32EA-3CA5-9B12EA564540,AcerToolsProcess +39C64B04-91AB-4D4A-B343-077A565B6089,FjInternalUsbConfig 39C7942C-C272-4912-9FE4-57F695CF5442,AmtBoot 39C8FAEE-FBEE-41A3-9282-123F18C48CD9,BroadwaterMemoryInitPei 39D1EDC0-C9ED-4663-90DB-7457FF0548C5,AmiErrorHandlerMain +39DE9293-5BD9-4728-827E-1242F3F9BE3A,HpAmdTbtDxe +39E35910-CA97-4851-811B-303822DA9036,AmdMemFp11StxhDxe 39E4761D-FF39-4603-B7A6-B5A5CEE1C9F2,Lily_RTLWlanDxe 39E8CA1A-7A69-4A73-834A-D06381933286,UsbPei 39E8CDA1-6A35-4CDD-A902-D1A795F70380,AmiResetTypeHob @@ -2370,9 +2649,11 @@ 3A05D1CE-E283-4738-88C9-D152F335C0DC,MSIFreeDOS 3A09E64D-08A9-42D5-8234-1127E6AF05EB,SioPowerButtonOverrideSmm 3A18A5AF-F25B-42EE-8606-8D30A974916B,PasswordEncodeSmmProtocol +3A19FBFF-AB92-4004-AD2E-F769F53AAE63,ApobRplPei 3A29DD19-2C84-4A70-9A01-FBDDAFFB6461,DellMemoryS4 3A2A83F2-98AC-4A8B-BBBC-DDDCC655A0D6,FchShastaDxe 3A2AEC67-77B8-40AE-9281-03519C9E7F08,LenovoAoacSmm +3A2B9049-C351-4556-99B0-8B0A9BE9981A,PlatformDiskDxe 3A3300AB-C929-487D-AB34-159BC13562C0,PchResetCallbackProtocolGuid 3A35EE58-8286-4F00-9A5B-1B6AB7680815,amiFVhoblistguid 3A3817E2-FB69-4FBC-834D-AEE6A9B14133,AmdCpmFwMessageInfoPei @@ -2384,7 +2665,9 @@ 3A61FD45-69A0-42AD-B261-24DA451BF442,ForceRecovery 3A666558-43E3-4D25-9169-DB81F5DB42E1,PKeyFileX509Guid 3A6A1473-13E0-4795-BA9F-22891277D74D,HdpEraseUnitAppDxe +3A7AA63A-88B9-410B-80C0-C97F146B6DF8,FjUtilSmm 3A829D04-3962-42DF-9137-B1D354AEA4AB,OemDxeGetBoardData +3A84B1D8-77B9-4786-8C06-C97009DCD5C1,AmdLegacyInterrupt 3A885AAE-3E30-42B9-A976-2F1F13BD7015,SecurityPkgList 3A95AD68-D735-418A-AF10-5AE516555994,AaeonLanByPassSmi 3AA7FD11-CC5F-11EC-95E0-E02BE9424581,DellLegacyBeep @@ -2395,6 +2678,7 @@ 3AB85907-33CD-4D6C-93A5-9BE7E579BF95,FjNetworkServices 3AC66273-9F97-41B7-9AAD-5D781DA0B8A7,DellVideoDxe 3AC97E05-F217-4EBD-B134-8FDA26E85769,DebugDxe +3AC9D717-A920-4BB2-8EC8-F235094C7E50,CpuInfoSetupUtilityDxe 3ACC966D-8E33-45C6-B4FE-62724BCD15A9,AhciBusDxe 3ACEB0C0-3C72-11E4-9A56-74D435052646,TlsDxe 3ACF33EE-D892-40F4-A2FC-3854D2E1323D,EfiPeiCapsulePpiGuid @@ -2414,6 +2698,7 @@ 3B1DEAB5-C75D-442E-9238-8E2FFB62B0BB,UefiPxe4BcDxe 3B1E4B7C-09D8-944F-A408-1309EB8B4427,EmuThreadThunkProtocolGuid 3B24F79D-91A0-46FF-BE29-458AE211FAC5,KbcEmul +3B286D06-DED4-441C-B4E4-444B50AA73BD,WifiBtDxe 3B2E5712-7F64-4E6C-9D18-63A6867CC744,AmdSocFp7r2RmbPei 3B37B724-4AF7-4A35-97B3-D2FB8F4F563C,DellStopShipConfig 3B387BFD-7ABC-4CF2-A0CA-B6A16C1B1B25,EdkiiFpdtExtendedFirmwarePerformance @@ -2422,6 +2707,8 @@ 3B3EE27E-9BEF-463F-B03A-A5C9A098B7B5,CpuOverclockingConfigGuid 3B42EF57-16D3-44CB-8632-9FDB06B41451,MemoryInit 3B43161F-AEB4-43EC-9E1B-8050171B4899,BiosGuardRecoveryHook +3B4514C2-D098-404C-B1DC-D71AEACA4E96,AmdMemoryHobInfoPeimShp +3B462A2C-C75E-43C5-AC4F-D4AF0D5E002E,AmdFabricStxKrkPei 3B4D59EC-DFD9-4EC6-BB8A-E0FE2B4264A0,PciDxeInit 3B4D9B23-95AC-44F6-9FCD-0E9594586C72,BdsLibStringPackageGuid 3B6686BD-0D76-4030-B70E-B5519E2FC5A0,EfiCapsuleGuid @@ -2433,6 +2720,7 @@ 3B897E94-4864-416B-8353-9479325497AC,OemDxe 3B8C8162-188C-46A4-AEC9-BE43F1D65697,EfiFwDisplayCapsuleGuid 3B95AA31-3793-434B-8667-C8070892E05E,EfiIp4ConfigProtocolGuid +3B9AEC47-FC79-4CA1-8F53-CFBA75DAA6FB,SchenkerSetupPei 3BA7E14B-176D-4B2A-948A-C86FB001943C,EfiErrorHandlingProtocol 3BB37EC4-82E8-4C84-AAA5-1E0BCFCDA6FD,DellFmpFtb 3BBCB209-26C8-4BA9-AD25-B95B45A04D26,BatteryState3 @@ -2443,16 +2731,19 @@ 3BC1F6DE-693E-4547-A300-21823CA420B2,PeiUsbControllerPpiGuid 3BC2BD12-AD2E-11D5-87DD-00062945C3B9,CpuStatusCodeDataTypeExceptionHandlerGuid 3BC42C6D-ABEC-41BA-8CCB-D8E0EF1CEF85,PCHPolicy +3BCA86E6-FFDD-47F8-9E76-0D7E1706F6CD,ModernPreloadDxe 3BCE2765-74D9-4FE2-9FEE-E579C06F736B,UsbOcUpdateDxeSierra 3BD2A492-96C0-4079-B420-FCF98EF103ED,EfiCertX509Sha256Guid 3BD2ED18-9D72-4208-9D8A-4BE274E6ED69,CapsuleUpdateApp 3BD2F4EC-E524-46E4-A9D8-510117425562,EfiHiiStandardFormGuid 3BD61419-4BB8-4921-92C8-BA84A7A3591F,ResetDateTimeDxe 3BD930FD-F823-4948-8691-98E6FE36ACE2,EfiDebugMaskPpi +3BEB5ABD-5BE5-40B7-B9D8-4026E3D6D6AE,FjUtil 3BEB6B06-09CE-4386-8884-F323ADD04F1F,GlobeTile 3BF4AF16-AB7C-4B43-898D-AB26AC5DDC6C,SecSMIFlash 3BF66866-3F8B-4CD8-B74C-B994111F535F,FfsIntegrityCheckDxe 3BFFECFD-D75F-4975-B888-3902BD69002B,MeGlobalNvsAreaProtocol +3C094B02-9797-495E-8CA8-940371396A08,FjS3SaveMem 3C0D6860-7396-488A-BF52-2D8647D35B28,MeOptionsSmm 3C0ED5E2-91EA-4B94-820D-9DAF9A3BB4A2,DmarAcpiTable 3C0F72B5-D51E-40C8-90F1-5A923E0D1F24,TpmResiliencyDxe @@ -2480,6 +2771,7 @@ 3C7200E9-005F-4EA4-87DE-A3DFAC8A27C3,EfiShellDynamicCommandProtocolGuid 3C7BC880-41F8-4869-AEFC-870A3ED28299,EfiHeciProtocolGuid 3C7D193C-682C-4C14-A68F-552DEA4F437E,PcdDataBaseSignatureGuid +3C80727F-6846-41BC-8E54-0107C10ACDF0,FchI3cHciDxe 3C887050-42C8-4958-A08E-495D910CF515,InstallSdevDxe 3C8B9970-870A-11E4-B7C6-B8E8562CBAFA,ChipsetGpioDxe 3C8D294C-5FC3-4451-BB31-C4C032295E6C,IdleLoopEventGuid @@ -2492,6 +2784,7 @@ 3CA59AB6-67CB-4385-9EDD-407C49F0D9BC,OemBootOsb 3CA6DB44-8614-4DCA-8B95-A35EFD51779E,DxeCheckCMOSHealth 3CC02D82-D40F-4897-96EF-2F35B3AAA096,I2cMaster +3CCC52E4-56D8-4AFA-A9CD-0E8E2D81488F,AsusSsidUpdate 3CCD3DD8-8D45-4FED-962D-2B38CD82B3C4,UserIdentifyManagerGuid 3CD405CE-2D91-44E9-895D-4459EECD8F9A,AmdRasRvApeiDxe 3CD652B4-6D33-4DCE-89DB-83DF9766FCCA,EfiVectorHandoffInfoPpiGuid @@ -2499,22 +2792,26 @@ 3CE1E631-7008-477C-ADA7-5DCFC7C1494B,EdkiiPeiFirmwareVolumeInfoPrehashedFvPpi 3CEC37DF-90AD-4D88-AFF4-093056A6807D,SystemSecureFlashSleepTrapSmmDxe 3CEF354A-3B7A-4519-AD70-72A134698311,Ebl +3CF15020-4DB3-4769-9D37-913A3489FE7D,BindProtDbgDxe 3D0E663A-DC72-4489-87C5-E49EE773A452,IffsPpi 3D154670-6015-4425-B9C5-8035E34BE6FD,NvmExpressPei 3D17205B-4C49-47E2-8157-864CD3D80DBD,FatPei 3D18BA13-D9B1-4DD4-B916-D30796539ED8,EdkiiUfsHcPlatformProtocol 3D18D024-EA2F-4EDD-9FE3-672A37DB802D,OsTransparentUpdate +3D2AD454-BD5A-4F2F-A68E-185000CD2045,CmosInterfaceCoreSmm 3D2DBA75-5EBC-4EEA-A487-06AD9E1CACB3,DellI2cPlatformDxe 3D2F8940-A850-4543-B294-9B0BD0E750C7,HstiDxe 3D3CA290-B9A5-11E3-B75D-B8AC6F7D65E6,XenBusProtocolGuid 3D411389-F606-485E-B7BB-CB6EAB4672CD,FjBIOSMasterPasswordBin 3D417445-1F37-46D8-BC1F-D07014344974,AhciPciHcPei +3D49F3EA-AD1B-4866-8459-E5B58CA410D3,AmdMemMcsrUserPreferenceDxe 3D51D4DA-DE98-49A1-9442-9D81E0FBB6C2,WakeEventPei 3D532050-5CDA-4FD0-879E-0F7F630D5AFB,BrotliCustomDecompress 3D5674D0-AE75-4723-9159-1D653B40402F,DellTxTdxe 3D5ABD30-4175-87CE-6D64-D2ADE523C4BB,EfiVirtualCdGuid 3D61A466-AB40-409A-A698-F362D464B38F,EfiEventNotificationTypeBootGuid 3D64F384-CA32-42C6-A629-42A494B2CB4A,TpmCapsuleDxe +3D68B132-2652-47FD-B2E9-B417122B5A6D,DellCommonBoardInitSmm 3D6CDB0A-5B1F-43A3-A43B-441267F9DAB5,AmiSmbiosCpuInfoProtocol 3D7CD868-072E-4A7E-9C83-1DCE7C0DB0AC,DG_GOP 3D7F7739-A084-4FA9-9A83-6B4B0E2CD638,SATADxeConfiguration @@ -2523,7 +2820,9 @@ 3D92FF43-193F-46BE-B0E1-B820124BF6D9,FjGabiNvramAbstractionSmm 3D989471-CFAC-46B7-9B1C-08430109402D,TxtOneTouch 3D9FC54D-19E5-4AD0-B986-02D687D760E5,ASRLOGODXE +3DA02C3C-62E5-438B-B0DB-9E5128379661,EarlyDxeDevices 3DA97FDE-2261-4CFB-A171-74CD5A9AE279,SaveSpdToRomDxe +3DAB18DE-976C-40B9-972B-6CFD196E0C92,UsbViewerDxe 3DACF484-53DC-4BD6-84C9-AA17BCF2FFDC,PowerFailureRecoveryPei 3DACF585-53DC-4BD6-84C9-BB37BCF2FA23,SerialPortSettingPei 3DB287DE-F551-4DD1-AC5F-050FE6C10A6C,Smsc5028PeiInit @@ -2539,6 +2838,8 @@ 3DDE54E9-8D18-4EA8-9423-C2E846E18E23,DellSmBiosStrucD3 3DE30DC2-D84E-48EA-8E38-A9C17D743F10,TimerSMISmm 3DE852F6-34BF-4345-FFFF-FFFFCCE3A3EE,BootFailedDxe +3DEC6443-30AA-44FD-979E-84B91D3C1412,SbSocPhoenixPei +3DEC6443-30AA-44FD-979E-84B91D3CEEFD,SbSocRaphaelPei 3DF2AECB-7489-4D91-9BEA-9B135A564670,BdsCheckPointHandler 3DFC255F-9C86-48BC-972D-E522533768DB,LenovoRebootCp 3DFE0FAB-70C7-4B53-9855-985F14DB2DDA,RawIp4Tx @@ -2554,17 +2855,23 @@ 3E405418-0D8C-4F1A-B055-BEF90841468D,TcoWdtHob 3E44AD09-D88B-4C52-B41B-B8C00536474A,LenovoSystemCryptSvcRt 3E4817FD-2742-4351-B59F-91493280329C,AlertStandardFormatPeim +3E5281CC-3A12-4ED7-831E-623D7A18D98A,AmdSocSp6StpPei +3E544221-56DE-432E-BBC8-46FACF14FE77,AmdBiosFlashDxe 3E5756E0-6709-4313-8B5A-31534A6542B8,OnboardTPMPei 3E58A128-55C8-4164-FFFF-FFFF38A05639,XnotePlatformPolicyRtDxe 3E591C00-9E4A-11DF-9244-0002A5D5C51B,EfiMmcHostProtocolGuid +3E5EF8CB-915D-4FDA-92DD-71042E0B7A01,PowerProfile 3E625104-1920-44B1-AE2C-1BDA57ED73EA,KtiRas 3E710061-647A-4C03-BE85-FAD6CCFA5A18,PcPassword 3E745226-9818-45B6-A2AC-D7CD0E8BA2BC,EfiUsb2HcProtocolGuid 3E74BFBF-893D-4097-B263-96DEE7EE2CFB,SetupStatusSmm +3E7598EE-FD81-46C9-9798-C2FD1A73E839,AIMTSmm 3E7788CA-2BFC-4FCE-8122-5176CA492D9F,CbsSetupDxeRV 3E7D2B56-3F47-42AA-8F6B-22F519818DAB,ScPcieSmiDispatchProtocolGuid 3E7DD42F-A67E-4D4F-BC02-2B5A6EC8DAE9,SetupVariablePei 3E91A5E2-26A1-4AE2-854B-08C39BAA0BC6,DellSdCardNotifyDxe +3E9A7EC8-EB9B-47AC-B78E-F1A4C3FC78EA,CbsBaseDxeSHP +3E9F711D-3496-46EE-9DA5-46DFBC1D686F,PlatformFlashPartSmm 3E9FF4C8-A355-4063-A487-610360C0ACCE,ThirdPartyNvme 3EA824D1-81E3-4FF5-BD43-BB9C65DF7C46,AmiCsmStartedProtocolGuid 3EAF5E3A-E4B2-48E6-A9F1-B75CF204BCC8,PeiBoardConfigInit @@ -2586,6 +2893,7 @@ 3F2BCF3A-7876-475B-B97D-EFAE8BEF75FC,AmdNbioGfxRNPei 3F31B066-82A2-4B2A-A6CE-AB0F7DD0066A,NVDimmMgmt 3F4592F4-D5DE-4C29-883E-63434BBE0B33,Cf9Reset +3F4CDD2B-A713-4443-A253-7EB22B71730E,BctBaseSmmRPL 3F557189-8DAE-45AE-A0B3-2B99CA7AA7A0,EfiFtwLiteProtocol 3F5A74B2-BF80-4850-8591-4F2DF5F9CB2B,PhoenixGdiProtocolGuid 3F626A59-87D2-4FCF-B5DE-9D12A8B2AF88,FeatureByte @@ -2593,8 +2901,10 @@ 3F7753EF-D36F-45CC-8A1A-2EAAFF1038B6,PciPlatform 3F7753EF-D36F-45CC-8A1A-2EAAFF1038B7,BootMediaInfo 3F78CB8D-72EE-414E-B023-DACA003BDDF5,ProjectSxSMI -3F78CB8D-72EE-414E-B023-DACA003EFCDE,APM +3F78CB8D-72EE-414E-B023-DACA003EFCDE,AsusApmSmi 3F7E615B-0D45-4F80-88DC-26B234958560,FitDiagnosticsLoader +3F7F265B-29CE-4A54-8751-8A9E90719831,FjEdpDisplay +3F837872-2A07-4470-B8B7-9AC131360314,VariableEditDxe 3F8DC333-CCD5-4E58-B8CF-7B9A8F31EA96,AmiTseOemPortingVar29 3F949D9F-CC66-479A-9AD3-F6C1C3FF4378,AmiSgxDxe 3F9615F9-1DD3-4185-920D-8D0D5B23D36C,fTPMInit @@ -2605,9 +2915,11 @@ 3FA4F847-D8EB-4DF4-BD49-103A0A847BBC,EfiKmsFormatMdc4128Guid 3FB208AC-2185-498C-BF46-DC23DA587B55,EmuRedfishService 3FB856A5-C8B0-4760-B49A-2EDD4FA35BFA,LenovoIbexPeakGlobalSmiControl +3FB90C4A-985E-46C3-AC50-4640F3261F1A,BiosFwInfo 3FBD651B-5F0B-47AF-BE25-AE35C63C8D5C,AmiCpmWrapperPei 3FBD651B-5F0B-47AF-BE25-AE35C63C8D5D,AmiCpmWrapperPei 3FC08BA1-EDC6-4E5F-BDC8-0E46B65C92F6,SmmGpiDispatch2OnSmmGpiDispatchThunk +3FC2A64E-0A39-48D1-9424-721344C1918A,CompalInfo 3FC69994-1900-468B-B2D9-E6163056C3E7,Ast2500Pei 3FCF2813-F138-411C-BFC4-DBE5B9499822,ODMEMUSBLAN 3FD1D3A2-99F7-420B-BC69-8BB1D492A332,Fid @@ -2647,7 +2959,9 @@ 407B4008-BF5B-11DF-9547-CF16E0D72085,PL111LcdGraphicsDxe 408E3BA4-8410-4C44-A51E-DF8BDB36056C,HpPlatformSmbiosDxe 408EDCEC-CF6D-477C-A5A8-B4844E3DE281,ConSplitterDxe +40902599-A3A9-43EE-AD76-D0482FBE29B5,PlatformVTdSampleDxe 40A0BE5C-ECA6-45F1-BFF5-619E26951E5C,HstiDxeV2 +40B086C3-95B5-444F-A895-CBF484A19A0F,AsusHwmSetupItem 40B09B5A-F0EF-4627-93D5-27F04B754D05,AmtReadyToBootGuid 40B207DD-89D7-4F58-B278-622176CA0998,SioResetSystemSmm 40B2D964-FE11-40DC-8283-2EFBDA295356,FmpDevicePkgTokenSpace @@ -2657,8 +2971,10 @@ 40C1E78A-D6C5-4A41-805A-85D680F8FDB1,FmpDxe 40C83888-A477-490E-A0AD-7B968CA2D73F,DellVRHeatsinkDxe 40CDA63E-3F70-4B25-A50C-49DBD7EE343F,SmbiosType132 +40D85A8F-37E5-4788-997F-70478C4B7B48,SecureEraseDxe 40E064B2-0AE0-48B1-A07D-F8CF1E1A2310,EfiNetworkPkgTokenSpaceGuid 40F75919-0CDB-4DB2-A0FB-6881CE7E9770,UsbMouseAbsolutePointerDxe +40F93610-8D5F-43D3-A896-C61EE79F1376,HpSmbusSmm 40FC560C-C5D9-4219-8963-46605AB2570A,FjSysmanFwUpdaterBin 40FDF4FC-B7CC-4AC5-9BA2-A050D26656A7,SmcOptimizePei 41015350-BA3B-4916-B043-4615408A87B3,OememSmiCore @@ -2667,17 +2983,21 @@ 411F7E6F-4666-58B2-D69E-D680C0F68BE2,SystemAcpiAddedValueDxe 41282EF2-9B5A-4EB7-95D8-D9CD7BDCE367,Oa2MagicNumber 41292206-4069-42A6-AC38-C4A5C123C6E5,BaseTraceHubLibNull +4131B0C5-DEC3-470A-AAD5-1509349DBFB4,AdlSioFunctionDxe 4133A446-3E9B-463E-982D-0B7A09B1F138,FjShutdownLogDxe 413B1952-D564-4AEB-8CDA-8353161500BC,S3SaveSmm 41401688-2862-431B-BAAC-6ECADAC384AB,PciCfg2OnPciCfgThunk +41415623-A074-4369-98C8-370770AED42B,AmdMemSmbiosV2RsPei 4143C17D-54BC-4903-9958-2454216BB21E,LpcPlatform 414D94AD-998D-47D2-BFCD-4E882241DE32,FwCapsuleHdr 414E6BDD-E47B-47CC-B244-BB61020CF516,EfiHardwareErrorVariableGuid +414FE699-1D18-4C80-8C92-6140737801E2,FjUartModeSelection 415928AD-31D9-4CBF-9E92-6D1F67EC5711,EfiNgnCfgOut 416CF182-4A5F-4F21-919A-0161D837181E,POSTCODE0A_DUALACCELEROMETERWMI_SMM 417560D0-80F6-4CB2-A15E-50ACD383691F,FchSmmDispatcher 41781F4F-A3CD-4750-8A2C-2192B4DFE52B,EfiPeiPlatformTypeHedtEvPpi 41789FB9-02AC-4484-BD40-A3147D7EDA25,PeiRecoveryLibNull +417DA59E-CB73-452B-90F3-A8D9B805004A,BootOrderDxe 41804D8B-2CF4-43CA-9034-18E5DD227C93,HpNetworkTransferDriverWmiSmm 41846A2E-7AAA-4498-BC26-B5ACD49F92E1,DellSmbBootPriority 418BC604-F15E-4843-85D0-2D2480B7E488,EfiMpstNodeData @@ -2690,12 +3010,14 @@ 41B168D3-7C13-430C-BFEE-B438C2795C1F,SmmWhea 41CF3880-0560-4D01-8624-3A0A47894574,DetectDevice 41D94CD2-35B6-455A-8258-D4E51334AADD,EfiIp4ProtocolGuid +41DC6838-029A-4D2E-860C-6EC6425B5EDD,AsusWlanUpdate 41E26B9C-ADA6-45B3-808E-2357A35B60D6,ArmBootMonFsFileInfoGuid 41E2F0CE-238A-4906-AEF8-37C531ADDF89,ThermalModePei 41E321D8-CE30-4160-B08A-75AA570BF36F,LenovoFlashDeviceInterfaceDxe 41E89AB0-BD3D-44B6-A431-E4836EFBF2CB,PowerManagement2 41EADC00-8DB2-4BFE-B0EA-CBAAE7F4D31B,SetupModifyProtocol 41EF54AD-E2CA-4433-FD27-D9CACA621EAE,AmdNbioIOMMUDxe +41F19F4B-E16D-4908-89DA-BEA814A66093,AmdSpiHcProtocolSmm 41F46692-9513-4D1C-8BB3-B6A168182DE4,DellMePciPlatformConfigDxe 41F564F5-616E-41D7-B4E3-E124C7FEC024,TransitionBios 41F8606A-F74C-409D-9465-5219557CBC7D,DellFlashIoSmmProtocol @@ -2728,6 +3050,7 @@ 428DA2C1-39BE-41B1-88A6-A6FB870139A4,BsfWsRouting 429501D9-E447-40F4-867B-75C93A1DB54E,SmramCpuDataVariable 4296D9F4-F6FC-4DDE-8685-8CE2D79D90F0,EfiDriverHealthManagerFormSet +42AAA06F-B219-42A3-889E-413053ED10AE,FchSmbusDxe 42BB2364-F488-45DE-9311-E9E2CD37BD74,RtKbcDriver 42BB673D-09F3-4E2E-9FEE-D081131DED5B,BootScriptSaveDxe 42BBACA3-7161-4891-AC10-C75E2E4DF614,IffsPlatformPolicyProtocol @@ -2755,8 +3078,10 @@ 43130081-60D6-4C29-BBC0-AB0B5BB90483,DellMfgAuthenticationSmm 43172851-CF7E-4345-9FE0-D7012BB17B88,iFfsSmm 4325AFB3-9F11-42C7-A293-94AAE3804942,FjUpdateSystemInfoDxe +432F9D66-F40F-435E-B402-46D41A394CCE,AmiChipsetPolicy 4335ED99-9D86-492D-83AE-4D7359E99089,SioPlatformHook 4344558D-4EF9-4725-B1E4-3376E8D6974F,ShellLevel3HiiGuid +434DBB27-969C-47D1-876A-4146D4EB4E36,DellBluetoothSmm 43522AE9-ECFA-4826-BC07-0E057A87D607,RealtekGopDriver 4356B162-D0B2-11E1-8952-4437E6A60EA5,Lan9118Dxe 43573EA3-8F6B-4BCA-970B-EFFAB15AC0E8,SanitizationModeSsdt @@ -2764,25 +3089,31 @@ 435D621B-3C41-4536-B0C6-AF67059FC4BE,CrashLogDxe 43679142-87C4-44AD-AF02-B47F782D6CF3,PeiIpmiLibIpmiPpi 43788BEB-638F-434C-8A84-46D33A589E76,DxeBmcElog +437B9A30-299F-11ED-A261-0242AC120002,DebugLEDSmm 437F14D6-97AE-4DA8-A598-2E65791E6944,SplashBarDxe 43827082-110B-428F-B6BB-41F65E67B202,AsusUsbDxe 4383BB24-2E0F-47AB-8955-B9EE710ACE52,FjLanRtl8111xSmm +438A5B8D-98D6-4CCA-A182-BA8C0471B5E8,PchSmiDispatcher 438B7799-F4D5-47A6-A75C-305C4449F512,SwSmiDxe 4391AA92-6644-4D8A-9A84-DDD405C312F3,AppleBootPolicy 43A110CE-9CCD-402B-8C29-4A6D8AF77990,EslUdp4ServiceGuid 43A4C605-C66D-473E-A06A-37E9143FC439,PcRtc 43AC4333-472C-4B91-8C5C-52A8B4374256,IioCfgUpdateDxeNeonCityFPGA 43B03B31-057F-4F1F-9B53-C3A54F565586,SystemEventPei +43B16233-893C-4893-BF34-CDAC541926B0,UpdateSmbios 43B400A8-9980-4871-8D8E-9DA7CBD246DE,OemAmt 43B93232-AFBE-11D4-BD0F-0080C73C8881,PartitionDxe 43BB9EAB-7D57-4DEF-B0A2-A3A9F9C6EAE3,LenovoMailBoxDxe 43BC7B72-E961-4A59-8525-6F30A276625F,EcMemMappingDxe 43BE0B44-874B-4EAD-B09C-241A4FBD7EB3,EfiKmsFormatGeneric1024Guid +43BEB924-62EB-45FB-B0BF-9A97AF463D68,IteEcDxe 43C1B250-BF52-4DDE-8280-57E0AD61117D,H19AmdDimmSpdAccess +43CA74CA-7D29-49A0-B3B9-20F84015B27D,SecCoreNative 43CB767D-322C-4285-B2FA-E952BF2DD94C,AmdCpmSoundWireDxe 43DECD73-77CB-474D-BD6F-1A98E7E2B6C6,LenovoErrorManagerDxe 43E3023C-13DC-4BA6-99CB-AF6F9ECF8B73,H19DeviceFwUpdateHook 43E7ABDD-E352-4CFB-A230-4CDC1D350E5C,GraphicsConsole +43E7D039-EEA6-4C08-B741-096D39447845,SataDriveInfoSetupUtilityDxe 43EA62DB-C2E4-4AF7-AE94-2F48D708A3BC,OemSsidGpio 43F66FFD-B288-4139-BAD5-B89803E730A2,DxeTxtPolicyProtocol 43F9B080-C902-4737-B306-487050F7CAA5,fjHddEraseApp64 @@ -2793,7 +3124,8 @@ 4414D6D8-232C-4972-A4F7-2B21D4298786,I2cHost 441FFA18-8714-421E-8C95-587080796FEE,AmiSmmDebuServiceProtocolGuid 4426CCB2-E684-4A8A-AE40-20D4B025B710,EfiPeiS3ResumePpiGuid -442BE18B-CA6E-4A23-9A99-9AFE8A213A32,PlatformPeiSystemInformation +442BA91E-B0A8-499F-94F7-2E922C9AAE0D,AodDxe +442BE18B-CA6E-4A23-9A99-9AFE8A213A32,SystemInformation 444C3203-F8B1-42A7-ABE9-2E58025BE12A,FpdtPerformanceProtocol 44577A0D-361A-45B2-B33D-BB9EE60D5A4F,ArmRealViewEbPkgTokenSpaceGuid 44640C32-33D7-4FB0-B1F9-6C7B232E994D,SpsPei @@ -2805,6 +3137,7 @@ 447C8D3F-429F-405D-BDC6-35D75F3DC082,OFCRuntimeDxe 44830575-0A1A-450B-9FEF-BC88A1866A13,FjGabiBootOrderHandlerSmm 44883EC1-C77C-1749-B73D-30C7B468B556,ExFatDxe +4489DD91-8FBA-4F0E-B218-A24497805E1B,AmdFabricBrhPei 448F5DA4-6DD7-4FE1-9307-69224192215D,EfiSectionExtractionProtocolGuid 4495E47E-42A9-4007-8C17-B6664F909D04,BlockIoDxe 449C91B9-0907-49B5-AA76-04AF3097401C,SmbiosPlatformDxe @@ -2816,6 +3149,8 @@ 44CDFA70-2C7C-4791-9AA3-EAE8777F0A8B,X11DPGPeiDriver 44CF7D20-DFF6-4209-9A1F-F6CD5F5CE88B,LenovoVariableInitSmm 44D763ED-7798-49A4-8B8B-C3D5BB2FD4FD,RestrictedBootfromRemovableMediaPei +44D88421-93BD-4325-BE63-051B531889CB,BiosCfgToolSmm +44E71185-2277-4557-BC53-957FAD9CA65C,FjLvdsRTD213xR_Dxe 44E7717F-075E-450D-98D5-54EBBB40701E,EfiPlatformTypeLightningRidgeExecB3Protocol 44F0DE6E-4D8C-4045-A8C7-4DD168856B9E,EfiRngAlgorithmSp80090Ctr256Guid 44F23590-DC88-11DD-AD8B-0800200C9A66,SystemAhciAtaAtapiPassThruDxe @@ -2830,7 +3165,9 @@ 453368F6-7C85-434A-A98A-72D1B7FFA926,EmuIoThunkProtocolGuid 453C5E5A-482D-43F0-87C9-5941F3A38AC2,EfiKmsFormatSha1160Guid 45424D0C-E6AF-4AF2-AD99-FA77168742D1,SmartTimer +4542B4AD-29DE-409B-AE4F-93A8C25392E2,ClearCmosDxe 4549AB47-6E60-4293-B91D-31B610AD8056,EfiEsrtOperationProtocolGuid +454B0149-5B42-485E-8A8E-A20422790B97,AmdFabricBrhSmm 454DB25C-E506-4F90-A6DF-69E0223E3F2B,PramAddrDataGuid 4551F2F5-C684-4F27-936F-C7B04A5C5FF1,SecureBootDXE 45594FFD-60D8-45BB-8D6F-867BDF09E8C9,StorageSetupInfoProtocol @@ -2843,9 +3180,13 @@ 457A68D7-15A5-4AF9-A252-9963FF9B0C34,PowerButtonSetupPei 4589CBF3-03F9-4998-9D6F-26343C69562A,LenovoComputraceLoaderDxe 458B03ED-6E53-414F-9F07-3A829C990641,DriveLockSmm +458CE95A-4942-09A9-5D21-A6B16D5DAD7F,RedfishCredentialDxe 459504D7-72D7-4BB2-956D-C9FA899920E8,OemFwLnk +45982835-D04F-4745-BCFD-519E6BB2DE7A,NvmeInfoSetupUtilityDxe 4599D26F-1A11-49B8-B91F-858745CFF824,AmiStandardDefaultsVariable 459C70C3-9344-4484-9F93-7822530D0D11,MePciPlatform +459FAFEE-3BCD-434D-90C9-A283ABAE84D5,HspfTPMAcpiSmm +45A36262-660C-495E-BDC4-50A852A44A11,MtkSuppDxeGen2 45AAC157-93B6-46D6-AA9E-4CF6C32916A4,CRBSmm 45AC8863-E3FA-4A38-A23C-00BCD10CBD50,AmiNvramSmmCommunicationGuid 45AEE2D6-18B5-4DFE-92B3-2C04F61631AF,AaeonEcPei @@ -2853,6 +3194,7 @@ 45B59855-500C-443B-B504-9AB4CA29BC68,EfiPlatformTypeLightningRidgeEX8S1NProtocol 45BCD98E-59AD-4174-9546-344A07485898,EfiSupplicantServiceBindingProtocolGuid 45BD5504-94A8-4301-B211-B0AE4F56E9AE,ThermalSMM +45CBB784-020C-46E2-8A14-BE20CA21C3F1,PowerLossNotifySettingDxe 45D68DB9-8B4E-48C0-99E9-F21F262DB653,XhciPei 45DC2877-0DF1-4BD4-810F-0C75111819CC,EcDxeRestorePei 45E78B8A-BD68-453A-8E9E-C3773108B213,SiInitPreMemPch @@ -2865,8 +3207,10 @@ 45FC167C-8B1B-49F8-A3FF-9FE54241C969,RfIScsiBoot 45FDB42B-1F95-4A53-9BA4-1C8BFB8BCB01,DellGpeConfig 45FF16E5-02B2-4C89-8604-E68C10DDE107,SmmCommonService +4612B275-356B-44D3-9315-33E6E936E64C,FjTpmInit 461A67CF-3D9B-4FC0-BCD2-7C606335DE0F,SystemSetupSecurityGuiDxe 461B2833-3DA5-4556-95F2-BA506131051B,ExtCfgDevDrvDxe +461DFED6-9D33-4AC0-8D25-57381ED0BBC0,AfterG3PolicyInit 46233426-744E-4763-958D-44B1200B320A,AmdMemoryHobInfoPeim 462CAA21-7614-4503-836E-8AB6F4662331,Enter_Setup 46310243-7B03-4132-BE44-2243FACA7CDD,CMDB @@ -2875,6 +3219,7 @@ 46419146-3D6E-473C-A3AA-22AB404F197C,FjDxeServicesTableDxe 464FDC84-D53F-4A7B-B491-87991228F08B,FjUsbDeviceDxe 4658B698-EAB5-647A-987A-5A1665478FF6,A01SysPasswordSmm +465EA4B9-0FFC-40E7-9CC2-0F2CC3E66DFF,TouchscreenIdm 465FDE84-E8B0-B04B-A843-A03F68F617A9,ThunkPpiList 4660828D-842A-4F69-B31B-D393662B5240,LenovoDeviceGuardDxe 466A7291-50DF-4B40-A2EB-CEE67D5428C9,AmiTseOemPortingVar16 @@ -2889,6 +3234,7 @@ 46A2DC1D-6D2A-4558-BC0E-86B4B54B4236,OemCustomizeCsm16Config 46A9772D-D258-4210-9017-8799C57466BA,SwitchDellSystemID 46B94C2D-AF5D-4915-814D-159323AE780A,PowerButtonHandler +46C81ECA-E931-40B2-AECF-DFD8F00664EF,MtkWiFiDxe 46CF6120-9BDE-49B1-9D59-D35E355BF850,OdometerResetSmm 46D8ACDD-29C3-4013-81E8-37A425AB4F99,SystemVspCmosSmm 46DDB415-5244-49C7-9374-F0E298E7D386,EdkiiHttpTlsCipherList @@ -2901,6 +3247,7 @@ 46FCD5D8-A9B3-42E3-904A-012F07BC5F5C,PowerOffSmm 470458CE-3E8A-40A7-BFCB-07755ABC4104,FjGabiGpio 47060D0C-BB2B-42D2-9A85-4DF1A2BFDFE2,BoardDxe +470A56EF-DC23-47C5-9D79-888E755C875F,HpLidSwitchingDxe 470CA824-F687-4148-885E-46311241C201,PchEhciPei 470CB248-E8AC-473C-BB4F-81069A1FE6FD,SmmFaultTolerantWriteDxe 470E1529-B79E-4E32-A0FE-6A156D29F9B2,EfiBootScriptSaveProtocolGuid @@ -2912,19 +3259,24 @@ 4727E62C-DF17-4000-89E3-7AEE74AFEC63,FjGabiEntrySmiDispatcherDxe 472A583E-70CF-465A-BB77-53ADFCDB5883,OCMR_DXE 4735EC40-F0B8-4102-A4C1-2E83B6B0C0BD,FchHuashanDxe +473BF006-83E1-4B25-BC6A-DA8A20555B59,TouchPad_Sensel 474933A5-E26E-4722-8BA8-851D0154228F,FjHddErase 4759E93E-8F44-448F-88A1-BD97FC47BEA5,AmdPspP2CmboxV2 47727552-A54B-4A84-8CC1-BFF23E239636,Tcg2PlatformPei +47727552-A54B-4A84-8CC1-BFF23E249637,XmlCliCommonPei 4772C6DA-506D-4C95-AC17-AE66885F6D53,DellGpe 4776E33F-DB47-479A-A25F-A1CD0AFAB38B,EfiKmsFormatAesxts128Guid +4778683F-B2BD-46B9-BF34-1BD00D5EC7F5,AmdMemoryHobInfoPeim 47889FB2-D671-4FAB-A0CA-DF0E44DF70D6,EfiPkcs7VerifyProtocolGuid 478C92A0-2622-42B7-A65D-5894169E4D24,ELabel 478FCDAD-760E-426C-869B-2F3345051750,DellHddSmartDxe 4795255C-7031-473C-AF8A-8BC7701ACCA5,fTPMAcpi 47970A28-8F4A-4CB2-91DE-BF344153189A,AmiCspFlashLibNull 47AA8FEE-48D0-11E4-A6D3-B8E8562CBAFA,SpiLockDxe +47AE3255-FA69-459F-D334-D8A57BF952A4,IspI2cMasterDxe 47B2138F-5A6B-4C65-9167-8740595D16AD,DellPasswordMgrSmm 47B7FA8C-F4BD-4AF6-8200-333086F0D2C8,EfiSmmReadyToLockProtocolGuid +47C1AC56-67DA-4BB0-BDFD-C4DB6CB9EEAB,ConsoleBootMsgDxe 47C7B221-C42A-11D2-8E57-00A0C969723B,EfiShellEnvironment2Guid 47C7B223-C42A-11D2-8E57-00A0C969723B,EfiShellInterfaceGuid 47DCFD49-F110-4EF8-98D4-D8C8883270DA,D01IhisiSmm @@ -2944,12 +3296,14 @@ 4839023B-4C12-4EB2-B2B8-C91B42D878A0,IsctAcpi 48441C12-74EA-4FBD-BD1F-199CF39C5BE4,Kb902xFlashSmm 48459B6D-0E45-46AE-B5C4-E701A25A0D6D,PlatformCrisis +484C77C1-378E-41E4-B4F1-08A1555FB197,AsusWatchDogTimerDxe 48569430-485F-4ACC-A184-B35D11CB7560,AmdCpmUcsiDxe 4862AFF3-667C-5458-B274-A1C62DF8BA80,HeciInit 4866788F-6BA8-47D8-8306-ACF77F551046,FspNonVolatileStorageHob2 48705A28-FF4E-4573-8164-A026963D801F,LenovoCapsuleUpdateVariable 487647C2-3D08-4D02-9AA4-7CE4F7BD5A7B,PlatformSmiSecureCheckSmm 487784C5-6299-4BA6-B096-5CC5277CF757,EdkiiCapsuleUpdatePolicyProtocol +487AD797-E10F-4BAF-9144-660AB11C2E29,WiFiLauncher 4882FE88-7AC6-418F-BEC4-3AF4373A3374,FjBootVariableCheck 48925241-D2ED-46D4-8A87-A18D153C2802,SmmOemEeprom 48959D4F-4574-470E-AA4C-CF144D1C1678,InstallVerbtableDxe @@ -2961,11 +3315,13 @@ 48B05831-3298-49CC-86CD-3020D95381E7,ConfigDataUpdater 48C7F9E6-8F68-49DE-B698-0D6A014890F7,SiInitPreMem 48D51913-F340-4798-83D7-5CAB3D5C6DA7,AppleEffaceableBCENOR +48D65EC7-8B1E-4965-9AC2-B7AD627209CE,SaveMemoryConfig 48E40CAD-A6D2-4756-8AEB-81F468D4A856,Tpm20ShutdownOverrideguid 48E796BD-4ED3-4755-A8CA-4CF437258241,EfiPeiPlatformTypeNeonCityFpgaPpi 48ECB431-FB72-45C0-A922-F458FE040BD5,EfiEdidOverrideProtocolGuid 48F40D93-AF30-4410-9F4A-FF61947E3F62,MAPS_WatchDogTimerPEI 48FB21BF-47E5-406C-A73E-D83D00767214,FwhFlashPeiLibNull +48FBAE5F-09AC-4BDA-AFD8-B30884B2422A,AfterG3Init 4904B42F-9FC0-4C2E-BB3F-A2AB35123530,DebugAgentLibNull 4906415D-4B32-4D28-8557-21C390D76A3C,DeleteUefiCaFromDb 490D0119-4448-440D-8F5C-F58FB53EE057,PolicyInitDxe @@ -2975,9 +3331,12 @@ 492261E4-0659-424C-82B6-73274389E7A7,DellRaidRom 492CB3AE-66DB-4F1E-91AE-534C48F2F83D,WheaSupport 492F48F1-D0EE-41E9-BBE8-92C98A3CB7F1,FchTacomaSsdt +492F92B4-F0EA-4875-9C59-80CED0B90A31,M24Lc256Pei 49328871-FE65-4586-A013-0ADAAEA1DAFF,FvbServicesRuntimeDxeRA 493B5BAC-BB9E-4BF5-8379-20E2ACA98541,EfiSaInfoProtocol +493D3613-845F-413C-A7C5-1BD890CDC4E1,AIMTBatteryInfo 4941D466-4042-4C49-2B8B-8C83834C1379,PegaPeim +49450E14-2BA1-40E9-9755-6FE327F8E022,DeviceChangeDxe 49462CB7-0CFF-41AC-B139-51DFF93D8140,TrackPointElan 4953F720-006D-41F5-990D-0AC7742ABB60,IntelGigabitLan 4953F720-006D-41F5-990D-0AC7742ABB61,Intel10GLan @@ -2996,11 +3355,14 @@ 49EA041E-6752-42CA-B0B1-7344FE2546B7,ArmTimerDxe 49EAB1A6-AF2F-4064-9B29-D9655B3B8DED,DellAmtConfigPei 49EDB1C1-BF21-4761-BB12-EB0031AABB39,EfiPeiFirmwareVolumeInfoPpiGuid +49F71D68-D464-435A-9C95-11325BACEFE6,QuickI2c 49F8C35C-B9EF-402A-AB44-871C139EB00D,FastBootSetupDxe 49F8D341-339B-4E88-A1CC-7FFD00343C59,DellS3ResumeStatusCodePei 49FC00CF-BBD2-4FD4-B9D1-F084A51EB708,ApobSspDxe 4A0266FE-FE57-4738-80AB-146E46F03A65,EfiWheaBootProtocol 4A033533-D570-43F6-BA84-61CBA70165F8,DellUefiClass3ConfigPei +4A0C7D11-CA7F-4C59-8659-6BDA5132A5A8,DtprDxe +4A0F0F08-EE19-4FE2-85B1-9AB4718D17D0,BiosSelfHealingSmm 4A153B6E-85A1-4982-98F4-6A8CFCA4ABA1,EfiExtendedSalSensorServicesProtocol 4A1A67D0-E77A-4F0A-AF1D-CC412BE93DC9,AmdCcxZenZpDxe 4A1D0E66-5271-4E22-83FE-90921B748213,EfiDxeIpmiTransportProtocol @@ -3017,6 +3379,7 @@ 4A4ECE10-61EB-4FC4-8839-F7CFDD962074,IccPei 4A5227D3-0BEF-4CAA-ACBD-EC84446C5C6C,MiscGaIoDxe 4A538818-5AE0-4EB2-B2EB-488B23657022,FvMainCompact +4A59F1EA-A18D-40A6-8717-C16DC5A6ABB6,PchCrashLogAgent 4A5CA267-4016-460F-80EE-7B4C3D77FD62,DellUserInterfaceDxe 4A64C620-1CEF-40A0-BE1C-EED6B20ECCE9,MrcHealthDataInit 4A64F200-F99C-42F3-80C7-0D91E2D3EB5D,SioGpioControlDxe @@ -3042,6 +3405,7 @@ 4B0165A9-61D6-4E23-A0B5-3EC79C2E30D5,DxePchPlatformPolicyProtocolGuid 4B1D21E9-4DCA-4820-8112-61E52B815EC1,RtCommonService 4B215191-9A25-43FD-86B5-74E7AF723315,AmiNvmePassThruProtocolGuid +4B26CDB7-EFD0-42AE-9211-8C1711C3695B,PcdStatusCodeDxe 4B28E4C7-FF36-4E10-93CF-A82159E777C5,ResetSystemRuntimeDxe 4B3029CC-6B98-47FB-BC96-76DCB80441F0,EfiDiskInfoUfsInterfaceGuid 4B3082A3-80C6-4D7E-9CD0-583917265DF1,AmiSmbiosNvramGuid @@ -3053,6 +3417,7 @@ 4B4F517C-0145-4783-A1D7-018D20797555,PciHsUartDxe 4B562E45-2EB2-4E5C-BF2D-5763F4304DFB,UsbMassStorageSmm 4B5DC1DF-1EAA-48B2-A7E9-EAC489A00B5C,EdkiiBootLogo2Protocol +4B5DE05E-16F4-11ED-861D-0242AC120003,EcFmpCapsuleDxe 4B5F17C7-B567-4E47-BF3D-E4C21EF33497,ExpansionSlotConfigPortingDxe 4B63A5D4-CB08-47CD-AFD9-BEA33A30F313,CrashLogDxe 4B63A5D4-CB09-47CD-AFD9-BEA44A30F315,PopUpRework @@ -3066,13 +3431,19 @@ 4B8C9600-9958-443D-BE30-F4B7A7E53463,DxeSmartPowerOn 4B94F4FD-8FB9-4CF1-A0D8-EA03B4467BE2,OemThermal 4B9D17B3-4DC9-45D9-8F06-BDD3F9A45E5C,AmdI2c3MasterDxe +4BAED146-B579-4959-8150-F93F1C7A0B68,IntelGraphicsPreMemPeim 4BB346D2-8076-4671-8BC9-7B95CBB9A6DF,MonoStatusCode +4BBAF21C-98AD-421E-B53C-9EC2E8A87A29,AmdPlatformRasRsPei 4BC80B15-255D-4858-8072-51D6D98CF90E,SetHostName +4BCB4D93-46D2-94EF-BB82-5C8671B24D26,CxlErrorLogDxe 4BD01172-54D3-4A97-B6A0-DA57474CDF3C,FjGabiEntrySmmBin 4BD0EB2F-3A2D-442E-822D-753516F75424,PchInitDxeTgl 4BD56BE3-4975-4D8A-A0AD-C491204B5D4D,EfiAdapterInfoUndiIpv6SupportGuid +4BDE935B-7700-4E73-823D-AF9B402270AC,CloudBootCreateEmbeddedBoot +4BEB3357-F146-4E10-9F60-E4797906AFDA,PostMessageConfigUtilDxe 4BEB96B4-C069-4C49-845F-1C1CC68CD8D6,FchShastaSsdt 4BEECAFE-5F02-432E-44B9-3CA5CA5DF189,AmdNbioBaseSspDxe +4BF759DC-8DC5-4B66-B3B1-37B7F9185B61,TDP1204 4BF98E30-17E0-11E9-B56E-0800200C9A66,ThermalSensors 4BFFC0D3-7E33-4370-8A28-3238FC33AD2F,DataStorageSmm 4C006CD9-19BA-4617-8483-609194A1ACFC,UsbInt13 @@ -3094,6 +3465,7 @@ 4C91B810-A28D-4BBC-BDF0-30A9C6C7EEC2,OemLOGO 4C9BA841-0A69-4567-9E37-42CBF5F7F269,OemGlobalNvsDxe 4CA16857-A0C5-4E46-BE0F-98A4BB314E5D,MemTest +4CA8A1EF-D4DA-4212-9F4D-41638E68B6C1,MemoryStorageChipsetDxe 4CBB6611-3608-492B-92A7-DD92FD6FE4FE,OEMBOARDPei 4CC14F19-C626-4AB6-9DEA-CA6C01FD10CD,AsusHeader 4CC771CB-777B-4F64-B0F9-C70ED4355D1C,MediaCradReaderConfigSmm @@ -3114,6 +3486,7 @@ 4D0E0FBB-AD24-4213-B9B4-692B6662CB36,FjTpmDisable 4D0EBC36-88D7-492C-AF46-677BA21F6D81,SetupConfigUpdateDxeCLX64L 4D1514D2-FBDE-49C6-B20A-A40288A0D4AA,HstiIhvSmm +4D1EFB42-6A65-4C9C-81A7-FE2A6B885DA8,EventLogPei 4D20583A-7765-4E7A-8A67-DCDE74EE3EC5,HttpBootConfigGuid 4D2ADE73-B751-4C68-9FA2-61909EBC59EA,KEMhMarsDxe 4D2C22F3-C0E5-419E-8978-BC9C3CF843A8,DellFmpGbe @@ -3138,14 +3511,18 @@ 4D85D326-58E0-43FD-9F63-58DF46789B7F,PciResourceAlloc 4D8B155B-C059-4C8F-8926-06FD4331DB8A,GetPcdInfoPpiGuid 4D8B77D9-E923-48F8-B070-4053D78B7E56,Tpm12DeviceLibTcg +4D922231-4F16-468F-A771-A1E5C29713C9,OemDisplayRule 4D9CBEF0-15A0-4D0C-83DB-5213E710C23F,Tcg2ConfigDxe +4DA62F29-32BA-4470-94FE-D7C84260D427,SecureBioXhci 4DB83B45-9CA8-41ED-9FC7-C3FC00267B8E,CountryCode 4DC2E02D-D5FB-4330-BD53-53797347DF01,HwmFanDxe 4DCAAB0A-1990-4352-8D2F-2D8F135598A5,EslTcp4ServiceGuid 4DCBF9BA-DEC1-42B0-8A09-01555694F6CF,GbtCustomizeButtonSmm 4DCD2C72-ECBD-4F47-84BB-2B3BD2BFF90B,UsbCrisisEnumPei +4DCE95D9-37A9-4DDC-8143-326CE9A49B3A,AmdSocFp8StxKrkDxe 4DD4DF07-3278-406F-B5DE-EC7EECC650E1,CrbPxeUefiDriver 4DDA8138-47CD-4019-9178-115003431B21,SWSMI_Shadow +4DDD67E7-BDF5-4473-8AB0-02821C084338,MemorySelfRepair 4DE01DE6-7CBB-4786-9F2A-9B9C7C97AC06,S3RestoreAcpiPei 4DE67E0A-162C-4999-A5B8-BA0E5D43284C,CmosChecksum 4DE9A180-FA40-4899-AB66-4E6325B0315D,GpioExpanderDxe @@ -3171,13 +3548,16 @@ 4E304BC0-3B03-4A97-BB55-91375189A31D,iFlashDxeBin 4E32566D-8E9E-4F52-81D3-5BB9715F9727,OvmfPkKek1AppPrefix 4E348EF9-F02D-4DFB-847C-FC5CA755E426,FchSmmDispatcher +4E37AEAE-F9D7-464D-9969-0FFBEB6F423F,AsusRomLayoutDxe 4E3A82E6-E43F-460A-866E-9B5AAB804448,EslIp4ServiceGuid 4E3F9A17-ACA9-42F3-A8CC-E7340FB6DB6E,MemTopology 4E4E97F9-63FF-4BDA-90BB-C6F943FA5100,PlatformStatusCodeHandlerSmm2 4E509696-E33F-408E-9AF5-CC8C20065385,SoftwareGuardConfigGuid +4E537B6B-C6A9-474F-A023-D512CD141A83,QrCodeGeneratorDxe 4E5B4FEA-936A-45BC-AC6A-2F8F14A6C29E,PrmConfigProtocol 4E613EA8-C01C-4BA7-BA09-38BD86815F85,FjPasswordServiceSmm 4E694D04-318B-4F89-A3B3-BA3560FD389E,HddSetupVarDefaults +4E6D9DEE-CAB0-413B-9F6E-59869DD364F6,CmosInterfaceCoreDxe 4E75CCB0-A653-4C76-A213-5B2DBCD2A9EF,TouchDriver 4E76928F-50AD-4334-B06B-A84213108A57,NtFwhPpiGuid 4E77C4E1-7879-4A1D-8A88-584BC2CD58C5,HpTriggerEfiDriverLoad @@ -3200,11 +3580,14 @@ 4EC8B120-8307-11E0-BC91-0002A5D5C51B,PL011Uart 4ECB6C53-C641-4370-8CB2-3B0E496E8378,EfiExtendedSalVariableServicesProtocolGuid 4ECEC19C-6E5F-4815-8342-B55F2CC5DFC1,LenovoVproHiiDxe +4ED42C6A-AC97-46C9-9758-E1FA769D3AFA,OemIceSetup 4ED4BF27-4092-42E9-807D-527B1D00C9BD,EfiHobMemoryAllocStackGuid 4ED73FC1-3AE7-4BAF-98DE-9F2AEEAA00AF,FjS5WakeSmm 4ED88276-D4DF-4D03-8661-295801B2DA58,FastBootExceptionInfoHob +4EDD7BAF-BA98-47D8-85BF-831D98E786CD,Sdev 4EECDF66-C506-4458-9C0D-70021828FB31,SpiProtectionSmm 4EEF2D60-0E00-11DE-8C30-0800200C9A66,SataController +4EF83446-DCC5-46BE-A9A8-870390A6E28B,AmdAblPerformanceDxe 4EFA0DB6-26DC-4BB1-A76F-14BC630C7B3C,AmtForcePushPetHob 4EFA14DD-2A34-491C-B81E-7D05B210FCFA,RemapPwdPei 4EFC51DA-23A6-4790-A292-4985C7F5CDEF,LenovoComputraceEnablerDxe @@ -3239,8 +3622,12 @@ 4F921013-4F71-4C6C-BCF8-419B2B801932,SetupBrowser 4F948815-B4B9-43CB-8A33-90E060B34955,EfiUdp6ProtocolGuid 4F95E00D-6B84-40D1-B2A2-FDF718537183,WlanPei +4F967D7A-D55F-4B53-BDD9-269A80785D16,AdlSemaMiscellaneousDxe 4F9883C7-B309-4152-ACF3-223850478D88,SmcPkgTokenSpace +4FA09F49-AE5F-4D7E-870B-080030E1B63E,FvBbPei 4FA7E1F2-CE8B-4D38-A3F8-342DC4515446,IioCfgUpdateDxeNeonCityEPRP +4FAB12FA-21D5-42A2-8260-E0CFA50C899B,MonolithicCapsuleDxe +4FB0D5AF-D140-4078-83B5-39013075CEBB,FjBeepOnPOSTPei 4FB2CE1F-1A3A-42E3-BD0C-7B84F954189A,AcpiCallbacksSmm 4FB2F0D0-7183-4BFC-9E65-11A4031847D2,AmdCpmPlatformOscTableInstall 4FBB790E-71E9-42FF-9F8C-469C4FD0A04A,OpromCallback @@ -3249,11 +3636,13 @@ 4FD1BA49-8F90-471A-A2C9-173C7A732FD0,SeCfTPMPolicyPpiGuid 4FD2D553-DABD-4C17-ADC1-32C8F3EDAAD9,LcdShadowDxe 4FD49958-F29D-4019-80F6-0700699D9540,OemWwanSmm +4FD5F726-BED2-410D-9097-C679DE190854,SetupLoadDefaultShp 4FDBCCB7-E829-4B4C-8887-B23FD7254B85,EfiRedfishPkgTokenSpace 4FE0ADEE-606B-4375-90B5-65698DFD0B9B,IntelUefiRaidDiskInfo 4FE772E8-FE3E-4086-B638-8C493C490488,PhysicalPresencePei 4FEBE43F-256E-4C82-A20A-BC0D03C72185,PTN3460CfgPei 4FED14B0-2B0C-4E20-9071-61094B1C4B55,EzFlashInterfaceWrapper +4FEEDBF2-3E3C-4D99-AD5F-D92195DDEDD6,FjWatchdogGHO 4FF26BC4-694E-4994-89C2-E9E44690D174,HpNvErrorLog 4FF2E88A-A404-46F7-9A2A-35E00844F6E6,SpiDeviceDxe 4FF3AA5B-105C-4409-87CD-59C15B7FC5D8,DellGlobalNvsDxe @@ -3262,6 +3651,7 @@ 5007A40E-A5E0-44F7-86AE-662F9A91DA26,FvOnFv2Thunk 500CC042-E300-4759-9211-868B9AD0E207,FjUIDxe 5011522C-7B0E-4ACB-8E30-9B1D133CF2E0,FmpAuthenticationLibNull +5014B9B7-B3FE-4D0D-8F5A-2B27132B7779,AdvBdsDxe 501BD93A-F1A9-4F4C-A946-7867DF975537,LenovoEn25Qh64FlashPartSmm 501C5B87-8181-4AE5-A6B2-D05ACE0D83DE,SmcOobPlatformPolicyCallback 501F30E9-D14F-47DA-AE60-B101E4189D07,AhciInt13Smm @@ -3270,7 +3660,9 @@ 502B04F3-71AB-47B4-BEAE-4736EA190AA4,PciDxeInit 502D4D8C-E607-4613-B187-3ACAB0169AD7,DellDualBootBlockDxe 502D8541-01BE-4FB3-8986-3F9916548164,DellTpmSmm +503A80A4-34C3-47B4-BB6E-00AD1F36CF47,AmdLegacyInterrupt 503E70FE-047A-410B-A55F-4F63C9382C1E,CpuIo2OnCpuIoThunk +5045A8A6-7D74-4037-AAED-1449DBAEBCCC,PciLookupTableDxe 504F2F1F-E7EB-46F9-AA07-0606F311AA1A,SmmPlatform 5053697E-2CBC-4819-90D9-0580DEEE5754,EfiCapsuleArchProtocolGuid 50578334-FCFD-4DCA-B3AF-47DD76E946CF,AmdNbioDxe @@ -3287,6 +3679,7 @@ 50B4FAD4-9D0D-440B-812C-D8E3EC21244D,XhciHandlerCommon 50BEA1E5-A2C5-46E9-9B3A-59596516B00A,ArmVirtVariable 50C511E0-3C68-4FD1-B7EC-2589657EA225,IDDxe +50C59A68-1920-4B6E-A296-2D37C0619EB9,SetupMenuSmm 50C86A39-C194-4B03-8B4E-22CE463BB2A0,DellSmmDiagLeds 50D51651-E5EA-4C7A-9DEF-7CF8A63AFC91,AmdPspDxeV2Phx 50DC5C90-1D33-4FD6-87E5-063B1DFA2170,AmiSerialProtocolGuid @@ -3302,6 +3695,7 @@ 510DF6A1-B6C1-4948-AEE7-59F220F898BD,SataController 510F8CC8-8500-4D16-A298-96D28584D6C2,DellPolicySmm 510FDE31-692D-4D86-8DB7-7F460C0A7B7E,PprVlsErrorLogListener +511110E8-A64B-4B88-A473-E0D296AF5352,TouchDriver 51116915-C34B-4D8E-86DB-6A70F2E60DAA,NVMe 51116915-C34B-4D8E-86DB-6A70F2E60DAC,IOBufferCopyController 5111B2D3-B8F7-45BF-8A63-2A1678F67A41,PeiSmmControl @@ -3344,6 +3738,8 @@ 51C9DF0F-21B9-1015-9151-12872F032A51,HardwareHealthManagementPei 51C9F40C-5243-4473-B265-B3C8FFAFF9FA,Crc32SectionExtractDxe 51CCF399-4FDF-4E55-A45B-E123F84D456A,ConPlatformDxe +51D27BF0-6414-4C69-AE20-BF017C326505,WmiSetupUnderOsSmm +51D2DA4C-5950-43A8-B8D6-133A686072EA,FchSmbusDxe 51D4BACC-E70A-4136-9426-546973ED938C,LenovoPlatformS3SaveDxe 51D528BA-9730-4460-ABD4-B1E5E3A472ED,PcieLanePEI 51D687C8-196E-4CFE-8A0C-8368980EA8B6,DellChassisConfigSmm @@ -3366,9 +3762,11 @@ 52416508-181C-4899-8CCA-E020A2BD3F18,ODMSMM 5242AADB-BDAB-4B92-B7D5-A58B6E0EEE6B,IchSmbusArpDisabledPei 5243ED17-6742-484C-8922-F2FDB1DC2725,WmiSensorHandler +5244407B-C852-480D-BAB5-938C832C5581,ASRockSIPei 524685A0-89A0-11E3-9D4D-BFA9F6A40308,AndroidFastbootPlatformProtocolGuid 524B4384-D632-4862-9D3A-6D82C9E85825,SystemInventoryInfo 524E19D8-8066-4BEB-8BBD-6FF9E405B3A7,MeResiliencyDxe +52534DC0-3328-4153-A17C-9FA795654C05,FjGpioGHODxe 5255DFB0-0E7C-47DC-95A7-0B838DA09BB0,UpiPlatformHooksPeim 525B672C-8C8F-0361-AE8E-565EE0F563B8,MemInfoDxe 5261213D-3A3D-441E-B3AF-21D3F7A4CA17,EfiScsiBusProtocol @@ -3376,27 +3774,34 @@ 5272EFC4-D506-4CED-A415-DA68B0515120,PciDxeInit 527EA834-EBB5-44EC-AA27-BC0FDCC0226C,FjSecureServicesDxe 52888EAE-5B10-47D0-A87F-B822ABA0CAF4,EfiPeiCoreFvLocationPpi +5291C916-8638-4296-BD84-3F4ACBB2D5A3,AmdAgesaParameterGroupPei 52978AFB-F8D1-4B0F-974A-0B7C9445E4EB,AmdCcxZen3CznPei 529D3F93-E8E9-4E73-B1E1-BDF6A9D50113,ArpDxe 52A7AA5D-3B23-4F06-FFFF-FFFFA95DD84E,XnoteSetupSecurityDxe 52A88B2A-65FD-4951-8B25-06FB6598128B,DellSpiPartEon 52A9B223-FAB8-4A24-AEA6-461A59BD3F33,AmdSmbiosDxe 52B3DBA7-9565-48E8-8E13-EC7196721B3C,PlatformInfoPei +52BAF47B-6920-4304-A031-A45CC345DA3F,POSTCODE01_TPM_CONFIG_POLICY_SMM 52C05B14-0B98-496C-BC3B-04B50211D680,PeiCore 52C78312-8EDC-4233-98F2-1A1AA5E388A5,EfiNvmExpressPassThruProtocolGuid 52C877FD-C27C-4779-B750-7880B28B4306,SetupConfigUpdateDxeNeonCityEPRP 52CE9845-5AF4-43E2-BAFD-230812547AC2,PlatformGpioProtocolGuid 52DAA304-DEB3-449B-AFB8-A88A54F28F95,OhciPei 52DFCF2E-5BE5-4376-BC22-14F788A4A425,AmdNbioEarlyPhaseRVPei +52E75865-F4A4-4FFA-A9F0-D3048EA79F84,ThermalPei 52ED90D3-BBF8-45FB-B24C-5121655D23B8,FjHddFeaturesDxe 52EDB5F1-9632-4CE5-8B82-3099200E66DA,SoftSkuSmm 52EFDE98-4C81-4423-8C6D-4ECAE61DDDD9,UsbOcUpdateDxeGlacier 52F934EE-7F15-4723-90CF-4E37127718A5,TcgPeiPei +52F9F971-5302-4F46-B1A6-1E55669B52C8,SxStateSmiPkg 52FA6F82-5255-45E1-8ABF-C62EDA2C89BA,SmbiosType133 +52FE8196-F9DE-4D07-B22F-51F77A0E7C41,LocalApicTimerDxe +5303664A-4222-474C-97A4-9A0D97D0020A,SVI3ManagementPei 53070378-119A-4836-77BD-893C824ACEB2,FchPromontoryXhciPei 53070378-119A-4836-82BD-893C824ACEB2,FchPei 531AED6E-3DEE-45EB-8DF1-B70ADB1F885D,TrueTypeDecoderDxe 531BDEF7-EF15-4C27-8441-110E61B48933,HpPwdPresentModule +531D43E0-5BC6-4FF6-8499-5EAE5B195E53,PeiFramework 531E5D9B-419B-4C3C-9561-B894F695DDE4,FvbVariableStoragePei 532A50A2-BCE6-4675-80EC-53EE57A68FA2,FchBixbySmmInit 532B6532-6499-428D-ACB1-F6F779C94DF9,AuthvarMailboxVariable @@ -3431,18 +3836,23 @@ 53CB13DF-A56F-4101-BB4F-9BE040657BB5,StdBoardSmm 53CD299F-2BC1-40C0-8C07-23F64FDB30E0,EdkiiPlatformLogoProtocolGuid 53CE1482-8B8D-4B24-888A-C2BDA19CF4A1,UefiToPublicWmiRouter +53D7E8EC-56F5-4F9C-8198-7BFB2ED4E05E,BootSectorWriteProtect +53DBDED9-C255-4908-847E-E191583AC7DC,UpdateFruSmbios 53E65F94-B418-4541-9A12-18839A56B427,Thc 53F019E9-BB0C-424B-870A-1FAF10B1CB4C,iFfsPei +53F5C473-46B5-45F3-8261-E4A59A9E755D,AmdPspPeiV2Stp 53F66425-21F2-45F3-99D5-ECAE1E21663A,H19TpmDetection 53FEBC13-C534-483E-8DA0-968E6FFD18D0,SecureBIOCameraSunplus 5402F0A2-7818-478B-8744-048AAE94BE0D,DellTpm20Dxe 540D61D0-C2D8-4E2E-8AD0-5C3D1B56CD4E,UpdateSmbiosEcVersion +54141B25-D623-42B8-A249-3C2BB739AC4C,DummyDriverDxe 541D5A75-95EE-43C7-9E5D-2394DC486249,AmiTseAdminPasswordValidGuid 54289C30-4D54-4BA4-8D06-1C6B9B2DC23D,CpPcHotkeyData 542D6248-4198-4960-9F59-2384646D63B4,AmiOpromPolicyProtocolGuid 543323CE-9F0C-4DDF-A33C-BC3B3A5AC227,SmmBmcElog 54357618-E106-406C-A5CE-AD7A1BA3CCCD,ExternalUsbPortConfigDxe 54360212-BD31-403B-A983-C5E472049E40,OneTimeFlagsPeiInit +5440D0DA-F426-45F7-BB50-B282212FDBAF,DellAmdCbsApcbUpdateSmmStp 5446C293-339B-47CD-B719-585DE39408CC,PostReport 544C6868-AA26-4B94-A43D-80A1BF4E65EF,DellErrorHandlerSmm 5466B9AA-EE2F-4FDB-84A3-A330BE1301FF,AmdHstiV2 @@ -3452,9 +3862,12 @@ 547957B2-D791-4CFF-8808-8024897B4D98,PLX8605PEI 5479662B-6AE4-49E8-A6BD-6DE4B625811F,KeyboardDxe 5479E09C-2E74-481B-89F8-B0172E388D1F,StartWatchDog +547C4CBE-BC2A-454D-AEE0-D29E487E0ACA,ErrorLogHookPoint 547C5CAE-2640-4ACF-9532-0E25B3F03F05,WheaDxe 5487F114-45E6-4D34-95E5-C7CF09E8AEA9,FjNvramVariablesAccessReferencePei 54891A9E-763E-4377-8841-8D5C90D88CDE,TerminalSrc +548A6718-6BC0-45A9-B4E9-6F63B0E1DD43,RtkUndiDxeClientron +549070BD-3FBD-47C9-B640-975C306F175D,AmdCpmDsdt 54913A6D-F4EE-4CDB-8475-74062BFCECF5,NvramMailboxAddressVariable 5493C51C-79C8-4C2E-9758-1DB5B52B13B7,DellSmmNbDockProtocol 54975633-0945-4D9C-97C2-E0CC6469A5A3,MeLibPei @@ -3462,9 +3875,11 @@ 54A3058D-8537-4A32-BDB0-4027BB688727,ITEAcPowerLossPei 54A85D82-3A54-4006-9C0E-E527295C4FA8,SetupLangService 54AAC64F-8A72-4093-8051-F4D23C5D2A4A,SbSocBixbyDxe +54AB2D48-8067-42A2-BAED-71F8E04FFE6D,BootDevTypeOrderInfoDxe 54AB7A17-AD08-4F86-83C2-4CF398EBC0AD,AsusPostErrDxe 54AFED50-5999-4594-9B79-F0AAA09FA32C,DashIoCfgDxe 54B070F3-9EB8-47CC-ADAF-39029C853CBB,NvramSmiDxe +54B0E2D1-F3EA-46D1-8DBA-367A347824EF,OemWakeOnLanPolicy 54B34347-C478-4865-8415-742E5155B204,UefiRestNetwork 54B6C2D3-79A9-400C-A3F6-D737CBEC6368,IioPlatformHooksPeim 54BD6A5D-38F2-44BD-84AB-108BE4F45914,DellChassisConfigDxe @@ -3474,6 +3889,7 @@ 54CE6010-2A6D-42AA-B1E2-FD97DE9C4DA8,AppleDebugSupportFireWireInit 54D2878F-25CD-4A2B-8420-EBD18E609C76,OemHookStatusCodeLibNull 54EA32CF-F34A-4ACA-951C-1203B7C51725,OemRgbLbDxe +54EB2B7F-0CC3-4E1B-B03D-E81756F642B9,GfxInitPei 54EEEF50-2EC0-45B8-80CA-9CB1AB819507,ApobRmbDxe 54FCC43E-AA89-4333-9A85-CDEA24051E9E,EfiSupplicantProtocolGuid 55025E9D-32E9-403B-81C1-F9E3D9D70640,AmdHsti @@ -3481,6 +3897,7 @@ 550303D2-F033-4468-857A-442C10E199E9,LenovoDriveEraseDxe 5504DF0C-F54D-465F-9200-F0383DBA1BC3,DualMeFlashExe 5507247A-846B-4F22-B55F-72B4049435EF,AmtLockKbd +55073147-BE8A-493D-8342-BDFC17E7F2BA,AmdNbioBaseRplPei 5507E3F0-9C84-47DC-8CEA-C29A01B7CD5D,SioBdsPlugin 550E42E1-B6FA-4E99-BBD9-1A901F001D7A,AmiVendorKeysNvGuid 552BA34F-949E-404D-B6E2-02BA73534307,PlatformRasConfigSmm @@ -3489,6 +3906,7 @@ 5542AB6E-501E-4D60-97DB-ED717584BD1E,DellTcg2EarlyDxe 5542CCE1-DF5C-4D1B-ABCA-364F77D399FB,EfiHiiCompatibilityProtocolGuid 55461099-28DE-4A16-B51E-D0D18A0793F9,CmosButtonLoadDefaultsDxe +5546A554-C246-46D6-97E1-2506D2D8B674,AmiUpdateBoardIdHob 5552575A-7E00-4D61-A3A4-F7547351B49E,SmmBaseRuntime 55538D1E-B4C5-4BD5-B594-9B5BA9774F1E,AodSetupDxe 555F76EA-785F-40D7-9174-153C43636C68,CirrusLogic5430Dxe @@ -3509,8 +3927,11 @@ 55B1D734-C5E1-49DB-9647-B16AFB0E305B,EfiHash2ProtocolGuid 55B71FB5-17C6-410E-B5BD-5FA2E3D4466B,EfiI2cBusConfigurationManagementProtocolGuid 55BB5A4B-3B3F-442C-BF09-0F87A67E8EE7,BindingsDxe +55BDA60B-1D0F-42D5-9F09-2D3D3067B899,EarlyDevices 55CF7CCE-051F-42C3-9CA9-20DB5CAD9AE4,AmiEventLogsHiiHandle +55D2C031-C1DB-4FD4-AC8C-C7EBE54E3E1D,DxeGraphicsOutput 55D460DB-8FEA-415A-B95D-70145AE0675C,DxePrintLibPrint2Protocol +55E3774A-EB45-4FD2-AAAE-B7DEEB504A0E,Tcg2Pei 55E76644-78A5-4A82-A900-7126A5798892,HeciInit 55E86300-F0B2-44AA-A5A4-EAEECE2E983B,PlatformToDriverDxe 55F10D34-4F05-426A-9A72-613EA8544DE0,AmdCpmPmfBoardPeim @@ -3521,11 +3942,14 @@ 5604D863-BF24-439B-BBF6-636D72036E07,SpiUtil 560BF58A-1E0D-4D7E-953F-2980A261E031,EfiSioVariableGuid 560FE30A-760C-46FA-989A-206F48C17C80,UsbHubTuningDxe +561196F1-1234-4145-8893-8893A1F97D97,FjOnScreenKeyboardDxe +561230EC-E2A5-4E58-80C2-30486D9F8D62,RtkUndiDxe 5618EC3F-A4EF-4EED-8759-64EEB780B4BE,DellSetupD4Smm 561DE4F7-BC8E-4E9A-A741-3E0D1A735621,DeepSleepSmm 563413A6-9DD1-4B7F-9E7C-5536E92AA55A,UefiDriverAsix 5639867A-8C8E-408D-AC2F-4B61BDC0BBBB,EfiBluetoothAttributeServiceBindingProtocolGuid 563C75D2-045D-43FD-A7C0-A472B0AD0255,gear6 +563E434B-6EDA-40DC-9123-A0FA0166EB4C,FjGpioAlderLakePei 563F8EDE-1FA5-45A2-BE23-B0B6A07DE239,DramPolicyPpiGuid 563FAFF1-EC71-4EB8-9E6E-60BF1447E285,FlashUcAcmSmm 5640497F-645E-4611-B915-E682C8BD4783,AsrockClockGenDxe @@ -3540,7 +3964,7 @@ 5678DBEB-6702-44DA-8C0C-60942AC1F980,Ps2KbdPei 56966690-24E8-4DFA-BEA8-BFCD83DA44B8,MultiPdtDxe 56AA1233-7407-4058-9E17-88DE138EA15D,AmdCcxZen3CznDxe -56B70419-7103-4D0E-83F4-F3546BD21E40,EzFileBrowser +56B70419-7103-4D0E-83F4-F3546BD21E40,EzFileExplorerLite 56BBC314-B442-4D5A-BA5C-D842DAFDBB24,PlatformInitAdvancedPreMem 56BD294C-4488-4B6D-A637-EAF159B43BED,OpromUpdateDxeCLX64L 56BF094C-69F6-49DD-8C1C-1ECEFF71C9E5,CsmRt32 @@ -3562,12 +3986,15 @@ 571A2DDE-E141-4D73-927D-85F5A7BB187E,AmiTcgLibDxe 571D1ED1-C2D9-418E-953A-248EBC687048,DellIdeSmm 572528F4-9BC6-41BD-9D14-5AAD93464A51,NationalPC8374L +5726C43B-C1E0-4735-8049-5110EDF2851C,AmdSocFp8PhxPei 57292E63-5BD0-4787-AC14-43E6B0A1515B,OememSmi 5733EBA8-492D-46FA-AA6A-379779E10B77,EfiMpstSupportProtocol +57354F58-C310-4884-AB1C-D770510BA7D6,FanTuningPei 573A445F-4FB6-C2D3-2CC0-5B9C772CFB94,AmdRasSspApeiDxe 5740766A-718E-4DC0-9935-C36F7D3F884F,DefaultdbxFile 575B08F4-A946-4341-B46A-765CC9F04644,PCIeIdm 575DFB6F-4009-495F-B23E-A6A084CEA57B,Int40InterfaceSmm +57651554-BE8F-4546-80C6-36323D52935A,AmdPlatformRasRsDxe 5774B56B-40B5-4FD6-98F7-D4D27C86CA49,FjGenericItemProtectedStorageDxe 577D959C-E967-4546-8620-C778FAE5DA05,EfiDebuggerConfigurationProtocolGuid 5785E965-8357-48A1-AC12-CAF77A35FC72,PlatformStatusCodeHandlerSmm @@ -3576,6 +4003,7 @@ 578C315A-68CF-4E81-B5C6-22DB40D010BC,EfiI2cMasterProtocolGuid 578C3195-D8C1-44F1-8A06-2B592FBE6AF3,TouchInputFilterDriver 578DC3C1-DFD2-4314-997F-F882CF50E5E7,FjEvteApp +578F70A0-066D-11ED-B939-0242AC120002,AmdMemStpSp6Dxe 579A7D1F-C166-4D0D-ADDB-B20B8B768B72,TmeInitDxe 579B3063-8114-4FCD-9DF1-0E4519AF7744,ShellResolution 57A13B87-133D-4BF3-BFF1-1BCAC7176CF1,EdkiiTcgPpi @@ -3586,28 +4014,39 @@ 57C295E7-4411-47FB-A176-68CE13ED449C,VideoIdm 57CE81B5-B995-4703-A42A-8774A353E5AA,AsusRunTimePaysBios 57D16189-7A07-4EFD-9701-5A19FE120E73,PermanentlyRemoval +57D21D52-3896-497C-9C20-B144BE7AD1CC,UnlockPei 57D55F85-C177-4A84-A2DD-8668E6F082E1,DellCipherSmm 57D59D87-A2A9-482C-8EC7-D9F9FA3E20F4,PlatformWmiAslSupport 57E56594-CE95-46AD-9531-3C49310CA7CE,Ofbd +57E9BE79-FA6E-4A83-A3EA-AB2B6678E4CA,ACPISxSMICore 57E9EEE9-EB7D-4453-BBF7-6C138BF06458,AmdCpmDisplayFeatureDxe 57E9EEE9-EB7D-4453-BBF7-6C181FD09027,AmdAgesaDxeDriver 57F435A8-1C37-4834-AD61-B03D94DDCEF3,DellPasswordMgrDxe +57F4434C-A01B-487F-A426-AC7BE1D79DA2,UefiHotkey 57F48613-300A-4101-A76D-4F73C533B5B8,PriorBootDxe 57F55732-CF55-43C7-B66B-216CE2282888,MonoStatusCodePei +57FDAAFB-DB48-4546-B73C-58428D8261B3,MtkSuppDxe +58014AAF-1C4A-4868-9042-58BCD1637054,FchProm21CbsPei 5802BCE4-EEEE-4E33-A130-EBAD27F0E439,MsegSmramGuid 58053681-13F3-47F6-B137-CDB3E888D9A4,ExtendedDataGuid +5808F44B-E501-467F-8899-670B9ADBD01C,RealtekLib 58094BEC-30FE-459A-B232-3A60D1C78C16,WheaErrorLogListener 58099949-C88B-4117-81A9-DB8949917CD8,SpdDxe 580DD900-385D-11D7-883A-00500473D4EB,Uhcd +58105900-9D9F-4F6E-8E0C-1F257113A3A6,ADLINK_ComHotCablePEI 5810798A-ED30-4080-8DD7-B9667A748C02,HashInstanceLibSha256 581F20FE-3C59-46EB-8D9F-47E6D38A1C3B,IsvtCheckpointDxe 5820DE98-FC8E-4B0B-A4B9-0A940D162A7E,SioDevStatusVar 5820EEB4-C135-4854-9D2A-AA9EFC4475E9,MeFwDowngrade 5821A154-1E3C-4EC0-92C9-2A66AB2FF186,FjNuvotonNct6796Smm 58279C2D-FB19-466E-B42E-CD437016DC25,AmiTseDriverHealthCtrl +58293BDD-1E0C-42C6-8376-61F049F77A97,AmdPspAspt +58295EC1-2EFF-4D01-A31C-67C42D6B3862,FDUpdateSMM 582BB1AF-0A33-4644-898D-94FC89C838F3,HwmThermalDxe +583CF04B-42E3-4638-AA22-02E4D3330A61,MacToUUID 5848FD2D-D6AF-474B-8275-95DDE70AE823,SmramCpuDataHeaderGuid 584CC99F-4BE8-43D1-A45A-933DC39479FC,AmiPeiNbCustomPpiGuid +5853694A-467F-4464-BBF9-0C971A74CB36,L05UefiDriveIdentificationDxe 5859CB76-6BEF-468A-BE2D-B3DD1A27F012,EfiUsbPolicyProtocolGuid 586032E3-1386-4ECC-B547-EB285E21066D,AmiAgesaPei 587743EC-B505-4E9F-9F2B-3DF703D7B1D4,KEMrWdtSci @@ -3624,10 +4063,12 @@ 58A30313-70D7-4201-8212-995765B3527F,DriveOptionSwitch 58A6FDE2-F873-468B-8989-DB4DE5E06CE9,HddSecurityErase 58A90A52-929F-44F8-AC35-A7E1AB18AC91,FPVARBAK +58AD4172-08AB-4AB4-99E6-8AA2F2B354DE,AdlSioFunctionPei 58B35361-8922-41BC-B313-EF7ED9ADFDF7,SecMigrationPei 58B8E0BC-05A5-4015-A47B-774A50346C1E,CompalSsidSvidDxeSetting 58B8E0FE-15B8-4915-A47B-774A50346211,ProjectHookDxe 58B9CFCD-7BEA-43EE-AEE2-896AC2E0D6C4,AdapterWarningsDxe +58BB9C75-D7E1-46AA-9F80-7B176F3B404B,AmdMemSmbiosV2StxLpd5Pei 58C518B1-76F3-11D4-BCEA-0080C73C8881,EfiWinNtThunkProtocolGuid 58C9681A-6956-41FA-B0AA-A3246D880E9A,DellWmiSmm 58CAD20D-D51F-B385-7F84-E829CA2F7C3A,EcGpioControl2Smm @@ -3639,6 +4080,8 @@ 58E81D7C-4D7F-4C6F-AAE6-32A99F25FD17,DellPsidDxe 58E8A611-AB19-47DC-9850-3985DE8DF1FD,PsmiMapHobGuid 58EB25EE-FBCB-419D-B9DD-12C38FFFBF0D,WlanControllerPei +58EE5E10-D0CF-4071-B1D7-980236E71412,GnbPhoenixRouting +58EE5E10-D0CF-4071-B1D7-980236E71E4E,GnbRaphaelRouting 590915CC-8622-4D61-BE64-C33EE760141F,DellSmBiosSmmDriver 590A0D26-06E5-4D20-8A82-59EA1B34982D,UniversalPayloadSmbiosTable 5917EF16-F723-4BB9-A64B-D8C532F4D8B5,EfiUserCredentialClassHandprintGuid @@ -3648,7 +4091,9 @@ 59223FC7-AAD9-4358-AD1A-ADB4B25BFEF9,I2cTouchHidDxe 59242DD8-E7CF-4979-B60E-A6067E2A185F,LegacyRegion 5924BE03-9DD8-4BAB-808F-C21CABFE0B4B,DellErrorHandlerPei +592626DA-4A1E-8B39-28BA-FEAD92C4A0A4,RedfishHostInterfaceDxe 59287178-59B2-49CA-BC63-532B12EA2C53,PchSmbusSmm +592AB072-3987-4DB3-86B0-EBD8D43E4B76,AmdFabricRsPei 59324945-EC44-4C0D-B1CD-9DB139DF070C,EfiIScsiInitiatorNameProtocolGuid 59378206-861B-4380-A349-2F2F4F030C4B,DashBiosManagerSmm 594AC308-8819-4284-B661-B7570881CC0F,RfSecureBoot @@ -3665,6 +4110,8 @@ 59B042E7-04A7-4D18-967A-8D31E3F34E8C,BiosConnectIqIntegrationDxe 59B90A53-461B-4C50-A79F-A32773C319AE,IdeBusSrc 59C2B0BD-BC73-4428-AA7F-8EE98DEFB2C3,AmdNbioBaseRmbPei +59C341BB-28BF-4867-9951-DA479E349D52,MTKSuppGen2 +59C34225-6FD4-4212-88F7-8845F2459DCE,FjPcieClkControl 59C5679B-08CB-4A53-B2AD-8CFD8359EEC5,OemACPIDriverDxe 59CFEAD5-DEEC-4F47-B9A5-222C25633283,FjGabiFlashDescriptorSmmProtocol 59D02FCD-9233-4D34-BCFE-87CA81D3DDA7,EfiGenericElogProtocol @@ -3673,10 +4120,14 @@ 59DBE71F-7508-49D3-9008-08FF60F47B82,WOLPlatformPortingSmm 59DFF742-7858-42B0-8D5B-12C2AD003D6C,MrcOemHooksPpi 59EAD3A3-A920-4A80-9298-AA7B235647AF,PeiMeConfig +59EDB77D-5397-4127-8A58-81D7B4132471,AmdPspPeiV2StxKrk 5A05F81C-C465-4C6F-9246-BFCC37534B88,BatteryInfo 5A0B785F-C5CD-4905-9274-868737A59388,IrstRemap 5A0EF9DD-A808-457D-8655-5C17BAF919C8,HpUsbControlDxe +5A112448-0523-4621-B96C-CF32F6AEF3A4,MemoryStorageKernelSmm +5A18C536-DB68-4154-908D-0E1D53BE8247,VariableStorageSelectorSmm 5A235B65-4BA0-4A97-89A2-C127DEA193A2,AsusOnBoardDimm +5A35A163-1B41-4396-A776-9A1FC51426F4,SyncSetup 5A35F091-B3E4-4DA7-BA74-C9303D3577F9,FjPowerButtonDxe 5A38B969-CD6A-4814-82E6-559F840BBC58,ISPDxe 5A3F3BD1-B7A6-404B-A0F7-285E1B898B00,DiskControllerSmbios @@ -3699,6 +4150,7 @@ 5AD75102-5B4C-44A9-A7D6-DA925BBC49A5,EhciSmm 5AD83885-8955-499B-8E9A-EBC24B6E76B1,AmdNbioSmuV9Dxe 5ADAB7F5-4AE8-FBB8-8F44-8CB7D8EBBF2F,CpuTechSmm +5ADE106C-10ED-4C66-8E16-86C4E52EC47A,FjRealtekLanDriver 5AE0C053-C2B3-4E7D-ADD9-FD3CEBC6D3D9,SlotDataUpdateDxeLightningRidgeEXRP 5AE3F37E-4EAE-41AE-8240-35465B5E81EB,CORE_DXE 5AEA42B5-31E1-4515-BC31-B8D5257565A6,EfiExtendedSalBaseIoServicesProtocolGuid @@ -3724,13 +4176,16 @@ 5B6DAB96-195D-4D24-9727-A7D0E93665C6,IconSD 5B6DBCBC-85F4-4BFC-AF96-188581325C42,AmdLegacyInterrupt 5B6F7107-BB3C-4660-92CD-542690280BBD,BootDiscoveryPolicyMgrFormset +5B74570A-03B1-4F5E-8ADB-FB7BB194D7CC,NVMeInfoSmm 5B74C741-4A5F-4A8E-B689-D804AB4368FD,DxeRealtekCrcInit +5B7CC220-E183-481C-87F4-27A92D8DB88F,SiInitPreMemFsp 5B7DF90B-2B93-4493-ABAA-4805BF008AEA,HpDmarSetup 5B85965C-455D-4CC6-9C4C-7F086967D2B0,PKeyFileSha256Guid 5B862868-7474-4CF2-81A1-9FCA12FEB5B0,FjSiidSmm 5B94E419-C795-414D-A0D4-B80A877BE5FE,FspSecCoreT 5B990069-AAF3-4CE8-93AE-533D0D30A56B,OemSSID 5BAB88BA-E0E2-4674-B6AD-B812F6881CD6,DxeVlvPlatformPolicyGuid +5BAC0CE8-902A-4482-9C26-F281C9388E33,FjNvramSmiSmm 5BAD89FF-B7E6-42C9-814A-CF2485D6E98A,EfiEventNotificationTypeNmiGuid 5BBA83E5-F027-4CA7-BFD0-16358CC9E123,IccOverClocking 5BBA83E6-F027-4CA7-BFD0-16358CC9E123,IntelIvbGopDriver @@ -3754,17 +4209,19 @@ 5C08E2E2-AD70-4C99-94A2-AE604EA033DA,IcnsConvert 5C0DFC5E-B4CB-4484-B768-260D7184FB58,AmdCcxZen4Smm 5C0F03D2-13C7-4C8C-B92E-2ECC692CA5C8,DfuMeFirmware -5C0FB3B9-F7BB-467B-A4DC-89D7D5A58432,ResLoader +5C0FB3B9-F7BB-467B-A4DC-89D7D5A58432,AsusResLoader 5C198761-16A8-4E69-972C-89D67954F81D,EfiDriverSupportedEfiVersionProtocolGuid 5C1997D7-8D45-4F21-AF3C-2206B8ED8BEC,PL061GpioDxe 5C19A130-A447-4DD8-BFD4-1CA7E2210A5C,FastbootDxe 5C1D737E-36D6-45B1-862C-6B9C244F4C07,PlatformStatusCodeHandlerDxe 5C266089-E103-4D43-9AB5-12D7095BE2AF,IntelSaGopDriver 5C284C81-B0AE-4E87-A322-B04C85624323,EfiEventNotificationTypeSei +5C2CD12E-E2F2-4276-A0F2-4A17832F774D,FchSmbusPei 5C337A89-C708-4B03-9485-C08BCA6FA8FA,SmmEntry64 5C3C5472-1ADC-44D8-93F5-78B31B950931,aModelName 5C3FF3EA-5E95-44AB-A042-F1CB952D0CE9,IntelRaidBiosThunk 5C403B01-8C30-4E68-96A0-55612F9C32B9,AsusEcDxeBs +5C43D50E-311D-4481-86E3-3842549EDC1C,AmdHotPlugRsSmm 5C44EAF7-FF0B-462E-87F4-2D46460BF48F,TraceHubStatusCodeHandlerSmm 5C476C6E-BB09-11E1-86A7-78E7D1AF36D1,HpNetworkTransferDriver 5C536A02-BDFE-4F47-BF72-18FF5DEAF8E9,FchSandstonePei @@ -3799,12 +4256,16 @@ 5D206DD3-516A-47DC-A1BC-6DA204AABE08,AmiOnboardRaidController 5D337D63-2677-4868-8251-B97C6D1F0E90,YukonEthernet 5D3D7AC4-BD45-4B01-B9DE-A58F4E3216CC,AmdCpmThunderboltMid +5D3D9BCB-B134-4CE0-B71A-AC6E65A75127,SioSsdtDxe 5D3F625B-A39D-410C-8D6A-9C31056406DE,ODMServiceDxe 5D44BE77-5669-41D0-B685-1BF3F83EFB98,DellPasswordUi 5D5450D7-990C-4180-A803-8E63F0608307,EfiSmmMpProtocol 5D6B38C8-5510-4458-B48D-9581CFA7B00D,EdkiiDeviceSecurityProtocol 5D7022B2-D3CF-4310-AC0A-4708DC4E5469,IioCxl2SsdtInstallDxe +5D71AF21-F162-4FAE-97A6-4C92CA8FC623,FchSmmDispatcher +5D724549-D2B1-4EB2-8263-AF5ABB12EB03,SamsungWa 5D744BC4-CA94-4F8A-9C50-EBC2A107303E,SerialIoUartDriver +5D751BCA-5A2D-BEC3-8B77-86F30CA893D3,PeiGraphicsOutput 5D758BFB-B323-4F6C-9017-A3238CE65163,LenovoSetupRestartDxe 5D7FE222-B0D3-400F-B092-5657623BD0BE,BootBlockProtectionDxe 5D8111C9-B4F9-46F3-9DDB-73A41AC696C5,password_capslock_indicator @@ -3818,18 +4279,23 @@ 5DAF50A5-EA81-4DE2-8F9B-CABDA9CF5C14,SecureBootConfigFormSetGuid 5DB12509-4550-4347-96B3-73C0FF6E869F,EfiRedfishDiscoverProtocol 5DB37E5C-2EEB-43F8-ADA0-243702D3945D,DellSioConfigDxe +5DB79943-DA75-415E-9282-74471AA2CFAA,CmosWarningPageUp 5DBA82CC-E80D-4478-A07D-394F362D3524,RasClvSddcProtocol 5DC03827-C9CB-4C83-B15F-6EAFBF86476C,AppleUartDxe 5DC2E5EB-352A-4BC9-85A6-F21B59067154,OEMComDxe 5DCFD448-794C-40E9-BDE4-4A923A9253F8,OemNvramDxe 5DD41324-E81E-4582-A45A-BF8E53A91548,OdmDxeGNVS +5DD4B7AD-C8D5-48C0-A506-7ED791EB1A8D,AmdFabricStxhSmm 5DEF82D2-6ED7-47DE-B0AC-11E55BAFFB05,LpcFlashLibNull +5DF4E4F9-9BCE-4C38-9D9C-8DFE61687AA5,UfsEraseDxe 5DF5A523-3036-4E1A-83E3-35D755EB4081,D01ODMWmiDxe 5DF9946D-8170-4FB5-854F-A98865F9878F,gear5 5DFAE03E-9C19-4996-85BF-65297BD4137F,PlatformVTdSampleDxe 5E0AD13C-014B-4921-9966-ACDEB04F3CC7,RemapIommuPei 5E1BB4F6-0D47-46F3-A18A-41EB400BD0F9,DellVirtRtcSmmProtocol +5E36941D-EBA5-4DD4-B6EE-D91C7A512290,AsusSmartHsioPei 5E3848D4-0DB5-4FC0-9729-3F353D4F879F,EfiLegacySpiSmmFlashProtocolGuid +5E3C397D-A1A8-4CE6-B058-3A2EB7EEDCDF,AmdSocSp6ShpDxe 5E4A8420-FEC0-40D3-98AE-C4CA45502B93,ODMDiagDxeProtocol 5E523CB4-D397-4986-87BD-A6DD8B22F455,AtaAtapiPassThruDxe 5E559C23-1FAA-4AE1-8D4A-C6CF026C766F,FirmwareIdGuid @@ -3840,12 +4306,15 @@ 5E794317-A07E-45DF-94BB-1C997D6232CA,AmiFwRecoveryCapsule 5E7A99D0-761F-4C26-8269-8571D85B0FEC,ICE30plusSMI 5E90A50D-6955-4A49-9032-DA3812F8E8E5,AmiSmbiosProtocolGuid +5E90F2AE-E938-48F4-87F9-5A219E68DFD0,AmdNbioPei 5E90FA7C-9F13-4C4A-96A7-C115FF568798,LenovoVariableStorePei 5E93C847-456D-40B3-A6B4-78B0C9CF7F20,EfiEapManagement2ProtocolGuid 5E948FE3-26D3-42B5-AF17-610287188DEC,EfiDiskInfoIdeInterfaceGuid 5E975522-176F-4E2D-BB25-64ADCC7792A4,BaseDebugDeviceLibNull +5E9AEA45-1101-4A6E-9905-CC13B6C96608,LogoDxe 5E9CABA3-F2B1-497A-ADAC-24F575E9CDE9,TcgDxe 5E9E1E5A-D6BC-4AC6-A161-854B7BB5E10A,Realtek8153Lan +5E9F8130-8F37-4006-B224-DEA482383084,DashManagementDxe 5EA17ABD-7B30-441D-83AE-3B73C1564B42,PspS3Smm 5EA93CAF-A8DD-4400-9FF6-FE343BCAF308,AodSmmSsp 5EAD1D32-C38A-4508-8DCF-0B9918957A4C,AmdMemoryHobInfoPeim @@ -3853,8 +4322,10 @@ 5EC7E137-3FE2-441E-A336-F657268733A6,DeviceBlacklist 5EC9DF0F-9FB9-4CD5-9BAE-12872F032A6A,PeiIpmiUsb 5ECC77F9-AB79-4E0E-90D3-79C31B61B778,UsbMouseSmm +5ED1678F-B3F8-11E3-93B8-047D7B99E097,SmapiSmm 5EDA3123-0840-45F7-ADAB-13A655EF3BB7,DellAcpiConfig 5EDAE60B-A9B0-4246-91DC-E97A4E4ADB2E,Armani_PowerReportSmm +5EFDBD4A-64B1-4F21-8A53-A13E8740E6D7,FchYuntaiDsdt 5F035AFB-AB8D-460E-AC58-254B8939E15C,SystemBiosSelfHealingPremiumPei 5F03BA33-8C6B-4C24-AA2E-14A2657BD454,EfiUserCredentialClassSmartCardGuid 5F05B20F-4A56-C231-FA0B-A7B1F110041D,EfiRegexSyntaxTypePosixExtendedGuid @@ -3865,7 +4336,10 @@ 5F1B0D5B-DB44-4B81-A69D-553C591AF092,OCMR_DXE 5F2719E2-4235-44EB-B908-CF74CE26B343,OemManufactureModeDxe 5F439A0B-45D8-4682-A4F4-F0576B513441,EfiSmmCpuIoGuid +5F46BBF3-DF4B-4794-826A-29217E631412,GnbSocPhoenixPei +5F46BBF3-DF4B-4794-826A-29217E63794F,GnbSocRaphaelPei 5F4735F7-DCF9-40FD-8858-026F931942A9,DxeIchInit +5F4B7803-A45D-450A-9105-A1A259C2D363,TPMHwPresentShp 5F53F1DE-E647-425D-8B59-2DDEE19E8C76,SecureBootMgrDxe 5F56DA51-6E43-435E-A167-FA4415E8E6B8,FjGabiCoreDxeBin 5F59B483-73A4-4507-AC11-A1D26EFA187B,SmbiosProcessorDxe @@ -3880,11 +4354,13 @@ 5F7CE43D-565A-4420-B4F8-22ECA7245755,AmiDbrFileGuid 5F7D4E0E-3D6D-42BC-A942-0E91E83E3C31,EfiPeiTcgLogHobGuid 5F82BC22-85E1-489D-93A1-42BBD664B434,IioCfgUpdateDxeLightningRidgeEXECB1 +5F8504C4-BCAA-4600-B435-347EEC6B5E14,MmioSerialUart0 5F864C8D-F2AE-4221-B8CA-F64ECFB0ACA7,OemDebug 5F87BA17-957D-433D-9E15-C0E7C8798899,AmiDigitalSignatureProtocolGuid 5FAC7360-D4F2-4C9E-A7ED-F2595E670889,SctIsaHcProtocolGuid 5FAD2389-2BC7-4BD2-83D3-429FB6AEA33F,EfiSerialPortTokenSpaceGuid 5FB81FA3-BF65-43AD-A47B-DF70C3112B5A,SvSmmHandler +5FC093B3-9400-4D36-B34F-4EEB07AA65D4,PciDxeInit 5FC364AD-4D63-4B80-B10C-0C8780ADA917,XhciSmiDispatcher 5FC8EEE0-9BF2-498F-B4D3-C51ED4C87BB4,LenovoSetupConfigDxe 5FCD1B11-2981-4EB8-8E03-4A0B5448DF5B,HpRemoteDiagnosticsDriverWmiSmm @@ -3899,17 +4375,21 @@ 5FF75356-3EBD-4589-B8BB-FEE7A372E3F3,XnoteBatteryStatusDisplay 5FF80B57-7F8F-48AC-A1DD-207414F503DB,WakeOnLanPei 60002AF3-DC95-4253-88AD-8BD876D83750,DellMfgModeSmm +6000589A-DA4A-44A4-ABE3-4329B098207A,AmdSocFp11StxhDxe 6010BEA0-A051-408D-9A6E-B744D468A05D,WinCapsuleUpdate 601211DC-0B12-4C09-AE27-AB0EC9692468,EfiTxtInfoProtocol 602160C7-E080-4AFE-BE4A-BB5D9B87042D,AcpiTableDxe 60319E22-7547-4BC6-B393-FBA7409F4E25,OemReadyToBoot 603445BC-975D-44A5-FFFF-FFFFB9465403,XnoteSetupAdvancedDxe 60400EBE-52A3-46CF-A322-E21C4718FA88,AaeonEcDxe +60445AE7-B5B2-482F-8672-B51018C95BC7,FjGpioGHOSmm 6046E678-24EF-4005-BA39-BDA11F6D555D,AmtInt16_csm 6048B8EC-6D17-45C0-9BCF-63D164B41AB3,LanRom +6056677A-1288-477D-B7C1-0708CD98A71E,AsusCheckDmi 605CED2C-583B-4171-9311-AA6E146B1A4B,I2cMasterDxe 605E41B8-E923-47CC-87B1-A6E38526E78D,SmbiosCompatiInfo 605EA650-C65C-42E1-BA80-91A52AB618C6,EfiEndOfPeiSignalPpiGuid +605EC241-85E0-4760-A5D2-0D02448FD468,Tca9548aPei 6069277B-246B-45D5-BD6D-81820E10C11F,CommonSmiCallBackSmm 606C2668-E9A4-46E7-A06B-3B9B7EE15CA0,OemPxeBoot 60707C56-8B72-435B-AB8F-251C9C0D2A34,BiosAuditLogSetupDxe @@ -3931,9 +4411,14 @@ 60B27E1A-D65E-4DB0-B2BB-C16FA71E44AB,PdmWindowSpinGuid 60B5E939-0FCF-4227-BA83-6BBED45BC0E3,EfiBootStateGuid 60B751F7-43B9-4238-8819-6B862B68C889,PhPlatformDxe +60B9DA4F-993D-411D-B43A-08B41E7BEC24,AsrockAmdSetupDxeMts 60BCD5C8-76F7-45AF-A541-C813EB86B635,AmdCpmWirelessButtonHidDxe 60C79D40-74FA-4DC4-A654-14C32E2E217C,FjFirmwareOnlineUpdate +60C83BC9-89FB-48D5-8962-A5DCE1D4C0FE,PostMessageDxe +60CDBBE2-3951-42D8-A963-8638A002E3B5,SetupUtilitySilicon2 60DC3885-9DCF-498C-9A32-DADB6AFA99A0,ErrorCodeHandlerDxe +60DE9928-47DD-4516-BAFB-34FA8F74A5D3,AppAuthenticationDxe +60E7BCDC-9ED0-40E7-A9E3-99404CFBD4B2,AlarmLEDBeeper 60EBDAA4-1565-4D9A-99C8-88DFA65549A5,DellFlashScreenDxe 60EC7720-512B-4490-9FD1-A336769AE01F,SmmControlPei 60EDA97E-3631-40A4-85D4-4A28065086B8,AcerWMI @@ -3942,6 +4427,7 @@ 6107BE23-5BAA-4FC9-8FC9-F2AEA77B07A7,FireWireOhci 6107EF7B-D384-4A24-BC9B-5FEF731F6A5B,IsaUartDxe 6108476E-4C45-4EC0-A7F2-5C2B3170EB71,WlanSupplicantDriver +610CDB96-7E56-44CA-BFF4-7D9B6000D87B,EventLogDxe 611114F1-A37B-4468-A436-5BDDA16AA240,EdkiiHttpCallbackProtocol 61141CA0-1444-4C4E-A16D-B601E0A09466,LenovoSystemKbcInitDxe 61187967-9A77-419D-AAEA-64DD56190815,AmiPeiSbOemPlatformPolicyOverridePpi @@ -3979,7 +4465,9 @@ 61DD33EA-421F-4CC0-8929-FFEEA9A1A261,EdkiiPeiAtaAhciHostControllerPpi 61EC04FC-48E6-D813-25C9-8DAA44750B12,EfiPlatformMemory2ErrorSectionGuid 61ED3D94-30D8-408C-97DF-DEDF2740F630,AmtLockPbtn +61F0BA73-93A9-419D-BD69-ADE3C5D5217B,CbsSetupDxeSTX 61F2DAE7-75D0-4EF2-AEE0-939CC3285ED8,AsusSeupItemControllBin +61F3D1BE-542E-4894-B3DA-2143C20B04CA,AsusSecurityJumperDxe 61F6E81A-7BBA-4A7F-B9F2-B0A3B5D461C5,DellFileExplorerDxe 61FE34BB-92EB-49BD-9151-4DB9184B9A6C,FjRuntimeServicesTableSmm 6200BFA9-8529-4DF0-AD67-7DA8DF6B0A4A,FjSystemIdentifierDxe @@ -3988,6 +4476,7 @@ 62197EF0-7B7E-11E2-B92A-0800200C9A66,BootOptionsPkgList 621D9B95-166A-432B-982D-2D4EEC7875A6,UncoreMiscDxe 621DE6C6-0F5E-4EE3-A102-0BDE769A0AD4,LenovoRemoteConfigUpdateDxe +62265FF8-A0BC-46A8-947E-67FEC0D7907B,AmdAcpiHmatService 62327151-AFC3-4187-89DD-788F0F16B6D5,MiscConfigPei 62331B78-D8D0-4C8C-8CCB-D27DFE32DB9B,EfiLegacySpiSmmControllerProtocolGuid 62408AD5-4EAC-432B-AB9B-C4B85BFAED02,DxeIpmiLibIpmiProtocol @@ -3995,10 +4484,12 @@ 62512C92-63C4-4D80-82B1-C1A4DC4480E5,EfiMiscProducer 62547EAC-2878-4342-BB6E-B60F1E0DD3F1,NCT7802YPeiInit 62652B53-79D9-4CF2-B5AA-AD99810A7F17,EfiHpIoxAccess +62674376-D362-45B3-9A6B-0E0D4098CADA,EmbeddedPowerButtonDxe 626967C7-071B-4D9A-9D0C-F112CF0836E9,EfiCrystalRidge 6269CF63-0737-46BF-80AD-9A035F76127E,PowerFailureRecoverySmm 626D93DB-2C42-48C3-915A-71F968A81B04,FmpDxe 627EE2DA-3BF9-439B-929F-2E0E6E9DBA62,BootScriptSmmPrivateDataGuid +627FBCC3-41F0-4378-99B6-533DCE8850A0,SmbusPei 62835C96-19B8-4D6D-BE13-3AA184784344,SbSocStarshipSp3Pei 62864A34-4733-4DC8-9CC3-F86EDD0B3276,ThunderboltSmm 628A497D-2BF6-4264-8741-069DBD3399D6,ConSplitter @@ -4022,7 +4513,10 @@ 62FC1B9A-8851-4654-90AD-CEA8C07FE259,IchSpi 63017E66-D790-4EE6-A0AC-6192AA74ACF7,UCR 6302D008-7F9B-4F30-87AC-60C9FEF5DA4E,EfiShellProtocolGuid +630972DF-8AB5-4A51-9A88-5DCEE225CC70,BootOrderSmm 630AEB10-2106-4234-9DB3-836A3663F50D,BaseCacheAsRamLibNull +630EAF59-9E9E-4515-9F0D-45D556BCAC1A,GetEdid +630FBB44-65DE-43BD-B503-8DE5914536B5,FchProm21GpioPei 6317D53B-0771-42B9-B6A8-D06FDC2DAE96,FjWirelessLanSmm 631B4DF7-BAEA-4C1F-A061-5B6462652822,DellDiagsDxe 63220A49-7909-44D6-A6D0-F3634CC921A6,OemPei @@ -4035,6 +4529,8 @@ 63438C6E-971C-4E40-8F0B-1109457BE333,LenovoCpuInitPhnxDxe 634DF746-6F4B-4684-93E6-526653E7C35A,OemThermalPolicy 634E8DB5-C432-43BE-A653-9CA2922CC458,Nvme +6362004D-B2A3-44E1-AF2F-E860E5BD572E,CbsSetupSmmBRH +63722DE5-EC4A-4237-953F-5502246776B2,EventLogSmm 6372357A-06D7-43EF-B55C-1964F3DD6916,DxeIpmiInitialize 637E0BA6-C5BB-41B7-A23B-3A65CFC3E9DB,BatteryState5 637EB153-DB4A-42F1-9101-AAA0FE3EE156,FjVgaSmm @@ -4056,6 +4552,7 @@ 63B5AF02-29C8-47A1-90FB-55D331FE4791,AmdHotPlugSspSmm 63B6E435-32BC-49C6-81BD-B7A1A0FE1A6C,PeiSmbusPolicyPpiGuid 63B93CAD-EB6D-4418-9C6D-98702F3D5262,Win7BootModeFeatureByte +63C2637F-F476-4D48-96C5-FF0BD01147AB,PasswordMeasurementDxe 63C4785A-CA34-4012-A3C8-0B6A324F5546,EfiRngAlgorithmX9313DesGuid 63C64ECE-DA83-479D-B382-F4939072C80D,DellGraphicsDrv 63CBCC47-65BA-4C19-9FC0-0AD81C9DB818,SleepStateSmi @@ -4075,6 +4572,9 @@ 642237C7-35D4-472D-8365-12E0CCF27A22,BootMaintFormSetGuid 6426C814-601A-4116-9E9F-BF9D6F8F254F,DellFlashUpdateDxe 642CD590-8059-4C0A-A958-C5EC07D23C4B,EfiPlatformToDriverConfigurationProtocolGuid +64302048-7006-49C4-AF0A-5ACE61257437,ConfigRouting +64376478-47EA-49E7-AEFF-D763F84729F9,dGpuDetect +6439C273-09B3-43CB-B25E-C675F5BCC73D,AmdMemBrhSp5Pei 643B8786-B417-48D2-8F5E-7819931CAED8,PeiInMemory 643DB325-A252-4BD5-B563-CEA73D64ADA8,FjSystemDataFvDriverDxe 643DF777-F312-42ED-81CC-1B1F57E18AD6,PchSmbusArpDisabled @@ -4082,14 +4582,19 @@ 645462F4-AF50-4FC5-838F-1DFBE3225511,UsbCdcNcm 6456ED61-3579-41C9-8A26-0A0BD62B78FC,Ip4IScsiConfigGuid 6467DB88-3E72-4488-91E8-7E028AD08CF8,DellIntrusionDetectPei +6470A429-20F8-4F17-A8C7-00EAEC19FD0B,FchEspiCmdPei 64730D93-E45B-4AF1-91B3-75B52ECBFAE9,MrdMultiBoardSupport 6483998C-9638-4C72-BD1A-77C55C5CEE8C,OSDSMIfunctionSmm 648CE07B-AE5D-4973-BD3C-8C9153C05DC5,SgInfoHob +6490F1C5-EBCC-4665-8892-0075B9BB49B7,CpuDxe 64980BB9-7BA3-4CB0-AA83-FE396A7F6724,UbaMainPeim 64A11188-5B86-4F59-A702-73365896E65E,AcpiVTD 64A892DC-5561-4536-92C7-799BFC183355,EfiIsaAcpiProtocolGuid 64AAEAE0-92DF-4980-8668-6EB5EAAF4393,FvInfoPei 64AF2828-82FD-49B7-BBD9-7B02BAB72CD5,DellEDiagsSmm +64AFC5D0-1DDF-4724-BE8F-ECECC0468E77,AmdNbioSmm +64BEA199-7C6C-4F51-B0DA-F42C897DA5CC,SetupDataParser +64C0771F-0901-471E-BE1F-CB7DADDFB247,DxeTAC 64C475EF-344B-492C-93AD-AB9EB4395004,EfiCompatibleMemoryTestedProtocol 64C96700-6B4C-480C-A3E1-B8BDE8F602B2,AmiPeiAfterMrcGuid 64CB24DF-A67F-5212-BB5F-ABE151768BB6,PowerLedSmm @@ -4106,14 +4611,17 @@ 652B38A9-77F4-453F-89D5-E7BDC352FC53,PeiUsbHostControllerPpiGuid 652EC62A-DC15-4B73-B6BD-DAA13BF1D88C,Cf9ResetSmm 652FC80A-684E-40B6-86AC-710148E2C540,ObjMgr +6537C422-DC1A-4ABB-9D25-EAAFE3D3DFCD,AMDPhxGenericGop 6540F933-425F-464B-B4AD-B93A6ED0A8F5,OcInit 65468E65-77F3-40AA-A149-32F223B0A3BA,ControllerDiscoveryPei 654A4AC8-30B0-4361-92C5-72D1F32A589D,TypeCPostWmiMessages +654CE064-776B-4759-98F5-AB0EDF692D0E,AmdPspDxeV2Stp 654FE61A-2EDA-4749-A76A-56ED7ADE1CBE,CmosPei 654FE61B-2EDB-4740-A76B-56ED7ADE1CBF,PowerLossFun 654FE61C-2EDC-4741-A76C-56ED7ADE1CB0,RTCSingleWakeUpInPei 65530BC7-A359-410F-B010-5AADC7EC2B62,EfiTcp4ProtocolGuid 655B0D2F-BCF1-4B1E-9A6A-A2E891BB50E4,BiosGuardFirmwareVersionPeim +655E4407-C79C-42B7-BE2C-9E1A266B08A3,AmdFabricRsSmm 655E4C19-9D7B-4491-AD10-A49FF355C00A,FastBootOptionBds 65639144-D492-4328-A498-F4B5545E4A30,IffsPartitionStatusProtocol 65675786-ACCA-4B11-8AB7-F843AA2A8BEA,WdtHob @@ -4122,11 +4630,15 @@ 656F7E22-5701-4341-A9A7-99A5D40A5245,AmdFabricSspDxe 6572045F-B1BF-458E-BC02-706762C609AE,EfiHeciSmmRuntimeProtocolGuid 657417C6-3C37-4C7C-907A-72C9EF34F802,FjEcDxe +6579AF18-92A2-415D-81D8-8B8FD867B42E,AmdSocSp5BrhPei +657F02D5-969B-402F-ABAE-E3B354D721D9,WifiProfileSyncDxe +65838FDF-F450-4394-B4CC-43953E72943D,FjDashCtrlDrv 658D56F0-4364-4721-B70E-732DDC8A2771,TrustedDeviceSetupApp 658DE942-03CE-43A3-891D-46423C5345BC,DellMfgSmm 6595CA83-8D11-4BA5-BDD1-92879864D320,PiSmmCpuDxeSmm 65986603-43BC-4ABF-94D8-5A58847381A6,SiliconPolicyDxe 659CD151-CA74-47AC-80DF-055F35BDBF4B,ControllerDiscoverySmm +659E9707-D2D6-4A66-9E38-4E840B3245C5,OemAfterSmbiosDxe 65A18235-5096-4032-8C63-214F0249CE8D,BaseMemoryLibSse2 65A72030-B02E-4BF3-8424-BA5F2FC56DE7,LenovoSetupUnderOsSmm 65E5746E-9C14-467D-B5B3-932A66D59F79,XhciPei @@ -4152,8 +4664,11 @@ 665E3FF5-46CC-11D4-9A38-0090273FC14D,EfiWatchdogTimerArchProtocolGuid 665E3FF6-46CC-11D4-9A38-0090273FC14D,EfiBdsArchProtocolGuid 66633083-3F16-43B2-8ED2-801A2EDC3824,DashBiosManagerDxe +666C5BD6-FD14-45A8-A639-E382A7E1BAA2,OemNVMEGen5 666E8FFF-F937-41A7-AF2F-F72B790DEB8C,SmbiosDataUpdateDxeXPV +6672D686-98C0-4585-9C15-9469AD4DBBD1,DHCP_vProPei 667A8B1C-9C97-4B2A-AE7E-568772FE45F3,BaseResetSystemLibNull +667C65FD-F778-44EB-ABBE-A5497AF8A85F,PciLegacy 667DD791-C6B3-4C27-8A6B-0F8E722DEB41,EfiEventNotificationTypeDmarGuid 667EF084-74EF-4707-90B3-75145920B39C,EfiPeiBootInNonS3ModePpi 6683D10C-CF6E-4914-B5B4-AB8ED7370ED7,AmiValidBootImageCertTblGuid @@ -4169,17 +4684,21 @@ 6699390B-DD2B-432F-BEB2-8C7D6A2C0CFC,HpPlatformPeiServices 669A9747-A65E-4F39-8FD6-9557573BC9DA,DellSystemIdPolicy 66A06013-AEBC-4A1F-A01A-AA3A74F98836,HeciAccessSmm +66A5851D-661E-4904-85D4-0A6608805CBD,OemEepromLanDisable 66BC00DC-8557-4FC1-9BEC-137760E27E96,RasClvMirrorFailoverProtocol 66BE3B16-4E6C-4BF6-A4E8-F879B8ACF16D,DellSecurityAuditDisplayConfig 66BF079F-2A14-47ED-A0F2-90CAF356E088,ASM108XPEI 66C36996-C62E-4D13-BF9A-756E66B01A3D,StoreRestoreMbrDefaultsAndWmi +66CEB16A-66DD-40A7-AAFF-0A9B9F83FD6B,WwanReadySettingDxe 66D54351-4C4B-4470-9599-F17A32752871,AplRecoveryPei 66DE8584-DE01-4BAB-B5D0-8B99594372FC,IchUhciPei +66DECFBB-345C-4892-9C92-D07C70DBC817,AmdFwConfigSmm 66DFDAC0-AA71-434E-8BE7-6A959B42C3A9,OemAmt 66E6C2E4-0245-4545-8165-12322480AF31,AdvancedPmaxDxe 66ED4721-3C98-4D3E-81E3-D03DD39A7254,EfiUdp6ServiceBindingProtocolGuid 66EECF40-6312-4A1A-A83A-B3B2F8D8A71A,LenovoVariableDxe 66F0C42D-0D0E-4C23-93C0-2D5295DC5E21,BiosGuardHob +66F831AD-FCCC-4221-B11C-7F4F4802B690,CbsBaseDxeSTX 66F8B964-A3F1-497B-B228-26B89EC3BDCA,AmdDrtmControlPei 67056139-CE96-4688-B7E7-73803EA528FA,ConfigChangePromptDxe 6707536E-46AF-42D3-8F6C-15F2F202C234,MXMdat @@ -4189,6 +4708,7 @@ 67269263-0AF1-45DD-93C8-299921D0E1E9,SmbiosUpdateDataProtocolGuid 672A0C68-2BF0-46F9-93C3-C4E7DC0FA555,UsbCredentialProvider 67329203-BAA6-49CA-B3C2-3784EB517017,KvmPlatformDxe +67375F4E-29AE-433F-9C2A-29EE6C7F5F2A,EmulationEDIDPEI 6737934B-A27E-4C05-AD5B-6AB86273680B,AmiNbMrcInfo 6737F69B-B8CC-45BC-9327-CCF5EEF70CDE,AmiPlatformIdeProtocolGuid 674177F0-730F-4EB9-A269-9C5F285230D8,DellUsbBusDxe @@ -4205,7 +4725,9 @@ 67820532-7613-4DD3-9ED7-3D9BE3A7DA63,Aint13 67856945-C6BF-476A-925D-EBD1CD2EAE11,KEMrJtagDxe 6789A9E8-6FE9-4E1C-90F9-59329ED27300,AmdFabricRmbDxe +6799D91E-0311-41F0-99AF-F162B9EC93CE,ProcessVideoOpromDxe 679AEE8A-CE51-4CCB-9AF8-90E055B3933E,NvmeRecoveryPei +679E3A98-341D-464F-8D78-3CE744F0BEB7,FchYuntaiSsdt 67A54A24-3F4F-4048-8787-3E5AA2A0B7D2,SAPolicy 67AC0B1E-54C2-41A6-B57E-C2A321416ABC,ActiveBios2 67AFDE5F-EF16-47B8-BA19-C21B3907DBF1,MiscGaIoSmm @@ -4219,15 +4741,19 @@ 67C63A11-F89D-4500-8270-D9DB251EB2AF,Ps2KeyboardPei 67CA9132-4415-4815-B2E0-DBDF68787871,OemMedinaEC 67CDD184-C0D9-4358-B376-330BF67D01AD,HpCommonFlashInfoSmm +67D1C54D-B8F7-4D69-A8F3-FF9116C4C02A,FchKunlunMultiFchSmm 67D6F4CD-D6B8-4573-BF4A-DE5E252D61AE,EfiJsonCapsuleId +67DB1E5C-EE66-48FD-A4B5-E9BD16EAFDF6,SmmAccessPei 67EE3885-80D7-4494-A5FD-445527E23F0E,FirmwareRollbackProtectionDynamicUpdate 67EF7A73-2594-4A5E-930A-E166FABCD2C8,EfiDmiFormatFru 67F8444F-8743-48F1-A328-1EAAB8736080,EfiCertRsa2048Sha1Guid 67FA951E-4FA2-9F4E-A658-4DBD954AC22E,HpSmbiosDxe 67FB408E-A519-40E9-8321-79F13FFDF9AF,RstResourcePei +680027A0-2FDF-4E07-B518-E3631685914D,HpStorageResetHookDxe 6806C45F-13C4-4274-B8A3-055EF641A060,DxeFileExplorerProtocol 6807217E-E8DE-42D0-91D9-60AECED7420D,Stall 68155128-AB86-437C-B235-4F860939A56C,TouchDriver +68198A68-D249-4826-BC5E-45DF0CCA2A53,EmuLinuxLoader 681D2368-4540-4FA9-8C1D-8B79DBF6B9AE,HybridGraphicDxe 681F3771-6F1D-42DE-9AA2-F82BBCDBC5F9,WinNtFlashMapPei 6820ABD4-A292-4817-9147-D91DC8C53542,EfiPlatformErrorHandlingProtocol @@ -4264,13 +4790,16 @@ 68BC3095-8839-4A97-8FEA-BEE06ECA7BBB,LenovoW25Q32FlashPartDxe 68D076CD-D8F3-409B-987F-1012CDB88242,SlotDataUpdateDxeLightningRidgeEXECB4 68D89864-C0A8-490D-BE18-C83D67240928,SmbiosDataUpdateDxeNeonCityFPGA +68EDC148-7120-41B4-9F53-F51BFC81A74E,CbsSetupSmmSTXH 68F0810C-1DDC-4407-BD65-872101407AB7,AmdCpmManageabilitySmm 68F19A73-C447-4FDD-B4B7-F380F7DD290F,FprGoodixDriver 69000FC4-15E6-45CF-A6D4-73337A9B5958,AmdCcxZenZpPei 69003CE2-F796-4EC4-AD17-B4D409298636,MctpSmbusSmm 69031D31-FC0A-4CEE-9803-F53015C4208D,RealtekGopLoader 6903A447-CB4F-45F6-89A2-7E7E2F9EE14C,InstallMsdm +69056653-3FC6-4382-90EC-B5FAF7599FD3,CnlHsioTuning 6906E93B-603B-4A0F-8692-832004AAF2DB,PchSmmPeriodicTimerControl +69110D87-9BB3-47FC-B412-22E4F135AE38,AmdCpmMemEyeToolDxe 69125D01-F951-47E9-9583-EF6A27AF703E,SpiAccessDxe 69282DF3-778F-4269-91AA-D7DF6E193317,Uc2OnUcThunk 6932FEBD-2397-462E-B0F9-EEB619FA693B,StatusReport @@ -4286,11 +4815,13 @@ 6973BC24-57F4-46B0-8766-C025ABB97AA4,NvmeShutdownNotificationDxe 697CFA95-B1F2-4ED7-A0D2-7AC6E47B3C99,HybridGraphicsDxe 697D81A2-CF18-4DC0-9E0D-06113B618A3F,EfiExtendedSalMpServicesProtocolGuid +697E6EE3-2EAF-41CC-AC6E-F4EFDFE93E6D,AsfMsg 697F0EA1-B630-4B93-9B08-EAFFC5D5FC45,FmpDxe 6983D90E-3EF7-4D09-8F36-63AE0C59CFF2,DellDiagSmm 6987936E-ED34-44DB-AE97-1FA5E4ED2116,HelloWorld 6988173D-B7C9-47BE-BDDF-255A18676913,UefiDriverPolicyDXE 698AC232-28A6-40EC-94AA-7D302DBF5667,PdrCapsule +699190BD-6456-4286-823C-28E4442DFCAB,AmdMpmPowerSupply 69967A8C-1159-4522-AA89-74CDC6E599A0,IdeSecurityPwnv 6996FC68-B040-4616-A89C-60B4C95D7BE6,ProjectDxePriori 699ADD70-8554-4993-83F6-D2CDC081DD85,SerialCapsuleGuid @@ -4298,6 +4829,7 @@ 69AA54B8-9795-4E7A-8689-64A96C9FE3E9,PeiGpioControl 69B792EA-39CE-402D-A2A6-F721DE351DFE,EdkiiSmmMemoryAttributeProtocol 69C5D214-F993-4C34-9011-A06787E5C956,FjSxEnterResumeDispatchSmm +69C5D5FB-FE8D-4336-BE00-582C621A23E3,AmdI2cConfigDxe 69CA132E-062C-4D7F-BE7F-9B0B8446C888,PhLegacyRegionSmm 69D13BF0-AF91-4D96-AA9F-2184C5CE3BC0,PlatformModuleTokenSpaceGuid 69DAB0B4-5FD9-4FEC-AA30-298D2B5A342E,DellFormBrowser3 @@ -4315,6 +4847,7 @@ 6A11F1A1-318B-4712-89C9-2DBF00995BE0,Cf9Reset 6A159D4F-6E6B-4523-AEB5-F7AF1C444B0F,EfiPprVariable 6A1EE763-D47A-43B4-AABE-EF1DE2AB56FC,EfiHiiPackageListProtocolGuid +6A30E568-598D-407A-A777-8AEE93BA2812,AmdPlatformRasBrhPei 6A3AEA11-2CC2-4B66-B4D3-A8779D6087C1,SystemSecureBiosPei 6A3DEF38-0A45-4107-A74E-ABF2B8EAED86,MemorySubClass 6A4B2718-CAF3-4D51-BD91-9EB1D6229F57,PasswordEncodeProtocol @@ -4325,14 +4858,18 @@ 6A79EBF1-BBB6-42A7-BDA1-5EACF52F2480,MotherBoardHealthDxe 6A7A5CFF-E8D9-4F70-BADA-75AB3025CE14,EfiComponentName2ProtocolGuid 6A7B1C86-590E-47A7-971A-C49B408D5ED7,LenovoSetupSecurityDxe +6A7FD3F4-53EE-4DEC-A1E5-69175B7FD581,CpuCrashLogAgent +6A8209ED-5D36-4906-A316-5541006F558E,OneKeyBatteryDxe 6A85825E-C459-4108-9B81-6602953468E4,FjGenericItemStorageSmm 6A8A395F-4C07-49D1-B94C-22ED50D425F8,LenovoSecureKeyDxe 6A8AC704-E589-4DD0-8EE0-31F87FBE3323,DxeTouchPanelInit +6A908656-35A0-4740-BE0F-4B364FB7945B,FchI3cConsumerSPD5Pei 6A969F3E-ED1F-41FE-A932-43994B05548F,SocWdtSmm 6A9839EE-070E-4B5F-8CCD-87BB12345F38,HddPasswordDxe 6A9D5926-EB27-473E-82E3-223B12CCAA12,FjGabiFlashCoreAbstractionDxe 6AA1A3CC-52C4-4B03-99F7-288F345C1DB3,DellAudioConfigDxe 6AB36EA4-CBF2-48DC-B610-9EBF193A5DEF,OemDisplayModePei +6AB58A31-4BD5-4CAC-8966-9A7FF01C000B,PlatformVTdSamplePei 6AC3044D-E062-4F23-A60B-286764DD09F5,DellSmbiosSmm 6AC5D123-C6E5-41BA-9BE3-A0371EE54B78,SetupConfigUpdateDxeNeonCityFPGA 6AD37609-A9F9-4587-9023-7820E10F5B7A,HiiLayoutPkgDxe @@ -4351,6 +4888,7 @@ 6B287864-759C-42C4-B435-A74AB694CD3B,SpecialBootStubDxe 6B309956-6617-472B-BBC7-2A09E55E3E52,ProgressBarFullLeftEndcap 6B30C738-A391-11D4-9A3B-0090273FC14D,EfiPlatformDriverOverrideProtocolGuid +6B35FEF5-022F-4596-8422-59AFA264C03A,WmiRmtApi 6B38F7B4-AD98-40E9-9093-ACA2B5A253C4,DiskIoDxe 6B41B553-A649-11D4-BD02-0080C73C8881,WinNtSerialIoDxe 6B4D57F0-6AB0-4A7D-BAB2-23425EF055E5,ICE30plusDXE @@ -4360,10 +4898,12 @@ 6B6D0A03-FD5D-4E10-9774-2D3EAA62EB61,SklRaidDriver 6B6FD380-2C55-42C6-98BF-CBBC5A9AA666,SocketSetup 6B7067C7-A843-A34C-9530-48446963B740,KeyMapLibNull +6B760600-8E5A-4945-AB9C-5732FA90A0B3,FjLanCapsuleDxe 6B789215-B063-45FD-868A-668A49F00EC6,TXTWrapperPei 6B844C5B-6B75-42CA-8E8E-1CB94412B59B,TcgPeiplatform 6B85F263-F584-44F8-BB5D-F02C40795D8E,SmmTcgStorageSec 6B8947C2-4287-4D91-8FE0-A381EA5B568F,rmHwA15Guid +6B8CE99C-9C68-41EC-B507-E03A143C7ED4,WirelessUndiLauncher 6B9FD3F7-16DF-45E8-BD39-B94A66541A5D,EdkiiPiSmmMemoryAttributesTableGuid 6BA22418-4704-4507-ADC4-364B8667E586,LoadSecureWipeImage 6BA6F808-527F-4186-9C30-670499BD92D1,DellSmmComputraceAcpiMode @@ -4389,12 +4929,15 @@ 6C289241-E240-483F-9E3E-872C0396B599,FlashSmiSmm 6C32B3FF-9F2C-44C5-A036-348A388C631B,PchIoExpander 6C33341C-BA4C-4DB4-9BD6-6356971DECEF,FjDisableManufacturingMode +6C3A7C66-3D26-4B1B-B803-2D801243BE29,AmdMbistRsPei 6C4077DF-8D80-6219-B80B-1F2573308D45,DellSecurityDxe 6C440404-5F74-44B8-CCE4-4B048830CCFC,LockLegacyResourcesDxe +6C4B1F2D-221D-4D86-AEE8-FD4CFABA879B,HQEepromDxe 6C50CDCB-7F46-4DCC-8DDD-D9F0A3C61128,EfiPpmGlobalNvsAreaProtocol 6C6872FE-56A9-4403-BB98-958D62DE87F1,UefiSerialPortInfo 6C77FAE1-A934-457A-982E-BCC12F9717AD,AmdPspIntrusionDetectionPei 6C79BA9B-5926-4295-A450-46B3401D95A5,AcpiPlatform1 +6C8E136F-D3E6-4131-AC32-4687CB4ABD27,FmpDxe 6C92CB60-08C1-4149-BF94-60B7C5206011,MAPS_WatchDogTimerDXE 6C9A8087-B68E-4F3D-B87D-A76C829C7D3E,CcgxDiscoverySmm 6C9AA1EC-286E-4A0A-AA98-E2E530626F4D,AmdiGpuVgaControlDxe @@ -4410,14 +4953,17 @@ 6CEC977B-142E-4EBA-ACBB-74D882B166CA,OemCustomDefaults 6CEE9C4A-E2A0-4F3D-A921-CE25F328C4BA,AsfSmm 6CF4D043-2D22-4FF0-AAB0-C5F932847400,SataDeviceFeatureDxe +6CF8600B-6B56-447D-AC08-05F8C3B00054,Tpm2ReservedNvIndexPei 6CFDBB02-DB4B-4C87-BE13-B4E79E68CE51,CbsBasePei 6CFF6068-4FD3-4779-95B8-4DFC90722371,PlatformVTdInfoSamplePei 6D000308-C913-40DB-AD40-B3094FB0F756,AmdCcxXvDxe 6D1D13B3-8874-4E92-AED5-22FC7C4F7391,BiosGuardDxe +6D1EAD71-0CEF-4B2A-B9AE-05D5E9B847CF,PasswordInterfaceCoreSmm 6D29159C-CC7A-4757-8185-42DDB2BECB89,CompalWSMTSmm 6D33944A-EC75-4855-A54D-809C75241F6C,BdsDxe 6D3569D4-85E5-4943-AE46-EE67A6E1AB5A,EfiTelnetServerProtocol 6D36ACC4-B9A1-474F-B333-071A56F3D4F4,AmdFabricRmbPei +6D39E536-4269-49FA-B7CD-25C35A4F8AD3,NvmeEraseDxe 6D3A727D-66C8-4D19-87E6-0215861490F3,EfiUnixSerialPort 6D3D1021-E7FC-42C2-B301-ECE9DB198287,SystemSpeakerPei 6D4849D1-DC04-4D57-BC90-2E0B5CFF1828,AmiPldmInterfaceBin @@ -4447,6 +4993,7 @@ 6DB075DE-449E-2644-96D0-CC5A1B4C3B2A,FirmwareVolumePei 6DB21643-241A-4CC9-82DD-46A1E4845ECC,StrongPasswordPoliciesSync 6DB6CF42-0A3C-4BC9-97DB-9CED03B7F18D,DellHotKeySmmProtocol +6DB72521-256A-4CC1-12DD-96A1E6699ECC,PowerEffcienfyPoliciesSync 6DB9486F-6AF6-4090-984D-238482CE3EA4,BdatAccessHandler 6DC01095-9001-4E4D-B852-AF429EADFF57,OemPowerMgmtDxe 6DCBD5ED-E82D-4C44-BDA1-7194199AD92A,EfiFmpCapsuleGuid @@ -4459,8 +5006,11 @@ 6E057ECF-FA99-4F39-95BC-59F9921D17E4,EdkiiSmmReadyToBootProtocolGuid 6E13B746-80DD-4EDC-B178-D25BD4838FBA,HwmThermalSmm 6E185705-E3AD-45EF-83C1-F1F9567AF396,DisconnectKbd +6E1C42D2-278F-4227-BEDE-548CF3206680,AmdMemoryHobInfoPeimBrh +6E27120A-A510-48AC-BD66-7083DA4D594F,CmosWarningPEI 6E2FFCF4-6899-414C-9B55-3A08842E650C,AppleIvyBridgeGop 6E32EAF6-32D1-43E0-B6E1-DCF6DA81DF76,LenovoN25Q064FlashPartSmm +6E36078B-6B6F-42BC-981E-4C639AFA4D6D,FmpDxe 6E448793-9CDF-4787-9392-4B6A6D5FFCA8,DellHwManagerDxe 6E5228F3-933E-4961-9573-0F1E61B522AC,LenovoSmbiosVpro 6E53E391-40FC-4539-9055-06469C50AFBC,AmiPciAccessCspBaseLibOverride @@ -4473,12 +5023,14 @@ 6E6E4A75-EF14-47FB-B43A-67EC43B87D22,SpiFlashProSmm 6E6EBC2D-77AB-46CF-B2A7-CC968B0E8AF3,mAmiTcgInterfaceVarGuid 6E6F05AC-234B-465B-9450-C36E6D7566C5,LenovoSystemIsaKbcDxe +6E6F55F6-8F74-4F71-8264-F11BA0581441,DashPldmBcc 6E7139CA-2B21-4168-9804-867FAF71F95D,BoardInitPei 6E7181AA-A835-47BE-9C49-0743354D2F5D,RecoveryPcdDataBase 6E72A82C-14A5-4F02-A377-4A423BB1817F,WindowsNameLabel 6E7CDEE1-414B-44C2-9D0C-BD2698F45982,WakeOnLanPortingDxe 6E7D90A7-9336-461C-8AE9-859C51A9A716,ReadyToBootNotifyDxe 6E851687-A7A9-4AA2-8DD0-673E03E51433,SetSockOpt +6E881000-5749-11E8-9BF0-8CDCD426C973,RedfishConfigHandlerDriver 6E8CD2B7-B636-4859-85ED-C637BDCA5919,DellDaServiceTag 6E900CF0-D596-43E1-B9F9-D9E0584CB207,DellFnUsbEmulationSmmProtocol 6E97D4F4-1898-4408-A62D-99CADED32FD8,DellDxeSbAcpi @@ -4497,6 +5049,7 @@ 6EE1B483-A9B8-4EAF-9AE1-3B28C5CFF36B,SkipTpmStartupGuid 6EEDE20E-8F32-4FE2-BEB7-7A00F3CCDBC3,OpromUpdateDxeLightningRidgeEXRP 6EFAC84F-0AB0-4747-81BE-855562590449,XenIoProtocolGuid +6EFF177D-E4EF-4E1D-8419-DB717231EB7D,OemThermalDptfSettings 6F0198AA-1F1D-426D-AE3E-39AB633FCC28,Cf9ResetDxe 6F052B94-59F5-4606-A017-06CBDC5C20BA,MctpSmbusSmm 6F0CF054-AE6A-418C-A7CE-3C7A7CD74EC0,LogoPcx @@ -4516,6 +5069,7 @@ 6F6F82F2-0D31-4319-8E31-CC722538E894,SystemVariableStoreManagerSmmRuntimeDxe 6F6FED5B-3741-4D4B-8AC7-C74914874A77,SbCrisis 6F71926E-60CE-428D-AA58-A3D9FB879429,IfConfig6 +6F7E5A78-6F5E-42F4-9C30-8E144182C5D6,ProjectHookPei 6F7E5A78-6F5E-42F4-9C30-8E144182D5F9,CompalCommonHookPei 6F7E88AD-C634-498A-84AF-CAEC526A3A51,AaeonModuleDxe 6F86764B-BBE4-49A1-A5D2-32E6A6861834,FchSmmDiagDispatcher @@ -4559,22 +5113,27 @@ 70456853-D70E-496C-B6B1-CF88A30BE1A9,AmdVersionPei 704EA695-F373-42D4-BF1B-44BB7F60C295,menu_bottom_left 704EBEA2-5EE6-4898-9659-018B74B44789,EfiSeCOperationProtocolGuid +7050210F-D434-4D76-B118-71DDFC6F4E43,OpalPasswordSmm 705D9A12-6281-4B05-BB64-C9FE38649CDF,SetupMenuDxe 7064F130-846E-4CE2-83C1-4BBCBCBF1AE5,AppleBootPolicy 706B0EFA-8768-44B6-8CB2-469B47A80C47,LenovoFidoCp 706C1E0C-44FC-4012-9B71-3DBFEC762F35,PlatformFlashSmm 70718A53-E05E-41A4-8420-378BEA75951F,ClickBiosUiSimple +7074566A-2F33-43D9-9C32-2DA17AE27BAD,BootDeviceInfoDxe 7076876E-80C2-4EE6-AAD2-28B349A6865B,EfiCertX509Sha384Guid 707B3C6E-99A6-4E17-84A0-40284C1B3F38,LenovoPiSaveStateAccess 707BE83E-0BF6-40A5-BE64-34C03AA0B8E2,EfiSmbusArpMapGuid 7081E22F-CAC6-4053-9468-675782CF88E5,EfiEventDxeDispatchGuid 70858A67-D4D5-4632-BF0E-D18E2C29C550,DTBTPEI +70943B04-3B8A-4F08-A412-F97C5B02F6BE,IntelPcieLanDxe 70995504-D7AA-4BBA-803A-A3A9C729A37E,DellSmmDpstProtocol 709E6472-1BCD-43BD-8B6B-CD2D6D08B967,AcpiAtd 70A4D159-1F01-4203-A598-7C2794151CE6,EfiOsBootOptionNames +70ADF2BD-D392-44FA-92E7-3884783343AF,SDPlatformInitSmm 70AEBF01-9EA0-48D8-AE17-3A184B12DBFE,TseDefaultBootOrder 70B0AF26-F847-4BB6-AAB9-CDE84FC61431,EdkiiIoMmuPpi 70B221AF-FDFF-4FDE-9968-1AF623A956D9,EfiI2cHostProtocolGuid +70B312BF-974B-4C6A-A70A-EE231B22958A,FjPowerButton_jp 70B4DE8C-3B01-4F0A-A2F3-93CEE977313E,EfiJedecNvDimm 70B8BACB-0B26-4048-A6F8-03A6AF2C5029,BootScriptHideSmm 70D57D67-7F05-494D-A014-B75D7345B700,StorageSecurityCommandDxe @@ -4604,12 +5163,16 @@ 71287108-BF58-41EA-B71C-B3622DEBCA9D,DellSmmSbGeneric 71298B1B-26AA-44D8-87CD-91A087C3481A,SmbiosDataUpdateDxeLightningRidgeEXECB3 712B5720-7D64-4F52-FFFF-FFFF9946CF56,PxeOnDemandDxe +71332179-AE93-469A-89C5-9EFF7A780D51,AsusWifiPublish 714845FE-F8B8-4B45-9AAE-708ECDDFCB77,ExFatDxe 7148E18C-703E-4F59-AC3D-3A923A0DAA50,OemDxeEcVer 7149FE42-011E-4E93-98D8-D24869B7031F,I2cMasterPeim 715783DE-BC09-46BC-AE7D-E39879591197,AmdCcxXvPei +7166543F-3E35-41A2-9118-577BBA62C693,AmdAgesaParameterGroupPei 716EF0D9-FF83-4F69-81E9-518BD39A8E70,EfiSdMmcPassThruProtocolGuid 716FB533-26BD-4BAC-9820-229BD5A7D300,FprGoodixMocPrometheusDriver +7171F76B-EDCD-4F00-A7E5-559F71B8A00D,AmdMemSh5Dxe +7172526E-F691-4B01-AE22-A19FCC35F651,FchTacomaDsdt 71761D37-32B2-45CD-A7D0-B0FEDD93E8CF,EfiDirectedIoDMArErrorSectionGuid 717886AB-C40A-44CF-9114-4119E84B0DC7,PciCfgOnPciCfg2Thunk 717A0EAA-9B18-461A-B6EC-AC09794CA631,LenovoSystemAcpiSupportDxe @@ -4617,8 +5180,11 @@ 7197C8A7-6559-4C93-93D5-8A84F988798B,PlatformBootManagerProtocol 71A19494-2AB6-4E96-8581-CF34254273FE,MeBiosPayloadDataProtocol 71A37E51-F3C8-4B99-B335-A661CA8AD13A,AmdCpmOemInitDxe +71A37E51-F3C8-4B99-B335-A661CA8AD33A,AmdIncompatiblePci +71A62895-1CD4-4B9A-A77B-571FD71BEFC9,OemAcpiDriver 71A8917B-0891-4E27-8A73-A9B334840393,AmiPeiBeforeMrcGuid 71A9EA61-5A35-4A5D-ACEF-9CF86D6D67E0,EdkiiPeiCapsuleOnDiskPpi +71AC8619-B70C-4974-9307-F646E73CCCFA,PlainPasswordTransfer 71B22C89-B849-4D83-8115-4563A626AC8D,KEMhGpioAccPei 71B8D01E-D764-4BC6-9D02-0007F8382F54,FjCmosAccessRt 71B8D0AC-ABA1-46B4-8D28-09C9FCA0158D,IwlMei @@ -4631,29 +5197,38 @@ 71EE5E94-65B9-45D5-821A-3A4D86CFE6BE,EfiUserCredentialProtocolGuid 71F3B066-936A-4C84-9228-23230FD47C79,ImagePasswordFill 71F7CA83-96C5-4742-BAA2-76B807A06B95,SctGopVbeBltBin +71F7D079-099F-4C15-8A84-C44A3629D181,SbSocBrhPei 71FAE25E-4427-4C48-B707-FC5BF2F6742E,RTKUndiDxe 71FD84CD-353B-464D-B7A4-6EA7B96995CB,NonDiscoverablePciDeviceDxe 71FE861A-5450-48B6-BFB0-B93522616F99,TPS65950 72002D05-2C57-48B4-B9DD-D2F19035A44B,HpDtSmm 720E6687-43C4-84EA-E1B5-23AAED359840,IntelGbeUndi +72120D23-40FF-4AB5-855C-C8C6DE9AAE54,FchSmmDiagDispatcher 72133706-A922-43F1-9C75-581D9AE8F666,AmdNbioSmuV9Pei 721ACF02-4D77-4C2A-B3DC-270B7BA9E4B0,FspNonVolatileStorageHobGuid 721C8B66-426C-4E86-8E99-3457C46AB0B9,SystemBiosSetupDxe 7223263E-035D-4495-81AE-7DDEBCD8616F,SystemAudioDeviceSmm 72234213-0FD7-48A1-A59F-B41BC107FBCD,ACPIOSFRVariableGuid 72234E22-8A17-4E30-AEC5-F3B3397E6691,SxCallback +722A7C2F-81B3-407A-98C7-CF9158CF904B,SiInitPreMemFsp 722E4818-344E-4421-88CD-491CB908C142,DellSetupCfgPolicies 7235C51C-0C80-4CAB-87AC-3B084A6304B1,OvmfPlatformConfigGuid 7238A672-755C-45E2-84C1-4C720CB2A8D1,EcCloseShmApi 72405B40-38DA-4ABA-9283-CA8321C23E63,FvReportPei +725FC6B0-984D-11E3-AD96-047D7B99E097,SetupMenuInterfaceCoreDxe 726205B4-2E4D-4606-998B-6B2A3E8858E4,DellWBootCapsuleProtocol +726A9E51-7B0E-4F77-9159-9239EB5DEA34,SioIt8659eDxe 72725F0E-5CD9-4997-8530-08D464C1FC46,XnoteCapsulePolicyDxe 72727297-BC14-4886-A642-617BC50A5265,IccInitDxe +7273772B-6DAA-4E2F-9063-6C95FDA931BF,AdlSemaPei 72748AA2-B149-4D14-8FF1-10F5836C8933,AmdSmmDriver 7279D04D-AAAE-994A-8A5C-5AEA41D1FE3A,AppleArpDxe 727F171D-99C0-42F7-8D1A-A61390AF5BB1,AbsoluteDxe +72896A9A-4A1A-46C3-A2EC-012DF5A89565,ClientronSmbiosDxe 728CAE6C-1FFC-449B-8681-BB2A621E0022,ContinueButtonSmall +72938FE7-5DC9-49B4-AAF0-2D23828A3190,DimmTypeDialogDxe 729B3079-8913-4E12-AFEF-2CA264799469,AmdAcpiDxe +72A71390-9AD6-4C1C-AE00-E050AF18A708,OemImageLanguage 72B11962-5759-4975-AE95-F8C3FE55EF1D,PchSmbusSmm 72B4CDB4-B297-4747-B1BA-5A4839D332AE,AmdFabricRnSmm 72BEE9DC-F9C8-4ACD-8D69-49C4E5BE6297,KEMhSDIO @@ -4671,13 +5246,16 @@ 7307BD0F-8B7A-4BA5-9AF6-3997D1E32786,AmdNbioSmuV10Pei 7310E28E-96EA-4360-946E-5ADC6BE8F531,DellSmmEcIoProtocol 7317BA01-C34C-4DE2-BB19-1AD8A612A1A4,FjVariableAccessServicesSmm +732B020D-DFDA-425D-9470-4BBF2F1B007C,DellQueryStdPcdValues 73303035-D6D0-46B5-8ECA-139EE287C000,RaidDriver +7338B21C-B7FF-4B81-9B50-0F2A71626C83,TouchPadDriver 733CBAC2-B23F-4B92-BC8E-FB01CE5907B7,FvbServicesRuntimeDxe 73400E57-A467-45AB-9F8C-D2519F76ABA4,DeviceFwServiceDxe 7348AD47-2E40-4846-B658-B9213469C130,DellEcPolicy2 734AA01D-95EC-45B7-A23A-2D86D8FDEBB6,AmiTcgStorageSecurityInitProtocol 734E8BE9-4801-4A31-A3FA-D61CCB601CA9,OptionRomPolicy 734F8167-996B-4C5D-BBA3-815A72167FF8,BFGDxe +735CE436-D125-41D2-A524-F6699B9709A0,AcpiDynamicPci 735F8C64-D696-44D0-BDF2-447FD05A5406,EmbeddedExternalDeviceProtocolGuid 73656701-D13A-47AB-B0EE-4849537CDFAC,SgxEarlyInitPeimSPR 736AC82E-4216-42F1-8EDE-91EC63D0EC43,FjSysmanSetupHooks @@ -4687,6 +5265,7 @@ 73852F31-9834-4EC7-97EE-41E584DC3C49,LEMComputraceApiSmm 7385DBBE-8050-4FAF-8B64-4C386E1FAA88,CodeAccessCheckS3Pei 738A9314-82C1-4592-8FF7-C1BDF1B20ED4,ShellTftpHiiGuid +738B84B5-1E84-4EB9-8EF8-95A167EA4AEE,NvidiaGraphicsDxe 738C6917-71F0-4D45-AB68-91744136AEEA,AppleIpAgent 738ECAE2-DBF9-4C00-A0F6-586F3A506139,FchMultiFchPei 73905351-EB4D-4637-A83B-D1BF6C1C48EB,TSEInvalidateBgrtStatusProtocolGuid @@ -4702,11 +5281,14 @@ 73CD248F-420B-4618-8F74-E15FF48258B5,AmdCpmAdaptiveS4Dxe 73D1D476-A7C9-4EFD-8F8B-D532EF381708,EfiPlatformTxtDeviceMemory 73DAB30F-3F9C-4160-B064-439CE16C3EDE,SystemBootManagerDxe +73DC6B53-A5CB-4605-97B9-0E83FDE59194,HQUcsiDriver 73DDB5E1-5FB4-4751-AF1E-83CF75BECBB6,EfiPeiConsplitAmiKeycodePpi 73E6F6B4-D029-4E87-8405-6067C8BD02A6,UsbPei 73E79970-4936-443B-B9A5-E0B61BC1288E,PlatformVTdSampleDxe 73E8D659-D2A2-4720-8316-B9BAD21E5A29,CbsBaseDxeRN 73E9457A-CEA1-4917-9A9C-9F1F0F0FD322,DebugPortDxe +73F19D89-1EA3-45B8-86A2-9E153947A034,SBURetimerFMP +73F3E50E-23C5-4586-BC6C-7E5223FA3C43,OemPortMappingPolicy 73F53712-2A64-4B86-961D-C25B63DF198C,AmdNbioIOMMURVDxe 73F70B77-943B-4090-99E8-4F8E4D824A43,wifi_none 73FA8DD2-589A-424C-82EB-2D360F09D900,HwmFanSmm @@ -4717,12 +5299,14 @@ 742F95A8-714A-5C43-88BA-B3361F12EEE6,BootRomFlash 74346897-9E0C-4B41-BF1F-BAA1ECB85DA6,IioCfgUpdateDxeLightningRidgeEXRP 74375386-DA3C-4FA2-BBA2-F53E37353422,AmdAcpConfigurationDxe +7449D85D-C41F-474D-A34B-DF839241ED4E,DellAnimationDxe 744C9DBD-74DE-424D-AB59-AA398305871F,EDIDParserDriver 744D080F-EDF3-4FF4-9870-A2DA5BA5F0E6,PlatformDefaultSettings 744EBDEA-F30A-4F13-A0B8-F7D7982A57DB,BiosPasswordDxe 7459A7D4-6533-4480-BBA7-79E25A4443C9,AmiTseDriverHealth 745D377A-B988-47B2-B18F-BBC80DC56698,EfiVirtualMemoryAccessProtocol 7462660F-1CBD-48DA-AD11-91717913831C,EfiPciOptionRomTableGuid +74627A28-DB74-4102-B2B2-F8D788AFFFEF,HpIcicleDefaultAndWmi 7465BA75-88A7-4B61-9A7E-6D4EDF6804DC,AmiUdfMediaGuid 7474A4C6-7F30-4DE1-BC68-DA5EFE615B52,SmbiosDataUpdateDxeNeonCityEPRP 748221BC-2BA9-1545-8AA9-A03A8591999E,AppleNetVolume @@ -4734,6 +5318,7 @@ 74AB5A17-82D7-472B-B2CC-22CB825844C4,FjDeviceInfoBaseDriver 74B3E9BF-A025-4D4E-B5B6-508F8B67085E,GetMemoryValue 74BD9FE0-8902-11E3-B9D3-F72238FC9A31,AndroidFastbootTransportProtocolGuid +74C4F1BE-FE72-4268-A685-C4CE71070401,AsusTestVersionHeader 74C83F3A-5EE3-4EB7-B945-702B839FB1A6,DxePlatform 74C85C25-09DD-497D-9F71-91C172283ED4,SioFanMapDxe 74CBEC3C-8190-42A0-9C02-D1C5ADC706D7,AppleAirport @@ -4744,22 +5329,28 @@ 74DB4ECD-3429-46D6-9BD3-88B50A8190A7,EcKeySmm 74DBE0FE-5621-4616-A978-8C1E239F191E,SmmMemoryManager 74DDF801-A7DC-4410-9DF8-C08E6D9FD6BB,FpgaCapsule +74E1B217-7CE5-432D-8C1B-0C216FADA7DF,ApobStxKrkPei 7502B5FB-33FC-42F0-A90C-A45E5B63449B,FjGpioCometLakePei 75032015-D156-423E-BFA3-7A65ABA47105,EfiI2cBusConfigurationManagementProtocolGuid 750890A6-7ACF-4F4F-81BD-B400C2BEA95A,AcpiModeEnable 750D5755-A0C9-42D3-A326-B5D465413523,AppleSEPDxe +750F8E5A-59BE-485B-A717-FD850FC8772B,FchKunlunMultiFchDxe +75153C93-7AD2-4452-8036-644AD4AAFF25,AsusPcieSsdUpdate 75189FA6-7BCF-4F4F-81BD-A4F1C3BEA95A,CptSwSmi 752F3136-4E16-4FDC-A22A-E5F46812F4CA,EfiShellParametersProtocolGuid 753630C9-FAE5-47A9-BBBF-88D621CD7282,SmmChildDispatcher 7537E889-FC63-42D2-B400-F7646C45CEE3,CastroCovePmicNvm +75472C94-6221-4CF2-9EC7-1462CB726B1B,AmdSocAm5PhxDxe 754AAF56-099B-440D-8DCD-626F4E2C52F4,RsaIScsiSupport 754BFF96-1234-4B41-B437-EF1B0C8CA155,KEMrPegConfigPei 755877A6-4F10-4A5C-9B2E-852123B9682C,FlashSmiDxe 755B6596-6896-4BA3-B3DD-1C629FD1EA88,AmiFlashProtocolGuid 755DFF82-93BE-4E9F-891F-955909D1EA19,RtkUndiDxeDriver +7565FA5B-101B-4493-9F27-1ECBD4BECC6C,AsusSetArmouryCrateField 7576CC89-8FA3-4CAD-BA02-6119B46ED44A,AmiSioSmmHandoffProtocolGuid 7578B307-B25B-44F9-892E-209B0E3993C6,Emul6064MsInputProtocolGuid 757DC0D7-EFFE-4C12-BC6F-D7E833EB9015,FjOA30Support +75816CA2-8FBD-439B-A120-C47FF86F0E29,BHInitDxe 7581D88A-F866-42C1-8683-26281938E5BF,RtkWifiSupDriver 75839B0B-0A99-4233-8AA4-3866F6CEF4B3,FpgaSocketVariable 7583C1FA-0BD6-447C-9E4E-397E1AE338B2,SystemSureBootPei @@ -4771,21 +5362,28 @@ 758AF8A7-2A04-4937-99E0-837D1F97C76F,LenovoSystemAcpiNumaDxe 75B0755B-B0D9-4205-BBF7-63289FFB8045,ProjectSmm 75B0886E-CD6A-469F-AE0B-8CED9033D199,EfiBpdtLibBp2DataGuid +75BA309D-5DFD-49BF-ACE8-28B39B52BDF7,CbsBasePeiRPL 75BE667C-48E1-452D-B0FC-363138ED87FF,PStateControl 75BFCE76-56F4-4FE1-B257-8B075E8F98A8,OemIp3SMI 75C024B9-C20C-4506-B85C-7C7356F0239B,AddonNetworkControlSmm +75C640C2-030E-4C57-81E2-532B1DD7339F,MemoryStorageKernelDxe 75C8F622-8090-4017-850C-3FA40B027984,SmcMemMapOut 75CA7C9D-502E-468A-9AAF-7F2A29E6DBCF,AmiSbHddPolicyProtocolGuid 75CE4288-DE5D-4E24-90B5-F75BD78E6BA1,SecureFirmwareVolumeDxe 75CF14AE-3441-49DC-AA10-BB35A7BA8BAB,EdkiiPlatformSpecificResetHandlerPpi +75D02D7A-5A2D-497A-9A4F-D7CE38EA1389,SDPreOSVariable 75E78806-C68F-4839-8A68-B29084820659,ExStatusCodeHandlerPei 75FBCDBA-28C4-455A-A71D-536C9AB65093,SmcSetupModify +75FC3BBA-72A4-61DA-4171-074C824223C1,DigistorWorkAround 76016A54-9959-495D-BB3E-BA35E25A51CB,SystemSetupMainDxe 7604B120-A55C-4A36-A9F6-420E5ADA995C,MpmAsfPei 760640DA-ECAC-4229-A591-7D3066EB242D,PldmImportBin 760A41FF-3619-4F01-B95F-A2E0E699D487,ServiceBodySmm +760E5D5F-9AD3-4055-B4C9-2F9F6E29CC2F,BiosLockDxe 760F874E-B8CB-405E-AA32-A46AE2F3D680,VariableDefaultUpdate 7612F7CE-C685-465A-91D4-D12F9E933383,SpiHcOperation +7627B2DE-4342-4DDA-A339-A96DAA057DDF,AsusMbSwWmiSmm +763EEAEB-FE2A-4778-BE0A-3842EF8610A8,BIOSLOCK 763F61A7-BCFD-4657-87B2-8DBCAD6425F9,DellOpalHddSecurityDxe 763FEE95-85A1-412E-9276-01BE8FAE6CE1,DellSetupASPMDxe 7644C181-FA6E-46DA-80CB-04B9904062E8,EfiPathFileName @@ -4802,6 +5400,10 @@ 76864548-0261-410E-A8B4-01615BFA3E0A,FwKeyHobPei 7687A497-FF4E-48FF-BCAA-67DBF65C42D1,AsrockBfgdxe 768BEDFD-7B4B-4C9F-B2FF-6377E3387243,NTFS +768BEDFD-7B4B-4C9F-B2FF-6377E3387651,OemGNVSDxe +768BEDFD-7B4B-4C9F-B2FF-6377E3387671,SmbusDxe +768BEDFD-7B4B-4C9F-B2FF-6377E3387691,SmbusSmm +768BEDFD-7B4B-4C9F-B2FF-6377E3387692,OemSmi 7692B160-3591-47AA-BDEE-655297662E76,UefiDMBMHooKInt13Protocol 769B1A29-C083-450A-8C96-D750FAF4530E,LenovoCertAuthDxe 76A1DF7D-754C-40E1-BC72-3FCAD842DEF6,DellDaEppid @@ -4809,11 +5411,13 @@ 76B6BDFA-2ACD-4462-9E3F-CB58C969D937,PerformanceProtocolGuid 76B75C23-FE4F-4E17-A2AD-1A653DBB494A,EfiExtendedSalLockServicesProtocol 76BE1ABF-1E1E-321D-B7F0-9E0984FDDABC,ProgressBar +76BE7979-4701-48EF-9E6C-44B9EF030923,GpioV2ControllerPei 76CA0AD8-4A14-4389-B7E5-FD88791762AD,FmpDxe 76CBE15D-3C00-4597-8F13-621D77E879E1,AmtSaveMebxConfig 76D1059D-2E22-40EF-A31F-C49DBBC0DBCE,SetupCheckSumPei 76D5CF91-0C55-434E-97C2-D2825C82E610,OemActivation3 76E1E9EE-5FC7-4613-B96F-FA797796573A,DellPbaMgrSmm +76EB2674-B3F2-4489-BB6D-E2448F7EF614,BiosSelfHealingPei 76ED6631-44FE-4ED2-8B5D-1B5355BB25E8,LogoDxe 76ED893A-B2F9-4C7D-A05F-1EA170ECF6CD,IntelGraphicsPeim 76F3992D-529E-4EFE-8BBE-8E1ED432C223,AmiMeasurePciopromGuid @@ -4824,6 +5428,7 @@ 7702A696-6521-4FE8-A786-528B4D86F5F1,DfciDevSettingsMgr 77085416-E137-44A0-89F3-0C7DA7F2F52A,OemNecTseEsaSwitch 77148690-7E43-4673-AFAE-34532CDD4248,SmmControlDxe +77165917-C00B-434B-BADC-A8FBFF437E7D,BeepExampleDxe 77197B37-A0FB-487C-9CDF-FC36179B73DE,DellStatusCodeHandlerDxe 7721929A-D56A-450D-2501-8EA51FA61974,SbCmos 772484B2-7482-4B91-9F9A-AD43F81C5881,EfiMiscSubClassGuid @@ -4831,28 +5436,35 @@ 773779CA-2AE8-4073-8BC5-43376A61BFD5,DellEcPolicy 7739F24C-93D7-11D4-9A3A-0090273FC14D,EfiHobListGuid 773CB08B-511A-4BD5-85AD-41D4F4B64A52,AmtSetupDxe +77447790-51B4-4A81-A8D2-7EF78E9F35C9,I2CSpeedDXE 77475D4F-7965-4038-B970-863FC73E0761,BSDP +7750576E-EBB3-454B-887C-6521B3CD34A5,AmdMemoryHobInfoPeim 77509744-7507-4B5C-BF6C-3BAB83652F4D,BctBaseSmmRV 7755CA7B-CA8F-43C5-889B-E1F59A93D575,IntelGopDriver 7758FA0F-2CAB-4684-949F-C20506339539,DellProfileManager 77617ECB-E229-4E20-B8F9-DF8245624D7A,SystemAcpiTableLoaderDxe +77651BCC-7262-484F-A74F-650821285D9D,BiosSelfHealingDxe 77786445-99AC-4C2E-9FF1-990965770530,NCT3933Smm 777BAA93-9260-421B-9173-FA62611B6188,HciPei 77892615-7C7A-4AEF-A320-2A0C15C44B95,BiosRegionLock +778E8993-0C45-41F7-976A-4C088855E6B6,AmdIspCamera 77A6009E-116E-464D-8EF8-B35201A022DD,DigitalThermalSensorSmm 77AB535A-45FC-624B-5560-F7B281D1F96E,EfiVirtualDiskGuid 77AED9BC-0938-4026-9D10-F6846027F366,ApobMdnDxe 77B35E10-AC21-4DFB-B094-DDA8878A6521,ASM1061Pei +77BC641D-582D-4B1C-BB79-594EDF3630EF,VTPCR7EventLog 77C0B0CB-0406-4868-AEB5-C36B01D42FF6,MemoryInitWrapper 77C2687E-975A-679C-BE44-2EF67868CEAC,IhisiRegister 77CB5A2E-59C8-490E-B69D-A3862BE5B3A0,EobonPriorityMap 77CC5D6F-E1A8-4ABA-8AE8-1D92DE3B50F1,OemNVME 77CF025D-D743-4DE5-AC39-AE4A591064B0,RestoreVariablesDxe 77D71582-4274-0EC5-36CD-65A2CC4FD663,DellWsmtEnforceSmm +77DE2CD5-67B8-4749-A8EF-7E26EFFC07AF,CbsSetupDxeBRH 77E5B618-2612-4C28-BCDF-A2B14D8A3EFE,IFlashDxe 77EB6C06-FD48-488B-A1B3-AE0A70801369,CryptoDXE 77EC5618-2101-4112-86B1-2F752AE10F1A,EcSecureFlashDxe 77ECCE3A-7398-4C04-981D-D778E793E0F9,TransferNvramPasswordToSmram +77F04055-3E04-4821-BEB0-B2AEE4983198,FchSongshanI3cPei 77FA9ABD-0359-4D32-BD60-28F4E78F784B,MicrosoftVendor 7807E404-8281-4FF1-8457-0B54BABE263F,HitachiH8s2113Dxe 7808F5C2-9CB0-4609-907F-B18453C363B4,DellStorageAgentsDxe @@ -4863,6 +5475,7 @@ 78259433-7B6D-4DB3-9AE8-36C4C2C3A17D,MeInfoSetup 78270D5E-9450-4FAE-8818-B91EA39864CD,ChipsetLibServicesSmm 7827D4B0-926E-48F9-8ABD-69816EF86D16,AppleDmgBootDxe +782C4946-0167-4C2B-949D-8DC4E53D25A7,FjUartModeSelection 782FD612-46F3-47A2-83D9-8FDB86E6FED1,FjGabiMiscAbstractionSmm 7833616E-AE0D-594F-870C-80E68682D587,ThunkProtocolList 783658A3-4172-4421-A299-E009079C0CB4,EfiLegacyBiosPlatformProtocolGuid @@ -4875,6 +5488,7 @@ 7872D787-4DAD-4496-BE61-EDB5B5F012E7,SpdDataReadPei 787D4843-68AC-4C28-BE53-BAC272BAECF9,DellVariable2RuntimeDxe 787E0C4A-4A27-4891-9489-AF5074C36E89,EfiTraceHubStatusCodeHandleHeaderPpi +78871234-8787-7878-A19B-0BE61B233187,DeviceWa 788B4AB1-294F-4FD4-BEB7-4F5E0709E9AC,DnAPartitionDxe 788DD6A1-F1EE-4BBA-A925-C0E7D66271BD,SystemBoardDxe 788E1D9F-1EAB-47D2-A2F3-78CAE87D6012,IdccDataHubGuid @@ -4882,6 +5496,7 @@ 78965B98-B0BF-449E-8B22-D2914E498A98,EfiSmmStandbyButtonDispatchProtocolGuid 78A6FB37-8F27-40A4-9C4E-9FC9E438D5E2,AmiTseOemPortingVar8 78AE4297-C10F-4D77-B6EC-521F34BF06F8,SmbiosDataUpdateDxeEldorado +78AF76C7-8A5C-420F-8DE6-12678D101590,TrackPointElan 78B55289-5393-4A3A-834A-111AD7726970,DellIoExpanderPca9555Smm 78B9EC8B-C000-46C5-AC93-24A0C1BB00CE,PwdCredentialProviderGuid 78BE11C4-EE44-4A22-9F05-03852EC5C978,EfiKmsFormatMd2128Guid @@ -4897,10 +5512,12 @@ 78EB25EE-F78B-419D-B0DD-12C38FFFBF1D,DeepPei 78EF0A56-1CF0-4535-B5DA-F6FD2F405A11,FmpDxe 78FFCA55-4869-4393-BEE9-72E58BD3BE38,SystemFixedBusNumbersDxe +7901F717-FE24-4C8B-87AD-C05F35660747,OemIp3Smi 790217BD-BECF-485B-9170-5FF711318B27,EfiHiiRestStyleFormset 7907C558-4C57-480E-9439-7F6684852920,DellMeLocalFwUpdateDxe_ME130 7914C493-F439-4C6C-AB23-7F72150E72D4,ImageAppleLogo 79263F9A-1701-4382-98C2-573F3558E6C8,PlatformFvbLibNull +792930B0-7B29-4ECD-8B0C-65D62644C343,CbsSetupSmmSTX 7929D36E-968A-4A4B-87CE-2375B1C7311D,DxePortingSample 792F0DE4-ECB7-4EA9-B25E-A531FBA36809,H19AesEncryptPswd 7934156D-CFCE-460E-92F5-A07909A59ECA,BiosGuardModule @@ -4924,6 +5541,7 @@ 79AB769C-E959-4B09-9718-80A896012C28,DellNetworkTransferDriver 79AC2D9C-9216-43C5-A074-0B45C76422C1,SmmRedirElogProtocol 79B26A82-5C07-4AAA-A8F3-8AD195D271A2,SetupConfigUpdateDxeFischerLakeRP +79BA7128-D5EF-4B41-912C-5F80DC9E1B24,AmdMemoryHobInfoPeimRs 79C3AC4A-DEC6-48F1-AFFE-E7B95A1CCB32,PoofAnimationState2 79C5C7B7-1083-42A6-AD15-2A4E7C4274D7,DxeSmmDriverEntryPoint 79CA4208-BBA1-4A9A-8456-E1E66A81484E,Legacy8259 @@ -4948,6 +5566,7 @@ 7A08CB98-E9BC-41C3-BE19-B302F3F1F595,Terminal 7A1CC2C0-7AF6-4F68-A564-CC03558FC3C5,SuperMDxe 7A2099C9-9AF8-4FE5-9812-BBC352762EF5,HpSioComPortWAPei +7A2634E5-4DB0-4E01-AB8B-B833E5F25AF1,FlashControllerNvsDxe 7A28436A-E113-406A-AFF9-0DBF7F643E02,EfiTcgPrivateInterfaceGuid 7A2A4270-38BA-45C6-B53C-C83B342D5B15,TisPei 7A345DCA-0C26-4F2A-A89A-57C08DDD22EE,NvVariableInfo @@ -4963,7 +5582,9 @@ 7A627E16-679D-4814-8F82-EEAF3881F098,BatteryState6 7A699129-DAA0-4224-8629-7338DE5D45ED,TpmDriver 7A6CA3B8-EE1B-489C-B300-24544A7BD418,ShellCTestApp +7A6DF3DB-1C0A-45C2-8251-AFE794D7D6B3,PciExpressPciCfg2 7A7F24EB-426C-476F-AE54-09A23A9E04C1,FjIbvAbstractionSmm +7A8406BD-E03C-4DAD-B532-E3CCED635CC5,AmdI2cTouchPanelDxe 7A9354D9-0468-444A-81CE-0BF617D890DF,EfiFirmwareFileSystemGuid 7A97840A-F3F6-49EC-928A-36D90A76D6A5,RecoveryFchInitPei 7A9A372D-3487-402E-B489-5FC551A43BD1,X11DPHDxeDriver @@ -4978,13 +5599,17 @@ 7ABBC454-F737-4322-931C-B1BB62A01D6F,BootMonFs 7ABCFE4A-F5D2-413A-9828-259E6B128DC9,LcfcWorkaroundMfgDoneDxe 7ABEC993-53D6-464F-8371-FFAFD97F3928,AmiCryptoPkgTokenSpace +7AC954F0-4FBB-4D9C-A2BF-E8A5922E6F30,AmdNbioPei 7AD33249-4BC9-4D31-9855-06D3A8C052A0,WlanControllerSmm 7AD9BAE7-864D-4F7E-9D11-1CAD8018FE7A,LenovoTpmFwUpdateSmm +7ADA185E-7E10-4F7C-B2DA-26E99102C88D,AmdCpmDiscreteUSB4Dxe +7ADAF482-ECE1-42C1-8FB0-BF8955340696,AmdMemSmbiosV2BrhPei 7ADBAD98-7FE1-4774-9260-747327435E6D,SpsAcpiHooks 7AE1026D-C7FA-4867-9C14-A00534A6C547,DMIRecovery 7AE3CEB7-2EE2-48FA-AA49-3510BC83CABF,PeiSeCPlatformPolicyPpiGuid 7AF77F94-4C38-4FF1-8CCD-3E084F2FFEC0,SkylakeGraphics 7AFFD257-51D0-439A-A89A-85A3419308E4,DellJSONParserDriver +7B04A674-8EF3-443E-999D-D62508BD3A3E,PldmImportBinShp 7B05F6C6-B8E3-4007-9F81-68E3773D6E20,LEMPasswordStoreProtocol 7B07D184-02D0-4BFD-AD6E-554C39353A13,LenovoSysConfigReqDxe 7B0E51C3-46FF-4D6C-AA5D-61DB3F44F50E,EcMemMappingPei @@ -5008,6 +5633,7 @@ 7B8DAD98-4B25-438A-BC31-F6CC931D5BB4,PlatformInitRecoveryPei 7B8DB049-C7C7-4D3B-809F-926DEE47CCA2,SBSMI 7B8EE7A1-4E35-4556-BB56-6797E24445C2,PeiCpuPlatformPolicyPpi +7B8F8199-42C7-DB87-307E-2892F3849538,AmdCpmOemInitPeim 7B9937AE-092E-4D5F-8BBD-87BB14162F38,SerialPortSettingDxe 7B9A0A12-42F8-4D4C-82B6-32F0CA1953F4,AmiBoardInfoFileGuid 7B9BE2E0-E28A-4197-AD3E-32F062F9462C,AddressBasedMirror @@ -5023,6 +5649,7 @@ 7BCB37D2-D280-453D-BC91-E1E4E6208A70,KEMhSmbEfi 7BD19958-CF71-48DD-953C-640505C52D4A,DellMultiFuncDevDxe 7BD7AB9F-DB9F-455D-8566-387B2F13D404,UsbPwrCtrlPei +7BD9DDF7-8B83-488E-AEC9-24C78610289C,VirtioFsDxe 7BE725B2-F56C-41C7-9F03-1E7B56B65971,SystemUsbMemoryManagerDxe 7BEEEF98-3028-4260-96F1-BEEBA31A787C,OemSioResChangePei 7BF3F3C8-4FCA-49A7-804F-9033D2E47841,AmdNbioBaseZPPei @@ -5031,6 +5658,7 @@ 7BF9BE38-9B8D-4D62-AD06-6805BEED9852,FjFlexIoDetectionViaI2C 7C03567F-C840-4E9C-BFCC-652793C2FBFB,DpfServicesDxe 7C04A583-9E3E-4F1C-AD65-E05268D0B4D1,FullShell +7C05C4AC-68F5-4526-BD10-7FABAF822369,semaInit 7C069ADA-DE4E-488C-B0FC-4F2E057D96D8,DUFontDriver 7C095EED-C8DE-49BD-90D4-6C9A3A3BE9C3,DellRmtPlatSiSmm 7C0C91D4-63DF-4AB4-AD2E-B01C6DF3E07B,OemStandaloneDxe @@ -5043,11 +5671,13 @@ 7C2E2D27-E8BD-4F5C-A569-AF65B77AA55D,DellPttSetupDxe 7C2E3F7B-A17A-4070-AE83-13FF416F62B2,MsiBoardNvs 7C347F9B-6FAE-45A5-906E-F8DFEBEE64FF,DellWmiSecurityMgr +7C365CF5-19B7-48F2-80F5-0A3267F69FEA,SmiSecurityVerify 7C380900-1B96-4615-978E-89E02E2C89D0,DebugDriverDxe 7C46C6A4-362F-4964-AF20-9333E552DCC3,PciHotPlug 7C4BC2E3-7C7E-43D5-AEBF-FF57810AC2DA,AsusWmiAtkDxeCore 7C5A8EE9-7EC5-443C-A867-3549B667EEA6,WakeOnLanPortingPei 7C604CBD-5440-46E1-97F7-A4DF8DD09C1C,AmdSmmControl +7C69E035-60D9-4782-AAAA-B05F2F8C1B09,PeiReportStatusConOut 7C79AC8C-5E6C-4E3D-BA6F-C260EE7C172E,SmmRuntime 7C81C66A-4F11-47AB-82D3-67C4D635AED1,LegacyMebxLaunch 7C820E3D-C3F7-42C1-A022-7FE434A87DFB,FvNetworkDxe @@ -5055,6 +5685,7 @@ 7C8BDE83-9E3E-4F1C-AD65-E05268D0B4D1,RealtekUndi 7C96D656-6B21-45A7-84D8-5068EEE1D415,MAPS_SmartFanDxe 7C9A98F8-2B2B-4027-8F16-F7D277D58025,IntelBootGuardKeyManifest +7C9AAA66-0D1A-4A23-BEA3-25195F6BC22C,FchKunlunMultiFchPei 7C9E5A63-B987-435E-B17F-9E9CFA53F880,SmmPlatform 7C9FE380-CFD2-4BF0-9B96-E5DF40635ECB,RealtekGopDriver 7CA1024F-EB17-11E5-9DBA-28D2447C4829,TlsAuthConfigDxe @@ -5066,12 +5697,14 @@ 7CBDCA19-4776-A997-7CA7-56D5343F2904,EarlyOneTimeFlags 7CC1567C-CCB8-4C50-80BA-D44A3B667415,AmdSb800_PeiInterfacePei 7CC1667C-CCB8-4C50-80BA-D44A3B667415,SbInterfacePei +7CC6C4D7-A271-4FDD-B29C-AD561CB3FF4C,WtCardReaderDxe 7CC7ED80-9A68-4781-80E4-DA1699105AFE,EfiLightIsaIoProtocol 7CCA3104-2A1D-4E84-9C7C-44B97A234012,HpSioSecurityPei 7CCAD11A-EFA4-4F82-BDE7-7D07FF90B280,BootOrderWmi 7CCB2D7E-CD15-417E-A5C8-003DA6325B9F,PowerStateManager 7CD73063-546E-4C09-ABD2-11C6B04ACC4E,SataPowerManagementSmm 7CE247D8-A588-40EC-B311-F820800EFA02,H19FingerprintVendorDriver +7CE501E6-4BBB-478B-9B41-5FA66A36042A,AmdRasBrhServiceDxe 7CE700F9-BB44-4157-9655-DCCC39432C1C,FjKbcDxe 7CE75114-8272-45AF-B536-761BD38852CE,Slp21PubKey 7CE88FB3-4BD7-4679-87A8-A8D8DEE50D2B,EfiEventReadyToBootGuid @@ -5079,17 +5712,22 @@ 7CFACBB0-B515-4970-AE98-38F540E73482,H2OVerifyRegionDxe 7D019990-8CE1-46F5-A776-3C5198676AA0,EfiExtendedSalResetServicesProtocolGuid 7D06E47C-B32C-496F-940E-F30CDE0B7CE5,SystemFirmwareDeviceBlockSmm +7D08D718-48EC-4C52-919D-407E5B1A94E4,IntelGigabitLan 7D0EEA4D-74CA-4118-898E-964181DC5D1B,SmmIpl 7D113AA9-6280-48C6-BACE-DFE7668E8307,AmiMpTpmBin 7D15608C-EE1A-43CC-A27A-BE9D8BA0F5F8,DellTcgServicesPei 7D17EF81-57C8-4210-957C-6FDAA8EA1DD6,PciHotPlugDxe +7D19E8AD-1089-42B7-A440-D8318A44E89F,SioIt8659ePei 7D24A234-A8C2-4718-BF60-A2EF070F414E,OpalPasswordSmm 7D24A567-A8C2-4718-DC60-A2EF070F414E,SmmCrcInit 7D277BE3-8778-4139-A33C-738065720098,FjIbvSfuSecFlashAbstractionDxeProtocol 7D279373-EECC-4D4F-AE2F-CEC4B706B06A,Tpm2AcpiTableStorage +7D29BF67-6131-4CCC-91DE-BB8291565701,CbsBaseDxeSTXH 7D2BD134-500D-4F42-AEE2-26ACCFB6CB1D,LibStdio 7D3DCEEE-CBCE-4EA7-8709-6E552F1EDBDE,FlaSStatusguid +7D47DC17-F443-42A1-BCC3-54FD06A95821,SDPngDecoder 7D4E94A9-269A-47A1-80F0-2B0EB42F7B4B,Int15ServiceSmm +7D51F6CC-9272-6541-A74F-6B784082D285,AcAdapterWarnDxe 7D574D54-D364-4D4A-95E3-4945DB7AD3EE,ShellInstall1HiiGuid 7D5FF0E3-2FB7-4E19-8419-44266CB60000,DP 7D655829-26DD-4342-96AD-04899477C3FA,SpiSmmStub @@ -5107,12 +5745,14 @@ 7DA45AA9-6DBF-4F1B-A43E-3287CBE51351,TpmPkgList 7DA53855-F630-4A30-9D85-0E99DFD92A06,EfiPlatformTypeLightningRidgeExecB4Protocol 7DA68578-C0E9-4742-8DE5-C91ACA88D5A7,DellBoardPolicySmm -7DADBC98-6489-4D1C-907A-8EE243AF805B,ASUS_EUPPEI +7DA6F287-4BE3-45CC-8515-E27486936C0E,BoardSyncPspFwAToPspFwBDxe +7DADBC98-6489-4D1C-907A-8EE243AF805B,AsusEupPei 7DB8BFAE-B3BC-483A-8252-E0F213151AA7,ODMWlanTpowerOnOverride 7DC20199-DE28-4A91-A89C-FF06F237352C,PrePostHotkey 7DCAF14D-1499-4149-8364-1673CD1CE75C,PecNbDxe 7DCE671B-C223-446A-A705-ED637AAF6771,EdkiiCryptoPpi 7DD26A06-9942-41A8-B9CF-09DE46D5D219,BBSManagerDxe +7DE2F2F8-B627-441C-B352-5B02EE035C47,LenovoAIOFmpDxe 7DF0DD67-5B91-4D40-A835-58013457010A,SmbiosDataUpdateDxeHedtCRB 7DFA9220-5145-42CB-A815-0865C1B952F9,FidoUsbDxe 7E0C6E3E-C80F-47D1-8ADA-554926B2B6B3,GenericMemoryTestDxe @@ -5122,11 +5762,14 @@ 7E374E25-8E01-4FEE-87F2-390C23C606CD,PlatformAcpiTable 7E3D95E4-89F8-41B9-B788-5FB22D77F9A3,SmcNVDIMMDxeDriver 7E4B2ACB-7391-408F-B143-3A0B07C6E165,FdoModeEnabledHobGuid +7E4F3635-6E28-40C6-BCFB-2B1A46459946,BiosPasswordDxe 7E631AA5-AFCE-437B-81FA-FA34EA14B3C3,ExFatRecovery 7E66ABA5-5780-4ACB-A50F-8198989C69C3,FjGabiSettingsDxe +7E696C3E-5C5D-4A64-9650-E792FAD24128,AdlDriverSmm 7E6A6CF5-C89C-492F-AC37-2307849C3AD5,EfiCpuPpmProtocol 7E715650-10E6-4B7B-896A-4DC5FC742BC5,LenovoModulesSmmThunkSmm 7E7369CE-0188-4183-8C2D-DAF7B730E42B,AmiCmosBadHobGuid +7E7507B4-45E1-21D6-43E3-32B9F7F4720E,Ds125Br401aPei 7E7F16FA-B957-47AB-B58B-7AC40DA44A5E,SIIDDxe 7E8567C5-ADFE-44A6-A1FC-6514105C6B24,FjCameraCapsuleDxe 7E8ADB71-9A5B-4AC7-82BE-E8598285DC14,LANWakeupDxe @@ -5136,9 +5779,12 @@ 7E99BC9E-EDE9-48C1-85B9-689432817F8F,SystemEsrtDxe 7EA76D38-C57A-412D-AF1D-D58BEE2B85B1,LenovoVproPetAlert 7EA7AACF-7ED3-4166-8271-B21156523620,SamplePlatformDevicePolicyDxe +7EAF93A7-7026-46FD-B359-6A98DEE70860,AsusCloudRecovery +7EB51510-729B-482E-AA28-C9EB6A7FB837,SioSxIntruderDxe 7EB7126D-C45E-4BD0-9357-7F507C5C9CF9,RomLayoutPei 7EB88C46-22FF-4CBD-8FE7-495383FAB1E4,PciBoardDxeInit 7EBB920D-1AAF-46D9-B2AF-541E1DCE148B,EdkiiPlatformHasDeviceTree +7EC6E119-1FD8-4C84-8E57-FF55D166C91E,PlutonSecurityProcessorV2 7ECBEF8F-2C6E-4CC0-B8B8-BF536396CC9D,HpQX448Pei 7ECD9C20-68B9-4A6F-B515-D64FF500B109,FsRecovery 7ED59FC2-3395-5DD2-A31C-1EF2F098E166,GopConsole @@ -5149,39 +5795,56 @@ 7EF09900-7397-45C0-9CA6-698324391870,DellAutoOsRecoveryDxe 7EF21E8C-2FC1-4BC3-A84A-73025EAAB896,ProgressBarFullMiddle 7F0013A7-DC79-4B22-8099-11F75FDC829D,EfiCacheSubClassGuid +7F009393-A908-4EEE-843B-0771FCED8F59,MpmOemFunction 7F0690AD-1725-4930-8137-94D0FCF5F63A,AmdXgbeAndDisplayConfigurePei 7F06A90F-AE0D-4887-82C0-FEC7F4F68B29,EmmcBlockIoPei 7F0FE834-0727-4640-95E9-9B1C056F87B8,CypressCCGx +7F133760-9CA0-4D4F-A201-038AB955B1B5,SetSystemState 7F1647C8-B76E-44B2-A565-F70FF19CD19E,EfiDns6ServiceBindingProtocolGuid 7F19E716-419C-4E79-8E37-C2BD84EB6528,PeiSpiSoftStrapsPpi 7F1D8127-EB69-44DD-A88A-ED37BDB97DB3,OemBadgingSmm 7F2BFC42-9BDE-4E9D-BE83-1BB752DF0C3A,SystemBiosSelfHealingPei +7F342334-54C3-40FB-A289-DA000A0637BD,BeepInterfaceCoreDxe 7F380019-B951-4BBD-BEDF-8DD7A621D773,OemNvDriverTypeDxe 7F3E00EE-B826-4358-8FFA-C30C3AF526F2,LenovoTpm2ConfigSmm 7F4158D3-074D-456D-8CB2-01F9C8F79DAA,EfiTpmDeviceSelectedGuid 7F480A20-7A19-4764-A5CA-4E9B8AECAF1E,PchPciBus 7F4A3A75-538C-4259-B420-C44818CBC553,ATIPwrXDXE 7F4F86F6-EBC9-4603-A4C2-C7CC8B4476DB,Heci2BarSaveRestoreGuid +7F51CB64-A6CF-4DA1-9E3D-E9F3976B3C92,FchSmmDispatcher 7F5E4E31-81B1-47E5-9E21-1E4B5BC2F61D,EdkiiPeiFirmwareVolumeInfoStoredHashFvPpi +7F630637-39BE-401D-AC06-57DC9117DF13,SDEVUpdate 7F6E0A24-DBFD-43DF-9755-0292D7D3DD48,IsaFloppyPei +7F786C3D-C586-48BE-BBBE-1D8273481C00,AsmUsb4InitPei +7F81D838-F91D-4C44-8552-8FB912122FDD,GopDxe 7F843E9E-BA26-4D3C-82F7-C703D87D334D,PhI2cPlatformSupport 7F865306-830D-4DC2-8E9A-B7856F925A0A,SupplicantDriver 7F8D35BD-0CE3-4654-B5D3-73FC4B38AABF,PlatformEarlyDxe +7F9263F2-0BC0-4AA0-8503-6D69513BCA15,AsusHddGptRecovery 7F955A3E-AFB5-4122-B925-4B1171F693F5,AmiBlockIoWriteProtectionProtocolGuid 7FA5F220-9F11-49B5-85A2-045AAC347D27,BackupService 7FA68D82-10A4-4E71-9524-D3D9500D3CDF,PlatformSecureLibNull 7FA9284E-40B3-417F-A2BB-58EAE1026314,FjSystemResetDxe 7FB30861-8941-4748-953A-2C59D93F9171,BiosConnectUiManager +7FB6E2BA-C550-4529-A85D-A8A9D13B851E,FjGrasscarryDxe 7FC90770-0E89-4A20-8152-6CB777B56F48,FlashInfoDxe 7FD082A9-3D6B-44E3-9C31-74D6B80F965C,SetupConfigUpdateDxeLightningRidgeEXECB1 +7FD24CF7-2BF6-4547-8441-845E793C619D,AmdSocSp5BrhDxe +7FE9EA1F-4224-4C7B-9F44-FEC1728E7DA1,FjDevInfo +7FEB1D5D-33F4-48D3-BD11-C4B36B6D0E57,FmpDxe 7FECA3CE-F18C-4DCE-9465-4DEB949298C9,E022X7 7FECA3CE-F18C-4DCE-9465-58D6FB0692B8,0_X64 7FECA3CE-F18C-4DCE-9465-80FF64F2AB7C,0_X64 7FED72EE-0170-4814-9878-A8FB1864DFAF,SmmRelocateDxe +7FF2BC6B-FCB9-4381-A602-45CDF9BFFFB4,DelAmiCapsuleImageLoadedVar +7FF2FCB3-E868-492D-9063-6D22E6A2B14C,SDConfigureSSID 7FFC3700-7C5E-423F-A04B-32E9F16A6727,SuperMPeiPrococol 7FFF52C8-82DE-4820-8960-5093102E484D,IncompatiblePciDevice 80023209-6386-4C1D-909B-63506A2146FF,HWM_SetupDXE +80030344-4BA0-4F2C-A6AC-1E0E928F2470,AmiAgesaSbPei 800594D2-39E7-4088-9BDD-D979737DEEE1,SmbiosDataUpdateDxeCLX64L +80060E80-2C20-429E-946B-1C89097F0BED,VariableServiceDxe +80144152-6770-45D0-8463-E4B48EBE4B5B,HpAmdTbtPei 801ADCA0-815E-46A4-84F7-657F53621A57,SectionExtractionDxe 801B5C4B-6AE2-4065-9F72-82CA760C2ECA,EfiRsaTpmClearOwnership 801DE6B4-2036-46B7-B8F7-79205CBD1772,SmartCoverPortingPei @@ -5194,6 +5857,7 @@ 80522809-D926-4D50-8E71-1E897AB29E1D,FjPowerDeliveryCapsuleDxe 805B032B-6A00-46F5-8501-CB88A21D5321,BcmDhd 805D1C5A-EF12-490A-9E7B-9F4AA2F97E73,AmiPspNvramSmm +806040CA-DAD9-4978-A3B4-2D2AB0C8A48F,QemuKernelLoaderFsDxe 80680ACD-2F8D-48B0-BFA9-3E3177AA9E27,OsVersionDxe 80752470-6EDE-485D-AC36-DC1BA66091EE,LenovoSpecialSwSmi 807E2D68-B13F-490A-A2FB-346A39459978,NCT6685DSmmDxe @@ -5202,6 +5866,7 @@ 80897901-91F6-4EFE-9579-3353A0C02DAB,SDMediaDevice 809FBBFD-127A-4249-88BC-FD0E767F4FFD,IconInternalHD 80A1BB91-2036-46DD-9CC8-97A1F2F7E5BC,HpSmmCoreServices +80A1CF80-A85D-4C1A-9131-1FEFC5959618,AsusPcieCardReaderUpdate 80A29A57-BF37-4403-B7B0-D654E84F8A6D,PchInitDxeEhl 80AADD0D-8053-4BA7-941B-36F48BB23001,DellSystemPwSmm 80B08E6A-C6CE-430F-9C07-52A9526DB0F9,CompalWSMTDxe @@ -5232,9 +5897,12 @@ 8151A914-2437-41D0-A410-14DF75F9BE70,SystemMassStorageEventDxe 816C3759-DFE4-4644-AA17-1F090E02A599,TiOnlyPei 81791CAF-44AD-441F-B0A2-322BA8FC95ED,FchImcControl +8180B47F-EBB0-4303-A389-74FD15356BA6,DebugLogDxe 81A4F912-E72F-44ED-8931-16A9FE9650E0,KbcEmulDxe 81AFA132-8D94-4101-A538-833C05D145D9,BoardSelectDxe 81BC1E82-D8B2-4444-A336-E83D80654A6C,DynamicPowerSwitch +81C0C020-E99E-4406-9656-5E686A0E0CC3,FjTpm +81C53D89-E238-4133-BBD2-5BDA8BEDEC85,StorageEraseDxe 81C9FDB4-4D6F-4D98-B7B8-6A9DAF677E73,D01HddPassword 81CD3462-6A1A-42F8-829B-8D77481DDB64,AmiPciExpressGen2LibNull 81D12896-975E-487F-AE40-1C37B4D7A820,DeviceWufuEsrtDxe @@ -5254,22 +5922,26 @@ 8214E213-180C-4822-A236-CDCA43F43C88,CbsSetupSmmMdn 8216D0CC-7F6E-46F1-982C-E6219D4AE066,AmdMemSspSp3Dxe 8217E118-1058-4C9B-936E-5B3027C2394B,PchLpcDxe +82180E9E-FB32-4086-AB38-370BB29134E3,MemoryStorageChipsetSmm 8218965D-20C0-4DD6-81A0-845C52270743,LenovoSetupDateTimeDxe 821ACA26-29EA-4993-839F-597FC021708D,AbsoluteAbtInstaller 821C9A09-541A-40F6-9F43-0AD193A12CFE,EdkiiMemoryProfileGuid 821D8B77-246D-4E96-8E10-3467D56AB1BA,SetupAdvanced 821D8B77-246D-4E96-8E10-3467D56AB1BB,SetupMain +822A31D8-0AA7-415D-BEEF-C5C896509C50,BctBaseSmmPHX 822A9647-5479-44F0-AC85-8869074D76AD,DellForeignKeyboardLayout 822D8836-2477-4F8C-9330-2F8695EBE4F9,FjSkylakeRtcBattery 8231DBBB-30E6-459B-BA4B-5ECE97561539,DellUsbCsmSwitchDxe 823B8A1A-6D01-45A6-8098-20DDD1C7B3D0,PlatformLtDxeLibNull 823F654C-D966-45A4-A4CC-5FB6741E34BE,AmdNbioEarlyPhaseRMBPei 82479446-5371-44F7-87BF-C808BC9A9925,SplashPei +824C0DEA-8B01-4F12-A68D-A5DAEE2B9714,AmdMemSmbiosV2StxhPei 824D5A3A-AF92-4C0C-9F19-19526DCA4ABB,FspmArchConfigPpi 8253972C-9CE7-4539-87EC-A248A48084C7,AddressTranslationDsm 8256C18C-27FE-4199-B369-C6C95C555F06,H19AmdFTpmUpdate 825880CC-DBB5-4955-8AFF-B26FA33C84AA,AppleFirmwareFeatures 82594D34-85DC-49D4-992E-238E622F6152,OemSmmSample +825AE2A9-9C84-497E-94E0-09C237765948,ThermalInitDxe 825BDE6A-E9E4-4CC8-9C2D-09B29C3BD426,EfiCpPcPlatTokenSpace 82627ACF-D92D-416D-8A6F-783CACD91223,AoacEcWakeupCustomPpi 826824B6-CC9B-4D62-8E7A-0FFBF6013CBE,SmmHeciProtocol @@ -5288,9 +5960,11 @@ 829FDCA9-6917-4713-A3AD-F04CF3E1B25F,S4SlpDelayDxe 82A3935E-BA18-4703-A7D7-6D356FFE26BA,CameraSmm 82A6080E-07CB-4841-A94E-D340FD0C5284,NvmeInfoDxe +82AB4703-FE33-49C3-AE40-4A20132C792A,AmdPspDxeV2Shp 82ADB73C-E005-4E07-976D-F7F75314EC4F,FchSmmDispatcher 82BF4973-734D-4324-A3D3-FCC0EE3AD51E,DellEarlyLogoPei 82C93B6D-68ED-440E-A826-BDC7AEF8EE0D,WirelessBluetoothDetect +82D18B9E-153A-4BD7-9270-ABC14ACE5DC8,UefiDriverRealTek 82D3F268-757A-44CD-A87D-13FDA972B999,EfiPlatformTypeLightningRidgeExecB1Protocol 82DDD68B-9163-4187-9B27-20A8FD60A71D,EdkiiIfrBitVarstore 82E1070A-B808-4F26-A8E9-ACDCDFF2721A,Rtk8153UsbUndiDxe @@ -5304,10 +5978,12 @@ 83410FC1-2C86-470A-AF66-3966A1ED42BD,PhAmtSupport 8341855A-F272-4FFE-BBEE-DAEAC5CEDDC7,DellStorageAgentSmmRegister 834C0C5F-ADB3-4372-AEEB-03E4E9E6C591,IntelFspPkgTokenSpaceGuid +83705B89-CBF9-44F8-8546-E0124C682D08,SpiNorFlashJedecSmm 8373FD38-D98B-4C8A-851E-2E9396748AF3,TxeFwDowngradeDxe 8376BDCA-5E03-4735-951A-4A74141E5886,TrEEConfigDxe 8378AB1E-4147-400A-8D84-E3DE981C0453,TamperResistantBoot 837B3E7E-4259-4E35-87ED-397A24CA1593,MpmSensorInfoDxe +837D8904-2231-4558-8F70-EE72790BAB9C,ClientronLanDevInfoDxe 837DCA9E-E874-4D82-B29A-23FE0E23D1E2,VirtioMmioTransportGuid 837DD75D-9862-4E68-87F9-64F855BB83EC,HpNetworkFeatureByteKillSmm 83890F3D-B747-4F4D-8C21-12908759A53F,HstiIhvProviderDxeEGS @@ -5323,9 +5999,12 @@ 83DB711B-ADAC-46B3-BBFF-5E6E28CFFBD2,DellWlanSmm 83DD3B39-7CAF-4FAC-A542-E050B767E3A7,VirtioPciDeviceDxe 83E053E5-3BF6-4C2D-9B86-72BE3CF2EDCC,I2cMouseDxe +83EC3FC9-CB74-4B2B-89B9-E98F0972F2A8,RotateScreen 83EC90A9-D791-4613-9C57-68C3DE923C3B,MeSmbiosUpdateConfig 83F01464-99BD-45E5-B383-AF6305D8E9E6,EfiUdp4ServiceBindingProtocolGuid 83FA5AED-5171-4949-BDC9-0CBC9E123663,FwCapsuleRecoveryPPI +83FAAFBF-FC4B-469F-892A-798E66A6F50A,RestJsonStructureDxe +83FEE84D-9321-4908-895D-4F6E355CEC55,HDMIPConFW 8401A045-6F70-4505-8471-7015B40355E3,UsbBusPei 8401A046-6F70-4505-8471-7015B40355E3,UsbBotPei 8404B613-EA35-466F-BC7B-9F51C965198E,AsusBackDoorPW @@ -5335,11 +6014,13 @@ 842546AF-5AEA-40DB-8695-42E52575CA45,A01DataServiceBodySmm 842680F2-1A9C-48E6-A433-BE9ACB0DD438,EfiIpmiBoot 842A454A-75E5-408B-8B1C-36420E4E3F21,NvramSmi +842C4FC7-1E52-492E-9E64-70F998CD8811,SDSmbiosUpdate 8434DA1F-5CEB-402E-A93C-038CBE0F3F0E,OemActivation3Smm 843CE545-9F06-410F-BA6C-311D66AD643A,MFGDoneSync2Setup 843DC720-AB1E-42CB-9357-8A0078F3561B,EfiSmmControl2ProtocolGuid 844EC5BC-AE49-41B2-A70A-0AEE59505518,DellAdvSysMgmtDxe 84562A94-1CFF-11DF-AB3F-FB61AA51C41C,PmRuntimeDxe +8456F6DB-043B-405E-B18D-684E69B05DE7,AmiOemRasDxe 845A6EE9-ABEB-4DDC-8983-0A13A2D1A79D,TdxDxe 8467C103-6FF6-4D66-86F6-E1124C111E94,DellHotKeyHandlerSmm 8467C103-6FF6-4D66-86F6-E1124C111E95,NbLegUsbPolicyload @@ -5350,15 +6031,20 @@ 848377A0-A78D-469D-B766-87186AA6770D,EpuHwModeDxe 8489334D-4219-4CA1-9B42-1D46B0B75861,TcgPpVendorLibNull 848E908E-BD11-428E-94F9-7A0EEFCD37A6,BaseCsrToPcieLibNull +84945A3D-49C8-4059-8F34-6A4532D32A47,VariableEditSmm 8495E3A1-43D9-11E8-927F-A4C4943F0C96,NvdimmInitializer 84991287-3FF0-4FCC-9C11-C7E041862C76,DellPowerManagementDxe +849E502A-75B6-4F9C-AD12-1E01F1DC0C40,AmdAgesaParameterGroupPei 84C31E7D-3703-42D3-B43B-1FEE41666D9A,SystemFormBrowserMetroViewLayoutDxe +84CB67EC-B27D-4F83-897D-16A95B626EBE,BoardInitAdvancedPostMem 84D3E3DC-98AD-4D40-9396-57E8ADC7868E,GetVariableHookDxe 84D4AD5B-1702-442E-BDD8-57E1196111E5,SmmAccessDxe2 84DA4361-EE8A-4769-9368-4F28A1C92032,EfiBxtTokenSpaceGuid 84DDA68C-CA5A-4C30-9261-DD6DE7E45A95,EzSetupPortingDxe 84E7016D-1EB8-4637-B01E-9EED018C7AE0,BiosGuardNvs 84E90BA3-CB79-4267-AE2F-437B86DAA6F4,DellTrustChainingPei +84EEA114-C6BE-4445-8F90-51D97863E363,CpuHotplugSmm +84F258E9-5AA9-4DD6-A4D4-209B3BE31B0C,OfflineCrashDumpDxe 84FA65AF-21BC-43BE-85FF-8AA7E7832A1D,AmiPciExpressLibNull 84FB407D-D076-4DDD-871F-33373A26BABB,FchPromontorySsdt 84FB407D-D086-4DDD-822F-33373A26BACC,FchTaishanSsdt @@ -5374,6 +6060,7 @@ 855328E7-F96F-4398-9E7F-1F0A8C014E2C,AppleMeDriverDxe 8555FD40-140B-4F3C-905E-3BF378A099FA,EfiActiveManagementProtocol 855D2C2A-8A68-4783-AEC0-CCD995CBA569,FchKeithMdnSsdt +855D6DC1-9FE8-42E0-9F76-50C2E2DD2E06,AmdPspDxeV2Rpl 85674556-04B3-4151-8612-53C628835F34,H19DxeInstallHook 856C6A10-F3B8-4C2E-A273-7868C09BE8EA,MmcMediaDevice 85768E4A-6CDC-444E-93DF-936685B5DFCC,VlvRefCodePkgTokenSpaceGuid @@ -5381,6 +6068,8 @@ 858031F3-96A2-406E-ABCC-ED264A3A31D6,CryptRuntimeDxe 858189AC-0ECA-4666-BAB8-9972409953C8,AcRecoverySmm 858EBE6F-360F-415B-B7DC-463AAEB03412,TcgLegacy +858ECEAE-4A83-41BE-9643-6ABB93943A4C,RealtekGopDriver +85941FF3-13C9-46E6-9EE7-68B487B83F27,AaeonSmartBoost 85984EC9-E300-4277-AC62-640FABADB6A5,DellSbDxe 859A2015-3C7B-4F4E-847F-7AA88C8714A5,ConfigChangePromptSmm 859F2D28-2894-4EF7-A05C-F8BFC7922DB7,HidSimplePointer @@ -5394,6 +6083,8 @@ 85B79D5D-EAAD-4A85-BA28-03D1362E668D,FchI2cMasterPei 85D80233-B31B-40F2-8131-034405FC5936,SmbiosType133 85D8435F-A603-4DAD-A285-7230D84F9F69,AcerDiagnosticLogDxe +85D91856-70A3-411D-9612-4531C060D867,ITE8225DxeInit +85DB8287-B268-4DF4-9226-7302B211E303,OSSelect 8600C3A8-4213-456E-832A-D51E8E5F4AB1,AppleHeciDxe 8614567D-35BE-4415-8D88-BD7D0C9C70C0,PlatformOverridesManagerGuid 861AB7EA-0E47-40B3-AEA6-48D07AF4703C,CsbSmartCover @@ -5411,6 +6102,7 @@ 864E1CA8-85EB-4D63-9DCC-6E0FC90FFD55,SioBusDxe 8650A9D0-3A80-43F2-85D8-6D10CDBF611E,SuperMSmm 8657015B-EA43-440D-949A-AF3BE365C0FC,IoMmuDxe +86574ACD-5A8F-4FFF-A64F-6A1702786850,CommonSetupDxe 865A5A9B-B85D-474C-8455-65D1BE844BE2,EfiDebugAgentGuid 865A5AAB-B85D-474C-8455-65D1BE844BE2,EfiSourceLevelDebugPkgTokenSpaceGuid 865F8FA9-BD72-4D38-A1C6-6041F426E92F,DellSbDxe @@ -5422,6 +6114,7 @@ 8683EFB2-FDE1-4AFF-B2DB-E96449FDD4E9,S3Pei 86843F56-675D-40A5-9530-BC858372F103,OsSelectionVariableGuid 868A660F-47F8-4088-A4C0-C55FF8DB0C96,LEMPhyPresenceSet12 +8698C9AB-DF46-4B3C-B119-1D4CC1199497,Realtek5243CardReader 86997AE6-D443-4939-B729-A3D0F32FB772,OneClickRecovery 869C711D-649C-44FE-8B9E-2CBB2911C3E6,EfiPeiDelayedDispatchPpi 86A075CC-7854-4B11-AF71-95B8762D941A,N17PQ3Gop @@ -5441,6 +6134,7 @@ 86EDAAE5-073C-4C89-B949-8984AC8A55F3,SdMmcDevice 86F5680A-155C-4BC8-AC77-573848E2AD3D,AmiTreePpiGuid 86F61BDF-5BFD-46D3-B0F9-E43728DA1D2E,OCMR_CPU_POWER_MANAGEMENT_DXE +86F67A12-2E32-44FC-8D6C-7901E2B5649A,CapsuleUpdatePolicyDxe 8708203B-8948-4E51-BEE7-8C1B56EEC9CD,FjPvCredentialProviderDxe 870CAF91-B79B-4EBA-920F-71E3DD4789F4,HeciRuntimeDxe 870E0F5A-1981-45F6-AE26-0391425CC46F,CpuCsrAccessSMM @@ -5457,10 +6151,13 @@ 876E11E2-5B23-4EA4-AF2A-4065EFBAD841,LenovoVariableStoreSmm 877609BF-BBE2-4C9E-B45B-A46859C76C73,FjGabiSettingsApiSmm 87777B50-6429-4F8A-8A62-F5B14F1F5948,FruCpuFeature3v0 +877F57F6-689B-4FC1-A7AF-02DF7FD536E8,AdlSemaSmm 87837AA2-EEB7-434E-9EAC-9D49639E72A2,OtaShellCommands 878AC2CC-5343-46F2-B563-51F89DAF56BA,IntelIGopVbt 878CA608-293F-482E-83A9-50A484B5D4ED,EDockSmm +8790C65B-61E2-41A0-B6AD-FCE066F18414,EarlyConsoleOutInterfaceDxe 87AB821C-79B8-4EF6-A913-21D22063F55F,AcpiPlatform +87AE079C-1143-48D7-A6DC-D9E6115DBBCA,FjGpioAlderLakeDxe 87C2106E-8790-459D-BD44-2EF32A68C3F9,IhisiServicesSmm 87C3E993-B28D-4226-89C9-120DBC92ACBF,SmBusSmm 87C4741D-CEF4-48A1-89AA-7F86EFA0A21A,MediaCapsuleEarly @@ -5479,6 +6176,7 @@ 87FB2BE8-F1E6-448D-970A-BE4DFE7921CB,AaeonSxSmi 87FC8DCF-660E-4FFF-8776-D6BA053DEDD1,DellIoExpanderPca9555Dxe 87FFC11C-D0AB-4D12-A779-0A5474050759,OemProtocol +88015920-2B9B-4B2E-840C-AD76BC6C3ABF,AmdNbioDxe 8803FA9A-0D33-4022-856B-AB5932A0F8BF,AmdInitPostPeim 880AACA3-4ADC-4A04-9079-B747340825E5,EfiPropertiesTableGuid 880AE5C9-FA45-9B63-7489-9B12CC564540,AcerBIOSConfigurationToolDxe @@ -5491,9 +6189,12 @@ 882F2546-EF1F-4090-9F9C-93845AD7841C,SmBusControllerIdentifier 884441DA-4459-4796-A5AE-D39F30E97A9E,LanWakeupPei 88523DDF-3AAC-41F6-B15F-DC7BEA434B39,TrackPointSynaptics +88548343-32E6-45D4-B1F1-1D4FA72DD4A3,MeFwuDxe 8863C0AD-7724-C84B-88E5-A33B116D1485,Host +88640B94-021C-4926-9198-0A98FB7A0826,COM_TYPE 8868E871-E4F1-11D3-BC22-0080C73C8881,EfiAcpi20TableGuid 886ACB20-78C0-4F88-9D3C-BADCE37EDA47,LenovoN25Q064FlashPartDxe +887B83CD-B40B-4390-94E2-EF77F36AE101,FjDxe 88863325-C803-469B-9904-6FB2E33F0070,AssetIDOnS3 88888888-8888-8888-8888-888888888888,WholeFv 889004EE-8388-43BE-8975-C593FC50BB4A,EmulatedEepromDxe @@ -5518,9 +6219,11 @@ 88F6ED8D-7D6E-40EB-84B4-D66FBDDCE5C0,AmdMemSmbiosV2PhxPei 88F74F5E-E998-4D59-44D8-225FEF02FCE3,TiXio2001BridgeConfig 88FAE289-0A6A-4097-9CCA-2BED645B094D,AplDxeIpl +88FEEAAB-BFBA-4CB9-8907-31BC6E546DBE,SXApp 8900C607-C0AA-478E-AF00-65870BC951FD,SetupStatusDxe 8900E28F-DE99-4FC4-894B-6F41CD139A48,InfineonTpmUpdateDxe 8901FE25-27D3-4815-A63D-35851C4F50EF,FjGabiPostFlashAbstraction +890987B9-3E09-4608-A468-5E0987B204ED,FchSongshanI3cDxe 890A3508-E816-41CF-B7E6-ED28E5BB5C28,AmtCompatiblity 890C2CEF-43C8-4209-A78D-AE14AA1798B4,AmiTcgPlatformPpiAfterMem 8913AADD-564E-4CF8-B176-F3F985979C5F,RomHoleReplacementProtocol @@ -5533,11 +6236,14 @@ 8958EDFF-02F7-4E49-87B1-FBA4BE4E8768,SmbiosDataUpdateDxeLightningRidgeEXECB4 8962C28B-0DFE-4739-A73F-092D374A7A13,efi_pop_RT_pressed 89680AAC-452B-4B44-AEF7-800B6BFAF195,EfiIchTokenSpace +8969E833-7DC7-4DAC-A2ED-08251482EE5B,I2cPssMonzaDxe 897508C5-FCDA-4DB9-8A7E-6214CF6C246C,LenovoNvmeInit 897508C5-FCDA-4DB9-8A7E-6214CF6CFFFF,LenovoHstiUpdate +8975A90C-238C-4FA8-9EF1-03C6C359CA39,AmdCpmDiscreteUSB4Peim 8977B212-0A43-4048-993B-B39AC7B0FE21,gear9 897A5222-978B-49AB-BAA0-FC523FB92602,FjThermalSmm 897C64C1-0CB7-4FA2-815C-307463E535B5,OemManufactureModePei +8980E2D0-6C77-423B-8E3A-8D3D40D10CBB,RTL8852BEWifiDriver 898415A1-06F1-4C21-B83A-C555CF2F2364,DellMemoryThrottleProtocol 89843C0B-5701-4FF6-A473-65759904F735,EfiBmcAcpiSwChildPolicyProtocol 8987081E-DAEB-44A9-8BEF-A195B22D9417,BasePciLibPciExpress @@ -5585,7 +6291,7 @@ 8A8D0AD0-E28C-4907-A651-AE9D65CD9298,TileSmm 8A91B1E1-56C7-4ADC-ABEB-1C2CA1729EFF,AmiPostManagerProtocolGuid 8A97886A-EEE1-4BF8-AD20-68F398F95B12,AMDPSPKvmMiscDxe -8A97B11E-EE8E-11E2-B664-047D7B99E097,AcpiOverride +8A97B11E-EE8E-11E2-B664-047D7B99E097,AcpiInterfaceCoreDxe 8A99693A-F42D-442B-B369-DDD6780DA710,PlatformHstiSetupDxe 8A9EE24D-DAE8-401F-A591-241DF848407F,WwanSmm 8A9F7CFC-5BFC-458F-986F-BC3D1BA7AC89,DellSpiPartStMicro @@ -5595,9 +6301,12 @@ 8AAFF1F7-D011-4AE5-8324-DFA470F75D33,AsfDxe 8AB17F97-758F-47AA-BA64-DDC63C3A1D86,H19DbxService 8AB1D576-5977-4A89-9414-099D90B53E79,TpvSmm +8AB2F241-77FA-49C7-BD2C-FD71A743FD8A,PostMessagePei 8AC88C0F-6220-F243-8E27-56E17CC503DB,AppleNetLoadFile2 8ACEFE43-D9A5-471D-B802-9879862AC3BC,FchSmbusDxe +8AD3148F-945F-46B4-8ACD-71469EA73945,Tcg2ConfigPei 8AE83DA6-881F-4BA6-997D-7BF16ED553B4,OemSmi +8AE96C45-9798-45E5-A952-143B6330A540,ClientronSmbiosUpdateDxe 8AF1FE4F-DB8D-43A4-AA5D-4ADE632A0FE9,SmcPeiSerialTextOut 8AF7DD16-2342-4987-9426-6604A207E24B,HddStandBy 8AF7DD16-2342-4987-9426-6604A207E26A,PasswordSeverityDxe @@ -5611,10 +6320,12 @@ 8B335317-B490-4C75-93DF-C68201346758,FjSetupControlDxe 8B33FFE0-D71C-4F82-9CEB-C97058C13F8E,BootFormSet 8B34EAC7-2690-460B-8BA5-D5CF32831735,EfiCapsuleInfo +8B48D921-54F7-11E4-9FF3-047D7B99E097,WirelessDeviceSupportDxe 8B529353-1FCC-4AC0-A121-90BE9F9CBF7A,DellDiagsLegacy 8B5FBABD-F51F-4942-BF16-16AAA38AE52B,AcpiPlatform 8B63F985-5DED-448A-8996-A008BED45AA8,SystemDeleteSignaturesDxe 8B68002A-817B-0361-BABA-6341A44EA052,DPTFPolicy +8B702C70-A9FE-45F6-BA66-951B50BA3B92,OpalRevertDxe 8B778A74-C275-49D5-93ED-4D709A129CB1,AbtDxe 8B786703-E8C7-4BEA-8F07-CDF991B90999,AmdPspDxeV2Rv 8B7E5420-1B71-442A-9916-C13A4FE02482,SmbiosDataUpdateDxeLightningRidgeEXRP @@ -5622,13 +6333,17 @@ 8B843E20-8132-4852-90CC-551A4E4A7F1C,EfiDevicePathToTextProtocolGuid 8B87A12B-F438-49C0-8A7B-8D16A1FDACD4,Rt8111FPciUndiDxe 8B8AFD01-8A32-4249-9800-FABC2B1084E5,BluetoothSmm +8B8EE015-62B3-40EC-A9E5-836CBFE1F33D,TouchPadDriver 8B8F683B-F376-4BA0-B8D7-B4BBD30319CC,AtSha204aDxe +8B921AB5-A1C3-4660-BD4B-FA00B7248421,PlatformFlashPartDxe +8B93CA34-91CC-4D2A-8C74-371F92691F13,RetimerFMP 8B9947AE-0A9E-4D5F-8A8D-87C914136F38,FlexIoCardDxe 8B9D3EE0-4BA4-433B-9C48-4E830B3B40FD,FloppyCtrl 8BA016CD-3EE3-4934-9BEE-AED08EA572B9,PspPlatform 8BA65DE3-39E1-4AFD-A8FE-7DD0BAFEFCC0,DxePalLibEsal 8BAA47AE-0A9E-4D5F-898D-87C914682F38,RTS545XDxe 8BB070F1-A8F3-471D-8616-774BA3F430A0,SmmIpmiTransportProtocol +8BB18D0B-9193-4DC5-BDA0-7BEA3735DC34,FjUsbHub 8BB59471-823C-4A11-B610-CE3985793EB1,DellSystemPolicy 8BB76937-EC61-4E48-B397-6667DA243486,FjDtPlatformSetupServicesDxe 8BBC2910-04E8-4450-A6CD-349E5D4D765B,DellRuntimeAcpiDxe @@ -5639,6 +6354,7 @@ 8BE4DF61-93CA-11D2-AA0D-00E098032B8C,EfiGlobalVariableGuid 8BEB8C19-3FEC-4FAB-A378-C903E890FCAE,AmiEventLogsFormset 8BEEDB0D-A31A-0361-A312-5DC8574C65F1,AzaliaPolicyPei +8BF0A193-CC00-4779-9DB3-3EA35DC77BCD,AmdPspPeiV2StxH 8C0ACC5E-28C1-4599-8238-9558A9D7A428,UsbTypeCPowerLimitPei 8C1015F8-483A-4919-A078-EA338F3C7DD4,SmmCommBuffer 8C1CAD13-167D-486F-8B20-12FF6D1305CC,FjPowerButtonDxe @@ -5681,6 +6397,8 @@ 8CFC5233-23C6-49E3-8A2D-7E581AB305BA,EdbCfg 8CFDB8C8-D6B2-40F3-8E97-02307CC98B7C,EfiVariableIndexTableGuid 8CFE04F2-027A-4BA0-A034-6CEC64865B24,SecureBIOCameraSonix +8D05A3A8-8464-4230-8A9F-C3EB968296FA,FmpDxe +8D07B6FB-3C1A-4AA9-A736-7039C8529BDD,PciDeviceInfoDxe 8D12E231-C667-4FD1-98F2-2449A7E7B2E5,EfiSmmControlProtocolGuid 8D1933CD-E806-4D83-9F9D-FF10E64D76D5,ISL95856Pei 8D1AE715-7F82-449D-A26C-62AC650AF73F,Int15PanelType @@ -5700,6 +6418,7 @@ 8D46CE70-B62D-4CF7-875C-BEC8016D7D01,DellTcg2ConfigInfoTpm12 8D48BD70-C8A3-4C06-901B-747946AAC358,EfiIsaHcPpiGuid 8D4A8276-1994-4E82-983A-A71753617797,menu_checked_selected +8D4EF3A5-8958-405D-98C4-ED91B71583F5,H2OEventLogConfigManagerDxe 8D59D32B-C655-4AE9-9B15-F25904992A43,EfiAbsolutePointerProtocolGuid 8D59EBC8-B85E-400E-970A-1F995D1DB91E,IntelSnbGopDriver 8D5EA70B-02EB-48D8-BEAB-459778C5DE1F,SmmConfidentialMem @@ -5713,10 +6432,13 @@ 8DA5D50B-A39C-4FF7-AB4F-7426A145D0E4,RandomNumberGen 8DAA8C2C-5E2B-4158-8ADF-5FACFC0E9B77,AcerLID 8DAC5195-3FD5-4E32-9C2A-1A65BD699932,AmiTseOemPortingVar9 +8DB6415E-1C83-4E8C-BB14-5560B58FC844,EmulationEDID 8DB699CC-BC81-41E2-AAC6-D81D5300D759,PartitionVariable 8DB954AD-047A-459A-AC0F-F3758779F61A,DellMfgModePei 8DBBB229-87E3-4CBC-B2F7-6A54C830D166,HpCableDetect +8DC58D0D-67F5-4B97-9DFC-E442BB9A5648,tftp 8DCE1957-D774-4FDA-B90F-0B231CB2E0CC,DellSmmServices +8DCEEEBB-5741-4092-884D-144EC472682D,PrmAddressTranslateModule 8DD46B11-0403-4B4C-B372-7041CB151834,DellFlashUpdate2Pei 8DD9176D-EE87-4F0E-8A84-3F998311F930,Dhcp6Dxe 8DD9176E-EE87-4F0E-8A84-3F998311F930,Dhcp4Dxe @@ -5727,6 +6449,7 @@ 8DEEC992-D39C-4A5C-AB6B-986E14242B9D,EfiDiskInfoSdMmcInterfaceGuid 8DEFE6CA-2AF0-474E-9642-838282B3C982,BiosAuditLogHandlerSmm 8DF01A06-9BD5-4BF7-B021-DB4FD9CCF45B,EfiHashAlgorithmSha224Guid +8DF39C0E-8170-4415-B7B3-DA2613B51046,EarlyGuidHobPei 8DFAE5D4-B50E-4C10-96E6-F2C266CACBB6,VideoRom 8E008510-9BB1-457D-9F70-897ABA865DB9,EfiLegacyBiosExtProtocolGuid 8E09C390-1B30-415E-AF5C-D42AB0160F8C,AmiCbsDxe @@ -5738,9 +6461,11 @@ 8E325979-3FE1-4927-AAE2-8F5C4BD2AF0D,SdMmcPciHcDxe 8E38A88A-C267-4131-A8CD-C0BC80A24CB5,CbsSetupDxeSSP 8E3C826C-B69E-4F56-95AB-1324DD02E28B,StdBoardPei +8E4318C2-599A-435B-BC14-D9C9FA4172CE,AmdMemChanXLatDxe 8E46DDDD-3D49-4A9D-B875-3C086F6AA2BD,EdkiiVt400 8E477676-55FD-48CF-9210-15A99B27D740,Slp10 8E47929C-C80E-40CE-B013-807FEFC94110,IntelGigabitLanDxe +8E55BB3F-1148-4EA5-BDB6-425E4584FF78,DefaultUpdate 8E57AE62-99DC-4F12-ACB7-216E2DD031AD,DxeCrcInit 8E5C4BEA-34FF-4E32-8358-3363DA01E628,LenovoSystemXhciResetSystem 8E61FD6B-7A8B-404F-B83F-AA90A47CABDF,SmmSmbiosElog @@ -5748,7 +6473,9 @@ 8E68E3C5-FC59-4280-8467-3800D31A8162,IccOverClocking9_5 8E6FEDCA-62B4-4E8F-8C42-9B8F40EF60CD,HpCallbackRegistrationDxe 8E724EB4-F314-497A-84F3-367A47E60910,DellIoExpanderDxe +8E74A1A7-8A76-4D29-9441-3C176018CB9F,SmbusSmm 8E74EFFB-C02A-4320-81F1-4B1114D10910,IntelPpiLayoutLoadPei +8E83304D-5BF1-454B-B111-AC574A5121E7,AsusMyAsusDxe 8E88BF4D-9F15-4206-BBD5-55D368B62AD1,NvmeRecoveryDxe 8E8CBC58-834C-41E3-B8CA-F00CCF5A717C,IccOverclockingProtocol 8E8FB93D-6F87-4CF8-9A9E-DF5B898D223A,MaintenanceLed @@ -5760,6 +6487,7 @@ 8EAE69C2-4079-4B0D-B075-8BA0653A432F,NetworkStackOverridePei 8EB0B9CB-367F-43EB-8E99-3A192CD4F7F3,CrbSmbiosType0 8EB48F19-CC92-4031-8D3D-EE473CCC87EB,SystemPrivateKey +8EB7B229-27E3-4FBC-B9F1-3A245B3AF1D6,HpCableDetect 8EB9B46C-8F80-4E6A-9FBF-EC892FBA2807,SmmAccessPei 8EC24268-E545-4242-B536-04F94C889969,BoardUpdatePolicyDxe 8EC38829-A59F-40E3-BAD0-85F815A157D1,DellServiceResetSmm @@ -5773,6 +6501,7 @@ 8EF61509-890B-4FF2-B352-1C0E9CDDEC8B,I2CLibPei 8F0B5301-C79B-44F1-8FD3-26D73E316700,PowerMgmtSmm 8F163A88-2376-40B3-89F7-AAC73E29E941,HpRemoteDiagnosticsDriver +8F1A65CF-1D27-4354-9F77-4DB764471B4A,AmiOemRasSmm 8F1AC44A-CE7E-4E29-95BB-92E321BB1573,SecFspWrapperPlatformSecLibSample 8F2156F2-887A-4BA8-BEF9-005C16293B7A,AmiMemoryInfoSample 8F26EF0A-4F7F-4E4B-9802-8C22B700FFAC,EnglishDxe @@ -5784,6 +6513,7 @@ 8F439D8B-07B2-4121-AA95-8AC91571FFFF,DellDefaultBootListDxe 8F4B8F82-9B91-4028-86E6-F4DB7D4C1DFF,Bds 8F4CD826-A5A0-4E93-9522-CFB0AB72926C,SataController +8F5572A4-6BF9-4A27-B8B8-85282E0C9C14,AmiApcbSmm 8F5A2E02-538C-4D59-B920-C4786ACBC552,Ahci 8F5C2D02-AF2B-49DE-B8D8-DF90130A2512,FlashMeDxe 8F644FA9-E850-4DB1-9CE2-0B44698E8DA4,EfiFirmwareVolumeBlock2ProtocolGuid @@ -5803,18 +6533,23 @@ 8F9D4825-797D-48FC-8471-845025792EF6,EdkiiS3SmmInitDone 8FAAD0A7-02B4-432F-8F5C-B880965D8B41,SmmCommunicationBufferDxe 8FB38CF8-D25D-4855-8F15-C07A0F6B8EA7,BiosReservedMemoryInit +8FB4CD1D-0660-466E-8ED0-AD723FD7DBAE,AmdNbioAlibRPLDxe 8FB82DA4-C3BE-42A6-8A70-7B94D60972A6,DellSbAccessSmm 8FBECFE2-1313-4CF6-AD2C-D3B9472F62D3,SmartTimer 8FC1FDD4-3876-449B-A41C-6A788495FC78,BiosAttributesMgr2Dxe 8FC6AAAA-4561-4815-8CF7-B87312992DCE,UserAuthenticationSmm +8FD1935A-6A80-4535-B714-C3CBE45A5C5C,PeiSerialTextOut +8FDB0B2D-996F-4C1C-89E0-C32E6DCE6CA6,AmdPspDxeV2Brh 8FDC888D-2162-4971-81C2-35D3A1AA5047,EfiRasMpLinkProtocol 8FE545E5-DCA9-4D52-BFCD-8F13E717015F,AmiReflashProtocolGuid 8FEEECF1-BCFD-4A78-9231-4801566B3567,AbsoluteComputraceInstaller +8FF4D380-8891-4495-AF40-716CD55C07E8,LEMPostLogoDIYDxe 8FF5354A-634F-4637-B3CE-4DF1CE6B56FE,RtkUndi8111H 8FFA88FB-4395-F6B4-0525-93FF277A6215,IfwiId 9006872D-3A86-4BAE-A2F0-E527B9D7119E,IntelLanUefiDriver 900901B9-41CD-4D54-A842-4D559980960B,AmdCpmThunderboltPeim 900C2FE6-679F-4B93-B656-25136FA93946,SelfhealingSupportShowInSetup +901E524A-5A57-4C2D-93A4-74F516E07C07,ClientronServiceDxe 90253CDA-4E1F-4CD6-9EA4-276F8725BDD0,SwSmi534D3320 9029F23E-E1EE-40D1-9382-36DD61A63EAA,NCT6686DPeiInit 9029F23E-E1EE-40D1-9382-36DD61A6791D,NCT6791DPeiInit @@ -5833,18 +6568,23 @@ 905F13B0-8F91-4B0A-BD76-E1E78F9422E4,UdfDxe 9069C144-0A7E-41EF-9C07-418BCA9BF939,AcpiDebugSmm 907125C0-A5F1-11E3-A3FE-A3198B49350C,FvSimpleFileSystem +907303D5-394D-4E7C-A430-7B6A764BDC3C,AmdNbioPcieDxe 9073E4E0-60EC-4B6E-9903-4C223C260F3C,EfiVendorKeysNvGuid 90766A99-9CA5-44DE-94DA-DCC1D2D6DA1F,UsraPpi 907AB054-712B-41BA-930F-2BBFB7F57ECB,DellQuickSetSmm +907AB576-C955-4A95-AE7E-596D2256CC61,OverrideGetVBiosVbt 908C3852-B61B-4F26-AB66-F74F97E7DC1C,AmtBypass 9096EB5B-59D1-49F8-866C-78D24631A6B4,EndOfDxeBeforePciEnumEventGroupGuid 90A06ED8-D514-4CC5-B11C-7743BEE24C55,AmdSocAm4RvDxe 90A330BD-6F89-4900-933A-C25EB4356348,SDController 90B2B846-CA6D-4D6E-A8D3-C140A8E110AC,SystemFirmwareDescriptor +90BD1EF6-F66A-4B4A-9879-B0701B99BC3C,NbBrhRouting 90BF2BFB-F998-4CBC-AD72-008D4D047A4B,PeiTbtInit 90C35CC1-C3A5-4F48-9AE6-922FCE6D827E,LnvWlanPxeBoot +90C5A43A-8513-4695-AF0B-F4AA7FCFB898,TouchPad_Sensel 90C8D394-4E04-439C-BA55-2D8CFCB414ED,SataDriver 90C9751D-FA74-4EA6-8C4B-F44D2BE8CD48,FmpDxe +90C9751D-FA74-4EA6-8C4B-F44D2BE8CD4B,FmpDxe 90CB75DB-71FC-489D-AACF-943477EC7212,SmartTimer 90CBFE5B-9784-44A4-8CB8-C640AEB9EA1C,DellSystemUsbPortConfigSmm 90DADB68-B868-4D62-A07F-09B3B64DA039,Mebx @@ -5858,8 +6598,10 @@ 910A077B-4B23-40FF-8DCD-64685349310C,SoftSkuStatus 910CC93A-F2B7-4630-884D-625D570FACF6,IshCapsuleDxe 910DCA07-1F94-4EE7-AF2F-FF72F3154353,EfiSmmBaseHelperReadyProtocolGuid +911A3B22-8301-4CD8-835B-CC70826D5829,AmdiGpuVbsWA 911D584C-35F7-4955-BEF9-B452769DDC3A,DebugSupportDxe 912740BE-2284-4734-B971-84B027353F0C,FspHeaderFileGuid +912C464D-DDBF-43C0-B725-F1F61EA42875,AmdCpmOemRnInitPeim 913D8F08-0130-4E85-B58E-389CA566C1EC,DellDeviceDetectionDxe 913FA238-7B16-4B72-A5F0-815E7D2C8C1F,AmiTseOemPortingVar24 9140CA7B-CABD-4A09-88F7-0862043CC286,DellSmstTransfer @@ -5870,6 +6612,7 @@ 915CB605-0E96-4C75-B724-53DCBAE7ADB5,DellDxeDiagLeds 9168384A-5F66-4CF7-AEB6-845BDEBD3012,PlatformFlashAccessLibDxe 9173C39B-08DA-429A-BE15-0F7481CF72CE,AMTLockUsbKBD +91797A08-B861-49A6-A271-7ECA11D79025,MemTestPei 91812ACA-332D-4215-B832-45C88FC7DE57,DellDptfChipsetPei 918211CE-A1D2-43A0-A04E-75B5BF44500E,EfiCPTokenSpaceGuid 9189541F-AC0C-4368-9062-70E1957C3445,EfiVirtualLockstep @@ -5892,10 +6635,12 @@ 91CE67A8-E0AA-4012-B99F-B6FCF3048EAA,ArmScmiClockProtocol 91D1E327-FE5A-49B8-AB65-0ECE2DDB45EC,EdkiiDynamicTableFactoryProtocol 91D211BF-37C2-495A-8DF7-9546BD2555C0,PpamPlatformSmm +91D34812-236F-4B8B-B527-27F96A0CC3DF,MTKWiFiDxe 91E7996D-7681-477C-BDFE-AD11447E66CE,RealtekLomSmm 91EFC190-DE79-441F-B57F-BB0F7D8A8B4D,FjM2WlanEnableDisablePei 91F6E9EB-9902-44B3-A487-C8E148D0F4EE,EmcaErrorLog 91F72280-36CC-4BF3-AC40-BC029E4B3177,inf +91FB89E6-F282-49BC-AC80-275E50B7B298,XnotePlatformPolicyFsp 9204A71D-2050-4AB7-AD42-749CF9ADB4EB,Lpc47N20x 9205CDE5-5AE5-4A4B-BFBF-F6211967EEF9,LibLocale 9210E52A-729E-4817-85C8-F45500CE24C6,PchLpcSmm @@ -5917,10 +6662,12 @@ 927AE345-BB7B-434F-8D29-71BE0D12AB2C,AmdFabricZpDxe 927D36AB-C278-4EC5-B2F3-8BAA4B8E1F34,FjGabiSystemDataEventLogAbstraction 9282ED2E-F8CE-CA47-AF50-3542332F7D53,AppleDnsResolver +92854555-35E8-4AB2-B0E2-CF56C9F4DE18,AXUsbUndiDxe 928939B2-4235-462F-9580-F6A2B2C21A4F,QemuAcpiTableNotifyProtocol 928EF6D4-72BC-4686-B57B-1EEB6ABD4F93,AcpiReset 929189C9-0670-4C0B-AF7D-135D1550C8C0,RecvDgram 929E8A68-0FB6-4F20-AC5E-D294C50B1CBB,TcpConnect_DXE +92ABFB76-D724-4585-A513-EB5FF3EB1C5D,AmdCpmSharedBPei 92AC65A1-8D72-4451-9FF6-EAB508C319AB,OemDxe 92B144D7-A2DF-481F-9BD7-8A7968638EB5,PcdRecoveryPreserveData 92B7896C-3362-46CE-99B3-4F5E3C34EB42,UniversalPayloadSmbios3Table @@ -5936,6 +6683,7 @@ 93022F8C-1F09-47EF-BBB2-5814FF609DF5,FileSystem 93039971-8545-4B04-B45E-32EB8326040E,EfiHiiPlatformSetupFormsetGuid 930C273B-A875-4713-9373-F12E8483E125,IntelGigabitLan_I210 +9310979D-A58F-413E-913F-5E9294D8ED2A,SetupCheckSumListInit 93145CD2-7B23-4516-BB23-E338CB2D2748,HddIdentifyDxe 9317EC24-7CB0-4D0E-8B32-2ED9209CD8AF,EfiPaddingRsassaPkcs1V1P5Guid 931E1E51-83DD-427F-B5E0-5F25E2C504A8,AdapterWarnings @@ -5949,6 +6697,8 @@ 93570BE6-3AD5-45C8-8FA6-9A8633E22D2B,DxeCallback 935D2F78-3A1F-4DE6-B28D-123A40DD2DEC,SmmGenericElog 93677DE0-9A9B-47DF-8674-60E76858AEAB,AudioSpeakerIdm +936A2417-D1FE-4BF3-974A-EC00CE20A064,PeiPostStart +936DADBA-EB50-458B-A896-C7A28C010398,ClearPasswordByRtcRemoval 93755C1C-BE15-4D5A-BF95-5F9753853CB6,FileSelectUIDxe 937710D0-EF10-42BE-92E1-8494722B17B5,DellDirtyShutdownDxe 937FE521-95AE-4D1A-8929-48BCD90AD31A,EfiIp6ConfigProtocolGuid @@ -5958,6 +6708,7 @@ 93B80004-9FB3-11D4-9A3A-0090273FC14D,PciBusDxe 93BA1826-DFFB-45DD-82A7-E7DCAA3BBDF3,SmmVariableWriteGuid 93BB96AF-B9F2-4EB8-9462-E0BA74564236,UefiOvmfPkgTokenSpaceGuid +93BBA9CE-F020-4740-8B4E-9ECCE3909CCD,AmdMemFp8StxPei 93C81A74-B648-4F7F-925E-E4A0CDCC776D,VlvInitDxe 93C95FC4-B741-4587-9304-1C5A2BE6F742,ApplePlatformSecurityPolicy 93CFC972-6B9F-4031-A542-C7299F126924,FjNuvotonNct6796Pei @@ -5968,6 +6719,8 @@ 93F1025B-B6D4-4F2F-A4A9-A4ABA0CF604F,aDefaultDxe 9400D59B-0E9C-4F6C-B59A-FC20009DB9EC,AmiPciIrqProgramGuid 9401BD4F-1A00-4990-AB56-DAF0E4E348DE,AmiHddSmartInitProtocolGuid +94118D41-65A5-497C-90A1-9D78591C797A,AmdNbioPei +94223E4B-D03E-40CD-82D5-0443158B22F9,OemSetupScreenSyncVariable 942681AC-4F3D-46AC-9AEA-D4F25F21248A,FjMeFwUpdateOdm 942F8076-3335-4EF9-93CC-74A470263DDA,SetAutoUmaModeSmm 9437D7F5-6D31-4494-9A4B-F6EEB21B6CC3,SioScriptPEI @@ -5985,8 +6738,10 @@ 94813714-E10A-4798-9909-8C904F66B4D9,NvmExpressPei 9487D2AF-B394-4119-A981-CE133B11DB7A,BoardModernStandbyDxe 9487D2AF-B394-4119-A981-CE133B11DB7B,BoardModernStandbySmm +948FA1ED-F8D0-4ECA-81B4-194D8364CCF6,AmdSocSp6ShpPei 94925FB1-EEF4-41ED-BD7A-CDB04AAA81C7,DellSbAcpiConfig 949822BC-26D3-4BC6-954B-F2C581342DE1,SystemXhciDxe +9498F6C5-1B77-4AE7-A045-DBC29EB5541D,StatusCodeLoggerDxe 94AB2F58-1438-4EF1-9152-18941A3A0E68,EfiSecurity2ArchProtocolGuid 94B9E8AE-8877-479A-9842-F5974B82CED3,EfiBoardFeaturesGuid 94C0203B-54C9-416E-A6E0-47E8D4786901,EfiPeiPlatformTypeLightningRidgeExecB3Ppi @@ -6012,19 +6767,23 @@ 952821AA-EACD-465B-B478-5429DFC9A747,OA2 952CB795-FF36-48CF-A249-4DF486D6AB8D,EfiTlsServiceBindingProtocolGuid 952EEE95-A6AF-43DA-A559-F349A46D710A,SimpleBootFlag +95367732-2D61-4A2E-A5B0-B8A143DC9303,ClientronDxeDriver 95409D5D-0A41-4258-8A99-810A22126BBE,OemSmbios 9546E07C-2CBB-4C88-986C-CD341086F044,EfiDebugSupportPeriodicCallbackProtocolGuid 954B4980-FF90-4B02-977F-91292251A3E3,DellAutoBifurcateBoardCfgDxe 954E2958-EBB2-4687-B98F-844DF4FAC63A,CompalSsidSvidDxeProgram 955C708E-B46A-488B-9D5B-D7E61D0F9609,SmbiosDataUpdateDxeEVB +9566132D-C678-484B-9B56-D4CF3F4F690F,MetroMsgDxe 956A2ED0-A6CF-409A-B8F5-35F14C3E3C02,EfiIderControllerDriverProtocol 9581983A-3663-46F0-83EC-8A0506EB63E7,BiosInfoChecker 9588502A-5370-11E3-8631-D7C5951364C8,AndroidFastbootApp 958AC2CA-9904-43AA-B9DE-35E5D4C41217,EfiOdmemGnvsAreaProtocol 95924E18-771C-42A9-B885-BEDDB60D2D38,LenovoSmmKeyboardConfigProtocol 95A1046F-5EA7-4C6D-86A7-AA91B7421E68,CspFlashPeiLibNull +95A7DF51-966F-499C-BCAB-9C2422C0D3D2,FchI3cPei 95A9A93E-A86E-4926-AAEF-9918E772D987,EfiEraseBlockProtocolGuid 95AF7E4D-C45D-47FF-AEB2-D9BC13466B3F,AppleAhciController +95BA4462-7EF0-49A3-9702-6896C39E414C,CbsSetupDxePHX 95BF86AD-A1E0-4143-B487-004B1C2E05FA,DxeCmosInit 95C051C5-F123-432E-9383-B9CF113F082E,LenovoTcgServicesSmm 95C3AB19-59C2-4418-A35F-CAB8724F8028,USRATraceLibNull @@ -6037,11 +6796,14 @@ 95DFCAE5-BB28-4D6B-B1E2-3AF3A6BF434F,PTID 95E3669D-34BE-4775-A651-7EA41B69D89E,Dhcp6Dxe 95E8152B-1B98-4F11-8A77-DB26583EBC42,AmiPeiSbInitPolicyGuid +95E89B6F-73DF-47E1-8F9B-DE52BDD37F53,OemPcdUpdate 95EB69CA-0240-49F1-B03C-D5F9C19C00B8,MeUpdateFaultToleranceDxe +95EBEE68-F645-4866-9BA9-51D3EEB3B650,FmpDxe 95ECB758-627E-4A2E-B7B8-DC863EFE3425,AmiDeviceGuardApi 95EF106E-469F-41D8-AFFF-CA5292A4D97C,AEPFreezeLockDxe 960241A5-5CE6-4EBF-B9C4-E37D294BEBA9,FspWrapperPeim 960C2719-4FDE-7E4A-44C6-26A6B2EFE9B2,SmmNvmExpressCsm +960CEA3A-20E6-4D33-AAAD-C9BD3CA5961D,TmeInitDxe 96107C8E-9490-4767-9D0D-5590F1F6E1FC,PhysicalPresenceDxe 961578FE-B6B7-44C3-AF35-6BC705CD2B1F,Fat 961578FE-B6B7-44C3-AF35-6BC705CD3B3F,MacMiscDxe @@ -6055,6 +6817,8 @@ 966DFABF-A140-4BBA-83CA-12021090BB44,DxeIchSmbusLightDxe 96735D5D-4595-4183-B1D7-934CC402AA95,ramdisk 96751A3D-72F4-41A6-A794-ED5D0E67AE6B,EfiCcMeasurementProtocol +967CFBD0-DF81-11EA-8B6E-0800200C9A66,FlashPei +967DF566-4DB7-3D52-39EC-1B9F450D5ACD,Sff8472Dxe 968BC767-031B-4798-FFFF-FFFF1EE81120,XnotePlatformInfoPei 968C1D9F-80C4-43B7-8CAE-668AA56C4E71,SmbiosPeim 9698CA50-54BB-4B43-B1CC-EC1338B7D767,Mec5105InitPei @@ -6068,6 +6832,7 @@ 96D4FDCD-1502-424D-9D4C-9B12D2DCAE5C,MicrocodeFmpImageTypeIdGuid 96DED71A-B9E7-4EAD-962C-01693CED2A64,I2CPeiInitGuid 96E198EC-CDBC-4C21-9743-EB4577648E59,IccDxe +96E9CA61-6C2E-4FF3-B265-F21904C44181,CbsSetupSmmSTP 96EB4AD6-A32A-11D4-BCFD-0080C73C8881,EfiWinNtIoProtocolGuid 96F1AC24-2B21-45FA-A0B5-67010C95E9D8,AhciMmioSmm 96F46153-97A7-4793-ACC1-FA19BF78EA97,EdkiiPeCoffImageEmulatorProtocol @@ -6101,6 +6866,7 @@ 978FE043-D7AF-422E-8A92-2B48E463BDE6,EfiKmsFormatGeneric512Guid 979333C2-DF0B-48EC-88A7-88A7E6E5479B,FjSmbiosEventLogDxe 97A03375-250D-4C59-93A8-F76796725E18,AmdApcbRvSmm +97A0429F-3945-485B-8336-1C5274713F03,AmiPspPei 97A20DF5-6F57-4C76-9095-0F6439F8A81C,fTPMTisDxe 97AF1D95-203C-42DE-8D6B-D13EB7E5A55A,PEFirmwareUpdateDxe 97B1CDCE-AFBB-42F5-9328-1CFEFE912E66,IncreasePcieIdleFanSpeedSmm @@ -6135,9 +6901,10 @@ 982ECA04-0492-4AF0-9C6E-354A3BEAC9FF,HpCoreBootOrder 9842073D-95D9-9F49-BD3F-2E29525125DF,EmuBusDriver 984820B1-6D76-46C2-8146-25F245663D17,EmuPciPei +9848733F-B8A1-4B80-B548-D6C0A569C088,AmdPspDxeV2StxH 9851740C-22E0-440D-9090-EF2D71C251C9,AmiCmosAccessDxeProtocolGuid 98538A96-6116-4BE1-A609-BBCCCC2E0D15,VariableProviderSmm -98584C0B-49D6-4BAF-B542-ECEE2582409C,ASUSBackup +98584C0B-49D6-4BAF-B542-ECEE2582409C,AsusBackupDxe 9859BB19-407C-4F8B-BCE1-F8DA6565F4A5,AndroidBootImgProtocol 985EEE91-BCAC-4238-8778-57EFDC93F24E,MainFormSet 9870A4C5-C65E-4D84-AE30-855348AF07C7,FjErrors2Screen @@ -6157,8 +6924,10 @@ 98B29A61-827F-4A28-B1AE-3B00A978537E,OemPeiSetSetupItemPcd 98B5B58C-E2E8-4A06-AACB-E4CE316C2B68,DustFilterReminderDxe 98B8D59B-E8BA-48EE-98DD-C295392F1EDB,EfiConfigFileNameGuid +98BA1A5C-DAF7-451F-829E-698D08ABC065,FchI3cConsumerSPD5Dxe 98BBCDA4-18B4-46D3-BD1F-6A3A52D44CF8,SmmAccess2OnSmmAccessThunk 98C281E5-F906-43DD-A92B-B003BF2765DA,PeiNtThunkPpiGuid +98C5594F-9759-11E2-9F93-047D7B99E097,SecureBootService 98C80A4F-E16B-4D11-939A-ABE561260330,EdkiiCapsuleOnDiskName 98C8588C-640A-4BB4-AEA0-3F81CDE17524,FspDxeIpl 98CC7CBA-90DC-4A70-8EF0-2A66222886A2,EsrtConfigPreserve @@ -6190,18 +6959,22 @@ 996EC11C-5397-4E73-B58F-827E52906DEF,EfiVectorHandoffTableGuid 99796403-CF03-42EC-A817-7183411D79E2,PchSmbusDxe 997FB7DF-DB23-40ED-A807-9612D2F4A3E8,TopSwapRestorePei +99846A70-614D-4062-820E-2473E4E128E3,FchEspiCmdSmm 999ABACA-3D6A-82B5-B562-12CC4F33DE57,DellDptfExtraGnvsArea 999BD818-7DF7-4A9A-A502-9B75033E6A0F,EsrtDxe 999E699C-B013-475E-B17B-F3A8AE5C4875,EdkiiDebugPpi 99A1E3F5-0887-43C7-B00A-F14A646BC142,DellSbSmmHooks 99A45B83-0BFB-4C38-8835-D59571010103,MAPS_DiagLEDDxe 99A96812-4730-4290-8BFE-7B4E514FF93B,EfiGlobalVariableControl +99B0F38D-1F27-4F46-9F44-42D694722882,AmdCpmMemEyeToolSmm 99C062A1-A4DF-4E99-813B-C283E1EFE761,SbSocRenoirDxe 99C078B7-D7D1-4EE2-B585-CC64A309640A,FjEvte 99C20A37-042A-46E2-80F4-E4027FDBC86F,PlatformSmm 99CA20D6-3BF8-4E90-A430-C6FDCC5A8E80,OemRaidDiskInfo +99CE8846-DB18-4D9E-B3BE-8B96E1CD55CE,SioMec152xPei 99D5757C-D906-11E0-8D78-8DE44824019B,PchEfiRaidDriverExecution 99D6037C-D317-4AF0-B0D2-3959530E6B16,CollectPOSTFlag +99DF8490-F92E-4A45-8A3E-A80C85D32826,SataEraseDxe 99E06CA1-3779-48B4-8D0A-8A496230E10F,NetworkOfflineLockerSmi 99E275E7-75A0-4B37-A2E6-C5385E6C00CB,AmiMaskedDevicePath 99E7FEA1-9A6F-4D68-A754-30793B78A738,RasInit @@ -6215,16 +6988,19 @@ 9A069A23-836F-41DF-AF02-F14BEC97DE72,FmpDxe 9A07118A-768D-449B-97D0-6ADC8F2B0244,CpuMpPei 9A08BC1A-7561-4A68-8875-C0977C91573C,NetBootUI +9A09E60C-50F2-4602-9248-1F29382DDF3B,AmdCpmAudioFeatureDxe 9A29BBE9-74BB-41D3-BCAE-6B086E0FE0C5,SmuV11DxeVMR 9A306620-F506-46C6-A095-30F75040AE79,SystemAhciPeimPei 9A44198E-A4A2-44E6-8A1F-39BEFDAC896F,EfiCustomizedDecompressProtocol 9A473A4A-4CEB-B95A-415E-5BA0BC639B2E,EfiRegexSyntaxTypeEcma262Guid 9A4E9246-D553-11D5-87E2-00062945C3B9,EfiStatusCodeDataTypeDebugGuid +9A5163E7-5C29-453F-825C-837A46A81E15,SerialDxe 9A54122B-F5E4-40D8-AE61-A71E406ED449,ChaosKeyDxe 9A55DA14-D845-4B3D-92DC-332143CC5C1C,HDAudioDxe 9A595246-6F53-4526-B856-3C0667F4DA67,LEMAllDriversConnectedEventHook 9A5F2711-B97F-4D5E-B111-265652D44587,WolPwrControlSmm 9A61F154-4A83-B8C5-80DE-239BFF40D66B,AmdRasDxe +9A6C1378-802C-4969-8C7B-85DFFBE82DF4,IntelPcieUndiDriver 9A6DC1AC-94C0-43B1-8714-4C70FD58A815,BaseS3BootScriptLibNull 9A6F58B2-7444-4EBA-8FAD-A033EF79ACDF,SecureBIOCamera_Sunplus 9A713C0D-2053-44AC-9D4A-E7933C4205A9,EcIoDxe @@ -6244,9 +7020,11 @@ 9AB332EF-81D9-43D1-867A-03DD574E8566,DellBbsmanagerDxe 9AB86388-95F2-4F69-ACDC-E1749E5409F0,VariableCheckerSmm 9AB9A129-B8FA-4045-BB05-48DBCE724F82,HWMINIT +9ABCBDDF-A4B5-4FDC-93F2-52AE580A49CD,BootDeviceInitAttributeDxe 9AC8B567-5FDB-46E5-8B12-ACFC4B24C5EC,OemDataRegionRestore 9ACC38D2-959B-490C-90EA-723D9D902108,AmdMemAm4SspPei 9AD125EF-A62E-4B76-86CE-18252861266E,AsusWifiMtk +9AD981C0-735F-11E3-A4C4-047D7B99E097,SwSmiInterfaceCoreSmm 9AE51047-E0B9-4A50-9E72-84E359D20189,OpromUpdateDxeLightningRidgeEXECB2 9AF1DA25-F06C-43BB-BE88-834550BF765B,DellGSetConfig 9B013FF3-31D2-4693-83E6-60FA0C73F0F7,CompalCommonHookSmm @@ -6254,11 +7032,16 @@ 9B0FF2C0-E245-11E1-8EFF-D0DF9A35C106,ChipsetSvcDxe 9B1531F9-FB32-49AC-A8CB-C78B11DC746B,RTL8153 9B182CEE-AED5-4D95-B2A9-A2CF6CDFEAA8,OemAcpiPlatform +9B2031FD-5759-4E8D-8DF5-2DDE44797EBF,DxeFlipToBoot 9B243EAD-77D0-4354-B78F-70B39AA48F0D,SystemVspBcpSmm +9B2756FC-BB82-44D8-9F2B-BCFCA688E3C1,NvmeInfoDxe +9B32B55D-D4D1-4329-B787-5A027B0ACE49,FjSwitchOnboardLANControllers 9B3ADA4F-AE56-4C24-8DEA-F03B7558AE50,PcdPeim 9B3F28D5-10A6-46C8-BA72-BD40B847A71A,AmiTcgPlatformPeiAfterMem +9B4236D3-34E5-4E36-A7F9-0AC8B7705160,CnvVfrSetupMenu 9B4BACCB-55C7-40F8-8439-13E3EB729B3F,BATMonintor 9B517978-EBA1-44E7-BA65-7C2CD08BF8E9,EdkiiPlatformLogoProtocol +9B5E3ADA-8B4C-4262-9D08-B1AC2B6585C5,HdaBeepRltkAlc3146 9B680FCE-AD6B-4F3A-B60B-F59899003443,DevicePathDxe 9B69E973-CBDC-4035-9AE8-EC9C7617FA28,LEMPostFlagProtocol 9B6EECF6-FBDC-4DB6-9562-D25F40D57661,MicrocodeLoaderPpi @@ -6280,12 +7063,16 @@ 9BD36F4F-08DC-4EAB-8637-2BC1BD5E0D95,EfiRasClvTester 9BD4232A-E5B0-418C-9ABD-B0B8574F138C,EcStorageAgentPei 9BD56875-85E9-4510-9DC0-1F842608591F,FjGpioGeminilakeDxe +9BE4D575-B6F1-4AC6-91AA-E2A7376D5A26,ASRockHDAudioPei 9BE82016-23FD-4ECE-826A-55A683A25F0C,SioFlexIoSmbiosDxe +9BEA1D1C-D130-42FF-BBFB-1B9DA3933DDD,SecureBioXhci 9BEC7109-6D7A-413A-8E4B-019CED0503E1,AmiBoardInfoSectionGuid +9BF0A5F3-36DD-4CCB-B05A-8D70F6F78ADF,ExpansionSlotConfigPortingDxe 9BF253B5-B562-4EFC-9891-50B322BE766C,AddSmbiosForNFA765 9BF467DC-DF4E-441D-8356-C3863D6645D9,AsusFMPDxe 9BFE0707-8174-4B8A-A5F5-556FB10E8843,RTCWakeup 9BFF300D-D647-480E-9FF3-2006D3D7CCC6,DellMultiDisplayDxe +9C080BCC-38EF-4F9F-BDC1-B2F5D11E9CB7,SyncSagVariable 9C0AAED4-74C5-4043-B417-A3223814CE76,ArmPlatformTokenSpaceGuid 9C0E458D-EAE7-1234-A3BA-3CE1CC335168,AmiHidServiceDriver 9C0E458D-EAE7-4191-A3BA-3CE1CC315168,HidKeyboardDxe @@ -6299,6 +7086,7 @@ 9C4D5E0C-1C12-4BC5-83D4-E671BDD61E40,DellServiceOsInterfaceSmm 9C4FB516-3A1E-D847-A1A1-7058B6986732,EfiEmuSystemConfig 9C53CE0E-0E9F-4F20-B1A1-150E4349D777,Tpm12PPILockOverrideguid +9C5835AB-E86D-48A9-95D0-3735B75F82F6,LnvAMDArmor3 9C5F9A77-DB16-4174-8E30-AA0BE19BC1FE,H19EmmcSecureErase 9C5FA4C6-746B-40A3-91CE-EC045F9D3716,SmbiosRecoveryDmiEdit 9C72F7FB-86B6-406F-B86E-F3809A86C138,AmiSmmDummyProtocolRedir @@ -6310,6 +7098,7 @@ 9C91D86F-DDA2-477D-B122-1660C585CB9F,DellCpldUpdateDxe 9C939BA6-1FCC-46F6-B4E1-102DBE186567,EfiAcpiDisDispatchProtocolGuid 9C98C00A-2E9B-4896-95C8-AC64358284E5,AmiDxeHashInterfaceguid +9C9E1444-A361-44F9-9888-F87517124B1A,SioSsdtDxe 9CA93627-B65B-4324-A202-C0B461764543,EfiPeiSmbus2PpiGuid 9CB0F5CC-B0F3-4ADD-8583-3C8AF6C00DE0,DxeS3BootScriptLibS3SaveStateProtocol 9CB2E73F-7325-40F4-A484-659BB344C3CD,SgxPolicyStatusGuid @@ -6321,6 +7110,7 @@ 9CCA03FC-4C9E-4A19-9B06-ED7B479BDE55,EfiSmmPeriodicTimerDispatchProtocolGuid 9CCFE1AC-784C-463D-B145-396D7014D559,VideoInitPeim 9CDA2EF0-EBCA-499C-A193-95B468625528,EventLogDxe +9CDD2B26-2411-4637-BAEA-A1A8F197B1DC,AmdMemSh5Pei 9CE4D938-9C87-41D0-9E55-34923FAF8B4F,AmiPeiNbInitPolicyGuid 9CF0F18E-7C7D-49DE-B5AA-BBBAD6B21007,AmiCallback 9CF30325-DC5C-4556-A8B0-74215C5F7FC4,HeciPei @@ -6347,7 +7137,9 @@ 9D60F495-DBF2-4B06-AFCA-F62C1C89647F,PasswordLockWhite 9D7A05E9-F740-44C3-858B-75586A8F9C8E,dbxVar 9D7AF408-64A3-4AF4-83C9-2D1095F700D1,CpuMpPei +9D81AC84-25F7-45CE-83D0-886EE0334398,MTKSupp 9D8243E8-8381-453D-ACEB-C350EE7757CA,StartupMenuApp +9D83F169-17C4-4E7E-90A7-6381A5C21831,ClientronSecureBootDxe 9D8964FD-9CF1-427E-AF66-80054E949DC0,DellSecureBootDxe 9D933189-EEE7-457C-981E-581C1A639FC3,AbtExtendedMessageProtocol 9D94D324-0D45-407D-9337-734CF92C0EF2,KeyboardConfig @@ -6356,6 +7148,7 @@ 9D9A39D8-BD42-4A73-A4D5-8EE94BE11380,EfiDhcp4ServiceBindingProtocolGuid 9D9F2522-242C-439B-A9AC-248DFE244639,FcclSmbios 9DA34AE0-EAF9-4BBF-8EC3-FD60226C44BE,EfiResetNotificationProtocolGuid +9DA54910-78B9-CBE5-725C-87E49C07471B,WtGetEdidDxe 9DAECAB8-AFB8-40D3-80CD-3545D5025DBB,CpuSmm 9DB1BC64-D6CD-4005-923F-94045B3F1F73,SecureBioFw 9DB2466C-4E61-49CE-9AFD-789AE72C8F5D,HpLibArchiveDriver @@ -6364,9 +7157,12 @@ 9DBD72F9-BDFC-4A4E-862B-331F91983234,SetupVarStructCheck 9DC0DDAA-56BD-447A-95CC-5180433110F9,menu_top_left 9DC1A3C2-EA96-4E3A-840E-9840A247F0A1,ThunderboltDxe +9DCACA24-81F8-43EC-91CA-25CC68F67583,AmdPlatformRasRmbDxe 9DD92425-6737-45CD-829C-1AC2CD20C873,LenovoAt24Rf08EepromPei 9DDF1845-E5CA-452B-B105-17C87FE293E0,SceBootOrderSaveRestore +9DE698D3-491E-4F9A-842D-0D9E9785AE18,PerfTunePei 9DF83401-C0A9-4FBD-BE58-986493837BE8,FjFlashMapSmm +9E039967-FB3B-4BE4-83AA-F72F309E481E,EventLogDxe 9E0C30BC-3F06-4BA6-8288-09179B855DBE,FrameworkBdsFrontPageFormsetGuid 9E0D9B8A-1D50-448F-8FC6-12F32218A346,IT889XPei 9E140B52-A636-4E66-A060-7DDE153B5E9B,HpTbtSetup @@ -6394,30 +7190,37 @@ 9E7C00CF-355A-4D4E-BF60-0428CFF95540,BaseSerialPortLib16550 9E85F0D5-5185-482B-8D50-5671307FEA80,AppleDiagnosticVault 9E863906-A40F-4875-977F-5B93FF237FC6,TerminalDxe +9E876632-FBB4-41B7-9800-30E0B4E8273F,AmdSmmControl 9E8AD3F4-383D-4EC3-816E-7A4749371290,FvbSmmDxe 9E8DD95D-868B-41A4-966C-107338C291BB,SmbiosDataUpdateDxeLightningRidgeEXECB2 9E90E60F-FD1E-4B01-BA6E-9FDE5A02E60B,DellConnectionMgr 9E9F374B-8F16-4230-9824-5846EE766A97,EfiSecPlatformInformation2PpiGuid 9EA28D33-0175-4788-BEA8-6950516030A5,SmBusPei 9EA5DF0F-A35C-48C1-BAC9-F63452B47C3E,LenovoSystemCapsuleRt +9EA6AFE6-6E5B-4F9E-A1E6-86F049033834,ReportStatusCodeRouterPei 9EA6D6D7-7CD0-4695-AD99-4D32E93577A5,BrightnessHardwareVbiosNvidiaSmm 9EADE774-C736-493E-B2A1-9CE0415861FA,AmdXgbeWorkaroundPei 9EBA2D25-BBE3-4AC2-A2C6-C87F44A1278C,PasswordUI 9ECD1C5A-90F2-471B-8419-1DB62BD9CC27,FjImonCalibration 9ECD3C5A-90F2-471B-8419-1DB62BD9CC27,SmscUSX2064 9ECD3C5A-90F2-471B-8419-1DB63BD9CC27,FjSmbusProgram +9ECD574F-CB36-4A9A-B2AE-E98B2762572E,FjMeIshDxe 9EDAD122-904B-4150-9AC6-B94653750453,AcChargeBeepSMI 9EDCBD06-3C78-4822-BD6E-A6847F7531C4,FastBootTseHook 9EE045D9-C35E-4967-8469-6C7E74508168,FjGrasscarryPartition +9EE045D9-C35E-4967-8469-6C7E74508169,FjRecPat 9EE41A8C-C112-4E4F-B2F0-65D0F9B133DB,DellPasswordPolicyExtSmmProtocol 9EE4CD62-7FA7-4183-9012-F6C4CF6E2C7D,NVBIOSINFO 9EEDA353-2930-46CB-A023-03E4E358A90C,FchPromontoryPlusSmmInit 9EF82BFE-707F-468F-A944-A61626E47DC9,AcpiGlobalVariable 9EF8C276-B3E6-4AD9-8FE7-C74F71C47248,AAFTblSMI 9EFE0B7E-27E8-46D5-8387-CDDAFD2C3A67,ASRockNetDnsBin +9F00131E-5248-44A6-BF84-93ED18E1780F,SioMec152xDxe +9F0053CA-35CA-4DF3-A45E-8C8FA8D1023E,TouchPadDriver 9F048812-A546-4C85-A5CF-A0785423705D,SystemConfigUpdate 9F1D2270-2E0F-4D07-9477-587989B8A32C,InterWifiDriver 9F1D2270-2E0F-4D07-9477-587989B8A32D,NetworkDevice +9F2171EC-7D0F-460F-915D-C58A0F7E6764,AmdNbioPei 9F3A0016-AE55-4288-829D-D22FD344C347,AmiBoardInfo 9F3A0016-AE55-4288-829D-D55FD3AAC347,AmiBoardInfo2 9F3A00FF-AEFF-42FF-82FF-D22FD344C3FF,IrqBoardInfo @@ -6428,6 +7231,7 @@ 9F5E8C5E-0373-4A08-8DB5-1F913316C5E4,LenovoSecuritySmiDispatchProtocol 9F606D27-E218-4112-834B-8ABCE950B1FB,SmbiosRpTable 9F6D574F-CA37-41DB-8E4B-78106A338813,SwSmi534D0C40 +9F732236-7A4E-4F27-9EEB-AB579F8F7A47,AudioPlaybackSmm 9F7DCADE-11EA-448A-A46F-76E003657DD1,VariableSmmRuntimeDxe 9F81528C-3E31-420D-A9E8-074FD1C2C22A,HpKeyPressTrigger 9F83F5ED-F407-4BD3-9B16-DC27A7016BBD,PlatformFirmwareVersionDxe @@ -6446,6 +7250,7 @@ 9FB4B4A7-42C0-4BCD-8540-9BCC6711F83E,SystemUsbMassStorageDxe 9FB63BF9-B522-4203-9A53-20EC854A312A,DellDaNonVolitileStorage 9FB6793F-7008-4963-AED6-35AFB265DF60,FjGpioGeminilakeSmm +9FB8AC55-D266-4F86-AC43-BF2BA74F5A7A,AmdCcxZen5Dxe 9FB9A8A1-2F4A-43A6-889C-D0F7B6C47AD5,EfiDhcp6ServiceBindingProtocolGuid 9FBFB853-7098-4929-B262-43537D88A414,SystemErrorCheckPEI 9FC7B519-3522-4A71-BEB6-F99F5B2DBF92,VgaConfigurationReadyToBoot @@ -6457,6 +7262,7 @@ 9FE02F9C-5BDA-4971-A918-B79451B43E43,FmpDxe 9FE09C87-6FD8-4063-8EBE-6809EF5EABC5,HpCompressDecompress 9FE0FCFF-B023-49A1-A2C8-ACCE1AA010BB,FboSmiFlashLink +9FE10324-D10E-4CF2-99C4-F1B5A0B4732A,PostMessageSmm 9FE1D71B-3F91-4103-AE62-3FEECA4D2BAA,SpiFlash 9FE6A332-1A1F-43E3-BD25-F7891C6FC74A,EfiBmcSelfTestLogProtocol 9FE7DE69-0AEA-470A-B50A-139813649189,KekVar @@ -6491,6 +7297,7 @@ A071C476-F78C-41C2-A173-B43D699A2C80,AppleEfiSocShutdown A07B3BDF-B78A-41EE-A276-55C225A07B0B,EfiPeiPlatformTypeOpalCitySthiPpi A07D8A73-D4F9-4AA0-BC25-391CCFC47E98,I2cControllerTemplate A08276EC-A0FE-4E06-8670-385336C7D093,x86Thunk +A08CD08E-CA79-445A-AB1B-A5BB039B569E,I2CSpeedPei A0A13495-A2BF-44E1-98F8-CC08D1AE604A,OemPeiSetGpio A0A3FEC9-FE9D-4CE7-8DB4-9C54F3F19E5A,HpSetup A0A8D728-BC2D-483F-B583-28489B77C8F6,FprSynapticsPrometheusDriver @@ -6501,6 +7308,7 @@ A0B852E0-4842-4222-8964-C82EDCFF0D6B,AsusUsbChargeSmm A0B87E92-6392-47FE-9AA0-90203147EC04,DellHddPwSmm A0BAD9F7-AB78-491B-B583-C52B7F84B9E0,SmmControl A0C0B7EF-99FF-417F-8B9F-5AD4701D90D6,Tpm12DeviceLibAtmelI2c +A0C3B7DC-4E19-48EC-A8C7-BA58E2E08FF4,AmdCpmOemInitPeim A0C6D314-97B1-4FB5-ADCE-05138A2B5D00,FjHddEraseDxe A0C6D918-8DEE-41BB-9D92-6753A572B652,EfiTpmStateInitHub A0C98B77-CBA5-4BB8-993B-4AF6CE33ECE4,Tcg2Pei @@ -6519,10 +7327,12 @@ A1147A20-3144-4F8D-8295-B48311C8E4A4,ArmJunoTokenSpaceGuid A11585B7-8FA2-4F1C-AA6F-DD6309469613,MeFwUpdLcl A11A707C-EB9A-450F-8CB6-9284B56A9F80,FjGabiEntrySmiDispatcherSmm A11D8F9F-2A52-40BC-9B82-BCCD7D281EEA,PchGpioUnlockSmm +A11F5FED-63A1-414A-B8FE-FB2184C242FD,HpDtPrivateWmiSmm A128BD92-E5D3-4A8C-A902-559989BDCA05,DellPermanentDeviceDisablePei A134273C-0429-4B93-A30C-305D5EC22DB5,KEMhGpioAccDxe A1445693-5659-030E-C256-42A1868A6D9B,MktmeCoreInitPeim A14694E4-78DF-4EF1-A118-7654FF6CFA9D,IpmiSdrReader +A14AEEAA-C07B-4846-BF54-C4943783EBCD,FchSmmDiagDispatcher A15E7FDE-9D23-4A61-B3FE-E02B30BD80E6,ADCLOMUEFIdriverDxe A15EE4CD-C21C-44D2-9547-2F49869FB9D3,LenovoTpm2ConfigPei A160BF99-2AA4-4D7D-9993-899CB12DF376,MmCoreDataHob @@ -6534,12 +7344,13 @@ A17EF0D6-52A0-4B70-8FAB-FC60E81C396F,FchDxeAux A17F4A89-5F19-444F-B7BE-48195E0575DB,SmbiosGenDxe A17F8AAB-42F9-4D94-82CD-A099E1DD52DF,BootTimeDxe A18596AC-1FC5-478D-BF14-0B415813D71F,Ohci -A1902AB9-5394-45F2-857A-12824213EEFB,MSOA +A1902AB9-5394-45F2-857A-12824213EEFB,AsusMsoaDxe A196BA47-8ED3-4188-A765-FA964DD7ED7A,LenovoSystemErrorLogDxe A19832B9-AC25-11D3-9A2D-0090273FC14D,EfiSimpleNetworkProtocolGuid A19A6C36-7053-4E2C-8BD0-E8286230E473,PciHostBridgeLibNull A19B1FE7-C1BC-49F8-875F-54A5D542443F,CpuIo2Dxe A19FB0EE-05F4-4CD6-8F28-59B782FF95C6,PciExpress +A1A38D16-5CD1-4109-BE88-BF0DB27A9838,CbsBaseDxeRPL A1AFF049-FDEB-442A-B320-13AB4CB72BBC,EfiMdeModulePkgTokenSpaceGuid A1B0B230-67DC-431E-A94A-A96AF1EBE637,Tpm2DeviceLibTcg2 A1B8C9FD-3D04-43AA-8399-720A629EBF3F,LemSecureBoot @@ -6547,6 +7358,7 @@ A1B8C9FD-3D04-43AA-8399-720A629EBF4F,LemSecureBootForceKey A1B98C63-7032-4ED7-8CF2-8169D2788BA8,SpecificResetProtocolDxe A1C85085-3053-4C4B-A9F6-724D22A76EF9,AmiLegacyTpmguid A1CD8AB7-B86F-43AD-877F-B3438DFF792E,HPLnx +A1D99CBA-81F9-49BF-A15B-D7EBD7F0BB8D,PCAL6408A A1DD808E-1E95-4399-ABC0-653C82E8530C,JunoAcpiTableFile A1DF608E-8027-413F-A2F2-1DF7863F906B,OhciDxe A1E37052-80D9-4E65-A317-3E9A55C43EC9,EfiIdeControllerInitProtocolGuid @@ -6569,8 +7381,10 @@ A229F23E-E1FF-40D1-9382-36DD61A63EAA,AltModePei A2424BB5-5441-4EFE-A608-2CCD60824C06,NvVariableFailDetectPei A245D6D8-AFD4-4359-8F7E-7D829CA27158,HpMpmProtocol A24FEE8C-AB1D-4B84-8E74-5DB474D8FEA8,UefiDiagnostic +A25334B3-467C-4152-AC84-F4C201EEF8C3,AmdFabricStxhDxe A25C2D8C-2F92-4626-8D63-843BA9439630,TxtDxeProtocol A25F2FCD-C168-4E77-AD3E-A488ACB725AB,CompletePowerManagementProtocol +A2627D18-010B-45B8-AD38-AB01691FC850,AmdHspConfigPei A2702A3C-62FD-402D-B8C3-1D18F6C6FDE5,AodSetupDxe A2760074-ED4C-4719-8382-C942CBF16D85,DisplayTypeDxe A27D40FC-EA2B-4F3F-BD17-D5032A79546F,LEMELocker @@ -6578,6 +7392,7 @@ A27E7C62-249F-4B7B-BD5C-807202035DEC,DellFlashUpdatePei A287558B-D9DD-461B-A929-EC2AD2FEF591,DellSpiPartSst A2990B11-F05C-4182-9703-BB02275DB8F9,SmcNvdimmSmmProtocol A29A63E3-E4E7-495F-8A6A-07738300CBB3,AmiTcgPlatformDxe +A2AA0A8F-43D5-4B21-A26B-5D02476AD457,AmdCcxZen5Pei A2AB9D42-967A-45B3-9507-28CCC7021F51,UnknownBoot A2AEDCB3-8080-4C3F-B414-7A05D25E0699,DellNtfsDxe A2B05C85-8D5B-4FF3-B7D1-8FBE92B4AA32,PchEvaInt15HandlerFile @@ -6595,6 +7410,7 @@ A2EE1AF9-CFDB-4F73-829F-3D2CF7E51472,DellBoardPolicyDxe A2EFA9DA-5218-4653-B357-FC51D73E0754,SecureBootServiceDxe A2F03EEA-9304-40BE-87B2-7F457B01232A,AsusSmbios A2F436EA-A127-4EF8-957C-8048606FF670,SnpDxe +A2F68EA6-61D6-4B84-A9C3-497D8A5E3804,RtcWakeUp A2FA40D4-68A7-4A4F-9446-7ACD93FD2391,UsbDebugCard A30D9B7C-DED3-48D6-83A6-3FF43444C37A,AppleDxeManufacturingFixture A31280AD-481E-41B6-95E8-127F4C984779,TianoCustomDecompressGuid @@ -6603,11 +7419,14 @@ A33319B5-8EE1-45E0-8C9F-809F5B0902CC,RsdpPlusProtocol A334E8C1-F49F-49AA-9F82-9210205FC1FB,FchSandstoneDxe A3358D8F-B7AF-47B7-A324-9036FBD73DDC,FjMfgErrorCheckDxe A340C064-723C-4A9C-A4DD-D5B47A26FBB0,EsrtManagementProtocolGuid +A342B464-0D5D-4576-9400-750FF10719E7,XmlCliCommonSmm A34CF082-0F50-4F0D-898A-3D39302BC51E,IntelFsp2WrapperTokenSpaceGuid A3527D16-E6CC-42F5-BADB-BF3DE177742B,UsbCbiDxe A353290B-867D-4CD3-A81B-4B7E5E100E16,EfiPlatformTxtPolicyData A356AB39-35C4-35DA-B37A-F8EA9E8B36A3,EfiStatusCodeDataTypeProgressCode +A35AFACA-8C95-4EEC-9453-D8E5B560A8BA,Afu32FlashDriverSmm A3610442-E69F-4DF3-82CA-2360C4031A23,ReportStatusCodeRouterPei +A362215D-75B6-4B54-80E5-7434751877F3,RtkUndiDxe A36495C1-C205-414E-B71F-4BE3476D699C,FSVariable A368D636-4C77-4B50-AAE8-F99E2DA40440,PnpRuntimeDxe A37A9E43-9077-4539-9B90-BD719B032B23,SpiControllerDxe @@ -6643,8 +7462,10 @@ A43B03DC-C18A-41B1-91C8-3FF9AAA25713,ExitFormSet A43F5A9E-B29E-451B-8526-44C3E43D5067,SioInit A44A669C-ACE0-4696-8179-F5EA87930C4F,HpErrorLoggingDxe A4524A9C-0B5E-492D-AEC9-308631B189B4,AmiSetTcgReadytobootGuid +A4578B9E-C666-4161-A168-159FF541ACD3,CnvUefiConfigVariables A457CFAD-64EA-49EE-A532-566AC2B6D6C4,PolyFuseWarningsDxe A45B3A0D-2E55-4C03-AD9C-27D4820B507E,EfiUgaSplashProtocol +A45BE8D5-B988-4F70-9F16-8BFBC6884669,PchInitSmm A45E60D1-C719-44AA-B07A-AA777F85906D,PeiAtaControllerPpiGuid A46423E3-4617-49F1-B9FF-D1BFA9115839,EfiSecurityArchProtocolGuid A464BF8C-77AB-4BD8-AEF1-82DAE1A06AF6,FjGabiFlashDescriptorDxeProtocol @@ -6667,6 +7488,7 @@ A4C55A05-88D4-44CB-8DC7-B3C092802E22,FchSmbusPei A4C751FC-23AE-4C3E-92E9-4964CF63F349,EfiUnicodeCollation2ProtocolGuid A4CB211C-3E43-4775-BF1A-8CECE36E793B,AaeonLanByPassPkg A4D53F5B-C216-4C8A-83D9-390B4A656CD4,AmdSocFp7PhxDxe +A4E221CB-C1E7-4292-98B7-4B2A41FC254F,Cf9Reset A4E7949F-F818-49DE-AEC0-08B0DB6E250C,T23SmbiosOverride A4E9A172-9D5B-47AE-BFCF-2C9FCA6F0ADC,AmdSocSp3r3CglPei A4EC8ADB-B7A8-47D1-8E52-EC820D0ACF6F,FvbSmm @@ -6674,7 +7496,9 @@ A4EE0728-E5D7-4AC5-B21E-658ED857E834,ArmMpCoreInfoGuid A4EED3AF-9837-46B3-9275-C71CB47071F9,NetsecDxe A4F2909C-5E2A-438A-91BA-272B0923049A,PlatformSetup A4FD00D3-821A-4519-85BB-2E1987A6F4E1,LenovoMx25L3206EflashPartDxe +A5095ECF-A28F-453C-960F-8757E4A480B1,Cf9Reset A510A614-2192-11DF-AF29-2754E86B3594,PciExpressHostBridge +A51BC7A4-0ED6-44C2-B5FB-B86FDE077DE1,AmiSetupNVLockDxe A52509C7-5ECD-42D1-85A2-46C37135D12D,GopPolicyDxe A5288050-8828-46C4-8F72-1CD735A56520,Slp20Dxe A53EF7E2-9F46-4B56-ADC8-FE93B25D1758,FjDeviceInfoRealtekLan @@ -6699,6 +7523,7 @@ A5C059A1-94E4-4AA7-87B5-AB155C2BF072,EfiCertX509Guid A5C1EF72-9379-4370-B4C7-0F5126CAC38E,TrEEConfigPei A5C6D68B-E78A-4426-9278-A8F0D9EB4D8F,UsbMassStorageDxe A5CE755B-EA21-4884-88C7-C7D4B1AE2837,ProgressBar +A5CFD301-408D-E8C2-44FE-07ACB1D56BAF,Sff8472Pei A5D75589-589E-49FB-8F93-F494280EA1BD,SmbiosType140 A5DEFDFF-944C-4B4D-9A76-8CF3ACAD2F7B,IntelRaidAtaAtapiPassThru A5E369C8-ABF9-4B43-B212-FF1BFD35666D,CbsSetupDxeZP @@ -6706,9 +7531,13 @@ A5F36439-BD52-49FB-B158-7F6688952BEA,OemSpecialLogoSupport A5F8F888-7191-429B-81AE-2688F415BD2B,DellSmmGpioLookupPolicy A5FADA55-1CAF-4486-9CDB-24018E71E952,PxeDriverDl A6077307-B297-4051-9AC0-A0DC8147E601,menu_locked +A60A27AF-C1EB-4823-B674-F0369EA40349,RTL8852CEWifiDriver A60B21B1-A200-4785-A86E-5106E76A3604,DellDynamicBacklightControlSmm A60C6B59-E459-425D-9C69-0BCC9CB27D81,EfiGetPcdInfoPpiGuid A60C7DCD-512F-4F02-B180-522E015E06B7,PpmProcessorSupportProtocol_3 +A610E170-08AF-11E3-A05F-047D7B99E097,ConfigurationVariable +A6185DDA-B5C7-4735-B871-8D6BCCCAC8C1,Pca9536Dxe +A6190292-DE59-421E-BA6A-1C7D17DFDFA7,AmdAblPerformanceDxe A622AB73-1E7F-43C8-A465-0D5B267F1A37,MicrowindowsDxe A622E42C-8E38-4A08-9E8F-54F784652F6B,SystemAcpiOA30Dxe A62D933A-9293-4D9F-9A16-CE81994CC4F2,AppleDebugSupport @@ -6739,6 +7568,7 @@ A6C300F4-A5D0-43E9-81BC-C4FB5069E4A2,FjGabiEntryDxe A6C37DD6-0D83-4127-B1E8-A1E600A797BD,HPWMIDxe A6C7C690-ADD8-4178-BC97-F6A4C1206285,c_pg4306 A6CA8BDC-AE14-4C13-9364-2F0E09CE0F54,AmdCpmEcInitDxe +A6CC6BC8-2ADA-46C3-BBA4-E99672CC9530,PciUartDxe A6DB3378-CFD7-4BFD-A1C4-2709FEC52F8B,AmiTseOemPortingVar10 A6DEFC45-18DC-41C9-B2A8-D0089DE08DD3,UfsPassThruDxe A6F691AC-31C8-4444-854C-E2C1A6950F92,DuetBds @@ -6746,6 +7576,7 @@ A6F7DEF5-10C2-4DBF-9B48-195388C56507,LANControllerSmm A702CE64-AB7A-498F-BAE6-CE18BBAE4C31,BrightnessHardwareVbiosSmm A708BD51-F56F-4DA2-8F78-1480CB2C1D84,SMSC5045PeiInit A7119441-E153-970D-5508-75DCDFA41974,SbSocSummitDxe +A721B30A-5A7C-4B6F-AC69-07496129A26A,FjRealtekLanControl A732241F-383D-4D9C-8AE1-8E09837589D7,XenBusRootDeviceGuid A733A552-26E6-4803-92DE-6C5543EE54EA,SlotDataUpdateDxeSierra A73D663D-A491-4278-9A69-9521BE3379F2,ArmVeTimerDxe @@ -6758,11 +7589,14 @@ A76B4E22-B50A-401D-8B35-5124B0BA4104,TcgPeiPolicyGuid A770C357-B693-4E6D-A6CF-D21C728E550B,EdkiiFormBrowserEx2ProtocolGuid A7717414-C616-4977-9420-844712A735BF,EfiCertTypeRsa2048Sha256Guid A7732DA8-11AA-4366-9715-CD92CFB7D362,SataController +A775A229-DBF2-455D-B737-FBD53D368A26,OTP A77B2472-E282-4E9F-A245-C2C0E27BBCC1,EfiBlockIo2ProtocolGuid A77C8452-0821-4544-AE47-257489855F91,AmiPspNvramDxe A799931B-FDB0-40B2-8A25-D26B58885379,AmdSocAm4BrPei +A799B420-F79B-44F0-A167-BC3F99DD6166,CbsBaseDxeSTP A79DC347-DEB4-4A4E-8497-CA5F8E7F0601,DellImageServerSmm A79EED97-4B98-4974-9690-37B32D6A5B56,RTSMArmVExpressLibSec +A7A11C86-C539-4BB8-8920-E7CCB5306DE3,SDTgaDecoder A7A15766-449B-AA93-114B-71B47BE174CA,DellDataWipeSmm A7AF67CB-603B-4D42-BA21-70BFB6293F96,EfiRngAlgorithmSp80090Hash256Guid A7B0CEAC-480A-4F8B-ACE3-7679BE16EAF9,PdHostInterfaceTiPei @@ -6770,6 +7604,7 @@ A7B36DCF-C75A-4BE8-BE2F-E4840CBE163B,DellPbaMgrDxe A7B81226-FE2B-43B3-9BC7-6B24B5920DBF,DellAcLossPei A7BBB38E-3AB4-409D-B11B-EE31A2688B0E,OemHooksPei A7C0687A-E8B9-42EC-B8A5-A950DF6EF94A,AlternativeDefaultMemoryQuota +A7C13377-CD27-48E7-A488-F38E3A51D11D,SDGifDecoder A7C619FF-9A64-4A89-947B-E7953E2427CB,PegaBsDxe A7C88FAE-EBEC-45ED-A7C5-5FA755177306,PerfTuneWdtPpi A7CED760-C71C-4E1A-ACB1-89604D5216CB,EfiIioUdsProtocolGuid @@ -6779,6 +7614,7 @@ A7D41F88-1CB8-4BFB-901C-F68BD2A47E9D,EcMeDisableDxe A7D8002B-923B-41C0-884C-3FC3795203FA,SystemVariableStoreProtocol A7D8D9A6-6AB0-4AEB-AD9D-163E59A7A380,SystemDiagnosticSplashScreenApp A7E2CE72-DC32-4BC0-9E35-FEB30AE5CC47,AmiEarlyBistPpi +A7E45308-81B0-43AE-AD30-2398395C27DF,ClearPassword A7E9ADAA-35C3-4A6B-A3B7-6C38BAA24F1F,BootBlockVisibleUpdateDxe A7EBBFED-CD82-4278-94DC-80F0CDE46FE4,GpioV2ProtocolInitDxe A7EDEBD8-A8D7-48F8-81FB-837656B82077,AmiNvramBackupRomAreaGuid @@ -6803,6 +7639,7 @@ A84B495B-79F4-40AB-8B60-653F69DCD944,AmiHeciDeliverProtocolGuid A85027FC-0E09-4FA9-A407-CAD206FB4F1D,PlatformStage1Pei A85DCA1B-198F-4E14-A673-874264687E85,DataSink A8656175-9210-4AB5-8ED4-A7503BD92F0C,BoardSmbiosDxe +A869B539-26F0-4F22-9A3E-F434E6898984,ProcessErrorCodeDxe A8752510-D83E-400A-85DE-FD1587882AFE,DellLomConfig A883FD70-4E7E-4B17-8EBB-C5646FF154CA,SpiMouseDxe A886C548-0CDD-4E2E-B364-AE956AAA4554,SwSmi534D0540 @@ -6818,6 +7655,7 @@ A8BC51CC-5A30-41D5-8B1A-EB46ABC527FA,IioRas A8C60A60-A950-48CB-A612-7FA732DF7243,OemRuntime A8C67255-E029-4B1A-968E-ECA6E9C11C73,AmtSmbios A8C6A171-5478-4A7C-9EB6-655C6CCC4E3A,InsydeReportFvPei +A8C77EB8-EBD6-4E51-A61A-B0366206B17B,BctBaseSmmSTP A8CDA0A2-4F37-4A1B-8E10-8EF3CC3BF3A8,EdkiiNonDiscoverableUhciDeviceGuid A8CEC941-CD87-4AB7-980C-4C77C33BF3BA,ImcErrorHandler A8CF6278-8758-458D-ADFB-3471F5AD50B1,SystemHddPwdPei @@ -6826,12 +7664,17 @@ A8DB985F-CB2C-4822-B8B1-1C8E48123FA5,FjGabiPasswordHandlerSmm A8E80DDF-A3BB-4880-9DB2-9BB1B8BB1212,SbMetronome A8F14FA9-FC88-45F4-A622-F06E6C56E632,FirmwareBootMediaInfoPei A8F634A5-28F1-4456-A9D5-7E24B99BDB65,PcxDecoderDxe +A8F7B053-CAD8-438F-98B3-200D4603B79C,OemLanSsid A8F960C6-4CC3-4417-8AD9-2A3B3F8027EA,AmiMemoryInfoGuid +A8FB59B6-8417-48A1-B565-199849271066,AsusVerbTable A90F8536-4AF8-45D6-B58D-D225FD1C06D9,FjI2cTouchPanelDxe A912F198-7F0E-4803-B908-B757B806EC83,Hello +A9177B11-8825-3A50-AE81-2E23A02DAA42,DashUsbSerialDxe A919B3B6-D44E-41F0-9179-8AA24FF2260E,PCIeSataDynamicSetup A91EE51F-0FF0-4A6C-A6F4-9214303AEDF7,MeEsrtUpdate +A92CC133-370E-47F0-9980-5D78896BEFE4,PlatformMilestoneHookDxePrior A92CDB4B-82F1-4E0B-A516-8A655D371524,VirtioNetDxe +A9388856-F674-4B2B-98B8-6F463029711C,SbSocRsDxe A93A7745-FC4C-4435-8B60-B5BC3B7E9135,WheaLastBootError A9474AB8-1AB4-43BE-90B3-17D119FE8086,PxeDriverDl A94A6AEF-D69B-4010-BA24-F91E1FE62ADA,LenovoSystemSecureBootDxe @@ -6841,8 +7684,10 @@ A954E4B0-0380-41F6-95C1-B8ADE56C2319,OemHookPei A95C1D60-CB9F-4BD8-A030-3F1C4A185156,SecureBootMod A960F489-9773-40CD-852C-55822D533F19,H19ComputraceRuntimeDxe A9620E5C-5FA1-40B7-8B21-50B632F88F38,EfiLoader +A9626A70-A4AC-4B9B-8396-8C931E11904F,AmdCpmPmfDxe A9638A2E-8862-439C-BA51-032161F6FE31,BayhubSecureErase A9731431-D968-4277-B752-A3A9A6AE1898,PeiIpmiPpiGuid +A974C9A7-F765-4411-9191-41D36D5139B9,AmiSerialUart0 A9759271-49CD-49BE-8764-5DEBFBE68F73,AmdResetManager A97C91D0-6FEB-4555-B0DA-4E79EC009D68,GraphicalFirmwareInterface A97EAC62-6F1A-4B05-8CFB-65B1CE7D6A3C,BiosVideoDxe @@ -6850,6 +7695,7 @@ A9874C4B-599B-4B46-8161-FA4E72E53BBA,ShadowDownPei A9920538-40A4-4335-9D71-1EF546AEFB27,DellSfpPei A993B66C-22EA-46BA-A27A-0A23356D901C,AmiHddTemperatureProtocol A9A048F6-48A0-4714-B7DA-A9AD87D4DAC9,EfiRestJsonStructureProtocol +A9A7A430-A520-4279-AB90-95683EFFEEC6,SioChip1Smm A9ACE824-4486-44E6-915A-8FBAED0799B9,SetupDataProviderDxe A9B54638-4F79-4369-BCA3-44B2B593ACB8,OemSmi A9B700CF-019E-4D8B-A3A7-88E1EA01699E,HddSecurity @@ -6869,6 +7715,7 @@ A9F8D54E-1107-4F0A-ADD0-4587E7A4A735,IntelSiliconPkgTokenSpaceGuid AA00D50B-4911-428F-B91A-A59DDB13E24C,EdkiiSmmCpuRendezvousProtocol AA0E8BC1-DABC-46B0-A844-37B8169B2BEA,EfiPciHotPlugInitProtocolGuid AA17ADD4-756C-460D-94B8-4388D7FB3E59,EdkiiPlatformBootManagerProtocol +AA1AA47C-3668-4F75-B51B-0C1C6499764C,AmiGetPstatesZen4 AA1FF342-8968-4C70-882B-9E46DE9E4E78,OemSsidDataUpdateDxe AA236098-86C3-4A56-8B89-B715E04AB5CE,SsidPei AA298E94-A45D-45B5-8CE5-4FB71FBA4CE0,RpmcSmm @@ -6877,24 +7724,30 @@ AA324A7F-A676-46DC-A35D-A404226A7A04,ReprotErrorCodeStatus AA382865-12B0-44E5-A731-6DEF4DF34CE7,LenovoPromptService AA40B708-9073-4436-B5FE-D22D7ABBA5C4,MemoryDiagnosticDxe AA40D00E-5B9B-4DAD-A487-FC1BCBEF8170,SgPeiInitPpi +AA4100C0-7F70-EABF-B720-5B6F7ACA5EEB,EepromDxe AA430398-3C8A-4817-8ED0-6291B5C77D6A,RTL8111HN AA48FBB2-9F87-4DFD-B416-575938F0C8F4,PropertiesTableAttributesDxe AA506A03-4A54-492B-8F2B-9AD9A949358A,UfsBootLunIdHobGuid AA5324ED-DC11-4D5D-A52B-FABDD7E80634,PlacementDxe AA600F06-26F5-428F-B4F1-913BEF6E4DBB,FspWrapperExtractGuidedPeim AA652CB9-2D52-4624-9FAE-D4E58B67CA46,PchSpiPeim +AA69724F-11C0-4B04-A860-2E8E196B03CA,AmdMemBrhSp5Dxe AA6E807F-88C8-4237-EE25-AAC45BF18804,EfiIntelLanDriver AA6E8785-726E-441D-ACB8-F75FB0B2B9F2,CoreEG2 AA7B4695-00B4-4468-AD92-99370AC031C5,LegacyRegion2 AA7E190D-BE21-4409-8E67-A2CD0F61E170,UniversalPayloadSerialPortInfo +AA8818DF-D0B1-45E4-A7F2-B6DB0E752BA7,AmdPmfDxe AA893E19-A641-4819-AD23-011B7C24250D,IT8728SioAcBackSmm AA924214-DFCB-4BEE-AA33-FAE9729AF000,A01ODMSmmServiceDriver AA9BD7A7-CAFB-4499-A4A9-0B346B40A622,SmmRegisterInfo AAA76748-3602-450A-B905-6A98A3E6D363,ProjectDxe AAB16018-679D-4461-BA20-E70CF7866A9B,EfiSystemTypeFru AAB18F19-FE14-4666-8604-87FF6D662C9A,EfiSpiSmmNorFlashProtocolGuid +AAB53D89-3AC6-40D1-8C65-44EA1FCA9A4E,AmiPspRebuildBSmmCommunicate +AAB5438C-F15B-4DEF-B61A-5280B62BFB58,FchSongshanMultiFchPei AABDBE33-DBDC-43D3-AFE3-AB37F9B46782,LEMCBMRDxe AABE9A45-B345-49D2-88EF-6AD0B85ED7E6,AmiRomLayoutProtocolGuid +AABE9A88-F09C-429F-B293-2D2DA9DA9980,AudioDxe AABF95D6-F40C-405F-8360-6A59794B8040,BasePciSegmentLibPci AAC33064-9ED0-4B89-A5AD-3EA767960B22,FaultTolerantWritePei AAC9B0AF-A46A-49D8-8016-9B9DAD2C7F5E,DxeBoardConfigInit @@ -6904,6 +7757,7 @@ AAD1E926-23B8-4C3A-8B44-0C9A031664F2,FmpDxe AAD8B9F8-2C83-4E4B-96E8-C5B8B8AC56BF,JedecNvDimmSMM AADE7C97-98E7-4CFA-B4EF-BBE20506A31D,EcIoSmmProtocol AADFA1AC-E923-4673-B1B8-714AD849F790,SystemFormBrowserSimpleTextViewLayoutDxe +AAE2EA7B-E052-4371-8E4B-FF0E52D80F66,AdlinkSetupItemMod AAE65279-0761-41D1-BA13-4A3C1383603F,Ozmosis AAEACCFD-F27B-4C17-B610-75CA1F2DFB52,EfiEbcVmTestProtocolGuid AAECDC89-2A49-46F1-A163-F7979C039998,IdeBusSrc @@ -6912,18 +7766,21 @@ AAF32C78-947B-439A-A180-2E144EC37792,EfiAuthenticatedVariableGuid AAF691F4-9851-4120-8A43-1129B2829899,FjDtPowerFailureRecoveryPlatformDxe AAF875D2-0968-4585-A40A-B35C9FE0CAEC,AodSmmZp AB1404CA-4801-4208-98BF-30D521DAD4D3,AmiTseUserPasswordValidGuid +AB17430C-135B-46A6-95C0-57052798A584,PlatformIbraTopSwapPei AB189162-6DB5-4EFC-AC59-D0B3CC851119,OemEarlyPei AB1C1816-D542-4E6F-9B1E-8ECD9253E2E7,ArmGlobalVariablePpiGuid AB21ACC3-BA33-EE2C-66BC-125677111AB2,AmiDebuggerCpuProtocol AB226E66-31D8-4613-879D-D2FAB610263C,EdkiiDynamicTablesPkgTokenSpace AB248E8D-ABE1-11D4-BD0D-0080C73C8881,WinNtUgaDxe AB248E99-ABE1-11D4-BD0D-0080C73C8881,EfiWinNtUgaGuid +AB27C87B-91B9-4F1C-B942-8437B164277A,FchHuangshanPei AB294A92-EAF5-4CF3-AB2B-2D4BED4DB63D,PeiMfgMemoryTestPpiGuid AB2BEE2F-C1A6-4399-853D-C07C774FFD0D,EfiLpcWpce791PolicyProtocolGuid AB359CE3-99B3-AE18-C89D-95D3B072E19B,EfiStatusCodeDataTypeError AB38A0DF-6873-44A9-87E6-D4EB56148449,EfiRamDiskProtocolGuid AB3E46F0-844B-456E-8911-5D4546172410,EventCtrl AB4E44B3-1786-4BCB-BB8F-98C349140D69,FchHuashanSsdt +AB52EAE3-1E20-4114-B61A-EC3ECDAAC1F0,AdlNxpPei AB5A4DF4-F0D7-49A8-BF5C-F25DA04C2533,CpuGlobalNvsAreaProtocolGuid AB5AD18D-331A-4B7F-9B7F-64EFBAF1AD31,PTInterfacePei AB5BCFE8-BEE9-47B7-B7E5-7EEA4D357A01,UpdateAsfTableDxe @@ -6968,14 +7825,20 @@ AC5E14DD-4567-41F7-9E29-5F52CD314214,X11DPHSmmDriver AC60ED9F-523E-4F5B-94CA-3961346A00BA,LenovoVariableInitDxe AC62D8B4-3E8F-4ED2-9AD6-DCEAA1CB96A3,DataAccessSupport AC64F0C4-25C1-47C8-AC74-B1527456351D,EfiPlatformTypeHedtEvProtocol +AC65572E-F3A7-4D9C-93FE-22A221C14591,DellSetupDMASupportDxe AC6993CF-43C8-4FCB-840C-B7CF2E079977,PciHotPlug2 AC6A415B-844B-4288-B618-D14D6144DFE1,FjGpioAbstractionReference AC6A515B-844B-4388-B618-D14D6144DFE1,FjGpioAbstractionReference +AC6F7D21-3704-4D4D-ACED-FE32C6AAAFF4,DTbtPeiPreMem AC6FD56A-3D41-4EFD-A1B9-870293811A28,PhMebxHotkey +AC7FA810-44E5-4CA6-9D17-778CC5B034EB,AsrockAmdSetupDxeRv +AC80A942-12F1-4296-922E-30E91F751412,SbSocPhoenixDxe +AC80A942-12F1-4296-922E-30E91F753975,SbSocRaphaelDxe AC86A8CC-BAE4-4BE9-9D59-4DAC6D7703ED,LEMFactoryDefaultDxe AC874606-8727-41A0-BCCD-43A4237466DD,EneUpdDXE AC8F7B00-C65B-4568-8806-9DEA9E5F1085,DellStatusCodeHandlerSmm AC95AD3D-4366-44BF-9A62-E4B29D7A2206,SmmAccess2Dxe +AC991242-FBB0-42FA-AEF4-AA9746FD68E1,SmuV13Dxe AC9CF0A8-E551-4BE2-AD0A-E1B564EEA273,AmiCpuInfo_2Protocol ACA0F10C-04C9-4C4E-9D7B-B7A097F5E1EC,LenovoEn25Qh64FlashPartDxe ACA24109-6C7A-4CEC-9133-5FB9D8274910,IntelLtsxFit @@ -6985,6 +7848,7 @@ ACB93B08-5CDC-4A8F-93D4-06E342DF182E,PchPeiInitPpiGuid ACC8E1E4-9F9F-4E40-A57E-F99E52F34CA5,AmtForcePushPetPolicy ACD03321-777E-4D3D-B1C8-20CFD88820C9,EfiRngAlgorithmX931AesGuid ACD28235-075B-48B5-98A1-DA04FCAF84F3,SiInitDxe +ACD49C8D-6947-490E-AAD1-C338AC67253E,PspClearNVDxe ACD88BB8-D466-4B8A-8DA5-EC6407A83B28,NvmeHealthDxe ACDEA335-34B9-4FD0-A4B8-FA4DD0F73958,SmuV12DxeCZN ACE09B4D-CE11-4E48-8C9C-8D6901F70787,MeOptionsDxe @@ -7000,6 +7864,7 @@ AD21F7A0-7F5B-47FE-8CC0-241F318CABF5,AppleLegacyStartup AD3D267D-50E1-4B94-95D3-1025EF5B8391,SecFlashUpdDXE AD414DD9-076F-40FA-8B6A-1B6779ADECA3,AcpiDebugTables AD416CE3-A483-45B1-94C2-4B4E4D575562,TcgMor +AD46DFB0-01D8-4D84-BBAB-1359A983AB9F,OemPeim AD49E1DA-5E83-4A0F-ACC7-67F08CAEAA78,TrEEPei AD4A0D05-806D-4FE4-96AD-3BD62D8C4CE0,DellDoSiodiagLedDxe AD53BB27-F696-4213-ACBB-AEFA2F4B8BDC,OemModelIDDxe @@ -7012,6 +7877,7 @@ AD6BF297-4E16-4A91-843C-FFCFBF986E51,SecureBIOCamera AD70855E-0CC5-4ABF-8979-BE762A949EA3,IncompatiblePciDeviceSupport AD77AE29-4C20-4FDD-8504-8176619B676A,AmiHddSecurityEndProtocolGuid AD7C7A22-5F5D-4864-A8EF-2B78AD0A52D8,DellUsbExtDxe +AD82C06C-34C0-44F0-BA98-801C3CA7592F,AmdNbioDxe AD82F436-75C5-4AA9-9293-C5550A7FF971,EdkiiDebugPrintErrorLevel AD873A33-61E5-45DE-BB73-84F8461FB9EF,DellHddSecurity AD92822B-30C8-49B1-8AF3-63CCDF19B07F,DxeSmmIoLibSmm @@ -7021,6 +7887,7 @@ ADA0B656-AD68-4281-813E-5ADA5A65583F,EcRotClearVariable ADA1C665-7A8A-467C-84EA-7172B2B65862,FchSSSataD3ColdSmm ADB5951F-E8B9-42B1-9BFE-39D7B55484C8,HpRuntimeBiosUpdateCheckSmm ADB7B9E6-70B7-48D4-B6A5-18FA15EBCD78,IntelCpuPcdsSetDoneProtocol +ADB99273-4FA6-4943-BBBF-565E7CFE9004,AmdFabricRplDxe ADBDD6EB-27B2-4A42-B392-F29C00C8D861,DeviceAddressPolicyProtocol ADC0425F-E954-459C-BAA4-60FED1C1162A,VariableBackupRestoreDxe ADCBFD3F-95F8-4EE9-9F1A-6DA826862D4D,DiagnosticTestBIOSInterfaceSmm @@ -7040,12 +7907,14 @@ AE0B5B70-D044-4456-BA51-970E4C6870BF,EfiTraceHubStatusCodeHandleSmm AE0CC06C-1167-48C1-89A2-90499DF68FC3,XnoteEsrtDxe AE2020DF-C175-4344-B755-BBA47744F8B1,PeiVideoTextOut AE23AAC4-ABB4-4A96-A198-E06CC8475CF7,FchDxeLpcClkRun +AE23D34B-0323-4707-A434-1DDAC210753B,OemBadgingSupportDxe AE24851D-E414-4062-959D-5F43EA99363C,DellAudioDxe AE265864-CF5D-41A8-913D-71C155E76442,CpuIoPei AE3356F4-F95B-404B-B1DE-64EB5D5E5BBE,MemRas AE3AA8AD-B581-4AA0-898E-14EF42D25F30,XnoteSecurityMenuSetup AE3D28CC-E05B-4FA1-A011-7EB55A3F1401,EfiDns4ProtocolGuid AE3D856A-655D-478D-8E48-1661311AA3BF,HpEsrtDxe +AE402620-E6FA-4E09-9B63-3FD5BDABF77D,I225_PXE AE4C11C8-1D6C-F24E-A183-E1CA36D1A8A9,HfsPlus AE587172-CA15-48E1-8BE1-29DDF05C6A1E,OemSpecVtdRmrr AE587172-CC15-48E1-8BE0-29DDF05C6A1F,DxeSelStatusCode @@ -7054,9 +7923,11 @@ AE58978D-8EB0-42CC-FFFF-FFFFA419F039,XnoteSetupMainDxe AE6376EB-C813-482D-8005-40023A674EC1,FPSmbiosType140 AE65A8B4-05A3-4CFC-A486-F3149AA34BC0,DellMfgModeDxe AE65F02C-EEE9-4AAC-8C73-47AA4D7CF2BE,LenovoFmpDxe +AE67A517-EB4C-4D22-9751-D66470D9B5DF,OemDeviceDisablePolicy AE68A9F6-3A3E-4AD2-869B-27C927CC5FD2,DellOA2 AE717C2F-1A42-4F2B-8861-78B79CA07E07,FV_MAIN_NESTED AE724F8D-62C6-4638-A065-0138F47B6D23,UefiPxeBcDxe +AE7300AB-0E4A-43F0-B077-42B9DFC46033,FjGpnvSmm AE73630A-022D-4884-A696-F728CBF53AEF,SetupItemLinkageSmm AE80D021-618E-11D4-BCD7-0080C73C8881,EfiDataHubProtocolGuid AE87A309-FC97-4E55-94DD-BB1B061CE84A,FjSystemConfigurationRt @@ -7064,14 +7935,17 @@ AE8F0389-6BA2-47D3-9E55-80B3DD9B8A98,DfciMenu AE933E1C-CC47-4E38-8F0E-E2F61D2605DF,EfiPeiSmmCommunicationPpiGuid AE9F1E7C-80C9-4A23-917F-7450BA578E0F,TheftRecoverySmm AEA6B965-DCF5-4311-B4B8-0F12464494D2,BootScriptDataGuid +AEA7C021-B7AB-4ECE-8035-536C234A40DC,SyncBIOSimagePei AEA8F032-4601-0189-2411-6C8E3027EE8E,DellDataWipeDxe AEA90534-A602-46E2-B3E5-1F01DA2664BB,OemVMDHiddenSlot +AEAD58C8-C3E1-4ED2-9193-5E0D5D71803D,StatusCodeLoggerPei AEB157E1-ECAA-418E-BE87-A8E5FAB12D20,SmbiosUpdateDxe AEB8657C-AEBF-40A1-9866-BB22C7223FF0,Sha1AndRsaDxe AEB9C5C1-94F1-4D02-BFD9-4602DB2D3C54,EfiTcg2PhysicalPresenceGuid AEBB0EF3-9450-43DA-B2CF-323D04C937CF,DellWmiBiosAttribDxe AEBFFA01-7EDC-49FF-8D88-CB848C5E8670,SiPolicyPpiGuid AEC4159D-F2FC-4090-95CE-38317A8ED64C,FirmwarePerformanceTable +AEC7B585-9AFC-400B-A8C5-78E135EFF845,ApobRplDxe AED6AA78-D5BF-4BC5-8CC5-F9EE47CF9299,CapsuleRuntimeDxe AEDA2428-9A22-4637-9B21-545E28FBB829,EfiEblAddCommandProtocolGuid AEDB04D0-EE2B-499A-B673-D71AF876CF83,DellSocketDxe @@ -7080,12 +7954,14 @@ AEF41E72-D85E-4EA9-980B-66E5820DE19E,LenovoSmartBootDxe AEF82756-87F2-4CF6-BE80-E59055295AA1,PEbiosinterface AEFAF26C-FB6D-4FEF-AF7A-9D78FF201FCA,FirmwareUpdate AF060190-5E3A-4025-AFBD-E1F905BFAA4C,EfiHiiImageDecoderNamePngGuid +AF1450C2-70DE-44D5-80B1-B90D44277990,PasswordSupport AF198108-862B-4B46-AAB8-B0B34D3ADE0F,WifiPxeControl AF1BB1DB-9931-4CB0-8629-B9319BB0EFA0,DfciSARecovery AF23B340-97B4-4685-8D4F-A3F28169B21D,EdkiiVarCheckProtocolGuid AF2417F4-7B7E-4C2E-94BB-7A3389A157CA,EfiPeiPlatformTypeLightningRidgeExrpPpi AF277E13-3F21-40B2-9452-43503BAD0670,BixbyPei AF29FB7F-EAB7-4211-9684-CE8D4A47A0C7,StaticSkuDataDxeExpertWorkStationRP +AF34C37F-F5D7-47F7-B586-B593CB338C35,ClientronSecureBootDxe AF382531-52E6-4CC4-B247-DB8E320CBBA3,SmbiosDMIEditBoard AF3969DD-43BC-43C4-9E46-9C3310AF6DA0,RtErrorLoggingDXE AF405B70-23A4-11E9-96B9-A0C589EF4E75,DellDiagUiManager @@ -7102,10 +7978,13 @@ AF6AC311-84C3-11D2-8E3C-00A0C969723B,EfiDeviceIoProtocolGuid AF784AF2-76E8-45D1-A0FF-68724CE98AFF,EcBlinkPei AF8898C9-9B92-4556-8318-E425C9DE0A65,F2App AF8A30CC-08E4-4E73-9E8E-2E39674D9E63,DellServiceMenu2 +AF9BAFE5-3459-4803-B8EE-5D6FC7FC511E,ApobRsPei AF9FFD67-EC10-488A-9DFC-6CBF5EE22C2E,EfiAcpiVariableGuid AFA4CF3F-AF71-4C30-A4FB-2910E771F9B0,AmiNvmeControllerProtocolGuid AFAB5682-F6CA-4E04-88BF-66638C23EFA1,WifiProvisioningDxe AFB3D17B-A330-4860-9BEB-E3C7D1D49C50,FjSecureServicesSmm +AFB436A3-CE6E-4106-BFA8-ECF7EB1B6486,AsusPTTDxe +AFB575B0-1FAC-0361-B6F3-9D6DAAAAE9D3,OemWlanPowerSwitch AFB6DFD0-8D22-4931-BEE9-B08F384CC1F7,LenovoCustomizedLogoSmm AFBFDE41-2E6E-4262-BA65-62B9236E5495,EfiTimestampProtocolGuid AFC04099-0D39-405D-BE46-846F08C51A31,AcpiPlatform @@ -7127,6 +8006,7 @@ B02F63AF-96D2-4040-A15B-CBB8ADF81933,AmdMemSmbiosDxe B0392493-4E68-CEC7-992C-F6B5E029BAD2,AmdSocAm4VmrPei B03ABACF-A532-5E78-ACA0-B11F765B3AFD,CpuDxe B03D4E0D-5156-44AB-BEDB-9675A3D57D41,PhPlatformSiSmmCodeCheckDxe +B040C9F7-5F6A-4B67-A7E5-4EAD9412F920,AmdFabricBrhDxe B053ED84-880C-4F7E-A57E-2C82C6E9BCBF,OemWlanBT B05E6B60-323F-4BCF-9A2B-5DBFB07301EF,AmdNbioEarlyPhaseRNPei B0649250-512B-41AB-8608-FE0757311B8B,AmdPspPeiV2Ssp @@ -7136,6 +8016,7 @@ B06F2CF8-8433-41A3-B513-B115C8E7EB8F,BiosUpdateExtendedPlatformPolicyPei B07156B4-5947-4885-A3ED-FB1DFA949AE4,PdHostInterfaceItePei B0732526-38C8-4B40-8877-61C7B06AAC45,EfiCpuIoProtocolGuid B0767CBC-4705-4D35-8866-17A9B85E3843,EfiMemoryConfigVariableGuid +B078474C-A6E0-465D-8229-B46110CC437B,OemAdjustHsioWorkaround B0792197-ABC3-4BB1-9FD3-CBEA8FD41373,BaseAmiBeepLibNull B079EE3C-37A6-47E6-BF8A-94A7E85C41AE,MFTSmm B085B8FC-CCFC-4337-A59C-DE4ACA1B0365,AmdCpmSocAm4SmBrPei @@ -7161,11 +8042,14 @@ B0C2372B-9393-4CBC-9CAF-53913C9DCE29,FlashDeviceFvbRuntimeDxe B0C4F9D7-2F31-4B68-BF3E-C5AFACD59025,FjPostScreenMfgPowerOffDxe B0D0314D-57C3-4453-9486-18822D8C81BA,FmpDxe B0D3C4C9-5954-4A84-80BF-144CE9F02223,PostBackLightControl +B0D542D9-E531-418F-B7CA-B9F58D6DDA45,OemCloudBootInterfaceSmm B0D6ED53-B844-43F5-BD2F-61095264E77E,PchSmiDispatcher B0D8F3C1-B7DE-4C11-BC89-2FB562C8C411,EdkiiSmmVarCheckProtocolGuid B0DAEB4F-1EF7-11E4-BBCC-78E7D1AF36D1,HpNetworkBiosUpdateDxeDriver B0E11362-00DA-4611-8D7D-10EF2527F653,VideoBiosDataBlock B0EAE4F8-9A04-4C6D-A748-793DAA0F65DF,TlsAuthConfigGuid +B0EB46FF-DB1D-43F8-8339-B8103A3A1412,PciDxeInit +B0EB46FF-DB1D-43F8-8339-B8103A3A5AE8,PciDxeInit B0EC5D53-7481-4821-AC57-69DDB2868DE6,UndiLayer B0EE53D4-A049-4A79-B2FF-19D9FAEFAA94,EcpPeiPciCfgPpiGuid B0F0D157-AD8F-45EF-BFD6-F525AABC3092,GabiSettingItemDefaultRestoreSmm @@ -7174,7 +8058,7 @@ B0FC49FA-4F5F-4542-81C4-E54DB9592022,LNVRNR B1095967-FCF4-4C53-BC16-7E3DF9C247EB,StdFlashPeiLibNull B10ADFA1-9E43-487F-AAF3-A7A9BDEAF4AC,ProgressBarFullRightEndcap B11216C5-44E4-472C-ACB7-128A5A3AD7A1,OpromUpdateDxeNeonCityFPGA -B11E930D-A082-42E2-A7F2-C63767A4D3E7,SI_BoardDxe +B11E930D-A082-42E2-A7F2-C63767A4D3E7,AsusSIBoardDxe B122A262-3551-4F48-8892-55F6C0614290,EfiFirmwareClassGuid B122A263-3661-4F68-9929-78F8B0D62180,EfiSystemResourceTableGuid B129AD37-3F38-444B-E425-9AA991A81893,HpOsToUefiInterface @@ -7186,8 +8070,11 @@ B13EDD38-684C-41ED-A305-D7B7E32497DF,Smbios B144E169-AFB1-4426-B0EC-099728909342,MuxGraphicsSwitch B147CD7E-17D3-4D66-AB39-472B1DA659C1,UefiTableDxe B14AFFC9-F12B-4EAA-B335-1CD84889F6F1,CrConfigUtil +B14BA91B-CCD9-4CF9-8FF3-BD159DDE760C,FjScrtyBootService B15239D6-6A01-4808-A0F7-B7F20F073555,Ax88772 +B15E091B-C90E-4F0D-81E4-BB32A2DA68FA,OemCloudBootInterfaceDxe B1625D3C-9D2D-4E0D-B864-8A763EE4EC50,TcpDxe +B162D432-E339-4316-862D-00280AB6A07E,BiosEventLogConfigUtilDxe B1659B1F-F74E-4866-9D66-2930900391A5,FwBlockService B167C2F5-E26A-4DFF-8E1C-0807C7F02A88,AmiCcidIoProtocol B16F81D3-A684-439D-A721-F617C9EB8ED8,FjCameraCapsulePei @@ -7198,6 +8085,7 @@ B18348FE-D540-4ADA-8745-172C109D3A22,FjExtDxe B18D3493-7E62-48DB-A4DA-8120BFB14394,FdiskOemSmmProtocol B18E803F-F4D2-49DC-9C10-643174F56B97,Usb_Lan_Ax88179 B1951813-0CFA-418E-B312-33368D5902EB,SystemPwSmm +B1975734-77C2-4827-9617-914883F3B578,ATFHobPeim B199DEA9-FD5C-4A84-8082-2F4170780305,EarlyPL011BaseAddressGuid B1A44F23-EDCC-4425-A1E6-22DA61640BA7,AsusESALaunchDetect B1A49A06-B630-4BF5-85BD-0997CE642D49,TouchDriver @@ -7213,6 +8101,7 @@ B1CD7448-319C-41AA-821D-3E606BF6F90D,SmcOemActivation B1D7B153-118C-48EB-982C-B55FCE99F6F4,GpnvErrorLoggingToken B1DA0ADF-4F77-4070-A88E-BFFE1C60529A,AMITSE B1DBC95C-0EE7-4261-B290-5BF0A4DB9527,DellSmmRadioExecProtocol +B1DD2F34-DA6D-4B8D-9D1C-DCB76B6E400F,NvStoreRestoreDefaultSmm B1DFF070-1322-4CD9-A5B0-F56BA2B54E23,AmdNbioGfxMDNDxe B1E9E2CA-B078-4070-BCCD-87449AC7D2A6,CpuS3Pei B1EE129E-DA36-4181-91F8-04A4923766A7,EfiDriverFamilyOverrideProtocolGuid @@ -7234,6 +8123,7 @@ B26B30A8-2172-4A46-9B4F-4D5B08DD6E40,T23OwnerStringService B26BCCA7-D044-49E1-B1B5-E2A96BB7C225,MitigationDxe B26E6830-629F-443F-BE20-D26E502C25BC,AmdFchHwmSmm B273CC44-E62A-41DC-9CAD-BDB4235459D8,UnicodeCollationDxe +B2768462-14E4-4B8F-AFB0-B274B367BAF0,LoadSetupDefaultDxe B27DAB38-9814-4E06-A5A2-65AE9A14258F,AmiIntSmmCommProtocol B28CBC31-FD64-404E-83DF-ED162AF76B4B,CertificateBasedAuthenticationDxe B29328EE-68FC-4966-9ACE-BE21FADB7328,AsusVariable @@ -7243,12 +8133,16 @@ B2A23305-9455-489C-AA81-21DB48C41EAB,LenovoAoacDxe B2A3D57C-7071-014E-B3EB-3C98D09CB32E,IntrusionDetect B2AB115E-C8B6-4036-BF31-E74BD8926CCE,DxePlatformAmtPolicy B2AB8AD0-5ED9-435F-B223-356B645D547B,AmdCpmABRecoverySmm +B2B0F1BD-5791-4802-93F0-71D3A0FE993D,ClientronServiceSmm B2B73FA6-7224-49D1-82B5-1DBB115F1C50,OdmAudioLib +B2BD9B02-9DF7-4E4B-A484-C27988EFBC77,AsusMbSwWmiDxe B2BF51E0-6543-4ACB-B09E-FD826E1AF4C0,RasClvPcieErrHandProtocol B2C62021-9E80-4250-B567-896EA8360AD1,DellFlashRecoveryImagePei B2C7D8F7-4E7F-46A9-8CDE-F9FB6D276278,EfiAmiDebugRxPkgTokenSpace +B2C9CD52-86B3-4031-B830-8BD84495ABC8,HddSpinDownDxe B2CD74DE-11F9-418C-BF2E-DAC3035AAB7A,IsPlatformSupportWhea B2D0CEAF-848E-4B07-BFEA-6FE6C740B3D2,EcMpmPei +B2DDC6BE-D2EE-4EF1-992C-2CD695115DA3,AmdCpmOemInitPeim B2DED54E-47CD-8416-1818-FBB243809984,AmdSocFp6RnDxe B2DEDC91-D59F-48D2-898A-12490C74A4E0,EfiIfrBootMaintenanceGuid B2E56A22-DFE7-4850-97AE-10E76112DE05,BatteryInfoDxe @@ -7256,6 +8150,7 @@ B2E6299D-686A-4214-B070-080367FC5340,DellInstallHiiPidListHobPei B2F436AC-A127-4EE8-957A-5048606DD681,MarvellNicSerialDriver B2FA4764-3B6E-43D3-91DF-87D15A3E5668,AmiAhciBusProtocolGuid B2FA5764-3B6E-43D3-91DF-87D15A3E5668,AmiAhciSmmProtocolGuid +B304F34D-B27B-452C-8931-CF60A2F0D268,FchProm21GpioDxe B30DFEED-947F-4396-B15A-DFBDB916DC24,EdkiiPeiSdMmcHostControllerPpiGuid B31FF060-8363-11DF-8395-0800200C9A66,SystemAhciBusSmm B323179B-97FB-477E-B0FE-D88591FA11AB,PeCoffLoaderProtocolGuid @@ -7267,14 +8162,16 @@ B336F62D-4135-4A55-AE4E-4971BBF0885D,RealTimeClock B342BEBB-41C3-40AB-AA70-E9F3742D1835,AmdCcxZen3Dxe B344259B-9957-4548-8BD1-B31464BB8370,DataStorageDxe B347F047-AF8C-490E-AC07-0AA9B7E53858,EfiWinNtSystemConfigGuid -B34ADD50-05D4-4C99-BC55-F3F2F7F52E1A,LegacyToEfi +B34ADD50-05D4-4C99-BC55-F3F2F7F52E1A,LegacyToEfiDxe B34E5765-2E04-4DAF-867F-7F40BE6FC33D,ExtFs B35AD166-FCBA-4D4D-89C7-4B47104E3AFD,AppleSpiIoSkl B3685A91-F96F-4959-A539-A63C3B9ACED3,UsbLanDriver B3711230-CA04-4F11-9A84-2D8111F8AA83,EcBlockSmm +B3737A34-628C-43CF-9A65-C235772F1819,FjScrtyRuntimeService B3738534-9051-40D1-9333-91284A5990CE,AmiPciHotPlugLibNull B375D24E-863A-2DC3-C429-7DAB7323AB9B,SceBootOrderSaveRestore B3762FA2-54D6-4EBC-84DE-4CFA9340FCB3,AcpiAMLDxe +B37C08EA-12BB-440F-8169-389E1705DA16,OemGlobalNVSDxe B38573B6-6200-4AC5-B51D-82E65938D783,RecoveryOnFatIdeDiskGuid B3884E99-9CBC-4CE8-855E-53A12ED0B8F4,AsusIpmiPei B38CFE42-F0A2-40A5-8F95-EAE71D32B5D3,RtHooks @@ -7294,6 +8191,7 @@ B3DAE700-2A77-4EA4-AF79-3297B484BE61,AmiMeasurePcioprom B3E123D0-7A1E-4DB4-AF66-BED41E9C6638,ScDeviceTableHobGuid B3F56470-6141-4621-8F19-704E577AA9E8,DriverSampleInventoryGuid B3F79D9A-436C-DC11-B052-CD85DF524CE6,EfiRegularExpressionProtocolGuid +B3F9713B-70CC-43E9-BC34-D960C6F4ACC9,FchKeithDsdt B40612B2-A063-11D4-9A3A-0090273FC14D,UsbCbi1Dxe B40612B9-A063-11D4-9A3A-0090273FC14D,UsbBotDxe B40637B3-4270-4D2F-B2B5-D41CFC4E0A56,CapsuleSmi @@ -7302,8 +8200,11 @@ B41956E1-7CA2-42DB-9562-168389F0F066,BootGuardPei B422FB70-E835-448D-A921-EBA460E105B6,SmmIpmiLibSmmIpmiProtocol B4282EDB-2371-44E0-9AB3-F33B3F7AA7CC,SecureBIOCameraSonix B42B8D12-2ACB-499A-A920-DD5BE6CF09B1,WdtProtocol +B42E97CF-B811-4A09-9810-FEE8F53A561E,PlatformHstiDxe B430F89F-EB33-4514-B490-1885ADDBF840,TypeAEh +B43348C1-E0AA-4767-AE22-2F31333152B6,L05BatFwUpdateProtocol B4339807-7CAC-49BA-9FB7-6231C622F270,BeginStickyBootButton +B43499EA-57B6-4015-BDBD-AEA5D3D4F592,ApobBrhDxe B43B03C4-FEB0-410B-A0A0-C25B1C8F8DD8,EcStorageAgentDxe B441DF87-8D94-4811-85F7-0F9A7BF89D2A,MeAlertAtHandler B44A486C-8BB3-457A-A8CE-F89B179C9504,DellEcIoPei @@ -7337,6 +8238,8 @@ B5320E5F-0875-42BC-A5B7-15AF36CE87CF,TcgDmarDxe B535ABF6-967D-43F2-B494-A1EB8E21A28E,AppleRomInformation B53BE3D7-3BA8-4868-A02A-8E15FB2C9299,CommonElogDxe B540A530-6978-4DA7-91CB-7207D764D262,FastBootVariableGuid +B54299AD-B521-4BB8-A361-689249FE72B9,AodSmm +B55600FD-A787-4EF3-803A-D1C9B546F24E,ErrorLogReport B55A4515-5895-4EA8-845B-75B7480F6502,SmmControl2OnSmmControlThunk B579B530-C797-4839-883E-EFCABD7756E9,VerbTable B57A1DF6-FFDB-4247-A3DF-3A562176751A,UefiDebugLibStdErr @@ -7344,19 +8247,25 @@ B57EC3FE-F833-4BA6-8578-2A7D6A87444B,EfiSpiNorFlashProtocolGuid B5852752-C452-4666-B189-03EEE5E3A07B,KEMoPLATFORMMENUDxe B589283B-0C57-4600-9AC8-493F5AB9D333,DataAccessHandler B58A69FE-163E-4CC0-A487-304D34D5489F,EfiTcgMADriverHobGuid +B590D584-A947-4888-B468-0A449309A10F,FchS3SaveDxe B597FB4A-3527-4982-A4E4-8E212C3CCA9C,AcpiSdevAcpiTable B59AE9E1-C127-4EED-A3A6-4A0772CF7A4E,EsrtFmpDxe +B59DAEA4-FADE-413E-A522-13639044AC2D,ElinkPei B5A05743-9B71-489B-A0ED-A0EB3950D23B,SecPeiDxeTimerLibCpu +B5A7329F-0D17-401F-9DAD-A090F8AA0BAC,OemPei B5ADE90F-DC14-47A7-8002-E87238AAE930,LEMEfiNvmExpressPassThruProtocolHook B5AE312C-BC8A-43B1-9C62-EBB826DD5D07,GrubFile B5AEB34F-3047-4955-B880-ADD36D86DC0F,EdkiiPayloadCommandLine B5AF1D7A-B8CF-4EB3-8925-A820E16B687D,BootScriptDataBootTimeGuid +B5AF45A9-C3EA-41EF-B65C-4EA982DA9D49,KvmPlatformDxe B5B1181B-ACEE-4CC7-866F-9D8DFD27B399,LenovoEventLogVariableStoreDxe B5B35764-460C-4A06-99FC-77A17C1B5CEB,EfiPciOverrideProtocolGuid +B5B4E5D6-1866-466A-8782-23FED9EC359E,CrisRecoveryGlk B5BB551E-F2A7-43B9-813A-F77DD80900F5,HpCertificateManagerDriver B5BD8969-0978-414B-BA9F-C46B0A95B76B,DellReFlashSmm B5BE0BFE-5882-4189-80F3-9A2383F574C2,EfiPlatformTypeKyaniteProtocol B5C59087-FEAC-4B41-9D80-790BA5AA070F,FwVersion +B5C63B66-55E8-44DD-9993-BD8D06B55A4B,RemoveSMBIOS B5CB5393-7FDA-4383-B660-055C7E8AD991,KeyboardBacklightBin B5CEC017-74CB-4E10-BAC3-924A4CC629C8,AmiTseOemPortingVar7 B5D09084-80AD-4759-B51C-27548AFB8B8D,EfiGpioProtocol @@ -7367,6 +8276,7 @@ B5F53C73-3A8B-49E3-A428-B7D15A2FD994,CbsBaseDxeRMB B601F8C4-43B7-4784-95B1-F4226CB40CEE,RuntimeDxe B60A3E6B-18C4-46E5-A29A-C9A10665A28E,EfiI2cIoProtocolGuid B60D320C-25AE-4DCF-B848-196A7E55972F,KeepCriticalData +B60D67C6-9546-4C1D-B1DA-681B001C53C0,H2OUveConfigUtilDxe B60DC6E8-3B6F-11D5-AF09-00A0C944A05B,EfiSalMcaInitPmiProtocolGuid B619A1FF-3B3F-4941-B0F4-2B053BBD1720,FpgaFvDataLibPei B625B186-E063-44F7-8905-6A74DC6F52B4,EfiDns4ServiceBindingProtocolGuid @@ -7378,9 +8288,12 @@ B63BF800-F267-4F55-9217-E97FB3B69846,DynamicPageCount B63EBF4E-D196-40BA-AB63-1FA9A6068E84,LenovoOsOptDefaultDxe B63F8EC7-A9C9-4472-A4C0-4D8BF365CC51,EfiSdHostIoProtocolGuid B6460A49-0AC1-484F-AE58-F16EB239DB3D,TpmBootFlowVariable +B64702DA-E6B5-43C8-8CE8-D253071E9D6C,RedfishRestExDxe B65694CC-09E3-4C3B-B5CD-05F44D3CDBFF,MmFvDispatch B65971BE-BABF-49ED-9DD2-48EC8DB4ABD3,LenovoSoundService B65BF670-FC37-4225-AB85-EC960A7A1ED9,UsraRegisterFilterLibNull +B65F896E-6E6D-4D5A-8BCE-2E458E971D6C,AmdPspPeiV2Rpl +B66C5FDE-2483-475D-8A6B-BFB6B751E20C,AmdHotPlugBrhSmm B670E168-BD14-4D33-86B0-E632848403F1,AmdMemoryHobInfoPeimV2 B674D90A-9BDA-410D-A26C-14D6AFFEBD6E,CompalCMFCDxe B674D90A-9BDA-410D-A26C-14D6AFFEBD6F,CompalEDIDDxe @@ -7396,11 +8309,14 @@ B6B643B8-2B41-4A61-A224-D4F476EF580C,AmdCpmOemInitDxe B6B9295F-CABF-4CEC-BB14-FE4246F2173A,iFfsDxe B6C0DCB6-434E-4BEC-BDAC-8EE7ED8A4EC8,ArithChk B6C1C466-E78A-4202-801A-B7950E956E0B,ProjectDXE +B6C26249-C597-46FA-B559-7537F04A3564,AIMTSensorInfo B6C9FA82-9B26-4BE9-8C40-87A370E48365,AmiPlatformWrapperPei B6CB37E2-E2FE-400D-AAC2-A093EE2C55F1,VariableCmosDxe B6D47007-1445-41DC-BC8C-8AC34D7FB236,HpMMIOHConfigDxe +B6DC988A-3D85-414D-888F-7816263533D8,UcodeCapsuleDxe B6DD6150-70B2-4DB4-AD9A-3C7C2B04E580,AsusEcDxeSmm B6E17DD5-5CA0-4E3A-858C-A14345AE0B83,SwSmi534D0040 +B6E78A31-AF84-4B5D-92FC-5077C483F891,PostCodeDxe B6E9A733-EB75-41B6-B30C-009BCF3801C8,BasePostCodeLibPort80 B6EC423C-21D2-490D-85C6-DD5864EAA674,PeiBaseMemoryTestPpiGuid B6F44CC0-9E45-11DF-BE21-0002A5D5C51B,MmcDxe @@ -7417,6 +8333,7 @@ B72B4B3A-1BE2-44BB-9EDB-B6215F113682,FjIfSecureBootAndRaid B733C141-E88F-4786-94AF-8B87BC4867FE,PttSsdtAcpiTableGuid B7358BEB-6A52-4D50-98F9-7EDD70B4B320,CommonPciPlatformDxe B73D3EA3-8C99-4682-88D5-A08EB6BFD561,IT889XSmm +B73F054B-D1F8-4496-98E8-DFEACF8D8511,ClientronBds B73F81B9-1DFC-487C-824C-0509EE2B0128,DebugServicePei B73FE497-B92E-416E-8326-45AD0D270092,IbbrFirmwareFileSystemFvGuid B74B152F-5271-498B-A4A2-5722CBBEC614,DellPolyFuseStringPolicySmm @@ -7424,8 +8341,10 @@ B74BB37A-ECA2-4F79-A544-90569ABE6B99,LenovoSystemSmmCommunicationSmm B74E676E-3B2E-483F-9458-C378FE0AC69F,Tcm32FileGuid B74EAE11-AAEE-476A-AB0F-351063D67825,MeUpdate B750C811-02C2-4BED-99B2-8C6960080D45,IrqBoardInfoOverride +B7520A2D-509A-423B-B7CD-E320E805C7E0,Usb4PlatformDxe B7542192-9E4B-427F-88FB-18A0198236E3,PdHostInterfaceTiDxe B7543E56-08D7-4C4F-B5D6-7E3ADFCB82C4,FjOemActivationSmm +B7564097-959B-470E-954D-920EC49DE19C,AmdLegacyInterrupt B759169B-61E2-4F92-9447-23E3DCD33CEC,AmdCcxZenRvSmm B7611005-1F26-45BA-A3DB-01F39DDB2785,BootMode B761DA21-76EC-4AB0-99E8-4DC251B72CB5,DellSmmEcProtocol @@ -7447,6 +8366,7 @@ B7B82AD8-3349-4968-A940-7B8C265FF9B5,RtkUsbUndiDxe B7B82AD8-3349-4968-A940-7B8C265FF9B9,b57undix64 B7BC0E96-57D2-4310-AEEF-74AC77DF0DAF,SetupXpBoot B7C14441-ACA2-4F7F-8AB1-47B9C88635A9,DashIoCfgSmm +B7C2AB7A-8D0B-4A95-892C-C93F30A673C8,AsusRecoveryFailedDxe B7D19491-E55A-470D-8508-85A5DFA41974,SbDxe B7D9F0D7-EBDB-4EE4-AB77-B30C4B9093CC,TbtSmm B7DDFF7A-1726-11E6-B12F-B8E8562CBAFA,WiFiPlatformDxe @@ -7471,8 +8391,12 @@ B8502C59-B268-4BE8-ADD6-601AFEAA4BC9,SpiKeyboard B850A139-BABB-4D91-9F27-72D2EF01BF3A,VbtMipiJdiGuid B859281C-16FA-45A8-9201-1C3830A973BD,GecUpdateSMI B85C7FEA-AEBF-492B-96C6-42EA133BCF29,AmiTseHddSecurity +B8642E41-D350-4BFF-9DEC-4940F15CD6E5,nfa765x64 B86B0E9F-9FAF-4368-A131-62416F3DD21B,AmdMemFp7Dxe +B871F3BB-04B7-48B8-9D8D-ABFAA9EDDE61,AsusWatchDogTimerPei +B874E099-B86F-417D-8DD5-A0C054AEF060,BoardSyncAPCBSmm B87AA73F-DCB3-4533-8398-6C1284272840,ReserveMemFlagVariable +B87C2ACB-AC3A-4D96-9E4E-A5B9587A6298,StaticSkuDataDxeEldorado B88303F6-2E0E-41CC-8510-F5892BF1D9D9,PlatformVariableInitPei B88CF2B3-5CCE-482C-8DB4-6F329A73BD6D,Rtk8156UsbUndiDxe B8916C45-0680-40FA-B88F-89F9D42EEC51,FchSmbusDxe @@ -7482,6 +8406,7 @@ B89FD028-D4C6-4BB7-BCA4-17D8C945DC23,DellVideoDeviceSmm B8A31DAA-33FD-48F4-B84A-4D391FFA1F45,EventLogPei B8A3F491-0243-45C4-B670-C1BF619802AE,HpRuntimeBiosUpdateCheckDxe B8A6E7C5-B8FD-425C-A67E-1009DF1F10B5,LenovoUserManagerDxe +B8AB793E-27A7-4107-907F-3FF4320D7F15,FchKunlunSmmInit B8AC7FB2-4211-4C2B-B62F-504421666C87,RngTest B8B8B609-0B6C-4B8C-A731-DE03A6C3F3DC,ScBiosWriteProtect B8C2663C-F9FD-452A-ABD8-20556FE2AE65,BiosAuditLogHandlerPei @@ -7498,12 +8423,15 @@ B8FE3D49-DCF3-4CBB-8070-47B4F5A34559,GopDebugDxe B904772F-F8A1-4147-82FF-56CAF2D6E042,PlatformSecureBiosPei B90510C4-A6DE-4E45-A50C-A46CCAFEEF91,BaseBoardDXE B912F198-7F0E-4803-B908-B757B806EC83,AppleImg4VerificationDxe +B913CF23-9B49-47AC-A7C8-EA6539502A40,ExtendOperatingAmbientTemperatureModePEI B91547F5-4D24-4EEF-8507-74DDABEB71AD,AmiSmmNvmePassThruProtocolGuid B91978DF-9FC1-427D-BB05-4C828455CA27,EfiSioControlProtocolGuid B921DC51-49D4-4C14-9089-931C2D6B92BE,AmdSocAm4RvPei B9237513-6C44-4411-A990-21E556E05ADE,EfiKmsFormatGeneric3072Guid +B92FEC73-D902-4690-9B92-430E0E906369,AmiPspPlatformDxe B937BAC9-B41B-4914-BC32-72410400F9DE,SetupDataProviderPei B941CF11-E648-401C-92A1-342A70C6B742,DellSmbVersionManifest +B94A1958-05F4-E7F5-4053-286F96ADB3ED,TrackPointAWS B94FC17C-579C-4AB3-BA28-678D1813D1D6,DellBiosConnectNetwork B958B78C-1D3E-EE40-8BF4-F0632D063916,EmuThunkPpi B95E9FDA-26DE-48D2-8807-1F9107AC5E3A,UefiPxeBcDxe @@ -7539,6 +8467,8 @@ B9F5C05A-C8C4-4D1C-966F-1977EF2CA54D,AmdPlatformRasRnDxe B9F93638-35F5-447D-B908-A2B852AA0B89,LenovoSmbiosTcgDxe BA05B97C-8EBF-48B7-858D-4B0AFBF0D7DA,BiosGuardRecoveryWorker BA080879-3AF4-4639-9613-D1FC8ED8A669,EfiJedecNvDimmSmm +BA0C203A-166B-4B93-9636-8327AB2BF71F,AmdErrorLogDisplayBrhDxe +BA0ECDFD-A429-49B9-A961-11EEFF784C7F,OemPei BA102EAD-5308-4F9B-9E22-C1CE4DC44F49,RSAKey BA118F88-5B65-4584-9C5A-C2D087F6ED1E,IrsiRuntimeDxe BA15E887-ABF5-438F-B87A-3110F1C8ACE2,XhciPdoResetWA @@ -7549,6 +8479,7 @@ BA246BC7-7E2F-4AE4-817A-FFDE572E39DE,AppleSmc2 BA25E07A-E253-442C-90FF-B4C92FAD6990,UsbMassStoragePei BA26C482-C1DE-4B97-A8BD-160DFDB984AC,FchPromontoryGpioDxe BA28936B-4051-48CF-A5CD-B63D7BFCA84A,SmBusDxe +BA2EF68E-3F4F-4532-909D-5C23220DF84B,DashPldmSmbios BA31025C-4AA8-4CAE-98CA-BA12C6BC7D78,SmmControl2Dxe BA320263-FFD4-4DA5-A617-D832193E835E,AmdRasRsServiceSmm BA33F15D-4000-45C1-8E88-F91692D457E3,MpInformationHob @@ -7557,9 +8488,11 @@ BA37F2C5-B0F3-4A95-B55F-F25F4F6F8452,IntelGraphicsPeim BA4548D4-B207-4F68-B1D6-10AC7F9CF1C8,HddPasswordPei BA51887A-BEB9-45DA-8E37-98A6B46E7C58,IeHeciInit BA522681-CF67-49E2-925F-F60B32819039,FspInitNotify +BA57B64D-4AD2-68B8-AB93-AF89654F7DBE,AmdBoardIdDxe BA5B13F3-8B83-4871-8C3D-44CE683EAC1E,AmtLibPei BA658945-DEE1-42B3-9FA4-BB6B22FB03E4,efi_pop_mid BA67550C-3628-4137-A53E-42660E081604,MePlatformPolicy +BA6BADE3-B38B-49AD-AD8F-D6086F240E78,AsusApmDxe BA73672C-A5D3-11D4-BD00-0080C73C8881,EfiWinNtConsoleGuid BA7BE337-6CFB-4DBB-B26C-21EC2FC16073,SecCore BA7C38E3-6F1C-49D1-9CF9-5C67324EA40B,FjLidDxe @@ -7572,6 +8505,7 @@ BAA9B7C4-2B4A-4047-B254-C12B42F00D67,CrisRecoveryApl BAAEAD09-02A0-4131-9E0D-BC529EF0FF2A,EfiTcgMpDriverHobGuid BAB4F20F-0981-4B5F-A047-6EF83BEEAB3C,EhciPei BAC76586-3515-420B-A1B7-235A716ECAAD,OutOfBand +BACA647C-883B-4169-9E89-7910C060FFEE,GopConfigNex BACE07C2-8987-11DB-A59A-0040D02B1835,EfiUnixGop BAE29D7B-89BB-4223-AF76-96D0B3249B36,SsaBiosServicesPpi BAE5596A-14DF-40FC-810E-BB2428009600,HpCmosButton @@ -7593,6 +8527,7 @@ BB2F0636-B0DD-489B-ADB6-606FE3A47258,CpuHotAdd BB3B5FE5-4736-48DA-8C9F-76CE085F0515,FchSmbusPei BB3BF734-D640-4CF5-AFEA-CA8CFA6020D1,ASUS_USBFLASHBACK BB5B5907-5F8E-42AD-915D-5D98B52ED697,PlatformStage2 +BB5F17A9-7757-45A7-BA24-7EF53EADE84D,AmdSocFp11StxhPei BB628AE0-CD4F-49FE-8D60-63186FD1E05B,EfiCacheInstallPpi BB62E663-625D-40B2-A088-BBE83623A245,EfiEapManagementProtocolGuid BB65942B-521F-4EC3-BAF9-A92540CF60D2,SataController @@ -7602,16 +8537,20 @@ BB696233-9D1F-4AC5-B057-41DDAD3B0CC1,OemAcpiMode BB6CBEFF-E072-40D2-A6EB-BAB75BDE87E7,TcgPlatformSetupPolicyGuid BB7119B6-EF1F-4056-9321-CF29CC7A2FBC,I2cPlatformDxe BB76F1EA-750F-4131-BB54-A880AD72C9E2,TimerWakeSmm +BB801A52-C90F-4EDE-91B2-82520888CBC3,IntelgbeUndiDxe BB83F95F-EDBC-4884-A520-CD42AF388FAE,BaseDebugLibSerialPort BB87B31D-F366-47E9-885E-E816B09B97B6,DellAlertStandardFormatSmm BB8C2CF3-A5E3-49EF-941B-4A01FAC6FD5F,SmiFlashDxe BB906FAA-2A47-5C67-DD9F-6867FE125D4F,DGPU_GOP_2 BB9175E1-3E95-4B7E-8750-9D6AA34EB7F6,AsrockApmoff +BB927FCE-C965-4A80-B4F7-D065D961EF2A,FjGpnv BB929DA9-68F7-4035-B22C-A3BB3F23DA55,SataControllerDriverGuid BB983CCF-151D-40E1-A07B-4A17BE168292,EfiMemoryOverwriteRequestControlLockGuid BB9C7AB7-B8D9-4BF3-9C29-9BF341E217BC,EfiPlatformCpuInfoGuid BB9D2F77-E1FD-4451-A946-6E868D216E4D,PlatformNotifyDispatchPei BBA544D9-4747-4C3C-9371-F1ACB6B13CA3,DellNbEcDxe +BBAC47BF-CE55-4D4C-B728-A8866EE23000,I2CApplicationPei +BBADFF1E-B651-4014-B476-D42919A839D2,UsbTextLookupDxe BBB31581-855A-44D7-A550-8A585D9B2DE9,BaseCryptLibRuntimeCryptProtocol BBB71DD1-B993-487C-839E-7A7536B49E46,FjPowerButtonPei BBB77CB9-762D-436C-AC40-8EE4901C3446,AmdPbsSetupDxe @@ -7621,6 +8560,7 @@ BBCB6F85-303C-4EB9-8182-AF98D4B3020C,Tpm2DeviceLibTrEE BBCF59BE-2613-4960-A0A4-639B4A970206,HpEdidOverride BBCFF46C-C8D3-4113-8985-B9D4F3B3F64E,FspBootLoaderTemporaryMemoryGuid BBE2668C-0EFC-46FB-9137-4F2DA8F419F3,ConsolePrefDxe +BBEB4F87-720B-45D4-AA61-FBF6D4C54961,AmtMacPassThrough BC00DE36-935C-4577-8DC5-487F06B6DD12,DellSystemUsbPortConfigPei BC05DC37-9DA0-4050-9728-F34DDB01E200,BiosRegionLockEntry BC05DC37-9DA0-4050-9728-F34DDB01E301,SpiLockSmi @@ -7645,12 +8585,14 @@ BC59E2E1-7492-4031-806E-C48DCCC3A026,FspInitPeim BC5F861C-86ED-417E-BB7B-6C026BCD755B,EfiFrbCodeProtocol BC5F861C-86ED-417E-BB7B-6C026BDC6523,EfiSelStatusCodeProtocol BC5FA650-EDBB-4D0D-B3A3-D98907F847DF,PeiBlockIoPpiGuid +BC6102DD-3CC7-4B86-9A2C-4E125CABDF3A,FchKunlunDxe BC62157E-3E33-4FEC-9920-2D3B36D750DF,EfiLoadedImageDevicePathProtocolGuid BC664EF6-4C70-4FE4-B336-83E2FC47B697,DellEpsaBin BC74787A-BE99-4A2F-8C9C-C6D7E5C77AD3,BoardUpdatePolicySmm BC79959D-47E5-47DE-8E8C-49DE89B1FD9D,FjDeviceFirmwareUpdateProtocol BC7A1133-4C66-C6BA-B4D8-EB9FEFB9F146,AmdSocSp3r3CpPei BC85572D-F297-4D9C-93FE-DD9226C14591,DellSetupSerrDxe +BC8C4A18-E784-42A7-993F-88BCE13247C5,SupplicantDriver BC93AC24-BBAA-49DE-8EB5-2396F87929E0,AmdNbioAlibRMBDxe BCA793DC-6532-4BEF-96B4-FC297D1FEA98,DellPciBusPei BCABB6DD-3E9F-47E2-B8FB-10B39AF6342C,DellDaTaaMac @@ -7667,7 +8609,10 @@ BCD9DF8C-BE89-4007-986F-FA401A4AF94E,Int15PanelColor BCDAF080-1BDE-4E22-AE6A-43541E128EC4,EfiIsaHcProtocolGuid BCEA6548-E204-4486-8F2A-36E13C7838CE,FpgaSocketSetup BCECAD77-6299-415D-AE48-733C45476891,DxeWifiManager +BCED1375-8E68-4D9F-B8B4-37862B22FA6D,SDPlatformInitDxe BCF5F0BD-BF2E-4CFA-BE94-43DDDEC445B0,FjMemResizedLogDxe +BCF94D6E-86D9-4A87-A446-B21B803BD140,BootDeviceInfoSmm +BCFEEAA3-F3BC-4196-B9A6-AE569A6C0033,SmuV13Pei BD0ABB5D-A29F-4001-A3CA-98485EF7F224,AcpiSmmPlatform BD0B5ED6-468C-4372-AE52-47BA08F81A1F,RepSetHandler BD18369D-C242-45CA-82AD-138AC2E29BAB,EfiSmmIoTrapDispatchProtocol @@ -7680,6 +8625,7 @@ BD446386-7F8A-4EE1-A014-8D3BAB92B4E9,EmulationPlatformInit BD44F629-EAE7-4198-87F1-39FAB0FD717E,FspEventEndOfFirmwareGuid BD45A258-C7BD-4BF0-B254-D0D45E02F877,DellCmosManagerDxeSrc BD463212-701B-4E34-BEC1-F3FB7602F8AA,IsaHostControllerDxe +BD4759AA-5104-42A3-BC64-785920E86C99,FchProm21GpioSmm BD4E9C29-855C-4BD8-8173-3F10B617F250,FjDisableDefaultConfigOrMfgModeBin BD6736AC-B126-4FEA-9D1D-174D4A899F22,SystemErrorMenuDxe BD67BF44-CAB8-4A1B-A3F9-FC3CE2D0E764,DellUsbMassStorageDxe @@ -7731,9 +8677,14 @@ BE6B4F66-5B89-4DC2-9102-A178C8621CF2,UefiBootMarkerProtocol BE6D9471-C8BF-4B35-BEA7-7687CDF7E142,AmdMemFp7Pei BE731247-5FA2-4D5B-9DB6-5385CCCD59E1,UsbOcUpdateDxeLightningRidgeEXECB3 BE733C7B-07D9-4401-A08E-F475B0FA11ED,SystemPowerOnEvent +BE7FDB92-E3BE-4517-BD4B-C6FCBE00DAA1,MpDmaBrhDxe +BE8A2412-E62A-422A-870D-6185B7A32271,OemEcVerUpd BE9BE8AE-EBBB-450F-962C-BE1938E3FEF9,F2HotKeyAndCorrectPassClr0199 BEA143EC-5DEC-4C6B-A631-2C2E27759487,DreamTeamSleepSmi +BEA1E7E4-9C23-4436-B3FD-4420DC6778F8,USBCSecurity +BEA26CCC-CE96-45D2-964F-509B1BA17A81,FjNvramSmiDxe BEA39084-044A-4C88-8763-2BFAFFA8950C,LTEB +BEAEFFE1-0633-41B5-913C-9389339C2927,RedfishPlatformConfigDxe BEB07103-05F9-4B5D-89AF-29471D593CD5,S5Charging BEC14E72-A956-4676-87E7-B092087F5F6C,FjIntrusion BEE0DC09-B048-476D-A0BB-ACF9B4F65C41,DellUsbKbPei @@ -7743,9 +8694,11 @@ BEF4D2B1-C53B-4933-A3BA-2A422C89A439,AmiFriProtocol BEF5ED27-4E93-40F8-AE11-6B41E1D4BCA9,AbtEraseDxe BF00D49C-7784-4A06-9F5C-12FB9E68C72B,FjGabiFlashCoreSmm BF0A78BA-EC29-49CF-A1C9-7AE54EAB6A51,EfiMtftp6ProtocolGuid +BF13D47C-7671-414E-B3EB-1784073EC5FE,EcInit BF27A268-F369-43A2-B295-242DEE7F3C29,DellPowerButtonDxe BF2AE378-01E0-4605-9E3B-2EE2FC7339DE,FmpDxe BF3C55E3-2B74-4722-8105-62053C27CFBC,PowerOnHddIdleNotification +BF420205-644E-4718-9C39-679B7854F446,AmdSpiFvbSmm BF43D37C-7071-414E-B3EB-3C98D08AA32E,EcInit BF43D37C-7078-414E-B3EB-3C98D08AA32E,FjSysmanSmcsUpdater BF4B9D10-13EC-43DD-8880-E90B718F27DE,EmbeddedDeviceGuid @@ -7762,6 +8715,7 @@ BF8764D9-AE9A-4EB8-AAE3-04E5F675D866,FmacDriver BF885A32-2ACF-495D-A7BA-D3F92FA96289,DellXhciDxe BF89F10D-B205-474F-96E3-7A7BB1B4A407,VgaClassDxe BF90FDDC-F163-4FC6-A5A3-D0FDC8F7CE68,AmiUpdateCspResources +BFA8CC03-C1CD-439E-BCF6-14207A2CDE94,PowerEfficiencySync BFB01142-3061-48A4-922F-9D246E201120,AmiTcgResetVarHobGuid BFBEDBD4-1B7E-42F5-A528-4351E860F120,S3SupportSmm BFC2B71F-ACBF-4E54-9B19-B6EEB400507B,AmdCpmPmfDxe @@ -7786,9 +8740,12 @@ C034A2CB-1190-4638-9DDF-6F297824741E,TestPointStubDxe C03DDD47-DC0A-4319-9FEC-44B078C242E6,AmiTseOemPortingVar13 C0512F00-0181-48C0-8B71-90504B8F991E,EfiBootNameLabel C0557EED-9A89-4770-9626-FCA051F2BA09,PerfTuneWdtProtocol +C0571D26-6176-11E9-8647-D663BD873D93,DebugInfo +C05A042A-7E6F-410A-9177-E288D13C3C34,PsrControlDxe C05ED2D1-5DDE-4B6E-A1AE-0B306ACB42BC,TrEEDxe C0622982-A30A-48A5-8150-5ABF4191056F,LEMBootModeDxeSmm C0645FCC-5000-4BCB-9AE0-4D46796F1390,PdHostInterfaceIteSmm +C067DBFA-2C8B-4A7C-921B-28DCB25D9EDA,AmdNbioEarlyPhaseRPLPei C06C5A03-704C-45D6-808E-4D9E867897D3,AppleEffaceableLocker C07119A7-98AA-4DCE-B347-9608634AA06A,DiagnosticsConnection C0734D12-7927-432B-986B-A7E3A35BA005,LightPciBusPciBusDxe @@ -7803,6 +8760,7 @@ C09C81CB-31E9-4DE6-A9F9-17A144354245,AdvancedPkgList C0A02971-C45C-47A6-AAAA-3F089A7B7A50,DellRmtPlatSiDxe C0A235DB-17E7-448A-B8E4-2E29FDFBB158,LenovoEventLogVariableStoreSmm C0A2EC40-7CA9-4FF7-A17C-08B81D70DE80,ECSmmFramework +C0A8BD98-DED0-4313-9970-6FE2794CD157,AmdCpmOemInitPeim C0B9206E-B6AB-4DF0-B3D6-286AC76698BD,DellD010AlegacyVideoRom C0CC43BD-C920-4064-935B-93B447379470,PowerManagementAcpiTableStorageGuid C0CD2D36-A81B-450D-A502-3767DFA29826,EfiPlatformTypeNeonCityEprpProtocol @@ -7811,11 +8769,13 @@ C0D5EC34-13E4-403B-9643-54AA7F72259D,SystemSecureFlashAuthenticationSmm C0E0A489-FB6C-4509-B1B3-C7119D489502,XnoteAcpiNvsSmm C0EBC974-B5B2-4725-9091-9F45578F213C,AddressTranslationDsmMemRas C0EC00FD-C2F8-4E47-90EF-9C8155285BEC,TcgNvramHobGuid +C0EE640C-B469-4EB1-8F11-46ACA1427307,WmiRmtApiDXE C0FDBE28-4E64-44AB-9F7E-F33140E4FA2F,FanTableDxe C10194E7-DEB2-4AF4-9EEE-BFFDE4D7D4C7,TimestampDxe C10A9E4D-BDB4-4B1A-82CC-D901F86F5739,DellSmmDiagLeds C10FB8CA-55A8-4132-8263-3D5B82359F04,AmiHidServiceDriver C112BF94-5CD0-45EC-AA7F-D3DEDAAB765F,OemWSsdtDriver +C1172A76-6A56-4C09-B1FD-C29F94DA1380,AmdMemoryHobInfoPeim C1176733-159F-42D5-BCB9-320660B17310,UbaConfigDatabasePpi C118F50D-391D-45F4-B3D3-11BC931AA56D,DsdtAsl C11B7A48-BA61-48B4-9198-48972B538007,SystemSdLegacySmm @@ -7823,7 +8783,9 @@ C11CCB12-C17A-4266-B47D-18FD101811EA,HdpBackupToNvram C128CADC-623E-4E41-97CB-A7138E627460,BaseFspSecPlatformLibNull C12A7328-F81F-11D2-BA4B-00A0C93EC93B,EfiPartTypeSystemPartGuid C12C4E6A-BC3D-4A91-8299-7E0A4D5B5289,SmcOemID +C1300EE7-4BF6-4164-9FDC-DC3E8EFB7FBD,AmdNbioPei C13111A8-6BC9-11E5-8797-001ACA00BFC4,BlueFieldDxe +C13C549F-2CBB-4868-9EE4-97D5DC69FA47,OneTimeBootDxe C1443436-B954-43BA-8278-C1E442C21539,DellFlashWriteProtect C144476F-F118-4C84-A936-417C8AFBD437,GenericUSBDebugger C146B184-8891-49D3-B734-CACDD84FC942,ATH9K_UndiLayer @@ -7832,7 +8794,10 @@ C1544C01-92A4-4198-8A84-778583C23621,EfiPxeDhcp4CallbackProtocol C162FF6A-F5A5-4DB7-9ECF-80EEC2501768,UtilityPartitionDxe C166B802-190F-4BFE-B8CD-EE53971A063C,PeiMeCore C1685343-EE19-4BAF-B47D-5C995DF7FA2F,StaticSkuDataDxeEVB +C16E2B26-B1D9-42BD-9002-BAB27F18A573,PspFarCheckDxe +C171DBBB-3AF7-408B-954E-789BFFD8CD2E,AsusBackupPei C178E415-6E49-469A-B73D-F6C5EB4101EB,AmdSpiRomProtectDxe +C181D3D6-ECDC-45D8-B586-9EA1851867E4,PlatformStatusCodeHandlerRuntimeDxe C182FB38-0FE4-4BEC-9270-A273E1EF2C80,AmdXgbeWorkaroundDxe C184562C-6864-40A3-A081-C8D35E82B920,WinCeGuid C18B8105-AB89-44DE-8D37-50B31FAE5D1E,SgTpvAcpiTables @@ -7847,6 +8812,7 @@ C1A78A9E-11E8-4910-91A5-FE48F5F4C20D,DellEpsaDxe C1AABE42-2CA8-4361-B37A-1466520E960E,FjNvsAreaRt C1AB12F7-74AA-408D-A2F4-C6CEFD179871,EdkiiMigratedFvInfo C1B135AA-7ACB-45D0-80B7-862B8D5F0CD5,AmdFabricRvSmm +C1B2415B-3D28-4766-AAE8-EFBEF3BF1451,AmdSocSp6StpDxe C1C31CFA-911C-4324-AB4C-79E8E6DE48E8,LEMDisposalProcess C1C41626-504C-4092-ACA9-41F936934328,EfiCertSha256Guid C1C418F9-591D-461C-82A2-B9CD96DFEA86,LegacyInterrupt @@ -7867,6 +8833,7 @@ C21CF0E2-6ABC-4C3B-9DE6-3ABA8C3F83C9,DxeIchSmbus C22077A1-5F9B-4891-9D1C-DEAA3632E921,DellUefiBootInfoDxe C2223A0B-80D3-4C35-891F-BD0CC4E990F0,LenovoSystemFvFileLoader C2239ACD-21D0-4CB0-B7DB-6D35EE7B0CC1,FirmwareRevisionSyncPei +C2281410-58B3-4F74-9458-22901ACEB901,EepromInterfaceCoreDxe C22E6B8A-8159-49A3-B353-E84B79DF19C0,VARIABLE C246FBBF-F75C-43F7-88A6-B5FD0CF1DB7F,AmiDbtFileGuid C24E74B6-4155-4E64-9A91-C1E44F5D0BBE,OemGlobalNvsSmm @@ -7890,9 +8857,11 @@ C2D52AC9-7C0E-47F3-8738-865B3F3BCF99,AmiPciPlatform C2E5D736-0771-42AC-B99F-1B7F1CA5610A,FileAccessPei C2E5E29C-E39B-4E8D-9909-E00A145359FD,HpFlashMe C2EF28BB-C6BD-4CB6-A3A1-BF6BB7EDA9F3,SecureBIOCamera +C2F1BD4E-9FEE-4079-909B-C683A86750CC,FchHuangshanSsdt C2F9AE46-3437-4FEF-9CB1-9A568B282FEE,FspSecCoreM C3068C28-3579-4670-B38D-2E21AD057993,PlatformHiiAdvancedDxe C3069C81-6717-4FB6-B646-04214894BAB4,SmcSwSmiFlashDxe +C30792A9-10F1-4B0E-9AF6-C95CD8B027CA,FjLanReInitPei C30ADC21-4AA5-4313-A7E7-53395B42BEAB,AmdCpmDisplayFeatureSmmBr C30B94E3-C8F2-4AB0-91AB-FA8DF621B1C9,MnpDxe C30FFF4A-10C6-4C0F-A454-FD319BAF6CE6,IntelBootGuardBootPolicy @@ -7903,17 +8872,20 @@ C31A6189-639A-458B-B040-D7D506CA8F4F,GetHostByAddr C3253C90-A24F-4599-A664-1F8813778FC9,ArmGlobalVariableGuid C3274B63-ADE0-414C-BC43-12AB926C634B,IdeBusPei C32A66D5-D8B7-2640-B768-082C8F083C37,ThunkPpiToProtocolPei +C32B1741-9035-4935-AA2F-3E49ABC9D77F,HpThermalDiagsDxe C358B1F8-8A88-40B6-89BB-28ECD6EDDB24,PxeDriver C35B1E30-30F0-4F14-B603-28556F14F874,DellDtDevCountsDxe C35F272C-97C2-465A-A216-696B668A8CFE,UserProfileManagerGuid C35F9520-5791-4667-ADE4-1CFDA837722D,AmiSmiVariableDxeDriverStarted C37297CC-3FD9-4026-9890-7A1628184620,EcIoPeim +C3745B97-5133-4BF7-8185-663617B95EBF,UsbPwrCtrlDxe C3811036-710B-4E39-8CF1-0AF9BE3A8198,TimerDxe C384EED1-B17A-40E4-B0C9-BE86D8B4DE40,KEMhResetBtnPei C38E6D34-5A7F-4BF9-BE57-94DD30380276,EfiPccardSsProtocol C38FB0E2-0C43-49C9-B544-9B17AA4DCBA3,PowerManagementAcpiTables C3944F59-4029-CCEB-AE0D-D4A6B479924F,UsbPortConfigDxe C39B4C90-CB56-49BC-9534-012F69A1C2CC,UuidPeiInit +C3A657D6-5FD4-4BAC-BEDE-0EF613750870,CrashLogVariableUpdateDxe C3B95ACF-4ED2-8462-AA52-788415A61C4B,GpsOnWwanSmm C3C242D1-0103-4C74-9A19-3C5C3B47EBCE,DellBiosAttributesSmm C3D69D87-5200-4AAB-A6DB-2569BA1A92FC,Tpm2DeviceLibRouterDxe @@ -7921,15 +8893,18 @@ C3DFAEFE-D237-4A20-8BBF-5444FDE098DE,FjPostScreenMfgFirstPowerOnDxe C3E36D09-8294-4B97-A857-D5288FE33E28,EfiBiosIdGuid C3E69EB2-0429-4BD6-AE4A-8CA02FBACC2E,AdvancedAcpiDxe C3EE3EF0-63E6-4F59-A437-AFA63C46C835,SmmAslSmi +C3EF34B6-057D-4614-B35D-FD4384FA2391,AmdFabricRplSmm C40DAA42-6E1D-4F6F-96F0-5E17BC8A1D4B,AmiHeciDeliverRuntimeDxe C40DF81F-7436-4661-B645-A933B5D2F3C1,AsusFWUpdateInterface C41459C2-A281-40D3-B30A-2B9DFF3F3DA0,DellSaveMemoryConfigDxe C41E9862-D078-4E7D-9062-00E3FAC34C19,AsusEcPei C41F8C82-B3E6-47E0-A61D-0F9E429E6996,DebugCommunicationLibUsb3Dxe C426C295-9829-441E-931E-9CE35E3F9FE6,UiThirdPartyApp +C42DD02B-BB83-4118-8F16-31011415A63A,UserLEDCtrlPei C4331752-8BAC-4F2A-A9C3-418ADFB033C4,DellSpiPartWinbond C43E2CF0-BEDC-461F-AACD-A4FA466EA382,LenovoTpmConfigPei C4408AAC-281F-4C4A-BE99-2E5C56BCC16D,OdometerInitDxe +C448F450-D9D2-4BDF-AC47-6EB2A225D54B,AmdOemRasRsDxe C4491F51-66B9-4590-95E4-E2B4AD777703,HeciSmm C45BC25F-3937-4FC4-AC79-BBE8BD3E5F97,AdlinkBSCSmm C463CEAC-FC57-4F36-88B7-356C750C3BCA,UhciPei @@ -7942,12 +8917,15 @@ C47D89B9-B9DC-4CA0-BB20-5B06EBE57A1D,IpmbDxe C48D651C-9D0E-4CE7-AD39-EDD1AB836B30,AmiTseAfterFirstBootOptionGuid C49189F3-1D4C-4AD7-A439-D013AB720931,PerfTunePpi C491D352-7623-4843-ACCC-2791A7574421,DefaultdbFile2 +C4968F6A-5CCC-4BDC-9E86-B7A65A2EEAF1,AmdCdmaDsmDxe C4975200-64F1-4FB6-9773-F6A9F89D985E,SaPegDataVariable C498F432-B8B7-44BF-86D3-7B36F2EC1390,IFWIVersionHobGuid C49A3700-A175-4451-BAE1-3E5F91D0D46A,DellAmdCbsApcbUpdateSmm C4A58D6D-3677-49CB-A00A-9470765FB55E,AddPerfRecordProtocolGuid +C4B4A7FB-D2E2-422C-4179-E5D46B1E1AA6,OneKeyRecovery C4B50EB2-ED16-4283-A5B0-A7341C3F997B,ArmTrustedMonitorLibNull -C4B8C7FB-D2E2-441C-BAD6-E5D46B1E1AA6,T23HookResetSystem +C4B769CD-2876-41BD-ADA2-79677F9697C3,aDefaultPei +C4B8C7FB-D2E2-441C-BAD6-E5D46B1E1AA6,L05DxeServiceBody C4BBBAE3-F891-4D4A-90EE-0F05D932C151,FpdtPei C4C7A1A9-D639-442D-B358-09D06AE18BFC,DellDaAssetTag C4CC0DE8-0687-4422-99C1-65351A5D5F95,UserDefaults @@ -7958,18 +8936,21 @@ C4ECA0B2-5277-4F2B-3ECB-E4175C94812E,ExtraS3Memory C4F2D007-37FD-422D-B63D-7ED73886E6CA,IdeRController C5046EFD-7BC3-4206-987C-32DA45026E6D,PlatformInitDxe C5068BAC-A7DC-42F1-AE80-CAA24BB4904B,PttPassThruPpiGuid +C50842D6-B284-4F3D-904B-E2DC83E00AF8,EarlyConsoleOutInterfacePei C50B323E-9075-4F2A-AC8E-D2596A1085CC,EfiSmmIchnDispatchProtocolGuid C5149B43-AE85-4F53-9982-B94335D3A9E7,EfiRngAlgorithmSp80090Hmac256Guid C516673C-6C71-4F0E-83B5-57FC662376EC,LibPosix C51711E7-B4BF-404A-BFB8-0A048EF1FFE4,EfiIp4ServiceBindingProtocolGuid C5184932-DBA5-46DB-A5BA-CC0BDA9C1435,EfiHashProtocolGuid -C522E695-93FF-4AC7-8220-F849C68C538F,APMDXE +C522E695-93FF-4AC7-8220-F849C68C538F,AsusApmPei C53B2402-0073-4C8C-B4ED-99F362742D24,CrbSdev C53C63B4-39C1-4185-BC9B-0FE9722A0C60,SmrrEnableHobGuid +C5440ED5-9BA4-4ABE-BAF6-F45468481DCD,CbsSetupDxeSTXH C54B425F-AA79-48B4-981F-998B3C4B641C,TrEEConfigFormSetGuid C54F4B67-E527-4379-BF61-193C7A68C661,menu_none C54FB758-5DC3-4068-893A-4E67F7CCF5D4,FjDmiFJJSpecific C55C14F8-8ED0-48CC-9836-DDF6A3C5EA11,InstallRavenPlatformSsdt +C5653FBC-B146-4B91-8EEF-1AEEAE7A0160,ToolInitialDxe C56EDB22-3D78-4705-A222-BDD6BD154DA0,TpmClearOnRollbackSmm C56FB1B2-017B-4984-A3F6-3F734FFA9E33,EfiUdpProtocol C5753963-3B84-4095-BF78-EDDAD3F9C9DD,EfiPciBusErrorSectionGuid @@ -8002,11 +8983,13 @@ C65AF0E1-82B3-416A-8F0A-DDD0D3098C58,DellPbaUsh C65CFED1-8BA5-48D4-A493-9E12F17952B0,FjGabiSettingsApiItemAccessSmm C6602CDF-E16A-4147-9B9A-0B399498722A,SystemCrisisRecoveryPei C666A794-406D-4A51-B303-ACFB59137A05,UsbOcUpdateDxeEldorado +C66E52C0-082A-48AB-BDDE-ED60C88CC4DA,FjLanReInitDxe C66F98CC-9840-40A6-BDC1-7B4CCC77F8C6,RtkUndiDxe C66F98CC-9840-40A6-BDC1-7B4CCC77F8C7,RtkUsbUndiDxe C6734411-2DDA-4632-A592-920F24D6ED21,AmiAtaPassThruInitProtocolGuid C6760651-A38D-5F4F-AEAF-F6661549DF75,EmuBlockIo C67CBA49-B3C6-4CBA-9671-BF2788712128,DellLegacyTcgSupport +C681ED8F-FC2E-41A4-8F3F-2C2A1961A81B,FchProm21Pei C68C190E-F95E-4ABC-AA01-D65F344D91F9,LGImageRecovery C68DAA4E-7AB5-41E8-A91D-5954421053F3,CbSupportDxe C68ED8E2-9DC6-4CBD-9D94-DB65ACC5C332,EfiSmmCommunicationProtocolGuid @@ -8018,10 +9001,12 @@ C6BB86C0-16F5-4535-953E-E6C7CB6E4CB6,FpgaErrorHandler C6C9AC93-CFC8-414C-872B-D0116F076BF9,HpThermalDiagsSioSmi C6D37AB1-ACBB-4928-A956-577BB3DBB751,DellDimmLocation C6DF98F2-5EC0-4A94-8C11-9A9828EF03F2,WifiConnectionManagerDxe +C6E9602D-C00D-4250-B24D-FE324B8DA40B,AcerPortingDxe C6F6CF5A-F085-401E-8402-00134B668703,FjFextPei C70522D0-0DDB-4623-AAB7-B84DFC47EFFD,AodSmmSsp C70522D0-0DDB-4623-AAB7-B84DFC47EFFF,AodSmmSsp C723F288-52F9-4D80-B633-E152F930A0DC,EfiSimpleAudioOutProtocol +C7340A2F-0539-42F1-B9EB-0C35237A4923,CbsBasePeiRMB C73413C9-405C-4F50-BA17-0DFFB913ED16,DellDockPolicy C7351A96-9215-4026-BCBD-12D6E7DB36E9,SystemFormBrowserMetroViewDxe C74233C1-96FD-4CB3-9453-55C9D77CE3C8,WM00WMISmmHandler @@ -8031,6 +9016,7 @@ C74F06D2-ED92-489B-879C-C0E428A22167,UefiRaid C7542254-A8F7-40BA-9BB9-390D31977775,OCMR_PEI C75F1B28-B273-4F0D-9838-952B70E6B9B4,UsbCardReaderSmm C770A27F-956A-497A-8548-E06197588BF6,RecoveryOnFatNvmeDisk +C770F6C2-3278-4A57-A1DB-E177F8DB2CD7,AmdRAIDCoreDxe C7715FBC-E2AB-4A33-840F-5DCD0198E552,SaDxeMiscConfigGuid C7735A2F-88F5-4882-AE63-FAAC8C8B86B3,EfiVAminiPortProtocolGuid C776AEA2-AA27-446E-975B-E0BEA9078BD9,BiosGuardPeiApRecoveryCapsule @@ -8038,6 +9024,7 @@ C779F6D8-7113-4AA1-9648-EB1633C7D53B,CapsulePei C77C3A41-61AB-4143-983E-3339280628E5,EdkiiCpuFeaturesInitDone C77DD102-1DB4-4997-AE37-4E8C521EF567,AmiProcessTcgSetupGuid C79DD14B-C66D-4ADD-A5A1-CBE3FDF2BD72,DisableCacheAsRamPei +C7A0C4A4-B05F-41C1-B137-F19686B302AF,SetupConfigUpdateDxeSierra C7A7030C-C3D8-45EE-BED9-5D9E76762953,MouseDriver C7A90676-51CC-4FFA-B5CA-69EA88D2F78D,EfiPlatformTypeOpalCityFpgaProtocol C7AD44B9-A775-4801-B772-A964262BB92E,ModuleS3ResumePeim @@ -8054,6 +9041,7 @@ C7D4BBCF-EB0A-4C91-BD8B-FCA99F28B011,AmiTxtPei C7D4F4E3-DAEA-40B0-8846-F4CAF3135CE8,BiosProtectDxe C7D7B773-68E6-4626-80F9-609C4451EB0C,FjDmiWakeCause C7D9BAF4-DC9D-4B22-B4E7-7500EAA7B67F,SiliconDataInitPeim +C7DAF48F-4787-11E4-9077-047D7B99E097,VariableRuntimeProtectionDxe C7DCFF6F-6F2A-4DC1-91C6-DF0BAFDBDA46,VbtMipiSharpGuid C7DD8530-96D8-40DD-BE88-CBDF446C6474,Stibp C7DF48CC-063E-4FD4-B775-75C00D9F19F6,SmbusDebugPei @@ -8062,6 +9050,7 @@ C7E6800D-9566-1143-81A8-B8C566AF3556,SNP C7EA9787-CA0A-43B4-B1E5-25EF87391F8D,PchS3Support C7EA9F94-1547-44F0-863F-563EAE79E1C0,TianoCompressSmm C7F7A2D8-7DC9-40B5-AF51-7BB0A1FAF12E,FjAzaliaVerbTable +C7F9E27D-045A-4D33-85BD-C7D0ABA7C836,It8659 C7FCCF43-5859-4ABE-BCB5-4C1626ED8B03,DellPeiDiagLeds C80EA8F3-A3C9-4225-AA60-769DD4C74E43,LenovoSvpManagerDxe C810485E-D0EC-4E98-AAB5-120C7E554428,TdtAm @@ -8069,18 +9058,23 @@ C811FA38-42C8-4579-A9BB-60E94EDDFB34,AmiTseSetupGuid C81C25C0-533B-48DF-93E5-B87807901CF6,MiscFunctionPortingPpi C81FFCBF-BB77-400B-BC86-C9B16CF95EAE,AppleUsbNotify C826B086-AE21-416C-9977-0D55AAE742B4,EcAuditLogPei +C828DD3F-8868-40A6-AA59-D5CA372D0937,UefiDriverAsix88179 C82919D6-33FD-43ED-800C-635A3369D0F3,SystemDiagnosticSummaryScreenDxe C8300EA9-869E-42DF-AEF2-5D939452A353,SetupDefaults C8339973-A563-4561-B858-D8476F9DEFC4,Metronome +C84D9EB9-B703-4CA1-BF74-903106A37346,aDefaultDxeLate C85171A2-9CBD-4E74-8C9B-D33384A236A3,I2cGlkToMde C85903B6-84B5-4D78-B59D-D2D6B97580F3,PngConvertDxe C85D06BE-5F75-48CE-A80F-1236BA3B87B1,EdkiiPerformanceMeasurementProtocol C86181CD-B38C-49DD-A176-7DC3591816A9,DellHotKeysConfig +C8638628-5B57-47B9-BA9A-AB1F90709C3F,AmdPspDxeV2StxKrk C866BD71-7C79-4BF1-A93B-066B830D8F9A,MpS3 C867A8C3-5BF1-4B33-82FE-B1B49D5286EE,OEMAcpiPlatformSmi C8714E83-895E-4192-FFFF-FFFF293630B3,XnoteRecoveryLauncher C8786997-70D7-4445-A5A8-E5C9C8DD56C6,MasterPswd C87DBB18-9ADD-41D5-80D7-4C8D795AD942,DellSmmEventSmm +C8858B5A-7A6A-4193-9253-CA6AB5F1EA37,DashMctpSmbusDxe +C887F4CF-4565-409B-9178-D2BF1D228DED,SioSetupUtilityDxe C88B0B6D-0DFC-49A7-9CB4-49074B4C3A78,EfiStorageSecurityCommandProtocolGuid C88D7B8B-2A7B-403D-A8A2-EF0A5AEE662F,OemEcRTCBackup C89851DD-5EA0-42CE-8934-EB8EA608FBA9,LenovoSystemAcceleratorKeyDxe @@ -8105,36 +9099,46 @@ C8FF7F70-1B85-4C66-A983-69699F62E91E,N19EP_GOP C9122295-56ED-4D4E-06A6-508D894D3E40,FspApiPerformanceGuid C9168F11-0C60-4A8C-A41F-1B2289315F4E,EcRotEnterRecoveryPei C91C3C17-FC74-46E5-BDBE-6F486A5A9F3C,AmiRomLayoutFfsFileGuid +C9265471-71A3-4D74-AA7A-3E6C5EC81135,AmdRasBrhServiceSmm C92B795E-CDFC-4932-91B5-00BBB5F0C95E,FjIbvInterexchangeDataStorageProtocoDxe C92E82A5-AD25-4800-9422-CBE8E7A30477,OemDgpuBoardIDDxe C92F72B5-7DD0-4E15-9D2C-A52CBD30CA1E,LenovoSmpManagerDxe C937B8BF-ECEB-4F42-907E-37A5D4C17B9D,CompalEepromDxe C937D89B-5F9C-4A1E-B10D-8F53D7474220,AmiPspRecovery C939F82A-3501-4657-8256-FD4C2288872F,HpErrorLoggingSmm +C93AB4BA-796E-4956-BF8A-B46EB1AFE737,MfgDoneSmm C93BD9EF-FB79-41CA-AFA2-C9D909730C91,FjAcpiPlatformDxe C947C2CA-C1E2-4007-BBE0-FD7C7865A548,DellNvmePwPei C952402C-F2A8-410F-96F7-2C789BE0E0A1,LenovoTamperDxe C95E6A28-FB95-49F2-AE01-F38166FD4524,OemServicesDriver C95F8AB0-1BC2-417C-8377-9815F578A9EE,UsbOcUpdateDxeExpertWorkStationRP +C96C3984-429E-4FAD-8A61-C1E86BA43BF8,AmdNbioIOMMUDxe C96C76EB-BC78-429C-9F4B-DA5178C28457,TpmNvsMm C9737920-C2AD-41C3-B133-0F9C251B6743,PeiDebugDispatchPpiGuid C97809C0-5F90-4466-8B38-341D7A67CF54,LenovoSmapiSmm C9839A23-4B0E-465E-8F29-14A5010CA7DF,PerDisCptInRomPostFlag C98AE68F-82B9-47BC-BE87-33240E110D68,DellUefiBootInfoSmm C99E42D0-4964-4B09-B924-4A59E13E4F04,SbRunSmm +C99F80E9-4CCC-4F34-AFE7-9194BF121412,GnbSocPhoenixDxe +C99F80E9-4CCC-4F34-AFE7-9194BF123590,GnbSocRaphaelDxe C9A3B737-8841-499E-814C-463054C7C7A3,FjPowerOverEthernet C9A44DC1-A394-426C-8B3E-7EE532A55037,AmpI2cDriver C9A6DE36-FDFF-4FAF-8343-85D9E3470F43,NvmeInt13 C9B8B0B7-9C85-46E8-B343-362FBD26E8F3,MuCryptoDxe C9BD03EA-40D6-D14E-0FFE-6B803FC3ADF4,CpuTechDxe +C9C01943-980E-DD30-A095-A411ACB3D229,WtTouchPanelDxe C9C30DD7-91D6-4F75-BF08-846E6020F1A8,AmdNbioIOMMUZPDxe C9C39664-96DD-4C5C-AFD7-CD657629CFB0,CpPlatFlashTokenSpace +C9C87129-DFAC-48DE-8581-7363A90E101D,UFSProvisioningTool C9D9CE44-708D-4E27-B989-E35A33999C28,DellSmmMultiPlatform C9D9D2A1-E586-4F2F-BF6E-99240C069EB1,RealtekWsTbt3Pxe C9DCF469-A7C4-11D5-87DA-00062945C3B9,EfiStandardCallerId C9E057D7-3B6D-475C-B8C2-7C955D2F58B3,gear4 +C9F1A91B-3AB2-4AEA-8B5A-374876B941A3,SDEmmcInfoSetupUtilityDxe +C9F36E6A-6884-465D-A20D-0610B65CFCD6,SyncBIOSimage C9F5A078-1F2D-4086-A1BE-1638774FEF44,SsdtRtd3ATables C9FAF091-57F8-A64C-A07A-445B124F0D93,FlashMapPei +CA05F74F-1E56-46A9-AF6C-DE5BBE83A37D,MemoryMarginToolHookSmmStp CA0D6FF6-62A7-4B1F-BB90-52EECA01A99F,TCM_MADriver CA1BCAD9-E021-4547-A1B0-5B22C7F687F4,ACPIOSFRModelStringVariableGuid CA261A26-7718-4B9B-8A07-5178B1AE3A02,DiskIoDxe @@ -8168,19 +9172,23 @@ CA915DD3-4C9B-4471-ADE1-33DF66765DFD,LenovoDashSupportDxe CA9725C0-12E5-4FAC-AD58-D9AAB03B8F11,LenovoHdpManagerDxe CA9D537C-0B20-4F94-9283-45F4D51A748D,DellAsfBypassAbstraction CA9D8617-D652-403B-B6C5-BA47570116AD,TxtPei +CAA3FA1C-76C4-44CE-BEC0-3E6D847AF8D4,EfiSmiServices CAA4381E-750C-4770-B870-7A23B4E42130,EfiHashAlgorithmSha512Guid CAB0E94C-E15F-11E3-918D-B8E8562CBAFA,EfiBootManagerPolicyConsoleGuid CAB9347C-8CE9-4DE1-9C6F-6457AC69332B,PrepareForScheckEvent CAC3FB95-33F5-4596-818B-68E024DDB67B,IsSecRecoveryPEI +CAC7FADF-36F8-414F-8E1C-8A80AA5C78D6,DashPldmBase CAC94001-5611-4440-9B21-F54B700A1D34,DellSmmSystemSioProtocol CACB3817-81E6-497E-87FF-C8FA8F24EC28,SgACPI CAD40D6E-C871-4398-910D-2D74EE94711A,AmiTseAfterTimeOutGuid CAD9920E-0CF5-4C6B-B92B-CC0A4E19557C,FjSysmanAmphionSmm +CADAB771-60DF-A925-19B3-0A6608DD2DA5,CCGxFwUpdateDrv CAE0AD55-47B7-4E03-A714-95E1711CC279,BcpBootOrder CAE2D87D-5CBC-47E7-8CAD-50377A5D0E90,PlatformErrorStrings CAE3AA63-676F-4DA3-BD50-6CC5EDDE9AAD,EdkiiPeiNvmExpressHostControllerPpi CAEB83C4-23AA-4311-8327-8B72DDB7041B,RcPolicyOverrideDxe CAEE2F3B-3191-4DA0-AD10-A5C07E636CD1,LibString +CB077E14-EBD8-4AC2-986F-82F3CD4E717E,SdHostDriver CB2337F3-CF73-4164-9B73-798BBF8928DF,TPMDxe CB2987B9-63AE-4B91-BF43-21FF641A5D49,AmiUpdateDxePolicyCallback CB2A97CF-3D3B-4215-B528-7B8944200E46,CcgxDiscovery @@ -8192,7 +9200,10 @@ CB4B5BB5-59A6-48BA-A77B-B4E4B3D491EB,OemDxeWwan CB4CE667-ED8D-4A66-B437-EA6A970F2E48,SmmResetSystem CB537AA2-F727-440B-9702-ADE9D0A293F1,PlatformStage2Pei CB5C54C0-230D-43DB-922C-24D34F8C915C,AmicsmPciBusNumXlatProtocol +CB659161-B780-4906-914A-DB57D1DD544A,EupControl CB73C3D9-2F01-4342-AE67-04DDE5264092,SmmPlatform +CB76358C-3A21-44BF-B7C1-33F064AC4C11,DisableUSBPei +CB7A797C-57D9-4616-88B4-624213967BD7,CompalDptf CB871572-C11A-47B5-B492-675EAFA77727,EfiDiskInfoUsbInterfaceGuid CB8C0E4F-14F7-4F5A-8DAD-752CB0B42045,SystemStatusBarDxe CB90F8BD-7012-407D-88A3-7D5E9E701B87,PilotIIIPc8374 @@ -8217,12 +9228,17 @@ CBF25110-18FF-4EE3-9735-E2477436FF3F,XnotePlatformInfoSmm CBF36E61-59D3-11E8-8518-B05ADAEB7886,NvdimmLostPassphraserecoveryDxe CBF486B7-D196-4C03-AFE2-33F38E64DA16,IntegratedTouch CC043281-112F-441C-805D-6D8DB3659618,BbstableHook +CC05C4D7-87B1-4605-A83F-592FFD53F959,mFmacDriver +CC0F2ACF-8883-4DA7-8F62-39A6BDC6BD4C,OemSetupValueHookPei CC0F8A3F-3DEA-4376-9679-5426BA0A907E,PkVar +CC17F218-E492-45A2-A1A4-16DBB1BB11C5,AmdNbioDxe CC1BAA36-11EB-45CC-9ADC-7565E273AC70,PnpSmm CC1FC04E-0B3D-4E0E-AED7-5898541E2683,CSMLinkerDxe CC243581-112F-441C-815D-6D8DB3659619,A01D2DRecoveryDriver +CC276239-D6E5-41D4-AC30-36794E52B98B,FujInSmm CC28F998-EB90-47FB-97CD-032151F6FCB9,OemSetCbsVariable CC322E80-6A08-4E80-8BCA-01A84BA6CFE4,PciHostBridge2 +CC34A436-EC78-4330-96CB-1AD2216CF87B,InputmodulesApp CC3CE225-D9E0-4AB1-AD66-B857C2D16D2E,FchKeithSsdt CC42B4D3-7220-428A-9B6E-E44971D02809,DellSmmMfgPolicyProtocol CC5263E8-9308-454A-89D0-340BD39BC98E,EfiEventNotificationTypeInitGuid @@ -8234,9 +9250,11 @@ CC620D5E-FECF-49D4-B51B-461D52494669,AutoEcud CC664EB8-3C24-4086-B6F6-34E856BCE36E,EfiWinNtPassThroughGuid CC6E66A3-472A-4802-9B97-21420C026391,AmdCpmZeroPowerOddDxe CC71B046-CF07-4DAE-AEAD-7046845BCD8A,LenovoVideoInitDxe +CC74AC11-6121-4EDA-A857-4D6EA9357CEE,Nct6126dTrdPeiInit CC74C741-4A5F-4A8E-B689-D804AB4368CC,DxeNotifyEC CC81918A-AC55-4FCD-83E6-0C1CC22937EA,WakeSourcePei CC84D725-DA1E-46A7-9E75-4BACF1FD3902,SystemFontDxe +CC8A8528-23F3-427E-AF41-C91E3297B622,AmdFabricStxKrkDxe CC93A70B-EC27-49C5-8B34-13931EFED6E2,EfiAlertStandardFormatProtocolGuid CC9F5B7E-254B-4F8A-A648-034A40AEDA35,PlatformCustomizePei CC9F6A7E-245B-4F99-B548-034B30BDDA44,FlexIoCard @@ -8252,6 +9270,7 @@ CCC5C136-ACD3-4251-9BDC-F663CD2297B7,AppleAudioDecoder CCCACBF6-0BDD-4460-927D-D1D4F21EA6EA,DellBiosDRAMChipLocation CCCB0C28-4B24-11D5-9A5A-0090273FC14D,GraphicsConsoleDxe CCCC8702-BD68-45B1-8237-C7DD004CDB37,DellSmBiosStrucD2 +CCCCD383-7145-4850-A4BE-89C36A15BA15,GpioV2ControllerPei CCCD2056-D401-4DEF-85B0-1FA11FF3B5E3,IioVvar CCCD3CAE-170D-4E34-8766-57B9042BEBB9,EcEkKey CCCDBAC6-7383-452D-B8AF-C5E29D7D0BFF,SystemPolicyManagerPei @@ -8260,27 +9279,33 @@ CCEC84CD-CDC5-4C75-8637-D4508FC79CCD,PngConvert CCF23F50-F7C1-4F00-8E70-13643C37E8B0,TBTRetimerFirmwareUpdateDxe CCF949FC-F831-4CEA-BFA1-C44983B99B91,AmdNbioGfxRMBDxe CD0A2EE7-418B-47E3-89C4-65D9169EFD23,PublishMrcNormalFv +CD0A45A4-8980-4A63-9A0D-014549D283C0,FjUsbHubRTS5420 CD167C1E-6E0B-42B3-82F6-E3E906199810,FspReadyForNotifyPhasePpi CD1B61E8-C6B4-420D-A1C5-2A75083CB0A6,FjMasterPasswordSmm CD1C556B-62BF-4EEC-8E73-7731F8E847B2,AmdCpmGpioInitSmm CD2333D7-6A0A-4C76-8350-240ADA36A2C7,DxePlatformSaPolicy CD26C70C-F69D-419C-AE25-50E844D1DAE8,RtkMAPT CD28DACA-BDBE-481A-90AC-625C79CF234C,H19BIOSLock +CD2AC321-3EA6-4AA1-92B7-DAC13F900883,AmdCpmAudioFeatureDxe CD2B6EB3-EA11-4848-B687-AFE57D3D1C0F,ApplePpiPlatformInfoDB CD31F8A8-28A6-4E49-8B3E-4142BD006C41,MeUlvCheckDxe CD361957-AFBE-425E-A358-5F5889CFFE7B,EfiHiiOldProtocol CD3BAFB6-50FB-4FE8-8E4E-AB74D2C1A600,EnglishDxe CD3D0A05-9E24-437C-A891-1EE053DB7638,EdkiiVariableLockProtocolGuid +CD3F92A7-9AE4-42F9-B2CC-B47A8615B85B,PcieInitPei CD46127F-9245-4521-BB89-A6D85D68FC13,LegacyTableCompatibly CD495FA4-8475-4ECF-9203-493C9CD5405D,EcDxeRestoreSmm CD51358D-6E7E-45CA-B450-57C046BDFDDC,BmpConvert CD539048-F16F-4F86-BD86-6B726BDC34F4,HpAcpiPlatform CD541D77-6699-4B36-A31E-1AA4C5D5B946,AmiStatusCodeCpuBistData CD554A69-EE4D-404F-855A-84A6A39755D7,AmiSriovLibNull +CD707DDE-4872-436F-B6E3-6F929184F959,BoardSpiConfigProtocolDxe CD72881F-45B5-4FEB-98C8-313DA8117462,EfiI2cMasterProtocolGuid CD72B362-8A6F-4699-AF55-03FD8924C506,HpRpsuDefaultsAndWmi CD7C839D-0521-4B26-9476-9FF2CB70649A,OpromUpdateDxeNeonCityEPECB CD84562C-6864-40A3-A081-C8D35E82B920,CspLibDxe +CD8F06A8-C30A-4A83-8C56-45D432A4BDEB,CbsBasePeiSHP +CD8FEC49-F25D-4A24-8FB8-EF9CA58067F0,SbSocRsPei CD92B9B9-2D4C-466B-8458-95447D8E4AFE,LenovoSystemSmBiosSmm CDB65801-494D-472E-A6A8-AFF5B76E8D1F,DellTxtConfigPei CDBD2D34-0E33-46A8-A6E8-38AE30899FA1,EzTpmUpdIfxFwDrv @@ -8288,6 +9313,7 @@ CDC0191E-1891-4119-817E-0B6A3685A511,LenovoSystemBusIsaRtcSmm CDC11AE9-01E7-42CB-88EB-FDFFD8819893,TcgLegacy CDC1C80D-E6D3-4A42-9229-75F3BEFCF109,PciOutOfResourceSetupPage CDC5DDDF-E79D-41EC-A9B0-6565490DB9D3,IgdOpRegionProtocolGuid +CDD36FE6-CF3E-4B06-9241-0C8C45098049,AmdSocAm5RplDxe CDD65692-2E98-45AD-B7EE-CBED4155DCE8,FjSystemDataPei CDDBF370-3DA5-46D9-9D0A-BFC112EC5316,OemSsid CDDD1FEC-7C13-473E-8AE0-7A0723ADC787,DualBiosDxe @@ -8297,21 +9323,26 @@ CDEB315F-C5D9-40F1-2314-60CB26262E4F,UefiSwitchMonitorDxe CDEC3671-816E-43DC-A002-DCD645229338,I2cHostDxe CDF0823D-0D05-40F2-A424-978BCD270156,FlexIoPortConfigDxe CE033449-3D90-9644-862E-2D7D9AA3F06A,BinConvert +CE04E069-89C4-4B9C-89FC-4AA48E98163A,FchSmbusPei CE063996-6C4E-4531-A18E-635EDD447A36,ShmInitPei CE12B236-17E5-47B4-96AE-C85BBAC1E5BF,SmcAssetInfo CE159F09-D896-4058-B5BB-1AE6EAB00E01,OemPowerModeDxe CE19678F-3F08-4E81-A1F3-1886CA13ADA7,SiliconPolicyPeiPostMem CE1C71E3-ECB3-4ED2-9DF4-2B38AB65B0BE,DellDiagManager CE1F0D0A-2E92-4EBA-A171-AD89125CEE87,ValidateExtendedBiosRegionPostMem +CE2217A4-5565-4FD2-9AB2-53E18F9A50FD,SctMtlGopWorkaroundDxe CE248B77-1179-4BC6-B324-9D2EDC4B976E,AhciControllerPei +CE25C500-D518-11E3-A146-047D7B99E097,ProjectServiceDxe CE2B8E5E-CFA9-4F18-9AE1-ACEAB642892C,DellOA30CtrlSmm CE345171-BA0B-11D2-8E4F-00A0C969723B,EfiDiskIoProtocolGuid CE35B5C7-EF21-48FF-A476-3F5FAF3F98AD,PersonalityModuleDxe CE366D33-B057-4C03-8561-CAF17738B66F,WdtAppDxe CE3CAD4C-4743-0482-5909-F385307178C2,NvmeResetHookDxe CE3DA938-6AD6-458A-8831-6B0A03DF6C86,Pentium4Base +CE3FA7C0-E9CA-11E2-9BF4-446D571553EB,LenovoStringDxe CE3FBFA0-C4A2-46F6-AF38-FDD6BF409B0A,SmmSioHwmIo CE4188D8-1D24-44E8-BCA2-2AB8F750AEC0,SetupConfigUpdateDxeHedtCRB +CE4385F8-DA0C-4E8F-9211-A7F954721D2E,FjLvdsInit CE44C4EA-6250-4DFF-9C1D-86D3CD1E64A6,AsusVmdAiControlKeepVmdMode CE4D553D-7FF4-4527-A38C-0411138D7B97,FjUsbTypecPwrLimitCtrlSx CE57B167-B0E4-41E8-A897-5F4FEB781D40,EdkiiSystemFmpCapsuleDriverFvFileGuid @@ -8327,14 +9358,17 @@ CE76670A-55C0-484B-962E-84A2F65210A6,MEMPATCHPEI CE7CD764-A1D9-44E5-9857-14FEFAAE96DD,PnpDxe CE7E8F88-9D27-46C9-B633-21F8B8712071,BaseBoardPei CE845704-1683-4D38-A4F9-7D0B50775793,EfiPlatformBootModeGuid +CE8A2C97-A09D-4DC3-9A1E-F8AB65075AFB,AmdPlatformRasBrhDxe CE92C5B4-14B3-4AE1-A274-3FFE74A5ADC1,KEMoSetup CEA4FF9C-D7BC-4F07-96F1-03F41F2B17AE,BaseFspDebugLibSerialPort CEAB683C-EC56-4A2D-A906-4053FA4E9C16,EfiTemporaryRamDonePpiGuid CEB0203C-DE91-4ECE-A95F-0217E959E191,SystemSecureFlashAuthenticationDxe +CEB409FC-FA01-4831-8BDB-7D06BE8FCC9E,PlatformG3State CEB7FE23-21A1-4B5C-8E92-2E7B52A95076,Legacy8259 CEB904D8-DE67-4286-8D3F-2259E6B781B8,UsbPowerShare CED4EAC6-49F3-4C12-A597-FC8C33447691,PeimBoardInitPreMem CED56284-CDAC-499C-9FED-69A944CE26CD,EcIoPeim +CEDF3529-7319-4530-9348-FB1211CDDFFA,OpenBmcSmbios CEE19373-FB2A-4B8E-BEF5-B6D7731F4939,I2cBus CEE33516-58E3-47DB-BB3F-2758B5A76C28,FirmwareVersionInfoDxe CEE8BEEA-507A-49F4-A3D7-D1100A2008CC,SynQuacerPciCpuIo2Dxe @@ -8342,17 +9376,20 @@ CEEC2EE9-BF2D-45D9-B96A-1144B062395D,UsraQuiesceLibNull CEF05965-F399-42A0-A226-A3FE96AA944E,RedfishHi CEF5B9A3-476D-497F-9FDC-E98143E0422C,NVRAM CEF68C66-06AB-4FB3-A3ED-5FFA885B5725,SmbiosBoard +CEFF9D2F-F5E3-4DEF-B051-386FA007AE4D,AsusSmmCommBuffDxe CF009B23-17B9-43EE-BB69-4393CA186B1C,LEMDeviceGuardInit CF10171A-57F0-470A-90E0-62D95F213F9B,HpBeepDeviceDefaults CF10F9FA-45BE-088A-0DCF-37B75CFE917C,SystemSmbiosLoaderDxe CF28CD73-F3DE-4125-8651-61CC4D786FB2,OEMWMIDxe CF2E24FE-ACA6-4D6E-9486-E9A55495D654,PlatformServiceRecord CF2F5574-3C73-4D2F-976D-665CAD2E5381,ASUSDirectKeyDXE +CF316AE5-E183-4528-B351-E65D3481253B,EmbeddedDxe CF31FAC5-C24E-11D2-85F3-00A0C93EC93B,BlockIoVendorGuid CF3279BC-AD5A-4A13-BE80-FB7B6C17730D,StaticSkuDataDxeBigPineKey CF368415-2CFD-4757-803F-6E273D9123EE,AcerLidPei CF3EF6C2-F125-41A0-B3DE-73AF4143812E,FjCryptServiceDxe CF46C339-0651-407A-8E85-D0D72731CCD5,RequestPOPOnReset +CF4915A5-B44F-4B45-A841-6CCDEA0B33D8,ApobStxHPei CF5014F8-2EBE-4D57-AA83-D7A3607371EA,DellFlashRecoveryImage2Pei CF569F50-DE44-4F54-B4D7-F4AE25CDA599,XenIoPciDxe CF67DF48-F242-4D81-A88B-82832C8108CD,AcerHwSupportDxe @@ -8361,9 +9398,11 @@ CF6DC7FE-FBE5-4AFE-8A8E-E7CED473259E,SureStartTestModePlatform CF7A379E-F788-44D4-AF65-165CE1E0ED68,SmcOptimizeDxe CF8034BE-6768-4D8B-B739-7CCE683A9FBE,EfiPciHostBridgeResourceAllocationProtocolGuid CF89079D-DE55-4618-8683-BCFB0D5C90BC,AsusSlp2Encrypt +CF8AC870-80E7-43CA-A2A9-A64CFBBACC94,EfiSmiServices CF93C01F-1A16-4DFC-B8BC-9C4DAF67C104,EfiEventNotificationTypePcieGuid CF9668F7-B0F0-4D7F-B41E-AEC794EEC7FC,LenovoSystemAcpiSmiServicesDxe2 CFAA77CE-7208-43C3-B815-99E8D66A28BA,b57undix64 +CFAAE0D9-0C2D-4EC8-A122-F6EB5F380916,DetectErrorsDxe CFB33810-6E87-4284-B203-A66ABE07F6E8,EfiHeciProtocolGuid CFBCAB7B-050D-494F-A841-51BEEB73406E,USBControllerDxe CFD3C49B-56DC-465C-B3A0-419A8B42CB60,EfiAcpiParameter @@ -8384,6 +9423,7 @@ D03F3A1D-088E-46C8-A9FB-8209770F2CE2,ChipsetPlatformLibServicesDxe D04159DC-E15F-11E3-B261-B8E8562CBAFA,EfiBootManagerPolicyNetworkGuid D041CFC0-7670-435A-A512-F45C923B285D,DellPeiSioEmi D049547C-8227-44D2-8A5E-02888DE930D1,ClearPasswordReq +D05173F7-7683-4C35-843A-39B307142E95,OemFwUpdateGuid D05ACBA9-3E18-4C80-AA97-023A22F8A946,FjAudioSpeaker D0632C90-AFD7-4492-B186-257C63143C61,SmmBase D06D425B-EED7-0361-AAD2-8C431409572D,BootGuardRecoveryHookPei @@ -8396,6 +9436,7 @@ D088A413-0A70-4217-BA55-9A3CB65C41B3,ExitPmAuthProtocolGuid D0893F05-B06D-4161-B947-9BE9B85AC3A1,SnpNt32Dxe D0927E0C-FEA5-4569-8AC0-33C8F60E5073,NvmeRstPassword D096FB72-A964-4FE6-9FBF-FA83CCD91549,FchSmbusDxe +D0A611D5-529D-45FF-8714-374E833337D8,Npce285xFlashDxe D0BA757A-6B67-4BA3-B138-7A15DD8CB94F,FjGabiSystemDataHandlerSmm D0CAA91E-2DE4-4B0D-B3DC-09C67E854E34,BiosSnp16 D0CAF5CA-3DF0-3D4F-89C5-66105356D61B,AppleBds @@ -8429,12 +9470,14 @@ D1A3216F-63E5-4F31-8D30-FF53F7CABF5C,MpCpuDxe D1A86E3F-0707-4C35-83CD-DC2C29C891A3,EdkiiNvVarStoreFormatted D1AF503B-68B9-4FC9-AE87-DFB72F21B3F1,DellFmpMe D1B61D55-88E1-4C14-8904-9E7CEA40AD6F,Cf9Reset +D1B7872C-E60D-4D86-932A-E9F8D46D344A,AMIProjectDXE D1C17AA1-CAC5-400F-BE17-E2A2AE06677C,EfiKmsFormatMd4128Guid D1C4AAF9-AAB1-4AEE-ACAC-D68AEF05F0D5,UsraLibNull D1D63B06-137F-4F5A-8C25-28DADFA1E988,FjPasswordSkipDmi D1E59F50-E8C3-4545-BF61-11F002233C97,TxtPeiAp D1EE4CC5-7310-45AE-854E-4450E10EA20A,OemDisaplayTIO D1FC3703-6591-4AE9-A795-C5628CCF5236,DellSmmNbProtocol +D201B7F4-515F-46A8-951D-9F2BE251C113,CPUDefault-PEI D20C96A8-B9CF-4C15-9FBB-1C055517F449,CxlCedt D20D8922-A2F8-4F80-FFFF-FFFFDC893C8D,XnotePlatformResetSmm D21D96B4-20C6-4F30-8E82-6701485B1049,DellLomPolicy @@ -8443,6 +9486,7 @@ D22C15F5-818B-4940-90EB-ABB377255644,SmbiosPlatformInfo D22E0A82-C256-472B-9820-F7BA7127FBE7,OtaDxeDriver D231DB5B-4A9C-4092-A8C5-9CA0BC7D6AA6,IffsInfoProtocol D233D6BD-F1B1-425A-BF45-5CAF2B88EDDC,WinNtOemHookStatusCodeHandlerPei +D238B630-280F-11E4-9A1E-047D7B99E097,EventInterfaceCoreDxe D2465DFB-9AC7-4954-8C48-CC439ADA7C3C,FjIbvWakeStatusAbstractionPei D256C663-1E0F-4704-A76A-94CEED7C16DE,FjDtPlatformSmbiosDxe D258D6AF-2FC0-4019-9C1F-1101C3DD19B5,DxeCoreEntryPoint @@ -8452,6 +9496,7 @@ D26697EE-9983-48B0-8F85-7D3E66528B07,LegacyBiosDxe D26C221E-2430-4C8A-9170-3FCB4500413F,TcgEvent2EntryHobGuid D27FED59-ABB4-4FED-BEAD-2A878C7E4A7E,SmbiosMeasurementDxe D2846ADB-B41B-4103-871F-E2235F4778C7,SmcPostMsgHotKey_PEI +D290465F-16B5-4579-A70B-CA1DF4FCE8DF,SDGlobalNVS D299F352-094F-4B87-8CD2-C94F9E0A44C3,DellRecoveryPei D29B104A-BE98-464A-9771-746B9A07DCA1,FjSysmanWatchdogBin D2A92001-22AD-43B9-BEBC-1B152100D8CC,EfiPeiPlatformTypeWolfPassPpi @@ -8462,6 +9507,7 @@ D2B6C80A-FAFE-4512-835D-50D136540AAA,MultiConfigUpdateDxe D2BC3092-92BB-4B21-A26B-CE6F7C3E9857,AtAmUi D2C18636-40E5-4EB5-A31B-36695FD42C87,EfiShellEnvironment2ExtGuid D2C2B842-46B0-4466-88B8-5A8285E9CEC2,IScsiFontSupport +D2C2C0A3-1623-4BF2-9ADA-BCF81493FF7C,AX88179UsbNetDriver D2C69B26-82E1-4A1B-AD35-ED0261B9F347,MemoryInitPei D2CB970C-8622-46E1-9083-DB2EA20CA6E3,SystemSecureFlashBootModePei D2DC7458-E6C1-4C8E-A32B-545269DC6361,OemPeiSetAcLossAuto @@ -8471,6 +9517,7 @@ D2FF92C7-55DB-4879-9D0B-A08BCE4F4E19,StaticSkuDataDxeBlizzard D303BB6F-7434-41FD-BC8E-0984A03C9B7D,AmdCpmAcpPowerGatingDxe D30E0E10-519B-4E39-AD47-DC3CE266A8AE,FjGabiNvramMergeDxe D317F29B-A325-4712-9BF1-C61954DC198C,EfiSmartCardEdgeProtocolGuid +D31D5D8B-61F3-4FC5-9CBB-7AEB6D987932,TouchDriver D31EAA20-8436-4E34-9A06-C47C78E19F18,SIOBasicIODxe D31F0400-7D16-4316-BF88-6065883B402B,EfiPchInfoProtocolGuid D3231048-B7D7-46FC-80F8-2F7B229586C5,UTDMUIApp @@ -8484,12 +9531,15 @@ D33AC55B-82A6-448D-8D14-DFE0814D0792,DellSetupRollbackDxeDriver D34BDC5E-968A-40F5-A48C-E594F45AE211,VariableAuthSmm D34D3234-38BA-428B-9ACD-84E830A80785,AmiModulePkgTokenSpaceGuid D34E68E9-B9BF-4924-8A06-0EA2672204DD,PciHostBridge +D358D713-7E11-43F1-9456-F5FF2EBE19A8,SbSocBrhDxe D359DE86-0A1B-47BC-95D2-1D1F8FFF0AD8,ChipsetSvcSmm D35EDA81-07D0-4142-9409-B07233ED2D07,CseSpiSelectPpiGuid D362743E-CD68-4500-AA93-C596383AE31B,FjPasswordCtrlPei -D36DDD2D-1C66-4210-B77A-2FD9F920E51F,ASUS_EUPSxSMI +D3667456-63A0-4713-B7DB-4162C196A37E,DxePostEnd +D36DDD2D-1C66-4210-B77A-2FD9F920E51F,AsusEupSmi D3705011-BC19-4AF7-BE16-F68030378C15,EfiIntelFrameworkModulePkgTokenSpaceGuid D3709BB4-B194-4B71-B9C0-DBD8D2DA97AD,IntelIchLegacyInterruptDxe +D3721461-FC24-443E-B486-724C9B5A2F70,MemTestDxe D3790CB3-A890-4A5A-A42E-ECB6B140D814,UHESerial D38D1F35-890B-43CA-BF9B-96337B86B06B,TypeADh D38FC876-0B17-4D95-A7F8-A022ECA1CA42,MeExtMeasurement @@ -8512,17 +9562,22 @@ D3C92EF3-39AA-4ECE-A1E6-DFD7A2D497D4,ODMShareMemProtocol D3DD0586-976D-449F-9837-0392E93B7D52,DellOsProtocolAccess D3E6E0F0-7206-40C5-B58A-05FCAD08DBC8,OemDxe D3E8A227-E905-407E-8F8F-FED32FB2F93B,DellUsbSmmCore +D3EB600F-06EF-4837-A2A8-7C4C90BE8DA5,BctBaseSmmSTXH D3ECC567-9FD5-44C1-86CF-5DA7A24F4B5D,EfiLpcWpc83627PolicyProtocolGuid D3F67D2D-67CA-4FB6-9654-77E82901469C,VirtualDev D400D1E4-A314-442B-89ED-A92E4C8197CB,EfiQuarkCapsuleGuid +D4013B06-AB7D-4B9C-89D5-6EF61F507ECA,AsrockAmdSetupDxeRN D40B6B80-97D5-4282-BB1D-223A16918058,EfiNvdimmLabelProtocolGuid D423E494-2DB6-4D2E-AE23-0A3D8D9D6E22,FjEPrivacyFilterSmm D42AE6BD-1352-4BFB-909A-CA72A6EAE889,LzmaF86CustomDecompressGuid +D42DB8C5-1E95-4A2F-9742-479C1BA42192,OemDataRegionFlashDxe D42F8F9A-9B96-4F47-B045-A8F3CD1FD9D3,SecureVariable D432A67F-14DC-484B-B3BB-3F0291849327,EfiDiskInfoProtocolGuid +D432C4A5-D473-4067-9CF7-02CE92A3CBFD,FchProm21Dxe D434ED39-8EDD-4FF8-91BF-4B11AFE85471,SwapAddressRangeDxe D4395796-6F4C-4C6B-B9D1-92DAA7199A84,AmiRedFishApi D43E3F66-1B5D-4623-975F-7F5EBEEEF02D,MtkWifiDriver +D446DA7F-F299-4911-8C91-91CCF5F8A752,SDBadgingSupport D450A69D-D8E4-C048-8E7E-0024EB541C79,NetworkInterfacePolicyDriver D458A654-F64C-49DB-B8D1-3821306BF1F6,BaseMemoryLibMmx D45DAC0C-4FE8-4304-FFFF-FFFF1745BE1A,XnotePopNoiseSmm @@ -8539,6 +9594,7 @@ D49D2EB0-44D5-4621-9FD6-1A92C9109B99,HiiResourcesSample D4A28A3E-DCF2-43CF-A2B7-F3572A7CAB09,EfiIobaseHob D4A5B2FD-AD44-404A-98A8-297857E72A53,SmcOobDataReadyProtocol D4A79A0D-B67D-4E83-8EFB-455924372934,DellTerminalPlatformPolicy +D4A86A1B-F939-4D4D-BF7F-CE404572B282,BootOrderAdjustDxe D4A88838-EBF4-48D7-9D97-CE6789FDE0B7,CryptoPkgTest D4B47610-BC1C-480B-BD23-CB031B7AA0A2,BiosPowerOn D4B61940-73AB-48A5-9E26-53A4CA4A2C37,DellDiagsSmm @@ -8569,9 +9625,12 @@ D52BB262-F022-49EC-86D2-7A293A7A054B,PchAcpiSmiDispatchProtocol D52D8AD2-EA9A-470C-9E33-828FA591AB8D,AmiPeiHashInterfaceProtocolGuid D530CEA0-DD63-11DE-8A39-0800200C9A66,MemSpd D5367802-B873-4C0F-B544-31B7CCF5C555,CmosManagerHob +D53E4F4C-125B-4441-A3CB-72EE159533AE,AmtPetAlertDxe +D53E9F23-CF7F-4270-ADC4-05E2920471EF,AmdSmmControl D54A91F0-4547-4380-8890-17C19937F853,DellSecureBootSmm D54D3DBE-CE19-489F-8EDE-9FE2F7238650,RestDxe D55319D5-6EDC-43E2-985B-F656E5B5153C,AmdFabricPhxDxe +D558DCB7-7A3E-4A38-8C46-F6CF21DFC1E6,BtPreBootDxe D5649ACA-DA40-4C58-A4DF-8E42EB40A180,SaPolicyProtocolGuid D56A4094-570F-4D3D-8F5F-8D8AA0B396CB,EhciPei D56B6D73-1A7B-4015-9BB4-7B071729ED24,EdkiiSmmPerformanceMeasurementProtocol @@ -8579,19 +9638,25 @@ D5710339-A467-4F76-B053-4F14C2F5C999,FjDtPlatformDiagnosticsDxe D579766D-54C0-4A51-AA39-411E59981DF2,UsbOcUpdateDxeBlizzard D57BC5C5-F058-4AA8-8585-B7645E1A7D25,DpfServicesSmm D57C852E-809F-45CF-A377-D77BC0CB78EE,HddSmart +D57E86D8-A921-4083-B3DD-5AFFA92B4FE5,Pca9536Pei D58EBCE1-AF26-488D-BE66-C164417F8C13,PciHostBridge D5919FF6-D708-4918-87A0-1BB21B157C08,CaseOpenDxe D5950985-8BE3-4B1C-B63F-95D15AB3B65F,SmmCpuSyncProtocol +D598FC5D-AC01-4D9A-95B5-A1D2422504A5,TouchDriver D5A531AB-300B-4AA1-9B8A-9C6C8F0110F4,CrServiceSmm D5B01A04-24D8-44B9-A390-888D669A1CBF,HpAmdXhciSmm D5B06D16-2EA1-4DEF-98D0-A05D40728417,EfiWatchdogTimerDriverProtocolGuid D5B366C7-DB85-455F-B50B-900A694E4C8C,SlingShot +D5C39D65-28B2-400A-9FBE-77E28BDD3CD5,AmdDebugDataPreserve D5D52FED-F8A6-49AC-97AC-7291A60405A6,FsIso9660 +D5D946C7-92AB-41FB-A390-6C6239B4E413,BoardInitAdvancedPreMem D5E4EE5F-3E0A-453C-A725-B692BB06365A,EfiExtendedSalElogServicesProtocol D5E606EB-83DF-4E90-81E8-C3DB2F77179A,rmHwA15x2A7x3Guid +D5FC5B41-F893-48A5-96EF-375C1874D45F,WlanSuplct D602D4E9-1F13-4E0F-8B6C-2B2FD32977D6,LEMSetFlashProtectedRange D6047569-C508-498F-AEC1-72E77DADE7AC,AepLogWmiSmm D6062B50-15CA-11DA-9219-001083FFCA4D,EfiAuthenticationChapRadiusGuid +D608A2C1-4331-4685-9749-F6819BAF4C04,StaticSkuDataDxeSierra D6099B94-CD97-4CC5-8714-7F6312701A8A,VirtioGpuDxe D60CF145-F97C-4085-A73D-8D399757DFE9,AmiCpmWrapperDxe D60CF145-F97C-4085-A73D-8D399757DFEA,AmiCpmWrapperDxe @@ -8603,7 +9668,9 @@ D6207835-B7E3-4FF8-B276-CDE3E52206BC,SmbiosDataUpdateDxeLightningRidgeEXECB1 D6294C9B-0866-4753-AAAD-7699AFC4BEE4,DefaultFixedBootOrder D62C96E9-D7D7-4D28-B0F9-BF2CA151DDEF,IePolicyInitPei D62E660E-6561-45DB-A838-8609BBA5FF37,Cf9Reset +D62E673F-A935-4751-9279-4C1E63ED0A4E,FchI3cDxe D635213B-5334-46B3-AE37-8D436DD3D523,OemNvme +D639D97F-5FCB-42CB-87C2-880A86F67CF2,CbsBasePeiBRH D6405DAC-92D7-4BB2-A9C9-CB7C749023F5,BIOSLD D641A0F5-CB7C-4846-A380-1D01B4D9E3B9,EfiPeiCorePrivate D6476950-2481-4CBB-8400-442542C766C8,ProcessorErrorHandler @@ -8624,10 +9691,12 @@ D6AC4AC2-8BC2-4CDD-8776-280E1469DE02,PchPolicyInitDxe D6B51356-0C90-4EE6-B3A7-48AA74D4A77A,SkipRegionAccessDxe D6B6547A-750E-4A3D-B61B-8703D8FA3287,DellAuxMac D6B6DA34-917B-4511-B147-407653BF391A,FjEvtControlDxe +D6C1D55A-DB24-45CE-AE52-1E5087BE222E,AmdResetHook D6C42CE2-391C-4345-8BFE-195632AC4558,CertificateStorageEvent D6C589EA-DD29-49EF-97F6-1A9FE19A04E0,PwdCredentialProvider D6C92E00-1FAB-4775-8310-3AC1D774C3CD,GenesysInit D6C97E78-FCD7-47F5-B575-6E1940246C7C,DellCountryCodeDxeSync +D6CC7A4D-440F-4FFC-879E-176CB5558118,FchSmmDispatcher D6D27C49-66CA-42C7-BC51-788328B5E5D0,SwSmi534D0240 D6D2FBA6-EF60-4C38-A83E-6769814D23B0,CryptoPei D6D47F07-1445-416C-BC8C-89C34D7CB210,HpFirstBootOptimizerDxe @@ -8636,6 +9705,7 @@ D6DF0817-248A-41F1-A1D3-59E537187D10,DellTcg2Smm D6E322B7-77ED-4394-86FD-FCED3C052780,LEMRomLayoutSmm D6E5092D-C7B2-4872-AF66-FDC0E6F95E78,EfiSystemNvDataHob D6EB696B-7EC3-4D1B-AA28-6775744C9EB5,TSEScreenMgmtProtocolGuid +D6F37045-3DA2-4AA0-9777-1DF7D9FC61C9,iMRRaid D6F43B1B-0F21-462B-B8B7-A033C3EB4261,BaseMemoryLibOptPei D6F76587-98CA-43DE-9E1A-59E60D0ABE73,AplFakeCapsulePei D700E3BC-4291-4749-87AF-432A023DE658,DellNbConfigDxe @@ -8671,6 +9741,7 @@ D7D7CA47-663B-488D-AEE3-6A35DCB89E2A,SbGlobalSmiControl D7DCC862-A2A0-4CDA-B18E-4477D2FE49E3,RadioExecSmm D7E31ECB-0A17-4529-9B84-C529DE8E1C0E,AcpiFvi D7E3630F-55CA-43DF-8035-F4FB0774D0D9,TmFifoDxe +D7E3D34E-1FF0-4E7A-8877-1FAAF9EB9654,CbsBaseDxeBRH D7E5ABE9-33AB-418E-9F91-72DAE2BA8E2F,ArmScmiBaseProtocol D7E69789-1F68-45E8-96EF-3B6407A5B2DC,EfiKmsFormatAescbc256Guid D7E6ABC1-971B-461B-B5E4-3C3766267AD9,SbInterfaceDxe @@ -8681,6 +9752,7 @@ D8117CFE-94A6-11D4-9A3A-0090273FC14D,EfiDecompressProtocolGuid D8117CFF-94A6-11D4-9A3A-0090273FC14D,EfiPeiPeCoffLoaderGuid D8117D02-94A6-11D4-9A3A-0090273FC14D,EfiPeiTransferControl D815413A-D96D-40A6-9F9F-88E09E36FA49,PsdsAcpiDxe +D81AF109-4741-4EDD-B4C4-58CFF321D7AD,FjBiosPostGpioPei D81D1706-BE6F-4734-B2AF-F885FFDCB16D,AsixUsbEthernetDxe D824AD37-7AB9-4817-BD53-DBAB779A3C83,DellAdvSysMgmtConfigSmm D82A73A8-7CB5-4BC1-8FA5-60F0EE2470A7,BiosUpdatePlatformPolicySmm @@ -8703,8 +9775,10 @@ D8A6F4A6-0E97-4A8B-A475-39F1B28B5AEC,Fv2OnFvThunk D8AAB432-93CC-48D2-9F34-3496CAF92185,SmartFanCtrlDXE D8AB1072-4B45-4828-837D-A4214377802E,BCLANDXE D8B6B249-77F8-4809-ACE2-5975DA16AAF5,TouchPadDriver +D8CAC470-CB7B-11E3-856B-047D7B99E097,BootOptionInterfaceCoreDxe D8D282C4-4478-4D75-B10B-B08F5E59B5E8,BasicDiagnostics D8E32E50-1DD2-4F8A-93A5-2569C03D0FC1,FchSmbusPei +D8E4C555-0BB6-4C6D-94CD-36072D59DCD2,PrmConfigDxe D8F15168-57A0-46D5-9071-2F3C23CB236D,RpmcPei D8F8C7F6-52BB-4CB3-BA5B-0683628A2CEC,DellDesktopPowerLEDSmm D8FA1C9B-049E-4292-A517-450A8D2242EF,FjGabiFlashCommonFdRegionCtrlDxe @@ -8723,6 +9797,7 @@ D93D907E-EE7D-4577-833C-5AD3ADBBB8C4,DeepS3ConfigDxe D93DE2E3-3727-4D5B-B49F-777C93A971D3,OpromUpdateDxeLightningRidgeEXECB3 D94082B7-04E0-4586-8072-8FC562ABBBFA,IncompatiblePciDeviceSupport D94816D9-D2EC-4BC9-963D-09D263F715C1,HousingMonitoringPei +D952A0C4-4D96-6853-DECD-058DC9DC5FCF,AmdSocAm4MtsPei D9569195-ED94-47D2-9523-38BF2D201371,IntelPciDeviceSecurityDxe D959E387-7B91-452C-90E0-A1DBAC90DDB8,ArmPlatformPrePiUniCore D95D6B4F-92FA-4E78-9C48-C68C0813688E,OemLinkDellPwdLib @@ -8740,14 +9815,17 @@ D993E866-5C8F-4DE7-BE99-453E284A43AF,WakeOnLanDxe D995C16A-DF06-4B26-9C5B-246FC7464649,SystemAcpiSlp2Dxe D995E954-BBC1-430F-AD91-B44DCB3C6F35,EfiPcieErrorSectionGuid D99B0C82-9BB0-4B8D-9545-A2670375A931,AfuCapsuleOnDiskSmm +D99D0269-592D-4618-A36C-FA8007331CBC,DeviceInfoLookupDxe D99FC054-CC38-4582-B0A6-F533678BAFA9,DellPeiPchGpioControl D9A688C2-F1EC-4884-8262-2C6381AF254B,CsmSmiDispatcher +D9AE5A34-2096-4DED-BF11-4738B0A39FA8,DellAmdCbsApcbUpdateSmmShp D9B07611-4ED7-38BF-B304-42116E7C966A,OSRecovery D9BEE56E-75DC-49D9-B4D7-B534210F637A,EfiCertDbGuid D9CD0AA0-C20F-4810-999E-D991FD0484D9,DellSmBiosStrucD9 D9D114EF-F40B-4D48-AAA0-A3DC99C9F5BD,DebugAgentPei D9D6BA2A-8225-469B-B36E-3B34EBE805CF,StatusCodeHandlerRuntimeDxeUsb D9DCC5DF-4007-435E-9098-8970935504B2,PlatformDxe +D9DDCFF2-215A-480A-AA63-1DF1F5EDBC01,HddSecurityPei D9E4F040-B4D0-4C26-8400-B1D91B756B77,IteOnlyPei D9E9FA06-0FE0-41C3-96FB-83425A3394F8,EfiExtendedSalBaseServicesProtocolGuid D9EA74E6-0B4D-4916-9821-EB58B86211D8,SbPcdDxe @@ -8761,14 +9839,17 @@ DA1B0D11-D1A7-46C4-9DC9-F3714875C6EB,VarCheckPolicyLibMmiHandler DA1C487A-C375-4D18-BD71-E0FA9F893998,EpsaReconnectUsbDriver DA2122B3-454C-4321-8F43-8A610AFFEB80,PspResumeServicesSmm DA36718F-E022-4FD8-BAD8-EF27F9E4928F,HeciInitSmm +DA389016-4D1E-4814-A13B-364F13D8DE3E,ClientronProgramGpioPei DA3B0E29-2DA7-48A7-AE98-B21093DBBC2B,RecoveryImageReadWrite DA3EC7A1-F6D3-4129-98B0-9494F8585006,DellLegUsbBusProtocol +DA3F7A4B-52F2-4086-B0B8-FEE95DF7A733,SmbusDxe DA3F8F9E-8D46-4B66-A009-42C8BCAD8530,FjVgaDxe DA451AF6-88D1-4FD7-B86E-44BC47EE1F7E,DellStorageAgentsSmm DA465B87-A26F-4C12-B78A-0361428FA026,AssetQrCode DA473D7F-4B31-4D63-92B7-3D905EF84B84,AmiSmmBufferValidationProtocol DA490532-DA5F-43C9-A0CE-6A2E05919350,AfuCapsuleOnDiskDxe DA4B2D79-FEE1-42C6-9B56-923633398AEB,BiosCapsule +DA5524A0-6030-4A66-A9E4-D26629871921,FjAlderLakeSmm DA56B22F-8379-4F2F-B328-221C0182C6F5,NearTdpLockOc DA571595-4D99-487C-827C-2622677D3307,EfiStatusCodeDataTypeAssert DA5D9983-033C-4823-9349-8B1B6A798030,LenovoSystemStatusCodeGenericSmm @@ -8786,6 +9867,7 @@ DA97681C-A9E3-4209-A9D5-F9E98152F39A,ClearChassisIntrusion DA9F192F-BAE4-4F20-8C6C-55C1ACDE80B0,menu_checked DAA55048-BC3F-4DD9-999B-F58ABF2BBFCC,DxePlatform DAAF0056-87B5-4584-854C-CF207B364CEA,SwSmi534D0840 +DABA25A6-DF31-4151-81EF-627701EE4F26,EarlyDevices DABAFA6C-F394-4DAB-835F-8012FD730766,LEMSetVariableCtl DABF7A7B-B5FE-4A18-845D-F241D8582794,UndiFirmwareVersionDxe DAC2B117-B5FB-4964-A312-0DCC77061B9B,Font @@ -8842,6 +9924,7 @@ DBE37563-AFEF-4B41-BDCE-B01B6D1E8690,Tpm12DeviceLibInfineonI2c DBEA47AE-E64B-4DD9-9586-151AEC8D5C18,HpPlatformSmmServices DBFAB6C3-6C4B-4E4F-A8FE-AD1C27D5E8BA,OFCSmmDriver DBFF9D55-89B7-46DA-BDDF-677D3DC0241D,EfiAcpiSupportProtocolGuid +DC08D13D-EC1A-4458-B37A-C50118D7AC48,SetupAutomationSmm DC092DB6-6F93-4C85-9615-7C8B23D48DB9,HpNetworkConfigDriver DC14E697-775A-4C3B-A11A-EDC38E1BE3E6,AmiCsmOpromPolicyProtocolGuid DC2AA475-F636-48BB-6D74-7F2D926C1111,LEMElockerSet @@ -8855,6 +9938,7 @@ DC3EA0B0-A144-4797-B55B-53FA242B6E1D,EfiWheaProcessorSpecificErrorSection DC3EA0B0-A144-4797-B95B-53FA242B6E1D,EfiProcessorSpecificErrorSectionGuid DC54B283-1A77-4CD6-83BB-FDDA469A2EC6,EdkiiPeiUfsHostControllerPpiGuid DC571B6D-D570-4862-A95F-299B28FDC2D2,DellAdvSysMgmtConfigDxe +DC58C51B-EC67-4DB7-B8A7-881858F55913,IntelLanUefiDriverI225 DC5FAA6B-BA33-49CD-8146-AF7D6DA39687,AcpiOemNVSInitDxe DC66C1E2-C114-4D0C-ACC0-003F15B3F729,BctBaseSmmRN DC68E307-6C8C-4997-B32F-3F73C381B769,DellSmmTagsProtocol @@ -8885,19 +9969,25 @@ DCDADB6D-880B-4CB9-9CC0-506C3E182CB2,BackupBiosInfo DCDD4692-88D3-4CE6-8CEF-15E0E4DA1494,Npce388nFlashDxe DCDED170-9AAD-4E64-BDD1-F55FA86E75B1,ApobPhxDxe DCDF614D-930E-4FDF-AFCD-F4A8A408E077,EarlyVideoDxe +DCE1B094-7DC6-45D0-9FDD-D7FC3CC3E4EF,QemuRamfbDxe DCE5298C-1D89-4125-944A-CD04D3CA0AAA,FjSysmanTeutatesBin DCE7D3FA-CC44-407E-AE58-90895B328915,OdmSmmGNVS DCFA911D-26EB-469F-A220-38B7DC461220,EfiMemoryAttributesTableGuid +DCFC22C0-A513-11E3-B576-446D571553EB,HotkeyInterfaceCoreDxe DCFD4C57-AAFD-4D92-B570-04B1212ED15E,AmdCpmOemInitDxe DD071A16-CF16-4AD3-A01E-5B15680CDFF0,KEMhUuid DD1BB969-BE0D-4B70-9E13-2ED2E1854240,LenovoWufuEsrtDxe +DD1C807E-BDB9-49A4-AD50-E510DC948476,FujNotInSmm DD223EF8-6D1B-490A-A53E-BA86FAAEB778,MmcMediaDevice +DD25B790-AE79-43C2-8644-96DAB90C3636,SystemOskTriggerDxe DD2E8F57-893F-4335-8DEA-4B5C343AE398,FjDeviceInfoIntelLan DD32356C-434B-418E-B3F7-E7227825F78E,UsbHubEnable DD455A69-EC75-456C-84D2-95CAE7D3C6D3,EslTcp6ServiceGuid DD4A4648-2DE7-4665-964D-21D9EF5FB446,EfiCcFinalEventsTable +DD4DBCE0-59C2-4A4D-AB0D-358976023385,MTKWiFiGen2Dxe DD4EA471-D8D2-4CE7-86B3-14AFECE76141,KEMrWdtSmi DD51AB78-E55D-4413-AFAE-E592F6B5321B,AmiEventLogsDynamic +DD5B9DAE-16BB-4E28-B10C-08A3AD7E44CE,AsusWakeOnRtcS5 DD5E92D1-DDAC-48CB-907A-882D8610E89E,SavePegConfig DD6C613A-5A77-4B4F-A61E-3BDD2AE21D81,PerfTuneProtocol DD73A3E6-9FDB-480E-81A6-A2D85D220B8C,DellXmlParser @@ -8905,19 +9995,24 @@ DD752080-DF6C-4533-AD66-6213EE681F84,ThermalDxe DD787473-07CE-4C63-82CE-930B33F39C09,SmmControl DD84017E-7F52-48F9-B16E-50ED9E0DBE27,EfiSocketIioVariable DD87502B-CBDE-48A4-A896-F521E0745CC0,AppAdapterTdx3v0 +DD915390-3B7F-428B-8DD4-C4C2FA897C63,AmdPlatformRasRsSmm +DD980BB7-9FDA-4A15-BBD2-734E4678B2B1,AmdSocAm5RplPei DD9E7534-7762-4698-8C14-F58517A625AA,EfiSimpleTextInputExProtocolGuid DDA33BE6-4A6B-41F2-8067-ED4FE50BEA2B,FjDfciDxe DDABFEAC-EF63-452C-8F39-ED7FAED8265E,PpmPlatformPolicyProtocolGuid DDADFC93-FBC5-4389-B20F-EC99E4A6AE52,SmmLibNull +DDB321DD-2D18-407D-8CC4-7F997BEB7D66,RecoveryPatch DDB412A6-E3F3-4E9E-90A3-2A991270219C,iFfsDxePolicyInit DDC3080A-2740-4EC2-9AA5-A0ADEFD6FF9C,EfiIioSystemProtocol DDCBCFBA-8EEB-488A-96D6-097831A6E50B,HashLibBaseCryptoRouterPei DDCF3616-3275-4164-98B6-FE85707FFE7D,EfiVariableInfoGuid +DDD75BF6-4CF9-4A2C-978F-A5AE656B61E5,CaseOpenPei DDE1BC72-D45E-4209-AB85-14462D2F5074,RomImageAddress DDE31574-3589-4FA9-BC69-1729AF6FDA4E,AmiNvramUpdateProtocolGuid DDED691E-0495-45DB-ADFF-D68452C9A5A4,Float DDEF12C9-944D-4757-A3EC-CCFBADA96DD2,DellFlashBios DDFB5557-3E2E-4569-B459-BEFFE189B8B0,AmiSmbiosFlashDataProtocolGuid +DE072137-A9FC-408C-8B4D-6FD2D798BBCB,FjUsbSecurityVG2 DE0EE9A4-3C7A-44F2-B78B-E3CCD69C3AF7,EfiExtendedSalBootServiceProtocolGuid DE115752-A79D-4F33-8459-A9524A64FC52,SioFanMapSmm DE13C06E-F532-49DA-A319-5F7DD0F603C2,GopFirmwareVersionDxe @@ -8949,6 +10044,7 @@ DE820DA5-69CC-4E50-B6C3-F07B27B10BC2,CNVISetupDxe DE83EECD-2E0F-47D3-B634-556615B101DF,OemUsbConfigDxe DE882DD5-B797-4E2C-A8BE-C6367BCB4A23,EpscHwDeviceId DE8A5A2C-D788-47FB-A0B5-20CA8E58DFEC,DellSystemIdConfigPei +DE8D943C-187E-42C3-98D1-1F7584DF6ABD,LfcGr2BoardType DE8F2878-36D5-498E-BA59-168C2647B335,PeiIffsTransitionStartPpi DE98E4D5-109B-48FC-B88D-980E97D8B93A,ArmaniPei DE9ABB5C-2F92-4352-9C56-F51BC9D5E55A,DxeFramework @@ -8964,16 +10060,20 @@ DED60489-979C-4B5A-8EE4-4068B0CC38DC,OpalPasswordPei DED7956D-7E20-4F20-91A1-190439B04D5B,SmbiosGetFlashData DEE3F62A-3B0F-448B-81F9-4AFD546515B9,SiliconNvsDataPei DEEA4A6A-9308-465B-AD99-B5BDA5B55575,CompalThermalUtilitySmi +DEEB4CD1-0F01-4F61-9F39-0DEC61E909FE,RunTimeWDTDXE DEEEA15E-4A77-4513-BA75-71D26FEF78A1,SmmIoLibSmmCpuIo2 DEF30E37-7AEC-4F69-91A2-CF099E2729F2,PciTableInit DEFBFC7A-CC02-4225-88AD-3C41E621785B,DellIdeDxe +DEFD645B-720F-4ED3-9B4A-A3688BF5A300,AmdMemMcsrUserPreferenceDxe DF13AA16-B7B9-42A0-A399-00EE6C81A85A,DxeBoardInit DF1BCAA1-9152-4357-A6B6-E5FBCFBB6B81,FchSmbusPei DF1CCEF6-F301-4A63-9661-FC6030DCC880,SecMain +DF2AFA8D-CFD0-4F71-830E-6A0EB22A9586,AdlinkDriverPei DF2B6949-B0AF-42B3-A70A-935D4875E480,OemRomIdVar DF2D868E-32FC-4CF0-8E6B-FFD95D1343D0,EfiPrintProtocolGuid DF2EC7DE-6F79-40F1-B704-7F8204E3D145,PlatformFlashDxe DF4F6190-42B8-4CA9-BA51-7A801B565F08,b57undix64 +DF500D60-FAD2-0884-F5D6-52D8B082868F,WtSetCoreNumAndSmtDxe DF59F831-6689-45B5-A4D9-3E660D56573E,LenovoBootOptionProtocol DF5CD25A-8E55-46BA-8CDA-BC7DB7BF9C64,MdesStatusCodeDxe DF636282-5EED-11DF-A9D6-B334FBA24BB0,IntelHdAudioDxe @@ -8989,13 +10089,16 @@ DF874E87-FFC5-4C5D-8B1E-81EE01A6D435,SetupLoadDefaultPei DF8DE36D-D241-4947-87F1-36F9EDE545D8,ASUSFS DF934DA3-CD31-49FE-AF50-B3C87C79325F,PlatformDebugLibIoPort DF939333-42FC-4B2A-A59E-BBAE8281FEEF,EdkiiBootManagerMenuFile +DF93FD41-44AE-4952-8971-41D472EAFC78,PspGetIntrusionLog DF960F12-05CE-4E18-B926-00AFC9F31C7E,PeiSioEmi DF9A9591-B646-4621-AF0D-18143A73289F,AppleLegacyBootFS DF9A9FFC-A075-4867-A0B2-5E7540BB023E,AcpiSmm DF9C0686-2B2E-49D9-94F4-A41C47AB9633,Hob +DF9DC2AA-6634-4F84-B677-532BCC6AA9AB,AmdFtpmTcg2Smm DFA66065-B419-11D3-9A2D-0090273FC14D,EfiVT100Guid DFB36C78-E534-4E05-9D5D-1803F36E88F2,ReportFvRecoveryPei DFB386F7-E100-43AD-9C9A-ED90D08A5E12,EfiIpSecProtocolGuid +DFB9BF4C-3520-4A80-904E-71D5F42E866A,XmlCliCommonDxe DFC54544-2516-47A5-B288-29F100AEFD01,HpCheckpointFlowControlCsbPrivate DFD4B243-0430-429D-829A-CA2BAB3FE7A6,AuthenticatedBiosInterfaceSmm DFD8D5CC-5AED-4820-A2B6-5C55E4E640EF,AcpiPlatformSmi @@ -9007,12 +10110,15 @@ DFEC7540-B6ED-425C-883F-9D8F3C85384B,MemRas DFF4BF9D-D027-4F7E-9385-C1ADB0CEF753,FjSmmAzaliaVerbTable DFF4E6C8-234C-453E-A92D-FA505E90D539,DellDaOwnerTag DFF5AB67-23C6-406F-99D4-F51B22044113,SmmWifiToolDriver +DFF622F8-8BA6-4715-B58B-C840C1D6FAF4,MsSysGrdTpmNvDef DFFC7495-75AD-4354-AB0A-BDFD9046067C,AbtErasePei E000A056-8E65-4730-A6BA-6ED08B8D289C,FjSystemResetPei +E000FC69-653B-43F5-93BC-4387957F330D,NVMEPowerSettingControl E008B434-0E73-440C-8612-A143F6A07BCB,Recovery E010BCCA-3A3B-4B03-BCF4-AE1F64A85C89,LenovoUserManagerPei E01FDFD3-48C8-432C-9555-4409DDBC6C6A,AmiFlashLibDxe E029BADD-E270-467E-9C0F-D7586C33850A,Runtime +E02FA6E3-AFF0-47BF-93D6-3BDEDF690BBC,BoardKvmNetworkStack E0364FEE-1440-4A41-AD3E-50E0B106A83D,DellDaBfa E03ABADF-E536-4E88-B3A0-B77F78EB34FE,CpuDxe E03D5A07-CDCD-4AD1-A829-0B5A4AA6D62B,BiosConnectProfileLoaderDaSmm @@ -9022,6 +10128,7 @@ E04095C5-F88D-4942-BEF5-3424A693A8B9,BSODSmm E0471A15-76DC-4203-8B27-6DB4F8BA644A,UbaConfigDatabaseDxe E048749B-68A4-40C2-9A83-DC2AB34819A8,FchSmmDispatcher E04EFEC1-AE85-4845-999F-950ED7352F17,DisableAbtSetup +E0527711-50F7-4672-B868-6A447EF54513,PatchDevice E052D8A6-224A-4C32-8D37-2E0AE162364D,PchSmbusDxe E05799E5-DB4B-451C-AC87-5893DD8E4295,FchTaishanDxe E05B0241-2F68-4DB4-8ADF-5760DE2E1570,TpmFwUpdateDxe @@ -9029,22 +10136,27 @@ E062C52D-78DC-4CC5-B246-B13497A8123C,PeiDxePostCodeLibReportStatusCode E065DDB3-8DFA-4CE0-A159-11D7B6FEA589,DellHwmIoSmm E0744B81-9513-49CD-8CEA-E9245E7039DA,EfiSmmGpiDispatchProtocolGuid E0746C42-D3F9-4F8B-B211-1410957B9FF5,BootOption +E07473CF-E2ED-4096-BF9F-DC64853AE80B,AmdMemFp8Dxe E07A890D-7CC3-D042-A74B-12F117DDDF15,AppleGraphicsConsole E0857D65-5F84-4592-AE49-33D49BA6CCF7,MeSoftStrapUpdatePei E08CA6D5-8D02-43AE-ABB1-952CC787C933,PeiDefaultVbtGuid E08EB66A-F063-4BB4-9D11-18F77C227BB7,HpPlatformSataPortConfigDxe +E092EDDD-0E41-4C9E-9C31-9C076FA8B5B6,ApobRsDxe E099F1C6-F520-4050-9556-D3A2CA154529,H19VariableChangedHook E09F355D-DAE8-4910-B14A-92780FDCF7CB,EdkiiPlatformSpecificResetNotificationPpi E0A0C1DE-469B-4D37-62E1-F8BB8AB958AE,Pca9545aDxe E0ADB57E-E1B6-44EC-BF2E-842874A26C83,LenovoWmaUsbDxe E0AFD3F0-C7E8-479C-9E4C-4579DCD850F8,IntegratedVideoOptionSmm E0AFD3F0-C7E8-479C-9E4C-4579DCD850F9,IntegratedVideoOptionDxe +E0B3E91A-4A7F-46AF-AD7E-D05F62A2EA9A,SystemOnScreenKeyboardDxe +E0B7F019-E82D-4432-9831-BC2CC4863F1F,FchHuangshanSmmInit E0BEC4CC-8AE8-4D15-92E5-9755A08987BB,NCT3933UPEI E0C14753-F9BE-11D2-9A0C-0090273FC14D,EfiPcAnsiGuid E0CEA537-FDB0-4D30-8C1C-9B0359A4598F,FjNuvotonNct5581Pei E0D172D7-1D81-4B39-90AE-FF45D5732483,CheckFspErrorInfoHobDxe E0D1BE6F-1C43-414E-B571-73C8C3105B18,UefiDriverAsix88179 E0D8CA17-4276-4386-BB79-48CB813D3C4F,EmbeddedTokenSpaceGuid +E0E1AB16-C482-4015-AE70-64BDFCAA89AB,DellBiosConnectAdvancedDownloadMgr E0E1F6A1-9D4B-11E3-83C4-78E7D1AF36D1,HpNetworkBiosUpdateDriver E0E2C90C-F1AD-4759-8EA9-5B4E770576CD,AmdNbioPcieZPDxe E0E7D776-E7EB-4E5F-9AA8-54CF3AA64A43,PeiServicesTablePointerLibKr7 @@ -9053,6 +10165,7 @@ E0EDAB16-C482-4015-AE70-64BDFCAA89AB,DellBiosConnectDownloadMgr E0F2E558-993B-43A9-88C8-D5308BCEBBBE,EcStorageAgentSmm E0FF720B-0140-43FE-9528-7A781357E42E,UsbOhciDxe E10539B8-1C35-4B84-8593-81555D065DD5,DellDaPasswords +E10C1F46-6ECB-47A7-BA9A-1C29D074A022,AmdSocAm5PhxPei E1136F9A-A0CF-477A-A86F-DCE8EFEC3C63,AmdSocFt6MdnDxe E113F896-75CF-F640-817F-C85A79E8AE67,EmuThunkPpiGuid E11D6290-CCFD-4501-B59A-CECBA0E79133,OdometerMetrics @@ -9060,6 +10173,7 @@ E11FACA0-4710-4C8E-A7A2-01BAA2591B4C,FdtClientProtocolGuid E121EC07-9C42-45EE-B0B6-FFF8EF03C521,AppleRtcRam E12929EF-F08C-4E26-8290-281740D874DE,DisableChassisIntrusion E12BB3A6-1EA1-4F4F-FFFF-FFFFBCE290C5,RecoveryPartitionDxe +E1319FEB-CA0D-4E73-B79C-34BA1134D79D,LVDS E13DD38C-1B41-49F5-8D92-0839D4234AA2,AmdCpmAdaptiveS4Smm E1404778-B848-4FFF-8351-9F78791417D9,TurboSmm E143C542-4FC4-4DD9-99F2-75715C44E41C,IePolicyInitDxe @@ -9076,6 +10190,7 @@ E16600D0-3C41-4798-B16A-0DBA67D2FC47,AmiCpuSmbios E17F0016-E0E6-4B01-AB59-797A2699901B,AaeonHiManager E18541CD-F755-4F73-928D-643C8A79B229,EfiNetworkInterfaceIdentifierProtocolGuid E18A21D4-964B-4974-992A-2A2FEF11E643,WOSKDxe +E18DBA7B-AB76-43FF-8C27-50EE3373481D,CxlEndpointDriver E18FE2D1-EF32-4C8E-895A-F02C3C38FB19,DellPropertyAccessorProtocol E19E3D16-BC11-11E4-9CAA-C2051D5D46B0,EfiArmProcessorErrorSectionGuid E1A21D94-4A20-4E0E-AE09-A9A21F24BB9E,EfiMeFwSkuVariable @@ -9083,6 +10198,7 @@ E1AD4352-2610-4DD6-BB8F-8BB2B03383A3,LenovoSystemScsiOpromPassThruDxe E1AEB947-940F-4635-A87F-817AB51B7261,DualDieRecoveryPei E1AF9F5B-7CDE-4F98-91ED-5E67868282B8,AsusBbVideo E1B26D32-414F-46DB-9AEE-420077F35DBE,AsrockAmdcpuDxe +E1B8CF4A-FE7B-4676-B4F7-50C7228282A4,AmdApcbPeiV3 E1C1D0A9-40B1-4632-BDCC-D9D6E5295631,EfiPaddingRsaesPkcs1V1P5Guid E1C401BB-2336-47F6-A512-4308F6F42931,BixbyEarlyLink E1CD9D21-0FC2-438D-9703-04E66D961E57,EfiExtendedSalPalServicesProtocolGuid @@ -9099,6 +10215,7 @@ E1F4062C-993B-4972-9A6A-3EB68AEC5403,RtkUndiDxe E1F7F068-97E7-4B74-BF0F-626745AF9934,DxeSpiNorFlashCommBuffer E20939BE-32D4-41BE-A150-897F85D49829,EfiMemoryOverwriteControlDataGuid E20BE735-E059-4CD5-A927-FF7D528EC650,DescriptorUpdate +E21B0336-9B81-4743-B033-6D7405734E3C,PciDeviceInfoSetupUtilityDxe E21F35A8-42FF-4050-82D6-93F7CDFA7073,PiSmmCommunicationSmm E223CF65-F6CE-4122-B3AF-4BD18AFF40A1,CpuInfoProtocolGuid E227C522-D5FE-4A53-87B1-0FBE570F98E9,ObservableProtocolGuid @@ -9110,9 +10227,11 @@ E230F9FB-12C2-4D2C-AC1C-E38F100EA530,SnapScreen E2347FA9-FD73-4165-B15C-C4665A259E53,AmtGbeChecksum E234A986-8946-485D-A645-C806225F0213,BiosDiags_2_0 E23F86E1-056E-4888-B685-CFCD67C179D4,SbRun +E2406FEC-6609-4385-AB3D-4535B6C7C46D,SmmSxDispatch2OnSmmSxDispatchThunk E2441B64-7EF4-41FE-B3A3-8CAA7F8D3017,PciPlatform E252C258-C839-48CF-A85C-E8F4C3235BDA,OemApVariable E2657A19-7CD8-5389-98BC-6E201BBF4F70,MonacoFont2x +E268A2D1-F8A2-4EB4-85B7-B052FEB79574,CpuInitDxe E269AC86-6049-4509-8D16-8899DA529BBB,PeiCmosInit E273212C-11D9-4728-B1AC-B6EE5083EED6,TbtRetimerCapsule1Dxe E2775B47-D453-4EE3-ADA7-391A1B05AC17,PciSioSerialDxe @@ -9121,10 +10240,13 @@ E287D20B-D897-4E1E-A5D9-977763936A04,EfiPchS3SupportProtocolGuid E292BA71-812C-42B9-885D-3F0565B098C7,SyncSetupCpt E2A5ECED-DE4C-432D-9AA0-061C33A308C8,A01DataServiceBodyDxe E2A74738-8934-48F5-8412-99E948C8DC1B,SmbiosDmiEdit +E2AA867F-70DE-492A-B25A-77B3055024CB,CbsBaseDxePHX E2B36190-879B-4A3D-AD8D-F2E7BBA32784,EfiCertRsa2048Sha256Guid E2B40649-EAA4-434F-8BBC-9FA4A82E6AAE,AmdSmmControl +E2C24CB6-A555-42F9-8442-BDB2B2B8B490,HsmpBrhDxe E2C3BC69-615C-4B5B-8E5C-A033A9C25ED6,Tcg800155PlatformIdEventHob E2CFB356-39A9-497B-B6B1-95B9D2EB2817,DellSlpConfig +E2D5F333-D89E-4F3B-A270-7AB3C1727A57,AmdMemShpSp6Pei E2D7B442-8413-45B8-928C-C77DEEE25D4A,FjGpioAbstractionReferencePei E2D927F5-7219-4C06-A715-ADDEF7F2821B,OemPei E2DD8CE7-0A31-4C3B-A774-B2881ED85682,SysInfo @@ -9135,7 +10257,9 @@ E2F05B00-408B-4A2B-914B-F3330B312F5E,SpeakerInit E2F66EA2-0313-4B7E-A74F-8E23A6FEB449,UfsPhyOverrideHobGuid E3007647-798F-FF48-AC61-E0B8D1B66327,PlatformDataRegion E305E101-913A-4A51-8E0E-B4618C5DB326,DellDxePchGpioControl +E30674E9-A7F0-4E1F-A5B6-D1052A9A7505,Pca6107Dxe E30C62E1-8CB1-4D98-B535-436BCD5F4566,LEMSataPortOverrideProtocol +E331EA77-E196-4590-9F35-87CF021BE337,FjBiosReadyGpio E3391FCF-E910-4E62-B216-756C850E29B9,SxDispatchNotify E33A8FC6-128F-482E-8CD5-360172CE4314,OemModelIDPei E33D951C-EBE8-474C-AFAA-21AC65AA768F,LEMBootModeFlagDxe @@ -9147,12 +10271,15 @@ E35A40E9-D4BE-4F4D-ABA7-22C29CAE0BE1,UefiDriverRealTek E360BDBA-C3CE-46BE-8F37-B231E5CB9F35,FD_Drv_X64 E364A338-2842-4F57-A7C7-CDC8CFDF6CD7,AppleEvent E3697058-B73E-421A-BE3D-C08008D8A005,SmbiosDataUpdateDxeArcherCityModular +E369E9DE-DC16-4F58-AC7B-088EA6DD5566,CbsSetupDxeSHP E36B2401-2251-4B13-AF67-A1B2EC561E36,DellSimulatedECSmm E374574A-2ADF-43DB-A778-88A75FC08026,DellSmbDaTokensConfig E3752948-B9A1-4770-90C4-DF41C38986BE,QemuVideoDxe E378875C-3282-48A0-A9A8-B1E4E16BD513,ChassisIntrusionS3 +E37E75F7-015C-4B3D-9DE8-BE595F8B0662,Amd3rdPartyDxe E380280C-4C35-4AA3-B961-7AE489A2B926,AmiSmbiosDynamicDataGuid E3830347-4844-49F1-9570-18AA377B711C,AppleDiagnosticVault +E3862753-53F0-4EF2-A2A8-C04800376EAE,FchI3cHciPei E38A1C3C-928C-4BF7-B6C1-7F0EF163FAA5,FlashDeviceLibRuntimeSmm E38C1029-E38F-45B9-8F0D-E2E60BC9B262,DisplayEngineGuid E38C11E3-968F-47B8-ACEF-ACC0693DB9FF,EfiIchTokenSpaceGuid @@ -9168,6 +10295,7 @@ E3E4048D-6C0C-43E4-AE1C-FFB579D8EF41,OpalPasswordDxe E3E49B8D-1987-48D0-9A01-EDA179CA0BD6,XmlCliProtocol E3E8BA35-541F-4EF1-BFB8-75F02A26CC75,HybridGraphicsPei E3ED7C21-9DB8-47C7-8E7D-7DB97FE2063E,DellSmmCircBuff +E3F7AF0C-DB93-4A36-A516-BE4844EA56C2,AsusFtmPei E405B445-B580-4C7F-9C1D-F226B81F74DD,BiosPowerSave E405FE96-5A56-40BA-BC24-619C89E2D2EE,EfiBmcSmbiosProtocol E40B55E5-20A2-41B0-A1AA-42040C98FF9D,WakeEventDxe @@ -9180,6 +10308,7 @@ E42DAC01-2260-4D0B-ADF9-86D3888396FD,FjMacPei E43176D7-B6E8-4827-B784-7FFDC4B68561,EfiRngAlgorithmRaw E4364A7F-F825-430E-9D3A-9C9BE6817CA5,EdkiiLinuxTerm E449F62E-A726-48D2-942B-7872BF90067D,PciSerialDxe +E44E41B5-8B58-4524-BF1D-4EE608A5983D,BoardAcpiTables E44FC862-12DF-4D4B-9511-93802514AAF8,RomHoleReplacementProtocolSmm E451DCBE-96A1-4729-A5CF-6B9C2CFF47FD,EfiPrimaryConsoleInDevice E4541241-8897-411A-91F8-7D7E45837146,BaseSerialPortLibNull @@ -9196,6 +10325,7 @@ E49D33ED-513D-4634-B698-6F55AA751C1B,EfiSmbusHcProtocolGuid E4A83242-DEEE-F12E-15FF-0102036CC3CE,OneKeyLabel E4A88140-8E28-461D-91BC-A90FF015717C,UsbOcUpdateDxeLightningRidgeEXRP E4A95FFC-DA1C-440F-8ACC-E3FA6B5EE4F1,DecompressFvCnvDxe +E4BD5CB1-9452-4BCA-AD8A-C3EDD770C40C,HpBatteryControl E4BD5CB1-9452-4BCA-AD8A-C3EDD770C40D,HpDimmSpdAccess E4BD5CB1-9452-4BCA-AD8A-C3EDD770C40E,HpThermalDiagnostic E4BD5CB1-9452-4BCA-AD8A-C3EDD770C40F,HpSysDiagsLaunch @@ -9203,10 +10333,12 @@ E4BD5CB1-9452-4BCA-AD8A-C3EDD770C410,HpSmartAdapterStatus E4BD5CB1-9452-4BCA-AD8A-C3EDD770C411,HpDimmId E4C5BA98-B685-4368-8D40-B80095FC0564,HpIcicleDxe E4C9411C-1268-404C-9E90-2573EF04F43F,StaticSkuDataDxeNeonCityEPECB +E4CDF1A7-7659-491B-9079-B961E0E486FB,AmdPspPsbDisablePei E4D359FE-B180-45D2-A6E7-4638876BC471,BiosGuard28 E4D470CB-41D2-5308-D260-778DDAFADE13,AfterPowerLossDxe E4D662CD-7CCB-4CB5-AECE-4EEA398FF8E4,FpgaSocketBbsPcie E4D932F4-31C9-4075-8FA3-4030F7EB767A,SmmPlatform +E4EB2CA8-FF2C-4EA4-A6FB-3EA56E711996,WakeOnLanInit E4ECD0B2-E277-4F2B-BECB-E4D75C9A812E,NbDxe E4ED28FD-13C1-40C4-B55A-C5260771A2CF,DeviceManagerDxe E4F272DA-237F-454C-8868-FCF096CF1C6C,LenovoPasswordCp @@ -9226,6 +10358,7 @@ E51F643F-5F3C-4CFD-9126-4687305F18DA,ReadyToPxeBootGuid E5205B53-9758-44AB-A44D-DB3BE41D6742,DellNbConfigPei E523FC7A-3DF9-4846-A801-D8CC1BE29148,PxeDriver E53485A0-3BF3-40D2-934B-3DB0FF405737,ComputraceBds +E535D55A-A0B6-4AE6-82CC-FCAB7B5DC579,OemErpHookDxe E53734A3-E594-4C25-B1A2-081445650F7F,SmmChildDispatcher2 E541B773-DD11-420C-B026-DF993653F8BF,EfiSmmSwDispatchProtocolGuid E5434B26-AEDF-43DE-8935-D1C485A912B9,EfiPeiPlatformTypeOpalCityFpgaPpi @@ -9250,12 +10383,15 @@ E5B24906-CF08-4DCD-9EE3-0D163FCA34BF,DellTcg2Dxe E5B58DBB-7688-44B4-97BF-5F1D4B7CC8DB,EfiEapConfigurationProtocolGuid E5B734C5-391D-46DF-B8EA-6695C979B1D8,Npce388nFlashSmm E5CB2AC9-D35D-4430-936E-1DE332478DE7,EfiGraphicsDeviceInfoHobGuid +E5CEE945-CCF3-4A38-A9F9-881321F3FCBE,GopConfigNexPeim E5D0875A-F647-4E16-BE4D-95024029CC44,MdesStatusCodeProtocol E5D0BBDC-1BBC-49B7-A8B6-67AAF0A1CD9E,SystemDiagnosticSplashScreenDxe E5D3026A-1CA5-40F0-8FB6-4B1AFA3C6EAA,AmiCmosAccessSmmProtocol E5DAFE50-10CB-41B5-9CB5-274E1CF1A8D7,Ip6BmcLanConfig E5DD1403-D622-C24E-8488-C71B17F5E802,EfiAdapterInformationProtocolGuid +E5E2681D-2E43-44E6-A8CF-0630E35F9D8B,BoardSpiConfigProtocolSmm E5E2C9D9-5BF5-497E-8860-94F81A09ADE0,NvmeSmm +E5E3C886-25FA-4C0C-B390-DCA2889A3B21,AmdErrorLogDisplayShpDxe E5E6AB4A-0D7D-4A06-A164-61E47CCE9B3B,DellAcpiPolicy E5FD5ACD-59F8-4D0A-B3A9-22CB020A6EAA,AmdFabricZpPei E5FF803C-DE51-4CC7-A8DB-39549815A886,DellUsbMassStorageDxe @@ -9264,6 +10400,7 @@ E609AFBF-EA72-4D82-83CF-D7E065AC6B3B,NonAmtNetworkControllerSmm E60A79D5-DC9B-47F1-87D3-51BF697B6121,CpuPei E6186D9E-2797-423D-B075-970A2C5FC338,DmiArrayVarProtect E622443C-284E-4B47-A984-FD66B482DAC0,BootManagerPolicyDxe +E629A64A-12C2-42D2-8F1F-B4A459887C28,SysTopologyReportDxe E62F9F2F-4895-4AB5-1234-399D0D9C1234,ComputraceDxe E633E57C-BBB1-4C6A-9F45-22C49378ADD0,BootScriptThunkHelper E6427302-1B37-4B55-8DD5-F43A2F018DE2,AmdCpmModernStandbyInitPei @@ -9290,6 +10427,7 @@ E6A6F568-53B5-45A4-859D-43B8C6C3645B,BiosDiags E6A7A1CE-5881-4B49-80BE-69C91811685C,Setup E6A81BBF-873D-47FD-B6BE-61B3E5720993,PchSmiDispatchProtocol E6AF1F7B-FC3F-46DA-A828-A3B457A44282,EfiPeiCpuIoPpiInstalledGuid +E6C079CB-3D03-4BDF-8D72-4AB7FD8D5AD3,SBSMM E6C20B9D-0A4B-45F1-8E39-A967E28F99C4,DustFilterReminderSmm E6C2F70A-B604-4877-85BA-DEEC89E117EB,PchInitVariableGuid E6C7EBB7-1604-4FCB-8F87-B3A6F48730AE,OrderedCollectionTest @@ -9297,10 +10435,13 @@ E6D77BB0-34D5-4726-BD29-FFFE09E26FB4,SwitchableRsteRaidDriver E6DA0CE7-C945-4775-941C-55F74D46FA84,FjSlp20Support E6DB4007-113B-4605-8F5F-668D7364C807,SmmInt15Service E6DC9900-CCF6-452B-85FA-C7F1E52F0152,SlotDataUpdateDxeNeonCityEPECB +E6E9CCBF-2544-47EF-ACFD-E49A96A79F49,AmdMbistBrhPei E6ED9B13-31AF-4C92-A561-D47B2FA994F7,FastBootHandlerDxe +E6EDCD6E-6F99-43D3-ABFA-E3E683683AB6,AsusGetOpRom E6F014AB-CB0E-456E-8AF7-7221EDB702F7,ThinkpadAcpiNvsDataProtocol E6F4F8F7-4992-47B2-8302-8508745E4A23,OemPir E6F930E0-BAE5-40E6-98C9-4CD2298278E7,IconNetworkVolume +E6FEA4AA-575C-48FC-99CE-1724DBDC1FF2,ActDxe E6FF49A0-15DF-48FD-9ACF-D7DC271B39D5,UefiCorebootModulePkgTokenSpaceGuid E701458C-4900-4CA5-B772-3D37949F7927,StatusCodeCallbackGuid E706CB54-84B8-40BD-832F-7FB2D5CB87B3,FileExplorerLite @@ -9309,20 +10450,24 @@ E71B3596-109E-4642-A432-FCF497F8DAE7,FchKeithSmmInit E724981B-2875-4C8A-9F9A-02AEC1965016,AsusModuleToIntSmmWrapper E72527CF-505B-4B50-99CD-A32467FA4AA4,AsfTable E7301EDE-A5D3-4CB6-9EB8-3235F938C3CA,MeIgnitionPostMem -E7428F24-EF0C-4AE4-B521-9D247494900E,OnBrdDevOprom +E7428F24-EF0C-4AE4-B521-9D247494900E,AsusOnBoardDeviceOprom E747D8FF-1794-48C6-96D7-A419D9C60F11,DellSioPolicyConfigPei E7488F2F-A9DD-4034-EB46-538F71DC7B9D,HpPcieRedriverPei E74CA1E2-6E5C-4F07-9831-8367B132DB89,AmdPspDxeV2Rn E74CCC19-BFF9-442E-9DA5-6A866262F179,DellCoreServiceHWIDNvs E74E2F92-ED3B-435D-8A7D-BB29408E9B22,AfuCapsuleOnDiskPei +E750224E-7BCE-40AF-B5BB-47E3611EB5C2,TdxDxe E7591211-2A96-4FD8-BB84-08387723DA26,PlatformVTdInfoSamplePei +E763F5EF-301E-6DEE-BBB7-A6EC553DCF7E,HpModernStandbySetupConfigDxe E764500B-E398-4AB7-BBBC-99A8E683681F,MeSmbiosDxe E767BF7F-4DB6-5B34-1011-4FBE4CA7AFD2,VlvMmioPolicyPpiGuid E770BB69-BCB4-4D04-9E97-23FF9456FEAC,SystemAccess E77217F1-8B8D-4973-94BD-C975794BC010,MarvellUndiDriver E77E53A5-A5B8-45DC-BAEB-66C86F1AC811,RuntimeAcpiSmm +E7862AEE-A997-48F3-9C58-B79D340D003A,AcerLibMemBuffer E7884BF4-51A1-485B-982A-FF89129983BC,BaseMemoryLibRepStr E790848E-B6AB-44AB-8491-DCA50C3907C6,EfiIpmiSolStatusProtocol +E7980D88-35FC-4C20-8319-921A73C9A239,SioChip1InitDxe E79A7050-8109-40D1-B3C0-2A3C74C40204,AGI E7B2CD04-4B14-44C2-B748-CEAF2B664AB0,EdkiiPeiVariablePpi E7B5B715-1183-4533-BE76-56A6D7CEB02E,AmiPeiPciEnumerationPpi @@ -9337,7 +10482,9 @@ E7F1DFF9-DAB6-498A-9ADF-57F344EDDF57,UfsPassThruDxe E806424F-D425-4B1A-BC26-5F690389A15A,PlatformMeHookPpi E807983E-D366-40C9-846A-0ED7E6022C96,DellTagsConfig E80DE38B-6D52-48D5-8BA2-52828AEE6221,OhciDxe +E80F8135-5770-470F-AFAA-6B7B3CFB8A46,VlvInitPeimLate E813E116-C099-4D21-9C34-A552D5E9A5D0,AmiPeiMrcDefault +E813FD31-D8CE-4DDF-8A9F-24D5CAC64FCF,AdlinkGetBoardInfo E8145F46-B686-4068-A2FA-13A58CB38BE6,ManufacturingModeSmm E81CC0AB-0585-8E1D-5BD9-59702FDA1FC4,OemBoardSmbios E82F99DE-74ED-4E56-BBA1-B143FCA3F69A,DebugAgentTimerLibNull @@ -9357,13 +10504,16 @@ E88A8180-16DA-4A1B-908C-3E517686F1FA,WifiProvisioningSmm E88DB748-A947-46CF-AB6F-5C99B6C6C4B8,RealtekGopDriver E8935638-7437-46BC-ADB5-3153820FD6CE,RTKUndiDxe E894B313-54CA-4BB2-8CDD-851E8AC9027C,AmiDebugportHob +E89C977A-4547-4FBB-8E64-E1BE3CE39B34,CxlManager E89EACF0-96F8-4CCD-89E9-968CD39F2317,BrightnessControlDxe E8A0A79D-043F-4A36-93F2-6FA5C506E9FF,AmdPspKvm E8A59290-A2AF-4099-B0AF-323FF9B7AB41,BeginBootButton E8A9F123-07DF-46E2-9BF6-C593CAF06A62,HardwareHealthManagementDxe E8C729FE-FB0A-4344-AD7E-48784116C9EF,SmmIpmiInitialize E8C803DC-E9A9-4081-B21A-6FABA90992DA,H19SelfTestDriver +E8C887B0-6884-4933-B958-71EEBC5120DA,SECWDTDXE E8DC00BA-411F-4D52-B925-50785436AC81,SmmSleepEvent +E8DCDF2D-0F9B-455B-90ED-A8CA5312B943,GpioV2ProtocolInitSmm E8DDEB8B-82D7-4B6E-A2B4-D5EAEC2B8976,IrsiRegistrationRuntimeDxe E8E1BAFB-12B0-4932-A481-DF93982C7AE4,SystemUsbHcLatchDxe E8E2C394-A4B7-4583-8C43-CAEC15C34966,EmulatedEepromPei @@ -9392,6 +10542,7 @@ E974833F-A4AE-4E39-BE37-8B6780DFAD01,Int15PanelFitting E975314A-1464-411F-85E4-041D903CB6C4,DellSmBiosStrucFan E98ADB03-B8B9-4AF8-BA20-26E9114CBCE5,EfiUserCredential2ProtocolGuid E98E9C9E-DABE-4D3F-B02A-B3708BD784EB,FiopCcgFwUpdate +E9928F9F-5D3F-47BC-BFC0-F5190C69CCE5,NvmExpressSmm E995D524-6B97-41BF-8CE3-D7C889742246,H19ReadBackDefaultData E9987145-B05B-4787-B918-5BEB86C4AB6F,TamperEventS0Protect E998C6D8-572B-4E18-96CC-031EA3DD558C,AmiOemCsm16BinaryGuid @@ -9424,6 +10575,7 @@ EA2E8235-37BD-4FFD-8571-556D4AAE3ED8,UsbTypeCSxIndicatorsSMM EA2EC402-2FD5-475F-922C-98EAE0376312,SystemLegacyBiosDxe EA32C776-6C14-41F4-80C6-0349E9E48AF8,FvbVariableStorageSmm EA343100-1A37-4239-A3CB-B92240B935CF,SdioSmm +EA34FEA6-EDA4-4A3F-BE0C-9BE1859D4621,AmdMemSmbiosV2StxD5Pei EA353BAD-99D2-4BE6-9B28-53A8E8596934,Armani_BatteryHealthControlSmm EA382BBC-192F-4883-9F30-CFA4A558362A,OemUsbPortMapPei EA42B5E6-5E01-4C6E-8189-C1EFA6ACFD01,LenovoProtectPBPei @@ -9442,6 +10594,7 @@ EA7CA24B-DED5-4DAD-A389-BF827E8F9B38,EfiPeiFirmwareVolumeInfo2PpiGuid EA7D60A6-1050-45E4-BEDF-BF177290D4B2,EfiEmmcBootPartitionProtocolGuid EA7F0916-B5C8-493F-A006-565CC2041044,FspS3Notify EA816D2C-CEE5-4F02-99B5-D3905CBBD077,EfiHiiNewProtocol +EA8D05BC-E348-4B75-BF6B-92E6B1E98068,HQDxeService EA907DA1-4A74-80B8-A66E-BAA384223E12,DellBiosAttributes EA94D9D6-BE8B-4BD0-9481-B04348165CFB,AmdPspSmmV2Ssp EA9D0ED6-A18B-4052-B526-6A94F44D5170,FvbReady @@ -9451,6 +10604,7 @@ EAA5A822-EACE-488B-B187-11ABC8E72E69,AmdMemS3BlackListPei EAA96391-9BE3-4488-8AF3-B3E6EFD157D5,EmuSecPei EAAF7109-EC2D-4A30-BF4F-621408630E4C,FlashOemHooKSmm EAB17499-7B0C-459C-BD4A-772CFF1B80A8,FchPromontoryPlusPei +EAB5F9D8-4CEB-4EFA-87D3-FA155D317B22,MipiCam EAB843A9-D414-41BB-87A2-6C2952DFA2EC,GpioCfgPei EAC3AED9-692D-4C7C-A25D-3895C4F398F3,DellCustomVbeSetting EAC9599C-2D94-4886-8F6C-D7A88B5B483A,N17MQ3Gop @@ -9459,11 +10613,14 @@ EADD5061-93EF-4CCC-8450-F78A7F0820F0,Tcg2ConfigPei EADEC90E-C2BE-4B96-A161-55236822C0BB,AdlinkBSCDxe EAEE5615-0CFD-45FC-8769-A0D85695AF85,EdkiiNonDiscoverableEhciDeviceGuid EAF100CB-ABF4-49E0-97E5-5E0A7750DCCB,EcSecuredTransferSmm +EAF18DB2-FBFD-4E50-8E77-AAC8191628B5,AmdSocFp8StxKrkPei EAF59C0E-BD46-413A-9AE9-DD9F6D1A927D,SmbiosDxe EAF9E3C1-C9CD-46DB-A5E5-5A124C832323,EdkiiSdMmcOverrideProtocol EAFA9C29-D84E-42BF-B19A-6D9734EF4ABB,HpJpeg EB00DB50-C654-460F-8D7A-0E444FD32B45,DebugMaskPei +EB079C68-0B05-4A53-B8D5-01C995D66A23,AmdMemPprSmmDriver EB098808-8FC1-4FB1-AB66-26784633B745,UltraFunctionTable +EB12FD12-42EA-4A72-A05E-4EBD04618477,CbsSetupSmmSHP EB1BF7E8-D4AB-43C6-88C4-B99175350383,Dec1515Pei EB23F55A-7863-4AC2-8D3D-956535DE0375,EfiIncompatiblePciDeviceSupportProtocolGuid EB317729-1FAA-4931-BF83-31EDBDF61E99,ErrorControl @@ -9471,6 +10628,7 @@ EB338826-681B-4295-B356-2B364C757B09,EfiFtp4ProtocolGuid EB346B97-975F-4A9F-8B22-F8E92BB3D569,EfiSmmCpuProtocolGuid EB3FFEAD-45F6-4A18-AC71-C4EE97B26119,KbcPeim EB5198EB-E7F5-45A1-9CCB-E53364BB4992,AmiSmmInfoProtocol +EB53FCAD-3071-4BAB-980C-6E4A379255F3,RealtekUefiDriver EB5E4685-CA66-4769-B6A2-26068B001326,EfiPciDevErrorSectionGuid EB5FC7A5-3747-4A25-90DB-631297A0A0AF,BoardInfoPeim EB61D625-1B5D-4F45-A2A0-931EF7280B48,SmartAssetTagInfoDxe @@ -9493,6 +10651,7 @@ EB9D2D32-2D88-11D3-9A16-0090273FC14D,EfiSalSystemTableGuid EBA4E8D2-3858-41EC-A281-2647BA9660D0,EfiDebugPortProtocolGuid EBB2898D-2168-48C1-936C-64C86EB6424B,UsbPxeUndiDriver2 EBB32EA2-6382-43F3-955A-39475AE6E1AB,UefiRaidPei +EBB6653C-D182-4E9B-BC73-947A291F7740,AdvBootIhisiSmm EBBD7E6A-37D0-417A-9410-D19A59BE349F,DellBiosVersionNameDxe EBBE2D1B-1647-4BDA-AB9A-7863E396D41A,EfiActiveBiosProtocolGuid EBC01AF5-07A9-489E-B7CE-DC089E459B2F,EdkiiUfsHostControllerProtocolGuid @@ -9500,6 +10659,7 @@ EBC065D8-BEFA-4437-BED0-9A41272102F1,RestBoot EBC3AEAD-CC13-49B0-A678-5BED93956955,BasePlatformHookLibNull EBD11F37-177E-4216-A98E-56C77ADCEABE,XnoteFlashCommunicationDxe EBD705FB-FA92-46A7-B32B-7F566D944614,SP805WatchdogDxe +EBDCA8B2-8185-4AFB-9EA3-182C2DFC231A,SmmSvcCallback EBF342FE-B1D3-4EF8-957C-8048606FF670,SetupBrowserDxe EBF342FE-B1D3-4EF8-957C-8048606FF671,SetupBrowser EBF8ED7C-0DD1-4787-84F1-F48D537DCACF,DriverHealthManagerDxe @@ -9517,18 +10677,23 @@ EC359751-1DB5-4E8A-B2E9-7BA1FE9A9168,FmacDrv EC35E25B-0425-4435-A34C-96D75703B893,FjEndofPeiGPIOOverride EC386589-999F-472D-8905-CAA5332F642A,H19TextColorsHook EC3A978D-7C4E-48FA-9ABE-6AD91CC8F811,EfiKmsProtocolGuid +EC3A9E6F-9691-4D84-B00D-3E55472807EA,AmdFabricRplPei +EC4B60B8-E4A6-4293-AD72-49C6FADD10F7,PlatformDebug EC4EBACB-2638-416E-BE80-E5FA4B511901,UniversalPayloadPciRootBridgeInfo EC512283-DAE2-48D7-ABB3-95C1AD78B596,NvdimmSmbusCommon +EC52188F-8DD1-4834-AADB-C66187D460EC,AmdNbioSmm EC5A555B-6384-4C00-8625-2C1768B95B38,LenovoMeConOutReady EC63428D-66CA-4BF9-82AE-840F6D5C2305,AmiBoardPciInitProtocolGuid EC6654E5-150C-4185-BEBB-E8E5CF0763B5,LenovoTpmConfigSmm EC69A5FC-83BE-43BB-87F7-4B07E314E7C0,AmiErrorDisplayFrameworkProtocol EC761DAF-6B86-41D0-8294-350B90FC9478,SystemCapsulePolicyDxe +EC76B3B4-6821-4D4B-A0AB-D28CC27AC439,AmdSmmControl EC7F4FA1-B217-42FC-A7F7-020C4305D5BA,EfiSmramNvsHeader EC835DD3-FE0F-617B-A621-B350C3E13388,EfiIp6ServiceBindingProtocolGuid EC853378-008D-4E10-BDDF-E13FEC491B23,PowerReportSmm EC87D643-EBA4-4BB5-A1E5-3F3E36B20DA9,EfiSetupVariableGuid EC8A3D69-6DDF-4108-9476-7337FC522136,EfiKmsFormatGeneric128Guid +EC9519B1-E788-4C45-B695-244457442D64,PeiSmmControl EC953378-008D-4E10-BDDF-E13FEC491B23,LGPowerReportSmm EC953378-008D-4E10-BDDF-E13FEC492C54,LGEcCommunicationSmm EC98FF95-242C-4513-B1BC-69FA24111C58,AcpiDebugDxe @@ -9539,9 +10704,11 @@ ECA2AE9E-7594-4901-871C-449DA1A11660,I2cDxe ECADBBB6-B0AE-4571-94E3-313C3D27A611,AmdNbioGfxRNDxe ECB54CD9-E5AE-4FDC-A971-E877756068F7,EfiPramConfGuid ECB867AB-8DF4-492D-8150-A7FD1B9B5A75,AmiSmmFlashProtocolGuid +ECBCA4B6-34C3-4829-8262-5A5795C325FB,AmdRasBrhDxe ECCBF582-EEE1-45B8-8926-067F40B3E55E,LenovoIsscPei ECD81473-0533-4844-BC77-48F0DE27519B,DellSmBiosStrucD8 ECDEEFD2-C596-4CB1-AFDF-6506F6C7CE2B,D01VariableLock +ECDEFE8B-F2C9-4E9E-9C0E-066F2AD36B5C,Amd3rdPartyDxe ECEB5BA3-F44D-40A3-A21D-6CBF147FA92F,N19M_GOP ECEBCB00-D9C8-11E4-AF3D-8CDCD426C973,HttpBootDxe ECF149B5-BF4E-4AC8-8A8C-CE87CBAC93D3,EfiSiliconRcHobsReadyPpi @@ -9554,6 +10721,7 @@ ED17FA2D-609A-4E8D-99F6-9C0CBBDD8C2F,TbtPei ED1D807E-9A5F-436A-B8AA-D78ED9E7D92C,DellNumberOfPStateProtocol ED2DE537-7823-4CB1-B687-85BA9BBEF0B4,RaidRom ED32D533-99E6-4209-9CC0-2D72CDD998A7,EfiSmmVariableProtocolGuid +ED3F1E9D-2320-4B37-9119-E928C1E6323B,BctBaseSmmSHP ED443008-3F06-46DB-927E-7AB2F02AF9D9,ApplePciCameraDxe ED4F0AA6-B02B-4539-BF51-C9E114E0FE7F,DeviceFwServicePei ED4F127B-45B0-4B44-88E9-0D7EF1BE98A0,FjSysmanYggdrasilSmmPowerOnTime @@ -9562,6 +10730,7 @@ ED52984E-6ED7-4445-9D5D-200C3201F51E,PlatformStage0 ED6E0531-F715-4A3D-9B12-C1CA5EF698A2,IntelFsp2PkgTokenSpaceGuid ED705681-1649-4BBB-8091-E36F52523761,StandbyImmediate ED73A77B-8AB0-4272-B7B8-E25311366FBF,AddrDecode +ED769C37-F526-444A-8D70-249BEFF04948,L05UpdateSlp20 ED815341-E67F-46C4-9DED-AA14222803C4,WakeOnLanSmm ED888C65-2D84-4595-9086-A15A1F66DE2B,EnableLsiDecoding ED8B5E2B-6622-4D14-9069-9BDEC54C9491,TcgPwdTseHook @@ -9580,7 +10749,9 @@ EDD33148-A91F-4257-84A8-2F2976CE79AF,LGPowerReportDxe EDD33148-A91F-4257-84A8-2F2976CE8ABE,LGEcCommunicationDxe EDD33148-A91F-4257-84A8-3A1A76CE8ABE,LGBdsFlowDxe EDD35E31-07B9-11D2-83A3-00A0C91FADCF,BootObjectAuthorizationParmsetGuid +EDD70CFF-6236-4FE0-A698-8436B4A3E0A8,SingleCapsuleDxe EDEBB2D8-CB7D-4A50-B7AA-B4DFFB179A8A,MemoyConfigChanged +EDF13B99-4EF3-4C9B-9FAE-4DE2D6381906,OverrideAcpiTable EDF52A90-A34C-47A2-832A-9308112CAE38,AmdDynamicLid EDF704F1-2675-4019-9258-6F0F6C677D95,DellWdtFeatureSmm EDF8DA40-AAD1-11DF-A1F4-0002A5D5C51B,PL341Dmc @@ -9596,6 +10767,7 @@ EE1DF00B-B4FE-4762-A330-1E8AB4D9149D,ExtfTable EE21FDBC-CA29-4CD8-8BDC-90070505668A,PerformanceControlSmm EE257F8F-E710-4181-9B01-C06698454A16,AmiPlatformInfoCompressedFfsSection EE28FF61-B960-47EB-B6BA-1F5EFBDAB442,OemTpmTypeDxe +EE2EA7C3-274A-898D-90D3-46BED34AAF61,GpioControlDxe EE2F2CA1-911D-44AE-97D8-AB313758B025,DellMfgDefaultsDxe EE2F45D2-5BA4-441E-8A1D-AA22DFA3B6C5,RomImageMemoryHob EE30FD26-1524-4CA2-B56D-345830DC9CDB,LenovoFingerprintCp @@ -9615,6 +10787,7 @@ EE90D8FC-6181-4B15-83C4-7D1CA0C36E2A,DramTweakerDxe EE911B88-39E3-4F56-B94C-64FFF5B53A3B,AmdCpmABRecoveryPeim EE993080-5197-4D4E-B63C-F1F7413E33CE,CpuDxe EE9B8D90-C5A6-40A2-BDE2-52558D33CCA1,EfiSmmUsbDispatch2ProtocolGuid +EE9E0D09-51B9-4537-AA64-3BD74C5FBFDF,OemDPTC EE9F26FB-D6DE-4FD3-9720-DC6CD3E337C1,CrisisMemoryInitPei EEA190F0-962F-11E0-AA80-0800200C9A66,SctMilestoneTaskEntry EEAE874B-64D3-4323-B582-545FB3C2EB5A,SmmBbsManagerInitNotifyProtocol @@ -9629,19 +10802,24 @@ EEDFD470-449A-4B15-8038-C85487AF5E4C,HpCommonFlashInfoDxe EEE00707-6734-491B-ADB3-C168265AB5B5,DellUsbMassStorageSmm EEE07404-26EE-43C9-9071-4E48008C4691,EfiWheaSupportProtocolGuid EEE4417A-D34E-40B1-9483-1BF62BD113CC,SystemFirmwareDeviceDxeSmm +EEE4E585-0585-4091-A89F-CAB51F6FCF3E,FchYuntaiPei EEECC312-FF36-4E21-9C5F-0B208CDC02FA,FjDTPMAutoConfigDriver EEEE611D-F78F-4FB9-B868-55907F169280,PlatformInitPreMem EEF749C2-C047-4D6E-B1BC-D36EB3A5559C,QuarkVariableLockGuid EF02529C-A283-48CD-8D08-6A1E9C3C03D3,AmiTseOemPortingVar18 EF074CB0-701A-4975-81C1-38F9212BD089,AmdMiniRasServiceDxe EF0C99B6-B1D3-4025-9405-BF6A560FE0E0,SmbiosMiscDxe +EF0D2ECB-AE7B-4ED2-8848-F39290D19322,StatusCodeLoggerSmm EF0E795C-749A-4B41-B994-7DDC6B594388,UsbOcUpdateDxeNeonCityEPRP EF14FD78-0793-4E2B-AC6D-062847E01791,MfgModeVariableGuid EF152FB4-7B2F-427D-BDB4-7E0A05826E64,BootFlowVariable EF155E93-2CB4-4A72-8720-8B447A91F540,AmdSocFp6CznDxe EF17CEE7-267D-4BFD-A257-4A6AB3EE8591,MemorySubClassDxe +EF183CE7-7ED5-4E29-BCDA-524182B4744B,AmdNbioGfxRPLDxe EF22F8A9-267E-4840-BC32-F0CFDFDFA426,PeiSmmControlPei +EF2331AD-7010-436C-B90E-2CB3536404EF,SioSetupUtilityDxe EF251B71-CEED-484E-82E3-3A1F34F512E2,EfiQuarkSCSocIdTokenSpaceGuid +EF2961F9-87D0-4E9E-A3B1-B14FFA8D347C,FjUsbTypeCPowerLimitDxe EF2B91D1-1847-4D88-9115-2835A0BEFBDC,MpmPei EF33C296-F64C-4146-AD04-347899702C84,SystemSmmUsbLegacySmm EF3468E0-1B0A-46D7-842C-928E67EFE0B8,X11DPHPeiDriver @@ -9653,8 +10831,11 @@ EF52F4D8-4B2E-4A2D-B888-DAC5421D73F7,AsfSmm EF598499-B25E-473A-BFAF-E7E57DCE82C4,TpmErrorHobGuid EF6619EE-F77D-4A8C-8693-D60D6AA56702,SetupSecurity EF7BF7D6-F8FF-4A76-8247-C0D0D1CC49C0,EfiSmbiosSlotPopulationGuid +EF86A49E-CD3C-445A-878E-7A738D2C7ED2,BoardSpiBusSmm +EF95CFE1-0D3A-4869-948B-FC36A3B13901,BoardSpiBusDxe EF96596D-F1D8-4B76-8ABE-700E03C1CA74,HspAcpifTpmSmm EF9A3971-C1A0-4A93-BD40-5AA165F2DC3A,ConsoleOutDevicesStartedProtocol +EF9A853E-2DF3-48ED-91E5-6232668C4DB1,CbsSetupSmmPhx EF9AEFE5-2BD3-4031-AF7D-5EFE5ABB9A0D,PeiLockPhysicalPresencePpiGuid EF9FC172-A1B2-4693-B327-6D32FC416042,EfiHiiDatabaseProtocolGuid EFA96432-DE33-4DD2-AEE6-328C33DF777A,EfiHashAlgorithmSha384Guid @@ -9674,10 +10855,14 @@ EFFFCCC2-7D6A-42B1-AD6D-61B882801AFF,PxeDriver F002485F-B0B6-4C3A-9E7B-54FABD83074D,EfiPlatformTypeLightningRidgeExecB2Protocol F00497E3-BFA2-41A1-9D29-54C2E93721C5,EfiStandaloneSmmNonSecureBuffer F0049EF2-FF2C-43A7-A308-B02421A3A69A,BmcSmbiosDxe +F00D1083-A096-452B-A2A9-47EAF7C4A09C,BbSecDataUpdateSmm +F00FD1CF-2FBF-4096-A882-7E7B8FD80BD5,SelfRepairApplication +F01872BF-AF48-40D2-92DB-51588466EEAB,RtkUsbUndiDxe F019E406-8C9C-11E5-8797-001ACA00BFC4,BfbFs F01BED57-04BC-4F3F-9660-D6F2EA228259,EfiLegacySpiFlashProtocolGuid F02313F7-581F-4F31-B09C-C1BA2FC58713,HpDriveWipe F02313F7-581F-4F31-B09C-C1BA2FC58714,LoadHpDriveWipeDxe +F023E844-257F-47CA-8C25-CD91C5B047F2,AmiSerialUart1 F035B9D5-744F-4FCB-9283-BAB4FAD9FAE8,FjBeepIfNoGraphic F035F3BD-863E-4573-A609-BB9405A8B1F7,SystemSecureVariableStorageSmm F0384FFD-8633-452F-9010-F6B7D2EAE2F1,WinNtFirmwareVolumePei @@ -9706,6 +10891,7 @@ F0F1588E-9028-4EB8-8031-F233B48EA0B7,PxeDummyDxe F0F1C259-FD3A-446B-B2F2-049334D1BD23,AmdSocAm4CznPei F0F6F006-DAB4-44B2-A7A1-0F72EEDCA716,AcpiPlatform F0FFF864-8454-46E5-9F2B-CF14F0A41A48,WarmBootSmm +F100061D-A26E-4790-8BE3-D41F364D85A9,WmiSetupUnderOsSmm F1039C39-9299-41FE-8799-5EAFB668EE6C,AmdRasRnApeiDxe F103A5A5-9345-4C3F-B496-DA14F41B6269,PlatformStage1 F109F361-370C-4D9C-B1AB-7CA2D4C8B3FF,AmiCpuInfoProtocol @@ -9716,16 +10902,22 @@ F1143A53-CBEB-4833-A4DC-0826E063EC08,MeRegionUpdateVolume F11721F9-1A68-4FEB-BB25-55B6F7A1AE74,LEMProgressBarProtocol F11757E2-1D21-47BB-9E07-04C60DA00ECA,UnexpectedIrqWA F122A15C-C10B-4D54-8F48-60F4F06DD1AD,LegacyBiosDxe +F1297746-69D5-4013-84CC-0FEB09CCD5C3,PlatformInfoBootMsgDxe F12DF3A4-6A2E-44BD-A3F9-2135A04E19E2,AsusEcPeiBiosReady +F12F698A-E506-4A1B-B32E-6920E55DA1C4,TpmMmioSevDecryptPei F139BD77-7FF7-49D6-9086-D50AB26F6DD7,EfiSvSmmProtocol F140088A-05B0-46E3-83FF-D5A69B7C7185,SioIt8669eDxe +F1448205-61B4-4624-B325-6C06BB1BC90B,SioFlexIoAcpiDxe +F149AE6A-1252-49A8-94FC-A2DDF5DCCF5D,AsusWatchDogTimerSmm F14F7AC4-F736-4AFE-B01A-129B1FA13A5D,AplPreMemNvram F1530049-1292-4D78-9F26-D3D59D17E5E4,LenovoEcEkKeyDXE +F1577E74-CAAB-41C8-9E26-F11EEBB6C83D,SdMmcDevice F15B92A8-6B4C-4EA3-A380-2F352AD15417,RealTekLanDriver F16BDBF0-3A61-11DE-8A39-0800200C9A66,PerfTuneDxe F16F8948-F81F-4F30-91A6-8F2F0FD57882,MAPS_SIO_InterfacePei F174D532-D257-4FE0-92A3-B664E8BBC8ED,HpCoreErrorCodeHandlerPei F179D6C8-1FC4-4C39-AC83-F1077080D070,FjMfgDescriptorUnlockDxe +F1809E8A-ACB8-4176-8CD4-B98414D0FD0D,ApicInfoDataDxe F18BA2F3-053D-408D-9E28-96CDA65272A8,FfsIntegrityCheckPei F19071B5-B2F6-4A9C-B2E2-FBF56DA5B229,AmdMemChanXLatZpPei F193C257-3CB5-4D90-A694-2E371082E116,UpdateSerial_NUM @@ -9734,11 +10926,13 @@ F19B5EA5-7CDF-4CB2-9C37-F1BE08AC588B,BroadcomGigabitEthernetDxe F19E8ED6-442B-4194-AF8E-C91435E36320,SmcTpmProvisionDxe F1A18726-FD79-4DF5-A326-E20B8CC46B06,DellBootScriptSmiHandler F1A25221-A98B-4189-85F2-0BA226A370DA,FTP_DXE +F1ADE5E1-230A-4573-A2BC-56F949BC9C3B,UpdateDsdtCrc F1B4C587-6E35-4FAB-B946-FAE259638660,FjGabiFlashBiosRegionCtrlDxe F1B52F57-16A6-4922-B81D-65838458FAB4,OemMfgPorting F1BDCEC7-31D1-4F0F-AF62-D02A44076026,LenovoN25Q032FlashPartDxe F1BE4604-24B3-4DA5-8BBF-E87A6C046C93,CbsSetupDxeMDN F1C50D3A-58E4-4104-9176-00CDF8BC4BB2,H2ODisplayEngineLocalTextDxe +F1CF1802-8F94-4504-AA96-CE193C57C86E,PostCodeSmm F1DBDF29-12EA-20D1-2C48-84C3DC5C7E0D,SbSocRavenPei F1DBDF29-A2EA-90D1-2A48-94C3DC5C7E0D,SbSocSummitPei F1E48287-3FE1-4535-89AB-48D6C3DA2759,EfiHotKeysProtocol @@ -9748,9 +10942,11 @@ F1FBD629-22EA-40D1-AA48-94C3DC5C7E0D,SbSocBristolPei F1FCD66F-8966-441E-909C-77F211AB9C3E,MERecoveryDxe F2074EA5-B8C9-4EBC-881E-30102260703E,ACPI_FACS_MODIFY F208336A-BFF4-4678-BA4F-342C72373C3A,FjOemIgcEsrtDxe +F20D51DA-16FD-48E6-B4D0-532B6BB8AEA6,AdlSemaWatchdogDxe F21173FE-DF86-4B8B-AFF9-C7CB77B9C7DD,PeiIchInit F21249FB-22FF-4D95-A1C6-CC9933F88CF7,HPD F2191B94-DCAB-49FF-8C8F-A41FA9908D11,DeviceLayoutLoadDxe +F21DA8FA-35B6-4CD0-BB27-620D1460D361,MIPICamera_Lattice F22FC20C-8CF4-45EB-8E06-AD4E50B95DD3,EfiHiiDriverHealthFormsetGuid F231ED70-045A-4273-A156-C344748F083F,RtcLossOptionSmm F235025B-85A0-4AD8-839E-A7FEDFD0CDE3,WatchRobotPei @@ -9758,6 +10954,8 @@ F235025B-85A0-4AD8-839E-A7FEDFD0CDE4,PowerOnRobotPei F238F47C-1DE9-4E8B-81B9-CC924E6B5BE5,EfiPcmciaRequestProtocol F23C466D-D24A-46E4-A951-A58FBC5ECE7F,KEMaEeepDxe F23FBEC1-987E-4B4B-BF47-7DDCC118DBF3,I2cEnumerateDriver +F244E34D-3643-4E3B-9DA5-8C691CBDE0EB,MeUnlock +F2458956-7449-4632-A875-8F418B74C937,CF9IoTrap F24643C2-C622-494E-8A0D-4632579C2D5B,EfiTrEEPhysicalPresenceGuid F26C52BA-024B-410F-B4FB-2F34573443B4,E0104X7 F26D2D30-817A-45E0-B703-E6C8837A8821,SmbiosType24 @@ -9773,6 +10971,7 @@ F282908A-A6F9-4E50-9D6C-210478F1ED46,FtBbUpdate F282DD45-CA7B-40EC-9618-99381C08F409,OpaPlatCfg F28AD240-3DB8-4809-B6F9-6841129FB23A,FjNvramVariablesAccessReferenceSmm F2911DF2-7DDF-40D9-9835-AD2B1E200CEA,SystemSetupExitDxe +F29729C7-B759-4B5C-B134-07FC40AC3CD2,Raid F2A128FF-257B-456E-9DE8-63E7C7DCDFAC,OpromStartEndProtocolGuid F2A4A79E-89EF-4B25-A48D-A5F05C8D522C,FchKeithDxe F2BA331A-8985-11DB-A406-0040D02B1835,EmuVirtualDisksGuid @@ -9781,6 +10980,7 @@ F2C16B9E-8985-11DB-92C8-0040D02B1835,EfiUnixFileSystem F2C1819D-10F5-4223-9236-9B4EBF1B9AE7,Logo1394 F2C1910E-F5C9-4B72-B243-6D59096A79F0,EfiI2cSlaveProtocolGuid F2C8B80E-8985-11DB-93F1-0040D02B1835,EfiUnixUga +F2CC3F5B-725F-4290-9A12-B379970295FF,RtkUndiDxe F2CC5D06-8985-11DB-BB19-0040D02B1835,EfiUnixConsole F2D006CC-8985-11DB-A472-0040D02B1835,EfiUnixMemory F2D3B330-8985-11DB-8AA3-0040D02B1835,EfiUnixCpuModel @@ -9788,6 +10988,7 @@ F2D74E5A-8985-11DB-9705-0040D02B1835,EfiUnixCpuSpeed F2D7FB2E-FFE7-4321-A4F5-DBB4370B963B,SubcomponentMeasureEvent F2E23F54-8985-11DB-AC79-0040D02B1835,EfiUnixIoProtocol F2E5E2C6-8985-11DB-A191-0040D02B1835,EfiUnixUgaIoProtocol +F2E7CE72-5657-494A-BDBA-F3DD8E1DF641,HpAcLossPei F2E98868-8985-11DB-9A59-0040D02B1835,EfiUnixThunkProtocol F2ED3D14-8985-11DB-B057-0040D02B1835,PeiUnixAutoscanPpi F2F0DC30-8985-11DB-A15B-0040D02B1835,UnixFwhPpi @@ -9809,18 +11010,22 @@ F328E36C-23B6-4A95-854B-32E19534CD75,SmmCommunicateHeaderGuid F33261E7-23CB-11D5-BD5C-0080C73C8881,FrameworkEfiMpServiceProtocolGuid F3331DE6-4A55-44E4-B767-7453F7A1A021,MicrocodeUpdate F3358D50-72D4-46C0-9BDC-EDC1DADFB55F,DellSmmMemLibWrapper +F3410F5B-4756-488F-844D-546B5DF05A0D,FjBiosPostGpioDxe F342BE75-274C-433C-A24D-2816F5433D50,VmwSmbios F34C2FA0-DE88-4270-8414-961222F4521C,PeiFlashMapPpi F34F24D7-7531-4B83-9116-BD03FCF99878,SyscfgSyncDxe F3552032-8985-11DB-8429-0040D02B1835,RealTimeClock F35F733F-5235-4D7B-83FA-97780CEBCB20,Ping6 +F3604610-DD52-4BED-8F76-ABC9284CD040,UltrasoundHpdCheck F363B225-4D2C-4352-80CD-8EA4280F8DC0,OemEdidFromGop F36FF770-A7E1-42CF-9ED2-56F0F271F44C,EfiManagedNetworkServiceBindingProtocolGuid F3714ADF-E3C3-473B-8FCC-5C34630C45C0,ComputeHmacSha256ProtocolGuid F3749E2C-5139-4E7A-B53A-4F5080B68B8F,PciSerialDxe +F3774E67-3F2E-4ED1-9A5D-A22EB1A073EF,FjVarstoreSyncGHO F3794B60-8985-11DB-8E53-0040D02B1835,Cpu F38C34DE-9C38-438C-9AF6-69F584F17EC0,PoofAnimationState4 F38D1338-AF7A-4FB6-91DB-1A9C2183570D,WdtPpi +F38D9312-05CB-48A8-8D3E-13643D686EA3,PchInitSmm F3982635-7706-4842-840F-6479B4865866,DellSimpleBootFlagDxe F3A3FCA1-466F-4978-AC84-2EA70FAE2BA2,AsfSecureBootSmm F3A4B484-9B26-4EEA-90E5-A206540CA525,EfiPciIovPlatformProtocol @@ -9848,13 +11053,16 @@ F43A3770-293D-4834-8D5A-DAB72F94D5E3,DefaultsManagerSmm F43F7EF6-6A33-427F-961B-6C4F412A977C,TraceHubPostCodeHandlerDxe F44875AB-B9FC-4578-A280-AA335B49967C,CmosSmm F4491BA4-7672-486F-B4D7-99899D22DA57,AmiPeimHob +F4493D0A-FDCB-4E25-9F11-6416B1514F0E,OemVerbTable F44C00EE-1F2C-4A00-AA09-1C9F3E0800A3,EfiArpServiceBindingProtocolGuid +F45370EE-1E16-417F-AD8B-D886B4F05547,BmcRfCertDxe F45A96A9-35DF-40CB-A0DA-C5F551CD6B21,SetupMenuSmm F46998C9-DD30-4C64-966C-E17777B2568A,AppleSmc F46B2EB2-E0D7-4C96-A3B1-0C61BB245C42,EdkiiSmmCryptoProtocol F46D8EA6-4A67-4872-B0D1-D4FDEA0B692F,LenovoSvpManagerSmm F46EE6F4-4785-43A3-923D-7F786C3C8479,LenovoStartupMenuDxe F4731D79-537E-4505-BD52-C03F9B1F6B89,BaseTimerLibNullTemplate +F4796268-1F6E-473C-80B2-7AFC3D2AC7DC,RtcWakeUpSmm F479E147-A125-11D4-BCFC-0080C73C8881,WinNtBlockIoDxe F495F038-71E6-49DB-9A80-B2E98F7BA718,PeiDbgModuleLocator F496922D-172F-4BBC-A1EB-0EEB949C3486,EfiAlternateFvBlock @@ -9881,6 +11089,7 @@ F5089266-1AA0-4953-97D8-562F8A73B519,EfiUsbHcProtocolGuid F508CCC1-E0DA-4A63-954C-6F0CE5CD1643,ThermalDxe F50B86B3-132F-4998-B386-2D49DCB79250,AsusTCG2DxeSetupItem F50E702C-8653-4CDE-BBCE-43B4D55B34B8,EfiMiscSubclassDriver +F515E82B-44D9-41D8-BA90-EAEFC7C6A668,FlashMediaReaderDxe F51D8B66-E76A-43CF-9880-3FAE4D30F687,SmmBbsManagerProtocol F5255151-DD1F-4BD9-A350-235200798740,UpdateDsdtByAcpiSdtDxe F52C3858-5EF8-4D41-834E-C39EEF8A45A3,EfiSerialGpioProtocol @@ -9898,14 +11107,19 @@ F5751C02-5378-469A-8514-07562D5057A6,CheckWakeUp F57D1C2E-3879-11DF-9118-931B1E0F29B0,VmwLogRuntimeDxe F57DF891-1DD1-4C67-99A1-4AB2DAD9FFBC,OdmDebugSmmProtocol F5883FC5-F8EE-4E44-B386-6021FB320C9B,ScReset +F5932638-89A4-477E-B93E-32A51284F3F8,AsusMcuPowerSavingDxe F5985F80-CF55-46AD-8CCB-D49BF9168AC4,AmiRedfishVlan F59A5549-B879-440C-A1F6-38AF40F2773E,PcieSataController +F5A41EC4-97AD-40F6-82EB-EE8501CD4926,AmiTlsCertificate F5AC7057-5650-466E-B692-76A47223EFB0,AcpiSmmPlatform +F5AF6D30-2EDE-4026-8E71-74EF7F36D363,DellDfuPersistentEventDxe F5B22FDA-B35C-4898-9F4E-40A44C47E295,FjClearsureEraseDxe F5B423E7-C4C8-474E-B5A1-3C68AD993402,AaeonBiosInfoPei F5BEF7C6-E153-4ABA-8340-515309F82964,ExtendODMSmm +F5C09051-2CF4-476D-8C83-7EF35BACF30A,WakeOnRtcSmm F5C48BAE-C10D-4A76-B855-5D5B062AFE04,LOMDriver F5D14DB5-2F0C-4611-9DDC-7C182B173A71,ProgressBarEmptyRightEndcap +F5D16B69-80C9-F8A0-C28D-ADC6F0D71370,AmdMemSmbiosV2RplPei F5DB13F4-0D20-4F76-BCB4-B361FCE4EB72,OemQkeyDxe F5DD1F71-C3E2-473D-84D5-341A374054AF,SystemFlashCommunicationDataProtocol F5E655D9-02A6-46F2-9E76-B8BE8E60AB22,EfiIfrRefreshIdOpGuid @@ -9914,6 +11128,8 @@ F5F219D3-7006-4648-AC8D-D61DFB7BC6AD,FontPackageListGuid F5F2AC62-6232-445C-B322-5969A083980C,MAPS_SIO_InterfaceDxe F5F87B4F-CC3C-408D-89E3-61C59C5407C4,SataConfigGuid F5F98F9A-7F21-4190-96DE-4C2713754BE5,DecompressFvAbtDxe +F5FF6D65-F0E5-4763-B204-8B739DF0DD1E,SystemTouchHotZoneDxe +F605503E-9870-4DA5-BE65-CCAA85004EE2,MemoryDeviceInfoDxe F60B6782-3247-4CDC-BDB7-5CEB184686AD,SystemUsbHidParserSmm F617B358-12CF-414A-A069-60677BDA13B3,DxeIchPlatformPolicyProtocolGuid F617B358-12CF-414A-A069-60677BDA13B4,UsbPolicyGuid @@ -9933,6 +11149,7 @@ F6663081-02D1-4F52-B57C-FDAD224941D4,AmdMemSmbiosV2RvPei F6697AC4-A776-4EE1-B643-1FEFF2B615BB,IncompatiblePciDeviceSupportDxe F672AE85-3769-4FB8-A5A0-70B38FB0A7C4,DxeTimerLibEsal F67FEE3A-DBE2-4228-9732-B4DD1E5FF6AF,BoardInfoSmmProtocol +F684BBB3-C802-47C5-A59B-A392ADF72AAF,FabricTopologyDump F6937495-1F44-4A8A-8A1B-5A669F9396F6,DevConsole F6994CBA-2351-4EBC-A2DA-20BAC2FE2CF3,SmmPciLibPciRootBridgeIo F6A11F0E-0CBE-440C-BD85-49FB595686EA,LegacyUcrDxe @@ -9944,12 +11161,14 @@ F6C73719-F34C-479C-B32F-277FCBBCFE4F,DelBootOption F6C78BEB-21FA-4855-9325-311B6A9DAA9E,RealtekGopLoader F6CDAAE0-B301-4202-89F6-8623E6AED26E,DellSmBiosStrucTherm F6D35FBB-63EA-4B25-81A5-5E62B4886292,PlatformSetup +F6D74E2F-EEAC-41B7-9E7A-29B258393DB2,AmiAmdPciResourceReport F6ECDC25-2079-475A-B0E8-F48B8FA5C20A,DellSTMicroTpmFwMgmtDxe F6EE6DBB-D67F-4EA0-8B96-6A71B19D84AD,EdkiiStatusCodeDataTypeVariableGuid F6F48D69-0C1E-4A3A-80DD-CC15474FF52A,DellDesktopPowerLEDDxe F6FB3997-F4EF-4354-B9C2-4737AFED4F2F,AsusWifiRealtek F706D0C8-F6FC-4F7A-AC98-96BA5CC43AAA,SandyBridgeGopDriver F70A4116-FDF6-45FB-93CD-84CDDD73DFD4,EfiPeiPlatformTypeLightningRidgeExecB1Ppi +F70A6E93-82E1-4E6A-9A26-E7DE6ACE5BBB,PostScreenInfo F7119829-314A-4E7F-8853-44AA79A7CB43,PspFactoryReset F7162F38-6088-4842-B0ED-C143DAD39EFB,PTUpdatePCD F7196B8E-472B-4C1D-9AB9-A69A8992F46C,LenovoVariableStoreSmmRuntimeDxe @@ -9963,6 +11182,7 @@ F74FF9BE-90CA-4B57-B769-F606FAA52572,UnexpectedCapsuleUpdateCallback F7503CEB-481C-4AE2-B42D-8BD684F395E1,SecureBIOCamera_Sonix F75BD2CD-F473-4BA1-89B3-1E69EFC8BA70,ASUS_HW_FastBootDXE F75BE584-342D-44D2-9819-36641E8D0107,GetFmpInfo +F761BD04-6E5E-4E37-94F4-4699972B243D,AmdMemStpSp6Pei F7673C6A-9C5C-4C54-B086-C6E0B7D03DB8,AmdSmmControl F76E0A70-B5ED-4C38-AC9A-E5F54BF16E34,DriverHealthFormSetGuid F771B43A-A5C2-45A8-8254-CBC08250DA15,BoardInitDxe @@ -9977,10 +11197,12 @@ F78285FD-121E-49F4-9716-44E307656586,Python2710 F786D3E4-B003-4C9D-96A3-A4FA84EF9603,DellDeviceCfgDrv F788DE7A-AB18-4886-BD3E-79ED9786F1A5,AmdMemPprSmmDriverSsp F799A761-2FC3-4240-92F1-FE457DC2FBBD,SpdPlatformInfoSmm +F7A11672-3EDB-4F77-8A1E-5E8C1E0C98E8,CsbSmartCoverSmm F7A1EEC5-7DA5-4D80-8EDA-C28347276328,CsmInt15HookSmm F7A1F48E-0F6A-4F12-A74D-ED6F5B6B00F2,OpromUpdateDxeLightningRidgeEXECB4 F7AD60F8-EFA8-44A3-9113-231F399EB4C7,EfiKmsFormatMdc2128Guid F7B0E92D-AB47-4A1D-8BDE-41E529EB5A70,H19UnlockPswd +F7B1EE00-A1B2-43DD-8F1B-815F0D1CE451,SataDevInfo F7B87A79-A640-4AA5-8C1E-453FB26EF376,EfiPeiPlatformTypeBuchananPassPpi F7CA7568-5A09-4D2C-8A9B-758468592AE2,AmiNvramControlProtocolGuid F7CAAF4A-B2DD-431A-8964-375D7E71B9B1,SMBIOSTypeDAhCallingInterfaceSmm @@ -9993,9 +11215,10 @@ F7D9FD14-9335-4389-80C5-334D6ABFCCED,ArmVirtPrePiUniCoreRelocatable F7DC7A53-D789-4149-9DEC-C18F2F8CC3D3,SioPowerButtonOverrideDxe F7DC7A53-D789-4849-9DEC-C78F2F8CC1D6,SmartCoverDxe F7DFDECF-9C36-4D43-85A4-6D92DAFC3477,FchPromontoryGpioSmmInit -F7ECF277-CD66-4DE8-A425-1D9F899492A7,ASUSFTM +F7ECF277-CD66-4DE8-A425-1D9F899492A7,AsusFtmDxe F7ED0F76-1F41-4527-AF2A-EECC76B8F078,ArmaniDxe F7EEA79A-D854-4099-9AE7-D0A328E44F72,AssetIDSmmProtocol +F7FD20F4-E545-4D3B-9AB5-EADB69AF130B,DellVariableLockDownDxe F7FDE4A6-294C-493C-B50F-9734553BB757,CapsuleX64 F8000580-44AB-441F-86B4-DA3CA099EEBB,H19RecordLogSmm F80156A2-1A2C-3335-982C-066C1FC37626,TbtInfo @@ -10041,12 +11264,15 @@ F8CC23A7-0F10-45AF-AA1C-0D9DD8BB3C20,DellHttpsBootManager F8D85E52-00F9-4DE4-AEEC-0AE76BA6C210,FjGpioCoffeeLakePei F8E21975-0899-4F58-A4BE-5525A9C6D77A,EfiHobMemoryAllocModuleGuid F8E5058C-CCB6-4714-B220-3F7E3A640BD1,EfiUserCredentialClassPasswordGuid +F8EA63DD-3E59-462E-90E4-40ED947F60B0,AmdNbioDxe F8F995CE-B26F-4ECF-B228-0DA5151BE710,EmbeddedUefiOkrProtocol F8FABC29-6CAB-48EB-802D-FF2EF6A3DF87,HpCableDetect F8FD0711-CAC1-492F-AFC6-AFF5DA4D01B1,FpkConfigUpdateNeonCityEPRP F906769F-4AED-4A0D-8C7C-FF21B9D1051A,IntelVTdPmrPei +F909628D-4B48-42FB-BD68-0F8685E33335,CheckBIOSVersion F9109394-E5A3-4E61-B168-DC34D534451E,DellBbsmanagerSmm F91486CE-700E-4D85-ADB5-4ED532536A7F,NvmeInfoSmm +F91DCAB4-3639-11EE-BE56-0242AC120002,OobPprDxe F920B52A-B421-4509-BD00-B75FD9562775,AcerCF9Hook F921941B-708E-4BCD-98FA-525E4A9DCD55,RtkUsbUndiDriver F9229745-981C-4E07-9FC6-789545CB8818,AcpiSupportDxe @@ -10062,6 +11288,7 @@ F962C719-6C1E-4A75-8629-38157622A906,AddressTranslationDxe F99775D1-1A6E-4555-98F2-18398403D1B2,FjRuntimeServicesTableRt F99C0302-9256-4050-B41D-F24B87F702D2,KeyboardLayouts F9A66268-C49F-4D29-8D20-FC1FB04B82F4,IntelLanUefiDriverGpy215 +F9A9F8E6-C797-4FD8-9213-80C0CDC290B1,PlatformData F9AAA8B4-B4A4-4ADC-9E28-29CAD222E15A,FjSysmanAmphion F9B71F6A-5EB5-42D6-84FF-9E8A2389526F,DellAutoRtcResetDxe F9CD1703-8108-45CD-9384-5B247B8CAFF5,SerialIoDxe @@ -10070,11 +11297,12 @@ F9E5AA3D-9D61-48C6-8348-24DA25924211,EmulatedEepromPei F9EF07AB-ABD0-4FE0-ABA7-BBA295024712,DellTagDxe F9F0B131-F346-4F16-80DD-F941072B3A7D,IffsPersistentData F9F1020C-CC31-4203-8850-EEC07A52A5B5,SecPchLibFsp -F9F5318B-D0ED-4CA8-BE91-1881CEB57F1B,ACPIRAM +F9F5318B-D0ED-4CA8-BE91-1881CEB57F1B,AsusAcpiRam F9FA0EAC-A5B5-40DD-BDFD-F540DFEE307D,SbRecoveryDevice F9FA662B-8361-4DF0-A419-781EB024B2B7,LenovoTpmProvisionDxe F9FAAF5D-E848-4537-8A75-0E3BD2DEFB6A,UsbOcUpdateDxeXPV FA0F4B4F-D6EF-40E7-BC1B-29245CA03BC2,FvbInitilized +FA1184F7-7E5D-4E82-B30E-FEA47677A94E,I226_PXE FA177FF7-1FC7-458D-A358-D9D62AE61CEC,PeimEntryPoint FA1B2631-91C4-43F0-BA91-AFBFC7452087,DellEnhancedVersionDxe FA20568B-548B-4B2B-81EF-1BA08D4A3CEC,BootScriptExecutorDxe @@ -10095,12 +11323,14 @@ FA735DA8-ECBD-4448-8154-91E77120D427,FjPowerButtonState FA7E8D10-1312-4B98-9A3B-3B5B13A25DB0,PsmiHandlerBufferGuid FA7FA216-4DB5-D8DD-64D9-FA8D539A5ACD,PiAst2500Dxe FA8288DD-D296-4DCF-BAA0-2F56EE8C6DA9,HpBeepDeviceWmi +FA82AC30-EA3B-4FDC-9D90-C2FDFFCAFBE4,SnapScreenDxe FA8ADDEF-38F2-43A9-BF1A-2936EFC5C0CC,ResiliencyDxe FA8B2FAB-0032-43DA-9165-213BEAA2D967,StoreRestoreMBR FA8F55E8-AB22-42DD-B916-7DCE39002574,TdthiProtocolFixed FA920010-6785-4941-B6EC-498C579F160A,VirtioDeviceProtocolGuid FA990751-0795-4D5E-AB70-A6F5A6771AC9,GopPolicy FAA216CB-B569-4407-8C25-1A1457B51DEC,AsusAcpiSwSmi +FAAB0F29-0582-4AD1-9BB9-E693A0D99823,SioWdatDxe FAB13F43-BF42-450E-B695-A35479A9D642,DellPowerOffPolicy FAB5D4F4-83C0-4AAF-8480-442D11DF6CEA,VirtioScsiDxe FAB72A4B-E67F-4951-845C-BE5D8F5AE62F,AmdCcxZen3RmbDxe @@ -10119,10 +11349,12 @@ FB011592-2A97-4982-8A54-3B3F595CD59F,FchKeithPei FB045DB2-598E-485A-BA30-5D7B1B1BD54D,AOAC FB049119-AC72-459F-865A-641DC13C931D,OemLOGO FB062BBC-F19D-4CF4-81FD-FAE535D44A53,WifiProfileSync +FB07B301-8B02-4952-876E-D071EECA6B53,FjBeepOnPOSTDxe FB0F46A6-4073-413D-991A-812ABEBC3138,PlatformStatusCodeHandlerSmm FB142B99-DF57-46CB-BC69-0BF858A734F9,SerialOverLan FB15CB3F-D373-45A1-B9B1-0079D4E9D6B2,menu_seperator FB257425-8C55-4DE8-8238-F53906AA5B94,IrqBoardInfoRvpDt +FB2B7D4B-B6AE-4284-8307-2D7F848C1B46,OemBootOptionPolicyDxe FB2CE027-10E9-4F0A-A7A9-1B9D9CBD6DCC,RecoveryLedBlink FB2EE051-A1F6-4B6C-A137-961C41F2C5DD,TPMfirmwaredriver FB3D20EE-CB5D-45EE-BBAE-C5AAA9C0FDFA,ChipsetSvcPei @@ -10132,6 +11364,7 @@ FB5937D3-7839-4CE4-432C-D02585D222A2,CcgxFwUpdateSmm FB62F7F0-5433-11E4-B810-402CF41D8A90,SecureEraseDxe FB6D36A2-EF7D-4B74-99AC-80B31F6BE9B1,WheaErrorInj FB6D9542-612D-4F45-872F-5CFF52E93DCF,EfiPeiRecoveryModulePpiGuid +FB7258BD-4097-4576-8CA5-7B2C3D85E988,CapsuleCallbackDxe FB73FD5B-FAB5-4EE8-8E32-48035C2071AB,Smbios248 FB7400EE-0E8F-4B9C-B677-CF3E0F27CF62,LEMEfiAtaPassThruProtocolHook FB74A690-DE1A-4BF4-97C0-170B3535FC98,PciThunderbolt @@ -10142,14 +11375,17 @@ FB8CE09B-A0DE-467E-9DC6-4465F5987676,AmdFabricSspSmm FB925AC7-192A-9567-8586-7C6F5F710607,Cryptest FB94D898-57D5-4624-AEE5-0551AE692E9F,KEMhTstMode FBA14D8B-BE6F-0361-93E8-4CDF18E19EDE,ICCPolicy +FBA2AFEB-9ACE-49E0-BB82-0EB9E83BD5BE,HpAcLossSmm FBA34BC8-4E37-451D-A7FF-5469F52064C6,UUDriver FBA4A10E-8931-4BE0-B1EB-92A1326F64BE,AcerHwConfigDxe FBA9DAA5-EE58-4E01-9E94-5B0EB63F851B,SpiProtectionDxe FBAA1C41-ED48-4EAA-98AD-7A3F95B47915,InstallD01MsftDxe FBB3F083-5787-45AF-BADC-664854100F20,FitDiagnostics FBB4A01B-947E-4D82-B27D-1E207C070053,BaseCacheAsRamLibNull +FBC9449A-681C-4517-AB91-9072ACDEBB77,GcExt FBDC5309-BF95-44B5-A8AE-E0593E0522BF,BackupBiosUpdate FBDCC90A-A7A2-4D50-AF79-880A513C5387,QCAWIFI +FBE0E499-2EBE-4421-A237-B21435FB7145,VariableServiceSmm FBF95065-427F-47B3-8077-D13C60710998,dbVar FBFCA56B-BB36-4B78-AAAB-BE1B97EC7CCB,EdkiiXtermR6 FBFFA123-4540-4439-A901-8899AABCDEF0,SyncMSR @@ -10160,10 +11396,12 @@ FC120ED3-40E1-46DC-8C9C-AAE3CA139ACF,BasePerformanceLibNull FC1B7640-3466-4C06-B1CC-1C935394B5C2,PchSerialGpio FC1BCDB0-7D31-49AA-936A-A4600D9DD083,EfiCrc32GuidedSectionExtractionGuid FC1D4706-88FB-42B0-98B0-A4B2E607EBAA,LibErr +FC22F5BD-FA25-4625-A53B-9CB485A98D87,SecureBootInitDxe FC3269A5-5514-4279-8C56-5D23718D879F,AsusSampleSmmWrapperPkg FC3DADEC-1E3C-49AC-9CC8-3C3597A8C85F,Smbus2HostController FC4285A7-EBB5-45D2-8541-EBA3318FC2C2,UsbOcUpdateDxeLightningRidgeEXECB1 FC44722E-1813-419F-9FDD-C3FB644CEC8C,DellErrorHandlerDxe +FC4707B5-BCB9-42AC-8790-E2269274FFBD,RtkUndiDxe FC4B3B8C-2A0B-47A2-8A95-AFFA51A01593,OsInstallerMenuDxe FC4E86EB-AAA2-4EFE-831A-1E66DB3C5970,AmdSmmControl FC510EE7-FFDC-11D4-BD41-0080C73C8881,AprioriDxe @@ -10178,13 +11416,16 @@ FC73690C-8D4A-4F8C-B7F5-BA241F316E28,CpuInitDxe FC740D58-59BA-429B-99EF-627051737B76,ImageDecoder FC740D58-59BA-429B-99EF-627051737B78,AsusImageDecoder FC788727-C2D0-469C-BD03-5AEA03323C67,GlobeMask +FC7A2E28-EF78-4472-8B17-B8BB0024616E,UefiRaid FC7B9F22-2AF6-4BDC-9B94-38646F1E0830,AsusIoSecInterface FC7DD6E0-813C-434D-B4DA-3BD649E9E15A,EdkiiScoTerm +FC8377DE-A3DA-421C-A455-E111BAA679E9,AmiFchUart0Dxe FC87501F-F707-49A2-B676-77717DD904DC,SmiCpuDecode FC8BE767-89F1-4D6E-8099-6F021EBC87CC,AmiIrqDmaMaskVariable FC8CFD34-4D25-478C-83F0-0309C93FFBA4,AmdCcxVhDxe FC90EB7A-3E0A-483C-A26C-484D36593FF4,AcpiPlatform FC9A50C1-8B3D-40D0-9912-6E26D7896CBA,AmiHeciSmm +FCA3A635-C4AF-458D-9679-F7B61480E39F,AmdGraphicsDxe FCA6A1D3-66D3-4E38-A737-E45A58B1A5D0,OobInit FCAA9AD2-D6C1-483E-8A24-15BE21704FAD,CablesIdm FCABE6A7-7953-4A84-B7EC-D29E89B62E87,EmbeddedMonotonicCounter @@ -10193,7 +11434,9 @@ FCC0B496-192A-48B4-BE7E-7F8763DD2FB1,FjFextDxe FCCCE259-07E1-417A-A755-E0F2CF39295E,CpuInitDxe FCD337AB-B1D3-4EF8-957C-8048606FF670,HiiDatabaseDxe FCD6562A-253A-40D7-87DE-28CFF25898C6,InsideHT +FCD67501-3518-491A-92CA-4EBC91E84BBE,AmdRAIDCoreDxe FCD6E85B-4A8E-4326-A7AB-8E67229DA8E3,AmdSocFp7PhxPei +FCDC2416-D7EB-4491-B194-3EFF5DB333C0,SVI3ManagementDxe FCDCB9C2-7987-47DF-A9A7-BE3DBA52D50C,BootOptionPolicy FCDD2EFC-6CA8-4D0B-9D00-6F9CFA578F98,EfiCpRcPkgTokenSpace FCDF7788-7878-11FF-CC77-88CCCC7788CC,EfiSmmRcToAptioBridge @@ -10202,6 +11445,7 @@ FCE2733C-8804-4293-AC52-562D2D729D2A,AmiSetupFormSetVar FCE47C4E-5ECC-4A41-B90E-0BAB09968D02,SystemSecureFlashSleepTrapSmm FCF51E6B-527F-438D-BE6D-A6D15F0CD98B,EfiTraceHubStatusCodeHandleRuntimeDxe FCF94301-9763-4A64-AA84-7892C4712367,IpSecDxe +FCFE7223-7291-4CE7-85BD-DEE481BB7115,AmdSocFp8PhxDxe FD022AE6-CF36-42F8-E360-2309237257B9,AmdNbioIOMMUSSPPei FD023012-19F4-4235-ADCF-D924DBE246FE,StaticSkuDataDxeLightningRidgeEXECB1 FD082F6E-6391-4DBC-86C3-E33CA14F3453,HpPlatformFormsDxe @@ -10222,6 +11466,7 @@ FD3B7E55-FA7B-4E07-AE1D-208B81FB0BAD,FvbRuntimeDxe FD3F690E-B4B0-4D68-89DB-19A1A3318F90,MICROCODE FD44820B-F1AB-41C0-AE4E-0C55556EB9BD,SMBiosFlashData FD480A76-B134-4EF7-ADFE-B0E054639807,UsraProtocol +FD4D6227-6B16-4BA2-BA9F-E94EB89FAF8D,EsrtDxe FD4E7631-3558-4C24-ADD3-C47EBEAB9267,HpSmmVariableProtocol FD5D40DE-20BE-44BE-9415-A51B527AB4FA,IntelWLan6GControl FD5FBE54-8C35-B345-8A0F-7AC8A5FD0521,EmuSnpProtocolGuid @@ -10236,9 +11481,13 @@ FD8DD4C4-B748-48E3-A932-BA68DD07BB06,FchSmbusDxe FD9175E4-943A-4885-A61B-40F639BC71D3,MAPS_SmartFanSmm FD93F9E1-3C73-46E0-B7B8-2BBA3F718F6C,TcgSmm FD96334B-2F26-42BE-A947-7AEFB4AF9291,IntelLanDriverPolicy +FD96DEAF-2C34-43FE-A7A8-011F8C3E9412,AfterG3InitPeim FD98B162-41BA-4C9E-982E-023699DE02F0,DellEcPolicy3 FDA14FA3-AFFC-469A-B7BB-34BCDD4AC096,PlatformIde +FDA82EB3-28A4-4950-84F6-3D49A73F0487,PlatformSmm +FDACDB6C-ACBC-4D87-8A59-83F539FC66FD,FanTuningDxe FDB3B9A7-1E82-4C77-9C6C-4305C851F253,ProgClkGenPeim +FDBC2130-2A17-4830-8477-544F3669772F,DxeCpuPowerManagement FDBE121D-3EB4-4F95-A294-B3794D177FEB,DellECZPODD FDBEBA3C-B4C5-4F76-B80A-3D1F8DA62973,DellFlashPowerConfigSmm FDC50ED1-ACB8-8048-8735-8098B7A13E5E,ApplePowerState @@ -10248,11 +11497,14 @@ FDD7E3DB-96CA-4036-9F88-9FAF7A43ACA4,MfgPanicModeHandler FDD96161-9E65-482B-B7BE-4B2F40974415,FjBootOptionDxe FDDC2E1E-33A9-40A6-A232-21D64B3622E8,SmiVariableInstallInt15Dxe FDE29A56-C197-4AE1-BB98-792B2F09725D,FspVariablePcd +FDEE5331-BEC6-4C6D-B82E-C5B14E91693E,PlatformSioEspiVwSmi FDFBBFAB-BC61-4961-B917-77445641507B,TseAfterPostInvPwdPrompt FDFBF935-656D-4EA7-9DD3-B7FB42497D78,DellSecurityAuditDisplaySmm FDFF263D-5F68-4591-87BA-B768F445A9AF,Tcg2Dxe FE00EAF2-BA37-4BCF-939C-4C78EA63ECDA,DellPropertyReady FE075D44-D9F1-4DA1-AE6A-8250553CDE66,AmiTseOemPortingVar25 +FE0CD24C-B7A0-4F0D-A78C-EC3E27181AE5,AmdMtkWlanDrvCfgDxe +FE16CB8E-82CF-4F43-AAFF-A9B3B2B55443,SmbiosInterfaceCoreDxe FE1F75AF-3647-4422-A7E1-ABD64520D904,PsrSetup FE27AFCE-A2C8-4C30-84C5-4CE14F6B292D,SataDeviceFeaturePei FE2B0D33-133D-4253-A97C-08F141044D85,OemRealtekWlanUndi @@ -10284,8 +11536,10 @@ FE9AF6AA-17F9-4A67-B009-E37579385DE5,SiliconDataInitDxe FEA01457-E381-4135-9475-C6AFD0076C61,CryptoDxe FEAA2E2B-53AC-4D5E-AE10-1EFD5DA4A2BA,BeagleBoardPciEmulation FEAAA7A6-CB95-4670-B499-877FA6CA6BAE,MeudFile +FEB817B5-5006-4DAD-B3B7-B72E26FF3EC3,AsusOnBoardDevicePei FEC445CC-2466-4DCE-9052-7400E044554F,CbsBaseDxeZP FEC46340-CA99-49FE-BCCA-D09FA6064A4A,MrcHooksServicesPpi +FEC58211-6025-45B7-9DCF-DB21A433BB78,MmcSetPowerOffTypePei FECCA19A-D1D3-4CDD-B477-56573F58B1A3,AmdNbioAlibRNDxe FED6583D-2418-4760-AC96-B5E18F0A6326,SmmCorePlatformHookLibNull FEDD6305-E2D7-4ED5-9FAA-DA080E336C22,PeiUsb2HostControllerPpiGuid @@ -10293,8 +11547,10 @@ FEDE0A1B-BCA2-4A9F-BB2B-D9FD7DEC2E9F,StatusCodeRuntimeDxe FEDF8E0C-E147-11E3-9903-B8E8562CBAFA,EfiBootManagerPolicyProtocolGuid FEE6987C-9FF3-4971-ABC1-23697CB6ACED,A01ModifyBootInfoDxe FEEA2404-752E-4E6E-823C-877D848CB12B,AsfSecureBootDxe +FEFEA8E3-9673-4A5D-A865-88351D2171CE,AmdDmarControlDxe FF052503-1AF9-4AEB-83C4-C2D4CEB10CA3,PhoenixEfiSmmSwSmiProtocolGuid FF084F98-B1D2-49F8-AA57-E7EEE7C48A12,VbtMipiPanel3Guid +FF0C09A0-76C7-4E99-8F21-2942D12E7B04,AmdOemRasBrhSmm FF0C8745-3270-4439-B74F-3E45F8C77064,IntelGopDriver FF0C8746-3270-4439-B74F-3E45F8C87566,gMXMsigned FF0C8746-3270-4439-B74F-3E45F8C8A588,gMXMsignedN16M2 @@ -10303,6 +11559,7 @@ FF0E5C5A-FA43-4593-BE3F-9D902E0359A6,FchPromontoryPlusGpioDxe FF10945A-1EA3-4BD8-B785-B525C5E14EBB,NonAmtNetWorkController FF11E702-8923-47CC-AD30-D9E0E240DD10,AAFTblDxe FF189B79-F558-4B6A-8A78-6FCD2B4B0E3C,FrontPageDxe +FF1B53B2-E81C-4A37-8D64-2F0F7642D82F,CustomizeMultiLogoSmm FF20FCDC-805A-7748-A090-6A8A37260D76,Power FF259F16-18D1-4298-8DD2-BD87FF2894A9,PchResetPeim FF2D54D4-5C55-4C06-8549-C3627CB8B995,EfiNbErrorLogDispatchProtocol @@ -10323,7 +11580,11 @@ FF69F7D7-BA16-4B20-8589-EA8EC0379967,DellAmdThunderboltDxe FF761299-D41F-4C73-8380-A24055ADF4B9,EDUDxe FF8124DD-34D8-4CF8-9C6F-DF6FCE3A9F13,DellUserInterface3Dxe FF917E22-A228-448D-BDAA-68EFCCDDA5D3,TxtDxe +FF97F61A-A215-46D3-8008-21CB4356042F,Wcn7851Launcher +FFA0AE14-0FD1-4169-B87D-58FB8C346556,FjLoadRtd3Table FFBD9AD2-F1DB-4F92-A649-EB9EEDEA86B5,AmiHddSmartProtocolGuid +FFD2BE39-1D4E-4623-ACC3-30689B9EA78A,TouchPadDriver +FFD92E9C-26B0-44E3-9960-872F6C4162B6,FjCmos FFE06BDD-6107-46A6-7BB2-5A9C7EC5275C,EfiAcpiTableProtocolGuid FFE0FCDC-809A-4D48-A060-6A8A6A269176,EventLogsSetupPage FFE92C5D-2D83-44E2-A4EA-294D53991DBC,HpChipsetSHUsbPortDisableSmm diff --git a/common/intel_microcode.h b/common/intel_microcode.h index c6a3d89..04354ce 100644 --- a/common/intel_microcode.h +++ b/common/intel_microcode.h @@ -21,7 +21,7 @@ WITHWARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. // This structure is described in Section 9.11.1 of the Intel Software Developer manual Volume 3A Part 1 typedef struct INTEL_MICROCODE_HEADER_ { - UINT32 HeaderVersion; // 0x00000001 + UINT32 HeaderType; // 0x00000001 for Microcode (we do not need to support IFS yet) UINT32 UpdateRevision; UINT16 DateYear; // BCD UINT8 DateDay; // BCD @@ -31,8 +31,7 @@ typedef struct INTEL_MICROCODE_HEADER_ { // Checksum is correct when the summation of all the DWORDs (including the extended Processor Signature Table) // that comprise the microcode update result in 00000000H. UINT32 LoaderRevision; // 0x00000001 - UINT8 ProcessorFlags; - UINT8 ProcessorFlagsReserved[3]; // Zeroes + UINT32 PlatformIds; // Platform Ids UINT32 DataSize; // Specifies the size of the encrypted data in bytes, and must be a multiple of DWORDs. // If this value is 00000000H, then the microcode update encrypted data is 2000 bytes (or 500 DWORDs). // Sane values are less than 0x1000000 @@ -40,7 +39,9 @@ typedef struct INTEL_MICROCODE_HEADER_ { // It is the summation of the header size, the encrypted data size and the size of the optional extended signature table. // This value is always a multiple of 1024 according to the spec, but Intel already breached it several times. // Sane values are less than 0x1000000 - UINT8 Reserved[12]; // Zeroes + UINT32 MetadataSize; // Reserved in Microcode headers + UINT32 UpdateRevisionMin; // Minimum required version for OS Kernel Late Loading + UINT32 Reserved; // Zeroes } INTEL_MICROCODE_HEADER; #define INTEL_MICROCODE_REAL_DATA_SIZE_ON_ZERO 2000 @@ -57,8 +58,8 @@ typedef struct INTEL_MICROCODE_EXTENDED_HEADER_ { typedef struct INTEL_MICROCODE_EXTENDED_HEADER_ENTRY_ { UINT32 ProcessorSignature; - UINT32 ProcessorFlags; - UINT32 Checksum; // To calculate the Checksum, substitute the Primary Processor Signature entry and the Processor Flags entry with the corresponding Extended Patch entry. + UINT32 PlatformIds; + UINT32 Checksum; // To calculate the Checksum, substitute the Primary Processor Signature entry and the Platform Ids entry with the corresponding Extended Patch entry. // Delete the Extended Processor Signature Table entries. // Checksum is correct when the summation of all DWORDs that comprise the created Extended Processor Patch results in 00000000H. } INTEL_MICROCODE_EXTENDED_HEADER_ENTRY; diff --git a/common/ksy/ami_nvar.ksy b/common/ksy/ami_nvar.ksy index 25e63de..b90e5f2 100644 --- a/common/ksy/ami_nvar.ksy +++ b/common/ksy/ami_nvar.ksy @@ -125,7 +125,7 @@ types: and _parent.attributes.extended_header and _parent.size > sizeof + sizeof + sizeof + sizeof extended_header_size: - value: '_parent.attributes.extended_header ? (extended_header_size_field >= sizeof + sizeof ? extended_header_size_field : 0) : 0' + value: '(_parent.attributes.extended_header and _parent.attributes.valid and (_parent.size > sizeof + sizeof + sizeof + sizeof)) ? (extended_header_size_field >= sizeof + sizeof ? extended_header_size_field : 0) : 0' extended_header_attributes: pos: _io.pos - extended_header_size type: nvar_extended_attributes diff --git a/common/ksy/apple_sysf.ksy b/common/ksy/apple_sysf.ksy new file mode 100644 index 0000000..4b6bb4f --- /dev/null +++ b/common/ksy/apple_sysf.ksy @@ -0,0 +1,58 @@ +meta: + id: apple_sysf + title: Apple System Flags store + application: Apple MacEFI-based UEFI firmware + file-extension: sysf + tags: + - firmware + license: CC0-1.0 + ks-version: 0.9 + endian: le + +seq: +- id: signature + type: u4 +- id: unknown + type: u1 +- id: unknown1 + type: u4 +- id: sysf_size + type: u2 +- id: body + type: sysf_store_body + size: sysf_size - len_sysf_store_header - sizeof +- id: crc + type: u4 + +instances: + len_sysf_store_header: + value: 11 + +types: + sysf_store_body: + seq: + - id: variables + type: sysf_variable + repeat: until + repeat-until: (_.len_name == 3 and _.name == "EOF") or _io.eof + - id: zeroes + type: u1 + repeat: eos + + sysf_variable: + seq: + - id: len_name + type: b7le + - id: invalid_flag + type: b1le + - id: name + type: strz + encoding: ascii + size: len_name + - id: len_data + type: u2 + if: name != "EOF" + - id: data + size: len_data + if: name != "EOF" + diff --git a/common/ksy/dell_dvar.ksy b/common/ksy/dell_dvar.ksy new file mode 100644 index 0000000..cdf07fa --- /dev/null +++ b/common/ksy/dell_dvar.ksy @@ -0,0 +1,91 @@ +meta: + id: dell_dvar + title: Dell DVAR Storage + application: Dell UEFI firmware + file-extension: dvar + tags: + - firmware + license: CC0-1.0 + ks-version: 0.9 + endian: le + +seq: + - id: signature + size: 4 + - id: len_store_c + type: u4 + - id: flags_c + type: u1 + - id: entries + type: dvar_entry + repeat: until + repeat-until: _.state_c == 0xFF + +instances: + len_store: + value: 0xFFFFFFFF - len_store_c + flags: + value: 0xFF - flags_c + data_offset: + value: 9 + +#TODO: find samples with different flags and types to make them flags insead of immediates + +types: + dvar_entry: + seq: + - id: state_c + type: u1 + - id: flags_c + type: u1 + if: state_c != 0xFF + - id: type_c + type: u1 + if: state_c != 0xFF + - id: attributes_c + type: u1 + if: state_c != 0xFF + - id: namespace_id_c + type: u1 + if: state_c != 0xFF and (flags == 2 or flags == 6) + - id: namespace_guid + size: 16 + if: state_c != 0xFF and flags == 6 + - id: name_id_8_c + type: u1 + if: state_c != 0xFF and type == 0 + - id: name_id_16_c + type: u2 + if: state_c != 0xFF and (type == 4 or type == 5) + - id: len_data_8_c + type: u1 + if: state_c != 0xFF and (type == 0 or type == 4) + - id: len_data_16_c + type: u2 + if: state_c != 0xFF and type == 5 + - id: data_8 + size: len_data_8 + if: state_c != 0xFF and (type == 0 or type == 4) + - id: data_16 + size: len_data_16 + if: state_c != 0xFF and type == 5 + + instances: + state: + value: 0xFF - state_c + flags: + value: 0xFF - flags_c + type: + value: 0xFF - type_c + attributes: + value: 0xFF - attributes_c + namespace_id: + value: 0xFF - namespace_id_c + name_id_8: + value: 0xFF - name_id_8_c + name_id_16: + value: 0xFFFF - name_id_16_c + len_data_8: + value: 0xFF - len_data_8_c + len_data_16: + value: 0xFFFF - len_data_16_c diff --git a/common/ksy/edk2_ftw.ksy b/common/ksy/edk2_ftw.ksy new file mode 100644 index 0000000..bed3013 --- /dev/null +++ b/common/ksy/edk2_ftw.ksy @@ -0,0 +1,37 @@ +meta: + id: edk2_ftw + title: EDK2 Fault Tolerant Write NVRAM store + application: EDK2-based UEFI firmware + file-extension: ftw + tags: + - firmware + license: CC0-1.0 + ks-version: 0.9 + endian: le + +seq: +- id: signature + size: 16 +- id: crc + type: u4 +- id: state + type: u1 +- id: reserved + size: 3 +- id: len_write_queue_32 + type: u4 +- id: len_write_queue_64 + type: u4 + if: len_write_queue_32 % 0x10 == 0 +- id: write_queue_32 + size: len_write_queue_32 + if: len_write_queue_32 % 0x10 == 0x04 +- id: write_queue_64 + size: ((len_write_queue_64.as) << 32) + len_write_queue_32 + if: len_write_queue_32 % 0x10 == 0 + +instances: + len_ftw_store_header_32: + value: 28 + len_ftw_store_header_64: + value: 32 diff --git a/common/ksy/edk2_vss.ksy b/common/ksy/edk2_vss.ksy new file mode 100644 index 0000000..8c6b5fd --- /dev/null +++ b/common/ksy/edk2_vss.ksy @@ -0,0 +1,158 @@ +meta: + id: edk2_vss + title: EDK2 VSS NVRAM store + application: EDK2-based UEFI firmware + file-extension: vss + tags: + - firmware + license: CC0-1.0 + ks-version: 0.9 + endian: le + +seq: +- id: signature + type: u4 +- id: vss_size + type: u4 + valid: + expr: _ > len_vss_store_header.as and _ < 0xFFFFFFFF +- id: format + type: u1 +- id: state + type: u1 +- id: reserved + type: u2 +- id: reserved1 + type: u4 +- id: body + type: vss_store_body + size: vss_size - len_vss_store_header +instances: + len_vss_store_header: + value: 16 + +types: + vss_store_body: + seq: + - id: variables + type: vss_variable + repeat: until + repeat-until: _.signature_first != 0xAA or _io.eof + + vss_variable_attributes: + seq: + - id: non_volatile + type: b1le + - id: boot_service + type: b1le + - id: runtime + type: b1le + - id: hw_error_record + type: b1le + - id: auth_write + type: b1le + - id: time_based_auth + type: b1le + - id: append_write + type: b1le + - id: reserved + type: b24le + - id: apple_data_checksum + type: b1le + + vss_variable: + seq: + - id: signature_first + type: u1 + - id: signature_last + type: u1 + valid: + expr: _ == 0x55 + if: signature_first == 0xAA + - id: state + type: u1 + if: signature_first == 0xAA + - id: reserved + type: u1 + if: signature_first == 0xAA + - id: attributes + type: vss_variable_attributes + if: signature_first == 0xAA +# vvv Intel legacy + - id: len_total + type: u4 + if: signature_first == 0xAA and is_intel_legacy + valid: + expr: _ >= len_intel_legacy_header.as + 4 + 1 # Header size + at least one UCS2 character for the name + UCS2 null terminator + at least one byte of data +# ^^^ Intel legacy +# Next 2 fields can be of any value for an authenticated variable due to them being a combined value of MonothonicCounter + - id: len_name + type: u4 + if: signature_first == 0xAA and not is_intel_legacy + - id: len_data + type: u4 + if: signature_first == 0xAA and not is_intel_legacy +# vvv Auth variable + - id: timestamp + size: 16 + if: signature_first == 0xAA and is_auth + - id: pubkey_index + type: u4 + if: signature_first == 0xAA and is_auth + - id: len_name_auth + type: u4 + if: signature_first == 0xAA and is_auth + valid: + expr: (_ >= 4) and (_ % 2 == 0) # UCS2 characters come in byte pairs + - id: len_data_auth + type: u4 + if: signature_first == 0xAA and is_auth + valid: + expr: _ > 0 +# ^^^ Auth variable + - id: vendor_guid + size: 16 + if: signature_first == 0xAA +# vvv Auth variable + - id: name_auth + size: len_name_auth + if: signature_first == 0xAA and is_auth + - id: data_auth + size: len_data_auth + if: signature_first == 0xAA and is_auth +# ^^^ Auth variable +# vvv Apple MacEFI + - id: apple_data_crc32 + type: u4 + if: signature_first == 0xAA and not is_intel_legacy and not is_auth and attributes.apple_data_checksum +# ^^^ Apple MacEFI +# vvv Intel legacy + - id: intel_legacy_data + size: len_total - len_intel_legacy_header + if: signature_first == 0xAA and is_intel_legacy +# ^^^ Intel legacy + - id: name + size: len_name + if: signature_first == 0xAA and not is_intel_legacy and not is_auth + valid: + expr: (len_name >= 4) and (len_name % 2 == 0) + - id: data + size: len_data + if: signature_first == 0xAA and not is_intel_legacy and not is_auth + valid: + expr: len_name > 0 + instances: + is_valid: + value: state == 0xFC or state == 0x7F or state == 0x3F + is_intel_legacy: + value: (state == 0xF8 or state == 0xFC) # Special states indicating Intel legacy variables + is_auth: + value: state != 0xF8 and state != 0xFC and ((attributes.auth_write or attributes.time_based_auth or attributes.append_write) or (len_name == 0 or len_data == 0)) + len_intel_legacy_header: + value: 28 + len_auth_header: + value: 60 + len_standard_header: + value: 32 + len_apple_header: + value: 36 diff --git a/common/ksy/edk2_vss2.ksy b/common/ksy/edk2_vss2.ksy new file mode 100644 index 0000000..bd4d149 --- /dev/null +++ b/common/ksy/edk2_vss2.ksy @@ -0,0 +1,150 @@ +meta: + id: edk2_vss2 + title: EDK2 VSS2 NVRAM variable storage + application: EDK2-based UEFI firmware + file-extension: vss2 + tags: + - firmware + license: CC0-1.0 + ks-version: 0.9 + endian: le + +seq: +- id: signature + size: 16 +- id: vss2_size + type: u4 + valid: + expr: _ > len_vss2_store_header.as and _ < 0xFFFFFFFF +- id: format + type: u1 +- id: state + type: u1 +- id: reserved + type: u2 +- id: reserved1 + type: u4 +- id: body + type: vss2_store_body + size: vss2_size - len_vss2_store_header + +instances: + len_vss2_store_header: + value: 7 * sizeof + +types: + vss2_store_body: + seq: + - id: variables + type: vss2_variable + repeat: until + repeat-until: _.signature_first != 0xAA or _io.eof + + vss2_variable_attributes: + seq: + - id: non_volatile + type: b1le + - id: boot_service + type: b1le + - id: runtime + type: b1le + - id: hw_error_record + type: b1le + - id: auth_write + type: b1le + - id: time_based_auth + type: b1le + - id: append_write + type: b1le + - id: reserved + type: b25le + + vss2_variable: + seq: + - id: invoke_offset + size: 0 + if: offset >= 0 + - id: signature_first + type: u1 + - id: signature_last + type: u1 + valid: + expr: _ == 0x55 + if: signature_first == 0xAA + - id: state + type: u1 + if: signature_first == 0xAA + - id: reserved + type: u1 + if: signature_first == 0xAA + - id: attributes + type: vss2_variable_attributes + if: signature_first == 0xAA + - id: len_name + type: u4 + if: signature_first == 0xAA + - id: len_data + type: u4 + if: signature_first == 0xAA +# vvv Auth variable + - id: timestamp + size: 16 + if: signature_first == 0xAA and is_auth + - id: pubkey_index + type: u4 + if: signature_first == 0xAA and is_auth + - id: len_name_auth + type: u4 + if: signature_first == 0xAA and is_auth + - id: len_data_auth + type: u4 + if: signature_first == 0xAA and is_auth +# ^^^ Auth variable + - id: vendor_guid + size: 16 + if: signature_first == 0xAA +# vvv Auth variable + - id: name_auth + size: len_name_auth + if: signature_first == 0xAA and is_auth + - id: data_auth + size: len_data_auth + if: signature_first == 0xAA and is_auth + - id: invoke_end_offset_auth + size: 0 + if: signature_first == 0xAA and is_auth and end_offset_auth >= 0 + - id: alignment_padding_auth + size: len_alignment_padding_auth + if: signature_first == 0xAA and is_auth +# ^^^ Auth variable + - id: name + size: len_name + if: signature_first == 0xAA and not is_auth + - id: data + size: len_data + if: signature_first == 0xAA and not is_auth + - id: invoke_end_offset + size: 0 + if: signature_first == 0xAA and not is_auth and end_offset >= 0 + - id: alignment_padding + size: len_alignment_padding + if: signature_first == 0xAA and not is_auth + instances: + offset: + value: _io.pos + end_offset: + value: _io.pos + end_offset_auth: + value: _io.pos + len_alignment_padding: + value: (((end_offset - offset)+3) & ~3) - (end_offset - offset) + len_alignment_padding_auth: + value: (((end_offset_auth - offset)+3) & ~3) - (end_offset_auth - offset) + is_valid: + value: state == 0x7F or state == 0x3F + is_auth: + value: (attributes.auth_write or attributes.time_based_auth or attributes.append_write) or (len_name == 0 or len_data == 0) + len_auth_header: + value: 60 + len_standard_header: + value: 32 diff --git a/common/ksy/insyde_fdc.ksy b/common/ksy/insyde_fdc.ksy new file mode 100644 index 0000000..2bfb0f7 --- /dev/null +++ b/common/ksy/insyde_fdc.ksy @@ -0,0 +1,23 @@ +meta: + id: insyde_fdc + title: Insyde Factory Data Copy NVRAM store + application: Insyde-based UEFI firmware + file-extension: fdc + tags: + - firmware + license: CC0-1.0 + ks-version: 0.9 + endian: le + +seq: +- id: signature + type: u4 +- id: fdc_size + type: u4 + valid: + expr: _ > len_fdc_store_header.as and _ < 0xFFFFFFFF +- id: body + size: fdc_size - len_fdc_store_header +instances: + len_fdc_store_header: + value: 0x50 diff --git a/common/ksy/insyde_fdm.ksy b/common/ksy/insyde_fdm.ksy new file mode 100644 index 0000000..50e06b4 --- /dev/null +++ b/common/ksy/insyde_fdm.ksy @@ -0,0 +1,91 @@ +meta: + id: insyde_fdm + title: Insyde Flash Device Map + application: Insyde-based UEFI firmware + file-extension: fdm + tags: + - firmware + license: CC0-1.0 + ks-version: 0.9 + endian: le + +seq: +- id: signature + type: u4 +- id: store_size + type: u4 +- id: data_offset + type: u4 +- id: entry_size + type: u4 +- id: entry_format + type: u1 +- id: revision + type: u1 +- id: num_extensions + type: u1 +- id: checksum + type: u1 +- id: fd_base_address + type: u8 +- id: extensions + type: fdm_extensions + size: num_extensions * sizeof + if: revision > 2 +- id: board_ids + type: fdm_board_ids + if: revision > 2 and extensions.extensions[1].count > 0 +#TODO: need to find a sample with revision == 4 and extensions.extensions[2].count > 0 +- id: entries + type: fdm_entries + size: store_size - data_offset + +types: + fdm_extensions: + seq: + - id: extensions + type: fdm_extension + repeat: eos + + fdm_extension: + seq: + - id: offset + type: u2 + - id: count + type: u2 + + fdm_board_ids: + seq: + - id: region_index + type: u4 + - id: num_board_ids + type: u4 + - id: board_ids + type: u8 + repeat: expr + repeat-expr: num_board_ids + + fdm_entries: + seq: + - id: entries + type: fdm_entry + repeat: eos + + fdm_entry: + seq: + - id: guid + size: 16 + - id: region_id + size: 16 + - id: region_offset + type: u8 + - id: region_size + type: u8 + - id: attributes + type: u4 + - id: hash + size: _parent._parent.entry_size - 16 - 16 - 8 - 8 - 4 + instances: + region_base: + value: _root.fd_base_address.as + region_offset.as + diff --git a/common/ksy/ms_slic_marker.ksy b/common/ksy/ms_slic_marker.ksy new file mode 100644 index 0000000..0ea0de1 --- /dev/null +++ b/common/ksy/ms_slic_marker.ksy @@ -0,0 +1,30 @@ +meta: + id: ms_slic_marker + title: Microsoft SLIC Marker + application: Phoenix-based UEFI firmware + file-extension: slmr + tags: + - firmware + license: CC0-1.0 + ks-version: 0.9 + endian: le + +seq: +- id: type + type: u4 +- id: len_marker + type: u4 +- id: version + type: u4 +- id: oem_id + size: 6 +- id: oem_table_id + size: 8 +- id: windows_flag + type: u8 +- id: slic_version + type: u4 +- id: reserved + size: 16 +- id: signature + size: 128 diff --git a/common/ksy/ms_slic_pubkey.ksy b/common/ksy/ms_slic_pubkey.ksy new file mode 100644 index 0000000..3c042ae --- /dev/null +++ b/common/ksy/ms_slic_pubkey.ksy @@ -0,0 +1,32 @@ +meta: + id: ms_slic_pubkey + title: Microsoft SLIC Public Key + application: Phoenix-based UEFI firmware + file-extension: slpk + tags: + - firmware + license: CC0-1.0 + ks-version: 0.9 + endian: le + +seq: +- id: type + type: u4 +- id: len_pubkey + type: u4 +- id: key_type + type: u1 +- id: version + type: u1 +- id: reserved + type: u2 +- id: algorithm + type: u4 +- id: magic + type: u4 +- id: bit_length + type: u4 +- id: exponent + type: u4 +- id: modulus + size: 128 diff --git a/common/ksy/phoenix_evsa.ksy b/common/ksy/phoenix_evsa.ksy new file mode 100644 index 0000000..11135d1 --- /dev/null +++ b/common/ksy/phoenix_evsa.ksy @@ -0,0 +1,144 @@ +meta: + id: phoenix_evsa + title: Phoenix EVSA NVRAM store + application: Phoenix-based UEFI firmware + file-extension: evsa + tags: + - firmware + license: CC0-1.0 + ks-version: 0.9 + endian: le + +seq: +- id: type + type: u1 +- id: checksum + type: u1 +- id: len_evsa_store_header + type: u2 +- id: signature + type: u4 +- id: attributes + type: u4 +- id: len_evsa_store + type: u4 +- id: reserved + type: u4 +- id: body + type: evsa_body + size: len_evsa_store - len_evsa_store_header + +types: + evsa_guid: + seq: + - id: guid_id + type: u2 + - id: guid + size: 16 + valid: + expr: _parent.len_evsa_entry == 22 + + evsa_name: + seq: + - id: var_id + type: u2 + - id: name + size: _parent.len_evsa_entry - 6 + + evsa_variable_attributes: + seq: + - id: non_volatile + type: b1le + - id: boot_service + type: b1le + - id: runtime + type: b1le + - id: hw_error_record + type: b1le + - id: auth_write + type: b1le + - id: time_based_auth + type: b1le + - id: append_write + type: b1le + - id: reserved + type: b21le + - id: extended_header + type: b1le + - id: reserved1 + type: b3le + + evsa_data: + seq: + - id: guid_id + type: u2 + - id: var_id + type: u2 + - id: attributes + type: evsa_variable_attributes + - id: len_data_ext + type: u4 + if: attributes.extended_header + - id: data + size: _parent.len_evsa_entry - 12 + if: not attributes.extended_header + - id: data_ext + size: len_data_ext + if: attributes.extended_header + + evsa_unknown: + seq: + - id: unknown + size: 0 + + evsa_entry: + seq: + - id: entry_type + type: u1 + - id: checksum + type: u1 + if: entry_type == 0xE1 + or entry_type == 0xE2 + or entry_type == 0xE3 + or entry_type == 0xED + or entry_type == 0xEE + or entry_type == 0xEF + or entry_type == 0x83 + - id: len_evsa_entry + type: u2 + if: entry_type == 0xE1 + or entry_type == 0xE2 + or entry_type == 0xE3 + or entry_type == 0xED + or entry_type == 0xEE + or entry_type == 0xEF + or entry_type == 0x83 + - id: body + type: + switch-on: entry_type + cases: + 0xED: evsa_guid + 0xE1: evsa_guid + 0xEE: evsa_name + 0xE2: evsa_name + 0xEF: evsa_data + 0xE3: evsa_data + 0x83: evsa_data + _: evsa_unknown + + evsa_body: + seq: + - id: entries + type: evsa_entry + repeat: until + repeat-until: (_.entry_type != 0xED + and _.entry_type != 0xEE + and _.entry_type != 0xEF + and _.entry_type != 0xE1 + and _.entry_type != 0xE2 + and _.entry_type != 0xE3 + and _.entry_type != 0x83) + or _io.eof + - id: free_space + type: u1 + repeat: eos diff --git a/common/ksy/phoenix_flm.ksy b/common/ksy/phoenix_flm.ksy new file mode 100644 index 0000000..a1148c4 --- /dev/null +++ b/common/ksy/phoenix_flm.ksy @@ -0,0 +1,45 @@ +meta: + id: phoenix_flm + title: Phoenix Flash Map + application: Phoenix-based UEFI firmware + file-extension: flm + tags: + - firmware + license: CC0-1.0 + ks-version: 0.9 + endian: le + +seq: +- id: signature + size: 10 +- id: num_entries + type: u2 +- id: reserved + type: u4 +- id: entries + type: flm_entry + repeat: expr + repeat-expr: num_entries + +instances: + len_flm_store_header: + value: 16 + len_flm_entry: + value: 36 + +types: + flm_entry: + seq: + - id: guid + size: 16 + - id: data_type + type: u2 + - id: entry_type + type: u2 + - id: physical_address + type: u8 + - id: size + type: u4 + - id: offset + type: u4 + diff --git a/common/meparser.cpp b/common/meparser.cpp index 0309406..aea1ae0 100755 --- a/common/meparser.cpp +++ b/common/meparser.cpp @@ -375,7 +375,7 @@ USTATUS MeParser::parseIfwi16Region(const UByteArray & region, const UModelIndex partitions.push_back(partition); } // Add boot partitions - for (UINT8 i = 0 ; i < 4; i++) { + for (UINT8 i = 0 ; i < 5; i++) { if (ifwiHeader->BootPartition[i].Offset != 0 && ifwiHeader->BootPartition[i].Offset != 0xFFFFFFFF) { IFWI_PARTITION_INFO partition = {}; partition.type = Types::IfwiPartition; @@ -551,7 +551,7 @@ USTATUS MeParser::parseIfwi17Region(const UByteArray & region, const UModelIndex partitions.push_back(partition); } // Add boot partitions - for (UINT8 i = 0 ; i < 4; i++) { + for (UINT8 i = 0 ; i < 5; i++) { if (ifwiHeader->BootPartition[i].Offset != 0 && ifwiHeader->BootPartition[i].Offset != 0xFFFFFFFF) { IFWI_PARTITION_INFO partition = {}; partition.type = Types::IfwiPartition; @@ -671,8 +671,15 @@ make_partition_table_consistent: } else if (partitions[i].subtype == Subtypes::BootIfwiPartition) { // Parse code partition contents - UModelIndex bootPartitionBpdtRegionIndex; - ffsParser->parseBpdtRegion(partition, 0, 0, partitionIndex, bootPartitionBpdtRegionIndex); + UModelIndex bootPartitionRegionIndex; + if (*(UINT32*)partition.constData() == FPT_HEADER_SIGNATURE) { + // Parse as FptRegion + parseFptRegion(partition, partitionIndex, bootPartitionRegionIndex); + } + else { + // Parse as BpdtRegion + ffsParser->parseBpdtRegion(partition, 0, 0, partitionIndex, bootPartitionRegionIndex); + } } } else if (partitions[i].type == Types::Padding) { diff --git a/common/meson.build b/common/meson.build index 096b4de..7ca986d 100644 --- a/common/meson.build +++ b/common/meson.build @@ -33,6 +33,17 @@ uefitoolcommon = static_library('uefitoolcommon', 'utility.cpp', 'ustring.cpp', 'generated/ami_nvar.cpp', + 'generated/apple_sysf.cpp', + 'generated/dell_dvar.cpp', + 'generated/edk2_vss.cpp', + 'generated/edk2_vss2.cpp', + 'generated/edk2_ftw.cpp', + 'generated/insyde_fdc.cpp', + 'generated/insyde_fdm.cpp', + 'generated/ms_slic_marker.cpp', + 'generated/ms_slic_pubkey.cpp', + 'generated/phoenix_flm.cpp', + 'generated/phoenix_evsa.cpp', 'generated/intel_acbp_v1.cpp', 'generated/intel_acbp_v2.cpp', 'generated/intel_keym_v1.cpp', diff --git a/common/nvram.cpp b/common/nvram.cpp index 93bf7a9..dff01d1 100644 --- a/common/nvram.cpp +++ b/common/nvram.cpp @@ -17,6 +17,8 @@ // // GUIDs mentioned in by nvram.h // +extern const UByteArray ZERO_GUID // 00000000-0000-0000-0000-000000000000 +("\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00", 16); extern const UByteArray NVRAM_NVAR_STORE_FILE_GUID // CEF5B9A3-476D-497F-9FDC-E98143E0422C ("\xA3\xB9\xF5\xCE\x6D\x47\x7F\x49\x9F\xDC\xE9\x81\x43\xE0\x42\x2C", 16); extern const UByteArray NVRAM_NVAR_EXTERNAL_DEFAULTS_FILE_GUID // 9221315B-30BB-46B5-813E-1B1BF4712BD3 @@ -150,7 +152,7 @@ UString efiTimeToUString(const EFI_TIME & time) time.Nanosecond); } -UString flashMapGuidToUString(const EFI_GUID & guid) +UString phoenixFlashMapGuidToUString(const EFI_GUID & guid) { const UByteArray baGuid((const char*)&guid, sizeof(EFI_GUID)); if (baGuid == NVRAM_PHOENIX_FLASH_MAP_VOLUME_HEADER) return UString("Volume header"); @@ -168,6 +170,7 @@ UString flashMapGuidToUString(const EFI_GUID & guid) || baGuid == NVRAM_PHOENIX_FLASH_MAP_EVSA6_GUID || baGuid == NVRAM_PHOENIX_FLASH_MAP_EVSA7_GUID) return UString("EVSA store"); if (baGuid == NVRAM_PHOENIX_FLASH_MAP_SELF_GUID) return UString("Flash map"); + if (baGuid == ZERO_GUID) return UString(); return UString("Unknown"); } diff --git a/common/nvram.h b/common/nvram.h index 0ab72b1..aadc20a 100755 --- a/common/nvram.h +++ b/common/nvram.h @@ -16,6 +16,7 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #define NVRAM_H #include "basetypes.h" +#include "ffs.h" #include "ubytearray.h" #include "ustring.h" @@ -69,9 +70,6 @@ extern const UByteArray NVRAM_ADDITIONAL_STORE_VOLUME_GUID; // 00504624-8A59-4EE #define NVRAM_VSS_STORE_SIGNATURE 0x53535624 // $VSS #define NVRAM_APPLE_SVS_STORE_SIGNATURE 0x53565324 // $SVS #define NVRAM_APPLE_NSS_STORE_SIGNATURE 0x53534E24 // $NSS -#define NVRAM_APPLE_FSYS_STORE_SIGNATURE 0x73797346 // Fsys -#define NVRAM_APPLE_GAID_STORE_SIGNATURE 0x64696147 // Gaid -#define NVRAM_VSS_VARIABLE_START_ID 0x55AA // Variable store header flags #define NVRAM_VSS_VARIABLE_STORE_FORMATTED 0x5a @@ -85,12 +83,12 @@ extern const UByteArray NVRAM_ADDITIONAL_STORE_VOLUME_GUID; // 00504624-8A59-4EE // Variable store header typedef struct VSS_VARIABLE_STORE_HEADER_ { - UINT32 Signature; // $VSS signature - UINT32 Size; // Size of variable store, including store header - UINT8 Format; // Store format state - UINT8 State; // Store health state - UINT16 Unknown; // Used in Apple $SVS varstores - UINT32 : 32; + UINT32 Signature; // Signature + UINT32 Size; // Size of variable store, including store header + UINT8 Format; // Store format state + UINT8 State; // Store health state + UINT16 Reserved; // Used in Apple $SVS varstores + UINT32 Reserved1; // Reserved } VSS_VARIABLE_STORE_HEADER; // Normal variable header @@ -141,12 +139,12 @@ typedef struct VSS_AUTH_VARIABLE_HEADER_ { } VSS_AUTH_VARIABLE_HEADER; // VSS variable states -#define NVRAM_VSS_VARIABLE_IN_DELETED_TRANSITION 0xfe // Variable is in obsolete transistion -#define NVRAM_VSS_VARIABLE_DELETED 0xfd // Variable is obsolete -#define NVRAM_VSS_VARIABLE_HEADER_VALID 0x7f // Variable has valid header -#define NVRAM_VSS_VARIABLE_ADDED 0x3f // Variable has been completely added -#define NVRAM_VSS_INTEL_VARIABLE_VALID 0xfc // Intel special variable valid -#define NVRAM_VSS_INTEL_VARIABLE_INVALID 0xf8 // Intel special variable invalid +#define NVRAM_VSS_VARIABLE_IN_DELETED_TRANSITION 0xfe // Variable is in obsolete transistion +#define NVRAM_VSS_VARIABLE_DELETED 0xfd // Variable is obsolete +#define NVRAM_VSS_VARIABLE_HEADER_VALID 0x7f // Variable has valid header +#define NVRAM_VSS_VARIABLE_ADDED 0x3f // Variable has been completely added +#define NVRAM_VSS_INTEL_VARIABLE_VALID 0xfc // Intel special variable valid +#define NVRAM_VSS_INTEL_VARIABLE_INVALID 0xf8 // Intel special variable invalid // VSS variable attributes #define NVRAM_VSS_VARIABLE_NON_VOLATILE 0x00000001 @@ -164,12 +162,8 @@ extern UString vssAttributesToUString(const UINT32 attributes); // // VSS2 variables // -#define NVRAM_VSS2_AUTH_VAR_KEY_DATABASE_GUID_PART1 0xaaf32c78 extern const UByteArray NVRAM_VSS2_AUTH_VAR_KEY_DATABASE_GUID; // AAF32C78-947B-439A-A180-2E144EC37792 - -#define NVRAM_VSS2_STORE_GUID_PART1 0xddcf3617 extern const UByteArray NVRAM_VSS2_STORE_GUID; // DDCF3617-3275-4164-98B6-FE85707FFE7D - extern const UByteArray NVRAM_FDC_STORE_GUID; // DDCF3616-3275-4164-98B6-FE85707FFE7D // Variable store header @@ -178,39 +172,34 @@ typedef struct VSS2_VARIABLE_STORE_HEADER_ { UINT32 Size; // Size of variable store, including store header UINT8 Format; // Store format state UINT8 State; // Store health state - UINT16 Unknown; - UINT32 : 32; + UINT16 Reserved; + UINT32 Reserved1; } VSS2_VARIABLE_STORE_HEADER; // VSS2 entries are 4-bytes aligned in VSS2 stores // -// _FDC region +// Insyde Factory Data Copy store // +#define INSYDE_FDC_STORE_SIGNATURE 0x4344465F -#define NVRAM_FDC_VOLUME_SIGNATURE 0x4344465F - -typedef struct FDC_VOLUME_HEADER_ { +typedef struct INSYDE_FDC_STORE_HEADER_ { UINT32 Signature; //_FDC signature UINT32 Size; // Size of the whole region - //EFI_FIRMWARE_VOLUME_HEADER VolumeHeader; - //EFI_FV_BLOCK_MAP_ENTRY FvBlockMap[2]; - //VSS_VARIABLE_STORE_HEADER VssHeader; -} FDC_VOLUME_HEADER; + EFI_FIRMWARE_VOLUME_HEADER VolumeHeader; + EFI_FV_BLOCK_MAP_ENTRY FvBlockMap[2]; +} INSYDE_FDC_STORE_HEADER; // // FTW block // #define EFI_FAULT_TOLERANT_WORKING_BLOCK_VALID 0x1 #define EFI_FAULT_TOLERANT_WORKING_BLOCK_INVALID 0x2 -extern const UByteArray EDKII_WORKING_BLOCK_SIGNATURE_GUID; // 9E58292B-7C68-497D-0ACE6500FD9F1B95 -extern const UByteArray VSS2_WORKING_BLOCK_SIGNATURE_GUID; // 9E58292B-7C68-497D-A0CE6500FD9F1B95 - -#define NVRAM_MAIN_STORE_VOLUME_GUID_DATA1 0xFFF12B8D -#define EDKII_WORKING_BLOCK_SIGNATURE_GUID_DATA1 0x9E58292B +extern const UByteArray EDKII_WORKING_BLOCK_SIGNATURE_GUID; // 9E58292B-7C68-497D-0ACE-6500FD9F1B95 +extern const UByteArray VSS2_WORKING_BLOCK_SIGNATURE_GUID; // 9E58292B-7C68-497D-A0CE-6500FD9F1B95 typedef struct EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32_ { - EFI_GUID Signature; // NVRAM_MAIN_STORE_VOLUME_GUID + EFI_GUID Signature; UINT32 Crc; // Crc32 of the header with empty Crc and State fields UINT8 State; UINT8 Reserved[3]; @@ -219,7 +208,7 @@ typedef struct EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32_ { } EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32; typedef struct EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64_ { - EFI_GUID Signature; // NVRAM_MAIN_STORE_VOLUME_GUID or EDKII_WORKING_BLOCK_SIGNATURE_GUID + EFI_GUID Signature; UINT32 Crc; // Crc32 of the header with empty Crc and State fields UINT8 State; UINT8 Reserved[3]; @@ -228,17 +217,18 @@ typedef struct EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64_ { } EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64; // -// Apple Fsys store +// Apple System Flags store // - -typedef struct APPLE_FSYS_STORE_HEADER_ { +#define NVRAM_APPLE_SYSF_STORE_SIGNATURE 0x73797346 // Fsys +#define NVRAM_APPLE_DIAG_STORE_SIGNATURE 0x64696147 // Gaid +typedef struct APPLE_SYSF_STORE_HEADER_ { UINT32 Signature; // Fsys or Gaid signature - UINT8 Unknown0; // Still unknown + UINT8 Unknown; // Still unknown UINT32 Unknown1; // Still unknown UINT16 Size; // Size of variable store -} APPLE_FSYS_STORE_HEADER; +} APPLE_SYSF_STORE_HEADER; -// Apple Fsys entry format +// Apple SysF entry format // UINT8 NameLength; // CHAR8 Name[]; // UINT16 DataLength; @@ -273,7 +263,7 @@ typedef struct EVSA_STORE_ENTRY_ { UINT32 Signature; // EVSA signature UINT32 Attributes; UINT32 StoreSize; - UINT32 : 32; + UINT32 Reserved; } EVSA_STORE_ENTRY; typedef struct EVSA_GUID_ENTRY_ { @@ -321,17 +311,13 @@ extern UString evsaAttributesToUString(const UINT32 attributes); // // Phoenix SCT Flash Map // - -#define NVRAM_PHOENIX_FLASH_MAP_SIGNATURE_PART1 0x414C465F #define NVRAM_PHOENIX_FLASH_MAP_SIGNATURE_LENGTH 10 - -// _FLASH_MAP -extern const UByteArray NVRAM_PHOENIX_FLASH_MAP_SIGNATURE; +extern const UByteArray NVRAM_PHOENIX_FLASH_MAP_SIGNATURE; // _FLASH_MAP typedef struct PHOENIX_FLASH_MAP_HEADER_ { UINT8 Signature[10]; // _FLASH_MAP signature UINT16 NumEntries; // Number of entries in the map - UINT32 : 32; // Reserved field + UINT32 Reserved; // Reserved field } PHOENIX_FLASH_MAP_HEADER; typedef struct PHOENIX_FLASH_MAP_ENTRY_ { @@ -342,11 +328,12 @@ typedef struct PHOENIX_FLASH_MAP_ENTRY_ { UINT32 Size; UINT32 Offset; } PHOENIX_FLASH_MAP_ENTRY; +#define NVRAM_PHOENIX_FLASH_MAP_TOTAL_SIZE 0x1000 +#define NVRAM_PHOENIX_FLASH_MAP_MAX_ENTRIES 113 +#define NVRAM_PHOENIX_FLASH_MAP_ENTRY_DATA_TYPE_VOLUME 0x0000 +#define NVRAM_PHOENIX_FLASH_MAP_ENTRY_DATA_TYPE_DATA_BLOCK 0x0001 -#define NVRAM_PHOENIX_FLASH_MAP_ENTRY_TYPE_VOLUME 0x0000 -#define NVRAM_PHOENIX_FLASH_MAP_ENTRY_TYPE_DATA_BLOCK 0x0001 - -extern UString flashMapGuidToUString(const EFI_GUID & guid); +extern UString phoenixFlashMapGuidToUString(const EFI_GUID & guid); extern const UByteArray NVRAM_PHOENIX_FLASH_MAP_VOLUME_HEADER; // B091E7D2-05A0-4198-94F0-74B7B8C55459 extern const UByteArray NVRAM_PHOENIX_FLASH_MAP_MICROCODES_GUID; // FD3F690E-B4B0-4D68-89DB-19A1A3318F90 @@ -395,10 +382,9 @@ typedef struct OEM_ACTIVATION_MARKER_ { UINT8 Signature[128]; } OEM_ACTIVATION_MARKER; -#define OEM_ACTIVATION_MARKER_TYPE 0x00000001 -#define OEM_ACTIVATION_MARKER_WINDOWS_FLAG_PART1 0x444E4957 -#define OEM_ACTIVATION_MARKER_WINDOWS_FLAG 0x2053574F444E4957UL -#define OEM_ACTIVATION_MARKER_RESERVED_BYTE 0x00 +#define OEM_ACTIVATION_MARKER_TYPE 0x00000001 +#define OEM_ACTIVATION_MARKER_WINDOWS_FLAG 0x2053574F444E4957UL // WINDOWS +#define OEM_ACTIVATION_MARKER_RESERVED_BYTE 0x00 // // Phoenix CMDB, no londer used, requires no parsing @@ -413,7 +399,10 @@ typedef struct PHOENIX_CMDB_HEADER_ { } PHOENIX_CMDB_HEADER; #define NVRAM_PHOENIX_CMDB_HEADER_SIGNATURE 0x42444D43 -#define NVRAM_PHOENIX_CMDB_SIZE 0x100; +#define NVRAM_PHOENIX_CMDB_SIZE 0x100 + +// Zero GUID +extern const UByteArray ZERO_GUID; // Restore previous packing rules #pragma pack(pop) diff --git a/common/nvramparser.cpp b/common/nvramparser.cpp old mode 100755 new mode 100644 index 68b7454..765c289 --- a/common/nvramparser.cpp +++ b/common/nvramparser.cpp @@ -26,6 +26,19 @@ #include "umemstream.h" #include "kaitai/kaitaistream.h" #include "generated/ami_nvar.h" +#include "generated/apple_sysf.h" +#include "generated/edk2_vss.h" +#include "generated/edk2_vss2.h" +#include "generated/edk2_ftw.h" +#include "generated/insyde_fdc.h" +#include "generated/ms_slic_pubkey.h" +#include "generated/ms_slic_marker.h" +#include "generated/phoenix_flm.h" +#include "generated/phoenix_evsa.h" + +#ifndef MIN +#define MIN(x, y) (((x) < (y)) ? (x) : (y)) +#endif USTATUS NvramParser::parseNvarStore(const UModelIndex & index) { @@ -39,6 +52,14 @@ USTATUS NvramParser::parseNvarStore(const UModelIndex & index) if (nvar.isEmpty()) return U_SUCCESS; + // Obtain required fields from parsing data + UINT8 emptyByte = 0xFF; + if (model->hasEmptyParsingData(index) == false) { + UByteArray data = model->parsingData(index); + const VOLUME_PARSING_DATA* pdata = (const VOLUME_PARSING_DATA*)data.constData(); + emptyByte = pdata->emptyByte; + } + try { const UINT32 localOffset = (UINT32)model->header(index).size(); umemstream is(nvar.constData(), nvar.size()); @@ -68,7 +89,7 @@ USTATUS NvramParser::parseNvarStore(const UModelIndex & index) // Get info UString info = usprintf("Full size: %Xh (%u)", (UINT32)padding.size(), (UINT32)padding.size()); - if ((UINT32)padding.count(0xFF) == unparsedSize) { // Free space + if ((UINT32)padding.count(emptyByte) == unparsedSize) { // Free space // Add tree item model->addItem(localOffset + entry->offset(), Types::FreeSpace, 0, UString("Free space"), UString(), info, UByteArray(), padding, UByteArray(), Fixed, index); } @@ -101,7 +122,7 @@ USTATUS NvramParser::parseNvarStore(const UModelIndex & index) // Set default next to predefined last value NVAR_ENTRY_PARSING_DATA pdata = {}; - pdata.emptyByte = 0xFF; + pdata.emptyByte = emptyByte; pdata.next = 0xFFFFFF; pdata.isValid = TRUE; @@ -274,14 +295,13 @@ processing_done: } } catch (...) { - msg(usprintf("%s: unable to parse AMI NVAR storage", __FUNCTION__), index); return U_INVALID_STORE; } return U_SUCCESS; } -USTATUS NvramParser::parseNvramVolumeBody(const UModelIndex & index) +USTATUS NvramParser::parseNvramVolumeBody(const UModelIndex & index,const UINT32 fdcStoreSizeOverride) { // Sanity check if (!index.isValid()) @@ -296,1548 +316,1226 @@ USTATUS NvramParser::parseNvramVolumeBody(const UModelIndex & index) } // Get local offset - UINT32 localOffset = (UINT32)model->header(index).size(); + const UINT32 localOffset = (UINT32)model->header(index).size(); // Get item data - UByteArray data = model->body(index); - - // Search for first store - USTATUS result; - UINT32 prevStoreOffset; - result = findNextStore(index, data, localOffset, 0, prevStoreOffset); - if (result) - return result; - - // First store is not at the beginning of volume body - UString name; - UString info; - if (prevStoreOffset > 0) { - // Get info - UByteArray padding = data.left(prevStoreOffset); - name = UString("Padding"); - info = usprintf("Full size: %Xh (%u)", (UINT32)padding.size(), (UINT32)padding.size()); - - // Add tree item - model->addItem(localOffset, Types::Padding, getPaddingType(padding), name, UString(), info, UByteArray(), padding, UByteArray(), Fixed, index); - } - - // Search for and parse all stores - UINT32 storeOffset = prevStoreOffset; - UINT32 prevStoreSize = 0; - - while (!result) { - // Padding between stores - if (storeOffset > prevStoreOffset + prevStoreSize) { - UINT32 paddingOffset = prevStoreOffset + prevStoreSize; - UINT32 paddingSize = storeOffset - paddingOffset; - UByteArray padding = data.mid(paddingOffset, paddingSize); - - // Get info - name = UString("Padding"); - info = usprintf("Full size: %Xh (%u)", (UINT32)padding.size(), (UINT32)padding.size()); - - // Add tree item - model->addItem(localOffset + paddingOffset, Types::Padding, getPaddingType(padding), name, UString(), info, UByteArray(), padding, UByteArray(), Fixed, index); - } - - // Get store size - UINT32 storeSize = 0; - result = getStoreSize(data, storeOffset, storeSize); - if (result) { - msg(usprintf("%s: getStoreSize failed with error ", __FUNCTION__) + errorCodeToUString(result), index); - return result; - } - - // Check that current store is fully present in input - if (storeSize > (UINT32)data.size() || storeOffset + storeSize > (UINT32)data.size()) { - // Mark the rest as padding and finish parsing - UByteArray padding = data.mid(storeOffset); - - // Get info - name = UString("Padding"); - info = usprintf("Full size: %Xh (%u)", (UINT32)padding.size(), (UINT32)padding.size()); - - // Add tree item - UModelIndex paddingIndex = model->addItem(localOffset + storeOffset, Types::Padding, getPaddingType(padding), name, UString(), info, UByteArray(), padding, UByteArray(), Fixed, index); - msg(usprintf("%s: one of stores inside overlaps the end of data", __FUNCTION__), paddingIndex); - - // Update variables - prevStoreOffset = storeOffset; - prevStoreSize = (UINT32)padding.size(); - break; - } - - // Parse current store header - UModelIndex storeIndex; - UByteArray store = data.mid(storeOffset, storeSize); - result = parseStoreHeader(store, localOffset + storeOffset, index, storeIndex); - if (result) - msg(usprintf("%s: store header parsing failed with error ", __FUNCTION__) + errorCodeToUString(result), index); - - // Go to next store - prevStoreOffset = storeOffset; - prevStoreSize = storeSize; - result = findNextStore(index, data, localOffset, storeOffset + prevStoreSize, storeOffset); - } - - // Padding/free space at the end - storeOffset = prevStoreOffset + prevStoreSize; - if ((UINT32)data.size() > storeOffset) { - UByteArray padding = data.mid(storeOffset); - // Add info - info = usprintf("Full size: %Xh (%u)", (UINT32)padding.size(), (UINT32)padding.size()); - - if (padding.count(emptyByte) == padding.size()) { // Free space - // Add tree item - model->addItem(localOffset + storeOffset, Types::FreeSpace, 0, UString("Free space"), UString(), info, UByteArray(), padding, UByteArray(), Fixed, index); - } - else { - // Nothing is parsed yet, but the file is not empty - if (!storeOffset) { - msg(usprintf("%s: can't be parsed as NVRAM volume", __FUNCTION__), index); - return U_SUCCESS; - } - - // Add tree item - model->addItem(localOffset + storeOffset, Types::Padding, getPaddingType(padding), UString("Padding"), UString(), info, UByteArray(), padding, UByteArray(), Fixed, index); - } - } - - // Parse bodies - for (int i = 0; i < model->rowCount(index); i++) { - UModelIndex current = index.model()->index(i, 0, index); - - switch (model->type(current)) { - case Types::FdcStore: - parseFdcStoreBody(current); - break; - case Types::VssStore: - parseVssStoreBody(current, 0); - break; - case Types::Vss2Store: - parseVssStoreBody(current, 4); - break; - case Types::FsysStore: - parseFsysStoreBody(current); - break; - case Types::EvsaStore: - parseEvsaStoreBody(current); - break; - case Types::FlashMapStore: - parseFlashMapBody(current); - break; - default: - // Ignore unknown! - break; - } - } - - return U_SUCCESS; -} + UByteArray volumeBody = model->body(index); + const UINT32 volumeBodySize = (UINT32)volumeBody.size(); -USTATUS NvramParser::findNextStore(const UModelIndex & index, const UByteArray & volume, const UINT32 localOffset, const UINT32 storeOffset, UINT32 & nextStoreOffset) -{ - UINT32 dataSize = (UINT32)volume.size(); - - if (dataSize < sizeof(UINT32)) - return U_STORES_NOT_FOUND; - - // TODO: add checks for restSize - // TODO: remove misaligned access by doing the signature checks differently, the current way is UB is C++ - // TODO: rewrite this all as Kaitai-based parser - UINT32 offset = storeOffset; - for (; offset < dataSize - sizeof(UINT32); offset++) { - const UINT32* currentPos = (const UINT32*)(volume.constData() + offset); - if (readUnaligned(currentPos) == NVRAM_VSS_STORE_SIGNATURE - || readUnaligned(currentPos) == NVRAM_APPLE_SVS_STORE_SIGNATURE - || readUnaligned(currentPos) == NVRAM_APPLE_NSS_STORE_SIGNATURE) { // $VSS, $SVS or $NSS signatures found, perform checks - const VSS_VARIABLE_STORE_HEADER* vssHeader = (const VSS_VARIABLE_STORE_HEADER*)currentPos; - if (vssHeader->Format != NVRAM_VSS_VARIABLE_STORE_FORMATTED) { - msg(usprintf("%s: VSS store candidate at offset %Xh skipped, has invalid format %02Xh", __FUNCTION__, localOffset + offset, vssHeader->Format), index); - continue; - } - if (vssHeader->Size == 0 || vssHeader->Size == 0xFFFFFFFF) { - msg(usprintf("%s: VSS store candidate at offset %Xh skipped, has invalid size %Xh", __FUNCTION__, localOffset + offset, vssHeader->Size), index); - continue; - } - // All checks passed, store found - break; - } - else if (readUnaligned(currentPos) == NVRAM_VSS2_AUTH_VAR_KEY_DATABASE_GUID_PART1 - || readUnaligned(currentPos) == NVRAM_VSS2_STORE_GUID_PART1) { // VSS2 store signatures found, perform checks - UByteArray guid = UByteArray(volume.constData() + offset, sizeof(EFI_GUID)); - if (guid != NVRAM_VSS2_AUTH_VAR_KEY_DATABASE_GUID && guid != NVRAM_VSS2_STORE_GUID) // Check the whole signature - continue; - - const VSS2_VARIABLE_STORE_HEADER* vssHeader = (const VSS2_VARIABLE_STORE_HEADER*)currentPos; - if (vssHeader->Format != NVRAM_VSS_VARIABLE_STORE_FORMATTED) { - msg(usprintf("%s: VSS2 store candidate at offset %Xh skipped, has invalid format %02Xh", __FUNCTION__, localOffset + offset, vssHeader->Format), index); - continue; - } - if (vssHeader->Size == 0 || vssHeader->Size == 0xFFFFFFFF) { - msg(usprintf("%s: VSS2 store candidate at offset %Xh skipped, has invalid size %Xh", __FUNCTION__, localOffset + offset, vssHeader->Size), index); - continue; - } - // All checks passed, store found - break; - } - else if (readUnaligned(currentPos) == NVRAM_FDC_VOLUME_SIGNATURE) { // FDC signature found - const FDC_VOLUME_HEADER* fdcHeader = (const FDC_VOLUME_HEADER*)currentPos; - if (fdcHeader->Size == 0 || fdcHeader->Size == 0xFFFFFFFF) { - msg(usprintf("%s: FDC store candidate at offset %Xh skipped, has invalid size %Xh", __FUNCTION__, localOffset + offset, fdcHeader->Size), index); - continue; - } - // All checks passed, store found - break; - } - else if (readUnaligned(currentPos) == NVRAM_APPLE_FSYS_STORE_SIGNATURE - || readUnaligned(currentPos) == NVRAM_APPLE_GAID_STORE_SIGNATURE) { // Fsys or Gaid signature found - const APPLE_FSYS_STORE_HEADER* fsysHeader = (const APPLE_FSYS_STORE_HEADER*)currentPos; - if (fsysHeader->Size == 0 || fsysHeader->Size == 0xFFFF) { - msg(usprintf("%s: Fsys store candidate at offset %Xh skipped, has invalid size %Xh", __FUNCTION__, localOffset + offset, fsysHeader->Size), index); - continue; - } - // All checks passed, store found - break; - } - else if (readUnaligned(currentPos) == NVRAM_EVSA_STORE_SIGNATURE) { //EVSA signature found - if (offset < sizeof(UINT32)) - continue; - - const EVSA_STORE_ENTRY* evsaHeader = (const EVSA_STORE_ENTRY*)(currentPos - 1); - if (evsaHeader->Header.Type != NVRAM_EVSA_ENTRY_TYPE_STORE) { - msg(usprintf("%s: EVSA store candidate at offset %Xh skipped, has invalid type %02Xh", __FUNCTION__, localOffset + offset - 4, evsaHeader->Header.Type), index); - continue; - } - if (evsaHeader->StoreSize == 0 || evsaHeader->StoreSize == 0xFFFFFFFF) { - msg(usprintf("%s: EVSA store candidate at offset %Xh skipped, has invalid size %Xh", __FUNCTION__, localOffset + offset, evsaHeader->StoreSize), index); - continue; - } - // All checks passed, store found - offset -= sizeof(UINT32); - break; - } - else if (readUnaligned(currentPos) == NVRAM_MAIN_STORE_VOLUME_GUID_DATA1 - || readUnaligned(currentPos) == EDKII_WORKING_BLOCK_SIGNATURE_GUID_DATA1) { // Possible FTW block signature found - UByteArray guid = UByteArray(volume.constData() + offset, sizeof(EFI_GUID)); - if (guid != NVRAM_MAIN_STORE_VOLUME_GUID && guid != EDKII_WORKING_BLOCK_SIGNATURE_GUID && guid != VSS2_WORKING_BLOCK_SIGNATURE_GUID) // Check the whole signature - continue; - - // Detect header variant based on WriteQueueSize - const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32* ftwHeader = (const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32*)currentPos; - if (ftwHeader->WriteQueueSize % 0x10 == 0x04) { // Header with 32 bit WriteQueueSize - if (ftwHeader->WriteQueueSize == 0 || ftwHeader->WriteQueueSize == 0xFFFFFFFF) { - msg(usprintf("%s: FTW block candidate at offset %Xh skipped, has invalid body size %Xh", __FUNCTION__, localOffset + offset, ftwHeader->WriteQueueSize), index); - continue; - } - } - else if (ftwHeader->WriteQueueSize % 0x10 == 0x00) { // Header with 64 bit WriteQueueSize - const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64* ftw64Header = (const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64*)currentPos; - if (ftw64Header->WriteQueueSize == 0 || ftw64Header->WriteQueueSize >= 0xFFFFFFFF) { - msg(usprintf("%s: FTW block candidate at offset %Xh skipped, has invalid body size %" PRIX64 "h", __FUNCTION__, localOffset + offset, ftw64Header->WriteQueueSize), index); - continue; - } - } - else // Unknown header - continue; - - // All checks passed, store found - break; - } - else if (readUnaligned(currentPos) == NVRAM_PHOENIX_FLASH_MAP_SIGNATURE_PART1) {// Phoenix SCT flash map - UByteArray signature = UByteArray(volume.constData() + offset, NVRAM_PHOENIX_FLASH_MAP_SIGNATURE_LENGTH); - if (signature != NVRAM_PHOENIX_FLASH_MAP_SIGNATURE) // Check the whole signature - continue; - - // All checks passed, store found - break; - } - else if (readUnaligned(currentPos) == NVRAM_PHOENIX_CMDB_HEADER_SIGNATURE) { // Phoenix SCT CMDB store - const PHOENIX_CMDB_HEADER* cmdbHeader = (const PHOENIX_CMDB_HEADER*)currentPos; - - // Check size - if (cmdbHeader->HeaderSize != sizeof(PHOENIX_CMDB_HEADER)) - continue; - - // All checks passed, store found - break; - } - else if (readUnaligned(currentPos) == INTEL_MICROCODE_HEADER_VERSION_1) {// Intel microcode - const INTEL_MICROCODE_HEADER* ucodeHeader = (const INTEL_MICROCODE_HEADER*)currentPos; - - // TotalSize is greater then DataSize and is multiple of 1024 - if (FALSE == ffsParser->microcodeHeaderValid(ucodeHeader)) { - continue; + // Iterate over all bytes inside the volume body, trying to parse every next byte offset by one of the known parsers + UByteArray outerPadding; + UINT32 previousStoreEndOffset = 0; + for (UINT32 storeOffset = 0; + storeOffset < volumeBodySize; + storeOffset++) { + UString name, text, info; + UByteArray header, body; + + // VSS + try { + if (volumeBodySize - storeOffset < sizeof(VSS_VARIABLE_STORE_HEADER)) { + // No need to parse further, the rest of the volume is too small + goto not_vss; } - // All checks passed, store found - break; - } - else if (readUnaligned(currentPos) == OEM_ACTIVATION_PUBKEY_MAGIC) { // SLIC pubkey - if (offset < 4 * sizeof(UINT32)) - continue; + // Perform initial sanity check + const VSS_VARIABLE_STORE_HEADER* storeHeader = (const VSS_VARIABLE_STORE_HEADER*)(volumeBody.constData() + storeOffset); + if ((storeHeader->Signature != NVRAM_VSS_STORE_SIGNATURE + && storeHeader->Signature != NVRAM_APPLE_SVS_STORE_SIGNATURE + && storeHeader->Signature != NVRAM_APPLE_NSS_STORE_SIGNATURE) + || storeHeader->Format != NVRAM_VSS_VARIABLE_STORE_FORMATTED) { + // No need to parse further, not a VSS store + goto not_vss; + } + UINT32 storeSize = MIN(volumeBodySize - storeOffset, storeHeader->Size); //TODO: consider this check to become hard bail as it was before - const OEM_ACTIVATION_PUBKEY* pubkeyHeader = (const OEM_ACTIVATION_PUBKEY*)(currentPos - 4); - // Check type - if (pubkeyHeader->Type != OEM_ACTIVATION_PUBKEY_TYPE) - continue; + // This copy is required for possible FDC workaround + UByteArray vss = volumeBody.mid(storeOffset, storeSize); - // All checks passed, store found - offset -= 4 * sizeof(UINT32); - break; - } - else if (readUnaligned(currentPos) == OEM_ACTIVATION_MARKER_WINDOWS_FLAG_PART1) { // SLIC marker - if (offset < 26 - || offset >= dataSize - sizeof(UINT64) - || *(const UINT64*)currentPos != OEM_ACTIVATION_MARKER_WINDOWS_FLAG) // Check full windows flag and structure size - continue; + // Check if we are here to parse a special case of FDC store with size override + UINT32 originalStoreSize = 0; + bool fdcHeaderSizeOverrideRequired = (fdcStoreSizeOverride > 0 && storeHeader->Signature == NVRAM_VSS_STORE_SIGNATURE && storeHeader->Size == 0xFFFFFFFF); + if (fdcHeaderSizeOverrideRequired) { + VSS_VARIABLE_STORE_HEADER* vssHeader = (VSS_VARIABLE_STORE_HEADER*)vss.data(); + originalStoreSize = vssHeader->Size; + vssHeader->Size = fdcStoreSizeOverride; + } - const OEM_ACTIVATION_MARKER* markerHeader = (const OEM_ACTIVATION_MARKER*)(volume.constData() + offset - 26); - // Check reserved bytes - bool reservedBytesValid = true; - for (UINT32 i = 0; i < sizeof(markerHeader->Reserved); i++) - if (markerHeader->Reserved[i] != OEM_ACTIVATION_MARKER_RESERVED_BYTE) { - reservedBytesValid = false; + // Try parsing VSS store candidate + umemstream is(vss.constData(), vss.size()); + kaitai::kstream ks(&is); + edk2_vss_t parsed(&ks); + + // Restore original store size, if needed + if (fdcHeaderSizeOverrideRequired) { + VSS_VARIABLE_STORE_HEADER* vssHeader = (VSS_VARIABLE_STORE_HEADER*)vss.data(); + vssHeader->Size = originalStoreSize; + } + + // VSS store at current offset parsed correctly + // Check if we need to add a padding before it + if (!outerPadding.isEmpty()) { + UString info = usprintf("Full size: %Xh (%u)", (UINT32)outerPadding.size(), (UINT32)outerPadding.size()); + model->addItem(localOffset + previousStoreEndOffset, Types::Padding, getPaddingType(outerPadding), UString("Padding"), UString(), info, UByteArray(), outerPadding, UByteArray(), Fixed, index); + outerPadding.clear(); + } + + // Construct header and body + header = vss.left(parsed.len_vss_store_header()); + body = vss.mid(header.size(), storeSize - header.size()); + + // Add info + if (parsed.signature() == NVRAM_APPLE_SVS_STORE_SIGNATURE) { + name = UString("Apple SVS store"); + } + else if (parsed.signature() == NVRAM_APPLE_NSS_STORE_SIGNATURE) { + name = UString("Apple NSS store"); + } + else { + name = UString("VSS store"); + } + + info = usprintf("Signature: %Xh (", parsed.signature()) + fourCC(parsed.signature()) + UString(")\n"); + info += usprintf("Full size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nFormat: %02Xh\nState: %02Xh\nReserved: %02Xh\nReserved1: %04Xh", + storeSize , storeSize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + parsed.format(), + parsed.state(), + parsed.reserved(), + parsed.reserved1()); + + // Add header tree item + UModelIndex headerIndex = model->addItem(localOffset + storeOffset, Types::VssStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, index); + + // Add variables + UINT32 entryOffset = parsed.len_vss_store_header(); + for (const auto & variable : *parsed.body()->variables()) { + UINT8 subtype; + + // This is the terminating entry, needs special processing + if (variable->_is_null_signature_last()) { + // Add free space or padding after all variables, if needed + if (entryOffset < storeSize) { + UByteArray freeSpace = vss.mid(entryOffset, storeSize - entryOffset); + // Add info + info = usprintf("Full size: %Xh (%u)", (UINT32)freeSpace.size(), (UINT32)freeSpace.size()); + + // Check that remaining unparsed bytes are actually empty + if (freeSpace.count(emptyByte) == freeSpace.size()) { // Free space + // Add tree item + model->addItem(entryOffset, Types::FreeSpace, 0, UString("Free space"), UString(), info, UByteArray(), freeSpace, UByteArray(), Fixed, headerIndex); + } + else { + // Add tree item + model->addItem(entryOffset, Types::Padding, getPaddingType(freeSpace), UString("Padding"), UString(), info, UByteArray(), freeSpace, UByteArray(), Fixed, headerIndex); + } + } break; } - if (!reservedBytesValid) - continue; + + // This is a normal entry + UINT32 variableSize; + if (variable->is_intel_legacy()) { // Intel legacy + subtype = Subtypes::IntelVssEntry; + // Needs some additional parsing of variable->intel_legacy_data to separate the name from the value + text = uFromUcs2(variable->intel_legacy_data().c_str()); + UINT32 textLengthInBytes = (UINT32)text.length()*2+2; + header = vss.mid(entryOffset, variable->len_intel_legacy_header() + textLengthInBytes); + body = vss.mid(entryOffset + header.size(), variable->len_total() - variable->len_intel_legacy_header() - textLengthInBytes); + variableSize = (UINT32)(header.size() + body.size()); + const EFI_GUID variableGuid = readUnaligned((const EFI_GUID*)(variable->vendor_guid().c_str())); + name = guidToUString(variableGuid); + info = UString("Variable GUID: ") + guidToUString(variableGuid, false) + "\n"; + } + else if (variable->is_auth()) { // Authenticated + subtype = Subtypes::AuthVssEntry; + header = vss.mid(entryOffset, variable->len_auth_header() + variable->len_name_auth()); + body = vss.mid(entryOffset + header.size(), variable->len_data_auth()); + variableSize = (UINT32)(header.size() + body.size()); + const EFI_GUID variableGuid = readUnaligned((const EFI_GUID*)(variable->vendor_guid().c_str())); + name = guidToUString(variableGuid); + text = uFromUcs2(variable->name_auth().c_str()); + info = UString("Variable GUID: ") + guidToUString(variableGuid, false) + "\n"; + } + else if (!variable->_is_null_apple_data_crc32()) { // Apple CRC32 + subtype = Subtypes::AppleVssEntry; + header = vss.mid(entryOffset, variable->len_apple_header() + variable->len_name()); + body = vss.mid(entryOffset + header.size(), variable->len_data()); + variableSize = (UINT32)(header.size() + body.size()); + const EFI_GUID variableGuid = readUnaligned((const EFI_GUID*)(variable->vendor_guid().c_str())); + name = guidToUString(variableGuid); + text = uFromUcs2(variable->name().c_str()); + info = UString("Variable GUID: ") + guidToUString(variableGuid, false) + "\n"; + } + else { // Standard + subtype = Subtypes::StandardVssEntry; + header = vss.mid(entryOffset, variable->len_standard_header() + variable->len_name()); + body = vss.mid(entryOffset + header.size(), variable->len_data()); + variableSize = (UINT32)(header.size() + body.size()); + const EFI_GUID variableGuid = readUnaligned((const EFI_GUID*)(variable->vendor_guid().c_str())); + name = guidToUString(variableGuid); + text = uFromUcs2(variable->name().c_str()); + info = UString("Variable GUID: ") + guidToUString(variableGuid, false) + "\n"; + } + + // Override variable type to Invalid, if needed + if (!variable->is_valid()) { + subtype = Subtypes::InvalidVssEntry; + name = UString("Invalid"); + text.clear(); + } + + const UINT32 variableAttributes = variable->attributes()->non_volatile() + + (variable->attributes()->boot_service() << 1) + + (variable->attributes()->runtime() << 2) + + (variable->attributes()->hw_error_record() << 3) + + (variable->attributes()->auth_write() << 4) + + (variable->attributes()->time_based_auth() << 5) + + (variable->attributes()->append_write() << 6) + + (UINT32)(variable->attributes()->reserved() << 7) + + (UINT32)(variable->attributes()->apple_data_checksum() << 31); + + // Add generic info + info += usprintf("Full size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nState: %02Xh\nReserved: %02Xh\nAttributes: %08Xh (", + variableSize, variableSize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + variable->state(), + variable->reserved(), + variableAttributes) + vssAttributesToUString(variableAttributes) + UString(")"); + + // Add specific info + if (variable->is_auth()) { + UINT64 monotonicCounter = (UINT64)variable->len_name() + ((UINT64)variable->len_data() << 32); + info += usprintf("\nMonotonic counter: %" PRIX64 "h\nTimestamp: ", monotonicCounter) + efiTimeToUString(*(const EFI_TIME*)variable->timestamp().c_str()) + + usprintf("\nPubKey index: %u", variable->pubkey_index()); + } + else if (!variable->_is_null_apple_data_crc32()) { + // Calculate CRC32 of the variable data + UINT32 calculatedCrc32 = (UINT32)crc32(0, (const UINT8*)body.constData(), (uInt)body.size()); + + info += usprintf("\nData checksum: %08Xh", variable->apple_data_crc32()) + + (variable->apple_data_crc32() != calculatedCrc32 ? usprintf(", invalid, should be %08Xh", calculatedCrc32) : UString(", valid")); + } + + // Add tree item + model->addItem(entryOffset, Types::VssEntry, subtype, name, text, info, header, body, UByteArray(), Fixed, headerIndex); + + entryOffset += variableSize; + } - // All checks passed, store found - offset -= 26; - break; + storeOffset += storeSize - 1; + previousStoreEndOffset = storeOffset + 1; + continue; + } catch (...) { + // Parsing failed, try something else } - } - // No more stores found - if (offset >= dataSize - sizeof(UINT32)) - return U_STORES_NOT_FOUND; - - nextStoreOffset = offset; - - return U_SUCCESS; -} +not_vss: + // VSS2 + try { + if (volumeBodySize - storeOffset < sizeof(VSS2_VARIABLE_STORE_HEADER)) { + // No need to parse further, the rest of the volume is too small + goto not_vss2; + } + + // Perform initial sanity check + const VSS2_VARIABLE_STORE_HEADER* storeHeader = (const VSS2_VARIABLE_STORE_HEADER*)(volumeBody.constData() + storeOffset); + UByteArray guid = UByteArray((const char*)&storeHeader->Signature, sizeof(EFI_GUID)); + + if ((guid != NVRAM_VSS2_AUTH_VAR_KEY_DATABASE_GUID + && guid != NVRAM_VSS2_STORE_GUID + && guid != NVRAM_FDC_STORE_GUID) + || storeHeader->Format != NVRAM_VSS_VARIABLE_STORE_FORMATTED) { + // No need to parse further, not a VSS2 store + goto not_vss2; + } + UINT32 storeSize = MIN(volumeBodySize - storeOffset, storeHeader->Size); + + // This copy is required for possible FDC workaround + UByteArray vss2 = volumeBody.mid(storeOffset, storeSize); + + // Check if we are here to parse a special case of FDC store with size override + UINT32 originalStoreSize = 0; + bool fdcHeaderSizeOverrideRequired = (fdcStoreSizeOverride > 0 && guid == NVRAM_FDC_STORE_GUID && storeHeader->Size == 0xFFFFFFFF); + if (fdcHeaderSizeOverrideRequired) { + VSS2_VARIABLE_STORE_HEADER* vss2Header = (VSS2_VARIABLE_STORE_HEADER*)vss2.data(); + originalStoreSize = vss2Header->Size; + vss2Header->Size = fdcStoreSizeOverride; + } + + // Try parsing VSS store candidate + umemstream is(vss2.constData(), vss2.size()); + kaitai::kstream ks(&is); + edk2_vss2_t parsed(&ks); + + // Restore original store size, if needed + if (fdcHeaderSizeOverrideRequired) { + VSS2_VARIABLE_STORE_HEADER* vss2Header = (VSS2_VARIABLE_STORE_HEADER*)vss2.data(); + vss2Header->Size = originalStoreSize; + } + + // VSS2 store at current offset parsed correctly + // Check if we need to add a padding before it + if (!outerPadding.isEmpty()) { + info = usprintf("Full size: %Xh (%u)", (UINT32)outerPadding.size(), (UINT32)outerPadding.size()); + model->addItem(localOffset + previousStoreEndOffset, Types::Padding, getPaddingType(outerPadding), UString("Padding"), UString(), info, UByteArray(), outerPadding, UByteArray(), Fixed, index); + outerPadding.clear(); + } -USTATUS NvramParser::getStoreSize(const UByteArray & data, const UINT32 storeOffset, UINT32 & storeSize) -{ - const UINT32* signature = (const UINT32*)(data.constData() + storeOffset); - if (*signature == NVRAM_VSS_STORE_SIGNATURE || *signature == NVRAM_APPLE_SVS_STORE_SIGNATURE || *signature == NVRAM_APPLE_NSS_STORE_SIGNATURE) { - const VSS_VARIABLE_STORE_HEADER* vssHeader = (const VSS_VARIABLE_STORE_HEADER*)signature; - storeSize = vssHeader->Size; - } - else if (*signature == NVRAM_VSS2_AUTH_VAR_KEY_DATABASE_GUID_PART1 || *signature == NVRAM_VSS2_STORE_GUID_PART1) { - const VSS2_VARIABLE_STORE_HEADER* vssHeader = (const VSS2_VARIABLE_STORE_HEADER*)signature; - storeSize = vssHeader->Size; - } - else if (*signature == NVRAM_FDC_VOLUME_SIGNATURE) { - const FDC_VOLUME_HEADER* fdcHeader = (const FDC_VOLUME_HEADER*)signature; - storeSize = fdcHeader->Size; - } - else if (*signature == NVRAM_APPLE_FSYS_STORE_SIGNATURE || *signature == NVRAM_APPLE_GAID_STORE_SIGNATURE) { - const APPLE_FSYS_STORE_HEADER* fsysHeader = (const APPLE_FSYS_STORE_HEADER*)signature; - storeSize = fsysHeader->Size; - } - else if (*(signature + 1) == NVRAM_EVSA_STORE_SIGNATURE) { - const EVSA_STORE_ENTRY* evsaHeader = (const EVSA_STORE_ENTRY*)signature; - storeSize = evsaHeader->StoreSize; - } - else if (*signature == NVRAM_MAIN_STORE_VOLUME_GUID_DATA1 || *signature == EDKII_WORKING_BLOCK_SIGNATURE_GUID_DATA1) { - const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32* ftwHeader = (const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32*)signature; - if (ftwHeader->WriteQueueSize % 0x10 == 0x04) { // Header with 32 bit WriteQueueSize - storeSize = sizeof(EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32) + ftwHeader->WriteQueueSize; - } - else { // Header with 64 bit WriteQueueSize - const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64* ftw64Header = (const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64*)signature; - storeSize = sizeof(EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64) + (UINT32)ftw64Header->WriteQueueSize; - } - } - else if (*signature == NVRAM_PHOENIX_FLASH_MAP_SIGNATURE_PART1) { // Phoenix SCT flash map - const PHOENIX_FLASH_MAP_HEADER* flashMapHeader = (const PHOENIX_FLASH_MAP_HEADER*)signature; - storeSize = sizeof(PHOENIX_FLASH_MAP_HEADER) + sizeof(PHOENIX_FLASH_MAP_ENTRY) * flashMapHeader->NumEntries; - } - else if (*signature == NVRAM_PHOENIX_CMDB_HEADER_SIGNATURE) { // Phoenix SCT CMDB store - storeSize = NVRAM_PHOENIX_CMDB_SIZE; // It's a predefined max size, no need to calculate - } - else if (*(signature + 4) == OEM_ACTIVATION_PUBKEY_MAGIC) { // SLIC pubkey - const OEM_ACTIVATION_PUBKEY* pubkeyHeader = (const OEM_ACTIVATION_PUBKEY*)signature; - storeSize = pubkeyHeader->Size; - } - else if (*(const UINT64*)(data.constData() + storeOffset + 26) == OEM_ACTIVATION_MARKER_WINDOWS_FLAG) { // SLIC marker - const OEM_ACTIVATION_MARKER* markerHeader = (const OEM_ACTIVATION_MARKER*)signature; - storeSize = markerHeader->Size; - } - else if (*signature == INTEL_MICROCODE_HEADER_VERSION_1) { // Intel microcode, must be checked after SLIC marker because of the same *signature values - const INTEL_MICROCODE_HEADER* ucodeHeader = (const INTEL_MICROCODE_HEADER*)signature; - storeSize = ucodeHeader->TotalSize; - } else { - return U_INVALID_PARAMETER; // Unreachable - } - return U_SUCCESS; -} - -USTATUS NvramParser::parseVssStoreHeader(const UByteArray & store, const UINT32 localOffset, const bool sizeOverride, const UModelIndex & parent, UModelIndex & index) -{ - const UINT32 dataSize = (UINT32)store.size(); - - // Check store size - if (dataSize < sizeof(VSS_VARIABLE_STORE_HEADER)) { - msg(usprintf("%s: volume body is too small even for VSS store header", __FUNCTION__), parent); - return U_SUCCESS; - } - - // Get VSS store header - const VSS_VARIABLE_STORE_HEADER* vssStoreHeader = (const VSS_VARIABLE_STORE_HEADER*)store.constData(); - - // Check for size override - UINT32 storeSize = vssStoreHeader->Size; - if (sizeOverride) { - storeSize = dataSize; - } - - // Check store size - if (dataSize < storeSize) { - msg(usprintf("%s: VSS store size %Xh (%u) is greater than volume body size %Xh (%u)", __FUNCTION__, - storeSize, storeSize, - dataSize, dataSize), parent); - return U_SUCCESS; - } - - // Construct header and body - UByteArray header = store.left(sizeof(VSS_VARIABLE_STORE_HEADER)); - UByteArray body = store.mid(sizeof(VSS_VARIABLE_STORE_HEADER), storeSize - sizeof(VSS_VARIABLE_STORE_HEADER)); - - // Add info - UString name; - if (vssStoreHeader->Signature == NVRAM_APPLE_SVS_STORE_SIGNATURE) { - name = UString("SVS store"); - } - else if (vssStoreHeader->Signature == NVRAM_APPLE_NSS_STORE_SIGNATURE) { - name = UString("NSS store"); - } - else { - name = UString("VSS store"); - } - - UString info = usprintf("Signature: %Xh\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nFormat: %02Xh\nState: %02Xh\nUnknown: %04Xh", - vssStoreHeader->Signature, + // Construct header and body + header = vss2.left(parsed.len_vss2_store_header()); + body = vss2.mid(header.size(), storeSize - header.size()); + + // Add info + name = UString("VSS2 store"); + if (guid == NVRAM_VSS2_AUTH_VAR_KEY_DATABASE_GUID) { + info = UString("Signature: AAF32C78-947B-439A-A180-2E144EC37792\n"); + } + else if (guid == NVRAM_FDC_STORE_GUID) { + info = UString("Signature: DDCF3616-3275-4164-98B6-FE85707FFE7D\n"); + } + else { + info = UString("Signature: DDCF3617-3275-4164-98B6-FE85707FFE7D\n"); + } + + info += usprintf("Full size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nFormat: %02Xh\nState: %02Xh\nReserved: %02Xh\nReserved1: %04Xh", storeSize, storeSize, (UINT32)header.size(), (UINT32)header.size(), (UINT32)body.size(), (UINT32)body.size(), - vssStoreHeader->Format, - vssStoreHeader->State, - vssStoreHeader->Unknown); - - // Add tree item - index = model->addItem(localOffset, Types::VssStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, parent); - - return U_SUCCESS; -} - -USTATUS NvramParser::parseVss2StoreHeader(const UByteArray & store, const UINT32 localOffset, const bool sizeOverride, const UModelIndex & parent, UModelIndex & index) -{ - const UINT32 dataSize = (UINT32)store.size(); - - // Check store size - if (dataSize < sizeof(VSS2_VARIABLE_STORE_HEADER)) { - msg(usprintf("%s: volume body is too small even for VSS2 store header", __FUNCTION__), parent); - return U_SUCCESS; - } - - // Get VSS2 store header - const VSS2_VARIABLE_STORE_HEADER* vssStoreHeader = (const VSS2_VARIABLE_STORE_HEADER*)store.constData(); - - // Check for size override - UINT32 storeSize = vssStoreHeader->Size; - if (sizeOverride) { - storeSize = dataSize; - } - - // Check store size - if (dataSize < storeSize) { - msg(usprintf("%s: VSS2 store size %Xh (%u) is greater than volume body size %Xh (%u)", __FUNCTION__, - storeSize, storeSize, - dataSize, dataSize), parent); - return U_SUCCESS; - } - - // Construct header and body - UByteArray header = store.left(sizeof(VSS2_VARIABLE_STORE_HEADER)); - UByteArray body = store.mid(sizeof(VSS2_VARIABLE_STORE_HEADER), storeSize - sizeof(VSS2_VARIABLE_STORE_HEADER)); - - // Add info - UString name = UString("VSS2 store"); - UString info = UString("Signature: ") + guidToUString(vssStoreHeader->Signature, false) + - usprintf("\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nFormat: %02Xh\nState: %02Xh\nUnknown: %04Xh", - storeSize, storeSize, - (UINT32)header.size(), (UINT32)header.size(), - (UINT32)body.size(), (UINT32)body.size(), - vssStoreHeader->Format, - vssStoreHeader->State, - vssStoreHeader->Unknown); - - // Add tree item - index = model->addItem(localOffset, Types::Vss2Store, 0, name, UString(), info, header, body, UByteArray(), Fixed, parent); - - return U_SUCCESS; -} - -USTATUS NvramParser::parseFtwStoreHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index) -{ - const UINT32 dataSize = (UINT32)store.size(); - - // Check store size - if (dataSize < sizeof(EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64)) { - msg(usprintf("%s: volume body is too small even for FTW store header", __FUNCTION__), parent); - return U_SUCCESS; - } - - // Obtain required information from parent volume - UINT8 emptyByte = 0xFF; - UModelIndex parentVolumeIndex = model->findParentOfType(parent, Types::Volume); - if (parentVolumeIndex.isValid() && model->hasEmptyParsingData(parentVolumeIndex) == false) { - UByteArray data = model->parsingData(parentVolumeIndex); - const VOLUME_PARSING_DATA* pdata = (const VOLUME_PARSING_DATA*)data.constData(); - emptyByte = pdata->emptyByte; - } - - // Get FTW block headers - const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32* ftw32BlockHeader = (const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32*)store.constData(); - const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64* ftw64BlockHeader = (const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64*)store.constData(); - - // Check store size - UINT32 ftwBlockSize; - bool has32bitHeader; - if (ftw32BlockHeader->WriteQueueSize % 0x10 == 0x04) { // Header with 32 bit WriteQueueSize - ftwBlockSize = sizeof(EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32) + ftw32BlockHeader->WriteQueueSize; - has32bitHeader = true; - } - else { // Header with 64 bit WriteQueueSize - ftwBlockSize = sizeof(EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64) + (UINT32)ftw64BlockHeader->WriteQueueSize; - has32bitHeader = false; - } - if (dataSize < ftwBlockSize) { - msg(usprintf("%s: FTW store size %Xh (%u) is greater than volume body size %Xh (%u)", __FUNCTION__, - ftwBlockSize, ftwBlockSize, - dataSize, dataSize), parent); - return U_SUCCESS; - } - - // Construct header and body - UINT32 headerSize = has32bitHeader ? sizeof(EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32) : sizeof(EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64); - UByteArray header = store.left(headerSize); - UByteArray body = store.mid(headerSize, ftwBlockSize - headerSize); - - // Check block header checksum - UByteArray crcHeader = header; - EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32* crcFtwBlockHeader = (EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32*)header.data(); - crcFtwBlockHeader->Crc = emptyByte ? 0xFFFFFFFF : 0; - crcFtwBlockHeader->State = emptyByte ? 0xFF : 0; - UINT32 calculatedCrc = (UINT32)crc32(0, (const UINT8*)crcFtwBlockHeader, headerSize); - - // Add info - UString name("FTW store"); - UString info = UString("Signature: ") + guidToUString(ftw32BlockHeader->Signature, false) + - usprintf("\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nState: %02Xh\nHeader CRC32: %08Xh", - ftwBlockSize, ftwBlockSize, - headerSize, headerSize, - (UINT32)body.size(), (UINT32)body.size(), - ftw32BlockHeader->State, - ftw32BlockHeader->Crc) + - (ftw32BlockHeader->Crc != calculatedCrc ? usprintf(", invalid, should be %08Xh", calculatedCrc) : UString(", valid")); - - // Add tree item - index = model->addItem(localOffset, Types::FtwStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, parent); - - return U_SUCCESS; -} - -USTATUS NvramParser::parseFdcStoreHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index) -{ - const UINT32 dataSize = (UINT32)store.size(); - - // Check store size - if (dataSize < sizeof(FDC_VOLUME_HEADER)) { - msg(usprintf("%s: volume body is too small even for FDC store header", __FUNCTION__), parent); - return U_SUCCESS; - } - - // Get Fdc store header - const FDC_VOLUME_HEADER* fdcStoreHeader = (const FDC_VOLUME_HEADER*)store.constData(); - - // Check store size - if (dataSize < fdcStoreHeader->Size) { - msg(usprintf("%s: FDC store size %Xh (%u) is greater than volume body size %Xh (%u)", __FUNCTION__, - fdcStoreHeader->Size, fdcStoreHeader->Size, - dataSize, dataSize), parent); - return U_SUCCESS; - } - - // Construct header and body - UByteArray header = store.left(sizeof(FDC_VOLUME_HEADER)); - UByteArray body = store.mid(sizeof(FDC_VOLUME_HEADER), fdcStoreHeader->Size - sizeof(FDC_VOLUME_HEADER)); - - // Add info - UString name("FDC store"); - UString info = usprintf("Signature: _FDC\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)", - fdcStoreHeader->Size, fdcStoreHeader->Size, - (UINT32)header.size(), (UINT32)header.size(), - (UINT32)body.size(), (UINT32)body.size()); - - // Add tree item - index = model->addItem(localOffset, Types::FdcStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, parent); - - return U_SUCCESS; -} - -USTATUS NvramParser::parseFsysStoreHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index) -{ - const UINT32 dataSize = (UINT32)store.size(); - - // Check store size - if (dataSize < sizeof(APPLE_FSYS_STORE_HEADER)) { - msg(usprintf("%s: volume body is too small even for Fsys store header", __FUNCTION__), parent); - return U_SUCCESS; - } - - // Get Fsys store header - const APPLE_FSYS_STORE_HEADER* fsysStoreHeader = (const APPLE_FSYS_STORE_HEADER*)store.constData(); - - // Check store size - if (dataSize < fsysStoreHeader->Size) { - msg(usprintf("%s: Fsys store size %Xh (%u) is greater than volume body size %Xh (%u)", __FUNCTION__, - fsysStoreHeader->Size, fsysStoreHeader->Size, - dataSize, dataSize), parent); - return U_SUCCESS; - } - - // Construct header and body - UByteArray header = store.left(sizeof(APPLE_FSYS_STORE_HEADER)); - UByteArray body = store.mid(sizeof(APPLE_FSYS_STORE_HEADER), fsysStoreHeader->Size - sizeof(APPLE_FSYS_STORE_HEADER) - sizeof(UINT32)); - - // Check store checksum - UINT32 storedCrc = *(UINT32*)store.right(sizeof(UINT32)).constData(); - UINT32 calculatedCrc = (UINT32)crc32(0, (const UINT8*)store.constData(), (UINT32)store.size() - sizeof(UINT32)); - - // Add info - bool isGaidStore = (fsysStoreHeader->Signature == NVRAM_APPLE_GAID_STORE_SIGNATURE); - UString name = isGaidStore ? UString("Gaid store") : UString("Fsys store"); - UString info = usprintf("Signature: %s\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nUnknown0: %02Xh\nUnknown1: %08Xh\nCRC32: %08Xh", - isGaidStore ? "Gaid" : "Fsys", - fsysStoreHeader->Size, fsysStoreHeader->Size, - (UINT32)header.size(), (UINT32)header.size(), - (UINT32)body.size(), (UINT32)body.size(), - fsysStoreHeader->Unknown0, - fsysStoreHeader->Unknown1, - storedCrc) - + (storedCrc != calculatedCrc ? usprintf(", invalid, should be %08Xh", calculatedCrc) : UString(", valid")); - - // Add tree item - index = model->addItem(localOffset, Types::FsysStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, parent); - - return U_SUCCESS; -} - -USTATUS NvramParser::parseEvsaStoreHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index) -{ - const UINT32 dataSize = (UINT32)store.size(); - - // Check dataSize - if (dataSize < sizeof(EVSA_STORE_ENTRY)) { - msg(usprintf("%s: volume body is too small even for EVSA store header", __FUNCTION__), parent); - return U_SUCCESS; - } - - // Get EVSA store header - const EVSA_STORE_ENTRY* evsaStoreHeader = (const EVSA_STORE_ENTRY*)store.constData(); - - // Check store size - if (dataSize < evsaStoreHeader->StoreSize) { - msg(usprintf("%s: EVSA store size %Xh (%u) is greater than volume body size %Xh (%u)", __FUNCTION__, - evsaStoreHeader->StoreSize, evsaStoreHeader->StoreSize, - dataSize, dataSize), parent); - return U_SUCCESS; - } - - // Construct header and body - UByteArray header = store.left(evsaStoreHeader->Header.Size); - UByteArray body = store.mid(evsaStoreHeader->Header.Size, evsaStoreHeader->StoreSize - evsaStoreHeader->Header.Size); - - // Recalculate checksum - UINT8 calculated = calculateChecksum8(((const UINT8*)evsaStoreHeader) + 2, evsaStoreHeader->Header.Size - 2); - - // Add info - UString name("EVSA store"); - UString info = usprintf("Signature: EVSA\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nType: %02Xh\nAttributes: %08Xh\nChecksum: %02Xh", - evsaStoreHeader->StoreSize, evsaStoreHeader->StoreSize, - (UINT32)header.size(), (UINT32)header.size(), - (UINT32)body.size(), (UINT32)body.size(), - evsaStoreHeader->Header.Type, - evsaStoreHeader->Attributes, - evsaStoreHeader->Header.Checksum) + - (evsaStoreHeader->Header.Checksum != calculated ? usprintf(", invalid, should be %02Xh", calculated) : UString(", valid")); - - // Add tree item - index = model->addItem(localOffset, Types::EvsaStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, parent); - - return U_SUCCESS; -} - -USTATUS NvramParser::parseFlashMapStoreHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index) -{ - const UINT32 dataSize = (UINT32)store.size(); - - // Check data size - if (dataSize < sizeof(PHOENIX_FLASH_MAP_HEADER)) { - msg(usprintf("%s: volume body is too small even for FlashMap block header", __FUNCTION__), parent); - return U_SUCCESS; - } - - // Get FlashMap block header - const PHOENIX_FLASH_MAP_HEADER* flashMapHeader = (const PHOENIX_FLASH_MAP_HEADER*)store.constData(); - - // Check store size - UINT32 flashMapSize = sizeof(PHOENIX_FLASH_MAP_HEADER) + flashMapHeader->NumEntries * sizeof(PHOENIX_FLASH_MAP_ENTRY); - if (dataSize < flashMapSize) { - msg(usprintf("%s: FlashMap block size %Xh (%u) is greater than volume body size %Xh (%u)", __FUNCTION__, - flashMapSize, flashMapSize, - dataSize, dataSize), parent); - return U_SUCCESS; - } - - // Construct header and body - UByteArray header = store.left(sizeof(PHOENIX_FLASH_MAP_HEADER)); - UByteArray body = store.mid(sizeof(PHOENIX_FLASH_MAP_HEADER), flashMapSize - sizeof(PHOENIX_FLASH_MAP_HEADER)); - - // Add info - UString name("Phoenix SCT flash map"); - UString info = usprintf("Signature: _FLASH_MAP\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nNumber of entries: %u", - flashMapSize, flashMapSize, - (UINT32)header.size(), (UINT32)header.size(), - (UINT32)body.size(), (UINT32)body.size(), - flashMapHeader->NumEntries); - - // Add tree item - index = model->addItem(localOffset, Types::FlashMapStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, parent); - - return U_SUCCESS; -} - -USTATUS NvramParser::parseCmdbStoreHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index) -{ - const UINT32 dataSize = (UINT32)store.size(); - - // Check store size - if (dataSize < sizeof(PHOENIX_CMDB_HEADER)) { - msg(usprintf("%s: volume body is too small even for CMDB store header", __FUNCTION__), parent); - return U_SUCCESS; - } - - UINT32 cmdbSize = NVRAM_PHOENIX_CMDB_SIZE; - if (dataSize < cmdbSize) { - msg(usprintf("%s: CMDB store size %Xh (%u) is greater than volume body size %Xh (%u)", __FUNCTION__, - cmdbSize, cmdbSize, - dataSize, dataSize), parent); - return U_SUCCESS; - } - - // Get store header - const PHOENIX_CMDB_HEADER* cmdbHeader = (const PHOENIX_CMDB_HEADER*)store.constData(); - - // Construct header and body - UByteArray header = store.left(cmdbHeader->TotalSize); - UByteArray body = store.mid(cmdbHeader->TotalSize, cmdbSize - cmdbHeader->TotalSize); - - // Add info - UString name("CMDB store"); - UString info = usprintf("Signature: CMDB\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)", - cmdbSize, cmdbSize, - (UINT32)header.size(), (UINT32)header.size(), - (UINT32)body.size(), (UINT32)body.size()); - - // Add tree item - index = model->addItem(localOffset, Types::CmdbStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, parent); - - return U_SUCCESS; -} - -USTATUS NvramParser::parseSlicPubkeyHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index) -{ - const UINT32 dataSize = (UINT32)store.size(); - - // Check data size - if (dataSize < sizeof(OEM_ACTIVATION_PUBKEY)) { - msg(usprintf("%s: volume body is too small even for SLIC pubkey header", __FUNCTION__), parent); - return U_SUCCESS; - } - - // Get SLIC pubkey header - const OEM_ACTIVATION_PUBKEY* pubkeyHeader = (const OEM_ACTIVATION_PUBKEY*)store.constData(); - - // Check store size - if (dataSize < pubkeyHeader->Size) { - msg(usprintf("%s: SLIC pubkey size %Xh (%u) is greater than volume body size %Xh (%u)", __FUNCTION__, - pubkeyHeader->Size, pubkeyHeader->Size, - dataSize, dataSize), parent); - return U_SUCCESS; - } - - // Construct header and body - UByteArray header = store.left(sizeof(OEM_ACTIVATION_PUBKEY)); - - // Add info - UString name("SLIC pubkey"); - UString info = usprintf("Type: 0h\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: 0h (0)\n" - "Key type: %02Xh\nVersion: %02Xh\nAlgorithm: %08Xh\nMagic: RSA1\nBit length: %08Xh\nExponent: %08Xh", - pubkeyHeader->Size, pubkeyHeader->Size, - (UINT32)header.size(), (UINT32)header.size(), - pubkeyHeader->KeyType, - pubkeyHeader->Version, - pubkeyHeader->Algorithm, - pubkeyHeader->BitLength, - pubkeyHeader->Exponent); - - // Add tree item - index = model->addItem(localOffset, Types::SlicData, Subtypes::PubkeySlicData, name, UString(), info, header, UByteArray(), UByteArray(), Fixed, parent); - - return U_SUCCESS; -} - -USTATUS NvramParser::parseSlicMarkerHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index) -{ - const UINT32 dataSize = (UINT32)store.size(); - - // Check data size - if (dataSize < sizeof(OEM_ACTIVATION_MARKER)) { - msg(usprintf("%s: volume body is too small even for SLIC marker header", __FUNCTION__), parent); - return U_SUCCESS; - } - - // Get SLIC marker header - const OEM_ACTIVATION_MARKER* markerHeader = (const OEM_ACTIVATION_MARKER*)store.constData(); - - // Check store size - if (dataSize < markerHeader->Size) { - msg(usprintf("%s: SLIC marker size %Xh (%u) is greater than volume body size %Xh (%u)", __FUNCTION__, - markerHeader->Size, markerHeader->Size, - dataSize, dataSize), parent); - return U_SUCCESS; - } - - // Construct header and body - UByteArray header = store.left(sizeof(OEM_ACTIVATION_MARKER)); - - // Add info - UString name("SLIC marker"); - UString info = usprintf("Type: 1h\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: 0h (0)\n" - "Version: %08Xh\nOEM ID: %s\nOEM table ID: %s\nWindows flag: WINDOWS\nSLIC version: %08Xh", - markerHeader->Size, markerHeader->Size, - (UINT32)header.size(), (UINT32)header.size(), - markerHeader->Version, - (const char*)UString((const char*)&(markerHeader->OemId)).left(6).toLocal8Bit(), - (const char*)UString((const char*)&(markerHeader->OemTableId)).left(8).toLocal8Bit(), - markerHeader->SlicVersion); - - - // Add tree item - index = model->addItem(localOffset, Types::SlicData, Subtypes::MarkerSlicData, name, UString(), info, header, UByteArray(), UByteArray(), Fixed, parent); - - return U_SUCCESS; -} - -USTATUS NvramParser::parseStoreHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index) -{ - const UINT32 dataSize = (UINT32)store.size(); - const UINT32* signature = (const UINT32*)store.constData(); - // Check store size - if (dataSize < sizeof(UINT32)) { - msg(usprintf("%s: volume body is too small even for a store signature", __FUNCTION__), parent); - return U_SUCCESS; - } - - // Check signature and run parser function needed - // VSS/SVS/NSS store - if (*signature == NVRAM_VSS_STORE_SIGNATURE || *signature == NVRAM_APPLE_SVS_STORE_SIGNATURE || *signature == NVRAM_APPLE_NSS_STORE_SIGNATURE) - return parseVssStoreHeader(store, localOffset, false, parent, index); - // VSS2 store - if (*signature == NVRAM_VSS2_AUTH_VAR_KEY_DATABASE_GUID_PART1 || *signature == NVRAM_VSS2_STORE_GUID_PART1) - return parseVss2StoreHeader(store, localOffset, false, parent, index); - // FTW store - else if (*signature == NVRAM_MAIN_STORE_VOLUME_GUID_DATA1 || *signature == EDKII_WORKING_BLOCK_SIGNATURE_GUID_DATA1) - return parseFtwStoreHeader(store, localOffset, parent, index); - // FDC store - else if (*signature == NVRAM_FDC_VOLUME_SIGNATURE) - return parseFdcStoreHeader(store, localOffset, parent, index); - // Apple Fsys/Gaid store - else if (*signature == NVRAM_APPLE_FSYS_STORE_SIGNATURE || *signature == NVRAM_APPLE_GAID_STORE_SIGNATURE) - return parseFsysStoreHeader(store, localOffset, parent, index); - // EVSA store - else if (dataSize >= 2 * sizeof(UINT32) && *(signature + 1) == NVRAM_EVSA_STORE_SIGNATURE) - return parseEvsaStoreHeader(store, localOffset, parent, index); - // Phoenix SCT flash map - else if (*signature == NVRAM_PHOENIX_FLASH_MAP_SIGNATURE_PART1) - return parseFlashMapStoreHeader(store, localOffset, parent, index); - // Phoenix CMDB store - else if (*signature == NVRAM_PHOENIX_CMDB_HEADER_SIGNATURE) - return parseCmdbStoreHeader(store, localOffset, parent, index); - // SLIC pubkey - else if (dataSize >= 5 * sizeof(UINT32) && *(signature + 4) == OEM_ACTIVATION_PUBKEY_MAGIC) - return parseSlicPubkeyHeader(store, localOffset, parent, index); - // SLIC marker - else if (dataSize >= 34 && *(const UINT64*)(store.constData() + 26) == OEM_ACTIVATION_MARKER_WINDOWS_FLAG) - return parseSlicMarkerHeader(store, localOffset, parent, index); - // Intel microcode - // Must be checked after SLIC marker because of the same *signature values - else if (*signature == INTEL_MICROCODE_HEADER_VERSION_1) - return ffsParser->parseIntelMicrocodeHeader(store, localOffset, parent, index); - - msg(usprintf("parseStoreHeader: don't know how to parse a header with signature %08Xh", *signature), parent); - return U_SUCCESS; -} - -USTATUS NvramParser::parseFdcStoreBody(const UModelIndex & index) -{ - // Sanity check - if (!index.isValid()) - return U_INVALID_PARAMETER; - - // Get item data - const UByteArray data = model->body(index); - - // Get local offset - UINT32 localOffset = (UINT32)model->header(index).size(); - - // The body is a firmware volume with either a VSS or VSS2 store - UModelIndex volumeIndex; - USTATUS status = ffsParser->parseVolumeHeader(data, localOffset, index, volumeIndex); - if (status || !volumeIndex.isValid()) { - msg(usprintf("%s: store can't be parsed as FDC store", __FUNCTION__), index); - return U_SUCCESS; - } - - // Determine if it's a VSS or VSS2 store inside - UByteArray store = model->body(volumeIndex); - if ((UINT32)store.size() >= sizeof(UINT32) && *(const UINT32*)store.constData() == NVRAM_VSS_STORE_SIGNATURE) { - UModelIndex vssIndex; - status = parseVssStoreHeader(store, (UINT32)(localOffset + model->header(volumeIndex).size()), true, volumeIndex, vssIndex); - if (status) - return status; - return parseVssStoreBody(vssIndex, 0); - } - else if ((UINT32)store.size() >= sizeof(EFI_GUID) && store.left(sizeof(EFI_GUID)) == NVRAM_FDC_STORE_GUID) { - UModelIndex vss2Index; - status = parseVss2StoreHeader(store, (UINT32)(localOffset + model->header(volumeIndex).size()), true, volumeIndex, vss2Index); - if (status) - return status; - return parseVssStoreBody(vss2Index, 0); - } - else { - msg(usprintf("%s: internal volume can't be parsed as VSS/VSS2 store", __FUNCTION__), index); - return U_SUCCESS; - } - -} - -USTATUS NvramParser::parseVssStoreBody(const UModelIndex & index, UINT8 alignment) -{ - // Sanity check - if (!index.isValid()) - return U_INVALID_PARAMETER; - - // Obtain required information from parent volume - UINT8 emptyByte = 0xFF; - UModelIndex parentVolumeIndex = model->findParentOfType(index, Types::Volume); - if (parentVolumeIndex.isValid() && model->hasEmptyParsingData(parentVolumeIndex) == false) { - UByteArray data = model->parsingData(parentVolumeIndex); - const VOLUME_PARSING_DATA* pdata = (const VOLUME_PARSING_DATA*)data.constData(); - emptyByte = pdata->emptyByte; - } - - // Get local offset - UINT32 localOffset = (UINT32)model->header(index).size(); - - // Get item data - const UByteArray data = model->body(index); - - // Check that the is enough space for variable header - const UINT32 dataSize = (UINT32)data.size(); - if (dataSize < sizeof(VSS_VARIABLE_HEADER)) { - msg(usprintf("%s: store body is too small even for VSS variable header", __FUNCTION__), index); - return U_SUCCESS; - } - - UINT32 offset = 0; - - // Parse all variables - while (1) { - bool isInvalid = true; - bool isAuthenticated = false; - bool isAppleCrc32 = false; - bool isIntelSpecial = false; - - UINT32 storedCrc32 = 0; - UINT32 calculatedCrc32 = 0; - UINT64 monotonicCounter = 0; - EFI_TIME timestamp = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }; - UINT32 pubKeyIndex = 0; - - UINT8 subtype = 0; - UString name; - UString text; - EFI_GUID* variableGuid = NULL; - CHAR16* variableName = (CHAR16*)L""; - UByteArray header; - UByteArray body; - - UINT32 unparsedSize = dataSize - offset; - - // Get variable header - const VSS_VARIABLE_HEADER* variableHeader = (const VSS_VARIABLE_HEADER*)(data.constData() + offset); - - // Check variable header to fit in still unparsed data - UINT32 variableSize = 0; - if (unparsedSize >= sizeof(VSS_VARIABLE_HEADER) - && variableHeader->StartId == NVRAM_VSS_VARIABLE_START_ID) { - // Apple VSS variable with CRC32 of the data - if (variableHeader->Attributes & NVRAM_VSS_VARIABLE_APPLE_DATA_CHECKSUM) { - isAppleCrc32 = true; - if (unparsedSize < sizeof(VSS_APPLE_VARIABLE_HEADER)) { - variableSize = 0; + parsed.format(), + parsed.state(), + parsed.reserved(), + parsed.reserved1()); + + // Add header tree item + UModelIndex headerIndex = model->addItem(localOffset + storeOffset, Types::Vss2Store, 0, name, UString(), info, header, body, UByteArray(), Fixed, index); + + // Add variables + UINT32 entryOffset = parsed.len_vss2_store_header(); + for (const auto & variable : *parsed.body()->variables()) { + UINT8 subtype; + + // This is the terminating entry, needs special processing + if (variable->_is_null_signature_last()) { + // Add free space or padding after all variables, if needed + if (entryOffset < storeSize) { + UByteArray freeSpace = vss2.mid(entryOffset, storeSize - entryOffset); + // Add info + info = usprintf("Full size: %Xh (%u)", (UINT32)freeSpace.size(), (UINT32)freeSpace.size()); + + // Check that remaining unparsed bytes are actually empty + if (freeSpace.count(emptyByte) == freeSpace.size()) { // Free space + // Add tree item + model->addItem(entryOffset, Types::FreeSpace, 0, UString("Free space"), UString(), info, UByteArray(), freeSpace, UByteArray(), Fixed, headerIndex); + } + else { + // Add tree item + model->addItem(entryOffset, Types::Padding, getPaddingType(freeSpace), UString("Padding"), UString(), info, UByteArray(), freeSpace, UByteArray(), Fixed, headerIndex); + } + } + break; } - else { - const VSS_APPLE_VARIABLE_HEADER* appleVariableHeader = (const VSS_APPLE_VARIABLE_HEADER*)variableHeader; - variableSize = sizeof(VSS_APPLE_VARIABLE_HEADER) + appleVariableHeader->NameSize + appleVariableHeader->DataSize; - variableGuid = (EFI_GUID*)&appleVariableHeader->VendorGuid; - variableName = (CHAR16*)(appleVariableHeader + 1); - - header = data.mid(offset, sizeof(VSS_APPLE_VARIABLE_HEADER) + appleVariableHeader->NameSize); - body = data.mid(offset + header.size(), appleVariableHeader->DataSize); - - // Calculate CRC32 of the variable data - storedCrc32 = appleVariableHeader->DataCrc32; - calculatedCrc32 = (UINT32)crc32(0, (const UINT8*)body.constData(), (uInt)body.size()); + + // This is a normal entry + UINT32 variableSize; + UINT32 alignmentSize; + if (variable->is_auth()) { // Authenticated + subtype = Subtypes::AuthVssEntry; + header = vss2.mid(entryOffset, variable->len_auth_header() + variable->len_name_auth()); + body = vss2.mid(entryOffset + header.size(), variable->len_data_auth()); + variableSize = (UINT32)(header.size() + body.size()); + alignmentSize = variable->len_alignment_padding_auth(); + const EFI_GUID variableGuid = readUnaligned((const EFI_GUID*)(variable->vendor_guid().c_str())); + name = guidToUString(variableGuid); + text = uFromUcs2(variable->name_auth().c_str()); + info = UString("Variable GUID: ") + guidToUString(variableGuid, false) + "\n"; } + else { // Standard + subtype = Subtypes::StandardVssEntry; + header = vss2.mid(entryOffset, variable->len_standard_header() + variable->len_name()); + body = vss2.mid(entryOffset + header.size(), variable->len_data()); + variableSize = (UINT32)(header.size() + body.size()); + alignmentSize = variable->len_alignment_padding(); + const EFI_GUID variableGuid = readUnaligned((const EFI_GUID*)(variable->vendor_guid().c_str())); + name = guidToUString(variableGuid); + text = uFromUcs2(variable->name().c_str()); + info = UString("Variable GUID: ") + guidToUString(variableGuid, false) + "\n"; + } + + // Override variable type to Invalid if needed + if (!variable->is_valid()) { + subtype = Subtypes::InvalidVssEntry; + name = UString("Invalid"); + text.clear(); + } + + const UINT32 variableAttributes = variable->attributes()->non_volatile() + + (variable->attributes()->boot_service() << 1) + + (variable->attributes()->runtime() << 2) + + (variable->attributes()->hw_error_record() << 3) + + (variable->attributes()->auth_write() << 4) + + (variable->attributes()->time_based_auth() << 5) + + (variable->attributes()->append_write() << 6) + + (UINT32)(variable->attributes()->reserved() << 7); + + // Add generic info + info += usprintf("Full size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nState: %02Xh\nReserved: %02Xh\nAttributes: %08Xh (", + variableSize, variableSize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + variable->state(), + variable->reserved(), + variableAttributes) + vssAttributesToUString(variableAttributes) + UString(")"); + + // Add specific info + if (variable->is_auth()) { + UINT64 monotonicCounter = (UINT64)variable->len_name() + ((UINT64)variable->len_data() << 32); + info += usprintf("\nMonotonic counter: %" PRIX64 "h\nTimestamp: ", monotonicCounter) + efiTimeToUString(*(const EFI_TIME*)variable->timestamp().c_str()) + + usprintf("\nPubKey index: %u", variable->pubkey_index()); + } + + // Add tree item + model->addItem(entryOffset, Types::VssEntry, subtype, name, text, info, header, body, UByteArray(), Fixed, headerIndex); + + entryOffset += (variableSize + alignmentSize); } - // Authenticated variable - else if ((variableHeader->Attributes & NVRAM_VSS_VARIABLE_AUTHENTICATED_WRITE_ACCESS) - || (variableHeader->Attributes & NVRAM_VSS_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS) - || (variableHeader->Attributes & NVRAM_VSS_VARIABLE_APPEND_WRITE) - || (variableHeader->NameSize == 0 && variableHeader->DataSize == 0)) { // If both NameSize and DataSize are zeros, it's auth variable with zero montonic counter - isAuthenticated = true; - if (unparsedSize < sizeof(VSS_AUTH_VARIABLE_HEADER)) { - variableSize = 0; - } - else { - const VSS_AUTH_VARIABLE_HEADER* authVariableHeader = (const VSS_AUTH_VARIABLE_HEADER*)variableHeader; - variableSize = sizeof(VSS_AUTH_VARIABLE_HEADER) + authVariableHeader->NameSize + authVariableHeader->DataSize; - variableGuid = (EFI_GUID*)&authVariableHeader->VendorGuid; - variableName = (CHAR16*)(authVariableHeader + 1); - - header = data.mid(offset, sizeof(VSS_AUTH_VARIABLE_HEADER) + authVariableHeader->NameSize); - body = data.mid(offset + header.size(), authVariableHeader->DataSize); - - monotonicCounter = authVariableHeader->MonotonicCounter; - timestamp = authVariableHeader->Timestamp; - pubKeyIndex = authVariableHeader->PubKeyIndex; - } + storeOffset += storeSize - 1; + previousStoreEndOffset = storeOffset + 1; + continue; + } catch (...) { + // Parsing failed, try something else + } +not_vss2: + // Do not try any other parsers if we are here for FDC store parsing + if (fdcStoreSizeOverride != 0) { + continue; + } + + // FTW + try { + if (volumeBodySize - storeOffset < sizeof(EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32)) { + // No need to parse further, the rest of the volume is too small + goto not_ftw; } - - // Intel special variable - else if (variableHeader->State == NVRAM_VSS_INTEL_VARIABLE_VALID - || variableHeader->State == NVRAM_VSS_INTEL_VARIABLE_INVALID) { - isIntelSpecial = true; - const VSS_INTEL_VARIABLE_HEADER* intelVariableHeader = (const VSS_INTEL_VARIABLE_HEADER*)variableHeader; - variableSize = intelVariableHeader->TotalSize; - variableGuid = (EFI_GUID*)&intelVariableHeader->VendorGuid; - variableName = (CHAR16*)(intelVariableHeader + 1); - - UINT32 i = 0; - while (variableName[i] != 0) ++i; - - i = sizeof(VSS_INTEL_VARIABLE_HEADER) + 2 * (i + 1); - i = i < variableSize ? i : variableSize; - - header = data.mid(offset, i); - body = data.mid(offset + header.size(), variableSize - i); + // Perform initial sanity check + const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32* storeHeader = (const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32*)(volumeBody.constData() + storeOffset); + UByteArray guid = UByteArray((const char*)&storeHeader->Signature, sizeof(EFI_GUID)); + if (guid != NVRAM_MAIN_STORE_VOLUME_GUID + && guid != EDKII_WORKING_BLOCK_SIGNATURE_GUID + && guid != VSS2_WORKING_BLOCK_SIGNATURE_GUID) { + // No need to parse further, not a FTW store + goto not_ftw; + } + // Determine store size + UINT32 storeSize; + if (storeHeader->WriteQueueSize % 0x10 == 4) { + storeSize = sizeof(EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32) + storeHeader->WriteQueueSize; + } + else if (storeHeader->WriteQueueSize % 0x10 == 0) { + const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64* storeHeader64 = (const EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64*)(volumeBody.constData() + storeOffset); + storeSize = (UINT32)(sizeof(EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64) + storeHeader64->WriteQueueSize); } - - // Normal VSS variable else { - variableSize = sizeof(VSS_VARIABLE_HEADER) + variableHeader->NameSize + variableHeader->DataSize; - variableGuid = (EFI_GUID*)&variableHeader->VendorGuid; - variableName = (CHAR16*)(variableHeader + 1); - - header = data.mid(offset, sizeof(VSS_VARIABLE_HEADER) + variableHeader->NameSize); - body = data.mid(offset + header.size(), variableHeader->DataSize); + // No need to parse further, unknown FTW store size + msg(usprintf("%s: can not determine FTW store size for candidate at base %08Xh", __FUNCTION__, model->base(index) + localOffset + storeOffset), index); + goto not_ftw; } - - // Check variable state - if (variableHeader->State == NVRAM_VSS_INTEL_VARIABLE_VALID - || variableHeader->State == NVRAM_VSS_VARIABLE_ADDED - || variableHeader->State == NVRAM_VSS_VARIABLE_HEADER_VALID) { - isInvalid = false; - } - - // Check variable size - if (variableSize > unparsedSize) { - variableSize = 0; - } - } + storeSize = MIN(volumeBodySize - storeOffset, storeSize); - // Can't parse further, add the last element and break the loop - if (!variableSize) { - // Check if the data left is a free space or a padding - UByteArray padding = data.mid(offset, unparsedSize); - // Get info - UString info = usprintf("Full size: %Xh (%u)", (UINT32)padding.size(), (UINT32)padding.size()); + umemstream is(volumeBody.constData() + storeOffset, storeSize); + kaitai::kstream ks(&is); + edk2_ftw_t parsed(&ks); - if (padding.count(emptyByte) == padding.size()) { // Free space - // Add tree item - model->addItem(localOffset + offset, Types::FreeSpace, 0, UString("Free space"), UString(), info, UByteArray(), padding, UByteArray(), Fixed, index); + // Construct header and calculate header checksum + UINT32 headerSize; + UINT32 calculatedCrc; + if (parsed._is_null_len_write_queue_64()) { + headerSize = sizeof(EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32); + header = volumeBody.mid(storeOffset, headerSize); + + // Check block header checksum + UByteArray crcHeader = header; + EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32* crcFtwBlockHeader = (EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER32*)crcHeader.data(); + crcFtwBlockHeader->Crc = emptyByte ? 0xFFFFFFFF : 0; + crcFtwBlockHeader->State = emptyByte ? 0xFF : 0; + calculatedCrc = (UINT32)crc32(0, (const UINT8*)crcFtwBlockHeader, (UINT32)headerSize); } - else { // Padding - // Nothing is parsed yet, but the store is not empty - if (!offset) { - msg(usprintf("%s: store can't be parsed as VSS store", __FUNCTION__), index); - return U_SUCCESS; + else { + headerSize = sizeof(EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64); + header = volumeBody.mid(storeOffset, headerSize); + + // Check block header checksum + UByteArray crcHeader = header; + EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64* crcFtwBlockHeader = (EFI_FAULT_TOLERANT_WORKING_BLOCK_HEADER64*)crcHeader.data(); + crcFtwBlockHeader->Crc = emptyByte ? 0xFFFFFFFF : 0; + crcFtwBlockHeader->State = emptyByte ? 0xFF : 0; + calculatedCrc = (UINT32)crc32(0, (const UINT8*)crcFtwBlockHeader, (UINT32)headerSize); + } + + // FTW store at current offset parsed correctly + // Check if we need to add a padding before it + if (!outerPadding.isEmpty()) { + UString info = usprintf("Full size: %Xh (%u)", (UINT32)outerPadding.size(), (UINT32)outerPadding.size()); + model->addItem(localOffset + previousStoreEndOffset, Types::Padding, getPaddingType(outerPadding), UString("Padding"), UString(), info, UByteArray(), outerPadding, UByteArray(), Fixed, index); + outerPadding.clear(); + } + + // Construct body + body = volumeBody.mid(storeOffset + header.size(), storeSize - header.size()); + + // Add info + name = UString("FTW store"); + info = UString("Signature: ") + guidToUString(*(const EFI_GUID*)guid.constData(), false); + info += usprintf("\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nState: %02Xh\nHeader CRC32: %08Xh", + (UINT32)storeSize, (UINT32)storeSize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + parsed.state(), + parsed.crc()) + (parsed.crc() != calculatedCrc ? usprintf(", invalid, should be %08Xh", calculatedCrc) : UString(", valid")); + + // Add header tree item + model->addItem(localOffset + storeOffset, Types::FtwStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, index); + + storeOffset += storeSize - 1; + previousStoreEndOffset = storeOffset + 1; + continue; + } catch (...) { + // Parsing failed, try something else + } +not_ftw: + // Insyde FDC + try { + if (volumeBodySize - storeOffset < sizeof(INSYDE_FDC_STORE_HEADER)) { + // No need to parse further, the rest of the volume is too small + goto not_fdc; + } + // Perform initial sanity check + const INSYDE_FDC_STORE_HEADER* storeHeader = (const INSYDE_FDC_STORE_HEADER*)(volumeBody.constData() + storeOffset); + if (storeHeader->Signature != INSYDE_FDC_STORE_SIGNATURE) { + // No need to parse further, not a FDC store + goto not_fdc; + } + UINT32 storeSize = MIN(volumeBodySize - storeOffset, storeHeader->Size); + + umemstream is(volumeBody.constData() + storeOffset, storeSize); + kaitai::kstream ks(&is); + insyde_fdc_t parsed(&ks); + + // Insyde FDC store at current offset parsed correctly + // Check if we need to add a padding before it + if (!outerPadding.isEmpty()) { + UString info = usprintf("Full size: %Xh (%u)", (UINT32)outerPadding.size(), (UINT32)outerPadding.size()); + model->addItem(localOffset + previousStoreEndOffset, Types::Padding, getPaddingType(outerPadding), UString("Padding"), UString(), info, UByteArray(), outerPadding, UByteArray(), Fixed, index); + outerPadding.clear(); + } + + // Construct header and body + header = volumeBody.mid(storeOffset, sizeof(INSYDE_FDC_STORE_HEADER)); + body = volumeBody.mid(storeOffset + header.size(), storeSize - header.size()); + + // Add info + name = UString("Insyde FDC store"); + info = usprintf("Signature: _FDC\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)", + storeSize, storeSize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size()); + + // Add header tree item + UModelIndex headerIndex = model->addItem(localOffset + storeOffset, Types::FdcStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, index); + + // Parse FDC body as normal VSS/VSS2 storage with size override + parseNvramVolumeBody(headerIndex, (UINT32)body.size()); + + storeOffset += storeSize - 1; + previousStoreEndOffset = storeOffset + 1; + continue; + } catch (...) { + // Parsing failed, try something else + } +not_fdc: + // Apple SysF + try { + if (volumeBodySize - storeOffset < sizeof(APPLE_SYSF_STORE_HEADER)) { + // No need to parse further, the rest of the volume is too small + goto not_sysf; + } + // Perform initial sanity check + const APPLE_SYSF_STORE_HEADER* storeHeader = (const APPLE_SYSF_STORE_HEADER*)(volumeBody.constData() + storeOffset); + if (storeHeader->Signature != NVRAM_APPLE_SYSF_STORE_SIGNATURE + && storeHeader->Signature != NVRAM_APPLE_DIAG_STORE_SIGNATURE) { + // No need to parse further, not a SysF/Diag store + goto not_sysf; + } + UINT32 storeSize = MIN(volumeBodySize - storeOffset, storeHeader->Size); + + umemstream is(volumeBody.constData() + storeOffset, storeSize); + kaitai::kstream ks(&is); + apple_sysf_t parsed(&ks); + + // Apple SysF/Diag store at current offset parsed correctly + // Check if we need to add a padding before it + if (!outerPadding.isEmpty()) { + info = usprintf("Full size: %Xh (%u)", (UINT32)outerPadding.size(), (UINT32)outerPadding.size()); + model->addItem(localOffset + previousStoreEndOffset, Types::Padding, getPaddingType(outerPadding), UString("Padding"), UString(), info, UByteArray(), outerPadding, UByteArray(), Fixed, index); + outerPadding.clear(); + } + + // Construct header and body + header = volumeBody.mid(storeOffset, sizeof(APPLE_SYSF_STORE_HEADER)); + body = volumeBody.mid(storeOffset + header.size(), storeSize - header.size()); + + // Check store checksum + UINT32 calculatedCrc = (UINT32)crc32(0, (const UINT8*)(volumeBody.constData() + storeOffset), storeSize - sizeof(UINT32)); + + // Add info + if (storeHeader->Signature == NVRAM_APPLE_SYSF_STORE_SIGNATURE) { + name = UString("Apple SysF store"); + info = UString("Signature: Fsys\n"); + } + else { + name = UString("Apple Diag store"); + info = UString("Signature: Gaid\n"); + } + info += usprintf("Full size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nUnknown: %02Xh\nUnknown1: %08Xh\nCRC32: %08Xh", + storeSize, storeSize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + parsed.unknown(), + parsed.unknown1(), + parsed.crc()) + (parsed.crc() != calculatedCrc ? usprintf(", invalid, should be %08Xh", calculatedCrc) : UString(", valid")); + + // Add header tree item + UModelIndex headerIndex = model->addItem(localOffset + storeOffset, Types::SysFStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, index); + + // Add variables + UINT32 entryOffset = sizeof(APPLE_SYSF_STORE_HEADER); + for (const auto & variable : *parsed.body()->variables()) { + UINT8 subtype; + + if (variable->invalid_flag()) { + subtype = Subtypes::InvalidSysFEntry; + name = UString("Invalid"); + } + else { + subtype = Subtypes::NormalSysFEntry; + name = usprintf("%s", variable->name().c_str()); } + if (variable->len_name() == 3 && variable->name() == "EOF") { + header = volumeBody.mid(storeOffset + entryOffset, 4); + body.clear(); + } + else { + header = volumeBody.mid(storeOffset + entryOffset, sizeof(UINT8) + (UINT32)variable->len_name() + sizeof(UINT16)); + body = volumeBody.mid(storeOffset + entryOffset + header.size(), (UINT32)variable->len_data()); + } + // Add generic info + UINT32 variableSize = (UINT32)header.size() + (UINT32)body.size(); + info = usprintf("Full size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\n", + variableSize, variableSize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size()); + // Add tree item - model->addItem(localOffset + offset, Types::Padding, getPaddingType(padding), UString("Padding"), UString(), info, UByteArray(), padding, UByteArray(), Fixed, index); + model->addItem(entryOffset, Types::SysFEntry, subtype, name, UString(), info, header, body, UByteArray(), Fixed, headerIndex); + + entryOffset += variableSize; } - return U_SUCCESS; + // Add free space or padding after all variables, if needed + if (entryOffset < storeSize) { + UByteArray freeSpace = volumeBody.mid(storeOffset + entryOffset, storeSize - entryOffset); + // Add info + info = usprintf("Full size: %Xh (%u)", (UINT32)freeSpace.size(), (UINT32)freeSpace.size()); + + // Check that remaining unparsed bytes are actually zeroes + if (freeSpace.count('\x00') == freeSpace.size() - 4) { // Free space, 4 last bytes are always CRC32 + // Add tree item + model->addItem(entryOffset, Types::FreeSpace, 0, UString("Free space"), UString(), info, UByteArray(), freeSpace, UByteArray(), Fixed, headerIndex); + } + else { + // Add tree item + model->addItem(entryOffset, Types::Padding, getPaddingType(freeSpace), UString("Padding"), UString(), info, UByteArray(), freeSpace, UByteArray(), Fixed, headerIndex); + } + } + + storeOffset += storeSize - 1; + previousStoreEndOffset = storeOffset + 1; + continue; + } catch (...) { + // Parsing failed, try something else } - - UString info; - - // Rename invalid variables - if (isInvalid || !variableGuid) { - isInvalid = true; - name = UString("Invalid"); - } - else { // Add GUID and text for valid variables - name = guidToUString(readUnaligned(variableGuid)); - info += UString("Variable GUID: ") + guidToUString(readUnaligned(variableGuid), false) + "\n"; - text = uFromUcs2((const char*)variableName); - } - - // Add info - info += usprintf("Full size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nState: %02Xh\nReserved: %02Xh\nAttributes: %08Xh (", - variableSize, variableSize, - (UINT32)header.size(), (UINT32)header.size(), - (UINT32)body.size(), (UINT32)body.size(), - variableHeader->State, - variableHeader->Reserved, - variableHeader->Attributes) + vssAttributesToUString(variableHeader->Attributes) + UString(")"); - - // Set subtype and add related info - if (isInvalid) - subtype = Subtypes::InvalidVssEntry; - else if (isAuthenticated) { - subtype = Subtypes::AuthVssEntry; - info += usprintf("\nMonotonic counter: %" PRIX64 "h\nTimestamp: ", monotonicCounter) + efiTimeToUString(timestamp) - + usprintf("\nPubKey index: %u", pubKeyIndex); - } - else if (isAppleCrc32) { - subtype = Subtypes::AppleVssEntry; - info += usprintf("\nData checksum: %08Xh", storedCrc32) + - (storedCrc32 != calculatedCrc32 ? usprintf(", invalid, should be %08Xh", calculatedCrc32) : UString(", valid")); - } - else if (isIntelSpecial) { - subtype = Subtypes::IntelVssEntry; - } - else { - subtype = Subtypes::StandardVssEntry; - } - - // Add tree item - model->addItem(localOffset + offset, Types::VssEntry, subtype, name, text, info, header, body, UByteArray(), Fixed, index); - - // Apply alignment, if needed - if (alignment) { - variableSize = ((variableSize + alignment - 1) & (~(alignment - 1))); - } - - // Move to next variable - offset += variableSize; - } - - return U_SUCCESS; -} +not_sysf: + // Phoenix Flash Map + try { + if (volumeBodySize - storeOffset < sizeof(PHOENIX_FLASH_MAP_HEADER)) { + // No need to parse further, the rest of the volume is too small + goto not_flm; + } + // Perform initial sanity check + const PHOENIX_FLASH_MAP_HEADER* storeHeader = (const PHOENIX_FLASH_MAP_HEADER*)(volumeBody.constData() + storeOffset); + if (UByteArray((const char*)storeHeader->Signature, NVRAM_PHOENIX_FLASH_MAP_SIGNATURE_LENGTH) != NVRAM_PHOENIX_FLASH_MAP_SIGNATURE + || storeHeader->NumEntries > NVRAM_PHOENIX_FLASH_MAP_MAX_ENTRIES) { + // No need to parse further, not a Phoenix Flash Map + goto not_flm; + } + UINT32 storeSize = sizeof(PHOENIX_FLASH_MAP_HEADER) + storeHeader->NumEntries * sizeof(PHOENIX_FLASH_MAP_ENTRY); + + umemstream is(volumeBody.constData() + storeOffset, storeSize); + kaitai::kstream ks(&is); + phoenix_flm_t parsed(&ks); + + // Phoenix FlashMap store at current offset parsed correctly + // Check if we need to add a padding before it + if (!outerPadding.isEmpty()) { + info = usprintf("Full size: %Xh (%u)", (UINT32)outerPadding.size(), (UINT32)outerPadding.size()); + model->addItem(localOffset + previousStoreEndOffset, Types::Padding, getPaddingType(outerPadding), UString("Padding"), UString(), info, UByteArray(), outerPadding, UByteArray(), Fixed, index); + outerPadding.clear(); + } + + // Construct header and body + header = volumeBody.left(storeOffset + sizeof(PHOENIX_FLASH_MAP_HEADER)); + body = volumeBody.mid(storeOffset + header.size(), storeSize - header.size()); + + // Add info + name = UString("Phoenix SCT flash map"); + info = usprintf("Signature: _FLASH_MAP\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nEntries: %u\nReserved: %08Xh", + storeSize, storeSize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + parsed.num_entries(), + parsed.reserved()); + + // Add header tree item + UModelIndex headerIndex = model->addItem(localOffset + storeOffset, Types::PhoenixFlashMapStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, index); + + // Add entries + UINT32 entryOffset = sizeof(PHOENIX_FLASH_MAP_HEADER); + for (const auto & entry : *parsed.entries()) { + UINT8 subtype; + + if (entry->data_type() == NVRAM_PHOENIX_FLASH_MAP_ENTRY_DATA_TYPE_VOLUME) { + subtype = Subtypes::VolumeFlashMapEntry; + } + else if (entry->data_type() == NVRAM_PHOENIX_FLASH_MAP_ENTRY_DATA_TYPE_DATA_BLOCK) { + subtype = Subtypes::DataFlashMapEntry; + } + else { + subtype = Subtypes::UnknownFlashMapEntry; + } + + const EFI_GUID guid = readUnaligned((const EFI_GUID*)entry->guid().c_str()); + name = guidToUString(guid); + text = phoenixFlashMapGuidToUString(guid); + header = volumeBody.mid(storeOffset + entryOffset, sizeof(PHOENIX_FLASH_MAP_ENTRY)); -USTATUS NvramParser::parseFsysStoreBody(const UModelIndex & index) -{ - // Sanity check - if (!index.isValid()) - return U_INVALID_PARAMETER; - - // Get local offset - UINT32 localOffset = (UINT32)model->header(index).size(); - - // Get item data - const UByteArray data = model->body(index); - - // Check that the is enough space for variable header - const UINT32 storeDataSize = (UINT32)data.size(); - UINT32 offset = 0; - - // Parse all variables - while (1) { - UINT32 unparsedSize = storeDataSize - offset; - UINT32 variableSize = 0; - - // Get nameSize and name of the variable - UINT8 nameSize = *(UINT8*)(data.constData() + offset); - bool valid = !(nameSize & 0x80); // Last bit is a validity bit, 0 means valid - nameSize &= 0x7F; - - // Check sanity - if (unparsedSize >= nameSize + sizeof(UINT8)) { - variableSize = nameSize + sizeof(UINT8); - } - - UByteArray name; - if (variableSize) { - name = data.mid(offset + sizeof(UINT8), nameSize); - // Check for EOF variable - if (nameSize == 3 && name[0] == 'E' && name[1] == 'O' && name[2] == 'F') { - // There is no data afterward, add EOF variable and free space and return - UByteArray header = data.mid(offset, sizeof(UINT8) + nameSize); - UString info = usprintf("Full size: %Xh (%u)", (UINT32)header.size(), (UINT32)header.size()); - - // Add EOF tree item - model->addItem(localOffset + offset, Types::FsysEntry, Subtypes::NormalFsysEntry, UString("EOF"), UString(), info, header, UByteArray(), UByteArray(), Fixed, index); - - // Add free space - offset += (UINT32)header.size(); - UByteArray body = data.mid(offset); - info = usprintf("Full size: %Xh (%u)", (UINT32)body.size(), (UINT32)body.size()); - - // Add free space tree item - model->addItem(localOffset + offset, Types::FreeSpace, 0, UString("Free space"), UString(), info, UByteArray(), body, UByteArray(), Fixed, index); - - return U_SUCCESS; - } - } - - // Get dataSize and data of the variable - const UINT16 dataSize = *(UINT16*)(data.constData() + offset + sizeof(UINT8) + nameSize); - if (unparsedSize >= sizeof(UINT8) + nameSize + sizeof(UINT16) + dataSize) { - variableSize = sizeof(UINT8) + nameSize + sizeof(UINT16) + dataSize; - } - else { - // Last variable is bad, add the rest as padding and return - UByteArray body = data.mid(offset); - UString info = usprintf("Full size: %Xh (%u)", (UINT32)body.size(), (UINT32)body.size()); - - // Add padding tree item - model->addItem(localOffset + offset, Types::Padding, getPaddingType(body), UString("Padding"), UString(), info, UByteArray(), body, UByteArray(), Fixed, index); - - // Show message - msg(usprintf("%s: next variable appears too big, added as padding", __FUNCTION__), index); - - return U_SUCCESS; - } - - // Construct header and body - UByteArray header = data.mid(offset, sizeof(UINT8) + nameSize + sizeof(UINT16)); - UByteArray body = data.mid(offset + sizeof(UINT8) + nameSize + sizeof(UINT16), dataSize); - - // Add info - UString info = usprintf("Full size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)", - variableSize, variableSize, + // Add info + UINT32 entrySize = (UINT32)header.size(); + info = usprintf("Full size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: 0h (0)\nData type: %04Xh\nEntry type: %04Xh\nSize: %08Xh\nOffset: %08Xh\nPhysical address: %" PRIX64 "h", + entrySize, entrySize, (UINT32)header.size(), (UINT32)header.size(), - (UINT32)body.size(), (UINT32)body.size()); - - // Add tree item - model->addItem(localOffset + offset, Types::FsysEntry, valid ? Subtypes::NormalFsysEntry : Subtypes::InvalidFsysEntry, UString(name.constData()), UString(), info, header, body, UByteArray(), Fixed, index); - - // Move to next variable - offset += variableSize; - } - - return U_SUCCESS; -} - -USTATUS NvramParser::parseEvsaStoreBody(const UModelIndex & index) -{ - // Sanity check - if (!index.isValid()) - return U_INVALID_PARAMETER; - - // Obtain required information from parent volume - UINT8 emptyByte = 0xFF; - UModelIndex parentVolumeIndex = model->findParentOfType(index, Types::Volume); - if (parentVolumeIndex.isValid() && model->hasEmptyParsingData(parentVolumeIndex) == false) { - UByteArray data = model->parsingData(parentVolumeIndex); - const VOLUME_PARSING_DATA* pdata = (const VOLUME_PARSING_DATA*)data.constData(); - emptyByte = pdata->emptyByte; - } - - // Get local offset - UINT32 localOffset = (UINT32)model->header(index).size(); - - // Get item data - const UByteArray data = model->body(index); - - // Check that the is enough space for entry header - const UINT32 storeDataSize = (UINT32)data.size(); - UINT32 offset = 0; - - std::map guidMap; - std::map nameMap; - - // Parse all entries - UINT32 unparsedSize = storeDataSize; - while (unparsedSize) { - UINT32 variableSize = 0; - UString name; - UString info; - UByteArray header; - UByteArray body; - UINT8 subtype; - UINT8 calculated; - - const EVSA_ENTRY_HEADER* entryHeader = (const EVSA_ENTRY_HEADER*)(data.constData() + offset); - - // Check entry size - variableSize = sizeof(EVSA_ENTRY_HEADER); - if (unparsedSize < variableSize || unparsedSize < entryHeader->Size || entryHeader->Size < 2) { - body = data.mid(offset); - info = usprintf("Full size: %Xh (%u)", (UINT32)body.size(), (UINT32)body.size()); - - if (body.count(emptyByte) == body.size()) { // Free space - // Add free space tree item - model->addItem(localOffset + offset, Types::FreeSpace, 0, UString("Free space"), UString(), info, UByteArray(), body, UByteArray(), Fixed, index); - } - else { - // Add padding tree item - UModelIndex itemIndex = model->addItem(localOffset + offset, Types::Padding, getPaddingType(body), UString("Padding"), UString(), info, UByteArray(), body, UByteArray(), Fixed, index); + entry->data_type(), + entry->entry_type(), + entry->size(), + entry->offset(), + entry->physical_address()); - // Show message - msg(usprintf("%s: variable parsing failed, the rest of unparsed store added as padding", __FUNCTION__), itemIndex); - } - break; - } - variableSize = entryHeader->Size; - - // Recalculate entry checksum - calculated = calculateChecksum8(((const UINT8*)entryHeader) + 2, entryHeader->Size - 2); - - // GUID entry - if (entryHeader->Type == NVRAM_EVSA_ENTRY_TYPE_GUID1 || - entryHeader->Type == NVRAM_EVSA_ENTRY_TYPE_GUID2) { - const EVSA_GUID_ENTRY* guidHeader = (const EVSA_GUID_ENTRY*)entryHeader; - header = data.mid(offset, sizeof(EVSA_GUID_ENTRY)); - body = data.mid(offset + sizeof(EVSA_GUID_ENTRY), guidHeader->Header.Size - sizeof(EVSA_GUID_ENTRY)); - EFI_GUID guid = *(EFI_GUID*)body.constData(); - name = guidToUString(guid); - info = UString("GUID: ") + guidToUString(guid, false) - + usprintf("\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nType: %02Xh\nChecksum: %02Xh", - variableSize, variableSize, - (UINT32)header.size(), (UINT32)header.size(), - (UINT32)body.size(), (UINT32)body.size(), - guidHeader->Header.Type, - guidHeader->Header.Checksum) - + (guidHeader->Header.Checksum != calculated ? usprintf(", invalid, should be %02Xh", calculated) : UString(", valid")) - + usprintf("\nGuidId: %04Xh", guidHeader->GuidId); - subtype = Subtypes::GuidEvsaEntry; - guidMap.insert(std::pair(guidHeader->GuidId, guid)); - } - // Name entry - else if (entryHeader->Type == NVRAM_EVSA_ENTRY_TYPE_NAME1 || - entryHeader->Type == NVRAM_EVSA_ENTRY_TYPE_NAME2) { - const EVSA_NAME_ENTRY* nameHeader = (const EVSA_NAME_ENTRY*)entryHeader; - header = data.mid(offset, sizeof(EVSA_NAME_ENTRY)); - body = data.mid(offset + sizeof(EVSA_NAME_ENTRY), nameHeader->Header.Size - sizeof(EVSA_NAME_ENTRY)); - name = uFromUcs2(body.constData()); - info = UString("Name: ") + name - + usprintf("\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nType: %02Xh\nChecksum: %02Xh", - variableSize, variableSize, - (UINT32)header.size(), (UINT32)header.size(), - (UINT32)body.size(), (UINT32)body.size(), - nameHeader->Header.Type, - nameHeader->Header.Checksum) - + (nameHeader->Header.Checksum != calculated ? usprintf(", invalid, should be %02Xh", calculated) : UString(", valid")) - + usprintf("\nVarId: %04Xh", nameHeader->VarId); - subtype = Subtypes::NameEvsaEntry; - nameMap.insert(std::pair(nameHeader->VarId, name)); - } - // Data entry - else if (entryHeader->Type == NVRAM_EVSA_ENTRY_TYPE_DATA1 || - entryHeader->Type == NVRAM_EVSA_ENTRY_TYPE_DATA2 || - entryHeader->Type == NVRAM_EVSA_ENTRY_TYPE_DATA_INVALID) { - const EVSA_DATA_ENTRY* dataHeader = (const EVSA_DATA_ENTRY*)entryHeader; - // Check for extended header - UINT32 headerSize = sizeof(EVSA_DATA_ENTRY); - UINT32 dataSize = dataHeader->Header.Size - sizeof(EVSA_DATA_ENTRY); - if (dataHeader->Attributes & NVRAM_EVSA_DATA_EXTENDED_HEADER) { - const EVSA_DATA_ENTRY_EXTENDED* dataHeaderExtended = (const EVSA_DATA_ENTRY_EXTENDED*)entryHeader; - headerSize = sizeof(EVSA_DATA_ENTRY_EXTENDED); - dataSize = dataHeaderExtended->DataSize; - variableSize = headerSize + dataSize; - } - - header = data.mid(offset, headerSize); - body = data.mid(offset + headerSize, dataSize); - name = UString("Data"); - info = usprintf("Full size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nType: %02Xh\nChecksum: %02Xh", - variableSize, variableSize, - headerSize, headerSize, - dataSize, dataSize, - dataHeader->Header.Type, - dataHeader->Header.Checksum) - + (dataHeader->Header.Checksum != calculated ? usprintf(", invalid, should be %02Xh", calculated) : UString(", valid")) - + usprintf("\nVarId: %04Xh\nGuidId: %04Xh\nAttributes: %08Xh (", - dataHeader->VarId, - dataHeader->GuidId, - dataHeader->Attributes) - + evsaAttributesToUString(dataHeader->Attributes) + UString(")"); - subtype = Subtypes::DataEvsaEntry; - } - // Unknown entry or free space - else { - body = data.mid(offset); - info = usprintf("Full size: %Xh (%u)", (UINT32)body.size(), (UINT32)body.size()); - - if (body.count(emptyByte) == body.size()) { // Free space - // Add free space tree item - model->addItem(localOffset + offset, Types::FreeSpace, 0, UString("Free space"), UString(), info, UByteArray(), body, UByteArray(), Fixed, index); - } - else { - // Add padding tree item - UModelIndex itemIndex = model->addItem(localOffset + offset, Types::Padding, getPaddingType(body), UString("Padding"), UString(), info, UByteArray(), body, UByteArray(), Fixed, index); + // Add tree item + model->addItem(entryOffset, Types::PhoenixFlashMapEntry, subtype, name, text, info, header, UByteArray(), UByteArray(), Fixed, headerIndex); - // Show message - msg(usprintf("%s: unknown variable of type %02Xh found at offset %Xh, the rest of unparsed store added as padding", __FUNCTION__, entryHeader->Type, offset), itemIndex); + entryOffset += entrySize; } - break; - } - - // Add tree item - model->addItem(localOffset + offset, Types::EvsaEntry, subtype, name, UString(), info, header, body, UByteArray(), Fixed, index); - - // Move to next variable - offset += variableSize; - unparsedSize = storeDataSize - offset; - } - - // Reparse all data variables to detect invalid ones and assign name and test to valid ones - for (int i = 0; i < model->rowCount(index); i++) { - UModelIndex current = index.model()->index(i, 0, index); - - if (model->subtype(current) == Subtypes::DataEvsaEntry) { - UByteArray header = model->header(current); - const EVSA_DATA_ENTRY* dataHeader = (const EVSA_DATA_ENTRY*)header.constData(); - UString guid; - if (guidMap.count(dataHeader->GuidId)) - guid = guidToUString(guidMap[dataHeader->GuidId], false); - UString name; - if (nameMap.count(dataHeader->VarId)) - name = nameMap[dataHeader->VarId]; - // Check for variable validity - if (guid.isEmpty() && name.isEmpty()) { // Both name and guid aren't found - model->setSubtype(current, Subtypes::InvalidEvsaEntry); - model->setName(current, UString("Invalid")); - msg(usprintf("%s: data variable with invalid GuidId and invalid VarId", __FUNCTION__), current); + storeOffset += storeSize - 1; + previousStoreEndOffset = storeOffset + 1; + continue; + } catch (...) { + // Parsing failed, try something else + } +not_flm: + // Phoenix EVSA store + try { + if (volumeBodySize - storeOffset < sizeof(EVSA_STORE_ENTRY)) { + // No need to parse further, the rest of the volume is too small + goto not_evsa; } - else if (guid.isEmpty()) { // Guid not found - model->setSubtype(current, Subtypes::InvalidEvsaEntry); - model->setName(current, UString("Invalid")); - msg(usprintf("%s: data variable with invalid GuidId", __FUNCTION__), current); + // Perform initial sanity check + const EVSA_STORE_ENTRY* storeHeader = (const EVSA_STORE_ENTRY*)(volumeBody.constData() + storeOffset); + if (storeHeader->Signature != NVRAM_EVSA_STORE_SIGNATURE + || storeHeader->Header.Type != NVRAM_EVSA_ENTRY_TYPE_STORE + || storeHeader->Header.Size != sizeof(EVSA_STORE_ENTRY)) { + // No need to parse further, not a EVSA store + goto not_evsa; } - else if (name.isEmpty()) { // Name not found - model->setSubtype(current, Subtypes::InvalidEvsaEntry); - model->setName(current, UString("Invalid")); - msg(usprintf("%s: data variable with invalid VarId", __FUNCTION__), current); + UINT32 storeSize = MIN(volumeBodySize - storeOffset, storeHeader->StoreSize); + + umemstream is(volumeBody.constData() + storeOffset, storeSize); + kaitai::kstream ks(&is); + phoenix_evsa_t parsed(&ks); + + // Phoenix EVSA store at current offset parsed correctly + // Check if we need to add a padding before it + if (!outerPadding.isEmpty()) { + info = usprintf("Full size: %Xh (%u)", (UINT32)outerPadding.size(), (UINT32)outerPadding.size()); + model->addItem(localOffset + previousStoreEndOffset, Types::Padding, getPaddingType(outerPadding), UString("Padding"), UString(), info, UByteArray(), outerPadding, UByteArray(), Fixed, index); + outerPadding.clear(); } - else { // Variable is OK, rename it - if (dataHeader->Header.Type == NVRAM_EVSA_ENTRY_TYPE_DATA_INVALID) { - model->setSubtype(current, Subtypes::InvalidEvsaEntry); - model->setName(current, UString("Invalid")); + + // Construct header and body + header = volumeBody.mid(storeOffset, sizeof(EVSA_STORE_ENTRY)); + body = volumeBody.mid(storeOffset + header.size(), storeSize - header.size()); + + // Calculate header checksum + UINT8 calculated = calculateChecksum8(((const UINT8*)storeHeader) + 2, storeHeader->Header.Size - 2); + + // Add info + name = UString("Phoenix EVSA store"); + info = usprintf("Signature: EVSA\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nAttributes: %08Xh\nReserved: %08Xh\nChecksum: %02Xh", + storeSize, storeSize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + parsed.attributes(), + parsed.reserved(), + parsed.checksum()) + + (parsed.checksum() != calculated ? usprintf(", invalid, should be %02Xh", calculated) : UString(", valid")); + + // Add header tree item + UModelIndex headerIndex = model->addItem(localOffset + storeOffset, Types::EvsaStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, index); + + // Add entries + std::map guidMap; + std::map nameMap; + UINT32 entryOffset = parsed.len_evsa_store_header(); + for (const auto & entry : *parsed.body()->entries()) { + UINT8 subtype; + UINT32 entrySize; + + // This is the terminating entry, needs special processing + if (entry->_is_null_checksum()) { + // Add free space or padding after all variables, if needed + if (entryOffset < storeSize) { + UByteArray freeSpace = volumeBody.mid(storeOffset + entryOffset, storeSize - entryOffset); + // Add info + info = usprintf("Full size: %Xh (%u)", (UINT32)freeSpace.size(), (UINT32)freeSpace.size()); + + // Check that remaining unparsed bytes are actually empty + if (freeSpace.count(emptyByte) == freeSpace.size()) { // Free space + // Add tree item + model->addItem(entryOffset, Types::FreeSpace, 0, UString("Free space"), UString(), info, UByteArray(), freeSpace, UByteArray(), Fixed, headerIndex); + } + else { + // Add tree item + model->addItem(entryOffset, Types::Padding, getPaddingType(freeSpace), UString("Padding"), UString(), info, UByteArray(), freeSpace, UByteArray(), Fixed, headerIndex); + } + } + break; } - else { - model->setName(current, guid); + + const EVSA_ENTRY_HEADER* entryHeader = (const EVSA_ENTRY_HEADER*)(volumeBody.constData() + storeOffset + entryOffset); + calculated = calculateChecksum8(((const UINT8*)entryHeader) + 2, entryHeader->Size - 2); + + // GUID entry + if (entry->entry_type() == NVRAM_EVSA_ENTRY_TYPE_GUID1 || entry->entry_type() == NVRAM_EVSA_ENTRY_TYPE_GUID2) { + const phoenix_evsa_t::evsa_guid_t* guidEntry = (const phoenix_evsa_t::evsa_guid_t*)(entry->body()); + header = volumeBody.mid(storeOffset + entryOffset, sizeof(EVSA_GUID_ENTRY)); + body = volumeBody.mid(storeOffset + entryOffset + sizeof(EVSA_GUID_ENTRY), entry->len_evsa_entry() - header.size()); + entrySize = (UINT32)(header.size() + body.size()); + EFI_GUID guid = *(const EFI_GUID*)(guidEntry->guid().c_str()); + name = guidToUString(guid); + info = UString("GUID: ") + guidToUString(guid, false) + + usprintf("\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nType: %02Xh\nChecksum: %02Xh", + entrySize, entrySize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + entry->entry_type(), + entry->checksum()) + + (entry->checksum() != calculated ? usprintf(", invalid, should be %02Xh", calculated) : UString(", valid")) + + usprintf("\nGuidId: %04Xh", guidEntry->guid_id()); + subtype = Subtypes::GuidEvsaEntry; + guidMap.insert(std::pair(guidEntry->guid_id(), guid)); } - model->setText(current, name); - model->addInfo(current, UString("GUID: ") + guid + UString("\nName: ") + name + "\n", false); + // Name entry + else if (entry->entry_type() == NVRAM_EVSA_ENTRY_TYPE_NAME1 || entry->entry_type() == NVRAM_EVSA_ENTRY_TYPE_NAME2) { + const phoenix_evsa_t::evsa_name_t* nameEntry = (const phoenix_evsa_t::evsa_name_t*)(entry->body()); + header = volumeBody.mid(storeOffset + entryOffset, sizeof(EVSA_NAME_ENTRY)); + body = volumeBody.mid(storeOffset + entryOffset + sizeof(EVSA_NAME_ENTRY), entry->len_evsa_entry() - header.size()); + entrySize = (UINT32)(header.size() + body.size()); + name = uFromUcs2(body.constData()); + info = UString("Name: ") + name + + usprintf("\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nType: %02Xh\nChecksum: %02Xh", + entrySize, entrySize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + entry->entry_type(), + entry->checksum()) + + (entry->checksum() != calculated ? usprintf(", invalid, should be %02Xh", calculated) : UString(", valid")) + + usprintf("\nVarId: %04Xh", nameEntry->var_id()); + subtype = Subtypes::NameEvsaEntry; + nameMap.insert(std::pair(nameEntry->var_id(), name)); + } + // Data entry + else if (entry->entry_type() == NVRAM_EVSA_ENTRY_TYPE_DATA1 + || entry->entry_type() == NVRAM_EVSA_ENTRY_TYPE_DATA2 + || entry->entry_type() == NVRAM_EVSA_ENTRY_TYPE_DATA_INVALID) { + phoenix_evsa_t::evsa_data_t* dataEntry = (phoenix_evsa_t::evsa_data_t*)(entry->body()); + if (dataEntry->_is_null_len_data_ext()) { + header = volumeBody.mid(storeOffset + entryOffset, sizeof(EVSA_DATA_ENTRY)); + body = volumeBody.mid(storeOffset + entryOffset + sizeof(EVSA_DATA_ENTRY), entry->len_evsa_entry() - header.size()); + } + else { + header = volumeBody.mid(storeOffset + entryOffset, sizeof(EVSA_DATA_ENTRY_EXTENDED)); + body = volumeBody.mid(storeOffset + entryOffset + sizeof(EVSA_DATA_ENTRY_EXTENDED), dataEntry->len_data_ext()); + } + entrySize = (UINT32)(header.size() + body.size()); + name = UString("Data"); + subtype = Subtypes::DataEvsaEntry; + + const UINT32 attributes = dataEntry->attributes()->non_volatile() + + (dataEntry->attributes()->boot_service() << 1) + + (dataEntry->attributes()->runtime() << 2) + + (dataEntry->attributes()->hw_error_record() << 3) + + (dataEntry->attributes()->auth_write() << 4) + + (dataEntry->attributes()->time_based_auth() << 5) + + (dataEntry->attributes()->append_write() << 6) + + (UINT32)(dataEntry->attributes()->reserved() << 7) + + (dataEntry->attributes()->extended_header() << 28) + + (UINT32)(dataEntry->attributes()->reserved1() << 29); + + info = usprintf("Full size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)\nType: %02Xh\nChecksum: %02Xh", + entrySize, entrySize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size(), + entry->entry_type(), + entry->checksum()) + + (entry->checksum() != calculated ? usprintf(", invalid, should be %02Xh", calculated) : UString(", valid")) + + usprintf("\nVarId: %04Xh\nGuidId: %04Xh\nAttributes: %08Xh (", + dataEntry->var_id(), + dataEntry->guid_id(), + attributes) + + evsaAttributesToUString(attributes) + UString(")"); + } + + // Add tree item + model->addItem(entryOffset, Types::EvsaEntry, subtype, name, text, info, header, body, UByteArray(), Fixed, headerIndex); + + entryOffset += entrySize; } + + // Reparse all data variables to detect invalid ones and assign name and test to valid ones + for (int i = 0; i < model->rowCount(headerIndex); i++) { + UModelIndex current = headerIndex.model()->index(i, 0, headerIndex); + + if (model->subtype(current) == Subtypes::DataEvsaEntry) { + UByteArray header = model->header(current); + const EVSA_DATA_ENTRY* dataHeader = (const EVSA_DATA_ENTRY*)header.constData(); + UString guid; + if (guidMap.count(dataHeader->GuidId)) + guid = guidToUString(guidMap[dataHeader->GuidId], false); + UString name; + if (nameMap.count(dataHeader->VarId)) + name = nameMap[dataHeader->VarId]; + + // Check for variable validity + if (guid.isEmpty() && name.isEmpty()) { // Both name and guid aren't found + model->setSubtype(current, Subtypes::InvalidEvsaEntry); + model->setName(current, UString("Invalid")); + model->setText(current, UString()); + msg(usprintf("%s: data variable with invalid GuidId and invalid VarId", __FUNCTION__), current); + } + else if (guid.isEmpty()) { // Guid not found + model->setSubtype(current, Subtypes::InvalidEvsaEntry); + model->setName(current, UString("Invalid")); + model->setText(current, UString()); + msg(usprintf("%s: data variable with invalid GuidId", __FUNCTION__), current); + } + else if (name.isEmpty()) { // Name not found + model->setSubtype(current, Subtypes::InvalidEvsaEntry); + model->setName(current, UString("Invalid")); + model->setText(current, UString()); + msg(usprintf("%s: data variable with invalid VarId", __FUNCTION__), current); + } + else { // Variable is OK, rename it + if (dataHeader->Header.Type == NVRAM_EVSA_ENTRY_TYPE_DATA_INVALID) { + model->setSubtype(current, Subtypes::InvalidEvsaEntry); + model->setName(current, UString("Invalid")); + model->setText(current, UString()); + } + else { + model->setName(current, guid); + model->setText(current, name); + model->addInfo(current, UString("GUID: ") + guid + UString("\nName: ") + name + "\n", false); + } + } + } + } + + storeOffset += storeSize - 1; + previousStoreEndOffset = storeOffset + 1; + continue; + } catch (...) { + // Parsing failed, try something else + } + not_evsa: + // Phoenix CMDB store + try { + if (volumeBodySize - storeOffset < NVRAM_PHOENIX_CMDB_SIZE) { + // No need to parse further, the rest of the volume is too small + goto not_cmdb; + } + // Perform initial sanity check + const PHOENIX_CMDB_HEADER* storeHeader = (const PHOENIX_CMDB_HEADER*)(volumeBody.constData() + storeOffset); + if (storeHeader->Signature != NVRAM_PHOENIX_CMDB_HEADER_SIGNATURE) { + // No need to parse further, not a Phoenix CMDB store + goto not_cmdb; + } + UINT32 storeSize = NVRAM_PHOENIX_CMDB_SIZE; + + // CMDB store at current offset parsed correctly + // Check if we need to add a padding before it + if (!outerPadding.isEmpty()) { + info = usprintf("Full size: %Xh (%u)", (UINT32)outerPadding.size(), (UINT32)outerPadding.size()); + model->addItem(localOffset + previousStoreEndOffset, Types::Padding, getPaddingType(outerPadding), UString("Padding"), UString(), info, UByteArray(), outerPadding, UByteArray(), Fixed, index); + outerPadding.clear(); + } + + // Construct header and body + header = volumeBody.mid(storeOffset, storeHeader->TotalSize); + body = volumeBody.mid(storeOffset + header.size(), storeSize - header.size()); + + // Add info + name = UString("Phoenix CMDB store"); + info = usprintf("Signature: CMDB\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: %Xh (%u)", + storeSize, storeSize, + (UINT32)header.size(), (UINT32)header.size(), + (UINT32)body.size(), (UINT32)body.size()); + + // Add tree item + model->addItem(localOffset + storeOffset, Types::CmdbStore, 0, name, UString(), info, header, body, UByteArray(), Fixed, index); + + storeOffset += storeSize - 1; + previousStoreEndOffset = storeOffset + 1; + continue; + } catch (...) { + // Parsing failed, try something else + } +not_cmdb: + // SLIC PubKey + try { + if (volumeBodySize - storeOffset < sizeof(OEM_ACTIVATION_PUBKEY)) { + // No need to parse further, the rest of the volume is too small + goto not_pubkey; + } + // Perform initial sanity check + const OEM_ACTIVATION_PUBKEY* storeHeader = (const OEM_ACTIVATION_PUBKEY*)(volumeBody.constData() + storeOffset); + if (storeHeader->Magic != OEM_ACTIVATION_PUBKEY_MAGIC + || storeHeader->Type != OEM_ACTIVATION_PUBKEY_TYPE + || storeHeader->Size != sizeof(OEM_ACTIVATION_PUBKEY)) { + // No need to parse further, not a SLIC PubKey + goto not_pubkey; + } + UINT32 storeSize = sizeof(OEM_ACTIVATION_PUBKEY); + + umemstream is(volumeBody.constData() + storeOffset, storeSize); + kaitai::kstream ks(&is); + ms_slic_pubkey_t parsed(&ks); + + // SLIC PubKey at current offset parsed correctly + // Check if we need to add a padding before it + if (!outerPadding.isEmpty()) { + info = usprintf("Full size: %Xh (%u)", (UINT32)outerPadding.size(), (UINT32)outerPadding.size()); + model->addItem(localOffset + previousStoreEndOffset, Types::Padding, getPaddingType(outerPadding), UString("Padding"), UString(), info, UByteArray(), outerPadding, UByteArray(), Fixed, index); + outerPadding.clear(); + } + + // Construct header + header = volumeBody.mid(storeOffset, storeSize); + + // Add info + name = UString("SLIC pubkey"); + info = usprintf("Type: 0h\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: 0h (0)\n" + "Key type: %02Xh\nVersion: %02Xh\nAlgorithm: %08Xh\nMagic: RSA1\nBit length: %08Xh\nExponent: %08Xh", + parsed.len_pubkey(), parsed.len_pubkey(), + parsed.len_pubkey(), parsed.len_pubkey(), + parsed.key_type(), + parsed.version(), + parsed.algorithm(), + parsed.bit_length(), + parsed.exponent()); + + // Add tree item + model->addItem(localOffset + storeOffset, Types::SlicData, Subtypes::PubkeySlicData, name, UString(), info, header, UByteArray(), UByteArray(), Fixed, index); + + storeOffset += storeSize - 1; + previousStoreEndOffset = storeOffset + 1; + continue; + } catch (...) { + // Parsing failed, try something else + } +not_pubkey: + // SLIC marker + try { + if (volumeBodySize - storeOffset < sizeof(OEM_ACTIVATION_MARKER)) { + // No need to parse further, the rest of the volume is too small + goto not_marker; + } + // Perform initial sanity check + const OEM_ACTIVATION_MARKER* storeHeader = (const OEM_ACTIVATION_MARKER*)(volumeBody.constData() + storeOffset); + if (storeHeader->WindowsFlag != OEM_ACTIVATION_MARKER_WINDOWS_FLAG + || storeHeader->Type != OEM_ACTIVATION_MARKER_TYPE + || storeHeader->Size != sizeof(OEM_ACTIVATION_MARKER)) { + // No need to parse further, not a SLIC marker + goto not_marker; + } + // Check reserved bytes + for (UINT8 i = 0; i < sizeof(storeHeader->Reserved); i++) { + if (storeHeader->Reserved[i] != OEM_ACTIVATION_MARKER_RESERVED_BYTE) { + // No need to parse further, not a SLIC marker + goto not_marker; + } + } + UINT32 storeSize = sizeof(OEM_ACTIVATION_MARKER); + + umemstream is(volumeBody.constData() + storeOffset, storeSize); + kaitai::kstream ks(&is); + ms_slic_marker_t parsed(&ks); + + // SLIC marker at current offset parsed correctly + // Check if we need to add a padding before it + if (!outerPadding.isEmpty()) { + info = usprintf("Full size: %Xh (%u)", (UINT32)outerPadding.size(), (UINT32)outerPadding.size()); + model->addItem(localOffset + previousStoreEndOffset, Types::Padding, getPaddingType(outerPadding), UString("Padding"), UString(), info, UByteArray(), outerPadding, UByteArray(), Fixed, index); + outerPadding.clear(); + } + + // Construct header + header = volumeBody.mid(storeOffset, storeSize); + + // Add info + name = UString("SLIC marker"); + info = usprintf("Type: 1h\nFull size: %Xh (%u)\nHeader size: %Xh (%u)\nBody size: 0h (0)\n" + "Version: %08Xh\nOEM ID: %s\nOEM table ID: %s\nWindows flag: WINDOWS \nSLIC version: %08Xh", + parsed.len_marker(), parsed.len_marker(), + parsed.len_marker(), parsed.len_marker(), + parsed.version(), + parsed.oem_id().c_str(), + parsed.oem_table_id().c_str(), + parsed.slic_version()); + + // Add tree item + model->addItem(localOffset + storeOffset, Types::SlicData, Subtypes::MarkerSlicData, name, UString(), info, header, UByteArray(), UByteArray(), Fixed, index); + + storeOffset += storeSize - 1; + previousStoreEndOffset = storeOffset + 1; + continue; + } catch (...) { + // Parsing failed, try something else + } +not_marker: + // Intel uCode + try { + // Check data size + if (volumeBodySize - storeOffset < sizeof(INTEL_MICROCODE_HEADER)) { + goto not_ucode; + } + + const UINT32 currentUint32 = readUnaligned((const UINT32*)(volumeBody.constData() + storeOffset)); + if (currentUint32 != INTEL_MICROCODE_HEADER_VERSION_1) { + goto not_ucode; + } + + // Check microcode header candidate + const INTEL_MICROCODE_HEADER* ucodeHeader = (const INTEL_MICROCODE_HEADER*)(volumeBody.constData() + storeOffset); + if (FALSE == ffsParser->microcodeHeaderValid(ucodeHeader)) { + goto not_ucode; + } + + // Check candidate size + if (ucodeHeader->TotalSize == 0) { + goto not_ucode; + } + + // We still have enough data left to fit the whole TotalSize + UINT32 storeSize = ucodeHeader->TotalSize; + if (volumeBodySize - storeOffset < storeSize) { + goto not_ucode; + } + + // All checks passed, microcode found + // Check if we need to add a padding before it + if (!outerPadding.isEmpty()) { + info = usprintf("Full size: %Xh (%u)", (UINT32)outerPadding.size(), (UINT32)outerPadding.size()); + model->addItem(localOffset + previousStoreEndOffset, Types::Padding, getPaddingType(outerPadding), UString("Padding"), UString(), info, UByteArray(), outerPadding, UByteArray(), Fixed, index); + outerPadding.clear(); + } + + // Parse microcode header + UByteArray ucode = volumeBody.mid(storeOffset); + UModelIndex ucodeIndex; + if (U_SUCCESS != ffsParser->parseIntelMicrocodeHeader(ucode, localOffset + storeOffset, index, ucodeIndex)) { + goto not_ucode; + } + + storeOffset += storeSize - 1; + previousStoreEndOffset = storeOffset + 1; + continue; + } catch (...) { + // Parsing failed, try something else + } +not_ucode: + // FFS volume + try { + // Check data size + if (volumeBodySize - storeOffset < sizeof(EFI_FIRMWARE_VOLUME_HEADER)) { + goto not_ffs_volume; + } + + // Check volume header candidate + const EFI_FIRMWARE_VOLUME_HEADER* volumeHeader = (const EFI_FIRMWARE_VOLUME_HEADER*)(volumeBody.constData() + storeOffset); + if (volumeHeader->Signature != EFI_FV_SIGNATURE) { + goto not_ffs_volume; + } + + // All checks passed, volume found + UByteArray volume = volumeBody.mid(storeOffset); + UModelIndex volumeIndex; + if (U_SUCCESS != ffsParser->parseVolumeHeader(volume, localOffset + storeOffset, index, volumeIndex)) { + goto not_ffs_volume; + } + + (VOID)ffsParser->parseVolumeBody(volumeIndex); + UINT32 storeSize = (UINT32)(model->header(volumeIndex).size() + model->body(volumeIndex).size()); + + storeOffset += storeSize - 1; + previousStoreEndOffset = storeOffset + 1; + continue; + } catch (...) { + // Parsing failed, try something else + } +not_ffs_volume: + // Padding + if (storeOffset < volumeBodySize) { + outerPadding += volumeBody[storeOffset]; } } - - return U_SUCCESS; -} - -USTATUS NvramParser::parseFlashMapBody(const UModelIndex & index) -{ - // Sanity check - if (!index.isValid()) - return U_INVALID_PARAMETER; - - // Get parsing data for the current item - UINT32 localOffset = (UINT32)model->header(index).size(); - const UByteArray data = model->body(index); - - - const UINT32 dataSize = (UINT32)data.size(); - UINT32 offset = 0; - UINT32 unparsedSize = dataSize; - // Parse all entries - while (unparsedSize) { - const PHOENIX_FLASH_MAP_ENTRY* entryHeader = (const PHOENIX_FLASH_MAP_ENTRY*)(data.constData() + offset); - - // Check entry size - if (unparsedSize < sizeof(PHOENIX_FLASH_MAP_ENTRY)) { - // Last variable is bad, add the rest as padding and return - UByteArray body = data.mid(offset); - UString info = usprintf("Full size: %Xh (%u)", (UINT32)body.size(), (UINT32)body.size()); - - // Add padding tree item - model->addItem(localOffset + offset, Types::Padding, getPaddingType(body), UString("Padding"), UString(), info, UByteArray(), body, UByteArray(), Fixed, index); - - // Show message - if (unparsedSize < entryHeader->Size) - msg(usprintf("%s: next entry appears too big, added as padding", __FUNCTION__), index); - - break; - } - - UString name = guidToUString(entryHeader->Guid); - - // Construct header - UByteArray header = data.mid(offset, sizeof(PHOENIX_FLASH_MAP_ENTRY)); - + // Add padding at the very end + if (!outerPadding.isEmpty()) { // Add info - UString info = UString("Entry GUID: ") + guidToUString(entryHeader->Guid, false) + - usprintf("\nFull size: 24h (36)\nHeader size: 24h (36)\nBody size: 0h (0)\n" - "Entry type: %04Xh\nData type: %04Xh\nMemory address: %08Xh\nSize: %08Xh\nOffset: %08Xh", - entryHeader->EntryType, - entryHeader->DataType, - (UINT32)entryHeader->PhysicalAddress, - entryHeader->Size, - entryHeader->Offset); + UString info = usprintf("Full size: %Xh (%u)", (UINT32)outerPadding.size(), (UINT32)outerPadding.size()); - // Determine subtype - UINT8 subtype = 0; - switch (entryHeader->DataType) { - case NVRAM_PHOENIX_FLASH_MAP_ENTRY_TYPE_VOLUME: - subtype = Subtypes::VolumeFlashMapEntry; - break; - case NVRAM_PHOENIX_FLASH_MAP_ENTRY_TYPE_DATA_BLOCK: - subtype = Subtypes::DataFlashMapEntry; - break; + // Check that remaining unparsed bytes are actually empty + if (outerPadding.count(emptyByte) == outerPadding.size()) { + // Add tree item + model->addItem(localOffset + previousStoreEndOffset, Types::FreeSpace, 0, UString("Free space"), UString(), info, UByteArray(), outerPadding, UByteArray(), Fixed, index); + } + else { + // Add tree item + model->addItem(localOffset + previousStoreEndOffset, Types::Padding, getPaddingType(outerPadding), UString("Padding"), UString(), info, UByteArray(), outerPadding, UByteArray(), Fixed, index); } - - // Add tree item - model->addItem(localOffset + offset, Types::FlashMapEntry, subtype, name, flashMapGuidToUString(entryHeader->Guid), info, header, UByteArray(), UByteArray(), Fixed, index); - - // Move to next variable - offset += sizeof(PHOENIX_FLASH_MAP_ENTRY); - unparsedSize = dataSize - offset; } - + return U_SUCCESS; } #endif // U_ENABLE_NVRAM_PARSING_SUPPORT diff --git a/common/nvramparser.h b/common/nvramparser.h index 3a50c5d..a64e795 100644 --- a/common/nvramparser.h +++ b/common/nvramparser.h @@ -37,7 +37,7 @@ public: void clearMessages() { messagesVector.clear(); } // NVRAM parsing - USTATUS parseNvramVolumeBody(const UModelIndex & index); + USTATUS parseNvramVolumeBody(const UModelIndex & index, const UINT32 fdcStoreSizeOverride = 0); USTATUS parseNvarStore(const UModelIndex & index); private: @@ -47,27 +47,6 @@ private: void msg(const UString & message, const UModelIndex & index = UModelIndex()) { messagesVector.push_back(std::pair(message, index)); }; - - USTATUS findNextStore(const UModelIndex & index, const UByteArray & volume, const UINT32 localOffset, const UINT32 storeOffset, UINT32 & nextStoreOffset); - USTATUS getStoreSize(const UByteArray & data, const UINT32 storeOffset, UINT32 & storeSize); - USTATUS parseStoreHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index); - - USTATUS parseVssStoreHeader(const UByteArray & store, const UINT32 localOffset, const bool sizeOverride, const UModelIndex & parent, UModelIndex & index); - USTATUS parseVss2StoreHeader(const UByteArray & store, const UINT32 localOffset, const bool sizeOverride, const UModelIndex & parent, UModelIndex & index); - USTATUS parseFtwStoreHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index); - USTATUS parseFdcStoreHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index); - USTATUS parseFsysStoreHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index); - USTATUS parseEvsaStoreHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index); - USTATUS parseFlashMapStoreHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index); - USTATUS parseCmdbStoreHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index); - USTATUS parseSlicPubkeyHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index); - USTATUS parseSlicMarkerHeader(const UByteArray & store, const UINT32 localOffset, const UModelIndex & parent, UModelIndex & index); - - USTATUS parseFdcStoreBody(const UModelIndex & index); - USTATUS parseVssStoreBody(const UModelIndex & index, const UINT8 alignment); - USTATUS parseFsysStoreBody(const UModelIndex & index); - USTATUS parseEvsaStoreBody(const UModelIndex & index); - USTATUS parseFlashMapBody(const UModelIndex & index); }; #else class NvramParser diff --git a/common/types.cpp b/common/types.cpp index 32e3791..3ee9ed1 100755 --- a/common/types.cpp +++ b/common/types.cpp @@ -42,45 +42,49 @@ UString regionTypeToUString(const UINT8 type) UString itemTypeToUString(const UINT8 type) { switch (type) { - case Types::Root: return UString("Root"); - case Types::Image: return UString("Image"); - case Types::Capsule: return UString("Capsule"); - case Types::Region: return UString("Region"); - case Types::Volume: return UString("Volume"); - case Types::Padding: return UString("Padding"); - case Types::File: return UString("File"); - case Types::Section: return UString("Section"); - case Types::FreeSpace: return UString("Free space"); - case Types::VssStore: return UString("VSS store"); - case Types::Vss2Store: return UString("VSS2 store"); - case Types::FtwStore: return UString("FTW store"); - case Types::FdcStore: return UString("FDC store"); - case Types::FsysStore: return UString("Fsys store"); - case Types::EvsaStore: return UString("EVSA store"); - case Types::CmdbStore: return UString("CMDB store"); - case Types::FlashMapStore: return UString("FlashMap store"); - case Types::NvarGuidStore: return UString("NVAR GUID store"); - case Types::NvarEntry: return UString("NVAR entry"); - case Types::VssEntry: return UString("VSS entry"); - case Types::FsysEntry: return UString("Fsys entry"); - case Types::EvsaEntry: return UString("EVSA entry"); - case Types::FlashMapEntry: return UString("FlashMap entry"); - case Types::Microcode: return UString("Microcode"); - case Types::SlicData: return UString("SLIC data"); - case Types::FptStore: return UString("FPT store"); - case Types::FptEntry: return UString("FPT entry"); - case Types::IfwiHeader: return UString("IFWI header"); - case Types::IfwiPartition: return UString("IFWI partition"); - case Types::FptPartition: return UString("FPT partition"); - case Types::BpdtStore: return UString("BPDT store"); - case Types::BpdtEntry: return UString("BPDT entry"); - case Types::BpdtPartition: return UString("BPDT partition"); - case Types::CpdStore: return UString("CPD store"); - case Types::CpdEntry: return UString("CPD entry"); - case Types::CpdPartition: return UString("CPD partition"); - case Types::CpdExtension: return UString("CPD extension"); - case Types::CpdSpiEntry: return UString("CPD SPI entry"); - case Types::StartupApDataEntry: return UString("Startup AP data"); + case Types::Root: return UString("Root"); + case Types::Image: return UString("Image"); + case Types::Capsule: return UString("Capsule"); + case Types::Region: return UString("Region"); + case Types::Volume: return UString("Volume"); + case Types::Padding: return UString("Padding"); + case Types::File: return UString("File"); + case Types::Section: return UString("Section"); + case Types::FreeSpace: return UString("Free space"); + case Types::VssStore: return UString("VSS store"); + case Types::Vss2Store: return UString("VSS2 store"); + case Types::FtwStore: return UString("FTW store"); + case Types::FdcStore: return UString("FDC store"); + case Types::SysFStore: return UString("SysF store"); + case Types::EvsaStore: return UString("EVSA store"); + case Types::CmdbStore: return UString("CMDB store"); + case Types::PhoenixFlashMapStore: return UString("FlashMap store"); + case Types::InsydeFlashDeviceMapStore: return UString("FlashDeviceMap store"); + case Types::DellDvarStore: return UString("DVAR store"); + case Types::NvarGuidStore: return UString("NVAR GUID store"); + case Types::NvarEntry: return UString("NVAR entry"); + case Types::VssEntry: return UString("VSS entry"); + case Types::SysFEntry: return UString("SysF entry"); + case Types::EvsaEntry: return UString("EVSA entry"); + case Types::PhoenixFlashMapEntry: return UString("FlashMap entry"); + case Types::InsydeFlashDeviceMapEntry: return UString("FlashDeviceMap entry"); + case Types::DellDvarEntry: return UString("DVAR entry"); + case Types::Microcode: return UString("Microcode"); + case Types::SlicData: return UString("SLIC data"); + case Types::FptStore: return UString("FPT store"); + case Types::FptEntry: return UString("FPT entry"); + case Types::IfwiHeader: return UString("IFWI header"); + case Types::IfwiPartition: return UString("IFWI partition"); + case Types::FptPartition: return UString("FPT partition"); + case Types::BpdtStore: return UString("BPDT store"); + case Types::BpdtEntry: return UString("BPDT entry"); + case Types::BpdtPartition: return UString("BPDT partition"); + case Types::CpdStore: return UString("CPD store"); + case Types::CpdEntry: return UString("CPD entry"); + case Types::CpdPartition: return UString("CPD partition"); + case Types::CpdExtension: return UString("CPD extension"); + case Types::CpdSpiEntry: return UString("CPD SPI entry"); + case Types::StartupApDataEntry: return UString("Startup AP data"); } return usprintf("Unknown %02Xh", type); @@ -128,9 +132,9 @@ UString itemSubtypeToUString(const UINT8 type, const UINT8 subtype) else if (subtype == Subtypes::AuthVssEntry) return UString("Auth"); else if (subtype == Subtypes::IntelVssEntry) return UString("Intel"); break; - case Types::FsysEntry: - if (subtype == Subtypes::InvalidFsysEntry) return UString("Invalid"); - else if (subtype == Subtypes::NormalFsysEntry) return UString("Normal"); + case Types::SysFEntry: + if (subtype == Subtypes::InvalidSysFEntry) return UString("Invalid"); + else if (subtype == Subtypes::NormalSysFEntry) return UString("Normal"); break; case Types::EvsaEntry: if (subtype == Subtypes::InvalidEvsaEntry) return UString("Invalid"); @@ -139,9 +143,16 @@ UString itemSubtypeToUString(const UINT8 type, const UINT8 subtype) else if (subtype == Subtypes::NameEvsaEntry) return UString("Name"); else if (subtype == Subtypes::DataEvsaEntry) return UString("Data"); break; - case Types::FlashMapEntry: + case Types::PhoenixFlashMapEntry: if (subtype == Subtypes::VolumeFlashMapEntry) return UString("Volume"); else if (subtype == Subtypes::DataFlashMapEntry) return UString("Data"); + else if (subtype == Subtypes::UnknownFlashMapEntry) return UString("Unknown"); + break; + case Types::DellDvarEntry: + if (subtype == Subtypes::InvalidDvarEntry) return UString("Invalid"); + else if (subtype == Subtypes::NamespaceGuidDvarEntry) return UString("NamespaceGuid"); + else if (subtype == Subtypes::NameIdDvarEntry) return UString("NameId"); + else if (subtype == Subtypes::UnknownDvarEntry) return UString("Unknown"); break; case Types::Microcode: if (subtype == Subtypes::IntelMicrocode) return UString("Intel"); @@ -249,3 +260,29 @@ UString hashTypeToUString(const UINT16 algorithm_id) return usprintf("Unknown %04Xh", algorithm_id); } + +UString insydeFlashDeviceMapEntryTypeGuidToUString(const EFI_GUID & guid) +{ + const UByteArray baGuid((const char*)&guid, sizeof(EFI_GUID)); + if (baGuid == INSYDE_FLASH_MAP_REGION_BOOT_FV_GUID) return UString("Boot Firmare Volume"); + if (baGuid == INSYDE_FLASH_MAP_REGION_BVDT_GUID) return UString("BIOS Version Data Table"); + if (baGuid == INSYDE_FLASH_MAP_REGION_EC_GUID) return UString("EC Firmware"); + if (baGuid == INSYDE_FLASH_MAP_REGION_FTW_BACKUP_GUID) return UString("FTW Backup"); + if (baGuid == INSYDE_FLASH_MAP_REGION_FTW_STATE_GUID) return UString("FTW State"); + if (baGuid == INSYDE_FLASH_MAP_REGION_FV_GUID) return UString("Firmare Volume"); + if (baGuid == INSYDE_FLASH_MAP_REGION_FLASH_DEVICE_MAP_GUID) return UString("Flash Device Map"); + if (baGuid == INSYDE_FLASH_MAP_REGION_LOGO_GUID) return UString("Logo"); + if (baGuid == INSYDE_FLASH_MAP_REGION_MICROCODE_GUID) return UString("Microcode"); + if (baGuid == INSYDE_FLASH_MAP_REGION_MSDM_TABLE_GUID) return UString("MSDM Table"); + if (baGuid == INSYDE_FLASH_MAP_REGION_MULTI_CONFIG_GUID) return UString("MultiConfig"); + if (baGuid == INSYDE_FLASH_MAP_REGION_VAR_DEFAULT_GUID) return UString("Variable Defaults"); + if (baGuid == INSYDE_FLASH_MAP_REGION_SMBIOS_UPDATE_GUID) return UString("SMBIOS Update"); + if (baGuid == INSYDE_FLASH_MAP_REGION_VAR_GUID) return UString("Variables"); + if (baGuid == INSYDE_FLASH_MAP_REGION_UNKNOWN_GUID) return UString("Unknown"); + if (baGuid == INSYDE_FLASH_MAP_REGION_UNUSED_GUID) return UString("Unused"); + if (baGuid == INSYDE_FLASH_MAP_REGION_USB_OPTION_ROM_GUID) return UString("USB Option ROM"); + if (baGuid == INSYDE_FLASH_MAP_REGION_DXE_FV_GUID) return UString("DXE Firmare Volume"); + if (baGuid == INSYDE_FLASH_MAP_REGION_PEI_FV_GUID) return UString("PEI Firmare Volume"); + if (baGuid == INSYDE_FLASH_MAP_REGION_UNSIGNED_FV_GUID) return UString("Unsigned Firmare Volume"); + return guidToUString(guid); +} diff --git a/common/types.h b/common/types.h index 5785a96..e82d4bd 100755 --- a/common/types.h +++ b/common/types.h @@ -47,16 +47,20 @@ namespace Types { Vss2Store, FtwStore, FdcStore, - FsysStore, + SysFStore, EvsaStore, - FlashMapStore, + PhoenixFlashMapStore, + InsydeFlashDeviceMapStore, + DellDvarStore, CmdbStore, NvarGuidStore, NvarEntry, VssEntry, - FsysEntry, + SysFEntry, EvsaEntry, - FlashMapEntry, + PhoenixFlashMapEntry, + InsydeFlashDeviceMapEntry, + DellDvarEntry, Microcode, SlicData, IfwiHeader, @@ -138,9 +142,9 @@ namespace Subtypes { IntelVssEntry, }; - enum FsysEntrySubtypes { - InvalidFsysEntry = 150, - NormalFsysEntry, + enum SysFEntrySubtypes { + InvalidSysFEntry = 150, + NormalSysFEntry, }; enum EvsaEntrySubtypes { @@ -154,44 +158,52 @@ namespace Subtypes { enum FlashMapEntrySubtypes { VolumeFlashMapEntry = 170, DataFlashMapEntry, + UnknownFlashMapEntry, + }; + + enum DvarEntrySubtypes { + InvalidDvarEntry = 180, + NamespaceGuidDvarEntry, + NameIdDvarEntry, + UnknownDvarEntry }; enum MicrocodeSubtypes { - IntelMicrocode = 180, + IntelMicrocode = 190, AmdMicrocode, }; enum SlicDataSubtypes { - PubkeySlicData = 190, + PubkeySlicData = 200, MarkerSlicData, }; // ME-specific enum IfwiPartitionSubtypes { - DataIfwiPartition = 200, + DataIfwiPartition = 210, BootIfwiPartition, }; enum FptEntrySubtypes { - ValidFptEntry = 210, + ValidFptEntry = 220, InvalidFptEntry, }; enum FptPartitionSubtypes { - CodeFptPartition = 220, + CodeFptPartition = 230, DataFptPartition, GlutFptPartition, }; enum CpdPartitionSubtypes { - ManifestCpdPartition = 230, + ManifestCpdPartition = 240, MetadataCpdPartition, KeyCpdPartition, CodeCpdPartition, }; enum StartupApDataEntrySubtypes { - x86128kStartupApDataEntry = 240, + x86128kStartupApDataEntry = 250, }; } @@ -203,5 +215,6 @@ extern UString compressionTypeToUString(const UINT8 algorithm); extern UString regionTypeToUString(const UINT8 type); extern UString fitEntryTypeToUString(const UINT8 type); extern UString hashTypeToUString(const UINT16 digest_agorithm_id); +extern UString insydeFlashDeviceMapEntryTypeGuidToUString(const EFI_GUID & guid); #endif // TYPES_H diff --git a/common/ubytearray.h b/common/ubytearray.h index b72faca..1623403 100644 --- a/common/ubytearray.h +++ b/common/ubytearray.h @@ -69,6 +69,7 @@ public: UByteArray & operator=(const UByteArray & ba) { d = ba.d; return *this; } UByteArray & operator+=(const UByteArray & ba) { d += ba.d; return *this; } + UByteArray & operator+=(const char c) { d += c; return *this; } bool operator== (const UByteArray & ba) const { return d == ba.d; } bool operator!= (const UByteArray & ba) const { return d != ba.d; } inline void swap(UByteArray &other) { std::swap(d, other.d); } diff --git a/common/utility.cpp b/common/utility.cpp index 336b7c7..612f3da 100755 --- a/common/utility.cpp +++ b/common/utility.cpp @@ -81,9 +81,10 @@ UString uniqueItemName(const UModelIndex & index) switch (model->type(index)) { case Types::NvarEntry: case Types::VssEntry: - case Types::FsysEntry: + case Types::SysFEntry: case Types::EvsaEntry: - case Types::FlashMapEntry: + case Types::PhoenixFlashMapEntry: + case Types::InsydeFlashDeviceMapEntry: case Types::File: name = itemText.isEmpty() ? itemName : itemName + '_' + itemText; break; @@ -355,11 +356,7 @@ USTATUS decompress(const UByteArray & compressedData, const UINT8 compressionTyp // TODO: need to correctly handle non-x86 architecture of the FW image // After LZMA decompression, the data need to be converted to the raw data. UINT32 state = 0; - const UINT8 x86LookAhead = 4; - if (decompressedSize != x86LookAhead + x86_Convert(decompressed, decompressedSize, 0, &state, 0)) { - free(decompressed); - return U_CUSTOMIZED_DECOMPRESSION_FAILED; - } + z7_BranchConvSt_X86_Dec(decompressed, decompressedSize, 0, &state); dictionarySize = readUnaligned((UINT32*)(data + 1)); // LZMA dictionary size is stored in bytes 1-4 of LZMA properties header decompressedData = UByteArray((const char*)decompressed, (int)decompressedSize); @@ -373,8 +370,6 @@ USTATUS decompress(const UByteArray & compressedData, const UINT8 compressionTyp } } - - // 8bit sum calculation routine UINT8 calculateSum8(const UINT8* buffer, UINT32 bufferSize) { @@ -461,7 +456,7 @@ INTN findPattern(const UINT8 *pattern, const UINT8 *patternMask, UINTN patternSi if (patternSize == 0 || dataSize == 0 || dataOff >= dataSize || dataSize - dataOff < patternSize) return -1; - while (dataOff + patternSize < dataSize) { + while (dataOff + patternSize <= dataSize) { bool matches = true; for (UINTN i = 0; i < patternSize; i++) { if ((data[dataOff + i] & patternMask[i]) != pattern[i]) { @@ -577,3 +572,12 @@ USTATUS zlibDecompress(const UByteArray& input, UByteArray& output) inflateEnd(&stream); return ret == Z_STREAM_END ? U_SUCCESS : U_ZLIB_DECOMPRESSION_FAILED; } + +UString fourCC(const UINT32 value) +{ + const UINT8 byte0 = (const UINT8)(value & 0xFF); + const UINT8 byte1 = (const UINT8)((value & 0xFF00) >> 8); + const UINT8 byte2 = (const UINT8)((value & 0xFF0000) >> 16); + const UINT8 byte3 = (const UINT8)((value & 0xFF000000) >> 24); + return usprintf("%c%c%c%c", byte0, byte1, byte2, byte3); +} diff --git a/common/utility.h b/common/utility.h index 7a24e2a..505d217 100755 --- a/common/utility.h +++ b/common/utility.h @@ -23,6 +23,9 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #include "treemodel.h" #include "parsingdata.h" +// Returns text representation of 4CC value +UString fourCC(const UINT32 value); + // Returns bytes as string when all bytes are ascii visible, hex representation otherwise UString visibleAsciiOrHex(UINT8* bytes, UINT32 length); @@ -70,7 +73,7 @@ INTN findPattern(const UINT8 *pattern, const UINT8 *patternMask, UINTN patternSi template inline T readUnaligned(const T *v) { T tmp = {}; - memcpy(&tmp, v, sizeof(T)); + memcpy(reinterpret_cast(&tmp), reinterpret_cast(v), sizeof(T)); return tmp; } diff --git a/common/zlib/ChangeLog b/common/zlib/ChangeLog new file mode 100644 index 0000000..b801a10 --- /dev/null +++ b/common/zlib/ChangeLog @@ -0,0 +1,1618 @@ + + ChangeLog file for zlib + +Changes in 1.3.1 (22 Jan 2024) +- Reject overflows of zip header fields in minizip +- Fix bug in inflateSync() for data held in bit buffer +- Add LIT_MEM define to use more memory for a small deflate speedup +- Fix decision on the emission of Zip64 end records in minizip +- Add bounds checking to ERR_MSG() macro, used by zError() +- Neutralize zip file traversal attacks in miniunz +- Fix a bug in ZLIB_DEBUG compiles in check_match() +- Various portability and appearance improvements + +Changes in 1.3 (18 Aug 2023) +- Remove K&R function definitions and zlib2ansi +- Fix bug in deflateBound() for level 0 and memLevel 9 +- Fix bug when gzungetc() is used immediately after gzopen() +- Fix bug when using gzflush() with a very small buffer +- Fix crash when gzsetparams() attempted for transparent write +- Fix test/example.c to work with FORCE_STORED +- Rewrite of zran in examples (see zran.c version history) +- Fix minizip to allow it to open an empty zip file +- Fix reading disk number start on zip64 files in minizip +- Fix logic error in minizip argument processing +- Add minizip testing to Makefile +- Read multiple bytes instead of byte-by-byte in minizip unzip.c +- Add memory sanitizer to configure (--memory) +- Various portability improvements +- Various documentation improvements +- Various spelling and typo corrections + +Changes in 1.2.13 (13 Oct 2022) +- Fix configure issue that discarded provided CC definition +- Correct incorrect inputs provided to the CRC functions +- Repair prototypes and exporting of new CRC functions +- Fix inflateBack to detect invalid input with distances too far +- Have infback() deliver all of the available output up to any error +- Fix a bug when getting a gzip header extra field with inflate() +- Fix bug in block type selection when Z_FIXED used +- Tighten deflateBound bounds +- Remove deleted assembler code references +- Various portability and appearance improvements + +Changes in 1.2.12 (27 Mar 2022) +- Cygwin does not have _wopen(), so do not create gzopen_w() there +- Permit a deflateParams() parameter change as soon as possible +- Limit hash table inserts after switch from stored deflate +- Fix bug when window full in deflate_stored() +- Fix CLEAR_HASH macro to be usable as a single statement +- Avoid a conversion error in gzseek when off_t type too small +- Have Makefile return non-zero error code on test failure +- Avoid some conversion warnings in gzread.c and gzwrite.c +- Update use of errno for newer Windows CE versions +- Small speedup to inflate [psumbera] +- Return an error if the gzputs string length can't fit in an int +- Add address checking in clang to -w option of configure +- Don't compute check value for raw inflate if asked to validate +- Handle case where inflateSync used when header never processed +- Avoid the use of ptrdiff_t +- Avoid an undefined behavior of memcpy() in gzappend() +- Avoid undefined behaviors of memcpy() in gz*printf() +- Avoid an undefined behavior of memcpy() in _tr_stored_block() +- Make the names in functions declarations identical to definitions +- Remove old assembler code in which bugs have manifested +- Fix deflateEnd() to not report an error at start of raw deflate +- Add legal disclaimer to README +- Emphasize the need to continue decompressing gzip members +- Correct the initialization requirements for deflateInit2() +- Fix a bug that can crash deflate on some input when using Z_FIXED +- Assure that the number of bits for deflatePrime() is valid +- Use a structure to make globals in enough.c evident +- Use a macro for the printf format of big_t in enough.c +- Clean up code style in enough.c, update version +- Use inline function instead of macro for index in enough.c +- Clarify that prefix codes are counted in enough.c +- Show all the codes for the maximum tables size in enough.c +- Add gznorm.c example, which normalizes gzip files +- Fix the zran.c example to work on a multiple-member gzip file +- Add tables for crc32_combine(), to speed it up by a factor of 200 +- Add crc32_combine_gen() and crc32_combine_op() for fast combines +- Speed up software CRC-32 computation by a factor of 1.5 to 3 +- Use atomic test and set, if available, for dynamic CRC tables +- Don't bother computing check value after successful inflateSync() +- Correct comment in crc32.c +- Add use of the ARMv8 crc32 instructions when requested +- Use ARM crc32 instructions if the ARM architecture has them +- Explicitly note that the 32-bit check values are 32 bits +- Avoid adding empty gzip member after gzflush with Z_FINISH +- Fix memory leak on error in gzlog.c +- Fix error in comment on the polynomial representation of a byte +- Clarify gz* function interfaces, referring to parameter names +- Change macro name in inflate.c to avoid collision in VxWorks +- Correct typo in blast.c +- Improve portability of contrib/minizip +- Fix indentation in minizip's zip.c +- Replace black/white with allow/block. (theresa-m) +- minizip warning fix if MAXU32 already defined. (gvollant) +- Fix unztell64() in minizip to work past 4GB. (Daniël Hörchner) +- Clean up minizip to reduce warnings for testing +- Add fallthrough comments for gcc +- Eliminate use of ULL constants +- Separate out address sanitizing from warnings in configure +- Remove destructive aspects of make distclean +- Check for cc masquerading as gcc or clang in configure +- Fix crc32.c to compile local functions only if used + +Changes in 1.2.11 (15 Jan 2017) +- Fix deflate stored bug when pulling last block from window +- Permit immediate deflateParams changes before any deflate input + +Changes in 1.2.10 (2 Jan 2017) +- Avoid warnings on snprintf() return value +- Fix bug in deflate_stored() for zero-length input +- Fix bug in gzwrite.c that produced corrupt gzip files +- Remove files to be installed before copying them in Makefile.in +- Add warnings when compiling with assembler code + +Changes in 1.2.9 (31 Dec 2016) +- Fix contrib/minizip to permit unzipping with desktop API [Zouzou] +- Improve contrib/blast to return unused bytes +- Assure that gzoffset() is correct when appending +- Improve compress() and uncompress() to support large lengths +- Fix bug in test/example.c where error code not saved +- Remedy Coverity warning [Randers-Pehrson] +- Improve speed of gzprintf() in transparent mode +- Fix inflateInit2() bug when windowBits is 16 or 32 +- Change DEBUG macro to ZLIB_DEBUG +- Avoid uninitialized access by gzclose_w() +- Allow building zlib outside of the source directory +- Fix bug that accepted invalid zlib header when windowBits is zero +- Fix gzseek() problem on MinGW due to buggy _lseeki64 there +- Loop on write() calls in gzwrite.c in case of non-blocking I/O +- Add --warn (-w) option to ./configure for more compiler warnings +- Reject a window size of 256 bytes if not using the zlib wrapper +- Fix bug when level 0 used with Z_HUFFMAN or Z_RLE +- Add --debug (-d) option to ./configure to define ZLIB_DEBUG +- Fix bugs in creating a very large gzip header +- Add uncompress2() function, which returns the input size used +- Assure that deflateParams() will not switch functions mid-block +- Dramatically speed up deflation for level 0 (storing) +- Add gzfread(), duplicating the interface of fread() +- Add gzfwrite(), duplicating the interface of fwrite() +- Add deflateGetDictionary() function +- Use snprintf() for later versions of Microsoft C +- Fix *Init macros to use z_ prefix when requested +- Replace as400 with os400 for OS/400 support [Monnerat] +- Add crc32_z() and adler32_z() functions with size_t lengths +- Update Visual Studio project files [AraHaan] + +Changes in 1.2.8 (28 Apr 2013) +- Update contrib/minizip/iowin32.c for Windows RT [Vollant] +- Do not force Z_CONST for C++ +- Clean up contrib/vstudio [Roß] +- Correct spelling error in zlib.h +- Fix mixed line endings in contrib/vstudio + +Changes in 1.2.7.3 (13 Apr 2013) +- Fix version numbers and DLL names in contrib/vstudio/*/zlib.rc + +Changes in 1.2.7.2 (13 Apr 2013) +- Change check for a four-byte type back to hexadecimal +- Fix typo in win32/Makefile.msc +- Add casts in gzwrite.c for pointer differences + +Changes in 1.2.7.1 (24 Mar 2013) +- Replace use of unsafe string functions with snprintf if available +- Avoid including stddef.h on Windows for Z_SOLO compile [Niessink] +- Fix gzgetc undefine when Z_PREFIX set [Turk] +- Eliminate use of mktemp in Makefile (not always available) +- Fix bug in 'F' mode for gzopen() +- Add inflateGetDictionary() function +- Correct comment in deflate.h +- Use _snprintf for snprintf in Microsoft C +- On Darwin, only use /usr/bin/libtool if libtool is not Apple +- Delete "--version" file if created by "ar --version" [Richard G.] +- Fix configure check for veracity of compiler error return codes +- Fix CMake compilation of static lib for MSVC2010 x64 +- Remove unused variable in infback9.c +- Fix argument checks in gzlog_compress() and gzlog_write() +- Clean up the usage of z_const and respect const usage within zlib +- Clean up examples/gzlog.[ch] comparisons of different types +- Avoid shift equal to bits in type (caused endless loop) +- Fix uninitialized value bug in gzputc() introduced by const patches +- Fix memory allocation error in examples/zran.c [Nor] +- Fix bug where gzopen(), gzclose() would write an empty file +- Fix bug in gzclose() when gzwrite() runs out of memory +- Check for input buffer malloc failure in examples/gzappend.c +- Add note to contrib/blast to use binary mode in stdio +- Fix comparisons of differently signed integers in contrib/blast +- Check for invalid code length codes in contrib/puff +- Fix serious but very rare decompression bug in inftrees.c +- Update inflateBack() comments, since inflate() can be faster +- Use underscored I/O function names for WINAPI_FAMILY +- Add _tr_flush_bits to the external symbols prefixed by --zprefix +- Add contrib/vstudio/vc10 pre-build step for static only +- Quote --version-script argument in CMakeLists.txt +- Don't specify --version-script on Apple platforms in CMakeLists.txt +- Fix casting error in contrib/testzlib/testzlib.c +- Fix types in contrib/minizip to match result of get_crc_table() +- Simplify contrib/vstudio/vc10 with 'd' suffix +- Add TOP support to win32/Makefile.msc +- Support i686 and amd64 assembler builds in CMakeLists.txt +- Fix typos in the use of _LARGEFILE64_SOURCE in zconf.h +- Add vc11 and vc12 build files to contrib/vstudio +- Add gzvprintf() as an undocumented function in zlib +- Fix configure for Sun shell +- Remove runtime check in configure for four-byte integer type +- Add casts and consts to ease user conversion to C++ +- Add man pages for minizip and miniunzip +- In Makefile uninstall, don't rm if preceding cd fails +- Do not return Z_BUF_ERROR if deflateParam() has nothing to write + +Changes in 1.2.7 (2 May 2012) +- Replace use of memmove() with a simple copy for portability +- Test for existence of strerror +- Restore gzgetc_ for backward compatibility with 1.2.6 +- Fix build with non-GNU make on Solaris +- Require gcc 4.0 or later on Mac OS X to use the hidden attribute +- Include unistd.h for Watcom C +- Use __WATCOMC__ instead of __WATCOM__ +- Do not use the visibility attribute if NO_VIZ defined +- Improve the detection of no hidden visibility attribute +- Avoid using __int64 for gcc or solo compilation +- Cast to char * in gzprintf to avoid warnings [Zinser] +- Fix make_vms.com for VAX [Zinser] +- Don't use library or built-in byte swaps +- Simplify test and use of gcc hidden attribute +- Fix bug in gzclose_w() when gzwrite() fails to allocate memory +- Add "x" (O_EXCL) and "e" (O_CLOEXEC) modes support to gzopen() +- Fix bug in test/minigzip.c for configure --solo +- Fix contrib/vstudio project link errors [Mohanathas] +- Add ability to choose the builder in make_vms.com [Schweda] +- Add DESTDIR support to mingw32 win32/Makefile.gcc +- Fix comments in win32/Makefile.gcc for proper usage +- Allow overriding the default install locations for cmake +- Generate and install the pkg-config file with cmake +- Build both a static and a shared version of zlib with cmake +- Include version symbols for cmake builds +- If using cmake with MSVC, add the source directory to the includes +- Remove unneeded EXTRA_CFLAGS from win32/Makefile.gcc [Truta] +- Move obsolete emx makefile to old [Truta] +- Allow the use of -Wundef when compiling or using zlib +- Avoid the use of the -u option with mktemp +- Improve inflate() documentation on the use of Z_FINISH +- Recognize clang as gcc +- Add gzopen_w() in Windows for wide character path names +- Rename zconf.h in CMakeLists.txt to move it out of the way +- Add source directory in CMakeLists.txt for building examples +- Look in build directory for zlib.pc in CMakeLists.txt +- Remove gzflags from zlibvc.def in vc9 and vc10 +- Fix contrib/minizip compilation in the MinGW environment +- Update ./configure for Solaris, support --64 [Mooney] +- Remove -R. from Solaris shared build (possible security issue) +- Avoid race condition for parallel make (-j) running example +- Fix type mismatch between get_crc_table() and crc_table +- Fix parsing of version with "-" in CMakeLists.txt [Snider, Ziegler] +- Fix the path to zlib.map in CMakeLists.txt +- Force the native libtool in Mac OS X to avoid GNU libtool [Beebe] +- Add instructions to win32/Makefile.gcc for shared install [Torri] + +Changes in 1.2.6.1 (12 Feb 2012) +- Avoid the use of the Objective-C reserved name "id" +- Include io.h in gzguts.h for Microsoft compilers +- Fix problem with ./configure --prefix and gzgetc macro +- Include gz_header definition when compiling zlib solo +- Put gzflags() functionality back in zutil.c +- Avoid library header include in crc32.c for Z_SOLO +- Use name in GCC_CLASSIC as C compiler for coverage testing, if set +- Minor cleanup in contrib/minizip/zip.c [Vollant] +- Update make_vms.com [Zinser] +- Remove unnecessary gzgetc_ function +- Use optimized byte swap operations for Microsoft and GNU [Snyder] +- Fix minor typo in zlib.h comments [Rzesniowiecki] + +Changes in 1.2.6 (29 Jan 2012) +- Update the Pascal interface in contrib/pascal +- Fix function numbers for gzgetc_ in zlibvc.def files +- Fix configure.ac for contrib/minizip [Schiffer] +- Fix large-entry detection in minizip on 64-bit systems [Schiffer] +- Have ./configure use the compiler return code for error indication +- Fix CMakeLists.txt for cross compilation [McClure] +- Fix contrib/minizip/zip.c for 64-bit architectures [Dalsnes] +- Fix compilation of contrib/minizip on FreeBSD [Marquez] +- Correct suggested usages in win32/Makefile.msc [Shachar, Horvath] +- Include io.h for Turbo C / Borland C on all platforms [Truta] +- Make version explicit in contrib/minizip/configure.ac [Bosmans] +- Avoid warning for no encryption in contrib/minizip/zip.c [Vollant] +- Minor cleanup up contrib/minizip/unzip.c [Vollant] +- Fix bug when compiling minizip with C++ [Vollant] +- Protect for long name and extra fields in contrib/minizip [Vollant] +- Avoid some warnings in contrib/minizip [Vollant] +- Add -I../.. -L../.. to CFLAGS for minizip and miniunzip +- Add missing libs to minizip linker command +- Add support for VPATH builds in contrib/minizip +- Add an --enable-demos option to contrib/minizip/configure +- Add the generation of configure.log by ./configure +- Exit when required parameters not provided to win32/Makefile.gcc +- Have gzputc return the character written instead of the argument +- Use the -m option on ldconfig for BSD systems [Tobias] +- Correct in zlib.map when deflateResetKeep was added + +Changes in 1.2.5.3 (15 Jan 2012) +- Restore gzgetc function for binary compatibility +- Do not use _lseeki64 under Borland C++ [Truta] +- Update win32/Makefile.msc to build test/*.c [Truta] +- Remove old/visualc6 given CMakefile and other alternatives +- Update AS400 build files and documentation [Monnerat] +- Update win32/Makefile.gcc to build test/*.c [Truta] +- Permit stronger flushes after Z_BLOCK flushes +- Avoid extraneous empty blocks when doing empty flushes +- Permit Z_NULL arguments to deflatePending +- Allow deflatePrime() to insert bits in the middle of a stream +- Remove second empty static block for Z_PARTIAL_FLUSH +- Write out all of the available bits when using Z_BLOCK +- Insert the first two strings in the hash table after a flush + +Changes in 1.2.5.2 (17 Dec 2011) +- fix ld error: unable to find version dependency 'ZLIB_1.2.5' +- use relative symlinks for shared libs +- Avoid searching past window for Z_RLE strategy +- Assure that high-water mark initialization is always applied in deflate +- Add assertions to fill_window() in deflate.c to match comments +- Update python link in README +- Correct spelling error in gzread.c +- Fix bug in gzgets() for a concatenated empty gzip stream +- Correct error in comment for gz_make() +- Change gzread() and related to ignore junk after gzip streams +- Allow gzread() and related to continue after gzclearerr() +- Allow gzrewind() and gzseek() after a premature end-of-file +- Simplify gzseek() now that raw after gzip is ignored +- Change gzgetc() to a macro for speed (~40% speedup in testing) +- Fix gzclose() to return the actual error last encountered +- Always add large file support for windows +- Include zconf.h for windows large file support +- Include zconf.h.cmakein for windows large file support +- Update zconf.h.cmakein on make distclean +- Merge vestigial vsnprintf determination from zutil.h to gzguts.h +- Clarify how gzopen() appends in zlib.h comments +- Correct documentation of gzdirect() since junk at end now ignored +- Add a transparent write mode to gzopen() when 'T' is in the mode +- Update python link in zlib man page +- Get inffixed.h and MAKEFIXED result to match +- Add a ./config --solo option to make zlib subset with no library use +- Add undocumented inflateResetKeep() function for CAB file decoding +- Add --cover option to ./configure for gcc coverage testing +- Add #define ZLIB_CONST option to use const in the z_stream interface +- Add comment to gzdopen() in zlib.h to use dup() when using fileno() +- Note behavior of uncompress() to provide as much data as it can +- Add files in contrib/minizip to aid in building libminizip +- Split off AR options in Makefile.in and configure +- Change ON macro to Z_ARG to avoid application conflicts +- Facilitate compilation with Borland C++ for pragmas and vsnprintf +- Include io.h for Turbo C / Borland C++ +- Move example.c and minigzip.c to test/ +- Simplify incomplete code table filling in inflate_table() +- Remove code from inflate.c and infback.c that is impossible to execute +- Test the inflate code with full coverage +- Allow deflateSetDictionary, inflateSetDictionary at any time (in raw) +- Add deflateResetKeep and fix inflateResetKeep to retain dictionary +- Fix gzwrite.c to accommodate reduced memory zlib compilation +- Have inflate() with Z_FINISH avoid the allocation of a window +- Do not set strm->adler when doing raw inflate +- Fix gzeof() to behave just like feof() when read is not past end of file +- Fix bug in gzread.c when end-of-file is reached +- Avoid use of Z_BUF_ERROR in gz* functions except for premature EOF +- Document gzread() capability to read concurrently written files +- Remove hard-coding of resource compiler in CMakeLists.txt [Blammo] + +Changes in 1.2.5.1 (10 Sep 2011) +- Update FAQ entry on shared builds (#13) +- Avoid symbolic argument to chmod in Makefile.in +- Fix bug and add consts in contrib/puff [Oberhumer] +- Update contrib/puff/zeros.raw test file to have all block types +- Add full coverage test for puff in contrib/puff/Makefile +- Fix static-only-build install in Makefile.in +- Fix bug in unzGetCurrentFileInfo() in contrib/minizip [Kuno] +- Add libz.a dependency to shared in Makefile.in for parallel builds +- Spell out "number" (instead of "nb") in zlib.h for total_in, total_out +- Replace $(...) with `...` in configure for non-bash sh [Bowler] +- Add darwin* to Darwin* and solaris* to SunOS\ 5* in configure [Groffen] +- Add solaris* to Linux* in configure to allow gcc use [Groffen] +- Add *bsd* to Linux* case in configure [Bar-Lev] +- Add inffast.obj to dependencies in win32/Makefile.msc +- Correct spelling error in deflate.h [Kohler] +- Change libzdll.a again to libz.dll.a (!) in win32/Makefile.gcc +- Add test to configure for GNU C looking for gcc in output of $cc -v +- Add zlib.pc generation to win32/Makefile.gcc [Weigelt] +- Fix bug in zlib.h for _FILE_OFFSET_BITS set and _LARGEFILE64_SOURCE not +- Add comment in zlib.h that adler32_combine with len2 < 0 makes no sense +- Make NO_DIVIDE option in adler32.c much faster (thanks to John Reiser) +- Make stronger test in zconf.h to include unistd.h for LFS +- Apply Darwin patches for 64-bit file offsets to contrib/minizip [Slack] +- Fix zlib.h LFS support when Z_PREFIX used +- Add updated as400 support (removed from old) [Monnerat] +- Avoid deflate sensitivity to volatile input data +- Avoid division in adler32_combine for NO_DIVIDE +- Clarify the use of Z_FINISH with deflateBound() amount of space +- Set binary for output file in puff.c +- Use u4 type for crc_table to avoid conversion warnings +- Apply casts in zlib.h to avoid conversion warnings +- Add OF to prototypes for adler32_combine_ and crc32_combine_ [Miller] +- Improve inflateSync() documentation to note indeterminacy +- Add deflatePending() function to return the amount of pending output +- Correct the spelling of "specification" in FAQ [Randers-Pehrson] +- Add a check in configure for stdarg.h, use for gzprintf() +- Check that pointers fit in ints when gzprint() compiled old style +- Add dummy name before $(SHAREDLIBV) in Makefile [Bar-Lev, Bowler] +- Delete line in configure that adds -L. libz.a to LDFLAGS [Weigelt] +- Add debug records in assembler code [Londer] +- Update RFC references to use http://tools.ietf.org/html/... [Li] +- Add --archs option, use of libtool to configure for Mac OS X [Borstel] + +Changes in 1.2.5 (19 Apr 2010) +- Disable visibility attribute in win32/Makefile.gcc [Bar-Lev] +- Default to libdir as sharedlibdir in configure [Nieder] +- Update copyright dates on modified source files +- Update trees.c to be able to generate modified trees.h +- Exit configure for MinGW, suggesting win32/Makefile.gcc +- Check for NULL path in gz_open [Homurlu] + +Changes in 1.2.4.5 (18 Apr 2010) +- Set sharedlibdir in configure [Torok] +- Set LDFLAGS in Makefile.in [Bar-Lev] +- Avoid mkdir objs race condition in Makefile.in [Bowler] +- Add ZLIB_INTERNAL in front of internal inter-module functions and arrays +- Define ZLIB_INTERNAL to hide internal functions and arrays for GNU C +- Don't use hidden attribute when it is a warning generator (e.g. Solaris) + +Changes in 1.2.4.4 (18 Apr 2010) +- Fix CROSS_PREFIX executable testing, CHOST extract, mingw* [Torok] +- Undefine _LARGEFILE64_SOURCE in zconf.h if it is zero, but not if empty +- Try to use bash or ksh regardless of functionality of /bin/sh +- Fix configure incompatibility with NetBSD sh +- Remove attempt to run under bash or ksh since have better NetBSD fix +- Fix win32/Makefile.gcc for MinGW [Bar-Lev] +- Add diagnostic messages when using CROSS_PREFIX in configure +- Added --sharedlibdir option to configure [Weigelt] +- Use hidden visibility attribute when available [Frysinger] + +Changes in 1.2.4.3 (10 Apr 2010) +- Only use CROSS_PREFIX in configure for ar and ranlib if they exist +- Use CROSS_PREFIX for nm [Bar-Lev] +- Assume _LARGEFILE64_SOURCE defined is equivalent to true +- Avoid use of undefined symbols in #if with && and || +- Make *64 prototypes in gzguts.h consistent with functions +- Add -shared load option for MinGW in configure [Bowler] +- Move z_off64_t to public interface, use instead of off64_t +- Remove ! from shell test in configure (not portable to Solaris) +- Change +0 macro tests to -0 for possibly increased portability + +Changes in 1.2.4.2 (9 Apr 2010) +- Add consistent carriage returns to readme.txt's in masmx86 and masmx64 +- Really provide prototypes for *64 functions when building without LFS +- Only define unlink() in minigzip.c if unistd.h not included +- Update README to point to contrib/vstudio project files +- Move projects/vc6 to old/ and remove projects/ +- Include stdlib.h in minigzip.c for setmode() definition under WinCE +- Clean up assembler builds in win32/Makefile.msc [Rowe] +- Include sys/types.h for Microsoft for off_t definition +- Fix memory leak on error in gz_open() +- Symbolize nm as $NM in configure [Weigelt] +- Use TEST_LDSHARED instead of LDSHARED to link test programs [Weigelt] +- Add +0 to _FILE_OFFSET_BITS and _LFS64_LARGEFILE in case not defined +- Fix bug in gzeof() to take into account unused input data +- Avoid initialization of structures with variables in puff.c +- Updated win32/README-WIN32.txt [Rowe] + +Changes in 1.2.4.1 (28 Mar 2010) +- Remove the use of [a-z] constructs for sed in configure [gentoo 310225] +- Remove $(SHAREDLIB) from LIBS in Makefile.in [Creech] +- Restore "for debugging" comment on sprintf() in gzlib.c +- Remove fdopen for MVS from gzguts.h +- Put new README-WIN32.txt in win32 [Rowe] +- Add check for shell to configure and invoke another shell if needed +- Fix big fat stinking bug in gzseek() on uncompressed files +- Remove vestigial F_OPEN64 define in zutil.h +- Set and check the value of _LARGEFILE_SOURCE and _LARGEFILE64_SOURCE +- Avoid errors on non-LFS systems when applications define LFS macros +- Set EXE to ".exe" in configure for MINGW [Kahle] +- Match crc32() in crc32.c exactly to the prototype in zlib.h [Sherrill] +- Add prefix for cross-compilation in win32/makefile.gcc [Bar-Lev] +- Add DLL install in win32/makefile.gcc [Bar-Lev] +- Allow Linux* or linux* from uname in configure [Bar-Lev] +- Allow ldconfig to be redefined in configure and Makefile.in [Bar-Lev] +- Add cross-compilation prefixes to configure [Bar-Lev] +- Match type exactly in gz_load() invocation in gzread.c +- Match type exactly of zcalloc() in zutil.c to zlib.h alloc_func +- Provide prototypes for *64 functions when building zlib without LFS +- Don't use -lc when linking shared library on MinGW +- Remove errno.h check in configure and vestigial errno code in zutil.h + +Changes in 1.2.4 (14 Mar 2010) +- Fix VER3 extraction in configure for no fourth subversion +- Update zlib.3, add docs to Makefile.in to make .pdf out of it +- Add zlib.3.pdf to distribution +- Don't set error code in gzerror() if passed pointer is NULL +- Apply destination directory fixes to CMakeLists.txt [Lowman] +- Move #cmakedefine's to a new zconf.in.cmakein +- Restore zconf.h for builds that don't use configure or cmake +- Add distclean to dummy Makefile for convenience +- Update and improve INDEX, README, and FAQ +- Update CMakeLists.txt for the return of zconf.h [Lowman] +- Update contrib/vstudio/vc9 and vc10 [Vollant] +- Change libz.dll.a back to libzdll.a in win32/Makefile.gcc +- Apply license and readme changes to contrib/asm686 [Raiter] +- Check file name lengths and add -c option in minigzip.c [Li] +- Update contrib/amd64 and contrib/masmx86/ [Vollant] +- Avoid use of "eof" parameter in trees.c to not shadow library variable +- Update make_vms.com for removal of zlibdefs.h [Zinser] +- Update assembler code and vstudio projects in contrib [Vollant] +- Remove outdated assembler code contrib/masm686 and contrib/asm586 +- Remove old vc7 and vc8 from contrib/vstudio +- Update win32/Makefile.msc, add ZLIB_VER_SUBREVISION [Rowe] +- Fix memory leaks in gzclose_r() and gzclose_w(), file leak in gz_open() +- Add contrib/gcc_gvmat64 for longest_match and inflate_fast [Vollant] +- Remove *64 functions from win32/zlib.def (they're not 64-bit yet) +- Fix bug in void-returning vsprintf() case in gzwrite.c +- Fix name change from inflate.h in contrib/inflate86/inffas86.c +- Check if temporary file exists before removing in make_vms.com [Zinser] +- Fix make install and uninstall for --static option +- Fix usage of _MSC_VER in gzguts.h and zutil.h [Truta] +- Update readme.txt in contrib/masmx64 and masmx86 to assemble + +Changes in 1.2.3.9 (21 Feb 2010) +- Expunge gzio.c +- Move as400 build information to old +- Fix updates in contrib/minizip and contrib/vstudio +- Add const to vsnprintf test in configure to avoid warnings [Weigelt] +- Delete zconf.h (made by configure) [Weigelt] +- Change zconf.in.h to zconf.h.in per convention [Weigelt] +- Check for NULL buf in gzgets() +- Return empty string for gzgets() with len == 1 (like fgets()) +- Fix description of gzgets() in zlib.h for end-of-file, NULL return +- Update minizip to 1.1 [Vollant] +- Avoid MSVC loss of data warnings in gzread.c, gzwrite.c +- Note in zlib.h that gzerror() should be used to distinguish from EOF +- Remove use of snprintf() from gzlib.c +- Fix bug in gzseek() +- Update contrib/vstudio, adding vc9 and vc10 [Kuno, Vollant] +- Fix zconf.h generation in CMakeLists.txt [Lowman] +- Improve comments in zconf.h where modified by configure + +Changes in 1.2.3.8 (13 Feb 2010) +- Clean up text files (tabs, trailing whitespace, etc.) [Oberhumer] +- Use z_off64_t in gz_zero() and gz_skip() to match state->skip +- Avoid comparison problem when sizeof(int) == sizeof(z_off64_t) +- Revert to Makefile.in from 1.2.3.6 (live with the clutter) +- Fix missing error return in gzflush(), add zlib.h note +- Add *64 functions to zlib.map [Levin] +- Fix signed/unsigned comparison in gz_comp() +- Use SFLAGS when testing shared linking in configure +- Add --64 option to ./configure to use -m64 with gcc +- Fix ./configure --help to correctly name options +- Have make fail if a test fails [Levin] +- Avoid buffer overrun in contrib/masmx64/gvmat64.asm [Simpson] +- Remove assembler object files from contrib + +Changes in 1.2.3.7 (24 Jan 2010) +- Always gzopen() with O_LARGEFILE if available +- Fix gzdirect() to work immediately after gzopen() or gzdopen() +- Make gzdirect() more precise when the state changes while reading +- Improve zlib.h documentation in many places +- Catch memory allocation failure in gz_open() +- Complete close operation if seek forward in gzclose_w() fails +- Return Z_ERRNO from gzclose_r() if close() fails +- Return Z_STREAM_ERROR instead of EOF for gzclose() being passed NULL +- Return zero for gzwrite() errors to match zlib.h description +- Return -1 on gzputs() error to match zlib.h description +- Add zconf.in.h to allow recovery from configure modification [Weigelt] +- Fix static library permissions in Makefile.in [Weigelt] +- Avoid warnings in configure tests that hide functionality [Weigelt] +- Add *BSD and DragonFly to Linux case in configure [gentoo 123571] +- Change libzdll.a to libz.dll.a in win32/Makefile.gcc [gentoo 288212] +- Avoid access of uninitialized data for first inflateReset2 call [Gomes] +- Keep object files in subdirectories to reduce the clutter somewhat +- Remove default Makefile and zlibdefs.h, add dummy Makefile +- Add new external functions to Z_PREFIX, remove duplicates, z_z_ -> z_ +- Remove zlibdefs.h completely -- modify zconf.h instead + +Changes in 1.2.3.6 (17 Jan 2010) +- Avoid void * arithmetic in gzread.c and gzwrite.c +- Make compilers happier with const char * for gz_error message +- Avoid unused parameter warning in inflate.c +- Avoid signed-unsigned comparison warning in inflate.c +- Indent #pragma's for traditional C +- Fix usage of strwinerror() in glib.c, change to gz_strwinerror() +- Correct email address in configure for system options +- Update make_vms.com and add make_vms.com to contrib/minizip [Zinser] +- Update zlib.map [Brown] +- Fix Makefile.in for Solaris 10 make of example64 and minizip64 [Torok] +- Apply various fixes to CMakeLists.txt [Lowman] +- Add checks on len in gzread() and gzwrite() +- Add error message for no more room for gzungetc() +- Remove zlib version check in gzwrite() +- Defer compression of gzprintf() result until need to +- Use snprintf() in gzdopen() if available +- Remove USE_MMAP configuration determination (only used by minigzip) +- Remove examples/pigz.c (available separately) +- Update examples/gun.c to 1.6 + +Changes in 1.2.3.5 (8 Jan 2010) +- Add space after #if in zutil.h for some compilers +- Fix relatively harmless bug in deflate_fast() [Exarevsky] +- Fix same problem in deflate_slow() +- Add $(SHAREDLIBV) to LIBS in Makefile.in [Brown] +- Add deflate_rle() for faster Z_RLE strategy run-length encoding +- Add deflate_huff() for faster Z_HUFFMAN_ONLY encoding +- Change name of "write" variable in inffast.c to avoid library collisions +- Fix premature EOF from gzread() in gzio.c [Brown] +- Use zlib header window size if windowBits is 0 in inflateInit2() +- Remove compressBound() call in deflate.c to avoid linking compress.o +- Replace use of errno in gz* with functions, support WinCE [Alves] +- Provide alternative to perror() in minigzip.c for WinCE [Alves] +- Don't use _vsnprintf on later versions of MSVC [Lowman] +- Add CMake build script and input file [Lowman] +- Update contrib/minizip to 1.1 [Svensson, Vollant] +- Moved nintendods directory from contrib to root +- Replace gzio.c with a new set of routines with the same functionality +- Add gzbuffer(), gzoffset(), gzclose_r(), gzclose_w() as part of above +- Update contrib/minizip to 1.1b +- Change gzeof() to return 0 on error instead of -1 to agree with zlib.h + +Changes in 1.2.3.4 (21 Dec 2009) +- Use old school .SUFFIXES in Makefile.in for FreeBSD compatibility +- Update comments in configure and Makefile.in for default --shared +- Fix test -z's in configure [Marquess] +- Build examplesh and minigzipsh when not testing +- Change NULL's to Z_NULL's in deflate.c and in comments in zlib.h +- Import LDFLAGS from the environment in configure +- Fix configure to populate SFLAGS with discovered CFLAGS options +- Adapt make_vms.com to the new Makefile.in [Zinser] +- Add zlib2ansi script for C++ compilation [Marquess] +- Add _FILE_OFFSET_BITS=64 test to make test (when applicable) +- Add AMD64 assembler code for longest match to contrib [Teterin] +- Include options from $SFLAGS when doing $LDSHARED +- Simplify 64-bit file support by introducing z_off64_t type +- Make shared object files in objs directory to work around old Sun cc +- Use only three-part version number for Darwin shared compiles +- Add rc option to ar in Makefile.in for when ./configure not run +- Add -WI,-rpath,. to LDFLAGS for OSF 1 V4* +- Set LD_LIBRARYN32_PATH for SGI IRIX shared compile +- Protect against _FILE_OFFSET_BITS being defined when compiling zlib +- Rename Makefile.in targets allstatic to static and allshared to shared +- Fix static and shared Makefile.in targets to be independent +- Correct error return bug in gz_open() by setting state [Brown] +- Put spaces before ;;'s in configure for better sh compatibility +- Add pigz.c (parallel implementation of gzip) to examples/ +- Correct constant in crc32.c to UL [Leventhal] +- Reject negative lengths in crc32_combine() +- Add inflateReset2() function to work like inflateEnd()/inflateInit2() +- Include sys/types.h for _LARGEFILE64_SOURCE [Brown] +- Correct typo in doc/algorithm.txt [Janik] +- Fix bug in adler32_combine() [Zhu] +- Catch missing-end-of-block-code error in all inflates and in puff + Assures that random input to inflate eventually results in an error +- Added enough.c (calculation of ENOUGH for inftrees.h) to examples/ +- Update ENOUGH and its usage to reflect discovered bounds +- Fix gzerror() error report on empty input file [Brown] +- Add ush casts in trees.c to avoid pedantic runtime errors +- Fix typo in zlib.h uncompress() description [Reiss] +- Correct inflate() comments with regard to automatic header detection +- Remove deprecation comment on Z_PARTIAL_FLUSH (it stays) +- Put new version of gzlog (2.0) in examples with interruption recovery +- Add puff compile option to permit invalid distance-too-far streams +- Add puff TEST command options, ability to read piped input +- Prototype the *64 functions in zlib.h when _FILE_OFFSET_BITS == 64, but + _LARGEFILE64_SOURCE not defined +- Fix Z_FULL_FLUSH to truly erase the past by resetting s->strstart +- Fix deflateSetDictionary() to use all 32K for output consistency +- Remove extraneous #define MIN_LOOKAHEAD in deflate.c (in deflate.h) +- Clear bytes after deflate lookahead to avoid use of uninitialized data +- Change a limit in inftrees.c to be more transparent to Coverity Prevent +- Update win32/zlib.def with exported symbols from zlib.h +- Correct spelling errors in zlib.h [Willem, Sobrado] +- Allow Z_BLOCK for deflate() to force a new block +- Allow negative bits in inflatePrime() to delete existing bit buffer +- Add Z_TREES flush option to inflate() to return at end of trees +- Add inflateMark() to return current state information for random access +- Add Makefile for NintendoDS to contrib [Costa] +- Add -w in configure compile tests to avoid spurious warnings [Beucler] +- Fix typos in zlib.h comments for deflateSetDictionary() +- Fix EOF detection in transparent gzread() [Maier] + +Changes in 1.2.3.3 (2 October 2006) +- Make --shared the default for configure, add a --static option +- Add compile option to permit invalid distance-too-far streams +- Add inflateUndermine() function which is required to enable above +- Remove use of "this" variable name for C++ compatibility [Marquess] +- Add testing of shared library in make test, if shared library built +- Use ftello() and fseeko() if available instead of ftell() and fseek() +- Provide two versions of all functions that use the z_off_t type for + binary compatibility -- a normal version and a 64-bit offset version, + per the Large File Support Extension when _LARGEFILE64_SOURCE is + defined; use the 64-bit versions by default when _FILE_OFFSET_BITS + is defined to be 64 +- Add a --uname= option to configure to perhaps help with cross-compiling + +Changes in 1.2.3.2 (3 September 2006) +- Turn off silly Borland warnings [Hay] +- Use off64_t and define _LARGEFILE64_SOURCE when present +- Fix missing dependency on inffixed.h in Makefile.in +- Rig configure --shared to build both shared and static [Teredesai, Truta] +- Remove zconf.in.h and instead create a new zlibdefs.h file +- Fix contrib/minizip/unzip.c non-encrypted after encrypted [Vollant] +- Add treebuild.xml (see http://treebuild.metux.de/) [Weigelt] + +Changes in 1.2.3.1 (16 August 2006) +- Add watcom directory with OpenWatcom make files [Daniel] +- Remove #undef of FAR in zconf.in.h for MVS [Fedtke] +- Update make_vms.com [Zinser] +- Use -fPIC for shared build in configure [Teredesai, Nicholson] +- Use only major version number for libz.so on IRIX and OSF1 [Reinholdtsen] +- Use fdopen() (not _fdopen()) for Interix in zutil.h [Bäck] +- Add some FAQ entries about the contrib directory +- Update the MVS question in the FAQ +- Avoid extraneous reads after EOF in gzio.c [Brown] +- Correct spelling of "successfully" in gzio.c [Randers-Pehrson] +- Add comments to zlib.h about gzerror() usage [Brown] +- Set extra flags in gzip header in gzopen() like deflate() does +- Make configure options more compatible with double-dash conventions + [Weigelt] +- Clean up compilation under Solaris SunStudio cc [Rowe, Reinholdtsen] +- Fix uninstall target in Makefile.in [Truta] +- Add pkgconfig support [Weigelt] +- Use $(DESTDIR) macro in Makefile.in [Reinholdtsen, Weigelt] +- Replace set_data_type() with a more accurate detect_data_type() in + trees.c, according to the txtvsbin.txt document [Truta] +- Swap the order of #include and #include "zlib.h" in + gzio.c, example.c and minigzip.c [Truta] +- Shut up annoying VS2005 warnings about standard C deprecation [Rowe, + Truta] (where?) +- Fix target "clean" from win32/Makefile.bor [Truta] +- Create .pdb and .manifest files in win32/makefile.msc [Ziegler, Rowe] +- Update zlib www home address in win32/DLL_FAQ.txt [Truta] +- Update contrib/masmx86/inffas32.asm for VS2005 [Vollant, Van Wassenhove] +- Enable browse info in the "Debug" and "ASM Debug" configurations in + the Visual C++ 6 project, and set (non-ASM) "Debug" as default [Truta] +- Add pkgconfig support [Weigelt] +- Add ZLIB_VER_MAJOR, ZLIB_VER_MINOR and ZLIB_VER_REVISION in zlib.h, + for use in win32/zlib1.rc [Polushin, Rowe, Truta] +- Add a document that explains the new text detection scheme to + doc/txtvsbin.txt [Truta] +- Add rfc1950.txt, rfc1951.txt and rfc1952.txt to doc/ [Truta] +- Move algorithm.txt into doc/ [Truta] +- Synchronize FAQ with website +- Fix compressBound(), was low for some pathological cases [Fearnley] +- Take into account wrapper variations in deflateBound() +- Set examples/zpipe.c input and output to binary mode for Windows +- Update examples/zlib_how.html with new zpipe.c (also web site) +- Fix some warnings in examples/gzlog.c and examples/zran.c (it seems + that gcc became pickier in 4.0) +- Add zlib.map for Linux: "All symbols from zlib-1.1.4 remain + un-versioned, the patch adds versioning only for symbols introduced in + zlib-1.2.0 or later. It also declares as local those symbols which are + not designed to be exported." [Levin] +- Update Z_PREFIX list in zconf.in.h, add --zprefix option to configure +- Do not initialize global static by default in trees.c, add a response + NO_INIT_GLOBAL_POINTERS to initialize them if needed [Marquess] +- Don't use strerror() in gzio.c under WinCE [Yakimov] +- Don't use errno.h in zutil.h under WinCE [Yakimov] +- Move arguments for AR to its usage to allow replacing ar [Marot] +- Add HAVE_VISIBILITY_PRAGMA in zconf.in.h for Mozilla [Randers-Pehrson] +- Improve inflateInit() and inflateInit2() documentation +- Fix structure size comment in inflate.h +- Change configure help option from --h* to --help [Santos] + +Changes in 1.2.3 (18 July 2005) +- Apply security vulnerability fixes to contrib/infback9 as well +- Clean up some text files (carriage returns, trailing space) +- Update testzlib, vstudio, masmx64, and masmx86 in contrib [Vollant] + +Changes in 1.2.2.4 (11 July 2005) +- Add inflatePrime() function for starting inflation at bit boundary +- Avoid some Visual C warnings in deflate.c +- Avoid more silly Visual C warnings in inflate.c and inftrees.c for 64-bit + compile +- Fix some spelling errors in comments [Betts] +- Correct inflateInit2() error return documentation in zlib.h +- Add zran.c example of compressed data random access to examples + directory, shows use of inflatePrime() +- Fix cast for assignments to strm->state in inflate.c and infback.c +- Fix zlibCompileFlags() in zutil.c to use 1L for long shifts [Oberhumer] +- Move declarations of gf2 functions to right place in crc32.c [Oberhumer] +- Add cast in trees.c t avoid a warning [Oberhumer] +- Avoid some warnings in fitblk.c, gun.c, gzjoin.c in examples [Oberhumer] +- Update make_vms.com [Zinser] +- Initialize state->write in inflateReset() since copied in inflate_fast() +- Be more strict on incomplete code sets in inflate_table() and increase + ENOUGH and MAXD -- this repairs a possible security vulnerability for + invalid inflate input. Thanks to Tavis Ormandy and Markus Oberhumer for + discovering the vulnerability and providing test cases +- Add ia64 support to configure for HP-UX [Smith] +- Add error return to gzread() for format or i/o error [Levin] +- Use malloc.h for OS/2 [Necasek] + +Changes in 1.2.2.3 (27 May 2005) +- Replace 1U constants in inflate.c and inftrees.c for 64-bit compile +- Typecast fread() return values in gzio.c [Vollant] +- Remove trailing space in minigzip.c outmode (VC++ can't deal with it) +- Fix crc check bug in gzread() after gzungetc() [Heiner] +- Add the deflateTune() function to adjust internal compression parameters +- Add a fast gzip decompressor, gun.c, to examples (use of inflateBack) +- Remove an incorrect assertion in examples/zpipe.c +- Add C++ wrapper in infback9.h [Donais] +- Fix bug in inflateCopy() when decoding fixed codes +- Note in zlib.h how much deflateSetDictionary() actually uses +- Remove USE_DICT_HEAD in deflate.c (would mess up inflate if used) +- Add _WIN32_WCE to define WIN32 in zconf.in.h [Spencer] +- Don't include stderr.h or errno.h for _WIN32_WCE in zutil.h [Spencer] +- Add gzdirect() function to indicate transparent reads +- Update contrib/minizip [Vollant] +- Fix compilation of deflate.c when both ASMV and FASTEST [Oberhumer] +- Add casts in crc32.c to avoid warnings [Oberhumer] +- Add contrib/masmx64 [Vollant] +- Update contrib/asm586, asm686, masmx86, testzlib, vstudio [Vollant] + +Changes in 1.2.2.2 (30 December 2004) +- Replace structure assignments in deflate.c and inflate.c with zmemcpy to + avoid implicit memcpy calls (portability for no-library compilation) +- Increase sprintf() buffer size in gzdopen() to allow for large numbers +- Add INFLATE_STRICT to check distances against zlib header +- Improve WinCE errno handling and comments [Chang] +- Remove comment about no gzip header processing in FAQ +- Add Z_FIXED strategy option to deflateInit2() to force fixed trees +- Add updated make_vms.com [Coghlan], update README +- Create a new "examples" directory, move gzappend.c there, add zpipe.c, + fitblk.c, gzlog.[ch], gzjoin.c, and zlib_how.html +- Add FAQ entry and comments in deflate.c on uninitialized memory access +- Add Solaris 9 make options in configure [Gilbert] +- Allow strerror() usage in gzio.c for STDC +- Fix DecompressBuf in contrib/delphi/ZLib.pas [ManChesTer] +- Update contrib/masmx86/inffas32.asm and gvmat32.asm [Vollant] +- Use z_off_t for adler32_combine() and crc32_combine() lengths +- Make adler32() much faster for small len +- Use OS_CODE in deflate() default gzip header + +Changes in 1.2.2.1 (31 October 2004) +- Allow inflateSetDictionary() call for raw inflate +- Fix inflate header crc check bug for file names and comments +- Add deflateSetHeader() and gz_header structure for custom gzip headers +- Add inflateGetheader() to retrieve gzip headers +- Add crc32_combine() and adler32_combine() functions +- Add alloc_func, free_func, in_func, out_func to Z_PREFIX list +- Use zstreamp consistently in zlib.h (inflate_back functions) +- Remove GUNZIP condition from definition of inflate_mode in inflate.h + and in contrib/inflate86/inffast.S [Truta, Anderson] +- Add support for AMD64 in contrib/inflate86/inffas86.c [Anderson] +- Update projects/README.projects and projects/visualc6 [Truta] +- Update win32/DLL_FAQ.txt [Truta] +- Avoid warning under NO_GZCOMPRESS in gzio.c; fix typo [Truta] +- Deprecate Z_ASCII; use Z_TEXT instead [Truta] +- Use a new algorithm for setting strm->data_type in trees.c [Truta] +- Do not define an exit() prototype in zutil.c unless DEBUG defined +- Remove prototype of exit() from zutil.c, example.c, minigzip.c [Truta] +- Add comment in zlib.h for Z_NO_FLUSH parameter to deflate() +- Fix Darwin build version identification [Peterson] + +Changes in 1.2.2 (3 October 2004) +- Update zlib.h comments on gzip in-memory processing +- Set adler to 1 in inflateReset() to support Java test suite [Walles] +- Add contrib/dotzlib [Ravn] +- Update win32/DLL_FAQ.txt [Truta] +- Update contrib/minizip [Vollant] +- Move contrib/visual-basic.txt to old/ [Truta] +- Fix assembler builds in projects/visualc6/ [Truta] + +Changes in 1.2.1.2 (9 September 2004) +- Update INDEX file +- Fix trees.c to update strm->data_type (no one ever noticed!) +- Fix bug in error case in inflate.c, infback.c, and infback9.c [Brown] +- Add "volatile" to crc table flag declaration (for DYNAMIC_CRC_TABLE) +- Add limited multitasking protection to DYNAMIC_CRC_TABLE +- Add NO_vsnprintf for VMS in zutil.h [Mozilla] +- Don't declare strerror() under VMS [Mozilla] +- Add comment to DYNAMIC_CRC_TABLE to use get_crc_table() to initialize +- Update contrib/ada [Anisimkov] +- Update contrib/minizip [Vollant] +- Fix configure to not hardcode directories for Darwin [Peterson] +- Fix gzio.c to not return error on empty files [Brown] +- Fix indentation; update version in contrib/delphi/ZLib.pas and + contrib/pascal/zlibpas.pas [Truta] +- Update mkasm.bat in contrib/masmx86 [Truta] +- Update contrib/untgz [Truta] +- Add projects/README.projects [Truta] +- Add project for MS Visual C++ 6.0 in projects/visualc6 [Cadieux, Truta] +- Update win32/DLL_FAQ.txt [Truta] +- Update list of Z_PREFIX symbols in zconf.h [Randers-Pehrson, Truta] +- Remove an unnecessary assignment to curr in inftrees.c [Truta] +- Add OS/2 to exe builds in configure [Poltorak] +- Remove err dummy parameter in zlib.h [Kientzle] + +Changes in 1.2.1.1 (9 January 2004) +- Update email address in README +- Several FAQ updates +- Fix a big fat bug in inftrees.c that prevented decoding valid + dynamic blocks with only literals and no distance codes -- + Thanks to "Hot Emu" for the bug report and sample file +- Add a note to puff.c on no distance codes case + +Changes in 1.2.1 (17 November 2003) +- Remove a tab in contrib/gzappend/gzappend.c +- Update some interfaces in contrib for new zlib functions +- Update zlib version number in some contrib entries +- Add Windows CE definition for ptrdiff_t in zutil.h [Mai, Truta] +- Support shared libraries on Hurd and KFreeBSD [Brown] +- Fix error in NO_DIVIDE option of adler32.c + +Changes in 1.2.0.8 (4 November 2003) +- Update version in contrib/delphi/ZLib.pas and contrib/pascal/zlibpas.pas +- Add experimental NO_DIVIDE #define in adler32.c + - Possibly faster on some processors (let me know if it is) +- Correct Z_BLOCK to not return on first inflate call if no wrap +- Fix strm->data_type on inflate() return to correctly indicate EOB +- Add deflatePrime() function for appending in the middle of a byte +- Add contrib/gzappend for an example of appending to a stream +- Update win32/DLL_FAQ.txt [Truta] +- Delete Turbo C comment in README [Truta] +- Improve some indentation in zconf.h [Truta] +- Fix infinite loop on bad input in configure script [Church] +- Fix gzeof() for concatenated gzip files [Johnson] +- Add example to contrib/visual-basic.txt [Michael B.] +- Add -p to mkdir's in Makefile.in [vda] +- Fix configure to properly detect presence or lack of printf functions +- Add AS400 support [Monnerat] +- Add a little Cygwin support [Wilson] + +Changes in 1.2.0.7 (21 September 2003) +- Correct some debug formats in contrib/infback9 +- Cast a type in a debug statement in trees.c +- Change search and replace delimiter in configure from % to # [Beebe] +- Update contrib/untgz to 0.2 with various fixes [Truta] +- Add build support for Amiga [Nikl] +- Remove some directories in old that have been updated to 1.2 +- Add dylib building for Mac OS X in configure and Makefile.in +- Remove old distribution stuff from Makefile +- Update README to point to DLL_FAQ.txt, and add comment on Mac OS X +- Update links in README + +Changes in 1.2.0.6 (13 September 2003) +- Minor FAQ updates +- Update contrib/minizip to 1.00 [Vollant] +- Remove test of gz functions in example.c when GZ_COMPRESS defined [Truta] +- Update POSTINC comment for 68060 [Nikl] +- Add contrib/infback9 with deflate64 decoding (unsupported) +- For MVS define NO_vsnprintf and undefine FAR [van Burik] +- Add pragma for fdopen on MVS [van Burik] + +Changes in 1.2.0.5 (8 September 2003) +- Add OF to inflateBackEnd() declaration in zlib.h +- Remember start when using gzdopen in the middle of a file +- Use internal off_t counters in gz* functions to properly handle seeks +- Perform more rigorous check for distance-too-far in inffast.c +- Add Z_BLOCK flush option to return from inflate at block boundary +- Set strm->data_type on return from inflate + - Indicate bits unused, if at block boundary, and if in last block +- Replace size_t with ptrdiff_t in crc32.c, and check for correct size +- Add condition so old NO_DEFLATE define still works for compatibility +- FAQ update regarding the Windows DLL [Truta] +- INDEX update: add qnx entry, remove aix entry [Truta] +- Install zlib.3 into mandir [Wilson] +- Move contrib/zlib_dll_FAQ.txt to win32/DLL_FAQ.txt; update [Truta] +- Adapt the zlib interface to the new DLL convention guidelines [Truta] +- Introduce ZLIB_WINAPI macro to allow the export of functions using + the WINAPI calling convention, for Visual Basic [Vollant, Truta] +- Update msdos and win32 scripts and makefiles [Truta] +- Export symbols by name, not by ordinal, in win32/zlib.def [Truta] +- Add contrib/ada [Anisimkov] +- Move asm files from contrib/vstudio/vc70_32 to contrib/asm386 [Truta] +- Rename contrib/asm386 to contrib/masmx86 [Truta, Vollant] +- Add contrib/masm686 [Truta] +- Fix offsets in contrib/inflate86 and contrib/masmx86/inffas32.asm + [Truta, Vollant] +- Update contrib/delphi; rename to contrib/pascal; add example [Truta] +- Remove contrib/delphi2; add a new contrib/delphi [Truta] +- Avoid inclusion of the nonstandard in contrib/iostream, + and fix some method prototypes [Truta] +- Fix the ZCR_SEED2 constant to avoid warnings in contrib/minizip + [Truta] +- Avoid the use of backslash (\) in contrib/minizip [Vollant] +- Fix file time handling in contrib/untgz; update makefiles [Truta] +- Update contrib/vstudio/vc70_32 to comply with the new DLL guidelines + [Vollant] +- Remove contrib/vstudio/vc15_16 [Vollant] +- Rename contrib/vstudio/vc70_32 to contrib/vstudio/vc7 [Truta] +- Update README.contrib [Truta] +- Invert the assignment order of match_head and s->prev[...] in + INSERT_STRING [Truta] +- Compare TOO_FAR with 32767 instead of 32768, to avoid 16-bit warnings + [Truta] +- Compare function pointers with 0, not with NULL or Z_NULL [Truta] +- Fix prototype of syncsearch in inflate.c [Truta] +- Introduce ASMINF macro to be enabled when using an ASM implementation + of inflate_fast [Truta] +- Change NO_DEFLATE to NO_GZCOMPRESS [Truta] +- Modify test_gzio in example.c to take a single file name as a + parameter [Truta] +- Exit the example.c program if gzopen fails [Truta] +- Add type casts around strlen in example.c [Truta] +- Remove casting to sizeof in minigzip.c; give a proper type + to the variable compared with SUFFIX_LEN [Truta] +- Update definitions of STDC and STDC99 in zconf.h [Truta] +- Synchronize zconf.h with the new Windows DLL interface [Truta] +- Use SYS16BIT instead of __32BIT__ to distinguish between + 16- and 32-bit platforms [Truta] +- Use far memory allocators in small 16-bit memory models for + Turbo C [Truta] +- Add info about the use of ASMV, ASMINF and ZLIB_WINAPI in + zlibCompileFlags [Truta] +- Cygwin has vsnprintf [Wilson] +- In Windows16, OS_CODE is 0, as in MSDOS [Truta] +- In Cygwin, OS_CODE is 3 (Unix), not 11 (Windows32) [Wilson] + +Changes in 1.2.0.4 (10 August 2003) +- Minor FAQ updates +- Be more strict when checking inflateInit2's windowBits parameter +- Change NO_GUNZIP compile option to NO_GZIP to cover deflate as well +- Add gzip wrapper option to deflateInit2 using windowBits +- Add updated QNX rule in configure and qnx directory [Bonnefoy] +- Make inflate distance-too-far checks more rigorous +- Clean up FAR usage in inflate +- Add casting to sizeof() in gzio.c and minigzip.c + +Changes in 1.2.0.3 (19 July 2003) +- Fix silly error in gzungetc() implementation [Vollant] +- Update contrib/minizip and contrib/vstudio [Vollant] +- Fix printf format in example.c +- Correct cdecl support in zconf.in.h [Anisimkov] +- Minor FAQ updates + +Changes in 1.2.0.2 (13 July 2003) +- Add ZLIB_VERNUM in zlib.h for numerical preprocessor comparisons +- Attempt to avoid warnings in crc32.c for pointer-int conversion +- Add AIX to configure, remove aix directory [Bakker] +- Add some casts to minigzip.c +- Improve checking after insecure sprintf() or vsprintf() calls +- Remove #elif's from crc32.c +- Change leave label to inf_leave in inflate.c and infback.c to avoid + library conflicts +- Remove inflate gzip decoding by default--only enable gzip decoding by + special request for stricter backward compatibility +- Add zlibCompileFlags() function to return compilation information +- More typecasting in deflate.c to avoid warnings +- Remove leading underscore from _Capital #defines [Truta] +- Fix configure to link shared library when testing +- Add some Windows CE target adjustments [Mai] +- Remove #define ZLIB_DLL in zconf.h [Vollant] +- Add zlib.3 [Rodgers] +- Update RFC URL in deflate.c and algorithm.txt [Mai] +- Add zlib_dll_FAQ.txt to contrib [Truta] +- Add UL to some constants [Truta] +- Update minizip and vstudio [Vollant] +- Remove vestigial NEED_DUMMY_RETURN from zconf.in.h +- Expand use of NO_DUMMY_DECL to avoid all dummy structures +- Added iostream3 to contrib [Schwardt] +- Replace rewind() with fseek() for WinCE [Truta] +- Improve setting of zlib format compression level flags + - Report 0 for huffman and rle strategies and for level == 0 or 1 + - Report 2 only for level == 6 +- Only deal with 64K limit when necessary at compile time [Truta] +- Allow TOO_FAR check to be turned off at compile time [Truta] +- Add gzclearerr() function [Souza] +- Add gzungetc() function + +Changes in 1.2.0.1 (17 March 2003) +- Add Z_RLE strategy for run-length encoding [Truta] + - When Z_RLE requested, restrict matches to distance one + - Update zlib.h, minigzip.c, gzopen(), gzdopen() for Z_RLE +- Correct FASTEST compilation to allow level == 0 +- Clean up what gets compiled for FASTEST +- Incorporate changes to zconf.in.h [Vollant] + - Refine detection of Turbo C need for dummy returns + - Refine ZLIB_DLL compilation + - Include additional header file on VMS for off_t typedef +- Try to use _vsnprintf where it supplants vsprintf [Vollant] +- Add some casts in inffast.c +- Enhance comments in zlib.h on what happens if gzprintf() tries to + write more than 4095 bytes before compression +- Remove unused state from inflateBackEnd() +- Remove exit(0) from minigzip.c, example.c +- Get rid of all those darn tabs +- Add "check" target to Makefile.in that does the same thing as "test" +- Add "mostlyclean" and "maintainer-clean" targets to Makefile.in +- Update contrib/inflate86 [Anderson] +- Update contrib/testzlib, contrib/vstudio, contrib/minizip [Vollant] +- Add msdos and win32 directories with makefiles [Truta] +- More additions and improvements to the FAQ + +Changes in 1.2.0 (9 March 2003) +- New and improved inflate code + - About 20% faster + - Does not allocate 32K window unless and until needed + - Automatically detects and decompresses gzip streams + - Raw inflate no longer needs an extra dummy byte at end + - Added inflateBack functions using a callback interface--even faster + than inflate, useful for file utilities (gzip, zip) + - Added inflateCopy() function to record state for random access on + externally generated deflate streams (e.g. in gzip files) + - More readable code (I hope) +- New and improved crc32() + - About 50% faster, thanks to suggestions from Rodney Brown +- Add deflateBound() and compressBound() functions +- Fix memory leak in deflateInit2() +- Permit setting dictionary for raw deflate (for parallel deflate) +- Fix const declaration for gzwrite() +- Check for some malloc() failures in gzio.c +- Fix bug in gzopen() on single-byte file 0x1f +- Fix bug in gzread() on concatenated file with 0x1f at end of buffer + and next buffer doesn't start with 0x8b +- Fix uncompress() to return Z_DATA_ERROR on truncated input +- Free memory at end of example.c +- Remove MAX #define in trees.c (conflicted with some libraries) +- Fix static const's in deflate.c, gzio.c, and zutil.[ch] +- Declare malloc() and free() in gzio.c if STDC not defined +- Use malloc() instead of calloc() in zutil.c if int big enough +- Define STDC for AIX +- Add aix/ with approach for compiling shared library on AIX +- Add HP-UX support for shared libraries in configure +- Add OpenUNIX support for shared libraries in configure +- Use $cc instead of gcc to build shared library +- Make prefix directory if needed when installing +- Correct Macintosh avoidance of typedef Byte in zconf.h +- Correct Turbo C memory allocation when under Linux +- Use libz.a instead of -lz in Makefile (assure use of compiled library) +- Update configure to check for snprintf or vsnprintf functions and their + return value, warn during make if using an insecure function +- Fix configure problem with compile-time knowledge of HAVE_UNISTD_H that + is lost when library is used--resolution is to build new zconf.h +- Documentation improvements (in zlib.h): + - Document raw deflate and inflate + - Update RFCs URL + - Point out that zlib and gzip formats are different + - Note that Z_BUF_ERROR is not fatal + - Document string limit for gzprintf() and possible buffer overflow + - Note requirement on avail_out when flushing + - Note permitted values of flush parameter of inflate() +- Add some FAQs (and even answers) to the FAQ +- Add contrib/inflate86/ for x86 faster inflate +- Add contrib/blast/ for PKWare Data Compression Library decompression +- Add contrib/puff/ simple inflate for deflate format description + +Changes in 1.1.4 (11 March 2002) +- ZFREE was repeated on same allocation on some error conditions + This creates a security problem described in + http://www.zlib.org/advisory-2002-03-11.txt +- Returned incorrect error (Z_MEM_ERROR) on some invalid data +- Avoid accesses before window for invalid distances with inflate window + less than 32K +- force windowBits > 8 to avoid a bug in the encoder for a window size + of 256 bytes. (A complete fix will be available in 1.1.5) + +Changes in 1.1.3 (9 July 1998) +- fix "an inflate input buffer bug that shows up on rare but persistent + occasions" (Mark) +- fix gzread and gztell for concatenated .gz files (Didier Le Botlan) +- fix gzseek(..., SEEK_SET) in write mode +- fix crc check after a gzeek (Frank Faubert) +- fix miniunzip when the last entry in a zip file is itself a zip file + (J Lillge) +- add contrib/asm586 and contrib/asm686 (Brian Raiter) + See http://www.muppetlabs.com/~breadbox/software/assembly.html +- add support for Delphi 3 in contrib/delphi (Bob Dellaca) +- add support for C++Builder 3 and Delphi 3 in contrib/delphi2 (Davide Moretti) +- do not exit prematurely in untgz if 0 at start of block (Magnus Holmgren) +- use macro EXTERN instead of extern to support DLL for BeOS (Sander Stoks) +- added a FAQ file + +- Support gzdopen on Mac with Metrowerks (Jason Linhart) +- Do not redefine Byte on Mac (Brad Pettit & Jason Linhart) +- define SEEK_END too if SEEK_SET is not defined (Albert Chin-A-Young) +- avoid some warnings with Borland C (Tom Tanner) +- fix a problem in contrib/minizip/zip.c for 16-bit MSDOS (Gilles Vollant) +- emulate utime() for WIN32 in contrib/untgz (Gilles Vollant) +- allow several arguments to configure (Tim Mooney, Frodo Looijaard) +- use libdir and includedir in Makefile.in (Tim Mooney) +- support shared libraries on OSF1 V4 (Tim Mooney) +- remove so_locations in "make clean" (Tim Mooney) +- fix maketree.c compilation error (Glenn, Mark) +- Python interface to zlib now in Python 1.5 (Jeremy Hylton) +- new Makefile.riscos (Rich Walker) +- initialize static descriptors in trees.c for embedded targets (Nick Smith) +- use "foo-gz" in example.c for RISCOS and VMS (Nick Smith) +- add the OS/2 files in Makefile.in too (Andrew Zabolotny) +- fix fdopen and halloc macros for Microsoft C 6.0 (Tom Lane) +- fix maketree.c to allow clean compilation of inffixed.h (Mark) +- fix parameter check in deflateCopy (Gunther Nikl) +- cleanup trees.c, use compressed_len only in debug mode (Christian Spieler) +- Many portability patches by Christian Spieler: + . zutil.c, zutil.h: added "const" for zmem* + . Make_vms.com: fixed some typos + . Make_vms.com: msdos/Makefile.*: removed zutil.h from some dependency lists + . msdos/Makefile.msc: remove "default rtl link library" info from obj files + . msdos/Makefile.*: use model-dependent name for the built zlib library + . msdos/Makefile.emx, nt/Makefile.emx, nt/Makefile.gcc: + new makefiles, for emx (DOS/OS2), emx&rsxnt and mingw32 (Windows 9x / NT) +- use define instead of typedef for Bytef also for MSC small/medium (Tom Lane) +- replace __far with _far for better portability (Christian Spieler, Tom Lane) +- fix test for errno.h in configure (Tim Newsham) + +Changes in 1.1.2 (19 March 98) +- added contrib/minzip, mini zip and unzip based on zlib (Gilles Vollant) + See http://www.winimage.com/zLibDll/unzip.html +- preinitialize the inflate tables for fixed codes, to make the code + completely thread safe (Mark) +- some simplifications and slight speed-up to the inflate code (Mark) +- fix gzeof on non-compressed files (Allan Schrum) +- add -std1 option in configure for OSF1 to fix gzprintf (Martin Mokrejs) +- use default value of 4K for Z_BUFSIZE for 16-bit MSDOS (Tim Wegner + Glenn) +- added os2/Makefile.def and os2/zlib.def (Andrew Zabolotny) +- add shared lib support for UNIX_SV4.2MP (MATSUURA Takanori) +- do not wrap extern "C" around system includes (Tom Lane) +- mention zlib binding for TCL in README (Andreas Kupries) +- added amiga/Makefile.pup for Amiga powerUP SAS/C PPC (Andreas Kleinert) +- allow "make install prefix=..." even after configure (Glenn Randers-Pehrson) +- allow "configure --prefix $HOME" (Tim Mooney) +- remove warnings in example.c and gzio.c (Glenn Randers-Pehrson) +- move Makefile.sas to amiga/Makefile.sas + +Changes in 1.1.1 (27 Feb 98) +- fix macros _tr_tally_* in deflate.h for debug mode (Glenn Randers-Pehrson) +- remove block truncation heuristic which had very marginal effect for zlib + (smaller lit_bufsize than in gzip 1.2.4) and degraded a little the + compression ratio on some files. This also allows inlining _tr_tally for + matches in deflate_slow +- added msdos/Makefile.w32 for WIN32 Microsoft Visual C++ (Bob Frazier) + +Changes in 1.1.0 (24 Feb 98) +- do not return STREAM_END prematurely in inflate (John Bowler) +- revert to the zlib 1.0.8 inflate to avoid the gcc 2.8.0 bug (Jeremy Buhler) +- compile with -DFASTEST to get compression code optimized for speed only +- in minigzip, try mmap'ing the input file first (Miguel Albrecht) +- increase size of I/O buffers in minigzip.c and gzio.c (not a big gain + on Sun but significant on HP) + +- add a pointer to experimental unzip library in README (Gilles Vollant) +- initialize variable gcc in configure (Chris Herborth) + +Changes in 1.0.9 (17 Feb 1998) +- added gzputs and gzgets functions +- do not clear eof flag in gzseek (Mark Diekhans) +- fix gzseek for files in transparent mode (Mark Diekhans) +- do not assume that vsprintf returns the number of bytes written (Jens Krinke) +- replace EXPORT with ZEXPORT to avoid conflict with other programs +- added compress2 in zconf.h, zlib.def, zlib.dnt +- new asm code from Gilles Vollant in contrib/asm386 +- simplify the inflate code (Mark): + . Replace ZALLOC's in huft_build() with single ZALLOC in inflate_blocks_new() + . ZALLOC the length list in inflate_trees_fixed() instead of using stack + . ZALLOC the value area for huft_build() instead of using stack + . Simplify Z_FINISH check in inflate() + +- Avoid gcc 2.8.0 comparison bug a little differently than zlib 1.0.8 +- in inftrees.c, avoid cc -O bug on HP (Farshid Elahi) +- in zconf.h move the ZLIB_DLL stuff earlier to avoid problems with + the declaration of FAR (Gilles Vollant) +- install libz.so* with mode 755 (executable) instead of 644 (Marc Lehmann) +- read_buf buf parameter of type Bytef* instead of charf* +- zmemcpy parameters are of type Bytef*, not charf* (Joseph Strout) +- do not redeclare unlink in minigzip.c for WIN32 (John Bowler) +- fix check for presence of directories in "make install" (Ian Willis) + +Changes in 1.0.8 (27 Jan 1998) +- fixed offsets in contrib/asm386/gvmat32.asm (Gilles Vollant) +- fix gzgetc and gzputc for big endian systems (Markus Oberhumer) +- added compress2() to allow setting the compression level +- include sys/types.h to get off_t on some systems (Marc Lehmann & QingLong) +- use constant arrays for the static trees in trees.c instead of computing + them at run time (thanks to Ken Raeburn for this suggestion). To create + trees.h, compile with GEN_TREES_H and run "make test" +- check return code of example in "make test" and display result +- pass minigzip command line options to file_compress +- simplifying code of inflateSync to avoid gcc 2.8 bug + +- support CC="gcc -Wall" in configure -s (QingLong) +- avoid a flush caused by ftell in gzopen for write mode (Ken Raeburn) +- fix test for shared library support to avoid compiler warnings +- zlib.lib -> zlib.dll in msdos/zlib.rc (Gilles Vollant) +- check for TARGET_OS_MAC in addition to MACOS (Brad Pettit) +- do not use fdopen for Metrowerks on Mac (Brad Pettit)) +- add checks for gzputc and gzputc in example.c +- avoid warnings in gzio.c and deflate.c (Andreas Kleinert) +- use const for the CRC table (Ken Raeburn) +- fixed "make uninstall" for shared libraries +- use Tracev instead of Trace in infblock.c +- in example.c use correct compressed length for test_sync +- suppress +vnocompatwarnings in configure for HPUX (not always supported) + +Changes in 1.0.7 (20 Jan 1998) +- fix gzseek which was broken in write mode +- return error for gzseek to negative absolute position +- fix configure for Linux (Chun-Chung Chen) +- increase stack space for MSC (Tim Wegner) +- get_crc_table and inflateSyncPoint are EXPORTed (Gilles Vollant) +- define EXPORTVA for gzprintf (Gilles Vollant) +- added man page zlib.3 (Rick Rodgers) +- for contrib/untgz, fix makedir() and improve Makefile + +- check gzseek in write mode in example.c +- allocate extra buffer for seeks only if gzseek is actually called +- avoid signed/unsigned comparisons (Tim Wegner, Gilles Vollant) +- add inflateSyncPoint in zconf.h +- fix list of exported functions in nt/zlib.dnt and mdsos/zlib.def + +Changes in 1.0.6 (19 Jan 1998) +- add functions gzprintf, gzputc, gzgetc, gztell, gzeof, gzseek, gzrewind and + gzsetparams (thanks to Roland Giersig and Kevin Ruland for some of this code) +- Fix a deflate bug occurring only with compression level 0 (thanks to + Andy Buckler for finding this one) +- In minigzip, pass transparently also the first byte for .Z files +- return Z_BUF_ERROR instead of Z_OK if output buffer full in uncompress() +- check Z_FINISH in inflate (thanks to Marc Schluper) +- Implement deflateCopy (thanks to Adam Costello) +- make static libraries by default in configure, add --shared option +- move MSDOS or Windows specific files to directory msdos +- suppress the notion of partial flush to simplify the interface + (but the symbol Z_PARTIAL_FLUSH is kept for compatibility with 1.0.4) +- suppress history buffer provided by application to simplify the interface + (this feature was not implemented anyway in 1.0.4) +- next_in and avail_in must be initialized before calling inflateInit or + inflateInit2 +- add EXPORT in all exported functions (for Windows DLL) +- added Makefile.nt (thanks to Stephen Williams) +- added the unsupported "contrib" directory: + contrib/asm386/ by Gilles Vollant + 386 asm code replacing longest_match() + contrib/iostream/ by Kevin Ruland + A C++ I/O streams interface to the zlib gz* functions + contrib/iostream2/ by Tyge Løvset + Another C++ I/O streams interface + contrib/untgz/ by "Pedro A. Aranda Guti\irrez" + A very simple tar.gz file extractor using zlib + contrib/visual-basic.txt by Carlos Rios + How to use compress(), uncompress() and the gz* functions from VB +- pass params -f (filtered data), -h (huffman only), -1 to -9 (compression + level) in minigzip (thanks to Tom Lane) + +- use const for rommable constants in deflate +- added test for gzseek and gztell in example.c +- add undocumented function inflateSyncPoint() (hack for Paul Mackerras) +- add undocumented function zError to convert error code to string + (for Tim Smithers) +- Allow compilation of gzio with -DNO_DEFLATE to avoid the compression code +- Use default memcpy for Symantec MSDOS compiler +- Add EXPORT keyword for check_func (needed for Windows DLL) +- add current directory to LD_LIBRARY_PATH for "make test" +- create also a link for libz.so.1 +- added support for FUJITSU UXP/DS (thanks to Toshiaki Nomura) +- use $(SHAREDLIB) instead of libz.so in Makefile.in (for HPUX) +- added -soname for Linux in configure (Chun-Chung Chen, +- assign numbers to the exported functions in zlib.def (for Windows DLL) +- add advice in zlib.h for best usage of deflateSetDictionary +- work around compiler bug on Atari (cast Z_NULL in call of s->checkfn) +- allow compilation with ANSI keywords only enabled for TurboC in large model +- avoid "versionString"[0] (Borland bug) +- add NEED_DUMMY_RETURN for Borland +- use variable z_verbose for tracing in debug mode (L. Peter Deutsch) +- allow compilation with CC +- defined STDC for OS/2 (David Charlap) +- limit external names to 8 chars for MVS (Thomas Lund) +- in minigzip.c, use static buffers only for 16-bit systems +- fix suffix check for "minigzip -d foo.gz" +- do not return an error for the 2nd of two consecutive gzflush() (Felix Lee) +- use _fdopen instead of fdopen for MSC >= 6.0 (Thomas Fanslau) +- added makelcc.bat for lcc-win32 (Tom St Denis) +- in Makefile.dj2, use copy and del instead of install and rm (Frank Donahoe) +- Avoid expanded $Id$. Use "rcs -kb" or "cvs admin -kb" to avoid Id expansion +- check for unistd.h in configure (for off_t) +- remove useless check parameter in inflate_blocks_free +- avoid useless assignment of s->check to itself in inflate_blocks_new +- do not flush twice in gzclose (thanks to Ken Raeburn) +- rename FOPEN as F_OPEN to avoid clash with /usr/include/sys/file.h +- use NO_ERRNO_H instead of enumeration of operating systems with errno.h +- work around buggy fclose on pipes for HP/UX +- support zlib DLL with BORLAND C++ 5.0 (thanks to Glenn Randers-Pehrson) +- fix configure if CC is already equal to gcc + +Changes in 1.0.5 (3 Jan 98) +- Fix inflate to terminate gracefully when fed corrupted or invalid data +- Use const for rommable constants in inflate +- Eliminate memory leaks on error conditions in inflate +- Removed some vestigial code in inflate +- Update web address in README + +Changes in 1.0.4 (24 Jul 96) +- In very rare conditions, deflate(s, Z_FINISH) could fail to produce an EOF + bit, so the decompressor could decompress all the correct data but went + on to attempt decompressing extra garbage data. This affected minigzip too +- zlibVersion and gzerror return const char* (needed for DLL) +- port to RISCOS (no fdopen, no multiple dots, no unlink, no fileno) +- use z_error only for DEBUG (avoid problem with DLLs) + +Changes in 1.0.3 (2 Jul 96) +- use z_streamp instead of z_stream *, which is now a far pointer in MSDOS + small and medium models; this makes the library incompatible with previous + versions for these models. (No effect in large model or on other systems.) +- return OK instead of BUF_ERROR if previous deflate call returned with + avail_out as zero but there is nothing to do +- added memcmp for non STDC compilers +- define NO_DUMMY_DECL for more Mac compilers (.h files merged incorrectly) +- define __32BIT__ if __386__ or i386 is defined (pb. with Watcom and SCO) +- better check for 16-bit mode MSC (avoids problem with Symantec) + +Changes in 1.0.2 (23 May 96) +- added Windows DLL support +- added a function zlibVersion (for the DLL support) +- fixed declarations using Bytef in infutil.c (pb with MSDOS medium model) +- Bytef is define's instead of typedef'd only for Borland C +- avoid reading uninitialized memory in example.c +- mention in README that the zlib format is now RFC1950 +- updated Makefile.dj2 +- added algorithm.doc + +Changes in 1.0.1 (20 May 96) [1.0 skipped to avoid confusion] +- fix array overlay in deflate.c which sometimes caused bad compressed data +- fix inflate bug with empty stored block +- fix MSDOS medium model which was broken in 0.99 +- fix deflateParams() which could generate bad compressed data +- Bytef is define'd instead of typedef'ed (work around Borland bug) +- added an INDEX file +- new makefiles for DJGPP (Makefile.dj2), 32-bit Borland (Makefile.b32), + Watcom (Makefile.wat), Amiga SAS/C (Makefile.sas) +- speed up adler32 for modern machines without auto-increment +- added -ansi for IRIX in configure +- static_init_done in trees.c is an int +- define unlink as delete for VMS +- fix configure for QNX +- add configure branch for SCO and HPUX +- avoid many warnings (unused variables, dead assignments, etc...) +- no fdopen for BeOS +- fix the Watcom fix for 32 bit mode (define FAR as empty) +- removed redefinition of Byte for MKWERKS +- work around an MWKERKS bug (incorrect merge of all .h files) + +Changes in 0.99 (27 Jan 96) +- allow preset dictionary shared between compressor and decompressor +- allow compression level 0 (no compression) +- add deflateParams in zlib.h: allow dynamic change of compression level + and compression strategy +- test large buffers and deflateParams in example.c +- add optional "configure" to build zlib as a shared library +- suppress Makefile.qnx, use configure instead +- fixed deflate for 64-bit systems (detected on Cray) +- fixed inflate_blocks for 64-bit systems (detected on Alpha) +- declare Z_DEFLATED in zlib.h (possible parameter for deflateInit2) +- always return Z_BUF_ERROR when deflate() has nothing to do +- deflateInit and inflateInit are now macros to allow version checking +- prefix all global functions and types with z_ with -DZ_PREFIX +- make falloc completely reentrant (inftrees.c) +- fixed very unlikely race condition in ct_static_init +- free in reverse order of allocation to help memory manager +- use zlib-1.0/* instead of zlib/* inside the tar.gz +- make zlib warning-free with "gcc -O3 -Wall -Wwrite-strings -Wpointer-arith + -Wconversion -Wstrict-prototypes -Wmissing-prototypes" +- allow gzread on concatenated .gz files +- deflateEnd now returns Z_DATA_ERROR if it was premature +- deflate is finally (?) fully deterministic (no matches beyond end of input) +- Document Z_SYNC_FLUSH +- add uninstall in Makefile +- Check for __cpluplus in zlib.h +- Better test in ct_align for partial flush +- avoid harmless warnings for Borland C++ +- initialize hash_head in deflate.c +- avoid warning on fdopen (gzio.c) for HP cc -Aa +- include stdlib.h for STDC compilers +- include errno.h for Cray +- ignore error if ranlib doesn't exist +- call ranlib twice for NeXTSTEP +- use exec_prefix instead of prefix for libz.a +- renamed ct_* as _tr_* to avoid conflict with applications +- clear z->msg in inflateInit2 before any error return +- initialize opaque in example.c, gzio.c, deflate.c and inflate.c +- fixed typo in zconf.h (_GNUC__ => __GNUC__) +- check for WIN32 in zconf.h and zutil.c (avoid farmalloc in 32-bit mode) +- fix typo in Make_vms.com (f$trnlnm -> f$getsyi) +- in fcalloc, normalize pointer if size > 65520 bytes +- don't use special fcalloc for 32 bit Borland C++ +- use STDC instead of __GO32__ to avoid redeclaring exit, calloc, etc. +- use Z_BINARY instead of BINARY +- document that gzclose after gzdopen will close the file +- allow "a" as mode in gzopen +- fix error checking in gzread +- allow skipping .gz extra-field on pipes +- added reference to Perl interface in README +- put the crc table in FAR data (I dislike more and more the medium model :) +- added get_crc_table +- added a dimension to all arrays (Borland C can't count) +- workaround Borland C bug in declaration of inflate_codes_new & inflate_fast +- guard against multiple inclusion of *.h (for precompiled header on Mac) +- Watcom C pretends to be Microsoft C small model even in 32 bit mode +- don't use unsized arrays to avoid silly warnings by Visual C++: + warning C4746: 'inflate_mask' : unsized array treated as '__far' + (what's wrong with far data in far model?) +- define enum out of inflate_blocks_state to allow compilation with C++ + +Changes in 0.95 (16 Aug 95) +- fix MSDOS small and medium model (now easier to adapt to any compiler) +- inlined send_bits +- fix the final (:-) bug for deflate with flush (output was correct but + not completely flushed in rare occasions) +- default window size is same for compression and decompression + (it's now sufficient to set MAX_WBITS in zconf.h) +- voidp -> voidpf and voidnp -> voidp (for consistency with other + typedefs and because voidnp was not near in large model) + +Changes in 0.94 (13 Aug 95) +- support MSDOS medium model +- fix deflate with flush (could sometimes generate bad output) +- fix deflateReset (zlib header was incorrectly suppressed) +- added support for VMS +- allow a compression level in gzopen() +- gzflush now calls fflush +- For deflate with flush, flush even if no more input is provided +- rename libgz.a as libz.a +- avoid complex expression in infcodes.c triggering Turbo C bug +- work around a problem with gcc on Alpha (in INSERT_STRING) +- don't use inline functions (problem with some gcc versions) +- allow renaming of Byte, uInt, etc... with #define +- avoid warning about (unused) pointer before start of array in deflate.c +- avoid various warnings in gzio.c, example.c, infblock.c, adler32.c, zutil.c +- avoid reserved word 'new' in trees.c + +Changes in 0.93 (25 June 95) +- temporarily disable inline functions +- make deflate deterministic +- give enough lookahead for PARTIAL_FLUSH +- Set binary mode for stdin/stdout in minigzip.c for OS/2 +- don't even use signed char in inflate (not portable enough) +- fix inflate memory leak for segmented architectures + +Changes in 0.92 (3 May 95) +- don't assume that char is signed (problem on SGI) +- Clear bit buffer when starting a stored block +- no memcpy on Pyramid +- suppressed inftest.c +- optimized fill_window, put longest_match inline for gcc +- optimized inflate on stored blocks +- untabify all sources to simplify patches + +Changes in 0.91 (2 May 95) +- Default MEM_LEVEL is 8 (not 9 for Unix) as documented in zlib.h +- Document the memory requirements in zconf.h +- added "make install" +- fix sync search logic in inflateSync +- deflate(Z_FULL_FLUSH) now works even if output buffer too short +- after inflateSync, don't scare people with just "lo world" +- added support for DJGPP + +Changes in 0.9 (1 May 95) +- don't assume that zalloc clears the allocated memory (the TurboC bug + was Mark's bug after all :) +- let again gzread copy uncompressed data unchanged (was working in 0.71) +- deflate(Z_FULL_FLUSH), inflateReset and inflateSync are now fully implemented +- added a test of inflateSync in example.c +- moved MAX_WBITS to zconf.h because users might want to change that +- document explicitly that zalloc(64K) on MSDOS must return a normalized + pointer (zero offset) +- added Makefiles for Microsoft C, Turbo C, Borland C++ +- faster crc32() + +Changes in 0.8 (29 April 95) +- added fast inflate (inffast.c) +- deflate(Z_FINISH) now returns Z_STREAM_END when done. Warning: this + is incompatible with previous versions of zlib which returned Z_OK +- work around a TurboC compiler bug (bad code for b << 0, see infutil.h) + (actually that was not a compiler bug, see 0.81 above) +- gzread no longer reads one extra byte in certain cases +- In gzio destroy(), don't reference a freed structure +- avoid many warnings for MSDOS +- avoid the ERROR symbol which is used by MS Windows + +Changes in 0.71 (14 April 95) +- Fixed more MSDOS compilation problems :( There is still a bug with + TurboC large model + +Changes in 0.7 (14 April 95) +- Added full inflate support +- Simplified the crc32() interface. The pre- and post-conditioning + (one's complement) is now done inside crc32(). WARNING: this is + incompatible with previous versions; see zlib.h for the new usage + +Changes in 0.61 (12 April 95) +- workaround for a bug in TurboC. example and minigzip now work on MSDOS + +Changes in 0.6 (11 April 95) +- added minigzip.c +- added gzdopen to reopen a file descriptor as gzFile +- added transparent reading of non-gziped files in gzread +- fixed bug in gzread (don't read crc as data) +- fixed bug in destroy (gzio.c) (don't return Z_STREAM_END for gzclose) +- don't allocate big arrays in the stack (for MSDOS) +- fix some MSDOS compilation problems + +Changes in 0.5: +- do real compression in deflate.c. Z_PARTIAL_FLUSH is supported but + not yet Z_FULL_FLUSH +- support decompression but only in a single step (forced Z_FINISH) +- added opaque object for zalloc and zfree +- added deflateReset and inflateReset +- added a variable zlib_version for consistency checking +- renamed the 'filter' parameter of deflateInit2 as 'strategy' + Added Z_FILTERED and Z_HUFFMAN_ONLY constants + +Changes in 0.4: +- avoid "zip" everywhere, use zlib instead of ziplib +- suppress Z_BLOCK_FLUSH, interpret Z_PARTIAL_FLUSH as block flush + if compression method == 8 +- added adler32 and crc32 +- renamed deflateOptions as deflateInit2, call one or the other but not both +- added the method parameter for deflateInit2 +- added inflateInit2 +- simplified considerably deflateInit and inflateInit by not supporting + user-provided history buffer. This is supported only in deflateInit2 + and inflateInit2 + +Changes in 0.3: +- prefix all macro names with Z_ +- use Z_FINISH instead of deflateEnd to finish compression +- added Z_HUFFMAN_ONLY +- added gzerror() diff --git a/common/zlib/LICENSE b/common/zlib/LICENSE new file mode 100644 index 0000000..ab8ee6f --- /dev/null +++ b/common/zlib/LICENSE @@ -0,0 +1,22 @@ +Copyright notice: + + (C) 1995-2022 Jean-loup Gailly and Mark Adler + + This software is provided 'as-is', without any express or implied + warranty. In no event will the authors be held liable for any damages + arising from the use of this software. + + Permission is granted to anyone to use this software for any purpose, + including commercial applications, and to alter it and redistribute it + freely, subject to the following restrictions: + + 1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would be + appreciated but is not required. + 2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + 3. This notice may not be removed or altered from any source distribution. + + Jean-loup Gailly Mark Adler + jloup@gzip.org madler@alumni.caltech.edu diff --git a/common/zlib/README b/common/zlib/README new file mode 100644 index 0000000..c5f9175 --- /dev/null +++ b/common/zlib/README @@ -0,0 +1,117 @@ +ZLIB DATA COMPRESSION LIBRARY + +zlib 1.3.1 is a general purpose data compression library. All the code is +thread safe. The data format used by the zlib library is described by RFCs +(Request for Comments) 1950 to 1952 in the files +http://tools.ietf.org/html/rfc1950 (zlib format), rfc1951 (deflate format) and +rfc1952 (gzip format). + +All functions of the compression library are documented in the file zlib.h +(volunteer to write man pages welcome, contact zlib@gzip.org). A usage example +of the library is given in the file test/example.c which also tests that +the library is working correctly. Another example is given in the file +test/minigzip.c. The compression library itself is composed of all source +files in the root directory. + +To compile all files and run the test program, follow the instructions given at +the top of Makefile.in. In short "./configure; make test", and if that goes +well, "make install" should work for most flavors of Unix. For Windows, use +one of the special makefiles in win32/ or contrib/vstudio/ . For VMS, use +make_vms.com. + +Questions about zlib should be sent to , or to Gilles Vollant + for the Windows DLL version. The zlib home page is +http://zlib.net/ . Before reporting a problem, please check this site to +verify that you have the latest version of zlib; otherwise get the latest +version and check whether the problem still exists or not. + +PLEASE read the zlib FAQ http://zlib.net/zlib_faq.html before asking for help. + +Mark Nelson wrote an article about zlib for the Jan. 1997 +issue of Dr. Dobb's Journal; a copy of the article is available at +https://marknelson.us/posts/1997/01/01/zlib-engine.html . + +The changes made in version 1.3.1 are documented in the file ChangeLog. + +Unsupported third party contributions are provided in directory contrib/ . + +zlib is available in Java using the java.util.zip package. Follow the API +Documentation link at: https://docs.oracle.com/search/?q=java.util.zip . + +A Perl interface to zlib and bzip2 written by Paul Marquess +can be found at https://github.com/pmqs/IO-Compress . + +A Python interface to zlib written by A.M. Kuchling is +available in Python 1.5 and later versions, see +http://docs.python.org/library/zlib.html . + +zlib is built into tcl: http://wiki.tcl.tk/4610 . + +An experimental package to read and write files in .zip format, written on top +of zlib by Gilles Vollant , is available in the +contrib/minizip directory of zlib. + + +Notes for some targets: + +- For Windows DLL versions, please see win32/DLL_FAQ.txt + +- For 64-bit Irix, deflate.c must be compiled without any optimization. With + -O, one libpng test fails. The test works in 32 bit mode (with the -n32 + compiler flag). The compiler bug has been reported to SGI. + +- zlib doesn't work with gcc 2.6.3 on a DEC 3000/300LX under OSF/1 2.1 it works + when compiled with cc. + +- On Digital Unix 4.0D (formerly OSF/1) on AlphaServer, the cc option -std1 is + necessary to get gzprintf working correctly. This is done by configure. + +- zlib doesn't work on HP-UX 9.05 with some versions of /bin/cc. It works with + other compilers. Use "make test" to check your compiler. + +- gzdopen is not supported on RISCOS or BEOS. + +- For PalmOs, see http://palmzlib.sourceforge.net/ + + +Acknowledgments: + + The deflate format used by zlib was defined by Phil Katz. The deflate and + zlib specifications were written by L. Peter Deutsch. Thanks to all the + people who reported problems and suggested various improvements in zlib; they + are too numerous to cite here. + +Copyright notice: + + (C) 1995-2024 Jean-loup Gailly and Mark Adler + + This software is provided 'as-is', without any express or implied + warranty. In no event will the authors be held liable for any damages + arising from the use of this software. + + Permission is granted to anyone to use this software for any purpose, + including commercial applications, and to alter it and redistribute it + freely, subject to the following restrictions: + + 1. The origin of this software must not be misrepresented; you must not + claim that you wrote the original software. If you use this software + in a product, an acknowledgment in the product documentation would be + appreciated but is not required. + 2. Altered source versions must be plainly marked as such, and must not be + misrepresented as being the original software. + 3. This notice may not be removed or altered from any source distribution. + + Jean-loup Gailly Mark Adler + jloup@gzip.org madler@alumni.caltech.edu + +If you use the zlib library in a product, we would appreciate *not* receiving +lengthy legal documents to sign. The sources are provided for free but without +warranty of any kind. The library has been entirely written by Jean-loup +Gailly and Mark Adler; it does not include third-party code. We make all +contributions to and distributions of this project solely in our personal +capacity, and are not conveying any rights to any intellectual property of +any third parties. + +If you redistribute modified sources, we would appreciate that you include in +the file ChangeLog history information documenting your changes. Please read +the FAQ for more information on the distribution of modified source versions. diff --git a/common/zlib/adler32.c b/common/zlib/adler32.c index d0be438..04b81d2 100755 --- a/common/zlib/adler32.c +++ b/common/zlib/adler32.c @@ -7,8 +7,6 @@ #include "zutil.h" -local uLong adler32_combine_ OF((uLong adler1, uLong adler2, z_off64_t len2)); - #define BASE 65521U /* largest prime smaller than 65536 */ #define NMAX 5552 /* NMAX is the largest n such that 255n(n+1)/2 + (n+1)(BASE-1) <= 2^32-1 */ @@ -60,11 +58,7 @@ local uLong adler32_combine_ OF((uLong adler1, uLong adler2, z_off64_t len2)); #endif /* ========================================================================= */ -uLong ZEXPORT adler32_z(adler, buf, len) - uLong adler; - const Bytef *buf; - z_size_t len; -{ +uLong ZEXPORT adler32_z(uLong adler, const Bytef *buf, z_size_t len) { unsigned long sum2; unsigned n; @@ -131,20 +125,12 @@ uLong ZEXPORT adler32_z(adler, buf, len) } /* ========================================================================= */ -uLong ZEXPORT adler32(adler, buf, len) - uLong adler; - const Bytef *buf; - uInt len; -{ +uLong ZEXPORT adler32(uLong adler, const Bytef *buf, uInt len) { return adler32_z(adler, buf, len); } /* ========================================================================= */ -local uLong adler32_combine_(adler1, adler2, len2) - uLong adler1; - uLong adler2; - z_off64_t len2; -{ +local uLong adler32_combine_(uLong adler1, uLong adler2, z_off64_t len2) { unsigned long sum1; unsigned long sum2; unsigned rem; @@ -169,18 +155,10 @@ local uLong adler32_combine_(adler1, adler2, len2) } /* ========================================================================= */ -uLong ZEXPORT adler32_combine(adler1, adler2, len2) - uLong adler1; - uLong adler2; - z_off_t len2; -{ +uLong ZEXPORT adler32_combine(uLong adler1, uLong adler2, z_off_t len2) { return adler32_combine_(adler1, adler2, len2); } -uLong ZEXPORT adler32_combine64(adler1, adler2, len2) - uLong adler1; - uLong adler2; - z_off64_t len2; -{ +uLong ZEXPORT adler32_combine64(uLong adler1, uLong adler2, z_off64_t len2) { return adler32_combine_(adler1, adler2, len2); } diff --git a/common/zlib/compress.c b/common/zlib/compress.c index e2db404..f43bacf 100755 --- a/common/zlib/compress.c +++ b/common/zlib/compress.c @@ -19,13 +19,8 @@ memory, Z_BUF_ERROR if there was not enough room in the output buffer, Z_STREAM_ERROR if the level parameter is invalid. */ -int ZEXPORT compress2 (dest, destLen, source, sourceLen, level) - Bytef *dest; - uLongf *destLen; - const Bytef *source; - uLong sourceLen; - int level; -{ +int ZEXPORT compress2(Bytef *dest, uLongf *destLen, const Bytef *source, + uLong sourceLen, int level) { z_stream stream; int err; const uInt max = (uInt)-1; @@ -65,12 +60,8 @@ int ZEXPORT compress2 (dest, destLen, source, sourceLen, level) /* =========================================================================== */ -int ZEXPORT compress (dest, destLen, source, sourceLen) - Bytef *dest; - uLongf *destLen; - const Bytef *source; - uLong sourceLen; -{ +int ZEXPORT compress(Bytef *dest, uLongf *destLen, const Bytef *source, + uLong sourceLen) { return compress2(dest, destLen, source, sourceLen, Z_DEFAULT_COMPRESSION); } @@ -78,9 +69,7 @@ int ZEXPORT compress (dest, destLen, source, sourceLen) If the default memLevel or windowBits for deflateInit() is changed, then this function needs to be updated. */ -uLong ZEXPORT compressBound (sourceLen) - uLong sourceLen; -{ +uLong ZEXPORT compressBound(uLong sourceLen) { return sourceLen + (sourceLen >> 12) + (sourceLen >> 14) + (sourceLen >> 25) + 13; } diff --git a/common/zlib/crc32.c b/common/zlib/crc32.c old mode 100755 new mode 100644 index 9580440..6c38f5c --- a/common/zlib/crc32.c +++ b/common/zlib/crc32.c @@ -1,12 +1,10 @@ /* crc32.c -- compute the CRC-32 of a data stream - * Copyright (C) 1995-2006, 2010, 2011, 2012, 2016 Mark Adler + * Copyright (C) 1995-2022 Mark Adler * For conditions of distribution and use, see copyright notice in zlib.h * - * Thanks to Rodney Brown for his contribution of faster - * CRC methods: exclusive-oring 32 bits of data at a time, and pre-computing - * tables for updating the shift register in one step with three exclusive-ors - * instead of four steps with four exclusive-ors. This results in about a - * factor of two increase in speed on a Power PC G4 (PPC7455) using gcc -O3. + * This interleaved implementation of a CRC makes use of pipelined multiple + * arithmetic-logic units, commonly found in modern CPU cores. It is due to + * Kadatch and Jenkins (2010). See doc/crc-doc.1.0.pdf in this distribution. */ /* @(#) $Id$ */ @@ -14,11 +12,12 @@ /* Note on the use of DYNAMIC_CRC_TABLE: there is no mutex or semaphore protection on the static variables used to control the first-use generation - of the crc tables. Therefore, if you #define DYNAMIC_CRC_TABLE, you should + of the crc tables. Therefore, if you #define DYNAMIC_CRC_TABLE, you should first call get_crc_table() to initialize the tables before allowing more than one thread to use crc32(). - DYNAMIC_CRC_TABLE and MAKECRCH can be #defined to write out crc32.h. + MAKECRCH can be #defined to write out crc32.h. A main() routine is also + produced, so that this one source file can be compiled to an executable. */ #ifdef MAKECRCH @@ -28,415 +27,1023 @@ # endif /* !DYNAMIC_CRC_TABLE */ #endif /* MAKECRCH */ -#include "zutil.h" /* for STDC and FAR definitions */ +#include "zutil.h" /* for Z_U4, Z_U8, z_crc_t, and FAR definitions */ -/* Definitions for doing the crc four data bytes at a time. */ -#if !defined(NOBYFOUR) && defined(Z_U4) -# define BYFOUR -#endif -#ifdef BYFOUR - local unsigned long crc32_little OF((unsigned long, - const unsigned char FAR *, z_size_t)); - local unsigned long crc32_big OF((unsigned long, - const unsigned char FAR *, z_size_t)); -# define TBLS 8 + /* + A CRC of a message is computed on N braids of words in the message, where + each word consists of W bytes (4 or 8). If N is 3, for example, then three + running sparse CRCs are calculated respectively on each braid, at these + indices in the array of words: 0, 3, 6, ..., 1, 4, 7, ..., and 2, 5, 8, ... + This is done starting at a word boundary, and continues until as many blocks + of N * W bytes as are available have been processed. The results are combined + into a single CRC at the end. For this code, N must be in the range 1..6 and + W must be 4 or 8. The upper limit on N can be increased if desired by adding + more #if blocks, extending the patterns apparent in the code. In addition, + crc32.h would need to be regenerated, if the maximum N value is increased. + + N and W are chosen empirically by benchmarking the execution time on a given + processor. The choices for N and W below were based on testing on Intel Kaby + Lake i7, AMD Ryzen 7, ARM Cortex-A57, Sparc64-VII, PowerPC POWER9, and MIPS64 + Octeon II processors. The Intel, AMD, and ARM processors were all fastest + with N=5, W=8. The Sparc, PowerPC, and MIPS64 were all fastest at N=5, W=4. + They were all tested with either gcc or clang, all using the -O3 optimization + level. Your mileage may vary. + */ + +/* Define N */ +#ifdef Z_TESTN +# define N Z_TESTN #else -# define TBLS 1 -#endif /* BYFOUR */ +# define N 5 +#endif +#if N < 1 || N > 6 +# error N must be in 1..6 +#endif -/* Local functions for crc concatenation */ -local unsigned long gf2_matrix_times OF((unsigned long *mat, - unsigned long vec)); -local void gf2_matrix_square OF((unsigned long *square, unsigned long *mat)); -local uLong crc32_combine_ OF((uLong crc1, uLong crc2, z_off64_t len2)); +/* + z_crc_t must be at least 32 bits. z_word_t must be at least as long as + z_crc_t. It is assumed here that z_word_t is either 32 bits or 64 bits, and + that bytes are eight bits. + */ +/* + Define W and the associated z_word_t type. If W is not defined, then a + braided calculation is not used, and the associated tables and code are not + compiled. + */ +#ifdef Z_TESTW +# if Z_TESTW-1 != -1 +# define W Z_TESTW +# endif +#else +# ifdef MAKECRCH +# define W 8 /* required for MAKECRCH */ +# else +# if defined(__x86_64__) || defined(__aarch64__) +# define W 8 +# else +# define W 4 +# endif +# endif +#endif +#ifdef W +# if W == 8 && defined(Z_U8) + typedef Z_U8 z_word_t; +# elif defined(Z_U4) +# undef W +# define W 4 + typedef Z_U4 z_word_t; +# else +# undef W +# endif +#endif + +/* If available, use the ARM processor CRC32 instruction. */ +#if defined(__aarch64__) && defined(__ARM_FEATURE_CRC32) && W == 8 +# define ARMCRC32 +#endif + +#if defined(W) && (!defined(ARMCRC32) || defined(DYNAMIC_CRC_TABLE)) +/* + Swap the bytes in a z_word_t to convert between little and big endian. Any + self-respecting compiler will optimize this to a single machine byte-swap + instruction, if one is available. This assumes that word_t is either 32 bits + or 64 bits. + */ +local z_word_t byte_swap(z_word_t word) { +# if W == 8 + return + (word & 0xff00000000000000) >> 56 | + (word & 0xff000000000000) >> 40 | + (word & 0xff0000000000) >> 24 | + (word & 0xff00000000) >> 8 | + (word & 0xff000000) << 8 | + (word & 0xff0000) << 24 | + (word & 0xff00) << 40 | + (word & 0xff) << 56; +# else /* W == 4 */ + return + (word & 0xff000000) >> 24 | + (word & 0xff0000) >> 8 | + (word & 0xff00) << 8 | + (word & 0xff) << 24; +# endif +} +#endif #ifdef DYNAMIC_CRC_TABLE +/* ========================================================================= + * Table of powers of x for combining CRC-32s, filled in by make_crc_table() + * below. + */ + local z_crc_t FAR x2n_table[32]; +#else +/* ========================================================================= + * Tables for byte-wise and braided CRC-32 calculations, and a table of powers + * of x for combining CRC-32s, all made by make_crc_table(). + */ +# include "crc32.h" +#endif -local volatile int crc_table_empty = 1; -local z_crc_t FAR crc_table[TBLS][256]; -local void make_crc_table OF((void)); +/* CRC polynomial. */ +#define POLY 0xedb88320 /* p(x) reflected, with x^32 implied */ + +/* + Return a(x) multiplied by b(x) modulo p(x), where p(x) is the CRC polynomial, + reflected. For speed, this requires that a not be zero. + */ +local z_crc_t multmodp(z_crc_t a, z_crc_t b) { + z_crc_t m, p; + + m = (z_crc_t)1 << 31; + p = 0; + for (;;) { + if (a & m) { + p ^= b; + if ((a & (m - 1)) == 0) + break; + } + m >>= 1; + b = b & 1 ? (b >> 1) ^ POLY : b >> 1; + } + return p; +} + +/* + Return x^(n * 2^k) modulo p(x). Requires that x2n_table[] has been + initialized. + */ +local z_crc_t x2nmodp(z_off64_t n, unsigned k) { + z_crc_t p; + + p = (z_crc_t)1 << 31; /* x^0 == 1 */ + while (n) { + if (n & 1) + p = multmodp(x2n_table[k & 31], p); + n >>= 1; + k++; + } + return p; +} + +#ifdef DYNAMIC_CRC_TABLE +/* ========================================================================= + * Build the tables for byte-wise and braided CRC-32 calculations, and a table + * of powers of x for combining CRC-32s. + */ +local z_crc_t FAR crc_table[256]; +#ifdef W + local z_word_t FAR crc_big_table[256]; + local z_crc_t FAR crc_braid_table[W][256]; + local z_word_t FAR crc_braid_big_table[W][256]; + local void braid(z_crc_t [][256], z_word_t [][256], int, int); +#endif #ifdef MAKECRCH - local void write_table OF((FILE *, const z_crc_t FAR *)); + local void write_table(FILE *, const z_crc_t FAR *, int); + local void write_table32hi(FILE *, const z_word_t FAR *, int); + local void write_table64(FILE *, const z_word_t FAR *, int); #endif /* MAKECRCH */ + +/* + Define a once() function depending on the availability of atomics. If this is + compiled with DYNAMIC_CRC_TABLE defined, and if CRCs will be computed in + multiple threads, and if atomics are not available, then get_crc_table() must + be called to initialize the tables and must return before any threads are + allowed to compute or combine CRCs. + */ + +/* Definition of once functionality. */ +typedef struct once_s once_t; + +/* Check for the availability of atomics. */ +#if defined(__STDC__) && __STDC_VERSION__ >= 201112L && \ + !defined(__STDC_NO_ATOMICS__) + +#include + +/* Structure for once(), which must be initialized with ONCE_INIT. */ +struct once_s { + atomic_flag begun; + atomic_int done; +}; +#define ONCE_INIT {ATOMIC_FLAG_INIT, 0} + +/* + Run the provided init() function exactly once, even if multiple threads + invoke once() at the same time. The state must be a once_t initialized with + ONCE_INIT. + */ +local void once(once_t *state, void (*init)(void)) { + if (!atomic_load(&state->done)) { + if (atomic_flag_test_and_set(&state->begun)) + while (!atomic_load(&state->done)) + ; + else { + init(); + atomic_store(&state->done, 1); + } + } +} + +#else /* no atomics */ + +/* Structure for once(), which must be initialized with ONCE_INIT. */ +struct once_s { + volatile int begun; + volatile int done; +}; +#define ONCE_INIT {0, 0} + +/* Test and set. Alas, not atomic, but tries to minimize the period of + vulnerability. */ +local int test_and_set(int volatile *flag) { + int was; + + was = *flag; + *flag = 1; + return was; +} + +/* Run the provided init() function once. This is not thread-safe. */ +local void once(once_t *state, void (*init)(void)) { + if (!state->done) { + if (test_and_set(&state->begun)) + while (!state->done) + ; + else { + init(); + state->done = 1; + } + } +} + +#endif + +/* State for once(). */ +local once_t made = ONCE_INIT; + /* Generate tables for a byte-wise 32-bit CRC calculation on the polynomial: x^32+x^26+x^23+x^22+x^16+x^12+x^11+x^10+x^8+x^7+x^5+x^4+x^2+x+1. Polynomials over GF(2) are represented in binary, one bit per coefficient, - with the lowest powers in the most significant bit. Then adding polynomials + with the lowest powers in the most significant bit. Then adding polynomials is just exclusive-or, and multiplying a polynomial by x is a right shift by - one. If we call the above polynomial p, and represent a byte as the + one. If we call the above polynomial p, and represent a byte as the polynomial q, also with the lowest power in the most significant bit (so the - byte 0xb1 is the polynomial x^7+x^3+x+1), then the CRC is (q*x^32) mod p, + byte 0xb1 is the polynomial x^7+x^3+x^2+1), then the CRC is (q*x^32) mod p, where a mod b means the remainder after dividing a by b. This calculation is done using the shift-register method of multiplying and - taking the remainder. The register is initialized to zero, and for each + taking the remainder. The register is initialized to zero, and for each incoming bit, x^32 is added mod p to the register if the bit is a one (where - x^32 mod p is p+x^32 = x^26+...+1), and the register is multiplied mod p by - x (which is shifting right by one and adding x^32 mod p if the bit shifted - out is a one). We start with the highest power (least significant bit) of - q and repeat for all eight bits of q. + x^32 mod p is p+x^32 = x^26+...+1), and the register is multiplied mod p by x + (which is shifting right by one and adding x^32 mod p if the bit shifted out + is a one). We start with the highest power (least significant bit) of q and + repeat for all eight bits of q. - The first table is simply the CRC of all possible eight bit values. This is - all the information needed to generate CRCs on data a byte at a time for all - combinations of CRC register values and incoming bytes. The remaining tables - allow for word-at-a-time CRC calculation for both big-endian and little- - endian machines, where a word is four bytes. -*/ -local void make_crc_table() -{ - z_crc_t c; - int n, k; - z_crc_t poly; /* polynomial exclusive-or pattern */ - /* terms of polynomial defining this crc (except x^32): */ - static volatile int first = 1; /* flag to limit concurrent making */ - static const unsigned char p[] = {0,1,2,4,5,7,8,10,11,12,16,22,23,26}; + The table is simply the CRC of all possible eight bit values. This is all the + information needed to generate CRCs on data a byte at a time for all + combinations of CRC register values and incoming bytes. + */ - /* See if another task is already doing this (not thread-safe, but better - than nothing -- significantly reduces duration of vulnerability in - case the advice about DYNAMIC_CRC_TABLE is ignored) */ - if (first) { - first = 0; +local void make_crc_table(void) { + unsigned i, j, n; + z_crc_t p; - /* make exclusive-or pattern from polynomial (0xedb88320UL) */ - poly = 0; - for (n = 0; n < (int)(sizeof(p)/sizeof(unsigned char)); n++) - poly |= (z_crc_t)1 << (31 - p[n]); - - /* generate a crc for every 8-bit value */ - for (n = 0; n < 256; n++) { - c = (z_crc_t)n; - for (k = 0; k < 8; k++) - c = c & 1 ? poly ^ (c >> 1) : c >> 1; - crc_table[0][n] = c; - } - -#ifdef BYFOUR - /* generate crc for each value followed by one, two, and three zeros, - and then the byte reversal of those as well as the first table */ - for (n = 0; n < 256; n++) { - c = crc_table[0][n]; - crc_table[4][n] = ZSWAP32(c); - for (k = 1; k < 4; k++) { - c = crc_table[0][c & 0xff] ^ (c >> 8); - crc_table[k][n] = c; - crc_table[k + 4][n] = ZSWAP32(c); - } - } -#endif /* BYFOUR */ - - crc_table_empty = 0; - } - else { /* not first */ - /* wait for the other guy to finish (not efficient, but rare) */ - while (crc_table_empty) - ; + /* initialize the CRC of bytes tables */ + for (i = 0; i < 256; i++) { + p = i; + for (j = 0; j < 8; j++) + p = p & 1 ? (p >> 1) ^ POLY : p >> 1; + crc_table[i] = p; +#ifdef W + crc_big_table[i] = byte_swap(p); +#endif } + /* initialize the x^2^n mod p(x) table */ + p = (z_crc_t)1 << 30; /* x^1 */ + x2n_table[0] = p; + for (n = 1; n < 32; n++) + x2n_table[n] = p = multmodp(p, p); + +#ifdef W + /* initialize the braiding tables -- needs x2n_table[] */ + braid(crc_braid_table, crc_braid_big_table, N, W); +#endif + #ifdef MAKECRCH - /* write out CRC tables to crc32.h */ { + /* + The crc32.h header file contains tables for both 32-bit and 64-bit + z_word_t's, and so requires a 64-bit type be available. In that case, + z_word_t must be defined to be 64-bits. This code then also generates + and writes out the tables for the case that z_word_t is 32 bits. + */ +#if !defined(W) || W != 8 +# error Need a 64-bit integer type in order to generate crc32.h. +#endif FILE *out; + int k, n; + z_crc_t ltl[8][256]; + z_word_t big[8][256]; out = fopen("crc32.h", "w"); if (out == NULL) return; - fprintf(out, "/* crc32.h -- tables for rapid CRC calculation\n"); - fprintf(out, " * Generated automatically by crc32.c\n */\n\n"); - fprintf(out, "local const z_crc_t FAR "); - fprintf(out, "crc_table[TBLS][256] =\n{\n {\n"); - write_table(out, crc_table[0]); -# ifdef BYFOUR - fprintf(out, "#ifdef BYFOUR\n"); - for (k = 1; k < 8; k++) { - fprintf(out, " },\n {\n"); - write_table(out, crc_table[k]); + + /* write out little-endian CRC table to crc32.h */ + fprintf(out, + "/* crc32.h -- tables for rapid CRC calculation\n" + " * Generated automatically by crc32.c\n */\n" + "\n" + "local const z_crc_t FAR crc_table[] = {\n" + " "); + write_table(out, crc_table, 256); + fprintf(out, + "};\n"); + + /* write out big-endian CRC table for 64-bit z_word_t to crc32.h */ + fprintf(out, + "\n" + "#ifdef W\n" + "\n" + "#if W == 8\n" + "\n" + "local const z_word_t FAR crc_big_table[] = {\n" + " "); + write_table64(out, crc_big_table, 256); + fprintf(out, + "};\n"); + + /* write out big-endian CRC table for 32-bit z_word_t to crc32.h */ + fprintf(out, + "\n" + "#else /* W == 4 */\n" + "\n" + "local const z_word_t FAR crc_big_table[] = {\n" + " "); + write_table32hi(out, crc_big_table, 256); + fprintf(out, + "};\n" + "\n" + "#endif\n"); + + /* write out braid tables for each value of N */ + for (n = 1; n <= 6; n++) { + fprintf(out, + "\n" + "#if N == %d\n", n); + + /* compute braid tables for this N and 64-bit word_t */ + braid(ltl, big, n, 8); + + /* write out braid tables for 64-bit z_word_t to crc32.h */ + fprintf(out, + "\n" + "#if W == 8\n" + "\n" + "local const z_crc_t FAR crc_braid_table[][256] = {\n"); + for (k = 0; k < 8; k++) { + fprintf(out, " {"); + write_table(out, ltl[k], 256); + fprintf(out, "}%s", k < 7 ? ",\n" : ""); + } + fprintf(out, + "};\n" + "\n" + "local const z_word_t FAR crc_braid_big_table[][256] = {\n"); + for (k = 0; k < 8; k++) { + fprintf(out, " {"); + write_table64(out, big[k], 256); + fprintf(out, "}%s", k < 7 ? ",\n" : ""); + } + fprintf(out, + "};\n"); + + /* compute braid tables for this N and 32-bit word_t */ + braid(ltl, big, n, 4); + + /* write out braid tables for 32-bit z_word_t to crc32.h */ + fprintf(out, + "\n" + "#else /* W == 4 */\n" + "\n" + "local const z_crc_t FAR crc_braid_table[][256] = {\n"); + for (k = 0; k < 4; k++) { + fprintf(out, " {"); + write_table(out, ltl[k], 256); + fprintf(out, "}%s", k < 3 ? ",\n" : ""); + } + fprintf(out, + "};\n" + "\n" + "local const z_word_t FAR crc_braid_big_table[][256] = {\n"); + for (k = 0; k < 4; k++) { + fprintf(out, " {"); + write_table32hi(out, big[k], 256); + fprintf(out, "}%s", k < 3 ? ",\n" : ""); + } + fprintf(out, + "};\n" + "\n" + "#endif\n" + "\n" + "#endif\n"); } - fprintf(out, "#endif\n"); -# endif /* BYFOUR */ - fprintf(out, " }\n};\n"); + fprintf(out, + "\n" + "#endif\n"); + + /* write out zeros operator table to crc32.h */ + fprintf(out, + "\n" + "local const z_crc_t FAR x2n_table[] = {\n" + " "); + write_table(out, x2n_table, 32); + fprintf(out, + "};\n"); fclose(out); } #endif /* MAKECRCH */ } #ifdef MAKECRCH -local void write_table(out, table) - FILE *out; - const z_crc_t FAR *table; -{ + +/* + Write the 32-bit values in table[0..k-1] to out, five per line in + hexadecimal separated by commas. + */ +local void write_table(FILE *out, const z_crc_t FAR *table, int k) { int n; - for (n = 0; n < 256; n++) - fprintf(out, "%s0x%08lxUL%s", n % 5 ? "" : " ", + for (n = 0; n < k; n++) + fprintf(out, "%s0x%08lx%s", n == 0 || n % 5 ? "" : " ", (unsigned long)(table[n]), - n == 255 ? "\n" : (n % 5 == 4 ? ",\n" : ", ")); + n == k - 1 ? "" : (n % 5 == 4 ? ",\n" : ", ")); } + +/* + Write the high 32-bits of each value in table[0..k-1] to out, five per line + in hexadecimal separated by commas. + */ +local void write_table32hi(FILE *out, const z_word_t FAR *table, int k) { + int n; + + for (n = 0; n < k; n++) + fprintf(out, "%s0x%08lx%s", n == 0 || n % 5 ? "" : " ", + (unsigned long)(table[n] >> 32), + n == k - 1 ? "" : (n % 5 == 4 ? ",\n" : ", ")); +} + +/* + Write the 64-bit values in table[0..k-1] to out, three per line in + hexadecimal separated by commas. This assumes that if there is a 64-bit + type, then there is also a long long integer type, and it is at least 64 + bits. If not, then the type cast and format string can be adjusted + accordingly. + */ +local void write_table64(FILE *out, const z_word_t FAR *table, int k) { + int n; + + for (n = 0; n < k; n++) + fprintf(out, "%s0x%016llx%s", n == 0 || n % 3 ? "" : " ", + (unsigned long long)(table[n]), + n == k - 1 ? "" : (n % 3 == 2 ? ",\n" : ", ")); +} + +/* Actually do the deed. */ +int main(void) { + make_crc_table(); + return 0; +} + #endif /* MAKECRCH */ -#else /* !DYNAMIC_CRC_TABLE */ -/* ======================================================================== - * Tables of CRC-32s of all single-byte values, made by make_crc_table(). +#ifdef W +/* + Generate the little and big-endian braid tables for the given n and z_word_t + size w. Each array must have room for w blocks of 256 elements. */ -#include "crc32.h" +local void braid(z_crc_t ltl[][256], z_word_t big[][256], int n, int w) { + int k; + z_crc_t i, p, q; + for (k = 0; k < w; k++) { + p = x2nmodp((n * w + 3 - k) << 3, 0); + ltl[k][0] = 0; + big[w - 1 - k][0] = 0; + for (i = 1; i < 256; i++) { + ltl[k][i] = q = multmodp(i << 24, p); + big[w - 1 - k][i] = byte_swap(q); + } + } +} +#endif + #endif /* DYNAMIC_CRC_TABLE */ /* ========================================================================= - * This function can be used by asm versions of crc32() + * This function can be used by asm versions of crc32(), and to force the + * generation of the CRC tables in a threaded application. */ -const z_crc_t FAR * ZEXPORT get_crc_table() -{ +const z_crc_t FAR * ZEXPORT get_crc_table(void) { #ifdef DYNAMIC_CRC_TABLE - if (crc_table_empty) - make_crc_table(); + once(&made, make_crc_table); #endif /* DYNAMIC_CRC_TABLE */ return (const z_crc_t FAR *)crc_table; } -/* ========================================================================= */ -#define DO1 crc = crc_table[0][((int)crc ^ (*buf++)) & 0xff] ^ (crc >> 8) -#define DO8 DO1; DO1; DO1; DO1; DO1; DO1; DO1; DO1 +/* ========================================================================= + * Use ARM machine instructions if available. This will compute the CRC about + * ten times faster than the braided calculation. This code does not check for + * the presence of the CRC instruction at run time. __ARM_FEATURE_CRC32 will + * only be defined if the compilation specifies an ARM processor architecture + * that has the instructions. For example, compiling with -march=armv8.1-a or + * -march=armv8-a+crc, or -march=native if the compile machine has the crc32 + * instructions. + */ +#ifdef ARMCRC32 -/* ========================================================================= */ -unsigned long ZEXPORT crc32_z(crc, buf, len) - unsigned long crc; - const unsigned char FAR *buf; - z_size_t len; -{ - if (buf == Z_NULL) return 0UL; +/* + Constants empirically determined to maximize speed. These values are from + measurements on a Cortex-A57. Your mileage may vary. + */ +#define Z_BATCH 3990 /* number of words in a batch */ +#define Z_BATCH_ZEROS 0xa10d3d0c /* computed from Z_BATCH = 3990 */ +#define Z_BATCH_MIN 800 /* fewest words in a final batch */ + +unsigned long ZEXPORT crc32_z(unsigned long crc, const unsigned char FAR *buf, + z_size_t len) { + z_crc_t val; + z_word_t crc1, crc2; + const z_word_t *word; + z_word_t val0, val1, val2; + z_size_t last, last2, i; + z_size_t num; + + /* Return initial CRC, if requested. */ + if (buf == Z_NULL) return 0; #ifdef DYNAMIC_CRC_TABLE - if (crc_table_empty) - make_crc_table(); + once(&made, make_crc_table); #endif /* DYNAMIC_CRC_TABLE */ -#ifdef BYFOUR - if (sizeof(void *) == sizeof(ptrdiff_t)) { - z_crc_t endian; + /* Pre-condition the CRC */ + crc = (~crc) & 0xffffffff; - endian = 1; - if (*((unsigned char *)(&endian))) - return crc32_little(crc, buf, len); - else - return crc32_big(crc, buf, len); + /* Compute the CRC up to a word boundary. */ + while (len && ((z_size_t)buf & 7) != 0) { + len--; + val = *buf++; + __asm__ volatile("crc32b %w0, %w0, %w1" : "+r"(crc) : "r"(val)); } -#endif /* BYFOUR */ - crc = crc ^ 0xffffffffUL; - while (len >= 8) { - DO8; - len -= 8; + + /* Prepare to compute the CRC on full 64-bit words word[0..num-1]. */ + word = (z_word_t const *)buf; + num = len >> 3; + len &= 7; + + /* Do three interleaved CRCs to realize the throughput of one crc32x + instruction per cycle. Each CRC is calculated on Z_BATCH words. The + three CRCs are combined into a single CRC after each set of batches. */ + while (num >= 3 * Z_BATCH) { + crc1 = 0; + crc2 = 0; + for (i = 0; i < Z_BATCH; i++) { + val0 = word[i]; + val1 = word[i + Z_BATCH]; + val2 = word[i + 2 * Z_BATCH]; + __asm__ volatile("crc32x %w0, %w0, %x1" : "+r"(crc) : "r"(val0)); + __asm__ volatile("crc32x %w0, %w0, %x1" : "+r"(crc1) : "r"(val1)); + __asm__ volatile("crc32x %w0, %w0, %x1" : "+r"(crc2) : "r"(val2)); + } + word += 3 * Z_BATCH; + num -= 3 * Z_BATCH; + crc = multmodp(Z_BATCH_ZEROS, crc) ^ crc1; + crc = multmodp(Z_BATCH_ZEROS, crc) ^ crc2; } - if (len) do { - DO1; - } while (--len); - return crc ^ 0xffffffffUL; + + /* Do one last smaller batch with the remaining words, if there are enough + to pay for the combination of CRCs. */ + last = num / 3; + if (last >= Z_BATCH_MIN) { + last2 = last << 1; + crc1 = 0; + crc2 = 0; + for (i = 0; i < last; i++) { + val0 = word[i]; + val1 = word[i + last]; + val2 = word[i + last2]; + __asm__ volatile("crc32x %w0, %w0, %x1" : "+r"(crc) : "r"(val0)); + __asm__ volatile("crc32x %w0, %w0, %x1" : "+r"(crc1) : "r"(val1)); + __asm__ volatile("crc32x %w0, %w0, %x1" : "+r"(crc2) : "r"(val2)); + } + word += 3 * last; + num -= 3 * last; + val = x2nmodp(last, 6); + crc = multmodp(val, crc) ^ crc1; + crc = multmodp(val, crc) ^ crc2; + } + + /* Compute the CRC on any remaining words. */ + for (i = 0; i < num; i++) { + val0 = word[i]; + __asm__ volatile("crc32x %w0, %w0, %x1" : "+r"(crc) : "r"(val0)); + } + word += num; + + /* Complete the CRC on any remaining bytes. */ + buf = (const unsigned char FAR *)word; + while (len) { + len--; + val = *buf++; + __asm__ volatile("crc32b %w0, %w0, %w1" : "+r"(crc) : "r"(val)); + } + + /* Return the CRC, post-conditioned. */ + return crc ^ 0xffffffff; } +#else + +#ifdef W + +/* + Return the CRC of the W bytes in the word_t data, taking the + least-significant byte of the word as the first byte of data, without any pre + or post conditioning. This is used to combine the CRCs of each braid. + */ +local z_crc_t crc_word(z_word_t data) { + int k; + for (k = 0; k < W; k++) + data = (data >> 8) ^ crc_table[data & 0xff]; + return (z_crc_t)data; +} + +local z_word_t crc_word_big(z_word_t data) { + int k; + for (k = 0; k < W; k++) + data = (data << 8) ^ + crc_big_table[(data >> ((W - 1) << 3)) & 0xff]; + return data; +} + +#endif + /* ========================================================================= */ -unsigned long ZEXPORT crc32(crc, buf, len) - unsigned long crc; - const unsigned char FAR *buf; - uInt len; -{ +unsigned long ZEXPORT crc32_z(unsigned long crc, const unsigned char FAR *buf, + z_size_t len) { + /* Return initial CRC, if requested. */ + if (buf == Z_NULL) return 0; + +#ifdef DYNAMIC_CRC_TABLE + once(&made, make_crc_table); +#endif /* DYNAMIC_CRC_TABLE */ + + /* Pre-condition the CRC */ + crc = (~crc) & 0xffffffff; + +#ifdef W + + /* If provided enough bytes, do a braided CRC calculation. */ + if (len >= N * W + W - 1) { + z_size_t blks; + z_word_t const *words; + unsigned endian; + int k; + + /* Compute the CRC up to a z_word_t boundary. */ + while (len && ((z_size_t)buf & (W - 1)) != 0) { + len--; + crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff]; + } + + /* Compute the CRC on as many N z_word_t blocks as are available. */ + blks = len / (N * W); + len -= blks * N * W; + words = (z_word_t const *)buf; + + /* Do endian check at execution time instead of compile time, since ARM + processors can change the endianness at execution time. If the + compiler knows what the endianness will be, it can optimize out the + check and the unused branch. */ + endian = 1; + if (*(unsigned char *)&endian) { + /* Little endian. */ + + z_crc_t crc0; + z_word_t word0; +#if N > 1 + z_crc_t crc1; + z_word_t word1; +#if N > 2 + z_crc_t crc2; + z_word_t word2; +#if N > 3 + z_crc_t crc3; + z_word_t word3; +#if N > 4 + z_crc_t crc4; + z_word_t word4; +#if N > 5 + z_crc_t crc5; + z_word_t word5; +#endif +#endif +#endif +#endif +#endif + + /* Initialize the CRC for each braid. */ + crc0 = crc; +#if N > 1 + crc1 = 0; +#if N > 2 + crc2 = 0; +#if N > 3 + crc3 = 0; +#if N > 4 + crc4 = 0; +#if N > 5 + crc5 = 0; +#endif +#endif +#endif +#endif +#endif + + /* + Process the first blks-1 blocks, computing the CRCs on each braid + independently. + */ + while (--blks) { + /* Load the word for each braid into registers. */ + word0 = crc0 ^ words[0]; +#if N > 1 + word1 = crc1 ^ words[1]; +#if N > 2 + word2 = crc2 ^ words[2]; +#if N > 3 + word3 = crc3 ^ words[3]; +#if N > 4 + word4 = crc4 ^ words[4]; +#if N > 5 + word5 = crc5 ^ words[5]; +#endif +#endif +#endif +#endif +#endif + words += N; + + /* Compute and update the CRC for each word. The loop should + get unrolled. */ + crc0 = crc_braid_table[0][word0 & 0xff]; +#if N > 1 + crc1 = crc_braid_table[0][word1 & 0xff]; +#if N > 2 + crc2 = crc_braid_table[0][word2 & 0xff]; +#if N > 3 + crc3 = crc_braid_table[0][word3 & 0xff]; +#if N > 4 + crc4 = crc_braid_table[0][word4 & 0xff]; +#if N > 5 + crc5 = crc_braid_table[0][word5 & 0xff]; +#endif +#endif +#endif +#endif +#endif + for (k = 1; k < W; k++) { + crc0 ^= crc_braid_table[k][(word0 >> (k << 3)) & 0xff]; +#if N > 1 + crc1 ^= crc_braid_table[k][(word1 >> (k << 3)) & 0xff]; +#if N > 2 + crc2 ^= crc_braid_table[k][(word2 >> (k << 3)) & 0xff]; +#if N > 3 + crc3 ^= crc_braid_table[k][(word3 >> (k << 3)) & 0xff]; +#if N > 4 + crc4 ^= crc_braid_table[k][(word4 >> (k << 3)) & 0xff]; +#if N > 5 + crc5 ^= crc_braid_table[k][(word5 >> (k << 3)) & 0xff]; +#endif +#endif +#endif +#endif +#endif + } + } + + /* + Process the last block, combining the CRCs of the N braids at the + same time. + */ + crc = crc_word(crc0 ^ words[0]); +#if N > 1 + crc = crc_word(crc1 ^ words[1] ^ crc); +#if N > 2 + crc = crc_word(crc2 ^ words[2] ^ crc); +#if N > 3 + crc = crc_word(crc3 ^ words[3] ^ crc); +#if N > 4 + crc = crc_word(crc4 ^ words[4] ^ crc); +#if N > 5 + crc = crc_word(crc5 ^ words[5] ^ crc); +#endif +#endif +#endif +#endif +#endif + words += N; + } + else { + /* Big endian. */ + + z_word_t crc0, word0, comb; +#if N > 1 + z_word_t crc1, word1; +#if N > 2 + z_word_t crc2, word2; +#if N > 3 + z_word_t crc3, word3; +#if N > 4 + z_word_t crc4, word4; +#if N > 5 + z_word_t crc5, word5; +#endif +#endif +#endif +#endif +#endif + + /* Initialize the CRC for each braid. */ + crc0 = byte_swap(crc); +#if N > 1 + crc1 = 0; +#if N > 2 + crc2 = 0; +#if N > 3 + crc3 = 0; +#if N > 4 + crc4 = 0; +#if N > 5 + crc5 = 0; +#endif +#endif +#endif +#endif +#endif + + /* + Process the first blks-1 blocks, computing the CRCs on each braid + independently. + */ + while (--blks) { + /* Load the word for each braid into registers. */ + word0 = crc0 ^ words[0]; +#if N > 1 + word1 = crc1 ^ words[1]; +#if N > 2 + word2 = crc2 ^ words[2]; +#if N > 3 + word3 = crc3 ^ words[3]; +#if N > 4 + word4 = crc4 ^ words[4]; +#if N > 5 + word5 = crc5 ^ words[5]; +#endif +#endif +#endif +#endif +#endif + words += N; + + /* Compute and update the CRC for each word. The loop should + get unrolled. */ + crc0 = crc_braid_big_table[0][word0 & 0xff]; +#if N > 1 + crc1 = crc_braid_big_table[0][word1 & 0xff]; +#if N > 2 + crc2 = crc_braid_big_table[0][word2 & 0xff]; +#if N > 3 + crc3 = crc_braid_big_table[0][word3 & 0xff]; +#if N > 4 + crc4 = crc_braid_big_table[0][word4 & 0xff]; +#if N > 5 + crc5 = crc_braid_big_table[0][word5 & 0xff]; +#endif +#endif +#endif +#endif +#endif + for (k = 1; k < W; k++) { + crc0 ^= crc_braid_big_table[k][(word0 >> (k << 3)) & 0xff]; +#if N > 1 + crc1 ^= crc_braid_big_table[k][(word1 >> (k << 3)) & 0xff]; +#if N > 2 + crc2 ^= crc_braid_big_table[k][(word2 >> (k << 3)) & 0xff]; +#if N > 3 + crc3 ^= crc_braid_big_table[k][(word3 >> (k << 3)) & 0xff]; +#if N > 4 + crc4 ^= crc_braid_big_table[k][(word4 >> (k << 3)) & 0xff]; +#if N > 5 + crc5 ^= crc_braid_big_table[k][(word5 >> (k << 3)) & 0xff]; +#endif +#endif +#endif +#endif +#endif + } + } + + /* + Process the last block, combining the CRCs of the N braids at the + same time. + */ + comb = crc_word_big(crc0 ^ words[0]); +#if N > 1 + comb = crc_word_big(crc1 ^ words[1] ^ comb); +#if N > 2 + comb = crc_word_big(crc2 ^ words[2] ^ comb); +#if N > 3 + comb = crc_word_big(crc3 ^ words[3] ^ comb); +#if N > 4 + comb = crc_word_big(crc4 ^ words[4] ^ comb); +#if N > 5 + comb = crc_word_big(crc5 ^ words[5] ^ comb); +#endif +#endif +#endif +#endif +#endif + words += N; + crc = byte_swap(comb); + } + + /* + Update the pointer to the remaining bytes to process. + */ + buf = (unsigned char const *)words; + } + +#endif /* W */ + + /* Complete the computation of the CRC on any remaining bytes. */ + while (len >= 8) { + len -= 8; + crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff]; + crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff]; + crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff]; + crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff]; + crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff]; + crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff]; + crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff]; + crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff]; + } + while (len) { + len--; + crc = (crc >> 8) ^ crc_table[(crc ^ *buf++) & 0xff]; + } + + /* Return the CRC, post-conditioned. */ + return crc ^ 0xffffffff; +} + +#endif + +/* ========================================================================= */ +unsigned long ZEXPORT crc32(unsigned long crc, const unsigned char FAR *buf, + uInt len) { return crc32_z(crc, buf, len); } -#ifdef BYFOUR - -/* - This BYFOUR code accesses the passed unsigned char * buffer with a 32-bit - integer pointer type. This violates the strict aliasing rule, where a - compiler can assume, for optimization purposes, that two pointers to - fundamentally different types won't ever point to the same memory. This can - manifest as a problem only if one of the pointers is written to. This code - only reads from those pointers. So long as this code remains isolated in - this compilation unit, there won't be a problem. For this reason, this code - should not be copied and pasted into a compilation unit in which other code - writes to the buffer that is passed to these routines. - */ - /* ========================================================================= */ -#define DOLIT4 c ^= *buf4++; \ - c = crc_table[3][c & 0xff] ^ crc_table[2][(c >> 8) & 0xff] ^ \ - crc_table[1][(c >> 16) & 0xff] ^ crc_table[0][c >> 24] -#define DOLIT32 DOLIT4; DOLIT4; DOLIT4; DOLIT4; DOLIT4; DOLIT4; DOLIT4; DOLIT4 - -/* ========================================================================= */ -local unsigned long crc32_little(crc, buf, len) - unsigned long crc; - const unsigned char FAR *buf; - z_size_t len; -{ - register z_crc_t c; - register const z_crc_t FAR *buf4; - - c = (z_crc_t)crc; - c = ~c; - while (len && ((ptrdiff_t)buf & 3)) { - c = crc_table[0][(c ^ *buf++) & 0xff] ^ (c >> 8); - len--; - } - - buf4 = (const z_crc_t FAR *)(const void FAR *)buf; - while (len >= 32) { - DOLIT32; - len -= 32; - } - while (len >= 4) { - DOLIT4; - len -= 4; - } - buf = (const unsigned char FAR *)buf4; - - if (len) do { - c = crc_table[0][(c ^ *buf++) & 0xff] ^ (c >> 8); - } while (--len); - c = ~c; - return (unsigned long)c; +uLong ZEXPORT crc32_combine64(uLong crc1, uLong crc2, z_off64_t len2) { +#ifdef DYNAMIC_CRC_TABLE + once(&made, make_crc_table); +#endif /* DYNAMIC_CRC_TABLE */ + return multmodp(x2nmodp(len2, 3), crc1) ^ (crc2 & 0xffffffff); } /* ========================================================================= */ -#define DOBIG4 c ^= *buf4++; \ - c = crc_table[4][c & 0xff] ^ crc_table[5][(c >> 8) & 0xff] ^ \ - crc_table[6][(c >> 16) & 0xff] ^ crc_table[7][c >> 24] -#define DOBIG32 DOBIG4; DOBIG4; DOBIG4; DOBIG4; DOBIG4; DOBIG4; DOBIG4; DOBIG4 - -/* ========================================================================= */ -local unsigned long crc32_big(crc, buf, len) - unsigned long crc; - const unsigned char FAR *buf; - z_size_t len; -{ - register z_crc_t c; - register const z_crc_t FAR *buf4; - - c = ZSWAP32((z_crc_t)crc); - c = ~c; - while (len && ((ptrdiff_t)buf & 3)) { - c = crc_table[4][(c >> 24) ^ *buf++] ^ (c << 8); - len--; - } - - buf4 = (const z_crc_t FAR *)(const void FAR *)buf; - while (len >= 32) { - DOBIG32; - len -= 32; - } - while (len >= 4) { - DOBIG4; - len -= 4; - } - buf = (const unsigned char FAR *)buf4; - - if (len) do { - c = crc_table[4][(c >> 24) ^ *buf++] ^ (c << 8); - } while (--len); - c = ~c; - return (unsigned long)(ZSWAP32(c)); -} - -#endif /* BYFOUR */ - -#define GF2_DIM 32 /* dimension of GF(2) vectors (length of CRC) */ - -/* ========================================================================= */ -local unsigned long gf2_matrix_times(mat, vec) - unsigned long *mat; - unsigned long vec; -{ - unsigned long sum; - - sum = 0; - while (vec) { - if (vec & 1) - sum ^= *mat; - vec >>= 1; - mat++; - } - return sum; +uLong ZEXPORT crc32_combine(uLong crc1, uLong crc2, z_off_t len2) { + return crc32_combine64(crc1, crc2, (z_off64_t)len2); } /* ========================================================================= */ -local void gf2_matrix_square(square, mat) - unsigned long *square; - unsigned long *mat; -{ - int n; - - for (n = 0; n < GF2_DIM; n++) - square[n] = gf2_matrix_times(mat, mat[n]); +uLong ZEXPORT crc32_combine_gen64(z_off64_t len2) { +#ifdef DYNAMIC_CRC_TABLE + once(&made, make_crc_table); +#endif /* DYNAMIC_CRC_TABLE */ + return x2nmodp(len2, 3); } /* ========================================================================= */ -local uLong crc32_combine_(crc1, crc2, len2) - uLong crc1; - uLong crc2; - z_off64_t len2; -{ - int n; - unsigned long row; - unsigned long even[GF2_DIM]; /* even-power-of-two zeros operator */ - unsigned long odd[GF2_DIM]; /* odd-power-of-two zeros operator */ - - /* degenerate case (also disallow negative lengths) */ - if (len2 <= 0) - return crc1; - - /* put operator for one zero bit in odd */ - odd[0] = 0xedb88320UL; /* CRC-32 polynomial */ - row = 1; - for (n = 1; n < GF2_DIM; n++) { - odd[n] = row; - row <<= 1; - } - - /* put operator for two zero bits in even */ - gf2_matrix_square(even, odd); - - /* put operator for four zero bits in odd */ - gf2_matrix_square(odd, even); - - /* apply len2 zeros to crc1 (first square will put the operator for one - zero byte, eight zero bits, in even) */ - do { - /* apply zeros operator for this bit of len2 */ - gf2_matrix_square(even, odd); - if (len2 & 1) - crc1 = gf2_matrix_times(even, crc1); - len2 >>= 1; - - /* if no more bits set, then done */ - if (len2 == 0) - break; - - /* another iteration of the loop with odd and even swapped */ - gf2_matrix_square(odd, even); - if (len2 & 1) - crc1 = gf2_matrix_times(odd, crc1); - len2 >>= 1; - - /* if no more bits set, then done */ - } while (len2 != 0); - - /* return combined crc */ - crc1 ^= crc2; - return crc1; +uLong ZEXPORT crc32_combine_gen(z_off_t len2) { + return crc32_combine_gen64((z_off64_t)len2); } /* ========================================================================= */ -uLong ZEXPORT crc32_combine(crc1, crc2, len2) - uLong crc1; - uLong crc2; - z_off_t len2; -{ - return crc32_combine_(crc1, crc2, len2); -} - -uLong ZEXPORT crc32_combine64(crc1, crc2, len2) - uLong crc1; - uLong crc2; - z_off64_t len2; -{ - return crc32_combine_(crc1, crc2, len2); +uLong ZEXPORT crc32_combine_op(uLong crc1, uLong crc2, uLong op) { + return multmodp(op, crc1) ^ (crc2 & 0xffffffff); } diff --git a/common/zlib/crc32.h b/common/zlib/crc32.h old mode 100755 new mode 100644 index 9e0c778..137df68 --- a/common/zlib/crc32.h +++ b/common/zlib/crc32.h @@ -2,440 +2,9445 @@ * Generated automatically by crc32.c */ -local const z_crc_t FAR crc_table[TBLS][256] = -{ - { - 0x00000000UL, 0x77073096UL, 0xee0e612cUL, 0x990951baUL, 0x076dc419UL, - 0x706af48fUL, 0xe963a535UL, 0x9e6495a3UL, 0x0edb8832UL, 0x79dcb8a4UL, - 0xe0d5e91eUL, 0x97d2d988UL, 0x09b64c2bUL, 0x7eb17cbdUL, 0xe7b82d07UL, - 0x90bf1d91UL, 0x1db71064UL, 0x6ab020f2UL, 0xf3b97148UL, 0x84be41deUL, - 0x1adad47dUL, 0x6ddde4ebUL, 0xf4d4b551UL, 0x83d385c7UL, 0x136c9856UL, - 0x646ba8c0UL, 0xfd62f97aUL, 0x8a65c9ecUL, 0x14015c4fUL, 0x63066cd9UL, - 0xfa0f3d63UL, 0x8d080df5UL, 0x3b6e20c8UL, 0x4c69105eUL, 0xd56041e4UL, - 0xa2677172UL, 0x3c03e4d1UL, 0x4b04d447UL, 0xd20d85fdUL, 0xa50ab56bUL, - 0x35b5a8faUL, 0x42b2986cUL, 0xdbbbc9d6UL, 0xacbcf940UL, 0x32d86ce3UL, - 0x45df5c75UL, 0xdcd60dcfUL, 0xabd13d59UL, 0x26d930acUL, 0x51de003aUL, - 0xc8d75180UL, 0xbfd06116UL, 0x21b4f4b5UL, 0x56b3c423UL, 0xcfba9599UL, - 0xb8bda50fUL, 0x2802b89eUL, 0x5f058808UL, 0xc60cd9b2UL, 0xb10be924UL, - 0x2f6f7c87UL, 0x58684c11UL, 0xc1611dabUL, 0xb6662d3dUL, 0x76dc4190UL, - 0x01db7106UL, 0x98d220bcUL, 0xefd5102aUL, 0x71b18589UL, 0x06b6b51fUL, - 0x9fbfe4a5UL, 0xe8b8d433UL, 0x7807c9a2UL, 0x0f00f934UL, 0x9609a88eUL, - 0xe10e9818UL, 0x7f6a0dbbUL, 0x086d3d2dUL, 0x91646c97UL, 0xe6635c01UL, - 0x6b6b51f4UL, 0x1c6c6162UL, 0x856530d8UL, 0xf262004eUL, 0x6c0695edUL, - 0x1b01a57bUL, 0x8208f4c1UL, 0xf50fc457UL, 0x65b0d9c6UL, 0x12b7e950UL, - 0x8bbeb8eaUL, 0xfcb9887cUL, 0x62dd1ddfUL, 0x15da2d49UL, 0x8cd37cf3UL, - 0xfbd44c65UL, 0x4db26158UL, 0x3ab551ceUL, 0xa3bc0074UL, 0xd4bb30e2UL, - 0x4adfa541UL, 0x3dd895d7UL, 0xa4d1c46dUL, 0xd3d6f4fbUL, 0x4369e96aUL, - 0x346ed9fcUL, 0xad678846UL, 0xda60b8d0UL, 0x44042d73UL, 0x33031de5UL, - 0xaa0a4c5fUL, 0xdd0d7cc9UL, 0x5005713cUL, 0x270241aaUL, 0xbe0b1010UL, - 0xc90c2086UL, 0x5768b525UL, 0x206f85b3UL, 0xb966d409UL, 0xce61e49fUL, - 0x5edef90eUL, 0x29d9c998UL, 0xb0d09822UL, 0xc7d7a8b4UL, 0x59b33d17UL, - 0x2eb40d81UL, 0xb7bd5c3bUL, 0xc0ba6cadUL, 0xedb88320UL, 0x9abfb3b6UL, - 0x03b6e20cUL, 0x74b1d29aUL, 0xead54739UL, 0x9dd277afUL, 0x04db2615UL, - 0x73dc1683UL, 0xe3630b12UL, 0x94643b84UL, 0x0d6d6a3eUL, 0x7a6a5aa8UL, - 0xe40ecf0bUL, 0x9309ff9dUL, 0x0a00ae27UL, 0x7d079eb1UL, 0xf00f9344UL, - 0x8708a3d2UL, 0x1e01f268UL, 0x6906c2feUL, 0xf762575dUL, 0x806567cbUL, - 0x196c3671UL, 0x6e6b06e7UL, 0xfed41b76UL, 0x89d32be0UL, 0x10da7a5aUL, - 0x67dd4accUL, 0xf9b9df6fUL, 0x8ebeeff9UL, 0x17b7be43UL, 0x60b08ed5UL, - 0xd6d6a3e8UL, 0xa1d1937eUL, 0x38d8c2c4UL, 0x4fdff252UL, 0xd1bb67f1UL, - 0xa6bc5767UL, 0x3fb506ddUL, 0x48b2364bUL, 0xd80d2bdaUL, 0xaf0a1b4cUL, - 0x36034af6UL, 0x41047a60UL, 0xdf60efc3UL, 0xa867df55UL, 0x316e8eefUL, - 0x4669be79UL, 0xcb61b38cUL, 0xbc66831aUL, 0x256fd2a0UL, 0x5268e236UL, - 0xcc0c7795UL, 0xbb0b4703UL, 0x220216b9UL, 0x5505262fUL, 0xc5ba3bbeUL, - 0xb2bd0b28UL, 0x2bb45a92UL, 0x5cb36a04UL, 0xc2d7ffa7UL, 0xb5d0cf31UL, - 0x2cd99e8bUL, 0x5bdeae1dUL, 0x9b64c2b0UL, 0xec63f226UL, 0x756aa39cUL, - 0x026d930aUL, 0x9c0906a9UL, 0xeb0e363fUL, 0x72076785UL, 0x05005713UL, - 0x95bf4a82UL, 0xe2b87a14UL, 0x7bb12baeUL, 0x0cb61b38UL, 0x92d28e9bUL, - 0xe5d5be0dUL, 0x7cdcefb7UL, 0x0bdbdf21UL, 0x86d3d2d4UL, 0xf1d4e242UL, - 0x68ddb3f8UL, 0x1fda836eUL, 0x81be16cdUL, 0xf6b9265bUL, 0x6fb077e1UL, - 0x18b74777UL, 0x88085ae6UL, 0xff0f6a70UL, 0x66063bcaUL, 0x11010b5cUL, - 0x8f659effUL, 0xf862ae69UL, 0x616bffd3UL, 0x166ccf45UL, 0xa00ae278UL, - 0xd70dd2eeUL, 0x4e048354UL, 0x3903b3c2UL, 0xa7672661UL, 0xd06016f7UL, - 0x4969474dUL, 0x3e6e77dbUL, 0xaed16a4aUL, 0xd9d65adcUL, 0x40df0b66UL, - 0x37d83bf0UL, 0xa9bcae53UL, 0xdebb9ec5UL, 0x47b2cf7fUL, 0x30b5ffe9UL, - 0xbdbdf21cUL, 0xcabac28aUL, 0x53b39330UL, 0x24b4a3a6UL, 0xbad03605UL, - 0xcdd70693UL, 0x54de5729UL, 0x23d967bfUL, 0xb3667a2eUL, 0xc4614ab8UL, - 0x5d681b02UL, 0x2a6f2b94UL, 0xb40bbe37UL, 0xc30c8ea1UL, 0x5a05df1bUL, - 0x2d02ef8dUL -#ifdef BYFOUR - }, - { - 0x00000000UL, 0x191b3141UL, 0x32366282UL, 0x2b2d53c3UL, 0x646cc504UL, - 0x7d77f445UL, 0x565aa786UL, 0x4f4196c7UL, 0xc8d98a08UL, 0xd1c2bb49UL, - 0xfaefe88aUL, 0xe3f4d9cbUL, 0xacb54f0cUL, 0xb5ae7e4dUL, 0x9e832d8eUL, - 0x87981ccfUL, 0x4ac21251UL, 0x53d92310UL, 0x78f470d3UL, 0x61ef4192UL, - 0x2eaed755UL, 0x37b5e614UL, 0x1c98b5d7UL, 0x05838496UL, 0x821b9859UL, - 0x9b00a918UL, 0xb02dfadbUL, 0xa936cb9aUL, 0xe6775d5dUL, 0xff6c6c1cUL, - 0xd4413fdfUL, 0xcd5a0e9eUL, 0x958424a2UL, 0x8c9f15e3UL, 0xa7b24620UL, - 0xbea97761UL, 0xf1e8e1a6UL, 0xe8f3d0e7UL, 0xc3de8324UL, 0xdac5b265UL, - 0x5d5daeaaUL, 0x44469febUL, 0x6f6bcc28UL, 0x7670fd69UL, 0x39316baeUL, - 0x202a5aefUL, 0x0b07092cUL, 0x121c386dUL, 0xdf4636f3UL, 0xc65d07b2UL, - 0xed705471UL, 0xf46b6530UL, 0xbb2af3f7UL, 0xa231c2b6UL, 0x891c9175UL, - 0x9007a034UL, 0x179fbcfbUL, 0x0e848dbaUL, 0x25a9de79UL, 0x3cb2ef38UL, - 0x73f379ffUL, 0x6ae848beUL, 0x41c51b7dUL, 0x58de2a3cUL, 0xf0794f05UL, - 0xe9627e44UL, 0xc24f2d87UL, 0xdb541cc6UL, 0x94158a01UL, 0x8d0ebb40UL, - 0xa623e883UL, 0xbf38d9c2UL, 0x38a0c50dUL, 0x21bbf44cUL, 0x0a96a78fUL, - 0x138d96ceUL, 0x5ccc0009UL, 0x45d73148UL, 0x6efa628bUL, 0x77e153caUL, - 0xbabb5d54UL, 0xa3a06c15UL, 0x888d3fd6UL, 0x91960e97UL, 0xded79850UL, - 0xc7cca911UL, 0xece1fad2UL, 0xf5facb93UL, 0x7262d75cUL, 0x6b79e61dUL, - 0x4054b5deUL, 0x594f849fUL, 0x160e1258UL, 0x0f152319UL, 0x243870daUL, - 0x3d23419bUL, 0x65fd6ba7UL, 0x7ce65ae6UL, 0x57cb0925UL, 0x4ed03864UL, - 0x0191aea3UL, 0x188a9fe2UL, 0x33a7cc21UL, 0x2abcfd60UL, 0xad24e1afUL, - 0xb43fd0eeUL, 0x9f12832dUL, 0x8609b26cUL, 0xc94824abUL, 0xd05315eaUL, - 0xfb7e4629UL, 0xe2657768UL, 0x2f3f79f6UL, 0x362448b7UL, 0x1d091b74UL, - 0x04122a35UL, 0x4b53bcf2UL, 0x52488db3UL, 0x7965de70UL, 0x607eef31UL, - 0xe7e6f3feUL, 0xfefdc2bfUL, 0xd5d0917cUL, 0xcccba03dUL, 0x838a36faUL, - 0x9a9107bbUL, 0xb1bc5478UL, 0xa8a76539UL, 0x3b83984bUL, 0x2298a90aUL, - 0x09b5fac9UL, 0x10aecb88UL, 0x5fef5d4fUL, 0x46f46c0eUL, 0x6dd93fcdUL, - 0x74c20e8cUL, 0xf35a1243UL, 0xea412302UL, 0xc16c70c1UL, 0xd8774180UL, - 0x9736d747UL, 0x8e2de606UL, 0xa500b5c5UL, 0xbc1b8484UL, 0x71418a1aUL, - 0x685abb5bUL, 0x4377e898UL, 0x5a6cd9d9UL, 0x152d4f1eUL, 0x0c367e5fUL, - 0x271b2d9cUL, 0x3e001cddUL, 0xb9980012UL, 0xa0833153UL, 0x8bae6290UL, - 0x92b553d1UL, 0xddf4c516UL, 0xc4eff457UL, 0xefc2a794UL, 0xf6d996d5UL, - 0xae07bce9UL, 0xb71c8da8UL, 0x9c31de6bUL, 0x852aef2aUL, 0xca6b79edUL, - 0xd37048acUL, 0xf85d1b6fUL, 0xe1462a2eUL, 0x66de36e1UL, 0x7fc507a0UL, - 0x54e85463UL, 0x4df36522UL, 0x02b2f3e5UL, 0x1ba9c2a4UL, 0x30849167UL, - 0x299fa026UL, 0xe4c5aeb8UL, 0xfdde9ff9UL, 0xd6f3cc3aUL, 0xcfe8fd7bUL, - 0x80a96bbcUL, 0x99b25afdUL, 0xb29f093eUL, 0xab84387fUL, 0x2c1c24b0UL, - 0x350715f1UL, 0x1e2a4632UL, 0x07317773UL, 0x4870e1b4UL, 0x516bd0f5UL, - 0x7a468336UL, 0x635db277UL, 0xcbfad74eUL, 0xd2e1e60fUL, 0xf9ccb5ccUL, - 0xe0d7848dUL, 0xaf96124aUL, 0xb68d230bUL, 0x9da070c8UL, 0x84bb4189UL, - 0x03235d46UL, 0x1a386c07UL, 0x31153fc4UL, 0x280e0e85UL, 0x674f9842UL, - 0x7e54a903UL, 0x5579fac0UL, 0x4c62cb81UL, 0x8138c51fUL, 0x9823f45eUL, - 0xb30ea79dUL, 0xaa1596dcUL, 0xe554001bUL, 0xfc4f315aUL, 0xd7626299UL, - 0xce7953d8UL, 0x49e14f17UL, 0x50fa7e56UL, 0x7bd72d95UL, 0x62cc1cd4UL, - 0x2d8d8a13UL, 0x3496bb52UL, 0x1fbbe891UL, 0x06a0d9d0UL, 0x5e7ef3ecUL, - 0x4765c2adUL, 0x6c48916eUL, 0x7553a02fUL, 0x3a1236e8UL, 0x230907a9UL, - 0x0824546aUL, 0x113f652bUL, 0x96a779e4UL, 0x8fbc48a5UL, 0xa4911b66UL, - 0xbd8a2a27UL, 0xf2cbbce0UL, 0xebd08da1UL, 0xc0fdde62UL, 0xd9e6ef23UL, - 0x14bce1bdUL, 0x0da7d0fcUL, 0x268a833fUL, 0x3f91b27eUL, 0x70d024b9UL, - 0x69cb15f8UL, 0x42e6463bUL, 0x5bfd777aUL, 0xdc656bb5UL, 0xc57e5af4UL, - 0xee530937UL, 0xf7483876UL, 0xb809aeb1UL, 0xa1129ff0UL, 0x8a3fcc33UL, - 0x9324fd72UL - }, - { - 0x00000000UL, 0x01c26a37UL, 0x0384d46eUL, 0x0246be59UL, 0x0709a8dcUL, - 0x06cbc2ebUL, 0x048d7cb2UL, 0x054f1685UL, 0x0e1351b8UL, 0x0fd13b8fUL, - 0x0d9785d6UL, 0x0c55efe1UL, 0x091af964UL, 0x08d89353UL, 0x0a9e2d0aUL, - 0x0b5c473dUL, 0x1c26a370UL, 0x1de4c947UL, 0x1fa2771eUL, 0x1e601d29UL, - 0x1b2f0bacUL, 0x1aed619bUL, 0x18abdfc2UL, 0x1969b5f5UL, 0x1235f2c8UL, - 0x13f798ffUL, 0x11b126a6UL, 0x10734c91UL, 0x153c5a14UL, 0x14fe3023UL, - 0x16b88e7aUL, 0x177ae44dUL, 0x384d46e0UL, 0x398f2cd7UL, 0x3bc9928eUL, - 0x3a0bf8b9UL, 0x3f44ee3cUL, 0x3e86840bUL, 0x3cc03a52UL, 0x3d025065UL, - 0x365e1758UL, 0x379c7d6fUL, 0x35dac336UL, 0x3418a901UL, 0x3157bf84UL, - 0x3095d5b3UL, 0x32d36beaUL, 0x331101ddUL, 0x246be590UL, 0x25a98fa7UL, - 0x27ef31feUL, 0x262d5bc9UL, 0x23624d4cUL, 0x22a0277bUL, 0x20e69922UL, - 0x2124f315UL, 0x2a78b428UL, 0x2bbade1fUL, 0x29fc6046UL, 0x283e0a71UL, - 0x2d711cf4UL, 0x2cb376c3UL, 0x2ef5c89aUL, 0x2f37a2adUL, 0x709a8dc0UL, - 0x7158e7f7UL, 0x731e59aeUL, 0x72dc3399UL, 0x7793251cUL, 0x76514f2bUL, - 0x7417f172UL, 0x75d59b45UL, 0x7e89dc78UL, 0x7f4bb64fUL, 0x7d0d0816UL, - 0x7ccf6221UL, 0x798074a4UL, 0x78421e93UL, 0x7a04a0caUL, 0x7bc6cafdUL, - 0x6cbc2eb0UL, 0x6d7e4487UL, 0x6f38fadeUL, 0x6efa90e9UL, 0x6bb5866cUL, - 0x6a77ec5bUL, 0x68315202UL, 0x69f33835UL, 0x62af7f08UL, 0x636d153fUL, - 0x612bab66UL, 0x60e9c151UL, 0x65a6d7d4UL, 0x6464bde3UL, 0x662203baUL, - 0x67e0698dUL, 0x48d7cb20UL, 0x4915a117UL, 0x4b531f4eUL, 0x4a917579UL, - 0x4fde63fcUL, 0x4e1c09cbUL, 0x4c5ab792UL, 0x4d98dda5UL, 0x46c49a98UL, - 0x4706f0afUL, 0x45404ef6UL, 0x448224c1UL, 0x41cd3244UL, 0x400f5873UL, - 0x4249e62aUL, 0x438b8c1dUL, 0x54f16850UL, 0x55330267UL, 0x5775bc3eUL, - 0x56b7d609UL, 0x53f8c08cUL, 0x523aaabbUL, 0x507c14e2UL, 0x51be7ed5UL, - 0x5ae239e8UL, 0x5b2053dfUL, 0x5966ed86UL, 0x58a487b1UL, 0x5deb9134UL, - 0x5c29fb03UL, 0x5e6f455aUL, 0x5fad2f6dUL, 0xe1351b80UL, 0xe0f771b7UL, - 0xe2b1cfeeUL, 0xe373a5d9UL, 0xe63cb35cUL, 0xe7fed96bUL, 0xe5b86732UL, - 0xe47a0d05UL, 0xef264a38UL, 0xeee4200fUL, 0xeca29e56UL, 0xed60f461UL, - 0xe82fe2e4UL, 0xe9ed88d3UL, 0xebab368aUL, 0xea695cbdUL, 0xfd13b8f0UL, - 0xfcd1d2c7UL, 0xfe976c9eUL, 0xff5506a9UL, 0xfa1a102cUL, 0xfbd87a1bUL, - 0xf99ec442UL, 0xf85cae75UL, 0xf300e948UL, 0xf2c2837fUL, 0xf0843d26UL, - 0xf1465711UL, 0xf4094194UL, 0xf5cb2ba3UL, 0xf78d95faUL, 0xf64fffcdUL, - 0xd9785d60UL, 0xd8ba3757UL, 0xdafc890eUL, 0xdb3ee339UL, 0xde71f5bcUL, - 0xdfb39f8bUL, 0xddf521d2UL, 0xdc374be5UL, 0xd76b0cd8UL, 0xd6a966efUL, - 0xd4efd8b6UL, 0xd52db281UL, 0xd062a404UL, 0xd1a0ce33UL, 0xd3e6706aUL, - 0xd2241a5dUL, 0xc55efe10UL, 0xc49c9427UL, 0xc6da2a7eUL, 0xc7184049UL, - 0xc25756ccUL, 0xc3953cfbUL, 0xc1d382a2UL, 0xc011e895UL, 0xcb4dafa8UL, - 0xca8fc59fUL, 0xc8c97bc6UL, 0xc90b11f1UL, 0xcc440774UL, 0xcd866d43UL, - 0xcfc0d31aUL, 0xce02b92dUL, 0x91af9640UL, 0x906dfc77UL, 0x922b422eUL, - 0x93e92819UL, 0x96a63e9cUL, 0x976454abUL, 0x9522eaf2UL, 0x94e080c5UL, - 0x9fbcc7f8UL, 0x9e7eadcfUL, 0x9c381396UL, 0x9dfa79a1UL, 0x98b56f24UL, - 0x99770513UL, 0x9b31bb4aUL, 0x9af3d17dUL, 0x8d893530UL, 0x8c4b5f07UL, - 0x8e0de15eUL, 0x8fcf8b69UL, 0x8a809decUL, 0x8b42f7dbUL, 0x89044982UL, - 0x88c623b5UL, 0x839a6488UL, 0x82580ebfUL, 0x801eb0e6UL, 0x81dcdad1UL, - 0x8493cc54UL, 0x8551a663UL, 0x8717183aUL, 0x86d5720dUL, 0xa9e2d0a0UL, - 0xa820ba97UL, 0xaa6604ceUL, 0xaba46ef9UL, 0xaeeb787cUL, 0xaf29124bUL, - 0xad6fac12UL, 0xacadc625UL, 0xa7f18118UL, 0xa633eb2fUL, 0xa4755576UL, - 0xa5b73f41UL, 0xa0f829c4UL, 0xa13a43f3UL, 0xa37cfdaaUL, 0xa2be979dUL, - 0xb5c473d0UL, 0xb40619e7UL, 0xb640a7beUL, 0xb782cd89UL, 0xb2cddb0cUL, - 0xb30fb13bUL, 0xb1490f62UL, 0xb08b6555UL, 0xbbd72268UL, 0xba15485fUL, - 0xb853f606UL, 0xb9919c31UL, 0xbcde8ab4UL, 0xbd1ce083UL, 0xbf5a5edaUL, - 0xbe9834edUL - }, - { - 0x00000000UL, 0xb8bc6765UL, 0xaa09c88bUL, 0x12b5afeeUL, 0x8f629757UL, - 0x37def032UL, 0x256b5fdcUL, 0x9dd738b9UL, 0xc5b428efUL, 0x7d084f8aUL, - 0x6fbde064UL, 0xd7018701UL, 0x4ad6bfb8UL, 0xf26ad8ddUL, 0xe0df7733UL, - 0x58631056UL, 0x5019579fUL, 0xe8a530faUL, 0xfa109f14UL, 0x42acf871UL, - 0xdf7bc0c8UL, 0x67c7a7adUL, 0x75720843UL, 0xcdce6f26UL, 0x95ad7f70UL, - 0x2d111815UL, 0x3fa4b7fbUL, 0x8718d09eUL, 0x1acfe827UL, 0xa2738f42UL, - 0xb0c620acUL, 0x087a47c9UL, 0xa032af3eUL, 0x188ec85bUL, 0x0a3b67b5UL, - 0xb28700d0UL, 0x2f503869UL, 0x97ec5f0cUL, 0x8559f0e2UL, 0x3de59787UL, - 0x658687d1UL, 0xdd3ae0b4UL, 0xcf8f4f5aUL, 0x7733283fUL, 0xeae41086UL, - 0x525877e3UL, 0x40edd80dUL, 0xf851bf68UL, 0xf02bf8a1UL, 0x48979fc4UL, - 0x5a22302aUL, 0xe29e574fUL, 0x7f496ff6UL, 0xc7f50893UL, 0xd540a77dUL, - 0x6dfcc018UL, 0x359fd04eUL, 0x8d23b72bUL, 0x9f9618c5UL, 0x272a7fa0UL, - 0xbafd4719UL, 0x0241207cUL, 0x10f48f92UL, 0xa848e8f7UL, 0x9b14583dUL, - 0x23a83f58UL, 0x311d90b6UL, 0x89a1f7d3UL, 0x1476cf6aUL, 0xaccaa80fUL, - 0xbe7f07e1UL, 0x06c36084UL, 0x5ea070d2UL, 0xe61c17b7UL, 0xf4a9b859UL, - 0x4c15df3cUL, 0xd1c2e785UL, 0x697e80e0UL, 0x7bcb2f0eUL, 0xc377486bUL, - 0xcb0d0fa2UL, 0x73b168c7UL, 0x6104c729UL, 0xd9b8a04cUL, 0x446f98f5UL, - 0xfcd3ff90UL, 0xee66507eUL, 0x56da371bUL, 0x0eb9274dUL, 0xb6054028UL, - 0xa4b0efc6UL, 0x1c0c88a3UL, 0x81dbb01aUL, 0x3967d77fUL, 0x2bd27891UL, - 0x936e1ff4UL, 0x3b26f703UL, 0x839a9066UL, 0x912f3f88UL, 0x299358edUL, - 0xb4446054UL, 0x0cf80731UL, 0x1e4da8dfUL, 0xa6f1cfbaUL, 0xfe92dfecUL, - 0x462eb889UL, 0x549b1767UL, 0xec277002UL, 0x71f048bbUL, 0xc94c2fdeUL, - 0xdbf98030UL, 0x6345e755UL, 0x6b3fa09cUL, 0xd383c7f9UL, 0xc1366817UL, - 0x798a0f72UL, 0xe45d37cbUL, 0x5ce150aeUL, 0x4e54ff40UL, 0xf6e89825UL, - 0xae8b8873UL, 0x1637ef16UL, 0x048240f8UL, 0xbc3e279dUL, 0x21e91f24UL, - 0x99557841UL, 0x8be0d7afUL, 0x335cb0caUL, 0xed59b63bUL, 0x55e5d15eUL, - 0x47507eb0UL, 0xffec19d5UL, 0x623b216cUL, 0xda874609UL, 0xc832e9e7UL, - 0x708e8e82UL, 0x28ed9ed4UL, 0x9051f9b1UL, 0x82e4565fUL, 0x3a58313aUL, - 0xa78f0983UL, 0x1f336ee6UL, 0x0d86c108UL, 0xb53aa66dUL, 0xbd40e1a4UL, - 0x05fc86c1UL, 0x1749292fUL, 0xaff54e4aUL, 0x322276f3UL, 0x8a9e1196UL, - 0x982bbe78UL, 0x2097d91dUL, 0x78f4c94bUL, 0xc048ae2eUL, 0xd2fd01c0UL, - 0x6a4166a5UL, 0xf7965e1cUL, 0x4f2a3979UL, 0x5d9f9697UL, 0xe523f1f2UL, - 0x4d6b1905UL, 0xf5d77e60UL, 0xe762d18eUL, 0x5fdeb6ebUL, 0xc2098e52UL, - 0x7ab5e937UL, 0x680046d9UL, 0xd0bc21bcUL, 0x88df31eaUL, 0x3063568fUL, - 0x22d6f961UL, 0x9a6a9e04UL, 0x07bda6bdUL, 0xbf01c1d8UL, 0xadb46e36UL, - 0x15080953UL, 0x1d724e9aUL, 0xa5ce29ffUL, 0xb77b8611UL, 0x0fc7e174UL, - 0x9210d9cdUL, 0x2aacbea8UL, 0x38191146UL, 0x80a57623UL, 0xd8c66675UL, - 0x607a0110UL, 0x72cfaefeUL, 0xca73c99bUL, 0x57a4f122UL, 0xef189647UL, - 0xfdad39a9UL, 0x45115eccUL, 0x764dee06UL, 0xcef18963UL, 0xdc44268dUL, - 0x64f841e8UL, 0xf92f7951UL, 0x41931e34UL, 0x5326b1daUL, 0xeb9ad6bfUL, - 0xb3f9c6e9UL, 0x0b45a18cUL, 0x19f00e62UL, 0xa14c6907UL, 0x3c9b51beUL, - 0x842736dbUL, 0x96929935UL, 0x2e2efe50UL, 0x2654b999UL, 0x9ee8defcUL, - 0x8c5d7112UL, 0x34e11677UL, 0xa9362eceUL, 0x118a49abUL, 0x033fe645UL, - 0xbb838120UL, 0xe3e09176UL, 0x5b5cf613UL, 0x49e959fdUL, 0xf1553e98UL, - 0x6c820621UL, 0xd43e6144UL, 0xc68bceaaUL, 0x7e37a9cfUL, 0xd67f4138UL, - 0x6ec3265dUL, 0x7c7689b3UL, 0xc4caeed6UL, 0x591dd66fUL, 0xe1a1b10aUL, - 0xf3141ee4UL, 0x4ba87981UL, 0x13cb69d7UL, 0xab770eb2UL, 0xb9c2a15cUL, - 0x017ec639UL, 0x9ca9fe80UL, 0x241599e5UL, 0x36a0360bUL, 0x8e1c516eUL, - 0x866616a7UL, 0x3eda71c2UL, 0x2c6fde2cUL, 0x94d3b949UL, 0x090481f0UL, - 0xb1b8e695UL, 0xa30d497bUL, 0x1bb12e1eUL, 0x43d23e48UL, 0xfb6e592dUL, - 0xe9dbf6c3UL, 0x516791a6UL, 0xccb0a91fUL, 0x740cce7aUL, 0x66b96194UL, - 0xde0506f1UL - }, - { - 0x00000000UL, 0x96300777UL, 0x2c610eeeUL, 0xba510999UL, 0x19c46d07UL, - 0x8ff46a70UL, 0x35a563e9UL, 0xa395649eUL, 0x3288db0eUL, 0xa4b8dc79UL, - 0x1ee9d5e0UL, 0x88d9d297UL, 0x2b4cb609UL, 0xbd7cb17eUL, 0x072db8e7UL, - 0x911dbf90UL, 0x6410b71dUL, 0xf220b06aUL, 0x4871b9f3UL, 0xde41be84UL, - 0x7dd4da1aUL, 0xebe4dd6dUL, 0x51b5d4f4UL, 0xc785d383UL, 0x56986c13UL, - 0xc0a86b64UL, 0x7af962fdUL, 0xecc9658aUL, 0x4f5c0114UL, 0xd96c0663UL, - 0x633d0ffaUL, 0xf50d088dUL, 0xc8206e3bUL, 0x5e10694cUL, 0xe44160d5UL, - 0x727167a2UL, 0xd1e4033cUL, 0x47d4044bUL, 0xfd850dd2UL, 0x6bb50aa5UL, - 0xfaa8b535UL, 0x6c98b242UL, 0xd6c9bbdbUL, 0x40f9bcacUL, 0xe36cd832UL, - 0x755cdf45UL, 0xcf0dd6dcUL, 0x593dd1abUL, 0xac30d926UL, 0x3a00de51UL, - 0x8051d7c8UL, 0x1661d0bfUL, 0xb5f4b421UL, 0x23c4b356UL, 0x9995bacfUL, - 0x0fa5bdb8UL, 0x9eb80228UL, 0x0888055fUL, 0xb2d90cc6UL, 0x24e90bb1UL, - 0x877c6f2fUL, 0x114c6858UL, 0xab1d61c1UL, 0x3d2d66b6UL, 0x9041dc76UL, - 0x0671db01UL, 0xbc20d298UL, 0x2a10d5efUL, 0x8985b171UL, 0x1fb5b606UL, - 0xa5e4bf9fUL, 0x33d4b8e8UL, 0xa2c90778UL, 0x34f9000fUL, 0x8ea80996UL, - 0x18980ee1UL, 0xbb0d6a7fUL, 0x2d3d6d08UL, 0x976c6491UL, 0x015c63e6UL, - 0xf4516b6bUL, 0x62616c1cUL, 0xd8306585UL, 0x4e0062f2UL, 0xed95066cUL, - 0x7ba5011bUL, 0xc1f40882UL, 0x57c40ff5UL, 0xc6d9b065UL, 0x50e9b712UL, - 0xeab8be8bUL, 0x7c88b9fcUL, 0xdf1ddd62UL, 0x492dda15UL, 0xf37cd38cUL, - 0x654cd4fbUL, 0x5861b24dUL, 0xce51b53aUL, 0x7400bca3UL, 0xe230bbd4UL, - 0x41a5df4aUL, 0xd795d83dUL, 0x6dc4d1a4UL, 0xfbf4d6d3UL, 0x6ae96943UL, - 0xfcd96e34UL, 0x468867adUL, 0xd0b860daUL, 0x732d0444UL, 0xe51d0333UL, - 0x5f4c0aaaUL, 0xc97c0dddUL, 0x3c710550UL, 0xaa410227UL, 0x10100bbeUL, - 0x86200cc9UL, 0x25b56857UL, 0xb3856f20UL, 0x09d466b9UL, 0x9fe461ceUL, - 0x0ef9de5eUL, 0x98c9d929UL, 0x2298d0b0UL, 0xb4a8d7c7UL, 0x173db359UL, - 0x810db42eUL, 0x3b5cbdb7UL, 0xad6cbac0UL, 0x2083b8edUL, 0xb6b3bf9aUL, - 0x0ce2b603UL, 0x9ad2b174UL, 0x3947d5eaUL, 0xaf77d29dUL, 0x1526db04UL, - 0x8316dc73UL, 0x120b63e3UL, 0x843b6494UL, 0x3e6a6d0dUL, 0xa85a6a7aUL, - 0x0bcf0ee4UL, 0x9dff0993UL, 0x27ae000aUL, 0xb19e077dUL, 0x44930ff0UL, - 0xd2a30887UL, 0x68f2011eUL, 0xfec20669UL, 0x5d5762f7UL, 0xcb676580UL, - 0x71366c19UL, 0xe7066b6eUL, 0x761bd4feUL, 0xe02bd389UL, 0x5a7ada10UL, - 0xcc4add67UL, 0x6fdfb9f9UL, 0xf9efbe8eUL, 0x43beb717UL, 0xd58eb060UL, - 0xe8a3d6d6UL, 0x7e93d1a1UL, 0xc4c2d838UL, 0x52f2df4fUL, 0xf167bbd1UL, - 0x6757bca6UL, 0xdd06b53fUL, 0x4b36b248UL, 0xda2b0dd8UL, 0x4c1b0aafUL, - 0xf64a0336UL, 0x607a0441UL, 0xc3ef60dfUL, 0x55df67a8UL, 0xef8e6e31UL, - 0x79be6946UL, 0x8cb361cbUL, 0x1a8366bcUL, 0xa0d26f25UL, 0x36e26852UL, - 0x95770cccUL, 0x03470bbbUL, 0xb9160222UL, 0x2f260555UL, 0xbe3bbac5UL, - 0x280bbdb2UL, 0x925ab42bUL, 0x046ab35cUL, 0xa7ffd7c2UL, 0x31cfd0b5UL, - 0x8b9ed92cUL, 0x1daede5bUL, 0xb0c2649bUL, 0x26f263ecUL, 0x9ca36a75UL, - 0x0a936d02UL, 0xa906099cUL, 0x3f360eebUL, 0x85670772UL, 0x13570005UL, - 0x824abf95UL, 0x147ab8e2UL, 0xae2bb17bUL, 0x381bb60cUL, 0x9b8ed292UL, - 0x0dbed5e5UL, 0xb7efdc7cUL, 0x21dfdb0bUL, 0xd4d2d386UL, 0x42e2d4f1UL, - 0xf8b3dd68UL, 0x6e83da1fUL, 0xcd16be81UL, 0x5b26b9f6UL, 0xe177b06fUL, - 0x7747b718UL, 0xe65a0888UL, 0x706a0fffUL, 0xca3b0666UL, 0x5c0b0111UL, - 0xff9e658fUL, 0x69ae62f8UL, 0xd3ff6b61UL, 0x45cf6c16UL, 0x78e20aa0UL, - 0xeed20dd7UL, 0x5483044eUL, 0xc2b30339UL, 0x612667a7UL, 0xf71660d0UL, - 0x4d476949UL, 0xdb776e3eUL, 0x4a6ad1aeUL, 0xdc5ad6d9UL, 0x660bdf40UL, - 0xf03bd837UL, 0x53aebca9UL, 0xc59ebbdeUL, 0x7fcfb247UL, 0xe9ffb530UL, - 0x1cf2bdbdUL, 0x8ac2bacaUL, 0x3093b353UL, 0xa6a3b424UL, 0x0536d0baUL, - 0x9306d7cdUL, 0x2957de54UL, 0xbf67d923UL, 0x2e7a66b3UL, 0xb84a61c4UL, - 0x021b685dUL, 0x942b6f2aUL, 0x37be0bb4UL, 0xa18e0cc3UL, 0x1bdf055aUL, - 0x8def022dUL - }, - { - 0x00000000UL, 0x41311b19UL, 0x82623632UL, 0xc3532d2bUL, 0x04c56c64UL, - 0x45f4777dUL, 0x86a75a56UL, 0xc796414fUL, 0x088ad9c8UL, 0x49bbc2d1UL, - 0x8ae8effaUL, 0xcbd9f4e3UL, 0x0c4fb5acUL, 0x4d7eaeb5UL, 0x8e2d839eUL, - 0xcf1c9887UL, 0x5112c24aUL, 0x1023d953UL, 0xd370f478UL, 0x9241ef61UL, - 0x55d7ae2eUL, 0x14e6b537UL, 0xd7b5981cUL, 0x96848305UL, 0x59981b82UL, - 0x18a9009bUL, 0xdbfa2db0UL, 0x9acb36a9UL, 0x5d5d77e6UL, 0x1c6c6cffUL, - 0xdf3f41d4UL, 0x9e0e5acdUL, 0xa2248495UL, 0xe3159f8cUL, 0x2046b2a7UL, - 0x6177a9beUL, 0xa6e1e8f1UL, 0xe7d0f3e8UL, 0x2483dec3UL, 0x65b2c5daUL, - 0xaaae5d5dUL, 0xeb9f4644UL, 0x28cc6b6fUL, 0x69fd7076UL, 0xae6b3139UL, - 0xef5a2a20UL, 0x2c09070bUL, 0x6d381c12UL, 0xf33646dfUL, 0xb2075dc6UL, - 0x715470edUL, 0x30656bf4UL, 0xf7f32abbUL, 0xb6c231a2UL, 0x75911c89UL, - 0x34a00790UL, 0xfbbc9f17UL, 0xba8d840eUL, 0x79dea925UL, 0x38efb23cUL, - 0xff79f373UL, 0xbe48e86aUL, 0x7d1bc541UL, 0x3c2ade58UL, 0x054f79f0UL, - 0x447e62e9UL, 0x872d4fc2UL, 0xc61c54dbUL, 0x018a1594UL, 0x40bb0e8dUL, - 0x83e823a6UL, 0xc2d938bfUL, 0x0dc5a038UL, 0x4cf4bb21UL, 0x8fa7960aUL, - 0xce968d13UL, 0x0900cc5cUL, 0x4831d745UL, 0x8b62fa6eUL, 0xca53e177UL, - 0x545dbbbaUL, 0x156ca0a3UL, 0xd63f8d88UL, 0x970e9691UL, 0x5098d7deUL, - 0x11a9ccc7UL, 0xd2fae1ecUL, 0x93cbfaf5UL, 0x5cd76272UL, 0x1de6796bUL, - 0xdeb55440UL, 0x9f844f59UL, 0x58120e16UL, 0x1923150fUL, 0xda703824UL, - 0x9b41233dUL, 0xa76bfd65UL, 0xe65ae67cUL, 0x2509cb57UL, 0x6438d04eUL, - 0xa3ae9101UL, 0xe29f8a18UL, 0x21cca733UL, 0x60fdbc2aUL, 0xafe124adUL, - 0xeed03fb4UL, 0x2d83129fUL, 0x6cb20986UL, 0xab2448c9UL, 0xea1553d0UL, - 0x29467efbUL, 0x687765e2UL, 0xf6793f2fUL, 0xb7482436UL, 0x741b091dUL, - 0x352a1204UL, 0xf2bc534bUL, 0xb38d4852UL, 0x70de6579UL, 0x31ef7e60UL, - 0xfef3e6e7UL, 0xbfc2fdfeUL, 0x7c91d0d5UL, 0x3da0cbccUL, 0xfa368a83UL, - 0xbb07919aUL, 0x7854bcb1UL, 0x3965a7a8UL, 0x4b98833bUL, 0x0aa99822UL, - 0xc9fab509UL, 0x88cbae10UL, 0x4f5def5fUL, 0x0e6cf446UL, 0xcd3fd96dUL, - 0x8c0ec274UL, 0x43125af3UL, 0x022341eaUL, 0xc1706cc1UL, 0x804177d8UL, - 0x47d73697UL, 0x06e62d8eUL, 0xc5b500a5UL, 0x84841bbcUL, 0x1a8a4171UL, - 0x5bbb5a68UL, 0x98e87743UL, 0xd9d96c5aUL, 0x1e4f2d15UL, 0x5f7e360cUL, - 0x9c2d1b27UL, 0xdd1c003eUL, 0x120098b9UL, 0x533183a0UL, 0x9062ae8bUL, - 0xd153b592UL, 0x16c5f4ddUL, 0x57f4efc4UL, 0x94a7c2efUL, 0xd596d9f6UL, - 0xe9bc07aeUL, 0xa88d1cb7UL, 0x6bde319cUL, 0x2aef2a85UL, 0xed796bcaUL, - 0xac4870d3UL, 0x6f1b5df8UL, 0x2e2a46e1UL, 0xe136de66UL, 0xa007c57fUL, - 0x6354e854UL, 0x2265f34dUL, 0xe5f3b202UL, 0xa4c2a91bUL, 0x67918430UL, - 0x26a09f29UL, 0xb8aec5e4UL, 0xf99fdefdUL, 0x3accf3d6UL, 0x7bfde8cfUL, - 0xbc6ba980UL, 0xfd5ab299UL, 0x3e099fb2UL, 0x7f3884abUL, 0xb0241c2cUL, - 0xf1150735UL, 0x32462a1eUL, 0x73773107UL, 0xb4e17048UL, 0xf5d06b51UL, - 0x3683467aUL, 0x77b25d63UL, 0x4ed7facbUL, 0x0fe6e1d2UL, 0xccb5ccf9UL, - 0x8d84d7e0UL, 0x4a1296afUL, 0x0b238db6UL, 0xc870a09dUL, 0x8941bb84UL, - 0x465d2303UL, 0x076c381aUL, 0xc43f1531UL, 0x850e0e28UL, 0x42984f67UL, - 0x03a9547eUL, 0xc0fa7955UL, 0x81cb624cUL, 0x1fc53881UL, 0x5ef42398UL, - 0x9da70eb3UL, 0xdc9615aaUL, 0x1b0054e5UL, 0x5a314ffcUL, 0x996262d7UL, - 0xd85379ceUL, 0x174fe149UL, 0x567efa50UL, 0x952dd77bUL, 0xd41ccc62UL, - 0x138a8d2dUL, 0x52bb9634UL, 0x91e8bb1fUL, 0xd0d9a006UL, 0xecf37e5eUL, - 0xadc26547UL, 0x6e91486cUL, 0x2fa05375UL, 0xe836123aUL, 0xa9070923UL, - 0x6a542408UL, 0x2b653f11UL, 0xe479a796UL, 0xa548bc8fUL, 0x661b91a4UL, - 0x272a8abdUL, 0xe0bccbf2UL, 0xa18dd0ebUL, 0x62defdc0UL, 0x23efe6d9UL, - 0xbde1bc14UL, 0xfcd0a70dUL, 0x3f838a26UL, 0x7eb2913fUL, 0xb924d070UL, - 0xf815cb69UL, 0x3b46e642UL, 0x7a77fd5bUL, 0xb56b65dcUL, 0xf45a7ec5UL, - 0x370953eeUL, 0x763848f7UL, 0xb1ae09b8UL, 0xf09f12a1UL, 0x33cc3f8aUL, - 0x72fd2493UL - }, - { - 0x00000000UL, 0x376ac201UL, 0x6ed48403UL, 0x59be4602UL, 0xdca80907UL, - 0xebc2cb06UL, 0xb27c8d04UL, 0x85164f05UL, 0xb851130eUL, 0x8f3bd10fUL, - 0xd685970dUL, 0xe1ef550cUL, 0x64f91a09UL, 0x5393d808UL, 0x0a2d9e0aUL, - 0x3d475c0bUL, 0x70a3261cUL, 0x47c9e41dUL, 0x1e77a21fUL, 0x291d601eUL, - 0xac0b2f1bUL, 0x9b61ed1aUL, 0xc2dfab18UL, 0xf5b56919UL, 0xc8f23512UL, - 0xff98f713UL, 0xa626b111UL, 0x914c7310UL, 0x145a3c15UL, 0x2330fe14UL, - 0x7a8eb816UL, 0x4de47a17UL, 0xe0464d38UL, 0xd72c8f39UL, 0x8e92c93bUL, - 0xb9f80b3aUL, 0x3cee443fUL, 0x0b84863eUL, 0x523ac03cUL, 0x6550023dUL, - 0x58175e36UL, 0x6f7d9c37UL, 0x36c3da35UL, 0x01a91834UL, 0x84bf5731UL, - 0xb3d59530UL, 0xea6bd332UL, 0xdd011133UL, 0x90e56b24UL, 0xa78fa925UL, - 0xfe31ef27UL, 0xc95b2d26UL, 0x4c4d6223UL, 0x7b27a022UL, 0x2299e620UL, - 0x15f32421UL, 0x28b4782aUL, 0x1fdeba2bUL, 0x4660fc29UL, 0x710a3e28UL, - 0xf41c712dUL, 0xc376b32cUL, 0x9ac8f52eUL, 0xada2372fUL, 0xc08d9a70UL, - 0xf7e75871UL, 0xae591e73UL, 0x9933dc72UL, 0x1c259377UL, 0x2b4f5176UL, - 0x72f11774UL, 0x459bd575UL, 0x78dc897eUL, 0x4fb64b7fUL, 0x16080d7dUL, - 0x2162cf7cUL, 0xa4748079UL, 0x931e4278UL, 0xcaa0047aUL, 0xfdcac67bUL, - 0xb02ebc6cUL, 0x87447e6dUL, 0xdefa386fUL, 0xe990fa6eUL, 0x6c86b56bUL, - 0x5bec776aUL, 0x02523168UL, 0x3538f369UL, 0x087faf62UL, 0x3f156d63UL, - 0x66ab2b61UL, 0x51c1e960UL, 0xd4d7a665UL, 0xe3bd6464UL, 0xba032266UL, - 0x8d69e067UL, 0x20cbd748UL, 0x17a11549UL, 0x4e1f534bUL, 0x7975914aUL, - 0xfc63de4fUL, 0xcb091c4eUL, 0x92b75a4cUL, 0xa5dd984dUL, 0x989ac446UL, - 0xaff00647UL, 0xf64e4045UL, 0xc1248244UL, 0x4432cd41UL, 0x73580f40UL, - 0x2ae64942UL, 0x1d8c8b43UL, 0x5068f154UL, 0x67023355UL, 0x3ebc7557UL, - 0x09d6b756UL, 0x8cc0f853UL, 0xbbaa3a52UL, 0xe2147c50UL, 0xd57ebe51UL, - 0xe839e25aUL, 0xdf53205bUL, 0x86ed6659UL, 0xb187a458UL, 0x3491eb5dUL, - 0x03fb295cUL, 0x5a456f5eUL, 0x6d2fad5fUL, 0x801b35e1UL, 0xb771f7e0UL, - 0xeecfb1e2UL, 0xd9a573e3UL, 0x5cb33ce6UL, 0x6bd9fee7UL, 0x3267b8e5UL, - 0x050d7ae4UL, 0x384a26efUL, 0x0f20e4eeUL, 0x569ea2ecUL, 0x61f460edUL, - 0xe4e22fe8UL, 0xd388ede9UL, 0x8a36abebUL, 0xbd5c69eaUL, 0xf0b813fdUL, - 0xc7d2d1fcUL, 0x9e6c97feUL, 0xa90655ffUL, 0x2c101afaUL, 0x1b7ad8fbUL, - 0x42c49ef9UL, 0x75ae5cf8UL, 0x48e900f3UL, 0x7f83c2f2UL, 0x263d84f0UL, - 0x115746f1UL, 0x944109f4UL, 0xa32bcbf5UL, 0xfa958df7UL, 0xcdff4ff6UL, - 0x605d78d9UL, 0x5737bad8UL, 0x0e89fcdaUL, 0x39e33edbUL, 0xbcf571deUL, - 0x8b9fb3dfUL, 0xd221f5ddUL, 0xe54b37dcUL, 0xd80c6bd7UL, 0xef66a9d6UL, - 0xb6d8efd4UL, 0x81b22dd5UL, 0x04a462d0UL, 0x33cea0d1UL, 0x6a70e6d3UL, - 0x5d1a24d2UL, 0x10fe5ec5UL, 0x27949cc4UL, 0x7e2adac6UL, 0x494018c7UL, - 0xcc5657c2UL, 0xfb3c95c3UL, 0xa282d3c1UL, 0x95e811c0UL, 0xa8af4dcbUL, - 0x9fc58fcaUL, 0xc67bc9c8UL, 0xf1110bc9UL, 0x740744ccUL, 0x436d86cdUL, - 0x1ad3c0cfUL, 0x2db902ceUL, 0x4096af91UL, 0x77fc6d90UL, 0x2e422b92UL, - 0x1928e993UL, 0x9c3ea696UL, 0xab546497UL, 0xf2ea2295UL, 0xc580e094UL, - 0xf8c7bc9fUL, 0xcfad7e9eUL, 0x9613389cUL, 0xa179fa9dUL, 0x246fb598UL, - 0x13057799UL, 0x4abb319bUL, 0x7dd1f39aUL, 0x3035898dUL, 0x075f4b8cUL, - 0x5ee10d8eUL, 0x698bcf8fUL, 0xec9d808aUL, 0xdbf7428bUL, 0x82490489UL, - 0xb523c688UL, 0x88649a83UL, 0xbf0e5882UL, 0xe6b01e80UL, 0xd1dadc81UL, - 0x54cc9384UL, 0x63a65185UL, 0x3a181787UL, 0x0d72d586UL, 0xa0d0e2a9UL, - 0x97ba20a8UL, 0xce0466aaUL, 0xf96ea4abUL, 0x7c78ebaeUL, 0x4b1229afUL, - 0x12ac6fadUL, 0x25c6adacUL, 0x1881f1a7UL, 0x2feb33a6UL, 0x765575a4UL, - 0x413fb7a5UL, 0xc429f8a0UL, 0xf3433aa1UL, 0xaafd7ca3UL, 0x9d97bea2UL, - 0xd073c4b5UL, 0xe71906b4UL, 0xbea740b6UL, 0x89cd82b7UL, 0x0cdbcdb2UL, - 0x3bb10fb3UL, 0x620f49b1UL, 0x55658bb0UL, 0x6822d7bbUL, 0x5f4815baUL, - 0x06f653b8UL, 0x319c91b9UL, 0xb48adebcUL, 0x83e01cbdUL, 0xda5e5abfUL, - 0xed3498beUL - }, - { - 0x00000000UL, 0x6567bcb8UL, 0x8bc809aaUL, 0xeeafb512UL, 0x5797628fUL, - 0x32f0de37UL, 0xdc5f6b25UL, 0xb938d79dUL, 0xef28b4c5UL, 0x8a4f087dUL, - 0x64e0bd6fUL, 0x018701d7UL, 0xb8bfd64aUL, 0xddd86af2UL, 0x3377dfe0UL, - 0x56106358UL, 0x9f571950UL, 0xfa30a5e8UL, 0x149f10faUL, 0x71f8ac42UL, - 0xc8c07bdfUL, 0xada7c767UL, 0x43087275UL, 0x266fcecdUL, 0x707fad95UL, - 0x1518112dUL, 0xfbb7a43fUL, 0x9ed01887UL, 0x27e8cf1aUL, 0x428f73a2UL, - 0xac20c6b0UL, 0xc9477a08UL, 0x3eaf32a0UL, 0x5bc88e18UL, 0xb5673b0aUL, - 0xd00087b2UL, 0x6938502fUL, 0x0c5fec97UL, 0xe2f05985UL, 0x8797e53dUL, - 0xd1878665UL, 0xb4e03addUL, 0x5a4f8fcfUL, 0x3f283377UL, 0x8610e4eaUL, - 0xe3775852UL, 0x0dd8ed40UL, 0x68bf51f8UL, 0xa1f82bf0UL, 0xc49f9748UL, - 0x2a30225aUL, 0x4f579ee2UL, 0xf66f497fUL, 0x9308f5c7UL, 0x7da740d5UL, - 0x18c0fc6dUL, 0x4ed09f35UL, 0x2bb7238dUL, 0xc518969fUL, 0xa07f2a27UL, - 0x1947fdbaUL, 0x7c204102UL, 0x928ff410UL, 0xf7e848a8UL, 0x3d58149bUL, - 0x583fa823UL, 0xb6901d31UL, 0xd3f7a189UL, 0x6acf7614UL, 0x0fa8caacUL, - 0xe1077fbeUL, 0x8460c306UL, 0xd270a05eUL, 0xb7171ce6UL, 0x59b8a9f4UL, - 0x3cdf154cUL, 0x85e7c2d1UL, 0xe0807e69UL, 0x0e2fcb7bUL, 0x6b4877c3UL, - 0xa20f0dcbUL, 0xc768b173UL, 0x29c70461UL, 0x4ca0b8d9UL, 0xf5986f44UL, - 0x90ffd3fcUL, 0x7e5066eeUL, 0x1b37da56UL, 0x4d27b90eUL, 0x284005b6UL, - 0xc6efb0a4UL, 0xa3880c1cUL, 0x1ab0db81UL, 0x7fd76739UL, 0x9178d22bUL, - 0xf41f6e93UL, 0x03f7263bUL, 0x66909a83UL, 0x883f2f91UL, 0xed589329UL, - 0x546044b4UL, 0x3107f80cUL, 0xdfa84d1eUL, 0xbacff1a6UL, 0xecdf92feUL, - 0x89b82e46UL, 0x67179b54UL, 0x027027ecUL, 0xbb48f071UL, 0xde2f4cc9UL, - 0x3080f9dbUL, 0x55e74563UL, 0x9ca03f6bUL, 0xf9c783d3UL, 0x176836c1UL, - 0x720f8a79UL, 0xcb375de4UL, 0xae50e15cUL, 0x40ff544eUL, 0x2598e8f6UL, - 0x73888baeUL, 0x16ef3716UL, 0xf8408204UL, 0x9d273ebcUL, 0x241fe921UL, - 0x41785599UL, 0xafd7e08bUL, 0xcab05c33UL, 0x3bb659edUL, 0x5ed1e555UL, - 0xb07e5047UL, 0xd519ecffUL, 0x6c213b62UL, 0x094687daUL, 0xe7e932c8UL, - 0x828e8e70UL, 0xd49eed28UL, 0xb1f95190UL, 0x5f56e482UL, 0x3a31583aUL, - 0x83098fa7UL, 0xe66e331fUL, 0x08c1860dUL, 0x6da63ab5UL, 0xa4e140bdUL, - 0xc186fc05UL, 0x2f294917UL, 0x4a4ef5afUL, 0xf3762232UL, 0x96119e8aUL, - 0x78be2b98UL, 0x1dd99720UL, 0x4bc9f478UL, 0x2eae48c0UL, 0xc001fdd2UL, - 0xa566416aUL, 0x1c5e96f7UL, 0x79392a4fUL, 0x97969f5dUL, 0xf2f123e5UL, - 0x05196b4dUL, 0x607ed7f5UL, 0x8ed162e7UL, 0xebb6de5fUL, 0x528e09c2UL, - 0x37e9b57aUL, 0xd9460068UL, 0xbc21bcd0UL, 0xea31df88UL, 0x8f566330UL, - 0x61f9d622UL, 0x049e6a9aUL, 0xbda6bd07UL, 0xd8c101bfUL, 0x366eb4adUL, - 0x53090815UL, 0x9a4e721dUL, 0xff29cea5UL, 0x11867bb7UL, 0x74e1c70fUL, - 0xcdd91092UL, 0xa8beac2aUL, 0x46111938UL, 0x2376a580UL, 0x7566c6d8UL, - 0x10017a60UL, 0xfeaecf72UL, 0x9bc973caUL, 0x22f1a457UL, 0x479618efUL, - 0xa939adfdUL, 0xcc5e1145UL, 0x06ee4d76UL, 0x6389f1ceUL, 0x8d2644dcUL, - 0xe841f864UL, 0x51792ff9UL, 0x341e9341UL, 0xdab12653UL, 0xbfd69aebUL, - 0xe9c6f9b3UL, 0x8ca1450bUL, 0x620ef019UL, 0x07694ca1UL, 0xbe519b3cUL, - 0xdb362784UL, 0x35999296UL, 0x50fe2e2eUL, 0x99b95426UL, 0xfcdee89eUL, - 0x12715d8cUL, 0x7716e134UL, 0xce2e36a9UL, 0xab498a11UL, 0x45e63f03UL, - 0x208183bbUL, 0x7691e0e3UL, 0x13f65c5bUL, 0xfd59e949UL, 0x983e55f1UL, - 0x2106826cUL, 0x44613ed4UL, 0xaace8bc6UL, 0xcfa9377eUL, 0x38417fd6UL, - 0x5d26c36eUL, 0xb389767cUL, 0xd6eecac4UL, 0x6fd61d59UL, 0x0ab1a1e1UL, - 0xe41e14f3UL, 0x8179a84bUL, 0xd769cb13UL, 0xb20e77abUL, 0x5ca1c2b9UL, - 0x39c67e01UL, 0x80fea99cUL, 0xe5991524UL, 0x0b36a036UL, 0x6e511c8eUL, - 0xa7166686UL, 0xc271da3eUL, 0x2cde6f2cUL, 0x49b9d394UL, 0xf0810409UL, - 0x95e6b8b1UL, 0x7b490da3UL, 0x1e2eb11bUL, 0x483ed243UL, 0x2d596efbUL, - 0xc3f6dbe9UL, 0xa6916751UL, 0x1fa9b0ccUL, 0x7ace0c74UL, 0x9461b966UL, - 0xf10605deUL +local const z_crc_t FAR crc_table[] = { + 0x00000000, 0x77073096, 0xee0e612c, 0x990951ba, 0x076dc419, + 0x706af48f, 0xe963a535, 0x9e6495a3, 0x0edb8832, 0x79dcb8a4, + 0xe0d5e91e, 0x97d2d988, 0x09b64c2b, 0x7eb17cbd, 0xe7b82d07, + 0x90bf1d91, 0x1db71064, 0x6ab020f2, 0xf3b97148, 0x84be41de, + 0x1adad47d, 0x6ddde4eb, 0xf4d4b551, 0x83d385c7, 0x136c9856, + 0x646ba8c0, 0xfd62f97a, 0x8a65c9ec, 0x14015c4f, 0x63066cd9, + 0xfa0f3d63, 0x8d080df5, 0x3b6e20c8, 0x4c69105e, 0xd56041e4, + 0xa2677172, 0x3c03e4d1, 0x4b04d447, 0xd20d85fd, 0xa50ab56b, + 0x35b5a8fa, 0x42b2986c, 0xdbbbc9d6, 0xacbcf940, 0x32d86ce3, + 0x45df5c75, 0xdcd60dcf, 0xabd13d59, 0x26d930ac, 0x51de003a, + 0xc8d75180, 0xbfd06116, 0x21b4f4b5, 0x56b3c423, 0xcfba9599, + 0xb8bda50f, 0x2802b89e, 0x5f058808, 0xc60cd9b2, 0xb10be924, + 0x2f6f7c87, 0x58684c11, 0xc1611dab, 0xb6662d3d, 0x76dc4190, + 0x01db7106, 0x98d220bc, 0xefd5102a, 0x71b18589, 0x06b6b51f, + 0x9fbfe4a5, 0xe8b8d433, 0x7807c9a2, 0x0f00f934, 0x9609a88e, + 0xe10e9818, 0x7f6a0dbb, 0x086d3d2d, 0x91646c97, 0xe6635c01, + 0x6b6b51f4, 0x1c6c6162, 0x856530d8, 0xf262004e, 0x6c0695ed, + 0x1b01a57b, 0x8208f4c1, 0xf50fc457, 0x65b0d9c6, 0x12b7e950, + 0x8bbeb8ea, 0xfcb9887c, 0x62dd1ddf, 0x15da2d49, 0x8cd37cf3, + 0xfbd44c65, 0x4db26158, 0x3ab551ce, 0xa3bc0074, 0xd4bb30e2, + 0x4adfa541, 0x3dd895d7, 0xa4d1c46d, 0xd3d6f4fb, 0x4369e96a, + 0x346ed9fc, 0xad678846, 0xda60b8d0, 0x44042d73, 0x33031de5, + 0xaa0a4c5f, 0xdd0d7cc9, 0x5005713c, 0x270241aa, 0xbe0b1010, + 0xc90c2086, 0x5768b525, 0x206f85b3, 0xb966d409, 0xce61e49f, + 0x5edef90e, 0x29d9c998, 0xb0d09822, 0xc7d7a8b4, 0x59b33d17, + 0x2eb40d81, 0xb7bd5c3b, 0xc0ba6cad, 0xedb88320, 0x9abfb3b6, + 0x03b6e20c, 0x74b1d29a, 0xead54739, 0x9dd277af, 0x04db2615, + 0x73dc1683, 0xe3630b12, 0x94643b84, 0x0d6d6a3e, 0x7a6a5aa8, + 0xe40ecf0b, 0x9309ff9d, 0x0a00ae27, 0x7d079eb1, 0xf00f9344, + 0x8708a3d2, 0x1e01f268, 0x6906c2fe, 0xf762575d, 0x806567cb, + 0x196c3671, 0x6e6b06e7, 0xfed41b76, 0x89d32be0, 0x10da7a5a, + 0x67dd4acc, 0xf9b9df6f, 0x8ebeeff9, 0x17b7be43, 0x60b08ed5, + 0xd6d6a3e8, 0xa1d1937e, 0x38d8c2c4, 0x4fdff252, 0xd1bb67f1, + 0xa6bc5767, 0x3fb506dd, 0x48b2364b, 0xd80d2bda, 0xaf0a1b4c, + 0x36034af6, 0x41047a60, 0xdf60efc3, 0xa867df55, 0x316e8eef, + 0x4669be79, 0xcb61b38c, 0xbc66831a, 0x256fd2a0, 0x5268e236, + 0xcc0c7795, 0xbb0b4703, 0x220216b9, 0x5505262f, 0xc5ba3bbe, + 0xb2bd0b28, 0x2bb45a92, 0x5cb36a04, 0xc2d7ffa7, 0xb5d0cf31, + 0x2cd99e8b, 0x5bdeae1d, 0x9b64c2b0, 0xec63f226, 0x756aa39c, + 0x026d930a, 0x9c0906a9, 0xeb0e363f, 0x72076785, 0x05005713, + 0x95bf4a82, 0xe2b87a14, 0x7bb12bae, 0x0cb61b38, 0x92d28e9b, + 0xe5d5be0d, 0x7cdcefb7, 0x0bdbdf21, 0x86d3d2d4, 0xf1d4e242, + 0x68ddb3f8, 0x1fda836e, 0x81be16cd, 0xf6b9265b, 0x6fb077e1, + 0x18b74777, 0x88085ae6, 0xff0f6a70, 0x66063bca, 0x11010b5c, + 0x8f659eff, 0xf862ae69, 0x616bffd3, 0x166ccf45, 0xa00ae278, + 0xd70dd2ee, 0x4e048354, 0x3903b3c2, 0xa7672661, 0xd06016f7, + 0x4969474d, 0x3e6e77db, 0xaed16a4a, 0xd9d65adc, 0x40df0b66, + 0x37d83bf0, 0xa9bcae53, 0xdebb9ec5, 0x47b2cf7f, 0x30b5ffe9, + 0xbdbdf21c, 0xcabac28a, 0x53b39330, 0x24b4a3a6, 0xbad03605, + 0xcdd70693, 0x54de5729, 0x23d967bf, 0xb3667a2e, 0xc4614ab8, + 0x5d681b02, 0x2a6f2b94, 0xb40bbe37, 0xc30c8ea1, 0x5a05df1b, + 0x2d02ef8d}; + +#ifdef W + +#if W == 8 + +local const z_word_t FAR crc_big_table[] = { + 0x0000000000000000, 0x9630077700000000, 0x2c610eee00000000, + 0xba51099900000000, 0x19c46d0700000000, 0x8ff46a7000000000, + 0x35a563e900000000, 0xa395649e00000000, 0x3288db0e00000000, + 0xa4b8dc7900000000, 0x1ee9d5e000000000, 0x88d9d29700000000, + 0x2b4cb60900000000, 0xbd7cb17e00000000, 0x072db8e700000000, + 0x911dbf9000000000, 0x6410b71d00000000, 0xf220b06a00000000, + 0x4871b9f300000000, 0xde41be8400000000, 0x7dd4da1a00000000, + 0xebe4dd6d00000000, 0x51b5d4f400000000, 0xc785d38300000000, + 0x56986c1300000000, 0xc0a86b6400000000, 0x7af962fd00000000, + 0xecc9658a00000000, 0x4f5c011400000000, 0xd96c066300000000, + 0x633d0ffa00000000, 0xf50d088d00000000, 0xc8206e3b00000000, + 0x5e10694c00000000, 0xe44160d500000000, 0x727167a200000000, + 0xd1e4033c00000000, 0x47d4044b00000000, 0xfd850dd200000000, + 0x6bb50aa500000000, 0xfaa8b53500000000, 0x6c98b24200000000, + 0xd6c9bbdb00000000, 0x40f9bcac00000000, 0xe36cd83200000000, + 0x755cdf4500000000, 0xcf0dd6dc00000000, 0x593dd1ab00000000, + 0xac30d92600000000, 0x3a00de5100000000, 0x8051d7c800000000, + 0x1661d0bf00000000, 0xb5f4b42100000000, 0x23c4b35600000000, + 0x9995bacf00000000, 0x0fa5bdb800000000, 0x9eb8022800000000, + 0x0888055f00000000, 0xb2d90cc600000000, 0x24e90bb100000000, + 0x877c6f2f00000000, 0x114c685800000000, 0xab1d61c100000000, + 0x3d2d66b600000000, 0x9041dc7600000000, 0x0671db0100000000, + 0xbc20d29800000000, 0x2a10d5ef00000000, 0x8985b17100000000, + 0x1fb5b60600000000, 0xa5e4bf9f00000000, 0x33d4b8e800000000, + 0xa2c9077800000000, 0x34f9000f00000000, 0x8ea8099600000000, + 0x18980ee100000000, 0xbb0d6a7f00000000, 0x2d3d6d0800000000, + 0x976c649100000000, 0x015c63e600000000, 0xf4516b6b00000000, + 0x62616c1c00000000, 0xd830658500000000, 0x4e0062f200000000, + 0xed95066c00000000, 0x7ba5011b00000000, 0xc1f4088200000000, + 0x57c40ff500000000, 0xc6d9b06500000000, 0x50e9b71200000000, + 0xeab8be8b00000000, 0x7c88b9fc00000000, 0xdf1ddd6200000000, + 0x492dda1500000000, 0xf37cd38c00000000, 0x654cd4fb00000000, + 0x5861b24d00000000, 0xce51b53a00000000, 0x7400bca300000000, + 0xe230bbd400000000, 0x41a5df4a00000000, 0xd795d83d00000000, + 0x6dc4d1a400000000, 0xfbf4d6d300000000, 0x6ae9694300000000, + 0xfcd96e3400000000, 0x468867ad00000000, 0xd0b860da00000000, + 0x732d044400000000, 0xe51d033300000000, 0x5f4c0aaa00000000, + 0xc97c0ddd00000000, 0x3c71055000000000, 0xaa41022700000000, + 0x10100bbe00000000, 0x86200cc900000000, 0x25b5685700000000, + 0xb3856f2000000000, 0x09d466b900000000, 0x9fe461ce00000000, + 0x0ef9de5e00000000, 0x98c9d92900000000, 0x2298d0b000000000, + 0xb4a8d7c700000000, 0x173db35900000000, 0x810db42e00000000, + 0x3b5cbdb700000000, 0xad6cbac000000000, 0x2083b8ed00000000, + 0xb6b3bf9a00000000, 0x0ce2b60300000000, 0x9ad2b17400000000, + 0x3947d5ea00000000, 0xaf77d29d00000000, 0x1526db0400000000, + 0x8316dc7300000000, 0x120b63e300000000, 0x843b649400000000, + 0x3e6a6d0d00000000, 0xa85a6a7a00000000, 0x0bcf0ee400000000, + 0x9dff099300000000, 0x27ae000a00000000, 0xb19e077d00000000, + 0x44930ff000000000, 0xd2a3088700000000, 0x68f2011e00000000, + 0xfec2066900000000, 0x5d5762f700000000, 0xcb67658000000000, + 0x71366c1900000000, 0xe7066b6e00000000, 0x761bd4fe00000000, + 0xe02bd38900000000, 0x5a7ada1000000000, 0xcc4add6700000000, + 0x6fdfb9f900000000, 0xf9efbe8e00000000, 0x43beb71700000000, + 0xd58eb06000000000, 0xe8a3d6d600000000, 0x7e93d1a100000000, + 0xc4c2d83800000000, 0x52f2df4f00000000, 0xf167bbd100000000, + 0x6757bca600000000, 0xdd06b53f00000000, 0x4b36b24800000000, + 0xda2b0dd800000000, 0x4c1b0aaf00000000, 0xf64a033600000000, + 0x607a044100000000, 0xc3ef60df00000000, 0x55df67a800000000, + 0xef8e6e3100000000, 0x79be694600000000, 0x8cb361cb00000000, + 0x1a8366bc00000000, 0xa0d26f2500000000, 0x36e2685200000000, + 0x95770ccc00000000, 0x03470bbb00000000, 0xb916022200000000, + 0x2f26055500000000, 0xbe3bbac500000000, 0x280bbdb200000000, + 0x925ab42b00000000, 0x046ab35c00000000, 0xa7ffd7c200000000, + 0x31cfd0b500000000, 0x8b9ed92c00000000, 0x1daede5b00000000, + 0xb0c2649b00000000, 0x26f263ec00000000, 0x9ca36a7500000000, + 0x0a936d0200000000, 0xa906099c00000000, 0x3f360eeb00000000, + 0x8567077200000000, 0x1357000500000000, 0x824abf9500000000, + 0x147ab8e200000000, 0xae2bb17b00000000, 0x381bb60c00000000, + 0x9b8ed29200000000, 0x0dbed5e500000000, 0xb7efdc7c00000000, + 0x21dfdb0b00000000, 0xd4d2d38600000000, 0x42e2d4f100000000, + 0xf8b3dd6800000000, 0x6e83da1f00000000, 0xcd16be8100000000, + 0x5b26b9f600000000, 0xe177b06f00000000, 0x7747b71800000000, + 0xe65a088800000000, 0x706a0fff00000000, 0xca3b066600000000, + 0x5c0b011100000000, 0xff9e658f00000000, 0x69ae62f800000000, + 0xd3ff6b6100000000, 0x45cf6c1600000000, 0x78e20aa000000000, + 0xeed20dd700000000, 0x5483044e00000000, 0xc2b3033900000000, + 0x612667a700000000, 0xf71660d000000000, 0x4d47694900000000, + 0xdb776e3e00000000, 0x4a6ad1ae00000000, 0xdc5ad6d900000000, + 0x660bdf4000000000, 0xf03bd83700000000, 0x53aebca900000000, + 0xc59ebbde00000000, 0x7fcfb24700000000, 0xe9ffb53000000000, + 0x1cf2bdbd00000000, 0x8ac2baca00000000, 0x3093b35300000000, + 0xa6a3b42400000000, 0x0536d0ba00000000, 0x9306d7cd00000000, + 0x2957de5400000000, 0xbf67d92300000000, 0x2e7a66b300000000, + 0xb84a61c400000000, 0x021b685d00000000, 0x942b6f2a00000000, + 0x37be0bb400000000, 0xa18e0cc300000000, 0x1bdf055a00000000, + 0x8def022d00000000}; + +#else /* W == 4 */ + +local const z_word_t FAR crc_big_table[] = { + 0x00000000, 0x96300777, 0x2c610eee, 0xba510999, 0x19c46d07, + 0x8ff46a70, 0x35a563e9, 0xa395649e, 0x3288db0e, 0xa4b8dc79, + 0x1ee9d5e0, 0x88d9d297, 0x2b4cb609, 0xbd7cb17e, 0x072db8e7, + 0x911dbf90, 0x6410b71d, 0xf220b06a, 0x4871b9f3, 0xde41be84, + 0x7dd4da1a, 0xebe4dd6d, 0x51b5d4f4, 0xc785d383, 0x56986c13, + 0xc0a86b64, 0x7af962fd, 0xecc9658a, 0x4f5c0114, 0xd96c0663, + 0x633d0ffa, 0xf50d088d, 0xc8206e3b, 0x5e10694c, 0xe44160d5, + 0x727167a2, 0xd1e4033c, 0x47d4044b, 0xfd850dd2, 0x6bb50aa5, + 0xfaa8b535, 0x6c98b242, 0xd6c9bbdb, 0x40f9bcac, 0xe36cd832, + 0x755cdf45, 0xcf0dd6dc, 0x593dd1ab, 0xac30d926, 0x3a00de51, + 0x8051d7c8, 0x1661d0bf, 0xb5f4b421, 0x23c4b356, 0x9995bacf, + 0x0fa5bdb8, 0x9eb80228, 0x0888055f, 0xb2d90cc6, 0x24e90bb1, + 0x877c6f2f, 0x114c6858, 0xab1d61c1, 0x3d2d66b6, 0x9041dc76, + 0x0671db01, 0xbc20d298, 0x2a10d5ef, 0x8985b171, 0x1fb5b606, + 0xa5e4bf9f, 0x33d4b8e8, 0xa2c90778, 0x34f9000f, 0x8ea80996, + 0x18980ee1, 0xbb0d6a7f, 0x2d3d6d08, 0x976c6491, 0x015c63e6, + 0xf4516b6b, 0x62616c1c, 0xd8306585, 0x4e0062f2, 0xed95066c, + 0x7ba5011b, 0xc1f40882, 0x57c40ff5, 0xc6d9b065, 0x50e9b712, + 0xeab8be8b, 0x7c88b9fc, 0xdf1ddd62, 0x492dda15, 0xf37cd38c, + 0x654cd4fb, 0x5861b24d, 0xce51b53a, 0x7400bca3, 0xe230bbd4, + 0x41a5df4a, 0xd795d83d, 0x6dc4d1a4, 0xfbf4d6d3, 0x6ae96943, + 0xfcd96e34, 0x468867ad, 0xd0b860da, 0x732d0444, 0xe51d0333, + 0x5f4c0aaa, 0xc97c0ddd, 0x3c710550, 0xaa410227, 0x10100bbe, + 0x86200cc9, 0x25b56857, 0xb3856f20, 0x09d466b9, 0x9fe461ce, + 0x0ef9de5e, 0x98c9d929, 0x2298d0b0, 0xb4a8d7c7, 0x173db359, + 0x810db42e, 0x3b5cbdb7, 0xad6cbac0, 0x2083b8ed, 0xb6b3bf9a, + 0x0ce2b603, 0x9ad2b174, 0x3947d5ea, 0xaf77d29d, 0x1526db04, + 0x8316dc73, 0x120b63e3, 0x843b6494, 0x3e6a6d0d, 0xa85a6a7a, + 0x0bcf0ee4, 0x9dff0993, 0x27ae000a, 0xb19e077d, 0x44930ff0, + 0xd2a30887, 0x68f2011e, 0xfec20669, 0x5d5762f7, 0xcb676580, + 0x71366c19, 0xe7066b6e, 0x761bd4fe, 0xe02bd389, 0x5a7ada10, + 0xcc4add67, 0x6fdfb9f9, 0xf9efbe8e, 0x43beb717, 0xd58eb060, + 0xe8a3d6d6, 0x7e93d1a1, 0xc4c2d838, 0x52f2df4f, 0xf167bbd1, + 0x6757bca6, 0xdd06b53f, 0x4b36b248, 0xda2b0dd8, 0x4c1b0aaf, + 0xf64a0336, 0x607a0441, 0xc3ef60df, 0x55df67a8, 0xef8e6e31, + 0x79be6946, 0x8cb361cb, 0x1a8366bc, 0xa0d26f25, 0x36e26852, + 0x95770ccc, 0x03470bbb, 0xb9160222, 0x2f260555, 0xbe3bbac5, + 0x280bbdb2, 0x925ab42b, 0x046ab35c, 0xa7ffd7c2, 0x31cfd0b5, + 0x8b9ed92c, 0x1daede5b, 0xb0c2649b, 0x26f263ec, 0x9ca36a75, + 0x0a936d02, 0xa906099c, 0x3f360eeb, 0x85670772, 0x13570005, + 0x824abf95, 0x147ab8e2, 0xae2bb17b, 0x381bb60c, 0x9b8ed292, + 0x0dbed5e5, 0xb7efdc7c, 0x21dfdb0b, 0xd4d2d386, 0x42e2d4f1, + 0xf8b3dd68, 0x6e83da1f, 0xcd16be81, 0x5b26b9f6, 0xe177b06f, + 0x7747b718, 0xe65a0888, 0x706a0fff, 0xca3b0666, 0x5c0b0111, + 0xff9e658f, 0x69ae62f8, 0xd3ff6b61, 0x45cf6c16, 0x78e20aa0, + 0xeed20dd7, 0x5483044e, 0xc2b30339, 0x612667a7, 0xf71660d0, + 0x4d476949, 0xdb776e3e, 0x4a6ad1ae, 0xdc5ad6d9, 0x660bdf40, + 0xf03bd837, 0x53aebca9, 0xc59ebbde, 0x7fcfb247, 0xe9ffb530, + 0x1cf2bdbd, 0x8ac2baca, 0x3093b353, 0xa6a3b424, 0x0536d0ba, + 0x9306d7cd, 0x2957de54, 0xbf67d923, 0x2e7a66b3, 0xb84a61c4, + 0x021b685d, 0x942b6f2a, 0x37be0bb4, 0xa18e0cc3, 0x1bdf055a, + 0x8def022d}; + #endif - } -}; + +#if N == 1 + +#if W == 8 + +local const z_crc_t FAR crc_braid_table[][256] = { + {0x00000000, 0xccaa009e, 0x4225077d, 0x8e8f07e3, 0x844a0efa, + 0x48e00e64, 0xc66f0987, 0x0ac50919, 0xd3e51bb5, 0x1f4f1b2b, + 0x91c01cc8, 0x5d6a1c56, 0x57af154f, 0x9b0515d1, 0x158a1232, + 0xd92012ac, 0x7cbb312b, 0xb01131b5, 0x3e9e3656, 0xf23436c8, + 0xf8f13fd1, 0x345b3f4f, 0xbad438ac, 0x767e3832, 0xaf5e2a9e, + 0x63f42a00, 0xed7b2de3, 0x21d12d7d, 0x2b142464, 0xe7be24fa, + 0x69312319, 0xa59b2387, 0xf9766256, 0x35dc62c8, 0xbb53652b, + 0x77f965b5, 0x7d3c6cac, 0xb1966c32, 0x3f196bd1, 0xf3b36b4f, + 0x2a9379e3, 0xe639797d, 0x68b67e9e, 0xa41c7e00, 0xaed97719, + 0x62737787, 0xecfc7064, 0x205670fa, 0x85cd537d, 0x496753e3, + 0xc7e85400, 0x0b42549e, 0x01875d87, 0xcd2d5d19, 0x43a25afa, + 0x8f085a64, 0x562848c8, 0x9a824856, 0x140d4fb5, 0xd8a74f2b, + 0xd2624632, 0x1ec846ac, 0x9047414f, 0x5ced41d1, 0x299dc2ed, + 0xe537c273, 0x6bb8c590, 0xa712c50e, 0xadd7cc17, 0x617dcc89, + 0xeff2cb6a, 0x2358cbf4, 0xfa78d958, 0x36d2d9c6, 0xb85dde25, + 0x74f7debb, 0x7e32d7a2, 0xb298d73c, 0x3c17d0df, 0xf0bdd041, + 0x5526f3c6, 0x998cf358, 0x1703f4bb, 0xdba9f425, 0xd16cfd3c, + 0x1dc6fda2, 0x9349fa41, 0x5fe3fadf, 0x86c3e873, 0x4a69e8ed, + 0xc4e6ef0e, 0x084cef90, 0x0289e689, 0xce23e617, 0x40ace1f4, + 0x8c06e16a, 0xd0eba0bb, 0x1c41a025, 0x92cea7c6, 0x5e64a758, + 0x54a1ae41, 0x980baedf, 0x1684a93c, 0xda2ea9a2, 0x030ebb0e, + 0xcfa4bb90, 0x412bbc73, 0x8d81bced, 0x8744b5f4, 0x4beeb56a, + 0xc561b289, 0x09cbb217, 0xac509190, 0x60fa910e, 0xee7596ed, + 0x22df9673, 0x281a9f6a, 0xe4b09ff4, 0x6a3f9817, 0xa6959889, + 0x7fb58a25, 0xb31f8abb, 0x3d908d58, 0xf13a8dc6, 0xfbff84df, + 0x37558441, 0xb9da83a2, 0x7570833c, 0x533b85da, 0x9f918544, + 0x111e82a7, 0xddb48239, 0xd7718b20, 0x1bdb8bbe, 0x95548c5d, + 0x59fe8cc3, 0x80de9e6f, 0x4c749ef1, 0xc2fb9912, 0x0e51998c, + 0x04949095, 0xc83e900b, 0x46b197e8, 0x8a1b9776, 0x2f80b4f1, + 0xe32ab46f, 0x6da5b38c, 0xa10fb312, 0xabcaba0b, 0x6760ba95, + 0xe9efbd76, 0x2545bde8, 0xfc65af44, 0x30cfafda, 0xbe40a839, + 0x72eaa8a7, 0x782fa1be, 0xb485a120, 0x3a0aa6c3, 0xf6a0a65d, + 0xaa4de78c, 0x66e7e712, 0xe868e0f1, 0x24c2e06f, 0x2e07e976, + 0xe2ade9e8, 0x6c22ee0b, 0xa088ee95, 0x79a8fc39, 0xb502fca7, + 0x3b8dfb44, 0xf727fbda, 0xfde2f2c3, 0x3148f25d, 0xbfc7f5be, + 0x736df520, 0xd6f6d6a7, 0x1a5cd639, 0x94d3d1da, 0x5879d144, + 0x52bcd85d, 0x9e16d8c3, 0x1099df20, 0xdc33dfbe, 0x0513cd12, + 0xc9b9cd8c, 0x4736ca6f, 0x8b9ccaf1, 0x8159c3e8, 0x4df3c376, + 0xc37cc495, 0x0fd6c40b, 0x7aa64737, 0xb60c47a9, 0x3883404a, + 0xf42940d4, 0xfeec49cd, 0x32464953, 0xbcc94eb0, 0x70634e2e, + 0xa9435c82, 0x65e95c1c, 0xeb665bff, 0x27cc5b61, 0x2d095278, + 0xe1a352e6, 0x6f2c5505, 0xa386559b, 0x061d761c, 0xcab77682, + 0x44387161, 0x889271ff, 0x825778e6, 0x4efd7878, 0xc0727f9b, + 0x0cd87f05, 0xd5f86da9, 0x19526d37, 0x97dd6ad4, 0x5b776a4a, + 0x51b26353, 0x9d1863cd, 0x1397642e, 0xdf3d64b0, 0x83d02561, + 0x4f7a25ff, 0xc1f5221c, 0x0d5f2282, 0x079a2b9b, 0xcb302b05, + 0x45bf2ce6, 0x89152c78, 0x50353ed4, 0x9c9f3e4a, 0x121039a9, + 0xdeba3937, 0xd47f302e, 0x18d530b0, 0x965a3753, 0x5af037cd, + 0xff6b144a, 0x33c114d4, 0xbd4e1337, 0x71e413a9, 0x7b211ab0, + 0xb78b1a2e, 0x39041dcd, 0xf5ae1d53, 0x2c8e0fff, 0xe0240f61, + 0x6eab0882, 0xa201081c, 0xa8c40105, 0x646e019b, 0xeae10678, + 0x264b06e6}, + {0x00000000, 0xa6770bb4, 0x979f1129, 0x31e81a9d, 0xf44f2413, + 0x52382fa7, 0x63d0353a, 0xc5a73e8e, 0x33ef4e67, 0x959845d3, + 0xa4705f4e, 0x020754fa, 0xc7a06a74, 0x61d761c0, 0x503f7b5d, + 0xf64870e9, 0x67de9cce, 0xc1a9977a, 0xf0418de7, 0x56368653, + 0x9391b8dd, 0x35e6b369, 0x040ea9f4, 0xa279a240, 0x5431d2a9, + 0xf246d91d, 0xc3aec380, 0x65d9c834, 0xa07ef6ba, 0x0609fd0e, + 0x37e1e793, 0x9196ec27, 0xcfbd399c, 0x69ca3228, 0x582228b5, + 0xfe552301, 0x3bf21d8f, 0x9d85163b, 0xac6d0ca6, 0x0a1a0712, + 0xfc5277fb, 0x5a257c4f, 0x6bcd66d2, 0xcdba6d66, 0x081d53e8, + 0xae6a585c, 0x9f8242c1, 0x39f54975, 0xa863a552, 0x0e14aee6, + 0x3ffcb47b, 0x998bbfcf, 0x5c2c8141, 0xfa5b8af5, 0xcbb39068, + 0x6dc49bdc, 0x9b8ceb35, 0x3dfbe081, 0x0c13fa1c, 0xaa64f1a8, + 0x6fc3cf26, 0xc9b4c492, 0xf85cde0f, 0x5e2bd5bb, 0x440b7579, + 0xe27c7ecd, 0xd3946450, 0x75e36fe4, 0xb044516a, 0x16335ade, + 0x27db4043, 0x81ac4bf7, 0x77e43b1e, 0xd19330aa, 0xe07b2a37, + 0x460c2183, 0x83ab1f0d, 0x25dc14b9, 0x14340e24, 0xb2430590, + 0x23d5e9b7, 0x85a2e203, 0xb44af89e, 0x123df32a, 0xd79acda4, + 0x71edc610, 0x4005dc8d, 0xe672d739, 0x103aa7d0, 0xb64dac64, + 0x87a5b6f9, 0x21d2bd4d, 0xe47583c3, 0x42028877, 0x73ea92ea, + 0xd59d995e, 0x8bb64ce5, 0x2dc14751, 0x1c295dcc, 0xba5e5678, + 0x7ff968f6, 0xd98e6342, 0xe86679df, 0x4e11726b, 0xb8590282, + 0x1e2e0936, 0x2fc613ab, 0x89b1181f, 0x4c162691, 0xea612d25, + 0xdb8937b8, 0x7dfe3c0c, 0xec68d02b, 0x4a1fdb9f, 0x7bf7c102, + 0xdd80cab6, 0x1827f438, 0xbe50ff8c, 0x8fb8e511, 0x29cfeea5, + 0xdf879e4c, 0x79f095f8, 0x48188f65, 0xee6f84d1, 0x2bc8ba5f, + 0x8dbfb1eb, 0xbc57ab76, 0x1a20a0c2, 0x8816eaf2, 0x2e61e146, + 0x1f89fbdb, 0xb9fef06f, 0x7c59cee1, 0xda2ec555, 0xebc6dfc8, + 0x4db1d47c, 0xbbf9a495, 0x1d8eaf21, 0x2c66b5bc, 0x8a11be08, + 0x4fb68086, 0xe9c18b32, 0xd82991af, 0x7e5e9a1b, 0xefc8763c, + 0x49bf7d88, 0x78576715, 0xde206ca1, 0x1b87522f, 0xbdf0599b, + 0x8c184306, 0x2a6f48b2, 0xdc27385b, 0x7a5033ef, 0x4bb82972, + 0xedcf22c6, 0x28681c48, 0x8e1f17fc, 0xbff70d61, 0x198006d5, + 0x47abd36e, 0xe1dcd8da, 0xd034c247, 0x7643c9f3, 0xb3e4f77d, + 0x1593fcc9, 0x247be654, 0x820cede0, 0x74449d09, 0xd23396bd, + 0xe3db8c20, 0x45ac8794, 0x800bb91a, 0x267cb2ae, 0x1794a833, + 0xb1e3a387, 0x20754fa0, 0x86024414, 0xb7ea5e89, 0x119d553d, + 0xd43a6bb3, 0x724d6007, 0x43a57a9a, 0xe5d2712e, 0x139a01c7, + 0xb5ed0a73, 0x840510ee, 0x22721b5a, 0xe7d525d4, 0x41a22e60, + 0x704a34fd, 0xd63d3f49, 0xcc1d9f8b, 0x6a6a943f, 0x5b828ea2, + 0xfdf58516, 0x3852bb98, 0x9e25b02c, 0xafcdaab1, 0x09baa105, + 0xfff2d1ec, 0x5985da58, 0x686dc0c5, 0xce1acb71, 0x0bbdf5ff, + 0xadcafe4b, 0x9c22e4d6, 0x3a55ef62, 0xabc30345, 0x0db408f1, + 0x3c5c126c, 0x9a2b19d8, 0x5f8c2756, 0xf9fb2ce2, 0xc813367f, + 0x6e643dcb, 0x982c4d22, 0x3e5b4696, 0x0fb35c0b, 0xa9c457bf, + 0x6c636931, 0xca146285, 0xfbfc7818, 0x5d8b73ac, 0x03a0a617, + 0xa5d7ada3, 0x943fb73e, 0x3248bc8a, 0xf7ef8204, 0x519889b0, + 0x6070932d, 0xc6079899, 0x304fe870, 0x9638e3c4, 0xa7d0f959, + 0x01a7f2ed, 0xc400cc63, 0x6277c7d7, 0x539fdd4a, 0xf5e8d6fe, + 0x647e3ad9, 0xc209316d, 0xf3e12bf0, 0x55962044, 0x90311eca, + 0x3646157e, 0x07ae0fe3, 0xa1d90457, 0x579174be, 0xf1e67f0a, + 0xc00e6597, 0x66796e23, 0xa3de50ad, 0x05a95b19, 0x34414184, + 0x92364a30}, + {0x00000000, 0xcb5cd3a5, 0x4dc8a10b, 0x869472ae, 0x9b914216, + 0x50cd91b3, 0xd659e31d, 0x1d0530b8, 0xec53826d, 0x270f51c8, + 0xa19b2366, 0x6ac7f0c3, 0x77c2c07b, 0xbc9e13de, 0x3a0a6170, + 0xf156b2d5, 0x03d6029b, 0xc88ad13e, 0x4e1ea390, 0x85427035, + 0x9847408d, 0x531b9328, 0xd58fe186, 0x1ed33223, 0xef8580f6, + 0x24d95353, 0xa24d21fd, 0x6911f258, 0x7414c2e0, 0xbf481145, + 0x39dc63eb, 0xf280b04e, 0x07ac0536, 0xccf0d693, 0x4a64a43d, + 0x81387798, 0x9c3d4720, 0x57619485, 0xd1f5e62b, 0x1aa9358e, + 0xebff875b, 0x20a354fe, 0xa6372650, 0x6d6bf5f5, 0x706ec54d, + 0xbb3216e8, 0x3da66446, 0xf6fab7e3, 0x047a07ad, 0xcf26d408, + 0x49b2a6a6, 0x82ee7503, 0x9feb45bb, 0x54b7961e, 0xd223e4b0, + 0x197f3715, 0xe82985c0, 0x23755665, 0xa5e124cb, 0x6ebdf76e, + 0x73b8c7d6, 0xb8e41473, 0x3e7066dd, 0xf52cb578, 0x0f580a6c, + 0xc404d9c9, 0x4290ab67, 0x89cc78c2, 0x94c9487a, 0x5f959bdf, + 0xd901e971, 0x125d3ad4, 0xe30b8801, 0x28575ba4, 0xaec3290a, + 0x659ffaaf, 0x789aca17, 0xb3c619b2, 0x35526b1c, 0xfe0eb8b9, + 0x0c8e08f7, 0xc7d2db52, 0x4146a9fc, 0x8a1a7a59, 0x971f4ae1, + 0x5c439944, 0xdad7ebea, 0x118b384f, 0xe0dd8a9a, 0x2b81593f, + 0xad152b91, 0x6649f834, 0x7b4cc88c, 0xb0101b29, 0x36846987, + 0xfdd8ba22, 0x08f40f5a, 0xc3a8dcff, 0x453cae51, 0x8e607df4, + 0x93654d4c, 0x58399ee9, 0xdeadec47, 0x15f13fe2, 0xe4a78d37, + 0x2ffb5e92, 0xa96f2c3c, 0x6233ff99, 0x7f36cf21, 0xb46a1c84, + 0x32fe6e2a, 0xf9a2bd8f, 0x0b220dc1, 0xc07ede64, 0x46eaacca, + 0x8db67f6f, 0x90b34fd7, 0x5bef9c72, 0xdd7beedc, 0x16273d79, + 0xe7718fac, 0x2c2d5c09, 0xaab92ea7, 0x61e5fd02, 0x7ce0cdba, + 0xb7bc1e1f, 0x31286cb1, 0xfa74bf14, 0x1eb014d8, 0xd5ecc77d, + 0x5378b5d3, 0x98246676, 0x852156ce, 0x4e7d856b, 0xc8e9f7c5, + 0x03b52460, 0xf2e396b5, 0x39bf4510, 0xbf2b37be, 0x7477e41b, + 0x6972d4a3, 0xa22e0706, 0x24ba75a8, 0xefe6a60d, 0x1d661643, + 0xd63ac5e6, 0x50aeb748, 0x9bf264ed, 0x86f75455, 0x4dab87f0, + 0xcb3ff55e, 0x006326fb, 0xf135942e, 0x3a69478b, 0xbcfd3525, + 0x77a1e680, 0x6aa4d638, 0xa1f8059d, 0x276c7733, 0xec30a496, + 0x191c11ee, 0xd240c24b, 0x54d4b0e5, 0x9f886340, 0x828d53f8, + 0x49d1805d, 0xcf45f2f3, 0x04192156, 0xf54f9383, 0x3e134026, + 0xb8873288, 0x73dbe12d, 0x6eded195, 0xa5820230, 0x2316709e, + 0xe84aa33b, 0x1aca1375, 0xd196c0d0, 0x5702b27e, 0x9c5e61db, + 0x815b5163, 0x4a0782c6, 0xcc93f068, 0x07cf23cd, 0xf6999118, + 0x3dc542bd, 0xbb513013, 0x700de3b6, 0x6d08d30e, 0xa65400ab, + 0x20c07205, 0xeb9ca1a0, 0x11e81eb4, 0xdab4cd11, 0x5c20bfbf, + 0x977c6c1a, 0x8a795ca2, 0x41258f07, 0xc7b1fda9, 0x0ced2e0c, + 0xfdbb9cd9, 0x36e74f7c, 0xb0733dd2, 0x7b2fee77, 0x662adecf, + 0xad760d6a, 0x2be27fc4, 0xe0beac61, 0x123e1c2f, 0xd962cf8a, + 0x5ff6bd24, 0x94aa6e81, 0x89af5e39, 0x42f38d9c, 0xc467ff32, + 0x0f3b2c97, 0xfe6d9e42, 0x35314de7, 0xb3a53f49, 0x78f9ecec, + 0x65fcdc54, 0xaea00ff1, 0x28347d5f, 0xe368aefa, 0x16441b82, + 0xdd18c827, 0x5b8cba89, 0x90d0692c, 0x8dd55994, 0x46898a31, + 0xc01df89f, 0x0b412b3a, 0xfa1799ef, 0x314b4a4a, 0xb7df38e4, + 0x7c83eb41, 0x6186dbf9, 0xaada085c, 0x2c4e7af2, 0xe712a957, + 0x15921919, 0xdececabc, 0x585ab812, 0x93066bb7, 0x8e035b0f, + 0x455f88aa, 0xc3cbfa04, 0x089729a1, 0xf9c19b74, 0x329d48d1, + 0xb4093a7f, 0x7f55e9da, 0x6250d962, 0xa90c0ac7, 0x2f987869, + 0xe4c4abcc}, + {0x00000000, 0x3d6029b0, 0x7ac05360, 0x47a07ad0, 0xf580a6c0, + 0xc8e08f70, 0x8f40f5a0, 0xb220dc10, 0x30704bc1, 0x0d106271, + 0x4ab018a1, 0x77d03111, 0xc5f0ed01, 0xf890c4b1, 0xbf30be61, + 0x825097d1, 0x60e09782, 0x5d80be32, 0x1a20c4e2, 0x2740ed52, + 0x95603142, 0xa80018f2, 0xefa06222, 0xd2c04b92, 0x5090dc43, + 0x6df0f5f3, 0x2a508f23, 0x1730a693, 0xa5107a83, 0x98705333, + 0xdfd029e3, 0xe2b00053, 0xc1c12f04, 0xfca106b4, 0xbb017c64, + 0x866155d4, 0x344189c4, 0x0921a074, 0x4e81daa4, 0x73e1f314, + 0xf1b164c5, 0xccd14d75, 0x8b7137a5, 0xb6111e15, 0x0431c205, + 0x3951ebb5, 0x7ef19165, 0x4391b8d5, 0xa121b886, 0x9c419136, + 0xdbe1ebe6, 0xe681c256, 0x54a11e46, 0x69c137f6, 0x2e614d26, + 0x13016496, 0x9151f347, 0xac31daf7, 0xeb91a027, 0xd6f18997, + 0x64d15587, 0x59b17c37, 0x1e1106e7, 0x23712f57, 0x58f35849, + 0x659371f9, 0x22330b29, 0x1f532299, 0xad73fe89, 0x9013d739, + 0xd7b3ade9, 0xead38459, 0x68831388, 0x55e33a38, 0x124340e8, + 0x2f236958, 0x9d03b548, 0xa0639cf8, 0xe7c3e628, 0xdaa3cf98, + 0x3813cfcb, 0x0573e67b, 0x42d39cab, 0x7fb3b51b, 0xcd93690b, + 0xf0f340bb, 0xb7533a6b, 0x8a3313db, 0x0863840a, 0x3503adba, + 0x72a3d76a, 0x4fc3feda, 0xfde322ca, 0xc0830b7a, 0x872371aa, + 0xba43581a, 0x9932774d, 0xa4525efd, 0xe3f2242d, 0xde920d9d, + 0x6cb2d18d, 0x51d2f83d, 0x167282ed, 0x2b12ab5d, 0xa9423c8c, + 0x9422153c, 0xd3826fec, 0xeee2465c, 0x5cc29a4c, 0x61a2b3fc, + 0x2602c92c, 0x1b62e09c, 0xf9d2e0cf, 0xc4b2c97f, 0x8312b3af, + 0xbe729a1f, 0x0c52460f, 0x31326fbf, 0x7692156f, 0x4bf23cdf, + 0xc9a2ab0e, 0xf4c282be, 0xb362f86e, 0x8e02d1de, 0x3c220dce, + 0x0142247e, 0x46e25eae, 0x7b82771e, 0xb1e6b092, 0x8c869922, + 0xcb26e3f2, 0xf646ca42, 0x44661652, 0x79063fe2, 0x3ea64532, + 0x03c66c82, 0x8196fb53, 0xbcf6d2e3, 0xfb56a833, 0xc6368183, + 0x74165d93, 0x49767423, 0x0ed60ef3, 0x33b62743, 0xd1062710, + 0xec660ea0, 0xabc67470, 0x96a65dc0, 0x248681d0, 0x19e6a860, + 0x5e46d2b0, 0x6326fb00, 0xe1766cd1, 0xdc164561, 0x9bb63fb1, + 0xa6d61601, 0x14f6ca11, 0x2996e3a1, 0x6e369971, 0x5356b0c1, + 0x70279f96, 0x4d47b626, 0x0ae7ccf6, 0x3787e546, 0x85a73956, + 0xb8c710e6, 0xff676a36, 0xc2074386, 0x4057d457, 0x7d37fde7, + 0x3a978737, 0x07f7ae87, 0xb5d77297, 0x88b75b27, 0xcf1721f7, + 0xf2770847, 0x10c70814, 0x2da721a4, 0x6a075b74, 0x576772c4, + 0xe547aed4, 0xd8278764, 0x9f87fdb4, 0xa2e7d404, 0x20b743d5, + 0x1dd76a65, 0x5a7710b5, 0x67173905, 0xd537e515, 0xe857cca5, + 0xaff7b675, 0x92979fc5, 0xe915e8db, 0xd475c16b, 0x93d5bbbb, + 0xaeb5920b, 0x1c954e1b, 0x21f567ab, 0x66551d7b, 0x5b3534cb, + 0xd965a31a, 0xe4058aaa, 0xa3a5f07a, 0x9ec5d9ca, 0x2ce505da, + 0x11852c6a, 0x562556ba, 0x6b457f0a, 0x89f57f59, 0xb49556e9, + 0xf3352c39, 0xce550589, 0x7c75d999, 0x4115f029, 0x06b58af9, + 0x3bd5a349, 0xb9853498, 0x84e51d28, 0xc34567f8, 0xfe254e48, + 0x4c059258, 0x7165bbe8, 0x36c5c138, 0x0ba5e888, 0x28d4c7df, + 0x15b4ee6f, 0x521494bf, 0x6f74bd0f, 0xdd54611f, 0xe03448af, + 0xa794327f, 0x9af41bcf, 0x18a48c1e, 0x25c4a5ae, 0x6264df7e, + 0x5f04f6ce, 0xed242ade, 0xd044036e, 0x97e479be, 0xaa84500e, + 0x4834505d, 0x755479ed, 0x32f4033d, 0x0f942a8d, 0xbdb4f69d, + 0x80d4df2d, 0xc774a5fd, 0xfa148c4d, 0x78441b9c, 0x4524322c, + 0x028448fc, 0x3fe4614c, 0x8dc4bd5c, 0xb0a494ec, 0xf704ee3c, + 0xca64c78c}, + {0x00000000, 0xb8bc6765, 0xaa09c88b, 0x12b5afee, 0x8f629757, + 0x37def032, 0x256b5fdc, 0x9dd738b9, 0xc5b428ef, 0x7d084f8a, + 0x6fbde064, 0xd7018701, 0x4ad6bfb8, 0xf26ad8dd, 0xe0df7733, + 0x58631056, 0x5019579f, 0xe8a530fa, 0xfa109f14, 0x42acf871, + 0xdf7bc0c8, 0x67c7a7ad, 0x75720843, 0xcdce6f26, 0x95ad7f70, + 0x2d111815, 0x3fa4b7fb, 0x8718d09e, 0x1acfe827, 0xa2738f42, + 0xb0c620ac, 0x087a47c9, 0xa032af3e, 0x188ec85b, 0x0a3b67b5, + 0xb28700d0, 0x2f503869, 0x97ec5f0c, 0x8559f0e2, 0x3de59787, + 0x658687d1, 0xdd3ae0b4, 0xcf8f4f5a, 0x7733283f, 0xeae41086, + 0x525877e3, 0x40edd80d, 0xf851bf68, 0xf02bf8a1, 0x48979fc4, + 0x5a22302a, 0xe29e574f, 0x7f496ff6, 0xc7f50893, 0xd540a77d, + 0x6dfcc018, 0x359fd04e, 0x8d23b72b, 0x9f9618c5, 0x272a7fa0, + 0xbafd4719, 0x0241207c, 0x10f48f92, 0xa848e8f7, 0x9b14583d, + 0x23a83f58, 0x311d90b6, 0x89a1f7d3, 0x1476cf6a, 0xaccaa80f, + 0xbe7f07e1, 0x06c36084, 0x5ea070d2, 0xe61c17b7, 0xf4a9b859, + 0x4c15df3c, 0xd1c2e785, 0x697e80e0, 0x7bcb2f0e, 0xc377486b, + 0xcb0d0fa2, 0x73b168c7, 0x6104c729, 0xd9b8a04c, 0x446f98f5, + 0xfcd3ff90, 0xee66507e, 0x56da371b, 0x0eb9274d, 0xb6054028, + 0xa4b0efc6, 0x1c0c88a3, 0x81dbb01a, 0x3967d77f, 0x2bd27891, + 0x936e1ff4, 0x3b26f703, 0x839a9066, 0x912f3f88, 0x299358ed, + 0xb4446054, 0x0cf80731, 0x1e4da8df, 0xa6f1cfba, 0xfe92dfec, + 0x462eb889, 0x549b1767, 0xec277002, 0x71f048bb, 0xc94c2fde, + 0xdbf98030, 0x6345e755, 0x6b3fa09c, 0xd383c7f9, 0xc1366817, + 0x798a0f72, 0xe45d37cb, 0x5ce150ae, 0x4e54ff40, 0xf6e89825, + 0xae8b8873, 0x1637ef16, 0x048240f8, 0xbc3e279d, 0x21e91f24, + 0x99557841, 0x8be0d7af, 0x335cb0ca, 0xed59b63b, 0x55e5d15e, + 0x47507eb0, 0xffec19d5, 0x623b216c, 0xda874609, 0xc832e9e7, + 0x708e8e82, 0x28ed9ed4, 0x9051f9b1, 0x82e4565f, 0x3a58313a, + 0xa78f0983, 0x1f336ee6, 0x0d86c108, 0xb53aa66d, 0xbd40e1a4, + 0x05fc86c1, 0x1749292f, 0xaff54e4a, 0x322276f3, 0x8a9e1196, + 0x982bbe78, 0x2097d91d, 0x78f4c94b, 0xc048ae2e, 0xd2fd01c0, + 0x6a4166a5, 0xf7965e1c, 0x4f2a3979, 0x5d9f9697, 0xe523f1f2, + 0x4d6b1905, 0xf5d77e60, 0xe762d18e, 0x5fdeb6eb, 0xc2098e52, + 0x7ab5e937, 0x680046d9, 0xd0bc21bc, 0x88df31ea, 0x3063568f, + 0x22d6f961, 0x9a6a9e04, 0x07bda6bd, 0xbf01c1d8, 0xadb46e36, + 0x15080953, 0x1d724e9a, 0xa5ce29ff, 0xb77b8611, 0x0fc7e174, + 0x9210d9cd, 0x2aacbea8, 0x38191146, 0x80a57623, 0xd8c66675, + 0x607a0110, 0x72cfaefe, 0xca73c99b, 0x57a4f122, 0xef189647, + 0xfdad39a9, 0x45115ecc, 0x764dee06, 0xcef18963, 0xdc44268d, + 0x64f841e8, 0xf92f7951, 0x41931e34, 0x5326b1da, 0xeb9ad6bf, + 0xb3f9c6e9, 0x0b45a18c, 0x19f00e62, 0xa14c6907, 0x3c9b51be, + 0x842736db, 0x96929935, 0x2e2efe50, 0x2654b999, 0x9ee8defc, + 0x8c5d7112, 0x34e11677, 0xa9362ece, 0x118a49ab, 0x033fe645, + 0xbb838120, 0xe3e09176, 0x5b5cf613, 0x49e959fd, 0xf1553e98, + 0x6c820621, 0xd43e6144, 0xc68bceaa, 0x7e37a9cf, 0xd67f4138, + 0x6ec3265d, 0x7c7689b3, 0xc4caeed6, 0x591dd66f, 0xe1a1b10a, + 0xf3141ee4, 0x4ba87981, 0x13cb69d7, 0xab770eb2, 0xb9c2a15c, + 0x017ec639, 0x9ca9fe80, 0x241599e5, 0x36a0360b, 0x8e1c516e, + 0x866616a7, 0x3eda71c2, 0x2c6fde2c, 0x94d3b949, 0x090481f0, + 0xb1b8e695, 0xa30d497b, 0x1bb12e1e, 0x43d23e48, 0xfb6e592d, + 0xe9dbf6c3, 0x516791a6, 0xccb0a91f, 0x740cce7a, 0x66b96194, + 0xde0506f1}, + {0x00000000, 0x01c26a37, 0x0384d46e, 0x0246be59, 0x0709a8dc, + 0x06cbc2eb, 0x048d7cb2, 0x054f1685, 0x0e1351b8, 0x0fd13b8f, + 0x0d9785d6, 0x0c55efe1, 0x091af964, 0x08d89353, 0x0a9e2d0a, + 0x0b5c473d, 0x1c26a370, 0x1de4c947, 0x1fa2771e, 0x1e601d29, + 0x1b2f0bac, 0x1aed619b, 0x18abdfc2, 0x1969b5f5, 0x1235f2c8, + 0x13f798ff, 0x11b126a6, 0x10734c91, 0x153c5a14, 0x14fe3023, + 0x16b88e7a, 0x177ae44d, 0x384d46e0, 0x398f2cd7, 0x3bc9928e, + 0x3a0bf8b9, 0x3f44ee3c, 0x3e86840b, 0x3cc03a52, 0x3d025065, + 0x365e1758, 0x379c7d6f, 0x35dac336, 0x3418a901, 0x3157bf84, + 0x3095d5b3, 0x32d36bea, 0x331101dd, 0x246be590, 0x25a98fa7, + 0x27ef31fe, 0x262d5bc9, 0x23624d4c, 0x22a0277b, 0x20e69922, + 0x2124f315, 0x2a78b428, 0x2bbade1f, 0x29fc6046, 0x283e0a71, + 0x2d711cf4, 0x2cb376c3, 0x2ef5c89a, 0x2f37a2ad, 0x709a8dc0, + 0x7158e7f7, 0x731e59ae, 0x72dc3399, 0x7793251c, 0x76514f2b, + 0x7417f172, 0x75d59b45, 0x7e89dc78, 0x7f4bb64f, 0x7d0d0816, + 0x7ccf6221, 0x798074a4, 0x78421e93, 0x7a04a0ca, 0x7bc6cafd, + 0x6cbc2eb0, 0x6d7e4487, 0x6f38fade, 0x6efa90e9, 0x6bb5866c, + 0x6a77ec5b, 0x68315202, 0x69f33835, 0x62af7f08, 0x636d153f, + 0x612bab66, 0x60e9c151, 0x65a6d7d4, 0x6464bde3, 0x662203ba, + 0x67e0698d, 0x48d7cb20, 0x4915a117, 0x4b531f4e, 0x4a917579, + 0x4fde63fc, 0x4e1c09cb, 0x4c5ab792, 0x4d98dda5, 0x46c49a98, + 0x4706f0af, 0x45404ef6, 0x448224c1, 0x41cd3244, 0x400f5873, + 0x4249e62a, 0x438b8c1d, 0x54f16850, 0x55330267, 0x5775bc3e, + 0x56b7d609, 0x53f8c08c, 0x523aaabb, 0x507c14e2, 0x51be7ed5, + 0x5ae239e8, 0x5b2053df, 0x5966ed86, 0x58a487b1, 0x5deb9134, + 0x5c29fb03, 0x5e6f455a, 0x5fad2f6d, 0xe1351b80, 0xe0f771b7, + 0xe2b1cfee, 0xe373a5d9, 0xe63cb35c, 0xe7fed96b, 0xe5b86732, + 0xe47a0d05, 0xef264a38, 0xeee4200f, 0xeca29e56, 0xed60f461, + 0xe82fe2e4, 0xe9ed88d3, 0xebab368a, 0xea695cbd, 0xfd13b8f0, + 0xfcd1d2c7, 0xfe976c9e, 0xff5506a9, 0xfa1a102c, 0xfbd87a1b, + 0xf99ec442, 0xf85cae75, 0xf300e948, 0xf2c2837f, 0xf0843d26, + 0xf1465711, 0xf4094194, 0xf5cb2ba3, 0xf78d95fa, 0xf64fffcd, + 0xd9785d60, 0xd8ba3757, 0xdafc890e, 0xdb3ee339, 0xde71f5bc, + 0xdfb39f8b, 0xddf521d2, 0xdc374be5, 0xd76b0cd8, 0xd6a966ef, + 0xd4efd8b6, 0xd52db281, 0xd062a404, 0xd1a0ce33, 0xd3e6706a, + 0xd2241a5d, 0xc55efe10, 0xc49c9427, 0xc6da2a7e, 0xc7184049, + 0xc25756cc, 0xc3953cfb, 0xc1d382a2, 0xc011e895, 0xcb4dafa8, + 0xca8fc59f, 0xc8c97bc6, 0xc90b11f1, 0xcc440774, 0xcd866d43, + 0xcfc0d31a, 0xce02b92d, 0x91af9640, 0x906dfc77, 0x922b422e, + 0x93e92819, 0x96a63e9c, 0x976454ab, 0x9522eaf2, 0x94e080c5, + 0x9fbcc7f8, 0x9e7eadcf, 0x9c381396, 0x9dfa79a1, 0x98b56f24, + 0x99770513, 0x9b31bb4a, 0x9af3d17d, 0x8d893530, 0x8c4b5f07, + 0x8e0de15e, 0x8fcf8b69, 0x8a809dec, 0x8b42f7db, 0x89044982, + 0x88c623b5, 0x839a6488, 0x82580ebf, 0x801eb0e6, 0x81dcdad1, + 0x8493cc54, 0x8551a663, 0x8717183a, 0x86d5720d, 0xa9e2d0a0, + 0xa820ba97, 0xaa6604ce, 0xaba46ef9, 0xaeeb787c, 0xaf29124b, + 0xad6fac12, 0xacadc625, 0xa7f18118, 0xa633eb2f, 0xa4755576, + 0xa5b73f41, 0xa0f829c4, 0xa13a43f3, 0xa37cfdaa, 0xa2be979d, + 0xb5c473d0, 0xb40619e7, 0xb640a7be, 0xb782cd89, 0xb2cddb0c, + 0xb30fb13b, 0xb1490f62, 0xb08b6555, 0xbbd72268, 0xba15485f, + 0xb853f606, 0xb9919c31, 0xbcde8ab4, 0xbd1ce083, 0xbf5a5eda, + 0xbe9834ed}, + {0x00000000, 0x191b3141, 0x32366282, 0x2b2d53c3, 0x646cc504, + 0x7d77f445, 0x565aa786, 0x4f4196c7, 0xc8d98a08, 0xd1c2bb49, + 0xfaefe88a, 0xe3f4d9cb, 0xacb54f0c, 0xb5ae7e4d, 0x9e832d8e, + 0x87981ccf, 0x4ac21251, 0x53d92310, 0x78f470d3, 0x61ef4192, + 0x2eaed755, 0x37b5e614, 0x1c98b5d7, 0x05838496, 0x821b9859, + 0x9b00a918, 0xb02dfadb, 0xa936cb9a, 0xe6775d5d, 0xff6c6c1c, + 0xd4413fdf, 0xcd5a0e9e, 0x958424a2, 0x8c9f15e3, 0xa7b24620, + 0xbea97761, 0xf1e8e1a6, 0xe8f3d0e7, 0xc3de8324, 0xdac5b265, + 0x5d5daeaa, 0x44469feb, 0x6f6bcc28, 0x7670fd69, 0x39316bae, + 0x202a5aef, 0x0b07092c, 0x121c386d, 0xdf4636f3, 0xc65d07b2, + 0xed705471, 0xf46b6530, 0xbb2af3f7, 0xa231c2b6, 0x891c9175, + 0x9007a034, 0x179fbcfb, 0x0e848dba, 0x25a9de79, 0x3cb2ef38, + 0x73f379ff, 0x6ae848be, 0x41c51b7d, 0x58de2a3c, 0xf0794f05, + 0xe9627e44, 0xc24f2d87, 0xdb541cc6, 0x94158a01, 0x8d0ebb40, + 0xa623e883, 0xbf38d9c2, 0x38a0c50d, 0x21bbf44c, 0x0a96a78f, + 0x138d96ce, 0x5ccc0009, 0x45d73148, 0x6efa628b, 0x77e153ca, + 0xbabb5d54, 0xa3a06c15, 0x888d3fd6, 0x91960e97, 0xded79850, + 0xc7cca911, 0xece1fad2, 0xf5facb93, 0x7262d75c, 0x6b79e61d, + 0x4054b5de, 0x594f849f, 0x160e1258, 0x0f152319, 0x243870da, + 0x3d23419b, 0x65fd6ba7, 0x7ce65ae6, 0x57cb0925, 0x4ed03864, + 0x0191aea3, 0x188a9fe2, 0x33a7cc21, 0x2abcfd60, 0xad24e1af, + 0xb43fd0ee, 0x9f12832d, 0x8609b26c, 0xc94824ab, 0xd05315ea, + 0xfb7e4629, 0xe2657768, 0x2f3f79f6, 0x362448b7, 0x1d091b74, + 0x04122a35, 0x4b53bcf2, 0x52488db3, 0x7965de70, 0x607eef31, + 0xe7e6f3fe, 0xfefdc2bf, 0xd5d0917c, 0xcccba03d, 0x838a36fa, + 0x9a9107bb, 0xb1bc5478, 0xa8a76539, 0x3b83984b, 0x2298a90a, + 0x09b5fac9, 0x10aecb88, 0x5fef5d4f, 0x46f46c0e, 0x6dd93fcd, + 0x74c20e8c, 0xf35a1243, 0xea412302, 0xc16c70c1, 0xd8774180, + 0x9736d747, 0x8e2de606, 0xa500b5c5, 0xbc1b8484, 0x71418a1a, + 0x685abb5b, 0x4377e898, 0x5a6cd9d9, 0x152d4f1e, 0x0c367e5f, + 0x271b2d9c, 0x3e001cdd, 0xb9980012, 0xa0833153, 0x8bae6290, + 0x92b553d1, 0xddf4c516, 0xc4eff457, 0xefc2a794, 0xf6d996d5, + 0xae07bce9, 0xb71c8da8, 0x9c31de6b, 0x852aef2a, 0xca6b79ed, + 0xd37048ac, 0xf85d1b6f, 0xe1462a2e, 0x66de36e1, 0x7fc507a0, + 0x54e85463, 0x4df36522, 0x02b2f3e5, 0x1ba9c2a4, 0x30849167, + 0x299fa026, 0xe4c5aeb8, 0xfdde9ff9, 0xd6f3cc3a, 0xcfe8fd7b, + 0x80a96bbc, 0x99b25afd, 0xb29f093e, 0xab84387f, 0x2c1c24b0, + 0x350715f1, 0x1e2a4632, 0x07317773, 0x4870e1b4, 0x516bd0f5, + 0x7a468336, 0x635db277, 0xcbfad74e, 0xd2e1e60f, 0xf9ccb5cc, + 0xe0d7848d, 0xaf96124a, 0xb68d230b, 0x9da070c8, 0x84bb4189, + 0x03235d46, 0x1a386c07, 0x31153fc4, 0x280e0e85, 0x674f9842, + 0x7e54a903, 0x5579fac0, 0x4c62cb81, 0x8138c51f, 0x9823f45e, + 0xb30ea79d, 0xaa1596dc, 0xe554001b, 0xfc4f315a, 0xd7626299, + 0xce7953d8, 0x49e14f17, 0x50fa7e56, 0x7bd72d95, 0x62cc1cd4, + 0x2d8d8a13, 0x3496bb52, 0x1fbbe891, 0x06a0d9d0, 0x5e7ef3ec, + 0x4765c2ad, 0x6c48916e, 0x7553a02f, 0x3a1236e8, 0x230907a9, + 0x0824546a, 0x113f652b, 0x96a779e4, 0x8fbc48a5, 0xa4911b66, + 0xbd8a2a27, 0xf2cbbce0, 0xebd08da1, 0xc0fdde62, 0xd9e6ef23, + 0x14bce1bd, 0x0da7d0fc, 0x268a833f, 0x3f91b27e, 0x70d024b9, + 0x69cb15f8, 0x42e6463b, 0x5bfd777a, 0xdc656bb5, 0xc57e5af4, + 0xee530937, 0xf7483876, 0xb809aeb1, 0xa1129ff0, 0x8a3fcc33, + 0x9324fd72}, + {0x00000000, 0x77073096, 0xee0e612c, 0x990951ba, 0x076dc419, + 0x706af48f, 0xe963a535, 0x9e6495a3, 0x0edb8832, 0x79dcb8a4, + 0xe0d5e91e, 0x97d2d988, 0x09b64c2b, 0x7eb17cbd, 0xe7b82d07, + 0x90bf1d91, 0x1db71064, 0x6ab020f2, 0xf3b97148, 0x84be41de, + 0x1adad47d, 0x6ddde4eb, 0xf4d4b551, 0x83d385c7, 0x136c9856, + 0x646ba8c0, 0xfd62f97a, 0x8a65c9ec, 0x14015c4f, 0x63066cd9, + 0xfa0f3d63, 0x8d080df5, 0x3b6e20c8, 0x4c69105e, 0xd56041e4, + 0xa2677172, 0x3c03e4d1, 0x4b04d447, 0xd20d85fd, 0xa50ab56b, + 0x35b5a8fa, 0x42b2986c, 0xdbbbc9d6, 0xacbcf940, 0x32d86ce3, + 0x45df5c75, 0xdcd60dcf, 0xabd13d59, 0x26d930ac, 0x51de003a, + 0xc8d75180, 0xbfd06116, 0x21b4f4b5, 0x56b3c423, 0xcfba9599, + 0xb8bda50f, 0x2802b89e, 0x5f058808, 0xc60cd9b2, 0xb10be924, + 0x2f6f7c87, 0x58684c11, 0xc1611dab, 0xb6662d3d, 0x76dc4190, + 0x01db7106, 0x98d220bc, 0xefd5102a, 0x71b18589, 0x06b6b51f, + 0x9fbfe4a5, 0xe8b8d433, 0x7807c9a2, 0x0f00f934, 0x9609a88e, + 0xe10e9818, 0x7f6a0dbb, 0x086d3d2d, 0x91646c97, 0xe6635c01, + 0x6b6b51f4, 0x1c6c6162, 0x856530d8, 0xf262004e, 0x6c0695ed, + 0x1b01a57b, 0x8208f4c1, 0xf50fc457, 0x65b0d9c6, 0x12b7e950, + 0x8bbeb8ea, 0xfcb9887c, 0x62dd1ddf, 0x15da2d49, 0x8cd37cf3, + 0xfbd44c65, 0x4db26158, 0x3ab551ce, 0xa3bc0074, 0xd4bb30e2, + 0x4adfa541, 0x3dd895d7, 0xa4d1c46d, 0xd3d6f4fb, 0x4369e96a, + 0x346ed9fc, 0xad678846, 0xda60b8d0, 0x44042d73, 0x33031de5, + 0xaa0a4c5f, 0xdd0d7cc9, 0x5005713c, 0x270241aa, 0xbe0b1010, + 0xc90c2086, 0x5768b525, 0x206f85b3, 0xb966d409, 0xce61e49f, + 0x5edef90e, 0x29d9c998, 0xb0d09822, 0xc7d7a8b4, 0x59b33d17, + 0x2eb40d81, 0xb7bd5c3b, 0xc0ba6cad, 0xedb88320, 0x9abfb3b6, + 0x03b6e20c, 0x74b1d29a, 0xead54739, 0x9dd277af, 0x04db2615, + 0x73dc1683, 0xe3630b12, 0x94643b84, 0x0d6d6a3e, 0x7a6a5aa8, + 0xe40ecf0b, 0x9309ff9d, 0x0a00ae27, 0x7d079eb1, 0xf00f9344, + 0x8708a3d2, 0x1e01f268, 0x6906c2fe, 0xf762575d, 0x806567cb, + 0x196c3671, 0x6e6b06e7, 0xfed41b76, 0x89d32be0, 0x10da7a5a, + 0x67dd4acc, 0xf9b9df6f, 0x8ebeeff9, 0x17b7be43, 0x60b08ed5, + 0xd6d6a3e8, 0xa1d1937e, 0x38d8c2c4, 0x4fdff252, 0xd1bb67f1, + 0xa6bc5767, 0x3fb506dd, 0x48b2364b, 0xd80d2bda, 0xaf0a1b4c, + 0x36034af6, 0x41047a60, 0xdf60efc3, 0xa867df55, 0x316e8eef, + 0x4669be79, 0xcb61b38c, 0xbc66831a, 0x256fd2a0, 0x5268e236, + 0xcc0c7795, 0xbb0b4703, 0x220216b9, 0x5505262f, 0xc5ba3bbe, + 0xb2bd0b28, 0x2bb45a92, 0x5cb36a04, 0xc2d7ffa7, 0xb5d0cf31, + 0x2cd99e8b, 0x5bdeae1d, 0x9b64c2b0, 0xec63f226, 0x756aa39c, + 0x026d930a, 0x9c0906a9, 0xeb0e363f, 0x72076785, 0x05005713, + 0x95bf4a82, 0xe2b87a14, 0x7bb12bae, 0x0cb61b38, 0x92d28e9b, + 0xe5d5be0d, 0x7cdcefb7, 0x0bdbdf21, 0x86d3d2d4, 0xf1d4e242, + 0x68ddb3f8, 0x1fda836e, 0x81be16cd, 0xf6b9265b, 0x6fb077e1, + 0x18b74777, 0x88085ae6, 0xff0f6a70, 0x66063bca, 0x11010b5c, + 0x8f659eff, 0xf862ae69, 0x616bffd3, 0x166ccf45, 0xa00ae278, + 0xd70dd2ee, 0x4e048354, 0x3903b3c2, 0xa7672661, 0xd06016f7, + 0x4969474d, 0x3e6e77db, 0xaed16a4a, 0xd9d65adc, 0x40df0b66, + 0x37d83bf0, 0xa9bcae53, 0xdebb9ec5, 0x47b2cf7f, 0x30b5ffe9, + 0xbdbdf21c, 0xcabac28a, 0x53b39330, 0x24b4a3a6, 0xbad03605, + 0xcdd70693, 0x54de5729, 0x23d967bf, 0xb3667a2e, 0xc4614ab8, + 0x5d681b02, 0x2a6f2b94, 0xb40bbe37, 0xc30c8ea1, 0x5a05df1b, + 0x2d02ef8d}}; + +local const z_word_t FAR crc_braid_big_table[][256] = { + {0x0000000000000000, 0x9630077700000000, 0x2c610eee00000000, + 0xba51099900000000, 0x19c46d0700000000, 0x8ff46a7000000000, + 0x35a563e900000000, 0xa395649e00000000, 0x3288db0e00000000, + 0xa4b8dc7900000000, 0x1ee9d5e000000000, 0x88d9d29700000000, + 0x2b4cb60900000000, 0xbd7cb17e00000000, 0x072db8e700000000, + 0x911dbf9000000000, 0x6410b71d00000000, 0xf220b06a00000000, + 0x4871b9f300000000, 0xde41be8400000000, 0x7dd4da1a00000000, + 0xebe4dd6d00000000, 0x51b5d4f400000000, 0xc785d38300000000, + 0x56986c1300000000, 0xc0a86b6400000000, 0x7af962fd00000000, + 0xecc9658a00000000, 0x4f5c011400000000, 0xd96c066300000000, + 0x633d0ffa00000000, 0xf50d088d00000000, 0xc8206e3b00000000, + 0x5e10694c00000000, 0xe44160d500000000, 0x727167a200000000, + 0xd1e4033c00000000, 0x47d4044b00000000, 0xfd850dd200000000, + 0x6bb50aa500000000, 0xfaa8b53500000000, 0x6c98b24200000000, + 0xd6c9bbdb00000000, 0x40f9bcac00000000, 0xe36cd83200000000, + 0x755cdf4500000000, 0xcf0dd6dc00000000, 0x593dd1ab00000000, + 0xac30d92600000000, 0x3a00de5100000000, 0x8051d7c800000000, + 0x1661d0bf00000000, 0xb5f4b42100000000, 0x23c4b35600000000, + 0x9995bacf00000000, 0x0fa5bdb800000000, 0x9eb8022800000000, + 0x0888055f00000000, 0xb2d90cc600000000, 0x24e90bb100000000, + 0x877c6f2f00000000, 0x114c685800000000, 0xab1d61c100000000, + 0x3d2d66b600000000, 0x9041dc7600000000, 0x0671db0100000000, + 0xbc20d29800000000, 0x2a10d5ef00000000, 0x8985b17100000000, + 0x1fb5b60600000000, 0xa5e4bf9f00000000, 0x33d4b8e800000000, + 0xa2c9077800000000, 0x34f9000f00000000, 0x8ea8099600000000, + 0x18980ee100000000, 0xbb0d6a7f00000000, 0x2d3d6d0800000000, + 0x976c649100000000, 0x015c63e600000000, 0xf4516b6b00000000, + 0x62616c1c00000000, 0xd830658500000000, 0x4e0062f200000000, + 0xed95066c00000000, 0x7ba5011b00000000, 0xc1f4088200000000, + 0x57c40ff500000000, 0xc6d9b06500000000, 0x50e9b71200000000, + 0xeab8be8b00000000, 0x7c88b9fc00000000, 0xdf1ddd6200000000, + 0x492dda1500000000, 0xf37cd38c00000000, 0x654cd4fb00000000, + 0x5861b24d00000000, 0xce51b53a00000000, 0x7400bca300000000, + 0xe230bbd400000000, 0x41a5df4a00000000, 0xd795d83d00000000, + 0x6dc4d1a400000000, 0xfbf4d6d300000000, 0x6ae9694300000000, + 0xfcd96e3400000000, 0x468867ad00000000, 0xd0b860da00000000, + 0x732d044400000000, 0xe51d033300000000, 0x5f4c0aaa00000000, + 0xc97c0ddd00000000, 0x3c71055000000000, 0xaa41022700000000, + 0x10100bbe00000000, 0x86200cc900000000, 0x25b5685700000000, + 0xb3856f2000000000, 0x09d466b900000000, 0x9fe461ce00000000, + 0x0ef9de5e00000000, 0x98c9d92900000000, 0x2298d0b000000000, + 0xb4a8d7c700000000, 0x173db35900000000, 0x810db42e00000000, + 0x3b5cbdb700000000, 0xad6cbac000000000, 0x2083b8ed00000000, + 0xb6b3bf9a00000000, 0x0ce2b60300000000, 0x9ad2b17400000000, + 0x3947d5ea00000000, 0xaf77d29d00000000, 0x1526db0400000000, + 0x8316dc7300000000, 0x120b63e300000000, 0x843b649400000000, + 0x3e6a6d0d00000000, 0xa85a6a7a00000000, 0x0bcf0ee400000000, + 0x9dff099300000000, 0x27ae000a00000000, 0xb19e077d00000000, + 0x44930ff000000000, 0xd2a3088700000000, 0x68f2011e00000000, + 0xfec2066900000000, 0x5d5762f700000000, 0xcb67658000000000, + 0x71366c1900000000, 0xe7066b6e00000000, 0x761bd4fe00000000, + 0xe02bd38900000000, 0x5a7ada1000000000, 0xcc4add6700000000, + 0x6fdfb9f900000000, 0xf9efbe8e00000000, 0x43beb71700000000, + 0xd58eb06000000000, 0xe8a3d6d600000000, 0x7e93d1a100000000, + 0xc4c2d83800000000, 0x52f2df4f00000000, 0xf167bbd100000000, + 0x6757bca600000000, 0xdd06b53f00000000, 0x4b36b24800000000, + 0xda2b0dd800000000, 0x4c1b0aaf00000000, 0xf64a033600000000, + 0x607a044100000000, 0xc3ef60df00000000, 0x55df67a800000000, + 0xef8e6e3100000000, 0x79be694600000000, 0x8cb361cb00000000, + 0x1a8366bc00000000, 0xa0d26f2500000000, 0x36e2685200000000, + 0x95770ccc00000000, 0x03470bbb00000000, 0xb916022200000000, + 0x2f26055500000000, 0xbe3bbac500000000, 0x280bbdb200000000, + 0x925ab42b00000000, 0x046ab35c00000000, 0xa7ffd7c200000000, + 0x31cfd0b500000000, 0x8b9ed92c00000000, 0x1daede5b00000000, + 0xb0c2649b00000000, 0x26f263ec00000000, 0x9ca36a7500000000, + 0x0a936d0200000000, 0xa906099c00000000, 0x3f360eeb00000000, + 0x8567077200000000, 0x1357000500000000, 0x824abf9500000000, + 0x147ab8e200000000, 0xae2bb17b00000000, 0x381bb60c00000000, + 0x9b8ed29200000000, 0x0dbed5e500000000, 0xb7efdc7c00000000, + 0x21dfdb0b00000000, 0xd4d2d38600000000, 0x42e2d4f100000000, + 0xf8b3dd6800000000, 0x6e83da1f00000000, 0xcd16be8100000000, + 0x5b26b9f600000000, 0xe177b06f00000000, 0x7747b71800000000, + 0xe65a088800000000, 0x706a0fff00000000, 0xca3b066600000000, + 0x5c0b011100000000, 0xff9e658f00000000, 0x69ae62f800000000, + 0xd3ff6b6100000000, 0x45cf6c1600000000, 0x78e20aa000000000, + 0xeed20dd700000000, 0x5483044e00000000, 0xc2b3033900000000, + 0x612667a700000000, 0xf71660d000000000, 0x4d47694900000000, + 0xdb776e3e00000000, 0x4a6ad1ae00000000, 0xdc5ad6d900000000, + 0x660bdf4000000000, 0xf03bd83700000000, 0x53aebca900000000, + 0xc59ebbde00000000, 0x7fcfb24700000000, 0xe9ffb53000000000, + 0x1cf2bdbd00000000, 0x8ac2baca00000000, 0x3093b35300000000, + 0xa6a3b42400000000, 0x0536d0ba00000000, 0x9306d7cd00000000, + 0x2957de5400000000, 0xbf67d92300000000, 0x2e7a66b300000000, + 0xb84a61c400000000, 0x021b685d00000000, 0x942b6f2a00000000, + 0x37be0bb400000000, 0xa18e0cc300000000, 0x1bdf055a00000000, + 0x8def022d00000000}, + {0x0000000000000000, 0x41311b1900000000, 0x8262363200000000, + 0xc3532d2b00000000, 0x04c56c6400000000, 0x45f4777d00000000, + 0x86a75a5600000000, 0xc796414f00000000, 0x088ad9c800000000, + 0x49bbc2d100000000, 0x8ae8effa00000000, 0xcbd9f4e300000000, + 0x0c4fb5ac00000000, 0x4d7eaeb500000000, 0x8e2d839e00000000, + 0xcf1c988700000000, 0x5112c24a00000000, 0x1023d95300000000, + 0xd370f47800000000, 0x9241ef6100000000, 0x55d7ae2e00000000, + 0x14e6b53700000000, 0xd7b5981c00000000, 0x9684830500000000, + 0x59981b8200000000, 0x18a9009b00000000, 0xdbfa2db000000000, + 0x9acb36a900000000, 0x5d5d77e600000000, 0x1c6c6cff00000000, + 0xdf3f41d400000000, 0x9e0e5acd00000000, 0xa224849500000000, + 0xe3159f8c00000000, 0x2046b2a700000000, 0x6177a9be00000000, + 0xa6e1e8f100000000, 0xe7d0f3e800000000, 0x2483dec300000000, + 0x65b2c5da00000000, 0xaaae5d5d00000000, 0xeb9f464400000000, + 0x28cc6b6f00000000, 0x69fd707600000000, 0xae6b313900000000, + 0xef5a2a2000000000, 0x2c09070b00000000, 0x6d381c1200000000, + 0xf33646df00000000, 0xb2075dc600000000, 0x715470ed00000000, + 0x30656bf400000000, 0xf7f32abb00000000, 0xb6c231a200000000, + 0x75911c8900000000, 0x34a0079000000000, 0xfbbc9f1700000000, + 0xba8d840e00000000, 0x79dea92500000000, 0x38efb23c00000000, + 0xff79f37300000000, 0xbe48e86a00000000, 0x7d1bc54100000000, + 0x3c2ade5800000000, 0x054f79f000000000, 0x447e62e900000000, + 0x872d4fc200000000, 0xc61c54db00000000, 0x018a159400000000, + 0x40bb0e8d00000000, 0x83e823a600000000, 0xc2d938bf00000000, + 0x0dc5a03800000000, 0x4cf4bb2100000000, 0x8fa7960a00000000, + 0xce968d1300000000, 0x0900cc5c00000000, 0x4831d74500000000, + 0x8b62fa6e00000000, 0xca53e17700000000, 0x545dbbba00000000, + 0x156ca0a300000000, 0xd63f8d8800000000, 0x970e969100000000, + 0x5098d7de00000000, 0x11a9ccc700000000, 0xd2fae1ec00000000, + 0x93cbfaf500000000, 0x5cd7627200000000, 0x1de6796b00000000, + 0xdeb5544000000000, 0x9f844f5900000000, 0x58120e1600000000, + 0x1923150f00000000, 0xda70382400000000, 0x9b41233d00000000, + 0xa76bfd6500000000, 0xe65ae67c00000000, 0x2509cb5700000000, + 0x6438d04e00000000, 0xa3ae910100000000, 0xe29f8a1800000000, + 0x21cca73300000000, 0x60fdbc2a00000000, 0xafe124ad00000000, + 0xeed03fb400000000, 0x2d83129f00000000, 0x6cb2098600000000, + 0xab2448c900000000, 0xea1553d000000000, 0x29467efb00000000, + 0x687765e200000000, 0xf6793f2f00000000, 0xb748243600000000, + 0x741b091d00000000, 0x352a120400000000, 0xf2bc534b00000000, + 0xb38d485200000000, 0x70de657900000000, 0x31ef7e6000000000, + 0xfef3e6e700000000, 0xbfc2fdfe00000000, 0x7c91d0d500000000, + 0x3da0cbcc00000000, 0xfa368a8300000000, 0xbb07919a00000000, + 0x7854bcb100000000, 0x3965a7a800000000, 0x4b98833b00000000, + 0x0aa9982200000000, 0xc9fab50900000000, 0x88cbae1000000000, + 0x4f5def5f00000000, 0x0e6cf44600000000, 0xcd3fd96d00000000, + 0x8c0ec27400000000, 0x43125af300000000, 0x022341ea00000000, + 0xc1706cc100000000, 0x804177d800000000, 0x47d7369700000000, + 0x06e62d8e00000000, 0xc5b500a500000000, 0x84841bbc00000000, + 0x1a8a417100000000, 0x5bbb5a6800000000, 0x98e8774300000000, + 0xd9d96c5a00000000, 0x1e4f2d1500000000, 0x5f7e360c00000000, + 0x9c2d1b2700000000, 0xdd1c003e00000000, 0x120098b900000000, + 0x533183a000000000, 0x9062ae8b00000000, 0xd153b59200000000, + 0x16c5f4dd00000000, 0x57f4efc400000000, 0x94a7c2ef00000000, + 0xd596d9f600000000, 0xe9bc07ae00000000, 0xa88d1cb700000000, + 0x6bde319c00000000, 0x2aef2a8500000000, 0xed796bca00000000, + 0xac4870d300000000, 0x6f1b5df800000000, 0x2e2a46e100000000, + 0xe136de6600000000, 0xa007c57f00000000, 0x6354e85400000000, + 0x2265f34d00000000, 0xe5f3b20200000000, 0xa4c2a91b00000000, + 0x6791843000000000, 0x26a09f2900000000, 0xb8aec5e400000000, + 0xf99fdefd00000000, 0x3accf3d600000000, 0x7bfde8cf00000000, + 0xbc6ba98000000000, 0xfd5ab29900000000, 0x3e099fb200000000, + 0x7f3884ab00000000, 0xb0241c2c00000000, 0xf115073500000000, + 0x32462a1e00000000, 0x7377310700000000, 0xb4e1704800000000, + 0xf5d06b5100000000, 0x3683467a00000000, 0x77b25d6300000000, + 0x4ed7facb00000000, 0x0fe6e1d200000000, 0xccb5ccf900000000, + 0x8d84d7e000000000, 0x4a1296af00000000, 0x0b238db600000000, + 0xc870a09d00000000, 0x8941bb8400000000, 0x465d230300000000, + 0x076c381a00000000, 0xc43f153100000000, 0x850e0e2800000000, + 0x42984f6700000000, 0x03a9547e00000000, 0xc0fa795500000000, + 0x81cb624c00000000, 0x1fc5388100000000, 0x5ef4239800000000, + 0x9da70eb300000000, 0xdc9615aa00000000, 0x1b0054e500000000, + 0x5a314ffc00000000, 0x996262d700000000, 0xd85379ce00000000, + 0x174fe14900000000, 0x567efa5000000000, 0x952dd77b00000000, + 0xd41ccc6200000000, 0x138a8d2d00000000, 0x52bb963400000000, + 0x91e8bb1f00000000, 0xd0d9a00600000000, 0xecf37e5e00000000, + 0xadc2654700000000, 0x6e91486c00000000, 0x2fa0537500000000, + 0xe836123a00000000, 0xa907092300000000, 0x6a54240800000000, + 0x2b653f1100000000, 0xe479a79600000000, 0xa548bc8f00000000, + 0x661b91a400000000, 0x272a8abd00000000, 0xe0bccbf200000000, + 0xa18dd0eb00000000, 0x62defdc000000000, 0x23efe6d900000000, + 0xbde1bc1400000000, 0xfcd0a70d00000000, 0x3f838a2600000000, + 0x7eb2913f00000000, 0xb924d07000000000, 0xf815cb6900000000, + 0x3b46e64200000000, 0x7a77fd5b00000000, 0xb56b65dc00000000, + 0xf45a7ec500000000, 0x370953ee00000000, 0x763848f700000000, + 0xb1ae09b800000000, 0xf09f12a100000000, 0x33cc3f8a00000000, + 0x72fd249300000000}, + {0x0000000000000000, 0x376ac20100000000, 0x6ed4840300000000, + 0x59be460200000000, 0xdca8090700000000, 0xebc2cb0600000000, + 0xb27c8d0400000000, 0x85164f0500000000, 0xb851130e00000000, + 0x8f3bd10f00000000, 0xd685970d00000000, 0xe1ef550c00000000, + 0x64f91a0900000000, 0x5393d80800000000, 0x0a2d9e0a00000000, + 0x3d475c0b00000000, 0x70a3261c00000000, 0x47c9e41d00000000, + 0x1e77a21f00000000, 0x291d601e00000000, 0xac0b2f1b00000000, + 0x9b61ed1a00000000, 0xc2dfab1800000000, 0xf5b5691900000000, + 0xc8f2351200000000, 0xff98f71300000000, 0xa626b11100000000, + 0x914c731000000000, 0x145a3c1500000000, 0x2330fe1400000000, + 0x7a8eb81600000000, 0x4de47a1700000000, 0xe0464d3800000000, + 0xd72c8f3900000000, 0x8e92c93b00000000, 0xb9f80b3a00000000, + 0x3cee443f00000000, 0x0b84863e00000000, 0x523ac03c00000000, + 0x6550023d00000000, 0x58175e3600000000, 0x6f7d9c3700000000, + 0x36c3da3500000000, 0x01a9183400000000, 0x84bf573100000000, + 0xb3d5953000000000, 0xea6bd33200000000, 0xdd01113300000000, + 0x90e56b2400000000, 0xa78fa92500000000, 0xfe31ef2700000000, + 0xc95b2d2600000000, 0x4c4d622300000000, 0x7b27a02200000000, + 0x2299e62000000000, 0x15f3242100000000, 0x28b4782a00000000, + 0x1fdeba2b00000000, 0x4660fc2900000000, 0x710a3e2800000000, + 0xf41c712d00000000, 0xc376b32c00000000, 0x9ac8f52e00000000, + 0xada2372f00000000, 0xc08d9a7000000000, 0xf7e7587100000000, + 0xae591e7300000000, 0x9933dc7200000000, 0x1c25937700000000, + 0x2b4f517600000000, 0x72f1177400000000, 0x459bd57500000000, + 0x78dc897e00000000, 0x4fb64b7f00000000, 0x16080d7d00000000, + 0x2162cf7c00000000, 0xa474807900000000, 0x931e427800000000, + 0xcaa0047a00000000, 0xfdcac67b00000000, 0xb02ebc6c00000000, + 0x87447e6d00000000, 0xdefa386f00000000, 0xe990fa6e00000000, + 0x6c86b56b00000000, 0x5bec776a00000000, 0x0252316800000000, + 0x3538f36900000000, 0x087faf6200000000, 0x3f156d6300000000, + 0x66ab2b6100000000, 0x51c1e96000000000, 0xd4d7a66500000000, + 0xe3bd646400000000, 0xba03226600000000, 0x8d69e06700000000, + 0x20cbd74800000000, 0x17a1154900000000, 0x4e1f534b00000000, + 0x7975914a00000000, 0xfc63de4f00000000, 0xcb091c4e00000000, + 0x92b75a4c00000000, 0xa5dd984d00000000, 0x989ac44600000000, + 0xaff0064700000000, 0xf64e404500000000, 0xc124824400000000, + 0x4432cd4100000000, 0x73580f4000000000, 0x2ae6494200000000, + 0x1d8c8b4300000000, 0x5068f15400000000, 0x6702335500000000, + 0x3ebc755700000000, 0x09d6b75600000000, 0x8cc0f85300000000, + 0xbbaa3a5200000000, 0xe2147c5000000000, 0xd57ebe5100000000, + 0xe839e25a00000000, 0xdf53205b00000000, 0x86ed665900000000, + 0xb187a45800000000, 0x3491eb5d00000000, 0x03fb295c00000000, + 0x5a456f5e00000000, 0x6d2fad5f00000000, 0x801b35e100000000, + 0xb771f7e000000000, 0xeecfb1e200000000, 0xd9a573e300000000, + 0x5cb33ce600000000, 0x6bd9fee700000000, 0x3267b8e500000000, + 0x050d7ae400000000, 0x384a26ef00000000, 0x0f20e4ee00000000, + 0x569ea2ec00000000, 0x61f460ed00000000, 0xe4e22fe800000000, + 0xd388ede900000000, 0x8a36abeb00000000, 0xbd5c69ea00000000, + 0xf0b813fd00000000, 0xc7d2d1fc00000000, 0x9e6c97fe00000000, + 0xa90655ff00000000, 0x2c101afa00000000, 0x1b7ad8fb00000000, + 0x42c49ef900000000, 0x75ae5cf800000000, 0x48e900f300000000, + 0x7f83c2f200000000, 0x263d84f000000000, 0x115746f100000000, + 0x944109f400000000, 0xa32bcbf500000000, 0xfa958df700000000, + 0xcdff4ff600000000, 0x605d78d900000000, 0x5737bad800000000, + 0x0e89fcda00000000, 0x39e33edb00000000, 0xbcf571de00000000, + 0x8b9fb3df00000000, 0xd221f5dd00000000, 0xe54b37dc00000000, + 0xd80c6bd700000000, 0xef66a9d600000000, 0xb6d8efd400000000, + 0x81b22dd500000000, 0x04a462d000000000, 0x33cea0d100000000, + 0x6a70e6d300000000, 0x5d1a24d200000000, 0x10fe5ec500000000, + 0x27949cc400000000, 0x7e2adac600000000, 0x494018c700000000, + 0xcc5657c200000000, 0xfb3c95c300000000, 0xa282d3c100000000, + 0x95e811c000000000, 0xa8af4dcb00000000, 0x9fc58fca00000000, + 0xc67bc9c800000000, 0xf1110bc900000000, 0x740744cc00000000, + 0x436d86cd00000000, 0x1ad3c0cf00000000, 0x2db902ce00000000, + 0x4096af9100000000, 0x77fc6d9000000000, 0x2e422b9200000000, + 0x1928e99300000000, 0x9c3ea69600000000, 0xab54649700000000, + 0xf2ea229500000000, 0xc580e09400000000, 0xf8c7bc9f00000000, + 0xcfad7e9e00000000, 0x9613389c00000000, 0xa179fa9d00000000, + 0x246fb59800000000, 0x1305779900000000, 0x4abb319b00000000, + 0x7dd1f39a00000000, 0x3035898d00000000, 0x075f4b8c00000000, + 0x5ee10d8e00000000, 0x698bcf8f00000000, 0xec9d808a00000000, + 0xdbf7428b00000000, 0x8249048900000000, 0xb523c68800000000, + 0x88649a8300000000, 0xbf0e588200000000, 0xe6b01e8000000000, + 0xd1dadc8100000000, 0x54cc938400000000, 0x63a6518500000000, + 0x3a18178700000000, 0x0d72d58600000000, 0xa0d0e2a900000000, + 0x97ba20a800000000, 0xce0466aa00000000, 0xf96ea4ab00000000, + 0x7c78ebae00000000, 0x4b1229af00000000, 0x12ac6fad00000000, + 0x25c6adac00000000, 0x1881f1a700000000, 0x2feb33a600000000, + 0x765575a400000000, 0x413fb7a500000000, 0xc429f8a000000000, + 0xf3433aa100000000, 0xaafd7ca300000000, 0x9d97bea200000000, + 0xd073c4b500000000, 0xe71906b400000000, 0xbea740b600000000, + 0x89cd82b700000000, 0x0cdbcdb200000000, 0x3bb10fb300000000, + 0x620f49b100000000, 0x55658bb000000000, 0x6822d7bb00000000, + 0x5f4815ba00000000, 0x06f653b800000000, 0x319c91b900000000, + 0xb48adebc00000000, 0x83e01cbd00000000, 0xda5e5abf00000000, + 0xed3498be00000000}, + {0x0000000000000000, 0x6567bcb800000000, 0x8bc809aa00000000, + 0xeeafb51200000000, 0x5797628f00000000, 0x32f0de3700000000, + 0xdc5f6b2500000000, 0xb938d79d00000000, 0xef28b4c500000000, + 0x8a4f087d00000000, 0x64e0bd6f00000000, 0x018701d700000000, + 0xb8bfd64a00000000, 0xddd86af200000000, 0x3377dfe000000000, + 0x5610635800000000, 0x9f57195000000000, 0xfa30a5e800000000, + 0x149f10fa00000000, 0x71f8ac4200000000, 0xc8c07bdf00000000, + 0xada7c76700000000, 0x4308727500000000, 0x266fcecd00000000, + 0x707fad9500000000, 0x1518112d00000000, 0xfbb7a43f00000000, + 0x9ed0188700000000, 0x27e8cf1a00000000, 0x428f73a200000000, + 0xac20c6b000000000, 0xc9477a0800000000, 0x3eaf32a000000000, + 0x5bc88e1800000000, 0xb5673b0a00000000, 0xd00087b200000000, + 0x6938502f00000000, 0x0c5fec9700000000, 0xe2f0598500000000, + 0x8797e53d00000000, 0xd187866500000000, 0xb4e03add00000000, + 0x5a4f8fcf00000000, 0x3f28337700000000, 0x8610e4ea00000000, + 0xe377585200000000, 0x0dd8ed4000000000, 0x68bf51f800000000, + 0xa1f82bf000000000, 0xc49f974800000000, 0x2a30225a00000000, + 0x4f579ee200000000, 0xf66f497f00000000, 0x9308f5c700000000, + 0x7da740d500000000, 0x18c0fc6d00000000, 0x4ed09f3500000000, + 0x2bb7238d00000000, 0xc518969f00000000, 0xa07f2a2700000000, + 0x1947fdba00000000, 0x7c20410200000000, 0x928ff41000000000, + 0xf7e848a800000000, 0x3d58149b00000000, 0x583fa82300000000, + 0xb6901d3100000000, 0xd3f7a18900000000, 0x6acf761400000000, + 0x0fa8caac00000000, 0xe1077fbe00000000, 0x8460c30600000000, + 0xd270a05e00000000, 0xb7171ce600000000, 0x59b8a9f400000000, + 0x3cdf154c00000000, 0x85e7c2d100000000, 0xe0807e6900000000, + 0x0e2fcb7b00000000, 0x6b4877c300000000, 0xa20f0dcb00000000, + 0xc768b17300000000, 0x29c7046100000000, 0x4ca0b8d900000000, + 0xf5986f4400000000, 0x90ffd3fc00000000, 0x7e5066ee00000000, + 0x1b37da5600000000, 0x4d27b90e00000000, 0x284005b600000000, + 0xc6efb0a400000000, 0xa3880c1c00000000, 0x1ab0db8100000000, + 0x7fd7673900000000, 0x9178d22b00000000, 0xf41f6e9300000000, + 0x03f7263b00000000, 0x66909a8300000000, 0x883f2f9100000000, + 0xed58932900000000, 0x546044b400000000, 0x3107f80c00000000, + 0xdfa84d1e00000000, 0xbacff1a600000000, 0xecdf92fe00000000, + 0x89b82e4600000000, 0x67179b5400000000, 0x027027ec00000000, + 0xbb48f07100000000, 0xde2f4cc900000000, 0x3080f9db00000000, + 0x55e7456300000000, 0x9ca03f6b00000000, 0xf9c783d300000000, + 0x176836c100000000, 0x720f8a7900000000, 0xcb375de400000000, + 0xae50e15c00000000, 0x40ff544e00000000, 0x2598e8f600000000, + 0x73888bae00000000, 0x16ef371600000000, 0xf840820400000000, + 0x9d273ebc00000000, 0x241fe92100000000, 0x4178559900000000, + 0xafd7e08b00000000, 0xcab05c3300000000, 0x3bb659ed00000000, + 0x5ed1e55500000000, 0xb07e504700000000, 0xd519ecff00000000, + 0x6c213b6200000000, 0x094687da00000000, 0xe7e932c800000000, + 0x828e8e7000000000, 0xd49eed2800000000, 0xb1f9519000000000, + 0x5f56e48200000000, 0x3a31583a00000000, 0x83098fa700000000, + 0xe66e331f00000000, 0x08c1860d00000000, 0x6da63ab500000000, + 0xa4e140bd00000000, 0xc186fc0500000000, 0x2f29491700000000, + 0x4a4ef5af00000000, 0xf376223200000000, 0x96119e8a00000000, + 0x78be2b9800000000, 0x1dd9972000000000, 0x4bc9f47800000000, + 0x2eae48c000000000, 0xc001fdd200000000, 0xa566416a00000000, + 0x1c5e96f700000000, 0x79392a4f00000000, 0x97969f5d00000000, + 0xf2f123e500000000, 0x05196b4d00000000, 0x607ed7f500000000, + 0x8ed162e700000000, 0xebb6de5f00000000, 0x528e09c200000000, + 0x37e9b57a00000000, 0xd946006800000000, 0xbc21bcd000000000, + 0xea31df8800000000, 0x8f56633000000000, 0x61f9d62200000000, + 0x049e6a9a00000000, 0xbda6bd0700000000, 0xd8c101bf00000000, + 0x366eb4ad00000000, 0x5309081500000000, 0x9a4e721d00000000, + 0xff29cea500000000, 0x11867bb700000000, 0x74e1c70f00000000, + 0xcdd9109200000000, 0xa8beac2a00000000, 0x4611193800000000, + 0x2376a58000000000, 0x7566c6d800000000, 0x10017a6000000000, + 0xfeaecf7200000000, 0x9bc973ca00000000, 0x22f1a45700000000, + 0x479618ef00000000, 0xa939adfd00000000, 0xcc5e114500000000, + 0x06ee4d7600000000, 0x6389f1ce00000000, 0x8d2644dc00000000, + 0xe841f86400000000, 0x51792ff900000000, 0x341e934100000000, + 0xdab1265300000000, 0xbfd69aeb00000000, 0xe9c6f9b300000000, + 0x8ca1450b00000000, 0x620ef01900000000, 0x07694ca100000000, + 0xbe519b3c00000000, 0xdb36278400000000, 0x3599929600000000, + 0x50fe2e2e00000000, 0x99b9542600000000, 0xfcdee89e00000000, + 0x12715d8c00000000, 0x7716e13400000000, 0xce2e36a900000000, + 0xab498a1100000000, 0x45e63f0300000000, 0x208183bb00000000, + 0x7691e0e300000000, 0x13f65c5b00000000, 0xfd59e94900000000, + 0x983e55f100000000, 0x2106826c00000000, 0x44613ed400000000, + 0xaace8bc600000000, 0xcfa9377e00000000, 0x38417fd600000000, + 0x5d26c36e00000000, 0xb389767c00000000, 0xd6eecac400000000, + 0x6fd61d5900000000, 0x0ab1a1e100000000, 0xe41e14f300000000, + 0x8179a84b00000000, 0xd769cb1300000000, 0xb20e77ab00000000, + 0x5ca1c2b900000000, 0x39c67e0100000000, 0x80fea99c00000000, + 0xe599152400000000, 0x0b36a03600000000, 0x6e511c8e00000000, + 0xa716668600000000, 0xc271da3e00000000, 0x2cde6f2c00000000, + 0x49b9d39400000000, 0xf081040900000000, 0x95e6b8b100000000, + 0x7b490da300000000, 0x1e2eb11b00000000, 0x483ed24300000000, + 0x2d596efb00000000, 0xc3f6dbe900000000, 0xa691675100000000, + 0x1fa9b0cc00000000, 0x7ace0c7400000000, 0x9461b96600000000, + 0xf10605de00000000}, + {0x0000000000000000, 0xb029603d00000000, 0x6053c07a00000000, + 0xd07aa04700000000, 0xc0a680f500000000, 0x708fe0c800000000, + 0xa0f5408f00000000, 0x10dc20b200000000, 0xc14b703000000000, + 0x7162100d00000000, 0xa118b04a00000000, 0x1131d07700000000, + 0x01edf0c500000000, 0xb1c490f800000000, 0x61be30bf00000000, + 0xd197508200000000, 0x8297e06000000000, 0x32be805d00000000, + 0xe2c4201a00000000, 0x52ed402700000000, 0x4231609500000000, + 0xf21800a800000000, 0x2262a0ef00000000, 0x924bc0d200000000, + 0x43dc905000000000, 0xf3f5f06d00000000, 0x238f502a00000000, + 0x93a6301700000000, 0x837a10a500000000, 0x3353709800000000, + 0xe329d0df00000000, 0x5300b0e200000000, 0x042fc1c100000000, + 0xb406a1fc00000000, 0x647c01bb00000000, 0xd455618600000000, + 0xc489413400000000, 0x74a0210900000000, 0xa4da814e00000000, + 0x14f3e17300000000, 0xc564b1f100000000, 0x754dd1cc00000000, + 0xa537718b00000000, 0x151e11b600000000, 0x05c2310400000000, + 0xb5eb513900000000, 0x6591f17e00000000, 0xd5b8914300000000, + 0x86b821a100000000, 0x3691419c00000000, 0xe6ebe1db00000000, + 0x56c281e600000000, 0x461ea15400000000, 0xf637c16900000000, + 0x264d612e00000000, 0x9664011300000000, 0x47f3519100000000, + 0xf7da31ac00000000, 0x27a091eb00000000, 0x9789f1d600000000, + 0x8755d16400000000, 0x377cb15900000000, 0xe706111e00000000, + 0x572f712300000000, 0x4958f35800000000, 0xf971936500000000, + 0x290b332200000000, 0x9922531f00000000, 0x89fe73ad00000000, + 0x39d7139000000000, 0xe9adb3d700000000, 0x5984d3ea00000000, + 0x8813836800000000, 0x383ae35500000000, 0xe840431200000000, + 0x5869232f00000000, 0x48b5039d00000000, 0xf89c63a000000000, + 0x28e6c3e700000000, 0x98cfa3da00000000, 0xcbcf133800000000, + 0x7be6730500000000, 0xab9cd34200000000, 0x1bb5b37f00000000, + 0x0b6993cd00000000, 0xbb40f3f000000000, 0x6b3a53b700000000, + 0xdb13338a00000000, 0x0a84630800000000, 0xbaad033500000000, + 0x6ad7a37200000000, 0xdafec34f00000000, 0xca22e3fd00000000, + 0x7a0b83c000000000, 0xaa71238700000000, 0x1a5843ba00000000, + 0x4d77329900000000, 0xfd5e52a400000000, 0x2d24f2e300000000, + 0x9d0d92de00000000, 0x8dd1b26c00000000, 0x3df8d25100000000, + 0xed82721600000000, 0x5dab122b00000000, 0x8c3c42a900000000, + 0x3c15229400000000, 0xec6f82d300000000, 0x5c46e2ee00000000, + 0x4c9ac25c00000000, 0xfcb3a26100000000, 0x2cc9022600000000, + 0x9ce0621b00000000, 0xcfe0d2f900000000, 0x7fc9b2c400000000, + 0xafb3128300000000, 0x1f9a72be00000000, 0x0f46520c00000000, + 0xbf6f323100000000, 0x6f15927600000000, 0xdf3cf24b00000000, + 0x0eaba2c900000000, 0xbe82c2f400000000, 0x6ef862b300000000, + 0xded1028e00000000, 0xce0d223c00000000, 0x7e24420100000000, + 0xae5ee24600000000, 0x1e77827b00000000, 0x92b0e6b100000000, + 0x2299868c00000000, 0xf2e326cb00000000, 0x42ca46f600000000, + 0x5216664400000000, 0xe23f067900000000, 0x3245a63e00000000, + 0x826cc60300000000, 0x53fb968100000000, 0xe3d2f6bc00000000, + 0x33a856fb00000000, 0x838136c600000000, 0x935d167400000000, + 0x2374764900000000, 0xf30ed60e00000000, 0x4327b63300000000, + 0x102706d100000000, 0xa00e66ec00000000, 0x7074c6ab00000000, + 0xc05da69600000000, 0xd081862400000000, 0x60a8e61900000000, + 0xb0d2465e00000000, 0x00fb266300000000, 0xd16c76e100000000, + 0x614516dc00000000, 0xb13fb69b00000000, 0x0116d6a600000000, + 0x11caf61400000000, 0xa1e3962900000000, 0x7199366e00000000, + 0xc1b0565300000000, 0x969f277000000000, 0x26b6474d00000000, + 0xf6cce70a00000000, 0x46e5873700000000, 0x5639a78500000000, + 0xe610c7b800000000, 0x366a67ff00000000, 0x864307c200000000, + 0x57d4574000000000, 0xe7fd377d00000000, 0x3787973a00000000, + 0x87aef70700000000, 0x9772d7b500000000, 0x275bb78800000000, + 0xf72117cf00000000, 0x470877f200000000, 0x1408c71000000000, + 0xa421a72d00000000, 0x745b076a00000000, 0xc472675700000000, + 0xd4ae47e500000000, 0x648727d800000000, 0xb4fd879f00000000, + 0x04d4e7a200000000, 0xd543b72000000000, 0x656ad71d00000000, + 0xb510775a00000000, 0x0539176700000000, 0x15e537d500000000, + 0xa5cc57e800000000, 0x75b6f7af00000000, 0xc59f979200000000, + 0xdbe815e900000000, 0x6bc175d400000000, 0xbbbbd59300000000, + 0x0b92b5ae00000000, 0x1b4e951c00000000, 0xab67f52100000000, + 0x7b1d556600000000, 0xcb34355b00000000, 0x1aa365d900000000, + 0xaa8a05e400000000, 0x7af0a5a300000000, 0xcad9c59e00000000, + 0xda05e52c00000000, 0x6a2c851100000000, 0xba56255600000000, + 0x0a7f456b00000000, 0x597ff58900000000, 0xe95695b400000000, + 0x392c35f300000000, 0x890555ce00000000, 0x99d9757c00000000, + 0x29f0154100000000, 0xf98ab50600000000, 0x49a3d53b00000000, + 0x983485b900000000, 0x281de58400000000, 0xf86745c300000000, + 0x484e25fe00000000, 0x5892054c00000000, 0xe8bb657100000000, + 0x38c1c53600000000, 0x88e8a50b00000000, 0xdfc7d42800000000, + 0x6feeb41500000000, 0xbf94145200000000, 0x0fbd746f00000000, + 0x1f6154dd00000000, 0xaf4834e000000000, 0x7f3294a700000000, + 0xcf1bf49a00000000, 0x1e8ca41800000000, 0xaea5c42500000000, + 0x7edf646200000000, 0xcef6045f00000000, 0xde2a24ed00000000, + 0x6e0344d000000000, 0xbe79e49700000000, 0x0e5084aa00000000, + 0x5d50344800000000, 0xed79547500000000, 0x3d03f43200000000, + 0x8d2a940f00000000, 0x9df6b4bd00000000, 0x2ddfd48000000000, + 0xfda574c700000000, 0x4d8c14fa00000000, 0x9c1b447800000000, + 0x2c32244500000000, 0xfc48840200000000, 0x4c61e43f00000000, + 0x5cbdc48d00000000, 0xec94a4b000000000, 0x3cee04f700000000, + 0x8cc764ca00000000}, + {0x0000000000000000, 0xa5d35ccb00000000, 0x0ba1c84d00000000, + 0xae72948600000000, 0x1642919b00000000, 0xb391cd5000000000, + 0x1de359d600000000, 0xb830051d00000000, 0x6d8253ec00000000, + 0xc8510f2700000000, 0x66239ba100000000, 0xc3f0c76a00000000, + 0x7bc0c27700000000, 0xde139ebc00000000, 0x70610a3a00000000, + 0xd5b256f100000000, 0x9b02d60300000000, 0x3ed18ac800000000, + 0x90a31e4e00000000, 0x3570428500000000, 0x8d40479800000000, + 0x28931b5300000000, 0x86e18fd500000000, 0x2332d31e00000000, + 0xf68085ef00000000, 0x5353d92400000000, 0xfd214da200000000, + 0x58f2116900000000, 0xe0c2147400000000, 0x451148bf00000000, + 0xeb63dc3900000000, 0x4eb080f200000000, 0x3605ac0700000000, + 0x93d6f0cc00000000, 0x3da4644a00000000, 0x9877388100000000, + 0x20473d9c00000000, 0x8594615700000000, 0x2be6f5d100000000, + 0x8e35a91a00000000, 0x5b87ffeb00000000, 0xfe54a32000000000, + 0x502637a600000000, 0xf5f56b6d00000000, 0x4dc56e7000000000, + 0xe81632bb00000000, 0x4664a63d00000000, 0xe3b7faf600000000, + 0xad077a0400000000, 0x08d426cf00000000, 0xa6a6b24900000000, + 0x0375ee8200000000, 0xbb45eb9f00000000, 0x1e96b75400000000, + 0xb0e423d200000000, 0x15377f1900000000, 0xc08529e800000000, + 0x6556752300000000, 0xcb24e1a500000000, 0x6ef7bd6e00000000, + 0xd6c7b87300000000, 0x7314e4b800000000, 0xdd66703e00000000, + 0x78b52cf500000000, 0x6c0a580f00000000, 0xc9d904c400000000, + 0x67ab904200000000, 0xc278cc8900000000, 0x7a48c99400000000, + 0xdf9b955f00000000, 0x71e901d900000000, 0xd43a5d1200000000, + 0x01880be300000000, 0xa45b572800000000, 0x0a29c3ae00000000, + 0xaffa9f6500000000, 0x17ca9a7800000000, 0xb219c6b300000000, + 0x1c6b523500000000, 0xb9b80efe00000000, 0xf7088e0c00000000, + 0x52dbd2c700000000, 0xfca9464100000000, 0x597a1a8a00000000, + 0xe14a1f9700000000, 0x4499435c00000000, 0xeaebd7da00000000, + 0x4f388b1100000000, 0x9a8adde000000000, 0x3f59812b00000000, + 0x912b15ad00000000, 0x34f8496600000000, 0x8cc84c7b00000000, + 0x291b10b000000000, 0x8769843600000000, 0x22bad8fd00000000, + 0x5a0ff40800000000, 0xffdca8c300000000, 0x51ae3c4500000000, + 0xf47d608e00000000, 0x4c4d659300000000, 0xe99e395800000000, + 0x47ecadde00000000, 0xe23ff11500000000, 0x378da7e400000000, + 0x925efb2f00000000, 0x3c2c6fa900000000, 0x99ff336200000000, + 0x21cf367f00000000, 0x841c6ab400000000, 0x2a6efe3200000000, + 0x8fbda2f900000000, 0xc10d220b00000000, 0x64de7ec000000000, + 0xcaacea4600000000, 0x6f7fb68d00000000, 0xd74fb39000000000, + 0x729cef5b00000000, 0xdcee7bdd00000000, 0x793d271600000000, + 0xac8f71e700000000, 0x095c2d2c00000000, 0xa72eb9aa00000000, + 0x02fde56100000000, 0xbacde07c00000000, 0x1f1ebcb700000000, + 0xb16c283100000000, 0x14bf74fa00000000, 0xd814b01e00000000, + 0x7dc7ecd500000000, 0xd3b5785300000000, 0x7666249800000000, + 0xce56218500000000, 0x6b857d4e00000000, 0xc5f7e9c800000000, + 0x6024b50300000000, 0xb596e3f200000000, 0x1045bf3900000000, + 0xbe372bbf00000000, 0x1be4777400000000, 0xa3d4726900000000, + 0x06072ea200000000, 0xa875ba2400000000, 0x0da6e6ef00000000, + 0x4316661d00000000, 0xe6c53ad600000000, 0x48b7ae5000000000, + 0xed64f29b00000000, 0x5554f78600000000, 0xf087ab4d00000000, + 0x5ef53fcb00000000, 0xfb26630000000000, 0x2e9435f100000000, + 0x8b47693a00000000, 0x2535fdbc00000000, 0x80e6a17700000000, + 0x38d6a46a00000000, 0x9d05f8a100000000, 0x33776c2700000000, + 0x96a430ec00000000, 0xee111c1900000000, 0x4bc240d200000000, + 0xe5b0d45400000000, 0x4063889f00000000, 0xf8538d8200000000, + 0x5d80d14900000000, 0xf3f245cf00000000, 0x5621190400000000, + 0x83934ff500000000, 0x2640133e00000000, 0x883287b800000000, + 0x2de1db7300000000, 0x95d1de6e00000000, 0x300282a500000000, + 0x9e70162300000000, 0x3ba34ae800000000, 0x7513ca1a00000000, + 0xd0c096d100000000, 0x7eb2025700000000, 0xdb615e9c00000000, + 0x63515b8100000000, 0xc682074a00000000, 0x68f093cc00000000, + 0xcd23cf0700000000, 0x189199f600000000, 0xbd42c53d00000000, + 0x133051bb00000000, 0xb6e30d7000000000, 0x0ed3086d00000000, + 0xab0054a600000000, 0x0572c02000000000, 0xa0a19ceb00000000, + 0xb41ee81100000000, 0x11cdb4da00000000, 0xbfbf205c00000000, + 0x1a6c7c9700000000, 0xa25c798a00000000, 0x078f254100000000, + 0xa9fdb1c700000000, 0x0c2eed0c00000000, 0xd99cbbfd00000000, + 0x7c4fe73600000000, 0xd23d73b000000000, 0x77ee2f7b00000000, + 0xcfde2a6600000000, 0x6a0d76ad00000000, 0xc47fe22b00000000, + 0x61acbee000000000, 0x2f1c3e1200000000, 0x8acf62d900000000, + 0x24bdf65f00000000, 0x816eaa9400000000, 0x395eaf8900000000, + 0x9c8df34200000000, 0x32ff67c400000000, 0x972c3b0f00000000, + 0x429e6dfe00000000, 0xe74d313500000000, 0x493fa5b300000000, + 0xececf97800000000, 0x54dcfc6500000000, 0xf10fa0ae00000000, + 0x5f7d342800000000, 0xfaae68e300000000, 0x821b441600000000, + 0x27c818dd00000000, 0x89ba8c5b00000000, 0x2c69d09000000000, + 0x9459d58d00000000, 0x318a894600000000, 0x9ff81dc000000000, + 0x3a2b410b00000000, 0xef9917fa00000000, 0x4a4a4b3100000000, + 0xe438dfb700000000, 0x41eb837c00000000, 0xf9db866100000000, + 0x5c08daaa00000000, 0xf27a4e2c00000000, 0x57a912e700000000, + 0x1919921500000000, 0xbccacede00000000, 0x12b85a5800000000, + 0xb76b069300000000, 0x0f5b038e00000000, 0xaa885f4500000000, + 0x04facbc300000000, 0xa129970800000000, 0x749bc1f900000000, + 0xd1489d3200000000, 0x7f3a09b400000000, 0xdae9557f00000000, + 0x62d9506200000000, 0xc70a0ca900000000, 0x6978982f00000000, + 0xccabc4e400000000}, + {0x0000000000000000, 0xb40b77a600000000, 0x29119f9700000000, + 0x9d1ae83100000000, 0x13244ff400000000, 0xa72f385200000000, + 0x3a35d06300000000, 0x8e3ea7c500000000, 0x674eef3300000000, + 0xd345989500000000, 0x4e5f70a400000000, 0xfa54070200000000, + 0x746aa0c700000000, 0xc061d76100000000, 0x5d7b3f5000000000, + 0xe97048f600000000, 0xce9cde6700000000, 0x7a97a9c100000000, + 0xe78d41f000000000, 0x5386365600000000, 0xddb8919300000000, + 0x69b3e63500000000, 0xf4a90e0400000000, 0x40a279a200000000, + 0xa9d2315400000000, 0x1dd946f200000000, 0x80c3aec300000000, + 0x34c8d96500000000, 0xbaf67ea000000000, 0x0efd090600000000, + 0x93e7e13700000000, 0x27ec969100000000, 0x9c39bdcf00000000, + 0x2832ca6900000000, 0xb528225800000000, 0x012355fe00000000, + 0x8f1df23b00000000, 0x3b16859d00000000, 0xa60c6dac00000000, + 0x12071a0a00000000, 0xfb7752fc00000000, 0x4f7c255a00000000, + 0xd266cd6b00000000, 0x666dbacd00000000, 0xe8531d0800000000, + 0x5c586aae00000000, 0xc142829f00000000, 0x7549f53900000000, + 0x52a563a800000000, 0xe6ae140e00000000, 0x7bb4fc3f00000000, + 0xcfbf8b9900000000, 0x41812c5c00000000, 0xf58a5bfa00000000, + 0x6890b3cb00000000, 0xdc9bc46d00000000, 0x35eb8c9b00000000, + 0x81e0fb3d00000000, 0x1cfa130c00000000, 0xa8f164aa00000000, + 0x26cfc36f00000000, 0x92c4b4c900000000, 0x0fde5cf800000000, + 0xbbd52b5e00000000, 0x79750b4400000000, 0xcd7e7ce200000000, + 0x506494d300000000, 0xe46fe37500000000, 0x6a5144b000000000, + 0xde5a331600000000, 0x4340db2700000000, 0xf74bac8100000000, + 0x1e3be47700000000, 0xaa3093d100000000, 0x372a7be000000000, + 0x83210c4600000000, 0x0d1fab8300000000, 0xb914dc2500000000, + 0x240e341400000000, 0x900543b200000000, 0xb7e9d52300000000, + 0x03e2a28500000000, 0x9ef84ab400000000, 0x2af33d1200000000, + 0xa4cd9ad700000000, 0x10c6ed7100000000, 0x8ddc054000000000, + 0x39d772e600000000, 0xd0a73a1000000000, 0x64ac4db600000000, + 0xf9b6a58700000000, 0x4dbdd22100000000, 0xc38375e400000000, + 0x7788024200000000, 0xea92ea7300000000, 0x5e999dd500000000, + 0xe54cb68b00000000, 0x5147c12d00000000, 0xcc5d291c00000000, + 0x78565eba00000000, 0xf668f97f00000000, 0x42638ed900000000, + 0xdf7966e800000000, 0x6b72114e00000000, 0x820259b800000000, + 0x36092e1e00000000, 0xab13c62f00000000, 0x1f18b18900000000, + 0x9126164c00000000, 0x252d61ea00000000, 0xb83789db00000000, + 0x0c3cfe7d00000000, 0x2bd068ec00000000, 0x9fdb1f4a00000000, + 0x02c1f77b00000000, 0xb6ca80dd00000000, 0x38f4271800000000, + 0x8cff50be00000000, 0x11e5b88f00000000, 0xa5eecf2900000000, + 0x4c9e87df00000000, 0xf895f07900000000, 0x658f184800000000, + 0xd1846fee00000000, 0x5fbac82b00000000, 0xebb1bf8d00000000, + 0x76ab57bc00000000, 0xc2a0201a00000000, 0xf2ea168800000000, + 0x46e1612e00000000, 0xdbfb891f00000000, 0x6ff0feb900000000, + 0xe1ce597c00000000, 0x55c52eda00000000, 0xc8dfc6eb00000000, + 0x7cd4b14d00000000, 0x95a4f9bb00000000, 0x21af8e1d00000000, + 0xbcb5662c00000000, 0x08be118a00000000, 0x8680b64f00000000, + 0x328bc1e900000000, 0xaf9129d800000000, 0x1b9a5e7e00000000, + 0x3c76c8ef00000000, 0x887dbf4900000000, 0x1567577800000000, + 0xa16c20de00000000, 0x2f52871b00000000, 0x9b59f0bd00000000, + 0x0643188c00000000, 0xb2486f2a00000000, 0x5b3827dc00000000, + 0xef33507a00000000, 0x7229b84b00000000, 0xc622cfed00000000, + 0x481c682800000000, 0xfc171f8e00000000, 0x610df7bf00000000, + 0xd506801900000000, 0x6ed3ab4700000000, 0xdad8dce100000000, + 0x47c234d000000000, 0xf3c9437600000000, 0x7df7e4b300000000, + 0xc9fc931500000000, 0x54e67b2400000000, 0xe0ed0c8200000000, + 0x099d447400000000, 0xbd9633d200000000, 0x208cdbe300000000, + 0x9487ac4500000000, 0x1ab90b8000000000, 0xaeb27c2600000000, + 0x33a8941700000000, 0x87a3e3b100000000, 0xa04f752000000000, + 0x1444028600000000, 0x895eeab700000000, 0x3d559d1100000000, + 0xb36b3ad400000000, 0x07604d7200000000, 0x9a7aa54300000000, + 0x2e71d2e500000000, 0xc7019a1300000000, 0x730aedb500000000, + 0xee10058400000000, 0x5a1b722200000000, 0xd425d5e700000000, + 0x602ea24100000000, 0xfd344a7000000000, 0x493f3dd600000000, + 0x8b9f1dcc00000000, 0x3f946a6a00000000, 0xa28e825b00000000, + 0x1685f5fd00000000, 0x98bb523800000000, 0x2cb0259e00000000, + 0xb1aacdaf00000000, 0x05a1ba0900000000, 0xecd1f2ff00000000, + 0x58da855900000000, 0xc5c06d6800000000, 0x71cb1ace00000000, + 0xfff5bd0b00000000, 0x4bfecaad00000000, 0xd6e4229c00000000, + 0x62ef553a00000000, 0x4503c3ab00000000, 0xf108b40d00000000, + 0x6c125c3c00000000, 0xd8192b9a00000000, 0x56278c5f00000000, + 0xe22cfbf900000000, 0x7f3613c800000000, 0xcb3d646e00000000, + 0x224d2c9800000000, 0x96465b3e00000000, 0x0b5cb30f00000000, + 0xbf57c4a900000000, 0x3169636c00000000, 0x856214ca00000000, + 0x1878fcfb00000000, 0xac738b5d00000000, 0x17a6a00300000000, + 0xa3add7a500000000, 0x3eb73f9400000000, 0x8abc483200000000, + 0x0482eff700000000, 0xb089985100000000, 0x2d93706000000000, + 0x999807c600000000, 0x70e84f3000000000, 0xc4e3389600000000, + 0x59f9d0a700000000, 0xedf2a70100000000, 0x63cc00c400000000, + 0xd7c7776200000000, 0x4add9f5300000000, 0xfed6e8f500000000, + 0xd93a7e6400000000, 0x6d3109c200000000, 0xf02be1f300000000, + 0x4420965500000000, 0xca1e319000000000, 0x7e15463600000000, + 0xe30fae0700000000, 0x5704d9a100000000, 0xbe74915700000000, + 0x0a7fe6f100000000, 0x97650ec000000000, 0x236e796600000000, + 0xad50dea300000000, 0x195ba90500000000, 0x8441413400000000, + 0x304a369200000000}, + {0x0000000000000000, 0x9e00aacc00000000, 0x7d07254200000000, + 0xe3078f8e00000000, 0xfa0e4a8400000000, 0x640ee04800000000, + 0x87096fc600000000, 0x1909c50a00000000, 0xb51be5d300000000, + 0x2b1b4f1f00000000, 0xc81cc09100000000, 0x561c6a5d00000000, + 0x4f15af5700000000, 0xd115059b00000000, 0x32128a1500000000, + 0xac1220d900000000, 0x2b31bb7c00000000, 0xb53111b000000000, + 0x56369e3e00000000, 0xc83634f200000000, 0xd13ff1f800000000, + 0x4f3f5b3400000000, 0xac38d4ba00000000, 0x32387e7600000000, + 0x9e2a5eaf00000000, 0x002af46300000000, 0xe32d7bed00000000, + 0x7d2dd12100000000, 0x6424142b00000000, 0xfa24bee700000000, + 0x1923316900000000, 0x87239ba500000000, 0x566276f900000000, + 0xc862dc3500000000, 0x2b6553bb00000000, 0xb565f97700000000, + 0xac6c3c7d00000000, 0x326c96b100000000, 0xd16b193f00000000, + 0x4f6bb3f300000000, 0xe379932a00000000, 0x7d7939e600000000, + 0x9e7eb66800000000, 0x007e1ca400000000, 0x1977d9ae00000000, + 0x8777736200000000, 0x6470fcec00000000, 0xfa70562000000000, + 0x7d53cd8500000000, 0xe353674900000000, 0x0054e8c700000000, + 0x9e54420b00000000, 0x875d870100000000, 0x195d2dcd00000000, + 0xfa5aa24300000000, 0x645a088f00000000, 0xc848285600000000, + 0x5648829a00000000, 0xb54f0d1400000000, 0x2b4fa7d800000000, + 0x324662d200000000, 0xac46c81e00000000, 0x4f41479000000000, + 0xd141ed5c00000000, 0xedc29d2900000000, 0x73c237e500000000, + 0x90c5b86b00000000, 0x0ec512a700000000, 0x17ccd7ad00000000, + 0x89cc7d6100000000, 0x6acbf2ef00000000, 0xf4cb582300000000, + 0x58d978fa00000000, 0xc6d9d23600000000, 0x25de5db800000000, + 0xbbdef77400000000, 0xa2d7327e00000000, 0x3cd798b200000000, + 0xdfd0173c00000000, 0x41d0bdf000000000, 0xc6f3265500000000, + 0x58f38c9900000000, 0xbbf4031700000000, 0x25f4a9db00000000, + 0x3cfd6cd100000000, 0xa2fdc61d00000000, 0x41fa499300000000, + 0xdffae35f00000000, 0x73e8c38600000000, 0xede8694a00000000, + 0x0eefe6c400000000, 0x90ef4c0800000000, 0x89e6890200000000, + 0x17e623ce00000000, 0xf4e1ac4000000000, 0x6ae1068c00000000, + 0xbba0ebd000000000, 0x25a0411c00000000, 0xc6a7ce9200000000, + 0x58a7645e00000000, 0x41aea15400000000, 0xdfae0b9800000000, + 0x3ca9841600000000, 0xa2a92eda00000000, 0x0ebb0e0300000000, + 0x90bba4cf00000000, 0x73bc2b4100000000, 0xedbc818d00000000, + 0xf4b5448700000000, 0x6ab5ee4b00000000, 0x89b261c500000000, + 0x17b2cb0900000000, 0x909150ac00000000, 0x0e91fa6000000000, + 0xed9675ee00000000, 0x7396df2200000000, 0x6a9f1a2800000000, + 0xf49fb0e400000000, 0x17983f6a00000000, 0x899895a600000000, + 0x258ab57f00000000, 0xbb8a1fb300000000, 0x588d903d00000000, + 0xc68d3af100000000, 0xdf84fffb00000000, 0x4184553700000000, + 0xa283dab900000000, 0x3c83707500000000, 0xda853b5300000000, + 0x4485919f00000000, 0xa7821e1100000000, 0x3982b4dd00000000, + 0x208b71d700000000, 0xbe8bdb1b00000000, 0x5d8c549500000000, + 0xc38cfe5900000000, 0x6f9ede8000000000, 0xf19e744c00000000, + 0x1299fbc200000000, 0x8c99510e00000000, 0x9590940400000000, + 0x0b903ec800000000, 0xe897b14600000000, 0x76971b8a00000000, + 0xf1b4802f00000000, 0x6fb42ae300000000, 0x8cb3a56d00000000, + 0x12b30fa100000000, 0x0bbacaab00000000, 0x95ba606700000000, + 0x76bdefe900000000, 0xe8bd452500000000, 0x44af65fc00000000, + 0xdaafcf3000000000, 0x39a840be00000000, 0xa7a8ea7200000000, + 0xbea12f7800000000, 0x20a185b400000000, 0xc3a60a3a00000000, + 0x5da6a0f600000000, 0x8ce74daa00000000, 0x12e7e76600000000, + 0xf1e068e800000000, 0x6fe0c22400000000, 0x76e9072e00000000, + 0xe8e9ade200000000, 0x0bee226c00000000, 0x95ee88a000000000, + 0x39fca87900000000, 0xa7fc02b500000000, 0x44fb8d3b00000000, + 0xdafb27f700000000, 0xc3f2e2fd00000000, 0x5df2483100000000, + 0xbef5c7bf00000000, 0x20f56d7300000000, 0xa7d6f6d600000000, + 0x39d65c1a00000000, 0xdad1d39400000000, 0x44d1795800000000, + 0x5dd8bc5200000000, 0xc3d8169e00000000, 0x20df991000000000, + 0xbedf33dc00000000, 0x12cd130500000000, 0x8ccdb9c900000000, + 0x6fca364700000000, 0xf1ca9c8b00000000, 0xe8c3598100000000, + 0x76c3f34d00000000, 0x95c47cc300000000, 0x0bc4d60f00000000, + 0x3747a67a00000000, 0xa9470cb600000000, 0x4a40833800000000, + 0xd44029f400000000, 0xcd49ecfe00000000, 0x5349463200000000, + 0xb04ec9bc00000000, 0x2e4e637000000000, 0x825c43a900000000, + 0x1c5ce96500000000, 0xff5b66eb00000000, 0x615bcc2700000000, + 0x7852092d00000000, 0xe652a3e100000000, 0x05552c6f00000000, + 0x9b5586a300000000, 0x1c761d0600000000, 0x8276b7ca00000000, + 0x6171384400000000, 0xff71928800000000, 0xe678578200000000, + 0x7878fd4e00000000, 0x9b7f72c000000000, 0x057fd80c00000000, + 0xa96df8d500000000, 0x376d521900000000, 0xd46add9700000000, + 0x4a6a775b00000000, 0x5363b25100000000, 0xcd63189d00000000, + 0x2e64971300000000, 0xb0643ddf00000000, 0x6125d08300000000, + 0xff257a4f00000000, 0x1c22f5c100000000, 0x82225f0d00000000, + 0x9b2b9a0700000000, 0x052b30cb00000000, 0xe62cbf4500000000, + 0x782c158900000000, 0xd43e355000000000, 0x4a3e9f9c00000000, + 0xa939101200000000, 0x3739bade00000000, 0x2e307fd400000000, + 0xb030d51800000000, 0x53375a9600000000, 0xcd37f05a00000000, + 0x4a146bff00000000, 0xd414c13300000000, 0x37134ebd00000000, + 0xa913e47100000000, 0xb01a217b00000000, 0x2e1a8bb700000000, + 0xcd1d043900000000, 0x531daef500000000, 0xff0f8e2c00000000, + 0x610f24e000000000, 0x8208ab6e00000000, 0x1c0801a200000000, + 0x0501c4a800000000, 0x9b016e6400000000, 0x7806e1ea00000000, + 0xe6064b2600000000}}; + +#else /* W == 4 */ + +local const z_crc_t FAR crc_braid_table[][256] = { + {0x00000000, 0xb8bc6765, 0xaa09c88b, 0x12b5afee, 0x8f629757, + 0x37def032, 0x256b5fdc, 0x9dd738b9, 0xc5b428ef, 0x7d084f8a, + 0x6fbde064, 0xd7018701, 0x4ad6bfb8, 0xf26ad8dd, 0xe0df7733, + 0x58631056, 0x5019579f, 0xe8a530fa, 0xfa109f14, 0x42acf871, + 0xdf7bc0c8, 0x67c7a7ad, 0x75720843, 0xcdce6f26, 0x95ad7f70, + 0x2d111815, 0x3fa4b7fb, 0x8718d09e, 0x1acfe827, 0xa2738f42, + 0xb0c620ac, 0x087a47c9, 0xa032af3e, 0x188ec85b, 0x0a3b67b5, + 0xb28700d0, 0x2f503869, 0x97ec5f0c, 0x8559f0e2, 0x3de59787, + 0x658687d1, 0xdd3ae0b4, 0xcf8f4f5a, 0x7733283f, 0xeae41086, + 0x525877e3, 0x40edd80d, 0xf851bf68, 0xf02bf8a1, 0x48979fc4, + 0x5a22302a, 0xe29e574f, 0x7f496ff6, 0xc7f50893, 0xd540a77d, + 0x6dfcc018, 0x359fd04e, 0x8d23b72b, 0x9f9618c5, 0x272a7fa0, + 0xbafd4719, 0x0241207c, 0x10f48f92, 0xa848e8f7, 0x9b14583d, + 0x23a83f58, 0x311d90b6, 0x89a1f7d3, 0x1476cf6a, 0xaccaa80f, + 0xbe7f07e1, 0x06c36084, 0x5ea070d2, 0xe61c17b7, 0xf4a9b859, + 0x4c15df3c, 0xd1c2e785, 0x697e80e0, 0x7bcb2f0e, 0xc377486b, + 0xcb0d0fa2, 0x73b168c7, 0x6104c729, 0xd9b8a04c, 0x446f98f5, + 0xfcd3ff90, 0xee66507e, 0x56da371b, 0x0eb9274d, 0xb6054028, + 0xa4b0efc6, 0x1c0c88a3, 0x81dbb01a, 0x3967d77f, 0x2bd27891, + 0x936e1ff4, 0x3b26f703, 0x839a9066, 0x912f3f88, 0x299358ed, + 0xb4446054, 0x0cf80731, 0x1e4da8df, 0xa6f1cfba, 0xfe92dfec, + 0x462eb889, 0x549b1767, 0xec277002, 0x71f048bb, 0xc94c2fde, + 0xdbf98030, 0x6345e755, 0x6b3fa09c, 0xd383c7f9, 0xc1366817, + 0x798a0f72, 0xe45d37cb, 0x5ce150ae, 0x4e54ff40, 0xf6e89825, + 0xae8b8873, 0x1637ef16, 0x048240f8, 0xbc3e279d, 0x21e91f24, + 0x99557841, 0x8be0d7af, 0x335cb0ca, 0xed59b63b, 0x55e5d15e, + 0x47507eb0, 0xffec19d5, 0x623b216c, 0xda874609, 0xc832e9e7, + 0x708e8e82, 0x28ed9ed4, 0x9051f9b1, 0x82e4565f, 0x3a58313a, + 0xa78f0983, 0x1f336ee6, 0x0d86c108, 0xb53aa66d, 0xbd40e1a4, + 0x05fc86c1, 0x1749292f, 0xaff54e4a, 0x322276f3, 0x8a9e1196, + 0x982bbe78, 0x2097d91d, 0x78f4c94b, 0xc048ae2e, 0xd2fd01c0, + 0x6a4166a5, 0xf7965e1c, 0x4f2a3979, 0x5d9f9697, 0xe523f1f2, + 0x4d6b1905, 0xf5d77e60, 0xe762d18e, 0x5fdeb6eb, 0xc2098e52, + 0x7ab5e937, 0x680046d9, 0xd0bc21bc, 0x88df31ea, 0x3063568f, + 0x22d6f961, 0x9a6a9e04, 0x07bda6bd, 0xbf01c1d8, 0xadb46e36, + 0x15080953, 0x1d724e9a, 0xa5ce29ff, 0xb77b8611, 0x0fc7e174, + 0x9210d9cd, 0x2aacbea8, 0x38191146, 0x80a57623, 0xd8c66675, + 0x607a0110, 0x72cfaefe, 0xca73c99b, 0x57a4f122, 0xef189647, + 0xfdad39a9, 0x45115ecc, 0x764dee06, 0xcef18963, 0xdc44268d, + 0x64f841e8, 0xf92f7951, 0x41931e34, 0x5326b1da, 0xeb9ad6bf, + 0xb3f9c6e9, 0x0b45a18c, 0x19f00e62, 0xa14c6907, 0x3c9b51be, + 0x842736db, 0x96929935, 0x2e2efe50, 0x2654b999, 0x9ee8defc, + 0x8c5d7112, 0x34e11677, 0xa9362ece, 0x118a49ab, 0x033fe645, + 0xbb838120, 0xe3e09176, 0x5b5cf613, 0x49e959fd, 0xf1553e98, + 0x6c820621, 0xd43e6144, 0xc68bceaa, 0x7e37a9cf, 0xd67f4138, + 0x6ec3265d, 0x7c7689b3, 0xc4caeed6, 0x591dd66f, 0xe1a1b10a, + 0xf3141ee4, 0x4ba87981, 0x13cb69d7, 0xab770eb2, 0xb9c2a15c, + 0x017ec639, 0x9ca9fe80, 0x241599e5, 0x36a0360b, 0x8e1c516e, + 0x866616a7, 0x3eda71c2, 0x2c6fde2c, 0x94d3b949, 0x090481f0, + 0xb1b8e695, 0xa30d497b, 0x1bb12e1e, 0x43d23e48, 0xfb6e592d, + 0xe9dbf6c3, 0x516791a6, 0xccb0a91f, 0x740cce7a, 0x66b96194, + 0xde0506f1}, + {0x00000000, 0x01c26a37, 0x0384d46e, 0x0246be59, 0x0709a8dc, + 0x06cbc2eb, 0x048d7cb2, 0x054f1685, 0x0e1351b8, 0x0fd13b8f, + 0x0d9785d6, 0x0c55efe1, 0x091af964, 0x08d89353, 0x0a9e2d0a, + 0x0b5c473d, 0x1c26a370, 0x1de4c947, 0x1fa2771e, 0x1e601d29, + 0x1b2f0bac, 0x1aed619b, 0x18abdfc2, 0x1969b5f5, 0x1235f2c8, + 0x13f798ff, 0x11b126a6, 0x10734c91, 0x153c5a14, 0x14fe3023, + 0x16b88e7a, 0x177ae44d, 0x384d46e0, 0x398f2cd7, 0x3bc9928e, + 0x3a0bf8b9, 0x3f44ee3c, 0x3e86840b, 0x3cc03a52, 0x3d025065, + 0x365e1758, 0x379c7d6f, 0x35dac336, 0x3418a901, 0x3157bf84, + 0x3095d5b3, 0x32d36bea, 0x331101dd, 0x246be590, 0x25a98fa7, + 0x27ef31fe, 0x262d5bc9, 0x23624d4c, 0x22a0277b, 0x20e69922, + 0x2124f315, 0x2a78b428, 0x2bbade1f, 0x29fc6046, 0x283e0a71, + 0x2d711cf4, 0x2cb376c3, 0x2ef5c89a, 0x2f37a2ad, 0x709a8dc0, + 0x7158e7f7, 0x731e59ae, 0x72dc3399, 0x7793251c, 0x76514f2b, + 0x7417f172, 0x75d59b45, 0x7e89dc78, 0x7f4bb64f, 0x7d0d0816, + 0x7ccf6221, 0x798074a4, 0x78421e93, 0x7a04a0ca, 0x7bc6cafd, + 0x6cbc2eb0, 0x6d7e4487, 0x6f38fade, 0x6efa90e9, 0x6bb5866c, + 0x6a77ec5b, 0x68315202, 0x69f33835, 0x62af7f08, 0x636d153f, + 0x612bab66, 0x60e9c151, 0x65a6d7d4, 0x6464bde3, 0x662203ba, + 0x67e0698d, 0x48d7cb20, 0x4915a117, 0x4b531f4e, 0x4a917579, + 0x4fde63fc, 0x4e1c09cb, 0x4c5ab792, 0x4d98dda5, 0x46c49a98, + 0x4706f0af, 0x45404ef6, 0x448224c1, 0x41cd3244, 0x400f5873, + 0x4249e62a, 0x438b8c1d, 0x54f16850, 0x55330267, 0x5775bc3e, + 0x56b7d609, 0x53f8c08c, 0x523aaabb, 0x507c14e2, 0x51be7ed5, + 0x5ae239e8, 0x5b2053df, 0x5966ed86, 0x58a487b1, 0x5deb9134, + 0x5c29fb03, 0x5e6f455a, 0x5fad2f6d, 0xe1351b80, 0xe0f771b7, + 0xe2b1cfee, 0xe373a5d9, 0xe63cb35c, 0xe7fed96b, 0xe5b86732, + 0xe47a0d05, 0xef264a38, 0xeee4200f, 0xeca29e56, 0xed60f461, + 0xe82fe2e4, 0xe9ed88d3, 0xebab368a, 0xea695cbd, 0xfd13b8f0, + 0xfcd1d2c7, 0xfe976c9e, 0xff5506a9, 0xfa1a102c, 0xfbd87a1b, + 0xf99ec442, 0xf85cae75, 0xf300e948, 0xf2c2837f, 0xf0843d26, + 0xf1465711, 0xf4094194, 0xf5cb2ba3, 0xf78d95fa, 0xf64fffcd, + 0xd9785d60, 0xd8ba3757, 0xdafc890e, 0xdb3ee339, 0xde71f5bc, + 0xdfb39f8b, 0xddf521d2, 0xdc374be5, 0xd76b0cd8, 0xd6a966ef, + 0xd4efd8b6, 0xd52db281, 0xd062a404, 0xd1a0ce33, 0xd3e6706a, + 0xd2241a5d, 0xc55efe10, 0xc49c9427, 0xc6da2a7e, 0xc7184049, + 0xc25756cc, 0xc3953cfb, 0xc1d382a2, 0xc011e895, 0xcb4dafa8, + 0xca8fc59f, 0xc8c97bc6, 0xc90b11f1, 0xcc440774, 0xcd866d43, + 0xcfc0d31a, 0xce02b92d, 0x91af9640, 0x906dfc77, 0x922b422e, + 0x93e92819, 0x96a63e9c, 0x976454ab, 0x9522eaf2, 0x94e080c5, + 0x9fbcc7f8, 0x9e7eadcf, 0x9c381396, 0x9dfa79a1, 0x98b56f24, + 0x99770513, 0x9b31bb4a, 0x9af3d17d, 0x8d893530, 0x8c4b5f07, + 0x8e0de15e, 0x8fcf8b69, 0x8a809dec, 0x8b42f7db, 0x89044982, + 0x88c623b5, 0x839a6488, 0x82580ebf, 0x801eb0e6, 0x81dcdad1, + 0x8493cc54, 0x8551a663, 0x8717183a, 0x86d5720d, 0xa9e2d0a0, + 0xa820ba97, 0xaa6604ce, 0xaba46ef9, 0xaeeb787c, 0xaf29124b, + 0xad6fac12, 0xacadc625, 0xa7f18118, 0xa633eb2f, 0xa4755576, + 0xa5b73f41, 0xa0f829c4, 0xa13a43f3, 0xa37cfdaa, 0xa2be979d, + 0xb5c473d0, 0xb40619e7, 0xb640a7be, 0xb782cd89, 0xb2cddb0c, + 0xb30fb13b, 0xb1490f62, 0xb08b6555, 0xbbd72268, 0xba15485f, + 0xb853f606, 0xb9919c31, 0xbcde8ab4, 0xbd1ce083, 0xbf5a5eda, + 0xbe9834ed}, + {0x00000000, 0x191b3141, 0x32366282, 0x2b2d53c3, 0x646cc504, + 0x7d77f445, 0x565aa786, 0x4f4196c7, 0xc8d98a08, 0xd1c2bb49, + 0xfaefe88a, 0xe3f4d9cb, 0xacb54f0c, 0xb5ae7e4d, 0x9e832d8e, + 0x87981ccf, 0x4ac21251, 0x53d92310, 0x78f470d3, 0x61ef4192, + 0x2eaed755, 0x37b5e614, 0x1c98b5d7, 0x05838496, 0x821b9859, + 0x9b00a918, 0xb02dfadb, 0xa936cb9a, 0xe6775d5d, 0xff6c6c1c, + 0xd4413fdf, 0xcd5a0e9e, 0x958424a2, 0x8c9f15e3, 0xa7b24620, + 0xbea97761, 0xf1e8e1a6, 0xe8f3d0e7, 0xc3de8324, 0xdac5b265, + 0x5d5daeaa, 0x44469feb, 0x6f6bcc28, 0x7670fd69, 0x39316bae, + 0x202a5aef, 0x0b07092c, 0x121c386d, 0xdf4636f3, 0xc65d07b2, + 0xed705471, 0xf46b6530, 0xbb2af3f7, 0xa231c2b6, 0x891c9175, + 0x9007a034, 0x179fbcfb, 0x0e848dba, 0x25a9de79, 0x3cb2ef38, + 0x73f379ff, 0x6ae848be, 0x41c51b7d, 0x58de2a3c, 0xf0794f05, + 0xe9627e44, 0xc24f2d87, 0xdb541cc6, 0x94158a01, 0x8d0ebb40, + 0xa623e883, 0xbf38d9c2, 0x38a0c50d, 0x21bbf44c, 0x0a96a78f, + 0x138d96ce, 0x5ccc0009, 0x45d73148, 0x6efa628b, 0x77e153ca, + 0xbabb5d54, 0xa3a06c15, 0x888d3fd6, 0x91960e97, 0xded79850, + 0xc7cca911, 0xece1fad2, 0xf5facb93, 0x7262d75c, 0x6b79e61d, + 0x4054b5de, 0x594f849f, 0x160e1258, 0x0f152319, 0x243870da, + 0x3d23419b, 0x65fd6ba7, 0x7ce65ae6, 0x57cb0925, 0x4ed03864, + 0x0191aea3, 0x188a9fe2, 0x33a7cc21, 0x2abcfd60, 0xad24e1af, + 0xb43fd0ee, 0x9f12832d, 0x8609b26c, 0xc94824ab, 0xd05315ea, + 0xfb7e4629, 0xe2657768, 0x2f3f79f6, 0x362448b7, 0x1d091b74, + 0x04122a35, 0x4b53bcf2, 0x52488db3, 0x7965de70, 0x607eef31, + 0xe7e6f3fe, 0xfefdc2bf, 0xd5d0917c, 0xcccba03d, 0x838a36fa, + 0x9a9107bb, 0xb1bc5478, 0xa8a76539, 0x3b83984b, 0x2298a90a, + 0x09b5fac9, 0x10aecb88, 0x5fef5d4f, 0x46f46c0e, 0x6dd93fcd, + 0x74c20e8c, 0xf35a1243, 0xea412302, 0xc16c70c1, 0xd8774180, + 0x9736d747, 0x8e2de606, 0xa500b5c5, 0xbc1b8484, 0x71418a1a, + 0x685abb5b, 0x4377e898, 0x5a6cd9d9, 0x152d4f1e, 0x0c367e5f, + 0x271b2d9c, 0x3e001cdd, 0xb9980012, 0xa0833153, 0x8bae6290, + 0x92b553d1, 0xddf4c516, 0xc4eff457, 0xefc2a794, 0xf6d996d5, + 0xae07bce9, 0xb71c8da8, 0x9c31de6b, 0x852aef2a, 0xca6b79ed, + 0xd37048ac, 0xf85d1b6f, 0xe1462a2e, 0x66de36e1, 0x7fc507a0, + 0x54e85463, 0x4df36522, 0x02b2f3e5, 0x1ba9c2a4, 0x30849167, + 0x299fa026, 0xe4c5aeb8, 0xfdde9ff9, 0xd6f3cc3a, 0xcfe8fd7b, + 0x80a96bbc, 0x99b25afd, 0xb29f093e, 0xab84387f, 0x2c1c24b0, + 0x350715f1, 0x1e2a4632, 0x07317773, 0x4870e1b4, 0x516bd0f5, + 0x7a468336, 0x635db277, 0xcbfad74e, 0xd2e1e60f, 0xf9ccb5cc, + 0xe0d7848d, 0xaf96124a, 0xb68d230b, 0x9da070c8, 0x84bb4189, + 0x03235d46, 0x1a386c07, 0x31153fc4, 0x280e0e85, 0x674f9842, + 0x7e54a903, 0x5579fac0, 0x4c62cb81, 0x8138c51f, 0x9823f45e, + 0xb30ea79d, 0xaa1596dc, 0xe554001b, 0xfc4f315a, 0xd7626299, + 0xce7953d8, 0x49e14f17, 0x50fa7e56, 0x7bd72d95, 0x62cc1cd4, + 0x2d8d8a13, 0x3496bb52, 0x1fbbe891, 0x06a0d9d0, 0x5e7ef3ec, + 0x4765c2ad, 0x6c48916e, 0x7553a02f, 0x3a1236e8, 0x230907a9, + 0x0824546a, 0x113f652b, 0x96a779e4, 0x8fbc48a5, 0xa4911b66, + 0xbd8a2a27, 0xf2cbbce0, 0xebd08da1, 0xc0fdde62, 0xd9e6ef23, + 0x14bce1bd, 0x0da7d0fc, 0x268a833f, 0x3f91b27e, 0x70d024b9, + 0x69cb15f8, 0x42e6463b, 0x5bfd777a, 0xdc656bb5, 0xc57e5af4, + 0xee530937, 0xf7483876, 0xb809aeb1, 0xa1129ff0, 0x8a3fcc33, + 0x9324fd72}, + {0x00000000, 0x77073096, 0xee0e612c, 0x990951ba, 0x076dc419, + 0x706af48f, 0xe963a535, 0x9e6495a3, 0x0edb8832, 0x79dcb8a4, + 0xe0d5e91e, 0x97d2d988, 0x09b64c2b, 0x7eb17cbd, 0xe7b82d07, + 0x90bf1d91, 0x1db71064, 0x6ab020f2, 0xf3b97148, 0x84be41de, + 0x1adad47d, 0x6ddde4eb, 0xf4d4b551, 0x83d385c7, 0x136c9856, + 0x646ba8c0, 0xfd62f97a, 0x8a65c9ec, 0x14015c4f, 0x63066cd9, + 0xfa0f3d63, 0x8d080df5, 0x3b6e20c8, 0x4c69105e, 0xd56041e4, + 0xa2677172, 0x3c03e4d1, 0x4b04d447, 0xd20d85fd, 0xa50ab56b, + 0x35b5a8fa, 0x42b2986c, 0xdbbbc9d6, 0xacbcf940, 0x32d86ce3, + 0x45df5c75, 0xdcd60dcf, 0xabd13d59, 0x26d930ac, 0x51de003a, + 0xc8d75180, 0xbfd06116, 0x21b4f4b5, 0x56b3c423, 0xcfba9599, + 0xb8bda50f, 0x2802b89e, 0x5f058808, 0xc60cd9b2, 0xb10be924, + 0x2f6f7c87, 0x58684c11, 0xc1611dab, 0xb6662d3d, 0x76dc4190, + 0x01db7106, 0x98d220bc, 0xefd5102a, 0x71b18589, 0x06b6b51f, + 0x9fbfe4a5, 0xe8b8d433, 0x7807c9a2, 0x0f00f934, 0x9609a88e, + 0xe10e9818, 0x7f6a0dbb, 0x086d3d2d, 0x91646c97, 0xe6635c01, + 0x6b6b51f4, 0x1c6c6162, 0x856530d8, 0xf262004e, 0x6c0695ed, + 0x1b01a57b, 0x8208f4c1, 0xf50fc457, 0x65b0d9c6, 0x12b7e950, + 0x8bbeb8ea, 0xfcb9887c, 0x62dd1ddf, 0x15da2d49, 0x8cd37cf3, + 0xfbd44c65, 0x4db26158, 0x3ab551ce, 0xa3bc0074, 0xd4bb30e2, + 0x4adfa541, 0x3dd895d7, 0xa4d1c46d, 0xd3d6f4fb, 0x4369e96a, + 0x346ed9fc, 0xad678846, 0xda60b8d0, 0x44042d73, 0x33031de5, + 0xaa0a4c5f, 0xdd0d7cc9, 0x5005713c, 0x270241aa, 0xbe0b1010, + 0xc90c2086, 0x5768b525, 0x206f85b3, 0xb966d409, 0xce61e49f, + 0x5edef90e, 0x29d9c998, 0xb0d09822, 0xc7d7a8b4, 0x59b33d17, + 0x2eb40d81, 0xb7bd5c3b, 0xc0ba6cad, 0xedb88320, 0x9abfb3b6, + 0x03b6e20c, 0x74b1d29a, 0xead54739, 0x9dd277af, 0x04db2615, + 0x73dc1683, 0xe3630b12, 0x94643b84, 0x0d6d6a3e, 0x7a6a5aa8, + 0xe40ecf0b, 0x9309ff9d, 0x0a00ae27, 0x7d079eb1, 0xf00f9344, + 0x8708a3d2, 0x1e01f268, 0x6906c2fe, 0xf762575d, 0x806567cb, + 0x196c3671, 0x6e6b06e7, 0xfed41b76, 0x89d32be0, 0x10da7a5a, + 0x67dd4acc, 0xf9b9df6f, 0x8ebeeff9, 0x17b7be43, 0x60b08ed5, + 0xd6d6a3e8, 0xa1d1937e, 0x38d8c2c4, 0x4fdff252, 0xd1bb67f1, + 0xa6bc5767, 0x3fb506dd, 0x48b2364b, 0xd80d2bda, 0xaf0a1b4c, + 0x36034af6, 0x41047a60, 0xdf60efc3, 0xa867df55, 0x316e8eef, + 0x4669be79, 0xcb61b38c, 0xbc66831a, 0x256fd2a0, 0x5268e236, + 0xcc0c7795, 0xbb0b4703, 0x220216b9, 0x5505262f, 0xc5ba3bbe, + 0xb2bd0b28, 0x2bb45a92, 0x5cb36a04, 0xc2d7ffa7, 0xb5d0cf31, + 0x2cd99e8b, 0x5bdeae1d, 0x9b64c2b0, 0xec63f226, 0x756aa39c, + 0x026d930a, 0x9c0906a9, 0xeb0e363f, 0x72076785, 0x05005713, + 0x95bf4a82, 0xe2b87a14, 0x7bb12bae, 0x0cb61b38, 0x92d28e9b, + 0xe5d5be0d, 0x7cdcefb7, 0x0bdbdf21, 0x86d3d2d4, 0xf1d4e242, + 0x68ddb3f8, 0x1fda836e, 0x81be16cd, 0xf6b9265b, 0x6fb077e1, + 0x18b74777, 0x88085ae6, 0xff0f6a70, 0x66063bca, 0x11010b5c, + 0x8f659eff, 0xf862ae69, 0x616bffd3, 0x166ccf45, 0xa00ae278, + 0xd70dd2ee, 0x4e048354, 0x3903b3c2, 0xa7672661, 0xd06016f7, + 0x4969474d, 0x3e6e77db, 0xaed16a4a, 0xd9d65adc, 0x40df0b66, + 0x37d83bf0, 0xa9bcae53, 0xdebb9ec5, 0x47b2cf7f, 0x30b5ffe9, + 0xbdbdf21c, 0xcabac28a, 0x53b39330, 0x24b4a3a6, 0xbad03605, + 0xcdd70693, 0x54de5729, 0x23d967bf, 0xb3667a2e, 0xc4614ab8, + 0x5d681b02, 0x2a6f2b94, 0xb40bbe37, 0xc30c8ea1, 0x5a05df1b, + 0x2d02ef8d}}; + +local const z_word_t FAR crc_braid_big_table[][256] = { + {0x00000000, 0x96300777, 0x2c610eee, 0xba510999, 0x19c46d07, + 0x8ff46a70, 0x35a563e9, 0xa395649e, 0x3288db0e, 0xa4b8dc79, + 0x1ee9d5e0, 0x88d9d297, 0x2b4cb609, 0xbd7cb17e, 0x072db8e7, + 0x911dbf90, 0x6410b71d, 0xf220b06a, 0x4871b9f3, 0xde41be84, + 0x7dd4da1a, 0xebe4dd6d, 0x51b5d4f4, 0xc785d383, 0x56986c13, + 0xc0a86b64, 0x7af962fd, 0xecc9658a, 0x4f5c0114, 0xd96c0663, + 0x633d0ffa, 0xf50d088d, 0xc8206e3b, 0x5e10694c, 0xe44160d5, + 0x727167a2, 0xd1e4033c, 0x47d4044b, 0xfd850dd2, 0x6bb50aa5, + 0xfaa8b535, 0x6c98b242, 0xd6c9bbdb, 0x40f9bcac, 0xe36cd832, + 0x755cdf45, 0xcf0dd6dc, 0x593dd1ab, 0xac30d926, 0x3a00de51, + 0x8051d7c8, 0x1661d0bf, 0xb5f4b421, 0x23c4b356, 0x9995bacf, + 0x0fa5bdb8, 0x9eb80228, 0x0888055f, 0xb2d90cc6, 0x24e90bb1, + 0x877c6f2f, 0x114c6858, 0xab1d61c1, 0x3d2d66b6, 0x9041dc76, + 0x0671db01, 0xbc20d298, 0x2a10d5ef, 0x8985b171, 0x1fb5b606, + 0xa5e4bf9f, 0x33d4b8e8, 0xa2c90778, 0x34f9000f, 0x8ea80996, + 0x18980ee1, 0xbb0d6a7f, 0x2d3d6d08, 0x976c6491, 0x015c63e6, + 0xf4516b6b, 0x62616c1c, 0xd8306585, 0x4e0062f2, 0xed95066c, + 0x7ba5011b, 0xc1f40882, 0x57c40ff5, 0xc6d9b065, 0x50e9b712, + 0xeab8be8b, 0x7c88b9fc, 0xdf1ddd62, 0x492dda15, 0xf37cd38c, + 0x654cd4fb, 0x5861b24d, 0xce51b53a, 0x7400bca3, 0xe230bbd4, + 0x41a5df4a, 0xd795d83d, 0x6dc4d1a4, 0xfbf4d6d3, 0x6ae96943, + 0xfcd96e34, 0x468867ad, 0xd0b860da, 0x732d0444, 0xe51d0333, + 0x5f4c0aaa, 0xc97c0ddd, 0x3c710550, 0xaa410227, 0x10100bbe, + 0x86200cc9, 0x25b56857, 0xb3856f20, 0x09d466b9, 0x9fe461ce, + 0x0ef9de5e, 0x98c9d929, 0x2298d0b0, 0xb4a8d7c7, 0x173db359, + 0x810db42e, 0x3b5cbdb7, 0xad6cbac0, 0x2083b8ed, 0xb6b3bf9a, + 0x0ce2b603, 0x9ad2b174, 0x3947d5ea, 0xaf77d29d, 0x1526db04, + 0x8316dc73, 0x120b63e3, 0x843b6494, 0x3e6a6d0d, 0xa85a6a7a, + 0x0bcf0ee4, 0x9dff0993, 0x27ae000a, 0xb19e077d, 0x44930ff0, + 0xd2a30887, 0x68f2011e, 0xfec20669, 0x5d5762f7, 0xcb676580, + 0x71366c19, 0xe7066b6e, 0x761bd4fe, 0xe02bd389, 0x5a7ada10, + 0xcc4add67, 0x6fdfb9f9, 0xf9efbe8e, 0x43beb717, 0xd58eb060, + 0xe8a3d6d6, 0x7e93d1a1, 0xc4c2d838, 0x52f2df4f, 0xf167bbd1, + 0x6757bca6, 0xdd06b53f, 0x4b36b248, 0xda2b0dd8, 0x4c1b0aaf, + 0xf64a0336, 0x607a0441, 0xc3ef60df, 0x55df67a8, 0xef8e6e31, + 0x79be6946, 0x8cb361cb, 0x1a8366bc, 0xa0d26f25, 0x36e26852, + 0x95770ccc, 0x03470bbb, 0xb9160222, 0x2f260555, 0xbe3bbac5, + 0x280bbdb2, 0x925ab42b, 0x046ab35c, 0xa7ffd7c2, 0x31cfd0b5, + 0x8b9ed92c, 0x1daede5b, 0xb0c2649b, 0x26f263ec, 0x9ca36a75, + 0x0a936d02, 0xa906099c, 0x3f360eeb, 0x85670772, 0x13570005, + 0x824abf95, 0x147ab8e2, 0xae2bb17b, 0x381bb60c, 0x9b8ed292, + 0x0dbed5e5, 0xb7efdc7c, 0x21dfdb0b, 0xd4d2d386, 0x42e2d4f1, + 0xf8b3dd68, 0x6e83da1f, 0xcd16be81, 0x5b26b9f6, 0xe177b06f, + 0x7747b718, 0xe65a0888, 0x706a0fff, 0xca3b0666, 0x5c0b0111, + 0xff9e658f, 0x69ae62f8, 0xd3ff6b61, 0x45cf6c16, 0x78e20aa0, + 0xeed20dd7, 0x5483044e, 0xc2b30339, 0x612667a7, 0xf71660d0, + 0x4d476949, 0xdb776e3e, 0x4a6ad1ae, 0xdc5ad6d9, 0x660bdf40, + 0xf03bd837, 0x53aebca9, 0xc59ebbde, 0x7fcfb247, 0xe9ffb530, + 0x1cf2bdbd, 0x8ac2baca, 0x3093b353, 0xa6a3b424, 0x0536d0ba, + 0x9306d7cd, 0x2957de54, 0xbf67d923, 0x2e7a66b3, 0xb84a61c4, + 0x021b685d, 0x942b6f2a, 0x37be0bb4, 0xa18e0cc3, 0x1bdf055a, + 0x8def022d}, + {0x00000000, 0x41311b19, 0x82623632, 0xc3532d2b, 0x04c56c64, + 0x45f4777d, 0x86a75a56, 0xc796414f, 0x088ad9c8, 0x49bbc2d1, + 0x8ae8effa, 0xcbd9f4e3, 0x0c4fb5ac, 0x4d7eaeb5, 0x8e2d839e, + 0xcf1c9887, 0x5112c24a, 0x1023d953, 0xd370f478, 0x9241ef61, + 0x55d7ae2e, 0x14e6b537, 0xd7b5981c, 0x96848305, 0x59981b82, + 0x18a9009b, 0xdbfa2db0, 0x9acb36a9, 0x5d5d77e6, 0x1c6c6cff, + 0xdf3f41d4, 0x9e0e5acd, 0xa2248495, 0xe3159f8c, 0x2046b2a7, + 0x6177a9be, 0xa6e1e8f1, 0xe7d0f3e8, 0x2483dec3, 0x65b2c5da, + 0xaaae5d5d, 0xeb9f4644, 0x28cc6b6f, 0x69fd7076, 0xae6b3139, + 0xef5a2a20, 0x2c09070b, 0x6d381c12, 0xf33646df, 0xb2075dc6, + 0x715470ed, 0x30656bf4, 0xf7f32abb, 0xb6c231a2, 0x75911c89, + 0x34a00790, 0xfbbc9f17, 0xba8d840e, 0x79dea925, 0x38efb23c, + 0xff79f373, 0xbe48e86a, 0x7d1bc541, 0x3c2ade58, 0x054f79f0, + 0x447e62e9, 0x872d4fc2, 0xc61c54db, 0x018a1594, 0x40bb0e8d, + 0x83e823a6, 0xc2d938bf, 0x0dc5a038, 0x4cf4bb21, 0x8fa7960a, + 0xce968d13, 0x0900cc5c, 0x4831d745, 0x8b62fa6e, 0xca53e177, + 0x545dbbba, 0x156ca0a3, 0xd63f8d88, 0x970e9691, 0x5098d7de, + 0x11a9ccc7, 0xd2fae1ec, 0x93cbfaf5, 0x5cd76272, 0x1de6796b, + 0xdeb55440, 0x9f844f59, 0x58120e16, 0x1923150f, 0xda703824, + 0x9b41233d, 0xa76bfd65, 0xe65ae67c, 0x2509cb57, 0x6438d04e, + 0xa3ae9101, 0xe29f8a18, 0x21cca733, 0x60fdbc2a, 0xafe124ad, + 0xeed03fb4, 0x2d83129f, 0x6cb20986, 0xab2448c9, 0xea1553d0, + 0x29467efb, 0x687765e2, 0xf6793f2f, 0xb7482436, 0x741b091d, + 0x352a1204, 0xf2bc534b, 0xb38d4852, 0x70de6579, 0x31ef7e60, + 0xfef3e6e7, 0xbfc2fdfe, 0x7c91d0d5, 0x3da0cbcc, 0xfa368a83, + 0xbb07919a, 0x7854bcb1, 0x3965a7a8, 0x4b98833b, 0x0aa99822, + 0xc9fab509, 0x88cbae10, 0x4f5def5f, 0x0e6cf446, 0xcd3fd96d, + 0x8c0ec274, 0x43125af3, 0x022341ea, 0xc1706cc1, 0x804177d8, + 0x47d73697, 0x06e62d8e, 0xc5b500a5, 0x84841bbc, 0x1a8a4171, + 0x5bbb5a68, 0x98e87743, 0xd9d96c5a, 0x1e4f2d15, 0x5f7e360c, + 0x9c2d1b27, 0xdd1c003e, 0x120098b9, 0x533183a0, 0x9062ae8b, + 0xd153b592, 0x16c5f4dd, 0x57f4efc4, 0x94a7c2ef, 0xd596d9f6, + 0xe9bc07ae, 0xa88d1cb7, 0x6bde319c, 0x2aef2a85, 0xed796bca, + 0xac4870d3, 0x6f1b5df8, 0x2e2a46e1, 0xe136de66, 0xa007c57f, + 0x6354e854, 0x2265f34d, 0xe5f3b202, 0xa4c2a91b, 0x67918430, + 0x26a09f29, 0xb8aec5e4, 0xf99fdefd, 0x3accf3d6, 0x7bfde8cf, + 0xbc6ba980, 0xfd5ab299, 0x3e099fb2, 0x7f3884ab, 0xb0241c2c, + 0xf1150735, 0x32462a1e, 0x73773107, 0xb4e17048, 0xf5d06b51, + 0x3683467a, 0x77b25d63, 0x4ed7facb, 0x0fe6e1d2, 0xccb5ccf9, + 0x8d84d7e0, 0x4a1296af, 0x0b238db6, 0xc870a09d, 0x8941bb84, + 0x465d2303, 0x076c381a, 0xc43f1531, 0x850e0e28, 0x42984f67, + 0x03a9547e, 0xc0fa7955, 0x81cb624c, 0x1fc53881, 0x5ef42398, + 0x9da70eb3, 0xdc9615aa, 0x1b0054e5, 0x5a314ffc, 0x996262d7, + 0xd85379ce, 0x174fe149, 0x567efa50, 0x952dd77b, 0xd41ccc62, + 0x138a8d2d, 0x52bb9634, 0x91e8bb1f, 0xd0d9a006, 0xecf37e5e, + 0xadc26547, 0x6e91486c, 0x2fa05375, 0xe836123a, 0xa9070923, + 0x6a542408, 0x2b653f11, 0xe479a796, 0xa548bc8f, 0x661b91a4, + 0x272a8abd, 0xe0bccbf2, 0xa18dd0eb, 0x62defdc0, 0x23efe6d9, + 0xbde1bc14, 0xfcd0a70d, 0x3f838a26, 0x7eb2913f, 0xb924d070, + 0xf815cb69, 0x3b46e642, 0x7a77fd5b, 0xb56b65dc, 0xf45a7ec5, + 0x370953ee, 0x763848f7, 0xb1ae09b8, 0xf09f12a1, 0x33cc3f8a, + 0x72fd2493}, + {0x00000000, 0x376ac201, 0x6ed48403, 0x59be4602, 0xdca80907, + 0xebc2cb06, 0xb27c8d04, 0x85164f05, 0xb851130e, 0x8f3bd10f, + 0xd685970d, 0xe1ef550c, 0x64f91a09, 0x5393d808, 0x0a2d9e0a, + 0x3d475c0b, 0x70a3261c, 0x47c9e41d, 0x1e77a21f, 0x291d601e, + 0xac0b2f1b, 0x9b61ed1a, 0xc2dfab18, 0xf5b56919, 0xc8f23512, + 0xff98f713, 0xa626b111, 0x914c7310, 0x145a3c15, 0x2330fe14, + 0x7a8eb816, 0x4de47a17, 0xe0464d38, 0xd72c8f39, 0x8e92c93b, + 0xb9f80b3a, 0x3cee443f, 0x0b84863e, 0x523ac03c, 0x6550023d, + 0x58175e36, 0x6f7d9c37, 0x36c3da35, 0x01a91834, 0x84bf5731, + 0xb3d59530, 0xea6bd332, 0xdd011133, 0x90e56b24, 0xa78fa925, + 0xfe31ef27, 0xc95b2d26, 0x4c4d6223, 0x7b27a022, 0x2299e620, + 0x15f32421, 0x28b4782a, 0x1fdeba2b, 0x4660fc29, 0x710a3e28, + 0xf41c712d, 0xc376b32c, 0x9ac8f52e, 0xada2372f, 0xc08d9a70, + 0xf7e75871, 0xae591e73, 0x9933dc72, 0x1c259377, 0x2b4f5176, + 0x72f11774, 0x459bd575, 0x78dc897e, 0x4fb64b7f, 0x16080d7d, + 0x2162cf7c, 0xa4748079, 0x931e4278, 0xcaa0047a, 0xfdcac67b, + 0xb02ebc6c, 0x87447e6d, 0xdefa386f, 0xe990fa6e, 0x6c86b56b, + 0x5bec776a, 0x02523168, 0x3538f369, 0x087faf62, 0x3f156d63, + 0x66ab2b61, 0x51c1e960, 0xd4d7a665, 0xe3bd6464, 0xba032266, + 0x8d69e067, 0x20cbd748, 0x17a11549, 0x4e1f534b, 0x7975914a, + 0xfc63de4f, 0xcb091c4e, 0x92b75a4c, 0xa5dd984d, 0x989ac446, + 0xaff00647, 0xf64e4045, 0xc1248244, 0x4432cd41, 0x73580f40, + 0x2ae64942, 0x1d8c8b43, 0x5068f154, 0x67023355, 0x3ebc7557, + 0x09d6b756, 0x8cc0f853, 0xbbaa3a52, 0xe2147c50, 0xd57ebe51, + 0xe839e25a, 0xdf53205b, 0x86ed6659, 0xb187a458, 0x3491eb5d, + 0x03fb295c, 0x5a456f5e, 0x6d2fad5f, 0x801b35e1, 0xb771f7e0, + 0xeecfb1e2, 0xd9a573e3, 0x5cb33ce6, 0x6bd9fee7, 0x3267b8e5, + 0x050d7ae4, 0x384a26ef, 0x0f20e4ee, 0x569ea2ec, 0x61f460ed, + 0xe4e22fe8, 0xd388ede9, 0x8a36abeb, 0xbd5c69ea, 0xf0b813fd, + 0xc7d2d1fc, 0x9e6c97fe, 0xa90655ff, 0x2c101afa, 0x1b7ad8fb, + 0x42c49ef9, 0x75ae5cf8, 0x48e900f3, 0x7f83c2f2, 0x263d84f0, + 0x115746f1, 0x944109f4, 0xa32bcbf5, 0xfa958df7, 0xcdff4ff6, + 0x605d78d9, 0x5737bad8, 0x0e89fcda, 0x39e33edb, 0xbcf571de, + 0x8b9fb3df, 0xd221f5dd, 0xe54b37dc, 0xd80c6bd7, 0xef66a9d6, + 0xb6d8efd4, 0x81b22dd5, 0x04a462d0, 0x33cea0d1, 0x6a70e6d3, + 0x5d1a24d2, 0x10fe5ec5, 0x27949cc4, 0x7e2adac6, 0x494018c7, + 0xcc5657c2, 0xfb3c95c3, 0xa282d3c1, 0x95e811c0, 0xa8af4dcb, + 0x9fc58fca, 0xc67bc9c8, 0xf1110bc9, 0x740744cc, 0x436d86cd, + 0x1ad3c0cf, 0x2db902ce, 0x4096af91, 0x77fc6d90, 0x2e422b92, + 0x1928e993, 0x9c3ea696, 0xab546497, 0xf2ea2295, 0xc580e094, + 0xf8c7bc9f, 0xcfad7e9e, 0x9613389c, 0xa179fa9d, 0x246fb598, + 0x13057799, 0x4abb319b, 0x7dd1f39a, 0x3035898d, 0x075f4b8c, + 0x5ee10d8e, 0x698bcf8f, 0xec9d808a, 0xdbf7428b, 0x82490489, + 0xb523c688, 0x88649a83, 0xbf0e5882, 0xe6b01e80, 0xd1dadc81, + 0x54cc9384, 0x63a65185, 0x3a181787, 0x0d72d586, 0xa0d0e2a9, + 0x97ba20a8, 0xce0466aa, 0xf96ea4ab, 0x7c78ebae, 0x4b1229af, + 0x12ac6fad, 0x25c6adac, 0x1881f1a7, 0x2feb33a6, 0x765575a4, + 0x413fb7a5, 0xc429f8a0, 0xf3433aa1, 0xaafd7ca3, 0x9d97bea2, + 0xd073c4b5, 0xe71906b4, 0xbea740b6, 0x89cd82b7, 0x0cdbcdb2, + 0x3bb10fb3, 0x620f49b1, 0x55658bb0, 0x6822d7bb, 0x5f4815ba, + 0x06f653b8, 0x319c91b9, 0xb48adebc, 0x83e01cbd, 0xda5e5abf, + 0xed3498be}, + {0x00000000, 0x6567bcb8, 0x8bc809aa, 0xeeafb512, 0x5797628f, + 0x32f0de37, 0xdc5f6b25, 0xb938d79d, 0xef28b4c5, 0x8a4f087d, + 0x64e0bd6f, 0x018701d7, 0xb8bfd64a, 0xddd86af2, 0x3377dfe0, + 0x56106358, 0x9f571950, 0xfa30a5e8, 0x149f10fa, 0x71f8ac42, + 0xc8c07bdf, 0xada7c767, 0x43087275, 0x266fcecd, 0x707fad95, + 0x1518112d, 0xfbb7a43f, 0x9ed01887, 0x27e8cf1a, 0x428f73a2, + 0xac20c6b0, 0xc9477a08, 0x3eaf32a0, 0x5bc88e18, 0xb5673b0a, + 0xd00087b2, 0x6938502f, 0x0c5fec97, 0xe2f05985, 0x8797e53d, + 0xd1878665, 0xb4e03add, 0x5a4f8fcf, 0x3f283377, 0x8610e4ea, + 0xe3775852, 0x0dd8ed40, 0x68bf51f8, 0xa1f82bf0, 0xc49f9748, + 0x2a30225a, 0x4f579ee2, 0xf66f497f, 0x9308f5c7, 0x7da740d5, + 0x18c0fc6d, 0x4ed09f35, 0x2bb7238d, 0xc518969f, 0xa07f2a27, + 0x1947fdba, 0x7c204102, 0x928ff410, 0xf7e848a8, 0x3d58149b, + 0x583fa823, 0xb6901d31, 0xd3f7a189, 0x6acf7614, 0x0fa8caac, + 0xe1077fbe, 0x8460c306, 0xd270a05e, 0xb7171ce6, 0x59b8a9f4, + 0x3cdf154c, 0x85e7c2d1, 0xe0807e69, 0x0e2fcb7b, 0x6b4877c3, + 0xa20f0dcb, 0xc768b173, 0x29c70461, 0x4ca0b8d9, 0xf5986f44, + 0x90ffd3fc, 0x7e5066ee, 0x1b37da56, 0x4d27b90e, 0x284005b6, + 0xc6efb0a4, 0xa3880c1c, 0x1ab0db81, 0x7fd76739, 0x9178d22b, + 0xf41f6e93, 0x03f7263b, 0x66909a83, 0x883f2f91, 0xed589329, + 0x546044b4, 0x3107f80c, 0xdfa84d1e, 0xbacff1a6, 0xecdf92fe, + 0x89b82e46, 0x67179b54, 0x027027ec, 0xbb48f071, 0xde2f4cc9, + 0x3080f9db, 0x55e74563, 0x9ca03f6b, 0xf9c783d3, 0x176836c1, + 0x720f8a79, 0xcb375de4, 0xae50e15c, 0x40ff544e, 0x2598e8f6, + 0x73888bae, 0x16ef3716, 0xf8408204, 0x9d273ebc, 0x241fe921, + 0x41785599, 0xafd7e08b, 0xcab05c33, 0x3bb659ed, 0x5ed1e555, + 0xb07e5047, 0xd519ecff, 0x6c213b62, 0x094687da, 0xe7e932c8, + 0x828e8e70, 0xd49eed28, 0xb1f95190, 0x5f56e482, 0x3a31583a, + 0x83098fa7, 0xe66e331f, 0x08c1860d, 0x6da63ab5, 0xa4e140bd, + 0xc186fc05, 0x2f294917, 0x4a4ef5af, 0xf3762232, 0x96119e8a, + 0x78be2b98, 0x1dd99720, 0x4bc9f478, 0x2eae48c0, 0xc001fdd2, + 0xa566416a, 0x1c5e96f7, 0x79392a4f, 0x97969f5d, 0xf2f123e5, + 0x05196b4d, 0x607ed7f5, 0x8ed162e7, 0xebb6de5f, 0x528e09c2, + 0x37e9b57a, 0xd9460068, 0xbc21bcd0, 0xea31df88, 0x8f566330, + 0x61f9d622, 0x049e6a9a, 0xbda6bd07, 0xd8c101bf, 0x366eb4ad, + 0x53090815, 0x9a4e721d, 0xff29cea5, 0x11867bb7, 0x74e1c70f, + 0xcdd91092, 0xa8beac2a, 0x46111938, 0x2376a580, 0x7566c6d8, + 0x10017a60, 0xfeaecf72, 0x9bc973ca, 0x22f1a457, 0x479618ef, + 0xa939adfd, 0xcc5e1145, 0x06ee4d76, 0x6389f1ce, 0x8d2644dc, + 0xe841f864, 0x51792ff9, 0x341e9341, 0xdab12653, 0xbfd69aeb, + 0xe9c6f9b3, 0x8ca1450b, 0x620ef019, 0x07694ca1, 0xbe519b3c, + 0xdb362784, 0x35999296, 0x50fe2e2e, 0x99b95426, 0xfcdee89e, + 0x12715d8c, 0x7716e134, 0xce2e36a9, 0xab498a11, 0x45e63f03, + 0x208183bb, 0x7691e0e3, 0x13f65c5b, 0xfd59e949, 0x983e55f1, + 0x2106826c, 0x44613ed4, 0xaace8bc6, 0xcfa9377e, 0x38417fd6, + 0x5d26c36e, 0xb389767c, 0xd6eecac4, 0x6fd61d59, 0x0ab1a1e1, + 0xe41e14f3, 0x8179a84b, 0xd769cb13, 0xb20e77ab, 0x5ca1c2b9, + 0x39c67e01, 0x80fea99c, 0xe5991524, 0x0b36a036, 0x6e511c8e, + 0xa7166686, 0xc271da3e, 0x2cde6f2c, 0x49b9d394, 0xf0810409, + 0x95e6b8b1, 0x7b490da3, 0x1e2eb11b, 0x483ed243, 0x2d596efb, + 0xc3f6dbe9, 0xa6916751, 0x1fa9b0cc, 0x7ace0c74, 0x9461b966, + 0xf10605de}}; + +#endif + +#endif + +#if N == 2 + +#if W == 8 + +local const z_crc_t FAR crc_braid_table[][256] = { + {0x00000000, 0xae689191, 0x87a02563, 0x29c8b4f2, 0xd4314c87, + 0x7a59dd16, 0x539169e4, 0xfdf9f875, 0x73139f4f, 0xdd7b0ede, + 0xf4b3ba2c, 0x5adb2bbd, 0xa722d3c8, 0x094a4259, 0x2082f6ab, + 0x8eea673a, 0xe6273e9e, 0x484faf0f, 0x61871bfd, 0xcfef8a6c, + 0x32167219, 0x9c7ee388, 0xb5b6577a, 0x1bdec6eb, 0x9534a1d1, + 0x3b5c3040, 0x129484b2, 0xbcfc1523, 0x4105ed56, 0xef6d7cc7, + 0xc6a5c835, 0x68cd59a4, 0x173f7b7d, 0xb957eaec, 0x909f5e1e, + 0x3ef7cf8f, 0xc30e37fa, 0x6d66a66b, 0x44ae1299, 0xeac68308, + 0x642ce432, 0xca4475a3, 0xe38cc151, 0x4de450c0, 0xb01da8b5, + 0x1e753924, 0x37bd8dd6, 0x99d51c47, 0xf11845e3, 0x5f70d472, + 0x76b86080, 0xd8d0f111, 0x25290964, 0x8b4198f5, 0xa2892c07, + 0x0ce1bd96, 0x820bdaac, 0x2c634b3d, 0x05abffcf, 0xabc36e5e, + 0x563a962b, 0xf85207ba, 0xd19ab348, 0x7ff222d9, 0x2e7ef6fa, + 0x8016676b, 0xa9ded399, 0x07b64208, 0xfa4fba7d, 0x54272bec, + 0x7def9f1e, 0xd3870e8f, 0x5d6d69b5, 0xf305f824, 0xdacd4cd6, + 0x74a5dd47, 0x895c2532, 0x2734b4a3, 0x0efc0051, 0xa09491c0, + 0xc859c864, 0x663159f5, 0x4ff9ed07, 0xe1917c96, 0x1c6884e3, + 0xb2001572, 0x9bc8a180, 0x35a03011, 0xbb4a572b, 0x1522c6ba, + 0x3cea7248, 0x9282e3d9, 0x6f7b1bac, 0xc1138a3d, 0xe8db3ecf, + 0x46b3af5e, 0x39418d87, 0x97291c16, 0xbee1a8e4, 0x10893975, + 0xed70c100, 0x43185091, 0x6ad0e463, 0xc4b875f2, 0x4a5212c8, + 0xe43a8359, 0xcdf237ab, 0x639aa63a, 0x9e635e4f, 0x300bcfde, + 0x19c37b2c, 0xb7abeabd, 0xdf66b319, 0x710e2288, 0x58c6967a, + 0xf6ae07eb, 0x0b57ff9e, 0xa53f6e0f, 0x8cf7dafd, 0x229f4b6c, + 0xac752c56, 0x021dbdc7, 0x2bd50935, 0x85bd98a4, 0x784460d1, + 0xd62cf140, 0xffe445b2, 0x518cd423, 0x5cfdedf4, 0xf2957c65, + 0xdb5dc897, 0x75355906, 0x88cca173, 0x26a430e2, 0x0f6c8410, + 0xa1041581, 0x2fee72bb, 0x8186e32a, 0xa84e57d8, 0x0626c649, + 0xfbdf3e3c, 0x55b7afad, 0x7c7f1b5f, 0xd2178ace, 0xbadad36a, + 0x14b242fb, 0x3d7af609, 0x93126798, 0x6eeb9fed, 0xc0830e7c, + 0xe94bba8e, 0x47232b1f, 0xc9c94c25, 0x67a1ddb4, 0x4e696946, + 0xe001f8d7, 0x1df800a2, 0xb3909133, 0x9a5825c1, 0x3430b450, + 0x4bc29689, 0xe5aa0718, 0xcc62b3ea, 0x620a227b, 0x9ff3da0e, + 0x319b4b9f, 0x1853ff6d, 0xb63b6efc, 0x38d109c6, 0x96b99857, + 0xbf712ca5, 0x1119bd34, 0xece04541, 0x4288d4d0, 0x6b406022, + 0xc528f1b3, 0xade5a817, 0x038d3986, 0x2a458d74, 0x842d1ce5, + 0x79d4e490, 0xd7bc7501, 0xfe74c1f3, 0x501c5062, 0xdef63758, + 0x709ea6c9, 0x5956123b, 0xf73e83aa, 0x0ac77bdf, 0xa4afea4e, + 0x8d675ebc, 0x230fcf2d, 0x72831b0e, 0xdceb8a9f, 0xf5233e6d, + 0x5b4baffc, 0xa6b25789, 0x08dac618, 0x211272ea, 0x8f7ae37b, + 0x01908441, 0xaff815d0, 0x8630a122, 0x285830b3, 0xd5a1c8c6, + 0x7bc95957, 0x5201eda5, 0xfc697c34, 0x94a42590, 0x3accb401, + 0x130400f3, 0xbd6c9162, 0x40956917, 0xeefdf886, 0xc7354c74, + 0x695ddde5, 0xe7b7badf, 0x49df2b4e, 0x60179fbc, 0xce7f0e2d, + 0x3386f658, 0x9dee67c9, 0xb426d33b, 0x1a4e42aa, 0x65bc6073, + 0xcbd4f1e2, 0xe21c4510, 0x4c74d481, 0xb18d2cf4, 0x1fe5bd65, + 0x362d0997, 0x98459806, 0x16afff3c, 0xb8c76ead, 0x910fda5f, + 0x3f674bce, 0xc29eb3bb, 0x6cf6222a, 0x453e96d8, 0xeb560749, + 0x839b5eed, 0x2df3cf7c, 0x043b7b8e, 0xaa53ea1f, 0x57aa126a, + 0xf9c283fb, 0xd00a3709, 0x7e62a698, 0xf088c1a2, 0x5ee05033, + 0x7728e4c1, 0xd9407550, 0x24b98d25, 0x8ad11cb4, 0xa319a846, + 0x0d7139d7}, + {0x00000000, 0xb9fbdbe8, 0xa886b191, 0x117d6a79, 0x8a7c6563, + 0x3387be8b, 0x22fad4f2, 0x9b010f1a, 0xcf89cc87, 0x7672176f, + 0x670f7d16, 0xdef4a6fe, 0x45f5a9e4, 0xfc0e720c, 0xed731875, + 0x5488c39d, 0x44629f4f, 0xfd9944a7, 0xece42ede, 0x551ff536, + 0xce1efa2c, 0x77e521c4, 0x66984bbd, 0xdf639055, 0x8beb53c8, + 0x32108820, 0x236de259, 0x9a9639b1, 0x019736ab, 0xb86ced43, + 0xa911873a, 0x10ea5cd2, 0x88c53e9e, 0x313ee576, 0x20438f0f, + 0x99b854e7, 0x02b95bfd, 0xbb428015, 0xaa3fea6c, 0x13c43184, + 0x474cf219, 0xfeb729f1, 0xefca4388, 0x56319860, 0xcd30977a, + 0x74cb4c92, 0x65b626eb, 0xdc4dfd03, 0xcca7a1d1, 0x755c7a39, + 0x64211040, 0xdddacba8, 0x46dbc4b2, 0xff201f5a, 0xee5d7523, + 0x57a6aecb, 0x032e6d56, 0xbad5b6be, 0xaba8dcc7, 0x1253072f, + 0x89520835, 0x30a9d3dd, 0x21d4b9a4, 0x982f624c, 0xcafb7b7d, + 0x7300a095, 0x627dcaec, 0xdb861104, 0x40871e1e, 0xf97cc5f6, + 0xe801af8f, 0x51fa7467, 0x0572b7fa, 0xbc896c12, 0xadf4066b, + 0x140fdd83, 0x8f0ed299, 0x36f50971, 0x27886308, 0x9e73b8e0, + 0x8e99e432, 0x37623fda, 0x261f55a3, 0x9fe48e4b, 0x04e58151, + 0xbd1e5ab9, 0xac6330c0, 0x1598eb28, 0x411028b5, 0xf8ebf35d, + 0xe9969924, 0x506d42cc, 0xcb6c4dd6, 0x7297963e, 0x63eafc47, + 0xda1127af, 0x423e45e3, 0xfbc59e0b, 0xeab8f472, 0x53432f9a, + 0xc8422080, 0x71b9fb68, 0x60c49111, 0xd93f4af9, 0x8db78964, + 0x344c528c, 0x253138f5, 0x9ccae31d, 0x07cbec07, 0xbe3037ef, + 0xaf4d5d96, 0x16b6867e, 0x065cdaac, 0xbfa70144, 0xaeda6b3d, + 0x1721b0d5, 0x8c20bfcf, 0x35db6427, 0x24a60e5e, 0x9d5dd5b6, + 0xc9d5162b, 0x702ecdc3, 0x6153a7ba, 0xd8a87c52, 0x43a97348, + 0xfa52a8a0, 0xeb2fc2d9, 0x52d41931, 0x4e87f0bb, 0xf77c2b53, + 0xe601412a, 0x5ffa9ac2, 0xc4fb95d8, 0x7d004e30, 0x6c7d2449, + 0xd586ffa1, 0x810e3c3c, 0x38f5e7d4, 0x29888dad, 0x90735645, + 0x0b72595f, 0xb28982b7, 0xa3f4e8ce, 0x1a0f3326, 0x0ae56ff4, + 0xb31eb41c, 0xa263de65, 0x1b98058d, 0x80990a97, 0x3962d17f, + 0x281fbb06, 0x91e460ee, 0xc56ca373, 0x7c97789b, 0x6dea12e2, + 0xd411c90a, 0x4f10c610, 0xf6eb1df8, 0xe7967781, 0x5e6dac69, + 0xc642ce25, 0x7fb915cd, 0x6ec47fb4, 0xd73fa45c, 0x4c3eab46, + 0xf5c570ae, 0xe4b81ad7, 0x5d43c13f, 0x09cb02a2, 0xb030d94a, + 0xa14db333, 0x18b668db, 0x83b767c1, 0x3a4cbc29, 0x2b31d650, + 0x92ca0db8, 0x8220516a, 0x3bdb8a82, 0x2aa6e0fb, 0x935d3b13, + 0x085c3409, 0xb1a7efe1, 0xa0da8598, 0x19215e70, 0x4da99ded, + 0xf4524605, 0xe52f2c7c, 0x5cd4f794, 0xc7d5f88e, 0x7e2e2366, + 0x6f53491f, 0xd6a892f7, 0x847c8bc6, 0x3d87502e, 0x2cfa3a57, + 0x9501e1bf, 0x0e00eea5, 0xb7fb354d, 0xa6865f34, 0x1f7d84dc, + 0x4bf54741, 0xf20e9ca9, 0xe373f6d0, 0x5a882d38, 0xc1892222, + 0x7872f9ca, 0x690f93b3, 0xd0f4485b, 0xc01e1489, 0x79e5cf61, + 0x6898a518, 0xd1637ef0, 0x4a6271ea, 0xf399aa02, 0xe2e4c07b, + 0x5b1f1b93, 0x0f97d80e, 0xb66c03e6, 0xa711699f, 0x1eeab277, + 0x85ebbd6d, 0x3c106685, 0x2d6d0cfc, 0x9496d714, 0x0cb9b558, + 0xb5426eb0, 0xa43f04c9, 0x1dc4df21, 0x86c5d03b, 0x3f3e0bd3, + 0x2e4361aa, 0x97b8ba42, 0xc33079df, 0x7acba237, 0x6bb6c84e, + 0xd24d13a6, 0x494c1cbc, 0xf0b7c754, 0xe1caad2d, 0x583176c5, + 0x48db2a17, 0xf120f1ff, 0xe05d9b86, 0x59a6406e, 0xc2a74f74, + 0x7b5c949c, 0x6a21fee5, 0xd3da250d, 0x8752e690, 0x3ea93d78, + 0x2fd45701, 0x962f8ce9, 0x0d2e83f3, 0xb4d5581b, 0xa5a83262, + 0x1c53e98a}, + {0x00000000, 0x9d0fe176, 0xe16ec4ad, 0x7c6125db, 0x19ac8f1b, + 0x84a36e6d, 0xf8c24bb6, 0x65cdaac0, 0x33591e36, 0xae56ff40, + 0xd237da9b, 0x4f383bed, 0x2af5912d, 0xb7fa705b, 0xcb9b5580, + 0x5694b4f6, 0x66b23c6c, 0xfbbddd1a, 0x87dcf8c1, 0x1ad319b7, + 0x7f1eb377, 0xe2115201, 0x9e7077da, 0x037f96ac, 0x55eb225a, + 0xc8e4c32c, 0xb485e6f7, 0x298a0781, 0x4c47ad41, 0xd1484c37, + 0xad2969ec, 0x3026889a, 0xcd6478d8, 0x506b99ae, 0x2c0abc75, + 0xb1055d03, 0xd4c8f7c3, 0x49c716b5, 0x35a6336e, 0xa8a9d218, + 0xfe3d66ee, 0x63328798, 0x1f53a243, 0x825c4335, 0xe791e9f5, + 0x7a9e0883, 0x06ff2d58, 0x9bf0cc2e, 0xabd644b4, 0x36d9a5c2, + 0x4ab88019, 0xd7b7616f, 0xb27acbaf, 0x2f752ad9, 0x53140f02, + 0xce1bee74, 0x988f5a82, 0x0580bbf4, 0x79e19e2f, 0xe4ee7f59, + 0x8123d599, 0x1c2c34ef, 0x604d1134, 0xfd42f042, 0x41b9f7f1, + 0xdcb61687, 0xa0d7335c, 0x3dd8d22a, 0x581578ea, 0xc51a999c, + 0xb97bbc47, 0x24745d31, 0x72e0e9c7, 0xefef08b1, 0x938e2d6a, + 0x0e81cc1c, 0x6b4c66dc, 0xf64387aa, 0x8a22a271, 0x172d4307, + 0x270bcb9d, 0xba042aeb, 0xc6650f30, 0x5b6aee46, 0x3ea74486, + 0xa3a8a5f0, 0xdfc9802b, 0x42c6615d, 0x1452d5ab, 0x895d34dd, + 0xf53c1106, 0x6833f070, 0x0dfe5ab0, 0x90f1bbc6, 0xec909e1d, + 0x719f7f6b, 0x8cdd8f29, 0x11d26e5f, 0x6db34b84, 0xf0bcaaf2, + 0x95710032, 0x087ee144, 0x741fc49f, 0xe91025e9, 0xbf84911f, + 0x228b7069, 0x5eea55b2, 0xc3e5b4c4, 0xa6281e04, 0x3b27ff72, + 0x4746daa9, 0xda493bdf, 0xea6fb345, 0x77605233, 0x0b0177e8, + 0x960e969e, 0xf3c33c5e, 0x6eccdd28, 0x12adf8f3, 0x8fa21985, + 0xd936ad73, 0x44394c05, 0x385869de, 0xa55788a8, 0xc09a2268, + 0x5d95c31e, 0x21f4e6c5, 0xbcfb07b3, 0x8373efe2, 0x1e7c0e94, + 0x621d2b4f, 0xff12ca39, 0x9adf60f9, 0x07d0818f, 0x7bb1a454, + 0xe6be4522, 0xb02af1d4, 0x2d2510a2, 0x51443579, 0xcc4bd40f, + 0xa9867ecf, 0x34899fb9, 0x48e8ba62, 0xd5e75b14, 0xe5c1d38e, + 0x78ce32f8, 0x04af1723, 0x99a0f655, 0xfc6d5c95, 0x6162bde3, + 0x1d039838, 0x800c794e, 0xd698cdb8, 0x4b972cce, 0x37f60915, + 0xaaf9e863, 0xcf3442a3, 0x523ba3d5, 0x2e5a860e, 0xb3556778, + 0x4e17973a, 0xd318764c, 0xaf795397, 0x3276b2e1, 0x57bb1821, + 0xcab4f957, 0xb6d5dc8c, 0x2bda3dfa, 0x7d4e890c, 0xe041687a, + 0x9c204da1, 0x012facd7, 0x64e20617, 0xf9ede761, 0x858cc2ba, + 0x188323cc, 0x28a5ab56, 0xb5aa4a20, 0xc9cb6ffb, 0x54c48e8d, + 0x3109244d, 0xac06c53b, 0xd067e0e0, 0x4d680196, 0x1bfcb560, + 0x86f35416, 0xfa9271cd, 0x679d90bb, 0x02503a7b, 0x9f5fdb0d, + 0xe33efed6, 0x7e311fa0, 0xc2ca1813, 0x5fc5f965, 0x23a4dcbe, + 0xbeab3dc8, 0xdb669708, 0x4669767e, 0x3a0853a5, 0xa707b2d3, + 0xf1930625, 0x6c9ce753, 0x10fdc288, 0x8df223fe, 0xe83f893e, + 0x75306848, 0x09514d93, 0x945eace5, 0xa478247f, 0x3977c509, + 0x4516e0d2, 0xd81901a4, 0xbdd4ab64, 0x20db4a12, 0x5cba6fc9, + 0xc1b58ebf, 0x97213a49, 0x0a2edb3f, 0x764ffee4, 0xeb401f92, + 0x8e8db552, 0x13825424, 0x6fe371ff, 0xf2ec9089, 0x0fae60cb, + 0x92a181bd, 0xeec0a466, 0x73cf4510, 0x1602efd0, 0x8b0d0ea6, + 0xf76c2b7d, 0x6a63ca0b, 0x3cf77efd, 0xa1f89f8b, 0xdd99ba50, + 0x40965b26, 0x255bf1e6, 0xb8541090, 0xc435354b, 0x593ad43d, + 0x691c5ca7, 0xf413bdd1, 0x8872980a, 0x157d797c, 0x70b0d3bc, + 0xedbf32ca, 0x91de1711, 0x0cd1f667, 0x5a454291, 0xc74aa3e7, + 0xbb2b863c, 0x2624674a, 0x43e9cd8a, 0xdee62cfc, 0xa2870927, + 0x3f88e851}, + {0x00000000, 0xdd96d985, 0x605cb54b, 0xbdca6cce, 0xc0b96a96, + 0x1d2fb313, 0xa0e5dfdd, 0x7d730658, 0x5a03d36d, 0x87950ae8, + 0x3a5f6626, 0xe7c9bfa3, 0x9abab9fb, 0x472c607e, 0xfae60cb0, + 0x2770d535, 0xb407a6da, 0x69917f5f, 0xd45b1391, 0x09cdca14, + 0x74becc4c, 0xa92815c9, 0x14e27907, 0xc974a082, 0xee0475b7, + 0x3392ac32, 0x8e58c0fc, 0x53ce1979, 0x2ebd1f21, 0xf32bc6a4, + 0x4ee1aa6a, 0x937773ef, 0xb37e4bf5, 0x6ee89270, 0xd322febe, + 0x0eb4273b, 0x73c72163, 0xae51f8e6, 0x139b9428, 0xce0d4dad, + 0xe97d9898, 0x34eb411d, 0x89212dd3, 0x54b7f456, 0x29c4f20e, + 0xf4522b8b, 0x49984745, 0x940e9ec0, 0x0779ed2f, 0xdaef34aa, + 0x67255864, 0xbab381e1, 0xc7c087b9, 0x1a565e3c, 0xa79c32f2, + 0x7a0aeb77, 0x5d7a3e42, 0x80ece7c7, 0x3d268b09, 0xe0b0528c, + 0x9dc354d4, 0x40558d51, 0xfd9fe19f, 0x2009381a, 0xbd8d91ab, + 0x601b482e, 0xddd124e0, 0x0047fd65, 0x7d34fb3d, 0xa0a222b8, + 0x1d684e76, 0xc0fe97f3, 0xe78e42c6, 0x3a189b43, 0x87d2f78d, + 0x5a442e08, 0x27372850, 0xfaa1f1d5, 0x476b9d1b, 0x9afd449e, + 0x098a3771, 0xd41ceef4, 0x69d6823a, 0xb4405bbf, 0xc9335de7, + 0x14a58462, 0xa96fe8ac, 0x74f93129, 0x5389e41c, 0x8e1f3d99, + 0x33d55157, 0xee4388d2, 0x93308e8a, 0x4ea6570f, 0xf36c3bc1, + 0x2efae244, 0x0ef3da5e, 0xd36503db, 0x6eaf6f15, 0xb339b690, + 0xce4ab0c8, 0x13dc694d, 0xae160583, 0x7380dc06, 0x54f00933, + 0x8966d0b6, 0x34acbc78, 0xe93a65fd, 0x944963a5, 0x49dfba20, + 0xf415d6ee, 0x29830f6b, 0xbaf47c84, 0x6762a501, 0xdaa8c9cf, + 0x073e104a, 0x7a4d1612, 0xa7dbcf97, 0x1a11a359, 0xc7877adc, + 0xe0f7afe9, 0x3d61766c, 0x80ab1aa2, 0x5d3dc327, 0x204ec57f, + 0xfdd81cfa, 0x40127034, 0x9d84a9b1, 0xa06a2517, 0x7dfcfc92, + 0xc036905c, 0x1da049d9, 0x60d34f81, 0xbd459604, 0x008ffaca, + 0xdd19234f, 0xfa69f67a, 0x27ff2fff, 0x9a354331, 0x47a39ab4, + 0x3ad09cec, 0xe7464569, 0x5a8c29a7, 0x871af022, 0x146d83cd, + 0xc9fb5a48, 0x74313686, 0xa9a7ef03, 0xd4d4e95b, 0x094230de, + 0xb4885c10, 0x691e8595, 0x4e6e50a0, 0x93f88925, 0x2e32e5eb, + 0xf3a43c6e, 0x8ed73a36, 0x5341e3b3, 0xee8b8f7d, 0x331d56f8, + 0x13146ee2, 0xce82b767, 0x7348dba9, 0xaede022c, 0xd3ad0474, + 0x0e3bddf1, 0xb3f1b13f, 0x6e6768ba, 0x4917bd8f, 0x9481640a, + 0x294b08c4, 0xf4ddd141, 0x89aed719, 0x54380e9c, 0xe9f26252, + 0x3464bbd7, 0xa713c838, 0x7a8511bd, 0xc74f7d73, 0x1ad9a4f6, + 0x67aaa2ae, 0xba3c7b2b, 0x07f617e5, 0xda60ce60, 0xfd101b55, + 0x2086c2d0, 0x9d4cae1e, 0x40da779b, 0x3da971c3, 0xe03fa846, + 0x5df5c488, 0x80631d0d, 0x1de7b4bc, 0xc0716d39, 0x7dbb01f7, + 0xa02dd872, 0xdd5ede2a, 0x00c807af, 0xbd026b61, 0x6094b2e4, + 0x47e467d1, 0x9a72be54, 0x27b8d29a, 0xfa2e0b1f, 0x875d0d47, + 0x5acbd4c2, 0xe701b80c, 0x3a976189, 0xa9e01266, 0x7476cbe3, + 0xc9bca72d, 0x142a7ea8, 0x695978f0, 0xb4cfa175, 0x0905cdbb, + 0xd493143e, 0xf3e3c10b, 0x2e75188e, 0x93bf7440, 0x4e29adc5, + 0x335aab9d, 0xeecc7218, 0x53061ed6, 0x8e90c753, 0xae99ff49, + 0x730f26cc, 0xcec54a02, 0x13539387, 0x6e2095df, 0xb3b64c5a, + 0x0e7c2094, 0xd3eaf911, 0xf49a2c24, 0x290cf5a1, 0x94c6996f, + 0x495040ea, 0x342346b2, 0xe9b59f37, 0x547ff3f9, 0x89e92a7c, + 0x1a9e5993, 0xc7088016, 0x7ac2ecd8, 0xa754355d, 0xda273305, + 0x07b1ea80, 0xba7b864e, 0x67ed5fcb, 0x409d8afe, 0x9d0b537b, + 0x20c13fb5, 0xfd57e630, 0x8024e068, 0x5db239ed, 0xe0785523, + 0x3dee8ca6}, + {0x00000000, 0x9ba54c6f, 0xec3b9e9f, 0x779ed2f0, 0x03063b7f, + 0x98a37710, 0xef3da5e0, 0x7498e98f, 0x060c76fe, 0x9da93a91, + 0xea37e861, 0x7192a40e, 0x050a4d81, 0x9eaf01ee, 0xe931d31e, + 0x72949f71, 0x0c18edfc, 0x97bda193, 0xe0237363, 0x7b863f0c, + 0x0f1ed683, 0x94bb9aec, 0xe325481c, 0x78800473, 0x0a149b02, + 0x91b1d76d, 0xe62f059d, 0x7d8a49f2, 0x0912a07d, 0x92b7ec12, + 0xe5293ee2, 0x7e8c728d, 0x1831dbf8, 0x83949797, 0xf40a4567, + 0x6faf0908, 0x1b37e087, 0x8092ace8, 0xf70c7e18, 0x6ca93277, + 0x1e3dad06, 0x8598e169, 0xf2063399, 0x69a37ff6, 0x1d3b9679, + 0x869eda16, 0xf10008e6, 0x6aa54489, 0x14293604, 0x8f8c7a6b, + 0xf812a89b, 0x63b7e4f4, 0x172f0d7b, 0x8c8a4114, 0xfb1493e4, + 0x60b1df8b, 0x122540fa, 0x89800c95, 0xfe1ede65, 0x65bb920a, + 0x11237b85, 0x8a8637ea, 0xfd18e51a, 0x66bda975, 0x3063b7f0, + 0xabc6fb9f, 0xdc58296f, 0x47fd6500, 0x33658c8f, 0xa8c0c0e0, + 0xdf5e1210, 0x44fb5e7f, 0x366fc10e, 0xadca8d61, 0xda545f91, + 0x41f113fe, 0x3569fa71, 0xaeccb61e, 0xd95264ee, 0x42f72881, + 0x3c7b5a0c, 0xa7de1663, 0xd040c493, 0x4be588fc, 0x3f7d6173, + 0xa4d82d1c, 0xd346ffec, 0x48e3b383, 0x3a772cf2, 0xa1d2609d, + 0xd64cb26d, 0x4de9fe02, 0x3971178d, 0xa2d45be2, 0xd54a8912, + 0x4eefc57d, 0x28526c08, 0xb3f72067, 0xc469f297, 0x5fccbef8, + 0x2b545777, 0xb0f11b18, 0xc76fc9e8, 0x5cca8587, 0x2e5e1af6, + 0xb5fb5699, 0xc2658469, 0x59c0c806, 0x2d582189, 0xb6fd6de6, + 0xc163bf16, 0x5ac6f379, 0x244a81f4, 0xbfefcd9b, 0xc8711f6b, + 0x53d45304, 0x274cba8b, 0xbce9f6e4, 0xcb772414, 0x50d2687b, + 0x2246f70a, 0xb9e3bb65, 0xce7d6995, 0x55d825fa, 0x2140cc75, + 0xbae5801a, 0xcd7b52ea, 0x56de1e85, 0x60c76fe0, 0xfb62238f, + 0x8cfcf17f, 0x1759bd10, 0x63c1549f, 0xf86418f0, 0x8ffaca00, + 0x145f866f, 0x66cb191e, 0xfd6e5571, 0x8af08781, 0x1155cbee, + 0x65cd2261, 0xfe686e0e, 0x89f6bcfe, 0x1253f091, 0x6cdf821c, + 0xf77ace73, 0x80e41c83, 0x1b4150ec, 0x6fd9b963, 0xf47cf50c, + 0x83e227fc, 0x18476b93, 0x6ad3f4e2, 0xf176b88d, 0x86e86a7d, + 0x1d4d2612, 0x69d5cf9d, 0xf27083f2, 0x85ee5102, 0x1e4b1d6d, + 0x78f6b418, 0xe353f877, 0x94cd2a87, 0x0f6866e8, 0x7bf08f67, + 0xe055c308, 0x97cb11f8, 0x0c6e5d97, 0x7efac2e6, 0xe55f8e89, + 0x92c15c79, 0x09641016, 0x7dfcf999, 0xe659b5f6, 0x91c76706, + 0x0a622b69, 0x74ee59e4, 0xef4b158b, 0x98d5c77b, 0x03708b14, + 0x77e8629b, 0xec4d2ef4, 0x9bd3fc04, 0x0076b06b, 0x72e22f1a, + 0xe9476375, 0x9ed9b185, 0x057cfdea, 0x71e41465, 0xea41580a, + 0x9ddf8afa, 0x067ac695, 0x50a4d810, 0xcb01947f, 0xbc9f468f, + 0x273a0ae0, 0x53a2e36f, 0xc807af00, 0xbf997df0, 0x243c319f, + 0x56a8aeee, 0xcd0de281, 0xba933071, 0x21367c1e, 0x55ae9591, + 0xce0bd9fe, 0xb9950b0e, 0x22304761, 0x5cbc35ec, 0xc7197983, + 0xb087ab73, 0x2b22e71c, 0x5fba0e93, 0xc41f42fc, 0xb381900c, + 0x2824dc63, 0x5ab04312, 0xc1150f7d, 0xb68bdd8d, 0x2d2e91e2, + 0x59b6786d, 0xc2133402, 0xb58de6f2, 0x2e28aa9d, 0x489503e8, + 0xd3304f87, 0xa4ae9d77, 0x3f0bd118, 0x4b933897, 0xd03674f8, + 0xa7a8a608, 0x3c0dea67, 0x4e997516, 0xd53c3979, 0xa2a2eb89, + 0x3907a7e6, 0x4d9f4e69, 0xd63a0206, 0xa1a4d0f6, 0x3a019c99, + 0x448dee14, 0xdf28a27b, 0xa8b6708b, 0x33133ce4, 0x478bd56b, + 0xdc2e9904, 0xabb04bf4, 0x3015079b, 0x428198ea, 0xd924d485, + 0xaeba0675, 0x351f4a1a, 0x4187a395, 0xda22effa, 0xadbc3d0a, + 0x36197165}, + {0x00000000, 0xc18edfc0, 0x586cb9c1, 0x99e26601, 0xb0d97382, + 0x7157ac42, 0xe8b5ca43, 0x293b1583, 0xbac3e145, 0x7b4d3e85, + 0xe2af5884, 0x23218744, 0x0a1a92c7, 0xcb944d07, 0x52762b06, + 0x93f8f4c6, 0xaef6c4cb, 0x6f781b0b, 0xf69a7d0a, 0x3714a2ca, + 0x1e2fb749, 0xdfa16889, 0x46430e88, 0x87cdd148, 0x1435258e, + 0xd5bbfa4e, 0x4c599c4f, 0x8dd7438f, 0xa4ec560c, 0x656289cc, + 0xfc80efcd, 0x3d0e300d, 0x869c8fd7, 0x47125017, 0xdef03616, + 0x1f7ee9d6, 0x3645fc55, 0xf7cb2395, 0x6e294594, 0xafa79a54, + 0x3c5f6e92, 0xfdd1b152, 0x6433d753, 0xa5bd0893, 0x8c861d10, + 0x4d08c2d0, 0xd4eaa4d1, 0x15647b11, 0x286a4b1c, 0xe9e494dc, + 0x7006f2dd, 0xb1882d1d, 0x98b3389e, 0x593de75e, 0xc0df815f, + 0x01515e9f, 0x92a9aa59, 0x53277599, 0xcac51398, 0x0b4bcc58, + 0x2270d9db, 0xe3fe061b, 0x7a1c601a, 0xbb92bfda, 0xd64819ef, + 0x17c6c62f, 0x8e24a02e, 0x4faa7fee, 0x66916a6d, 0xa71fb5ad, + 0x3efdd3ac, 0xff730c6c, 0x6c8bf8aa, 0xad05276a, 0x34e7416b, + 0xf5699eab, 0xdc528b28, 0x1ddc54e8, 0x843e32e9, 0x45b0ed29, + 0x78bedd24, 0xb93002e4, 0x20d264e5, 0xe15cbb25, 0xc867aea6, + 0x09e97166, 0x900b1767, 0x5185c8a7, 0xc27d3c61, 0x03f3e3a1, + 0x9a1185a0, 0x5b9f5a60, 0x72a44fe3, 0xb32a9023, 0x2ac8f622, + 0xeb4629e2, 0x50d49638, 0x915a49f8, 0x08b82ff9, 0xc936f039, + 0xe00de5ba, 0x21833a7a, 0xb8615c7b, 0x79ef83bb, 0xea17777d, + 0x2b99a8bd, 0xb27bcebc, 0x73f5117c, 0x5ace04ff, 0x9b40db3f, + 0x02a2bd3e, 0xc32c62fe, 0xfe2252f3, 0x3fac8d33, 0xa64eeb32, + 0x67c034f2, 0x4efb2171, 0x8f75feb1, 0x169798b0, 0xd7194770, + 0x44e1b3b6, 0x856f6c76, 0x1c8d0a77, 0xdd03d5b7, 0xf438c034, + 0x35b61ff4, 0xac5479f5, 0x6ddaa635, 0x77e1359f, 0xb66fea5f, + 0x2f8d8c5e, 0xee03539e, 0xc738461d, 0x06b699dd, 0x9f54ffdc, + 0x5eda201c, 0xcd22d4da, 0x0cac0b1a, 0x954e6d1b, 0x54c0b2db, + 0x7dfba758, 0xbc757898, 0x25971e99, 0xe419c159, 0xd917f154, + 0x18992e94, 0x817b4895, 0x40f59755, 0x69ce82d6, 0xa8405d16, + 0x31a23b17, 0xf02ce4d7, 0x63d41011, 0xa25acfd1, 0x3bb8a9d0, + 0xfa367610, 0xd30d6393, 0x1283bc53, 0x8b61da52, 0x4aef0592, + 0xf17dba48, 0x30f36588, 0xa9110389, 0x689fdc49, 0x41a4c9ca, + 0x802a160a, 0x19c8700b, 0xd846afcb, 0x4bbe5b0d, 0x8a3084cd, + 0x13d2e2cc, 0xd25c3d0c, 0xfb67288f, 0x3ae9f74f, 0xa30b914e, + 0x62854e8e, 0x5f8b7e83, 0x9e05a143, 0x07e7c742, 0xc6691882, + 0xef520d01, 0x2edcd2c1, 0xb73eb4c0, 0x76b06b00, 0xe5489fc6, + 0x24c64006, 0xbd242607, 0x7caaf9c7, 0x5591ec44, 0x941f3384, + 0x0dfd5585, 0xcc738a45, 0xa1a92c70, 0x6027f3b0, 0xf9c595b1, + 0x384b4a71, 0x11705ff2, 0xd0fe8032, 0x491ce633, 0x889239f3, + 0x1b6acd35, 0xdae412f5, 0x430674f4, 0x8288ab34, 0xabb3beb7, + 0x6a3d6177, 0xf3df0776, 0x3251d8b6, 0x0f5fe8bb, 0xced1377b, + 0x5733517a, 0x96bd8eba, 0xbf869b39, 0x7e0844f9, 0xe7ea22f8, + 0x2664fd38, 0xb59c09fe, 0x7412d63e, 0xedf0b03f, 0x2c7e6fff, + 0x05457a7c, 0xc4cba5bc, 0x5d29c3bd, 0x9ca71c7d, 0x2735a3a7, + 0xe6bb7c67, 0x7f591a66, 0xbed7c5a6, 0x97ecd025, 0x56620fe5, + 0xcf8069e4, 0x0e0eb624, 0x9df642e2, 0x5c789d22, 0xc59afb23, + 0x041424e3, 0x2d2f3160, 0xeca1eea0, 0x754388a1, 0xb4cd5761, + 0x89c3676c, 0x484db8ac, 0xd1afdead, 0x1021016d, 0x391a14ee, + 0xf894cb2e, 0x6176ad2f, 0xa0f872ef, 0x33008629, 0xf28e59e9, + 0x6b6c3fe8, 0xaae2e028, 0x83d9f5ab, 0x42572a6b, 0xdbb54c6a, + 0x1a3b93aa}, + {0x00000000, 0xefc26b3e, 0x04f5d03d, 0xeb37bb03, 0x09eba07a, + 0xe629cb44, 0x0d1e7047, 0xe2dc1b79, 0x13d740f4, 0xfc152bca, + 0x172290c9, 0xf8e0fbf7, 0x1a3ce08e, 0xf5fe8bb0, 0x1ec930b3, + 0xf10b5b8d, 0x27ae81e8, 0xc86cead6, 0x235b51d5, 0xcc993aeb, + 0x2e452192, 0xc1874aac, 0x2ab0f1af, 0xc5729a91, 0x3479c11c, + 0xdbbbaa22, 0x308c1121, 0xdf4e7a1f, 0x3d926166, 0xd2500a58, + 0x3967b15b, 0xd6a5da65, 0x4f5d03d0, 0xa09f68ee, 0x4ba8d3ed, + 0xa46ab8d3, 0x46b6a3aa, 0xa974c894, 0x42437397, 0xad8118a9, + 0x5c8a4324, 0xb348281a, 0x587f9319, 0xb7bdf827, 0x5561e35e, + 0xbaa38860, 0x51943363, 0xbe56585d, 0x68f38238, 0x8731e906, + 0x6c065205, 0x83c4393b, 0x61182242, 0x8eda497c, 0x65edf27f, + 0x8a2f9941, 0x7b24c2cc, 0x94e6a9f2, 0x7fd112f1, 0x901379cf, + 0x72cf62b6, 0x9d0d0988, 0x763ab28b, 0x99f8d9b5, 0x9eba07a0, + 0x71786c9e, 0x9a4fd79d, 0x758dbca3, 0x9751a7da, 0x7893cce4, + 0x93a477e7, 0x7c661cd9, 0x8d6d4754, 0x62af2c6a, 0x89989769, + 0x665afc57, 0x8486e72e, 0x6b448c10, 0x80733713, 0x6fb15c2d, + 0xb9148648, 0x56d6ed76, 0xbde15675, 0x52233d4b, 0xb0ff2632, + 0x5f3d4d0c, 0xb40af60f, 0x5bc89d31, 0xaac3c6bc, 0x4501ad82, + 0xae361681, 0x41f47dbf, 0xa32866c6, 0x4cea0df8, 0xa7ddb6fb, + 0x481fddc5, 0xd1e70470, 0x3e256f4e, 0xd512d44d, 0x3ad0bf73, + 0xd80ca40a, 0x37cecf34, 0xdcf97437, 0x333b1f09, 0xc2304484, + 0x2df22fba, 0xc6c594b9, 0x2907ff87, 0xcbdbe4fe, 0x24198fc0, + 0xcf2e34c3, 0x20ec5ffd, 0xf6498598, 0x198beea6, 0xf2bc55a5, + 0x1d7e3e9b, 0xffa225e2, 0x10604edc, 0xfb57f5df, 0x14959ee1, + 0xe59ec56c, 0x0a5cae52, 0xe16b1551, 0x0ea97e6f, 0xec756516, + 0x03b70e28, 0xe880b52b, 0x0742de15, 0xe6050901, 0x09c7623f, + 0xe2f0d93c, 0x0d32b202, 0xefeea97b, 0x002cc245, 0xeb1b7946, + 0x04d91278, 0xf5d249f5, 0x1a1022cb, 0xf12799c8, 0x1ee5f2f6, + 0xfc39e98f, 0x13fb82b1, 0xf8cc39b2, 0x170e528c, 0xc1ab88e9, + 0x2e69e3d7, 0xc55e58d4, 0x2a9c33ea, 0xc8402893, 0x278243ad, + 0xccb5f8ae, 0x23779390, 0xd27cc81d, 0x3dbea323, 0xd6891820, + 0x394b731e, 0xdb976867, 0x34550359, 0xdf62b85a, 0x30a0d364, + 0xa9580ad1, 0x469a61ef, 0xadaddaec, 0x426fb1d2, 0xa0b3aaab, + 0x4f71c195, 0xa4467a96, 0x4b8411a8, 0xba8f4a25, 0x554d211b, + 0xbe7a9a18, 0x51b8f126, 0xb364ea5f, 0x5ca68161, 0xb7913a62, + 0x5853515c, 0x8ef68b39, 0x6134e007, 0x8a035b04, 0x65c1303a, + 0x871d2b43, 0x68df407d, 0x83e8fb7e, 0x6c2a9040, 0x9d21cbcd, + 0x72e3a0f3, 0x99d41bf0, 0x761670ce, 0x94ca6bb7, 0x7b080089, + 0x903fbb8a, 0x7ffdd0b4, 0x78bf0ea1, 0x977d659f, 0x7c4ade9c, + 0x9388b5a2, 0x7154aedb, 0x9e96c5e5, 0x75a17ee6, 0x9a6315d8, + 0x6b684e55, 0x84aa256b, 0x6f9d9e68, 0x805ff556, 0x6283ee2f, + 0x8d418511, 0x66763e12, 0x89b4552c, 0x5f118f49, 0xb0d3e477, + 0x5be45f74, 0xb426344a, 0x56fa2f33, 0xb938440d, 0x520fff0e, + 0xbdcd9430, 0x4cc6cfbd, 0xa304a483, 0x48331f80, 0xa7f174be, + 0x452d6fc7, 0xaaef04f9, 0x41d8bffa, 0xae1ad4c4, 0x37e20d71, + 0xd820664f, 0x3317dd4c, 0xdcd5b672, 0x3e09ad0b, 0xd1cbc635, + 0x3afc7d36, 0xd53e1608, 0x24354d85, 0xcbf726bb, 0x20c09db8, + 0xcf02f686, 0x2ddeedff, 0xc21c86c1, 0x292b3dc2, 0xc6e956fc, + 0x104c8c99, 0xff8ee7a7, 0x14b95ca4, 0xfb7b379a, 0x19a72ce3, + 0xf66547dd, 0x1d52fcde, 0xf29097e0, 0x039bcc6d, 0xec59a753, + 0x076e1c50, 0xe8ac776e, 0x0a706c17, 0xe5b20729, 0x0e85bc2a, + 0xe147d714}, + {0x00000000, 0x177b1443, 0x2ef62886, 0x398d3cc5, 0x5dec510c, + 0x4a97454f, 0x731a798a, 0x64616dc9, 0xbbd8a218, 0xaca3b65b, + 0x952e8a9e, 0x82559edd, 0xe634f314, 0xf14fe757, 0xc8c2db92, + 0xdfb9cfd1, 0xacc04271, 0xbbbb5632, 0x82366af7, 0x954d7eb4, + 0xf12c137d, 0xe657073e, 0xdfda3bfb, 0xc8a12fb8, 0x1718e069, + 0x0063f42a, 0x39eec8ef, 0x2e95dcac, 0x4af4b165, 0x5d8fa526, + 0x640299e3, 0x73798da0, 0x82f182a3, 0x958a96e0, 0xac07aa25, + 0xbb7cbe66, 0xdf1dd3af, 0xc866c7ec, 0xf1ebfb29, 0xe690ef6a, + 0x392920bb, 0x2e5234f8, 0x17df083d, 0x00a41c7e, 0x64c571b7, + 0x73be65f4, 0x4a335931, 0x5d484d72, 0x2e31c0d2, 0x394ad491, + 0x00c7e854, 0x17bcfc17, 0x73dd91de, 0x64a6859d, 0x5d2bb958, + 0x4a50ad1b, 0x95e962ca, 0x82927689, 0xbb1f4a4c, 0xac645e0f, + 0xc80533c6, 0xdf7e2785, 0xe6f31b40, 0xf1880f03, 0xde920307, + 0xc9e91744, 0xf0642b81, 0xe71f3fc2, 0x837e520b, 0x94054648, + 0xad887a8d, 0xbaf36ece, 0x654aa11f, 0x7231b55c, 0x4bbc8999, + 0x5cc79dda, 0x38a6f013, 0x2fdde450, 0x1650d895, 0x012bccd6, + 0x72524176, 0x65295535, 0x5ca469f0, 0x4bdf7db3, 0x2fbe107a, + 0x38c50439, 0x014838fc, 0x16332cbf, 0xc98ae36e, 0xdef1f72d, + 0xe77ccbe8, 0xf007dfab, 0x9466b262, 0x831da621, 0xba909ae4, + 0xadeb8ea7, 0x5c6381a4, 0x4b1895e7, 0x7295a922, 0x65eebd61, + 0x018fd0a8, 0x16f4c4eb, 0x2f79f82e, 0x3802ec6d, 0xe7bb23bc, + 0xf0c037ff, 0xc94d0b3a, 0xde361f79, 0xba5772b0, 0xad2c66f3, + 0x94a15a36, 0x83da4e75, 0xf0a3c3d5, 0xe7d8d796, 0xde55eb53, + 0xc92eff10, 0xad4f92d9, 0xba34869a, 0x83b9ba5f, 0x94c2ae1c, + 0x4b7b61cd, 0x5c00758e, 0x658d494b, 0x72f65d08, 0x169730c1, + 0x01ec2482, 0x38611847, 0x2f1a0c04, 0x6655004f, 0x712e140c, + 0x48a328c9, 0x5fd83c8a, 0x3bb95143, 0x2cc24500, 0x154f79c5, + 0x02346d86, 0xdd8da257, 0xcaf6b614, 0xf37b8ad1, 0xe4009e92, + 0x8061f35b, 0x971ae718, 0xae97dbdd, 0xb9eccf9e, 0xca95423e, + 0xddee567d, 0xe4636ab8, 0xf3187efb, 0x97791332, 0x80020771, + 0xb98f3bb4, 0xaef42ff7, 0x714de026, 0x6636f465, 0x5fbbc8a0, + 0x48c0dce3, 0x2ca1b12a, 0x3bdaa569, 0x025799ac, 0x152c8def, + 0xe4a482ec, 0xf3df96af, 0xca52aa6a, 0xdd29be29, 0xb948d3e0, + 0xae33c7a3, 0x97befb66, 0x80c5ef25, 0x5f7c20f4, 0x480734b7, + 0x718a0872, 0x66f11c31, 0x029071f8, 0x15eb65bb, 0x2c66597e, + 0x3b1d4d3d, 0x4864c09d, 0x5f1fd4de, 0x6692e81b, 0x71e9fc58, + 0x15889191, 0x02f385d2, 0x3b7eb917, 0x2c05ad54, 0xf3bc6285, + 0xe4c776c6, 0xdd4a4a03, 0xca315e40, 0xae503389, 0xb92b27ca, + 0x80a61b0f, 0x97dd0f4c, 0xb8c70348, 0xafbc170b, 0x96312bce, + 0x814a3f8d, 0xe52b5244, 0xf2504607, 0xcbdd7ac2, 0xdca66e81, + 0x031fa150, 0x1464b513, 0x2de989d6, 0x3a929d95, 0x5ef3f05c, + 0x4988e41f, 0x7005d8da, 0x677ecc99, 0x14074139, 0x037c557a, + 0x3af169bf, 0x2d8a7dfc, 0x49eb1035, 0x5e900476, 0x671d38b3, + 0x70662cf0, 0xafdfe321, 0xb8a4f762, 0x8129cba7, 0x9652dfe4, + 0xf233b22d, 0xe548a66e, 0xdcc59aab, 0xcbbe8ee8, 0x3a3681eb, + 0x2d4d95a8, 0x14c0a96d, 0x03bbbd2e, 0x67dad0e7, 0x70a1c4a4, + 0x492cf861, 0x5e57ec22, 0x81ee23f3, 0x969537b0, 0xaf180b75, + 0xb8631f36, 0xdc0272ff, 0xcb7966bc, 0xf2f45a79, 0xe58f4e3a, + 0x96f6c39a, 0x818dd7d9, 0xb800eb1c, 0xaf7bff5f, 0xcb1a9296, + 0xdc6186d5, 0xe5ecba10, 0xf297ae53, 0x2d2e6182, 0x3a5575c1, + 0x03d84904, 0x14a35d47, 0x70c2308e, 0x67b924cd, 0x5e341808, + 0x494f0c4b}}; + +local const z_word_t FAR crc_braid_big_table[][256] = { + {0x0000000000000000, 0x43147b1700000000, 0x8628f62e00000000, + 0xc53c8d3900000000, 0x0c51ec5d00000000, 0x4f45974a00000000, + 0x8a791a7300000000, 0xc96d616400000000, 0x18a2d8bb00000000, + 0x5bb6a3ac00000000, 0x9e8a2e9500000000, 0xdd9e558200000000, + 0x14f334e600000000, 0x57e74ff100000000, 0x92dbc2c800000000, + 0xd1cfb9df00000000, 0x7142c0ac00000000, 0x3256bbbb00000000, + 0xf76a368200000000, 0xb47e4d9500000000, 0x7d132cf100000000, + 0x3e0757e600000000, 0xfb3bdadf00000000, 0xb82fa1c800000000, + 0x69e0181700000000, 0x2af4630000000000, 0xefc8ee3900000000, + 0xacdc952e00000000, 0x65b1f44a00000000, 0x26a58f5d00000000, + 0xe399026400000000, 0xa08d797300000000, 0xa382f18200000000, + 0xe0968a9500000000, 0x25aa07ac00000000, 0x66be7cbb00000000, + 0xafd31ddf00000000, 0xecc766c800000000, 0x29fbebf100000000, + 0x6aef90e600000000, 0xbb20293900000000, 0xf834522e00000000, + 0x3d08df1700000000, 0x7e1ca40000000000, 0xb771c56400000000, + 0xf465be7300000000, 0x3159334a00000000, 0x724d485d00000000, + 0xd2c0312e00000000, 0x91d44a3900000000, 0x54e8c70000000000, + 0x17fcbc1700000000, 0xde91dd7300000000, 0x9d85a66400000000, + 0x58b92b5d00000000, 0x1bad504a00000000, 0xca62e99500000000, + 0x8976928200000000, 0x4c4a1fbb00000000, 0x0f5e64ac00000000, + 0xc63305c800000000, 0x85277edf00000000, 0x401bf3e600000000, + 0x030f88f100000000, 0x070392de00000000, 0x4417e9c900000000, + 0x812b64f000000000, 0xc23f1fe700000000, 0x0b527e8300000000, + 0x4846059400000000, 0x8d7a88ad00000000, 0xce6ef3ba00000000, + 0x1fa14a6500000000, 0x5cb5317200000000, 0x9989bc4b00000000, + 0xda9dc75c00000000, 0x13f0a63800000000, 0x50e4dd2f00000000, + 0x95d8501600000000, 0xd6cc2b0100000000, 0x7641527200000000, + 0x3555296500000000, 0xf069a45c00000000, 0xb37ddf4b00000000, + 0x7a10be2f00000000, 0x3904c53800000000, 0xfc38480100000000, + 0xbf2c331600000000, 0x6ee38ac900000000, 0x2df7f1de00000000, + 0xe8cb7ce700000000, 0xabdf07f000000000, 0x62b2669400000000, + 0x21a61d8300000000, 0xe49a90ba00000000, 0xa78eebad00000000, + 0xa481635c00000000, 0xe795184b00000000, 0x22a9957200000000, + 0x61bdee6500000000, 0xa8d08f0100000000, 0xebc4f41600000000, + 0x2ef8792f00000000, 0x6dec023800000000, 0xbc23bbe700000000, + 0xff37c0f000000000, 0x3a0b4dc900000000, 0x791f36de00000000, + 0xb07257ba00000000, 0xf3662cad00000000, 0x365aa19400000000, + 0x754eda8300000000, 0xd5c3a3f000000000, 0x96d7d8e700000000, + 0x53eb55de00000000, 0x10ff2ec900000000, 0xd9924fad00000000, + 0x9a8634ba00000000, 0x5fbab98300000000, 0x1caec29400000000, + 0xcd617b4b00000000, 0x8e75005c00000000, 0x4b498d6500000000, + 0x085df67200000000, 0xc130971600000000, 0x8224ec0100000000, + 0x4718613800000000, 0x040c1a2f00000000, 0x4f00556600000000, + 0x0c142e7100000000, 0xc928a34800000000, 0x8a3cd85f00000000, + 0x4351b93b00000000, 0x0045c22c00000000, 0xc5794f1500000000, + 0x866d340200000000, 0x57a28ddd00000000, 0x14b6f6ca00000000, + 0xd18a7bf300000000, 0x929e00e400000000, 0x5bf3618000000000, + 0x18e71a9700000000, 0xdddb97ae00000000, 0x9ecfecb900000000, + 0x3e4295ca00000000, 0x7d56eedd00000000, 0xb86a63e400000000, + 0xfb7e18f300000000, 0x3213799700000000, 0x7107028000000000, + 0xb43b8fb900000000, 0xf72ff4ae00000000, 0x26e04d7100000000, + 0x65f4366600000000, 0xa0c8bb5f00000000, 0xe3dcc04800000000, + 0x2ab1a12c00000000, 0x69a5da3b00000000, 0xac99570200000000, + 0xef8d2c1500000000, 0xec82a4e400000000, 0xaf96dff300000000, + 0x6aaa52ca00000000, 0x29be29dd00000000, 0xe0d348b900000000, + 0xa3c733ae00000000, 0x66fbbe9700000000, 0x25efc58000000000, + 0xf4207c5f00000000, 0xb734074800000000, 0x72088a7100000000, + 0x311cf16600000000, 0xf871900200000000, 0xbb65eb1500000000, + 0x7e59662c00000000, 0x3d4d1d3b00000000, 0x9dc0644800000000, + 0xded41f5f00000000, 0x1be8926600000000, 0x58fce97100000000, + 0x9191881500000000, 0xd285f30200000000, 0x17b97e3b00000000, + 0x54ad052c00000000, 0x8562bcf300000000, 0xc676c7e400000000, + 0x034a4add00000000, 0x405e31ca00000000, 0x893350ae00000000, + 0xca272bb900000000, 0x0f1ba68000000000, 0x4c0fdd9700000000, + 0x4803c7b800000000, 0x0b17bcaf00000000, 0xce2b319600000000, + 0x8d3f4a8100000000, 0x44522be500000000, 0x074650f200000000, + 0xc27addcb00000000, 0x816ea6dc00000000, 0x50a11f0300000000, + 0x13b5641400000000, 0xd689e92d00000000, 0x959d923a00000000, + 0x5cf0f35e00000000, 0x1fe4884900000000, 0xdad8057000000000, + 0x99cc7e6700000000, 0x3941071400000000, 0x7a557c0300000000, + 0xbf69f13a00000000, 0xfc7d8a2d00000000, 0x3510eb4900000000, + 0x7604905e00000000, 0xb3381d6700000000, 0xf02c667000000000, + 0x21e3dfaf00000000, 0x62f7a4b800000000, 0xa7cb298100000000, + 0xe4df529600000000, 0x2db233f200000000, 0x6ea648e500000000, + 0xab9ac5dc00000000, 0xe88ebecb00000000, 0xeb81363a00000000, + 0xa8954d2d00000000, 0x6da9c01400000000, 0x2ebdbb0300000000, + 0xe7d0da6700000000, 0xa4c4a17000000000, 0x61f82c4900000000, + 0x22ec575e00000000, 0xf323ee8100000000, 0xb037959600000000, + 0x750b18af00000000, 0x361f63b800000000, 0xff7202dc00000000, + 0xbc6679cb00000000, 0x795af4f200000000, 0x3a4e8fe500000000, + 0x9ac3f69600000000, 0xd9d78d8100000000, 0x1ceb00b800000000, + 0x5fff7baf00000000, 0x96921acb00000000, 0xd58661dc00000000, + 0x10baece500000000, 0x53ae97f200000000, 0x82612e2d00000000, + 0xc175553a00000000, 0x0449d80300000000, 0x475da31400000000, + 0x8e30c27000000000, 0xcd24b96700000000, 0x0818345e00000000, + 0x4b0c4f4900000000}, + {0x0000000000000000, 0x3e6bc2ef00000000, 0x3dd0f50400000000, + 0x03bb37eb00000000, 0x7aa0eb0900000000, 0x44cb29e600000000, + 0x47701e0d00000000, 0x791bdce200000000, 0xf440d71300000000, + 0xca2b15fc00000000, 0xc990221700000000, 0xf7fbe0f800000000, + 0x8ee03c1a00000000, 0xb08bfef500000000, 0xb330c91e00000000, + 0x8d5b0bf100000000, 0xe881ae2700000000, 0xd6ea6cc800000000, + 0xd5515b2300000000, 0xeb3a99cc00000000, 0x9221452e00000000, + 0xac4a87c100000000, 0xaff1b02a00000000, 0x919a72c500000000, + 0x1cc1793400000000, 0x22aabbdb00000000, 0x21118c3000000000, + 0x1f7a4edf00000000, 0x6661923d00000000, 0x580a50d200000000, + 0x5bb1673900000000, 0x65daa5d600000000, 0xd0035d4f00000000, + 0xee689fa000000000, 0xedd3a84b00000000, 0xd3b86aa400000000, + 0xaaa3b64600000000, 0x94c874a900000000, 0x9773434200000000, + 0xa91881ad00000000, 0x24438a5c00000000, 0x1a2848b300000000, + 0x19937f5800000000, 0x27f8bdb700000000, 0x5ee3615500000000, + 0x6088a3ba00000000, 0x6333945100000000, 0x5d5856be00000000, + 0x3882f36800000000, 0x06e9318700000000, 0x0552066c00000000, + 0x3b39c48300000000, 0x4222186100000000, 0x7c49da8e00000000, + 0x7ff2ed6500000000, 0x41992f8a00000000, 0xccc2247b00000000, + 0xf2a9e69400000000, 0xf112d17f00000000, 0xcf79139000000000, + 0xb662cf7200000000, 0x88090d9d00000000, 0x8bb23a7600000000, + 0xb5d9f89900000000, 0xa007ba9e00000000, 0x9e6c787100000000, + 0x9dd74f9a00000000, 0xa3bc8d7500000000, 0xdaa7519700000000, + 0xe4cc937800000000, 0xe777a49300000000, 0xd91c667c00000000, + 0x54476d8d00000000, 0x6a2caf6200000000, 0x6997988900000000, + 0x57fc5a6600000000, 0x2ee7868400000000, 0x108c446b00000000, + 0x1337738000000000, 0x2d5cb16f00000000, 0x488614b900000000, + 0x76edd65600000000, 0x7556e1bd00000000, 0x4b3d235200000000, + 0x3226ffb000000000, 0x0c4d3d5f00000000, 0x0ff60ab400000000, + 0x319dc85b00000000, 0xbcc6c3aa00000000, 0x82ad014500000000, + 0x811636ae00000000, 0xbf7df44100000000, 0xc66628a300000000, + 0xf80dea4c00000000, 0xfbb6dda700000000, 0xc5dd1f4800000000, + 0x7004e7d100000000, 0x4e6f253e00000000, 0x4dd412d500000000, + 0x73bfd03a00000000, 0x0aa40cd800000000, 0x34cfce3700000000, + 0x3774f9dc00000000, 0x091f3b3300000000, 0x844430c200000000, + 0xba2ff22d00000000, 0xb994c5c600000000, 0x87ff072900000000, + 0xfee4dbcb00000000, 0xc08f192400000000, 0xc3342ecf00000000, + 0xfd5fec2000000000, 0x988549f600000000, 0xa6ee8b1900000000, + 0xa555bcf200000000, 0x9b3e7e1d00000000, 0xe225a2ff00000000, + 0xdc4e601000000000, 0xdff557fb00000000, 0xe19e951400000000, + 0x6cc59ee500000000, 0x52ae5c0a00000000, 0x51156be100000000, + 0x6f7ea90e00000000, 0x166575ec00000000, 0x280eb70300000000, + 0x2bb580e800000000, 0x15de420700000000, 0x010905e600000000, + 0x3f62c70900000000, 0x3cd9f0e200000000, 0x02b2320d00000000, + 0x7ba9eeef00000000, 0x45c22c0000000000, 0x46791beb00000000, + 0x7812d90400000000, 0xf549d2f500000000, 0xcb22101a00000000, + 0xc89927f100000000, 0xf6f2e51e00000000, 0x8fe939fc00000000, + 0xb182fb1300000000, 0xb239ccf800000000, 0x8c520e1700000000, + 0xe988abc100000000, 0xd7e3692e00000000, 0xd4585ec500000000, + 0xea339c2a00000000, 0x932840c800000000, 0xad43822700000000, + 0xaef8b5cc00000000, 0x9093772300000000, 0x1dc87cd200000000, + 0x23a3be3d00000000, 0x201889d600000000, 0x1e734b3900000000, + 0x676897db00000000, 0x5903553400000000, 0x5ab862df00000000, + 0x64d3a03000000000, 0xd10a58a900000000, 0xef619a4600000000, + 0xecdaadad00000000, 0xd2b16f4200000000, 0xabaab3a000000000, + 0x95c1714f00000000, 0x967a46a400000000, 0xa811844b00000000, + 0x254a8fba00000000, 0x1b214d5500000000, 0x189a7abe00000000, + 0x26f1b85100000000, 0x5fea64b300000000, 0x6181a65c00000000, + 0x623a91b700000000, 0x5c51535800000000, 0x398bf68e00000000, + 0x07e0346100000000, 0x045b038a00000000, 0x3a30c16500000000, + 0x432b1d8700000000, 0x7d40df6800000000, 0x7efbe88300000000, + 0x40902a6c00000000, 0xcdcb219d00000000, 0xf3a0e37200000000, + 0xf01bd49900000000, 0xce70167600000000, 0xb76bca9400000000, + 0x8900087b00000000, 0x8abb3f9000000000, 0xb4d0fd7f00000000, + 0xa10ebf7800000000, 0x9f657d9700000000, 0x9cde4a7c00000000, + 0xa2b5889300000000, 0xdbae547100000000, 0xe5c5969e00000000, + 0xe67ea17500000000, 0xd815639a00000000, 0x554e686b00000000, + 0x6b25aa8400000000, 0x689e9d6f00000000, 0x56f55f8000000000, + 0x2fee836200000000, 0x1185418d00000000, 0x123e766600000000, + 0x2c55b48900000000, 0x498f115f00000000, 0x77e4d3b000000000, + 0x745fe45b00000000, 0x4a3426b400000000, 0x332ffa5600000000, + 0x0d4438b900000000, 0x0eff0f5200000000, 0x3094cdbd00000000, + 0xbdcfc64c00000000, 0x83a404a300000000, 0x801f334800000000, + 0xbe74f1a700000000, 0xc76f2d4500000000, 0xf904efaa00000000, + 0xfabfd84100000000, 0xc4d41aae00000000, 0x710de23700000000, + 0x4f6620d800000000, 0x4cdd173300000000, 0x72b6d5dc00000000, + 0x0bad093e00000000, 0x35c6cbd100000000, 0x367dfc3a00000000, + 0x08163ed500000000, 0x854d352400000000, 0xbb26f7cb00000000, + 0xb89dc02000000000, 0x86f602cf00000000, 0xffedde2d00000000, + 0xc1861cc200000000, 0xc23d2b2900000000, 0xfc56e9c600000000, + 0x998c4c1000000000, 0xa7e78eff00000000, 0xa45cb91400000000, + 0x9a377bfb00000000, 0xe32ca71900000000, 0xdd4765f600000000, + 0xdefc521d00000000, 0xe09790f200000000, 0x6dcc9b0300000000, + 0x53a759ec00000000, 0x501c6e0700000000, 0x6e77ace800000000, + 0x176c700a00000000, 0x2907b2e500000000, 0x2abc850e00000000, + 0x14d747e100000000}, + {0x0000000000000000, 0xc0df8ec100000000, 0xc1b96c5800000000, + 0x0166e29900000000, 0x8273d9b000000000, 0x42ac577100000000, + 0x43cab5e800000000, 0x83153b2900000000, 0x45e1c3ba00000000, + 0x853e4d7b00000000, 0x8458afe200000000, 0x4487212300000000, + 0xc7921a0a00000000, 0x074d94cb00000000, 0x062b765200000000, + 0xc6f4f89300000000, 0xcbc4f6ae00000000, 0x0b1b786f00000000, + 0x0a7d9af600000000, 0xcaa2143700000000, 0x49b72f1e00000000, + 0x8968a1df00000000, 0x880e434600000000, 0x48d1cd8700000000, + 0x8e25351400000000, 0x4efabbd500000000, 0x4f9c594c00000000, + 0x8f43d78d00000000, 0x0c56eca400000000, 0xcc89626500000000, + 0xcdef80fc00000000, 0x0d300e3d00000000, 0xd78f9c8600000000, + 0x1750124700000000, 0x1636f0de00000000, 0xd6e97e1f00000000, + 0x55fc453600000000, 0x9523cbf700000000, 0x9445296e00000000, + 0x549aa7af00000000, 0x926e5f3c00000000, 0x52b1d1fd00000000, + 0x53d7336400000000, 0x9308bda500000000, 0x101d868c00000000, + 0xd0c2084d00000000, 0xd1a4ead400000000, 0x117b641500000000, + 0x1c4b6a2800000000, 0xdc94e4e900000000, 0xddf2067000000000, + 0x1d2d88b100000000, 0x9e38b39800000000, 0x5ee73d5900000000, + 0x5f81dfc000000000, 0x9f5e510100000000, 0x59aaa99200000000, + 0x9975275300000000, 0x9813c5ca00000000, 0x58cc4b0b00000000, + 0xdbd9702200000000, 0x1b06fee300000000, 0x1a601c7a00000000, + 0xdabf92bb00000000, 0xef1948d600000000, 0x2fc6c61700000000, + 0x2ea0248e00000000, 0xee7faa4f00000000, 0x6d6a916600000000, + 0xadb51fa700000000, 0xacd3fd3e00000000, 0x6c0c73ff00000000, + 0xaaf88b6c00000000, 0x6a2705ad00000000, 0x6b41e73400000000, + 0xab9e69f500000000, 0x288b52dc00000000, 0xe854dc1d00000000, + 0xe9323e8400000000, 0x29edb04500000000, 0x24ddbe7800000000, + 0xe40230b900000000, 0xe564d22000000000, 0x25bb5ce100000000, + 0xa6ae67c800000000, 0x6671e90900000000, 0x67170b9000000000, + 0xa7c8855100000000, 0x613c7dc200000000, 0xa1e3f30300000000, + 0xa085119a00000000, 0x605a9f5b00000000, 0xe34fa47200000000, + 0x23902ab300000000, 0x22f6c82a00000000, 0xe22946eb00000000, + 0x3896d45000000000, 0xf8495a9100000000, 0xf92fb80800000000, + 0x39f036c900000000, 0xbae50de000000000, 0x7a3a832100000000, + 0x7b5c61b800000000, 0xbb83ef7900000000, 0x7d7717ea00000000, + 0xbda8992b00000000, 0xbcce7bb200000000, 0x7c11f57300000000, + 0xff04ce5a00000000, 0x3fdb409b00000000, 0x3ebda20200000000, + 0xfe622cc300000000, 0xf35222fe00000000, 0x338dac3f00000000, + 0x32eb4ea600000000, 0xf234c06700000000, 0x7121fb4e00000000, + 0xb1fe758f00000000, 0xb098971600000000, 0x704719d700000000, + 0xb6b3e14400000000, 0x766c6f8500000000, 0x770a8d1c00000000, + 0xb7d503dd00000000, 0x34c038f400000000, 0xf41fb63500000000, + 0xf57954ac00000000, 0x35a6da6d00000000, 0x9f35e17700000000, + 0x5fea6fb600000000, 0x5e8c8d2f00000000, 0x9e5303ee00000000, + 0x1d4638c700000000, 0xdd99b60600000000, 0xdcff549f00000000, + 0x1c20da5e00000000, 0xdad422cd00000000, 0x1a0bac0c00000000, + 0x1b6d4e9500000000, 0xdbb2c05400000000, 0x58a7fb7d00000000, + 0x987875bc00000000, 0x991e972500000000, 0x59c119e400000000, + 0x54f117d900000000, 0x942e991800000000, 0x95487b8100000000, + 0x5597f54000000000, 0xd682ce6900000000, 0x165d40a800000000, + 0x173ba23100000000, 0xd7e42cf000000000, 0x1110d46300000000, + 0xd1cf5aa200000000, 0xd0a9b83b00000000, 0x107636fa00000000, + 0x93630dd300000000, 0x53bc831200000000, 0x52da618b00000000, + 0x9205ef4a00000000, 0x48ba7df100000000, 0x8865f33000000000, + 0x890311a900000000, 0x49dc9f6800000000, 0xcac9a44100000000, + 0x0a162a8000000000, 0x0b70c81900000000, 0xcbaf46d800000000, + 0x0d5bbe4b00000000, 0xcd84308a00000000, 0xcce2d21300000000, + 0x0c3d5cd200000000, 0x8f2867fb00000000, 0x4ff7e93a00000000, + 0x4e910ba300000000, 0x8e4e856200000000, 0x837e8b5f00000000, + 0x43a1059e00000000, 0x42c7e70700000000, 0x821869c600000000, + 0x010d52ef00000000, 0xc1d2dc2e00000000, 0xc0b43eb700000000, + 0x006bb07600000000, 0xc69f48e500000000, 0x0640c62400000000, + 0x072624bd00000000, 0xc7f9aa7c00000000, 0x44ec915500000000, + 0x84331f9400000000, 0x8555fd0d00000000, 0x458a73cc00000000, + 0x702ca9a100000000, 0xb0f3276000000000, 0xb195c5f900000000, + 0x714a4b3800000000, 0xf25f701100000000, 0x3280fed000000000, + 0x33e61c4900000000, 0xf339928800000000, 0x35cd6a1b00000000, + 0xf512e4da00000000, 0xf474064300000000, 0x34ab888200000000, + 0xb7beb3ab00000000, 0x77613d6a00000000, 0x7607dff300000000, + 0xb6d8513200000000, 0xbbe85f0f00000000, 0x7b37d1ce00000000, + 0x7a51335700000000, 0xba8ebd9600000000, 0x399b86bf00000000, + 0xf944087e00000000, 0xf822eae700000000, 0x38fd642600000000, + 0xfe099cb500000000, 0x3ed6127400000000, 0x3fb0f0ed00000000, + 0xff6f7e2c00000000, 0x7c7a450500000000, 0xbca5cbc400000000, + 0xbdc3295d00000000, 0x7d1ca79c00000000, 0xa7a3352700000000, + 0x677cbbe600000000, 0x661a597f00000000, 0xa6c5d7be00000000, + 0x25d0ec9700000000, 0xe50f625600000000, 0xe46980cf00000000, + 0x24b60e0e00000000, 0xe242f69d00000000, 0x229d785c00000000, + 0x23fb9ac500000000, 0xe324140400000000, 0x60312f2d00000000, + 0xa0eea1ec00000000, 0xa188437500000000, 0x6157cdb400000000, + 0x6c67c38900000000, 0xacb84d4800000000, 0xaddeafd100000000, + 0x6d01211000000000, 0xee141a3900000000, 0x2ecb94f800000000, + 0x2fad766100000000, 0xef72f8a000000000, 0x2986003300000000, + 0xe9598ef200000000, 0xe83f6c6b00000000, 0x28e0e2aa00000000, + 0xabf5d98300000000, 0x6b2a574200000000, 0x6a4cb5db00000000, + 0xaa933b1a00000000}, + {0x0000000000000000, 0x6f4ca59b00000000, 0x9f9e3bec00000000, + 0xf0d29e7700000000, 0x7f3b060300000000, 0x1077a39800000000, + 0xe0a53def00000000, 0x8fe9987400000000, 0xfe760c0600000000, + 0x913aa99d00000000, 0x61e837ea00000000, 0x0ea4927100000000, + 0x814d0a0500000000, 0xee01af9e00000000, 0x1ed331e900000000, + 0x719f947200000000, 0xfced180c00000000, 0x93a1bd9700000000, + 0x637323e000000000, 0x0c3f867b00000000, 0x83d61e0f00000000, + 0xec9abb9400000000, 0x1c4825e300000000, 0x7304807800000000, + 0x029b140a00000000, 0x6dd7b19100000000, 0x9d052fe600000000, + 0xf2498a7d00000000, 0x7da0120900000000, 0x12ecb79200000000, + 0xe23e29e500000000, 0x8d728c7e00000000, 0xf8db311800000000, + 0x9797948300000000, 0x67450af400000000, 0x0809af6f00000000, + 0x87e0371b00000000, 0xe8ac928000000000, 0x187e0cf700000000, + 0x7732a96c00000000, 0x06ad3d1e00000000, 0x69e1988500000000, + 0x993306f200000000, 0xf67fa36900000000, 0x79963b1d00000000, + 0x16da9e8600000000, 0xe60800f100000000, 0x8944a56a00000000, + 0x0436291400000000, 0x6b7a8c8f00000000, 0x9ba812f800000000, + 0xf4e4b76300000000, 0x7b0d2f1700000000, 0x14418a8c00000000, + 0xe49314fb00000000, 0x8bdfb16000000000, 0xfa40251200000000, + 0x950c808900000000, 0x65de1efe00000000, 0x0a92bb6500000000, + 0x857b231100000000, 0xea37868a00000000, 0x1ae518fd00000000, + 0x75a9bd6600000000, 0xf0b7633000000000, 0x9ffbc6ab00000000, + 0x6f2958dc00000000, 0x0065fd4700000000, 0x8f8c653300000000, + 0xe0c0c0a800000000, 0x10125edf00000000, 0x7f5efb4400000000, + 0x0ec16f3600000000, 0x618dcaad00000000, 0x915f54da00000000, + 0xfe13f14100000000, 0x71fa693500000000, 0x1eb6ccae00000000, + 0xee6452d900000000, 0x8128f74200000000, 0x0c5a7b3c00000000, + 0x6316dea700000000, 0x93c440d000000000, 0xfc88e54b00000000, + 0x73617d3f00000000, 0x1c2dd8a400000000, 0xecff46d300000000, + 0x83b3e34800000000, 0xf22c773a00000000, 0x9d60d2a100000000, + 0x6db24cd600000000, 0x02fee94d00000000, 0x8d17713900000000, + 0xe25bd4a200000000, 0x12894ad500000000, 0x7dc5ef4e00000000, + 0x086c522800000000, 0x6720f7b300000000, 0x97f269c400000000, + 0xf8becc5f00000000, 0x7757542b00000000, 0x181bf1b000000000, + 0xe8c96fc700000000, 0x8785ca5c00000000, 0xf61a5e2e00000000, + 0x9956fbb500000000, 0x698465c200000000, 0x06c8c05900000000, + 0x8921582d00000000, 0xe66dfdb600000000, 0x16bf63c100000000, + 0x79f3c65a00000000, 0xf4814a2400000000, 0x9bcdefbf00000000, + 0x6b1f71c800000000, 0x0453d45300000000, 0x8bba4c2700000000, + 0xe4f6e9bc00000000, 0x142477cb00000000, 0x7b68d25000000000, + 0x0af7462200000000, 0x65bbe3b900000000, 0x95697dce00000000, + 0xfa25d85500000000, 0x75cc402100000000, 0x1a80e5ba00000000, + 0xea527bcd00000000, 0x851ede5600000000, 0xe06fc76000000000, + 0x8f2362fb00000000, 0x7ff1fc8c00000000, 0x10bd591700000000, + 0x9f54c16300000000, 0xf01864f800000000, 0x00cafa8f00000000, + 0x6f865f1400000000, 0x1e19cb6600000000, 0x71556efd00000000, + 0x8187f08a00000000, 0xeecb551100000000, 0x6122cd6500000000, + 0x0e6e68fe00000000, 0xfebcf68900000000, 0x91f0531200000000, + 0x1c82df6c00000000, 0x73ce7af700000000, 0x831ce48000000000, + 0xec50411b00000000, 0x63b9d96f00000000, 0x0cf57cf400000000, + 0xfc27e28300000000, 0x936b471800000000, 0xe2f4d36a00000000, + 0x8db876f100000000, 0x7d6ae88600000000, 0x12264d1d00000000, + 0x9dcfd56900000000, 0xf28370f200000000, 0x0251ee8500000000, + 0x6d1d4b1e00000000, 0x18b4f67800000000, 0x77f853e300000000, + 0x872acd9400000000, 0xe866680f00000000, 0x678ff07b00000000, + 0x08c355e000000000, 0xf811cb9700000000, 0x975d6e0c00000000, + 0xe6c2fa7e00000000, 0x898e5fe500000000, 0x795cc19200000000, + 0x1610640900000000, 0x99f9fc7d00000000, 0xf6b559e600000000, + 0x0667c79100000000, 0x692b620a00000000, 0xe459ee7400000000, + 0x8b154bef00000000, 0x7bc7d59800000000, 0x148b700300000000, + 0x9b62e87700000000, 0xf42e4dec00000000, 0x04fcd39b00000000, + 0x6bb0760000000000, 0x1a2fe27200000000, 0x756347e900000000, + 0x85b1d99e00000000, 0xeafd7c0500000000, 0x6514e47100000000, + 0x0a5841ea00000000, 0xfa8adf9d00000000, 0x95c67a0600000000, + 0x10d8a45000000000, 0x7f9401cb00000000, 0x8f469fbc00000000, + 0xe00a3a2700000000, 0x6fe3a25300000000, 0x00af07c800000000, + 0xf07d99bf00000000, 0x9f313c2400000000, 0xeeaea85600000000, + 0x81e20dcd00000000, 0x713093ba00000000, 0x1e7c362100000000, + 0x9195ae5500000000, 0xfed90bce00000000, 0x0e0b95b900000000, + 0x6147302200000000, 0xec35bc5c00000000, 0x837919c700000000, + 0x73ab87b000000000, 0x1ce7222b00000000, 0x930eba5f00000000, + 0xfc421fc400000000, 0x0c9081b300000000, 0x63dc242800000000, + 0x1243b05a00000000, 0x7d0f15c100000000, 0x8ddd8bb600000000, + 0xe2912e2d00000000, 0x6d78b65900000000, 0x023413c200000000, + 0xf2e68db500000000, 0x9daa282e00000000, 0xe803954800000000, + 0x874f30d300000000, 0x779daea400000000, 0x18d10b3f00000000, + 0x9738934b00000000, 0xf87436d000000000, 0x08a6a8a700000000, + 0x67ea0d3c00000000, 0x1675994e00000000, 0x79393cd500000000, + 0x89eba2a200000000, 0xe6a7073900000000, 0x694e9f4d00000000, + 0x06023ad600000000, 0xf6d0a4a100000000, 0x999c013a00000000, + 0x14ee8d4400000000, 0x7ba228df00000000, 0x8b70b6a800000000, + 0xe43c133300000000, 0x6bd58b4700000000, 0x04992edc00000000, + 0xf44bb0ab00000000, 0x9b07153000000000, 0xea98814200000000, + 0x85d424d900000000, 0x7506baae00000000, 0x1a4a1f3500000000, + 0x95a3874100000000, 0xfaef22da00000000, 0x0a3dbcad00000000, + 0x6571193600000000}, + {0x0000000000000000, 0x85d996dd00000000, 0x4bb55c6000000000, + 0xce6ccabd00000000, 0x966ab9c000000000, 0x13b32f1d00000000, + 0xdddfe5a000000000, 0x5806737d00000000, 0x6dd3035a00000000, + 0xe80a958700000000, 0x26665f3a00000000, 0xa3bfc9e700000000, + 0xfbb9ba9a00000000, 0x7e602c4700000000, 0xb00ce6fa00000000, + 0x35d5702700000000, 0xdaa607b400000000, 0x5f7f916900000000, + 0x91135bd400000000, 0x14cacd0900000000, 0x4cccbe7400000000, + 0xc91528a900000000, 0x0779e21400000000, 0x82a074c900000000, + 0xb77504ee00000000, 0x32ac923300000000, 0xfcc0588e00000000, + 0x7919ce5300000000, 0x211fbd2e00000000, 0xa4c62bf300000000, + 0x6aaae14e00000000, 0xef73779300000000, 0xf54b7eb300000000, + 0x7092e86e00000000, 0xbefe22d300000000, 0x3b27b40e00000000, + 0x6321c77300000000, 0xe6f851ae00000000, 0x28949b1300000000, + 0xad4d0dce00000000, 0x98987de900000000, 0x1d41eb3400000000, + 0xd32d218900000000, 0x56f4b75400000000, 0x0ef2c42900000000, + 0x8b2b52f400000000, 0x4547984900000000, 0xc09e0e9400000000, + 0x2fed790700000000, 0xaa34efda00000000, 0x6458256700000000, + 0xe181b3ba00000000, 0xb987c0c700000000, 0x3c5e561a00000000, + 0xf2329ca700000000, 0x77eb0a7a00000000, 0x423e7a5d00000000, + 0xc7e7ec8000000000, 0x098b263d00000000, 0x8c52b0e000000000, + 0xd454c39d00000000, 0x518d554000000000, 0x9fe19ffd00000000, + 0x1a38092000000000, 0xab918dbd00000000, 0x2e481b6000000000, + 0xe024d1dd00000000, 0x65fd470000000000, 0x3dfb347d00000000, + 0xb822a2a000000000, 0x764e681d00000000, 0xf397fec000000000, + 0xc6428ee700000000, 0x439b183a00000000, 0x8df7d28700000000, + 0x082e445a00000000, 0x5028372700000000, 0xd5f1a1fa00000000, + 0x1b9d6b4700000000, 0x9e44fd9a00000000, 0x71378a0900000000, + 0xf4ee1cd400000000, 0x3a82d66900000000, 0xbf5b40b400000000, + 0xe75d33c900000000, 0x6284a51400000000, 0xace86fa900000000, + 0x2931f97400000000, 0x1ce4895300000000, 0x993d1f8e00000000, + 0x5751d53300000000, 0xd28843ee00000000, 0x8a8e309300000000, + 0x0f57a64e00000000, 0xc13b6cf300000000, 0x44e2fa2e00000000, + 0x5edaf30e00000000, 0xdb0365d300000000, 0x156faf6e00000000, + 0x90b639b300000000, 0xc8b04ace00000000, 0x4d69dc1300000000, + 0x830516ae00000000, 0x06dc807300000000, 0x3309f05400000000, + 0xb6d0668900000000, 0x78bcac3400000000, 0xfd653ae900000000, + 0xa563499400000000, 0x20badf4900000000, 0xeed615f400000000, + 0x6b0f832900000000, 0x847cf4ba00000000, 0x01a5626700000000, + 0xcfc9a8da00000000, 0x4a103e0700000000, 0x12164d7a00000000, + 0x97cfdba700000000, 0x59a3111a00000000, 0xdc7a87c700000000, + 0xe9aff7e000000000, 0x6c76613d00000000, 0xa21aab8000000000, + 0x27c33d5d00000000, 0x7fc54e2000000000, 0xfa1cd8fd00000000, + 0x3470124000000000, 0xb1a9849d00000000, 0x17256aa000000000, + 0x92fcfc7d00000000, 0x5c9036c000000000, 0xd949a01d00000000, + 0x814fd36000000000, 0x049645bd00000000, 0xcafa8f0000000000, + 0x4f2319dd00000000, 0x7af669fa00000000, 0xff2fff2700000000, + 0x3143359a00000000, 0xb49aa34700000000, 0xec9cd03a00000000, + 0x694546e700000000, 0xa7298c5a00000000, 0x22f01a8700000000, + 0xcd836d1400000000, 0x485afbc900000000, 0x8636317400000000, + 0x03efa7a900000000, 0x5be9d4d400000000, 0xde30420900000000, + 0x105c88b400000000, 0x95851e6900000000, 0xa0506e4e00000000, + 0x2589f89300000000, 0xebe5322e00000000, 0x6e3ca4f300000000, + 0x363ad78e00000000, 0xb3e3415300000000, 0x7d8f8bee00000000, + 0xf8561d3300000000, 0xe26e141300000000, 0x67b782ce00000000, + 0xa9db487300000000, 0x2c02deae00000000, 0x7404add300000000, + 0xf1dd3b0e00000000, 0x3fb1f1b300000000, 0xba68676e00000000, + 0x8fbd174900000000, 0x0a64819400000000, 0xc4084b2900000000, + 0x41d1ddf400000000, 0x19d7ae8900000000, 0x9c0e385400000000, + 0x5262f2e900000000, 0xd7bb643400000000, 0x38c813a700000000, + 0xbd11857a00000000, 0x737d4fc700000000, 0xf6a4d91a00000000, + 0xaea2aa6700000000, 0x2b7b3cba00000000, 0xe517f60700000000, + 0x60ce60da00000000, 0x551b10fd00000000, 0xd0c2862000000000, + 0x1eae4c9d00000000, 0x9b77da4000000000, 0xc371a93d00000000, + 0x46a83fe000000000, 0x88c4f55d00000000, 0x0d1d638000000000, + 0xbcb4e71d00000000, 0x396d71c000000000, 0xf701bb7d00000000, + 0x72d82da000000000, 0x2ade5edd00000000, 0xaf07c80000000000, + 0x616b02bd00000000, 0xe4b2946000000000, 0xd167e44700000000, + 0x54be729a00000000, 0x9ad2b82700000000, 0x1f0b2efa00000000, + 0x470d5d8700000000, 0xc2d4cb5a00000000, 0x0cb801e700000000, + 0x8961973a00000000, 0x6612e0a900000000, 0xe3cb767400000000, + 0x2da7bcc900000000, 0xa87e2a1400000000, 0xf078596900000000, + 0x75a1cfb400000000, 0xbbcd050900000000, 0x3e1493d400000000, + 0x0bc1e3f300000000, 0x8e18752e00000000, 0x4074bf9300000000, + 0xc5ad294e00000000, 0x9dab5a3300000000, 0x1872ccee00000000, + 0xd61e065300000000, 0x53c7908e00000000, 0x49ff99ae00000000, + 0xcc260f7300000000, 0x024ac5ce00000000, 0x8793531300000000, + 0xdf95206e00000000, 0x5a4cb6b300000000, 0x94207c0e00000000, + 0x11f9ead300000000, 0x242c9af400000000, 0xa1f50c2900000000, + 0x6f99c69400000000, 0xea40504900000000, 0xb246233400000000, + 0x379fb5e900000000, 0xf9f37f5400000000, 0x7c2ae98900000000, + 0x93599e1a00000000, 0x168008c700000000, 0xd8ecc27a00000000, + 0x5d3554a700000000, 0x053327da00000000, 0x80eab10700000000, + 0x4e867bba00000000, 0xcb5fed6700000000, 0xfe8a9d4000000000, + 0x7b530b9d00000000, 0xb53fc12000000000, 0x30e657fd00000000, + 0x68e0248000000000, 0xed39b25d00000000, 0x235578e000000000, + 0xa68cee3d00000000}, + {0x0000000000000000, 0x76e10f9d00000000, 0xadc46ee100000000, + 0xdb25617c00000000, 0x1b8fac1900000000, 0x6d6ea38400000000, + 0xb64bc2f800000000, 0xc0aacd6500000000, 0x361e593300000000, + 0x40ff56ae00000000, 0x9bda37d200000000, 0xed3b384f00000000, + 0x2d91f52a00000000, 0x5b70fab700000000, 0x80559bcb00000000, + 0xf6b4945600000000, 0x6c3cb26600000000, 0x1addbdfb00000000, + 0xc1f8dc8700000000, 0xb719d31a00000000, 0x77b31e7f00000000, + 0x015211e200000000, 0xda77709e00000000, 0xac967f0300000000, + 0x5a22eb5500000000, 0x2cc3e4c800000000, 0xf7e685b400000000, + 0x81078a2900000000, 0x41ad474c00000000, 0x374c48d100000000, + 0xec6929ad00000000, 0x9a88263000000000, 0xd87864cd00000000, + 0xae996b5000000000, 0x75bc0a2c00000000, 0x035d05b100000000, + 0xc3f7c8d400000000, 0xb516c74900000000, 0x6e33a63500000000, + 0x18d2a9a800000000, 0xee663dfe00000000, 0x9887326300000000, + 0x43a2531f00000000, 0x35435c8200000000, 0xf5e991e700000000, + 0x83089e7a00000000, 0x582dff0600000000, 0x2eccf09b00000000, + 0xb444d6ab00000000, 0xc2a5d93600000000, 0x1980b84a00000000, + 0x6f61b7d700000000, 0xafcb7ab200000000, 0xd92a752f00000000, + 0x020f145300000000, 0x74ee1bce00000000, 0x825a8f9800000000, + 0xf4bb800500000000, 0x2f9ee17900000000, 0x597feee400000000, + 0x99d5238100000000, 0xef342c1c00000000, 0x34114d6000000000, + 0x42f042fd00000000, 0xf1f7b94100000000, 0x8716b6dc00000000, + 0x5c33d7a000000000, 0x2ad2d83d00000000, 0xea78155800000000, + 0x9c991ac500000000, 0x47bc7bb900000000, 0x315d742400000000, + 0xc7e9e07200000000, 0xb108efef00000000, 0x6a2d8e9300000000, + 0x1ccc810e00000000, 0xdc664c6b00000000, 0xaa8743f600000000, + 0x71a2228a00000000, 0x07432d1700000000, 0x9dcb0b2700000000, + 0xeb2a04ba00000000, 0x300f65c600000000, 0x46ee6a5b00000000, + 0x8644a73e00000000, 0xf0a5a8a300000000, 0x2b80c9df00000000, + 0x5d61c64200000000, 0xabd5521400000000, 0xdd345d8900000000, + 0x06113cf500000000, 0x70f0336800000000, 0xb05afe0d00000000, + 0xc6bbf19000000000, 0x1d9e90ec00000000, 0x6b7f9f7100000000, + 0x298fdd8c00000000, 0x5f6ed21100000000, 0x844bb36d00000000, + 0xf2aabcf000000000, 0x3200719500000000, 0x44e17e0800000000, + 0x9fc41f7400000000, 0xe92510e900000000, 0x1f9184bf00000000, + 0x69708b2200000000, 0xb255ea5e00000000, 0xc4b4e5c300000000, + 0x041e28a600000000, 0x72ff273b00000000, 0xa9da464700000000, + 0xdf3b49da00000000, 0x45b36fea00000000, 0x3352607700000000, + 0xe877010b00000000, 0x9e960e9600000000, 0x5e3cc3f300000000, + 0x28ddcc6e00000000, 0xf3f8ad1200000000, 0x8519a28f00000000, + 0x73ad36d900000000, 0x054c394400000000, 0xde69583800000000, + 0xa88857a500000000, 0x68229ac000000000, 0x1ec3955d00000000, + 0xc5e6f42100000000, 0xb307fbbc00000000, 0xe2ef738300000000, + 0x940e7c1e00000000, 0x4f2b1d6200000000, 0x39ca12ff00000000, + 0xf960df9a00000000, 0x8f81d00700000000, 0x54a4b17b00000000, + 0x2245bee600000000, 0xd4f12ab000000000, 0xa210252d00000000, + 0x7935445100000000, 0x0fd44bcc00000000, 0xcf7e86a900000000, + 0xb99f893400000000, 0x62bae84800000000, 0x145be7d500000000, + 0x8ed3c1e500000000, 0xf832ce7800000000, 0x2317af0400000000, + 0x55f6a09900000000, 0x955c6dfc00000000, 0xe3bd626100000000, + 0x3898031d00000000, 0x4e790c8000000000, 0xb8cd98d600000000, + 0xce2c974b00000000, 0x1509f63700000000, 0x63e8f9aa00000000, + 0xa34234cf00000000, 0xd5a33b5200000000, 0x0e865a2e00000000, + 0x786755b300000000, 0x3a97174e00000000, 0x4c7618d300000000, + 0x975379af00000000, 0xe1b2763200000000, 0x2118bb5700000000, + 0x57f9b4ca00000000, 0x8cdcd5b600000000, 0xfa3dda2b00000000, + 0x0c894e7d00000000, 0x7a6841e000000000, 0xa14d209c00000000, + 0xd7ac2f0100000000, 0x1706e26400000000, 0x61e7edf900000000, + 0xbac28c8500000000, 0xcc23831800000000, 0x56aba52800000000, + 0x204aaab500000000, 0xfb6fcbc900000000, 0x8d8ec45400000000, + 0x4d24093100000000, 0x3bc506ac00000000, 0xe0e067d000000000, + 0x9601684d00000000, 0x60b5fc1b00000000, 0x1654f38600000000, + 0xcd7192fa00000000, 0xbb909d6700000000, 0x7b3a500200000000, + 0x0ddb5f9f00000000, 0xd6fe3ee300000000, 0xa01f317e00000000, + 0x1318cac200000000, 0x65f9c55f00000000, 0xbedca42300000000, + 0xc83dabbe00000000, 0x089766db00000000, 0x7e76694600000000, + 0xa553083a00000000, 0xd3b207a700000000, 0x250693f100000000, + 0x53e79c6c00000000, 0x88c2fd1000000000, 0xfe23f28d00000000, + 0x3e893fe800000000, 0x4868307500000000, 0x934d510900000000, + 0xe5ac5e9400000000, 0x7f2478a400000000, 0x09c5773900000000, + 0xd2e0164500000000, 0xa40119d800000000, 0x64abd4bd00000000, + 0x124adb2000000000, 0xc96fba5c00000000, 0xbf8eb5c100000000, + 0x493a219700000000, 0x3fdb2e0a00000000, 0xe4fe4f7600000000, + 0x921f40eb00000000, 0x52b58d8e00000000, 0x2454821300000000, + 0xff71e36f00000000, 0x8990ecf200000000, 0xcb60ae0f00000000, + 0xbd81a19200000000, 0x66a4c0ee00000000, 0x1045cf7300000000, + 0xd0ef021600000000, 0xa60e0d8b00000000, 0x7d2b6cf700000000, + 0x0bca636a00000000, 0xfd7ef73c00000000, 0x8b9ff8a100000000, + 0x50ba99dd00000000, 0x265b964000000000, 0xe6f15b2500000000, + 0x901054b800000000, 0x4b3535c400000000, 0x3dd43a5900000000, + 0xa75c1c6900000000, 0xd1bd13f400000000, 0x0a98728800000000, + 0x7c797d1500000000, 0xbcd3b07000000000, 0xca32bfed00000000, + 0x1117de9100000000, 0x67f6d10c00000000, 0x9142455a00000000, + 0xe7a34ac700000000, 0x3c862bbb00000000, 0x4a67242600000000, + 0x8acde94300000000, 0xfc2ce6de00000000, 0x270987a200000000, + 0x51e8883f00000000}, + {0x0000000000000000, 0xe8dbfbb900000000, 0x91b186a800000000, + 0x796a7d1100000000, 0x63657c8a00000000, 0x8bbe873300000000, + 0xf2d4fa2200000000, 0x1a0f019b00000000, 0x87cc89cf00000000, + 0x6f17727600000000, 0x167d0f6700000000, 0xfea6f4de00000000, + 0xe4a9f54500000000, 0x0c720efc00000000, 0x751873ed00000000, + 0x9dc3885400000000, 0x4f9f624400000000, 0xa74499fd00000000, + 0xde2ee4ec00000000, 0x36f51f5500000000, 0x2cfa1ece00000000, + 0xc421e57700000000, 0xbd4b986600000000, 0x559063df00000000, + 0xc853eb8b00000000, 0x2088103200000000, 0x59e26d2300000000, + 0xb139969a00000000, 0xab36970100000000, 0x43ed6cb800000000, + 0x3a8711a900000000, 0xd25cea1000000000, 0x9e3ec58800000000, + 0x76e53e3100000000, 0x0f8f432000000000, 0xe754b89900000000, + 0xfd5bb90200000000, 0x158042bb00000000, 0x6cea3faa00000000, + 0x8431c41300000000, 0x19f24c4700000000, 0xf129b7fe00000000, + 0x8843caef00000000, 0x6098315600000000, 0x7a9730cd00000000, + 0x924ccb7400000000, 0xeb26b66500000000, 0x03fd4ddc00000000, + 0xd1a1a7cc00000000, 0x397a5c7500000000, 0x4010216400000000, + 0xa8cbdadd00000000, 0xb2c4db4600000000, 0x5a1f20ff00000000, + 0x23755dee00000000, 0xcbaea65700000000, 0x566d2e0300000000, + 0xbeb6d5ba00000000, 0xc7dca8ab00000000, 0x2f07531200000000, + 0x3508528900000000, 0xddd3a93000000000, 0xa4b9d42100000000, + 0x4c622f9800000000, 0x7d7bfbca00000000, 0x95a0007300000000, + 0xecca7d6200000000, 0x041186db00000000, 0x1e1e874000000000, + 0xf6c57cf900000000, 0x8faf01e800000000, 0x6774fa5100000000, + 0xfab7720500000000, 0x126c89bc00000000, 0x6b06f4ad00000000, + 0x83dd0f1400000000, 0x99d20e8f00000000, 0x7109f53600000000, + 0x0863882700000000, 0xe0b8739e00000000, 0x32e4998e00000000, + 0xda3f623700000000, 0xa3551f2600000000, 0x4b8ee49f00000000, + 0x5181e50400000000, 0xb95a1ebd00000000, 0xc03063ac00000000, + 0x28eb981500000000, 0xb528104100000000, 0x5df3ebf800000000, + 0x249996e900000000, 0xcc426d5000000000, 0xd64d6ccb00000000, + 0x3e96977200000000, 0x47fcea6300000000, 0xaf2711da00000000, + 0xe3453e4200000000, 0x0b9ec5fb00000000, 0x72f4b8ea00000000, + 0x9a2f435300000000, 0x802042c800000000, 0x68fbb97100000000, + 0x1191c46000000000, 0xf94a3fd900000000, 0x6489b78d00000000, + 0x8c524c3400000000, 0xf538312500000000, 0x1de3ca9c00000000, + 0x07eccb0700000000, 0xef3730be00000000, 0x965d4daf00000000, + 0x7e86b61600000000, 0xacda5c0600000000, 0x4401a7bf00000000, + 0x3d6bdaae00000000, 0xd5b0211700000000, 0xcfbf208c00000000, + 0x2764db3500000000, 0x5e0ea62400000000, 0xb6d55d9d00000000, + 0x2b16d5c900000000, 0xc3cd2e7000000000, 0xbaa7536100000000, + 0x527ca8d800000000, 0x4873a94300000000, 0xa0a852fa00000000, + 0xd9c22feb00000000, 0x3119d45200000000, 0xbbf0874e00000000, + 0x532b7cf700000000, 0x2a4101e600000000, 0xc29afa5f00000000, + 0xd895fbc400000000, 0x304e007d00000000, 0x49247d6c00000000, + 0xa1ff86d500000000, 0x3c3c0e8100000000, 0xd4e7f53800000000, + 0xad8d882900000000, 0x4556739000000000, 0x5f59720b00000000, + 0xb78289b200000000, 0xcee8f4a300000000, 0x26330f1a00000000, + 0xf46fe50a00000000, 0x1cb41eb300000000, 0x65de63a200000000, + 0x8d05981b00000000, 0x970a998000000000, 0x7fd1623900000000, + 0x06bb1f2800000000, 0xee60e49100000000, 0x73a36cc500000000, + 0x9b78977c00000000, 0xe212ea6d00000000, 0x0ac911d400000000, + 0x10c6104f00000000, 0xf81debf600000000, 0x817796e700000000, + 0x69ac6d5e00000000, 0x25ce42c600000000, 0xcd15b97f00000000, + 0xb47fc46e00000000, 0x5ca43fd700000000, 0x46ab3e4c00000000, + 0xae70c5f500000000, 0xd71ab8e400000000, 0x3fc1435d00000000, + 0xa202cb0900000000, 0x4ad930b000000000, 0x33b34da100000000, + 0xdb68b61800000000, 0xc167b78300000000, 0x29bc4c3a00000000, + 0x50d6312b00000000, 0xb80dca9200000000, 0x6a51208200000000, + 0x828adb3b00000000, 0xfbe0a62a00000000, 0x133b5d9300000000, + 0x09345c0800000000, 0xe1efa7b100000000, 0x9885daa000000000, + 0x705e211900000000, 0xed9da94d00000000, 0x054652f400000000, + 0x7c2c2fe500000000, 0x94f7d45c00000000, 0x8ef8d5c700000000, + 0x66232e7e00000000, 0x1f49536f00000000, 0xf792a8d600000000, + 0xc68b7c8400000000, 0x2e50873d00000000, 0x573afa2c00000000, + 0xbfe1019500000000, 0xa5ee000e00000000, 0x4d35fbb700000000, + 0x345f86a600000000, 0xdc847d1f00000000, 0x4147f54b00000000, + 0xa99c0ef200000000, 0xd0f673e300000000, 0x382d885a00000000, + 0x222289c100000000, 0xcaf9727800000000, 0xb3930f6900000000, + 0x5b48f4d000000000, 0x89141ec000000000, 0x61cfe57900000000, + 0x18a5986800000000, 0xf07e63d100000000, 0xea71624a00000000, + 0x02aa99f300000000, 0x7bc0e4e200000000, 0x931b1f5b00000000, + 0x0ed8970f00000000, 0xe6036cb600000000, 0x9f6911a700000000, + 0x77b2ea1e00000000, 0x6dbdeb8500000000, 0x8566103c00000000, + 0xfc0c6d2d00000000, 0x14d7969400000000, 0x58b5b90c00000000, + 0xb06e42b500000000, 0xc9043fa400000000, 0x21dfc41d00000000, + 0x3bd0c58600000000, 0xd30b3e3f00000000, 0xaa61432e00000000, + 0x42bab89700000000, 0xdf7930c300000000, 0x37a2cb7a00000000, + 0x4ec8b66b00000000, 0xa6134dd200000000, 0xbc1c4c4900000000, + 0x54c7b7f000000000, 0x2dadcae100000000, 0xc576315800000000, + 0x172adb4800000000, 0xfff120f100000000, 0x869b5de000000000, + 0x6e40a65900000000, 0x744fa7c200000000, 0x9c945c7b00000000, + 0xe5fe216a00000000, 0x0d25dad300000000, 0x90e6528700000000, + 0x783da93e00000000, 0x0157d42f00000000, 0xe98c2f9600000000, + 0xf3832e0d00000000, 0x1b58d5b400000000, 0x6232a8a500000000, + 0x8ae9531c00000000}, + {0x0000000000000000, 0x919168ae00000000, 0x6325a08700000000, + 0xf2b4c82900000000, 0x874c31d400000000, 0x16dd597a00000000, + 0xe469915300000000, 0x75f8f9fd00000000, 0x4f9f137300000000, + 0xde0e7bdd00000000, 0x2cbab3f400000000, 0xbd2bdb5a00000000, + 0xc8d322a700000000, 0x59424a0900000000, 0xabf6822000000000, + 0x3a67ea8e00000000, 0x9e3e27e600000000, 0x0faf4f4800000000, + 0xfd1b876100000000, 0x6c8aefcf00000000, 0x1972163200000000, + 0x88e37e9c00000000, 0x7a57b6b500000000, 0xebc6de1b00000000, + 0xd1a1349500000000, 0x40305c3b00000000, 0xb284941200000000, + 0x2315fcbc00000000, 0x56ed054100000000, 0xc77c6def00000000, + 0x35c8a5c600000000, 0xa459cd6800000000, 0x7d7b3f1700000000, + 0xecea57b900000000, 0x1e5e9f9000000000, 0x8fcff73e00000000, + 0xfa370ec300000000, 0x6ba6666d00000000, 0x9912ae4400000000, + 0x0883c6ea00000000, 0x32e42c6400000000, 0xa37544ca00000000, + 0x51c18ce300000000, 0xc050e44d00000000, 0xb5a81db000000000, + 0x2439751e00000000, 0xd68dbd3700000000, 0x471cd59900000000, + 0xe34518f100000000, 0x72d4705f00000000, 0x8060b87600000000, + 0x11f1d0d800000000, 0x6409292500000000, 0xf598418b00000000, + 0x072c89a200000000, 0x96bde10c00000000, 0xacda0b8200000000, + 0x3d4b632c00000000, 0xcfffab0500000000, 0x5e6ec3ab00000000, + 0x2b963a5600000000, 0xba0752f800000000, 0x48b39ad100000000, + 0xd922f27f00000000, 0xfaf67e2e00000000, 0x6b67168000000000, + 0x99d3dea900000000, 0x0842b60700000000, 0x7dba4ffa00000000, + 0xec2b275400000000, 0x1e9fef7d00000000, 0x8f0e87d300000000, + 0xb5696d5d00000000, 0x24f805f300000000, 0xd64ccdda00000000, + 0x47dda57400000000, 0x32255c8900000000, 0xa3b4342700000000, + 0x5100fc0e00000000, 0xc09194a000000000, 0x64c859c800000000, + 0xf559316600000000, 0x07edf94f00000000, 0x967c91e100000000, + 0xe384681c00000000, 0x721500b200000000, 0x80a1c89b00000000, + 0x1130a03500000000, 0x2b574abb00000000, 0xbac6221500000000, + 0x4872ea3c00000000, 0xd9e3829200000000, 0xac1b7b6f00000000, + 0x3d8a13c100000000, 0xcf3edbe800000000, 0x5eafb34600000000, + 0x878d413900000000, 0x161c299700000000, 0xe4a8e1be00000000, + 0x7539891000000000, 0x00c170ed00000000, 0x9150184300000000, + 0x63e4d06a00000000, 0xf275b8c400000000, 0xc812524a00000000, + 0x59833ae400000000, 0xab37f2cd00000000, 0x3aa69a6300000000, + 0x4f5e639e00000000, 0xdecf0b3000000000, 0x2c7bc31900000000, + 0xbdeaabb700000000, 0x19b366df00000000, 0x88220e7100000000, + 0x7a96c65800000000, 0xeb07aef600000000, 0x9eff570b00000000, + 0x0f6e3fa500000000, 0xfddaf78c00000000, 0x6c4b9f2200000000, + 0x562c75ac00000000, 0xc7bd1d0200000000, 0x3509d52b00000000, + 0xa498bd8500000000, 0xd160447800000000, 0x40f12cd600000000, + 0xb245e4ff00000000, 0x23d48c5100000000, 0xf4edfd5c00000000, + 0x657c95f200000000, 0x97c85ddb00000000, 0x0659357500000000, + 0x73a1cc8800000000, 0xe230a42600000000, 0x10846c0f00000000, + 0x811504a100000000, 0xbb72ee2f00000000, 0x2ae3868100000000, + 0xd8574ea800000000, 0x49c6260600000000, 0x3c3edffb00000000, + 0xadafb75500000000, 0x5f1b7f7c00000000, 0xce8a17d200000000, + 0x6ad3daba00000000, 0xfb42b21400000000, 0x09f67a3d00000000, + 0x9867129300000000, 0xed9feb6e00000000, 0x7c0e83c000000000, + 0x8eba4be900000000, 0x1f2b234700000000, 0x254cc9c900000000, + 0xb4dda16700000000, 0x4669694e00000000, 0xd7f801e000000000, + 0xa200f81d00000000, 0x339190b300000000, 0xc125589a00000000, + 0x50b4303400000000, 0x8996c24b00000000, 0x1807aae500000000, + 0xeab362cc00000000, 0x7b220a6200000000, 0x0edaf39f00000000, + 0x9f4b9b3100000000, 0x6dff531800000000, 0xfc6e3bb600000000, + 0xc609d13800000000, 0x5798b99600000000, 0xa52c71bf00000000, + 0x34bd191100000000, 0x4145e0ec00000000, 0xd0d4884200000000, + 0x2260406b00000000, 0xb3f128c500000000, 0x17a8e5ad00000000, + 0x86398d0300000000, 0x748d452a00000000, 0xe51c2d8400000000, + 0x90e4d47900000000, 0x0175bcd700000000, 0xf3c174fe00000000, + 0x62501c5000000000, 0x5837f6de00000000, 0xc9a69e7000000000, + 0x3b12565900000000, 0xaa833ef700000000, 0xdf7bc70a00000000, + 0x4eeaafa400000000, 0xbc5e678d00000000, 0x2dcf0f2300000000, + 0x0e1b837200000000, 0x9f8aebdc00000000, 0x6d3e23f500000000, + 0xfcaf4b5b00000000, 0x8957b2a600000000, 0x18c6da0800000000, + 0xea72122100000000, 0x7be37a8f00000000, 0x4184900100000000, + 0xd015f8af00000000, 0x22a1308600000000, 0xb330582800000000, + 0xc6c8a1d500000000, 0x5759c97b00000000, 0xa5ed015200000000, + 0x347c69fc00000000, 0x9025a49400000000, 0x01b4cc3a00000000, + 0xf300041300000000, 0x62916cbd00000000, 0x1769954000000000, + 0x86f8fdee00000000, 0x744c35c700000000, 0xe5dd5d6900000000, + 0xdfbab7e700000000, 0x4e2bdf4900000000, 0xbc9f176000000000, + 0x2d0e7fce00000000, 0x58f6863300000000, 0xc967ee9d00000000, + 0x3bd326b400000000, 0xaa424e1a00000000, 0x7360bc6500000000, + 0xe2f1d4cb00000000, 0x10451ce200000000, 0x81d4744c00000000, + 0xf42c8db100000000, 0x65bde51f00000000, 0x97092d3600000000, + 0x0698459800000000, 0x3cffaf1600000000, 0xad6ec7b800000000, + 0x5fda0f9100000000, 0xce4b673f00000000, 0xbbb39ec200000000, + 0x2a22f66c00000000, 0xd8963e4500000000, 0x490756eb00000000, + 0xed5e9b8300000000, 0x7ccff32d00000000, 0x8e7b3b0400000000, + 0x1fea53aa00000000, 0x6a12aa5700000000, 0xfb83c2f900000000, + 0x09370ad000000000, 0x98a6627e00000000, 0xa2c188f000000000, + 0x3350e05e00000000, 0xc1e4287700000000, 0x507540d900000000, + 0x258db92400000000, 0xb41cd18a00000000, 0x46a819a300000000, + 0xd739710d00000000}}; + +#else /* W == 4 */ + +local const z_crc_t FAR crc_braid_table[][256] = { + {0x00000000, 0xccaa009e, 0x4225077d, 0x8e8f07e3, 0x844a0efa, + 0x48e00e64, 0xc66f0987, 0x0ac50919, 0xd3e51bb5, 0x1f4f1b2b, + 0x91c01cc8, 0x5d6a1c56, 0x57af154f, 0x9b0515d1, 0x158a1232, + 0xd92012ac, 0x7cbb312b, 0xb01131b5, 0x3e9e3656, 0xf23436c8, + 0xf8f13fd1, 0x345b3f4f, 0xbad438ac, 0x767e3832, 0xaf5e2a9e, + 0x63f42a00, 0xed7b2de3, 0x21d12d7d, 0x2b142464, 0xe7be24fa, + 0x69312319, 0xa59b2387, 0xf9766256, 0x35dc62c8, 0xbb53652b, + 0x77f965b5, 0x7d3c6cac, 0xb1966c32, 0x3f196bd1, 0xf3b36b4f, + 0x2a9379e3, 0xe639797d, 0x68b67e9e, 0xa41c7e00, 0xaed97719, + 0x62737787, 0xecfc7064, 0x205670fa, 0x85cd537d, 0x496753e3, + 0xc7e85400, 0x0b42549e, 0x01875d87, 0xcd2d5d19, 0x43a25afa, + 0x8f085a64, 0x562848c8, 0x9a824856, 0x140d4fb5, 0xd8a74f2b, + 0xd2624632, 0x1ec846ac, 0x9047414f, 0x5ced41d1, 0x299dc2ed, + 0xe537c273, 0x6bb8c590, 0xa712c50e, 0xadd7cc17, 0x617dcc89, + 0xeff2cb6a, 0x2358cbf4, 0xfa78d958, 0x36d2d9c6, 0xb85dde25, + 0x74f7debb, 0x7e32d7a2, 0xb298d73c, 0x3c17d0df, 0xf0bdd041, + 0x5526f3c6, 0x998cf358, 0x1703f4bb, 0xdba9f425, 0xd16cfd3c, + 0x1dc6fda2, 0x9349fa41, 0x5fe3fadf, 0x86c3e873, 0x4a69e8ed, + 0xc4e6ef0e, 0x084cef90, 0x0289e689, 0xce23e617, 0x40ace1f4, + 0x8c06e16a, 0xd0eba0bb, 0x1c41a025, 0x92cea7c6, 0x5e64a758, + 0x54a1ae41, 0x980baedf, 0x1684a93c, 0xda2ea9a2, 0x030ebb0e, + 0xcfa4bb90, 0x412bbc73, 0x8d81bced, 0x8744b5f4, 0x4beeb56a, + 0xc561b289, 0x09cbb217, 0xac509190, 0x60fa910e, 0xee7596ed, + 0x22df9673, 0x281a9f6a, 0xe4b09ff4, 0x6a3f9817, 0xa6959889, + 0x7fb58a25, 0xb31f8abb, 0x3d908d58, 0xf13a8dc6, 0xfbff84df, + 0x37558441, 0xb9da83a2, 0x7570833c, 0x533b85da, 0x9f918544, + 0x111e82a7, 0xddb48239, 0xd7718b20, 0x1bdb8bbe, 0x95548c5d, + 0x59fe8cc3, 0x80de9e6f, 0x4c749ef1, 0xc2fb9912, 0x0e51998c, + 0x04949095, 0xc83e900b, 0x46b197e8, 0x8a1b9776, 0x2f80b4f1, + 0xe32ab46f, 0x6da5b38c, 0xa10fb312, 0xabcaba0b, 0x6760ba95, + 0xe9efbd76, 0x2545bde8, 0xfc65af44, 0x30cfafda, 0xbe40a839, + 0x72eaa8a7, 0x782fa1be, 0xb485a120, 0x3a0aa6c3, 0xf6a0a65d, + 0xaa4de78c, 0x66e7e712, 0xe868e0f1, 0x24c2e06f, 0x2e07e976, + 0xe2ade9e8, 0x6c22ee0b, 0xa088ee95, 0x79a8fc39, 0xb502fca7, + 0x3b8dfb44, 0xf727fbda, 0xfde2f2c3, 0x3148f25d, 0xbfc7f5be, + 0x736df520, 0xd6f6d6a7, 0x1a5cd639, 0x94d3d1da, 0x5879d144, + 0x52bcd85d, 0x9e16d8c3, 0x1099df20, 0xdc33dfbe, 0x0513cd12, + 0xc9b9cd8c, 0x4736ca6f, 0x8b9ccaf1, 0x8159c3e8, 0x4df3c376, + 0xc37cc495, 0x0fd6c40b, 0x7aa64737, 0xb60c47a9, 0x3883404a, + 0xf42940d4, 0xfeec49cd, 0x32464953, 0xbcc94eb0, 0x70634e2e, + 0xa9435c82, 0x65e95c1c, 0xeb665bff, 0x27cc5b61, 0x2d095278, + 0xe1a352e6, 0x6f2c5505, 0xa386559b, 0x061d761c, 0xcab77682, + 0x44387161, 0x889271ff, 0x825778e6, 0x4efd7878, 0xc0727f9b, + 0x0cd87f05, 0xd5f86da9, 0x19526d37, 0x97dd6ad4, 0x5b776a4a, + 0x51b26353, 0x9d1863cd, 0x1397642e, 0xdf3d64b0, 0x83d02561, + 0x4f7a25ff, 0xc1f5221c, 0x0d5f2282, 0x079a2b9b, 0xcb302b05, + 0x45bf2ce6, 0x89152c78, 0x50353ed4, 0x9c9f3e4a, 0x121039a9, + 0xdeba3937, 0xd47f302e, 0x18d530b0, 0x965a3753, 0x5af037cd, + 0xff6b144a, 0x33c114d4, 0xbd4e1337, 0x71e413a9, 0x7b211ab0, + 0xb78b1a2e, 0x39041dcd, 0xf5ae1d53, 0x2c8e0fff, 0xe0240f61, + 0x6eab0882, 0xa201081c, 0xa8c40105, 0x646e019b, 0xeae10678, + 0x264b06e6}, + {0x00000000, 0xa6770bb4, 0x979f1129, 0x31e81a9d, 0xf44f2413, + 0x52382fa7, 0x63d0353a, 0xc5a73e8e, 0x33ef4e67, 0x959845d3, + 0xa4705f4e, 0x020754fa, 0xc7a06a74, 0x61d761c0, 0x503f7b5d, + 0xf64870e9, 0x67de9cce, 0xc1a9977a, 0xf0418de7, 0x56368653, + 0x9391b8dd, 0x35e6b369, 0x040ea9f4, 0xa279a240, 0x5431d2a9, + 0xf246d91d, 0xc3aec380, 0x65d9c834, 0xa07ef6ba, 0x0609fd0e, + 0x37e1e793, 0x9196ec27, 0xcfbd399c, 0x69ca3228, 0x582228b5, + 0xfe552301, 0x3bf21d8f, 0x9d85163b, 0xac6d0ca6, 0x0a1a0712, + 0xfc5277fb, 0x5a257c4f, 0x6bcd66d2, 0xcdba6d66, 0x081d53e8, + 0xae6a585c, 0x9f8242c1, 0x39f54975, 0xa863a552, 0x0e14aee6, + 0x3ffcb47b, 0x998bbfcf, 0x5c2c8141, 0xfa5b8af5, 0xcbb39068, + 0x6dc49bdc, 0x9b8ceb35, 0x3dfbe081, 0x0c13fa1c, 0xaa64f1a8, + 0x6fc3cf26, 0xc9b4c492, 0xf85cde0f, 0x5e2bd5bb, 0x440b7579, + 0xe27c7ecd, 0xd3946450, 0x75e36fe4, 0xb044516a, 0x16335ade, + 0x27db4043, 0x81ac4bf7, 0x77e43b1e, 0xd19330aa, 0xe07b2a37, + 0x460c2183, 0x83ab1f0d, 0x25dc14b9, 0x14340e24, 0xb2430590, + 0x23d5e9b7, 0x85a2e203, 0xb44af89e, 0x123df32a, 0xd79acda4, + 0x71edc610, 0x4005dc8d, 0xe672d739, 0x103aa7d0, 0xb64dac64, + 0x87a5b6f9, 0x21d2bd4d, 0xe47583c3, 0x42028877, 0x73ea92ea, + 0xd59d995e, 0x8bb64ce5, 0x2dc14751, 0x1c295dcc, 0xba5e5678, + 0x7ff968f6, 0xd98e6342, 0xe86679df, 0x4e11726b, 0xb8590282, + 0x1e2e0936, 0x2fc613ab, 0x89b1181f, 0x4c162691, 0xea612d25, + 0xdb8937b8, 0x7dfe3c0c, 0xec68d02b, 0x4a1fdb9f, 0x7bf7c102, + 0xdd80cab6, 0x1827f438, 0xbe50ff8c, 0x8fb8e511, 0x29cfeea5, + 0xdf879e4c, 0x79f095f8, 0x48188f65, 0xee6f84d1, 0x2bc8ba5f, + 0x8dbfb1eb, 0xbc57ab76, 0x1a20a0c2, 0x8816eaf2, 0x2e61e146, + 0x1f89fbdb, 0xb9fef06f, 0x7c59cee1, 0xda2ec555, 0xebc6dfc8, + 0x4db1d47c, 0xbbf9a495, 0x1d8eaf21, 0x2c66b5bc, 0x8a11be08, + 0x4fb68086, 0xe9c18b32, 0xd82991af, 0x7e5e9a1b, 0xefc8763c, + 0x49bf7d88, 0x78576715, 0xde206ca1, 0x1b87522f, 0xbdf0599b, + 0x8c184306, 0x2a6f48b2, 0xdc27385b, 0x7a5033ef, 0x4bb82972, + 0xedcf22c6, 0x28681c48, 0x8e1f17fc, 0xbff70d61, 0x198006d5, + 0x47abd36e, 0xe1dcd8da, 0xd034c247, 0x7643c9f3, 0xb3e4f77d, + 0x1593fcc9, 0x247be654, 0x820cede0, 0x74449d09, 0xd23396bd, + 0xe3db8c20, 0x45ac8794, 0x800bb91a, 0x267cb2ae, 0x1794a833, + 0xb1e3a387, 0x20754fa0, 0x86024414, 0xb7ea5e89, 0x119d553d, + 0xd43a6bb3, 0x724d6007, 0x43a57a9a, 0xe5d2712e, 0x139a01c7, + 0xb5ed0a73, 0x840510ee, 0x22721b5a, 0xe7d525d4, 0x41a22e60, + 0x704a34fd, 0xd63d3f49, 0xcc1d9f8b, 0x6a6a943f, 0x5b828ea2, + 0xfdf58516, 0x3852bb98, 0x9e25b02c, 0xafcdaab1, 0x09baa105, + 0xfff2d1ec, 0x5985da58, 0x686dc0c5, 0xce1acb71, 0x0bbdf5ff, + 0xadcafe4b, 0x9c22e4d6, 0x3a55ef62, 0xabc30345, 0x0db408f1, + 0x3c5c126c, 0x9a2b19d8, 0x5f8c2756, 0xf9fb2ce2, 0xc813367f, + 0x6e643dcb, 0x982c4d22, 0x3e5b4696, 0x0fb35c0b, 0xa9c457bf, + 0x6c636931, 0xca146285, 0xfbfc7818, 0x5d8b73ac, 0x03a0a617, + 0xa5d7ada3, 0x943fb73e, 0x3248bc8a, 0xf7ef8204, 0x519889b0, + 0x6070932d, 0xc6079899, 0x304fe870, 0x9638e3c4, 0xa7d0f959, + 0x01a7f2ed, 0xc400cc63, 0x6277c7d7, 0x539fdd4a, 0xf5e8d6fe, + 0x647e3ad9, 0xc209316d, 0xf3e12bf0, 0x55962044, 0x90311eca, + 0x3646157e, 0x07ae0fe3, 0xa1d90457, 0x579174be, 0xf1e67f0a, + 0xc00e6597, 0x66796e23, 0xa3de50ad, 0x05a95b19, 0x34414184, + 0x92364a30}, + {0x00000000, 0xcb5cd3a5, 0x4dc8a10b, 0x869472ae, 0x9b914216, + 0x50cd91b3, 0xd659e31d, 0x1d0530b8, 0xec53826d, 0x270f51c8, + 0xa19b2366, 0x6ac7f0c3, 0x77c2c07b, 0xbc9e13de, 0x3a0a6170, + 0xf156b2d5, 0x03d6029b, 0xc88ad13e, 0x4e1ea390, 0x85427035, + 0x9847408d, 0x531b9328, 0xd58fe186, 0x1ed33223, 0xef8580f6, + 0x24d95353, 0xa24d21fd, 0x6911f258, 0x7414c2e0, 0xbf481145, + 0x39dc63eb, 0xf280b04e, 0x07ac0536, 0xccf0d693, 0x4a64a43d, + 0x81387798, 0x9c3d4720, 0x57619485, 0xd1f5e62b, 0x1aa9358e, + 0xebff875b, 0x20a354fe, 0xa6372650, 0x6d6bf5f5, 0x706ec54d, + 0xbb3216e8, 0x3da66446, 0xf6fab7e3, 0x047a07ad, 0xcf26d408, + 0x49b2a6a6, 0x82ee7503, 0x9feb45bb, 0x54b7961e, 0xd223e4b0, + 0x197f3715, 0xe82985c0, 0x23755665, 0xa5e124cb, 0x6ebdf76e, + 0x73b8c7d6, 0xb8e41473, 0x3e7066dd, 0xf52cb578, 0x0f580a6c, + 0xc404d9c9, 0x4290ab67, 0x89cc78c2, 0x94c9487a, 0x5f959bdf, + 0xd901e971, 0x125d3ad4, 0xe30b8801, 0x28575ba4, 0xaec3290a, + 0x659ffaaf, 0x789aca17, 0xb3c619b2, 0x35526b1c, 0xfe0eb8b9, + 0x0c8e08f7, 0xc7d2db52, 0x4146a9fc, 0x8a1a7a59, 0x971f4ae1, + 0x5c439944, 0xdad7ebea, 0x118b384f, 0xe0dd8a9a, 0x2b81593f, + 0xad152b91, 0x6649f834, 0x7b4cc88c, 0xb0101b29, 0x36846987, + 0xfdd8ba22, 0x08f40f5a, 0xc3a8dcff, 0x453cae51, 0x8e607df4, + 0x93654d4c, 0x58399ee9, 0xdeadec47, 0x15f13fe2, 0xe4a78d37, + 0x2ffb5e92, 0xa96f2c3c, 0x6233ff99, 0x7f36cf21, 0xb46a1c84, + 0x32fe6e2a, 0xf9a2bd8f, 0x0b220dc1, 0xc07ede64, 0x46eaacca, + 0x8db67f6f, 0x90b34fd7, 0x5bef9c72, 0xdd7beedc, 0x16273d79, + 0xe7718fac, 0x2c2d5c09, 0xaab92ea7, 0x61e5fd02, 0x7ce0cdba, + 0xb7bc1e1f, 0x31286cb1, 0xfa74bf14, 0x1eb014d8, 0xd5ecc77d, + 0x5378b5d3, 0x98246676, 0x852156ce, 0x4e7d856b, 0xc8e9f7c5, + 0x03b52460, 0xf2e396b5, 0x39bf4510, 0xbf2b37be, 0x7477e41b, + 0x6972d4a3, 0xa22e0706, 0x24ba75a8, 0xefe6a60d, 0x1d661643, + 0xd63ac5e6, 0x50aeb748, 0x9bf264ed, 0x86f75455, 0x4dab87f0, + 0xcb3ff55e, 0x006326fb, 0xf135942e, 0x3a69478b, 0xbcfd3525, + 0x77a1e680, 0x6aa4d638, 0xa1f8059d, 0x276c7733, 0xec30a496, + 0x191c11ee, 0xd240c24b, 0x54d4b0e5, 0x9f886340, 0x828d53f8, + 0x49d1805d, 0xcf45f2f3, 0x04192156, 0xf54f9383, 0x3e134026, + 0xb8873288, 0x73dbe12d, 0x6eded195, 0xa5820230, 0x2316709e, + 0xe84aa33b, 0x1aca1375, 0xd196c0d0, 0x5702b27e, 0x9c5e61db, + 0x815b5163, 0x4a0782c6, 0xcc93f068, 0x07cf23cd, 0xf6999118, + 0x3dc542bd, 0xbb513013, 0x700de3b6, 0x6d08d30e, 0xa65400ab, + 0x20c07205, 0xeb9ca1a0, 0x11e81eb4, 0xdab4cd11, 0x5c20bfbf, + 0x977c6c1a, 0x8a795ca2, 0x41258f07, 0xc7b1fda9, 0x0ced2e0c, + 0xfdbb9cd9, 0x36e74f7c, 0xb0733dd2, 0x7b2fee77, 0x662adecf, + 0xad760d6a, 0x2be27fc4, 0xe0beac61, 0x123e1c2f, 0xd962cf8a, + 0x5ff6bd24, 0x94aa6e81, 0x89af5e39, 0x42f38d9c, 0xc467ff32, + 0x0f3b2c97, 0xfe6d9e42, 0x35314de7, 0xb3a53f49, 0x78f9ecec, + 0x65fcdc54, 0xaea00ff1, 0x28347d5f, 0xe368aefa, 0x16441b82, + 0xdd18c827, 0x5b8cba89, 0x90d0692c, 0x8dd55994, 0x46898a31, + 0xc01df89f, 0x0b412b3a, 0xfa1799ef, 0x314b4a4a, 0xb7df38e4, + 0x7c83eb41, 0x6186dbf9, 0xaada085c, 0x2c4e7af2, 0xe712a957, + 0x15921919, 0xdececabc, 0x585ab812, 0x93066bb7, 0x8e035b0f, + 0x455f88aa, 0xc3cbfa04, 0x089729a1, 0xf9c19b74, 0x329d48d1, + 0xb4093a7f, 0x7f55e9da, 0x6250d962, 0xa90c0ac7, 0x2f987869, + 0xe4c4abcc}, + {0x00000000, 0x3d6029b0, 0x7ac05360, 0x47a07ad0, 0xf580a6c0, + 0xc8e08f70, 0x8f40f5a0, 0xb220dc10, 0x30704bc1, 0x0d106271, + 0x4ab018a1, 0x77d03111, 0xc5f0ed01, 0xf890c4b1, 0xbf30be61, + 0x825097d1, 0x60e09782, 0x5d80be32, 0x1a20c4e2, 0x2740ed52, + 0x95603142, 0xa80018f2, 0xefa06222, 0xd2c04b92, 0x5090dc43, + 0x6df0f5f3, 0x2a508f23, 0x1730a693, 0xa5107a83, 0x98705333, + 0xdfd029e3, 0xe2b00053, 0xc1c12f04, 0xfca106b4, 0xbb017c64, + 0x866155d4, 0x344189c4, 0x0921a074, 0x4e81daa4, 0x73e1f314, + 0xf1b164c5, 0xccd14d75, 0x8b7137a5, 0xb6111e15, 0x0431c205, + 0x3951ebb5, 0x7ef19165, 0x4391b8d5, 0xa121b886, 0x9c419136, + 0xdbe1ebe6, 0xe681c256, 0x54a11e46, 0x69c137f6, 0x2e614d26, + 0x13016496, 0x9151f347, 0xac31daf7, 0xeb91a027, 0xd6f18997, + 0x64d15587, 0x59b17c37, 0x1e1106e7, 0x23712f57, 0x58f35849, + 0x659371f9, 0x22330b29, 0x1f532299, 0xad73fe89, 0x9013d739, + 0xd7b3ade9, 0xead38459, 0x68831388, 0x55e33a38, 0x124340e8, + 0x2f236958, 0x9d03b548, 0xa0639cf8, 0xe7c3e628, 0xdaa3cf98, + 0x3813cfcb, 0x0573e67b, 0x42d39cab, 0x7fb3b51b, 0xcd93690b, + 0xf0f340bb, 0xb7533a6b, 0x8a3313db, 0x0863840a, 0x3503adba, + 0x72a3d76a, 0x4fc3feda, 0xfde322ca, 0xc0830b7a, 0x872371aa, + 0xba43581a, 0x9932774d, 0xa4525efd, 0xe3f2242d, 0xde920d9d, + 0x6cb2d18d, 0x51d2f83d, 0x167282ed, 0x2b12ab5d, 0xa9423c8c, + 0x9422153c, 0xd3826fec, 0xeee2465c, 0x5cc29a4c, 0x61a2b3fc, + 0x2602c92c, 0x1b62e09c, 0xf9d2e0cf, 0xc4b2c97f, 0x8312b3af, + 0xbe729a1f, 0x0c52460f, 0x31326fbf, 0x7692156f, 0x4bf23cdf, + 0xc9a2ab0e, 0xf4c282be, 0xb362f86e, 0x8e02d1de, 0x3c220dce, + 0x0142247e, 0x46e25eae, 0x7b82771e, 0xb1e6b092, 0x8c869922, + 0xcb26e3f2, 0xf646ca42, 0x44661652, 0x79063fe2, 0x3ea64532, + 0x03c66c82, 0x8196fb53, 0xbcf6d2e3, 0xfb56a833, 0xc6368183, + 0x74165d93, 0x49767423, 0x0ed60ef3, 0x33b62743, 0xd1062710, + 0xec660ea0, 0xabc67470, 0x96a65dc0, 0x248681d0, 0x19e6a860, + 0x5e46d2b0, 0x6326fb00, 0xe1766cd1, 0xdc164561, 0x9bb63fb1, + 0xa6d61601, 0x14f6ca11, 0x2996e3a1, 0x6e369971, 0x5356b0c1, + 0x70279f96, 0x4d47b626, 0x0ae7ccf6, 0x3787e546, 0x85a73956, + 0xb8c710e6, 0xff676a36, 0xc2074386, 0x4057d457, 0x7d37fde7, + 0x3a978737, 0x07f7ae87, 0xb5d77297, 0x88b75b27, 0xcf1721f7, + 0xf2770847, 0x10c70814, 0x2da721a4, 0x6a075b74, 0x576772c4, + 0xe547aed4, 0xd8278764, 0x9f87fdb4, 0xa2e7d404, 0x20b743d5, + 0x1dd76a65, 0x5a7710b5, 0x67173905, 0xd537e515, 0xe857cca5, + 0xaff7b675, 0x92979fc5, 0xe915e8db, 0xd475c16b, 0x93d5bbbb, + 0xaeb5920b, 0x1c954e1b, 0x21f567ab, 0x66551d7b, 0x5b3534cb, + 0xd965a31a, 0xe4058aaa, 0xa3a5f07a, 0x9ec5d9ca, 0x2ce505da, + 0x11852c6a, 0x562556ba, 0x6b457f0a, 0x89f57f59, 0xb49556e9, + 0xf3352c39, 0xce550589, 0x7c75d999, 0x4115f029, 0x06b58af9, + 0x3bd5a349, 0xb9853498, 0x84e51d28, 0xc34567f8, 0xfe254e48, + 0x4c059258, 0x7165bbe8, 0x36c5c138, 0x0ba5e888, 0x28d4c7df, + 0x15b4ee6f, 0x521494bf, 0x6f74bd0f, 0xdd54611f, 0xe03448af, + 0xa794327f, 0x9af41bcf, 0x18a48c1e, 0x25c4a5ae, 0x6264df7e, + 0x5f04f6ce, 0xed242ade, 0xd044036e, 0x97e479be, 0xaa84500e, + 0x4834505d, 0x755479ed, 0x32f4033d, 0x0f942a8d, 0xbdb4f69d, + 0x80d4df2d, 0xc774a5fd, 0xfa148c4d, 0x78441b9c, 0x4524322c, + 0x028448fc, 0x3fe4614c, 0x8dc4bd5c, 0xb0a494ec, 0xf704ee3c, + 0xca64c78c}}; + +local const z_word_t FAR crc_braid_big_table[][256] = { + {0x00000000, 0xb029603d, 0x6053c07a, 0xd07aa047, 0xc0a680f5, + 0x708fe0c8, 0xa0f5408f, 0x10dc20b2, 0xc14b7030, 0x7162100d, + 0xa118b04a, 0x1131d077, 0x01edf0c5, 0xb1c490f8, 0x61be30bf, + 0xd1975082, 0x8297e060, 0x32be805d, 0xe2c4201a, 0x52ed4027, + 0x42316095, 0xf21800a8, 0x2262a0ef, 0x924bc0d2, 0x43dc9050, + 0xf3f5f06d, 0x238f502a, 0x93a63017, 0x837a10a5, 0x33537098, + 0xe329d0df, 0x5300b0e2, 0x042fc1c1, 0xb406a1fc, 0x647c01bb, + 0xd4556186, 0xc4894134, 0x74a02109, 0xa4da814e, 0x14f3e173, + 0xc564b1f1, 0x754dd1cc, 0xa537718b, 0x151e11b6, 0x05c23104, + 0xb5eb5139, 0x6591f17e, 0xd5b89143, 0x86b821a1, 0x3691419c, + 0xe6ebe1db, 0x56c281e6, 0x461ea154, 0xf637c169, 0x264d612e, + 0x96640113, 0x47f35191, 0xf7da31ac, 0x27a091eb, 0x9789f1d6, + 0x8755d164, 0x377cb159, 0xe706111e, 0x572f7123, 0x4958f358, + 0xf9719365, 0x290b3322, 0x9922531f, 0x89fe73ad, 0x39d71390, + 0xe9adb3d7, 0x5984d3ea, 0x88138368, 0x383ae355, 0xe8404312, + 0x5869232f, 0x48b5039d, 0xf89c63a0, 0x28e6c3e7, 0x98cfa3da, + 0xcbcf1338, 0x7be67305, 0xab9cd342, 0x1bb5b37f, 0x0b6993cd, + 0xbb40f3f0, 0x6b3a53b7, 0xdb13338a, 0x0a846308, 0xbaad0335, + 0x6ad7a372, 0xdafec34f, 0xca22e3fd, 0x7a0b83c0, 0xaa712387, + 0x1a5843ba, 0x4d773299, 0xfd5e52a4, 0x2d24f2e3, 0x9d0d92de, + 0x8dd1b26c, 0x3df8d251, 0xed827216, 0x5dab122b, 0x8c3c42a9, + 0x3c152294, 0xec6f82d3, 0x5c46e2ee, 0x4c9ac25c, 0xfcb3a261, + 0x2cc90226, 0x9ce0621b, 0xcfe0d2f9, 0x7fc9b2c4, 0xafb31283, + 0x1f9a72be, 0x0f46520c, 0xbf6f3231, 0x6f159276, 0xdf3cf24b, + 0x0eaba2c9, 0xbe82c2f4, 0x6ef862b3, 0xded1028e, 0xce0d223c, + 0x7e244201, 0xae5ee246, 0x1e77827b, 0x92b0e6b1, 0x2299868c, + 0xf2e326cb, 0x42ca46f6, 0x52166644, 0xe23f0679, 0x3245a63e, + 0x826cc603, 0x53fb9681, 0xe3d2f6bc, 0x33a856fb, 0x838136c6, + 0x935d1674, 0x23747649, 0xf30ed60e, 0x4327b633, 0x102706d1, + 0xa00e66ec, 0x7074c6ab, 0xc05da696, 0xd0818624, 0x60a8e619, + 0xb0d2465e, 0x00fb2663, 0xd16c76e1, 0x614516dc, 0xb13fb69b, + 0x0116d6a6, 0x11caf614, 0xa1e39629, 0x7199366e, 0xc1b05653, + 0x969f2770, 0x26b6474d, 0xf6cce70a, 0x46e58737, 0x5639a785, + 0xe610c7b8, 0x366a67ff, 0x864307c2, 0x57d45740, 0xe7fd377d, + 0x3787973a, 0x87aef707, 0x9772d7b5, 0x275bb788, 0xf72117cf, + 0x470877f2, 0x1408c710, 0xa421a72d, 0x745b076a, 0xc4726757, + 0xd4ae47e5, 0x648727d8, 0xb4fd879f, 0x04d4e7a2, 0xd543b720, + 0x656ad71d, 0xb510775a, 0x05391767, 0x15e537d5, 0xa5cc57e8, + 0x75b6f7af, 0xc59f9792, 0xdbe815e9, 0x6bc175d4, 0xbbbbd593, + 0x0b92b5ae, 0x1b4e951c, 0xab67f521, 0x7b1d5566, 0xcb34355b, + 0x1aa365d9, 0xaa8a05e4, 0x7af0a5a3, 0xcad9c59e, 0xda05e52c, + 0x6a2c8511, 0xba562556, 0x0a7f456b, 0x597ff589, 0xe95695b4, + 0x392c35f3, 0x890555ce, 0x99d9757c, 0x29f01541, 0xf98ab506, + 0x49a3d53b, 0x983485b9, 0x281de584, 0xf86745c3, 0x484e25fe, + 0x5892054c, 0xe8bb6571, 0x38c1c536, 0x88e8a50b, 0xdfc7d428, + 0x6feeb415, 0xbf941452, 0x0fbd746f, 0x1f6154dd, 0xaf4834e0, + 0x7f3294a7, 0xcf1bf49a, 0x1e8ca418, 0xaea5c425, 0x7edf6462, + 0xcef6045f, 0xde2a24ed, 0x6e0344d0, 0xbe79e497, 0x0e5084aa, + 0x5d503448, 0xed795475, 0x3d03f432, 0x8d2a940f, 0x9df6b4bd, + 0x2ddfd480, 0xfda574c7, 0x4d8c14fa, 0x9c1b4478, 0x2c322445, + 0xfc488402, 0x4c61e43f, 0x5cbdc48d, 0xec94a4b0, 0x3cee04f7, + 0x8cc764ca}, + {0x00000000, 0xa5d35ccb, 0x0ba1c84d, 0xae729486, 0x1642919b, + 0xb391cd50, 0x1de359d6, 0xb830051d, 0x6d8253ec, 0xc8510f27, + 0x66239ba1, 0xc3f0c76a, 0x7bc0c277, 0xde139ebc, 0x70610a3a, + 0xd5b256f1, 0x9b02d603, 0x3ed18ac8, 0x90a31e4e, 0x35704285, + 0x8d404798, 0x28931b53, 0x86e18fd5, 0x2332d31e, 0xf68085ef, + 0x5353d924, 0xfd214da2, 0x58f21169, 0xe0c21474, 0x451148bf, + 0xeb63dc39, 0x4eb080f2, 0x3605ac07, 0x93d6f0cc, 0x3da4644a, + 0x98773881, 0x20473d9c, 0x85946157, 0x2be6f5d1, 0x8e35a91a, + 0x5b87ffeb, 0xfe54a320, 0x502637a6, 0xf5f56b6d, 0x4dc56e70, + 0xe81632bb, 0x4664a63d, 0xe3b7faf6, 0xad077a04, 0x08d426cf, + 0xa6a6b249, 0x0375ee82, 0xbb45eb9f, 0x1e96b754, 0xb0e423d2, + 0x15377f19, 0xc08529e8, 0x65567523, 0xcb24e1a5, 0x6ef7bd6e, + 0xd6c7b873, 0x7314e4b8, 0xdd66703e, 0x78b52cf5, 0x6c0a580f, + 0xc9d904c4, 0x67ab9042, 0xc278cc89, 0x7a48c994, 0xdf9b955f, + 0x71e901d9, 0xd43a5d12, 0x01880be3, 0xa45b5728, 0x0a29c3ae, + 0xaffa9f65, 0x17ca9a78, 0xb219c6b3, 0x1c6b5235, 0xb9b80efe, + 0xf7088e0c, 0x52dbd2c7, 0xfca94641, 0x597a1a8a, 0xe14a1f97, + 0x4499435c, 0xeaebd7da, 0x4f388b11, 0x9a8adde0, 0x3f59812b, + 0x912b15ad, 0x34f84966, 0x8cc84c7b, 0x291b10b0, 0x87698436, + 0x22bad8fd, 0x5a0ff408, 0xffdca8c3, 0x51ae3c45, 0xf47d608e, + 0x4c4d6593, 0xe99e3958, 0x47ecadde, 0xe23ff115, 0x378da7e4, + 0x925efb2f, 0x3c2c6fa9, 0x99ff3362, 0x21cf367f, 0x841c6ab4, + 0x2a6efe32, 0x8fbda2f9, 0xc10d220b, 0x64de7ec0, 0xcaacea46, + 0x6f7fb68d, 0xd74fb390, 0x729cef5b, 0xdcee7bdd, 0x793d2716, + 0xac8f71e7, 0x095c2d2c, 0xa72eb9aa, 0x02fde561, 0xbacde07c, + 0x1f1ebcb7, 0xb16c2831, 0x14bf74fa, 0xd814b01e, 0x7dc7ecd5, + 0xd3b57853, 0x76662498, 0xce562185, 0x6b857d4e, 0xc5f7e9c8, + 0x6024b503, 0xb596e3f2, 0x1045bf39, 0xbe372bbf, 0x1be47774, + 0xa3d47269, 0x06072ea2, 0xa875ba24, 0x0da6e6ef, 0x4316661d, + 0xe6c53ad6, 0x48b7ae50, 0xed64f29b, 0x5554f786, 0xf087ab4d, + 0x5ef53fcb, 0xfb266300, 0x2e9435f1, 0x8b47693a, 0x2535fdbc, + 0x80e6a177, 0x38d6a46a, 0x9d05f8a1, 0x33776c27, 0x96a430ec, + 0xee111c19, 0x4bc240d2, 0xe5b0d454, 0x4063889f, 0xf8538d82, + 0x5d80d149, 0xf3f245cf, 0x56211904, 0x83934ff5, 0x2640133e, + 0x883287b8, 0x2de1db73, 0x95d1de6e, 0x300282a5, 0x9e701623, + 0x3ba34ae8, 0x7513ca1a, 0xd0c096d1, 0x7eb20257, 0xdb615e9c, + 0x63515b81, 0xc682074a, 0x68f093cc, 0xcd23cf07, 0x189199f6, + 0xbd42c53d, 0x133051bb, 0xb6e30d70, 0x0ed3086d, 0xab0054a6, + 0x0572c020, 0xa0a19ceb, 0xb41ee811, 0x11cdb4da, 0xbfbf205c, + 0x1a6c7c97, 0xa25c798a, 0x078f2541, 0xa9fdb1c7, 0x0c2eed0c, + 0xd99cbbfd, 0x7c4fe736, 0xd23d73b0, 0x77ee2f7b, 0xcfde2a66, + 0x6a0d76ad, 0xc47fe22b, 0x61acbee0, 0x2f1c3e12, 0x8acf62d9, + 0x24bdf65f, 0x816eaa94, 0x395eaf89, 0x9c8df342, 0x32ff67c4, + 0x972c3b0f, 0x429e6dfe, 0xe74d3135, 0x493fa5b3, 0xececf978, + 0x54dcfc65, 0xf10fa0ae, 0x5f7d3428, 0xfaae68e3, 0x821b4416, + 0x27c818dd, 0x89ba8c5b, 0x2c69d090, 0x9459d58d, 0x318a8946, + 0x9ff81dc0, 0x3a2b410b, 0xef9917fa, 0x4a4a4b31, 0xe438dfb7, + 0x41eb837c, 0xf9db8661, 0x5c08daaa, 0xf27a4e2c, 0x57a912e7, + 0x19199215, 0xbccacede, 0x12b85a58, 0xb76b0693, 0x0f5b038e, + 0xaa885f45, 0x04facbc3, 0xa1299708, 0x749bc1f9, 0xd1489d32, + 0x7f3a09b4, 0xdae9557f, 0x62d95062, 0xc70a0ca9, 0x6978982f, + 0xccabc4e4}, + {0x00000000, 0xb40b77a6, 0x29119f97, 0x9d1ae831, 0x13244ff4, + 0xa72f3852, 0x3a35d063, 0x8e3ea7c5, 0x674eef33, 0xd3459895, + 0x4e5f70a4, 0xfa540702, 0x746aa0c7, 0xc061d761, 0x5d7b3f50, + 0xe97048f6, 0xce9cde67, 0x7a97a9c1, 0xe78d41f0, 0x53863656, + 0xddb89193, 0x69b3e635, 0xf4a90e04, 0x40a279a2, 0xa9d23154, + 0x1dd946f2, 0x80c3aec3, 0x34c8d965, 0xbaf67ea0, 0x0efd0906, + 0x93e7e137, 0x27ec9691, 0x9c39bdcf, 0x2832ca69, 0xb5282258, + 0x012355fe, 0x8f1df23b, 0x3b16859d, 0xa60c6dac, 0x12071a0a, + 0xfb7752fc, 0x4f7c255a, 0xd266cd6b, 0x666dbacd, 0xe8531d08, + 0x5c586aae, 0xc142829f, 0x7549f539, 0x52a563a8, 0xe6ae140e, + 0x7bb4fc3f, 0xcfbf8b99, 0x41812c5c, 0xf58a5bfa, 0x6890b3cb, + 0xdc9bc46d, 0x35eb8c9b, 0x81e0fb3d, 0x1cfa130c, 0xa8f164aa, + 0x26cfc36f, 0x92c4b4c9, 0x0fde5cf8, 0xbbd52b5e, 0x79750b44, + 0xcd7e7ce2, 0x506494d3, 0xe46fe375, 0x6a5144b0, 0xde5a3316, + 0x4340db27, 0xf74bac81, 0x1e3be477, 0xaa3093d1, 0x372a7be0, + 0x83210c46, 0x0d1fab83, 0xb914dc25, 0x240e3414, 0x900543b2, + 0xb7e9d523, 0x03e2a285, 0x9ef84ab4, 0x2af33d12, 0xa4cd9ad7, + 0x10c6ed71, 0x8ddc0540, 0x39d772e6, 0xd0a73a10, 0x64ac4db6, + 0xf9b6a587, 0x4dbdd221, 0xc38375e4, 0x77880242, 0xea92ea73, + 0x5e999dd5, 0xe54cb68b, 0x5147c12d, 0xcc5d291c, 0x78565eba, + 0xf668f97f, 0x42638ed9, 0xdf7966e8, 0x6b72114e, 0x820259b8, + 0x36092e1e, 0xab13c62f, 0x1f18b189, 0x9126164c, 0x252d61ea, + 0xb83789db, 0x0c3cfe7d, 0x2bd068ec, 0x9fdb1f4a, 0x02c1f77b, + 0xb6ca80dd, 0x38f42718, 0x8cff50be, 0x11e5b88f, 0xa5eecf29, + 0x4c9e87df, 0xf895f079, 0x658f1848, 0xd1846fee, 0x5fbac82b, + 0xebb1bf8d, 0x76ab57bc, 0xc2a0201a, 0xf2ea1688, 0x46e1612e, + 0xdbfb891f, 0x6ff0feb9, 0xe1ce597c, 0x55c52eda, 0xc8dfc6eb, + 0x7cd4b14d, 0x95a4f9bb, 0x21af8e1d, 0xbcb5662c, 0x08be118a, + 0x8680b64f, 0x328bc1e9, 0xaf9129d8, 0x1b9a5e7e, 0x3c76c8ef, + 0x887dbf49, 0x15675778, 0xa16c20de, 0x2f52871b, 0x9b59f0bd, + 0x0643188c, 0xb2486f2a, 0x5b3827dc, 0xef33507a, 0x7229b84b, + 0xc622cfed, 0x481c6828, 0xfc171f8e, 0x610df7bf, 0xd5068019, + 0x6ed3ab47, 0xdad8dce1, 0x47c234d0, 0xf3c94376, 0x7df7e4b3, + 0xc9fc9315, 0x54e67b24, 0xe0ed0c82, 0x099d4474, 0xbd9633d2, + 0x208cdbe3, 0x9487ac45, 0x1ab90b80, 0xaeb27c26, 0x33a89417, + 0x87a3e3b1, 0xa04f7520, 0x14440286, 0x895eeab7, 0x3d559d11, + 0xb36b3ad4, 0x07604d72, 0x9a7aa543, 0x2e71d2e5, 0xc7019a13, + 0x730aedb5, 0xee100584, 0x5a1b7222, 0xd425d5e7, 0x602ea241, + 0xfd344a70, 0x493f3dd6, 0x8b9f1dcc, 0x3f946a6a, 0xa28e825b, + 0x1685f5fd, 0x98bb5238, 0x2cb0259e, 0xb1aacdaf, 0x05a1ba09, + 0xecd1f2ff, 0x58da8559, 0xc5c06d68, 0x71cb1ace, 0xfff5bd0b, + 0x4bfecaad, 0xd6e4229c, 0x62ef553a, 0x4503c3ab, 0xf108b40d, + 0x6c125c3c, 0xd8192b9a, 0x56278c5f, 0xe22cfbf9, 0x7f3613c8, + 0xcb3d646e, 0x224d2c98, 0x96465b3e, 0x0b5cb30f, 0xbf57c4a9, + 0x3169636c, 0x856214ca, 0x1878fcfb, 0xac738b5d, 0x17a6a003, + 0xa3add7a5, 0x3eb73f94, 0x8abc4832, 0x0482eff7, 0xb0899851, + 0x2d937060, 0x999807c6, 0x70e84f30, 0xc4e33896, 0x59f9d0a7, + 0xedf2a701, 0x63cc00c4, 0xd7c77762, 0x4add9f53, 0xfed6e8f5, + 0xd93a7e64, 0x6d3109c2, 0xf02be1f3, 0x44209655, 0xca1e3190, + 0x7e154636, 0xe30fae07, 0x5704d9a1, 0xbe749157, 0x0a7fe6f1, + 0x97650ec0, 0x236e7966, 0xad50dea3, 0x195ba905, 0x84414134, + 0x304a3692}, + {0x00000000, 0x9e00aacc, 0x7d072542, 0xe3078f8e, 0xfa0e4a84, + 0x640ee048, 0x87096fc6, 0x1909c50a, 0xb51be5d3, 0x2b1b4f1f, + 0xc81cc091, 0x561c6a5d, 0x4f15af57, 0xd115059b, 0x32128a15, + 0xac1220d9, 0x2b31bb7c, 0xb53111b0, 0x56369e3e, 0xc83634f2, + 0xd13ff1f8, 0x4f3f5b34, 0xac38d4ba, 0x32387e76, 0x9e2a5eaf, + 0x002af463, 0xe32d7bed, 0x7d2dd121, 0x6424142b, 0xfa24bee7, + 0x19233169, 0x87239ba5, 0x566276f9, 0xc862dc35, 0x2b6553bb, + 0xb565f977, 0xac6c3c7d, 0x326c96b1, 0xd16b193f, 0x4f6bb3f3, + 0xe379932a, 0x7d7939e6, 0x9e7eb668, 0x007e1ca4, 0x1977d9ae, + 0x87777362, 0x6470fcec, 0xfa705620, 0x7d53cd85, 0xe3536749, + 0x0054e8c7, 0x9e54420b, 0x875d8701, 0x195d2dcd, 0xfa5aa243, + 0x645a088f, 0xc8482856, 0x5648829a, 0xb54f0d14, 0x2b4fa7d8, + 0x324662d2, 0xac46c81e, 0x4f414790, 0xd141ed5c, 0xedc29d29, + 0x73c237e5, 0x90c5b86b, 0x0ec512a7, 0x17ccd7ad, 0x89cc7d61, + 0x6acbf2ef, 0xf4cb5823, 0x58d978fa, 0xc6d9d236, 0x25de5db8, + 0xbbdef774, 0xa2d7327e, 0x3cd798b2, 0xdfd0173c, 0x41d0bdf0, + 0xc6f32655, 0x58f38c99, 0xbbf40317, 0x25f4a9db, 0x3cfd6cd1, + 0xa2fdc61d, 0x41fa4993, 0xdffae35f, 0x73e8c386, 0xede8694a, + 0x0eefe6c4, 0x90ef4c08, 0x89e68902, 0x17e623ce, 0xf4e1ac40, + 0x6ae1068c, 0xbba0ebd0, 0x25a0411c, 0xc6a7ce92, 0x58a7645e, + 0x41aea154, 0xdfae0b98, 0x3ca98416, 0xa2a92eda, 0x0ebb0e03, + 0x90bba4cf, 0x73bc2b41, 0xedbc818d, 0xf4b54487, 0x6ab5ee4b, + 0x89b261c5, 0x17b2cb09, 0x909150ac, 0x0e91fa60, 0xed9675ee, + 0x7396df22, 0x6a9f1a28, 0xf49fb0e4, 0x17983f6a, 0x899895a6, + 0x258ab57f, 0xbb8a1fb3, 0x588d903d, 0xc68d3af1, 0xdf84fffb, + 0x41845537, 0xa283dab9, 0x3c837075, 0xda853b53, 0x4485919f, + 0xa7821e11, 0x3982b4dd, 0x208b71d7, 0xbe8bdb1b, 0x5d8c5495, + 0xc38cfe59, 0x6f9ede80, 0xf19e744c, 0x1299fbc2, 0x8c99510e, + 0x95909404, 0x0b903ec8, 0xe897b146, 0x76971b8a, 0xf1b4802f, + 0x6fb42ae3, 0x8cb3a56d, 0x12b30fa1, 0x0bbacaab, 0x95ba6067, + 0x76bdefe9, 0xe8bd4525, 0x44af65fc, 0xdaafcf30, 0x39a840be, + 0xa7a8ea72, 0xbea12f78, 0x20a185b4, 0xc3a60a3a, 0x5da6a0f6, + 0x8ce74daa, 0x12e7e766, 0xf1e068e8, 0x6fe0c224, 0x76e9072e, + 0xe8e9ade2, 0x0bee226c, 0x95ee88a0, 0x39fca879, 0xa7fc02b5, + 0x44fb8d3b, 0xdafb27f7, 0xc3f2e2fd, 0x5df24831, 0xbef5c7bf, + 0x20f56d73, 0xa7d6f6d6, 0x39d65c1a, 0xdad1d394, 0x44d17958, + 0x5dd8bc52, 0xc3d8169e, 0x20df9910, 0xbedf33dc, 0x12cd1305, + 0x8ccdb9c9, 0x6fca3647, 0xf1ca9c8b, 0xe8c35981, 0x76c3f34d, + 0x95c47cc3, 0x0bc4d60f, 0x3747a67a, 0xa9470cb6, 0x4a408338, + 0xd44029f4, 0xcd49ecfe, 0x53494632, 0xb04ec9bc, 0x2e4e6370, + 0x825c43a9, 0x1c5ce965, 0xff5b66eb, 0x615bcc27, 0x7852092d, + 0xe652a3e1, 0x05552c6f, 0x9b5586a3, 0x1c761d06, 0x8276b7ca, + 0x61713844, 0xff719288, 0xe6785782, 0x7878fd4e, 0x9b7f72c0, + 0x057fd80c, 0xa96df8d5, 0x376d5219, 0xd46add97, 0x4a6a775b, + 0x5363b251, 0xcd63189d, 0x2e649713, 0xb0643ddf, 0x6125d083, + 0xff257a4f, 0x1c22f5c1, 0x82225f0d, 0x9b2b9a07, 0x052b30cb, + 0xe62cbf45, 0x782c1589, 0xd43e3550, 0x4a3e9f9c, 0xa9391012, + 0x3739bade, 0x2e307fd4, 0xb030d518, 0x53375a96, 0xcd37f05a, + 0x4a146bff, 0xd414c133, 0x37134ebd, 0xa913e471, 0xb01a217b, + 0x2e1a8bb7, 0xcd1d0439, 0x531daef5, 0xff0f8e2c, 0x610f24e0, + 0x8208ab6e, 0x1c0801a2, 0x0501c4a8, 0x9b016e64, 0x7806e1ea, + 0xe6064b26}}; + +#endif + +#endif + +#if N == 3 + +#if W == 8 + +local const z_crc_t FAR crc_braid_table[][256] = { + {0x00000000, 0x81256527, 0xd93bcc0f, 0x581ea928, 0x69069e5f, + 0xe823fb78, 0xb03d5250, 0x31183777, 0xd20d3cbe, 0x53285999, + 0x0b36f0b1, 0x8a139596, 0xbb0ba2e1, 0x3a2ec7c6, 0x62306eee, + 0xe3150bc9, 0x7f6b7f3d, 0xfe4e1a1a, 0xa650b332, 0x2775d615, + 0x166de162, 0x97488445, 0xcf562d6d, 0x4e73484a, 0xad664383, + 0x2c4326a4, 0x745d8f8c, 0xf578eaab, 0xc460dddc, 0x4545b8fb, + 0x1d5b11d3, 0x9c7e74f4, 0xfed6fe7a, 0x7ff39b5d, 0x27ed3275, + 0xa6c85752, 0x97d06025, 0x16f50502, 0x4eebac2a, 0xcfcec90d, + 0x2cdbc2c4, 0xadfea7e3, 0xf5e00ecb, 0x74c56bec, 0x45dd5c9b, + 0xc4f839bc, 0x9ce69094, 0x1dc3f5b3, 0x81bd8147, 0x0098e460, + 0x58864d48, 0xd9a3286f, 0xe8bb1f18, 0x699e7a3f, 0x3180d317, + 0xb0a5b630, 0x53b0bdf9, 0xd295d8de, 0x8a8b71f6, 0x0bae14d1, + 0x3ab623a6, 0xbb934681, 0xe38defa9, 0x62a88a8e, 0x26dcfab5, + 0xa7f99f92, 0xffe736ba, 0x7ec2539d, 0x4fda64ea, 0xceff01cd, + 0x96e1a8e5, 0x17c4cdc2, 0xf4d1c60b, 0x75f4a32c, 0x2dea0a04, + 0xaccf6f23, 0x9dd75854, 0x1cf23d73, 0x44ec945b, 0xc5c9f17c, + 0x59b78588, 0xd892e0af, 0x808c4987, 0x01a92ca0, 0x30b11bd7, + 0xb1947ef0, 0xe98ad7d8, 0x68afb2ff, 0x8bbab936, 0x0a9fdc11, + 0x52817539, 0xd3a4101e, 0xe2bc2769, 0x6399424e, 0x3b87eb66, + 0xbaa28e41, 0xd80a04cf, 0x592f61e8, 0x0131c8c0, 0x8014ade7, + 0xb10c9a90, 0x3029ffb7, 0x6837569f, 0xe91233b8, 0x0a073871, + 0x8b225d56, 0xd33cf47e, 0x52199159, 0x6301a62e, 0xe224c309, + 0xba3a6a21, 0x3b1f0f06, 0xa7617bf2, 0x26441ed5, 0x7e5ab7fd, + 0xff7fd2da, 0xce67e5ad, 0x4f42808a, 0x175c29a2, 0x96794c85, + 0x756c474c, 0xf449226b, 0xac578b43, 0x2d72ee64, 0x1c6ad913, + 0x9d4fbc34, 0xc551151c, 0x4474703b, 0x4db9f56a, 0xcc9c904d, + 0x94823965, 0x15a75c42, 0x24bf6b35, 0xa59a0e12, 0xfd84a73a, + 0x7ca1c21d, 0x9fb4c9d4, 0x1e91acf3, 0x468f05db, 0xc7aa60fc, + 0xf6b2578b, 0x779732ac, 0x2f899b84, 0xaeacfea3, 0x32d28a57, + 0xb3f7ef70, 0xebe94658, 0x6acc237f, 0x5bd41408, 0xdaf1712f, + 0x82efd807, 0x03cabd20, 0xe0dfb6e9, 0x61fad3ce, 0x39e47ae6, + 0xb8c11fc1, 0x89d928b6, 0x08fc4d91, 0x50e2e4b9, 0xd1c7819e, + 0xb36f0b10, 0x324a6e37, 0x6a54c71f, 0xeb71a238, 0xda69954f, + 0x5b4cf068, 0x03525940, 0x82773c67, 0x616237ae, 0xe0475289, + 0xb859fba1, 0x397c9e86, 0x0864a9f1, 0x8941ccd6, 0xd15f65fe, + 0x507a00d9, 0xcc04742d, 0x4d21110a, 0x153fb822, 0x941add05, + 0xa502ea72, 0x24278f55, 0x7c39267d, 0xfd1c435a, 0x1e094893, + 0x9f2c2db4, 0xc732849c, 0x4617e1bb, 0x770fd6cc, 0xf62ab3eb, + 0xae341ac3, 0x2f117fe4, 0x6b650fdf, 0xea406af8, 0xb25ec3d0, + 0x337ba6f7, 0x02639180, 0x8346f4a7, 0xdb585d8f, 0x5a7d38a8, + 0xb9683361, 0x384d5646, 0x6053ff6e, 0xe1769a49, 0xd06ead3e, + 0x514bc819, 0x09556131, 0x88700416, 0x140e70e2, 0x952b15c5, + 0xcd35bced, 0x4c10d9ca, 0x7d08eebd, 0xfc2d8b9a, 0xa43322b2, + 0x25164795, 0xc6034c5c, 0x4726297b, 0x1f388053, 0x9e1de574, + 0xaf05d203, 0x2e20b724, 0x763e1e0c, 0xf71b7b2b, 0x95b3f1a5, + 0x14969482, 0x4c883daa, 0xcdad588d, 0xfcb56ffa, 0x7d900add, + 0x258ea3f5, 0xa4abc6d2, 0x47becd1b, 0xc69ba83c, 0x9e850114, + 0x1fa06433, 0x2eb85344, 0xaf9d3663, 0xf7839f4b, 0x76a6fa6c, + 0xead88e98, 0x6bfdebbf, 0x33e34297, 0xb2c627b0, 0x83de10c7, + 0x02fb75e0, 0x5ae5dcc8, 0xdbc0b9ef, 0x38d5b226, 0xb9f0d701, + 0xe1ee7e29, 0x60cb1b0e, 0x51d32c79, 0xd0f6495e, 0x88e8e076, + 0x09cd8551}, + {0x00000000, 0x9b73ead4, 0xed96d3e9, 0x76e5393d, 0x005ca193, + 0x9b2f4b47, 0xedca727a, 0x76b998ae, 0x00b94326, 0x9bcaa9f2, + 0xed2f90cf, 0x765c7a1b, 0x00e5e2b5, 0x9b960861, 0xed73315c, + 0x7600db88, 0x0172864c, 0x9a016c98, 0xece455a5, 0x7797bf71, + 0x012e27df, 0x9a5dcd0b, 0xecb8f436, 0x77cb1ee2, 0x01cbc56a, + 0x9ab82fbe, 0xec5d1683, 0x772efc57, 0x019764f9, 0x9ae48e2d, + 0xec01b710, 0x77725dc4, 0x02e50c98, 0x9996e64c, 0xef73df71, + 0x740035a5, 0x02b9ad0b, 0x99ca47df, 0xef2f7ee2, 0x745c9436, + 0x025c4fbe, 0x992fa56a, 0xefca9c57, 0x74b97683, 0x0200ee2d, + 0x997304f9, 0xef963dc4, 0x74e5d710, 0x03978ad4, 0x98e46000, + 0xee01593d, 0x7572b3e9, 0x03cb2b47, 0x98b8c193, 0xee5df8ae, + 0x752e127a, 0x032ec9f2, 0x985d2326, 0xeeb81a1b, 0x75cbf0cf, + 0x03726861, 0x980182b5, 0xeee4bb88, 0x7597515c, 0x05ca1930, + 0x9eb9f3e4, 0xe85ccad9, 0x732f200d, 0x0596b8a3, 0x9ee55277, + 0xe8006b4a, 0x7373819e, 0x05735a16, 0x9e00b0c2, 0xe8e589ff, + 0x7396632b, 0x052ffb85, 0x9e5c1151, 0xe8b9286c, 0x73cac2b8, + 0x04b89f7c, 0x9fcb75a8, 0xe92e4c95, 0x725da641, 0x04e43eef, + 0x9f97d43b, 0xe972ed06, 0x720107d2, 0x0401dc5a, 0x9f72368e, + 0xe9970fb3, 0x72e4e567, 0x045d7dc9, 0x9f2e971d, 0xe9cbae20, + 0x72b844f4, 0x072f15a8, 0x9c5cff7c, 0xeab9c641, 0x71ca2c95, + 0x0773b43b, 0x9c005eef, 0xeae567d2, 0x71968d06, 0x0796568e, + 0x9ce5bc5a, 0xea008567, 0x71736fb3, 0x07caf71d, 0x9cb91dc9, + 0xea5c24f4, 0x712fce20, 0x065d93e4, 0x9d2e7930, 0xebcb400d, + 0x70b8aad9, 0x06013277, 0x9d72d8a3, 0xeb97e19e, 0x70e40b4a, + 0x06e4d0c2, 0x9d973a16, 0xeb72032b, 0x7001e9ff, 0x06b87151, + 0x9dcb9b85, 0xeb2ea2b8, 0x705d486c, 0x0b943260, 0x90e7d8b4, + 0xe602e189, 0x7d710b5d, 0x0bc893f3, 0x90bb7927, 0xe65e401a, + 0x7d2daace, 0x0b2d7146, 0x905e9b92, 0xe6bba2af, 0x7dc8487b, + 0x0b71d0d5, 0x90023a01, 0xe6e7033c, 0x7d94e9e8, 0x0ae6b42c, + 0x91955ef8, 0xe77067c5, 0x7c038d11, 0x0aba15bf, 0x91c9ff6b, + 0xe72cc656, 0x7c5f2c82, 0x0a5ff70a, 0x912c1dde, 0xe7c924e3, + 0x7cbace37, 0x0a035699, 0x9170bc4d, 0xe7958570, 0x7ce66fa4, + 0x09713ef8, 0x9202d42c, 0xe4e7ed11, 0x7f9407c5, 0x092d9f6b, + 0x925e75bf, 0xe4bb4c82, 0x7fc8a656, 0x09c87dde, 0x92bb970a, + 0xe45eae37, 0x7f2d44e3, 0x0994dc4d, 0x92e73699, 0xe4020fa4, + 0x7f71e570, 0x0803b8b4, 0x93705260, 0xe5956b5d, 0x7ee68189, + 0x085f1927, 0x932cf3f3, 0xe5c9cace, 0x7eba201a, 0x08bafb92, + 0x93c91146, 0xe52c287b, 0x7e5fc2af, 0x08e65a01, 0x9395b0d5, + 0xe57089e8, 0x7e03633c, 0x0e5e2b50, 0x952dc184, 0xe3c8f8b9, + 0x78bb126d, 0x0e028ac3, 0x95716017, 0xe394592a, 0x78e7b3fe, + 0x0ee76876, 0x959482a2, 0xe371bb9f, 0x7802514b, 0x0ebbc9e5, + 0x95c82331, 0xe32d1a0c, 0x785ef0d8, 0x0f2cad1c, 0x945f47c8, + 0xe2ba7ef5, 0x79c99421, 0x0f700c8f, 0x9403e65b, 0xe2e6df66, + 0x799535b2, 0x0f95ee3a, 0x94e604ee, 0xe2033dd3, 0x7970d707, + 0x0fc94fa9, 0x94baa57d, 0xe25f9c40, 0x792c7694, 0x0cbb27c8, + 0x97c8cd1c, 0xe12df421, 0x7a5e1ef5, 0x0ce7865b, 0x97946c8f, + 0xe17155b2, 0x7a02bf66, 0x0c0264ee, 0x97718e3a, 0xe194b707, + 0x7ae75dd3, 0x0c5ec57d, 0x972d2fa9, 0xe1c81694, 0x7abbfc40, + 0x0dc9a184, 0x96ba4b50, 0xe05f726d, 0x7b2c98b9, 0x0d950017, + 0x96e6eac3, 0xe003d3fe, 0x7b70392a, 0x0d70e2a2, 0x96030876, + 0xe0e6314b, 0x7b95db9f, 0x0d2c4331, 0x965fa9e5, 0xe0ba90d8, + 0x7bc97a0c}, + {0x00000000, 0x172864c0, 0x2e50c980, 0x3978ad40, 0x5ca19300, + 0x4b89f7c0, 0x72f15a80, 0x65d93e40, 0xb9432600, 0xae6b42c0, + 0x9713ef80, 0x803b8b40, 0xe5e2b500, 0xf2cad1c0, 0xcbb27c80, + 0xdc9a1840, 0xa9f74a41, 0xbedf2e81, 0x87a783c1, 0x908fe701, + 0xf556d941, 0xe27ebd81, 0xdb0610c1, 0xcc2e7401, 0x10b46c41, + 0x079c0881, 0x3ee4a5c1, 0x29ccc101, 0x4c15ff41, 0x5b3d9b81, + 0x624536c1, 0x756d5201, 0x889f92c3, 0x9fb7f603, 0xa6cf5b43, + 0xb1e73f83, 0xd43e01c3, 0xc3166503, 0xfa6ec843, 0xed46ac83, + 0x31dcb4c3, 0x26f4d003, 0x1f8c7d43, 0x08a41983, 0x6d7d27c3, + 0x7a554303, 0x432dee43, 0x54058a83, 0x2168d882, 0x3640bc42, + 0x0f381102, 0x181075c2, 0x7dc94b82, 0x6ae12f42, 0x53998202, + 0x44b1e6c2, 0x982bfe82, 0x8f039a42, 0xb67b3702, 0xa15353c2, + 0xc48a6d82, 0xd3a20942, 0xeadaa402, 0xfdf2c0c2, 0xca4e23c7, + 0xdd664707, 0xe41eea47, 0xf3368e87, 0x96efb0c7, 0x81c7d407, + 0xb8bf7947, 0xaf971d87, 0x730d05c7, 0x64256107, 0x5d5dcc47, + 0x4a75a887, 0x2fac96c7, 0x3884f207, 0x01fc5f47, 0x16d43b87, + 0x63b96986, 0x74910d46, 0x4de9a006, 0x5ac1c4c6, 0x3f18fa86, + 0x28309e46, 0x11483306, 0x066057c6, 0xdafa4f86, 0xcdd22b46, + 0xf4aa8606, 0xe382e2c6, 0x865bdc86, 0x9173b846, 0xa80b1506, + 0xbf2371c6, 0x42d1b104, 0x55f9d5c4, 0x6c817884, 0x7ba91c44, + 0x1e702204, 0x095846c4, 0x3020eb84, 0x27088f44, 0xfb929704, + 0xecbaf3c4, 0xd5c25e84, 0xc2ea3a44, 0xa7330404, 0xb01b60c4, + 0x8963cd84, 0x9e4ba944, 0xeb26fb45, 0xfc0e9f85, 0xc57632c5, + 0xd25e5605, 0xb7876845, 0xa0af0c85, 0x99d7a1c5, 0x8effc505, + 0x5265dd45, 0x454db985, 0x7c3514c5, 0x6b1d7005, 0x0ec44e45, + 0x19ec2a85, 0x209487c5, 0x37bce305, 0x4fed41cf, 0x58c5250f, + 0x61bd884f, 0x7695ec8f, 0x134cd2cf, 0x0464b60f, 0x3d1c1b4f, + 0x2a347f8f, 0xf6ae67cf, 0xe186030f, 0xd8feae4f, 0xcfd6ca8f, + 0xaa0ff4cf, 0xbd27900f, 0x845f3d4f, 0x9377598f, 0xe61a0b8e, + 0xf1326f4e, 0xc84ac20e, 0xdf62a6ce, 0xbabb988e, 0xad93fc4e, + 0x94eb510e, 0x83c335ce, 0x5f592d8e, 0x4871494e, 0x7109e40e, + 0x662180ce, 0x03f8be8e, 0x14d0da4e, 0x2da8770e, 0x3a8013ce, + 0xc772d30c, 0xd05ab7cc, 0xe9221a8c, 0xfe0a7e4c, 0x9bd3400c, + 0x8cfb24cc, 0xb583898c, 0xa2abed4c, 0x7e31f50c, 0x691991cc, + 0x50613c8c, 0x4749584c, 0x2290660c, 0x35b802cc, 0x0cc0af8c, + 0x1be8cb4c, 0x6e85994d, 0x79adfd8d, 0x40d550cd, 0x57fd340d, + 0x32240a4d, 0x250c6e8d, 0x1c74c3cd, 0x0b5ca70d, 0xd7c6bf4d, + 0xc0eedb8d, 0xf99676cd, 0xeebe120d, 0x8b672c4d, 0x9c4f488d, + 0xa537e5cd, 0xb21f810d, 0x85a36208, 0x928b06c8, 0xabf3ab88, + 0xbcdbcf48, 0xd902f108, 0xce2a95c8, 0xf7523888, 0xe07a5c48, + 0x3ce04408, 0x2bc820c8, 0x12b08d88, 0x0598e948, 0x6041d708, + 0x7769b3c8, 0x4e111e88, 0x59397a48, 0x2c542849, 0x3b7c4c89, + 0x0204e1c9, 0x152c8509, 0x70f5bb49, 0x67dddf89, 0x5ea572c9, + 0x498d1609, 0x95170e49, 0x823f6a89, 0xbb47c7c9, 0xac6fa309, + 0xc9b69d49, 0xde9ef989, 0xe7e654c9, 0xf0ce3009, 0x0d3cf0cb, + 0x1a14940b, 0x236c394b, 0x34445d8b, 0x519d63cb, 0x46b5070b, + 0x7fcdaa4b, 0x68e5ce8b, 0xb47fd6cb, 0xa357b20b, 0x9a2f1f4b, + 0x8d077b8b, 0xe8de45cb, 0xfff6210b, 0xc68e8c4b, 0xd1a6e88b, + 0xa4cbba8a, 0xb3e3de4a, 0x8a9b730a, 0x9db317ca, 0xf86a298a, + 0xef424d4a, 0xd63ae00a, 0xc11284ca, 0x1d889c8a, 0x0aa0f84a, + 0x33d8550a, 0x24f031ca, 0x41290f8a, 0x56016b4a, 0x6f79c60a, + 0x7851a2ca}, + {0x00000000, 0x9fda839e, 0xe4c4017d, 0x7b1e82e3, 0x12f904bb, + 0x8d238725, 0xf63d05c6, 0x69e78658, 0x25f20976, 0xba288ae8, + 0xc136080b, 0x5eec8b95, 0x370b0dcd, 0xa8d18e53, 0xd3cf0cb0, + 0x4c158f2e, 0x4be412ec, 0xd43e9172, 0xaf201391, 0x30fa900f, + 0x591d1657, 0xc6c795c9, 0xbdd9172a, 0x220394b4, 0x6e161b9a, + 0xf1cc9804, 0x8ad21ae7, 0x15089979, 0x7cef1f21, 0xe3359cbf, + 0x982b1e5c, 0x07f19dc2, 0x97c825d8, 0x0812a646, 0x730c24a5, + 0xecd6a73b, 0x85312163, 0x1aeba2fd, 0x61f5201e, 0xfe2fa380, + 0xb23a2cae, 0x2de0af30, 0x56fe2dd3, 0xc924ae4d, 0xa0c32815, + 0x3f19ab8b, 0x44072968, 0xdbddaaf6, 0xdc2c3734, 0x43f6b4aa, + 0x38e83649, 0xa732b5d7, 0xced5338f, 0x510fb011, 0x2a1132f2, + 0xb5cbb16c, 0xf9de3e42, 0x6604bddc, 0x1d1a3f3f, 0x82c0bca1, + 0xeb273af9, 0x74fdb967, 0x0fe33b84, 0x9039b81a, 0xf4e14df1, + 0x6b3bce6f, 0x10254c8c, 0x8fffcf12, 0xe618494a, 0x79c2cad4, + 0x02dc4837, 0x9d06cba9, 0xd1134487, 0x4ec9c719, 0x35d745fa, + 0xaa0dc664, 0xc3ea403c, 0x5c30c3a2, 0x272e4141, 0xb8f4c2df, + 0xbf055f1d, 0x20dfdc83, 0x5bc15e60, 0xc41bddfe, 0xadfc5ba6, + 0x3226d838, 0x49385adb, 0xd6e2d945, 0x9af7566b, 0x052dd5f5, + 0x7e335716, 0xe1e9d488, 0x880e52d0, 0x17d4d14e, 0x6cca53ad, + 0xf310d033, 0x63296829, 0xfcf3ebb7, 0x87ed6954, 0x1837eaca, + 0x71d06c92, 0xee0aef0c, 0x95146def, 0x0aceee71, 0x46db615f, + 0xd901e2c1, 0xa21f6022, 0x3dc5e3bc, 0x542265e4, 0xcbf8e67a, + 0xb0e66499, 0x2f3ce707, 0x28cd7ac5, 0xb717f95b, 0xcc097bb8, + 0x53d3f826, 0x3a347e7e, 0xa5eefde0, 0xdef07f03, 0x412afc9d, + 0x0d3f73b3, 0x92e5f02d, 0xe9fb72ce, 0x7621f150, 0x1fc67708, + 0x801cf496, 0xfb027675, 0x64d8f5eb, 0x32b39da3, 0xad691e3d, + 0xd6779cde, 0x49ad1f40, 0x204a9918, 0xbf901a86, 0xc48e9865, + 0x5b541bfb, 0x174194d5, 0x889b174b, 0xf38595a8, 0x6c5f1636, + 0x05b8906e, 0x9a6213f0, 0xe17c9113, 0x7ea6128d, 0x79578f4f, + 0xe68d0cd1, 0x9d938e32, 0x02490dac, 0x6bae8bf4, 0xf474086a, + 0x8f6a8a89, 0x10b00917, 0x5ca58639, 0xc37f05a7, 0xb8618744, + 0x27bb04da, 0x4e5c8282, 0xd186011c, 0xaa9883ff, 0x35420061, + 0xa57bb87b, 0x3aa13be5, 0x41bfb906, 0xde653a98, 0xb782bcc0, + 0x28583f5e, 0x5346bdbd, 0xcc9c3e23, 0x8089b10d, 0x1f533293, + 0x644db070, 0xfb9733ee, 0x9270b5b6, 0x0daa3628, 0x76b4b4cb, + 0xe96e3755, 0xee9faa97, 0x71452909, 0x0a5babea, 0x95812874, + 0xfc66ae2c, 0x63bc2db2, 0x18a2af51, 0x87782ccf, 0xcb6da3e1, + 0x54b7207f, 0x2fa9a29c, 0xb0732102, 0xd994a75a, 0x464e24c4, + 0x3d50a627, 0xa28a25b9, 0xc652d052, 0x598853cc, 0x2296d12f, + 0xbd4c52b1, 0xd4abd4e9, 0x4b715777, 0x306fd594, 0xafb5560a, + 0xe3a0d924, 0x7c7a5aba, 0x0764d859, 0x98be5bc7, 0xf159dd9f, + 0x6e835e01, 0x159ddce2, 0x8a475f7c, 0x8db6c2be, 0x126c4120, + 0x6972c3c3, 0xf6a8405d, 0x9f4fc605, 0x0095459b, 0x7b8bc778, + 0xe45144e6, 0xa844cbc8, 0x379e4856, 0x4c80cab5, 0xd35a492b, + 0xbabdcf73, 0x25674ced, 0x5e79ce0e, 0xc1a34d90, 0x519af58a, + 0xce407614, 0xb55ef4f7, 0x2a847769, 0x4363f131, 0xdcb972af, + 0xa7a7f04c, 0x387d73d2, 0x7468fcfc, 0xebb27f62, 0x90acfd81, + 0x0f767e1f, 0x6691f847, 0xf94b7bd9, 0x8255f93a, 0x1d8f7aa4, + 0x1a7ee766, 0x85a464f8, 0xfebae61b, 0x61606585, 0x0887e3dd, + 0x975d6043, 0xec43e2a0, 0x7399613e, 0x3f8cee10, 0xa0566d8e, + 0xdb48ef6d, 0x44926cf3, 0x2d75eaab, 0xb2af6935, 0xc9b1ebd6, + 0x566b6848}, + {0x00000000, 0x65673b46, 0xcace768c, 0xafa94dca, 0x4eedeb59, + 0x2b8ad01f, 0x84239dd5, 0xe144a693, 0x9ddbd6b2, 0xf8bcedf4, + 0x5715a03e, 0x32729b78, 0xd3363deb, 0xb65106ad, 0x19f84b67, + 0x7c9f7021, 0xe0c6ab25, 0x85a19063, 0x2a08dda9, 0x4f6fe6ef, + 0xae2b407c, 0xcb4c7b3a, 0x64e536f0, 0x01820db6, 0x7d1d7d97, + 0x187a46d1, 0xb7d30b1b, 0xd2b4305d, 0x33f096ce, 0x5697ad88, + 0xf93ee042, 0x9c59db04, 0x1afc500b, 0x7f9b6b4d, 0xd0322687, + 0xb5551dc1, 0x5411bb52, 0x31768014, 0x9edfcdde, 0xfbb8f698, + 0x872786b9, 0xe240bdff, 0x4de9f035, 0x288ecb73, 0xc9ca6de0, + 0xacad56a6, 0x03041b6c, 0x6663202a, 0xfa3afb2e, 0x9f5dc068, + 0x30f48da2, 0x5593b6e4, 0xb4d71077, 0xd1b02b31, 0x7e1966fb, + 0x1b7e5dbd, 0x67e12d9c, 0x028616da, 0xad2f5b10, 0xc8486056, + 0x290cc6c5, 0x4c6bfd83, 0xe3c2b049, 0x86a58b0f, 0x35f8a016, + 0x509f9b50, 0xff36d69a, 0x9a51eddc, 0x7b154b4f, 0x1e727009, + 0xb1db3dc3, 0xd4bc0685, 0xa82376a4, 0xcd444de2, 0x62ed0028, + 0x078a3b6e, 0xe6ce9dfd, 0x83a9a6bb, 0x2c00eb71, 0x4967d037, + 0xd53e0b33, 0xb0593075, 0x1ff07dbf, 0x7a9746f9, 0x9bd3e06a, + 0xfeb4db2c, 0x511d96e6, 0x347aada0, 0x48e5dd81, 0x2d82e6c7, + 0x822bab0d, 0xe74c904b, 0x060836d8, 0x636f0d9e, 0xccc64054, + 0xa9a17b12, 0x2f04f01d, 0x4a63cb5b, 0xe5ca8691, 0x80adbdd7, + 0x61e91b44, 0x048e2002, 0xab276dc8, 0xce40568e, 0xb2df26af, + 0xd7b81de9, 0x78115023, 0x1d766b65, 0xfc32cdf6, 0x9955f6b0, + 0x36fcbb7a, 0x539b803c, 0xcfc25b38, 0xaaa5607e, 0x050c2db4, + 0x606b16f2, 0x812fb061, 0xe4488b27, 0x4be1c6ed, 0x2e86fdab, + 0x52198d8a, 0x377eb6cc, 0x98d7fb06, 0xfdb0c040, 0x1cf466d3, + 0x79935d95, 0xd63a105f, 0xb35d2b19, 0x6bf1402c, 0x0e967b6a, + 0xa13f36a0, 0xc4580de6, 0x251cab75, 0x407b9033, 0xefd2ddf9, + 0x8ab5e6bf, 0xf62a969e, 0x934dadd8, 0x3ce4e012, 0x5983db54, + 0xb8c77dc7, 0xdda04681, 0x72090b4b, 0x176e300d, 0x8b37eb09, + 0xee50d04f, 0x41f99d85, 0x249ea6c3, 0xc5da0050, 0xa0bd3b16, + 0x0f1476dc, 0x6a734d9a, 0x16ec3dbb, 0x738b06fd, 0xdc224b37, + 0xb9457071, 0x5801d6e2, 0x3d66eda4, 0x92cfa06e, 0xf7a89b28, + 0x710d1027, 0x146a2b61, 0xbbc366ab, 0xdea45ded, 0x3fe0fb7e, + 0x5a87c038, 0xf52e8df2, 0x9049b6b4, 0xecd6c695, 0x89b1fdd3, + 0x2618b019, 0x437f8b5f, 0xa23b2dcc, 0xc75c168a, 0x68f55b40, + 0x0d926006, 0x91cbbb02, 0xf4ac8044, 0x5b05cd8e, 0x3e62f6c8, + 0xdf26505b, 0xba416b1d, 0x15e826d7, 0x708f1d91, 0x0c106db0, + 0x697756f6, 0xc6de1b3c, 0xa3b9207a, 0x42fd86e9, 0x279abdaf, + 0x8833f065, 0xed54cb23, 0x5e09e03a, 0x3b6edb7c, 0x94c796b6, + 0xf1a0adf0, 0x10e40b63, 0x75833025, 0xda2a7def, 0xbf4d46a9, + 0xc3d23688, 0xa6b50dce, 0x091c4004, 0x6c7b7b42, 0x8d3fddd1, + 0xe858e697, 0x47f1ab5d, 0x2296901b, 0xbecf4b1f, 0xdba87059, + 0x74013d93, 0x116606d5, 0xf022a046, 0x95459b00, 0x3aecd6ca, + 0x5f8bed8c, 0x23149dad, 0x4673a6eb, 0xe9daeb21, 0x8cbdd067, + 0x6df976f4, 0x089e4db2, 0xa7370078, 0xc2503b3e, 0x44f5b031, + 0x21928b77, 0x8e3bc6bd, 0xeb5cfdfb, 0x0a185b68, 0x6f7f602e, + 0xc0d62de4, 0xa5b116a2, 0xd92e6683, 0xbc495dc5, 0x13e0100f, + 0x76872b49, 0x97c38dda, 0xf2a4b69c, 0x5d0dfb56, 0x386ac010, + 0xa4331b14, 0xc1542052, 0x6efd6d98, 0x0b9a56de, 0xeadef04d, + 0x8fb9cb0b, 0x201086c1, 0x4577bd87, 0x39e8cda6, 0x5c8ff6e0, + 0xf326bb2a, 0x9641806c, 0x770526ff, 0x12621db9, 0xbdcb5073, + 0xd8ac6b35}, + {0x00000000, 0xd7e28058, 0x74b406f1, 0xa35686a9, 0xe9680de2, + 0x3e8a8dba, 0x9ddc0b13, 0x4a3e8b4b, 0x09a11d85, 0xde439ddd, + 0x7d151b74, 0xaaf79b2c, 0xe0c91067, 0x372b903f, 0x947d1696, + 0x439f96ce, 0x13423b0a, 0xc4a0bb52, 0x67f63dfb, 0xb014bda3, + 0xfa2a36e8, 0x2dc8b6b0, 0x8e9e3019, 0x597cb041, 0x1ae3268f, + 0xcd01a6d7, 0x6e57207e, 0xb9b5a026, 0xf38b2b6d, 0x2469ab35, + 0x873f2d9c, 0x50ddadc4, 0x26847614, 0xf166f64c, 0x523070e5, + 0x85d2f0bd, 0xcfec7bf6, 0x180efbae, 0xbb587d07, 0x6cbafd5f, + 0x2f256b91, 0xf8c7ebc9, 0x5b916d60, 0x8c73ed38, 0xc64d6673, + 0x11afe62b, 0xb2f96082, 0x651be0da, 0x35c64d1e, 0xe224cd46, + 0x41724bef, 0x9690cbb7, 0xdcae40fc, 0x0b4cc0a4, 0xa81a460d, + 0x7ff8c655, 0x3c67509b, 0xeb85d0c3, 0x48d3566a, 0x9f31d632, + 0xd50f5d79, 0x02eddd21, 0xa1bb5b88, 0x7659dbd0, 0x4d08ec28, + 0x9aea6c70, 0x39bcead9, 0xee5e6a81, 0xa460e1ca, 0x73826192, + 0xd0d4e73b, 0x07366763, 0x44a9f1ad, 0x934b71f5, 0x301df75c, + 0xe7ff7704, 0xadc1fc4f, 0x7a237c17, 0xd975fabe, 0x0e977ae6, + 0x5e4ad722, 0x89a8577a, 0x2afed1d3, 0xfd1c518b, 0xb722dac0, + 0x60c05a98, 0xc396dc31, 0x14745c69, 0x57ebcaa7, 0x80094aff, + 0x235fcc56, 0xf4bd4c0e, 0xbe83c745, 0x6961471d, 0xca37c1b4, + 0x1dd541ec, 0x6b8c9a3c, 0xbc6e1a64, 0x1f389ccd, 0xc8da1c95, + 0x82e497de, 0x55061786, 0xf650912f, 0x21b21177, 0x622d87b9, + 0xb5cf07e1, 0x16998148, 0xc17b0110, 0x8b458a5b, 0x5ca70a03, + 0xfff18caa, 0x28130cf2, 0x78cea136, 0xaf2c216e, 0x0c7aa7c7, + 0xdb98279f, 0x91a6acd4, 0x46442c8c, 0xe512aa25, 0x32f02a7d, + 0x716fbcb3, 0xa68d3ceb, 0x05dbba42, 0xd2393a1a, 0x9807b151, + 0x4fe53109, 0xecb3b7a0, 0x3b5137f8, 0x9a11d850, 0x4df35808, + 0xeea5dea1, 0x39475ef9, 0x7379d5b2, 0xa49b55ea, 0x07cdd343, + 0xd02f531b, 0x93b0c5d5, 0x4452458d, 0xe704c324, 0x30e6437c, + 0x7ad8c837, 0xad3a486f, 0x0e6ccec6, 0xd98e4e9e, 0x8953e35a, + 0x5eb16302, 0xfde7e5ab, 0x2a0565f3, 0x603beeb8, 0xb7d96ee0, + 0x148fe849, 0xc36d6811, 0x80f2fedf, 0x57107e87, 0xf446f82e, + 0x23a47876, 0x699af33d, 0xbe787365, 0x1d2ef5cc, 0xcacc7594, + 0xbc95ae44, 0x6b772e1c, 0xc821a8b5, 0x1fc328ed, 0x55fda3a6, + 0x821f23fe, 0x2149a557, 0xf6ab250f, 0xb534b3c1, 0x62d63399, + 0xc180b530, 0x16623568, 0x5c5cbe23, 0x8bbe3e7b, 0x28e8b8d2, + 0xff0a388a, 0xafd7954e, 0x78351516, 0xdb6393bf, 0x0c8113e7, + 0x46bf98ac, 0x915d18f4, 0x320b9e5d, 0xe5e91e05, 0xa67688cb, + 0x71940893, 0xd2c28e3a, 0x05200e62, 0x4f1e8529, 0x98fc0571, + 0x3baa83d8, 0xec480380, 0xd7193478, 0x00fbb420, 0xa3ad3289, + 0x744fb2d1, 0x3e71399a, 0xe993b9c2, 0x4ac53f6b, 0x9d27bf33, + 0xdeb829fd, 0x095aa9a5, 0xaa0c2f0c, 0x7deeaf54, 0x37d0241f, + 0xe032a447, 0x436422ee, 0x9486a2b6, 0xc45b0f72, 0x13b98f2a, + 0xb0ef0983, 0x670d89db, 0x2d330290, 0xfad182c8, 0x59870461, + 0x8e658439, 0xcdfa12f7, 0x1a1892af, 0xb94e1406, 0x6eac945e, + 0x24921f15, 0xf3709f4d, 0x502619e4, 0x87c499bc, 0xf19d426c, + 0x267fc234, 0x8529449d, 0x52cbc4c5, 0x18f54f8e, 0xcf17cfd6, + 0x6c41497f, 0xbba3c927, 0xf83c5fe9, 0x2fdedfb1, 0x8c885918, + 0x5b6ad940, 0x1154520b, 0xc6b6d253, 0x65e054fa, 0xb202d4a2, + 0xe2df7966, 0x353df93e, 0x966b7f97, 0x4189ffcf, 0x0bb77484, + 0xdc55f4dc, 0x7f037275, 0xa8e1f22d, 0xeb7e64e3, 0x3c9ce4bb, + 0x9fca6212, 0x4828e24a, 0x02166901, 0xd5f4e959, 0x76a26ff0, + 0xa140efa8}, + {0x00000000, 0xef52b6e1, 0x05d46b83, 0xea86dd62, 0x0ba8d706, + 0xe4fa61e7, 0x0e7cbc85, 0xe12e0a64, 0x1751ae0c, 0xf80318ed, + 0x1285c58f, 0xfdd7736e, 0x1cf9790a, 0xf3abcfeb, 0x192d1289, + 0xf67fa468, 0x2ea35c18, 0xc1f1eaf9, 0x2b77379b, 0xc425817a, + 0x250b8b1e, 0xca593dff, 0x20dfe09d, 0xcf8d567c, 0x39f2f214, + 0xd6a044f5, 0x3c269997, 0xd3742f76, 0x325a2512, 0xdd0893f3, + 0x378e4e91, 0xd8dcf870, 0x5d46b830, 0xb2140ed1, 0x5892d3b3, + 0xb7c06552, 0x56ee6f36, 0xb9bcd9d7, 0x533a04b5, 0xbc68b254, + 0x4a17163c, 0xa545a0dd, 0x4fc37dbf, 0xa091cb5e, 0x41bfc13a, + 0xaeed77db, 0x446baab9, 0xab391c58, 0x73e5e428, 0x9cb752c9, + 0x76318fab, 0x9963394a, 0x784d332e, 0x971f85cf, 0x7d9958ad, + 0x92cbee4c, 0x64b44a24, 0x8be6fcc5, 0x616021a7, 0x8e329746, + 0x6f1c9d22, 0x804e2bc3, 0x6ac8f6a1, 0x859a4040, 0xba8d7060, + 0x55dfc681, 0xbf591be3, 0x500bad02, 0xb125a766, 0x5e771187, + 0xb4f1cce5, 0x5ba37a04, 0xaddcde6c, 0x428e688d, 0xa808b5ef, + 0x475a030e, 0xa674096a, 0x4926bf8b, 0xa3a062e9, 0x4cf2d408, + 0x942e2c78, 0x7b7c9a99, 0x91fa47fb, 0x7ea8f11a, 0x9f86fb7e, + 0x70d44d9f, 0x9a5290fd, 0x7500261c, 0x837f8274, 0x6c2d3495, + 0x86abe9f7, 0x69f95f16, 0x88d75572, 0x6785e393, 0x8d033ef1, + 0x62518810, 0xe7cbc850, 0x08997eb1, 0xe21fa3d3, 0x0d4d1532, + 0xec631f56, 0x0331a9b7, 0xe9b774d5, 0x06e5c234, 0xf09a665c, + 0x1fc8d0bd, 0xf54e0ddf, 0x1a1cbb3e, 0xfb32b15a, 0x146007bb, + 0xfee6dad9, 0x11b46c38, 0xc9689448, 0x263a22a9, 0xccbcffcb, + 0x23ee492a, 0xc2c0434e, 0x2d92f5af, 0xc71428cd, 0x28469e2c, + 0xde393a44, 0x316b8ca5, 0xdbed51c7, 0x34bfe726, 0xd591ed42, + 0x3ac35ba3, 0xd04586c1, 0x3f173020, 0xae6be681, 0x41395060, + 0xabbf8d02, 0x44ed3be3, 0xa5c33187, 0x4a918766, 0xa0175a04, + 0x4f45ece5, 0xb93a488d, 0x5668fe6c, 0xbcee230e, 0x53bc95ef, + 0xb2929f8b, 0x5dc0296a, 0xb746f408, 0x581442e9, 0x80c8ba99, + 0x6f9a0c78, 0x851cd11a, 0x6a4e67fb, 0x8b606d9f, 0x6432db7e, + 0x8eb4061c, 0x61e6b0fd, 0x97991495, 0x78cba274, 0x924d7f16, + 0x7d1fc9f7, 0x9c31c393, 0x73637572, 0x99e5a810, 0x76b71ef1, + 0xf32d5eb1, 0x1c7fe850, 0xf6f93532, 0x19ab83d3, 0xf88589b7, + 0x17d73f56, 0xfd51e234, 0x120354d5, 0xe47cf0bd, 0x0b2e465c, + 0xe1a89b3e, 0x0efa2ddf, 0xefd427bb, 0x0086915a, 0xea004c38, + 0x0552fad9, 0xdd8e02a9, 0x32dcb448, 0xd85a692a, 0x3708dfcb, + 0xd626d5af, 0x3974634e, 0xd3f2be2c, 0x3ca008cd, 0xcadfaca5, + 0x258d1a44, 0xcf0bc726, 0x205971c7, 0xc1777ba3, 0x2e25cd42, + 0xc4a31020, 0x2bf1a6c1, 0x14e696e1, 0xfbb42000, 0x1132fd62, + 0xfe604b83, 0x1f4e41e7, 0xf01cf706, 0x1a9a2a64, 0xf5c89c85, + 0x03b738ed, 0xece58e0c, 0x0663536e, 0xe931e58f, 0x081fefeb, + 0xe74d590a, 0x0dcb8468, 0xe2993289, 0x3a45caf9, 0xd5177c18, + 0x3f91a17a, 0xd0c3179b, 0x31ed1dff, 0xdebfab1e, 0x3439767c, + 0xdb6bc09d, 0x2d1464f5, 0xc246d214, 0x28c00f76, 0xc792b997, + 0x26bcb3f3, 0xc9ee0512, 0x2368d870, 0xcc3a6e91, 0x49a02ed1, + 0xa6f29830, 0x4c744552, 0xa326f3b3, 0x4208f9d7, 0xad5a4f36, + 0x47dc9254, 0xa88e24b5, 0x5ef180dd, 0xb1a3363c, 0x5b25eb5e, + 0xb4775dbf, 0x555957db, 0xba0be13a, 0x508d3c58, 0xbfdf8ab9, + 0x670372c9, 0x8851c428, 0x62d7194a, 0x8d85afab, 0x6caba5cf, + 0x83f9132e, 0x697fce4c, 0x862d78ad, 0x7052dcc5, 0x9f006a24, + 0x7586b746, 0x9ad401a7, 0x7bfa0bc3, 0x94a8bd22, 0x7e2e6040, + 0x917cd6a1}, + {0x00000000, 0x87a6cb43, 0xd43c90c7, 0x539a5b84, 0x730827cf, + 0xf4aeec8c, 0xa734b708, 0x20927c4b, 0xe6104f9e, 0x61b684dd, + 0x322cdf59, 0xb58a141a, 0x95186851, 0x12bea312, 0x4124f896, + 0xc68233d5, 0x1751997d, 0x90f7523e, 0xc36d09ba, 0x44cbc2f9, + 0x6459beb2, 0xe3ff75f1, 0xb0652e75, 0x37c3e536, 0xf141d6e3, + 0x76e71da0, 0x257d4624, 0xa2db8d67, 0x8249f12c, 0x05ef3a6f, + 0x567561eb, 0xd1d3aaa8, 0x2ea332fa, 0xa905f9b9, 0xfa9fa23d, + 0x7d39697e, 0x5dab1535, 0xda0dde76, 0x899785f2, 0x0e314eb1, + 0xc8b37d64, 0x4f15b627, 0x1c8feda3, 0x9b2926e0, 0xbbbb5aab, + 0x3c1d91e8, 0x6f87ca6c, 0xe821012f, 0x39f2ab87, 0xbe5460c4, + 0xedce3b40, 0x6a68f003, 0x4afa8c48, 0xcd5c470b, 0x9ec61c8f, + 0x1960d7cc, 0xdfe2e419, 0x58442f5a, 0x0bde74de, 0x8c78bf9d, + 0xaceac3d6, 0x2b4c0895, 0x78d65311, 0xff709852, 0x5d4665f4, + 0xdae0aeb7, 0x897af533, 0x0edc3e70, 0x2e4e423b, 0xa9e88978, + 0xfa72d2fc, 0x7dd419bf, 0xbb562a6a, 0x3cf0e129, 0x6f6abaad, + 0xe8cc71ee, 0xc85e0da5, 0x4ff8c6e6, 0x1c629d62, 0x9bc45621, + 0x4a17fc89, 0xcdb137ca, 0x9e2b6c4e, 0x198da70d, 0x391fdb46, + 0xbeb91005, 0xed234b81, 0x6a8580c2, 0xac07b317, 0x2ba17854, + 0x783b23d0, 0xff9de893, 0xdf0f94d8, 0x58a95f9b, 0x0b33041f, + 0x8c95cf5c, 0x73e5570e, 0xf4439c4d, 0xa7d9c7c9, 0x207f0c8a, + 0x00ed70c1, 0x874bbb82, 0xd4d1e006, 0x53772b45, 0x95f51890, + 0x1253d3d3, 0x41c98857, 0xc66f4314, 0xe6fd3f5f, 0x615bf41c, + 0x32c1af98, 0xb56764db, 0x64b4ce73, 0xe3120530, 0xb0885eb4, + 0x372e95f7, 0x17bce9bc, 0x901a22ff, 0xc380797b, 0x4426b238, + 0x82a481ed, 0x05024aae, 0x5698112a, 0xd13eda69, 0xf1aca622, + 0x760a6d61, 0x259036e5, 0xa236fda6, 0xba8ccbe8, 0x3d2a00ab, + 0x6eb05b2f, 0xe916906c, 0xc984ec27, 0x4e222764, 0x1db87ce0, + 0x9a1eb7a3, 0x5c9c8476, 0xdb3a4f35, 0x88a014b1, 0x0f06dff2, + 0x2f94a3b9, 0xa83268fa, 0xfba8337e, 0x7c0ef83d, 0xaddd5295, + 0x2a7b99d6, 0x79e1c252, 0xfe470911, 0xded5755a, 0x5973be19, + 0x0ae9e59d, 0x8d4f2ede, 0x4bcd1d0b, 0xcc6bd648, 0x9ff18dcc, + 0x1857468f, 0x38c53ac4, 0xbf63f187, 0xecf9aa03, 0x6b5f6140, + 0x942ff912, 0x13893251, 0x401369d5, 0xc7b5a296, 0xe727dedd, + 0x6081159e, 0x331b4e1a, 0xb4bd8559, 0x723fb68c, 0xf5997dcf, + 0xa603264b, 0x21a5ed08, 0x01379143, 0x86915a00, 0xd50b0184, + 0x52adcac7, 0x837e606f, 0x04d8ab2c, 0x5742f0a8, 0xd0e43beb, + 0xf07647a0, 0x77d08ce3, 0x244ad767, 0xa3ec1c24, 0x656e2ff1, + 0xe2c8e4b2, 0xb152bf36, 0x36f47475, 0x1666083e, 0x91c0c37d, + 0xc25a98f9, 0x45fc53ba, 0xe7caae1c, 0x606c655f, 0x33f63edb, + 0xb450f598, 0x94c289d3, 0x13644290, 0x40fe1914, 0xc758d257, + 0x01dae182, 0x867c2ac1, 0xd5e67145, 0x5240ba06, 0x72d2c64d, + 0xf5740d0e, 0xa6ee568a, 0x21489dc9, 0xf09b3761, 0x773dfc22, + 0x24a7a7a6, 0xa3016ce5, 0x839310ae, 0x0435dbed, 0x57af8069, + 0xd0094b2a, 0x168b78ff, 0x912db3bc, 0xc2b7e838, 0x4511237b, + 0x65835f30, 0xe2259473, 0xb1bfcff7, 0x361904b4, 0xc9699ce6, + 0x4ecf57a5, 0x1d550c21, 0x9af3c762, 0xba61bb29, 0x3dc7706a, + 0x6e5d2bee, 0xe9fbe0ad, 0x2f79d378, 0xa8df183b, 0xfb4543bf, + 0x7ce388fc, 0x5c71f4b7, 0xdbd73ff4, 0x884d6470, 0x0febaf33, + 0xde38059b, 0x599eced8, 0x0a04955c, 0x8da25e1f, 0xad302254, + 0x2a96e917, 0x790cb293, 0xfeaa79d0, 0x38284a05, 0xbf8e8146, + 0xec14dac2, 0x6bb21181, 0x4b206dca, 0xcc86a689, 0x9f1cfd0d, + 0x18ba364e}}; + +local const z_word_t FAR crc_braid_big_table[][256] = { + {0x0000000000000000, 0x43cba68700000000, 0xc7903cd400000000, + 0x845b9a5300000000, 0xcf27087300000000, 0x8cecaef400000000, + 0x08b734a700000000, 0x4b7c922000000000, 0x9e4f10e600000000, + 0xdd84b66100000000, 0x59df2c3200000000, 0x1a148ab500000000, + 0x5168189500000000, 0x12a3be1200000000, 0x96f8244100000000, + 0xd53382c600000000, 0x7d99511700000000, 0x3e52f79000000000, + 0xba096dc300000000, 0xf9c2cb4400000000, 0xb2be596400000000, + 0xf175ffe300000000, 0x752e65b000000000, 0x36e5c33700000000, + 0xe3d641f100000000, 0xa01de77600000000, 0x24467d2500000000, + 0x678ddba200000000, 0x2cf1498200000000, 0x6f3aef0500000000, + 0xeb61755600000000, 0xa8aad3d100000000, 0xfa32a32e00000000, + 0xb9f905a900000000, 0x3da29ffa00000000, 0x7e69397d00000000, + 0x3515ab5d00000000, 0x76de0dda00000000, 0xf285978900000000, + 0xb14e310e00000000, 0x647db3c800000000, 0x27b6154f00000000, + 0xa3ed8f1c00000000, 0xe026299b00000000, 0xab5abbbb00000000, + 0xe8911d3c00000000, 0x6cca876f00000000, 0x2f0121e800000000, + 0x87abf23900000000, 0xc46054be00000000, 0x403bceed00000000, + 0x03f0686a00000000, 0x488cfa4a00000000, 0x0b475ccd00000000, + 0x8f1cc69e00000000, 0xccd7601900000000, 0x19e4e2df00000000, + 0x5a2f445800000000, 0xde74de0b00000000, 0x9dbf788c00000000, + 0xd6c3eaac00000000, 0x95084c2b00000000, 0x1153d67800000000, + 0x529870ff00000000, 0xf465465d00000000, 0xb7aee0da00000000, + 0x33f57a8900000000, 0x703edc0e00000000, 0x3b424e2e00000000, + 0x7889e8a900000000, 0xfcd272fa00000000, 0xbf19d47d00000000, + 0x6a2a56bb00000000, 0x29e1f03c00000000, 0xadba6a6f00000000, + 0xee71cce800000000, 0xa50d5ec800000000, 0xe6c6f84f00000000, + 0x629d621c00000000, 0x2156c49b00000000, 0x89fc174a00000000, + 0xca37b1cd00000000, 0x4e6c2b9e00000000, 0x0da78d1900000000, + 0x46db1f3900000000, 0x0510b9be00000000, 0x814b23ed00000000, + 0xc280856a00000000, 0x17b307ac00000000, 0x5478a12b00000000, + 0xd0233b7800000000, 0x93e89dff00000000, 0xd8940fdf00000000, + 0x9b5fa95800000000, 0x1f04330b00000000, 0x5ccf958c00000000, + 0x0e57e57300000000, 0x4d9c43f400000000, 0xc9c7d9a700000000, + 0x8a0c7f2000000000, 0xc170ed0000000000, 0x82bb4b8700000000, + 0x06e0d1d400000000, 0x452b775300000000, 0x9018f59500000000, + 0xd3d3531200000000, 0x5788c94100000000, 0x14436fc600000000, + 0x5f3ffde600000000, 0x1cf45b6100000000, 0x98afc13200000000, + 0xdb6467b500000000, 0x73ceb46400000000, 0x300512e300000000, + 0xb45e88b000000000, 0xf7952e3700000000, 0xbce9bc1700000000, + 0xff221a9000000000, 0x7b7980c300000000, 0x38b2264400000000, + 0xed81a48200000000, 0xae4a020500000000, 0x2a11985600000000, + 0x69da3ed100000000, 0x22a6acf100000000, 0x616d0a7600000000, + 0xe536902500000000, 0xa6fd36a200000000, 0xe8cb8cba00000000, + 0xab002a3d00000000, 0x2f5bb06e00000000, 0x6c9016e900000000, + 0x27ec84c900000000, 0x6427224e00000000, 0xe07cb81d00000000, + 0xa3b71e9a00000000, 0x76849c5c00000000, 0x354f3adb00000000, + 0xb114a08800000000, 0xf2df060f00000000, 0xb9a3942f00000000, + 0xfa6832a800000000, 0x7e33a8fb00000000, 0x3df80e7c00000000, + 0x9552ddad00000000, 0xd6997b2a00000000, 0x52c2e17900000000, + 0x110947fe00000000, 0x5a75d5de00000000, 0x19be735900000000, + 0x9de5e90a00000000, 0xde2e4f8d00000000, 0x0b1dcd4b00000000, + 0x48d66bcc00000000, 0xcc8df19f00000000, 0x8f46571800000000, + 0xc43ac53800000000, 0x87f163bf00000000, 0x03aaf9ec00000000, + 0x40615f6b00000000, 0x12f92f9400000000, 0x5132891300000000, + 0xd569134000000000, 0x96a2b5c700000000, 0xddde27e700000000, + 0x9e15816000000000, 0x1a4e1b3300000000, 0x5985bdb400000000, + 0x8cb63f7200000000, 0xcf7d99f500000000, 0x4b2603a600000000, + 0x08eda52100000000, 0x4391370100000000, 0x005a918600000000, + 0x84010bd500000000, 0xc7caad5200000000, 0x6f607e8300000000, + 0x2cabd80400000000, 0xa8f0425700000000, 0xeb3be4d000000000, + 0xa04776f000000000, 0xe38cd07700000000, 0x67d74a2400000000, + 0x241ceca300000000, 0xf12f6e6500000000, 0xb2e4c8e200000000, + 0x36bf52b100000000, 0x7574f43600000000, 0x3e08661600000000, + 0x7dc3c09100000000, 0xf9985ac200000000, 0xba53fc4500000000, + 0x1caecae700000000, 0x5f656c6000000000, 0xdb3ef63300000000, + 0x98f550b400000000, 0xd389c29400000000, 0x9042641300000000, + 0x1419fe4000000000, 0x57d258c700000000, 0x82e1da0100000000, + 0xc12a7c8600000000, 0x4571e6d500000000, 0x06ba405200000000, + 0x4dc6d27200000000, 0x0e0d74f500000000, 0x8a56eea600000000, + 0xc99d482100000000, 0x61379bf000000000, 0x22fc3d7700000000, + 0xa6a7a72400000000, 0xe56c01a300000000, 0xae10938300000000, + 0xeddb350400000000, 0x6980af5700000000, 0x2a4b09d000000000, + 0xff788b1600000000, 0xbcb32d9100000000, 0x38e8b7c200000000, + 0x7b23114500000000, 0x305f836500000000, 0x739425e200000000, + 0xf7cfbfb100000000, 0xb404193600000000, 0xe69c69c900000000, + 0xa557cf4e00000000, 0x210c551d00000000, 0x62c7f39a00000000, + 0x29bb61ba00000000, 0x6a70c73d00000000, 0xee2b5d6e00000000, + 0xade0fbe900000000, 0x78d3792f00000000, 0x3b18dfa800000000, + 0xbf4345fb00000000, 0xfc88e37c00000000, 0xb7f4715c00000000, + 0xf43fd7db00000000, 0x70644d8800000000, 0x33afeb0f00000000, + 0x9b0538de00000000, 0xd8ce9e5900000000, 0x5c95040a00000000, + 0x1f5ea28d00000000, 0x542230ad00000000, 0x17e9962a00000000, + 0x93b20c7900000000, 0xd079aafe00000000, 0x054a283800000000, + 0x46818ebf00000000, 0xc2da14ec00000000, 0x8111b26b00000000, + 0xca6d204b00000000, 0x89a686cc00000000, 0x0dfd1c9f00000000, + 0x4e36ba1800000000}, + {0x0000000000000000, 0xe1b652ef00000000, 0x836bd40500000000, + 0x62dd86ea00000000, 0x06d7a80b00000000, 0xe761fae400000000, + 0x85bc7c0e00000000, 0x640a2ee100000000, 0x0cae511700000000, + 0xed1803f800000000, 0x8fc5851200000000, 0x6e73d7fd00000000, + 0x0a79f91c00000000, 0xebcfabf300000000, 0x89122d1900000000, + 0x68a47ff600000000, 0x185ca32e00000000, 0xf9eaf1c100000000, + 0x9b37772b00000000, 0x7a8125c400000000, 0x1e8b0b2500000000, + 0xff3d59ca00000000, 0x9de0df2000000000, 0x7c568dcf00000000, + 0x14f2f23900000000, 0xf544a0d600000000, 0x9799263c00000000, + 0x762f74d300000000, 0x12255a3200000000, 0xf39308dd00000000, + 0x914e8e3700000000, 0x70f8dcd800000000, 0x30b8465d00000000, + 0xd10e14b200000000, 0xb3d3925800000000, 0x5265c0b700000000, + 0x366fee5600000000, 0xd7d9bcb900000000, 0xb5043a5300000000, + 0x54b268bc00000000, 0x3c16174a00000000, 0xdda045a500000000, + 0xbf7dc34f00000000, 0x5ecb91a000000000, 0x3ac1bf4100000000, + 0xdb77edae00000000, 0xb9aa6b4400000000, 0x581c39ab00000000, + 0x28e4e57300000000, 0xc952b79c00000000, 0xab8f317600000000, + 0x4a39639900000000, 0x2e334d7800000000, 0xcf851f9700000000, + 0xad58997d00000000, 0x4ceecb9200000000, 0x244ab46400000000, + 0xc5fce68b00000000, 0xa721606100000000, 0x4697328e00000000, + 0x229d1c6f00000000, 0xc32b4e8000000000, 0xa1f6c86a00000000, + 0x40409a8500000000, 0x60708dba00000000, 0x81c6df5500000000, + 0xe31b59bf00000000, 0x02ad0b5000000000, 0x66a725b100000000, + 0x8711775e00000000, 0xe5ccf1b400000000, 0x047aa35b00000000, + 0x6cdedcad00000000, 0x8d688e4200000000, 0xefb508a800000000, + 0x0e035a4700000000, 0x6a0974a600000000, 0x8bbf264900000000, + 0xe962a0a300000000, 0x08d4f24c00000000, 0x782c2e9400000000, + 0x999a7c7b00000000, 0xfb47fa9100000000, 0x1af1a87e00000000, + 0x7efb869f00000000, 0x9f4dd47000000000, 0xfd90529a00000000, + 0x1c26007500000000, 0x74827f8300000000, 0x95342d6c00000000, + 0xf7e9ab8600000000, 0x165ff96900000000, 0x7255d78800000000, + 0x93e3856700000000, 0xf13e038d00000000, 0x1088516200000000, + 0x50c8cbe700000000, 0xb17e990800000000, 0xd3a31fe200000000, + 0x32154d0d00000000, 0x561f63ec00000000, 0xb7a9310300000000, + 0xd574b7e900000000, 0x34c2e50600000000, 0x5c669af000000000, + 0xbdd0c81f00000000, 0xdf0d4ef500000000, 0x3ebb1c1a00000000, + 0x5ab132fb00000000, 0xbb07601400000000, 0xd9dae6fe00000000, + 0x386cb41100000000, 0x489468c900000000, 0xa9223a2600000000, + 0xcbffbccc00000000, 0x2a49ee2300000000, 0x4e43c0c200000000, + 0xaff5922d00000000, 0xcd2814c700000000, 0x2c9e462800000000, + 0x443a39de00000000, 0xa58c6b3100000000, 0xc751eddb00000000, + 0x26e7bf3400000000, 0x42ed91d500000000, 0xa35bc33a00000000, + 0xc18645d000000000, 0x2030173f00000000, 0x81e66bae00000000, + 0x6050394100000000, 0x028dbfab00000000, 0xe33bed4400000000, + 0x8731c3a500000000, 0x6687914a00000000, 0x045a17a000000000, + 0xe5ec454f00000000, 0x8d483ab900000000, 0x6cfe685600000000, + 0x0e23eebc00000000, 0xef95bc5300000000, 0x8b9f92b200000000, + 0x6a29c05d00000000, 0x08f446b700000000, 0xe942145800000000, + 0x99bac88000000000, 0x780c9a6f00000000, 0x1ad11c8500000000, + 0xfb674e6a00000000, 0x9f6d608b00000000, 0x7edb326400000000, + 0x1c06b48e00000000, 0xfdb0e66100000000, 0x9514999700000000, + 0x74a2cb7800000000, 0x167f4d9200000000, 0xf7c91f7d00000000, + 0x93c3319c00000000, 0x7275637300000000, 0x10a8e59900000000, + 0xf11eb77600000000, 0xb15e2df300000000, 0x50e87f1c00000000, + 0x3235f9f600000000, 0xd383ab1900000000, 0xb78985f800000000, + 0x563fd71700000000, 0x34e251fd00000000, 0xd554031200000000, + 0xbdf07ce400000000, 0x5c462e0b00000000, 0x3e9ba8e100000000, + 0xdf2dfa0e00000000, 0xbb27d4ef00000000, 0x5a91860000000000, + 0x384c00ea00000000, 0xd9fa520500000000, 0xa9028edd00000000, + 0x48b4dc3200000000, 0x2a695ad800000000, 0xcbdf083700000000, + 0xafd526d600000000, 0x4e63743900000000, 0x2cbef2d300000000, + 0xcd08a03c00000000, 0xa5acdfca00000000, 0x441a8d2500000000, + 0x26c70bcf00000000, 0xc771592000000000, 0xa37b77c100000000, + 0x42cd252e00000000, 0x2010a3c400000000, 0xc1a6f12b00000000, + 0xe196e61400000000, 0x0020b4fb00000000, 0x62fd321100000000, + 0x834b60fe00000000, 0xe7414e1f00000000, 0x06f71cf000000000, + 0x642a9a1a00000000, 0x859cc8f500000000, 0xed38b70300000000, + 0x0c8ee5ec00000000, 0x6e53630600000000, 0x8fe531e900000000, + 0xebef1f0800000000, 0x0a594de700000000, 0x6884cb0d00000000, + 0x893299e200000000, 0xf9ca453a00000000, 0x187c17d500000000, + 0x7aa1913f00000000, 0x9b17c3d000000000, 0xff1ded3100000000, + 0x1eabbfde00000000, 0x7c76393400000000, 0x9dc06bdb00000000, + 0xf564142d00000000, 0x14d246c200000000, 0x760fc02800000000, + 0x97b992c700000000, 0xf3b3bc2600000000, 0x1205eec900000000, + 0x70d8682300000000, 0x916e3acc00000000, 0xd12ea04900000000, + 0x3098f2a600000000, 0x5245744c00000000, 0xb3f326a300000000, + 0xd7f9084200000000, 0x364f5aad00000000, 0x5492dc4700000000, + 0xb5248ea800000000, 0xdd80f15e00000000, 0x3c36a3b100000000, + 0x5eeb255b00000000, 0xbf5d77b400000000, 0xdb57595500000000, + 0x3ae10bba00000000, 0x583c8d5000000000, 0xb98adfbf00000000, + 0xc972036700000000, 0x28c4518800000000, 0x4a19d76200000000, + 0xabaf858d00000000, 0xcfa5ab6c00000000, 0x2e13f98300000000, + 0x4cce7f6900000000, 0xad782d8600000000, 0xc5dc527000000000, + 0x246a009f00000000, 0x46b7867500000000, 0xa701d49a00000000, + 0xc30bfa7b00000000, 0x22bda89400000000, 0x40602e7e00000000, + 0xa1d67c9100000000}, + {0x0000000000000000, 0x5880e2d700000000, 0xf106b47400000000, + 0xa98656a300000000, 0xe20d68e900000000, 0xba8d8a3e00000000, + 0x130bdc9d00000000, 0x4b8b3e4a00000000, 0x851da10900000000, + 0xdd9d43de00000000, 0x741b157d00000000, 0x2c9bf7aa00000000, + 0x6710c9e000000000, 0x3f902b3700000000, 0x96167d9400000000, + 0xce969f4300000000, 0x0a3b421300000000, 0x52bba0c400000000, + 0xfb3df66700000000, 0xa3bd14b000000000, 0xe8362afa00000000, + 0xb0b6c82d00000000, 0x19309e8e00000000, 0x41b07c5900000000, + 0x8f26e31a00000000, 0xd7a601cd00000000, 0x7e20576e00000000, + 0x26a0b5b900000000, 0x6d2b8bf300000000, 0x35ab692400000000, + 0x9c2d3f8700000000, 0xc4addd5000000000, 0x1476842600000000, + 0x4cf666f100000000, 0xe570305200000000, 0xbdf0d28500000000, + 0xf67beccf00000000, 0xaefb0e1800000000, 0x077d58bb00000000, + 0x5ffdba6c00000000, 0x916b252f00000000, 0xc9ebc7f800000000, + 0x606d915b00000000, 0x38ed738c00000000, 0x73664dc600000000, + 0x2be6af1100000000, 0x8260f9b200000000, 0xdae01b6500000000, + 0x1e4dc63500000000, 0x46cd24e200000000, 0xef4b724100000000, + 0xb7cb909600000000, 0xfc40aedc00000000, 0xa4c04c0b00000000, + 0x0d461aa800000000, 0x55c6f87f00000000, 0x9b50673c00000000, + 0xc3d085eb00000000, 0x6a56d34800000000, 0x32d6319f00000000, + 0x795d0fd500000000, 0x21dded0200000000, 0x885bbba100000000, + 0xd0db597600000000, 0x28ec084d00000000, 0x706cea9a00000000, + 0xd9eabc3900000000, 0x816a5eee00000000, 0xcae160a400000000, + 0x9261827300000000, 0x3be7d4d000000000, 0x6367360700000000, + 0xadf1a94400000000, 0xf5714b9300000000, 0x5cf71d3000000000, + 0x0477ffe700000000, 0x4ffcc1ad00000000, 0x177c237a00000000, + 0xbefa75d900000000, 0xe67a970e00000000, 0x22d74a5e00000000, + 0x7a57a88900000000, 0xd3d1fe2a00000000, 0x8b511cfd00000000, + 0xc0da22b700000000, 0x985ac06000000000, 0x31dc96c300000000, + 0x695c741400000000, 0xa7caeb5700000000, 0xff4a098000000000, + 0x56cc5f2300000000, 0x0e4cbdf400000000, 0x45c783be00000000, + 0x1d47616900000000, 0xb4c137ca00000000, 0xec41d51d00000000, + 0x3c9a8c6b00000000, 0x641a6ebc00000000, 0xcd9c381f00000000, + 0x951cdac800000000, 0xde97e48200000000, 0x8617065500000000, + 0x2f9150f600000000, 0x7711b22100000000, 0xb9872d6200000000, + 0xe107cfb500000000, 0x4881991600000000, 0x10017bc100000000, + 0x5b8a458b00000000, 0x030aa75c00000000, 0xaa8cf1ff00000000, + 0xf20c132800000000, 0x36a1ce7800000000, 0x6e212caf00000000, + 0xc7a77a0c00000000, 0x9f2798db00000000, 0xd4aca69100000000, + 0x8c2c444600000000, 0x25aa12e500000000, 0x7d2af03200000000, + 0xb3bc6f7100000000, 0xeb3c8da600000000, 0x42badb0500000000, + 0x1a3a39d200000000, 0x51b1079800000000, 0x0931e54f00000000, + 0xa0b7b3ec00000000, 0xf837513b00000000, 0x50d8119a00000000, + 0x0858f34d00000000, 0xa1dea5ee00000000, 0xf95e473900000000, + 0xb2d5797300000000, 0xea559ba400000000, 0x43d3cd0700000000, + 0x1b532fd000000000, 0xd5c5b09300000000, 0x8d45524400000000, + 0x24c304e700000000, 0x7c43e63000000000, 0x37c8d87a00000000, + 0x6f483aad00000000, 0xc6ce6c0e00000000, 0x9e4e8ed900000000, + 0x5ae3538900000000, 0x0263b15e00000000, 0xabe5e7fd00000000, + 0xf365052a00000000, 0xb8ee3b6000000000, 0xe06ed9b700000000, + 0x49e88f1400000000, 0x11686dc300000000, 0xdffef28000000000, + 0x877e105700000000, 0x2ef846f400000000, 0x7678a42300000000, + 0x3df39a6900000000, 0x657378be00000000, 0xccf52e1d00000000, + 0x9475ccca00000000, 0x44ae95bc00000000, 0x1c2e776b00000000, + 0xb5a821c800000000, 0xed28c31f00000000, 0xa6a3fd5500000000, + 0xfe231f8200000000, 0x57a5492100000000, 0x0f25abf600000000, + 0xc1b334b500000000, 0x9933d66200000000, 0x30b580c100000000, + 0x6835621600000000, 0x23be5c5c00000000, 0x7b3ebe8b00000000, + 0xd2b8e82800000000, 0x8a380aff00000000, 0x4e95d7af00000000, + 0x1615357800000000, 0xbf9363db00000000, 0xe713810c00000000, + 0xac98bf4600000000, 0xf4185d9100000000, 0x5d9e0b3200000000, + 0x051ee9e500000000, 0xcb8876a600000000, 0x9308947100000000, + 0x3a8ec2d200000000, 0x620e200500000000, 0x29851e4f00000000, + 0x7105fc9800000000, 0xd883aa3b00000000, 0x800348ec00000000, + 0x783419d700000000, 0x20b4fb0000000000, 0x8932ada300000000, + 0xd1b24f7400000000, 0x9a39713e00000000, 0xc2b993e900000000, + 0x6b3fc54a00000000, 0x33bf279d00000000, 0xfd29b8de00000000, + 0xa5a95a0900000000, 0x0c2f0caa00000000, 0x54afee7d00000000, + 0x1f24d03700000000, 0x47a432e000000000, 0xee22644300000000, + 0xb6a2869400000000, 0x720f5bc400000000, 0x2a8fb91300000000, + 0x8309efb000000000, 0xdb890d6700000000, 0x9002332d00000000, + 0xc882d1fa00000000, 0x6104875900000000, 0x3984658e00000000, + 0xf712facd00000000, 0xaf92181a00000000, 0x06144eb900000000, + 0x5e94ac6e00000000, 0x151f922400000000, 0x4d9f70f300000000, + 0xe419265000000000, 0xbc99c48700000000, 0x6c429df100000000, + 0x34c27f2600000000, 0x9d44298500000000, 0xc5c4cb5200000000, + 0x8e4ff51800000000, 0xd6cf17cf00000000, 0x7f49416c00000000, + 0x27c9a3bb00000000, 0xe95f3cf800000000, 0xb1dfde2f00000000, + 0x1859888c00000000, 0x40d96a5b00000000, 0x0b52541100000000, + 0x53d2b6c600000000, 0xfa54e06500000000, 0xa2d402b200000000, + 0x6679dfe200000000, 0x3ef93d3500000000, 0x977f6b9600000000, + 0xcfff894100000000, 0x8474b70b00000000, 0xdcf455dc00000000, + 0x7572037f00000000, 0x2df2e1a800000000, 0xe3647eeb00000000, + 0xbbe49c3c00000000, 0x1262ca9f00000000, 0x4ae2284800000000, + 0x0169160200000000, 0x59e9f4d500000000, 0xf06fa27600000000, + 0xa8ef40a100000000}, + {0x0000000000000000, 0x463b676500000000, 0x8c76ceca00000000, + 0xca4da9af00000000, 0x59ebed4e00000000, 0x1fd08a2b00000000, + 0xd59d238400000000, 0x93a644e100000000, 0xb2d6db9d00000000, + 0xf4edbcf800000000, 0x3ea0155700000000, 0x789b723200000000, + 0xeb3d36d300000000, 0xad0651b600000000, 0x674bf81900000000, + 0x21709f7c00000000, 0x25abc6e000000000, 0x6390a18500000000, + 0xa9dd082a00000000, 0xefe66f4f00000000, 0x7c402bae00000000, + 0x3a7b4ccb00000000, 0xf036e56400000000, 0xb60d820100000000, + 0x977d1d7d00000000, 0xd1467a1800000000, 0x1b0bd3b700000000, + 0x5d30b4d200000000, 0xce96f03300000000, 0x88ad975600000000, + 0x42e03ef900000000, 0x04db599c00000000, 0x0b50fc1a00000000, + 0x4d6b9b7f00000000, 0x872632d000000000, 0xc11d55b500000000, + 0x52bb115400000000, 0x1480763100000000, 0xdecddf9e00000000, + 0x98f6b8fb00000000, 0xb986278700000000, 0xffbd40e200000000, + 0x35f0e94d00000000, 0x73cb8e2800000000, 0xe06dcac900000000, + 0xa656adac00000000, 0x6c1b040300000000, 0x2a20636600000000, + 0x2efb3afa00000000, 0x68c05d9f00000000, 0xa28df43000000000, + 0xe4b6935500000000, 0x7710d7b400000000, 0x312bb0d100000000, + 0xfb66197e00000000, 0xbd5d7e1b00000000, 0x9c2de16700000000, + 0xda16860200000000, 0x105b2fad00000000, 0x566048c800000000, + 0xc5c60c2900000000, 0x83fd6b4c00000000, 0x49b0c2e300000000, + 0x0f8ba58600000000, 0x16a0f83500000000, 0x509b9f5000000000, + 0x9ad636ff00000000, 0xdced519a00000000, 0x4f4b157b00000000, + 0x0970721e00000000, 0xc33ddbb100000000, 0x8506bcd400000000, + 0xa47623a800000000, 0xe24d44cd00000000, 0x2800ed6200000000, + 0x6e3b8a0700000000, 0xfd9dcee600000000, 0xbba6a98300000000, + 0x71eb002c00000000, 0x37d0674900000000, 0x330b3ed500000000, + 0x753059b000000000, 0xbf7df01f00000000, 0xf946977a00000000, + 0x6ae0d39b00000000, 0x2cdbb4fe00000000, 0xe6961d5100000000, + 0xa0ad7a3400000000, 0x81dde54800000000, 0xc7e6822d00000000, + 0x0dab2b8200000000, 0x4b904ce700000000, 0xd836080600000000, + 0x9e0d6f6300000000, 0x5440c6cc00000000, 0x127ba1a900000000, + 0x1df0042f00000000, 0x5bcb634a00000000, 0x9186cae500000000, + 0xd7bdad8000000000, 0x441be96100000000, 0x02208e0400000000, + 0xc86d27ab00000000, 0x8e5640ce00000000, 0xaf26dfb200000000, + 0xe91db8d700000000, 0x2350117800000000, 0x656b761d00000000, + 0xf6cd32fc00000000, 0xb0f6559900000000, 0x7abbfc3600000000, + 0x3c809b5300000000, 0x385bc2cf00000000, 0x7e60a5aa00000000, + 0xb42d0c0500000000, 0xf2166b6000000000, 0x61b02f8100000000, + 0x278b48e400000000, 0xedc6e14b00000000, 0xabfd862e00000000, + 0x8a8d195200000000, 0xccb67e3700000000, 0x06fbd79800000000, + 0x40c0b0fd00000000, 0xd366f41c00000000, 0x955d937900000000, + 0x5f103ad600000000, 0x192b5db300000000, 0x2c40f16b00000000, + 0x6a7b960e00000000, 0xa0363fa100000000, 0xe60d58c400000000, + 0x75ab1c2500000000, 0x33907b4000000000, 0xf9ddd2ef00000000, + 0xbfe6b58a00000000, 0x9e962af600000000, 0xd8ad4d9300000000, + 0x12e0e43c00000000, 0x54db835900000000, 0xc77dc7b800000000, + 0x8146a0dd00000000, 0x4b0b097200000000, 0x0d306e1700000000, + 0x09eb378b00000000, 0x4fd050ee00000000, 0x859df94100000000, + 0xc3a69e2400000000, 0x5000dac500000000, 0x163bbda000000000, + 0xdc76140f00000000, 0x9a4d736a00000000, 0xbb3dec1600000000, + 0xfd068b7300000000, 0x374b22dc00000000, 0x717045b900000000, + 0xe2d6015800000000, 0xa4ed663d00000000, 0x6ea0cf9200000000, + 0x289ba8f700000000, 0x27100d7100000000, 0x612b6a1400000000, + 0xab66c3bb00000000, 0xed5da4de00000000, 0x7efbe03f00000000, + 0x38c0875a00000000, 0xf28d2ef500000000, 0xb4b6499000000000, + 0x95c6d6ec00000000, 0xd3fdb18900000000, 0x19b0182600000000, + 0x5f8b7f4300000000, 0xcc2d3ba200000000, 0x8a165cc700000000, + 0x405bf56800000000, 0x0660920d00000000, 0x02bbcb9100000000, + 0x4480acf400000000, 0x8ecd055b00000000, 0xc8f6623e00000000, + 0x5b5026df00000000, 0x1d6b41ba00000000, 0xd726e81500000000, + 0x911d8f7000000000, 0xb06d100c00000000, 0xf656776900000000, + 0x3c1bdec600000000, 0x7a20b9a300000000, 0xe986fd4200000000, + 0xafbd9a2700000000, 0x65f0338800000000, 0x23cb54ed00000000, + 0x3ae0095e00000000, 0x7cdb6e3b00000000, 0xb696c79400000000, + 0xf0ada0f100000000, 0x630be41000000000, 0x2530837500000000, + 0xef7d2ada00000000, 0xa9464dbf00000000, 0x8836d2c300000000, + 0xce0db5a600000000, 0x04401c0900000000, 0x427b7b6c00000000, + 0xd1dd3f8d00000000, 0x97e658e800000000, 0x5dabf14700000000, + 0x1b90962200000000, 0x1f4bcfbe00000000, 0x5970a8db00000000, + 0x933d017400000000, 0xd506661100000000, 0x46a022f000000000, + 0x009b459500000000, 0xcad6ec3a00000000, 0x8ced8b5f00000000, + 0xad9d142300000000, 0xeba6734600000000, 0x21ebdae900000000, + 0x67d0bd8c00000000, 0xf476f96d00000000, 0xb24d9e0800000000, + 0x780037a700000000, 0x3e3b50c200000000, 0x31b0f54400000000, + 0x778b922100000000, 0xbdc63b8e00000000, 0xfbfd5ceb00000000, + 0x685b180a00000000, 0x2e607f6f00000000, 0xe42dd6c000000000, + 0xa216b1a500000000, 0x83662ed900000000, 0xc55d49bc00000000, + 0x0f10e01300000000, 0x492b877600000000, 0xda8dc39700000000, + 0x9cb6a4f200000000, 0x56fb0d5d00000000, 0x10c06a3800000000, + 0x141b33a400000000, 0x522054c100000000, 0x986dfd6e00000000, + 0xde569a0b00000000, 0x4df0deea00000000, 0x0bcbb98f00000000, + 0xc186102000000000, 0x87bd774500000000, 0xa6cde83900000000, + 0xe0f68f5c00000000, 0x2abb26f300000000, 0x6c80419600000000, + 0xff26057700000000, 0xb91d621200000000, 0x7350cbbd00000000, + 0x356bacd800000000}, + {0x0000000000000000, 0x9e83da9f00000000, 0x7d01c4e400000000, + 0xe3821e7b00000000, 0xbb04f91200000000, 0x2587238d00000000, + 0xc6053df600000000, 0x5886e76900000000, 0x7609f22500000000, + 0xe88a28ba00000000, 0x0b0836c100000000, 0x958bec5e00000000, + 0xcd0d0b3700000000, 0x538ed1a800000000, 0xb00ccfd300000000, + 0x2e8f154c00000000, 0xec12e44b00000000, 0x72913ed400000000, + 0x911320af00000000, 0x0f90fa3000000000, 0x57161d5900000000, + 0xc995c7c600000000, 0x2a17d9bd00000000, 0xb494032200000000, + 0x9a1b166e00000000, 0x0498ccf100000000, 0xe71ad28a00000000, + 0x7999081500000000, 0x211fef7c00000000, 0xbf9c35e300000000, + 0x5c1e2b9800000000, 0xc29df10700000000, 0xd825c89700000000, + 0x46a6120800000000, 0xa5240c7300000000, 0x3ba7d6ec00000000, + 0x6321318500000000, 0xfda2eb1a00000000, 0x1e20f56100000000, + 0x80a32ffe00000000, 0xae2c3ab200000000, 0x30afe02d00000000, + 0xd32dfe5600000000, 0x4dae24c900000000, 0x1528c3a000000000, + 0x8bab193f00000000, 0x6829074400000000, 0xf6aadddb00000000, + 0x34372cdc00000000, 0xaab4f64300000000, 0x4936e83800000000, + 0xd7b532a700000000, 0x8f33d5ce00000000, 0x11b00f5100000000, + 0xf232112a00000000, 0x6cb1cbb500000000, 0x423edef900000000, + 0xdcbd046600000000, 0x3f3f1a1d00000000, 0xa1bcc08200000000, + 0xf93a27eb00000000, 0x67b9fd7400000000, 0x843be30f00000000, + 0x1ab8399000000000, 0xf14de1f400000000, 0x6fce3b6b00000000, + 0x8c4c251000000000, 0x12cfff8f00000000, 0x4a4918e600000000, + 0xd4cac27900000000, 0x3748dc0200000000, 0xa9cb069d00000000, + 0x874413d100000000, 0x19c7c94e00000000, 0xfa45d73500000000, + 0x64c60daa00000000, 0x3c40eac300000000, 0xa2c3305c00000000, + 0x41412e2700000000, 0xdfc2f4b800000000, 0x1d5f05bf00000000, + 0x83dcdf2000000000, 0x605ec15b00000000, 0xfedd1bc400000000, + 0xa65bfcad00000000, 0x38d8263200000000, 0xdb5a384900000000, + 0x45d9e2d600000000, 0x6b56f79a00000000, 0xf5d52d0500000000, + 0x1657337e00000000, 0x88d4e9e100000000, 0xd0520e8800000000, + 0x4ed1d41700000000, 0xad53ca6c00000000, 0x33d010f300000000, + 0x2968296300000000, 0xb7ebf3fc00000000, 0x5469ed8700000000, + 0xcaea371800000000, 0x926cd07100000000, 0x0cef0aee00000000, + 0xef6d149500000000, 0x71eece0a00000000, 0x5f61db4600000000, + 0xc1e201d900000000, 0x22601fa200000000, 0xbce3c53d00000000, + 0xe465225400000000, 0x7ae6f8cb00000000, 0x9964e6b000000000, + 0x07e73c2f00000000, 0xc57acd2800000000, 0x5bf917b700000000, + 0xb87b09cc00000000, 0x26f8d35300000000, 0x7e7e343a00000000, + 0xe0fdeea500000000, 0x037ff0de00000000, 0x9dfc2a4100000000, + 0xb3733f0d00000000, 0x2df0e59200000000, 0xce72fbe900000000, + 0x50f1217600000000, 0x0877c61f00000000, 0x96f41c8000000000, + 0x757602fb00000000, 0xebf5d86400000000, 0xa39db33200000000, + 0x3d1e69ad00000000, 0xde9c77d600000000, 0x401fad4900000000, + 0x18994a2000000000, 0x861a90bf00000000, 0x65988ec400000000, + 0xfb1b545b00000000, 0xd594411700000000, 0x4b179b8800000000, + 0xa89585f300000000, 0x36165f6c00000000, 0x6e90b80500000000, + 0xf013629a00000000, 0x13917ce100000000, 0x8d12a67e00000000, + 0x4f8f577900000000, 0xd10c8de600000000, 0x328e939d00000000, + 0xac0d490200000000, 0xf48bae6b00000000, 0x6a0874f400000000, + 0x898a6a8f00000000, 0x1709b01000000000, 0x3986a55c00000000, + 0xa7057fc300000000, 0x448761b800000000, 0xda04bb2700000000, + 0x82825c4e00000000, 0x1c0186d100000000, 0xff8398aa00000000, + 0x6100423500000000, 0x7bb87ba500000000, 0xe53ba13a00000000, + 0x06b9bf4100000000, 0x983a65de00000000, 0xc0bc82b700000000, + 0x5e3f582800000000, 0xbdbd465300000000, 0x233e9ccc00000000, + 0x0db1898000000000, 0x9332531f00000000, 0x70b04d6400000000, + 0xee3397fb00000000, 0xb6b5709200000000, 0x2836aa0d00000000, + 0xcbb4b47600000000, 0x55376ee900000000, 0x97aa9fee00000000, + 0x0929457100000000, 0xeaab5b0a00000000, 0x7428819500000000, + 0x2cae66fc00000000, 0xb22dbc6300000000, 0x51afa21800000000, + 0xcf2c788700000000, 0xe1a36dcb00000000, 0x7f20b75400000000, + 0x9ca2a92f00000000, 0x022173b000000000, 0x5aa794d900000000, + 0xc4244e4600000000, 0x27a6503d00000000, 0xb9258aa200000000, + 0x52d052c600000000, 0xcc53885900000000, 0x2fd1962200000000, + 0xb1524cbd00000000, 0xe9d4abd400000000, 0x7757714b00000000, + 0x94d56f3000000000, 0x0a56b5af00000000, 0x24d9a0e300000000, + 0xba5a7a7c00000000, 0x59d8640700000000, 0xc75bbe9800000000, + 0x9fdd59f100000000, 0x015e836e00000000, 0xe2dc9d1500000000, + 0x7c5f478a00000000, 0xbec2b68d00000000, 0x20416c1200000000, + 0xc3c3726900000000, 0x5d40a8f600000000, 0x05c64f9f00000000, + 0x9b45950000000000, 0x78c78b7b00000000, 0xe64451e400000000, + 0xc8cb44a800000000, 0x56489e3700000000, 0xb5ca804c00000000, + 0x2b495ad300000000, 0x73cfbdba00000000, 0xed4c672500000000, + 0x0ece795e00000000, 0x904da3c100000000, 0x8af59a5100000000, + 0x147640ce00000000, 0xf7f45eb500000000, 0x6977842a00000000, + 0x31f1634300000000, 0xaf72b9dc00000000, 0x4cf0a7a700000000, + 0xd2737d3800000000, 0xfcfc687400000000, 0x627fb2eb00000000, + 0x81fdac9000000000, 0x1f7e760f00000000, 0x47f8916600000000, + 0xd97b4bf900000000, 0x3af9558200000000, 0xa47a8f1d00000000, + 0x66e77e1a00000000, 0xf864a48500000000, 0x1be6bafe00000000, + 0x8565606100000000, 0xdde3870800000000, 0x43605d9700000000, + 0xa0e243ec00000000, 0x3e61997300000000, 0x10ee8c3f00000000, + 0x8e6d56a000000000, 0x6def48db00000000, 0xf36c924400000000, + 0xabea752d00000000, 0x3569afb200000000, 0xd6ebb1c900000000, + 0x48686b5600000000}, + {0x0000000000000000, 0xc064281700000000, 0x80c9502e00000000, + 0x40ad783900000000, 0x0093a15c00000000, 0xc0f7894b00000000, + 0x805af17200000000, 0x403ed96500000000, 0x002643b900000000, + 0xc0426bae00000000, 0x80ef139700000000, 0x408b3b8000000000, + 0x00b5e2e500000000, 0xc0d1caf200000000, 0x807cb2cb00000000, + 0x40189adc00000000, 0x414af7a900000000, 0x812edfbe00000000, + 0xc183a78700000000, 0x01e78f9000000000, 0x41d956f500000000, + 0x81bd7ee200000000, 0xc11006db00000000, 0x01742ecc00000000, + 0x416cb41000000000, 0x81089c0700000000, 0xc1a5e43e00000000, + 0x01c1cc2900000000, 0x41ff154c00000000, 0x819b3d5b00000000, + 0xc136456200000000, 0x01526d7500000000, 0xc3929f8800000000, + 0x03f6b79f00000000, 0x435bcfa600000000, 0x833fe7b100000000, + 0xc3013ed400000000, 0x036516c300000000, 0x43c86efa00000000, + 0x83ac46ed00000000, 0xc3b4dc3100000000, 0x03d0f42600000000, + 0x437d8c1f00000000, 0x8319a40800000000, 0xc3277d6d00000000, + 0x0343557a00000000, 0x43ee2d4300000000, 0x838a055400000000, + 0x82d8682100000000, 0x42bc403600000000, 0x0211380f00000000, + 0xc275101800000000, 0x824bc97d00000000, 0x422fe16a00000000, + 0x0282995300000000, 0xc2e6b14400000000, 0x82fe2b9800000000, + 0x429a038f00000000, 0x02377bb600000000, 0xc25353a100000000, + 0x826d8ac400000000, 0x4209a2d300000000, 0x02a4daea00000000, + 0xc2c0f2fd00000000, 0xc7234eca00000000, 0x074766dd00000000, + 0x47ea1ee400000000, 0x878e36f300000000, 0xc7b0ef9600000000, + 0x07d4c78100000000, 0x4779bfb800000000, 0x871d97af00000000, + 0xc7050d7300000000, 0x0761256400000000, 0x47cc5d5d00000000, + 0x87a8754a00000000, 0xc796ac2f00000000, 0x07f2843800000000, + 0x475ffc0100000000, 0x873bd41600000000, 0x8669b96300000000, + 0x460d917400000000, 0x06a0e94d00000000, 0xc6c4c15a00000000, + 0x86fa183f00000000, 0x469e302800000000, 0x0633481100000000, + 0xc657600600000000, 0x864ffada00000000, 0x462bd2cd00000000, + 0x0686aaf400000000, 0xc6e282e300000000, 0x86dc5b8600000000, + 0x46b8739100000000, 0x06150ba800000000, 0xc67123bf00000000, + 0x04b1d14200000000, 0xc4d5f95500000000, 0x8478816c00000000, + 0x441ca97b00000000, 0x0422701e00000000, 0xc446580900000000, + 0x84eb203000000000, 0x448f082700000000, 0x049792fb00000000, + 0xc4f3baec00000000, 0x845ec2d500000000, 0x443aeac200000000, + 0x040433a700000000, 0xc4601bb000000000, 0x84cd638900000000, + 0x44a94b9e00000000, 0x45fb26eb00000000, 0x859f0efc00000000, + 0xc53276c500000000, 0x05565ed200000000, 0x456887b700000000, + 0x850cafa000000000, 0xc5a1d79900000000, 0x05c5ff8e00000000, + 0x45dd655200000000, 0x85b94d4500000000, 0xc514357c00000000, + 0x05701d6b00000000, 0x454ec40e00000000, 0x852aec1900000000, + 0xc587942000000000, 0x05e3bc3700000000, 0xcf41ed4f00000000, + 0x0f25c55800000000, 0x4f88bd6100000000, 0x8fec957600000000, + 0xcfd24c1300000000, 0x0fb6640400000000, 0x4f1b1c3d00000000, + 0x8f7f342a00000000, 0xcf67aef600000000, 0x0f0386e100000000, + 0x4faefed800000000, 0x8fcad6cf00000000, 0xcff40faa00000000, + 0x0f9027bd00000000, 0x4f3d5f8400000000, 0x8f59779300000000, + 0x8e0b1ae600000000, 0x4e6f32f100000000, 0x0ec24ac800000000, + 0xcea662df00000000, 0x8e98bbba00000000, 0x4efc93ad00000000, + 0x0e51eb9400000000, 0xce35c38300000000, 0x8e2d595f00000000, + 0x4e49714800000000, 0x0ee4097100000000, 0xce80216600000000, + 0x8ebef80300000000, 0x4edad01400000000, 0x0e77a82d00000000, + 0xce13803a00000000, 0x0cd372c700000000, 0xccb75ad000000000, + 0x8c1a22e900000000, 0x4c7e0afe00000000, 0x0c40d39b00000000, + 0xcc24fb8c00000000, 0x8c8983b500000000, 0x4cedaba200000000, + 0x0cf5317e00000000, 0xcc91196900000000, 0x8c3c615000000000, + 0x4c58494700000000, 0x0c66902200000000, 0xcc02b83500000000, + 0x8cafc00c00000000, 0x4ccbe81b00000000, 0x4d99856e00000000, + 0x8dfdad7900000000, 0xcd50d54000000000, 0x0d34fd5700000000, + 0x4d0a243200000000, 0x8d6e0c2500000000, 0xcdc3741c00000000, + 0x0da75c0b00000000, 0x4dbfc6d700000000, 0x8ddbeec000000000, + 0xcd7696f900000000, 0x0d12beee00000000, 0x4d2c678b00000000, + 0x8d484f9c00000000, 0xcde537a500000000, 0x0d811fb200000000, + 0x0862a38500000000, 0xc8068b9200000000, 0x88abf3ab00000000, + 0x48cfdbbc00000000, 0x08f102d900000000, 0xc8952ace00000000, + 0x883852f700000000, 0x485c7ae000000000, 0x0844e03c00000000, + 0xc820c82b00000000, 0x888db01200000000, 0x48e9980500000000, + 0x08d7416000000000, 0xc8b3697700000000, 0x881e114e00000000, + 0x487a395900000000, 0x4928542c00000000, 0x894c7c3b00000000, + 0xc9e1040200000000, 0x09852c1500000000, 0x49bbf57000000000, + 0x89dfdd6700000000, 0xc972a55e00000000, 0x09168d4900000000, + 0x490e179500000000, 0x896a3f8200000000, 0xc9c747bb00000000, + 0x09a36fac00000000, 0x499db6c900000000, 0x89f99ede00000000, + 0xc954e6e700000000, 0x0930cef000000000, 0xcbf03c0d00000000, + 0x0b94141a00000000, 0x4b396c2300000000, 0x8b5d443400000000, + 0xcb639d5100000000, 0x0b07b54600000000, 0x4baacd7f00000000, + 0x8bcee56800000000, 0xcbd67fb400000000, 0x0bb257a300000000, + 0x4b1f2f9a00000000, 0x8b7b078d00000000, 0xcb45dee800000000, + 0x0b21f6ff00000000, 0x4b8c8ec600000000, 0x8be8a6d100000000, + 0x8abacba400000000, 0x4adee3b300000000, 0x0a739b8a00000000, + 0xca17b39d00000000, 0x8a296af800000000, 0x4a4d42ef00000000, + 0x0ae03ad600000000, 0xca8412c100000000, 0x8a9c881d00000000, + 0x4af8a00a00000000, 0x0a55d83300000000, 0xca31f02400000000, + 0x8a0f294100000000, 0x4a6b015600000000, 0x0ac6796f00000000, + 0xcaa2517800000000}, + {0x0000000000000000, 0xd4ea739b00000000, 0xe9d396ed00000000, + 0x3d39e57600000000, 0x93a15c0000000000, 0x474b2f9b00000000, + 0x7a72caed00000000, 0xae98b97600000000, 0x2643b90000000000, + 0xf2a9ca9b00000000, 0xcf902fed00000000, 0x1b7a5c7600000000, + 0xb5e2e50000000000, 0x6108969b00000000, 0x5c3173ed00000000, + 0x88db007600000000, 0x4c86720100000000, 0x986c019a00000000, + 0xa555e4ec00000000, 0x71bf977700000000, 0xdf272e0100000000, + 0x0bcd5d9a00000000, 0x36f4b8ec00000000, 0xe21ecb7700000000, + 0x6ac5cb0100000000, 0xbe2fb89a00000000, 0x83165dec00000000, + 0x57fc2e7700000000, 0xf964970100000000, 0x2d8ee49a00000000, + 0x10b701ec00000000, 0xc45d727700000000, 0x980ce50200000000, + 0x4ce6969900000000, 0x71df73ef00000000, 0xa535007400000000, + 0x0badb90200000000, 0xdf47ca9900000000, 0xe27e2fef00000000, + 0x36945c7400000000, 0xbe4f5c0200000000, 0x6aa52f9900000000, + 0x579ccaef00000000, 0x8376b97400000000, 0x2dee000200000000, + 0xf904739900000000, 0xc43d96ef00000000, 0x10d7e57400000000, + 0xd48a970300000000, 0x0060e49800000000, 0x3d5901ee00000000, + 0xe9b3727500000000, 0x472bcb0300000000, 0x93c1b89800000000, + 0xaef85dee00000000, 0x7a122e7500000000, 0xf2c92e0300000000, + 0x26235d9800000000, 0x1b1ab8ee00000000, 0xcff0cb7500000000, + 0x6168720300000000, 0xb582019800000000, 0x88bbe4ee00000000, + 0x5c51977500000000, 0x3019ca0500000000, 0xe4f3b99e00000000, + 0xd9ca5ce800000000, 0x0d202f7300000000, 0xa3b8960500000000, + 0x7752e59e00000000, 0x4a6b00e800000000, 0x9e81737300000000, + 0x165a730500000000, 0xc2b0009e00000000, 0xff89e5e800000000, + 0x2b63967300000000, 0x85fb2f0500000000, 0x51115c9e00000000, + 0x6c28b9e800000000, 0xb8c2ca7300000000, 0x7c9fb80400000000, + 0xa875cb9f00000000, 0x954c2ee900000000, 0x41a65d7200000000, + 0xef3ee40400000000, 0x3bd4979f00000000, 0x06ed72e900000000, + 0xd207017200000000, 0x5adc010400000000, 0x8e36729f00000000, + 0xb30f97e900000000, 0x67e5e47200000000, 0xc97d5d0400000000, + 0x1d972e9f00000000, 0x20aecbe900000000, 0xf444b87200000000, + 0xa8152f0700000000, 0x7cff5c9c00000000, 0x41c6b9ea00000000, + 0x952cca7100000000, 0x3bb4730700000000, 0xef5e009c00000000, + 0xd267e5ea00000000, 0x068d967100000000, 0x8e56960700000000, + 0x5abce59c00000000, 0x678500ea00000000, 0xb36f737100000000, + 0x1df7ca0700000000, 0xc91db99c00000000, 0xf4245cea00000000, + 0x20ce2f7100000000, 0xe4935d0600000000, 0x30792e9d00000000, + 0x0d40cbeb00000000, 0xd9aab87000000000, 0x7732010600000000, + 0xa3d8729d00000000, 0x9ee197eb00000000, 0x4a0be47000000000, + 0xc2d0e40600000000, 0x163a979d00000000, 0x2b0372eb00000000, + 0xffe9017000000000, 0x5171b80600000000, 0x859bcb9d00000000, + 0xb8a22eeb00000000, 0x6c485d7000000000, 0x6032940b00000000, + 0xb4d8e79000000000, 0x89e102e600000000, 0x5d0b717d00000000, + 0xf393c80b00000000, 0x2779bb9000000000, 0x1a405ee600000000, + 0xceaa2d7d00000000, 0x46712d0b00000000, 0x929b5e9000000000, + 0xafa2bbe600000000, 0x7b48c87d00000000, 0xd5d0710b00000000, + 0x013a029000000000, 0x3c03e7e600000000, 0xe8e9947d00000000, + 0x2cb4e60a00000000, 0xf85e959100000000, 0xc56770e700000000, + 0x118d037c00000000, 0xbf15ba0a00000000, 0x6bffc99100000000, + 0x56c62ce700000000, 0x822c5f7c00000000, 0x0af75f0a00000000, + 0xde1d2c9100000000, 0xe324c9e700000000, 0x37ceba7c00000000, + 0x9956030a00000000, 0x4dbc709100000000, 0x708595e700000000, + 0xa46fe67c00000000, 0xf83e710900000000, 0x2cd4029200000000, + 0x11ede7e400000000, 0xc507947f00000000, 0x6b9f2d0900000000, + 0xbf755e9200000000, 0x824cbbe400000000, 0x56a6c87f00000000, + 0xde7dc80900000000, 0x0a97bb9200000000, 0x37ae5ee400000000, + 0xe3442d7f00000000, 0x4ddc940900000000, 0x9936e79200000000, + 0xa40f02e400000000, 0x70e5717f00000000, 0xb4b8030800000000, + 0x6052709300000000, 0x5d6b95e500000000, 0x8981e67e00000000, + 0x27195f0800000000, 0xf3f32c9300000000, 0xcecac9e500000000, + 0x1a20ba7e00000000, 0x92fbba0800000000, 0x4611c99300000000, + 0x7b282ce500000000, 0xafc25f7e00000000, 0x015ae60800000000, + 0xd5b0959300000000, 0xe88970e500000000, 0x3c63037e00000000, + 0x502b5e0e00000000, 0x84c12d9500000000, 0xb9f8c8e300000000, + 0x6d12bb7800000000, 0xc38a020e00000000, 0x1760719500000000, + 0x2a5994e300000000, 0xfeb3e77800000000, 0x7668e70e00000000, + 0xa282949500000000, 0x9fbb71e300000000, 0x4b51027800000000, + 0xe5c9bb0e00000000, 0x3123c89500000000, 0x0c1a2de300000000, + 0xd8f05e7800000000, 0x1cad2c0f00000000, 0xc8475f9400000000, + 0xf57ebae200000000, 0x2194c97900000000, 0x8f0c700f00000000, + 0x5be6039400000000, 0x66dfe6e200000000, 0xb235957900000000, + 0x3aee950f00000000, 0xee04e69400000000, 0xd33d03e200000000, + 0x07d7707900000000, 0xa94fc90f00000000, 0x7da5ba9400000000, + 0x409c5fe200000000, 0x94762c7900000000, 0xc827bb0c00000000, + 0x1ccdc89700000000, 0x21f42de100000000, 0xf51e5e7a00000000, + 0x5b86e70c00000000, 0x8f6c949700000000, 0xb25571e100000000, + 0x66bf027a00000000, 0xee64020c00000000, 0x3a8e719700000000, + 0x07b794e100000000, 0xd35de77a00000000, 0x7dc55e0c00000000, + 0xa92f2d9700000000, 0x9416c8e100000000, 0x40fcbb7a00000000, + 0x84a1c90d00000000, 0x504bba9600000000, 0x6d725fe000000000, + 0xb9982c7b00000000, 0x1700950d00000000, 0xc3eae69600000000, + 0xfed303e000000000, 0x2a39707b00000000, 0xa2e2700d00000000, + 0x7608039600000000, 0x4b31e6e000000000, 0x9fdb957b00000000, + 0x31432c0d00000000, 0xe5a95f9600000000, 0xd890bae000000000, + 0x0c7ac97b00000000}, + {0x0000000000000000, 0x2765258100000000, 0x0fcc3bd900000000, + 0x28a91e5800000000, 0x5f9e066900000000, 0x78fb23e800000000, + 0x50523db000000000, 0x7737183100000000, 0xbe3c0dd200000000, + 0x9959285300000000, 0xb1f0360b00000000, 0x9695138a00000000, + 0xe1a20bbb00000000, 0xc6c72e3a00000000, 0xee6e306200000000, + 0xc90b15e300000000, 0x3d7f6b7f00000000, 0x1a1a4efe00000000, + 0x32b350a600000000, 0x15d6752700000000, 0x62e16d1600000000, + 0x4584489700000000, 0x6d2d56cf00000000, 0x4a48734e00000000, + 0x834366ad00000000, 0xa426432c00000000, 0x8c8f5d7400000000, + 0xabea78f500000000, 0xdcdd60c400000000, 0xfbb8454500000000, + 0xd3115b1d00000000, 0xf4747e9c00000000, 0x7afed6fe00000000, + 0x5d9bf37f00000000, 0x7532ed2700000000, 0x5257c8a600000000, + 0x2560d09700000000, 0x0205f51600000000, 0x2aaceb4e00000000, + 0x0dc9cecf00000000, 0xc4c2db2c00000000, 0xe3a7fead00000000, + 0xcb0ee0f500000000, 0xec6bc57400000000, 0x9b5cdd4500000000, + 0xbc39f8c400000000, 0x9490e69c00000000, 0xb3f5c31d00000000, + 0x4781bd8100000000, 0x60e4980000000000, 0x484d865800000000, + 0x6f28a3d900000000, 0x181fbbe800000000, 0x3f7a9e6900000000, + 0x17d3803100000000, 0x30b6a5b000000000, 0xf9bdb05300000000, + 0xded895d200000000, 0xf6718b8a00000000, 0xd114ae0b00000000, + 0xa623b63a00000000, 0x814693bb00000000, 0xa9ef8de300000000, + 0x8e8aa86200000000, 0xb5fadc2600000000, 0x929ff9a700000000, + 0xba36e7ff00000000, 0x9d53c27e00000000, 0xea64da4f00000000, + 0xcd01ffce00000000, 0xe5a8e19600000000, 0xc2cdc41700000000, + 0x0bc6d1f400000000, 0x2ca3f47500000000, 0x040aea2d00000000, + 0x236fcfac00000000, 0x5458d79d00000000, 0x733df21c00000000, + 0x5b94ec4400000000, 0x7cf1c9c500000000, 0x8885b75900000000, + 0xafe092d800000000, 0x87498c8000000000, 0xa02ca90100000000, + 0xd71bb13000000000, 0xf07e94b100000000, 0xd8d78ae900000000, + 0xffb2af6800000000, 0x36b9ba8b00000000, 0x11dc9f0a00000000, + 0x3975815200000000, 0x1e10a4d300000000, 0x6927bce200000000, + 0x4e42996300000000, 0x66eb873b00000000, 0x418ea2ba00000000, + 0xcf040ad800000000, 0xe8612f5900000000, 0xc0c8310100000000, + 0xe7ad148000000000, 0x909a0cb100000000, 0xb7ff293000000000, + 0x9f56376800000000, 0xb83312e900000000, 0x7138070a00000000, + 0x565d228b00000000, 0x7ef43cd300000000, 0x5991195200000000, + 0x2ea6016300000000, 0x09c324e200000000, 0x216a3aba00000000, + 0x060f1f3b00000000, 0xf27b61a700000000, 0xd51e442600000000, + 0xfdb75a7e00000000, 0xdad27fff00000000, 0xade567ce00000000, + 0x8a80424f00000000, 0xa2295c1700000000, 0x854c799600000000, + 0x4c476c7500000000, 0x6b2249f400000000, 0x438b57ac00000000, + 0x64ee722d00000000, 0x13d96a1c00000000, 0x34bc4f9d00000000, + 0x1c1551c500000000, 0x3b70744400000000, 0x6af5b94d00000000, + 0x4d909ccc00000000, 0x6539829400000000, 0x425ca71500000000, + 0x356bbf2400000000, 0x120e9aa500000000, 0x3aa784fd00000000, + 0x1dc2a17c00000000, 0xd4c9b49f00000000, 0xf3ac911e00000000, + 0xdb058f4600000000, 0xfc60aac700000000, 0x8b57b2f600000000, + 0xac32977700000000, 0x849b892f00000000, 0xa3feacae00000000, + 0x578ad23200000000, 0x70eff7b300000000, 0x5846e9eb00000000, + 0x7f23cc6a00000000, 0x0814d45b00000000, 0x2f71f1da00000000, + 0x07d8ef8200000000, 0x20bdca0300000000, 0xe9b6dfe000000000, + 0xced3fa6100000000, 0xe67ae43900000000, 0xc11fc1b800000000, + 0xb628d98900000000, 0x914dfc0800000000, 0xb9e4e25000000000, + 0x9e81c7d100000000, 0x100b6fb300000000, 0x376e4a3200000000, + 0x1fc7546a00000000, 0x38a271eb00000000, 0x4f9569da00000000, + 0x68f04c5b00000000, 0x4059520300000000, 0x673c778200000000, + 0xae37626100000000, 0x895247e000000000, 0xa1fb59b800000000, + 0x869e7c3900000000, 0xf1a9640800000000, 0xd6cc418900000000, + 0xfe655fd100000000, 0xd9007a5000000000, 0x2d7404cc00000000, + 0x0a11214d00000000, 0x22b83f1500000000, 0x05dd1a9400000000, + 0x72ea02a500000000, 0x558f272400000000, 0x7d26397c00000000, + 0x5a431cfd00000000, 0x9348091e00000000, 0xb42d2c9f00000000, + 0x9c8432c700000000, 0xbbe1174600000000, 0xccd60f7700000000, + 0xebb32af600000000, 0xc31a34ae00000000, 0xe47f112f00000000, + 0xdf0f656b00000000, 0xf86a40ea00000000, 0xd0c35eb200000000, + 0xf7a67b3300000000, 0x8091630200000000, 0xa7f4468300000000, + 0x8f5d58db00000000, 0xa8387d5a00000000, 0x613368b900000000, + 0x46564d3800000000, 0x6eff536000000000, 0x499a76e100000000, + 0x3ead6ed000000000, 0x19c84b5100000000, 0x3161550900000000, + 0x1604708800000000, 0xe2700e1400000000, 0xc5152b9500000000, + 0xedbc35cd00000000, 0xcad9104c00000000, 0xbdee087d00000000, + 0x9a8b2dfc00000000, 0xb22233a400000000, 0x9547162500000000, + 0x5c4c03c600000000, 0x7b29264700000000, 0x5380381f00000000, + 0x74e51d9e00000000, 0x03d205af00000000, 0x24b7202e00000000, + 0x0c1e3e7600000000, 0x2b7b1bf700000000, 0xa5f1b39500000000, + 0x8294961400000000, 0xaa3d884c00000000, 0x8d58adcd00000000, + 0xfa6fb5fc00000000, 0xdd0a907d00000000, 0xf5a38e2500000000, + 0xd2c6aba400000000, 0x1bcdbe4700000000, 0x3ca89bc600000000, + 0x1401859e00000000, 0x3364a01f00000000, 0x4453b82e00000000, + 0x63369daf00000000, 0x4b9f83f700000000, 0x6cfaa67600000000, + 0x988ed8ea00000000, 0xbfebfd6b00000000, 0x9742e33300000000, + 0xb027c6b200000000, 0xc710de8300000000, 0xe075fb0200000000, + 0xc8dce55a00000000, 0xefb9c0db00000000, 0x26b2d53800000000, + 0x01d7f0b900000000, 0x297eeee100000000, 0x0e1bcb6000000000, + 0x792cd35100000000, 0x5e49f6d000000000, 0x76e0e88800000000, + 0x5185cd0900000000}}; + +#else /* W == 4 */ + +local const z_crc_t FAR crc_braid_table[][256] = { + {0x00000000, 0x9ba54c6f, 0xec3b9e9f, 0x779ed2f0, 0x03063b7f, + 0x98a37710, 0xef3da5e0, 0x7498e98f, 0x060c76fe, 0x9da93a91, + 0xea37e861, 0x7192a40e, 0x050a4d81, 0x9eaf01ee, 0xe931d31e, + 0x72949f71, 0x0c18edfc, 0x97bda193, 0xe0237363, 0x7b863f0c, + 0x0f1ed683, 0x94bb9aec, 0xe325481c, 0x78800473, 0x0a149b02, + 0x91b1d76d, 0xe62f059d, 0x7d8a49f2, 0x0912a07d, 0x92b7ec12, + 0xe5293ee2, 0x7e8c728d, 0x1831dbf8, 0x83949797, 0xf40a4567, + 0x6faf0908, 0x1b37e087, 0x8092ace8, 0xf70c7e18, 0x6ca93277, + 0x1e3dad06, 0x8598e169, 0xf2063399, 0x69a37ff6, 0x1d3b9679, + 0x869eda16, 0xf10008e6, 0x6aa54489, 0x14293604, 0x8f8c7a6b, + 0xf812a89b, 0x63b7e4f4, 0x172f0d7b, 0x8c8a4114, 0xfb1493e4, + 0x60b1df8b, 0x122540fa, 0x89800c95, 0xfe1ede65, 0x65bb920a, + 0x11237b85, 0x8a8637ea, 0xfd18e51a, 0x66bda975, 0x3063b7f0, + 0xabc6fb9f, 0xdc58296f, 0x47fd6500, 0x33658c8f, 0xa8c0c0e0, + 0xdf5e1210, 0x44fb5e7f, 0x366fc10e, 0xadca8d61, 0xda545f91, + 0x41f113fe, 0x3569fa71, 0xaeccb61e, 0xd95264ee, 0x42f72881, + 0x3c7b5a0c, 0xa7de1663, 0xd040c493, 0x4be588fc, 0x3f7d6173, + 0xa4d82d1c, 0xd346ffec, 0x48e3b383, 0x3a772cf2, 0xa1d2609d, + 0xd64cb26d, 0x4de9fe02, 0x3971178d, 0xa2d45be2, 0xd54a8912, + 0x4eefc57d, 0x28526c08, 0xb3f72067, 0xc469f297, 0x5fccbef8, + 0x2b545777, 0xb0f11b18, 0xc76fc9e8, 0x5cca8587, 0x2e5e1af6, + 0xb5fb5699, 0xc2658469, 0x59c0c806, 0x2d582189, 0xb6fd6de6, + 0xc163bf16, 0x5ac6f379, 0x244a81f4, 0xbfefcd9b, 0xc8711f6b, + 0x53d45304, 0x274cba8b, 0xbce9f6e4, 0xcb772414, 0x50d2687b, + 0x2246f70a, 0xb9e3bb65, 0xce7d6995, 0x55d825fa, 0x2140cc75, + 0xbae5801a, 0xcd7b52ea, 0x56de1e85, 0x60c76fe0, 0xfb62238f, + 0x8cfcf17f, 0x1759bd10, 0x63c1549f, 0xf86418f0, 0x8ffaca00, + 0x145f866f, 0x66cb191e, 0xfd6e5571, 0x8af08781, 0x1155cbee, + 0x65cd2261, 0xfe686e0e, 0x89f6bcfe, 0x1253f091, 0x6cdf821c, + 0xf77ace73, 0x80e41c83, 0x1b4150ec, 0x6fd9b963, 0xf47cf50c, + 0x83e227fc, 0x18476b93, 0x6ad3f4e2, 0xf176b88d, 0x86e86a7d, + 0x1d4d2612, 0x69d5cf9d, 0xf27083f2, 0x85ee5102, 0x1e4b1d6d, + 0x78f6b418, 0xe353f877, 0x94cd2a87, 0x0f6866e8, 0x7bf08f67, + 0xe055c308, 0x97cb11f8, 0x0c6e5d97, 0x7efac2e6, 0xe55f8e89, + 0x92c15c79, 0x09641016, 0x7dfcf999, 0xe659b5f6, 0x91c76706, + 0x0a622b69, 0x74ee59e4, 0xef4b158b, 0x98d5c77b, 0x03708b14, + 0x77e8629b, 0xec4d2ef4, 0x9bd3fc04, 0x0076b06b, 0x72e22f1a, + 0xe9476375, 0x9ed9b185, 0x057cfdea, 0x71e41465, 0xea41580a, + 0x9ddf8afa, 0x067ac695, 0x50a4d810, 0xcb01947f, 0xbc9f468f, + 0x273a0ae0, 0x53a2e36f, 0xc807af00, 0xbf997df0, 0x243c319f, + 0x56a8aeee, 0xcd0de281, 0xba933071, 0x21367c1e, 0x55ae9591, + 0xce0bd9fe, 0xb9950b0e, 0x22304761, 0x5cbc35ec, 0xc7197983, + 0xb087ab73, 0x2b22e71c, 0x5fba0e93, 0xc41f42fc, 0xb381900c, + 0x2824dc63, 0x5ab04312, 0xc1150f7d, 0xb68bdd8d, 0x2d2e91e2, + 0x59b6786d, 0xc2133402, 0xb58de6f2, 0x2e28aa9d, 0x489503e8, + 0xd3304f87, 0xa4ae9d77, 0x3f0bd118, 0x4b933897, 0xd03674f8, + 0xa7a8a608, 0x3c0dea67, 0x4e997516, 0xd53c3979, 0xa2a2eb89, + 0x3907a7e6, 0x4d9f4e69, 0xd63a0206, 0xa1a4d0f6, 0x3a019c99, + 0x448dee14, 0xdf28a27b, 0xa8b6708b, 0x33133ce4, 0x478bd56b, + 0xdc2e9904, 0xabb04bf4, 0x3015079b, 0x428198ea, 0xd924d485, + 0xaeba0675, 0x351f4a1a, 0x4187a395, 0xda22effa, 0xadbc3d0a, + 0x36197165}, + {0x00000000, 0xc18edfc0, 0x586cb9c1, 0x99e26601, 0xb0d97382, + 0x7157ac42, 0xe8b5ca43, 0x293b1583, 0xbac3e145, 0x7b4d3e85, + 0xe2af5884, 0x23218744, 0x0a1a92c7, 0xcb944d07, 0x52762b06, + 0x93f8f4c6, 0xaef6c4cb, 0x6f781b0b, 0xf69a7d0a, 0x3714a2ca, + 0x1e2fb749, 0xdfa16889, 0x46430e88, 0x87cdd148, 0x1435258e, + 0xd5bbfa4e, 0x4c599c4f, 0x8dd7438f, 0xa4ec560c, 0x656289cc, + 0xfc80efcd, 0x3d0e300d, 0x869c8fd7, 0x47125017, 0xdef03616, + 0x1f7ee9d6, 0x3645fc55, 0xf7cb2395, 0x6e294594, 0xafa79a54, + 0x3c5f6e92, 0xfdd1b152, 0x6433d753, 0xa5bd0893, 0x8c861d10, + 0x4d08c2d0, 0xd4eaa4d1, 0x15647b11, 0x286a4b1c, 0xe9e494dc, + 0x7006f2dd, 0xb1882d1d, 0x98b3389e, 0x593de75e, 0xc0df815f, + 0x01515e9f, 0x92a9aa59, 0x53277599, 0xcac51398, 0x0b4bcc58, + 0x2270d9db, 0xe3fe061b, 0x7a1c601a, 0xbb92bfda, 0xd64819ef, + 0x17c6c62f, 0x8e24a02e, 0x4faa7fee, 0x66916a6d, 0xa71fb5ad, + 0x3efdd3ac, 0xff730c6c, 0x6c8bf8aa, 0xad05276a, 0x34e7416b, + 0xf5699eab, 0xdc528b28, 0x1ddc54e8, 0x843e32e9, 0x45b0ed29, + 0x78bedd24, 0xb93002e4, 0x20d264e5, 0xe15cbb25, 0xc867aea6, + 0x09e97166, 0x900b1767, 0x5185c8a7, 0xc27d3c61, 0x03f3e3a1, + 0x9a1185a0, 0x5b9f5a60, 0x72a44fe3, 0xb32a9023, 0x2ac8f622, + 0xeb4629e2, 0x50d49638, 0x915a49f8, 0x08b82ff9, 0xc936f039, + 0xe00de5ba, 0x21833a7a, 0xb8615c7b, 0x79ef83bb, 0xea17777d, + 0x2b99a8bd, 0xb27bcebc, 0x73f5117c, 0x5ace04ff, 0x9b40db3f, + 0x02a2bd3e, 0xc32c62fe, 0xfe2252f3, 0x3fac8d33, 0xa64eeb32, + 0x67c034f2, 0x4efb2171, 0x8f75feb1, 0x169798b0, 0xd7194770, + 0x44e1b3b6, 0x856f6c76, 0x1c8d0a77, 0xdd03d5b7, 0xf438c034, + 0x35b61ff4, 0xac5479f5, 0x6ddaa635, 0x77e1359f, 0xb66fea5f, + 0x2f8d8c5e, 0xee03539e, 0xc738461d, 0x06b699dd, 0x9f54ffdc, + 0x5eda201c, 0xcd22d4da, 0x0cac0b1a, 0x954e6d1b, 0x54c0b2db, + 0x7dfba758, 0xbc757898, 0x25971e99, 0xe419c159, 0xd917f154, + 0x18992e94, 0x817b4895, 0x40f59755, 0x69ce82d6, 0xa8405d16, + 0x31a23b17, 0xf02ce4d7, 0x63d41011, 0xa25acfd1, 0x3bb8a9d0, + 0xfa367610, 0xd30d6393, 0x1283bc53, 0x8b61da52, 0x4aef0592, + 0xf17dba48, 0x30f36588, 0xa9110389, 0x689fdc49, 0x41a4c9ca, + 0x802a160a, 0x19c8700b, 0xd846afcb, 0x4bbe5b0d, 0x8a3084cd, + 0x13d2e2cc, 0xd25c3d0c, 0xfb67288f, 0x3ae9f74f, 0xa30b914e, + 0x62854e8e, 0x5f8b7e83, 0x9e05a143, 0x07e7c742, 0xc6691882, + 0xef520d01, 0x2edcd2c1, 0xb73eb4c0, 0x76b06b00, 0xe5489fc6, + 0x24c64006, 0xbd242607, 0x7caaf9c7, 0x5591ec44, 0x941f3384, + 0x0dfd5585, 0xcc738a45, 0xa1a92c70, 0x6027f3b0, 0xf9c595b1, + 0x384b4a71, 0x11705ff2, 0xd0fe8032, 0x491ce633, 0x889239f3, + 0x1b6acd35, 0xdae412f5, 0x430674f4, 0x8288ab34, 0xabb3beb7, + 0x6a3d6177, 0xf3df0776, 0x3251d8b6, 0x0f5fe8bb, 0xced1377b, + 0x5733517a, 0x96bd8eba, 0xbf869b39, 0x7e0844f9, 0xe7ea22f8, + 0x2664fd38, 0xb59c09fe, 0x7412d63e, 0xedf0b03f, 0x2c7e6fff, + 0x05457a7c, 0xc4cba5bc, 0x5d29c3bd, 0x9ca71c7d, 0x2735a3a7, + 0xe6bb7c67, 0x7f591a66, 0xbed7c5a6, 0x97ecd025, 0x56620fe5, + 0xcf8069e4, 0x0e0eb624, 0x9df642e2, 0x5c789d22, 0xc59afb23, + 0x041424e3, 0x2d2f3160, 0xeca1eea0, 0x754388a1, 0xb4cd5761, + 0x89c3676c, 0x484db8ac, 0xd1afdead, 0x1021016d, 0x391a14ee, + 0xf894cb2e, 0x6176ad2f, 0xa0f872ef, 0x33008629, 0xf28e59e9, + 0x6b6c3fe8, 0xaae2e028, 0x83d9f5ab, 0x42572a6b, 0xdbb54c6a, + 0x1a3b93aa}, + {0x00000000, 0xefc26b3e, 0x04f5d03d, 0xeb37bb03, 0x09eba07a, + 0xe629cb44, 0x0d1e7047, 0xe2dc1b79, 0x13d740f4, 0xfc152bca, + 0x172290c9, 0xf8e0fbf7, 0x1a3ce08e, 0xf5fe8bb0, 0x1ec930b3, + 0xf10b5b8d, 0x27ae81e8, 0xc86cead6, 0x235b51d5, 0xcc993aeb, + 0x2e452192, 0xc1874aac, 0x2ab0f1af, 0xc5729a91, 0x3479c11c, + 0xdbbbaa22, 0x308c1121, 0xdf4e7a1f, 0x3d926166, 0xd2500a58, + 0x3967b15b, 0xd6a5da65, 0x4f5d03d0, 0xa09f68ee, 0x4ba8d3ed, + 0xa46ab8d3, 0x46b6a3aa, 0xa974c894, 0x42437397, 0xad8118a9, + 0x5c8a4324, 0xb348281a, 0x587f9319, 0xb7bdf827, 0x5561e35e, + 0xbaa38860, 0x51943363, 0xbe56585d, 0x68f38238, 0x8731e906, + 0x6c065205, 0x83c4393b, 0x61182242, 0x8eda497c, 0x65edf27f, + 0x8a2f9941, 0x7b24c2cc, 0x94e6a9f2, 0x7fd112f1, 0x901379cf, + 0x72cf62b6, 0x9d0d0988, 0x763ab28b, 0x99f8d9b5, 0x9eba07a0, + 0x71786c9e, 0x9a4fd79d, 0x758dbca3, 0x9751a7da, 0x7893cce4, + 0x93a477e7, 0x7c661cd9, 0x8d6d4754, 0x62af2c6a, 0x89989769, + 0x665afc57, 0x8486e72e, 0x6b448c10, 0x80733713, 0x6fb15c2d, + 0xb9148648, 0x56d6ed76, 0xbde15675, 0x52233d4b, 0xb0ff2632, + 0x5f3d4d0c, 0xb40af60f, 0x5bc89d31, 0xaac3c6bc, 0x4501ad82, + 0xae361681, 0x41f47dbf, 0xa32866c6, 0x4cea0df8, 0xa7ddb6fb, + 0x481fddc5, 0xd1e70470, 0x3e256f4e, 0xd512d44d, 0x3ad0bf73, + 0xd80ca40a, 0x37cecf34, 0xdcf97437, 0x333b1f09, 0xc2304484, + 0x2df22fba, 0xc6c594b9, 0x2907ff87, 0xcbdbe4fe, 0x24198fc0, + 0xcf2e34c3, 0x20ec5ffd, 0xf6498598, 0x198beea6, 0xf2bc55a5, + 0x1d7e3e9b, 0xffa225e2, 0x10604edc, 0xfb57f5df, 0x14959ee1, + 0xe59ec56c, 0x0a5cae52, 0xe16b1551, 0x0ea97e6f, 0xec756516, + 0x03b70e28, 0xe880b52b, 0x0742de15, 0xe6050901, 0x09c7623f, + 0xe2f0d93c, 0x0d32b202, 0xefeea97b, 0x002cc245, 0xeb1b7946, + 0x04d91278, 0xf5d249f5, 0x1a1022cb, 0xf12799c8, 0x1ee5f2f6, + 0xfc39e98f, 0x13fb82b1, 0xf8cc39b2, 0x170e528c, 0xc1ab88e9, + 0x2e69e3d7, 0xc55e58d4, 0x2a9c33ea, 0xc8402893, 0x278243ad, + 0xccb5f8ae, 0x23779390, 0xd27cc81d, 0x3dbea323, 0xd6891820, + 0x394b731e, 0xdb976867, 0x34550359, 0xdf62b85a, 0x30a0d364, + 0xa9580ad1, 0x469a61ef, 0xadaddaec, 0x426fb1d2, 0xa0b3aaab, + 0x4f71c195, 0xa4467a96, 0x4b8411a8, 0xba8f4a25, 0x554d211b, + 0xbe7a9a18, 0x51b8f126, 0xb364ea5f, 0x5ca68161, 0xb7913a62, + 0x5853515c, 0x8ef68b39, 0x6134e007, 0x8a035b04, 0x65c1303a, + 0x871d2b43, 0x68df407d, 0x83e8fb7e, 0x6c2a9040, 0x9d21cbcd, + 0x72e3a0f3, 0x99d41bf0, 0x761670ce, 0x94ca6bb7, 0x7b080089, + 0x903fbb8a, 0x7ffdd0b4, 0x78bf0ea1, 0x977d659f, 0x7c4ade9c, + 0x9388b5a2, 0x7154aedb, 0x9e96c5e5, 0x75a17ee6, 0x9a6315d8, + 0x6b684e55, 0x84aa256b, 0x6f9d9e68, 0x805ff556, 0x6283ee2f, + 0x8d418511, 0x66763e12, 0x89b4552c, 0x5f118f49, 0xb0d3e477, + 0x5be45f74, 0xb426344a, 0x56fa2f33, 0xb938440d, 0x520fff0e, + 0xbdcd9430, 0x4cc6cfbd, 0xa304a483, 0x48331f80, 0xa7f174be, + 0x452d6fc7, 0xaaef04f9, 0x41d8bffa, 0xae1ad4c4, 0x37e20d71, + 0xd820664f, 0x3317dd4c, 0xdcd5b672, 0x3e09ad0b, 0xd1cbc635, + 0x3afc7d36, 0xd53e1608, 0x24354d85, 0xcbf726bb, 0x20c09db8, + 0xcf02f686, 0x2ddeedff, 0xc21c86c1, 0x292b3dc2, 0xc6e956fc, + 0x104c8c99, 0xff8ee7a7, 0x14b95ca4, 0xfb7b379a, 0x19a72ce3, + 0xf66547dd, 0x1d52fcde, 0xf29097e0, 0x039bcc6d, 0xec59a753, + 0x076e1c50, 0xe8ac776e, 0x0a706c17, 0xe5b20729, 0x0e85bc2a, + 0xe147d714}, + {0x00000000, 0x177b1443, 0x2ef62886, 0x398d3cc5, 0x5dec510c, + 0x4a97454f, 0x731a798a, 0x64616dc9, 0xbbd8a218, 0xaca3b65b, + 0x952e8a9e, 0x82559edd, 0xe634f314, 0xf14fe757, 0xc8c2db92, + 0xdfb9cfd1, 0xacc04271, 0xbbbb5632, 0x82366af7, 0x954d7eb4, + 0xf12c137d, 0xe657073e, 0xdfda3bfb, 0xc8a12fb8, 0x1718e069, + 0x0063f42a, 0x39eec8ef, 0x2e95dcac, 0x4af4b165, 0x5d8fa526, + 0x640299e3, 0x73798da0, 0x82f182a3, 0x958a96e0, 0xac07aa25, + 0xbb7cbe66, 0xdf1dd3af, 0xc866c7ec, 0xf1ebfb29, 0xe690ef6a, + 0x392920bb, 0x2e5234f8, 0x17df083d, 0x00a41c7e, 0x64c571b7, + 0x73be65f4, 0x4a335931, 0x5d484d72, 0x2e31c0d2, 0x394ad491, + 0x00c7e854, 0x17bcfc17, 0x73dd91de, 0x64a6859d, 0x5d2bb958, + 0x4a50ad1b, 0x95e962ca, 0x82927689, 0xbb1f4a4c, 0xac645e0f, + 0xc80533c6, 0xdf7e2785, 0xe6f31b40, 0xf1880f03, 0xde920307, + 0xc9e91744, 0xf0642b81, 0xe71f3fc2, 0x837e520b, 0x94054648, + 0xad887a8d, 0xbaf36ece, 0x654aa11f, 0x7231b55c, 0x4bbc8999, + 0x5cc79dda, 0x38a6f013, 0x2fdde450, 0x1650d895, 0x012bccd6, + 0x72524176, 0x65295535, 0x5ca469f0, 0x4bdf7db3, 0x2fbe107a, + 0x38c50439, 0x014838fc, 0x16332cbf, 0xc98ae36e, 0xdef1f72d, + 0xe77ccbe8, 0xf007dfab, 0x9466b262, 0x831da621, 0xba909ae4, + 0xadeb8ea7, 0x5c6381a4, 0x4b1895e7, 0x7295a922, 0x65eebd61, + 0x018fd0a8, 0x16f4c4eb, 0x2f79f82e, 0x3802ec6d, 0xe7bb23bc, + 0xf0c037ff, 0xc94d0b3a, 0xde361f79, 0xba5772b0, 0xad2c66f3, + 0x94a15a36, 0x83da4e75, 0xf0a3c3d5, 0xe7d8d796, 0xde55eb53, + 0xc92eff10, 0xad4f92d9, 0xba34869a, 0x83b9ba5f, 0x94c2ae1c, + 0x4b7b61cd, 0x5c00758e, 0x658d494b, 0x72f65d08, 0x169730c1, + 0x01ec2482, 0x38611847, 0x2f1a0c04, 0x6655004f, 0x712e140c, + 0x48a328c9, 0x5fd83c8a, 0x3bb95143, 0x2cc24500, 0x154f79c5, + 0x02346d86, 0xdd8da257, 0xcaf6b614, 0xf37b8ad1, 0xe4009e92, + 0x8061f35b, 0x971ae718, 0xae97dbdd, 0xb9eccf9e, 0xca95423e, + 0xddee567d, 0xe4636ab8, 0xf3187efb, 0x97791332, 0x80020771, + 0xb98f3bb4, 0xaef42ff7, 0x714de026, 0x6636f465, 0x5fbbc8a0, + 0x48c0dce3, 0x2ca1b12a, 0x3bdaa569, 0x025799ac, 0x152c8def, + 0xe4a482ec, 0xf3df96af, 0xca52aa6a, 0xdd29be29, 0xb948d3e0, + 0xae33c7a3, 0x97befb66, 0x80c5ef25, 0x5f7c20f4, 0x480734b7, + 0x718a0872, 0x66f11c31, 0x029071f8, 0x15eb65bb, 0x2c66597e, + 0x3b1d4d3d, 0x4864c09d, 0x5f1fd4de, 0x6692e81b, 0x71e9fc58, + 0x15889191, 0x02f385d2, 0x3b7eb917, 0x2c05ad54, 0xf3bc6285, + 0xe4c776c6, 0xdd4a4a03, 0xca315e40, 0xae503389, 0xb92b27ca, + 0x80a61b0f, 0x97dd0f4c, 0xb8c70348, 0xafbc170b, 0x96312bce, + 0x814a3f8d, 0xe52b5244, 0xf2504607, 0xcbdd7ac2, 0xdca66e81, + 0x031fa150, 0x1464b513, 0x2de989d6, 0x3a929d95, 0x5ef3f05c, + 0x4988e41f, 0x7005d8da, 0x677ecc99, 0x14074139, 0x037c557a, + 0x3af169bf, 0x2d8a7dfc, 0x49eb1035, 0x5e900476, 0x671d38b3, + 0x70662cf0, 0xafdfe321, 0xb8a4f762, 0x8129cba7, 0x9652dfe4, + 0xf233b22d, 0xe548a66e, 0xdcc59aab, 0xcbbe8ee8, 0x3a3681eb, + 0x2d4d95a8, 0x14c0a96d, 0x03bbbd2e, 0x67dad0e7, 0x70a1c4a4, + 0x492cf861, 0x5e57ec22, 0x81ee23f3, 0x969537b0, 0xaf180b75, + 0xb8631f36, 0xdc0272ff, 0xcb7966bc, 0xf2f45a79, 0xe58f4e3a, + 0x96f6c39a, 0x818dd7d9, 0xb800eb1c, 0xaf7bff5f, 0xcb1a9296, + 0xdc6186d5, 0xe5ecba10, 0xf297ae53, 0x2d2e6182, 0x3a5575c1, + 0x03d84904, 0x14a35d47, 0x70c2308e, 0x67b924cd, 0x5e341808, + 0x494f0c4b}}; + +local const z_word_t FAR crc_braid_big_table[][256] = { + {0x00000000, 0x43147b17, 0x8628f62e, 0xc53c8d39, 0x0c51ec5d, + 0x4f45974a, 0x8a791a73, 0xc96d6164, 0x18a2d8bb, 0x5bb6a3ac, + 0x9e8a2e95, 0xdd9e5582, 0x14f334e6, 0x57e74ff1, 0x92dbc2c8, + 0xd1cfb9df, 0x7142c0ac, 0x3256bbbb, 0xf76a3682, 0xb47e4d95, + 0x7d132cf1, 0x3e0757e6, 0xfb3bdadf, 0xb82fa1c8, 0x69e01817, + 0x2af46300, 0xefc8ee39, 0xacdc952e, 0x65b1f44a, 0x26a58f5d, + 0xe3990264, 0xa08d7973, 0xa382f182, 0xe0968a95, 0x25aa07ac, + 0x66be7cbb, 0xafd31ddf, 0xecc766c8, 0x29fbebf1, 0x6aef90e6, + 0xbb202939, 0xf834522e, 0x3d08df17, 0x7e1ca400, 0xb771c564, + 0xf465be73, 0x3159334a, 0x724d485d, 0xd2c0312e, 0x91d44a39, + 0x54e8c700, 0x17fcbc17, 0xde91dd73, 0x9d85a664, 0x58b92b5d, + 0x1bad504a, 0xca62e995, 0x89769282, 0x4c4a1fbb, 0x0f5e64ac, + 0xc63305c8, 0x85277edf, 0x401bf3e6, 0x030f88f1, 0x070392de, + 0x4417e9c9, 0x812b64f0, 0xc23f1fe7, 0x0b527e83, 0x48460594, + 0x8d7a88ad, 0xce6ef3ba, 0x1fa14a65, 0x5cb53172, 0x9989bc4b, + 0xda9dc75c, 0x13f0a638, 0x50e4dd2f, 0x95d85016, 0xd6cc2b01, + 0x76415272, 0x35552965, 0xf069a45c, 0xb37ddf4b, 0x7a10be2f, + 0x3904c538, 0xfc384801, 0xbf2c3316, 0x6ee38ac9, 0x2df7f1de, + 0xe8cb7ce7, 0xabdf07f0, 0x62b26694, 0x21a61d83, 0xe49a90ba, + 0xa78eebad, 0xa481635c, 0xe795184b, 0x22a99572, 0x61bdee65, + 0xa8d08f01, 0xebc4f416, 0x2ef8792f, 0x6dec0238, 0xbc23bbe7, + 0xff37c0f0, 0x3a0b4dc9, 0x791f36de, 0xb07257ba, 0xf3662cad, + 0x365aa194, 0x754eda83, 0xd5c3a3f0, 0x96d7d8e7, 0x53eb55de, + 0x10ff2ec9, 0xd9924fad, 0x9a8634ba, 0x5fbab983, 0x1caec294, + 0xcd617b4b, 0x8e75005c, 0x4b498d65, 0x085df672, 0xc1309716, + 0x8224ec01, 0x47186138, 0x040c1a2f, 0x4f005566, 0x0c142e71, + 0xc928a348, 0x8a3cd85f, 0x4351b93b, 0x0045c22c, 0xc5794f15, + 0x866d3402, 0x57a28ddd, 0x14b6f6ca, 0xd18a7bf3, 0x929e00e4, + 0x5bf36180, 0x18e71a97, 0xdddb97ae, 0x9ecfecb9, 0x3e4295ca, + 0x7d56eedd, 0xb86a63e4, 0xfb7e18f3, 0x32137997, 0x71070280, + 0xb43b8fb9, 0xf72ff4ae, 0x26e04d71, 0x65f43666, 0xa0c8bb5f, + 0xe3dcc048, 0x2ab1a12c, 0x69a5da3b, 0xac995702, 0xef8d2c15, + 0xec82a4e4, 0xaf96dff3, 0x6aaa52ca, 0x29be29dd, 0xe0d348b9, + 0xa3c733ae, 0x66fbbe97, 0x25efc580, 0xf4207c5f, 0xb7340748, + 0x72088a71, 0x311cf166, 0xf8719002, 0xbb65eb15, 0x7e59662c, + 0x3d4d1d3b, 0x9dc06448, 0xded41f5f, 0x1be89266, 0x58fce971, + 0x91918815, 0xd285f302, 0x17b97e3b, 0x54ad052c, 0x8562bcf3, + 0xc676c7e4, 0x034a4add, 0x405e31ca, 0x893350ae, 0xca272bb9, + 0x0f1ba680, 0x4c0fdd97, 0x4803c7b8, 0x0b17bcaf, 0xce2b3196, + 0x8d3f4a81, 0x44522be5, 0x074650f2, 0xc27addcb, 0x816ea6dc, + 0x50a11f03, 0x13b56414, 0xd689e92d, 0x959d923a, 0x5cf0f35e, + 0x1fe48849, 0xdad80570, 0x99cc7e67, 0x39410714, 0x7a557c03, + 0xbf69f13a, 0xfc7d8a2d, 0x3510eb49, 0x7604905e, 0xb3381d67, + 0xf02c6670, 0x21e3dfaf, 0x62f7a4b8, 0xa7cb2981, 0xe4df5296, + 0x2db233f2, 0x6ea648e5, 0xab9ac5dc, 0xe88ebecb, 0xeb81363a, + 0xa8954d2d, 0x6da9c014, 0x2ebdbb03, 0xe7d0da67, 0xa4c4a170, + 0x61f82c49, 0x22ec575e, 0xf323ee81, 0xb0379596, 0x750b18af, + 0x361f63b8, 0xff7202dc, 0xbc6679cb, 0x795af4f2, 0x3a4e8fe5, + 0x9ac3f696, 0xd9d78d81, 0x1ceb00b8, 0x5fff7baf, 0x96921acb, + 0xd58661dc, 0x10baece5, 0x53ae97f2, 0x82612e2d, 0xc175553a, + 0x0449d803, 0x475da314, 0x8e30c270, 0xcd24b967, 0x0818345e, + 0x4b0c4f49}, + {0x00000000, 0x3e6bc2ef, 0x3dd0f504, 0x03bb37eb, 0x7aa0eb09, + 0x44cb29e6, 0x47701e0d, 0x791bdce2, 0xf440d713, 0xca2b15fc, + 0xc9902217, 0xf7fbe0f8, 0x8ee03c1a, 0xb08bfef5, 0xb330c91e, + 0x8d5b0bf1, 0xe881ae27, 0xd6ea6cc8, 0xd5515b23, 0xeb3a99cc, + 0x9221452e, 0xac4a87c1, 0xaff1b02a, 0x919a72c5, 0x1cc17934, + 0x22aabbdb, 0x21118c30, 0x1f7a4edf, 0x6661923d, 0x580a50d2, + 0x5bb16739, 0x65daa5d6, 0xd0035d4f, 0xee689fa0, 0xedd3a84b, + 0xd3b86aa4, 0xaaa3b646, 0x94c874a9, 0x97734342, 0xa91881ad, + 0x24438a5c, 0x1a2848b3, 0x19937f58, 0x27f8bdb7, 0x5ee36155, + 0x6088a3ba, 0x63339451, 0x5d5856be, 0x3882f368, 0x06e93187, + 0x0552066c, 0x3b39c483, 0x42221861, 0x7c49da8e, 0x7ff2ed65, + 0x41992f8a, 0xccc2247b, 0xf2a9e694, 0xf112d17f, 0xcf791390, + 0xb662cf72, 0x88090d9d, 0x8bb23a76, 0xb5d9f899, 0xa007ba9e, + 0x9e6c7871, 0x9dd74f9a, 0xa3bc8d75, 0xdaa75197, 0xe4cc9378, + 0xe777a493, 0xd91c667c, 0x54476d8d, 0x6a2caf62, 0x69979889, + 0x57fc5a66, 0x2ee78684, 0x108c446b, 0x13377380, 0x2d5cb16f, + 0x488614b9, 0x76edd656, 0x7556e1bd, 0x4b3d2352, 0x3226ffb0, + 0x0c4d3d5f, 0x0ff60ab4, 0x319dc85b, 0xbcc6c3aa, 0x82ad0145, + 0x811636ae, 0xbf7df441, 0xc66628a3, 0xf80dea4c, 0xfbb6dda7, + 0xc5dd1f48, 0x7004e7d1, 0x4e6f253e, 0x4dd412d5, 0x73bfd03a, + 0x0aa40cd8, 0x34cfce37, 0x3774f9dc, 0x091f3b33, 0x844430c2, + 0xba2ff22d, 0xb994c5c6, 0x87ff0729, 0xfee4dbcb, 0xc08f1924, + 0xc3342ecf, 0xfd5fec20, 0x988549f6, 0xa6ee8b19, 0xa555bcf2, + 0x9b3e7e1d, 0xe225a2ff, 0xdc4e6010, 0xdff557fb, 0xe19e9514, + 0x6cc59ee5, 0x52ae5c0a, 0x51156be1, 0x6f7ea90e, 0x166575ec, + 0x280eb703, 0x2bb580e8, 0x15de4207, 0x010905e6, 0x3f62c709, + 0x3cd9f0e2, 0x02b2320d, 0x7ba9eeef, 0x45c22c00, 0x46791beb, + 0x7812d904, 0xf549d2f5, 0xcb22101a, 0xc89927f1, 0xf6f2e51e, + 0x8fe939fc, 0xb182fb13, 0xb239ccf8, 0x8c520e17, 0xe988abc1, + 0xd7e3692e, 0xd4585ec5, 0xea339c2a, 0x932840c8, 0xad438227, + 0xaef8b5cc, 0x90937723, 0x1dc87cd2, 0x23a3be3d, 0x201889d6, + 0x1e734b39, 0x676897db, 0x59035534, 0x5ab862df, 0x64d3a030, + 0xd10a58a9, 0xef619a46, 0xecdaadad, 0xd2b16f42, 0xabaab3a0, + 0x95c1714f, 0x967a46a4, 0xa811844b, 0x254a8fba, 0x1b214d55, + 0x189a7abe, 0x26f1b851, 0x5fea64b3, 0x6181a65c, 0x623a91b7, + 0x5c515358, 0x398bf68e, 0x07e03461, 0x045b038a, 0x3a30c165, + 0x432b1d87, 0x7d40df68, 0x7efbe883, 0x40902a6c, 0xcdcb219d, + 0xf3a0e372, 0xf01bd499, 0xce701676, 0xb76bca94, 0x8900087b, + 0x8abb3f90, 0xb4d0fd7f, 0xa10ebf78, 0x9f657d97, 0x9cde4a7c, + 0xa2b58893, 0xdbae5471, 0xe5c5969e, 0xe67ea175, 0xd815639a, + 0x554e686b, 0x6b25aa84, 0x689e9d6f, 0x56f55f80, 0x2fee8362, + 0x1185418d, 0x123e7666, 0x2c55b489, 0x498f115f, 0x77e4d3b0, + 0x745fe45b, 0x4a3426b4, 0x332ffa56, 0x0d4438b9, 0x0eff0f52, + 0x3094cdbd, 0xbdcfc64c, 0x83a404a3, 0x801f3348, 0xbe74f1a7, + 0xc76f2d45, 0xf904efaa, 0xfabfd841, 0xc4d41aae, 0x710de237, + 0x4f6620d8, 0x4cdd1733, 0x72b6d5dc, 0x0bad093e, 0x35c6cbd1, + 0x367dfc3a, 0x08163ed5, 0x854d3524, 0xbb26f7cb, 0xb89dc020, + 0x86f602cf, 0xffedde2d, 0xc1861cc2, 0xc23d2b29, 0xfc56e9c6, + 0x998c4c10, 0xa7e78eff, 0xa45cb914, 0x9a377bfb, 0xe32ca719, + 0xdd4765f6, 0xdefc521d, 0xe09790f2, 0x6dcc9b03, 0x53a759ec, + 0x501c6e07, 0x6e77ace8, 0x176c700a, 0x2907b2e5, 0x2abc850e, + 0x14d747e1}, + {0x00000000, 0xc0df8ec1, 0xc1b96c58, 0x0166e299, 0x8273d9b0, + 0x42ac5771, 0x43cab5e8, 0x83153b29, 0x45e1c3ba, 0x853e4d7b, + 0x8458afe2, 0x44872123, 0xc7921a0a, 0x074d94cb, 0x062b7652, + 0xc6f4f893, 0xcbc4f6ae, 0x0b1b786f, 0x0a7d9af6, 0xcaa21437, + 0x49b72f1e, 0x8968a1df, 0x880e4346, 0x48d1cd87, 0x8e253514, + 0x4efabbd5, 0x4f9c594c, 0x8f43d78d, 0x0c56eca4, 0xcc896265, + 0xcdef80fc, 0x0d300e3d, 0xd78f9c86, 0x17501247, 0x1636f0de, + 0xd6e97e1f, 0x55fc4536, 0x9523cbf7, 0x9445296e, 0x549aa7af, + 0x926e5f3c, 0x52b1d1fd, 0x53d73364, 0x9308bda5, 0x101d868c, + 0xd0c2084d, 0xd1a4ead4, 0x117b6415, 0x1c4b6a28, 0xdc94e4e9, + 0xddf20670, 0x1d2d88b1, 0x9e38b398, 0x5ee73d59, 0x5f81dfc0, + 0x9f5e5101, 0x59aaa992, 0x99752753, 0x9813c5ca, 0x58cc4b0b, + 0xdbd97022, 0x1b06fee3, 0x1a601c7a, 0xdabf92bb, 0xef1948d6, + 0x2fc6c617, 0x2ea0248e, 0xee7faa4f, 0x6d6a9166, 0xadb51fa7, + 0xacd3fd3e, 0x6c0c73ff, 0xaaf88b6c, 0x6a2705ad, 0x6b41e734, + 0xab9e69f5, 0x288b52dc, 0xe854dc1d, 0xe9323e84, 0x29edb045, + 0x24ddbe78, 0xe40230b9, 0xe564d220, 0x25bb5ce1, 0xa6ae67c8, + 0x6671e909, 0x67170b90, 0xa7c88551, 0x613c7dc2, 0xa1e3f303, + 0xa085119a, 0x605a9f5b, 0xe34fa472, 0x23902ab3, 0x22f6c82a, + 0xe22946eb, 0x3896d450, 0xf8495a91, 0xf92fb808, 0x39f036c9, + 0xbae50de0, 0x7a3a8321, 0x7b5c61b8, 0xbb83ef79, 0x7d7717ea, + 0xbda8992b, 0xbcce7bb2, 0x7c11f573, 0xff04ce5a, 0x3fdb409b, + 0x3ebda202, 0xfe622cc3, 0xf35222fe, 0x338dac3f, 0x32eb4ea6, + 0xf234c067, 0x7121fb4e, 0xb1fe758f, 0xb0989716, 0x704719d7, + 0xb6b3e144, 0x766c6f85, 0x770a8d1c, 0xb7d503dd, 0x34c038f4, + 0xf41fb635, 0xf57954ac, 0x35a6da6d, 0x9f35e177, 0x5fea6fb6, + 0x5e8c8d2f, 0x9e5303ee, 0x1d4638c7, 0xdd99b606, 0xdcff549f, + 0x1c20da5e, 0xdad422cd, 0x1a0bac0c, 0x1b6d4e95, 0xdbb2c054, + 0x58a7fb7d, 0x987875bc, 0x991e9725, 0x59c119e4, 0x54f117d9, + 0x942e9918, 0x95487b81, 0x5597f540, 0xd682ce69, 0x165d40a8, + 0x173ba231, 0xd7e42cf0, 0x1110d463, 0xd1cf5aa2, 0xd0a9b83b, + 0x107636fa, 0x93630dd3, 0x53bc8312, 0x52da618b, 0x9205ef4a, + 0x48ba7df1, 0x8865f330, 0x890311a9, 0x49dc9f68, 0xcac9a441, + 0x0a162a80, 0x0b70c819, 0xcbaf46d8, 0x0d5bbe4b, 0xcd84308a, + 0xcce2d213, 0x0c3d5cd2, 0x8f2867fb, 0x4ff7e93a, 0x4e910ba3, + 0x8e4e8562, 0x837e8b5f, 0x43a1059e, 0x42c7e707, 0x821869c6, + 0x010d52ef, 0xc1d2dc2e, 0xc0b43eb7, 0x006bb076, 0xc69f48e5, + 0x0640c624, 0x072624bd, 0xc7f9aa7c, 0x44ec9155, 0x84331f94, + 0x8555fd0d, 0x458a73cc, 0x702ca9a1, 0xb0f32760, 0xb195c5f9, + 0x714a4b38, 0xf25f7011, 0x3280fed0, 0x33e61c49, 0xf3399288, + 0x35cd6a1b, 0xf512e4da, 0xf4740643, 0x34ab8882, 0xb7beb3ab, + 0x77613d6a, 0x7607dff3, 0xb6d85132, 0xbbe85f0f, 0x7b37d1ce, + 0x7a513357, 0xba8ebd96, 0x399b86bf, 0xf944087e, 0xf822eae7, + 0x38fd6426, 0xfe099cb5, 0x3ed61274, 0x3fb0f0ed, 0xff6f7e2c, + 0x7c7a4505, 0xbca5cbc4, 0xbdc3295d, 0x7d1ca79c, 0xa7a33527, + 0x677cbbe6, 0x661a597f, 0xa6c5d7be, 0x25d0ec97, 0xe50f6256, + 0xe46980cf, 0x24b60e0e, 0xe242f69d, 0x229d785c, 0x23fb9ac5, + 0xe3241404, 0x60312f2d, 0xa0eea1ec, 0xa1884375, 0x6157cdb4, + 0x6c67c389, 0xacb84d48, 0xaddeafd1, 0x6d012110, 0xee141a39, + 0x2ecb94f8, 0x2fad7661, 0xef72f8a0, 0x29860033, 0xe9598ef2, + 0xe83f6c6b, 0x28e0e2aa, 0xabf5d983, 0x6b2a5742, 0x6a4cb5db, + 0xaa933b1a}, + {0x00000000, 0x6f4ca59b, 0x9f9e3bec, 0xf0d29e77, 0x7f3b0603, + 0x1077a398, 0xe0a53def, 0x8fe99874, 0xfe760c06, 0x913aa99d, + 0x61e837ea, 0x0ea49271, 0x814d0a05, 0xee01af9e, 0x1ed331e9, + 0x719f9472, 0xfced180c, 0x93a1bd97, 0x637323e0, 0x0c3f867b, + 0x83d61e0f, 0xec9abb94, 0x1c4825e3, 0x73048078, 0x029b140a, + 0x6dd7b191, 0x9d052fe6, 0xf2498a7d, 0x7da01209, 0x12ecb792, + 0xe23e29e5, 0x8d728c7e, 0xf8db3118, 0x97979483, 0x67450af4, + 0x0809af6f, 0x87e0371b, 0xe8ac9280, 0x187e0cf7, 0x7732a96c, + 0x06ad3d1e, 0x69e19885, 0x993306f2, 0xf67fa369, 0x79963b1d, + 0x16da9e86, 0xe60800f1, 0x8944a56a, 0x04362914, 0x6b7a8c8f, + 0x9ba812f8, 0xf4e4b763, 0x7b0d2f17, 0x14418a8c, 0xe49314fb, + 0x8bdfb160, 0xfa402512, 0x950c8089, 0x65de1efe, 0x0a92bb65, + 0x857b2311, 0xea37868a, 0x1ae518fd, 0x75a9bd66, 0xf0b76330, + 0x9ffbc6ab, 0x6f2958dc, 0x0065fd47, 0x8f8c6533, 0xe0c0c0a8, + 0x10125edf, 0x7f5efb44, 0x0ec16f36, 0x618dcaad, 0x915f54da, + 0xfe13f141, 0x71fa6935, 0x1eb6ccae, 0xee6452d9, 0x8128f742, + 0x0c5a7b3c, 0x6316dea7, 0x93c440d0, 0xfc88e54b, 0x73617d3f, + 0x1c2dd8a4, 0xecff46d3, 0x83b3e348, 0xf22c773a, 0x9d60d2a1, + 0x6db24cd6, 0x02fee94d, 0x8d177139, 0xe25bd4a2, 0x12894ad5, + 0x7dc5ef4e, 0x086c5228, 0x6720f7b3, 0x97f269c4, 0xf8becc5f, + 0x7757542b, 0x181bf1b0, 0xe8c96fc7, 0x8785ca5c, 0xf61a5e2e, + 0x9956fbb5, 0x698465c2, 0x06c8c059, 0x8921582d, 0xe66dfdb6, + 0x16bf63c1, 0x79f3c65a, 0xf4814a24, 0x9bcdefbf, 0x6b1f71c8, + 0x0453d453, 0x8bba4c27, 0xe4f6e9bc, 0x142477cb, 0x7b68d250, + 0x0af74622, 0x65bbe3b9, 0x95697dce, 0xfa25d855, 0x75cc4021, + 0x1a80e5ba, 0xea527bcd, 0x851ede56, 0xe06fc760, 0x8f2362fb, + 0x7ff1fc8c, 0x10bd5917, 0x9f54c163, 0xf01864f8, 0x00cafa8f, + 0x6f865f14, 0x1e19cb66, 0x71556efd, 0x8187f08a, 0xeecb5511, + 0x6122cd65, 0x0e6e68fe, 0xfebcf689, 0x91f05312, 0x1c82df6c, + 0x73ce7af7, 0x831ce480, 0xec50411b, 0x63b9d96f, 0x0cf57cf4, + 0xfc27e283, 0x936b4718, 0xe2f4d36a, 0x8db876f1, 0x7d6ae886, + 0x12264d1d, 0x9dcfd569, 0xf28370f2, 0x0251ee85, 0x6d1d4b1e, + 0x18b4f678, 0x77f853e3, 0x872acd94, 0xe866680f, 0x678ff07b, + 0x08c355e0, 0xf811cb97, 0x975d6e0c, 0xe6c2fa7e, 0x898e5fe5, + 0x795cc192, 0x16106409, 0x99f9fc7d, 0xf6b559e6, 0x0667c791, + 0x692b620a, 0xe459ee74, 0x8b154bef, 0x7bc7d598, 0x148b7003, + 0x9b62e877, 0xf42e4dec, 0x04fcd39b, 0x6bb07600, 0x1a2fe272, + 0x756347e9, 0x85b1d99e, 0xeafd7c05, 0x6514e471, 0x0a5841ea, + 0xfa8adf9d, 0x95c67a06, 0x10d8a450, 0x7f9401cb, 0x8f469fbc, + 0xe00a3a27, 0x6fe3a253, 0x00af07c8, 0xf07d99bf, 0x9f313c24, + 0xeeaea856, 0x81e20dcd, 0x713093ba, 0x1e7c3621, 0x9195ae55, + 0xfed90bce, 0x0e0b95b9, 0x61473022, 0xec35bc5c, 0x837919c7, + 0x73ab87b0, 0x1ce7222b, 0x930eba5f, 0xfc421fc4, 0x0c9081b3, + 0x63dc2428, 0x1243b05a, 0x7d0f15c1, 0x8ddd8bb6, 0xe2912e2d, + 0x6d78b659, 0x023413c2, 0xf2e68db5, 0x9daa282e, 0xe8039548, + 0x874f30d3, 0x779daea4, 0x18d10b3f, 0x9738934b, 0xf87436d0, + 0x08a6a8a7, 0x67ea0d3c, 0x1675994e, 0x79393cd5, 0x89eba2a2, + 0xe6a70739, 0x694e9f4d, 0x06023ad6, 0xf6d0a4a1, 0x999c013a, + 0x14ee8d44, 0x7ba228df, 0x8b70b6a8, 0xe43c1333, 0x6bd58b47, + 0x04992edc, 0xf44bb0ab, 0x9b071530, 0xea988142, 0x85d424d9, + 0x7506baae, 0x1a4a1f35, 0x95a38741, 0xfaef22da, 0x0a3dbcad, + 0x65711936}}; + +#endif + +#endif + +#if N == 4 + +#if W == 8 + +local const z_crc_t FAR crc_braid_table[][256] = { + {0x00000000, 0xf1da05aa, 0x38c50d15, 0xc91f08bf, 0x718a1a2a, + 0x80501f80, 0x494f173f, 0xb8951295, 0xe3143454, 0x12ce31fe, + 0xdbd13941, 0x2a0b3ceb, 0x929e2e7e, 0x63442bd4, 0xaa5b236b, + 0x5b8126c1, 0x1d596ee9, 0xec836b43, 0x259c63fc, 0xd4466656, + 0x6cd374c3, 0x9d097169, 0x541679d6, 0xa5cc7c7c, 0xfe4d5abd, + 0x0f975f17, 0xc68857a8, 0x37525202, 0x8fc74097, 0x7e1d453d, + 0xb7024d82, 0x46d84828, 0x3ab2ddd2, 0xcb68d878, 0x0277d0c7, + 0xf3add56d, 0x4b38c7f8, 0xbae2c252, 0x73fdcaed, 0x8227cf47, + 0xd9a6e986, 0x287cec2c, 0xe163e493, 0x10b9e139, 0xa82cf3ac, + 0x59f6f606, 0x90e9feb9, 0x6133fb13, 0x27ebb33b, 0xd631b691, + 0x1f2ebe2e, 0xeef4bb84, 0x5661a911, 0xa7bbacbb, 0x6ea4a404, + 0x9f7ea1ae, 0xc4ff876f, 0x352582c5, 0xfc3a8a7a, 0x0de08fd0, + 0xb5759d45, 0x44af98ef, 0x8db09050, 0x7c6a95fa, 0x7565bba4, + 0x84bfbe0e, 0x4da0b6b1, 0xbc7ab31b, 0x04efa18e, 0xf535a424, + 0x3c2aac9b, 0xcdf0a931, 0x96718ff0, 0x67ab8a5a, 0xaeb482e5, + 0x5f6e874f, 0xe7fb95da, 0x16219070, 0xdf3e98cf, 0x2ee49d65, + 0x683cd54d, 0x99e6d0e7, 0x50f9d858, 0xa123ddf2, 0x19b6cf67, + 0xe86ccacd, 0x2173c272, 0xd0a9c7d8, 0x8b28e119, 0x7af2e4b3, + 0xb3edec0c, 0x4237e9a6, 0xfaa2fb33, 0x0b78fe99, 0xc267f626, + 0x33bdf38c, 0x4fd76676, 0xbe0d63dc, 0x77126b63, 0x86c86ec9, + 0x3e5d7c5c, 0xcf8779f6, 0x06987149, 0xf74274e3, 0xacc35222, + 0x5d195788, 0x94065f37, 0x65dc5a9d, 0xdd494808, 0x2c934da2, + 0xe58c451d, 0x145640b7, 0x528e089f, 0xa3540d35, 0x6a4b058a, + 0x9b910020, 0x230412b5, 0xd2de171f, 0x1bc11fa0, 0xea1b1a0a, + 0xb19a3ccb, 0x40403961, 0x895f31de, 0x78853474, 0xc01026e1, + 0x31ca234b, 0xf8d52bf4, 0x090f2e5e, 0xeacb7748, 0x1b1172e2, + 0xd20e7a5d, 0x23d47ff7, 0x9b416d62, 0x6a9b68c8, 0xa3846077, + 0x525e65dd, 0x09df431c, 0xf80546b6, 0x311a4e09, 0xc0c04ba3, + 0x78555936, 0x898f5c9c, 0x40905423, 0xb14a5189, 0xf79219a1, + 0x06481c0b, 0xcf5714b4, 0x3e8d111e, 0x8618038b, 0x77c20621, + 0xbedd0e9e, 0x4f070b34, 0x14862df5, 0xe55c285f, 0x2c4320e0, + 0xdd99254a, 0x650c37df, 0x94d63275, 0x5dc93aca, 0xac133f60, + 0xd079aa9a, 0x21a3af30, 0xe8bca78f, 0x1966a225, 0xa1f3b0b0, + 0x5029b51a, 0x9936bda5, 0x68ecb80f, 0x336d9ece, 0xc2b79b64, + 0x0ba893db, 0xfa729671, 0x42e784e4, 0xb33d814e, 0x7a2289f1, + 0x8bf88c5b, 0xcd20c473, 0x3cfac1d9, 0xf5e5c966, 0x043fcccc, + 0xbcaade59, 0x4d70dbf3, 0x846fd34c, 0x75b5d6e6, 0x2e34f027, + 0xdfeef58d, 0x16f1fd32, 0xe72bf898, 0x5fbeea0d, 0xae64efa7, + 0x677be718, 0x96a1e2b2, 0x9faeccec, 0x6e74c946, 0xa76bc1f9, + 0x56b1c453, 0xee24d6c6, 0x1ffed36c, 0xd6e1dbd3, 0x273bde79, + 0x7cbaf8b8, 0x8d60fd12, 0x447ff5ad, 0xb5a5f007, 0x0d30e292, + 0xfceae738, 0x35f5ef87, 0xc42fea2d, 0x82f7a205, 0x732da7af, + 0xba32af10, 0x4be8aaba, 0xf37db82f, 0x02a7bd85, 0xcbb8b53a, + 0x3a62b090, 0x61e39651, 0x903993fb, 0x59269b44, 0xa8fc9eee, + 0x10698c7b, 0xe1b389d1, 0x28ac816e, 0xd97684c4, 0xa51c113e, + 0x54c61494, 0x9dd91c2b, 0x6c031981, 0xd4960b14, 0x254c0ebe, + 0xec530601, 0x1d8903ab, 0x4608256a, 0xb7d220c0, 0x7ecd287f, + 0x8f172dd5, 0x37823f40, 0xc6583aea, 0x0f473255, 0xfe9d37ff, + 0xb8457fd7, 0x499f7a7d, 0x808072c2, 0x715a7768, 0xc9cf65fd, + 0x38156057, 0xf10a68e8, 0x00d06d42, 0x5b514b83, 0xaa8b4e29, + 0x63944696, 0x924e433c, 0x2adb51a9, 0xdb015403, 0x121e5cbc, + 0xe3c45916}, + {0x00000000, 0x0ee7e8d1, 0x1dcfd1a2, 0x13283973, 0x3b9fa344, + 0x35784b95, 0x265072e6, 0x28b79a37, 0x773f4688, 0x79d8ae59, + 0x6af0972a, 0x64177ffb, 0x4ca0e5cc, 0x42470d1d, 0x516f346e, + 0x5f88dcbf, 0xee7e8d10, 0xe09965c1, 0xf3b15cb2, 0xfd56b463, + 0xd5e12e54, 0xdb06c685, 0xc82efff6, 0xc6c91727, 0x9941cb98, + 0x97a62349, 0x848e1a3a, 0x8a69f2eb, 0xa2de68dc, 0xac39800d, + 0xbf11b97e, 0xb1f651af, 0x078c1c61, 0x096bf4b0, 0x1a43cdc3, + 0x14a42512, 0x3c13bf25, 0x32f457f4, 0x21dc6e87, 0x2f3b8656, + 0x70b35ae9, 0x7e54b238, 0x6d7c8b4b, 0x639b639a, 0x4b2cf9ad, + 0x45cb117c, 0x56e3280f, 0x5804c0de, 0xe9f29171, 0xe71579a0, + 0xf43d40d3, 0xfadaa802, 0xd26d3235, 0xdc8adae4, 0xcfa2e397, + 0xc1450b46, 0x9ecdd7f9, 0x902a3f28, 0x8302065b, 0x8de5ee8a, + 0xa55274bd, 0xabb59c6c, 0xb89da51f, 0xb67a4dce, 0x0f1838c2, + 0x01ffd013, 0x12d7e960, 0x1c3001b1, 0x34879b86, 0x3a607357, + 0x29484a24, 0x27afa2f5, 0x78277e4a, 0x76c0969b, 0x65e8afe8, + 0x6b0f4739, 0x43b8dd0e, 0x4d5f35df, 0x5e770cac, 0x5090e47d, + 0xe166b5d2, 0xef815d03, 0xfca96470, 0xf24e8ca1, 0xdaf91696, + 0xd41efe47, 0xc736c734, 0xc9d12fe5, 0x9659f35a, 0x98be1b8b, + 0x8b9622f8, 0x8571ca29, 0xadc6501e, 0xa321b8cf, 0xb00981bc, + 0xbeee696d, 0x089424a3, 0x0673cc72, 0x155bf501, 0x1bbc1dd0, + 0x330b87e7, 0x3dec6f36, 0x2ec45645, 0x2023be94, 0x7fab622b, + 0x714c8afa, 0x6264b389, 0x6c835b58, 0x4434c16f, 0x4ad329be, + 0x59fb10cd, 0x571cf81c, 0xe6eaa9b3, 0xe80d4162, 0xfb257811, + 0xf5c290c0, 0xdd750af7, 0xd392e226, 0xc0badb55, 0xce5d3384, + 0x91d5ef3b, 0x9f3207ea, 0x8c1a3e99, 0x82fdd648, 0xaa4a4c7f, + 0xa4ada4ae, 0xb7859ddd, 0xb962750c, 0x1e307184, 0x10d79955, + 0x03ffa026, 0x0d1848f7, 0x25afd2c0, 0x2b483a11, 0x38600362, + 0x3687ebb3, 0x690f370c, 0x67e8dfdd, 0x74c0e6ae, 0x7a270e7f, + 0x52909448, 0x5c777c99, 0x4f5f45ea, 0x41b8ad3b, 0xf04efc94, + 0xfea91445, 0xed812d36, 0xe366c5e7, 0xcbd15fd0, 0xc536b701, + 0xd61e8e72, 0xd8f966a3, 0x8771ba1c, 0x899652cd, 0x9abe6bbe, + 0x9459836f, 0xbcee1958, 0xb209f189, 0xa121c8fa, 0xafc6202b, + 0x19bc6de5, 0x175b8534, 0x0473bc47, 0x0a945496, 0x2223cea1, + 0x2cc42670, 0x3fec1f03, 0x310bf7d2, 0x6e832b6d, 0x6064c3bc, + 0x734cfacf, 0x7dab121e, 0x551c8829, 0x5bfb60f8, 0x48d3598b, + 0x4634b15a, 0xf7c2e0f5, 0xf9250824, 0xea0d3157, 0xe4ead986, + 0xcc5d43b1, 0xc2baab60, 0xd1929213, 0xdf757ac2, 0x80fda67d, + 0x8e1a4eac, 0x9d3277df, 0x93d59f0e, 0xbb620539, 0xb585ede8, + 0xa6add49b, 0xa84a3c4a, 0x11284946, 0x1fcfa197, 0x0ce798e4, + 0x02007035, 0x2ab7ea02, 0x245002d3, 0x37783ba0, 0x399fd371, + 0x66170fce, 0x68f0e71f, 0x7bd8de6c, 0x753f36bd, 0x5d88ac8a, + 0x536f445b, 0x40477d28, 0x4ea095f9, 0xff56c456, 0xf1b12c87, + 0xe29915f4, 0xec7efd25, 0xc4c96712, 0xca2e8fc3, 0xd906b6b0, + 0xd7e15e61, 0x886982de, 0x868e6a0f, 0x95a6537c, 0x9b41bbad, + 0xb3f6219a, 0xbd11c94b, 0xae39f038, 0xa0de18e9, 0x16a45527, + 0x1843bdf6, 0x0b6b8485, 0x058c6c54, 0x2d3bf663, 0x23dc1eb2, + 0x30f427c1, 0x3e13cf10, 0x619b13af, 0x6f7cfb7e, 0x7c54c20d, + 0x72b32adc, 0x5a04b0eb, 0x54e3583a, 0x47cb6149, 0x492c8998, + 0xf8dad837, 0xf63d30e6, 0xe5150995, 0xebf2e144, 0xc3457b73, + 0xcda293a2, 0xde8aaad1, 0xd06d4200, 0x8fe59ebf, 0x8102766e, + 0x922a4f1d, 0x9ccda7cc, 0xb47a3dfb, 0xba9dd52a, 0xa9b5ec59, + 0xa7520488}, + {0x00000000, 0x3c60e308, 0x78c1c610, 0x44a12518, 0xf1838c20, + 0xcde36f28, 0x89424a30, 0xb522a938, 0x38761e01, 0x0416fd09, + 0x40b7d811, 0x7cd73b19, 0xc9f59221, 0xf5957129, 0xb1345431, + 0x8d54b739, 0x70ec3c02, 0x4c8cdf0a, 0x082dfa12, 0x344d191a, + 0x816fb022, 0xbd0f532a, 0xf9ae7632, 0xc5ce953a, 0x489a2203, + 0x74fac10b, 0x305be413, 0x0c3b071b, 0xb919ae23, 0x85794d2b, + 0xc1d86833, 0xfdb88b3b, 0xe1d87804, 0xddb89b0c, 0x9919be14, + 0xa5795d1c, 0x105bf424, 0x2c3b172c, 0x689a3234, 0x54fad13c, + 0xd9ae6605, 0xe5ce850d, 0xa16fa015, 0x9d0f431d, 0x282dea25, + 0x144d092d, 0x50ec2c35, 0x6c8ccf3d, 0x91344406, 0xad54a70e, + 0xe9f58216, 0xd595611e, 0x60b7c826, 0x5cd72b2e, 0x18760e36, + 0x2416ed3e, 0xa9425a07, 0x9522b90f, 0xd1839c17, 0xede37f1f, + 0x58c1d627, 0x64a1352f, 0x20001037, 0x1c60f33f, 0x18c1f649, + 0x24a11541, 0x60003059, 0x5c60d351, 0xe9427a69, 0xd5229961, + 0x9183bc79, 0xade35f71, 0x20b7e848, 0x1cd70b40, 0x58762e58, + 0x6416cd50, 0xd1346468, 0xed548760, 0xa9f5a278, 0x95954170, + 0x682dca4b, 0x544d2943, 0x10ec0c5b, 0x2c8cef53, 0x99ae466b, + 0xa5cea563, 0xe16f807b, 0xdd0f6373, 0x505bd44a, 0x6c3b3742, + 0x289a125a, 0x14faf152, 0xa1d8586a, 0x9db8bb62, 0xd9199e7a, + 0xe5797d72, 0xf9198e4d, 0xc5796d45, 0x81d8485d, 0xbdb8ab55, + 0x089a026d, 0x34fae165, 0x705bc47d, 0x4c3b2775, 0xc16f904c, + 0xfd0f7344, 0xb9ae565c, 0x85ceb554, 0x30ec1c6c, 0x0c8cff64, + 0x482dda7c, 0x744d3974, 0x89f5b24f, 0xb5955147, 0xf134745f, + 0xcd549757, 0x78763e6f, 0x4416dd67, 0x00b7f87f, 0x3cd71b77, + 0xb183ac4e, 0x8de34f46, 0xc9426a5e, 0xf5228956, 0x4000206e, + 0x7c60c366, 0x38c1e67e, 0x04a10576, 0x3183ec92, 0x0de30f9a, + 0x49422a82, 0x7522c98a, 0xc00060b2, 0xfc6083ba, 0xb8c1a6a2, + 0x84a145aa, 0x09f5f293, 0x3595119b, 0x71343483, 0x4d54d78b, + 0xf8767eb3, 0xc4169dbb, 0x80b7b8a3, 0xbcd75bab, 0x416fd090, + 0x7d0f3398, 0x39ae1680, 0x05cef588, 0xb0ec5cb0, 0x8c8cbfb8, + 0xc82d9aa0, 0xf44d79a8, 0x7919ce91, 0x45792d99, 0x01d80881, + 0x3db8eb89, 0x889a42b1, 0xb4faa1b9, 0xf05b84a1, 0xcc3b67a9, + 0xd05b9496, 0xec3b779e, 0xa89a5286, 0x94fab18e, 0x21d818b6, + 0x1db8fbbe, 0x5919dea6, 0x65793dae, 0xe82d8a97, 0xd44d699f, + 0x90ec4c87, 0xac8caf8f, 0x19ae06b7, 0x25cee5bf, 0x616fc0a7, + 0x5d0f23af, 0xa0b7a894, 0x9cd74b9c, 0xd8766e84, 0xe4168d8c, + 0x513424b4, 0x6d54c7bc, 0x29f5e2a4, 0x159501ac, 0x98c1b695, + 0xa4a1559d, 0xe0007085, 0xdc60938d, 0x69423ab5, 0x5522d9bd, + 0x1183fca5, 0x2de31fad, 0x29421adb, 0x1522f9d3, 0x5183dccb, + 0x6de33fc3, 0xd8c196fb, 0xe4a175f3, 0xa00050eb, 0x9c60b3e3, + 0x113404da, 0x2d54e7d2, 0x69f5c2ca, 0x559521c2, 0xe0b788fa, + 0xdcd76bf2, 0x98764eea, 0xa416ade2, 0x59ae26d9, 0x65cec5d1, + 0x216fe0c9, 0x1d0f03c1, 0xa82daaf9, 0x944d49f1, 0xd0ec6ce9, + 0xec8c8fe1, 0x61d838d8, 0x5db8dbd0, 0x1919fec8, 0x25791dc0, + 0x905bb4f8, 0xac3b57f0, 0xe89a72e8, 0xd4fa91e0, 0xc89a62df, + 0xf4fa81d7, 0xb05ba4cf, 0x8c3b47c7, 0x3919eeff, 0x05790df7, + 0x41d828ef, 0x7db8cbe7, 0xf0ec7cde, 0xcc8c9fd6, 0x882dbace, + 0xb44d59c6, 0x016ff0fe, 0x3d0f13f6, 0x79ae36ee, 0x45ced5e6, + 0xb8765edd, 0x8416bdd5, 0xc0b798cd, 0xfcd77bc5, 0x49f5d2fd, + 0x759531f5, 0x313414ed, 0x0d54f7e5, 0x800040dc, 0xbc60a3d4, + 0xf8c186cc, 0xc4a165c4, 0x7183ccfc, 0x4de32ff4, 0x09420aec, + 0x3522e9e4}, + {0x00000000, 0x6307d924, 0xc60fb248, 0xa5086b6c, 0x576e62d1, + 0x3469bbf5, 0x9161d099, 0xf26609bd, 0xaedcc5a2, 0xcddb1c86, + 0x68d377ea, 0x0bd4aece, 0xf9b2a773, 0x9ab57e57, 0x3fbd153b, + 0x5cbacc1f, 0x86c88d05, 0xe5cf5421, 0x40c73f4d, 0x23c0e669, + 0xd1a6efd4, 0xb2a136f0, 0x17a95d9c, 0x74ae84b8, 0x281448a7, + 0x4b139183, 0xee1bfaef, 0x8d1c23cb, 0x7f7a2a76, 0x1c7df352, + 0xb975983e, 0xda72411a, 0xd6e01c4b, 0xb5e7c56f, 0x10efae03, + 0x73e87727, 0x818e7e9a, 0xe289a7be, 0x4781ccd2, 0x248615f6, + 0x783cd9e9, 0x1b3b00cd, 0xbe336ba1, 0xdd34b285, 0x2f52bb38, + 0x4c55621c, 0xe95d0970, 0x8a5ad054, 0x5028914e, 0x332f486a, + 0x96272306, 0xf520fa22, 0x0746f39f, 0x64412abb, 0xc14941d7, + 0xa24e98f3, 0xfef454ec, 0x9df38dc8, 0x38fbe6a4, 0x5bfc3f80, + 0xa99a363d, 0xca9def19, 0x6f958475, 0x0c925d51, 0x76b13ed7, + 0x15b6e7f3, 0xb0be8c9f, 0xd3b955bb, 0x21df5c06, 0x42d88522, + 0xe7d0ee4e, 0x84d7376a, 0xd86dfb75, 0xbb6a2251, 0x1e62493d, + 0x7d659019, 0x8f0399a4, 0xec044080, 0x490c2bec, 0x2a0bf2c8, + 0xf079b3d2, 0x937e6af6, 0x3676019a, 0x5571d8be, 0xa717d103, + 0xc4100827, 0x6118634b, 0x021fba6f, 0x5ea57670, 0x3da2af54, + 0x98aac438, 0xfbad1d1c, 0x09cb14a1, 0x6acccd85, 0xcfc4a6e9, + 0xacc37fcd, 0xa051229c, 0xc356fbb8, 0x665e90d4, 0x055949f0, + 0xf73f404d, 0x94389969, 0x3130f205, 0x52372b21, 0x0e8de73e, + 0x6d8a3e1a, 0xc8825576, 0xab858c52, 0x59e385ef, 0x3ae45ccb, + 0x9fec37a7, 0xfcebee83, 0x2699af99, 0x459e76bd, 0xe0961dd1, + 0x8391c4f5, 0x71f7cd48, 0x12f0146c, 0xb7f87f00, 0xd4ffa624, + 0x88456a3b, 0xeb42b31f, 0x4e4ad873, 0x2d4d0157, 0xdf2b08ea, + 0xbc2cd1ce, 0x1924baa2, 0x7a236386, 0xed627dae, 0x8e65a48a, + 0x2b6dcfe6, 0x486a16c2, 0xba0c1f7f, 0xd90bc65b, 0x7c03ad37, + 0x1f047413, 0x43beb80c, 0x20b96128, 0x85b10a44, 0xe6b6d360, + 0x14d0dadd, 0x77d703f9, 0xd2df6895, 0xb1d8b1b1, 0x6baaf0ab, + 0x08ad298f, 0xada542e3, 0xcea29bc7, 0x3cc4927a, 0x5fc34b5e, + 0xfacb2032, 0x99ccf916, 0xc5763509, 0xa671ec2d, 0x03798741, + 0x607e5e65, 0x921857d8, 0xf11f8efc, 0x5417e590, 0x37103cb4, + 0x3b8261e5, 0x5885b8c1, 0xfd8dd3ad, 0x9e8a0a89, 0x6cec0334, + 0x0febda10, 0xaae3b17c, 0xc9e46858, 0x955ea447, 0xf6597d63, + 0x5351160f, 0x3056cf2b, 0xc230c696, 0xa1371fb2, 0x043f74de, + 0x6738adfa, 0xbd4aece0, 0xde4d35c4, 0x7b455ea8, 0x1842878c, + 0xea248e31, 0x89235715, 0x2c2b3c79, 0x4f2ce55d, 0x13962942, + 0x7091f066, 0xd5999b0a, 0xb69e422e, 0x44f84b93, 0x27ff92b7, + 0x82f7f9db, 0xe1f020ff, 0x9bd34379, 0xf8d49a5d, 0x5ddcf131, + 0x3edb2815, 0xccbd21a8, 0xafbaf88c, 0x0ab293e0, 0x69b54ac4, + 0x350f86db, 0x56085fff, 0xf3003493, 0x9007edb7, 0x6261e40a, + 0x01663d2e, 0xa46e5642, 0xc7698f66, 0x1d1bce7c, 0x7e1c1758, + 0xdb147c34, 0xb813a510, 0x4a75acad, 0x29727589, 0x8c7a1ee5, + 0xef7dc7c1, 0xb3c70bde, 0xd0c0d2fa, 0x75c8b996, 0x16cf60b2, + 0xe4a9690f, 0x87aeb02b, 0x22a6db47, 0x41a10263, 0x4d335f32, + 0x2e348616, 0x8b3ced7a, 0xe83b345e, 0x1a5d3de3, 0x795ae4c7, + 0xdc528fab, 0xbf55568f, 0xe3ef9a90, 0x80e843b4, 0x25e028d8, + 0x46e7f1fc, 0xb481f841, 0xd7862165, 0x728e4a09, 0x1189932d, + 0xcbfbd237, 0xa8fc0b13, 0x0df4607f, 0x6ef3b95b, 0x9c95b0e6, + 0xff9269c2, 0x5a9a02ae, 0x399ddb8a, 0x65271795, 0x0620ceb1, + 0xa328a5dd, 0xc02f7cf9, 0x32497544, 0x514eac60, 0xf446c70c, + 0x97411e28}, + {0x00000000, 0x01b5fd1d, 0x036bfa3a, 0x02de0727, 0x06d7f474, + 0x07620969, 0x05bc0e4e, 0x0409f353, 0x0dafe8e8, 0x0c1a15f5, + 0x0ec412d2, 0x0f71efcf, 0x0b781c9c, 0x0acde181, 0x0813e6a6, + 0x09a61bbb, 0x1b5fd1d0, 0x1aea2ccd, 0x18342bea, 0x1981d6f7, + 0x1d8825a4, 0x1c3dd8b9, 0x1ee3df9e, 0x1f562283, 0x16f03938, + 0x1745c425, 0x159bc302, 0x142e3e1f, 0x1027cd4c, 0x11923051, + 0x134c3776, 0x12f9ca6b, 0x36bfa3a0, 0x370a5ebd, 0x35d4599a, + 0x3461a487, 0x306857d4, 0x31ddaac9, 0x3303adee, 0x32b650f3, + 0x3b104b48, 0x3aa5b655, 0x387bb172, 0x39ce4c6f, 0x3dc7bf3c, + 0x3c724221, 0x3eac4506, 0x3f19b81b, 0x2de07270, 0x2c558f6d, + 0x2e8b884a, 0x2f3e7557, 0x2b378604, 0x2a827b19, 0x285c7c3e, + 0x29e98123, 0x204f9a98, 0x21fa6785, 0x232460a2, 0x22919dbf, + 0x26986eec, 0x272d93f1, 0x25f394d6, 0x244669cb, 0x6d7f4740, + 0x6ccaba5d, 0x6e14bd7a, 0x6fa14067, 0x6ba8b334, 0x6a1d4e29, + 0x68c3490e, 0x6976b413, 0x60d0afa8, 0x616552b5, 0x63bb5592, + 0x620ea88f, 0x66075bdc, 0x67b2a6c1, 0x656ca1e6, 0x64d95cfb, + 0x76209690, 0x77956b8d, 0x754b6caa, 0x74fe91b7, 0x70f762e4, + 0x71429ff9, 0x739c98de, 0x722965c3, 0x7b8f7e78, 0x7a3a8365, + 0x78e48442, 0x7951795f, 0x7d588a0c, 0x7ced7711, 0x7e337036, + 0x7f868d2b, 0x5bc0e4e0, 0x5a7519fd, 0x58ab1eda, 0x591ee3c7, + 0x5d171094, 0x5ca2ed89, 0x5e7ceaae, 0x5fc917b3, 0x566f0c08, + 0x57daf115, 0x5504f632, 0x54b10b2f, 0x50b8f87c, 0x510d0561, + 0x53d30246, 0x5266ff5b, 0x409f3530, 0x412ac82d, 0x43f4cf0a, + 0x42413217, 0x4648c144, 0x47fd3c59, 0x45233b7e, 0x4496c663, + 0x4d30ddd8, 0x4c8520c5, 0x4e5b27e2, 0x4feedaff, 0x4be729ac, + 0x4a52d4b1, 0x488cd396, 0x49392e8b, 0xdafe8e80, 0xdb4b739d, + 0xd99574ba, 0xd82089a7, 0xdc297af4, 0xdd9c87e9, 0xdf4280ce, + 0xdef77dd3, 0xd7516668, 0xd6e49b75, 0xd43a9c52, 0xd58f614f, + 0xd186921c, 0xd0336f01, 0xd2ed6826, 0xd358953b, 0xc1a15f50, + 0xc014a24d, 0xc2caa56a, 0xc37f5877, 0xc776ab24, 0xc6c35639, + 0xc41d511e, 0xc5a8ac03, 0xcc0eb7b8, 0xcdbb4aa5, 0xcf654d82, + 0xced0b09f, 0xcad943cc, 0xcb6cbed1, 0xc9b2b9f6, 0xc80744eb, + 0xec412d20, 0xedf4d03d, 0xef2ad71a, 0xee9f2a07, 0xea96d954, + 0xeb232449, 0xe9fd236e, 0xe848de73, 0xe1eec5c8, 0xe05b38d5, + 0xe2853ff2, 0xe330c2ef, 0xe73931bc, 0xe68ccca1, 0xe452cb86, + 0xe5e7369b, 0xf71efcf0, 0xf6ab01ed, 0xf47506ca, 0xf5c0fbd7, + 0xf1c90884, 0xf07cf599, 0xf2a2f2be, 0xf3170fa3, 0xfab11418, + 0xfb04e905, 0xf9daee22, 0xf86f133f, 0xfc66e06c, 0xfdd31d71, + 0xff0d1a56, 0xfeb8e74b, 0xb781c9c0, 0xb63434dd, 0xb4ea33fa, + 0xb55fcee7, 0xb1563db4, 0xb0e3c0a9, 0xb23dc78e, 0xb3883a93, + 0xba2e2128, 0xbb9bdc35, 0xb945db12, 0xb8f0260f, 0xbcf9d55c, + 0xbd4c2841, 0xbf922f66, 0xbe27d27b, 0xacde1810, 0xad6be50d, + 0xafb5e22a, 0xae001f37, 0xaa09ec64, 0xabbc1179, 0xa962165e, + 0xa8d7eb43, 0xa171f0f8, 0xa0c40de5, 0xa21a0ac2, 0xa3aff7df, + 0xa7a6048c, 0xa613f991, 0xa4cdfeb6, 0xa57803ab, 0x813e6a60, + 0x808b977d, 0x8255905a, 0x83e06d47, 0x87e99e14, 0x865c6309, + 0x8482642e, 0x85379933, 0x8c918288, 0x8d247f95, 0x8ffa78b2, + 0x8e4f85af, 0x8a4676fc, 0x8bf38be1, 0x892d8cc6, 0x889871db, + 0x9a61bbb0, 0x9bd446ad, 0x990a418a, 0x98bfbc97, 0x9cb64fc4, + 0x9d03b2d9, 0x9fddb5fe, 0x9e6848e3, 0x97ce5358, 0x967bae45, + 0x94a5a962, 0x9510547f, 0x9119a72c, 0x90ac5a31, 0x92725d16, + 0x93c7a00b}, + {0x00000000, 0x6e8c1b41, 0xdd183682, 0xb3942dc3, 0x61416b45, + 0x0fcd7004, 0xbc595dc7, 0xd2d54686, 0xc282d68a, 0xac0ecdcb, + 0x1f9ae008, 0x7116fb49, 0xa3c3bdcf, 0xcd4fa68e, 0x7edb8b4d, + 0x1057900c, 0x5e74ab55, 0x30f8b014, 0x836c9dd7, 0xede08696, + 0x3f35c010, 0x51b9db51, 0xe22df692, 0x8ca1edd3, 0x9cf67ddf, + 0xf27a669e, 0x41ee4b5d, 0x2f62501c, 0xfdb7169a, 0x933b0ddb, + 0x20af2018, 0x4e233b59, 0xbce956aa, 0xd2654deb, 0x61f16028, + 0x0f7d7b69, 0xdda83def, 0xb32426ae, 0x00b00b6d, 0x6e3c102c, + 0x7e6b8020, 0x10e79b61, 0xa373b6a2, 0xcdffade3, 0x1f2aeb65, + 0x71a6f024, 0xc232dde7, 0xacbec6a6, 0xe29dfdff, 0x8c11e6be, + 0x3f85cb7d, 0x5109d03c, 0x83dc96ba, 0xed508dfb, 0x5ec4a038, + 0x3048bb79, 0x201f2b75, 0x4e933034, 0xfd071df7, 0x938b06b6, + 0x415e4030, 0x2fd25b71, 0x9c4676b2, 0xf2ca6df3, 0xa2a3ab15, + 0xcc2fb054, 0x7fbb9d97, 0x113786d6, 0xc3e2c050, 0xad6edb11, + 0x1efaf6d2, 0x7076ed93, 0x60217d9f, 0x0ead66de, 0xbd394b1d, + 0xd3b5505c, 0x016016da, 0x6fec0d9b, 0xdc782058, 0xb2f43b19, + 0xfcd70040, 0x925b1b01, 0x21cf36c2, 0x4f432d83, 0x9d966b05, + 0xf31a7044, 0x408e5d87, 0x2e0246c6, 0x3e55d6ca, 0x50d9cd8b, + 0xe34de048, 0x8dc1fb09, 0x5f14bd8f, 0x3198a6ce, 0x820c8b0d, + 0xec80904c, 0x1e4afdbf, 0x70c6e6fe, 0xc352cb3d, 0xadded07c, + 0x7f0b96fa, 0x11878dbb, 0xa213a078, 0xcc9fbb39, 0xdcc82b35, + 0xb2443074, 0x01d01db7, 0x6f5c06f6, 0xbd894070, 0xd3055b31, + 0x609176f2, 0x0e1d6db3, 0x403e56ea, 0x2eb24dab, 0x9d266068, + 0xf3aa7b29, 0x217f3daf, 0x4ff326ee, 0xfc670b2d, 0x92eb106c, + 0x82bc8060, 0xec309b21, 0x5fa4b6e2, 0x3128ada3, 0xe3fdeb25, + 0x8d71f064, 0x3ee5dda7, 0x5069c6e6, 0x9e36506b, 0xf0ba4b2a, + 0x432e66e9, 0x2da27da8, 0xff773b2e, 0x91fb206f, 0x226f0dac, + 0x4ce316ed, 0x5cb486e1, 0x32389da0, 0x81acb063, 0xef20ab22, + 0x3df5eda4, 0x5379f6e5, 0xe0eddb26, 0x8e61c067, 0xc042fb3e, + 0xaecee07f, 0x1d5acdbc, 0x73d6d6fd, 0xa103907b, 0xcf8f8b3a, + 0x7c1ba6f9, 0x1297bdb8, 0x02c02db4, 0x6c4c36f5, 0xdfd81b36, + 0xb1540077, 0x638146f1, 0x0d0d5db0, 0xbe997073, 0xd0156b32, + 0x22df06c1, 0x4c531d80, 0xffc73043, 0x914b2b02, 0x439e6d84, + 0x2d1276c5, 0x9e865b06, 0xf00a4047, 0xe05dd04b, 0x8ed1cb0a, + 0x3d45e6c9, 0x53c9fd88, 0x811cbb0e, 0xef90a04f, 0x5c048d8c, + 0x328896cd, 0x7cabad94, 0x1227b6d5, 0xa1b39b16, 0xcf3f8057, + 0x1deac6d1, 0x7366dd90, 0xc0f2f053, 0xae7eeb12, 0xbe297b1e, + 0xd0a5605f, 0x63314d9c, 0x0dbd56dd, 0xdf68105b, 0xb1e40b1a, + 0x027026d9, 0x6cfc3d98, 0x3c95fb7e, 0x5219e03f, 0xe18dcdfc, + 0x8f01d6bd, 0x5dd4903b, 0x33588b7a, 0x80cca6b9, 0xee40bdf8, + 0xfe172df4, 0x909b36b5, 0x230f1b76, 0x4d830037, 0x9f5646b1, + 0xf1da5df0, 0x424e7033, 0x2cc26b72, 0x62e1502b, 0x0c6d4b6a, + 0xbff966a9, 0xd1757de8, 0x03a03b6e, 0x6d2c202f, 0xdeb80dec, + 0xb03416ad, 0xa06386a1, 0xceef9de0, 0x7d7bb023, 0x13f7ab62, + 0xc122ede4, 0xafaef6a5, 0x1c3adb66, 0x72b6c027, 0x807cadd4, + 0xeef0b695, 0x5d649b56, 0x33e88017, 0xe13dc691, 0x8fb1ddd0, + 0x3c25f013, 0x52a9eb52, 0x42fe7b5e, 0x2c72601f, 0x9fe64ddc, + 0xf16a569d, 0x23bf101b, 0x4d330b5a, 0xfea72699, 0x902b3dd8, + 0xde080681, 0xb0841dc0, 0x03103003, 0x6d9c2b42, 0xbf496dc4, + 0xd1c57685, 0x62515b46, 0x0cdd4007, 0x1c8ad00b, 0x7206cb4a, + 0xc192e689, 0xaf1efdc8, 0x7dcbbb4e, 0x1347a00f, 0xa0d38dcc, + 0xce5f968d}, + {0x00000000, 0xe71da697, 0x154a4b6f, 0xf257edf8, 0x2a9496de, + 0xcd893049, 0x3fdeddb1, 0xd8c37b26, 0x55292dbc, 0xb2348b2b, + 0x406366d3, 0xa77ec044, 0x7fbdbb62, 0x98a01df5, 0x6af7f00d, + 0x8dea569a, 0xaa525b78, 0x4d4ffdef, 0xbf181017, 0x5805b680, + 0x80c6cda6, 0x67db6b31, 0x958c86c9, 0x7291205e, 0xff7b76c4, + 0x1866d053, 0xea313dab, 0x0d2c9b3c, 0xd5efe01a, 0x32f2468d, + 0xc0a5ab75, 0x27b80de2, 0x8fd5b0b1, 0x68c81626, 0x9a9ffbde, + 0x7d825d49, 0xa541266f, 0x425c80f8, 0xb00b6d00, 0x5716cb97, + 0xdafc9d0d, 0x3de13b9a, 0xcfb6d662, 0x28ab70f5, 0xf0680bd3, + 0x1775ad44, 0xe52240bc, 0x023fe62b, 0x2587ebc9, 0xc29a4d5e, + 0x30cda0a6, 0xd7d00631, 0x0f137d17, 0xe80edb80, 0x1a593678, + 0xfd4490ef, 0x70aec675, 0x97b360e2, 0x65e48d1a, 0x82f92b8d, + 0x5a3a50ab, 0xbd27f63c, 0x4f701bc4, 0xa86dbd53, 0xc4da6723, + 0x23c7c1b4, 0xd1902c4c, 0x368d8adb, 0xee4ef1fd, 0x0953576a, + 0xfb04ba92, 0x1c191c05, 0x91f34a9f, 0x76eeec08, 0x84b901f0, + 0x63a4a767, 0xbb67dc41, 0x5c7a7ad6, 0xae2d972e, 0x493031b9, + 0x6e883c5b, 0x89959acc, 0x7bc27734, 0x9cdfd1a3, 0x441caa85, + 0xa3010c12, 0x5156e1ea, 0xb64b477d, 0x3ba111e7, 0xdcbcb770, + 0x2eeb5a88, 0xc9f6fc1f, 0x11358739, 0xf62821ae, 0x047fcc56, + 0xe3626ac1, 0x4b0fd792, 0xac127105, 0x5e459cfd, 0xb9583a6a, + 0x619b414c, 0x8686e7db, 0x74d10a23, 0x93ccacb4, 0x1e26fa2e, + 0xf93b5cb9, 0x0b6cb141, 0xec7117d6, 0x34b26cf0, 0xd3afca67, + 0x21f8279f, 0xc6e58108, 0xe15d8cea, 0x06402a7d, 0xf417c785, + 0x130a6112, 0xcbc91a34, 0x2cd4bca3, 0xde83515b, 0x399ef7cc, + 0xb474a156, 0x536907c1, 0xa13eea39, 0x46234cae, 0x9ee03788, + 0x79fd911f, 0x8baa7ce7, 0x6cb7da70, 0x52c5c807, 0xb5d86e90, + 0x478f8368, 0xa09225ff, 0x78515ed9, 0x9f4cf84e, 0x6d1b15b6, + 0x8a06b321, 0x07ece5bb, 0xe0f1432c, 0x12a6aed4, 0xf5bb0843, + 0x2d787365, 0xca65d5f2, 0x3832380a, 0xdf2f9e9d, 0xf897937f, + 0x1f8a35e8, 0xedddd810, 0x0ac07e87, 0xd20305a1, 0x351ea336, + 0xc7494ece, 0x2054e859, 0xadbebec3, 0x4aa31854, 0xb8f4f5ac, + 0x5fe9533b, 0x872a281d, 0x60378e8a, 0x92606372, 0x757dc5e5, + 0xdd1078b6, 0x3a0dde21, 0xc85a33d9, 0x2f47954e, 0xf784ee68, + 0x109948ff, 0xe2cea507, 0x05d30390, 0x8839550a, 0x6f24f39d, + 0x9d731e65, 0x7a6eb8f2, 0xa2adc3d4, 0x45b06543, 0xb7e788bb, + 0x50fa2e2c, 0x774223ce, 0x905f8559, 0x620868a1, 0x8515ce36, + 0x5dd6b510, 0xbacb1387, 0x489cfe7f, 0xaf8158e8, 0x226b0e72, + 0xc576a8e5, 0x3721451d, 0xd03ce38a, 0x08ff98ac, 0xefe23e3b, + 0x1db5d3c3, 0xfaa87554, 0x961faf24, 0x710209b3, 0x8355e44b, + 0x644842dc, 0xbc8b39fa, 0x5b969f6d, 0xa9c17295, 0x4edcd402, + 0xc3368298, 0x242b240f, 0xd67cc9f7, 0x31616f60, 0xe9a21446, + 0x0ebfb2d1, 0xfce85f29, 0x1bf5f9be, 0x3c4df45c, 0xdb5052cb, + 0x2907bf33, 0xce1a19a4, 0x16d96282, 0xf1c4c415, 0x039329ed, + 0xe48e8f7a, 0x6964d9e0, 0x8e797f77, 0x7c2e928f, 0x9b333418, + 0x43f04f3e, 0xa4ede9a9, 0x56ba0451, 0xb1a7a2c6, 0x19ca1f95, + 0xfed7b902, 0x0c8054fa, 0xeb9df26d, 0x335e894b, 0xd4432fdc, + 0x2614c224, 0xc10964b3, 0x4ce33229, 0xabfe94be, 0x59a97946, + 0xbeb4dfd1, 0x6677a4f7, 0x816a0260, 0x733def98, 0x9420490f, + 0xb39844ed, 0x5485e27a, 0xa6d20f82, 0x41cfa915, 0x990cd233, + 0x7e1174a4, 0x8c46995c, 0x6b5b3fcb, 0xe6b16951, 0x01accfc6, + 0xf3fb223e, 0x14e684a9, 0xcc25ff8f, 0x2b385918, 0xd96fb4e0, + 0x3e721277}, + {0x00000000, 0xa58b900e, 0x9066265d, 0x35edb653, 0xfbbd4afb, + 0x5e36daf5, 0x6bdb6ca6, 0xce50fca8, 0x2c0b93b7, 0x898003b9, + 0xbc6db5ea, 0x19e625e4, 0xd7b6d94c, 0x723d4942, 0x47d0ff11, + 0xe25b6f1f, 0x5817276e, 0xfd9cb760, 0xc8710133, 0x6dfa913d, + 0xa3aa6d95, 0x0621fd9b, 0x33cc4bc8, 0x9647dbc6, 0x741cb4d9, + 0xd19724d7, 0xe47a9284, 0x41f1028a, 0x8fa1fe22, 0x2a2a6e2c, + 0x1fc7d87f, 0xba4c4871, 0xb02e4edc, 0x15a5ded2, 0x20486881, + 0x85c3f88f, 0x4b930427, 0xee189429, 0xdbf5227a, 0x7e7eb274, + 0x9c25dd6b, 0x39ae4d65, 0x0c43fb36, 0xa9c86b38, 0x67989790, + 0xc213079e, 0xf7feb1cd, 0x527521c3, 0xe83969b2, 0x4db2f9bc, + 0x785f4fef, 0xddd4dfe1, 0x13842349, 0xb60fb347, 0x83e20514, + 0x2669951a, 0xc432fa05, 0x61b96a0b, 0x5454dc58, 0xf1df4c56, + 0x3f8fb0fe, 0x9a0420f0, 0xafe996a3, 0x0a6206ad, 0xbb2d9bf9, + 0x1ea60bf7, 0x2b4bbda4, 0x8ec02daa, 0x4090d102, 0xe51b410c, + 0xd0f6f75f, 0x757d6751, 0x9726084e, 0x32ad9840, 0x07402e13, + 0xa2cbbe1d, 0x6c9b42b5, 0xc910d2bb, 0xfcfd64e8, 0x5976f4e6, + 0xe33abc97, 0x46b12c99, 0x735c9aca, 0xd6d70ac4, 0x1887f66c, + 0xbd0c6662, 0x88e1d031, 0x2d6a403f, 0xcf312f20, 0x6ababf2e, + 0x5f57097d, 0xfadc9973, 0x348c65db, 0x9107f5d5, 0xa4ea4386, + 0x0161d388, 0x0b03d525, 0xae88452b, 0x9b65f378, 0x3eee6376, + 0xf0be9fde, 0x55350fd0, 0x60d8b983, 0xc553298d, 0x27084692, + 0x8283d69c, 0xb76e60cf, 0x12e5f0c1, 0xdcb50c69, 0x793e9c67, + 0x4cd32a34, 0xe958ba3a, 0x5314f24b, 0xf69f6245, 0xc372d416, + 0x66f94418, 0xa8a9b8b0, 0x0d2228be, 0x38cf9eed, 0x9d440ee3, + 0x7f1f61fc, 0xda94f1f2, 0xef7947a1, 0x4af2d7af, 0x84a22b07, + 0x2129bb09, 0x14c40d5a, 0xb14f9d54, 0xad2a31b3, 0x08a1a1bd, + 0x3d4c17ee, 0x98c787e0, 0x56977b48, 0xf31ceb46, 0xc6f15d15, + 0x637acd1b, 0x8121a204, 0x24aa320a, 0x11478459, 0xb4cc1457, + 0x7a9ce8ff, 0xdf1778f1, 0xeafacea2, 0x4f715eac, 0xf53d16dd, + 0x50b686d3, 0x655b3080, 0xc0d0a08e, 0x0e805c26, 0xab0bcc28, + 0x9ee67a7b, 0x3b6dea75, 0xd936856a, 0x7cbd1564, 0x4950a337, + 0xecdb3339, 0x228bcf91, 0x87005f9f, 0xb2ede9cc, 0x176679c2, + 0x1d047f6f, 0xb88fef61, 0x8d625932, 0x28e9c93c, 0xe6b93594, + 0x4332a59a, 0x76df13c9, 0xd35483c7, 0x310fecd8, 0x94847cd6, + 0xa169ca85, 0x04e25a8b, 0xcab2a623, 0x6f39362d, 0x5ad4807e, + 0xff5f1070, 0x45135801, 0xe098c80f, 0xd5757e5c, 0x70feee52, + 0xbeae12fa, 0x1b2582f4, 0x2ec834a7, 0x8b43a4a9, 0x6918cbb6, + 0xcc935bb8, 0xf97eedeb, 0x5cf57de5, 0x92a5814d, 0x372e1143, + 0x02c3a710, 0xa748371e, 0x1607aa4a, 0xb38c3a44, 0x86618c17, + 0x23ea1c19, 0xedbae0b1, 0x483170bf, 0x7ddcc6ec, 0xd85756e2, + 0x3a0c39fd, 0x9f87a9f3, 0xaa6a1fa0, 0x0fe18fae, 0xc1b17306, + 0x643ae308, 0x51d7555b, 0xf45cc555, 0x4e108d24, 0xeb9b1d2a, + 0xde76ab79, 0x7bfd3b77, 0xb5adc7df, 0x102657d1, 0x25cbe182, + 0x8040718c, 0x621b1e93, 0xc7908e9d, 0xf27d38ce, 0x57f6a8c0, + 0x99a65468, 0x3c2dc466, 0x09c07235, 0xac4be23b, 0xa629e496, + 0x03a27498, 0x364fc2cb, 0x93c452c5, 0x5d94ae6d, 0xf81f3e63, + 0xcdf28830, 0x6879183e, 0x8a227721, 0x2fa9e72f, 0x1a44517c, + 0xbfcfc172, 0x719f3dda, 0xd414add4, 0xe1f91b87, 0x44728b89, + 0xfe3ec3f8, 0x5bb553f6, 0x6e58e5a5, 0xcbd375ab, 0x05838903, + 0xa008190d, 0x95e5af5e, 0x306e3f50, 0xd235504f, 0x77bec041, + 0x42537612, 0xe7d8e61c, 0x29881ab4, 0x8c038aba, 0xb9ee3ce9, + 0x1c65ace7}}; + +local const z_word_t FAR crc_braid_big_table[][256] = { + {0x0000000000000000, 0x0e908ba500000000, 0x5d26669000000000, + 0x53b6ed3500000000, 0xfb4abdfb00000000, 0xf5da365e00000000, + 0xa66cdb6b00000000, 0xa8fc50ce00000000, 0xb7930b2c00000000, + 0xb903808900000000, 0xeab56dbc00000000, 0xe425e61900000000, + 0x4cd9b6d700000000, 0x42493d7200000000, 0x11ffd04700000000, + 0x1f6f5be200000000, 0x6e27175800000000, 0x60b79cfd00000000, + 0x330171c800000000, 0x3d91fa6d00000000, 0x956daaa300000000, + 0x9bfd210600000000, 0xc84bcc3300000000, 0xc6db479600000000, + 0xd9b41c7400000000, 0xd72497d100000000, 0x84927ae400000000, + 0x8a02f14100000000, 0x22fea18f00000000, 0x2c6e2a2a00000000, + 0x7fd8c71f00000000, 0x71484cba00000000, 0xdc4e2eb000000000, + 0xd2dea51500000000, 0x8168482000000000, 0x8ff8c38500000000, + 0x2704934b00000000, 0x299418ee00000000, 0x7a22f5db00000000, + 0x74b27e7e00000000, 0x6bdd259c00000000, 0x654dae3900000000, + 0x36fb430c00000000, 0x386bc8a900000000, 0x9097986700000000, + 0x9e0713c200000000, 0xcdb1fef700000000, 0xc321755200000000, + 0xb26939e800000000, 0xbcf9b24d00000000, 0xef4f5f7800000000, + 0xe1dfd4dd00000000, 0x4923841300000000, 0x47b30fb600000000, + 0x1405e28300000000, 0x1a95692600000000, 0x05fa32c400000000, + 0x0b6ab96100000000, 0x58dc545400000000, 0x564cdff100000000, + 0xfeb08f3f00000000, 0xf020049a00000000, 0xa396e9af00000000, + 0xad06620a00000000, 0xf99b2dbb00000000, 0xf70ba61e00000000, + 0xa4bd4b2b00000000, 0xaa2dc08e00000000, 0x02d1904000000000, + 0x0c411be500000000, 0x5ff7f6d000000000, 0x51677d7500000000, + 0x4e08269700000000, 0x4098ad3200000000, 0x132e400700000000, + 0x1dbecba200000000, 0xb5429b6c00000000, 0xbbd210c900000000, + 0xe864fdfc00000000, 0xe6f4765900000000, 0x97bc3ae300000000, + 0x992cb14600000000, 0xca9a5c7300000000, 0xc40ad7d600000000, + 0x6cf6871800000000, 0x62660cbd00000000, 0x31d0e18800000000, + 0x3f406a2d00000000, 0x202f31cf00000000, 0x2ebfba6a00000000, + 0x7d09575f00000000, 0x7399dcfa00000000, 0xdb658c3400000000, + 0xd5f5079100000000, 0x8643eaa400000000, 0x88d3610100000000, + 0x25d5030b00000000, 0x2b4588ae00000000, 0x78f3659b00000000, + 0x7663ee3e00000000, 0xde9fbef000000000, 0xd00f355500000000, + 0x83b9d86000000000, 0x8d2953c500000000, 0x9246082700000000, + 0x9cd6838200000000, 0xcf606eb700000000, 0xc1f0e51200000000, + 0x690cb5dc00000000, 0x679c3e7900000000, 0x342ad34c00000000, + 0x3aba58e900000000, 0x4bf2145300000000, 0x45629ff600000000, + 0x16d472c300000000, 0x1844f96600000000, 0xb0b8a9a800000000, + 0xbe28220d00000000, 0xed9ecf3800000000, 0xe30e449d00000000, + 0xfc611f7f00000000, 0xf2f194da00000000, 0xa14779ef00000000, + 0xafd7f24a00000000, 0x072ba28400000000, 0x09bb292100000000, + 0x5a0dc41400000000, 0x549d4fb100000000, 0xb3312aad00000000, + 0xbda1a10800000000, 0xee174c3d00000000, 0xe087c79800000000, + 0x487b975600000000, 0x46eb1cf300000000, 0x155df1c600000000, + 0x1bcd7a6300000000, 0x04a2218100000000, 0x0a32aa2400000000, + 0x5984471100000000, 0x5714ccb400000000, 0xffe89c7a00000000, + 0xf17817df00000000, 0xa2cefaea00000000, 0xac5e714f00000000, + 0xdd163df500000000, 0xd386b65000000000, 0x80305b6500000000, + 0x8ea0d0c000000000, 0x265c800e00000000, 0x28cc0bab00000000, + 0x7b7ae69e00000000, 0x75ea6d3b00000000, 0x6a8536d900000000, + 0x6415bd7c00000000, 0x37a3504900000000, 0x3933dbec00000000, + 0x91cf8b2200000000, 0x9f5f008700000000, 0xcce9edb200000000, + 0xc279661700000000, 0x6f7f041d00000000, 0x61ef8fb800000000, + 0x3259628d00000000, 0x3cc9e92800000000, 0x9435b9e600000000, + 0x9aa5324300000000, 0xc913df7600000000, 0xc78354d300000000, + 0xd8ec0f3100000000, 0xd67c849400000000, 0x85ca69a100000000, + 0x8b5ae20400000000, 0x23a6b2ca00000000, 0x2d36396f00000000, + 0x7e80d45a00000000, 0x70105fff00000000, 0x0158134500000000, + 0x0fc898e000000000, 0x5c7e75d500000000, 0x52eefe7000000000, + 0xfa12aebe00000000, 0xf482251b00000000, 0xa734c82e00000000, + 0xa9a4438b00000000, 0xb6cb186900000000, 0xb85b93cc00000000, + 0xebed7ef900000000, 0xe57df55c00000000, 0x4d81a59200000000, + 0x43112e3700000000, 0x10a7c30200000000, 0x1e3748a700000000, + 0x4aaa071600000000, 0x443a8cb300000000, 0x178c618600000000, + 0x191cea2300000000, 0xb1e0baed00000000, 0xbf70314800000000, + 0xecc6dc7d00000000, 0xe25657d800000000, 0xfd390c3a00000000, + 0xf3a9879f00000000, 0xa01f6aaa00000000, 0xae8fe10f00000000, + 0x0673b1c100000000, 0x08e33a6400000000, 0x5b55d75100000000, + 0x55c55cf400000000, 0x248d104e00000000, 0x2a1d9beb00000000, + 0x79ab76de00000000, 0x773bfd7b00000000, 0xdfc7adb500000000, + 0xd157261000000000, 0x82e1cb2500000000, 0x8c71408000000000, + 0x931e1b6200000000, 0x9d8e90c700000000, 0xce387df200000000, + 0xc0a8f65700000000, 0x6854a69900000000, 0x66c42d3c00000000, + 0x3572c00900000000, 0x3be24bac00000000, 0x96e429a600000000, + 0x9874a20300000000, 0xcbc24f3600000000, 0xc552c49300000000, + 0x6dae945d00000000, 0x633e1ff800000000, 0x3088f2cd00000000, + 0x3e18796800000000, 0x2177228a00000000, 0x2fe7a92f00000000, + 0x7c51441a00000000, 0x72c1cfbf00000000, 0xda3d9f7100000000, + 0xd4ad14d400000000, 0x871bf9e100000000, 0x898b724400000000, + 0xf8c33efe00000000, 0xf653b55b00000000, 0xa5e5586e00000000, + 0xab75d3cb00000000, 0x0389830500000000, 0x0d1908a000000000, + 0x5eafe59500000000, 0x503f6e3000000000, 0x4f5035d200000000, + 0x41c0be7700000000, 0x1276534200000000, 0x1ce6d8e700000000, + 0xb41a882900000000, 0xba8a038c00000000, 0xe93ceeb900000000, + 0xe7ac651c00000000}, + {0x0000000000000000, 0x97a61de700000000, 0x6f4b4a1500000000, + 0xf8ed57f200000000, 0xde96942a00000000, 0x493089cd00000000, + 0xb1ddde3f00000000, 0x267bc3d800000000, 0xbc2d295500000000, + 0x2b8b34b200000000, 0xd366634000000000, 0x44c07ea700000000, + 0x62bbbd7f00000000, 0xf51da09800000000, 0x0df0f76a00000000, + 0x9a56ea8d00000000, 0x785b52aa00000000, 0xeffd4f4d00000000, + 0x171018bf00000000, 0x80b6055800000000, 0xa6cdc68000000000, + 0x316bdb6700000000, 0xc9868c9500000000, 0x5e20917200000000, + 0xc4767bff00000000, 0x53d0661800000000, 0xab3d31ea00000000, + 0x3c9b2c0d00000000, 0x1ae0efd500000000, 0x8d46f23200000000, + 0x75aba5c000000000, 0xe20db82700000000, 0xb1b0d58f00000000, + 0x2616c86800000000, 0xdefb9f9a00000000, 0x495d827d00000000, + 0x6f2641a500000000, 0xf8805c4200000000, 0x006d0bb000000000, + 0x97cb165700000000, 0x0d9dfcda00000000, 0x9a3be13d00000000, + 0x62d6b6cf00000000, 0xf570ab2800000000, 0xd30b68f000000000, + 0x44ad751700000000, 0xbc4022e500000000, 0x2be63f0200000000, + 0xc9eb872500000000, 0x5e4d9ac200000000, 0xa6a0cd3000000000, + 0x3106d0d700000000, 0x177d130f00000000, 0x80db0ee800000000, + 0x7836591a00000000, 0xef9044fd00000000, 0x75c6ae7000000000, + 0xe260b39700000000, 0x1a8de46500000000, 0x8d2bf98200000000, + 0xab503a5a00000000, 0x3cf627bd00000000, 0xc41b704f00000000, + 0x53bd6da800000000, 0x2367dac400000000, 0xb4c1c72300000000, + 0x4c2c90d100000000, 0xdb8a8d3600000000, 0xfdf14eee00000000, + 0x6a57530900000000, 0x92ba04fb00000000, 0x051c191c00000000, + 0x9f4af39100000000, 0x08ecee7600000000, 0xf001b98400000000, + 0x67a7a46300000000, 0x41dc67bb00000000, 0xd67a7a5c00000000, + 0x2e972dae00000000, 0xb931304900000000, 0x5b3c886e00000000, + 0xcc9a958900000000, 0x3477c27b00000000, 0xa3d1df9c00000000, + 0x85aa1c4400000000, 0x120c01a300000000, 0xeae1565100000000, + 0x7d474bb600000000, 0xe711a13b00000000, 0x70b7bcdc00000000, + 0x885aeb2e00000000, 0x1ffcf6c900000000, 0x3987351100000000, + 0xae2128f600000000, 0x56cc7f0400000000, 0xc16a62e300000000, + 0x92d70f4b00000000, 0x057112ac00000000, 0xfd9c455e00000000, + 0x6a3a58b900000000, 0x4c419b6100000000, 0xdbe7868600000000, + 0x230ad17400000000, 0xb4accc9300000000, 0x2efa261e00000000, + 0xb95c3bf900000000, 0x41b16c0b00000000, 0xd61771ec00000000, + 0xf06cb23400000000, 0x67caafd300000000, 0x9f27f82100000000, + 0x0881e5c600000000, 0xea8c5de100000000, 0x7d2a400600000000, + 0x85c717f400000000, 0x12610a1300000000, 0x341ac9cb00000000, + 0xa3bcd42c00000000, 0x5b5183de00000000, 0xccf79e3900000000, + 0x56a174b400000000, 0xc107695300000000, 0x39ea3ea100000000, + 0xae4c234600000000, 0x8837e09e00000000, 0x1f91fd7900000000, + 0xe77caa8b00000000, 0x70dab76c00000000, 0x07c8c55200000000, + 0x906ed8b500000000, 0x68838f4700000000, 0xff2592a000000000, + 0xd95e517800000000, 0x4ef84c9f00000000, 0xb6151b6d00000000, + 0x21b3068a00000000, 0xbbe5ec0700000000, 0x2c43f1e000000000, + 0xd4aea61200000000, 0x4308bbf500000000, 0x6573782d00000000, + 0xf2d565ca00000000, 0x0a38323800000000, 0x9d9e2fdf00000000, + 0x7f9397f800000000, 0xe8358a1f00000000, 0x10d8dded00000000, + 0x877ec00a00000000, 0xa10503d200000000, 0x36a31e3500000000, + 0xce4e49c700000000, 0x59e8542000000000, 0xc3bebead00000000, + 0x5418a34a00000000, 0xacf5f4b800000000, 0x3b53e95f00000000, + 0x1d282a8700000000, 0x8a8e376000000000, 0x7263609200000000, + 0xe5c57d7500000000, 0xb67810dd00000000, 0x21de0d3a00000000, + 0xd9335ac800000000, 0x4e95472f00000000, 0x68ee84f700000000, + 0xff48991000000000, 0x07a5cee200000000, 0x9003d30500000000, + 0x0a55398800000000, 0x9df3246f00000000, 0x651e739d00000000, + 0xf2b86e7a00000000, 0xd4c3ada200000000, 0x4365b04500000000, + 0xbb88e7b700000000, 0x2c2efa5000000000, 0xce23427700000000, + 0x59855f9000000000, 0xa168086200000000, 0x36ce158500000000, + 0x10b5d65d00000000, 0x8713cbba00000000, 0x7ffe9c4800000000, + 0xe85881af00000000, 0x720e6b2200000000, 0xe5a876c500000000, + 0x1d45213700000000, 0x8ae33cd000000000, 0xac98ff0800000000, + 0x3b3ee2ef00000000, 0xc3d3b51d00000000, 0x5475a8fa00000000, + 0x24af1f9600000000, 0xb309027100000000, 0x4be4558300000000, + 0xdc42486400000000, 0xfa398bbc00000000, 0x6d9f965b00000000, + 0x9572c1a900000000, 0x02d4dc4e00000000, 0x988236c300000000, + 0x0f242b2400000000, 0xf7c97cd600000000, 0x606f613100000000, + 0x4614a2e900000000, 0xd1b2bf0e00000000, 0x295fe8fc00000000, + 0xbef9f51b00000000, 0x5cf44d3c00000000, 0xcb5250db00000000, + 0x33bf072900000000, 0xa4191ace00000000, 0x8262d91600000000, + 0x15c4c4f100000000, 0xed29930300000000, 0x7a8f8ee400000000, + 0xe0d9646900000000, 0x777f798e00000000, 0x8f922e7c00000000, + 0x1834339b00000000, 0x3e4ff04300000000, 0xa9e9eda400000000, + 0x5104ba5600000000, 0xc6a2a7b100000000, 0x951fca1900000000, + 0x02b9d7fe00000000, 0xfa54800c00000000, 0x6df29deb00000000, + 0x4b895e3300000000, 0xdc2f43d400000000, 0x24c2142600000000, + 0xb36409c100000000, 0x2932e34c00000000, 0xbe94feab00000000, + 0x4679a95900000000, 0xd1dfb4be00000000, 0xf7a4776600000000, + 0x60026a8100000000, 0x98ef3d7300000000, 0x0f49209400000000, + 0xed4498b300000000, 0x7ae2855400000000, 0x820fd2a600000000, + 0x15a9cf4100000000, 0x33d20c9900000000, 0xa474117e00000000, + 0x5c99468c00000000, 0xcb3f5b6b00000000, 0x5169b1e600000000, + 0xc6cfac0100000000, 0x3e22fbf300000000, 0xa984e61400000000, + 0x8fff25cc00000000, 0x1859382b00000000, 0xe0b46fd900000000, + 0x7712723e00000000}, + {0x0000000000000000, 0x411b8c6e00000000, 0x823618dd00000000, + 0xc32d94b300000000, 0x456b416100000000, 0x0470cd0f00000000, + 0xc75d59bc00000000, 0x8646d5d200000000, 0x8ad682c200000000, + 0xcbcd0eac00000000, 0x08e09a1f00000000, 0x49fb167100000000, + 0xcfbdc3a300000000, 0x8ea64fcd00000000, 0x4d8bdb7e00000000, + 0x0c90571000000000, 0x55ab745e00000000, 0x14b0f83000000000, + 0xd79d6c8300000000, 0x9686e0ed00000000, 0x10c0353f00000000, + 0x51dbb95100000000, 0x92f62de200000000, 0xd3eda18c00000000, + 0xdf7df69c00000000, 0x9e667af200000000, 0x5d4bee4100000000, + 0x1c50622f00000000, 0x9a16b7fd00000000, 0xdb0d3b9300000000, + 0x1820af2000000000, 0x593b234e00000000, 0xaa56e9bc00000000, + 0xeb4d65d200000000, 0x2860f16100000000, 0x697b7d0f00000000, + 0xef3da8dd00000000, 0xae2624b300000000, 0x6d0bb00000000000, + 0x2c103c6e00000000, 0x20806b7e00000000, 0x619be71000000000, + 0xa2b673a300000000, 0xe3adffcd00000000, 0x65eb2a1f00000000, + 0x24f0a67100000000, 0xe7dd32c200000000, 0xa6c6beac00000000, + 0xfffd9de200000000, 0xbee6118c00000000, 0x7dcb853f00000000, + 0x3cd0095100000000, 0xba96dc8300000000, 0xfb8d50ed00000000, + 0x38a0c45e00000000, 0x79bb483000000000, 0x752b1f2000000000, + 0x3430934e00000000, 0xf71d07fd00000000, 0xb6068b9300000000, + 0x30405e4100000000, 0x715bd22f00000000, 0xb276469c00000000, + 0xf36dcaf200000000, 0x15aba3a200000000, 0x54b02fcc00000000, + 0x979dbb7f00000000, 0xd686371100000000, 0x50c0e2c300000000, + 0x11db6ead00000000, 0xd2f6fa1e00000000, 0x93ed767000000000, + 0x9f7d216000000000, 0xde66ad0e00000000, 0x1d4b39bd00000000, + 0x5c50b5d300000000, 0xda16600100000000, 0x9b0dec6f00000000, + 0x582078dc00000000, 0x193bf4b200000000, 0x4000d7fc00000000, + 0x011b5b9200000000, 0xc236cf2100000000, 0x832d434f00000000, + 0x056b969d00000000, 0x44701af300000000, 0x875d8e4000000000, + 0xc646022e00000000, 0xcad6553e00000000, 0x8bcdd95000000000, + 0x48e04de300000000, 0x09fbc18d00000000, 0x8fbd145f00000000, + 0xcea6983100000000, 0x0d8b0c8200000000, 0x4c9080ec00000000, + 0xbffd4a1e00000000, 0xfee6c67000000000, 0x3dcb52c300000000, + 0x7cd0dead00000000, 0xfa960b7f00000000, 0xbb8d871100000000, + 0x78a013a200000000, 0x39bb9fcc00000000, 0x352bc8dc00000000, + 0x743044b200000000, 0xb71dd00100000000, 0xf6065c6f00000000, + 0x704089bd00000000, 0x315b05d300000000, 0xf276916000000000, + 0xb36d1d0e00000000, 0xea563e4000000000, 0xab4db22e00000000, + 0x6860269d00000000, 0x297baaf300000000, 0xaf3d7f2100000000, + 0xee26f34f00000000, 0x2d0b67fc00000000, 0x6c10eb9200000000, + 0x6080bc8200000000, 0x219b30ec00000000, 0xe2b6a45f00000000, + 0xa3ad283100000000, 0x25ebfde300000000, 0x64f0718d00000000, + 0xa7dde53e00000000, 0xe6c6695000000000, 0x6b50369e00000000, + 0x2a4bbaf000000000, 0xe9662e4300000000, 0xa87da22d00000000, + 0x2e3b77ff00000000, 0x6f20fb9100000000, 0xac0d6f2200000000, + 0xed16e34c00000000, 0xe186b45c00000000, 0xa09d383200000000, + 0x63b0ac8100000000, 0x22ab20ef00000000, 0xa4edf53d00000000, + 0xe5f6795300000000, 0x26dbede000000000, 0x67c0618e00000000, + 0x3efb42c000000000, 0x7fe0ceae00000000, 0xbccd5a1d00000000, + 0xfdd6d67300000000, 0x7b9003a100000000, 0x3a8b8fcf00000000, + 0xf9a61b7c00000000, 0xb8bd971200000000, 0xb42dc00200000000, + 0xf5364c6c00000000, 0x361bd8df00000000, 0x770054b100000000, + 0xf146816300000000, 0xb05d0d0d00000000, 0x737099be00000000, + 0x326b15d000000000, 0xc106df2200000000, 0x801d534c00000000, + 0x4330c7ff00000000, 0x022b4b9100000000, 0x846d9e4300000000, + 0xc576122d00000000, 0x065b869e00000000, 0x47400af000000000, + 0x4bd05de000000000, 0x0acbd18e00000000, 0xc9e6453d00000000, + 0x88fdc95300000000, 0x0ebb1c8100000000, 0x4fa090ef00000000, + 0x8c8d045c00000000, 0xcd96883200000000, 0x94adab7c00000000, + 0xd5b6271200000000, 0x169bb3a100000000, 0x57803fcf00000000, + 0xd1c6ea1d00000000, 0x90dd667300000000, 0x53f0f2c000000000, + 0x12eb7eae00000000, 0x1e7b29be00000000, 0x5f60a5d000000000, + 0x9c4d316300000000, 0xdd56bd0d00000000, 0x5b1068df00000000, + 0x1a0be4b100000000, 0xd926700200000000, 0x983dfc6c00000000, + 0x7efb953c00000000, 0x3fe0195200000000, 0xfccd8de100000000, + 0xbdd6018f00000000, 0x3b90d45d00000000, 0x7a8b583300000000, + 0xb9a6cc8000000000, 0xf8bd40ee00000000, 0xf42d17fe00000000, + 0xb5369b9000000000, 0x761b0f2300000000, 0x3700834d00000000, + 0xb146569f00000000, 0xf05ddaf100000000, 0x33704e4200000000, + 0x726bc22c00000000, 0x2b50e16200000000, 0x6a4b6d0c00000000, + 0xa966f9bf00000000, 0xe87d75d100000000, 0x6e3ba00300000000, + 0x2f202c6d00000000, 0xec0db8de00000000, 0xad1634b000000000, + 0xa18663a000000000, 0xe09defce00000000, 0x23b07b7d00000000, + 0x62abf71300000000, 0xe4ed22c100000000, 0xa5f6aeaf00000000, + 0x66db3a1c00000000, 0x27c0b67200000000, 0xd4ad7c8000000000, + 0x95b6f0ee00000000, 0x569b645d00000000, 0x1780e83300000000, + 0x91c63de100000000, 0xd0ddb18f00000000, 0x13f0253c00000000, + 0x52eba95200000000, 0x5e7bfe4200000000, 0x1f60722c00000000, + 0xdc4de69f00000000, 0x9d566af100000000, 0x1b10bf2300000000, + 0x5a0b334d00000000, 0x9926a7fe00000000, 0xd83d2b9000000000, + 0x810608de00000000, 0xc01d84b000000000, 0x0330100300000000, + 0x422b9c6d00000000, 0xc46d49bf00000000, 0x8576c5d100000000, + 0x465b516200000000, 0x0740dd0c00000000, 0x0bd08a1c00000000, + 0x4acb067200000000, 0x89e692c100000000, 0xc8fd1eaf00000000, + 0x4ebbcb7d00000000, 0x0fa0471300000000, 0xcc8dd3a000000000, + 0x8d965fce00000000}, + {0x0000000000000000, 0x1dfdb50100000000, 0x3afa6b0300000000, + 0x2707de0200000000, 0x74f4d70600000000, 0x6909620700000000, + 0x4e0ebc0500000000, 0x53f3090400000000, 0xe8e8af0d00000000, + 0xf5151a0c00000000, 0xd212c40e00000000, 0xcfef710f00000000, + 0x9c1c780b00000000, 0x81e1cd0a00000000, 0xa6e6130800000000, + 0xbb1ba60900000000, 0xd0d15f1b00000000, 0xcd2cea1a00000000, + 0xea2b341800000000, 0xf7d6811900000000, 0xa425881d00000000, + 0xb9d83d1c00000000, 0x9edfe31e00000000, 0x8322561f00000000, + 0x3839f01600000000, 0x25c4451700000000, 0x02c39b1500000000, + 0x1f3e2e1400000000, 0x4ccd271000000000, 0x5130921100000000, + 0x76374c1300000000, 0x6bcaf91200000000, 0xa0a3bf3600000000, + 0xbd5e0a3700000000, 0x9a59d43500000000, 0x87a4613400000000, + 0xd457683000000000, 0xc9aadd3100000000, 0xeead033300000000, + 0xf350b63200000000, 0x484b103b00000000, 0x55b6a53a00000000, + 0x72b17b3800000000, 0x6f4cce3900000000, 0x3cbfc73d00000000, + 0x2142723c00000000, 0x0645ac3e00000000, 0x1bb8193f00000000, + 0x7072e02d00000000, 0x6d8f552c00000000, 0x4a888b2e00000000, + 0x57753e2f00000000, 0x0486372b00000000, 0x197b822a00000000, + 0x3e7c5c2800000000, 0x2381e92900000000, 0x989a4f2000000000, + 0x8567fa2100000000, 0xa260242300000000, 0xbf9d912200000000, + 0xec6e982600000000, 0xf1932d2700000000, 0xd694f32500000000, + 0xcb69462400000000, 0x40477f6d00000000, 0x5dbaca6c00000000, + 0x7abd146e00000000, 0x6740a16f00000000, 0x34b3a86b00000000, + 0x294e1d6a00000000, 0x0e49c36800000000, 0x13b4766900000000, + 0xa8afd06000000000, 0xb552656100000000, 0x9255bb6300000000, + 0x8fa80e6200000000, 0xdc5b076600000000, 0xc1a6b26700000000, + 0xe6a16c6500000000, 0xfb5cd96400000000, 0x9096207600000000, + 0x8d6b957700000000, 0xaa6c4b7500000000, 0xb791fe7400000000, + 0xe462f77000000000, 0xf99f427100000000, 0xde989c7300000000, + 0xc365297200000000, 0x787e8f7b00000000, 0x65833a7a00000000, + 0x4284e47800000000, 0x5f79517900000000, 0x0c8a587d00000000, + 0x1177ed7c00000000, 0x3670337e00000000, 0x2b8d867f00000000, + 0xe0e4c05b00000000, 0xfd19755a00000000, 0xda1eab5800000000, + 0xc7e31e5900000000, 0x9410175d00000000, 0x89eda25c00000000, + 0xaeea7c5e00000000, 0xb317c95f00000000, 0x080c6f5600000000, + 0x15f1da5700000000, 0x32f6045500000000, 0x2f0bb15400000000, + 0x7cf8b85000000000, 0x61050d5100000000, 0x4602d35300000000, + 0x5bff665200000000, 0x30359f4000000000, 0x2dc82a4100000000, + 0x0acff44300000000, 0x1732414200000000, 0x44c1484600000000, + 0x593cfd4700000000, 0x7e3b234500000000, 0x63c6964400000000, + 0xd8dd304d00000000, 0xc520854c00000000, 0xe2275b4e00000000, + 0xffdaee4f00000000, 0xac29e74b00000000, 0xb1d4524a00000000, + 0x96d38c4800000000, 0x8b2e394900000000, 0x808efeda00000000, + 0x9d734bdb00000000, 0xba7495d900000000, 0xa78920d800000000, + 0xf47a29dc00000000, 0xe9879cdd00000000, 0xce8042df00000000, + 0xd37df7de00000000, 0x686651d700000000, 0x759be4d600000000, + 0x529c3ad400000000, 0x4f618fd500000000, 0x1c9286d100000000, + 0x016f33d000000000, 0x2668edd200000000, 0x3b9558d300000000, + 0x505fa1c100000000, 0x4da214c000000000, 0x6aa5cac200000000, + 0x77587fc300000000, 0x24ab76c700000000, 0x3956c3c600000000, + 0x1e511dc400000000, 0x03aca8c500000000, 0xb8b70ecc00000000, + 0xa54abbcd00000000, 0x824d65cf00000000, 0x9fb0d0ce00000000, + 0xcc43d9ca00000000, 0xd1be6ccb00000000, 0xf6b9b2c900000000, + 0xeb4407c800000000, 0x202d41ec00000000, 0x3dd0f4ed00000000, + 0x1ad72aef00000000, 0x072a9fee00000000, 0x54d996ea00000000, + 0x492423eb00000000, 0x6e23fde900000000, 0x73de48e800000000, + 0xc8c5eee100000000, 0xd5385be000000000, 0xf23f85e200000000, + 0xefc230e300000000, 0xbc3139e700000000, 0xa1cc8ce600000000, + 0x86cb52e400000000, 0x9b36e7e500000000, 0xf0fc1ef700000000, + 0xed01abf600000000, 0xca0675f400000000, 0xd7fbc0f500000000, + 0x8408c9f100000000, 0x99f57cf000000000, 0xbef2a2f200000000, + 0xa30f17f300000000, 0x1814b1fa00000000, 0x05e904fb00000000, + 0x22eedaf900000000, 0x3f136ff800000000, 0x6ce066fc00000000, + 0x711dd3fd00000000, 0x561a0dff00000000, 0x4be7b8fe00000000, + 0xc0c981b700000000, 0xdd3434b600000000, 0xfa33eab400000000, + 0xe7ce5fb500000000, 0xb43d56b100000000, 0xa9c0e3b000000000, + 0x8ec73db200000000, 0x933a88b300000000, 0x28212eba00000000, + 0x35dc9bbb00000000, 0x12db45b900000000, 0x0f26f0b800000000, + 0x5cd5f9bc00000000, 0x41284cbd00000000, 0x662f92bf00000000, + 0x7bd227be00000000, 0x1018deac00000000, 0x0de56bad00000000, + 0x2ae2b5af00000000, 0x371f00ae00000000, 0x64ec09aa00000000, + 0x7911bcab00000000, 0x5e1662a900000000, 0x43ebd7a800000000, + 0xf8f071a100000000, 0xe50dc4a000000000, 0xc20a1aa200000000, + 0xdff7afa300000000, 0x8c04a6a700000000, 0x91f913a600000000, + 0xb6fecda400000000, 0xab0378a500000000, 0x606a3e8100000000, + 0x7d978b8000000000, 0x5a90558200000000, 0x476de08300000000, + 0x149ee98700000000, 0x09635c8600000000, 0x2e64828400000000, + 0x3399378500000000, 0x8882918c00000000, 0x957f248d00000000, + 0xb278fa8f00000000, 0xaf854f8e00000000, 0xfc76468a00000000, + 0xe18bf38b00000000, 0xc68c2d8900000000, 0xdb71988800000000, + 0xb0bb619a00000000, 0xad46d49b00000000, 0x8a410a9900000000, + 0x97bcbf9800000000, 0xc44fb69c00000000, 0xd9b2039d00000000, + 0xfeb5dd9f00000000, 0xe348689e00000000, 0x5853ce9700000000, + 0x45ae7b9600000000, 0x62a9a59400000000, 0x7f54109500000000, + 0x2ca7199100000000, 0x315aac9000000000, 0x165d729200000000, + 0x0ba0c79300000000}, + {0x0000000000000000, 0x24d9076300000000, 0x48b20fc600000000, + 0x6c6b08a500000000, 0xd1626e5700000000, 0xf5bb693400000000, + 0x99d0619100000000, 0xbd0966f200000000, 0xa2c5dcae00000000, + 0x861cdbcd00000000, 0xea77d36800000000, 0xceaed40b00000000, + 0x73a7b2f900000000, 0x577eb59a00000000, 0x3b15bd3f00000000, + 0x1fccba5c00000000, 0x058dc88600000000, 0x2154cfe500000000, + 0x4d3fc74000000000, 0x69e6c02300000000, 0xd4efa6d100000000, + 0xf036a1b200000000, 0x9c5da91700000000, 0xb884ae7400000000, + 0xa748142800000000, 0x8391134b00000000, 0xeffa1bee00000000, + 0xcb231c8d00000000, 0x762a7a7f00000000, 0x52f37d1c00000000, + 0x3e9875b900000000, 0x1a4172da00000000, 0x4b1ce0d600000000, + 0x6fc5e7b500000000, 0x03aeef1000000000, 0x2777e87300000000, + 0x9a7e8e8100000000, 0xbea789e200000000, 0xd2cc814700000000, + 0xf615862400000000, 0xe9d93c7800000000, 0xcd003b1b00000000, + 0xa16b33be00000000, 0x85b234dd00000000, 0x38bb522f00000000, + 0x1c62554c00000000, 0x70095de900000000, 0x54d05a8a00000000, + 0x4e91285000000000, 0x6a482f3300000000, 0x0623279600000000, + 0x22fa20f500000000, 0x9ff3460700000000, 0xbb2a416400000000, + 0xd74149c100000000, 0xf3984ea200000000, 0xec54f4fe00000000, + 0xc88df39d00000000, 0xa4e6fb3800000000, 0x803ffc5b00000000, + 0x3d369aa900000000, 0x19ef9dca00000000, 0x7584956f00000000, + 0x515d920c00000000, 0xd73eb17600000000, 0xf3e7b61500000000, + 0x9f8cbeb000000000, 0xbb55b9d300000000, 0x065cdf2100000000, + 0x2285d84200000000, 0x4eeed0e700000000, 0x6a37d78400000000, + 0x75fb6dd800000000, 0x51226abb00000000, 0x3d49621e00000000, + 0x1990657d00000000, 0xa499038f00000000, 0x804004ec00000000, + 0xec2b0c4900000000, 0xc8f20b2a00000000, 0xd2b379f000000000, + 0xf66a7e9300000000, 0x9a01763600000000, 0xbed8715500000000, + 0x03d117a700000000, 0x270810c400000000, 0x4b63186100000000, + 0x6fba1f0200000000, 0x7076a55e00000000, 0x54afa23d00000000, + 0x38c4aa9800000000, 0x1c1dadfb00000000, 0xa114cb0900000000, + 0x85cdcc6a00000000, 0xe9a6c4cf00000000, 0xcd7fc3ac00000000, + 0x9c2251a000000000, 0xb8fb56c300000000, 0xd4905e6600000000, + 0xf049590500000000, 0x4d403ff700000000, 0x6999389400000000, + 0x05f2303100000000, 0x212b375200000000, 0x3ee78d0e00000000, + 0x1a3e8a6d00000000, 0x765582c800000000, 0x528c85ab00000000, + 0xef85e35900000000, 0xcb5ce43a00000000, 0xa737ec9f00000000, + 0x83eeebfc00000000, 0x99af992600000000, 0xbd769e4500000000, + 0xd11d96e000000000, 0xf5c4918300000000, 0x48cdf77100000000, + 0x6c14f01200000000, 0x007ff8b700000000, 0x24a6ffd400000000, + 0x3b6a458800000000, 0x1fb342eb00000000, 0x73d84a4e00000000, + 0x57014d2d00000000, 0xea082bdf00000000, 0xced12cbc00000000, + 0xa2ba241900000000, 0x8663237a00000000, 0xae7d62ed00000000, + 0x8aa4658e00000000, 0xe6cf6d2b00000000, 0xc2166a4800000000, + 0x7f1f0cba00000000, 0x5bc60bd900000000, 0x37ad037c00000000, + 0x1374041f00000000, 0x0cb8be4300000000, 0x2861b92000000000, + 0x440ab18500000000, 0x60d3b6e600000000, 0xdddad01400000000, + 0xf903d77700000000, 0x9568dfd200000000, 0xb1b1d8b100000000, + 0xabf0aa6b00000000, 0x8f29ad0800000000, 0xe342a5ad00000000, + 0xc79ba2ce00000000, 0x7a92c43c00000000, 0x5e4bc35f00000000, + 0x3220cbfa00000000, 0x16f9cc9900000000, 0x093576c500000000, + 0x2dec71a600000000, 0x4187790300000000, 0x655e7e6000000000, + 0xd857189200000000, 0xfc8e1ff100000000, 0x90e5175400000000, + 0xb43c103700000000, 0xe561823b00000000, 0xc1b8855800000000, + 0xadd38dfd00000000, 0x890a8a9e00000000, 0x3403ec6c00000000, + 0x10daeb0f00000000, 0x7cb1e3aa00000000, 0x5868e4c900000000, + 0x47a45e9500000000, 0x637d59f600000000, 0x0f16515300000000, + 0x2bcf563000000000, 0x96c630c200000000, 0xb21f37a100000000, + 0xde743f0400000000, 0xfaad386700000000, 0xe0ec4abd00000000, + 0xc4354dde00000000, 0xa85e457b00000000, 0x8c87421800000000, + 0x318e24ea00000000, 0x1557238900000000, 0x793c2b2c00000000, + 0x5de52c4f00000000, 0x4229961300000000, 0x66f0917000000000, + 0x0a9b99d500000000, 0x2e429eb600000000, 0x934bf84400000000, + 0xb792ff2700000000, 0xdbf9f78200000000, 0xff20f0e100000000, + 0x7943d39b00000000, 0x5d9ad4f800000000, 0x31f1dc5d00000000, + 0x1528db3e00000000, 0xa821bdcc00000000, 0x8cf8baaf00000000, + 0xe093b20a00000000, 0xc44ab56900000000, 0xdb860f3500000000, + 0xff5f085600000000, 0x933400f300000000, 0xb7ed079000000000, + 0x0ae4616200000000, 0x2e3d660100000000, 0x42566ea400000000, + 0x668f69c700000000, 0x7cce1b1d00000000, 0x58171c7e00000000, + 0x347c14db00000000, 0x10a513b800000000, 0xadac754a00000000, + 0x8975722900000000, 0xe51e7a8c00000000, 0xc1c77def00000000, + 0xde0bc7b300000000, 0xfad2c0d000000000, 0x96b9c87500000000, + 0xb260cf1600000000, 0x0f69a9e400000000, 0x2bb0ae8700000000, + 0x47dba62200000000, 0x6302a14100000000, 0x325f334d00000000, + 0x1686342e00000000, 0x7aed3c8b00000000, 0x5e343be800000000, + 0xe33d5d1a00000000, 0xc7e45a7900000000, 0xab8f52dc00000000, + 0x8f5655bf00000000, 0x909aefe300000000, 0xb443e88000000000, + 0xd828e02500000000, 0xfcf1e74600000000, 0x41f881b400000000, + 0x652186d700000000, 0x094a8e7200000000, 0x2d93891100000000, + 0x37d2fbcb00000000, 0x130bfca800000000, 0x7f60f40d00000000, + 0x5bb9f36e00000000, 0xe6b0959c00000000, 0xc26992ff00000000, + 0xae029a5a00000000, 0x8adb9d3900000000, 0x9517276500000000, + 0xb1ce200600000000, 0xdda528a300000000, 0xf97c2fc000000000, + 0x4475493200000000, 0x60ac4e5100000000, 0x0cc746f400000000, + 0x281e419700000000}, + {0x0000000000000000, 0x08e3603c00000000, 0x10c6c17800000000, + 0x1825a14400000000, 0x208c83f100000000, 0x286fe3cd00000000, + 0x304a428900000000, 0x38a922b500000000, 0x011e763800000000, + 0x09fd160400000000, 0x11d8b74000000000, 0x193bd77c00000000, + 0x2192f5c900000000, 0x297195f500000000, 0x315434b100000000, + 0x39b7548d00000000, 0x023cec7000000000, 0x0adf8c4c00000000, + 0x12fa2d0800000000, 0x1a194d3400000000, 0x22b06f8100000000, + 0x2a530fbd00000000, 0x3276aef900000000, 0x3a95cec500000000, + 0x03229a4800000000, 0x0bc1fa7400000000, 0x13e45b3000000000, + 0x1b073b0c00000000, 0x23ae19b900000000, 0x2b4d798500000000, + 0x3368d8c100000000, 0x3b8bb8fd00000000, 0x0478d8e100000000, + 0x0c9bb8dd00000000, 0x14be199900000000, 0x1c5d79a500000000, + 0x24f45b1000000000, 0x2c173b2c00000000, 0x34329a6800000000, + 0x3cd1fa5400000000, 0x0566aed900000000, 0x0d85cee500000000, + 0x15a06fa100000000, 0x1d430f9d00000000, 0x25ea2d2800000000, + 0x2d094d1400000000, 0x352cec5000000000, 0x3dcf8c6c00000000, + 0x0644349100000000, 0x0ea754ad00000000, 0x1682f5e900000000, + 0x1e6195d500000000, 0x26c8b76000000000, 0x2e2bd75c00000000, + 0x360e761800000000, 0x3eed162400000000, 0x075a42a900000000, + 0x0fb9229500000000, 0x179c83d100000000, 0x1f7fe3ed00000000, + 0x27d6c15800000000, 0x2f35a16400000000, 0x3710002000000000, + 0x3ff3601c00000000, 0x49f6c11800000000, 0x4115a12400000000, + 0x5930006000000000, 0x51d3605c00000000, 0x697a42e900000000, + 0x619922d500000000, 0x79bc839100000000, 0x715fe3ad00000000, + 0x48e8b72000000000, 0x400bd71c00000000, 0x582e765800000000, + 0x50cd166400000000, 0x686434d100000000, 0x608754ed00000000, + 0x78a2f5a900000000, 0x7041959500000000, 0x4bca2d6800000000, + 0x43294d5400000000, 0x5b0cec1000000000, 0x53ef8c2c00000000, + 0x6b46ae9900000000, 0x63a5cea500000000, 0x7b806fe100000000, + 0x73630fdd00000000, 0x4ad45b5000000000, 0x42373b6c00000000, + 0x5a129a2800000000, 0x52f1fa1400000000, 0x6a58d8a100000000, + 0x62bbb89d00000000, 0x7a9e19d900000000, 0x727d79e500000000, + 0x4d8e19f900000000, 0x456d79c500000000, 0x5d48d88100000000, + 0x55abb8bd00000000, 0x6d029a0800000000, 0x65e1fa3400000000, + 0x7dc45b7000000000, 0x75273b4c00000000, 0x4c906fc100000000, + 0x44730ffd00000000, 0x5c56aeb900000000, 0x54b5ce8500000000, + 0x6c1cec3000000000, 0x64ff8c0c00000000, 0x7cda2d4800000000, + 0x74394d7400000000, 0x4fb2f58900000000, 0x475195b500000000, + 0x5f7434f100000000, 0x579754cd00000000, 0x6f3e767800000000, + 0x67dd164400000000, 0x7ff8b70000000000, 0x771bd73c00000000, + 0x4eac83b100000000, 0x464fe38d00000000, 0x5e6a42c900000000, + 0x568922f500000000, 0x6e20004000000000, 0x66c3607c00000000, + 0x7ee6c13800000000, 0x7605a10400000000, 0x92ec833100000000, + 0x9a0fe30d00000000, 0x822a424900000000, 0x8ac9227500000000, + 0xb26000c000000000, 0xba8360fc00000000, 0xa2a6c1b800000000, + 0xaa45a18400000000, 0x93f2f50900000000, 0x9b11953500000000, + 0x8334347100000000, 0x8bd7544d00000000, 0xb37e76f800000000, + 0xbb9d16c400000000, 0xa3b8b78000000000, 0xab5bd7bc00000000, + 0x90d06f4100000000, 0x98330f7d00000000, 0x8016ae3900000000, + 0x88f5ce0500000000, 0xb05cecb000000000, 0xb8bf8c8c00000000, + 0xa09a2dc800000000, 0xa8794df400000000, 0x91ce197900000000, + 0x992d794500000000, 0x8108d80100000000, 0x89ebb83d00000000, + 0xb1429a8800000000, 0xb9a1fab400000000, 0xa1845bf000000000, + 0xa9673bcc00000000, 0x96945bd000000000, 0x9e773bec00000000, + 0x86529aa800000000, 0x8eb1fa9400000000, 0xb618d82100000000, + 0xbefbb81d00000000, 0xa6de195900000000, 0xae3d796500000000, + 0x978a2de800000000, 0x9f694dd400000000, 0x874cec9000000000, + 0x8faf8cac00000000, 0xb706ae1900000000, 0xbfe5ce2500000000, + 0xa7c06f6100000000, 0xaf230f5d00000000, 0x94a8b7a000000000, + 0x9c4bd79c00000000, 0x846e76d800000000, 0x8c8d16e400000000, + 0xb424345100000000, 0xbcc7546d00000000, 0xa4e2f52900000000, + 0xac01951500000000, 0x95b6c19800000000, 0x9d55a1a400000000, + 0x857000e000000000, 0x8d9360dc00000000, 0xb53a426900000000, + 0xbdd9225500000000, 0xa5fc831100000000, 0xad1fe32d00000000, + 0xdb1a422900000000, 0xd3f9221500000000, 0xcbdc835100000000, + 0xc33fe36d00000000, 0xfb96c1d800000000, 0xf375a1e400000000, + 0xeb5000a000000000, 0xe3b3609c00000000, 0xda04341100000000, + 0xd2e7542d00000000, 0xcac2f56900000000, 0xc221955500000000, + 0xfa88b7e000000000, 0xf26bd7dc00000000, 0xea4e769800000000, + 0xe2ad16a400000000, 0xd926ae5900000000, 0xd1c5ce6500000000, + 0xc9e06f2100000000, 0xc1030f1d00000000, 0xf9aa2da800000000, + 0xf1494d9400000000, 0xe96cecd000000000, 0xe18f8cec00000000, + 0xd838d86100000000, 0xd0dbb85d00000000, 0xc8fe191900000000, + 0xc01d792500000000, 0xf8b45b9000000000, 0xf0573bac00000000, + 0xe8729ae800000000, 0xe091fad400000000, 0xdf629ac800000000, + 0xd781faf400000000, 0xcfa45bb000000000, 0xc7473b8c00000000, + 0xffee193900000000, 0xf70d790500000000, 0xef28d84100000000, + 0xe7cbb87d00000000, 0xde7cecf000000000, 0xd69f8ccc00000000, + 0xceba2d8800000000, 0xc6594db400000000, 0xfef06f0100000000, + 0xf6130f3d00000000, 0xee36ae7900000000, 0xe6d5ce4500000000, + 0xdd5e76b800000000, 0xd5bd168400000000, 0xcd98b7c000000000, + 0xc57bd7fc00000000, 0xfdd2f54900000000, 0xf531957500000000, + 0xed14343100000000, 0xe5f7540d00000000, 0xdc40008000000000, + 0xd4a360bc00000000, 0xcc86c1f800000000, 0xc465a1c400000000, + 0xfccc837100000000, 0xf42fe34d00000000, 0xec0a420900000000, + 0xe4e9223500000000}, + {0x0000000000000000, 0xd1e8e70e00000000, 0xa2d1cf1d00000000, + 0x7339281300000000, 0x44a39f3b00000000, 0x954b783500000000, + 0xe672502600000000, 0x379ab72800000000, 0x88463f7700000000, + 0x59aed87900000000, 0x2a97f06a00000000, 0xfb7f176400000000, + 0xcce5a04c00000000, 0x1d0d474200000000, 0x6e346f5100000000, + 0xbfdc885f00000000, 0x108d7eee00000000, 0xc16599e000000000, + 0xb25cb1f300000000, 0x63b456fd00000000, 0x542ee1d500000000, + 0x85c606db00000000, 0xf6ff2ec800000000, 0x2717c9c600000000, + 0x98cb419900000000, 0x4923a69700000000, 0x3a1a8e8400000000, + 0xebf2698a00000000, 0xdc68dea200000000, 0x0d8039ac00000000, + 0x7eb911bf00000000, 0xaf51f6b100000000, 0x611c8c0700000000, + 0xb0f46b0900000000, 0xc3cd431a00000000, 0x1225a41400000000, + 0x25bf133c00000000, 0xf457f43200000000, 0x876edc2100000000, + 0x56863b2f00000000, 0xe95ab37000000000, 0x38b2547e00000000, + 0x4b8b7c6d00000000, 0x9a639b6300000000, 0xadf92c4b00000000, + 0x7c11cb4500000000, 0x0f28e35600000000, 0xdec0045800000000, + 0x7191f2e900000000, 0xa07915e700000000, 0xd3403df400000000, + 0x02a8dafa00000000, 0x35326dd200000000, 0xe4da8adc00000000, + 0x97e3a2cf00000000, 0x460b45c100000000, 0xf9d7cd9e00000000, + 0x283f2a9000000000, 0x5b06028300000000, 0x8aeee58d00000000, + 0xbd7452a500000000, 0x6c9cb5ab00000000, 0x1fa59db800000000, + 0xce4d7ab600000000, 0xc238180f00000000, 0x13d0ff0100000000, + 0x60e9d71200000000, 0xb101301c00000000, 0x869b873400000000, + 0x5773603a00000000, 0x244a482900000000, 0xf5a2af2700000000, + 0x4a7e277800000000, 0x9b96c07600000000, 0xe8afe86500000000, + 0x39470f6b00000000, 0x0eddb84300000000, 0xdf355f4d00000000, + 0xac0c775e00000000, 0x7de4905000000000, 0xd2b566e100000000, + 0x035d81ef00000000, 0x7064a9fc00000000, 0xa18c4ef200000000, + 0x9616f9da00000000, 0x47fe1ed400000000, 0x34c736c700000000, + 0xe52fd1c900000000, 0x5af3599600000000, 0x8b1bbe9800000000, + 0xf822968b00000000, 0x29ca718500000000, 0x1e50c6ad00000000, + 0xcfb821a300000000, 0xbc8109b000000000, 0x6d69eebe00000000, + 0xa324940800000000, 0x72cc730600000000, 0x01f55b1500000000, + 0xd01dbc1b00000000, 0xe7870b3300000000, 0x366fec3d00000000, + 0x4556c42e00000000, 0x94be232000000000, 0x2b62ab7f00000000, + 0xfa8a4c7100000000, 0x89b3646200000000, 0x585b836c00000000, + 0x6fc1344400000000, 0xbe29d34a00000000, 0xcd10fb5900000000, + 0x1cf81c5700000000, 0xb3a9eae600000000, 0x62410de800000000, + 0x117825fb00000000, 0xc090c2f500000000, 0xf70a75dd00000000, + 0x26e292d300000000, 0x55dbbac000000000, 0x84335dce00000000, + 0x3befd59100000000, 0xea07329f00000000, 0x993e1a8c00000000, + 0x48d6fd8200000000, 0x7f4c4aaa00000000, 0xaea4ada400000000, + 0xdd9d85b700000000, 0x0c7562b900000000, 0x8471301e00000000, + 0x5599d71000000000, 0x26a0ff0300000000, 0xf748180d00000000, + 0xc0d2af2500000000, 0x113a482b00000000, 0x6203603800000000, + 0xb3eb873600000000, 0x0c370f6900000000, 0xdddfe86700000000, + 0xaee6c07400000000, 0x7f0e277a00000000, 0x4894905200000000, + 0x997c775c00000000, 0xea455f4f00000000, 0x3badb84100000000, + 0x94fc4ef000000000, 0x4514a9fe00000000, 0x362d81ed00000000, + 0xe7c566e300000000, 0xd05fd1cb00000000, 0x01b736c500000000, + 0x728e1ed600000000, 0xa366f9d800000000, 0x1cba718700000000, + 0xcd52968900000000, 0xbe6bbe9a00000000, 0x6f83599400000000, + 0x5819eebc00000000, 0x89f109b200000000, 0xfac821a100000000, + 0x2b20c6af00000000, 0xe56dbc1900000000, 0x34855b1700000000, + 0x47bc730400000000, 0x9654940a00000000, 0xa1ce232200000000, + 0x7026c42c00000000, 0x031fec3f00000000, 0xd2f70b3100000000, + 0x6d2b836e00000000, 0xbcc3646000000000, 0xcffa4c7300000000, + 0x1e12ab7d00000000, 0x29881c5500000000, 0xf860fb5b00000000, + 0x8b59d34800000000, 0x5ab1344600000000, 0xf5e0c2f700000000, + 0x240825f900000000, 0x57310dea00000000, 0x86d9eae400000000, + 0xb1435dcc00000000, 0x60abbac200000000, 0x139292d100000000, + 0xc27a75df00000000, 0x7da6fd8000000000, 0xac4e1a8e00000000, + 0xdf77329d00000000, 0x0e9fd59300000000, 0x390562bb00000000, + 0xe8ed85b500000000, 0x9bd4ada600000000, 0x4a3c4aa800000000, + 0x4649281100000000, 0x97a1cf1f00000000, 0xe498e70c00000000, + 0x3570000200000000, 0x02eab72a00000000, 0xd302502400000000, + 0xa03b783700000000, 0x71d39f3900000000, 0xce0f176600000000, + 0x1fe7f06800000000, 0x6cded87b00000000, 0xbd363f7500000000, + 0x8aac885d00000000, 0x5b446f5300000000, 0x287d474000000000, + 0xf995a04e00000000, 0x56c456ff00000000, 0x872cb1f100000000, + 0xf41599e200000000, 0x25fd7eec00000000, 0x1267c9c400000000, + 0xc38f2eca00000000, 0xb0b606d900000000, 0x615ee1d700000000, + 0xde82698800000000, 0x0f6a8e8600000000, 0x7c53a69500000000, + 0xadbb419b00000000, 0x9a21f6b300000000, 0x4bc911bd00000000, + 0x38f039ae00000000, 0xe918dea000000000, 0x2755a41600000000, + 0xf6bd431800000000, 0x85846b0b00000000, 0x546c8c0500000000, + 0x63f63b2d00000000, 0xb21edc2300000000, 0xc127f43000000000, + 0x10cf133e00000000, 0xaf139b6100000000, 0x7efb7c6f00000000, + 0x0dc2547c00000000, 0xdc2ab37200000000, 0xebb0045a00000000, + 0x3a58e35400000000, 0x4961cb4700000000, 0x98892c4900000000, + 0x37d8daf800000000, 0xe6303df600000000, 0x950915e500000000, + 0x44e1f2eb00000000, 0x737b45c300000000, 0xa293a2cd00000000, + 0xd1aa8ade00000000, 0x00426dd000000000, 0xbf9ee58f00000000, + 0x6e76028100000000, 0x1d4f2a9200000000, 0xcca7cd9c00000000, + 0xfb3d7ab400000000, 0x2ad59dba00000000, 0x59ecb5a900000000, + 0x880452a700000000}, + {0x0000000000000000, 0xaa05daf100000000, 0x150dc53800000000, + 0xbf081fc900000000, 0x2a1a8a7100000000, 0x801f508000000000, + 0x3f174f4900000000, 0x951295b800000000, 0x543414e300000000, + 0xfe31ce1200000000, 0x4139d1db00000000, 0xeb3c0b2a00000000, + 0x7e2e9e9200000000, 0xd42b446300000000, 0x6b235baa00000000, + 0xc126815b00000000, 0xe96e591d00000000, 0x436b83ec00000000, + 0xfc639c2500000000, 0x566646d400000000, 0xc374d36c00000000, + 0x6971099d00000000, 0xd679165400000000, 0x7c7ccca500000000, + 0xbd5a4dfe00000000, 0x175f970f00000000, 0xa85788c600000000, + 0x0252523700000000, 0x9740c78f00000000, 0x3d451d7e00000000, + 0x824d02b700000000, 0x2848d84600000000, 0xd2ddb23a00000000, + 0x78d868cb00000000, 0xc7d0770200000000, 0x6dd5adf300000000, + 0xf8c7384b00000000, 0x52c2e2ba00000000, 0xedcafd7300000000, + 0x47cf278200000000, 0x86e9a6d900000000, 0x2cec7c2800000000, + 0x93e463e100000000, 0x39e1b91000000000, 0xacf32ca800000000, + 0x06f6f65900000000, 0xb9fee99000000000, 0x13fb336100000000, + 0x3bb3eb2700000000, 0x91b631d600000000, 0x2ebe2e1f00000000, + 0x84bbf4ee00000000, 0x11a9615600000000, 0xbbacbba700000000, + 0x04a4a46e00000000, 0xaea17e9f00000000, 0x6f87ffc400000000, + 0xc582253500000000, 0x7a8a3afc00000000, 0xd08fe00d00000000, + 0x459d75b500000000, 0xef98af4400000000, 0x5090b08d00000000, + 0xfa956a7c00000000, 0xa4bb657500000000, 0x0ebebf8400000000, + 0xb1b6a04d00000000, 0x1bb37abc00000000, 0x8ea1ef0400000000, + 0x24a435f500000000, 0x9bac2a3c00000000, 0x31a9f0cd00000000, + 0xf08f719600000000, 0x5a8aab6700000000, 0xe582b4ae00000000, + 0x4f876e5f00000000, 0xda95fbe700000000, 0x7090211600000000, + 0xcf983edf00000000, 0x659de42e00000000, 0x4dd53c6800000000, + 0xe7d0e69900000000, 0x58d8f95000000000, 0xf2dd23a100000000, + 0x67cfb61900000000, 0xcdca6ce800000000, 0x72c2732100000000, + 0xd8c7a9d000000000, 0x19e1288b00000000, 0xb3e4f27a00000000, + 0x0cecedb300000000, 0xa6e9374200000000, 0x33fba2fa00000000, + 0x99fe780b00000000, 0x26f667c200000000, 0x8cf3bd3300000000, + 0x7666d74f00000000, 0xdc630dbe00000000, 0x636b127700000000, + 0xc96ec88600000000, 0x5c7c5d3e00000000, 0xf67987cf00000000, + 0x4971980600000000, 0xe37442f700000000, 0x2252c3ac00000000, + 0x8857195d00000000, 0x375f069400000000, 0x9d5adc6500000000, + 0x084849dd00000000, 0xa24d932c00000000, 0x1d458ce500000000, + 0xb740561400000000, 0x9f088e5200000000, 0x350d54a300000000, + 0x8a054b6a00000000, 0x2000919b00000000, 0xb512042300000000, + 0x1f17ded200000000, 0xa01fc11b00000000, 0x0a1a1bea00000000, + 0xcb3c9ab100000000, 0x6139404000000000, 0xde315f8900000000, + 0x7434857800000000, 0xe12610c000000000, 0x4b23ca3100000000, + 0xf42bd5f800000000, 0x5e2e0f0900000000, 0x4877cbea00000000, + 0xe272111b00000000, 0x5d7a0ed200000000, 0xf77fd42300000000, + 0x626d419b00000000, 0xc8689b6a00000000, 0x776084a300000000, + 0xdd655e5200000000, 0x1c43df0900000000, 0xb64605f800000000, + 0x094e1a3100000000, 0xa34bc0c000000000, 0x3659557800000000, + 0x9c5c8f8900000000, 0x2354904000000000, 0x89514ab100000000, + 0xa11992f700000000, 0x0b1c480600000000, 0xb41457cf00000000, + 0x1e118d3e00000000, 0x8b03188600000000, 0x2106c27700000000, + 0x9e0eddbe00000000, 0x340b074f00000000, 0xf52d861400000000, + 0x5f285ce500000000, 0xe020432c00000000, 0x4a2599dd00000000, + 0xdf370c6500000000, 0x7532d69400000000, 0xca3ac95d00000000, + 0x603f13ac00000000, 0x9aaa79d000000000, 0x30afa32100000000, + 0x8fa7bce800000000, 0x25a2661900000000, 0xb0b0f3a100000000, + 0x1ab5295000000000, 0xa5bd369900000000, 0x0fb8ec6800000000, + 0xce9e6d3300000000, 0x649bb7c200000000, 0xdb93a80b00000000, + 0x719672fa00000000, 0xe484e74200000000, 0x4e813db300000000, + 0xf189227a00000000, 0x5b8cf88b00000000, 0x73c420cd00000000, + 0xd9c1fa3c00000000, 0x66c9e5f500000000, 0xcccc3f0400000000, + 0x59deaabc00000000, 0xf3db704d00000000, 0x4cd36f8400000000, + 0xe6d6b57500000000, 0x27f0342e00000000, 0x8df5eedf00000000, + 0x32fdf11600000000, 0x98f82be700000000, 0x0deabe5f00000000, + 0xa7ef64ae00000000, 0x18e77b6700000000, 0xb2e2a19600000000, + 0xecccae9f00000000, 0x46c9746e00000000, 0xf9c16ba700000000, + 0x53c4b15600000000, 0xc6d624ee00000000, 0x6cd3fe1f00000000, + 0xd3dbe1d600000000, 0x79de3b2700000000, 0xb8f8ba7c00000000, + 0x12fd608d00000000, 0xadf57f4400000000, 0x07f0a5b500000000, + 0x92e2300d00000000, 0x38e7eafc00000000, 0x87eff53500000000, + 0x2dea2fc400000000, 0x05a2f78200000000, 0xafa72d7300000000, + 0x10af32ba00000000, 0xbaaae84b00000000, 0x2fb87df300000000, + 0x85bda70200000000, 0x3ab5b8cb00000000, 0x90b0623a00000000, + 0x5196e36100000000, 0xfb93399000000000, 0x449b265900000000, + 0xee9efca800000000, 0x7b8c691000000000, 0xd189b3e100000000, + 0x6e81ac2800000000, 0xc48476d900000000, 0x3e111ca500000000, + 0x9414c65400000000, 0x2b1cd99d00000000, 0x8119036c00000000, + 0x140b96d400000000, 0xbe0e4c2500000000, 0x010653ec00000000, + 0xab03891d00000000, 0x6a25084600000000, 0xc020d2b700000000, + 0x7f28cd7e00000000, 0xd52d178f00000000, 0x403f823700000000, + 0xea3a58c600000000, 0x5532470f00000000, 0xff379dfe00000000, + 0xd77f45b800000000, 0x7d7a9f4900000000, 0xc272808000000000, + 0x68775a7100000000, 0xfd65cfc900000000, 0x5760153800000000, + 0xe8680af100000000, 0x426dd00000000000, 0x834b515b00000000, + 0x294e8baa00000000, 0x9646946300000000, 0x3c434e9200000000, + 0xa951db2a00000000, 0x035401db00000000, 0xbc5c1e1200000000, + 0x1659c4e300000000}}; + +#else /* W == 4 */ + +local const z_crc_t FAR crc_braid_table[][256] = { + {0x00000000, 0xae689191, 0x87a02563, 0x29c8b4f2, 0xd4314c87, + 0x7a59dd16, 0x539169e4, 0xfdf9f875, 0x73139f4f, 0xdd7b0ede, + 0xf4b3ba2c, 0x5adb2bbd, 0xa722d3c8, 0x094a4259, 0x2082f6ab, + 0x8eea673a, 0xe6273e9e, 0x484faf0f, 0x61871bfd, 0xcfef8a6c, + 0x32167219, 0x9c7ee388, 0xb5b6577a, 0x1bdec6eb, 0x9534a1d1, + 0x3b5c3040, 0x129484b2, 0xbcfc1523, 0x4105ed56, 0xef6d7cc7, + 0xc6a5c835, 0x68cd59a4, 0x173f7b7d, 0xb957eaec, 0x909f5e1e, + 0x3ef7cf8f, 0xc30e37fa, 0x6d66a66b, 0x44ae1299, 0xeac68308, + 0x642ce432, 0xca4475a3, 0xe38cc151, 0x4de450c0, 0xb01da8b5, + 0x1e753924, 0x37bd8dd6, 0x99d51c47, 0xf11845e3, 0x5f70d472, + 0x76b86080, 0xd8d0f111, 0x25290964, 0x8b4198f5, 0xa2892c07, + 0x0ce1bd96, 0x820bdaac, 0x2c634b3d, 0x05abffcf, 0xabc36e5e, + 0x563a962b, 0xf85207ba, 0xd19ab348, 0x7ff222d9, 0x2e7ef6fa, + 0x8016676b, 0xa9ded399, 0x07b64208, 0xfa4fba7d, 0x54272bec, + 0x7def9f1e, 0xd3870e8f, 0x5d6d69b5, 0xf305f824, 0xdacd4cd6, + 0x74a5dd47, 0x895c2532, 0x2734b4a3, 0x0efc0051, 0xa09491c0, + 0xc859c864, 0x663159f5, 0x4ff9ed07, 0xe1917c96, 0x1c6884e3, + 0xb2001572, 0x9bc8a180, 0x35a03011, 0xbb4a572b, 0x1522c6ba, + 0x3cea7248, 0x9282e3d9, 0x6f7b1bac, 0xc1138a3d, 0xe8db3ecf, + 0x46b3af5e, 0x39418d87, 0x97291c16, 0xbee1a8e4, 0x10893975, + 0xed70c100, 0x43185091, 0x6ad0e463, 0xc4b875f2, 0x4a5212c8, + 0xe43a8359, 0xcdf237ab, 0x639aa63a, 0x9e635e4f, 0x300bcfde, + 0x19c37b2c, 0xb7abeabd, 0xdf66b319, 0x710e2288, 0x58c6967a, + 0xf6ae07eb, 0x0b57ff9e, 0xa53f6e0f, 0x8cf7dafd, 0x229f4b6c, + 0xac752c56, 0x021dbdc7, 0x2bd50935, 0x85bd98a4, 0x784460d1, + 0xd62cf140, 0xffe445b2, 0x518cd423, 0x5cfdedf4, 0xf2957c65, + 0xdb5dc897, 0x75355906, 0x88cca173, 0x26a430e2, 0x0f6c8410, + 0xa1041581, 0x2fee72bb, 0x8186e32a, 0xa84e57d8, 0x0626c649, + 0xfbdf3e3c, 0x55b7afad, 0x7c7f1b5f, 0xd2178ace, 0xbadad36a, + 0x14b242fb, 0x3d7af609, 0x93126798, 0x6eeb9fed, 0xc0830e7c, + 0xe94bba8e, 0x47232b1f, 0xc9c94c25, 0x67a1ddb4, 0x4e696946, + 0xe001f8d7, 0x1df800a2, 0xb3909133, 0x9a5825c1, 0x3430b450, + 0x4bc29689, 0xe5aa0718, 0xcc62b3ea, 0x620a227b, 0x9ff3da0e, + 0x319b4b9f, 0x1853ff6d, 0xb63b6efc, 0x38d109c6, 0x96b99857, + 0xbf712ca5, 0x1119bd34, 0xece04541, 0x4288d4d0, 0x6b406022, + 0xc528f1b3, 0xade5a817, 0x038d3986, 0x2a458d74, 0x842d1ce5, + 0x79d4e490, 0xd7bc7501, 0xfe74c1f3, 0x501c5062, 0xdef63758, + 0x709ea6c9, 0x5956123b, 0xf73e83aa, 0x0ac77bdf, 0xa4afea4e, + 0x8d675ebc, 0x230fcf2d, 0x72831b0e, 0xdceb8a9f, 0xf5233e6d, + 0x5b4baffc, 0xa6b25789, 0x08dac618, 0x211272ea, 0x8f7ae37b, + 0x01908441, 0xaff815d0, 0x8630a122, 0x285830b3, 0xd5a1c8c6, + 0x7bc95957, 0x5201eda5, 0xfc697c34, 0x94a42590, 0x3accb401, + 0x130400f3, 0xbd6c9162, 0x40956917, 0xeefdf886, 0xc7354c74, + 0x695ddde5, 0xe7b7badf, 0x49df2b4e, 0x60179fbc, 0xce7f0e2d, + 0x3386f658, 0x9dee67c9, 0xb426d33b, 0x1a4e42aa, 0x65bc6073, + 0xcbd4f1e2, 0xe21c4510, 0x4c74d481, 0xb18d2cf4, 0x1fe5bd65, + 0x362d0997, 0x98459806, 0x16afff3c, 0xb8c76ead, 0x910fda5f, + 0x3f674bce, 0xc29eb3bb, 0x6cf6222a, 0x453e96d8, 0xeb560749, + 0x839b5eed, 0x2df3cf7c, 0x043b7b8e, 0xaa53ea1f, 0x57aa126a, + 0xf9c283fb, 0xd00a3709, 0x7e62a698, 0xf088c1a2, 0x5ee05033, + 0x7728e4c1, 0xd9407550, 0x24b98d25, 0x8ad11cb4, 0xa319a846, + 0x0d7139d7}, + {0x00000000, 0xb9fbdbe8, 0xa886b191, 0x117d6a79, 0x8a7c6563, + 0x3387be8b, 0x22fad4f2, 0x9b010f1a, 0xcf89cc87, 0x7672176f, + 0x670f7d16, 0xdef4a6fe, 0x45f5a9e4, 0xfc0e720c, 0xed731875, + 0x5488c39d, 0x44629f4f, 0xfd9944a7, 0xece42ede, 0x551ff536, + 0xce1efa2c, 0x77e521c4, 0x66984bbd, 0xdf639055, 0x8beb53c8, + 0x32108820, 0x236de259, 0x9a9639b1, 0x019736ab, 0xb86ced43, + 0xa911873a, 0x10ea5cd2, 0x88c53e9e, 0x313ee576, 0x20438f0f, + 0x99b854e7, 0x02b95bfd, 0xbb428015, 0xaa3fea6c, 0x13c43184, + 0x474cf219, 0xfeb729f1, 0xefca4388, 0x56319860, 0xcd30977a, + 0x74cb4c92, 0x65b626eb, 0xdc4dfd03, 0xcca7a1d1, 0x755c7a39, + 0x64211040, 0xdddacba8, 0x46dbc4b2, 0xff201f5a, 0xee5d7523, + 0x57a6aecb, 0x032e6d56, 0xbad5b6be, 0xaba8dcc7, 0x1253072f, + 0x89520835, 0x30a9d3dd, 0x21d4b9a4, 0x982f624c, 0xcafb7b7d, + 0x7300a095, 0x627dcaec, 0xdb861104, 0x40871e1e, 0xf97cc5f6, + 0xe801af8f, 0x51fa7467, 0x0572b7fa, 0xbc896c12, 0xadf4066b, + 0x140fdd83, 0x8f0ed299, 0x36f50971, 0x27886308, 0x9e73b8e0, + 0x8e99e432, 0x37623fda, 0x261f55a3, 0x9fe48e4b, 0x04e58151, + 0xbd1e5ab9, 0xac6330c0, 0x1598eb28, 0x411028b5, 0xf8ebf35d, + 0xe9969924, 0x506d42cc, 0xcb6c4dd6, 0x7297963e, 0x63eafc47, + 0xda1127af, 0x423e45e3, 0xfbc59e0b, 0xeab8f472, 0x53432f9a, + 0xc8422080, 0x71b9fb68, 0x60c49111, 0xd93f4af9, 0x8db78964, + 0x344c528c, 0x253138f5, 0x9ccae31d, 0x07cbec07, 0xbe3037ef, + 0xaf4d5d96, 0x16b6867e, 0x065cdaac, 0xbfa70144, 0xaeda6b3d, + 0x1721b0d5, 0x8c20bfcf, 0x35db6427, 0x24a60e5e, 0x9d5dd5b6, + 0xc9d5162b, 0x702ecdc3, 0x6153a7ba, 0xd8a87c52, 0x43a97348, + 0xfa52a8a0, 0xeb2fc2d9, 0x52d41931, 0x4e87f0bb, 0xf77c2b53, + 0xe601412a, 0x5ffa9ac2, 0xc4fb95d8, 0x7d004e30, 0x6c7d2449, + 0xd586ffa1, 0x810e3c3c, 0x38f5e7d4, 0x29888dad, 0x90735645, + 0x0b72595f, 0xb28982b7, 0xa3f4e8ce, 0x1a0f3326, 0x0ae56ff4, + 0xb31eb41c, 0xa263de65, 0x1b98058d, 0x80990a97, 0x3962d17f, + 0x281fbb06, 0x91e460ee, 0xc56ca373, 0x7c97789b, 0x6dea12e2, + 0xd411c90a, 0x4f10c610, 0xf6eb1df8, 0xe7967781, 0x5e6dac69, + 0xc642ce25, 0x7fb915cd, 0x6ec47fb4, 0xd73fa45c, 0x4c3eab46, + 0xf5c570ae, 0xe4b81ad7, 0x5d43c13f, 0x09cb02a2, 0xb030d94a, + 0xa14db333, 0x18b668db, 0x83b767c1, 0x3a4cbc29, 0x2b31d650, + 0x92ca0db8, 0x8220516a, 0x3bdb8a82, 0x2aa6e0fb, 0x935d3b13, + 0x085c3409, 0xb1a7efe1, 0xa0da8598, 0x19215e70, 0x4da99ded, + 0xf4524605, 0xe52f2c7c, 0x5cd4f794, 0xc7d5f88e, 0x7e2e2366, + 0x6f53491f, 0xd6a892f7, 0x847c8bc6, 0x3d87502e, 0x2cfa3a57, + 0x9501e1bf, 0x0e00eea5, 0xb7fb354d, 0xa6865f34, 0x1f7d84dc, + 0x4bf54741, 0xf20e9ca9, 0xe373f6d0, 0x5a882d38, 0xc1892222, + 0x7872f9ca, 0x690f93b3, 0xd0f4485b, 0xc01e1489, 0x79e5cf61, + 0x6898a518, 0xd1637ef0, 0x4a6271ea, 0xf399aa02, 0xe2e4c07b, + 0x5b1f1b93, 0x0f97d80e, 0xb66c03e6, 0xa711699f, 0x1eeab277, + 0x85ebbd6d, 0x3c106685, 0x2d6d0cfc, 0x9496d714, 0x0cb9b558, + 0xb5426eb0, 0xa43f04c9, 0x1dc4df21, 0x86c5d03b, 0x3f3e0bd3, + 0x2e4361aa, 0x97b8ba42, 0xc33079df, 0x7acba237, 0x6bb6c84e, + 0xd24d13a6, 0x494c1cbc, 0xf0b7c754, 0xe1caad2d, 0x583176c5, + 0x48db2a17, 0xf120f1ff, 0xe05d9b86, 0x59a6406e, 0xc2a74f74, + 0x7b5c949c, 0x6a21fee5, 0xd3da250d, 0x8752e690, 0x3ea93d78, + 0x2fd45701, 0x962f8ce9, 0x0d2e83f3, 0xb4d5581b, 0xa5a83262, + 0x1c53e98a}, + {0x00000000, 0x9d0fe176, 0xe16ec4ad, 0x7c6125db, 0x19ac8f1b, + 0x84a36e6d, 0xf8c24bb6, 0x65cdaac0, 0x33591e36, 0xae56ff40, + 0xd237da9b, 0x4f383bed, 0x2af5912d, 0xb7fa705b, 0xcb9b5580, + 0x5694b4f6, 0x66b23c6c, 0xfbbddd1a, 0x87dcf8c1, 0x1ad319b7, + 0x7f1eb377, 0xe2115201, 0x9e7077da, 0x037f96ac, 0x55eb225a, + 0xc8e4c32c, 0xb485e6f7, 0x298a0781, 0x4c47ad41, 0xd1484c37, + 0xad2969ec, 0x3026889a, 0xcd6478d8, 0x506b99ae, 0x2c0abc75, + 0xb1055d03, 0xd4c8f7c3, 0x49c716b5, 0x35a6336e, 0xa8a9d218, + 0xfe3d66ee, 0x63328798, 0x1f53a243, 0x825c4335, 0xe791e9f5, + 0x7a9e0883, 0x06ff2d58, 0x9bf0cc2e, 0xabd644b4, 0x36d9a5c2, + 0x4ab88019, 0xd7b7616f, 0xb27acbaf, 0x2f752ad9, 0x53140f02, + 0xce1bee74, 0x988f5a82, 0x0580bbf4, 0x79e19e2f, 0xe4ee7f59, + 0x8123d599, 0x1c2c34ef, 0x604d1134, 0xfd42f042, 0x41b9f7f1, + 0xdcb61687, 0xa0d7335c, 0x3dd8d22a, 0x581578ea, 0xc51a999c, + 0xb97bbc47, 0x24745d31, 0x72e0e9c7, 0xefef08b1, 0x938e2d6a, + 0x0e81cc1c, 0x6b4c66dc, 0xf64387aa, 0x8a22a271, 0x172d4307, + 0x270bcb9d, 0xba042aeb, 0xc6650f30, 0x5b6aee46, 0x3ea74486, + 0xa3a8a5f0, 0xdfc9802b, 0x42c6615d, 0x1452d5ab, 0x895d34dd, + 0xf53c1106, 0x6833f070, 0x0dfe5ab0, 0x90f1bbc6, 0xec909e1d, + 0x719f7f6b, 0x8cdd8f29, 0x11d26e5f, 0x6db34b84, 0xf0bcaaf2, + 0x95710032, 0x087ee144, 0x741fc49f, 0xe91025e9, 0xbf84911f, + 0x228b7069, 0x5eea55b2, 0xc3e5b4c4, 0xa6281e04, 0x3b27ff72, + 0x4746daa9, 0xda493bdf, 0xea6fb345, 0x77605233, 0x0b0177e8, + 0x960e969e, 0xf3c33c5e, 0x6eccdd28, 0x12adf8f3, 0x8fa21985, + 0xd936ad73, 0x44394c05, 0x385869de, 0xa55788a8, 0xc09a2268, + 0x5d95c31e, 0x21f4e6c5, 0xbcfb07b3, 0x8373efe2, 0x1e7c0e94, + 0x621d2b4f, 0xff12ca39, 0x9adf60f9, 0x07d0818f, 0x7bb1a454, + 0xe6be4522, 0xb02af1d4, 0x2d2510a2, 0x51443579, 0xcc4bd40f, + 0xa9867ecf, 0x34899fb9, 0x48e8ba62, 0xd5e75b14, 0xe5c1d38e, + 0x78ce32f8, 0x04af1723, 0x99a0f655, 0xfc6d5c95, 0x6162bde3, + 0x1d039838, 0x800c794e, 0xd698cdb8, 0x4b972cce, 0x37f60915, + 0xaaf9e863, 0xcf3442a3, 0x523ba3d5, 0x2e5a860e, 0xb3556778, + 0x4e17973a, 0xd318764c, 0xaf795397, 0x3276b2e1, 0x57bb1821, + 0xcab4f957, 0xb6d5dc8c, 0x2bda3dfa, 0x7d4e890c, 0xe041687a, + 0x9c204da1, 0x012facd7, 0x64e20617, 0xf9ede761, 0x858cc2ba, + 0x188323cc, 0x28a5ab56, 0xb5aa4a20, 0xc9cb6ffb, 0x54c48e8d, + 0x3109244d, 0xac06c53b, 0xd067e0e0, 0x4d680196, 0x1bfcb560, + 0x86f35416, 0xfa9271cd, 0x679d90bb, 0x02503a7b, 0x9f5fdb0d, + 0xe33efed6, 0x7e311fa0, 0xc2ca1813, 0x5fc5f965, 0x23a4dcbe, + 0xbeab3dc8, 0xdb669708, 0x4669767e, 0x3a0853a5, 0xa707b2d3, + 0xf1930625, 0x6c9ce753, 0x10fdc288, 0x8df223fe, 0xe83f893e, + 0x75306848, 0x09514d93, 0x945eace5, 0xa478247f, 0x3977c509, + 0x4516e0d2, 0xd81901a4, 0xbdd4ab64, 0x20db4a12, 0x5cba6fc9, + 0xc1b58ebf, 0x97213a49, 0x0a2edb3f, 0x764ffee4, 0xeb401f92, + 0x8e8db552, 0x13825424, 0x6fe371ff, 0xf2ec9089, 0x0fae60cb, + 0x92a181bd, 0xeec0a466, 0x73cf4510, 0x1602efd0, 0x8b0d0ea6, + 0xf76c2b7d, 0x6a63ca0b, 0x3cf77efd, 0xa1f89f8b, 0xdd99ba50, + 0x40965b26, 0x255bf1e6, 0xb8541090, 0xc435354b, 0x593ad43d, + 0x691c5ca7, 0xf413bdd1, 0x8872980a, 0x157d797c, 0x70b0d3bc, + 0xedbf32ca, 0x91de1711, 0x0cd1f667, 0x5a454291, 0xc74aa3e7, + 0xbb2b863c, 0x2624674a, 0x43e9cd8a, 0xdee62cfc, 0xa2870927, + 0x3f88e851}, + {0x00000000, 0xdd96d985, 0x605cb54b, 0xbdca6cce, 0xc0b96a96, + 0x1d2fb313, 0xa0e5dfdd, 0x7d730658, 0x5a03d36d, 0x87950ae8, + 0x3a5f6626, 0xe7c9bfa3, 0x9abab9fb, 0x472c607e, 0xfae60cb0, + 0x2770d535, 0xb407a6da, 0x69917f5f, 0xd45b1391, 0x09cdca14, + 0x74becc4c, 0xa92815c9, 0x14e27907, 0xc974a082, 0xee0475b7, + 0x3392ac32, 0x8e58c0fc, 0x53ce1979, 0x2ebd1f21, 0xf32bc6a4, + 0x4ee1aa6a, 0x937773ef, 0xb37e4bf5, 0x6ee89270, 0xd322febe, + 0x0eb4273b, 0x73c72163, 0xae51f8e6, 0x139b9428, 0xce0d4dad, + 0xe97d9898, 0x34eb411d, 0x89212dd3, 0x54b7f456, 0x29c4f20e, + 0xf4522b8b, 0x49984745, 0x940e9ec0, 0x0779ed2f, 0xdaef34aa, + 0x67255864, 0xbab381e1, 0xc7c087b9, 0x1a565e3c, 0xa79c32f2, + 0x7a0aeb77, 0x5d7a3e42, 0x80ece7c7, 0x3d268b09, 0xe0b0528c, + 0x9dc354d4, 0x40558d51, 0xfd9fe19f, 0x2009381a, 0xbd8d91ab, + 0x601b482e, 0xddd124e0, 0x0047fd65, 0x7d34fb3d, 0xa0a222b8, + 0x1d684e76, 0xc0fe97f3, 0xe78e42c6, 0x3a189b43, 0x87d2f78d, + 0x5a442e08, 0x27372850, 0xfaa1f1d5, 0x476b9d1b, 0x9afd449e, + 0x098a3771, 0xd41ceef4, 0x69d6823a, 0xb4405bbf, 0xc9335de7, + 0x14a58462, 0xa96fe8ac, 0x74f93129, 0x5389e41c, 0x8e1f3d99, + 0x33d55157, 0xee4388d2, 0x93308e8a, 0x4ea6570f, 0xf36c3bc1, + 0x2efae244, 0x0ef3da5e, 0xd36503db, 0x6eaf6f15, 0xb339b690, + 0xce4ab0c8, 0x13dc694d, 0xae160583, 0x7380dc06, 0x54f00933, + 0x8966d0b6, 0x34acbc78, 0xe93a65fd, 0x944963a5, 0x49dfba20, + 0xf415d6ee, 0x29830f6b, 0xbaf47c84, 0x6762a501, 0xdaa8c9cf, + 0x073e104a, 0x7a4d1612, 0xa7dbcf97, 0x1a11a359, 0xc7877adc, + 0xe0f7afe9, 0x3d61766c, 0x80ab1aa2, 0x5d3dc327, 0x204ec57f, + 0xfdd81cfa, 0x40127034, 0x9d84a9b1, 0xa06a2517, 0x7dfcfc92, + 0xc036905c, 0x1da049d9, 0x60d34f81, 0xbd459604, 0x008ffaca, + 0xdd19234f, 0xfa69f67a, 0x27ff2fff, 0x9a354331, 0x47a39ab4, + 0x3ad09cec, 0xe7464569, 0x5a8c29a7, 0x871af022, 0x146d83cd, + 0xc9fb5a48, 0x74313686, 0xa9a7ef03, 0xd4d4e95b, 0x094230de, + 0xb4885c10, 0x691e8595, 0x4e6e50a0, 0x93f88925, 0x2e32e5eb, + 0xf3a43c6e, 0x8ed73a36, 0x5341e3b3, 0xee8b8f7d, 0x331d56f8, + 0x13146ee2, 0xce82b767, 0x7348dba9, 0xaede022c, 0xd3ad0474, + 0x0e3bddf1, 0xb3f1b13f, 0x6e6768ba, 0x4917bd8f, 0x9481640a, + 0x294b08c4, 0xf4ddd141, 0x89aed719, 0x54380e9c, 0xe9f26252, + 0x3464bbd7, 0xa713c838, 0x7a8511bd, 0xc74f7d73, 0x1ad9a4f6, + 0x67aaa2ae, 0xba3c7b2b, 0x07f617e5, 0xda60ce60, 0xfd101b55, + 0x2086c2d0, 0x9d4cae1e, 0x40da779b, 0x3da971c3, 0xe03fa846, + 0x5df5c488, 0x80631d0d, 0x1de7b4bc, 0xc0716d39, 0x7dbb01f7, + 0xa02dd872, 0xdd5ede2a, 0x00c807af, 0xbd026b61, 0x6094b2e4, + 0x47e467d1, 0x9a72be54, 0x27b8d29a, 0xfa2e0b1f, 0x875d0d47, + 0x5acbd4c2, 0xe701b80c, 0x3a976189, 0xa9e01266, 0x7476cbe3, + 0xc9bca72d, 0x142a7ea8, 0x695978f0, 0xb4cfa175, 0x0905cdbb, + 0xd493143e, 0xf3e3c10b, 0x2e75188e, 0x93bf7440, 0x4e29adc5, + 0x335aab9d, 0xeecc7218, 0x53061ed6, 0x8e90c753, 0xae99ff49, + 0x730f26cc, 0xcec54a02, 0x13539387, 0x6e2095df, 0xb3b64c5a, + 0x0e7c2094, 0xd3eaf911, 0xf49a2c24, 0x290cf5a1, 0x94c6996f, + 0x495040ea, 0x342346b2, 0xe9b59f37, 0x547ff3f9, 0x89e92a7c, + 0x1a9e5993, 0xc7088016, 0x7ac2ecd8, 0xa754355d, 0xda273305, + 0x07b1ea80, 0xba7b864e, 0x67ed5fcb, 0x409d8afe, 0x9d0b537b, + 0x20c13fb5, 0xfd57e630, 0x8024e068, 0x5db239ed, 0xe0785523, + 0x3dee8ca6}}; + +local const z_word_t FAR crc_braid_big_table[][256] = { + {0x00000000, 0x85d996dd, 0x4bb55c60, 0xce6ccabd, 0x966ab9c0, + 0x13b32f1d, 0xdddfe5a0, 0x5806737d, 0x6dd3035a, 0xe80a9587, + 0x26665f3a, 0xa3bfc9e7, 0xfbb9ba9a, 0x7e602c47, 0xb00ce6fa, + 0x35d57027, 0xdaa607b4, 0x5f7f9169, 0x91135bd4, 0x14cacd09, + 0x4cccbe74, 0xc91528a9, 0x0779e214, 0x82a074c9, 0xb77504ee, + 0x32ac9233, 0xfcc0588e, 0x7919ce53, 0x211fbd2e, 0xa4c62bf3, + 0x6aaae14e, 0xef737793, 0xf54b7eb3, 0x7092e86e, 0xbefe22d3, + 0x3b27b40e, 0x6321c773, 0xe6f851ae, 0x28949b13, 0xad4d0dce, + 0x98987de9, 0x1d41eb34, 0xd32d2189, 0x56f4b754, 0x0ef2c429, + 0x8b2b52f4, 0x45479849, 0xc09e0e94, 0x2fed7907, 0xaa34efda, + 0x64582567, 0xe181b3ba, 0xb987c0c7, 0x3c5e561a, 0xf2329ca7, + 0x77eb0a7a, 0x423e7a5d, 0xc7e7ec80, 0x098b263d, 0x8c52b0e0, + 0xd454c39d, 0x518d5540, 0x9fe19ffd, 0x1a380920, 0xab918dbd, + 0x2e481b60, 0xe024d1dd, 0x65fd4700, 0x3dfb347d, 0xb822a2a0, + 0x764e681d, 0xf397fec0, 0xc6428ee7, 0x439b183a, 0x8df7d287, + 0x082e445a, 0x50283727, 0xd5f1a1fa, 0x1b9d6b47, 0x9e44fd9a, + 0x71378a09, 0xf4ee1cd4, 0x3a82d669, 0xbf5b40b4, 0xe75d33c9, + 0x6284a514, 0xace86fa9, 0x2931f974, 0x1ce48953, 0x993d1f8e, + 0x5751d533, 0xd28843ee, 0x8a8e3093, 0x0f57a64e, 0xc13b6cf3, + 0x44e2fa2e, 0x5edaf30e, 0xdb0365d3, 0x156faf6e, 0x90b639b3, + 0xc8b04ace, 0x4d69dc13, 0x830516ae, 0x06dc8073, 0x3309f054, + 0xb6d06689, 0x78bcac34, 0xfd653ae9, 0xa5634994, 0x20badf49, + 0xeed615f4, 0x6b0f8329, 0x847cf4ba, 0x01a56267, 0xcfc9a8da, + 0x4a103e07, 0x12164d7a, 0x97cfdba7, 0x59a3111a, 0xdc7a87c7, + 0xe9aff7e0, 0x6c76613d, 0xa21aab80, 0x27c33d5d, 0x7fc54e20, + 0xfa1cd8fd, 0x34701240, 0xb1a9849d, 0x17256aa0, 0x92fcfc7d, + 0x5c9036c0, 0xd949a01d, 0x814fd360, 0x049645bd, 0xcafa8f00, + 0x4f2319dd, 0x7af669fa, 0xff2fff27, 0x3143359a, 0xb49aa347, + 0xec9cd03a, 0x694546e7, 0xa7298c5a, 0x22f01a87, 0xcd836d14, + 0x485afbc9, 0x86363174, 0x03efa7a9, 0x5be9d4d4, 0xde304209, + 0x105c88b4, 0x95851e69, 0xa0506e4e, 0x2589f893, 0xebe5322e, + 0x6e3ca4f3, 0x363ad78e, 0xb3e34153, 0x7d8f8bee, 0xf8561d33, + 0xe26e1413, 0x67b782ce, 0xa9db4873, 0x2c02deae, 0x7404add3, + 0xf1dd3b0e, 0x3fb1f1b3, 0xba68676e, 0x8fbd1749, 0x0a648194, + 0xc4084b29, 0x41d1ddf4, 0x19d7ae89, 0x9c0e3854, 0x5262f2e9, + 0xd7bb6434, 0x38c813a7, 0xbd11857a, 0x737d4fc7, 0xf6a4d91a, + 0xaea2aa67, 0x2b7b3cba, 0xe517f607, 0x60ce60da, 0x551b10fd, + 0xd0c28620, 0x1eae4c9d, 0x9b77da40, 0xc371a93d, 0x46a83fe0, + 0x88c4f55d, 0x0d1d6380, 0xbcb4e71d, 0x396d71c0, 0xf701bb7d, + 0x72d82da0, 0x2ade5edd, 0xaf07c800, 0x616b02bd, 0xe4b29460, + 0xd167e447, 0x54be729a, 0x9ad2b827, 0x1f0b2efa, 0x470d5d87, + 0xc2d4cb5a, 0x0cb801e7, 0x8961973a, 0x6612e0a9, 0xe3cb7674, + 0x2da7bcc9, 0xa87e2a14, 0xf0785969, 0x75a1cfb4, 0xbbcd0509, + 0x3e1493d4, 0x0bc1e3f3, 0x8e18752e, 0x4074bf93, 0xc5ad294e, + 0x9dab5a33, 0x1872ccee, 0xd61e0653, 0x53c7908e, 0x49ff99ae, + 0xcc260f73, 0x024ac5ce, 0x87935313, 0xdf95206e, 0x5a4cb6b3, + 0x94207c0e, 0x11f9ead3, 0x242c9af4, 0xa1f50c29, 0x6f99c694, + 0xea405049, 0xb2462334, 0x379fb5e9, 0xf9f37f54, 0x7c2ae989, + 0x93599e1a, 0x168008c7, 0xd8ecc27a, 0x5d3554a7, 0x053327da, + 0x80eab107, 0x4e867bba, 0xcb5fed67, 0xfe8a9d40, 0x7b530b9d, + 0xb53fc120, 0x30e657fd, 0x68e02480, 0xed39b25d, 0x235578e0, + 0xa68cee3d}, + {0x00000000, 0x76e10f9d, 0xadc46ee1, 0xdb25617c, 0x1b8fac19, + 0x6d6ea384, 0xb64bc2f8, 0xc0aacd65, 0x361e5933, 0x40ff56ae, + 0x9bda37d2, 0xed3b384f, 0x2d91f52a, 0x5b70fab7, 0x80559bcb, + 0xf6b49456, 0x6c3cb266, 0x1addbdfb, 0xc1f8dc87, 0xb719d31a, + 0x77b31e7f, 0x015211e2, 0xda77709e, 0xac967f03, 0x5a22eb55, + 0x2cc3e4c8, 0xf7e685b4, 0x81078a29, 0x41ad474c, 0x374c48d1, + 0xec6929ad, 0x9a882630, 0xd87864cd, 0xae996b50, 0x75bc0a2c, + 0x035d05b1, 0xc3f7c8d4, 0xb516c749, 0x6e33a635, 0x18d2a9a8, + 0xee663dfe, 0x98873263, 0x43a2531f, 0x35435c82, 0xf5e991e7, + 0x83089e7a, 0x582dff06, 0x2eccf09b, 0xb444d6ab, 0xc2a5d936, + 0x1980b84a, 0x6f61b7d7, 0xafcb7ab2, 0xd92a752f, 0x020f1453, + 0x74ee1bce, 0x825a8f98, 0xf4bb8005, 0x2f9ee179, 0x597feee4, + 0x99d52381, 0xef342c1c, 0x34114d60, 0x42f042fd, 0xf1f7b941, + 0x8716b6dc, 0x5c33d7a0, 0x2ad2d83d, 0xea781558, 0x9c991ac5, + 0x47bc7bb9, 0x315d7424, 0xc7e9e072, 0xb108efef, 0x6a2d8e93, + 0x1ccc810e, 0xdc664c6b, 0xaa8743f6, 0x71a2228a, 0x07432d17, + 0x9dcb0b27, 0xeb2a04ba, 0x300f65c6, 0x46ee6a5b, 0x8644a73e, + 0xf0a5a8a3, 0x2b80c9df, 0x5d61c642, 0xabd55214, 0xdd345d89, + 0x06113cf5, 0x70f03368, 0xb05afe0d, 0xc6bbf190, 0x1d9e90ec, + 0x6b7f9f71, 0x298fdd8c, 0x5f6ed211, 0x844bb36d, 0xf2aabcf0, + 0x32007195, 0x44e17e08, 0x9fc41f74, 0xe92510e9, 0x1f9184bf, + 0x69708b22, 0xb255ea5e, 0xc4b4e5c3, 0x041e28a6, 0x72ff273b, + 0xa9da4647, 0xdf3b49da, 0x45b36fea, 0x33526077, 0xe877010b, + 0x9e960e96, 0x5e3cc3f3, 0x28ddcc6e, 0xf3f8ad12, 0x8519a28f, + 0x73ad36d9, 0x054c3944, 0xde695838, 0xa88857a5, 0x68229ac0, + 0x1ec3955d, 0xc5e6f421, 0xb307fbbc, 0xe2ef7383, 0x940e7c1e, + 0x4f2b1d62, 0x39ca12ff, 0xf960df9a, 0x8f81d007, 0x54a4b17b, + 0x2245bee6, 0xd4f12ab0, 0xa210252d, 0x79354451, 0x0fd44bcc, + 0xcf7e86a9, 0xb99f8934, 0x62bae848, 0x145be7d5, 0x8ed3c1e5, + 0xf832ce78, 0x2317af04, 0x55f6a099, 0x955c6dfc, 0xe3bd6261, + 0x3898031d, 0x4e790c80, 0xb8cd98d6, 0xce2c974b, 0x1509f637, + 0x63e8f9aa, 0xa34234cf, 0xd5a33b52, 0x0e865a2e, 0x786755b3, + 0x3a97174e, 0x4c7618d3, 0x975379af, 0xe1b27632, 0x2118bb57, + 0x57f9b4ca, 0x8cdcd5b6, 0xfa3dda2b, 0x0c894e7d, 0x7a6841e0, + 0xa14d209c, 0xd7ac2f01, 0x1706e264, 0x61e7edf9, 0xbac28c85, + 0xcc238318, 0x56aba528, 0x204aaab5, 0xfb6fcbc9, 0x8d8ec454, + 0x4d240931, 0x3bc506ac, 0xe0e067d0, 0x9601684d, 0x60b5fc1b, + 0x1654f386, 0xcd7192fa, 0xbb909d67, 0x7b3a5002, 0x0ddb5f9f, + 0xd6fe3ee3, 0xa01f317e, 0x1318cac2, 0x65f9c55f, 0xbedca423, + 0xc83dabbe, 0x089766db, 0x7e766946, 0xa553083a, 0xd3b207a7, + 0x250693f1, 0x53e79c6c, 0x88c2fd10, 0xfe23f28d, 0x3e893fe8, + 0x48683075, 0x934d5109, 0xe5ac5e94, 0x7f2478a4, 0x09c57739, + 0xd2e01645, 0xa40119d8, 0x64abd4bd, 0x124adb20, 0xc96fba5c, + 0xbf8eb5c1, 0x493a2197, 0x3fdb2e0a, 0xe4fe4f76, 0x921f40eb, + 0x52b58d8e, 0x24548213, 0xff71e36f, 0x8990ecf2, 0xcb60ae0f, + 0xbd81a192, 0x66a4c0ee, 0x1045cf73, 0xd0ef0216, 0xa60e0d8b, + 0x7d2b6cf7, 0x0bca636a, 0xfd7ef73c, 0x8b9ff8a1, 0x50ba99dd, + 0x265b9640, 0xe6f15b25, 0x901054b8, 0x4b3535c4, 0x3dd43a59, + 0xa75c1c69, 0xd1bd13f4, 0x0a987288, 0x7c797d15, 0xbcd3b070, + 0xca32bfed, 0x1117de91, 0x67f6d10c, 0x9142455a, 0xe7a34ac7, + 0x3c862bbb, 0x4a672426, 0x8acde943, 0xfc2ce6de, 0x270987a2, + 0x51e8883f}, + {0x00000000, 0xe8dbfbb9, 0x91b186a8, 0x796a7d11, 0x63657c8a, + 0x8bbe8733, 0xf2d4fa22, 0x1a0f019b, 0x87cc89cf, 0x6f177276, + 0x167d0f67, 0xfea6f4de, 0xe4a9f545, 0x0c720efc, 0x751873ed, + 0x9dc38854, 0x4f9f6244, 0xa74499fd, 0xde2ee4ec, 0x36f51f55, + 0x2cfa1ece, 0xc421e577, 0xbd4b9866, 0x559063df, 0xc853eb8b, + 0x20881032, 0x59e26d23, 0xb139969a, 0xab369701, 0x43ed6cb8, + 0x3a8711a9, 0xd25cea10, 0x9e3ec588, 0x76e53e31, 0x0f8f4320, + 0xe754b899, 0xfd5bb902, 0x158042bb, 0x6cea3faa, 0x8431c413, + 0x19f24c47, 0xf129b7fe, 0x8843caef, 0x60983156, 0x7a9730cd, + 0x924ccb74, 0xeb26b665, 0x03fd4ddc, 0xd1a1a7cc, 0x397a5c75, + 0x40102164, 0xa8cbdadd, 0xb2c4db46, 0x5a1f20ff, 0x23755dee, + 0xcbaea657, 0x566d2e03, 0xbeb6d5ba, 0xc7dca8ab, 0x2f075312, + 0x35085289, 0xddd3a930, 0xa4b9d421, 0x4c622f98, 0x7d7bfbca, + 0x95a00073, 0xecca7d62, 0x041186db, 0x1e1e8740, 0xf6c57cf9, + 0x8faf01e8, 0x6774fa51, 0xfab77205, 0x126c89bc, 0x6b06f4ad, + 0x83dd0f14, 0x99d20e8f, 0x7109f536, 0x08638827, 0xe0b8739e, + 0x32e4998e, 0xda3f6237, 0xa3551f26, 0x4b8ee49f, 0x5181e504, + 0xb95a1ebd, 0xc03063ac, 0x28eb9815, 0xb5281041, 0x5df3ebf8, + 0x249996e9, 0xcc426d50, 0xd64d6ccb, 0x3e969772, 0x47fcea63, + 0xaf2711da, 0xe3453e42, 0x0b9ec5fb, 0x72f4b8ea, 0x9a2f4353, + 0x802042c8, 0x68fbb971, 0x1191c460, 0xf94a3fd9, 0x6489b78d, + 0x8c524c34, 0xf5383125, 0x1de3ca9c, 0x07eccb07, 0xef3730be, + 0x965d4daf, 0x7e86b616, 0xacda5c06, 0x4401a7bf, 0x3d6bdaae, + 0xd5b02117, 0xcfbf208c, 0x2764db35, 0x5e0ea624, 0xb6d55d9d, + 0x2b16d5c9, 0xc3cd2e70, 0xbaa75361, 0x527ca8d8, 0x4873a943, + 0xa0a852fa, 0xd9c22feb, 0x3119d452, 0xbbf0874e, 0x532b7cf7, + 0x2a4101e6, 0xc29afa5f, 0xd895fbc4, 0x304e007d, 0x49247d6c, + 0xa1ff86d5, 0x3c3c0e81, 0xd4e7f538, 0xad8d8829, 0x45567390, + 0x5f59720b, 0xb78289b2, 0xcee8f4a3, 0x26330f1a, 0xf46fe50a, + 0x1cb41eb3, 0x65de63a2, 0x8d05981b, 0x970a9980, 0x7fd16239, + 0x06bb1f28, 0xee60e491, 0x73a36cc5, 0x9b78977c, 0xe212ea6d, + 0x0ac911d4, 0x10c6104f, 0xf81debf6, 0x817796e7, 0x69ac6d5e, + 0x25ce42c6, 0xcd15b97f, 0xb47fc46e, 0x5ca43fd7, 0x46ab3e4c, + 0xae70c5f5, 0xd71ab8e4, 0x3fc1435d, 0xa202cb09, 0x4ad930b0, + 0x33b34da1, 0xdb68b618, 0xc167b783, 0x29bc4c3a, 0x50d6312b, + 0xb80dca92, 0x6a512082, 0x828adb3b, 0xfbe0a62a, 0x133b5d93, + 0x09345c08, 0xe1efa7b1, 0x9885daa0, 0x705e2119, 0xed9da94d, + 0x054652f4, 0x7c2c2fe5, 0x94f7d45c, 0x8ef8d5c7, 0x66232e7e, + 0x1f49536f, 0xf792a8d6, 0xc68b7c84, 0x2e50873d, 0x573afa2c, + 0xbfe10195, 0xa5ee000e, 0x4d35fbb7, 0x345f86a6, 0xdc847d1f, + 0x4147f54b, 0xa99c0ef2, 0xd0f673e3, 0x382d885a, 0x222289c1, + 0xcaf97278, 0xb3930f69, 0x5b48f4d0, 0x89141ec0, 0x61cfe579, + 0x18a59868, 0xf07e63d1, 0xea71624a, 0x02aa99f3, 0x7bc0e4e2, + 0x931b1f5b, 0x0ed8970f, 0xe6036cb6, 0x9f6911a7, 0x77b2ea1e, + 0x6dbdeb85, 0x8566103c, 0xfc0c6d2d, 0x14d79694, 0x58b5b90c, + 0xb06e42b5, 0xc9043fa4, 0x21dfc41d, 0x3bd0c586, 0xd30b3e3f, + 0xaa61432e, 0x42bab897, 0xdf7930c3, 0x37a2cb7a, 0x4ec8b66b, + 0xa6134dd2, 0xbc1c4c49, 0x54c7b7f0, 0x2dadcae1, 0xc5763158, + 0x172adb48, 0xfff120f1, 0x869b5de0, 0x6e40a659, 0x744fa7c2, + 0x9c945c7b, 0xe5fe216a, 0x0d25dad3, 0x90e65287, 0x783da93e, + 0x0157d42f, 0xe98c2f96, 0xf3832e0d, 0x1b58d5b4, 0x6232a8a5, + 0x8ae9531c}, + {0x00000000, 0x919168ae, 0x6325a087, 0xf2b4c829, 0x874c31d4, + 0x16dd597a, 0xe4699153, 0x75f8f9fd, 0x4f9f1373, 0xde0e7bdd, + 0x2cbab3f4, 0xbd2bdb5a, 0xc8d322a7, 0x59424a09, 0xabf68220, + 0x3a67ea8e, 0x9e3e27e6, 0x0faf4f48, 0xfd1b8761, 0x6c8aefcf, + 0x19721632, 0x88e37e9c, 0x7a57b6b5, 0xebc6de1b, 0xd1a13495, + 0x40305c3b, 0xb2849412, 0x2315fcbc, 0x56ed0541, 0xc77c6def, + 0x35c8a5c6, 0xa459cd68, 0x7d7b3f17, 0xecea57b9, 0x1e5e9f90, + 0x8fcff73e, 0xfa370ec3, 0x6ba6666d, 0x9912ae44, 0x0883c6ea, + 0x32e42c64, 0xa37544ca, 0x51c18ce3, 0xc050e44d, 0xb5a81db0, + 0x2439751e, 0xd68dbd37, 0x471cd599, 0xe34518f1, 0x72d4705f, + 0x8060b876, 0x11f1d0d8, 0x64092925, 0xf598418b, 0x072c89a2, + 0x96bde10c, 0xacda0b82, 0x3d4b632c, 0xcfffab05, 0x5e6ec3ab, + 0x2b963a56, 0xba0752f8, 0x48b39ad1, 0xd922f27f, 0xfaf67e2e, + 0x6b671680, 0x99d3dea9, 0x0842b607, 0x7dba4ffa, 0xec2b2754, + 0x1e9fef7d, 0x8f0e87d3, 0xb5696d5d, 0x24f805f3, 0xd64ccdda, + 0x47dda574, 0x32255c89, 0xa3b43427, 0x5100fc0e, 0xc09194a0, + 0x64c859c8, 0xf5593166, 0x07edf94f, 0x967c91e1, 0xe384681c, + 0x721500b2, 0x80a1c89b, 0x1130a035, 0x2b574abb, 0xbac62215, + 0x4872ea3c, 0xd9e38292, 0xac1b7b6f, 0x3d8a13c1, 0xcf3edbe8, + 0x5eafb346, 0x878d4139, 0x161c2997, 0xe4a8e1be, 0x75398910, + 0x00c170ed, 0x91501843, 0x63e4d06a, 0xf275b8c4, 0xc812524a, + 0x59833ae4, 0xab37f2cd, 0x3aa69a63, 0x4f5e639e, 0xdecf0b30, + 0x2c7bc319, 0xbdeaabb7, 0x19b366df, 0x88220e71, 0x7a96c658, + 0xeb07aef6, 0x9eff570b, 0x0f6e3fa5, 0xfddaf78c, 0x6c4b9f22, + 0x562c75ac, 0xc7bd1d02, 0x3509d52b, 0xa498bd85, 0xd1604478, + 0x40f12cd6, 0xb245e4ff, 0x23d48c51, 0xf4edfd5c, 0x657c95f2, + 0x97c85ddb, 0x06593575, 0x73a1cc88, 0xe230a426, 0x10846c0f, + 0x811504a1, 0xbb72ee2f, 0x2ae38681, 0xd8574ea8, 0x49c62606, + 0x3c3edffb, 0xadafb755, 0x5f1b7f7c, 0xce8a17d2, 0x6ad3daba, + 0xfb42b214, 0x09f67a3d, 0x98671293, 0xed9feb6e, 0x7c0e83c0, + 0x8eba4be9, 0x1f2b2347, 0x254cc9c9, 0xb4dda167, 0x4669694e, + 0xd7f801e0, 0xa200f81d, 0x339190b3, 0xc125589a, 0x50b43034, + 0x8996c24b, 0x1807aae5, 0xeab362cc, 0x7b220a62, 0x0edaf39f, + 0x9f4b9b31, 0x6dff5318, 0xfc6e3bb6, 0xc609d138, 0x5798b996, + 0xa52c71bf, 0x34bd1911, 0x4145e0ec, 0xd0d48842, 0x2260406b, + 0xb3f128c5, 0x17a8e5ad, 0x86398d03, 0x748d452a, 0xe51c2d84, + 0x90e4d479, 0x0175bcd7, 0xf3c174fe, 0x62501c50, 0x5837f6de, + 0xc9a69e70, 0x3b125659, 0xaa833ef7, 0xdf7bc70a, 0x4eeaafa4, + 0xbc5e678d, 0x2dcf0f23, 0x0e1b8372, 0x9f8aebdc, 0x6d3e23f5, + 0xfcaf4b5b, 0x8957b2a6, 0x18c6da08, 0xea721221, 0x7be37a8f, + 0x41849001, 0xd015f8af, 0x22a13086, 0xb3305828, 0xc6c8a1d5, + 0x5759c97b, 0xa5ed0152, 0x347c69fc, 0x9025a494, 0x01b4cc3a, + 0xf3000413, 0x62916cbd, 0x17699540, 0x86f8fdee, 0x744c35c7, + 0xe5dd5d69, 0xdfbab7e7, 0x4e2bdf49, 0xbc9f1760, 0x2d0e7fce, + 0x58f68633, 0xc967ee9d, 0x3bd326b4, 0xaa424e1a, 0x7360bc65, + 0xe2f1d4cb, 0x10451ce2, 0x81d4744c, 0xf42c8db1, 0x65bde51f, + 0x97092d36, 0x06984598, 0x3cffaf16, 0xad6ec7b8, 0x5fda0f91, + 0xce4b673f, 0xbbb39ec2, 0x2a22f66c, 0xd8963e45, 0x490756eb, + 0xed5e9b83, 0x7ccff32d, 0x8e7b3b04, 0x1fea53aa, 0x6a12aa57, + 0xfb83c2f9, 0x09370ad0, 0x98a6627e, 0xa2c188f0, 0x3350e05e, + 0xc1e42877, 0x507540d9, 0x258db924, 0xb41cd18a, 0x46a819a3, + 0xd739710d}}; + +#endif + +#endif + +#if N == 5 + +#if W == 8 + +local const z_crc_t FAR crc_braid_table[][256] = { + {0x00000000, 0xaf449247, 0x85f822cf, 0x2abcb088, 0xd08143df, + 0x7fc5d198, 0x55796110, 0xfa3df357, 0x7a7381ff, 0xd53713b8, + 0xff8ba330, 0x50cf3177, 0xaaf2c220, 0x05b65067, 0x2f0ae0ef, + 0x804e72a8, 0xf4e703fe, 0x5ba391b9, 0x711f2131, 0xde5bb376, + 0x24664021, 0x8b22d266, 0xa19e62ee, 0x0edaf0a9, 0x8e948201, + 0x21d01046, 0x0b6ca0ce, 0xa4283289, 0x5e15c1de, 0xf1515399, + 0xdbede311, 0x74a97156, 0x32bf01bd, 0x9dfb93fa, 0xb7472372, + 0x1803b135, 0xe23e4262, 0x4d7ad025, 0x67c660ad, 0xc882f2ea, + 0x48cc8042, 0xe7881205, 0xcd34a28d, 0x627030ca, 0x984dc39d, + 0x370951da, 0x1db5e152, 0xb2f17315, 0xc6580243, 0x691c9004, + 0x43a0208c, 0xece4b2cb, 0x16d9419c, 0xb99dd3db, 0x93216353, + 0x3c65f114, 0xbc2b83bc, 0x136f11fb, 0x39d3a173, 0x96973334, + 0x6caac063, 0xc3ee5224, 0xe952e2ac, 0x461670eb, 0x657e037a, + 0xca3a913d, 0xe08621b5, 0x4fc2b3f2, 0xb5ff40a5, 0x1abbd2e2, + 0x3007626a, 0x9f43f02d, 0x1f0d8285, 0xb04910c2, 0x9af5a04a, + 0x35b1320d, 0xcf8cc15a, 0x60c8531d, 0x4a74e395, 0xe53071d2, + 0x91990084, 0x3edd92c3, 0x1461224b, 0xbb25b00c, 0x4118435b, + 0xee5cd11c, 0xc4e06194, 0x6ba4f3d3, 0xebea817b, 0x44ae133c, + 0x6e12a3b4, 0xc15631f3, 0x3b6bc2a4, 0x942f50e3, 0xbe93e06b, + 0x11d7722c, 0x57c102c7, 0xf8859080, 0xd2392008, 0x7d7db24f, + 0x87404118, 0x2804d35f, 0x02b863d7, 0xadfcf190, 0x2db28338, + 0x82f6117f, 0xa84aa1f7, 0x070e33b0, 0xfd33c0e7, 0x527752a0, + 0x78cbe228, 0xd78f706f, 0xa3260139, 0x0c62937e, 0x26de23f6, + 0x899ab1b1, 0x73a742e6, 0xdce3d0a1, 0xf65f6029, 0x591bf26e, + 0xd95580c6, 0x76111281, 0x5cada209, 0xf3e9304e, 0x09d4c319, + 0xa690515e, 0x8c2ce1d6, 0x23687391, 0xcafc06f4, 0x65b894b3, + 0x4f04243b, 0xe040b67c, 0x1a7d452b, 0xb539d76c, 0x9f8567e4, + 0x30c1f5a3, 0xb08f870b, 0x1fcb154c, 0x3577a5c4, 0x9a333783, + 0x600ec4d4, 0xcf4a5693, 0xe5f6e61b, 0x4ab2745c, 0x3e1b050a, + 0x915f974d, 0xbbe327c5, 0x14a7b582, 0xee9a46d5, 0x41ded492, + 0x6b62641a, 0xc426f65d, 0x446884f5, 0xeb2c16b2, 0xc190a63a, + 0x6ed4347d, 0x94e9c72a, 0x3bad556d, 0x1111e5e5, 0xbe5577a2, + 0xf8430749, 0x5707950e, 0x7dbb2586, 0xd2ffb7c1, 0x28c24496, + 0x8786d6d1, 0xad3a6659, 0x027ef41e, 0x823086b6, 0x2d7414f1, + 0x07c8a479, 0xa88c363e, 0x52b1c569, 0xfdf5572e, 0xd749e7a6, + 0x780d75e1, 0x0ca404b7, 0xa3e096f0, 0x895c2678, 0x2618b43f, + 0xdc254768, 0x7361d52f, 0x59dd65a7, 0xf699f7e0, 0x76d78548, + 0xd993170f, 0xf32fa787, 0x5c6b35c0, 0xa656c697, 0x091254d0, + 0x23aee458, 0x8cea761f, 0xaf82058e, 0x00c697c9, 0x2a7a2741, + 0x853eb506, 0x7f034651, 0xd047d416, 0xfafb649e, 0x55bff6d9, + 0xd5f18471, 0x7ab51636, 0x5009a6be, 0xff4d34f9, 0x0570c7ae, + 0xaa3455e9, 0x8088e561, 0x2fcc7726, 0x5b650670, 0xf4219437, + 0xde9d24bf, 0x71d9b6f8, 0x8be445af, 0x24a0d7e8, 0x0e1c6760, + 0xa158f527, 0x2116878f, 0x8e5215c8, 0xa4eea540, 0x0baa3707, + 0xf197c450, 0x5ed35617, 0x746fe69f, 0xdb2b74d8, 0x9d3d0433, + 0x32799674, 0x18c526fc, 0xb781b4bb, 0x4dbc47ec, 0xe2f8d5ab, + 0xc8446523, 0x6700f764, 0xe74e85cc, 0x480a178b, 0x62b6a703, + 0xcdf23544, 0x37cfc613, 0x988b5454, 0xb237e4dc, 0x1d73769b, + 0x69da07cd, 0xc69e958a, 0xec222502, 0x4366b745, 0xb95b4412, + 0x161fd655, 0x3ca366dd, 0x93e7f49a, 0x13a98632, 0xbced1475, + 0x9651a4fd, 0x391536ba, 0xc328c5ed, 0x6c6c57aa, 0x46d0e722, + 0xe9947565}, + {0x00000000, 0x4e890ba9, 0x9d121752, 0xd39b1cfb, 0xe15528e5, + 0xafdc234c, 0x7c473fb7, 0x32ce341e, 0x19db578b, 0x57525c22, + 0x84c940d9, 0xca404b70, 0xf88e7f6e, 0xb60774c7, 0x659c683c, + 0x2b156395, 0x33b6af16, 0x7d3fa4bf, 0xaea4b844, 0xe02db3ed, + 0xd2e387f3, 0x9c6a8c5a, 0x4ff190a1, 0x01789b08, 0x2a6df89d, + 0x64e4f334, 0xb77fefcf, 0xf9f6e466, 0xcb38d078, 0x85b1dbd1, + 0x562ac72a, 0x18a3cc83, 0x676d5e2c, 0x29e45585, 0xfa7f497e, + 0xb4f642d7, 0x863876c9, 0xc8b17d60, 0x1b2a619b, 0x55a36a32, + 0x7eb609a7, 0x303f020e, 0xe3a41ef5, 0xad2d155c, 0x9fe32142, + 0xd16a2aeb, 0x02f13610, 0x4c783db9, 0x54dbf13a, 0x1a52fa93, + 0xc9c9e668, 0x8740edc1, 0xb58ed9df, 0xfb07d276, 0x289cce8d, + 0x6615c524, 0x4d00a6b1, 0x0389ad18, 0xd012b1e3, 0x9e9bba4a, + 0xac558e54, 0xe2dc85fd, 0x31479906, 0x7fce92af, 0xcedabc58, + 0x8053b7f1, 0x53c8ab0a, 0x1d41a0a3, 0x2f8f94bd, 0x61069f14, + 0xb29d83ef, 0xfc148846, 0xd701ebd3, 0x9988e07a, 0x4a13fc81, + 0x049af728, 0x3654c336, 0x78ddc89f, 0xab46d464, 0xe5cfdfcd, + 0xfd6c134e, 0xb3e518e7, 0x607e041c, 0x2ef70fb5, 0x1c393bab, + 0x52b03002, 0x812b2cf9, 0xcfa22750, 0xe4b744c5, 0xaa3e4f6c, + 0x79a55397, 0x372c583e, 0x05e26c20, 0x4b6b6789, 0x98f07b72, + 0xd67970db, 0xa9b7e274, 0xe73ee9dd, 0x34a5f526, 0x7a2cfe8f, + 0x48e2ca91, 0x066bc138, 0xd5f0ddc3, 0x9b79d66a, 0xb06cb5ff, + 0xfee5be56, 0x2d7ea2ad, 0x63f7a904, 0x51399d1a, 0x1fb096b3, + 0xcc2b8a48, 0x82a281e1, 0x9a014d62, 0xd48846cb, 0x07135a30, + 0x499a5199, 0x7b546587, 0x35dd6e2e, 0xe64672d5, 0xa8cf797c, + 0x83da1ae9, 0xcd531140, 0x1ec80dbb, 0x50410612, 0x628f320c, + 0x2c0639a5, 0xff9d255e, 0xb1142ef7, 0x46c47ef1, 0x084d7558, + 0xdbd669a3, 0x955f620a, 0xa7915614, 0xe9185dbd, 0x3a834146, + 0x740a4aef, 0x5f1f297a, 0x119622d3, 0xc20d3e28, 0x8c843581, + 0xbe4a019f, 0xf0c30a36, 0x235816cd, 0x6dd11d64, 0x7572d1e7, + 0x3bfbda4e, 0xe860c6b5, 0xa6e9cd1c, 0x9427f902, 0xdaaef2ab, + 0x0935ee50, 0x47bce5f9, 0x6ca9866c, 0x22208dc5, 0xf1bb913e, + 0xbf329a97, 0x8dfcae89, 0xc375a520, 0x10eeb9db, 0x5e67b272, + 0x21a920dd, 0x6f202b74, 0xbcbb378f, 0xf2323c26, 0xc0fc0838, + 0x8e750391, 0x5dee1f6a, 0x136714c3, 0x38727756, 0x76fb7cff, + 0xa5606004, 0xebe96bad, 0xd9275fb3, 0x97ae541a, 0x443548e1, + 0x0abc4348, 0x121f8fcb, 0x5c968462, 0x8f0d9899, 0xc1849330, + 0xf34aa72e, 0xbdc3ac87, 0x6e58b07c, 0x20d1bbd5, 0x0bc4d840, + 0x454dd3e9, 0x96d6cf12, 0xd85fc4bb, 0xea91f0a5, 0xa418fb0c, + 0x7783e7f7, 0x390aec5e, 0x881ec2a9, 0xc697c900, 0x150cd5fb, + 0x5b85de52, 0x694bea4c, 0x27c2e1e5, 0xf459fd1e, 0xbad0f6b7, + 0x91c59522, 0xdf4c9e8b, 0x0cd78270, 0x425e89d9, 0x7090bdc7, + 0x3e19b66e, 0xed82aa95, 0xa30ba13c, 0xbba86dbf, 0xf5216616, + 0x26ba7aed, 0x68337144, 0x5afd455a, 0x14744ef3, 0xc7ef5208, + 0x896659a1, 0xa2733a34, 0xecfa319d, 0x3f612d66, 0x71e826cf, + 0x432612d1, 0x0daf1978, 0xde340583, 0x90bd0e2a, 0xef739c85, + 0xa1fa972c, 0x72618bd7, 0x3ce8807e, 0x0e26b460, 0x40afbfc9, + 0x9334a332, 0xddbda89b, 0xf6a8cb0e, 0xb821c0a7, 0x6bbadc5c, + 0x2533d7f5, 0x17fde3eb, 0x5974e842, 0x8aeff4b9, 0xc466ff10, + 0xdcc53393, 0x924c383a, 0x41d724c1, 0x0f5e2f68, 0x3d901b76, + 0x731910df, 0xa0820c24, 0xee0b078d, 0xc51e6418, 0x8b976fb1, + 0x580c734a, 0x168578e3, 0x244b4cfd, 0x6ac24754, 0xb9595baf, + 0xf7d05006}, + {0x00000000, 0x8d88fde2, 0xc060fd85, 0x4de80067, 0x5bb0fd4b, + 0xd63800a9, 0x9bd000ce, 0x1658fd2c, 0xb761fa96, 0x3ae90774, + 0x77010713, 0xfa89faf1, 0xecd107dd, 0x6159fa3f, 0x2cb1fa58, + 0xa13907ba, 0xb5b2f36d, 0x383a0e8f, 0x75d20ee8, 0xf85af30a, + 0xee020e26, 0x638af3c4, 0x2e62f3a3, 0xa3ea0e41, 0x02d309fb, + 0x8f5bf419, 0xc2b3f47e, 0x4f3b099c, 0x5963f4b0, 0xd4eb0952, + 0x99030935, 0x148bf4d7, 0xb014e09b, 0x3d9c1d79, 0x70741d1e, + 0xfdfce0fc, 0xeba41dd0, 0x662ce032, 0x2bc4e055, 0xa64c1db7, + 0x07751a0d, 0x8afde7ef, 0xc715e788, 0x4a9d1a6a, 0x5cc5e746, + 0xd14d1aa4, 0x9ca51ac3, 0x112de721, 0x05a613f6, 0x882eee14, + 0xc5c6ee73, 0x484e1391, 0x5e16eebd, 0xd39e135f, 0x9e761338, + 0x13feeeda, 0xb2c7e960, 0x3f4f1482, 0x72a714e5, 0xff2fe907, + 0xe977142b, 0x64ffe9c9, 0x2917e9ae, 0xa49f144c, 0xbb58c777, + 0x36d03a95, 0x7b383af2, 0xf6b0c710, 0xe0e83a3c, 0x6d60c7de, + 0x2088c7b9, 0xad003a5b, 0x0c393de1, 0x81b1c003, 0xcc59c064, + 0x41d13d86, 0x5789c0aa, 0xda013d48, 0x97e93d2f, 0x1a61c0cd, + 0x0eea341a, 0x8362c9f8, 0xce8ac99f, 0x4302347d, 0x555ac951, + 0xd8d234b3, 0x953a34d4, 0x18b2c936, 0xb98bce8c, 0x3403336e, + 0x79eb3309, 0xf463ceeb, 0xe23b33c7, 0x6fb3ce25, 0x225bce42, + 0xafd333a0, 0x0b4c27ec, 0x86c4da0e, 0xcb2cda69, 0x46a4278b, + 0x50fcdaa7, 0xdd742745, 0x909c2722, 0x1d14dac0, 0xbc2ddd7a, + 0x31a52098, 0x7c4d20ff, 0xf1c5dd1d, 0xe79d2031, 0x6a15ddd3, + 0x27fdddb4, 0xaa752056, 0xbefed481, 0x33762963, 0x7e9e2904, + 0xf316d4e6, 0xe54e29ca, 0x68c6d428, 0x252ed44f, 0xa8a629ad, + 0x099f2e17, 0x8417d3f5, 0xc9ffd392, 0x44772e70, 0x522fd35c, + 0xdfa72ebe, 0x924f2ed9, 0x1fc7d33b, 0xadc088af, 0x2048754d, + 0x6da0752a, 0xe02888c8, 0xf67075e4, 0x7bf88806, 0x36108861, + 0xbb987583, 0x1aa17239, 0x97298fdb, 0xdac18fbc, 0x5749725e, + 0x41118f72, 0xcc997290, 0x817172f7, 0x0cf98f15, 0x18727bc2, + 0x95fa8620, 0xd8128647, 0x559a7ba5, 0x43c28689, 0xce4a7b6b, + 0x83a27b0c, 0x0e2a86ee, 0xaf138154, 0x229b7cb6, 0x6f737cd1, + 0xe2fb8133, 0xf4a37c1f, 0x792b81fd, 0x34c3819a, 0xb94b7c78, + 0x1dd46834, 0x905c95d6, 0xddb495b1, 0x503c6853, 0x4664957f, + 0xcbec689d, 0x860468fa, 0x0b8c9518, 0xaab592a2, 0x273d6f40, + 0x6ad56f27, 0xe75d92c5, 0xf1056fe9, 0x7c8d920b, 0x3165926c, + 0xbced6f8e, 0xa8669b59, 0x25ee66bb, 0x680666dc, 0xe58e9b3e, + 0xf3d66612, 0x7e5e9bf0, 0x33b69b97, 0xbe3e6675, 0x1f0761cf, + 0x928f9c2d, 0xdf679c4a, 0x52ef61a8, 0x44b79c84, 0xc93f6166, + 0x84d76101, 0x095f9ce3, 0x16984fd8, 0x9b10b23a, 0xd6f8b25d, + 0x5b704fbf, 0x4d28b293, 0xc0a04f71, 0x8d484f16, 0x00c0b2f4, + 0xa1f9b54e, 0x2c7148ac, 0x619948cb, 0xec11b529, 0xfa494805, + 0x77c1b5e7, 0x3a29b580, 0xb7a14862, 0xa32abcb5, 0x2ea24157, + 0x634a4130, 0xeec2bcd2, 0xf89a41fe, 0x7512bc1c, 0x38fabc7b, + 0xb5724199, 0x144b4623, 0x99c3bbc1, 0xd42bbba6, 0x59a34644, + 0x4ffbbb68, 0xc273468a, 0x8f9b46ed, 0x0213bb0f, 0xa68caf43, + 0x2b0452a1, 0x66ec52c6, 0xeb64af24, 0xfd3c5208, 0x70b4afea, + 0x3d5caf8d, 0xb0d4526f, 0x11ed55d5, 0x9c65a837, 0xd18da850, + 0x5c0555b2, 0x4a5da89e, 0xc7d5557c, 0x8a3d551b, 0x07b5a8f9, + 0x133e5c2e, 0x9eb6a1cc, 0xd35ea1ab, 0x5ed65c49, 0x488ea165, + 0xc5065c87, 0x88ee5ce0, 0x0566a102, 0xa45fa6b8, 0x29d75b5a, + 0x643f5b3d, 0xe9b7a6df, 0xffef5bf3, 0x7267a611, 0x3f8fa676, + 0xb2075b94}, + {0x00000000, 0x80f0171f, 0xda91287f, 0x5a613f60, 0x6e5356bf, + 0xeea341a0, 0xb4c27ec0, 0x343269df, 0xdca6ad7e, 0x5c56ba61, + 0x06378501, 0x86c7921e, 0xb2f5fbc1, 0x3205ecde, 0x6864d3be, + 0xe894c4a1, 0x623c5cbd, 0xe2cc4ba2, 0xb8ad74c2, 0x385d63dd, + 0x0c6f0a02, 0x8c9f1d1d, 0xd6fe227d, 0x560e3562, 0xbe9af1c3, + 0x3e6ae6dc, 0x640bd9bc, 0xe4fbcea3, 0xd0c9a77c, 0x5039b063, + 0x0a588f03, 0x8aa8981c, 0xc478b97a, 0x4488ae65, 0x1ee99105, + 0x9e19861a, 0xaa2befc5, 0x2adbf8da, 0x70bac7ba, 0xf04ad0a5, + 0x18de1404, 0x982e031b, 0xc24f3c7b, 0x42bf2b64, 0x768d42bb, + 0xf67d55a4, 0xac1c6ac4, 0x2cec7ddb, 0xa644e5c7, 0x26b4f2d8, + 0x7cd5cdb8, 0xfc25daa7, 0xc817b378, 0x48e7a467, 0x12869b07, + 0x92768c18, 0x7ae248b9, 0xfa125fa6, 0xa07360c6, 0x208377d9, + 0x14b11e06, 0x94410919, 0xce203679, 0x4ed02166, 0x538074b5, + 0xd37063aa, 0x89115cca, 0x09e14bd5, 0x3dd3220a, 0xbd233515, + 0xe7420a75, 0x67b21d6a, 0x8f26d9cb, 0x0fd6ced4, 0x55b7f1b4, + 0xd547e6ab, 0xe1758f74, 0x6185986b, 0x3be4a70b, 0xbb14b014, + 0x31bc2808, 0xb14c3f17, 0xeb2d0077, 0x6bdd1768, 0x5fef7eb7, + 0xdf1f69a8, 0x857e56c8, 0x058e41d7, 0xed1a8576, 0x6dea9269, + 0x378bad09, 0xb77bba16, 0x8349d3c9, 0x03b9c4d6, 0x59d8fbb6, + 0xd928eca9, 0x97f8cdcf, 0x1708dad0, 0x4d69e5b0, 0xcd99f2af, + 0xf9ab9b70, 0x795b8c6f, 0x233ab30f, 0xa3caa410, 0x4b5e60b1, + 0xcbae77ae, 0x91cf48ce, 0x113f5fd1, 0x250d360e, 0xa5fd2111, + 0xff9c1e71, 0x7f6c096e, 0xf5c49172, 0x7534866d, 0x2f55b90d, + 0xafa5ae12, 0x9b97c7cd, 0x1b67d0d2, 0x4106efb2, 0xc1f6f8ad, + 0x29623c0c, 0xa9922b13, 0xf3f31473, 0x7303036c, 0x47316ab3, + 0xc7c17dac, 0x9da042cc, 0x1d5055d3, 0xa700e96a, 0x27f0fe75, + 0x7d91c115, 0xfd61d60a, 0xc953bfd5, 0x49a3a8ca, 0x13c297aa, + 0x933280b5, 0x7ba64414, 0xfb56530b, 0xa1376c6b, 0x21c77b74, + 0x15f512ab, 0x950505b4, 0xcf643ad4, 0x4f942dcb, 0xc53cb5d7, + 0x45cca2c8, 0x1fad9da8, 0x9f5d8ab7, 0xab6fe368, 0x2b9ff477, + 0x71fecb17, 0xf10edc08, 0x199a18a9, 0x996a0fb6, 0xc30b30d6, + 0x43fb27c9, 0x77c94e16, 0xf7395909, 0xad586669, 0x2da87176, + 0x63785010, 0xe388470f, 0xb9e9786f, 0x39196f70, 0x0d2b06af, + 0x8ddb11b0, 0xd7ba2ed0, 0x574a39cf, 0xbfdefd6e, 0x3f2eea71, + 0x654fd511, 0xe5bfc20e, 0xd18dabd1, 0x517dbcce, 0x0b1c83ae, + 0x8bec94b1, 0x01440cad, 0x81b41bb2, 0xdbd524d2, 0x5b2533cd, + 0x6f175a12, 0xefe74d0d, 0xb586726d, 0x35766572, 0xdde2a1d3, + 0x5d12b6cc, 0x077389ac, 0x87839eb3, 0xb3b1f76c, 0x3341e073, + 0x6920df13, 0xe9d0c80c, 0xf4809ddf, 0x74708ac0, 0x2e11b5a0, + 0xaee1a2bf, 0x9ad3cb60, 0x1a23dc7f, 0x4042e31f, 0xc0b2f400, + 0x282630a1, 0xa8d627be, 0xf2b718de, 0x72470fc1, 0x4675661e, + 0xc6857101, 0x9ce44e61, 0x1c14597e, 0x96bcc162, 0x164cd67d, + 0x4c2de91d, 0xccddfe02, 0xf8ef97dd, 0x781f80c2, 0x227ebfa2, + 0xa28ea8bd, 0x4a1a6c1c, 0xcaea7b03, 0x908b4463, 0x107b537c, + 0x24493aa3, 0xa4b92dbc, 0xfed812dc, 0x7e2805c3, 0x30f824a5, + 0xb00833ba, 0xea690cda, 0x6a991bc5, 0x5eab721a, 0xde5b6505, + 0x843a5a65, 0x04ca4d7a, 0xec5e89db, 0x6cae9ec4, 0x36cfa1a4, + 0xb63fb6bb, 0x820ddf64, 0x02fdc87b, 0x589cf71b, 0xd86ce004, + 0x52c47818, 0xd2346f07, 0x88555067, 0x08a54778, 0x3c972ea7, + 0xbc6739b8, 0xe60606d8, 0x66f611c7, 0x8e62d566, 0x0e92c279, + 0x54f3fd19, 0xd403ea06, 0xe03183d9, 0x60c194c6, 0x3aa0aba6, + 0xba50bcb9}, + {0x00000000, 0x9570d495, 0xf190af6b, 0x64e07bfe, 0x38505897, + 0xad208c02, 0xc9c0f7fc, 0x5cb02369, 0x70a0b12e, 0xe5d065bb, + 0x81301e45, 0x1440cad0, 0x48f0e9b9, 0xdd803d2c, 0xb96046d2, + 0x2c109247, 0xe141625c, 0x7431b6c9, 0x10d1cd37, 0x85a119a2, + 0xd9113acb, 0x4c61ee5e, 0x288195a0, 0xbdf14135, 0x91e1d372, + 0x049107e7, 0x60717c19, 0xf501a88c, 0xa9b18be5, 0x3cc15f70, + 0x5821248e, 0xcd51f01b, 0x19f3c2f9, 0x8c83166c, 0xe8636d92, + 0x7d13b907, 0x21a39a6e, 0xb4d34efb, 0xd0333505, 0x4543e190, + 0x695373d7, 0xfc23a742, 0x98c3dcbc, 0x0db30829, 0x51032b40, + 0xc473ffd5, 0xa093842b, 0x35e350be, 0xf8b2a0a5, 0x6dc27430, + 0x09220fce, 0x9c52db5b, 0xc0e2f832, 0x55922ca7, 0x31725759, + 0xa40283cc, 0x8812118b, 0x1d62c51e, 0x7982bee0, 0xecf26a75, + 0xb042491c, 0x25329d89, 0x41d2e677, 0xd4a232e2, 0x33e785f2, + 0xa6975167, 0xc2772a99, 0x5707fe0c, 0x0bb7dd65, 0x9ec709f0, + 0xfa27720e, 0x6f57a69b, 0x434734dc, 0xd637e049, 0xb2d79bb7, + 0x27a74f22, 0x7b176c4b, 0xee67b8de, 0x8a87c320, 0x1ff717b5, + 0xd2a6e7ae, 0x47d6333b, 0x233648c5, 0xb6469c50, 0xeaf6bf39, + 0x7f866bac, 0x1b661052, 0x8e16c4c7, 0xa2065680, 0x37768215, + 0x5396f9eb, 0xc6e62d7e, 0x9a560e17, 0x0f26da82, 0x6bc6a17c, + 0xfeb675e9, 0x2a14470b, 0xbf64939e, 0xdb84e860, 0x4ef43cf5, + 0x12441f9c, 0x8734cb09, 0xe3d4b0f7, 0x76a46462, 0x5ab4f625, + 0xcfc422b0, 0xab24594e, 0x3e548ddb, 0x62e4aeb2, 0xf7947a27, + 0x937401d9, 0x0604d54c, 0xcb552557, 0x5e25f1c2, 0x3ac58a3c, + 0xafb55ea9, 0xf3057dc0, 0x6675a955, 0x0295d2ab, 0x97e5063e, + 0xbbf59479, 0x2e8540ec, 0x4a653b12, 0xdf15ef87, 0x83a5ccee, + 0x16d5187b, 0x72356385, 0xe745b710, 0x67cf0be4, 0xf2bfdf71, + 0x965fa48f, 0x032f701a, 0x5f9f5373, 0xcaef87e6, 0xae0ffc18, + 0x3b7f288d, 0x176fbaca, 0x821f6e5f, 0xe6ff15a1, 0x738fc134, + 0x2f3fe25d, 0xba4f36c8, 0xdeaf4d36, 0x4bdf99a3, 0x868e69b8, + 0x13febd2d, 0x771ec6d3, 0xe26e1246, 0xbede312f, 0x2baee5ba, + 0x4f4e9e44, 0xda3e4ad1, 0xf62ed896, 0x635e0c03, 0x07be77fd, + 0x92cea368, 0xce7e8001, 0x5b0e5494, 0x3fee2f6a, 0xaa9efbff, + 0x7e3cc91d, 0xeb4c1d88, 0x8fac6676, 0x1adcb2e3, 0x466c918a, + 0xd31c451f, 0xb7fc3ee1, 0x228cea74, 0x0e9c7833, 0x9becaca6, + 0xff0cd758, 0x6a7c03cd, 0x36cc20a4, 0xa3bcf431, 0xc75c8fcf, + 0x522c5b5a, 0x9f7dab41, 0x0a0d7fd4, 0x6eed042a, 0xfb9dd0bf, + 0xa72df3d6, 0x325d2743, 0x56bd5cbd, 0xc3cd8828, 0xefdd1a6f, + 0x7aadcefa, 0x1e4db504, 0x8b3d6191, 0xd78d42f8, 0x42fd966d, + 0x261ded93, 0xb36d3906, 0x54288e16, 0xc1585a83, 0xa5b8217d, + 0x30c8f5e8, 0x6c78d681, 0xf9080214, 0x9de879ea, 0x0898ad7f, + 0x24883f38, 0xb1f8ebad, 0xd5189053, 0x406844c6, 0x1cd867af, + 0x89a8b33a, 0xed48c8c4, 0x78381c51, 0xb569ec4a, 0x201938df, + 0x44f94321, 0xd18997b4, 0x8d39b4dd, 0x18496048, 0x7ca91bb6, + 0xe9d9cf23, 0xc5c95d64, 0x50b989f1, 0x3459f20f, 0xa129269a, + 0xfd9905f3, 0x68e9d166, 0x0c09aa98, 0x99797e0d, 0x4ddb4cef, + 0xd8ab987a, 0xbc4be384, 0x293b3711, 0x758b1478, 0xe0fbc0ed, + 0x841bbb13, 0x116b6f86, 0x3d7bfdc1, 0xa80b2954, 0xcceb52aa, + 0x599b863f, 0x052ba556, 0x905b71c3, 0xf4bb0a3d, 0x61cbdea8, + 0xac9a2eb3, 0x39eafa26, 0x5d0a81d8, 0xc87a554d, 0x94ca7624, + 0x01baa2b1, 0x655ad94f, 0xf02a0dda, 0xdc3a9f9d, 0x494a4b08, + 0x2daa30f6, 0xb8dae463, 0xe46ac70a, 0x711a139f, 0x15fa6861, + 0x808abcf4}, + {0x00000000, 0xcf9e17c8, 0x444d29d1, 0x8bd33e19, 0x889a53a2, + 0x4704446a, 0xccd77a73, 0x03496dbb, 0xca45a105, 0x05dbb6cd, + 0x8e0888d4, 0x41969f1c, 0x42dff2a7, 0x8d41e56f, 0x0692db76, + 0xc90cccbe, 0x4ffa444b, 0x80645383, 0x0bb76d9a, 0xc4297a52, + 0xc76017e9, 0x08fe0021, 0x832d3e38, 0x4cb329f0, 0x85bfe54e, + 0x4a21f286, 0xc1f2cc9f, 0x0e6cdb57, 0x0d25b6ec, 0xc2bba124, + 0x49689f3d, 0x86f688f5, 0x9ff48896, 0x506a9f5e, 0xdbb9a147, + 0x1427b68f, 0x176edb34, 0xd8f0ccfc, 0x5323f2e5, 0x9cbde52d, + 0x55b12993, 0x9a2f3e5b, 0x11fc0042, 0xde62178a, 0xdd2b7a31, + 0x12b56df9, 0x996653e0, 0x56f84428, 0xd00eccdd, 0x1f90db15, + 0x9443e50c, 0x5bddf2c4, 0x58949f7f, 0x970a88b7, 0x1cd9b6ae, + 0xd347a166, 0x1a4b6dd8, 0xd5d57a10, 0x5e064409, 0x919853c1, + 0x92d13e7a, 0x5d4f29b2, 0xd69c17ab, 0x19020063, 0xe498176d, + 0x2b0600a5, 0xa0d53ebc, 0x6f4b2974, 0x6c0244cf, 0xa39c5307, + 0x284f6d1e, 0xe7d17ad6, 0x2eddb668, 0xe143a1a0, 0x6a909fb9, + 0xa50e8871, 0xa647e5ca, 0x69d9f202, 0xe20acc1b, 0x2d94dbd3, + 0xab625326, 0x64fc44ee, 0xef2f7af7, 0x20b16d3f, 0x23f80084, + 0xec66174c, 0x67b52955, 0xa82b3e9d, 0x6127f223, 0xaeb9e5eb, + 0x256adbf2, 0xeaf4cc3a, 0xe9bda181, 0x2623b649, 0xadf08850, + 0x626e9f98, 0x7b6c9ffb, 0xb4f28833, 0x3f21b62a, 0xf0bfa1e2, + 0xf3f6cc59, 0x3c68db91, 0xb7bbe588, 0x7825f240, 0xb1293efe, + 0x7eb72936, 0xf564172f, 0x3afa00e7, 0x39b36d5c, 0xf62d7a94, + 0x7dfe448d, 0xb2605345, 0x3496dbb0, 0xfb08cc78, 0x70dbf261, + 0xbf45e5a9, 0xbc0c8812, 0x73929fda, 0xf841a1c3, 0x37dfb60b, + 0xfed37ab5, 0x314d6d7d, 0xba9e5364, 0x750044ac, 0x76492917, + 0xb9d73edf, 0x320400c6, 0xfd9a170e, 0x1241289b, 0xdddf3f53, + 0x560c014a, 0x99921682, 0x9adb7b39, 0x55456cf1, 0xde9652e8, + 0x11084520, 0xd804899e, 0x179a9e56, 0x9c49a04f, 0x53d7b787, + 0x509eda3c, 0x9f00cdf4, 0x14d3f3ed, 0xdb4de425, 0x5dbb6cd0, + 0x92257b18, 0x19f64501, 0xd66852c9, 0xd5213f72, 0x1abf28ba, + 0x916c16a3, 0x5ef2016b, 0x97fecdd5, 0x5860da1d, 0xd3b3e404, + 0x1c2df3cc, 0x1f649e77, 0xd0fa89bf, 0x5b29b7a6, 0x94b7a06e, + 0x8db5a00d, 0x422bb7c5, 0xc9f889dc, 0x06669e14, 0x052ff3af, + 0xcab1e467, 0x4162da7e, 0x8efccdb6, 0x47f00108, 0x886e16c0, + 0x03bd28d9, 0xcc233f11, 0xcf6a52aa, 0x00f44562, 0x8b277b7b, + 0x44b96cb3, 0xc24fe446, 0x0dd1f38e, 0x8602cd97, 0x499cda5f, + 0x4ad5b7e4, 0x854ba02c, 0x0e989e35, 0xc10689fd, 0x080a4543, + 0xc794528b, 0x4c476c92, 0x83d97b5a, 0x809016e1, 0x4f0e0129, + 0xc4dd3f30, 0x0b4328f8, 0xf6d93ff6, 0x3947283e, 0xb2941627, + 0x7d0a01ef, 0x7e436c54, 0xb1dd7b9c, 0x3a0e4585, 0xf590524d, + 0x3c9c9ef3, 0xf302893b, 0x78d1b722, 0xb74fa0ea, 0xb406cd51, + 0x7b98da99, 0xf04be480, 0x3fd5f348, 0xb9237bbd, 0x76bd6c75, + 0xfd6e526c, 0x32f045a4, 0x31b9281f, 0xfe273fd7, 0x75f401ce, + 0xba6a1606, 0x7366dab8, 0xbcf8cd70, 0x372bf369, 0xf8b5e4a1, + 0xfbfc891a, 0x34629ed2, 0xbfb1a0cb, 0x702fb703, 0x692db760, + 0xa6b3a0a8, 0x2d609eb1, 0xe2fe8979, 0xe1b7e4c2, 0x2e29f30a, + 0xa5facd13, 0x6a64dadb, 0xa3681665, 0x6cf601ad, 0xe7253fb4, + 0x28bb287c, 0x2bf245c7, 0xe46c520f, 0x6fbf6c16, 0xa0217bde, + 0x26d7f32b, 0xe949e4e3, 0x629adafa, 0xad04cd32, 0xae4da089, + 0x61d3b741, 0xea008958, 0x259e9e90, 0xec92522e, 0x230c45e6, + 0xa8df7bff, 0x67416c37, 0x6408018c, 0xab961644, 0x2045285d, + 0xefdb3f95}, + {0x00000000, 0x24825136, 0x4904a26c, 0x6d86f35a, 0x920944d8, + 0xb68b15ee, 0xdb0de6b4, 0xff8fb782, 0xff638ff1, 0xdbe1dec7, + 0xb6672d9d, 0x92e57cab, 0x6d6acb29, 0x49e89a1f, 0x246e6945, + 0x00ec3873, 0x25b619a3, 0x01344895, 0x6cb2bbcf, 0x4830eaf9, + 0xb7bf5d7b, 0x933d0c4d, 0xfebbff17, 0xda39ae21, 0xdad59652, + 0xfe57c764, 0x93d1343e, 0xb7536508, 0x48dcd28a, 0x6c5e83bc, + 0x01d870e6, 0x255a21d0, 0x4b6c3346, 0x6fee6270, 0x0268912a, + 0x26eac01c, 0xd965779e, 0xfde726a8, 0x9061d5f2, 0xb4e384c4, + 0xb40fbcb7, 0x908ded81, 0xfd0b1edb, 0xd9894fed, 0x2606f86f, + 0x0284a959, 0x6f025a03, 0x4b800b35, 0x6eda2ae5, 0x4a587bd3, + 0x27de8889, 0x035cd9bf, 0xfcd36e3d, 0xd8513f0b, 0xb5d7cc51, + 0x91559d67, 0x91b9a514, 0xb53bf422, 0xd8bd0778, 0xfc3f564e, + 0x03b0e1cc, 0x2732b0fa, 0x4ab443a0, 0x6e361296, 0x96d8668c, + 0xb25a37ba, 0xdfdcc4e0, 0xfb5e95d6, 0x04d12254, 0x20537362, + 0x4dd58038, 0x6957d10e, 0x69bbe97d, 0x4d39b84b, 0x20bf4b11, + 0x043d1a27, 0xfbb2ada5, 0xdf30fc93, 0xb2b60fc9, 0x96345eff, + 0xb36e7f2f, 0x97ec2e19, 0xfa6add43, 0xdee88c75, 0x21673bf7, + 0x05e56ac1, 0x6863999b, 0x4ce1c8ad, 0x4c0df0de, 0x688fa1e8, + 0x050952b2, 0x218b0384, 0xde04b406, 0xfa86e530, 0x9700166a, + 0xb382475c, 0xddb455ca, 0xf93604fc, 0x94b0f7a6, 0xb032a690, + 0x4fbd1112, 0x6b3f4024, 0x06b9b37e, 0x223be248, 0x22d7da3b, + 0x06558b0d, 0x6bd37857, 0x4f512961, 0xb0de9ee3, 0x945ccfd5, + 0xf9da3c8f, 0xdd586db9, 0xf8024c69, 0xdc801d5f, 0xb106ee05, + 0x9584bf33, 0x6a0b08b1, 0x4e895987, 0x230faadd, 0x078dfbeb, + 0x0761c398, 0x23e392ae, 0x4e6561f4, 0x6ae730c2, 0x95688740, + 0xb1ead676, 0xdc6c252c, 0xf8ee741a, 0xf6c1cb59, 0xd2439a6f, + 0xbfc56935, 0x9b473803, 0x64c88f81, 0x404adeb7, 0x2dcc2ded, + 0x094e7cdb, 0x09a244a8, 0x2d20159e, 0x40a6e6c4, 0x6424b7f2, + 0x9bab0070, 0xbf295146, 0xd2afa21c, 0xf62df32a, 0xd377d2fa, + 0xf7f583cc, 0x9a737096, 0xbef121a0, 0x417e9622, 0x65fcc714, + 0x087a344e, 0x2cf86578, 0x2c145d0b, 0x08960c3d, 0x6510ff67, + 0x4192ae51, 0xbe1d19d3, 0x9a9f48e5, 0xf719bbbf, 0xd39bea89, + 0xbdadf81f, 0x992fa929, 0xf4a95a73, 0xd02b0b45, 0x2fa4bcc7, + 0x0b26edf1, 0x66a01eab, 0x42224f9d, 0x42ce77ee, 0x664c26d8, + 0x0bcad582, 0x2f4884b4, 0xd0c73336, 0xf4456200, 0x99c3915a, + 0xbd41c06c, 0x981be1bc, 0xbc99b08a, 0xd11f43d0, 0xf59d12e6, + 0x0a12a564, 0x2e90f452, 0x43160708, 0x6794563e, 0x67786e4d, + 0x43fa3f7b, 0x2e7ccc21, 0x0afe9d17, 0xf5712a95, 0xd1f37ba3, + 0xbc7588f9, 0x98f7d9cf, 0x6019add5, 0x449bfce3, 0x291d0fb9, + 0x0d9f5e8f, 0xf210e90d, 0xd692b83b, 0xbb144b61, 0x9f961a57, + 0x9f7a2224, 0xbbf87312, 0xd67e8048, 0xf2fcd17e, 0x0d7366fc, + 0x29f137ca, 0x4477c490, 0x60f595a6, 0x45afb476, 0x612de540, + 0x0cab161a, 0x2829472c, 0xd7a6f0ae, 0xf324a198, 0x9ea252c2, + 0xba2003f4, 0xbacc3b87, 0x9e4e6ab1, 0xf3c899eb, 0xd74ac8dd, + 0x28c57f5f, 0x0c472e69, 0x61c1dd33, 0x45438c05, 0x2b759e93, + 0x0ff7cfa5, 0x62713cff, 0x46f36dc9, 0xb97cda4b, 0x9dfe8b7d, + 0xf0787827, 0xd4fa2911, 0xd4161162, 0xf0944054, 0x9d12b30e, + 0xb990e238, 0x461f55ba, 0x629d048c, 0x0f1bf7d6, 0x2b99a6e0, + 0x0ec38730, 0x2a41d606, 0x47c7255c, 0x6345746a, 0x9ccac3e8, + 0xb84892de, 0xd5ce6184, 0xf14c30b2, 0xf1a008c1, 0xd52259f7, + 0xb8a4aaad, 0x9c26fb9b, 0x63a94c19, 0x472b1d2f, 0x2aadee75, + 0x0e2fbf43}, + {0x00000000, 0x36f290f3, 0x6de521e6, 0x5b17b115, 0xdbca43cc, + 0xed38d33f, 0xb62f622a, 0x80ddf2d9, 0x6ce581d9, 0x5a17112a, + 0x0100a03f, 0x37f230cc, 0xb72fc215, 0x81dd52e6, 0xdacae3f3, + 0xec387300, 0xd9cb03b2, 0xef399341, 0xb42e2254, 0x82dcb2a7, + 0x0201407e, 0x34f3d08d, 0x6fe46198, 0x5916f16b, 0xb52e826b, + 0x83dc1298, 0xd8cba38d, 0xee39337e, 0x6ee4c1a7, 0x58165154, + 0x0301e041, 0x35f370b2, 0x68e70125, 0x5e1591d6, 0x050220c3, + 0x33f0b030, 0xb32d42e9, 0x85dfd21a, 0xdec8630f, 0xe83af3fc, + 0x040280fc, 0x32f0100f, 0x69e7a11a, 0x5f1531e9, 0xdfc8c330, + 0xe93a53c3, 0xb22de2d6, 0x84df7225, 0xb12c0297, 0x87de9264, + 0xdcc92371, 0xea3bb382, 0x6ae6415b, 0x5c14d1a8, 0x070360bd, + 0x31f1f04e, 0xddc9834e, 0xeb3b13bd, 0xb02ca2a8, 0x86de325b, + 0x0603c082, 0x30f15071, 0x6be6e164, 0x5d147197, 0xd1ce024a, + 0xe73c92b9, 0xbc2b23ac, 0x8ad9b35f, 0x0a044186, 0x3cf6d175, + 0x67e16060, 0x5113f093, 0xbd2b8393, 0x8bd91360, 0xd0cea275, + 0xe63c3286, 0x66e1c05f, 0x501350ac, 0x0b04e1b9, 0x3df6714a, + 0x080501f8, 0x3ef7910b, 0x65e0201e, 0x5312b0ed, 0xd3cf4234, + 0xe53dd2c7, 0xbe2a63d2, 0x88d8f321, 0x64e08021, 0x521210d2, + 0x0905a1c7, 0x3ff73134, 0xbf2ac3ed, 0x89d8531e, 0xd2cfe20b, + 0xe43d72f8, 0xb929036f, 0x8fdb939c, 0xd4cc2289, 0xe23eb27a, + 0x62e340a3, 0x5411d050, 0x0f066145, 0x39f4f1b6, 0xd5cc82b6, + 0xe33e1245, 0xb829a350, 0x8edb33a3, 0x0e06c17a, 0x38f45189, + 0x63e3e09c, 0x5511706f, 0x60e200dd, 0x5610902e, 0x0d07213b, + 0x3bf5b1c8, 0xbb284311, 0x8ddad3e2, 0xd6cd62f7, 0xe03ff204, + 0x0c078104, 0x3af511f7, 0x61e2a0e2, 0x57103011, 0xd7cdc2c8, + 0xe13f523b, 0xba28e32e, 0x8cda73dd, 0x78ed02d5, 0x4e1f9226, + 0x15082333, 0x23fab3c0, 0xa3274119, 0x95d5d1ea, 0xcec260ff, + 0xf830f00c, 0x1408830c, 0x22fa13ff, 0x79eda2ea, 0x4f1f3219, + 0xcfc2c0c0, 0xf9305033, 0xa227e126, 0x94d571d5, 0xa1260167, + 0x97d49194, 0xccc32081, 0xfa31b072, 0x7aec42ab, 0x4c1ed258, + 0x1709634d, 0x21fbf3be, 0xcdc380be, 0xfb31104d, 0xa026a158, + 0x96d431ab, 0x1609c372, 0x20fb5381, 0x7bece294, 0x4d1e7267, + 0x100a03f0, 0x26f89303, 0x7def2216, 0x4b1db2e5, 0xcbc0403c, + 0xfd32d0cf, 0xa62561da, 0x90d7f129, 0x7cef8229, 0x4a1d12da, + 0x110aa3cf, 0x27f8333c, 0xa725c1e5, 0x91d75116, 0xcac0e003, + 0xfc3270f0, 0xc9c10042, 0xff3390b1, 0xa42421a4, 0x92d6b157, + 0x120b438e, 0x24f9d37d, 0x7fee6268, 0x491cf29b, 0xa524819b, + 0x93d61168, 0xc8c1a07d, 0xfe33308e, 0x7eeec257, 0x481c52a4, + 0x130be3b1, 0x25f97342, 0xa923009f, 0x9fd1906c, 0xc4c62179, + 0xf234b18a, 0x72e94353, 0x441bd3a0, 0x1f0c62b5, 0x29fef246, + 0xc5c68146, 0xf33411b5, 0xa823a0a0, 0x9ed13053, 0x1e0cc28a, + 0x28fe5279, 0x73e9e36c, 0x451b739f, 0x70e8032d, 0x461a93de, + 0x1d0d22cb, 0x2bffb238, 0xab2240e1, 0x9dd0d012, 0xc6c76107, + 0xf035f1f4, 0x1c0d82f4, 0x2aff1207, 0x71e8a312, 0x471a33e1, + 0xc7c7c138, 0xf13551cb, 0xaa22e0de, 0x9cd0702d, 0xc1c401ba, + 0xf7369149, 0xac21205c, 0x9ad3b0af, 0x1a0e4276, 0x2cfcd285, + 0x77eb6390, 0x4119f363, 0xad218063, 0x9bd31090, 0xc0c4a185, + 0xf6363176, 0x76ebc3af, 0x4019535c, 0x1b0ee249, 0x2dfc72ba, + 0x180f0208, 0x2efd92fb, 0x75ea23ee, 0x4318b31d, 0xc3c541c4, + 0xf537d137, 0xae206022, 0x98d2f0d1, 0x74ea83d1, 0x42181322, + 0x190fa237, 0x2ffd32c4, 0xaf20c01d, 0x99d250ee, 0xc2c5e1fb, + 0xf4377108}}; + +local const z_word_t FAR crc_braid_big_table[][256] = { + {0x0000000000000000, 0xf390f23600000000, 0xe621e56d00000000, + 0x15b1175b00000000, 0xcc43cadb00000000, 0x3fd338ed00000000, + 0x2a622fb600000000, 0xd9f2dd8000000000, 0xd981e56c00000000, + 0x2a11175a00000000, 0x3fa0000100000000, 0xcc30f23700000000, + 0x15c22fb700000000, 0xe652dd8100000000, 0xf3e3cada00000000, + 0x007338ec00000000, 0xb203cbd900000000, 0x419339ef00000000, + 0x54222eb400000000, 0xa7b2dc8200000000, 0x7e40010200000000, + 0x8dd0f33400000000, 0x9861e46f00000000, 0x6bf1165900000000, + 0x6b822eb500000000, 0x9812dc8300000000, 0x8da3cbd800000000, + 0x7e3339ee00000000, 0xa7c1e46e00000000, 0x5451165800000000, + 0x41e0010300000000, 0xb270f33500000000, 0x2501e76800000000, + 0xd691155e00000000, 0xc320020500000000, 0x30b0f03300000000, + 0xe9422db300000000, 0x1ad2df8500000000, 0x0f63c8de00000000, + 0xfcf33ae800000000, 0xfc80020400000000, 0x0f10f03200000000, + 0x1aa1e76900000000, 0xe931155f00000000, 0x30c3c8df00000000, + 0xc3533ae900000000, 0xd6e22db200000000, 0x2572df8400000000, + 0x97022cb100000000, 0x6492de8700000000, 0x7123c9dc00000000, + 0x82b33bea00000000, 0x5b41e66a00000000, 0xa8d1145c00000000, + 0xbd60030700000000, 0x4ef0f13100000000, 0x4e83c9dd00000000, + 0xbd133beb00000000, 0xa8a22cb000000000, 0x5b32de8600000000, + 0x82c0030600000000, 0x7150f13000000000, 0x64e1e66b00000000, + 0x9771145d00000000, 0x4a02ced100000000, 0xb9923ce700000000, + 0xac232bbc00000000, 0x5fb3d98a00000000, 0x8641040a00000000, + 0x75d1f63c00000000, 0x6060e16700000000, 0x93f0135100000000, + 0x93832bbd00000000, 0x6013d98b00000000, 0x75a2ced000000000, + 0x86323ce600000000, 0x5fc0e16600000000, 0xac50135000000000, + 0xb9e1040b00000000, 0x4a71f63d00000000, 0xf801050800000000, + 0x0b91f73e00000000, 0x1e20e06500000000, 0xedb0125300000000, + 0x3442cfd300000000, 0xc7d23de500000000, 0xd2632abe00000000, + 0x21f3d88800000000, 0x2180e06400000000, 0xd210125200000000, + 0xc7a1050900000000, 0x3431f73f00000000, 0xedc32abf00000000, + 0x1e53d88900000000, 0x0be2cfd200000000, 0xf8723de400000000, + 0x6f0329b900000000, 0x9c93db8f00000000, 0x8922ccd400000000, + 0x7ab23ee200000000, 0xa340e36200000000, 0x50d0115400000000, + 0x4561060f00000000, 0xb6f1f43900000000, 0xb682ccd500000000, + 0x45123ee300000000, 0x50a329b800000000, 0xa333db8e00000000, + 0x7ac1060e00000000, 0x8951f43800000000, 0x9ce0e36300000000, + 0x6f70115500000000, 0xdd00e26000000000, 0x2e90105600000000, + 0x3b21070d00000000, 0xc8b1f53b00000000, 0x114328bb00000000, + 0xe2d3da8d00000000, 0xf762cdd600000000, 0x04f23fe000000000, + 0x0481070c00000000, 0xf711f53a00000000, 0xe2a0e26100000000, + 0x1130105700000000, 0xc8c2cdd700000000, 0x3b523fe100000000, + 0x2ee328ba00000000, 0xdd73da8c00000000, 0xd502ed7800000000, + 0x26921f4e00000000, 0x3323081500000000, 0xc0b3fa2300000000, + 0x194127a300000000, 0xead1d59500000000, 0xff60c2ce00000000, + 0x0cf030f800000000, 0x0c83081400000000, 0xff13fa2200000000, + 0xeaa2ed7900000000, 0x19321f4f00000000, 0xc0c0c2cf00000000, + 0x335030f900000000, 0x26e127a200000000, 0xd571d59400000000, + 0x670126a100000000, 0x9491d49700000000, 0x8120c3cc00000000, + 0x72b031fa00000000, 0xab42ec7a00000000, 0x58d21e4c00000000, + 0x4d63091700000000, 0xbef3fb2100000000, 0xbe80c3cd00000000, + 0x4d1031fb00000000, 0x58a126a000000000, 0xab31d49600000000, + 0x72c3091600000000, 0x8153fb2000000000, 0x94e2ec7b00000000, + 0x67721e4d00000000, 0xf0030a1000000000, 0x0393f82600000000, + 0x1622ef7d00000000, 0xe5b21d4b00000000, 0x3c40c0cb00000000, + 0xcfd032fd00000000, 0xda6125a600000000, 0x29f1d79000000000, + 0x2982ef7c00000000, 0xda121d4a00000000, 0xcfa30a1100000000, + 0x3c33f82700000000, 0xe5c125a700000000, 0x1651d79100000000, + 0x03e0c0ca00000000, 0xf07032fc00000000, 0x4200c1c900000000, + 0xb19033ff00000000, 0xa42124a400000000, 0x57b1d69200000000, + 0x8e430b1200000000, 0x7dd3f92400000000, 0x6862ee7f00000000, + 0x9bf21c4900000000, 0x9b8124a500000000, 0x6811d69300000000, + 0x7da0c1c800000000, 0x8e3033fe00000000, 0x57c2ee7e00000000, + 0xa4521c4800000000, 0xb1e30b1300000000, 0x4273f92500000000, + 0x9f0023a900000000, 0x6c90d19f00000000, 0x7921c6c400000000, + 0x8ab134f200000000, 0x5343e97200000000, 0xa0d31b4400000000, + 0xb5620c1f00000000, 0x46f2fe2900000000, 0x4681c6c500000000, + 0xb51134f300000000, 0xa0a023a800000000, 0x5330d19e00000000, + 0x8ac20c1e00000000, 0x7952fe2800000000, 0x6ce3e97300000000, + 0x9f731b4500000000, 0x2d03e87000000000, 0xde931a4600000000, + 0xcb220d1d00000000, 0x38b2ff2b00000000, 0xe14022ab00000000, + 0x12d0d09d00000000, 0x0761c7c600000000, 0xf4f135f000000000, + 0xf4820d1c00000000, 0x0712ff2a00000000, 0x12a3e87100000000, + 0xe1331a4700000000, 0x38c1c7c700000000, 0xcb5135f100000000, + 0xdee022aa00000000, 0x2d70d09c00000000, 0xba01c4c100000000, + 0x499136f700000000, 0x5c2021ac00000000, 0xafb0d39a00000000, + 0x76420e1a00000000, 0x85d2fc2c00000000, 0x9063eb7700000000, + 0x63f3194100000000, 0x638021ad00000000, 0x9010d39b00000000, + 0x85a1c4c000000000, 0x763136f600000000, 0xafc3eb7600000000, + 0x5c53194000000000, 0x49e20e1b00000000, 0xba72fc2d00000000, + 0x08020f1800000000, 0xfb92fd2e00000000, 0xee23ea7500000000, + 0x1db3184300000000, 0xc441c5c300000000, 0x37d137f500000000, + 0x226020ae00000000, 0xd1f0d29800000000, 0xd183ea7400000000, + 0x2213184200000000, 0x37a20f1900000000, 0xc432fd2f00000000, + 0x1dc020af00000000, 0xee50d29900000000, 0xfbe1c5c200000000, + 0x087137f400000000}, + {0x0000000000000000, 0x3651822400000000, 0x6ca2044900000000, + 0x5af3866d00000000, 0xd844099200000000, 0xee158bb600000000, + 0xb4e60ddb00000000, 0x82b78fff00000000, 0xf18f63ff00000000, + 0xc7dee1db00000000, 0x9d2d67b600000000, 0xab7ce59200000000, + 0x29cb6a6d00000000, 0x1f9ae84900000000, 0x45696e2400000000, + 0x7338ec0000000000, 0xa319b62500000000, 0x9548340100000000, + 0xcfbbb26c00000000, 0xf9ea304800000000, 0x7b5dbfb700000000, + 0x4d0c3d9300000000, 0x17ffbbfe00000000, 0x21ae39da00000000, + 0x5296d5da00000000, 0x64c757fe00000000, 0x3e34d19300000000, + 0x086553b700000000, 0x8ad2dc4800000000, 0xbc835e6c00000000, + 0xe670d80100000000, 0xd0215a2500000000, 0x46336c4b00000000, + 0x7062ee6f00000000, 0x2a91680200000000, 0x1cc0ea2600000000, + 0x9e7765d900000000, 0xa826e7fd00000000, 0xf2d5619000000000, + 0xc484e3b400000000, 0xb7bc0fb400000000, 0x81ed8d9000000000, + 0xdb1e0bfd00000000, 0xed4f89d900000000, 0x6ff8062600000000, + 0x59a9840200000000, 0x035a026f00000000, 0x350b804b00000000, + 0xe52ada6e00000000, 0xd37b584a00000000, 0x8988de2700000000, + 0xbfd95c0300000000, 0x3d6ed3fc00000000, 0x0b3f51d800000000, + 0x51ccd7b500000000, 0x679d559100000000, 0x14a5b99100000000, + 0x22f43bb500000000, 0x7807bdd800000000, 0x4e563ffc00000000, + 0xcce1b00300000000, 0xfab0322700000000, 0xa043b44a00000000, + 0x9612366e00000000, 0x8c66d89600000000, 0xba375ab200000000, + 0xe0c4dcdf00000000, 0xd6955efb00000000, 0x5422d10400000000, + 0x6273532000000000, 0x3880d54d00000000, 0x0ed1576900000000, + 0x7de9bb6900000000, 0x4bb8394d00000000, 0x114bbf2000000000, + 0x271a3d0400000000, 0xa5adb2fb00000000, 0x93fc30df00000000, + 0xc90fb6b200000000, 0xff5e349600000000, 0x2f7f6eb300000000, + 0x192eec9700000000, 0x43dd6afa00000000, 0x758ce8de00000000, + 0xf73b672100000000, 0xc16ae50500000000, 0x9b99636800000000, + 0xadc8e14c00000000, 0xdef00d4c00000000, 0xe8a18f6800000000, + 0xb252090500000000, 0x84038b2100000000, 0x06b404de00000000, + 0x30e586fa00000000, 0x6a16009700000000, 0x5c4782b300000000, + 0xca55b4dd00000000, 0xfc0436f900000000, 0xa6f7b09400000000, + 0x90a632b000000000, 0x1211bd4f00000000, 0x24403f6b00000000, + 0x7eb3b90600000000, 0x48e23b2200000000, 0x3bdad72200000000, + 0x0d8b550600000000, 0x5778d36b00000000, 0x6129514f00000000, + 0xe39edeb000000000, 0xd5cf5c9400000000, 0x8f3cdaf900000000, + 0xb96d58dd00000000, 0x694c02f800000000, 0x5f1d80dc00000000, + 0x05ee06b100000000, 0x33bf849500000000, 0xb1080b6a00000000, + 0x8759894e00000000, 0xddaa0f2300000000, 0xebfb8d0700000000, + 0x98c3610700000000, 0xae92e32300000000, 0xf461654e00000000, + 0xc230e76a00000000, 0x4087689500000000, 0x76d6eab100000000, + 0x2c256cdc00000000, 0x1a74eef800000000, 0x59cbc1f600000000, + 0x6f9a43d200000000, 0x3569c5bf00000000, 0x0338479b00000000, + 0x818fc86400000000, 0xb7de4a4000000000, 0xed2dcc2d00000000, + 0xdb7c4e0900000000, 0xa844a20900000000, 0x9e15202d00000000, + 0xc4e6a64000000000, 0xf2b7246400000000, 0x7000ab9b00000000, + 0x465129bf00000000, 0x1ca2afd200000000, 0x2af32df600000000, + 0xfad277d300000000, 0xcc83f5f700000000, 0x9670739a00000000, + 0xa021f1be00000000, 0x22967e4100000000, 0x14c7fc6500000000, + 0x4e347a0800000000, 0x7865f82c00000000, 0x0b5d142c00000000, + 0x3d0c960800000000, 0x67ff106500000000, 0x51ae924100000000, + 0xd3191dbe00000000, 0xe5489f9a00000000, 0xbfbb19f700000000, + 0x89ea9bd300000000, 0x1ff8adbd00000000, 0x29a92f9900000000, + 0x735aa9f400000000, 0x450b2bd000000000, 0xc7bca42f00000000, + 0xf1ed260b00000000, 0xab1ea06600000000, 0x9d4f224200000000, + 0xee77ce4200000000, 0xd8264c6600000000, 0x82d5ca0b00000000, + 0xb484482f00000000, 0x3633c7d000000000, 0x006245f400000000, + 0x5a91c39900000000, 0x6cc041bd00000000, 0xbce11b9800000000, + 0x8ab099bc00000000, 0xd0431fd100000000, 0xe6129df500000000, + 0x64a5120a00000000, 0x52f4902e00000000, 0x0807164300000000, + 0x3e56946700000000, 0x4d6e786700000000, 0x7b3ffa4300000000, + 0x21cc7c2e00000000, 0x179dfe0a00000000, 0x952a71f500000000, + 0xa37bf3d100000000, 0xf98875bc00000000, 0xcfd9f79800000000, + 0xd5ad196000000000, 0xe3fc9b4400000000, 0xb90f1d2900000000, + 0x8f5e9f0d00000000, 0x0de910f200000000, 0x3bb892d600000000, + 0x614b14bb00000000, 0x571a969f00000000, 0x24227a9f00000000, + 0x1273f8bb00000000, 0x48807ed600000000, 0x7ed1fcf200000000, + 0xfc66730d00000000, 0xca37f12900000000, 0x90c4774400000000, + 0xa695f56000000000, 0x76b4af4500000000, 0x40e52d6100000000, + 0x1a16ab0c00000000, 0x2c47292800000000, 0xaef0a6d700000000, + 0x98a124f300000000, 0xc252a29e00000000, 0xf40320ba00000000, + 0x873bccba00000000, 0xb16a4e9e00000000, 0xeb99c8f300000000, + 0xddc84ad700000000, 0x5f7fc52800000000, 0x692e470c00000000, + 0x33ddc16100000000, 0x058c434500000000, 0x939e752b00000000, + 0xa5cff70f00000000, 0xff3c716200000000, 0xc96df34600000000, + 0x4bda7cb900000000, 0x7d8bfe9d00000000, 0x277878f000000000, + 0x1129fad400000000, 0x621116d400000000, 0x544094f000000000, + 0x0eb3129d00000000, 0x38e290b900000000, 0xba551f4600000000, + 0x8c049d6200000000, 0xd6f71b0f00000000, 0xe0a6992b00000000, + 0x3087c30e00000000, 0x06d6412a00000000, 0x5c25c74700000000, + 0x6a74456300000000, 0xe8c3ca9c00000000, 0xde9248b800000000, + 0x8461ced500000000, 0xb2304cf100000000, 0xc108a0f100000000, + 0xf75922d500000000, 0xadaaa4b800000000, 0x9bfb269c00000000, + 0x194ca96300000000, 0x2f1d2b4700000000, 0x75eead2a00000000, + 0x43bf2f0e00000000}, + {0x0000000000000000, 0xc8179ecf00000000, 0xd1294d4400000000, + 0x193ed38b00000000, 0xa2539a8800000000, 0x6a44044700000000, + 0x737ad7cc00000000, 0xbb6d490300000000, 0x05a145ca00000000, + 0xcdb6db0500000000, 0xd488088e00000000, 0x1c9f964100000000, + 0xa7f2df4200000000, 0x6fe5418d00000000, 0x76db920600000000, + 0xbecc0cc900000000, 0x4b44fa4f00000000, 0x8353648000000000, + 0x9a6db70b00000000, 0x527a29c400000000, 0xe91760c700000000, + 0x2100fe0800000000, 0x383e2d8300000000, 0xf029b34c00000000, + 0x4ee5bf8500000000, 0x86f2214a00000000, 0x9fccf2c100000000, + 0x57db6c0e00000000, 0xecb6250d00000000, 0x24a1bbc200000000, + 0x3d9f684900000000, 0xf588f68600000000, 0x9688f49f00000000, + 0x5e9f6a5000000000, 0x47a1b9db00000000, 0x8fb6271400000000, + 0x34db6e1700000000, 0xfcccf0d800000000, 0xe5f2235300000000, + 0x2de5bd9c00000000, 0x9329b15500000000, 0x5b3e2f9a00000000, + 0x4200fc1100000000, 0x8a1762de00000000, 0x317a2bdd00000000, + 0xf96db51200000000, 0xe053669900000000, 0x2844f85600000000, + 0xddcc0ed000000000, 0x15db901f00000000, 0x0ce5439400000000, + 0xc4f2dd5b00000000, 0x7f9f945800000000, 0xb7880a9700000000, + 0xaeb6d91c00000000, 0x66a147d300000000, 0xd86d4b1a00000000, + 0x107ad5d500000000, 0x0944065e00000000, 0xc153989100000000, + 0x7a3ed19200000000, 0xb2294f5d00000000, 0xab179cd600000000, + 0x6300021900000000, 0x6d1798e400000000, 0xa500062b00000000, + 0xbc3ed5a000000000, 0x74294b6f00000000, 0xcf44026c00000000, + 0x07539ca300000000, 0x1e6d4f2800000000, 0xd67ad1e700000000, + 0x68b6dd2e00000000, 0xa0a143e100000000, 0xb99f906a00000000, + 0x71880ea500000000, 0xcae547a600000000, 0x02f2d96900000000, + 0x1bcc0ae200000000, 0xd3db942d00000000, 0x265362ab00000000, + 0xee44fc6400000000, 0xf77a2fef00000000, 0x3f6db12000000000, + 0x8400f82300000000, 0x4c1766ec00000000, 0x5529b56700000000, + 0x9d3e2ba800000000, 0x23f2276100000000, 0xebe5b9ae00000000, + 0xf2db6a2500000000, 0x3accf4ea00000000, 0x81a1bde900000000, + 0x49b6232600000000, 0x5088f0ad00000000, 0x989f6e6200000000, + 0xfb9f6c7b00000000, 0x3388f2b400000000, 0x2ab6213f00000000, + 0xe2a1bff000000000, 0x59ccf6f300000000, 0x91db683c00000000, + 0x88e5bbb700000000, 0x40f2257800000000, 0xfe3e29b100000000, + 0x3629b77e00000000, 0x2f1764f500000000, 0xe700fa3a00000000, + 0x5c6db33900000000, 0x947a2df600000000, 0x8d44fe7d00000000, + 0x455360b200000000, 0xb0db963400000000, 0x78cc08fb00000000, + 0x61f2db7000000000, 0xa9e545bf00000000, 0x12880cbc00000000, + 0xda9f927300000000, 0xc3a141f800000000, 0x0bb6df3700000000, + 0xb57ad3fe00000000, 0x7d6d4d3100000000, 0x64539eba00000000, + 0xac44007500000000, 0x1729497600000000, 0xdf3ed7b900000000, + 0xc600043200000000, 0x0e179afd00000000, 0x9b28411200000000, + 0x533fdfdd00000000, 0x4a010c5600000000, 0x8216929900000000, + 0x397bdb9a00000000, 0xf16c455500000000, 0xe85296de00000000, + 0x2045081100000000, 0x9e8904d800000000, 0x569e9a1700000000, + 0x4fa0499c00000000, 0x87b7d75300000000, 0x3cda9e5000000000, + 0xf4cd009f00000000, 0xedf3d31400000000, 0x25e44ddb00000000, + 0xd06cbb5d00000000, 0x187b259200000000, 0x0145f61900000000, + 0xc95268d600000000, 0x723f21d500000000, 0xba28bf1a00000000, + 0xa3166c9100000000, 0x6b01f25e00000000, 0xd5cdfe9700000000, + 0x1dda605800000000, 0x04e4b3d300000000, 0xccf32d1c00000000, + 0x779e641f00000000, 0xbf89fad000000000, 0xa6b7295b00000000, + 0x6ea0b79400000000, 0x0da0b58d00000000, 0xc5b72b4200000000, + 0xdc89f8c900000000, 0x149e660600000000, 0xaff32f0500000000, + 0x67e4b1ca00000000, 0x7eda624100000000, 0xb6cdfc8e00000000, + 0x0801f04700000000, 0xc0166e8800000000, 0xd928bd0300000000, + 0x113f23cc00000000, 0xaa526acf00000000, 0x6245f40000000000, + 0x7b7b278b00000000, 0xb36cb94400000000, 0x46e44fc200000000, + 0x8ef3d10d00000000, 0x97cd028600000000, 0x5fda9c4900000000, + 0xe4b7d54a00000000, 0x2ca04b8500000000, 0x359e980e00000000, + 0xfd8906c100000000, 0x43450a0800000000, 0x8b5294c700000000, + 0x926c474c00000000, 0x5a7bd98300000000, 0xe116908000000000, + 0x29010e4f00000000, 0x303fddc400000000, 0xf828430b00000000, + 0xf63fd9f600000000, 0x3e28473900000000, 0x271694b200000000, + 0xef010a7d00000000, 0x546c437e00000000, 0x9c7bddb100000000, + 0x85450e3a00000000, 0x4d5290f500000000, 0xf39e9c3c00000000, + 0x3b8902f300000000, 0x22b7d17800000000, 0xeaa04fb700000000, + 0x51cd06b400000000, 0x99da987b00000000, 0x80e44bf000000000, + 0x48f3d53f00000000, 0xbd7b23b900000000, 0x756cbd7600000000, + 0x6c526efd00000000, 0xa445f03200000000, 0x1f28b93100000000, + 0xd73f27fe00000000, 0xce01f47500000000, 0x06166aba00000000, + 0xb8da667300000000, 0x70cdf8bc00000000, 0x69f32b3700000000, + 0xa1e4b5f800000000, 0x1a89fcfb00000000, 0xd29e623400000000, + 0xcba0b1bf00000000, 0x03b72f7000000000, 0x60b72d6900000000, + 0xa8a0b3a600000000, 0xb19e602d00000000, 0x7989fee200000000, + 0xc2e4b7e100000000, 0x0af3292e00000000, 0x13cdfaa500000000, + 0xdbda646a00000000, 0x651668a300000000, 0xad01f66c00000000, + 0xb43f25e700000000, 0x7c28bb2800000000, 0xc745f22b00000000, + 0x0f526ce400000000, 0x166cbf6f00000000, 0xde7b21a000000000, + 0x2bf3d72600000000, 0xe3e449e900000000, 0xfada9a6200000000, + 0x32cd04ad00000000, 0x89a04dae00000000, 0x41b7d36100000000, + 0x588900ea00000000, 0x909e9e2500000000, 0x2e5292ec00000000, + 0xe6450c2300000000, 0xff7bdfa800000000, 0x376c416700000000, + 0x8c01086400000000, 0x441696ab00000000, 0x5d28452000000000, + 0x953fdbef00000000}, + {0x0000000000000000, 0x95d4709500000000, 0x6baf90f100000000, + 0xfe7be06400000000, 0x9758503800000000, 0x028c20ad00000000, + 0xfcf7c0c900000000, 0x6923b05c00000000, 0x2eb1a07000000000, + 0xbb65d0e500000000, 0x451e308100000000, 0xd0ca401400000000, + 0xb9e9f04800000000, 0x2c3d80dd00000000, 0xd24660b900000000, + 0x4792102c00000000, 0x5c6241e100000000, 0xc9b6317400000000, + 0x37cdd11000000000, 0xa219a18500000000, 0xcb3a11d900000000, + 0x5eee614c00000000, 0xa095812800000000, 0x3541f1bd00000000, + 0x72d3e19100000000, 0xe707910400000000, 0x197c716000000000, + 0x8ca801f500000000, 0xe58bb1a900000000, 0x705fc13c00000000, + 0x8e24215800000000, 0x1bf051cd00000000, 0xf9c2f31900000000, + 0x6c16838c00000000, 0x926d63e800000000, 0x07b9137d00000000, + 0x6e9aa32100000000, 0xfb4ed3b400000000, 0x053533d000000000, + 0x90e1434500000000, 0xd773536900000000, 0x42a723fc00000000, + 0xbcdcc39800000000, 0x2908b30d00000000, 0x402b035100000000, + 0xd5ff73c400000000, 0x2b8493a000000000, 0xbe50e33500000000, + 0xa5a0b2f800000000, 0x3074c26d00000000, 0xce0f220900000000, + 0x5bdb529c00000000, 0x32f8e2c000000000, 0xa72c925500000000, + 0x5957723100000000, 0xcc8302a400000000, 0x8b11128800000000, + 0x1ec5621d00000000, 0xe0be827900000000, 0x756af2ec00000000, + 0x1c4942b000000000, 0x899d322500000000, 0x77e6d24100000000, + 0xe232a2d400000000, 0xf285e73300000000, 0x675197a600000000, + 0x992a77c200000000, 0x0cfe075700000000, 0x65ddb70b00000000, + 0xf009c79e00000000, 0x0e7227fa00000000, 0x9ba6576f00000000, + 0xdc34474300000000, 0x49e037d600000000, 0xb79bd7b200000000, + 0x224fa72700000000, 0x4b6c177b00000000, 0xdeb867ee00000000, + 0x20c3878a00000000, 0xb517f71f00000000, 0xaee7a6d200000000, + 0x3b33d64700000000, 0xc548362300000000, 0x509c46b600000000, + 0x39bff6ea00000000, 0xac6b867f00000000, 0x5210661b00000000, + 0xc7c4168e00000000, 0x805606a200000000, 0x1582763700000000, + 0xebf9965300000000, 0x7e2de6c600000000, 0x170e569a00000000, + 0x82da260f00000000, 0x7ca1c66b00000000, 0xe975b6fe00000000, + 0x0b47142a00000000, 0x9e9364bf00000000, 0x60e884db00000000, + 0xf53cf44e00000000, 0x9c1f441200000000, 0x09cb348700000000, + 0xf7b0d4e300000000, 0x6264a47600000000, 0x25f6b45a00000000, + 0xb022c4cf00000000, 0x4e5924ab00000000, 0xdb8d543e00000000, + 0xb2aee46200000000, 0x277a94f700000000, 0xd901749300000000, + 0x4cd5040600000000, 0x572555cb00000000, 0xc2f1255e00000000, + 0x3c8ac53a00000000, 0xa95eb5af00000000, 0xc07d05f300000000, + 0x55a9756600000000, 0xabd2950200000000, 0x3e06e59700000000, + 0x7994f5bb00000000, 0xec40852e00000000, 0x123b654a00000000, + 0x87ef15df00000000, 0xeecca58300000000, 0x7b18d51600000000, + 0x8563357200000000, 0x10b745e700000000, 0xe40bcf6700000000, + 0x71dfbff200000000, 0x8fa45f9600000000, 0x1a702f0300000000, + 0x73539f5f00000000, 0xe687efca00000000, 0x18fc0fae00000000, + 0x8d287f3b00000000, 0xcaba6f1700000000, 0x5f6e1f8200000000, + 0xa115ffe600000000, 0x34c18f7300000000, 0x5de23f2f00000000, + 0xc8364fba00000000, 0x364dafde00000000, 0xa399df4b00000000, + 0xb8698e8600000000, 0x2dbdfe1300000000, 0xd3c61e7700000000, + 0x46126ee200000000, 0x2f31debe00000000, 0xbae5ae2b00000000, + 0x449e4e4f00000000, 0xd14a3eda00000000, 0x96d82ef600000000, + 0x030c5e6300000000, 0xfd77be0700000000, 0x68a3ce9200000000, + 0x01807ece00000000, 0x94540e5b00000000, 0x6a2fee3f00000000, + 0xfffb9eaa00000000, 0x1dc93c7e00000000, 0x881d4ceb00000000, + 0x7666ac8f00000000, 0xe3b2dc1a00000000, 0x8a916c4600000000, + 0x1f451cd300000000, 0xe13efcb700000000, 0x74ea8c2200000000, + 0x33789c0e00000000, 0xa6acec9b00000000, 0x58d70cff00000000, + 0xcd037c6a00000000, 0xa420cc3600000000, 0x31f4bca300000000, + 0xcf8f5cc700000000, 0x5a5b2c5200000000, 0x41ab7d9f00000000, + 0xd47f0d0a00000000, 0x2a04ed6e00000000, 0xbfd09dfb00000000, + 0xd6f32da700000000, 0x43275d3200000000, 0xbd5cbd5600000000, + 0x2888cdc300000000, 0x6f1addef00000000, 0xfacead7a00000000, + 0x04b54d1e00000000, 0x91613d8b00000000, 0xf8428dd700000000, + 0x6d96fd4200000000, 0x93ed1d2600000000, 0x06396db300000000, + 0x168e285400000000, 0x835a58c100000000, 0x7d21b8a500000000, + 0xe8f5c83000000000, 0x81d6786c00000000, 0x140208f900000000, + 0xea79e89d00000000, 0x7fad980800000000, 0x383f882400000000, + 0xadebf8b100000000, 0x539018d500000000, 0xc644684000000000, + 0xaf67d81c00000000, 0x3ab3a88900000000, 0xc4c848ed00000000, + 0x511c387800000000, 0x4aec69b500000000, 0xdf38192000000000, + 0x2143f94400000000, 0xb49789d100000000, 0xddb4398d00000000, + 0x4860491800000000, 0xb61ba97c00000000, 0x23cfd9e900000000, + 0x645dc9c500000000, 0xf189b95000000000, 0x0ff2593400000000, + 0x9a2629a100000000, 0xf30599fd00000000, 0x66d1e96800000000, + 0x98aa090c00000000, 0x0d7e799900000000, 0xef4cdb4d00000000, + 0x7a98abd800000000, 0x84e34bbc00000000, 0x11373b2900000000, + 0x78148b7500000000, 0xedc0fbe000000000, 0x13bb1b8400000000, + 0x866f6b1100000000, 0xc1fd7b3d00000000, 0x54290ba800000000, + 0xaa52ebcc00000000, 0x3f869b5900000000, 0x56a52b0500000000, + 0xc3715b9000000000, 0x3d0abbf400000000, 0xa8decb6100000000, + 0xb32e9aac00000000, 0x26faea3900000000, 0xd8810a5d00000000, + 0x4d557ac800000000, 0x2476ca9400000000, 0xb1a2ba0100000000, + 0x4fd95a6500000000, 0xda0d2af000000000, 0x9d9f3adc00000000, + 0x084b4a4900000000, 0xf630aa2d00000000, 0x63e4dab800000000, + 0x0ac76ae400000000, 0x9f131a7100000000, 0x6168fa1500000000, + 0xf4bc8a8000000000}, + {0x0000000000000000, 0x1f17f08000000000, 0x7f2891da00000000, + 0x603f615a00000000, 0xbf56536e00000000, 0xa041a3ee00000000, + 0xc07ec2b400000000, 0xdf69323400000000, 0x7eada6dc00000000, + 0x61ba565c00000000, 0x0185370600000000, 0x1e92c78600000000, + 0xc1fbf5b200000000, 0xdeec053200000000, 0xbed3646800000000, + 0xa1c494e800000000, 0xbd5c3c6200000000, 0xa24bcce200000000, + 0xc274adb800000000, 0xdd635d3800000000, 0x020a6f0c00000000, + 0x1d1d9f8c00000000, 0x7d22fed600000000, 0x62350e5600000000, + 0xc3f19abe00000000, 0xdce66a3e00000000, 0xbcd90b6400000000, + 0xa3cefbe400000000, 0x7ca7c9d000000000, 0x63b0395000000000, + 0x038f580a00000000, 0x1c98a88a00000000, 0x7ab978c400000000, + 0x65ae884400000000, 0x0591e91e00000000, 0x1a86199e00000000, + 0xc5ef2baa00000000, 0xdaf8db2a00000000, 0xbac7ba7000000000, + 0xa5d04af000000000, 0x0414de1800000000, 0x1b032e9800000000, + 0x7b3c4fc200000000, 0x642bbf4200000000, 0xbb428d7600000000, + 0xa4557df600000000, 0xc46a1cac00000000, 0xdb7dec2c00000000, + 0xc7e544a600000000, 0xd8f2b42600000000, 0xb8cdd57c00000000, + 0xa7da25fc00000000, 0x78b317c800000000, 0x67a4e74800000000, + 0x079b861200000000, 0x188c769200000000, 0xb948e27a00000000, + 0xa65f12fa00000000, 0xc66073a000000000, 0xd977832000000000, + 0x061eb11400000000, 0x1909419400000000, 0x793620ce00000000, + 0x6621d04e00000000, 0xb574805300000000, 0xaa6370d300000000, + 0xca5c118900000000, 0xd54be10900000000, 0x0a22d33d00000000, + 0x153523bd00000000, 0x750a42e700000000, 0x6a1db26700000000, + 0xcbd9268f00000000, 0xd4ced60f00000000, 0xb4f1b75500000000, + 0xabe647d500000000, 0x748f75e100000000, 0x6b98856100000000, + 0x0ba7e43b00000000, 0x14b014bb00000000, 0x0828bc3100000000, + 0x173f4cb100000000, 0x77002deb00000000, 0x6817dd6b00000000, + 0xb77eef5f00000000, 0xa8691fdf00000000, 0xc8567e8500000000, + 0xd7418e0500000000, 0x76851aed00000000, 0x6992ea6d00000000, + 0x09ad8b3700000000, 0x16ba7bb700000000, 0xc9d3498300000000, + 0xd6c4b90300000000, 0xb6fbd85900000000, 0xa9ec28d900000000, + 0xcfcdf89700000000, 0xd0da081700000000, 0xb0e5694d00000000, + 0xaff299cd00000000, 0x709babf900000000, 0x6f8c5b7900000000, + 0x0fb33a2300000000, 0x10a4caa300000000, 0xb1605e4b00000000, + 0xae77aecb00000000, 0xce48cf9100000000, 0xd15f3f1100000000, + 0x0e360d2500000000, 0x1121fda500000000, 0x711e9cff00000000, + 0x6e096c7f00000000, 0x7291c4f500000000, 0x6d86347500000000, + 0x0db9552f00000000, 0x12aea5af00000000, 0xcdc7979b00000000, + 0xd2d0671b00000000, 0xb2ef064100000000, 0xadf8f6c100000000, + 0x0c3c622900000000, 0x132b92a900000000, 0x7314f3f300000000, + 0x6c03037300000000, 0xb36a314700000000, 0xac7dc1c700000000, + 0xcc42a09d00000000, 0xd355501d00000000, 0x6ae900a700000000, + 0x75fef02700000000, 0x15c1917d00000000, 0x0ad661fd00000000, + 0xd5bf53c900000000, 0xcaa8a34900000000, 0xaa97c21300000000, + 0xb580329300000000, 0x1444a67b00000000, 0x0b5356fb00000000, + 0x6b6c37a100000000, 0x747bc72100000000, 0xab12f51500000000, + 0xb405059500000000, 0xd43a64cf00000000, 0xcb2d944f00000000, + 0xd7b53cc500000000, 0xc8a2cc4500000000, 0xa89dad1f00000000, + 0xb78a5d9f00000000, 0x68e36fab00000000, 0x77f49f2b00000000, + 0x17cbfe7100000000, 0x08dc0ef100000000, 0xa9189a1900000000, + 0xb60f6a9900000000, 0xd6300bc300000000, 0xc927fb4300000000, + 0x164ec97700000000, 0x095939f700000000, 0x696658ad00000000, + 0x7671a82d00000000, 0x1050786300000000, 0x0f4788e300000000, + 0x6f78e9b900000000, 0x706f193900000000, 0xaf062b0d00000000, + 0xb011db8d00000000, 0xd02ebad700000000, 0xcf394a5700000000, + 0x6efddebf00000000, 0x71ea2e3f00000000, 0x11d54f6500000000, + 0x0ec2bfe500000000, 0xd1ab8dd100000000, 0xcebc7d5100000000, + 0xae831c0b00000000, 0xb194ec8b00000000, 0xad0c440100000000, + 0xb21bb48100000000, 0xd224d5db00000000, 0xcd33255b00000000, + 0x125a176f00000000, 0x0d4de7ef00000000, 0x6d7286b500000000, + 0x7265763500000000, 0xd3a1e2dd00000000, 0xccb6125d00000000, + 0xac89730700000000, 0xb39e838700000000, 0x6cf7b1b300000000, + 0x73e0413300000000, 0x13df206900000000, 0x0cc8d0e900000000, + 0xdf9d80f400000000, 0xc08a707400000000, 0xa0b5112e00000000, + 0xbfa2e1ae00000000, 0x60cbd39a00000000, 0x7fdc231a00000000, + 0x1fe3424000000000, 0x00f4b2c000000000, 0xa130262800000000, + 0xbe27d6a800000000, 0xde18b7f200000000, 0xc10f477200000000, + 0x1e66754600000000, 0x017185c600000000, 0x614ee49c00000000, + 0x7e59141c00000000, 0x62c1bc9600000000, 0x7dd64c1600000000, + 0x1de92d4c00000000, 0x02feddcc00000000, 0xdd97eff800000000, + 0xc2801f7800000000, 0xa2bf7e2200000000, 0xbda88ea200000000, + 0x1c6c1a4a00000000, 0x037beaca00000000, 0x63448b9000000000, + 0x7c537b1000000000, 0xa33a492400000000, 0xbc2db9a400000000, + 0xdc12d8fe00000000, 0xc305287e00000000, 0xa524f83000000000, + 0xba3308b000000000, 0xda0c69ea00000000, 0xc51b996a00000000, + 0x1a72ab5e00000000, 0x05655bde00000000, 0x655a3a8400000000, + 0x7a4dca0400000000, 0xdb895eec00000000, 0xc49eae6c00000000, + 0xa4a1cf3600000000, 0xbbb63fb600000000, 0x64df0d8200000000, + 0x7bc8fd0200000000, 0x1bf79c5800000000, 0x04e06cd800000000, + 0x1878c45200000000, 0x076f34d200000000, 0x6750558800000000, + 0x7847a50800000000, 0xa72e973c00000000, 0xb83967bc00000000, + 0xd80606e600000000, 0xc711f66600000000, 0x66d5628e00000000, + 0x79c2920e00000000, 0x19fdf35400000000, 0x06ea03d400000000, + 0xd98331e000000000, 0xc694c16000000000, 0xa6aba03a00000000, + 0xb9bc50ba00000000}, + {0x0000000000000000, 0xe2fd888d00000000, 0x85fd60c000000000, + 0x6700e84d00000000, 0x4bfdb05b00000000, 0xa90038d600000000, + 0xce00d09b00000000, 0x2cfd581600000000, 0x96fa61b700000000, + 0x7407e93a00000000, 0x1307017700000000, 0xf1fa89fa00000000, + 0xdd07d1ec00000000, 0x3ffa596100000000, 0x58fab12c00000000, + 0xba0739a100000000, 0x6df3b2b500000000, 0x8f0e3a3800000000, + 0xe80ed27500000000, 0x0af35af800000000, 0x260e02ee00000000, + 0xc4f38a6300000000, 0xa3f3622e00000000, 0x410eeaa300000000, + 0xfb09d30200000000, 0x19f45b8f00000000, 0x7ef4b3c200000000, + 0x9c093b4f00000000, 0xb0f4635900000000, 0x5209ebd400000000, + 0x3509039900000000, 0xd7f48b1400000000, 0x9be014b000000000, + 0x791d9c3d00000000, 0x1e1d747000000000, 0xfce0fcfd00000000, + 0xd01da4eb00000000, 0x32e02c6600000000, 0x55e0c42b00000000, + 0xb71d4ca600000000, 0x0d1a750700000000, 0xefe7fd8a00000000, + 0x88e715c700000000, 0x6a1a9d4a00000000, 0x46e7c55c00000000, + 0xa41a4dd100000000, 0xc31aa59c00000000, 0x21e72d1100000000, + 0xf613a60500000000, 0x14ee2e8800000000, 0x73eec6c500000000, + 0x91134e4800000000, 0xbdee165e00000000, 0x5f139ed300000000, + 0x3813769e00000000, 0xdaeefe1300000000, 0x60e9c7b200000000, + 0x82144f3f00000000, 0xe514a77200000000, 0x07e92fff00000000, + 0x2b1477e900000000, 0xc9e9ff6400000000, 0xaee9172900000000, + 0x4c149fa400000000, 0x77c758bb00000000, 0x953ad03600000000, + 0xf23a387b00000000, 0x10c7b0f600000000, 0x3c3ae8e000000000, + 0xdec7606d00000000, 0xb9c7882000000000, 0x5b3a00ad00000000, + 0xe13d390c00000000, 0x03c0b18100000000, 0x64c059cc00000000, + 0x863dd14100000000, 0xaac0895700000000, 0x483d01da00000000, + 0x2f3de99700000000, 0xcdc0611a00000000, 0x1a34ea0e00000000, + 0xf8c9628300000000, 0x9fc98ace00000000, 0x7d34024300000000, + 0x51c95a5500000000, 0xb334d2d800000000, 0xd4343a9500000000, + 0x36c9b21800000000, 0x8cce8bb900000000, 0x6e33033400000000, + 0x0933eb7900000000, 0xebce63f400000000, 0xc7333be200000000, + 0x25ceb36f00000000, 0x42ce5b2200000000, 0xa033d3af00000000, + 0xec274c0b00000000, 0x0edac48600000000, 0x69da2ccb00000000, + 0x8b27a44600000000, 0xa7dafc5000000000, 0x452774dd00000000, + 0x22279c9000000000, 0xc0da141d00000000, 0x7add2dbc00000000, + 0x9820a53100000000, 0xff204d7c00000000, 0x1dddc5f100000000, + 0x31209de700000000, 0xd3dd156a00000000, 0xb4ddfd2700000000, + 0x562075aa00000000, 0x81d4febe00000000, 0x6329763300000000, + 0x04299e7e00000000, 0xe6d416f300000000, 0xca294ee500000000, + 0x28d4c66800000000, 0x4fd42e2500000000, 0xad29a6a800000000, + 0x172e9f0900000000, 0xf5d3178400000000, 0x92d3ffc900000000, + 0x702e774400000000, 0x5cd32f5200000000, 0xbe2ea7df00000000, + 0xd92e4f9200000000, 0x3bd3c71f00000000, 0xaf88c0ad00000000, + 0x4d75482000000000, 0x2a75a06d00000000, 0xc88828e000000000, + 0xe47570f600000000, 0x0688f87b00000000, 0x6188103600000000, + 0x837598bb00000000, 0x3972a11a00000000, 0xdb8f299700000000, + 0xbc8fc1da00000000, 0x5e72495700000000, 0x728f114100000000, + 0x907299cc00000000, 0xf772718100000000, 0x158ff90c00000000, + 0xc27b721800000000, 0x2086fa9500000000, 0x478612d800000000, + 0xa57b9a5500000000, 0x8986c24300000000, 0x6b7b4ace00000000, + 0x0c7ba28300000000, 0xee862a0e00000000, 0x548113af00000000, + 0xb67c9b2200000000, 0xd17c736f00000000, 0x3381fbe200000000, + 0x1f7ca3f400000000, 0xfd812b7900000000, 0x9a81c33400000000, + 0x787c4bb900000000, 0x3468d41d00000000, 0xd6955c9000000000, + 0xb195b4dd00000000, 0x53683c5000000000, 0x7f95644600000000, + 0x9d68eccb00000000, 0xfa68048600000000, 0x18958c0b00000000, + 0xa292b5aa00000000, 0x406f3d2700000000, 0x276fd56a00000000, + 0xc5925de700000000, 0xe96f05f100000000, 0x0b928d7c00000000, + 0x6c92653100000000, 0x8e6fedbc00000000, 0x599b66a800000000, + 0xbb66ee2500000000, 0xdc66066800000000, 0x3e9b8ee500000000, + 0x1266d6f300000000, 0xf09b5e7e00000000, 0x979bb63300000000, + 0x75663ebe00000000, 0xcf61071f00000000, 0x2d9c8f9200000000, + 0x4a9c67df00000000, 0xa861ef5200000000, 0x849cb74400000000, + 0x66613fc900000000, 0x0161d78400000000, 0xe39c5f0900000000, + 0xd84f981600000000, 0x3ab2109b00000000, 0x5db2f8d600000000, + 0xbf4f705b00000000, 0x93b2284d00000000, 0x714fa0c000000000, + 0x164f488d00000000, 0xf4b2c00000000000, 0x4eb5f9a100000000, + 0xac48712c00000000, 0xcb48996100000000, 0x29b511ec00000000, + 0x054849fa00000000, 0xe7b5c17700000000, 0x80b5293a00000000, + 0x6248a1b700000000, 0xb5bc2aa300000000, 0x5741a22e00000000, + 0x30414a6300000000, 0xd2bcc2ee00000000, 0xfe419af800000000, + 0x1cbc127500000000, 0x7bbcfa3800000000, 0x994172b500000000, + 0x23464b1400000000, 0xc1bbc39900000000, 0xa6bb2bd400000000, + 0x4446a35900000000, 0x68bbfb4f00000000, 0x8a4673c200000000, + 0xed469b8f00000000, 0x0fbb130200000000, 0x43af8ca600000000, + 0xa152042b00000000, 0xc652ec6600000000, 0x24af64eb00000000, + 0x08523cfd00000000, 0xeaafb47000000000, 0x8daf5c3d00000000, + 0x6f52d4b000000000, 0xd555ed1100000000, 0x37a8659c00000000, + 0x50a88dd100000000, 0xb255055c00000000, 0x9ea85d4a00000000, + 0x7c55d5c700000000, 0x1b553d8a00000000, 0xf9a8b50700000000, + 0x2e5c3e1300000000, 0xcca1b69e00000000, 0xaba15ed300000000, + 0x495cd65e00000000, 0x65a18e4800000000, 0x875c06c500000000, + 0xe05cee8800000000, 0x02a1660500000000, 0xb8a65fa400000000, + 0x5a5bd72900000000, 0x3d5b3f6400000000, 0xdfa6b7e900000000, + 0xf35befff00000000, 0x11a6677200000000, 0x76a68f3f00000000, + 0x945b07b200000000}, + {0x0000000000000000, 0xa90b894e00000000, 0x5217129d00000000, + 0xfb1c9bd300000000, 0xe52855e100000000, 0x4c23dcaf00000000, + 0xb73f477c00000000, 0x1e34ce3200000000, 0x8b57db1900000000, + 0x225c525700000000, 0xd940c98400000000, 0x704b40ca00000000, + 0x6e7f8ef800000000, 0xc77407b600000000, 0x3c689c6500000000, + 0x9563152b00000000, 0x16afb63300000000, 0xbfa43f7d00000000, + 0x44b8a4ae00000000, 0xedb32de000000000, 0xf387e3d200000000, + 0x5a8c6a9c00000000, 0xa190f14f00000000, 0x089b780100000000, + 0x9df86d2a00000000, 0x34f3e46400000000, 0xcfef7fb700000000, + 0x66e4f6f900000000, 0x78d038cb00000000, 0xd1dbb18500000000, + 0x2ac72a5600000000, 0x83cca31800000000, 0x2c5e6d6700000000, + 0x8555e42900000000, 0x7e497ffa00000000, 0xd742f6b400000000, + 0xc976388600000000, 0x607db1c800000000, 0x9b612a1b00000000, + 0x326aa35500000000, 0xa709b67e00000000, 0x0e023f3000000000, + 0xf51ea4e300000000, 0x5c152dad00000000, 0x4221e39f00000000, + 0xeb2a6ad100000000, 0x1036f10200000000, 0xb93d784c00000000, + 0x3af1db5400000000, 0x93fa521a00000000, 0x68e6c9c900000000, + 0xc1ed408700000000, 0xdfd98eb500000000, 0x76d207fb00000000, + 0x8dce9c2800000000, 0x24c5156600000000, 0xb1a6004d00000000, + 0x18ad890300000000, 0xe3b112d000000000, 0x4aba9b9e00000000, + 0x548e55ac00000000, 0xfd85dce200000000, 0x0699473100000000, + 0xaf92ce7f00000000, 0x58bcdace00000000, 0xf1b7538000000000, + 0x0aabc85300000000, 0xa3a0411d00000000, 0xbd948f2f00000000, + 0x149f066100000000, 0xef839db200000000, 0x468814fc00000000, + 0xd3eb01d700000000, 0x7ae0889900000000, 0x81fc134a00000000, + 0x28f79a0400000000, 0x36c3543600000000, 0x9fc8dd7800000000, + 0x64d446ab00000000, 0xcddfcfe500000000, 0x4e136cfd00000000, + 0xe718e5b300000000, 0x1c047e6000000000, 0xb50ff72e00000000, + 0xab3b391c00000000, 0x0230b05200000000, 0xf92c2b8100000000, + 0x5027a2cf00000000, 0xc544b7e400000000, 0x6c4f3eaa00000000, + 0x9753a57900000000, 0x3e582c3700000000, 0x206ce20500000000, + 0x89676b4b00000000, 0x727bf09800000000, 0xdb7079d600000000, + 0x74e2b7a900000000, 0xdde93ee700000000, 0x26f5a53400000000, + 0x8ffe2c7a00000000, 0x91cae24800000000, 0x38c16b0600000000, + 0xc3ddf0d500000000, 0x6ad6799b00000000, 0xffb56cb000000000, + 0x56bee5fe00000000, 0xada27e2d00000000, 0x04a9f76300000000, + 0x1a9d395100000000, 0xb396b01f00000000, 0x488a2bcc00000000, + 0xe181a28200000000, 0x624d019a00000000, 0xcb4688d400000000, + 0x305a130700000000, 0x99519a4900000000, 0x8765547b00000000, + 0x2e6edd3500000000, 0xd57246e600000000, 0x7c79cfa800000000, + 0xe91ada8300000000, 0x401153cd00000000, 0xbb0dc81e00000000, + 0x1206415000000000, 0x0c328f6200000000, 0xa539062c00000000, + 0x5e259dff00000000, 0xf72e14b100000000, 0xf17ec44600000000, + 0x58754d0800000000, 0xa369d6db00000000, 0x0a625f9500000000, + 0x145691a700000000, 0xbd5d18e900000000, 0x4641833a00000000, + 0xef4a0a7400000000, 0x7a291f5f00000000, 0xd322961100000000, + 0x283e0dc200000000, 0x8135848c00000000, 0x9f014abe00000000, + 0x360ac3f000000000, 0xcd16582300000000, 0x641dd16d00000000, + 0xe7d1727500000000, 0x4edafb3b00000000, 0xb5c660e800000000, + 0x1ccde9a600000000, 0x02f9279400000000, 0xabf2aeda00000000, + 0x50ee350900000000, 0xf9e5bc4700000000, 0x6c86a96c00000000, + 0xc58d202200000000, 0x3e91bbf100000000, 0x979a32bf00000000, + 0x89aefc8d00000000, 0x20a575c300000000, 0xdbb9ee1000000000, + 0x72b2675e00000000, 0xdd20a92100000000, 0x742b206f00000000, + 0x8f37bbbc00000000, 0x263c32f200000000, 0x3808fcc000000000, + 0x9103758e00000000, 0x6a1fee5d00000000, 0xc314671300000000, + 0x5677723800000000, 0xff7cfb7600000000, 0x046060a500000000, + 0xad6be9eb00000000, 0xb35f27d900000000, 0x1a54ae9700000000, + 0xe148354400000000, 0x4843bc0a00000000, 0xcb8f1f1200000000, + 0x6284965c00000000, 0x99980d8f00000000, 0x309384c100000000, + 0x2ea74af300000000, 0x87acc3bd00000000, 0x7cb0586e00000000, + 0xd5bbd12000000000, 0x40d8c40b00000000, 0xe9d34d4500000000, + 0x12cfd69600000000, 0xbbc45fd800000000, 0xa5f091ea00000000, + 0x0cfb18a400000000, 0xf7e7837700000000, 0x5eec0a3900000000, + 0xa9c21e8800000000, 0x00c997c600000000, 0xfbd50c1500000000, + 0x52de855b00000000, 0x4cea4b6900000000, 0xe5e1c22700000000, + 0x1efd59f400000000, 0xb7f6d0ba00000000, 0x2295c59100000000, + 0x8b9e4cdf00000000, 0x7082d70c00000000, 0xd9895e4200000000, + 0xc7bd907000000000, 0x6eb6193e00000000, 0x95aa82ed00000000, + 0x3ca10ba300000000, 0xbf6da8bb00000000, 0x166621f500000000, + 0xed7aba2600000000, 0x4471336800000000, 0x5a45fd5a00000000, + 0xf34e741400000000, 0x0852efc700000000, 0xa159668900000000, + 0x343a73a200000000, 0x9d31faec00000000, 0x662d613f00000000, + 0xcf26e87100000000, 0xd112264300000000, 0x7819af0d00000000, + 0x830534de00000000, 0x2a0ebd9000000000, 0x859c73ef00000000, + 0x2c97faa100000000, 0xd78b617200000000, 0x7e80e83c00000000, + 0x60b4260e00000000, 0xc9bfaf4000000000, 0x32a3349300000000, + 0x9ba8bddd00000000, 0x0ecba8f600000000, 0xa7c021b800000000, + 0x5cdcba6b00000000, 0xf5d7332500000000, 0xebe3fd1700000000, + 0x42e8745900000000, 0xb9f4ef8a00000000, 0x10ff66c400000000, + 0x9333c5dc00000000, 0x3a384c9200000000, 0xc124d74100000000, + 0x682f5e0f00000000, 0x761b903d00000000, 0xdf10197300000000, + 0x240c82a000000000, 0x8d070bee00000000, 0x18641ec500000000, + 0xb16f978b00000000, 0x4a730c5800000000, 0xe378851600000000, + 0xfd4c4b2400000000, 0x5447c26a00000000, 0xaf5b59b900000000, + 0x0650d0f700000000}, + {0x0000000000000000, 0x479244af00000000, 0xcf22f88500000000, + 0x88b0bc2a00000000, 0xdf4381d000000000, 0x98d1c57f00000000, + 0x1061795500000000, 0x57f33dfa00000000, 0xff81737a00000000, + 0xb81337d500000000, 0x30a38bff00000000, 0x7731cf5000000000, + 0x20c2f2aa00000000, 0x6750b60500000000, 0xefe00a2f00000000, + 0xa8724e8000000000, 0xfe03e7f400000000, 0xb991a35b00000000, + 0x31211f7100000000, 0x76b35bde00000000, 0x2140662400000000, + 0x66d2228b00000000, 0xee629ea100000000, 0xa9f0da0e00000000, + 0x0182948e00000000, 0x4610d02100000000, 0xcea06c0b00000000, + 0x893228a400000000, 0xdec1155e00000000, 0x995351f100000000, + 0x11e3eddb00000000, 0x5671a97400000000, 0xbd01bf3200000000, + 0xfa93fb9d00000000, 0x722347b700000000, 0x35b1031800000000, + 0x62423ee200000000, 0x25d07a4d00000000, 0xad60c66700000000, + 0xeaf282c800000000, 0x4280cc4800000000, 0x051288e700000000, + 0x8da234cd00000000, 0xca30706200000000, 0x9dc34d9800000000, + 0xda51093700000000, 0x52e1b51d00000000, 0x1573f1b200000000, + 0x430258c600000000, 0x04901c6900000000, 0x8c20a04300000000, + 0xcbb2e4ec00000000, 0x9c41d91600000000, 0xdbd39db900000000, + 0x5363219300000000, 0x14f1653c00000000, 0xbc832bbc00000000, + 0xfb116f1300000000, 0x73a1d33900000000, 0x3433979600000000, + 0x63c0aa6c00000000, 0x2452eec300000000, 0xace252e900000000, + 0xeb70164600000000, 0x7a037e6500000000, 0x3d913aca00000000, + 0xb52186e000000000, 0xf2b3c24f00000000, 0xa540ffb500000000, + 0xe2d2bb1a00000000, 0x6a62073000000000, 0x2df0439f00000000, + 0x85820d1f00000000, 0xc21049b000000000, 0x4aa0f59a00000000, + 0x0d32b13500000000, 0x5ac18ccf00000000, 0x1d53c86000000000, + 0x95e3744a00000000, 0xd27130e500000000, 0x8400999100000000, + 0xc392dd3e00000000, 0x4b22611400000000, 0x0cb025bb00000000, + 0x5b43184100000000, 0x1cd15cee00000000, 0x9461e0c400000000, + 0xd3f3a46b00000000, 0x7b81eaeb00000000, 0x3c13ae4400000000, + 0xb4a3126e00000000, 0xf33156c100000000, 0xa4c26b3b00000000, + 0xe3502f9400000000, 0x6be093be00000000, 0x2c72d71100000000, + 0xc702c15700000000, 0x809085f800000000, 0x082039d200000000, + 0x4fb27d7d00000000, 0x1841408700000000, 0x5fd3042800000000, + 0xd763b80200000000, 0x90f1fcad00000000, 0x3883b22d00000000, + 0x7f11f68200000000, 0xf7a14aa800000000, 0xb0330e0700000000, + 0xe7c033fd00000000, 0xa052775200000000, 0x28e2cb7800000000, + 0x6f708fd700000000, 0x390126a300000000, 0x7e93620c00000000, + 0xf623de2600000000, 0xb1b19a8900000000, 0xe642a77300000000, + 0xa1d0e3dc00000000, 0x29605ff600000000, 0x6ef21b5900000000, + 0xc68055d900000000, 0x8112117600000000, 0x09a2ad5c00000000, + 0x4e30e9f300000000, 0x19c3d40900000000, 0x5e5190a600000000, + 0xd6e12c8c00000000, 0x9173682300000000, 0xf406fcca00000000, + 0xb394b86500000000, 0x3b24044f00000000, 0x7cb640e000000000, + 0x2b457d1a00000000, 0x6cd739b500000000, 0xe467859f00000000, + 0xa3f5c13000000000, 0x0b878fb000000000, 0x4c15cb1f00000000, + 0xc4a5773500000000, 0x8337339a00000000, 0xd4c40e6000000000, + 0x93564acf00000000, 0x1be6f6e500000000, 0x5c74b24a00000000, + 0x0a051b3e00000000, 0x4d975f9100000000, 0xc527e3bb00000000, + 0x82b5a71400000000, 0xd5469aee00000000, 0x92d4de4100000000, + 0x1a64626b00000000, 0x5df626c400000000, 0xf584684400000000, + 0xb2162ceb00000000, 0x3aa690c100000000, 0x7d34d46e00000000, + 0x2ac7e99400000000, 0x6d55ad3b00000000, 0xe5e5111100000000, + 0xa27755be00000000, 0x490743f800000000, 0x0e95075700000000, + 0x8625bb7d00000000, 0xc1b7ffd200000000, 0x9644c22800000000, + 0xd1d6868700000000, 0x59663aad00000000, 0x1ef47e0200000000, + 0xb686308200000000, 0xf114742d00000000, 0x79a4c80700000000, + 0x3e368ca800000000, 0x69c5b15200000000, 0x2e57f5fd00000000, + 0xa6e749d700000000, 0xe1750d7800000000, 0xb704a40c00000000, + 0xf096e0a300000000, 0x78265c8900000000, 0x3fb4182600000000, + 0x684725dc00000000, 0x2fd5617300000000, 0xa765dd5900000000, + 0xe0f799f600000000, 0x4885d77600000000, 0x0f1793d900000000, + 0x87a72ff300000000, 0xc0356b5c00000000, 0x97c656a600000000, + 0xd054120900000000, 0x58e4ae2300000000, 0x1f76ea8c00000000, + 0x8e0582af00000000, 0xc997c60000000000, 0x41277a2a00000000, + 0x06b53e8500000000, 0x5146037f00000000, 0x16d447d000000000, + 0x9e64fbfa00000000, 0xd9f6bf5500000000, 0x7184f1d500000000, + 0x3616b57a00000000, 0xbea6095000000000, 0xf9344dff00000000, + 0xaec7700500000000, 0xe95534aa00000000, 0x61e5888000000000, + 0x2677cc2f00000000, 0x7006655b00000000, 0x379421f400000000, + 0xbf249dde00000000, 0xf8b6d97100000000, 0xaf45e48b00000000, + 0xe8d7a02400000000, 0x60671c0e00000000, 0x27f558a100000000, + 0x8f87162100000000, 0xc815528e00000000, 0x40a5eea400000000, + 0x0737aa0b00000000, 0x50c497f100000000, 0x1756d35e00000000, + 0x9fe66f7400000000, 0xd8742bdb00000000, 0x33043d9d00000000, + 0x7496793200000000, 0xfc26c51800000000, 0xbbb481b700000000, + 0xec47bc4d00000000, 0xabd5f8e200000000, 0x236544c800000000, + 0x64f7006700000000, 0xcc854ee700000000, 0x8b170a4800000000, + 0x03a7b66200000000, 0x4435f2cd00000000, 0x13c6cf3700000000, + 0x54548b9800000000, 0xdce437b200000000, 0x9b76731d00000000, + 0xcd07da6900000000, 0x8a959ec600000000, 0x022522ec00000000, + 0x45b7664300000000, 0x12445bb900000000, 0x55d61f1600000000, + 0xdd66a33c00000000, 0x9af4e79300000000, 0x3286a91300000000, + 0x7514edbc00000000, 0xfda4519600000000, 0xba36153900000000, + 0xedc528c300000000, 0xaa576c6c00000000, 0x22e7d04600000000, + 0x657594e900000000}}; + +#else /* W == 4 */ + +local const z_crc_t FAR crc_braid_table[][256] = { + {0x00000000, 0x65673b46, 0xcace768c, 0xafa94dca, 0x4eedeb59, + 0x2b8ad01f, 0x84239dd5, 0xe144a693, 0x9ddbd6b2, 0xf8bcedf4, + 0x5715a03e, 0x32729b78, 0xd3363deb, 0xb65106ad, 0x19f84b67, + 0x7c9f7021, 0xe0c6ab25, 0x85a19063, 0x2a08dda9, 0x4f6fe6ef, + 0xae2b407c, 0xcb4c7b3a, 0x64e536f0, 0x01820db6, 0x7d1d7d97, + 0x187a46d1, 0xb7d30b1b, 0xd2b4305d, 0x33f096ce, 0x5697ad88, + 0xf93ee042, 0x9c59db04, 0x1afc500b, 0x7f9b6b4d, 0xd0322687, + 0xb5551dc1, 0x5411bb52, 0x31768014, 0x9edfcdde, 0xfbb8f698, + 0x872786b9, 0xe240bdff, 0x4de9f035, 0x288ecb73, 0xc9ca6de0, + 0xacad56a6, 0x03041b6c, 0x6663202a, 0xfa3afb2e, 0x9f5dc068, + 0x30f48da2, 0x5593b6e4, 0xb4d71077, 0xd1b02b31, 0x7e1966fb, + 0x1b7e5dbd, 0x67e12d9c, 0x028616da, 0xad2f5b10, 0xc8486056, + 0x290cc6c5, 0x4c6bfd83, 0xe3c2b049, 0x86a58b0f, 0x35f8a016, + 0x509f9b50, 0xff36d69a, 0x9a51eddc, 0x7b154b4f, 0x1e727009, + 0xb1db3dc3, 0xd4bc0685, 0xa82376a4, 0xcd444de2, 0x62ed0028, + 0x078a3b6e, 0xe6ce9dfd, 0x83a9a6bb, 0x2c00eb71, 0x4967d037, + 0xd53e0b33, 0xb0593075, 0x1ff07dbf, 0x7a9746f9, 0x9bd3e06a, + 0xfeb4db2c, 0x511d96e6, 0x347aada0, 0x48e5dd81, 0x2d82e6c7, + 0x822bab0d, 0xe74c904b, 0x060836d8, 0x636f0d9e, 0xccc64054, + 0xa9a17b12, 0x2f04f01d, 0x4a63cb5b, 0xe5ca8691, 0x80adbdd7, + 0x61e91b44, 0x048e2002, 0xab276dc8, 0xce40568e, 0xb2df26af, + 0xd7b81de9, 0x78115023, 0x1d766b65, 0xfc32cdf6, 0x9955f6b0, + 0x36fcbb7a, 0x539b803c, 0xcfc25b38, 0xaaa5607e, 0x050c2db4, + 0x606b16f2, 0x812fb061, 0xe4488b27, 0x4be1c6ed, 0x2e86fdab, + 0x52198d8a, 0x377eb6cc, 0x98d7fb06, 0xfdb0c040, 0x1cf466d3, + 0x79935d95, 0xd63a105f, 0xb35d2b19, 0x6bf1402c, 0x0e967b6a, + 0xa13f36a0, 0xc4580de6, 0x251cab75, 0x407b9033, 0xefd2ddf9, + 0x8ab5e6bf, 0xf62a969e, 0x934dadd8, 0x3ce4e012, 0x5983db54, + 0xb8c77dc7, 0xdda04681, 0x72090b4b, 0x176e300d, 0x8b37eb09, + 0xee50d04f, 0x41f99d85, 0x249ea6c3, 0xc5da0050, 0xa0bd3b16, + 0x0f1476dc, 0x6a734d9a, 0x16ec3dbb, 0x738b06fd, 0xdc224b37, + 0xb9457071, 0x5801d6e2, 0x3d66eda4, 0x92cfa06e, 0xf7a89b28, + 0x710d1027, 0x146a2b61, 0xbbc366ab, 0xdea45ded, 0x3fe0fb7e, + 0x5a87c038, 0xf52e8df2, 0x9049b6b4, 0xecd6c695, 0x89b1fdd3, + 0x2618b019, 0x437f8b5f, 0xa23b2dcc, 0xc75c168a, 0x68f55b40, + 0x0d926006, 0x91cbbb02, 0xf4ac8044, 0x5b05cd8e, 0x3e62f6c8, + 0xdf26505b, 0xba416b1d, 0x15e826d7, 0x708f1d91, 0x0c106db0, + 0x697756f6, 0xc6de1b3c, 0xa3b9207a, 0x42fd86e9, 0x279abdaf, + 0x8833f065, 0xed54cb23, 0x5e09e03a, 0x3b6edb7c, 0x94c796b6, + 0xf1a0adf0, 0x10e40b63, 0x75833025, 0xda2a7def, 0xbf4d46a9, + 0xc3d23688, 0xa6b50dce, 0x091c4004, 0x6c7b7b42, 0x8d3fddd1, + 0xe858e697, 0x47f1ab5d, 0x2296901b, 0xbecf4b1f, 0xdba87059, + 0x74013d93, 0x116606d5, 0xf022a046, 0x95459b00, 0x3aecd6ca, + 0x5f8bed8c, 0x23149dad, 0x4673a6eb, 0xe9daeb21, 0x8cbdd067, + 0x6df976f4, 0x089e4db2, 0xa7370078, 0xc2503b3e, 0x44f5b031, + 0x21928b77, 0x8e3bc6bd, 0xeb5cfdfb, 0x0a185b68, 0x6f7f602e, + 0xc0d62de4, 0xa5b116a2, 0xd92e6683, 0xbc495dc5, 0x13e0100f, + 0x76872b49, 0x97c38dda, 0xf2a4b69c, 0x5d0dfb56, 0x386ac010, + 0xa4331b14, 0xc1542052, 0x6efd6d98, 0x0b9a56de, 0xeadef04d, + 0x8fb9cb0b, 0x201086c1, 0x4577bd87, 0x39e8cda6, 0x5c8ff6e0, + 0xf326bb2a, 0x9641806c, 0x770526ff, 0x12621db9, 0xbdcb5073, + 0xd8ac6b35}, + {0x00000000, 0xd7e28058, 0x74b406f1, 0xa35686a9, 0xe9680de2, + 0x3e8a8dba, 0x9ddc0b13, 0x4a3e8b4b, 0x09a11d85, 0xde439ddd, + 0x7d151b74, 0xaaf79b2c, 0xe0c91067, 0x372b903f, 0x947d1696, + 0x439f96ce, 0x13423b0a, 0xc4a0bb52, 0x67f63dfb, 0xb014bda3, + 0xfa2a36e8, 0x2dc8b6b0, 0x8e9e3019, 0x597cb041, 0x1ae3268f, + 0xcd01a6d7, 0x6e57207e, 0xb9b5a026, 0xf38b2b6d, 0x2469ab35, + 0x873f2d9c, 0x50ddadc4, 0x26847614, 0xf166f64c, 0x523070e5, + 0x85d2f0bd, 0xcfec7bf6, 0x180efbae, 0xbb587d07, 0x6cbafd5f, + 0x2f256b91, 0xf8c7ebc9, 0x5b916d60, 0x8c73ed38, 0xc64d6673, + 0x11afe62b, 0xb2f96082, 0x651be0da, 0x35c64d1e, 0xe224cd46, + 0x41724bef, 0x9690cbb7, 0xdcae40fc, 0x0b4cc0a4, 0xa81a460d, + 0x7ff8c655, 0x3c67509b, 0xeb85d0c3, 0x48d3566a, 0x9f31d632, + 0xd50f5d79, 0x02eddd21, 0xa1bb5b88, 0x7659dbd0, 0x4d08ec28, + 0x9aea6c70, 0x39bcead9, 0xee5e6a81, 0xa460e1ca, 0x73826192, + 0xd0d4e73b, 0x07366763, 0x44a9f1ad, 0x934b71f5, 0x301df75c, + 0xe7ff7704, 0xadc1fc4f, 0x7a237c17, 0xd975fabe, 0x0e977ae6, + 0x5e4ad722, 0x89a8577a, 0x2afed1d3, 0xfd1c518b, 0xb722dac0, + 0x60c05a98, 0xc396dc31, 0x14745c69, 0x57ebcaa7, 0x80094aff, + 0x235fcc56, 0xf4bd4c0e, 0xbe83c745, 0x6961471d, 0xca37c1b4, + 0x1dd541ec, 0x6b8c9a3c, 0xbc6e1a64, 0x1f389ccd, 0xc8da1c95, + 0x82e497de, 0x55061786, 0xf650912f, 0x21b21177, 0x622d87b9, + 0xb5cf07e1, 0x16998148, 0xc17b0110, 0x8b458a5b, 0x5ca70a03, + 0xfff18caa, 0x28130cf2, 0x78cea136, 0xaf2c216e, 0x0c7aa7c7, + 0xdb98279f, 0x91a6acd4, 0x46442c8c, 0xe512aa25, 0x32f02a7d, + 0x716fbcb3, 0xa68d3ceb, 0x05dbba42, 0xd2393a1a, 0x9807b151, + 0x4fe53109, 0xecb3b7a0, 0x3b5137f8, 0x9a11d850, 0x4df35808, + 0xeea5dea1, 0x39475ef9, 0x7379d5b2, 0xa49b55ea, 0x07cdd343, + 0xd02f531b, 0x93b0c5d5, 0x4452458d, 0xe704c324, 0x30e6437c, + 0x7ad8c837, 0xad3a486f, 0x0e6ccec6, 0xd98e4e9e, 0x8953e35a, + 0x5eb16302, 0xfde7e5ab, 0x2a0565f3, 0x603beeb8, 0xb7d96ee0, + 0x148fe849, 0xc36d6811, 0x80f2fedf, 0x57107e87, 0xf446f82e, + 0x23a47876, 0x699af33d, 0xbe787365, 0x1d2ef5cc, 0xcacc7594, + 0xbc95ae44, 0x6b772e1c, 0xc821a8b5, 0x1fc328ed, 0x55fda3a6, + 0x821f23fe, 0x2149a557, 0xf6ab250f, 0xb534b3c1, 0x62d63399, + 0xc180b530, 0x16623568, 0x5c5cbe23, 0x8bbe3e7b, 0x28e8b8d2, + 0xff0a388a, 0xafd7954e, 0x78351516, 0xdb6393bf, 0x0c8113e7, + 0x46bf98ac, 0x915d18f4, 0x320b9e5d, 0xe5e91e05, 0xa67688cb, + 0x71940893, 0xd2c28e3a, 0x05200e62, 0x4f1e8529, 0x98fc0571, + 0x3baa83d8, 0xec480380, 0xd7193478, 0x00fbb420, 0xa3ad3289, + 0x744fb2d1, 0x3e71399a, 0xe993b9c2, 0x4ac53f6b, 0x9d27bf33, + 0xdeb829fd, 0x095aa9a5, 0xaa0c2f0c, 0x7deeaf54, 0x37d0241f, + 0xe032a447, 0x436422ee, 0x9486a2b6, 0xc45b0f72, 0x13b98f2a, + 0xb0ef0983, 0x670d89db, 0x2d330290, 0xfad182c8, 0x59870461, + 0x8e658439, 0xcdfa12f7, 0x1a1892af, 0xb94e1406, 0x6eac945e, + 0x24921f15, 0xf3709f4d, 0x502619e4, 0x87c499bc, 0xf19d426c, + 0x267fc234, 0x8529449d, 0x52cbc4c5, 0x18f54f8e, 0xcf17cfd6, + 0x6c41497f, 0xbba3c927, 0xf83c5fe9, 0x2fdedfb1, 0x8c885918, + 0x5b6ad940, 0x1154520b, 0xc6b6d253, 0x65e054fa, 0xb202d4a2, + 0xe2df7966, 0x353df93e, 0x966b7f97, 0x4189ffcf, 0x0bb77484, + 0xdc55f4dc, 0x7f037275, 0xa8e1f22d, 0xeb7e64e3, 0x3c9ce4bb, + 0x9fca6212, 0x4828e24a, 0x02166901, 0xd5f4e959, 0x76a26ff0, + 0xa140efa8}, + {0x00000000, 0xef52b6e1, 0x05d46b83, 0xea86dd62, 0x0ba8d706, + 0xe4fa61e7, 0x0e7cbc85, 0xe12e0a64, 0x1751ae0c, 0xf80318ed, + 0x1285c58f, 0xfdd7736e, 0x1cf9790a, 0xf3abcfeb, 0x192d1289, + 0xf67fa468, 0x2ea35c18, 0xc1f1eaf9, 0x2b77379b, 0xc425817a, + 0x250b8b1e, 0xca593dff, 0x20dfe09d, 0xcf8d567c, 0x39f2f214, + 0xd6a044f5, 0x3c269997, 0xd3742f76, 0x325a2512, 0xdd0893f3, + 0x378e4e91, 0xd8dcf870, 0x5d46b830, 0xb2140ed1, 0x5892d3b3, + 0xb7c06552, 0x56ee6f36, 0xb9bcd9d7, 0x533a04b5, 0xbc68b254, + 0x4a17163c, 0xa545a0dd, 0x4fc37dbf, 0xa091cb5e, 0x41bfc13a, + 0xaeed77db, 0x446baab9, 0xab391c58, 0x73e5e428, 0x9cb752c9, + 0x76318fab, 0x9963394a, 0x784d332e, 0x971f85cf, 0x7d9958ad, + 0x92cbee4c, 0x64b44a24, 0x8be6fcc5, 0x616021a7, 0x8e329746, + 0x6f1c9d22, 0x804e2bc3, 0x6ac8f6a1, 0x859a4040, 0xba8d7060, + 0x55dfc681, 0xbf591be3, 0x500bad02, 0xb125a766, 0x5e771187, + 0xb4f1cce5, 0x5ba37a04, 0xaddcde6c, 0x428e688d, 0xa808b5ef, + 0x475a030e, 0xa674096a, 0x4926bf8b, 0xa3a062e9, 0x4cf2d408, + 0x942e2c78, 0x7b7c9a99, 0x91fa47fb, 0x7ea8f11a, 0x9f86fb7e, + 0x70d44d9f, 0x9a5290fd, 0x7500261c, 0x837f8274, 0x6c2d3495, + 0x86abe9f7, 0x69f95f16, 0x88d75572, 0x6785e393, 0x8d033ef1, + 0x62518810, 0xe7cbc850, 0x08997eb1, 0xe21fa3d3, 0x0d4d1532, + 0xec631f56, 0x0331a9b7, 0xe9b774d5, 0x06e5c234, 0xf09a665c, + 0x1fc8d0bd, 0xf54e0ddf, 0x1a1cbb3e, 0xfb32b15a, 0x146007bb, + 0xfee6dad9, 0x11b46c38, 0xc9689448, 0x263a22a9, 0xccbcffcb, + 0x23ee492a, 0xc2c0434e, 0x2d92f5af, 0xc71428cd, 0x28469e2c, + 0xde393a44, 0x316b8ca5, 0xdbed51c7, 0x34bfe726, 0xd591ed42, + 0x3ac35ba3, 0xd04586c1, 0x3f173020, 0xae6be681, 0x41395060, + 0xabbf8d02, 0x44ed3be3, 0xa5c33187, 0x4a918766, 0xa0175a04, + 0x4f45ece5, 0xb93a488d, 0x5668fe6c, 0xbcee230e, 0x53bc95ef, + 0xb2929f8b, 0x5dc0296a, 0xb746f408, 0x581442e9, 0x80c8ba99, + 0x6f9a0c78, 0x851cd11a, 0x6a4e67fb, 0x8b606d9f, 0x6432db7e, + 0x8eb4061c, 0x61e6b0fd, 0x97991495, 0x78cba274, 0x924d7f16, + 0x7d1fc9f7, 0x9c31c393, 0x73637572, 0x99e5a810, 0x76b71ef1, + 0xf32d5eb1, 0x1c7fe850, 0xf6f93532, 0x19ab83d3, 0xf88589b7, + 0x17d73f56, 0xfd51e234, 0x120354d5, 0xe47cf0bd, 0x0b2e465c, + 0xe1a89b3e, 0x0efa2ddf, 0xefd427bb, 0x0086915a, 0xea004c38, + 0x0552fad9, 0xdd8e02a9, 0x32dcb448, 0xd85a692a, 0x3708dfcb, + 0xd626d5af, 0x3974634e, 0xd3f2be2c, 0x3ca008cd, 0xcadfaca5, + 0x258d1a44, 0xcf0bc726, 0x205971c7, 0xc1777ba3, 0x2e25cd42, + 0xc4a31020, 0x2bf1a6c1, 0x14e696e1, 0xfbb42000, 0x1132fd62, + 0xfe604b83, 0x1f4e41e7, 0xf01cf706, 0x1a9a2a64, 0xf5c89c85, + 0x03b738ed, 0xece58e0c, 0x0663536e, 0xe931e58f, 0x081fefeb, + 0xe74d590a, 0x0dcb8468, 0xe2993289, 0x3a45caf9, 0xd5177c18, + 0x3f91a17a, 0xd0c3179b, 0x31ed1dff, 0xdebfab1e, 0x3439767c, + 0xdb6bc09d, 0x2d1464f5, 0xc246d214, 0x28c00f76, 0xc792b997, + 0x26bcb3f3, 0xc9ee0512, 0x2368d870, 0xcc3a6e91, 0x49a02ed1, + 0xa6f29830, 0x4c744552, 0xa326f3b3, 0x4208f9d7, 0xad5a4f36, + 0x47dc9254, 0xa88e24b5, 0x5ef180dd, 0xb1a3363c, 0x5b25eb5e, + 0xb4775dbf, 0x555957db, 0xba0be13a, 0x508d3c58, 0xbfdf8ab9, + 0x670372c9, 0x8851c428, 0x62d7194a, 0x8d85afab, 0x6caba5cf, + 0x83f9132e, 0x697fce4c, 0x862d78ad, 0x7052dcc5, 0x9f006a24, + 0x7586b746, 0x9ad401a7, 0x7bfa0bc3, 0x94a8bd22, 0x7e2e6040, + 0x917cd6a1}, + {0x00000000, 0x87a6cb43, 0xd43c90c7, 0x539a5b84, 0x730827cf, + 0xf4aeec8c, 0xa734b708, 0x20927c4b, 0xe6104f9e, 0x61b684dd, + 0x322cdf59, 0xb58a141a, 0x95186851, 0x12bea312, 0x4124f896, + 0xc68233d5, 0x1751997d, 0x90f7523e, 0xc36d09ba, 0x44cbc2f9, + 0x6459beb2, 0xe3ff75f1, 0xb0652e75, 0x37c3e536, 0xf141d6e3, + 0x76e71da0, 0x257d4624, 0xa2db8d67, 0x8249f12c, 0x05ef3a6f, + 0x567561eb, 0xd1d3aaa8, 0x2ea332fa, 0xa905f9b9, 0xfa9fa23d, + 0x7d39697e, 0x5dab1535, 0xda0dde76, 0x899785f2, 0x0e314eb1, + 0xc8b37d64, 0x4f15b627, 0x1c8feda3, 0x9b2926e0, 0xbbbb5aab, + 0x3c1d91e8, 0x6f87ca6c, 0xe821012f, 0x39f2ab87, 0xbe5460c4, + 0xedce3b40, 0x6a68f003, 0x4afa8c48, 0xcd5c470b, 0x9ec61c8f, + 0x1960d7cc, 0xdfe2e419, 0x58442f5a, 0x0bde74de, 0x8c78bf9d, + 0xaceac3d6, 0x2b4c0895, 0x78d65311, 0xff709852, 0x5d4665f4, + 0xdae0aeb7, 0x897af533, 0x0edc3e70, 0x2e4e423b, 0xa9e88978, + 0xfa72d2fc, 0x7dd419bf, 0xbb562a6a, 0x3cf0e129, 0x6f6abaad, + 0xe8cc71ee, 0xc85e0da5, 0x4ff8c6e6, 0x1c629d62, 0x9bc45621, + 0x4a17fc89, 0xcdb137ca, 0x9e2b6c4e, 0x198da70d, 0x391fdb46, + 0xbeb91005, 0xed234b81, 0x6a8580c2, 0xac07b317, 0x2ba17854, + 0x783b23d0, 0xff9de893, 0xdf0f94d8, 0x58a95f9b, 0x0b33041f, + 0x8c95cf5c, 0x73e5570e, 0xf4439c4d, 0xa7d9c7c9, 0x207f0c8a, + 0x00ed70c1, 0x874bbb82, 0xd4d1e006, 0x53772b45, 0x95f51890, + 0x1253d3d3, 0x41c98857, 0xc66f4314, 0xe6fd3f5f, 0x615bf41c, + 0x32c1af98, 0xb56764db, 0x64b4ce73, 0xe3120530, 0xb0885eb4, + 0x372e95f7, 0x17bce9bc, 0x901a22ff, 0xc380797b, 0x4426b238, + 0x82a481ed, 0x05024aae, 0x5698112a, 0xd13eda69, 0xf1aca622, + 0x760a6d61, 0x259036e5, 0xa236fda6, 0xba8ccbe8, 0x3d2a00ab, + 0x6eb05b2f, 0xe916906c, 0xc984ec27, 0x4e222764, 0x1db87ce0, + 0x9a1eb7a3, 0x5c9c8476, 0xdb3a4f35, 0x88a014b1, 0x0f06dff2, + 0x2f94a3b9, 0xa83268fa, 0xfba8337e, 0x7c0ef83d, 0xaddd5295, + 0x2a7b99d6, 0x79e1c252, 0xfe470911, 0xded5755a, 0x5973be19, + 0x0ae9e59d, 0x8d4f2ede, 0x4bcd1d0b, 0xcc6bd648, 0x9ff18dcc, + 0x1857468f, 0x38c53ac4, 0xbf63f187, 0xecf9aa03, 0x6b5f6140, + 0x942ff912, 0x13893251, 0x401369d5, 0xc7b5a296, 0xe727dedd, + 0x6081159e, 0x331b4e1a, 0xb4bd8559, 0x723fb68c, 0xf5997dcf, + 0xa603264b, 0x21a5ed08, 0x01379143, 0x86915a00, 0xd50b0184, + 0x52adcac7, 0x837e606f, 0x04d8ab2c, 0x5742f0a8, 0xd0e43beb, + 0xf07647a0, 0x77d08ce3, 0x244ad767, 0xa3ec1c24, 0x656e2ff1, + 0xe2c8e4b2, 0xb152bf36, 0x36f47475, 0x1666083e, 0x91c0c37d, + 0xc25a98f9, 0x45fc53ba, 0xe7caae1c, 0x606c655f, 0x33f63edb, + 0xb450f598, 0x94c289d3, 0x13644290, 0x40fe1914, 0xc758d257, + 0x01dae182, 0x867c2ac1, 0xd5e67145, 0x5240ba06, 0x72d2c64d, + 0xf5740d0e, 0xa6ee568a, 0x21489dc9, 0xf09b3761, 0x773dfc22, + 0x24a7a7a6, 0xa3016ce5, 0x839310ae, 0x0435dbed, 0x57af8069, + 0xd0094b2a, 0x168b78ff, 0x912db3bc, 0xc2b7e838, 0x4511237b, + 0x65835f30, 0xe2259473, 0xb1bfcff7, 0x361904b4, 0xc9699ce6, + 0x4ecf57a5, 0x1d550c21, 0x9af3c762, 0xba61bb29, 0x3dc7706a, + 0x6e5d2bee, 0xe9fbe0ad, 0x2f79d378, 0xa8df183b, 0xfb4543bf, + 0x7ce388fc, 0x5c71f4b7, 0xdbd73ff4, 0x884d6470, 0x0febaf33, + 0xde38059b, 0x599eced8, 0x0a04955c, 0x8da25e1f, 0xad302254, + 0x2a96e917, 0x790cb293, 0xfeaa79d0, 0x38284a05, 0xbf8e8146, + 0xec14dac2, 0x6bb21181, 0x4b206dca, 0xcc86a689, 0x9f1cfd0d, + 0x18ba364e}}; + +local const z_word_t FAR crc_braid_big_table[][256] = { + {0x00000000, 0x43cba687, 0xc7903cd4, 0x845b9a53, 0xcf270873, + 0x8cecaef4, 0x08b734a7, 0x4b7c9220, 0x9e4f10e6, 0xdd84b661, + 0x59df2c32, 0x1a148ab5, 0x51681895, 0x12a3be12, 0x96f82441, + 0xd53382c6, 0x7d995117, 0x3e52f790, 0xba096dc3, 0xf9c2cb44, + 0xb2be5964, 0xf175ffe3, 0x752e65b0, 0x36e5c337, 0xe3d641f1, + 0xa01de776, 0x24467d25, 0x678ddba2, 0x2cf14982, 0x6f3aef05, + 0xeb617556, 0xa8aad3d1, 0xfa32a32e, 0xb9f905a9, 0x3da29ffa, + 0x7e69397d, 0x3515ab5d, 0x76de0dda, 0xf2859789, 0xb14e310e, + 0x647db3c8, 0x27b6154f, 0xa3ed8f1c, 0xe026299b, 0xab5abbbb, + 0xe8911d3c, 0x6cca876f, 0x2f0121e8, 0x87abf239, 0xc46054be, + 0x403bceed, 0x03f0686a, 0x488cfa4a, 0x0b475ccd, 0x8f1cc69e, + 0xccd76019, 0x19e4e2df, 0x5a2f4458, 0xde74de0b, 0x9dbf788c, + 0xd6c3eaac, 0x95084c2b, 0x1153d678, 0x529870ff, 0xf465465d, + 0xb7aee0da, 0x33f57a89, 0x703edc0e, 0x3b424e2e, 0x7889e8a9, + 0xfcd272fa, 0xbf19d47d, 0x6a2a56bb, 0x29e1f03c, 0xadba6a6f, + 0xee71cce8, 0xa50d5ec8, 0xe6c6f84f, 0x629d621c, 0x2156c49b, + 0x89fc174a, 0xca37b1cd, 0x4e6c2b9e, 0x0da78d19, 0x46db1f39, + 0x0510b9be, 0x814b23ed, 0xc280856a, 0x17b307ac, 0x5478a12b, + 0xd0233b78, 0x93e89dff, 0xd8940fdf, 0x9b5fa958, 0x1f04330b, + 0x5ccf958c, 0x0e57e573, 0x4d9c43f4, 0xc9c7d9a7, 0x8a0c7f20, + 0xc170ed00, 0x82bb4b87, 0x06e0d1d4, 0x452b7753, 0x9018f595, + 0xd3d35312, 0x5788c941, 0x14436fc6, 0x5f3ffde6, 0x1cf45b61, + 0x98afc132, 0xdb6467b5, 0x73ceb464, 0x300512e3, 0xb45e88b0, + 0xf7952e37, 0xbce9bc17, 0xff221a90, 0x7b7980c3, 0x38b22644, + 0xed81a482, 0xae4a0205, 0x2a119856, 0x69da3ed1, 0x22a6acf1, + 0x616d0a76, 0xe5369025, 0xa6fd36a2, 0xe8cb8cba, 0xab002a3d, + 0x2f5bb06e, 0x6c9016e9, 0x27ec84c9, 0x6427224e, 0xe07cb81d, + 0xa3b71e9a, 0x76849c5c, 0x354f3adb, 0xb114a088, 0xf2df060f, + 0xb9a3942f, 0xfa6832a8, 0x7e33a8fb, 0x3df80e7c, 0x9552ddad, + 0xd6997b2a, 0x52c2e179, 0x110947fe, 0x5a75d5de, 0x19be7359, + 0x9de5e90a, 0xde2e4f8d, 0x0b1dcd4b, 0x48d66bcc, 0xcc8df19f, + 0x8f465718, 0xc43ac538, 0x87f163bf, 0x03aaf9ec, 0x40615f6b, + 0x12f92f94, 0x51328913, 0xd5691340, 0x96a2b5c7, 0xddde27e7, + 0x9e158160, 0x1a4e1b33, 0x5985bdb4, 0x8cb63f72, 0xcf7d99f5, + 0x4b2603a6, 0x08eda521, 0x43913701, 0x005a9186, 0x84010bd5, + 0xc7caad52, 0x6f607e83, 0x2cabd804, 0xa8f04257, 0xeb3be4d0, + 0xa04776f0, 0xe38cd077, 0x67d74a24, 0x241ceca3, 0xf12f6e65, + 0xb2e4c8e2, 0x36bf52b1, 0x7574f436, 0x3e086616, 0x7dc3c091, + 0xf9985ac2, 0xba53fc45, 0x1caecae7, 0x5f656c60, 0xdb3ef633, + 0x98f550b4, 0xd389c294, 0x90426413, 0x1419fe40, 0x57d258c7, + 0x82e1da01, 0xc12a7c86, 0x4571e6d5, 0x06ba4052, 0x4dc6d272, + 0x0e0d74f5, 0x8a56eea6, 0xc99d4821, 0x61379bf0, 0x22fc3d77, + 0xa6a7a724, 0xe56c01a3, 0xae109383, 0xeddb3504, 0x6980af57, + 0x2a4b09d0, 0xff788b16, 0xbcb32d91, 0x38e8b7c2, 0x7b231145, + 0x305f8365, 0x739425e2, 0xf7cfbfb1, 0xb4041936, 0xe69c69c9, + 0xa557cf4e, 0x210c551d, 0x62c7f39a, 0x29bb61ba, 0x6a70c73d, + 0xee2b5d6e, 0xade0fbe9, 0x78d3792f, 0x3b18dfa8, 0xbf4345fb, + 0xfc88e37c, 0xb7f4715c, 0xf43fd7db, 0x70644d88, 0x33afeb0f, + 0x9b0538de, 0xd8ce9e59, 0x5c95040a, 0x1f5ea28d, 0x542230ad, + 0x17e9962a, 0x93b20c79, 0xd079aafe, 0x054a2838, 0x46818ebf, + 0xc2da14ec, 0x8111b26b, 0xca6d204b, 0x89a686cc, 0x0dfd1c9f, + 0x4e36ba18}, + {0x00000000, 0xe1b652ef, 0x836bd405, 0x62dd86ea, 0x06d7a80b, + 0xe761fae4, 0x85bc7c0e, 0x640a2ee1, 0x0cae5117, 0xed1803f8, + 0x8fc58512, 0x6e73d7fd, 0x0a79f91c, 0xebcfabf3, 0x89122d19, + 0x68a47ff6, 0x185ca32e, 0xf9eaf1c1, 0x9b37772b, 0x7a8125c4, + 0x1e8b0b25, 0xff3d59ca, 0x9de0df20, 0x7c568dcf, 0x14f2f239, + 0xf544a0d6, 0x9799263c, 0x762f74d3, 0x12255a32, 0xf39308dd, + 0x914e8e37, 0x70f8dcd8, 0x30b8465d, 0xd10e14b2, 0xb3d39258, + 0x5265c0b7, 0x366fee56, 0xd7d9bcb9, 0xb5043a53, 0x54b268bc, + 0x3c16174a, 0xdda045a5, 0xbf7dc34f, 0x5ecb91a0, 0x3ac1bf41, + 0xdb77edae, 0xb9aa6b44, 0x581c39ab, 0x28e4e573, 0xc952b79c, + 0xab8f3176, 0x4a396399, 0x2e334d78, 0xcf851f97, 0xad58997d, + 0x4ceecb92, 0x244ab464, 0xc5fce68b, 0xa7216061, 0x4697328e, + 0x229d1c6f, 0xc32b4e80, 0xa1f6c86a, 0x40409a85, 0x60708dba, + 0x81c6df55, 0xe31b59bf, 0x02ad0b50, 0x66a725b1, 0x8711775e, + 0xe5ccf1b4, 0x047aa35b, 0x6cdedcad, 0x8d688e42, 0xefb508a8, + 0x0e035a47, 0x6a0974a6, 0x8bbf2649, 0xe962a0a3, 0x08d4f24c, + 0x782c2e94, 0x999a7c7b, 0xfb47fa91, 0x1af1a87e, 0x7efb869f, + 0x9f4dd470, 0xfd90529a, 0x1c260075, 0x74827f83, 0x95342d6c, + 0xf7e9ab86, 0x165ff969, 0x7255d788, 0x93e38567, 0xf13e038d, + 0x10885162, 0x50c8cbe7, 0xb17e9908, 0xd3a31fe2, 0x32154d0d, + 0x561f63ec, 0xb7a93103, 0xd574b7e9, 0x34c2e506, 0x5c669af0, + 0xbdd0c81f, 0xdf0d4ef5, 0x3ebb1c1a, 0x5ab132fb, 0xbb076014, + 0xd9dae6fe, 0x386cb411, 0x489468c9, 0xa9223a26, 0xcbffbccc, + 0x2a49ee23, 0x4e43c0c2, 0xaff5922d, 0xcd2814c7, 0x2c9e4628, + 0x443a39de, 0xa58c6b31, 0xc751eddb, 0x26e7bf34, 0x42ed91d5, + 0xa35bc33a, 0xc18645d0, 0x2030173f, 0x81e66bae, 0x60503941, + 0x028dbfab, 0xe33bed44, 0x8731c3a5, 0x6687914a, 0x045a17a0, + 0xe5ec454f, 0x8d483ab9, 0x6cfe6856, 0x0e23eebc, 0xef95bc53, + 0x8b9f92b2, 0x6a29c05d, 0x08f446b7, 0xe9421458, 0x99bac880, + 0x780c9a6f, 0x1ad11c85, 0xfb674e6a, 0x9f6d608b, 0x7edb3264, + 0x1c06b48e, 0xfdb0e661, 0x95149997, 0x74a2cb78, 0x167f4d92, + 0xf7c91f7d, 0x93c3319c, 0x72756373, 0x10a8e599, 0xf11eb776, + 0xb15e2df3, 0x50e87f1c, 0x3235f9f6, 0xd383ab19, 0xb78985f8, + 0x563fd717, 0x34e251fd, 0xd5540312, 0xbdf07ce4, 0x5c462e0b, + 0x3e9ba8e1, 0xdf2dfa0e, 0xbb27d4ef, 0x5a918600, 0x384c00ea, + 0xd9fa5205, 0xa9028edd, 0x48b4dc32, 0x2a695ad8, 0xcbdf0837, + 0xafd526d6, 0x4e637439, 0x2cbef2d3, 0xcd08a03c, 0xa5acdfca, + 0x441a8d25, 0x26c70bcf, 0xc7715920, 0xa37b77c1, 0x42cd252e, + 0x2010a3c4, 0xc1a6f12b, 0xe196e614, 0x0020b4fb, 0x62fd3211, + 0x834b60fe, 0xe7414e1f, 0x06f71cf0, 0x642a9a1a, 0x859cc8f5, + 0xed38b703, 0x0c8ee5ec, 0x6e536306, 0x8fe531e9, 0xebef1f08, + 0x0a594de7, 0x6884cb0d, 0x893299e2, 0xf9ca453a, 0x187c17d5, + 0x7aa1913f, 0x9b17c3d0, 0xff1ded31, 0x1eabbfde, 0x7c763934, + 0x9dc06bdb, 0xf564142d, 0x14d246c2, 0x760fc028, 0x97b992c7, + 0xf3b3bc26, 0x1205eec9, 0x70d86823, 0x916e3acc, 0xd12ea049, + 0x3098f2a6, 0x5245744c, 0xb3f326a3, 0xd7f90842, 0x364f5aad, + 0x5492dc47, 0xb5248ea8, 0xdd80f15e, 0x3c36a3b1, 0x5eeb255b, + 0xbf5d77b4, 0xdb575955, 0x3ae10bba, 0x583c8d50, 0xb98adfbf, + 0xc9720367, 0x28c45188, 0x4a19d762, 0xabaf858d, 0xcfa5ab6c, + 0x2e13f983, 0x4cce7f69, 0xad782d86, 0xc5dc5270, 0x246a009f, + 0x46b78675, 0xa701d49a, 0xc30bfa7b, 0x22bda894, 0x40602e7e, + 0xa1d67c91}, + {0x00000000, 0x5880e2d7, 0xf106b474, 0xa98656a3, 0xe20d68e9, + 0xba8d8a3e, 0x130bdc9d, 0x4b8b3e4a, 0x851da109, 0xdd9d43de, + 0x741b157d, 0x2c9bf7aa, 0x6710c9e0, 0x3f902b37, 0x96167d94, + 0xce969f43, 0x0a3b4213, 0x52bba0c4, 0xfb3df667, 0xa3bd14b0, + 0xe8362afa, 0xb0b6c82d, 0x19309e8e, 0x41b07c59, 0x8f26e31a, + 0xd7a601cd, 0x7e20576e, 0x26a0b5b9, 0x6d2b8bf3, 0x35ab6924, + 0x9c2d3f87, 0xc4addd50, 0x14768426, 0x4cf666f1, 0xe5703052, + 0xbdf0d285, 0xf67beccf, 0xaefb0e18, 0x077d58bb, 0x5ffdba6c, + 0x916b252f, 0xc9ebc7f8, 0x606d915b, 0x38ed738c, 0x73664dc6, + 0x2be6af11, 0x8260f9b2, 0xdae01b65, 0x1e4dc635, 0x46cd24e2, + 0xef4b7241, 0xb7cb9096, 0xfc40aedc, 0xa4c04c0b, 0x0d461aa8, + 0x55c6f87f, 0x9b50673c, 0xc3d085eb, 0x6a56d348, 0x32d6319f, + 0x795d0fd5, 0x21dded02, 0x885bbba1, 0xd0db5976, 0x28ec084d, + 0x706cea9a, 0xd9eabc39, 0x816a5eee, 0xcae160a4, 0x92618273, + 0x3be7d4d0, 0x63673607, 0xadf1a944, 0xf5714b93, 0x5cf71d30, + 0x0477ffe7, 0x4ffcc1ad, 0x177c237a, 0xbefa75d9, 0xe67a970e, + 0x22d74a5e, 0x7a57a889, 0xd3d1fe2a, 0x8b511cfd, 0xc0da22b7, + 0x985ac060, 0x31dc96c3, 0x695c7414, 0xa7caeb57, 0xff4a0980, + 0x56cc5f23, 0x0e4cbdf4, 0x45c783be, 0x1d476169, 0xb4c137ca, + 0xec41d51d, 0x3c9a8c6b, 0x641a6ebc, 0xcd9c381f, 0x951cdac8, + 0xde97e482, 0x86170655, 0x2f9150f6, 0x7711b221, 0xb9872d62, + 0xe107cfb5, 0x48819916, 0x10017bc1, 0x5b8a458b, 0x030aa75c, + 0xaa8cf1ff, 0xf20c1328, 0x36a1ce78, 0x6e212caf, 0xc7a77a0c, + 0x9f2798db, 0xd4aca691, 0x8c2c4446, 0x25aa12e5, 0x7d2af032, + 0xb3bc6f71, 0xeb3c8da6, 0x42badb05, 0x1a3a39d2, 0x51b10798, + 0x0931e54f, 0xa0b7b3ec, 0xf837513b, 0x50d8119a, 0x0858f34d, + 0xa1dea5ee, 0xf95e4739, 0xb2d57973, 0xea559ba4, 0x43d3cd07, + 0x1b532fd0, 0xd5c5b093, 0x8d455244, 0x24c304e7, 0x7c43e630, + 0x37c8d87a, 0x6f483aad, 0xc6ce6c0e, 0x9e4e8ed9, 0x5ae35389, + 0x0263b15e, 0xabe5e7fd, 0xf365052a, 0xb8ee3b60, 0xe06ed9b7, + 0x49e88f14, 0x11686dc3, 0xdffef280, 0x877e1057, 0x2ef846f4, + 0x7678a423, 0x3df39a69, 0x657378be, 0xccf52e1d, 0x9475ccca, + 0x44ae95bc, 0x1c2e776b, 0xb5a821c8, 0xed28c31f, 0xa6a3fd55, + 0xfe231f82, 0x57a54921, 0x0f25abf6, 0xc1b334b5, 0x9933d662, + 0x30b580c1, 0x68356216, 0x23be5c5c, 0x7b3ebe8b, 0xd2b8e828, + 0x8a380aff, 0x4e95d7af, 0x16153578, 0xbf9363db, 0xe713810c, + 0xac98bf46, 0xf4185d91, 0x5d9e0b32, 0x051ee9e5, 0xcb8876a6, + 0x93089471, 0x3a8ec2d2, 0x620e2005, 0x29851e4f, 0x7105fc98, + 0xd883aa3b, 0x800348ec, 0x783419d7, 0x20b4fb00, 0x8932ada3, + 0xd1b24f74, 0x9a39713e, 0xc2b993e9, 0x6b3fc54a, 0x33bf279d, + 0xfd29b8de, 0xa5a95a09, 0x0c2f0caa, 0x54afee7d, 0x1f24d037, + 0x47a432e0, 0xee226443, 0xb6a28694, 0x720f5bc4, 0x2a8fb913, + 0x8309efb0, 0xdb890d67, 0x9002332d, 0xc882d1fa, 0x61048759, + 0x3984658e, 0xf712facd, 0xaf92181a, 0x06144eb9, 0x5e94ac6e, + 0x151f9224, 0x4d9f70f3, 0xe4192650, 0xbc99c487, 0x6c429df1, + 0x34c27f26, 0x9d442985, 0xc5c4cb52, 0x8e4ff518, 0xd6cf17cf, + 0x7f49416c, 0x27c9a3bb, 0xe95f3cf8, 0xb1dfde2f, 0x1859888c, + 0x40d96a5b, 0x0b525411, 0x53d2b6c6, 0xfa54e065, 0xa2d402b2, + 0x6679dfe2, 0x3ef93d35, 0x977f6b96, 0xcfff8941, 0x8474b70b, + 0xdcf455dc, 0x7572037f, 0x2df2e1a8, 0xe3647eeb, 0xbbe49c3c, + 0x1262ca9f, 0x4ae22848, 0x01691602, 0x59e9f4d5, 0xf06fa276, + 0xa8ef40a1}, + {0x00000000, 0x463b6765, 0x8c76ceca, 0xca4da9af, 0x59ebed4e, + 0x1fd08a2b, 0xd59d2384, 0x93a644e1, 0xb2d6db9d, 0xf4edbcf8, + 0x3ea01557, 0x789b7232, 0xeb3d36d3, 0xad0651b6, 0x674bf819, + 0x21709f7c, 0x25abc6e0, 0x6390a185, 0xa9dd082a, 0xefe66f4f, + 0x7c402bae, 0x3a7b4ccb, 0xf036e564, 0xb60d8201, 0x977d1d7d, + 0xd1467a18, 0x1b0bd3b7, 0x5d30b4d2, 0xce96f033, 0x88ad9756, + 0x42e03ef9, 0x04db599c, 0x0b50fc1a, 0x4d6b9b7f, 0x872632d0, + 0xc11d55b5, 0x52bb1154, 0x14807631, 0xdecddf9e, 0x98f6b8fb, + 0xb9862787, 0xffbd40e2, 0x35f0e94d, 0x73cb8e28, 0xe06dcac9, + 0xa656adac, 0x6c1b0403, 0x2a206366, 0x2efb3afa, 0x68c05d9f, + 0xa28df430, 0xe4b69355, 0x7710d7b4, 0x312bb0d1, 0xfb66197e, + 0xbd5d7e1b, 0x9c2de167, 0xda168602, 0x105b2fad, 0x566048c8, + 0xc5c60c29, 0x83fd6b4c, 0x49b0c2e3, 0x0f8ba586, 0x16a0f835, + 0x509b9f50, 0x9ad636ff, 0xdced519a, 0x4f4b157b, 0x0970721e, + 0xc33ddbb1, 0x8506bcd4, 0xa47623a8, 0xe24d44cd, 0x2800ed62, + 0x6e3b8a07, 0xfd9dcee6, 0xbba6a983, 0x71eb002c, 0x37d06749, + 0x330b3ed5, 0x753059b0, 0xbf7df01f, 0xf946977a, 0x6ae0d39b, + 0x2cdbb4fe, 0xe6961d51, 0xa0ad7a34, 0x81dde548, 0xc7e6822d, + 0x0dab2b82, 0x4b904ce7, 0xd8360806, 0x9e0d6f63, 0x5440c6cc, + 0x127ba1a9, 0x1df0042f, 0x5bcb634a, 0x9186cae5, 0xd7bdad80, + 0x441be961, 0x02208e04, 0xc86d27ab, 0x8e5640ce, 0xaf26dfb2, + 0xe91db8d7, 0x23501178, 0x656b761d, 0xf6cd32fc, 0xb0f65599, + 0x7abbfc36, 0x3c809b53, 0x385bc2cf, 0x7e60a5aa, 0xb42d0c05, + 0xf2166b60, 0x61b02f81, 0x278b48e4, 0xedc6e14b, 0xabfd862e, + 0x8a8d1952, 0xccb67e37, 0x06fbd798, 0x40c0b0fd, 0xd366f41c, + 0x955d9379, 0x5f103ad6, 0x192b5db3, 0x2c40f16b, 0x6a7b960e, + 0xa0363fa1, 0xe60d58c4, 0x75ab1c25, 0x33907b40, 0xf9ddd2ef, + 0xbfe6b58a, 0x9e962af6, 0xd8ad4d93, 0x12e0e43c, 0x54db8359, + 0xc77dc7b8, 0x8146a0dd, 0x4b0b0972, 0x0d306e17, 0x09eb378b, + 0x4fd050ee, 0x859df941, 0xc3a69e24, 0x5000dac5, 0x163bbda0, + 0xdc76140f, 0x9a4d736a, 0xbb3dec16, 0xfd068b73, 0x374b22dc, + 0x717045b9, 0xe2d60158, 0xa4ed663d, 0x6ea0cf92, 0x289ba8f7, + 0x27100d71, 0x612b6a14, 0xab66c3bb, 0xed5da4de, 0x7efbe03f, + 0x38c0875a, 0xf28d2ef5, 0xb4b64990, 0x95c6d6ec, 0xd3fdb189, + 0x19b01826, 0x5f8b7f43, 0xcc2d3ba2, 0x8a165cc7, 0x405bf568, + 0x0660920d, 0x02bbcb91, 0x4480acf4, 0x8ecd055b, 0xc8f6623e, + 0x5b5026df, 0x1d6b41ba, 0xd726e815, 0x911d8f70, 0xb06d100c, + 0xf6567769, 0x3c1bdec6, 0x7a20b9a3, 0xe986fd42, 0xafbd9a27, + 0x65f03388, 0x23cb54ed, 0x3ae0095e, 0x7cdb6e3b, 0xb696c794, + 0xf0ada0f1, 0x630be410, 0x25308375, 0xef7d2ada, 0xa9464dbf, + 0x8836d2c3, 0xce0db5a6, 0x04401c09, 0x427b7b6c, 0xd1dd3f8d, + 0x97e658e8, 0x5dabf147, 0x1b909622, 0x1f4bcfbe, 0x5970a8db, + 0x933d0174, 0xd5066611, 0x46a022f0, 0x009b4595, 0xcad6ec3a, + 0x8ced8b5f, 0xad9d1423, 0xeba67346, 0x21ebdae9, 0x67d0bd8c, + 0xf476f96d, 0xb24d9e08, 0x780037a7, 0x3e3b50c2, 0x31b0f544, + 0x778b9221, 0xbdc63b8e, 0xfbfd5ceb, 0x685b180a, 0x2e607f6f, + 0xe42dd6c0, 0xa216b1a5, 0x83662ed9, 0xc55d49bc, 0x0f10e013, + 0x492b8776, 0xda8dc397, 0x9cb6a4f2, 0x56fb0d5d, 0x10c06a38, + 0x141b33a4, 0x522054c1, 0x986dfd6e, 0xde569a0b, 0x4df0deea, + 0x0bcbb98f, 0xc1861020, 0x87bd7745, 0xa6cde839, 0xe0f68f5c, + 0x2abb26f3, 0x6c804196, 0xff260577, 0xb91d6212, 0x7350cbbd, + 0x356bacd8}}; + +#endif + +#endif + +#if N == 6 + +#if W == 8 + +local const z_crc_t FAR crc_braid_table[][256] = { + {0x00000000, 0x3db1ecdc, 0x7b63d9b8, 0x46d23564, 0xf6c7b370, + 0xcb765fac, 0x8da46ac8, 0xb0158614, 0x36fe60a1, 0x0b4f8c7d, + 0x4d9db919, 0x702c55c5, 0xc039d3d1, 0xfd883f0d, 0xbb5a0a69, + 0x86ebe6b5, 0x6dfcc142, 0x504d2d9e, 0x169f18fa, 0x2b2ef426, + 0x9b3b7232, 0xa68a9eee, 0xe058ab8a, 0xdde94756, 0x5b02a1e3, + 0x66b34d3f, 0x2061785b, 0x1dd09487, 0xadc51293, 0x9074fe4f, + 0xd6a6cb2b, 0xeb1727f7, 0xdbf98284, 0xe6486e58, 0xa09a5b3c, + 0x9d2bb7e0, 0x2d3e31f4, 0x108fdd28, 0x565de84c, 0x6bec0490, + 0xed07e225, 0xd0b60ef9, 0x96643b9d, 0xabd5d741, 0x1bc05155, + 0x2671bd89, 0x60a388ed, 0x5d126431, 0xb60543c6, 0x8bb4af1a, + 0xcd669a7e, 0xf0d776a2, 0x40c2f0b6, 0x7d731c6a, 0x3ba1290e, + 0x0610c5d2, 0x80fb2367, 0xbd4acfbb, 0xfb98fadf, 0xc6291603, + 0x763c9017, 0x4b8d7ccb, 0x0d5f49af, 0x30eea573, 0x6c820349, + 0x5133ef95, 0x17e1daf1, 0x2a50362d, 0x9a45b039, 0xa7f45ce5, + 0xe1266981, 0xdc97855d, 0x5a7c63e8, 0x67cd8f34, 0x211fba50, + 0x1cae568c, 0xacbbd098, 0x910a3c44, 0xd7d80920, 0xea69e5fc, + 0x017ec20b, 0x3ccf2ed7, 0x7a1d1bb3, 0x47acf76f, 0xf7b9717b, + 0xca089da7, 0x8cdaa8c3, 0xb16b441f, 0x3780a2aa, 0x0a314e76, + 0x4ce37b12, 0x715297ce, 0xc14711da, 0xfcf6fd06, 0xba24c862, + 0x879524be, 0xb77b81cd, 0x8aca6d11, 0xcc185875, 0xf1a9b4a9, + 0x41bc32bd, 0x7c0dde61, 0x3adfeb05, 0x076e07d9, 0x8185e16c, + 0xbc340db0, 0xfae638d4, 0xc757d408, 0x7742521c, 0x4af3bec0, + 0x0c218ba4, 0x31906778, 0xda87408f, 0xe736ac53, 0xa1e49937, + 0x9c5575eb, 0x2c40f3ff, 0x11f11f23, 0x57232a47, 0x6a92c69b, + 0xec79202e, 0xd1c8ccf2, 0x971af996, 0xaaab154a, 0x1abe935e, + 0x270f7f82, 0x61dd4ae6, 0x5c6ca63a, 0xd9040692, 0xe4b5ea4e, + 0xa267df2a, 0x9fd633f6, 0x2fc3b5e2, 0x1272593e, 0x54a06c5a, + 0x69118086, 0xeffa6633, 0xd24b8aef, 0x9499bf8b, 0xa9285357, + 0x193dd543, 0x248c399f, 0x625e0cfb, 0x5fefe027, 0xb4f8c7d0, + 0x89492b0c, 0xcf9b1e68, 0xf22af2b4, 0x423f74a0, 0x7f8e987c, + 0x395cad18, 0x04ed41c4, 0x8206a771, 0xbfb74bad, 0xf9657ec9, + 0xc4d49215, 0x74c11401, 0x4970f8dd, 0x0fa2cdb9, 0x32132165, + 0x02fd8416, 0x3f4c68ca, 0x799e5dae, 0x442fb172, 0xf43a3766, + 0xc98bdbba, 0x8f59eede, 0xb2e80202, 0x3403e4b7, 0x09b2086b, + 0x4f603d0f, 0x72d1d1d3, 0xc2c457c7, 0xff75bb1b, 0xb9a78e7f, + 0x841662a3, 0x6f014554, 0x52b0a988, 0x14629cec, 0x29d37030, + 0x99c6f624, 0xa4771af8, 0xe2a52f9c, 0xdf14c340, 0x59ff25f5, + 0x644ec929, 0x229cfc4d, 0x1f2d1091, 0xaf389685, 0x92897a59, + 0xd45b4f3d, 0xe9eaa3e1, 0xb58605db, 0x8837e907, 0xcee5dc63, + 0xf35430bf, 0x4341b6ab, 0x7ef05a77, 0x38226f13, 0x059383cf, + 0x8378657a, 0xbec989a6, 0xf81bbcc2, 0xc5aa501e, 0x75bfd60a, + 0x480e3ad6, 0x0edc0fb2, 0x336de36e, 0xd87ac499, 0xe5cb2845, + 0xa3191d21, 0x9ea8f1fd, 0x2ebd77e9, 0x130c9b35, 0x55deae51, + 0x686f428d, 0xee84a438, 0xd33548e4, 0x95e77d80, 0xa856915c, + 0x18431748, 0x25f2fb94, 0x6320cef0, 0x5e91222c, 0x6e7f875f, + 0x53ce6b83, 0x151c5ee7, 0x28adb23b, 0x98b8342f, 0xa509d8f3, + 0xe3dbed97, 0xde6a014b, 0x5881e7fe, 0x65300b22, 0x23e23e46, + 0x1e53d29a, 0xae46548e, 0x93f7b852, 0xd5258d36, 0xe89461ea, + 0x0383461d, 0x3e32aac1, 0x78e09fa5, 0x45517379, 0xf544f56d, + 0xc8f519b1, 0x8e272cd5, 0xb396c009, 0x357d26bc, 0x08ccca60, + 0x4e1eff04, 0x73af13d8, 0xc3ba95cc, 0xfe0b7910, 0xb8d94c74, + 0x8568a0a8}, + {0x00000000, 0x69790b65, 0xd2f216ca, 0xbb8b1daf, 0x7e952bd5, + 0x17ec20b0, 0xac673d1f, 0xc51e367a, 0xfd2a57aa, 0x94535ccf, + 0x2fd84160, 0x46a14a05, 0x83bf7c7f, 0xeac6771a, 0x514d6ab5, + 0x383461d0, 0x2125a915, 0x485ca270, 0xf3d7bfdf, 0x9aaeb4ba, + 0x5fb082c0, 0x36c989a5, 0x8d42940a, 0xe43b9f6f, 0xdc0ffebf, + 0xb576f5da, 0x0efde875, 0x6784e310, 0xa29ad56a, 0xcbe3de0f, + 0x7068c3a0, 0x1911c8c5, 0x424b522a, 0x2b32594f, 0x90b944e0, + 0xf9c04f85, 0x3cde79ff, 0x55a7729a, 0xee2c6f35, 0x87556450, + 0xbf610580, 0xd6180ee5, 0x6d93134a, 0x04ea182f, 0xc1f42e55, + 0xa88d2530, 0x1306389f, 0x7a7f33fa, 0x636efb3f, 0x0a17f05a, + 0xb19cedf5, 0xd8e5e690, 0x1dfbd0ea, 0x7482db8f, 0xcf09c620, + 0xa670cd45, 0x9e44ac95, 0xf73da7f0, 0x4cb6ba5f, 0x25cfb13a, + 0xe0d18740, 0x89a88c25, 0x3223918a, 0x5b5a9aef, 0x8496a454, + 0xedefaf31, 0x5664b29e, 0x3f1db9fb, 0xfa038f81, 0x937a84e4, + 0x28f1994b, 0x4188922e, 0x79bcf3fe, 0x10c5f89b, 0xab4ee534, + 0xc237ee51, 0x0729d82b, 0x6e50d34e, 0xd5dbcee1, 0xbca2c584, + 0xa5b30d41, 0xccca0624, 0x77411b8b, 0x1e3810ee, 0xdb262694, + 0xb25f2df1, 0x09d4305e, 0x60ad3b3b, 0x58995aeb, 0x31e0518e, + 0x8a6b4c21, 0xe3124744, 0x260c713e, 0x4f757a5b, 0xf4fe67f4, + 0x9d876c91, 0xc6ddf67e, 0xafa4fd1b, 0x142fe0b4, 0x7d56ebd1, + 0xb848ddab, 0xd131d6ce, 0x6abacb61, 0x03c3c004, 0x3bf7a1d4, + 0x528eaab1, 0xe905b71e, 0x807cbc7b, 0x45628a01, 0x2c1b8164, + 0x97909ccb, 0xfee997ae, 0xe7f85f6b, 0x8e81540e, 0x350a49a1, + 0x5c7342c4, 0x996d74be, 0xf0147fdb, 0x4b9f6274, 0x22e66911, + 0x1ad208c1, 0x73ab03a4, 0xc8201e0b, 0xa159156e, 0x64472314, + 0x0d3e2871, 0xb6b535de, 0xdfcc3ebb, 0xd25c4ee9, 0xbb25458c, + 0x00ae5823, 0x69d75346, 0xacc9653c, 0xc5b06e59, 0x7e3b73f6, + 0x17427893, 0x2f761943, 0x460f1226, 0xfd840f89, 0x94fd04ec, + 0x51e33296, 0x389a39f3, 0x8311245c, 0xea682f39, 0xf379e7fc, + 0x9a00ec99, 0x218bf136, 0x48f2fa53, 0x8deccc29, 0xe495c74c, + 0x5f1edae3, 0x3667d186, 0x0e53b056, 0x672abb33, 0xdca1a69c, + 0xb5d8adf9, 0x70c69b83, 0x19bf90e6, 0xa2348d49, 0xcb4d862c, + 0x90171cc3, 0xf96e17a6, 0x42e50a09, 0x2b9c016c, 0xee823716, + 0x87fb3c73, 0x3c7021dc, 0x55092ab9, 0x6d3d4b69, 0x0444400c, + 0xbfcf5da3, 0xd6b656c6, 0x13a860bc, 0x7ad16bd9, 0xc15a7676, + 0xa8237d13, 0xb132b5d6, 0xd84bbeb3, 0x63c0a31c, 0x0ab9a879, + 0xcfa79e03, 0xa6de9566, 0x1d5588c9, 0x742c83ac, 0x4c18e27c, + 0x2561e919, 0x9eeaf4b6, 0xf793ffd3, 0x328dc9a9, 0x5bf4c2cc, + 0xe07fdf63, 0x8906d406, 0x56caeabd, 0x3fb3e1d8, 0x8438fc77, + 0xed41f712, 0x285fc168, 0x4126ca0d, 0xfaadd7a2, 0x93d4dcc7, + 0xabe0bd17, 0xc299b672, 0x7912abdd, 0x106ba0b8, 0xd57596c2, + 0xbc0c9da7, 0x07878008, 0x6efe8b6d, 0x77ef43a8, 0x1e9648cd, + 0xa51d5562, 0xcc645e07, 0x097a687d, 0x60036318, 0xdb887eb7, + 0xb2f175d2, 0x8ac51402, 0xe3bc1f67, 0x583702c8, 0x314e09ad, + 0xf4503fd7, 0x9d2934b2, 0x26a2291d, 0x4fdb2278, 0x1481b897, + 0x7df8b3f2, 0xc673ae5d, 0xaf0aa538, 0x6a149342, 0x036d9827, + 0xb8e68588, 0xd19f8eed, 0xe9abef3d, 0x80d2e458, 0x3b59f9f7, + 0x5220f292, 0x973ec4e8, 0xfe47cf8d, 0x45ccd222, 0x2cb5d947, + 0x35a41182, 0x5cdd1ae7, 0xe7560748, 0x8e2f0c2d, 0x4b313a57, + 0x22483132, 0x99c32c9d, 0xf0ba27f8, 0xc88e4628, 0xa1f74d4d, + 0x1a7c50e2, 0x73055b87, 0xb61b6dfd, 0xdf626698, 0x64e97b37, + 0x0d907052}, + {0x00000000, 0x7fc99b93, 0xff933726, 0x805aacb5, 0x2457680d, + 0x5b9ef39e, 0xdbc45f2b, 0xa40dc4b8, 0x48aed01a, 0x37674b89, + 0xb73de73c, 0xc8f47caf, 0x6cf9b817, 0x13302384, 0x936a8f31, + 0xeca314a2, 0x915da034, 0xee943ba7, 0x6ece9712, 0x11070c81, + 0xb50ac839, 0xcac353aa, 0x4a99ff1f, 0x3550648c, 0xd9f3702e, + 0xa63aebbd, 0x26604708, 0x59a9dc9b, 0xfda41823, 0x826d83b0, + 0x02372f05, 0x7dfeb496, 0xf9ca4629, 0x8603ddba, 0x0659710f, + 0x7990ea9c, 0xdd9d2e24, 0xa254b5b7, 0x220e1902, 0x5dc78291, + 0xb1649633, 0xcead0da0, 0x4ef7a115, 0x313e3a86, 0x9533fe3e, + 0xeafa65ad, 0x6aa0c918, 0x1569528b, 0x6897e61d, 0x175e7d8e, + 0x9704d13b, 0xe8cd4aa8, 0x4cc08e10, 0x33091583, 0xb353b936, + 0xcc9a22a5, 0x20393607, 0x5ff0ad94, 0xdfaa0121, 0xa0639ab2, + 0x046e5e0a, 0x7ba7c599, 0xfbfd692c, 0x8434f2bf, 0x28e58a13, + 0x572c1180, 0xd776bd35, 0xa8bf26a6, 0x0cb2e21e, 0x737b798d, + 0xf321d538, 0x8ce84eab, 0x604b5a09, 0x1f82c19a, 0x9fd86d2f, + 0xe011f6bc, 0x441c3204, 0x3bd5a997, 0xbb8f0522, 0xc4469eb1, + 0xb9b82a27, 0xc671b1b4, 0x462b1d01, 0x39e28692, 0x9def422a, + 0xe226d9b9, 0x627c750c, 0x1db5ee9f, 0xf116fa3d, 0x8edf61ae, + 0x0e85cd1b, 0x714c5688, 0xd5419230, 0xaa8809a3, 0x2ad2a516, + 0x551b3e85, 0xd12fcc3a, 0xaee657a9, 0x2ebcfb1c, 0x5175608f, + 0xf578a437, 0x8ab13fa4, 0x0aeb9311, 0x75220882, 0x99811c20, + 0xe64887b3, 0x66122b06, 0x19dbb095, 0xbdd6742d, 0xc21fefbe, + 0x4245430b, 0x3d8cd898, 0x40726c0e, 0x3fbbf79d, 0xbfe15b28, + 0xc028c0bb, 0x64250403, 0x1bec9f90, 0x9bb63325, 0xe47fa8b6, + 0x08dcbc14, 0x77152787, 0xf74f8b32, 0x888610a1, 0x2c8bd419, + 0x53424f8a, 0xd318e33f, 0xacd178ac, 0x51cb1426, 0x2e028fb5, + 0xae582300, 0xd191b893, 0x759c7c2b, 0x0a55e7b8, 0x8a0f4b0d, + 0xf5c6d09e, 0x1965c43c, 0x66ac5faf, 0xe6f6f31a, 0x993f6889, + 0x3d32ac31, 0x42fb37a2, 0xc2a19b17, 0xbd680084, 0xc096b412, + 0xbf5f2f81, 0x3f058334, 0x40cc18a7, 0xe4c1dc1f, 0x9b08478c, + 0x1b52eb39, 0x649b70aa, 0x88386408, 0xf7f1ff9b, 0x77ab532e, + 0x0862c8bd, 0xac6f0c05, 0xd3a69796, 0x53fc3b23, 0x2c35a0b0, + 0xa801520f, 0xd7c8c99c, 0x57926529, 0x285bfeba, 0x8c563a02, + 0xf39fa191, 0x73c50d24, 0x0c0c96b7, 0xe0af8215, 0x9f661986, + 0x1f3cb533, 0x60f52ea0, 0xc4f8ea18, 0xbb31718b, 0x3b6bdd3e, + 0x44a246ad, 0x395cf23b, 0x469569a8, 0xc6cfc51d, 0xb9065e8e, + 0x1d0b9a36, 0x62c201a5, 0xe298ad10, 0x9d513683, 0x71f22221, + 0x0e3bb9b2, 0x8e611507, 0xf1a88e94, 0x55a54a2c, 0x2a6cd1bf, + 0xaa367d0a, 0xd5ffe699, 0x792e9e35, 0x06e705a6, 0x86bda913, + 0xf9743280, 0x5d79f638, 0x22b06dab, 0xa2eac11e, 0xdd235a8d, + 0x31804e2f, 0x4e49d5bc, 0xce137909, 0xb1dae29a, 0x15d72622, + 0x6a1ebdb1, 0xea441104, 0x958d8a97, 0xe8733e01, 0x97baa592, + 0x17e00927, 0x682992b4, 0xcc24560c, 0xb3edcd9f, 0x33b7612a, + 0x4c7efab9, 0xa0ddee1b, 0xdf147588, 0x5f4ed93d, 0x208742ae, + 0x848a8616, 0xfb431d85, 0x7b19b130, 0x04d02aa3, 0x80e4d81c, + 0xff2d438f, 0x7f77ef3a, 0x00be74a9, 0xa4b3b011, 0xdb7a2b82, + 0x5b208737, 0x24e91ca4, 0xc84a0806, 0xb7839395, 0x37d93f20, + 0x4810a4b3, 0xec1d600b, 0x93d4fb98, 0x138e572d, 0x6c47ccbe, + 0x11b97828, 0x6e70e3bb, 0xee2a4f0e, 0x91e3d49d, 0x35ee1025, + 0x4a278bb6, 0xca7d2703, 0xb5b4bc90, 0x5917a832, 0x26de33a1, + 0xa6849f14, 0xd94d0487, 0x7d40c03f, 0x02895bac, 0x82d3f719, + 0xfd1a6c8a}, + {0x00000000, 0xa396284c, 0x9c5d56d9, 0x3fcb7e95, 0xe3cbabf3, + 0x405d83bf, 0x7f96fd2a, 0xdc00d566, 0x1ce651a7, 0xbf7079eb, + 0x80bb077e, 0x232d2f32, 0xff2dfa54, 0x5cbbd218, 0x6370ac8d, + 0xc0e684c1, 0x39cca34e, 0x9a5a8b02, 0xa591f597, 0x0607dddb, + 0xda0708bd, 0x799120f1, 0x465a5e64, 0xe5cc7628, 0x252af2e9, + 0x86bcdaa5, 0xb977a430, 0x1ae18c7c, 0xc6e1591a, 0x65777156, + 0x5abc0fc3, 0xf92a278f, 0x7399469c, 0xd00f6ed0, 0xefc41045, + 0x4c523809, 0x9052ed6f, 0x33c4c523, 0x0c0fbbb6, 0xaf9993fa, + 0x6f7f173b, 0xcce93f77, 0xf32241e2, 0x50b469ae, 0x8cb4bcc8, + 0x2f229484, 0x10e9ea11, 0xb37fc25d, 0x4a55e5d2, 0xe9c3cd9e, + 0xd608b30b, 0x759e9b47, 0xa99e4e21, 0x0a08666d, 0x35c318f8, + 0x965530b4, 0x56b3b475, 0xf5259c39, 0xcaeee2ac, 0x6978cae0, + 0xb5781f86, 0x16ee37ca, 0x2925495f, 0x8ab36113, 0xe7328d38, + 0x44a4a574, 0x7b6fdbe1, 0xd8f9f3ad, 0x04f926cb, 0xa76f0e87, + 0x98a47012, 0x3b32585e, 0xfbd4dc9f, 0x5842f4d3, 0x67898a46, + 0xc41fa20a, 0x181f776c, 0xbb895f20, 0x844221b5, 0x27d409f9, + 0xdefe2e76, 0x7d68063a, 0x42a378af, 0xe13550e3, 0x3d358585, + 0x9ea3adc9, 0xa168d35c, 0x02fefb10, 0xc2187fd1, 0x618e579d, + 0x5e452908, 0xfdd30144, 0x21d3d422, 0x8245fc6e, 0xbd8e82fb, + 0x1e18aab7, 0x94abcba4, 0x373de3e8, 0x08f69d7d, 0xab60b531, + 0x77606057, 0xd4f6481b, 0xeb3d368e, 0x48ab1ec2, 0x884d9a03, + 0x2bdbb24f, 0x1410ccda, 0xb786e496, 0x6b8631f0, 0xc81019bc, + 0xf7db6729, 0x544d4f65, 0xad6768ea, 0x0ef140a6, 0x313a3e33, + 0x92ac167f, 0x4eacc319, 0xed3aeb55, 0xd2f195c0, 0x7167bd8c, + 0xb181394d, 0x12171101, 0x2ddc6f94, 0x8e4a47d8, 0x524a92be, + 0xf1dcbaf2, 0xce17c467, 0x6d81ec2b, 0x15141c31, 0xb682347d, + 0x89494ae8, 0x2adf62a4, 0xf6dfb7c2, 0x55499f8e, 0x6a82e11b, + 0xc914c957, 0x09f24d96, 0xaa6465da, 0x95af1b4f, 0x36393303, + 0xea39e665, 0x49afce29, 0x7664b0bc, 0xd5f298f0, 0x2cd8bf7f, + 0x8f4e9733, 0xb085e9a6, 0x1313c1ea, 0xcf13148c, 0x6c853cc0, + 0x534e4255, 0xf0d86a19, 0x303eeed8, 0x93a8c694, 0xac63b801, + 0x0ff5904d, 0xd3f5452b, 0x70636d67, 0x4fa813f2, 0xec3e3bbe, + 0x668d5aad, 0xc51b72e1, 0xfad00c74, 0x59462438, 0x8546f15e, + 0x26d0d912, 0x191ba787, 0xba8d8fcb, 0x7a6b0b0a, 0xd9fd2346, + 0xe6365dd3, 0x45a0759f, 0x99a0a0f9, 0x3a3688b5, 0x05fdf620, + 0xa66bde6c, 0x5f41f9e3, 0xfcd7d1af, 0xc31caf3a, 0x608a8776, + 0xbc8a5210, 0x1f1c7a5c, 0x20d704c9, 0x83412c85, 0x43a7a844, + 0xe0318008, 0xdffafe9d, 0x7c6cd6d1, 0xa06c03b7, 0x03fa2bfb, + 0x3c31556e, 0x9fa77d22, 0xf2269109, 0x51b0b945, 0x6e7bc7d0, + 0xcdedef9c, 0x11ed3afa, 0xb27b12b6, 0x8db06c23, 0x2e26446f, + 0xeec0c0ae, 0x4d56e8e2, 0x729d9677, 0xd10bbe3b, 0x0d0b6b5d, + 0xae9d4311, 0x91563d84, 0x32c015c8, 0xcbea3247, 0x687c1a0b, + 0x57b7649e, 0xf4214cd2, 0x282199b4, 0x8bb7b1f8, 0xb47ccf6d, + 0x17eae721, 0xd70c63e0, 0x749a4bac, 0x4b513539, 0xe8c71d75, + 0x34c7c813, 0x9751e05f, 0xa89a9eca, 0x0b0cb686, 0x81bfd795, + 0x2229ffd9, 0x1de2814c, 0xbe74a900, 0x62747c66, 0xc1e2542a, + 0xfe292abf, 0x5dbf02f3, 0x9d598632, 0x3ecfae7e, 0x0104d0eb, + 0xa292f8a7, 0x7e922dc1, 0xdd04058d, 0xe2cf7b18, 0x41595354, + 0xb87374db, 0x1be55c97, 0x242e2202, 0x87b80a4e, 0x5bb8df28, + 0xf82ef764, 0xc7e589f1, 0x6473a1bd, 0xa495257c, 0x07030d30, + 0x38c873a5, 0x9b5e5be9, 0x475e8e8f, 0xe4c8a6c3, 0xdb03d856, + 0x7895f01a}, + {0x00000000, 0x2a283862, 0x545070c4, 0x7e7848a6, 0xa8a0e188, + 0x8288d9ea, 0xfcf0914c, 0xd6d8a92e, 0x8a30c551, 0xa018fd33, + 0xde60b595, 0xf4488df7, 0x229024d9, 0x08b81cbb, 0x76c0541d, + 0x5ce86c7f, 0xcf108ce3, 0xe538b481, 0x9b40fc27, 0xb168c445, + 0x67b06d6b, 0x4d985509, 0x33e01daf, 0x19c825cd, 0x452049b2, + 0x6f0871d0, 0x11703976, 0x3b580114, 0xed80a83a, 0xc7a89058, + 0xb9d0d8fe, 0x93f8e09c, 0x45501f87, 0x6f7827e5, 0x11006f43, + 0x3b285721, 0xedf0fe0f, 0xc7d8c66d, 0xb9a08ecb, 0x9388b6a9, + 0xcf60dad6, 0xe548e2b4, 0x9b30aa12, 0xb1189270, 0x67c03b5e, + 0x4de8033c, 0x33904b9a, 0x19b873f8, 0x8a409364, 0xa068ab06, + 0xde10e3a0, 0xf438dbc2, 0x22e072ec, 0x08c84a8e, 0x76b00228, + 0x5c983a4a, 0x00705635, 0x2a586e57, 0x542026f1, 0x7e081e93, + 0xa8d0b7bd, 0x82f88fdf, 0xfc80c779, 0xd6a8ff1b, 0x8aa03f0e, + 0xa088076c, 0xdef04fca, 0xf4d877a8, 0x2200de86, 0x0828e6e4, + 0x7650ae42, 0x5c789620, 0x0090fa5f, 0x2ab8c23d, 0x54c08a9b, + 0x7ee8b2f9, 0xa8301bd7, 0x821823b5, 0xfc606b13, 0xd6485371, + 0x45b0b3ed, 0x6f988b8f, 0x11e0c329, 0x3bc8fb4b, 0xed105265, + 0xc7386a07, 0xb94022a1, 0x93681ac3, 0xcf8076bc, 0xe5a84ede, + 0x9bd00678, 0xb1f83e1a, 0x67209734, 0x4d08af56, 0x3370e7f0, + 0x1958df92, 0xcff02089, 0xe5d818eb, 0x9ba0504d, 0xb188682f, + 0x6750c101, 0x4d78f963, 0x3300b1c5, 0x192889a7, 0x45c0e5d8, + 0x6fe8ddba, 0x1190951c, 0x3bb8ad7e, 0xed600450, 0xc7483c32, + 0xb9307494, 0x93184cf6, 0x00e0ac6a, 0x2ac89408, 0x54b0dcae, + 0x7e98e4cc, 0xa8404de2, 0x82687580, 0xfc103d26, 0xd6380544, + 0x8ad0693b, 0xa0f85159, 0xde8019ff, 0xf4a8219d, 0x227088b3, + 0x0858b0d1, 0x7620f877, 0x5c08c015, 0xce31785d, 0xe419403f, + 0x9a610899, 0xb04930fb, 0x669199d5, 0x4cb9a1b7, 0x32c1e911, + 0x18e9d173, 0x4401bd0c, 0x6e29856e, 0x1051cdc8, 0x3a79f5aa, + 0xeca15c84, 0xc68964e6, 0xb8f12c40, 0x92d91422, 0x0121f4be, + 0x2b09ccdc, 0x5571847a, 0x7f59bc18, 0xa9811536, 0x83a92d54, + 0xfdd165f2, 0xd7f95d90, 0x8b1131ef, 0xa139098d, 0xdf41412b, + 0xf5697949, 0x23b1d067, 0x0999e805, 0x77e1a0a3, 0x5dc998c1, + 0x8b6167da, 0xa1495fb8, 0xdf31171e, 0xf5192f7c, 0x23c18652, + 0x09e9be30, 0x7791f696, 0x5db9cef4, 0x0151a28b, 0x2b799ae9, + 0x5501d24f, 0x7f29ea2d, 0xa9f14303, 0x83d97b61, 0xfda133c7, + 0xd7890ba5, 0x4471eb39, 0x6e59d35b, 0x10219bfd, 0x3a09a39f, + 0xecd10ab1, 0xc6f932d3, 0xb8817a75, 0x92a94217, 0xce412e68, + 0xe469160a, 0x9a115eac, 0xb03966ce, 0x66e1cfe0, 0x4cc9f782, + 0x32b1bf24, 0x18998746, 0x44914753, 0x6eb97f31, 0x10c13797, + 0x3ae90ff5, 0xec31a6db, 0xc6199eb9, 0xb861d61f, 0x9249ee7d, + 0xcea18202, 0xe489ba60, 0x9af1f2c6, 0xb0d9caa4, 0x6601638a, + 0x4c295be8, 0x3251134e, 0x18792b2c, 0x8b81cbb0, 0xa1a9f3d2, + 0xdfd1bb74, 0xf5f98316, 0x23212a38, 0x0909125a, 0x77715afc, + 0x5d59629e, 0x01b10ee1, 0x2b993683, 0x55e17e25, 0x7fc94647, + 0xa911ef69, 0x8339d70b, 0xfd419fad, 0xd769a7cf, 0x01c158d4, + 0x2be960b6, 0x55912810, 0x7fb91072, 0xa961b95c, 0x8349813e, + 0xfd31c998, 0xd719f1fa, 0x8bf19d85, 0xa1d9a5e7, 0xdfa1ed41, + 0xf589d523, 0x23517c0d, 0x0979446f, 0x77010cc9, 0x5d2934ab, + 0xced1d437, 0xe4f9ec55, 0x9a81a4f3, 0xb0a99c91, 0x667135bf, + 0x4c590ddd, 0x3221457b, 0x18097d19, 0x44e11166, 0x6ec92904, + 0x10b161a2, 0x3a9959c0, 0xec41f0ee, 0xc669c88c, 0xb811802a, + 0x9239b848}, + {0x00000000, 0x4713f6fb, 0x8e27edf6, 0xc9341b0d, 0xc73eddad, + 0x802d2b56, 0x4919305b, 0x0e0ac6a0, 0x550cbd1b, 0x121f4be0, + 0xdb2b50ed, 0x9c38a616, 0x923260b6, 0xd521964d, 0x1c158d40, + 0x5b067bbb, 0xaa197a36, 0xed0a8ccd, 0x243e97c0, 0x632d613b, + 0x6d27a79b, 0x2a345160, 0xe3004a6d, 0xa413bc96, 0xff15c72d, + 0xb80631d6, 0x71322adb, 0x3621dc20, 0x382b1a80, 0x7f38ec7b, + 0xb60cf776, 0xf11f018d, 0x8f43f22d, 0xc85004d6, 0x01641fdb, + 0x4677e920, 0x487d2f80, 0x0f6ed97b, 0xc65ac276, 0x8149348d, + 0xda4f4f36, 0x9d5cb9cd, 0x5468a2c0, 0x137b543b, 0x1d71929b, + 0x5a626460, 0x93567f6d, 0xd4458996, 0x255a881b, 0x62497ee0, + 0xab7d65ed, 0xec6e9316, 0xe26455b6, 0xa577a34d, 0x6c43b840, + 0x2b504ebb, 0x70563500, 0x3745c3fb, 0xfe71d8f6, 0xb9622e0d, + 0xb768e8ad, 0xf07b1e56, 0x394f055b, 0x7e5cf3a0, 0xc5f6e21b, + 0x82e514e0, 0x4bd10fed, 0x0cc2f916, 0x02c83fb6, 0x45dbc94d, + 0x8cefd240, 0xcbfc24bb, 0x90fa5f00, 0xd7e9a9fb, 0x1eddb2f6, + 0x59ce440d, 0x57c482ad, 0x10d77456, 0xd9e36f5b, 0x9ef099a0, + 0x6fef982d, 0x28fc6ed6, 0xe1c875db, 0xa6db8320, 0xa8d14580, + 0xefc2b37b, 0x26f6a876, 0x61e55e8d, 0x3ae32536, 0x7df0d3cd, + 0xb4c4c8c0, 0xf3d73e3b, 0xfdddf89b, 0xbace0e60, 0x73fa156d, + 0x34e9e396, 0x4ab51036, 0x0da6e6cd, 0xc492fdc0, 0x83810b3b, + 0x8d8bcd9b, 0xca983b60, 0x03ac206d, 0x44bfd696, 0x1fb9ad2d, + 0x58aa5bd6, 0x919e40db, 0xd68db620, 0xd8877080, 0x9f94867b, + 0x56a09d76, 0x11b36b8d, 0xe0ac6a00, 0xa7bf9cfb, 0x6e8b87f6, + 0x2998710d, 0x2792b7ad, 0x60814156, 0xa9b55a5b, 0xeea6aca0, + 0xb5a0d71b, 0xf2b321e0, 0x3b873aed, 0x7c94cc16, 0x729e0ab6, + 0x358dfc4d, 0xfcb9e740, 0xbbaa11bb, 0x509cc277, 0x178f348c, + 0xdebb2f81, 0x99a8d97a, 0x97a21fda, 0xd0b1e921, 0x1985f22c, + 0x5e9604d7, 0x05907f6c, 0x42838997, 0x8bb7929a, 0xcca46461, + 0xc2aea2c1, 0x85bd543a, 0x4c894f37, 0x0b9ab9cc, 0xfa85b841, + 0xbd964eba, 0x74a255b7, 0x33b1a34c, 0x3dbb65ec, 0x7aa89317, + 0xb39c881a, 0xf48f7ee1, 0xaf89055a, 0xe89af3a1, 0x21aee8ac, + 0x66bd1e57, 0x68b7d8f7, 0x2fa42e0c, 0xe6903501, 0xa183c3fa, + 0xdfdf305a, 0x98ccc6a1, 0x51f8ddac, 0x16eb2b57, 0x18e1edf7, + 0x5ff21b0c, 0x96c60001, 0xd1d5f6fa, 0x8ad38d41, 0xcdc07bba, + 0x04f460b7, 0x43e7964c, 0x4ded50ec, 0x0afea617, 0xc3cabd1a, + 0x84d94be1, 0x75c64a6c, 0x32d5bc97, 0xfbe1a79a, 0xbcf25161, + 0xb2f897c1, 0xf5eb613a, 0x3cdf7a37, 0x7bcc8ccc, 0x20caf777, + 0x67d9018c, 0xaeed1a81, 0xe9feec7a, 0xe7f42ada, 0xa0e7dc21, + 0x69d3c72c, 0x2ec031d7, 0x956a206c, 0xd279d697, 0x1b4dcd9a, + 0x5c5e3b61, 0x5254fdc1, 0x15470b3a, 0xdc731037, 0x9b60e6cc, + 0xc0669d77, 0x87756b8c, 0x4e417081, 0x0952867a, 0x075840da, + 0x404bb621, 0x897fad2c, 0xce6c5bd7, 0x3f735a5a, 0x7860aca1, + 0xb154b7ac, 0xf6474157, 0xf84d87f7, 0xbf5e710c, 0x766a6a01, + 0x31799cfa, 0x6a7fe741, 0x2d6c11ba, 0xe4580ab7, 0xa34bfc4c, + 0xad413aec, 0xea52cc17, 0x2366d71a, 0x647521e1, 0x1a29d241, + 0x5d3a24ba, 0x940e3fb7, 0xd31dc94c, 0xdd170fec, 0x9a04f917, + 0x5330e21a, 0x142314e1, 0x4f256f5a, 0x083699a1, 0xc10282ac, + 0x86117457, 0x881bb2f7, 0xcf08440c, 0x063c5f01, 0x412fa9fa, + 0xb030a877, 0xf7235e8c, 0x3e174581, 0x7904b37a, 0x770e75da, + 0x301d8321, 0xf929982c, 0xbe3a6ed7, 0xe53c156c, 0xa22fe397, + 0x6b1bf89a, 0x2c080e61, 0x2202c8c1, 0x65113e3a, 0xac252537, + 0xeb36d3cc}, + {0x00000000, 0xa13984ee, 0x99020f9d, 0x383b8b73, 0xe975197b, + 0x484c9d95, 0x707716e6, 0xd14e9208, 0x099b34b7, 0xa8a2b059, + 0x90993b2a, 0x31a0bfc4, 0xe0ee2dcc, 0x41d7a922, 0x79ec2251, + 0xd8d5a6bf, 0x1336696e, 0xb20fed80, 0x8a3466f3, 0x2b0de21d, + 0xfa437015, 0x5b7af4fb, 0x63417f88, 0xc278fb66, 0x1aad5dd9, + 0xbb94d937, 0x83af5244, 0x2296d6aa, 0xf3d844a2, 0x52e1c04c, + 0x6ada4b3f, 0xcbe3cfd1, 0x266cd2dc, 0x87555632, 0xbf6edd41, + 0x1e5759af, 0xcf19cba7, 0x6e204f49, 0x561bc43a, 0xf72240d4, + 0x2ff7e66b, 0x8ece6285, 0xb6f5e9f6, 0x17cc6d18, 0xc682ff10, + 0x67bb7bfe, 0x5f80f08d, 0xfeb97463, 0x355abbb2, 0x94633f5c, + 0xac58b42f, 0x0d6130c1, 0xdc2fa2c9, 0x7d162627, 0x452dad54, + 0xe41429ba, 0x3cc18f05, 0x9df80beb, 0xa5c38098, 0x04fa0476, + 0xd5b4967e, 0x748d1290, 0x4cb699e3, 0xed8f1d0d, 0x4cd9a5b8, + 0xede02156, 0xd5dbaa25, 0x74e22ecb, 0xa5acbcc3, 0x0495382d, + 0x3caeb35e, 0x9d9737b0, 0x4542910f, 0xe47b15e1, 0xdc409e92, + 0x7d791a7c, 0xac378874, 0x0d0e0c9a, 0x353587e9, 0x940c0307, + 0x5fefccd6, 0xfed64838, 0xc6edc34b, 0x67d447a5, 0xb69ad5ad, + 0x17a35143, 0x2f98da30, 0x8ea15ede, 0x5674f861, 0xf74d7c8f, + 0xcf76f7fc, 0x6e4f7312, 0xbf01e11a, 0x1e3865f4, 0x2603ee87, + 0x873a6a69, 0x6ab57764, 0xcb8cf38a, 0xf3b778f9, 0x528efc17, + 0x83c06e1f, 0x22f9eaf1, 0x1ac26182, 0xbbfbe56c, 0x632e43d3, + 0xc217c73d, 0xfa2c4c4e, 0x5b15c8a0, 0x8a5b5aa8, 0x2b62de46, + 0x13595535, 0xb260d1db, 0x79831e0a, 0xd8ba9ae4, 0xe0811197, + 0x41b89579, 0x90f60771, 0x31cf839f, 0x09f408ec, 0xa8cd8c02, + 0x70182abd, 0xd121ae53, 0xe91a2520, 0x4823a1ce, 0x996d33c6, + 0x3854b728, 0x006f3c5b, 0xa156b8b5, 0x99b34b70, 0x388acf9e, + 0x00b144ed, 0xa188c003, 0x70c6520b, 0xd1ffd6e5, 0xe9c45d96, + 0x48fdd978, 0x90287fc7, 0x3111fb29, 0x092a705a, 0xa813f4b4, + 0x795d66bc, 0xd864e252, 0xe05f6921, 0x4166edcf, 0x8a85221e, + 0x2bbca6f0, 0x13872d83, 0xb2bea96d, 0x63f03b65, 0xc2c9bf8b, + 0xfaf234f8, 0x5bcbb016, 0x831e16a9, 0x22279247, 0x1a1c1934, + 0xbb259dda, 0x6a6b0fd2, 0xcb528b3c, 0xf369004f, 0x525084a1, + 0xbfdf99ac, 0x1ee61d42, 0x26dd9631, 0x87e412df, 0x56aa80d7, + 0xf7930439, 0xcfa88f4a, 0x6e910ba4, 0xb644ad1b, 0x177d29f5, + 0x2f46a286, 0x8e7f2668, 0x5f31b460, 0xfe08308e, 0xc633bbfd, + 0x670a3f13, 0xace9f0c2, 0x0dd0742c, 0x35ebff5f, 0x94d27bb1, + 0x459ce9b9, 0xe4a56d57, 0xdc9ee624, 0x7da762ca, 0xa572c475, + 0x044b409b, 0x3c70cbe8, 0x9d494f06, 0x4c07dd0e, 0xed3e59e0, + 0xd505d293, 0x743c567d, 0xd56aeec8, 0x74536a26, 0x4c68e155, + 0xed5165bb, 0x3c1ff7b3, 0x9d26735d, 0xa51df82e, 0x04247cc0, + 0xdcf1da7f, 0x7dc85e91, 0x45f3d5e2, 0xe4ca510c, 0x3584c304, + 0x94bd47ea, 0xac86cc99, 0x0dbf4877, 0xc65c87a6, 0x67650348, + 0x5f5e883b, 0xfe670cd5, 0x2f299edd, 0x8e101a33, 0xb62b9140, + 0x171215ae, 0xcfc7b311, 0x6efe37ff, 0x56c5bc8c, 0xf7fc3862, + 0x26b2aa6a, 0x878b2e84, 0xbfb0a5f7, 0x1e892119, 0xf3063c14, + 0x523fb8fa, 0x6a043389, 0xcb3db767, 0x1a73256f, 0xbb4aa181, + 0x83712af2, 0x2248ae1c, 0xfa9d08a3, 0x5ba48c4d, 0x639f073e, + 0xc2a683d0, 0x13e811d8, 0xb2d19536, 0x8aea1e45, 0x2bd39aab, + 0xe030557a, 0x4109d194, 0x79325ae7, 0xd80bde09, 0x09454c01, + 0xa87cc8ef, 0x9047439c, 0x317ec772, 0xe9ab61cd, 0x4892e523, + 0x70a96e50, 0xd190eabe, 0x00de78b6, 0xa1e7fc58, 0x99dc772b, + 0x38e5f3c5}, + {0x00000000, 0xe81790a1, 0x0b5e2703, 0xe349b7a2, 0x16bc4e06, + 0xfeabdea7, 0x1de26905, 0xf5f5f9a4, 0x2d789c0c, 0xc56f0cad, + 0x2626bb0f, 0xce312bae, 0x3bc4d20a, 0xd3d342ab, 0x309af509, + 0xd88d65a8, 0x5af13818, 0xb2e6a8b9, 0x51af1f1b, 0xb9b88fba, + 0x4c4d761e, 0xa45ae6bf, 0x4713511d, 0xaf04c1bc, 0x7789a414, + 0x9f9e34b5, 0x7cd78317, 0x94c013b6, 0x6135ea12, 0x89227ab3, + 0x6a6bcd11, 0x827c5db0, 0xb5e27030, 0x5df5e091, 0xbebc5733, + 0x56abc792, 0xa35e3e36, 0x4b49ae97, 0xa8001935, 0x40178994, + 0x989aec3c, 0x708d7c9d, 0x93c4cb3f, 0x7bd35b9e, 0x8e26a23a, + 0x6631329b, 0x85788539, 0x6d6f1598, 0xef134828, 0x0704d889, + 0xe44d6f2b, 0x0c5aff8a, 0xf9af062e, 0x11b8968f, 0xf2f1212d, + 0x1ae6b18c, 0xc26bd424, 0x2a7c4485, 0xc935f327, 0x21226386, + 0xd4d79a22, 0x3cc00a83, 0xdf89bd21, 0x379e2d80, 0xb0b5e621, + 0x58a27680, 0xbbebc122, 0x53fc5183, 0xa609a827, 0x4e1e3886, + 0xad578f24, 0x45401f85, 0x9dcd7a2d, 0x75daea8c, 0x96935d2e, + 0x7e84cd8f, 0x8b71342b, 0x6366a48a, 0x802f1328, 0x68388389, + 0xea44de39, 0x02534e98, 0xe11af93a, 0x090d699b, 0xfcf8903f, + 0x14ef009e, 0xf7a6b73c, 0x1fb1279d, 0xc73c4235, 0x2f2bd294, + 0xcc626536, 0x2475f597, 0xd1800c33, 0x39979c92, 0xdade2b30, + 0x32c9bb91, 0x05579611, 0xed4006b0, 0x0e09b112, 0xe61e21b3, + 0x13ebd817, 0xfbfc48b6, 0x18b5ff14, 0xf0a26fb5, 0x282f0a1d, + 0xc0389abc, 0x23712d1e, 0xcb66bdbf, 0x3e93441b, 0xd684d4ba, + 0x35cd6318, 0xdddaf3b9, 0x5fa6ae09, 0xb7b13ea8, 0x54f8890a, + 0xbcef19ab, 0x491ae00f, 0xa10d70ae, 0x4244c70c, 0xaa5357ad, + 0x72de3205, 0x9ac9a2a4, 0x79801506, 0x919785a7, 0x64627c03, + 0x8c75eca2, 0x6f3c5b00, 0x872bcba1, 0xba1aca03, 0x520d5aa2, + 0xb144ed00, 0x59537da1, 0xaca68405, 0x44b114a4, 0xa7f8a306, + 0x4fef33a7, 0x9762560f, 0x7f75c6ae, 0x9c3c710c, 0x742be1ad, + 0x81de1809, 0x69c988a8, 0x8a803f0a, 0x6297afab, 0xe0ebf21b, + 0x08fc62ba, 0xebb5d518, 0x03a245b9, 0xf657bc1d, 0x1e402cbc, + 0xfd099b1e, 0x151e0bbf, 0xcd936e17, 0x2584feb6, 0xc6cd4914, + 0x2edad9b5, 0xdb2f2011, 0x3338b0b0, 0xd0710712, 0x386697b3, + 0x0ff8ba33, 0xe7ef2a92, 0x04a69d30, 0xecb10d91, 0x1944f435, + 0xf1536494, 0x121ad336, 0xfa0d4397, 0x2280263f, 0xca97b69e, + 0x29de013c, 0xc1c9919d, 0x343c6839, 0xdc2bf898, 0x3f624f3a, + 0xd775df9b, 0x5509822b, 0xbd1e128a, 0x5e57a528, 0xb6403589, + 0x43b5cc2d, 0xaba25c8c, 0x48ebeb2e, 0xa0fc7b8f, 0x78711e27, + 0x90668e86, 0x732f3924, 0x9b38a985, 0x6ecd5021, 0x86dac080, + 0x65937722, 0x8d84e783, 0x0aaf2c22, 0xe2b8bc83, 0x01f10b21, + 0xe9e69b80, 0x1c136224, 0xf404f285, 0x174d4527, 0xff5ad586, + 0x27d7b02e, 0xcfc0208f, 0x2c89972d, 0xc49e078c, 0x316bfe28, + 0xd97c6e89, 0x3a35d92b, 0xd222498a, 0x505e143a, 0xb849849b, + 0x5b003339, 0xb317a398, 0x46e25a3c, 0xaef5ca9d, 0x4dbc7d3f, + 0xa5abed9e, 0x7d268836, 0x95311897, 0x7678af35, 0x9e6f3f94, + 0x6b9ac630, 0x838d5691, 0x60c4e133, 0x88d37192, 0xbf4d5c12, + 0x575accb3, 0xb4137b11, 0x5c04ebb0, 0xa9f11214, 0x41e682b5, + 0xa2af3517, 0x4ab8a5b6, 0x9235c01e, 0x7a2250bf, 0x996be71d, + 0x717c77bc, 0x84898e18, 0x6c9e1eb9, 0x8fd7a91b, 0x67c039ba, + 0xe5bc640a, 0x0dabf4ab, 0xeee24309, 0x06f5d3a8, 0xf3002a0c, + 0x1b17baad, 0xf85e0d0f, 0x10499dae, 0xc8c4f806, 0x20d368a7, + 0xc39adf05, 0x2b8d4fa4, 0xde78b600, 0x366f26a1, 0xd5269103, + 0x3d3101a2}}; + +local const z_word_t FAR crc_braid_big_table[][256] = { + {0x0000000000000000, 0xa19017e800000000, 0x03275e0b00000000, + 0xa2b749e300000000, 0x064ebc1600000000, 0xa7deabfe00000000, + 0x0569e21d00000000, 0xa4f9f5f500000000, 0x0c9c782d00000000, + 0xad0c6fc500000000, 0x0fbb262600000000, 0xae2b31ce00000000, + 0x0ad2c43b00000000, 0xab42d3d300000000, 0x09f59a3000000000, + 0xa8658dd800000000, 0x1838f15a00000000, 0xb9a8e6b200000000, + 0x1b1faf5100000000, 0xba8fb8b900000000, 0x1e764d4c00000000, + 0xbfe65aa400000000, 0x1d51134700000000, 0xbcc104af00000000, + 0x14a4897700000000, 0xb5349e9f00000000, 0x1783d77c00000000, + 0xb613c09400000000, 0x12ea356100000000, 0xb37a228900000000, + 0x11cd6b6a00000000, 0xb05d7c8200000000, 0x3070e2b500000000, + 0x91e0f55d00000000, 0x3357bcbe00000000, 0x92c7ab5600000000, + 0x363e5ea300000000, 0x97ae494b00000000, 0x351900a800000000, + 0x9489174000000000, 0x3cec9a9800000000, 0x9d7c8d7000000000, + 0x3fcbc49300000000, 0x9e5bd37b00000000, 0x3aa2268e00000000, + 0x9b32316600000000, 0x3985788500000000, 0x98156f6d00000000, + 0x284813ef00000000, 0x89d8040700000000, 0x2b6f4de400000000, + 0x8aff5a0c00000000, 0x2e06aff900000000, 0x8f96b81100000000, + 0x2d21f1f200000000, 0x8cb1e61a00000000, 0x24d46bc200000000, + 0x85447c2a00000000, 0x27f335c900000000, 0x8663222100000000, + 0x229ad7d400000000, 0x830ac03c00000000, 0x21bd89df00000000, + 0x802d9e3700000000, 0x21e6b5b000000000, 0x8076a25800000000, + 0x22c1ebbb00000000, 0x8351fc5300000000, 0x27a809a600000000, + 0x86381e4e00000000, 0x248f57ad00000000, 0x851f404500000000, + 0x2d7acd9d00000000, 0x8ceada7500000000, 0x2e5d939600000000, + 0x8fcd847e00000000, 0x2b34718b00000000, 0x8aa4666300000000, + 0x28132f8000000000, 0x8983386800000000, 0x39de44ea00000000, + 0x984e530200000000, 0x3af91ae100000000, 0x9b690d0900000000, + 0x3f90f8fc00000000, 0x9e00ef1400000000, 0x3cb7a6f700000000, + 0x9d27b11f00000000, 0x35423cc700000000, 0x94d22b2f00000000, + 0x366562cc00000000, 0x97f5752400000000, 0x330c80d100000000, + 0x929c973900000000, 0x302bdeda00000000, 0x91bbc93200000000, + 0x1196570500000000, 0xb00640ed00000000, 0x12b1090e00000000, + 0xb3211ee600000000, 0x17d8eb1300000000, 0xb648fcfb00000000, + 0x14ffb51800000000, 0xb56fa2f000000000, 0x1d0a2f2800000000, + 0xbc9a38c000000000, 0x1e2d712300000000, 0xbfbd66cb00000000, + 0x1b44933e00000000, 0xbad484d600000000, 0x1863cd3500000000, + 0xb9f3dadd00000000, 0x09aea65f00000000, 0xa83eb1b700000000, + 0x0a89f85400000000, 0xab19efbc00000000, 0x0fe01a4900000000, + 0xae700da100000000, 0x0cc7444200000000, 0xad5753aa00000000, + 0x0532de7200000000, 0xa4a2c99a00000000, 0x0615807900000000, + 0xa785979100000000, 0x037c626400000000, 0xa2ec758c00000000, + 0x005b3c6f00000000, 0xa1cb2b8700000000, 0x03ca1aba00000000, + 0xa25a0d5200000000, 0x00ed44b100000000, 0xa17d535900000000, + 0x0584a6ac00000000, 0xa414b14400000000, 0x06a3f8a700000000, + 0xa733ef4f00000000, 0x0f56629700000000, 0xaec6757f00000000, + 0x0c713c9c00000000, 0xade12b7400000000, 0x0918de8100000000, + 0xa888c96900000000, 0x0a3f808a00000000, 0xabaf976200000000, + 0x1bf2ebe000000000, 0xba62fc0800000000, 0x18d5b5eb00000000, + 0xb945a20300000000, 0x1dbc57f600000000, 0xbc2c401e00000000, + 0x1e9b09fd00000000, 0xbf0b1e1500000000, 0x176e93cd00000000, + 0xb6fe842500000000, 0x1449cdc600000000, 0xb5d9da2e00000000, + 0x11202fdb00000000, 0xb0b0383300000000, 0x120771d000000000, + 0xb397663800000000, 0x33baf80f00000000, 0x922aefe700000000, + 0x309da60400000000, 0x910db1ec00000000, 0x35f4441900000000, + 0x946453f100000000, 0x36d31a1200000000, 0x97430dfa00000000, + 0x3f26802200000000, 0x9eb697ca00000000, 0x3c01de2900000000, + 0x9d91c9c100000000, 0x39683c3400000000, 0x98f82bdc00000000, + 0x3a4f623f00000000, 0x9bdf75d700000000, 0x2b82095500000000, + 0x8a121ebd00000000, 0x28a5575e00000000, 0x893540b600000000, + 0x2dccb54300000000, 0x8c5ca2ab00000000, 0x2eebeb4800000000, + 0x8f7bfca000000000, 0x271e717800000000, 0x868e669000000000, + 0x24392f7300000000, 0x85a9389b00000000, 0x2150cd6e00000000, + 0x80c0da8600000000, 0x2277936500000000, 0x83e7848d00000000, + 0x222caf0a00000000, 0x83bcb8e200000000, 0x210bf10100000000, + 0x809be6e900000000, 0x2462131c00000000, 0x85f204f400000000, + 0x27454d1700000000, 0x86d55aff00000000, 0x2eb0d72700000000, + 0x8f20c0cf00000000, 0x2d97892c00000000, 0x8c079ec400000000, + 0x28fe6b3100000000, 0x896e7cd900000000, 0x2bd9353a00000000, + 0x8a4922d200000000, 0x3a145e5000000000, 0x9b8449b800000000, + 0x3933005b00000000, 0x98a317b300000000, 0x3c5ae24600000000, + 0x9dcaf5ae00000000, 0x3f7dbc4d00000000, 0x9eedaba500000000, + 0x3688267d00000000, 0x9718319500000000, 0x35af787600000000, + 0x943f6f9e00000000, 0x30c69a6b00000000, 0x91568d8300000000, + 0x33e1c46000000000, 0x9271d38800000000, 0x125c4dbf00000000, + 0xb3cc5a5700000000, 0x117b13b400000000, 0xb0eb045c00000000, + 0x1412f1a900000000, 0xb582e64100000000, 0x1735afa200000000, + 0xb6a5b84a00000000, 0x1ec0359200000000, 0xbf50227a00000000, + 0x1de76b9900000000, 0xbc777c7100000000, 0x188e898400000000, + 0xb91e9e6c00000000, 0x1ba9d78f00000000, 0xba39c06700000000, + 0x0a64bce500000000, 0xabf4ab0d00000000, 0x0943e2ee00000000, + 0xa8d3f50600000000, 0x0c2a00f300000000, 0xadba171b00000000, + 0x0f0d5ef800000000, 0xae9d491000000000, 0x06f8c4c800000000, + 0xa768d32000000000, 0x05df9ac300000000, 0xa44f8d2b00000000, + 0x00b678de00000000, 0xa1266f3600000000, 0x039126d500000000, + 0xa201313d00000000}, + {0x0000000000000000, 0xee8439a100000000, 0x9d0f029900000000, + 0x738b3b3800000000, 0x7b1975e900000000, 0x959d4c4800000000, + 0xe616777000000000, 0x08924ed100000000, 0xb7349b0900000000, + 0x59b0a2a800000000, 0x2a3b999000000000, 0xc4bfa03100000000, + 0xcc2deee000000000, 0x22a9d74100000000, 0x5122ec7900000000, + 0xbfa6d5d800000000, 0x6e69361300000000, 0x80ed0fb200000000, + 0xf366348a00000000, 0x1de20d2b00000000, 0x157043fa00000000, + 0xfbf47a5b00000000, 0x887f416300000000, 0x66fb78c200000000, + 0xd95dad1a00000000, 0x37d994bb00000000, 0x4452af8300000000, + 0xaad6962200000000, 0xa244d8f300000000, 0x4cc0e15200000000, + 0x3f4bda6a00000000, 0xd1cfe3cb00000000, 0xdcd26c2600000000, + 0x3256558700000000, 0x41dd6ebf00000000, 0xaf59571e00000000, + 0xa7cb19cf00000000, 0x494f206e00000000, 0x3ac41b5600000000, + 0xd44022f700000000, 0x6be6f72f00000000, 0x8562ce8e00000000, + 0xf6e9f5b600000000, 0x186dcc1700000000, 0x10ff82c600000000, + 0xfe7bbb6700000000, 0x8df0805f00000000, 0x6374b9fe00000000, + 0xb2bb5a3500000000, 0x5c3f639400000000, 0x2fb458ac00000000, + 0xc130610d00000000, 0xc9a22fdc00000000, 0x2726167d00000000, + 0x54ad2d4500000000, 0xba2914e400000000, 0x058fc13c00000000, + 0xeb0bf89d00000000, 0x9880c3a500000000, 0x7604fa0400000000, + 0x7e96b4d500000000, 0x90128d7400000000, 0xe399b64c00000000, + 0x0d1d8fed00000000, 0xb8a5d94c00000000, 0x5621e0ed00000000, + 0x25aadbd500000000, 0xcb2ee27400000000, 0xc3bcaca500000000, + 0x2d38950400000000, 0x5eb3ae3c00000000, 0xb037979d00000000, + 0x0f91424500000000, 0xe1157be400000000, 0x929e40dc00000000, + 0x7c1a797d00000000, 0x748837ac00000000, 0x9a0c0e0d00000000, + 0xe987353500000000, 0x07030c9400000000, 0xd6ccef5f00000000, + 0x3848d6fe00000000, 0x4bc3edc600000000, 0xa547d46700000000, + 0xadd59ab600000000, 0x4351a31700000000, 0x30da982f00000000, + 0xde5ea18e00000000, 0x61f8745600000000, 0x8f7c4df700000000, + 0xfcf776cf00000000, 0x12734f6e00000000, 0x1ae101bf00000000, + 0xf465381e00000000, 0x87ee032600000000, 0x696a3a8700000000, + 0x6477b56a00000000, 0x8af38ccb00000000, 0xf978b7f300000000, + 0x17fc8e5200000000, 0x1f6ec08300000000, 0xf1eaf92200000000, + 0x8261c21a00000000, 0x6ce5fbbb00000000, 0xd3432e6300000000, + 0x3dc717c200000000, 0x4e4c2cfa00000000, 0xa0c8155b00000000, + 0xa85a5b8a00000000, 0x46de622b00000000, 0x3555591300000000, + 0xdbd160b200000000, 0x0a1e837900000000, 0xe49abad800000000, + 0x971181e000000000, 0x7995b84100000000, 0x7107f69000000000, + 0x9f83cf3100000000, 0xec08f40900000000, 0x028ccda800000000, + 0xbd2a187000000000, 0x53ae21d100000000, 0x20251ae900000000, + 0xcea1234800000000, 0xc6336d9900000000, 0x28b7543800000000, + 0x5b3c6f0000000000, 0xb5b856a100000000, 0x704bb39900000000, + 0x9ecf8a3800000000, 0xed44b10000000000, 0x03c088a100000000, + 0x0b52c67000000000, 0xe5d6ffd100000000, 0x965dc4e900000000, + 0x78d9fd4800000000, 0xc77f289000000000, 0x29fb113100000000, + 0x5a702a0900000000, 0xb4f413a800000000, 0xbc665d7900000000, + 0x52e264d800000000, 0x21695fe000000000, 0xcfed664100000000, + 0x1e22858a00000000, 0xf0a6bc2b00000000, 0x832d871300000000, + 0x6da9beb200000000, 0x653bf06300000000, 0x8bbfc9c200000000, + 0xf834f2fa00000000, 0x16b0cb5b00000000, 0xa9161e8300000000, + 0x4792272200000000, 0x34191c1a00000000, 0xda9d25bb00000000, + 0xd20f6b6a00000000, 0x3c8b52cb00000000, 0x4f0069f300000000, + 0xa184505200000000, 0xac99dfbf00000000, 0x421de61e00000000, + 0x3196dd2600000000, 0xdf12e48700000000, 0xd780aa5600000000, + 0x390493f700000000, 0x4a8fa8cf00000000, 0xa40b916e00000000, + 0x1bad44b600000000, 0xf5297d1700000000, 0x86a2462f00000000, + 0x68267f8e00000000, 0x60b4315f00000000, 0x8e3008fe00000000, + 0xfdbb33c600000000, 0x133f0a6700000000, 0xc2f0e9ac00000000, + 0x2c74d00d00000000, 0x5fffeb3500000000, 0xb17bd29400000000, + 0xb9e99c4500000000, 0x576da5e400000000, 0x24e69edc00000000, + 0xca62a77d00000000, 0x75c472a500000000, 0x9b404b0400000000, + 0xe8cb703c00000000, 0x064f499d00000000, 0x0edd074c00000000, + 0xe0593eed00000000, 0x93d205d500000000, 0x7d563c7400000000, + 0xc8ee6ad500000000, 0x266a537400000000, 0x55e1684c00000000, + 0xbb6551ed00000000, 0xb3f71f3c00000000, 0x5d73269d00000000, + 0x2ef81da500000000, 0xc07c240400000000, 0x7fdaf1dc00000000, + 0x915ec87d00000000, 0xe2d5f34500000000, 0x0c51cae400000000, + 0x04c3843500000000, 0xea47bd9400000000, 0x99cc86ac00000000, + 0x7748bf0d00000000, 0xa6875cc600000000, 0x4803656700000000, + 0x3b885e5f00000000, 0xd50c67fe00000000, 0xdd9e292f00000000, + 0x331a108e00000000, 0x40912bb600000000, 0xae15121700000000, + 0x11b3c7cf00000000, 0xff37fe6e00000000, 0x8cbcc55600000000, + 0x6238fcf700000000, 0x6aaab22600000000, 0x842e8b8700000000, + 0xf7a5b0bf00000000, 0x1921891e00000000, 0x143c06f300000000, + 0xfab83f5200000000, 0x8933046a00000000, 0x67b73dcb00000000, + 0x6f25731a00000000, 0x81a14abb00000000, 0xf22a718300000000, + 0x1cae482200000000, 0xa3089dfa00000000, 0x4d8ca45b00000000, + 0x3e079f6300000000, 0xd083a6c200000000, 0xd811e81300000000, + 0x3695d1b200000000, 0x451eea8a00000000, 0xab9ad32b00000000, + 0x7a5530e000000000, 0x94d1094100000000, 0xe75a327900000000, + 0x09de0bd800000000, 0x014c450900000000, 0xefc87ca800000000, + 0x9c43479000000000, 0x72c77e3100000000, 0xcd61abe900000000, + 0x23e5924800000000, 0x506ea97000000000, 0xbeea90d100000000, + 0xb678de0000000000, 0x58fce7a100000000, 0x2b77dc9900000000, + 0xc5f3e53800000000}, + {0x0000000000000000, 0xfbf6134700000000, 0xf6ed278e00000000, + 0x0d1b34c900000000, 0xaddd3ec700000000, 0x562b2d8000000000, + 0x5b30194900000000, 0xa0c60a0e00000000, 0x1bbd0c5500000000, + 0xe04b1f1200000000, 0xed502bdb00000000, 0x16a6389c00000000, + 0xb660329200000000, 0x4d9621d500000000, 0x408d151c00000000, + 0xbb7b065b00000000, 0x367a19aa00000000, 0xcd8c0aed00000000, + 0xc0973e2400000000, 0x3b612d6300000000, 0x9ba7276d00000000, + 0x6051342a00000000, 0x6d4a00e300000000, 0x96bc13a400000000, + 0x2dc715ff00000000, 0xd63106b800000000, 0xdb2a327100000000, + 0x20dc213600000000, 0x801a2b3800000000, 0x7bec387f00000000, + 0x76f70cb600000000, 0x8d011ff100000000, 0x2df2438f00000000, + 0xd60450c800000000, 0xdb1f640100000000, 0x20e9774600000000, + 0x802f7d4800000000, 0x7bd96e0f00000000, 0x76c25ac600000000, + 0x8d34498100000000, 0x364f4fda00000000, 0xcdb95c9d00000000, + 0xc0a2685400000000, 0x3b547b1300000000, 0x9b92711d00000000, + 0x6064625a00000000, 0x6d7f569300000000, 0x968945d400000000, + 0x1b885a2500000000, 0xe07e496200000000, 0xed657dab00000000, + 0x16936eec00000000, 0xb65564e200000000, 0x4da377a500000000, + 0x40b8436c00000000, 0xbb4e502b00000000, 0x0035567000000000, + 0xfbc3453700000000, 0xf6d871fe00000000, 0x0d2e62b900000000, + 0xade868b700000000, 0x561e7bf000000000, 0x5b054f3900000000, + 0xa0f35c7e00000000, 0x1be2f6c500000000, 0xe014e58200000000, + 0xed0fd14b00000000, 0x16f9c20c00000000, 0xb63fc80200000000, + 0x4dc9db4500000000, 0x40d2ef8c00000000, 0xbb24fccb00000000, + 0x005ffa9000000000, 0xfba9e9d700000000, 0xf6b2dd1e00000000, + 0x0d44ce5900000000, 0xad82c45700000000, 0x5674d71000000000, + 0x5b6fe3d900000000, 0xa099f09e00000000, 0x2d98ef6f00000000, + 0xd66efc2800000000, 0xdb75c8e100000000, 0x2083dba600000000, + 0x8045d1a800000000, 0x7bb3c2ef00000000, 0x76a8f62600000000, + 0x8d5ee56100000000, 0x3625e33a00000000, 0xcdd3f07d00000000, + 0xc0c8c4b400000000, 0x3b3ed7f300000000, 0x9bf8ddfd00000000, + 0x600eceba00000000, 0x6d15fa7300000000, 0x96e3e93400000000, + 0x3610b54a00000000, 0xcde6a60d00000000, 0xc0fd92c400000000, + 0x3b0b818300000000, 0x9bcd8b8d00000000, 0x603b98ca00000000, + 0x6d20ac0300000000, 0x96d6bf4400000000, 0x2dadb91f00000000, + 0xd65baa5800000000, 0xdb409e9100000000, 0x20b68dd600000000, + 0x807087d800000000, 0x7b86949f00000000, 0x769da05600000000, + 0x8d6bb31100000000, 0x006aace000000000, 0xfb9cbfa700000000, + 0xf6878b6e00000000, 0x0d71982900000000, 0xadb7922700000000, + 0x5641816000000000, 0x5b5ab5a900000000, 0xa0aca6ee00000000, + 0x1bd7a0b500000000, 0xe021b3f200000000, 0xed3a873b00000000, + 0x16cc947c00000000, 0xb60a9e7200000000, 0x4dfc8d3500000000, + 0x40e7b9fc00000000, 0xbb11aabb00000000, 0x77c29c5000000000, + 0x8c348f1700000000, 0x812fbbde00000000, 0x7ad9a89900000000, + 0xda1fa29700000000, 0x21e9b1d000000000, 0x2cf2851900000000, + 0xd704965e00000000, 0x6c7f900500000000, 0x9789834200000000, + 0x9a92b78b00000000, 0x6164a4cc00000000, 0xc1a2aec200000000, + 0x3a54bd8500000000, 0x374f894c00000000, 0xccb99a0b00000000, + 0x41b885fa00000000, 0xba4e96bd00000000, 0xb755a27400000000, + 0x4ca3b13300000000, 0xec65bb3d00000000, 0x1793a87a00000000, + 0x1a889cb300000000, 0xe17e8ff400000000, 0x5a0589af00000000, + 0xa1f39ae800000000, 0xace8ae2100000000, 0x571ebd6600000000, + 0xf7d8b76800000000, 0x0c2ea42f00000000, 0x013590e600000000, + 0xfac383a100000000, 0x5a30dfdf00000000, 0xa1c6cc9800000000, + 0xacddf85100000000, 0x572beb1600000000, 0xf7ede11800000000, + 0x0c1bf25f00000000, 0x0100c69600000000, 0xfaf6d5d100000000, + 0x418dd38a00000000, 0xba7bc0cd00000000, 0xb760f40400000000, + 0x4c96e74300000000, 0xec50ed4d00000000, 0x17a6fe0a00000000, + 0x1abdcac300000000, 0xe14bd98400000000, 0x6c4ac67500000000, + 0x97bcd53200000000, 0x9aa7e1fb00000000, 0x6151f2bc00000000, + 0xc197f8b200000000, 0x3a61ebf500000000, 0x377adf3c00000000, + 0xcc8ccc7b00000000, 0x77f7ca2000000000, 0x8c01d96700000000, + 0x811aedae00000000, 0x7aecfee900000000, 0xda2af4e700000000, + 0x21dce7a000000000, 0x2cc7d36900000000, 0xd731c02e00000000, + 0x6c206a9500000000, 0x97d679d200000000, 0x9acd4d1b00000000, + 0x613b5e5c00000000, 0xc1fd545200000000, 0x3a0b471500000000, + 0x371073dc00000000, 0xcce6609b00000000, 0x779d66c000000000, + 0x8c6b758700000000, 0x8170414e00000000, 0x7a86520900000000, + 0xda40580700000000, 0x21b64b4000000000, 0x2cad7f8900000000, + 0xd75b6cce00000000, 0x5a5a733f00000000, 0xa1ac607800000000, + 0xacb754b100000000, 0x574147f600000000, 0xf7874df800000000, + 0x0c715ebf00000000, 0x016a6a7600000000, 0xfa9c793100000000, + 0x41e77f6a00000000, 0xba116c2d00000000, 0xb70a58e400000000, + 0x4cfc4ba300000000, 0xec3a41ad00000000, 0x17cc52ea00000000, + 0x1ad7662300000000, 0xe121756400000000, 0x41d2291a00000000, + 0xba243a5d00000000, 0xb73f0e9400000000, 0x4cc91dd300000000, + 0xec0f17dd00000000, 0x17f9049a00000000, 0x1ae2305300000000, + 0xe114231400000000, 0x5a6f254f00000000, 0xa199360800000000, + 0xac8202c100000000, 0x5774118600000000, 0xf7b21b8800000000, + 0x0c4408cf00000000, 0x015f3c0600000000, 0xfaa92f4100000000, + 0x77a830b000000000, 0x8c5e23f700000000, 0x8145173e00000000, + 0x7ab3047900000000, 0xda750e7700000000, 0x21831d3000000000, + 0x2c9829f900000000, 0xd76e3abe00000000, 0x6c153ce500000000, + 0x97e32fa200000000, 0x9af81b6b00000000, 0x610e082c00000000, + 0xc1c8022200000000, 0x3a3e116500000000, 0x372525ac00000000, + 0xccd336eb00000000}, + {0x0000000000000000, 0x6238282a00000000, 0xc470505400000000, + 0xa648787e00000000, 0x88e1a0a800000000, 0xead9888200000000, + 0x4c91f0fc00000000, 0x2ea9d8d600000000, 0x51c5308a00000000, + 0x33fd18a000000000, 0x95b560de00000000, 0xf78d48f400000000, + 0xd924902200000000, 0xbb1cb80800000000, 0x1d54c07600000000, + 0x7f6ce85c00000000, 0xe38c10cf00000000, 0x81b438e500000000, + 0x27fc409b00000000, 0x45c468b100000000, 0x6b6db06700000000, + 0x0955984d00000000, 0xaf1de03300000000, 0xcd25c81900000000, + 0xb249204500000000, 0xd071086f00000000, 0x7639701100000000, + 0x1401583b00000000, 0x3aa880ed00000000, 0x5890a8c700000000, + 0xfed8d0b900000000, 0x9ce0f89300000000, 0x871f504500000000, + 0xe527786f00000000, 0x436f001100000000, 0x2157283b00000000, + 0x0ffef0ed00000000, 0x6dc6d8c700000000, 0xcb8ea0b900000000, + 0xa9b6889300000000, 0xd6da60cf00000000, 0xb4e248e500000000, + 0x12aa309b00000000, 0x709218b100000000, 0x5e3bc06700000000, + 0x3c03e84d00000000, 0x9a4b903300000000, 0xf873b81900000000, + 0x6493408a00000000, 0x06ab68a000000000, 0xa0e310de00000000, + 0xc2db38f400000000, 0xec72e02200000000, 0x8e4ac80800000000, + 0x2802b07600000000, 0x4a3a985c00000000, 0x3556700000000000, + 0x576e582a00000000, 0xf126205400000000, 0x931e087e00000000, + 0xbdb7d0a800000000, 0xdf8ff88200000000, 0x79c780fc00000000, + 0x1bffa8d600000000, 0x0e3fa08a00000000, 0x6c0788a000000000, + 0xca4ff0de00000000, 0xa877d8f400000000, 0x86de002200000000, + 0xe4e6280800000000, 0x42ae507600000000, 0x2096785c00000000, + 0x5ffa900000000000, 0x3dc2b82a00000000, 0x9b8ac05400000000, + 0xf9b2e87e00000000, 0xd71b30a800000000, 0xb523188200000000, + 0x136b60fc00000000, 0x715348d600000000, 0xedb3b04500000000, + 0x8f8b986f00000000, 0x29c3e01100000000, 0x4bfbc83b00000000, + 0x655210ed00000000, 0x076a38c700000000, 0xa12240b900000000, + 0xc31a689300000000, 0xbc7680cf00000000, 0xde4ea8e500000000, + 0x7806d09b00000000, 0x1a3ef8b100000000, 0x3497206700000000, + 0x56af084d00000000, 0xf0e7703300000000, 0x92df581900000000, + 0x8920f0cf00000000, 0xeb18d8e500000000, 0x4d50a09b00000000, + 0x2f6888b100000000, 0x01c1506700000000, 0x63f9784d00000000, + 0xc5b1003300000000, 0xa789281900000000, 0xd8e5c04500000000, + 0xbadde86f00000000, 0x1c95901100000000, 0x7eadb83b00000000, + 0x500460ed00000000, 0x323c48c700000000, 0x947430b900000000, + 0xf64c189300000000, 0x6aace00000000000, 0x0894c82a00000000, + 0xaedcb05400000000, 0xcce4987e00000000, 0xe24d40a800000000, + 0x8075688200000000, 0x263d10fc00000000, 0x440538d600000000, + 0x3b69d08a00000000, 0x5951f8a000000000, 0xff1980de00000000, + 0x9d21a8f400000000, 0xb388702200000000, 0xd1b0580800000000, + 0x77f8207600000000, 0x15c0085c00000000, 0x5d7831ce00000000, + 0x3f4019e400000000, 0x9908619a00000000, 0xfb3049b000000000, + 0xd599916600000000, 0xb7a1b94c00000000, 0x11e9c13200000000, + 0x73d1e91800000000, 0x0cbd014400000000, 0x6e85296e00000000, + 0xc8cd511000000000, 0xaaf5793a00000000, 0x845ca1ec00000000, + 0xe66489c600000000, 0x402cf1b800000000, 0x2214d99200000000, + 0xbef4210100000000, 0xdccc092b00000000, 0x7a84715500000000, + 0x18bc597f00000000, 0x361581a900000000, 0x542da98300000000, + 0xf265d1fd00000000, 0x905df9d700000000, 0xef31118b00000000, + 0x8d0939a100000000, 0x2b4141df00000000, 0x497969f500000000, + 0x67d0b12300000000, 0x05e8990900000000, 0xa3a0e17700000000, + 0xc198c95d00000000, 0xda67618b00000000, 0xb85f49a100000000, + 0x1e1731df00000000, 0x7c2f19f500000000, 0x5286c12300000000, + 0x30bee90900000000, 0x96f6917700000000, 0xf4ceb95d00000000, + 0x8ba2510100000000, 0xe99a792b00000000, 0x4fd2015500000000, + 0x2dea297f00000000, 0x0343f1a900000000, 0x617bd98300000000, + 0xc733a1fd00000000, 0xa50b89d700000000, 0x39eb714400000000, + 0x5bd3596e00000000, 0xfd9b211000000000, 0x9fa3093a00000000, + 0xb10ad1ec00000000, 0xd332f9c600000000, 0x757a81b800000000, + 0x1742a99200000000, 0x682e41ce00000000, 0x0a1669e400000000, + 0xac5e119a00000000, 0xce6639b000000000, 0xe0cfe16600000000, + 0x82f7c94c00000000, 0x24bfb13200000000, 0x4687991800000000, + 0x5347914400000000, 0x317fb96e00000000, 0x9737c11000000000, + 0xf50fe93a00000000, 0xdba631ec00000000, 0xb99e19c600000000, + 0x1fd661b800000000, 0x7dee499200000000, 0x0282a1ce00000000, + 0x60ba89e400000000, 0xc6f2f19a00000000, 0xa4cad9b000000000, + 0x8a63016600000000, 0xe85b294c00000000, 0x4e13513200000000, + 0x2c2b791800000000, 0xb0cb818b00000000, 0xd2f3a9a100000000, + 0x74bbd1df00000000, 0x1683f9f500000000, 0x382a212300000000, + 0x5a12090900000000, 0xfc5a717700000000, 0x9e62595d00000000, + 0xe10eb10100000000, 0x8336992b00000000, 0x257ee15500000000, + 0x4746c97f00000000, 0x69ef11a900000000, 0x0bd7398300000000, + 0xad9f41fd00000000, 0xcfa769d700000000, 0xd458c10100000000, + 0xb660e92b00000000, 0x1028915500000000, 0x7210b97f00000000, + 0x5cb961a900000000, 0x3e81498300000000, 0x98c931fd00000000, + 0xfaf119d700000000, 0x859df18b00000000, 0xe7a5d9a100000000, + 0x41eda1df00000000, 0x23d589f500000000, 0x0d7c512300000000, + 0x6f44790900000000, 0xc90c017700000000, 0xab34295d00000000, + 0x37d4d1ce00000000, 0x55ecf9e400000000, 0xf3a4819a00000000, + 0x919ca9b000000000, 0xbf35716600000000, 0xdd0d594c00000000, + 0x7b45213200000000, 0x197d091800000000, 0x6611e14400000000, + 0x0429c96e00000000, 0xa261b11000000000, 0xc059993a00000000, + 0xeef041ec00000000, 0x8cc869c600000000, 0x2a8011b800000000, + 0x48b8399200000000}, + {0x0000000000000000, 0x4c2896a300000000, 0xd9565d9c00000000, + 0x957ecb3f00000000, 0xf3abcbe300000000, 0xbf835d4000000000, + 0x2afd967f00000000, 0x66d500dc00000000, 0xa751e61c00000000, + 0xeb7970bf00000000, 0x7e07bb8000000000, 0x322f2d2300000000, + 0x54fa2dff00000000, 0x18d2bb5c00000000, 0x8dac706300000000, + 0xc184e6c000000000, 0x4ea3cc3900000000, 0x028b5a9a00000000, + 0x97f591a500000000, 0xdbdd070600000000, 0xbd0807da00000000, + 0xf120917900000000, 0x645e5a4600000000, 0x2876cce500000000, + 0xe9f22a2500000000, 0xa5dabc8600000000, 0x30a477b900000000, + 0x7c8ce11a00000000, 0x1a59e1c600000000, 0x5671776500000000, + 0xc30fbc5a00000000, 0x8f272af900000000, 0x9c46997300000000, + 0xd06e0fd000000000, 0x4510c4ef00000000, 0x0938524c00000000, + 0x6fed529000000000, 0x23c5c43300000000, 0xb6bb0f0c00000000, + 0xfa9399af00000000, 0x3b177f6f00000000, 0x773fe9cc00000000, + 0xe24122f300000000, 0xae69b45000000000, 0xc8bcb48c00000000, + 0x8494222f00000000, 0x11eae91000000000, 0x5dc27fb300000000, + 0xd2e5554a00000000, 0x9ecdc3e900000000, 0x0bb308d600000000, + 0x479b9e7500000000, 0x214e9ea900000000, 0x6d66080a00000000, + 0xf818c33500000000, 0xb430559600000000, 0x75b4b35600000000, + 0x399c25f500000000, 0xace2eeca00000000, 0xe0ca786900000000, + 0x861f78b500000000, 0xca37ee1600000000, 0x5f49252900000000, + 0x1361b38a00000000, 0x388d32e700000000, 0x74a5a44400000000, + 0xe1db6f7b00000000, 0xadf3f9d800000000, 0xcb26f90400000000, + 0x870e6fa700000000, 0x1270a49800000000, 0x5e58323b00000000, + 0x9fdcd4fb00000000, 0xd3f4425800000000, 0x468a896700000000, + 0x0aa21fc400000000, 0x6c771f1800000000, 0x205f89bb00000000, + 0xb521428400000000, 0xf909d42700000000, 0x762efede00000000, + 0x3a06687d00000000, 0xaf78a34200000000, 0xe35035e100000000, + 0x8585353d00000000, 0xc9ada39e00000000, 0x5cd368a100000000, + 0x10fbfe0200000000, 0xd17f18c200000000, 0x9d578e6100000000, + 0x0829455e00000000, 0x4401d3fd00000000, 0x22d4d32100000000, + 0x6efc458200000000, 0xfb828ebd00000000, 0xb7aa181e00000000, + 0xa4cbab9400000000, 0xe8e33d3700000000, 0x7d9df60800000000, + 0x31b560ab00000000, 0x5760607700000000, 0x1b48f6d400000000, + 0x8e363deb00000000, 0xc21eab4800000000, 0x039a4d8800000000, + 0x4fb2db2b00000000, 0xdacc101400000000, 0x96e486b700000000, + 0xf031866b00000000, 0xbc1910c800000000, 0x2967dbf700000000, + 0x654f4d5400000000, 0xea6867ad00000000, 0xa640f10e00000000, + 0x333e3a3100000000, 0x7f16ac9200000000, 0x19c3ac4e00000000, + 0x55eb3aed00000000, 0xc095f1d200000000, 0x8cbd677100000000, + 0x4d3981b100000000, 0x0111171200000000, 0x946fdc2d00000000, + 0xd8474a8e00000000, 0xbe924a5200000000, 0xf2badcf100000000, + 0x67c417ce00000000, 0x2bec816d00000000, 0x311c141500000000, + 0x7d3482b600000000, 0xe84a498900000000, 0xa462df2a00000000, + 0xc2b7dff600000000, 0x8e9f495500000000, 0x1be1826a00000000, + 0x57c914c900000000, 0x964df20900000000, 0xda6564aa00000000, + 0x4f1baf9500000000, 0x0333393600000000, 0x65e639ea00000000, + 0x29ceaf4900000000, 0xbcb0647600000000, 0xf098f2d500000000, + 0x7fbfd82c00000000, 0x33974e8f00000000, 0xa6e985b000000000, + 0xeac1131300000000, 0x8c1413cf00000000, 0xc03c856c00000000, + 0x55424e5300000000, 0x196ad8f000000000, 0xd8ee3e3000000000, + 0x94c6a89300000000, 0x01b863ac00000000, 0x4d90f50f00000000, + 0x2b45f5d300000000, 0x676d637000000000, 0xf213a84f00000000, + 0xbe3b3eec00000000, 0xad5a8d6600000000, 0xe1721bc500000000, + 0x740cd0fa00000000, 0x3824465900000000, 0x5ef1468500000000, + 0x12d9d02600000000, 0x87a71b1900000000, 0xcb8f8dba00000000, + 0x0a0b6b7a00000000, 0x4623fdd900000000, 0xd35d36e600000000, + 0x9f75a04500000000, 0xf9a0a09900000000, 0xb588363a00000000, + 0x20f6fd0500000000, 0x6cde6ba600000000, 0xe3f9415f00000000, + 0xafd1d7fc00000000, 0x3aaf1cc300000000, 0x76878a6000000000, + 0x10528abc00000000, 0x5c7a1c1f00000000, 0xc904d72000000000, + 0x852c418300000000, 0x44a8a74300000000, 0x088031e000000000, + 0x9dfefadf00000000, 0xd1d66c7c00000000, 0xb7036ca000000000, + 0xfb2bfa0300000000, 0x6e55313c00000000, 0x227da79f00000000, + 0x099126f200000000, 0x45b9b05100000000, 0xd0c77b6e00000000, + 0x9cefedcd00000000, 0xfa3aed1100000000, 0xb6127bb200000000, + 0x236cb08d00000000, 0x6f44262e00000000, 0xaec0c0ee00000000, + 0xe2e8564d00000000, 0x77969d7200000000, 0x3bbe0bd100000000, + 0x5d6b0b0d00000000, 0x11439dae00000000, 0x843d569100000000, + 0xc815c03200000000, 0x4732eacb00000000, 0x0b1a7c6800000000, + 0x9e64b75700000000, 0xd24c21f400000000, 0xb499212800000000, + 0xf8b1b78b00000000, 0x6dcf7cb400000000, 0x21e7ea1700000000, + 0xe0630cd700000000, 0xac4b9a7400000000, 0x3935514b00000000, + 0x751dc7e800000000, 0x13c8c73400000000, 0x5fe0519700000000, + 0xca9e9aa800000000, 0x86b60c0b00000000, 0x95d7bf8100000000, + 0xd9ff292200000000, 0x4c81e21d00000000, 0x00a974be00000000, + 0x667c746200000000, 0x2a54e2c100000000, 0xbf2a29fe00000000, + 0xf302bf5d00000000, 0x3286599d00000000, 0x7eaecf3e00000000, + 0xebd0040100000000, 0xa7f892a200000000, 0xc12d927e00000000, + 0x8d0504dd00000000, 0x187bcfe200000000, 0x5453594100000000, + 0xdb7473b800000000, 0x975ce51b00000000, 0x02222e2400000000, + 0x4e0ab88700000000, 0x28dfb85b00000000, 0x64f72ef800000000, + 0xf189e5c700000000, 0xbda1736400000000, 0x7c2595a400000000, + 0x300d030700000000, 0xa573c83800000000, 0xe95b5e9b00000000, + 0x8f8e5e4700000000, 0xc3a6c8e400000000, 0x56d803db00000000, + 0x1af0957800000000}, + {0x0000000000000000, 0x939bc97f00000000, 0x263793ff00000000, + 0xb5ac5a8000000000, 0x0d68572400000000, 0x9ef39e5b00000000, + 0x2b5fc4db00000000, 0xb8c40da400000000, 0x1ad0ae4800000000, + 0x894b673700000000, 0x3ce73db700000000, 0xaf7cf4c800000000, + 0x17b8f96c00000000, 0x8423301300000000, 0x318f6a9300000000, + 0xa214a3ec00000000, 0x34a05d9100000000, 0xa73b94ee00000000, + 0x1297ce6e00000000, 0x810c071100000000, 0x39c80ab500000000, + 0xaa53c3ca00000000, 0x1fff994a00000000, 0x8c64503500000000, + 0x2e70f3d900000000, 0xbdeb3aa600000000, 0x0847602600000000, + 0x9bdca95900000000, 0x2318a4fd00000000, 0xb0836d8200000000, + 0x052f370200000000, 0x96b4fe7d00000000, 0x2946caf900000000, + 0xbadd038600000000, 0x0f71590600000000, 0x9cea907900000000, + 0x242e9ddd00000000, 0xb7b554a200000000, 0x02190e2200000000, + 0x9182c75d00000000, 0x339664b100000000, 0xa00dadce00000000, + 0x15a1f74e00000000, 0x863a3e3100000000, 0x3efe339500000000, + 0xad65faea00000000, 0x18c9a06a00000000, 0x8b52691500000000, + 0x1de6976800000000, 0x8e7d5e1700000000, 0x3bd1049700000000, + 0xa84acde800000000, 0x108ec04c00000000, 0x8315093300000000, + 0x36b953b300000000, 0xa5229acc00000000, 0x0736392000000000, + 0x94adf05f00000000, 0x2101aadf00000000, 0xb29a63a000000000, + 0x0a5e6e0400000000, 0x99c5a77b00000000, 0x2c69fdfb00000000, + 0xbff2348400000000, 0x138ae52800000000, 0x80112c5700000000, + 0x35bd76d700000000, 0xa626bfa800000000, 0x1ee2b20c00000000, + 0x8d797b7300000000, 0x38d521f300000000, 0xab4ee88c00000000, + 0x095a4b6000000000, 0x9ac1821f00000000, 0x2f6dd89f00000000, + 0xbcf611e000000000, 0x04321c4400000000, 0x97a9d53b00000000, + 0x22058fbb00000000, 0xb19e46c400000000, 0x272ab8b900000000, + 0xb4b171c600000000, 0x011d2b4600000000, 0x9286e23900000000, + 0x2a42ef9d00000000, 0xb9d926e200000000, 0x0c757c6200000000, + 0x9feeb51d00000000, 0x3dfa16f100000000, 0xae61df8e00000000, + 0x1bcd850e00000000, 0x88564c7100000000, 0x309241d500000000, + 0xa30988aa00000000, 0x16a5d22a00000000, 0x853e1b5500000000, + 0x3acc2fd100000000, 0xa957e6ae00000000, 0x1cfbbc2e00000000, + 0x8f60755100000000, 0x37a478f500000000, 0xa43fb18a00000000, + 0x1193eb0a00000000, 0x8208227500000000, 0x201c819900000000, + 0xb38748e600000000, 0x062b126600000000, 0x95b0db1900000000, + 0x2d74d6bd00000000, 0xbeef1fc200000000, 0x0b43454200000000, + 0x98d88c3d00000000, 0x0e6c724000000000, 0x9df7bb3f00000000, + 0x285be1bf00000000, 0xbbc028c000000000, 0x0304256400000000, + 0x909fec1b00000000, 0x2533b69b00000000, 0xb6a87fe400000000, + 0x14bcdc0800000000, 0x8727157700000000, 0x328b4ff700000000, + 0xa110868800000000, 0x19d48b2c00000000, 0x8a4f425300000000, + 0x3fe318d300000000, 0xac78d1ac00000000, 0x2614cb5100000000, + 0xb58f022e00000000, 0x002358ae00000000, 0x93b891d100000000, + 0x2b7c9c7500000000, 0xb8e7550a00000000, 0x0d4b0f8a00000000, + 0x9ed0c6f500000000, 0x3cc4651900000000, 0xaf5fac6600000000, + 0x1af3f6e600000000, 0x89683f9900000000, 0x31ac323d00000000, + 0xa237fb4200000000, 0x179ba1c200000000, 0x840068bd00000000, + 0x12b496c000000000, 0x812f5fbf00000000, 0x3483053f00000000, + 0xa718cc4000000000, 0x1fdcc1e400000000, 0x8c47089b00000000, + 0x39eb521b00000000, 0xaa709b6400000000, 0x0864388800000000, + 0x9bfff1f700000000, 0x2e53ab7700000000, 0xbdc8620800000000, + 0x050c6fac00000000, 0x9697a6d300000000, 0x233bfc5300000000, + 0xb0a0352c00000000, 0x0f5201a800000000, 0x9cc9c8d700000000, + 0x2965925700000000, 0xbafe5b2800000000, 0x023a568c00000000, + 0x91a19ff300000000, 0x240dc57300000000, 0xb7960c0c00000000, + 0x1582afe000000000, 0x8619669f00000000, 0x33b53c1f00000000, + 0xa02ef56000000000, 0x18eaf8c400000000, 0x8b7131bb00000000, + 0x3edd6b3b00000000, 0xad46a24400000000, 0x3bf25c3900000000, + 0xa869954600000000, 0x1dc5cfc600000000, 0x8e5e06b900000000, + 0x369a0b1d00000000, 0xa501c26200000000, 0x10ad98e200000000, + 0x8336519d00000000, 0x2122f27100000000, 0xb2b93b0e00000000, + 0x0715618e00000000, 0x948ea8f100000000, 0x2c4aa55500000000, + 0xbfd16c2a00000000, 0x0a7d36aa00000000, 0x99e6ffd500000000, + 0x359e2e7900000000, 0xa605e70600000000, 0x13a9bd8600000000, + 0x803274f900000000, 0x38f6795d00000000, 0xab6db02200000000, + 0x1ec1eaa200000000, 0x8d5a23dd00000000, 0x2f4e803100000000, + 0xbcd5494e00000000, 0x097913ce00000000, 0x9ae2dab100000000, + 0x2226d71500000000, 0xb1bd1e6a00000000, 0x041144ea00000000, + 0x978a8d9500000000, 0x013e73e800000000, 0x92a5ba9700000000, + 0x2709e01700000000, 0xb492296800000000, 0x0c5624cc00000000, + 0x9fcdedb300000000, 0x2a61b73300000000, 0xb9fa7e4c00000000, + 0x1beedda000000000, 0x887514df00000000, 0x3dd94e5f00000000, + 0xae42872000000000, 0x16868a8400000000, 0x851d43fb00000000, + 0x30b1197b00000000, 0xa32ad00400000000, 0x1cd8e48000000000, + 0x8f432dff00000000, 0x3aef777f00000000, 0xa974be0000000000, + 0x11b0b3a400000000, 0x822b7adb00000000, 0x3787205b00000000, + 0xa41ce92400000000, 0x06084ac800000000, 0x959383b700000000, + 0x203fd93700000000, 0xb3a4104800000000, 0x0b601dec00000000, + 0x98fbd49300000000, 0x2d578e1300000000, 0xbecc476c00000000, + 0x2878b91100000000, 0xbbe3706e00000000, 0x0e4f2aee00000000, + 0x9dd4e39100000000, 0x2510ee3500000000, 0xb68b274a00000000, + 0x03277dca00000000, 0x90bcb4b500000000, 0x32a8175900000000, + 0xa133de2600000000, 0x149f84a600000000, 0x87044dd900000000, + 0x3fc0407d00000000, 0xac5b890200000000, 0x19f7d38200000000, + 0x8a6c1afd00000000}, + {0x0000000000000000, 0x650b796900000000, 0xca16f2d200000000, + 0xaf1d8bbb00000000, 0xd52b957e00000000, 0xb020ec1700000000, + 0x1f3d67ac00000000, 0x7a361ec500000000, 0xaa572afd00000000, + 0xcf5c539400000000, 0x6041d82f00000000, 0x054aa14600000000, + 0x7f7cbf8300000000, 0x1a77c6ea00000000, 0xb56a4d5100000000, + 0xd061343800000000, 0x15a9252100000000, 0x70a25c4800000000, + 0xdfbfd7f300000000, 0xbab4ae9a00000000, 0xc082b05f00000000, + 0xa589c93600000000, 0x0a94428d00000000, 0x6f9f3be400000000, + 0xbffe0fdc00000000, 0xdaf576b500000000, 0x75e8fd0e00000000, + 0x10e3846700000000, 0x6ad59aa200000000, 0x0fdee3cb00000000, + 0xa0c3687000000000, 0xc5c8111900000000, 0x2a524b4200000000, + 0x4f59322b00000000, 0xe044b99000000000, 0x854fc0f900000000, + 0xff79de3c00000000, 0x9a72a75500000000, 0x356f2cee00000000, + 0x5064558700000000, 0x800561bf00000000, 0xe50e18d600000000, + 0x4a13936d00000000, 0x2f18ea0400000000, 0x552ef4c100000000, + 0x30258da800000000, 0x9f38061300000000, 0xfa337f7a00000000, + 0x3ffb6e6300000000, 0x5af0170a00000000, 0xf5ed9cb100000000, + 0x90e6e5d800000000, 0xead0fb1d00000000, 0x8fdb827400000000, + 0x20c609cf00000000, 0x45cd70a600000000, 0x95ac449e00000000, + 0xf0a73df700000000, 0x5fbab64c00000000, 0x3ab1cf2500000000, + 0x4087d1e000000000, 0x258ca88900000000, 0x8a91233200000000, + 0xef9a5a5b00000000, 0x54a4968400000000, 0x31afefed00000000, + 0x9eb2645600000000, 0xfbb91d3f00000000, 0x818f03fa00000000, + 0xe4847a9300000000, 0x4b99f12800000000, 0x2e92884100000000, + 0xfef3bc7900000000, 0x9bf8c51000000000, 0x34e54eab00000000, + 0x51ee37c200000000, 0x2bd8290700000000, 0x4ed3506e00000000, + 0xe1cedbd500000000, 0x84c5a2bc00000000, 0x410db3a500000000, + 0x2406cacc00000000, 0x8b1b417700000000, 0xee10381e00000000, + 0x942626db00000000, 0xf12d5fb200000000, 0x5e30d40900000000, + 0x3b3bad6000000000, 0xeb5a995800000000, 0x8e51e03100000000, + 0x214c6b8a00000000, 0x444712e300000000, 0x3e710c2600000000, + 0x5b7a754f00000000, 0xf467fef400000000, 0x916c879d00000000, + 0x7ef6ddc600000000, 0x1bfda4af00000000, 0xb4e02f1400000000, + 0xd1eb567d00000000, 0xabdd48b800000000, 0xced631d100000000, + 0x61cbba6a00000000, 0x04c0c30300000000, 0xd4a1f73b00000000, + 0xb1aa8e5200000000, 0x1eb705e900000000, 0x7bbc7c8000000000, + 0x018a624500000000, 0x64811b2c00000000, 0xcb9c909700000000, + 0xae97e9fe00000000, 0x6b5ff8e700000000, 0x0e54818e00000000, + 0xa1490a3500000000, 0xc442735c00000000, 0xbe746d9900000000, + 0xdb7f14f000000000, 0x74629f4b00000000, 0x1169e62200000000, + 0xc108d21a00000000, 0xa403ab7300000000, 0x0b1e20c800000000, + 0x6e1559a100000000, 0x1423476400000000, 0x71283e0d00000000, + 0xde35b5b600000000, 0xbb3eccdf00000000, 0xe94e5cd200000000, + 0x8c4525bb00000000, 0x2358ae0000000000, 0x4653d76900000000, + 0x3c65c9ac00000000, 0x596eb0c500000000, 0xf6733b7e00000000, + 0x9378421700000000, 0x4319762f00000000, 0x26120f4600000000, + 0x890f84fd00000000, 0xec04fd9400000000, 0x9632e35100000000, + 0xf3399a3800000000, 0x5c24118300000000, 0x392f68ea00000000, + 0xfce779f300000000, 0x99ec009a00000000, 0x36f18b2100000000, + 0x53faf24800000000, 0x29ccec8d00000000, 0x4cc795e400000000, + 0xe3da1e5f00000000, 0x86d1673600000000, 0x56b0530e00000000, + 0x33bb2a6700000000, 0x9ca6a1dc00000000, 0xf9add8b500000000, + 0x839bc67000000000, 0xe690bf1900000000, 0x498d34a200000000, + 0x2c864dcb00000000, 0xc31c179000000000, 0xa6176ef900000000, + 0x090ae54200000000, 0x6c019c2b00000000, 0x163782ee00000000, + 0x733cfb8700000000, 0xdc21703c00000000, 0xb92a095500000000, + 0x694b3d6d00000000, 0x0c40440400000000, 0xa35dcfbf00000000, + 0xc656b6d600000000, 0xbc60a81300000000, 0xd96bd17a00000000, + 0x76765ac100000000, 0x137d23a800000000, 0xd6b532b100000000, + 0xb3be4bd800000000, 0x1ca3c06300000000, 0x79a8b90a00000000, + 0x039ea7cf00000000, 0x6695dea600000000, 0xc988551d00000000, + 0xac832c7400000000, 0x7ce2184c00000000, 0x19e9612500000000, + 0xb6f4ea9e00000000, 0xd3ff93f700000000, 0xa9c98d3200000000, + 0xccc2f45b00000000, 0x63df7fe000000000, 0x06d4068900000000, + 0xbdeaca5600000000, 0xd8e1b33f00000000, 0x77fc388400000000, + 0x12f741ed00000000, 0x68c15f2800000000, 0x0dca264100000000, + 0xa2d7adfa00000000, 0xc7dcd49300000000, 0x17bde0ab00000000, + 0x72b699c200000000, 0xddab127900000000, 0xb8a06b1000000000, + 0xc29675d500000000, 0xa79d0cbc00000000, 0x0880870700000000, + 0x6d8bfe6e00000000, 0xa843ef7700000000, 0xcd48961e00000000, + 0x62551da500000000, 0x075e64cc00000000, 0x7d687a0900000000, + 0x1863036000000000, 0xb77e88db00000000, 0xd275f1b200000000, + 0x0214c58a00000000, 0x671fbce300000000, 0xc802375800000000, + 0xad094e3100000000, 0xd73f50f400000000, 0xb234299d00000000, + 0x1d29a22600000000, 0x7822db4f00000000, 0x97b8811400000000, + 0xf2b3f87d00000000, 0x5dae73c600000000, 0x38a50aaf00000000, + 0x4293146a00000000, 0x27986d0300000000, 0x8885e6b800000000, + 0xed8e9fd100000000, 0x3defabe900000000, 0x58e4d28000000000, + 0xf7f9593b00000000, 0x92f2205200000000, 0xe8c43e9700000000, + 0x8dcf47fe00000000, 0x22d2cc4500000000, 0x47d9b52c00000000, + 0x8211a43500000000, 0xe71add5c00000000, 0x480756e700000000, + 0x2d0c2f8e00000000, 0x573a314b00000000, 0x3231482200000000, + 0x9d2cc39900000000, 0xf827baf000000000, 0x28468ec800000000, + 0x4d4df7a100000000, 0xe2507c1a00000000, 0x875b057300000000, + 0xfd6d1bb600000000, 0x986662df00000000, 0x377be96400000000, + 0x5270900d00000000}, + {0x0000000000000000, 0xdcecb13d00000000, 0xb8d9637b00000000, + 0x6435d24600000000, 0x70b3c7f600000000, 0xac5f76cb00000000, + 0xc86aa48d00000000, 0x148615b000000000, 0xa160fe3600000000, + 0x7d8c4f0b00000000, 0x19b99d4d00000000, 0xc5552c7000000000, + 0xd1d339c000000000, 0x0d3f88fd00000000, 0x690a5abb00000000, + 0xb5e6eb8600000000, 0x42c1fc6d00000000, 0x9e2d4d5000000000, + 0xfa189f1600000000, 0x26f42e2b00000000, 0x32723b9b00000000, + 0xee9e8aa600000000, 0x8aab58e000000000, 0x5647e9dd00000000, + 0xe3a1025b00000000, 0x3f4db36600000000, 0x5b78612000000000, + 0x8794d01d00000000, 0x9312c5ad00000000, 0x4ffe749000000000, + 0x2bcba6d600000000, 0xf72717eb00000000, 0x8482f9db00000000, + 0x586e48e600000000, 0x3c5b9aa000000000, 0xe0b72b9d00000000, + 0xf4313e2d00000000, 0x28dd8f1000000000, 0x4ce85d5600000000, + 0x9004ec6b00000000, 0x25e207ed00000000, 0xf90eb6d000000000, + 0x9d3b649600000000, 0x41d7d5ab00000000, 0x5551c01b00000000, + 0x89bd712600000000, 0xed88a36000000000, 0x3164125d00000000, + 0xc64305b600000000, 0x1aafb48b00000000, 0x7e9a66cd00000000, + 0xa276d7f000000000, 0xb6f0c24000000000, 0x6a1c737d00000000, + 0x0e29a13b00000000, 0xd2c5100600000000, 0x6723fb8000000000, + 0xbbcf4abd00000000, 0xdffa98fb00000000, 0x031629c600000000, + 0x17903c7600000000, 0xcb7c8d4b00000000, 0xaf495f0d00000000, + 0x73a5ee3000000000, 0x4903826c00000000, 0x95ef335100000000, + 0xf1dae11700000000, 0x2d36502a00000000, 0x39b0459a00000000, + 0xe55cf4a700000000, 0x816926e100000000, 0x5d8597dc00000000, + 0xe8637c5a00000000, 0x348fcd6700000000, 0x50ba1f2100000000, + 0x8c56ae1c00000000, 0x98d0bbac00000000, 0x443c0a9100000000, + 0x2009d8d700000000, 0xfce569ea00000000, 0x0bc27e0100000000, + 0xd72ecf3c00000000, 0xb31b1d7a00000000, 0x6ff7ac4700000000, + 0x7b71b9f700000000, 0xa79d08ca00000000, 0xc3a8da8c00000000, + 0x1f446bb100000000, 0xaaa2803700000000, 0x764e310a00000000, + 0x127be34c00000000, 0xce97527100000000, 0xda1147c100000000, + 0x06fdf6fc00000000, 0x62c824ba00000000, 0xbe24958700000000, + 0xcd817bb700000000, 0x116dca8a00000000, 0x755818cc00000000, + 0xa9b4a9f100000000, 0xbd32bc4100000000, 0x61de0d7c00000000, + 0x05ebdf3a00000000, 0xd9076e0700000000, 0x6ce1858100000000, + 0xb00d34bc00000000, 0xd438e6fa00000000, 0x08d457c700000000, + 0x1c52427700000000, 0xc0bef34a00000000, 0xa48b210c00000000, + 0x7867903100000000, 0x8f4087da00000000, 0x53ac36e700000000, + 0x3799e4a100000000, 0xeb75559c00000000, 0xfff3402c00000000, + 0x231ff11100000000, 0x472a235700000000, 0x9bc6926a00000000, + 0x2e2079ec00000000, 0xf2ccc8d100000000, 0x96f91a9700000000, + 0x4a15abaa00000000, 0x5e93be1a00000000, 0x827f0f2700000000, + 0xe64add6100000000, 0x3aa66c5c00000000, 0x920604d900000000, + 0x4eeab5e400000000, 0x2adf67a200000000, 0xf633d69f00000000, + 0xe2b5c32f00000000, 0x3e59721200000000, 0x5a6ca05400000000, + 0x8680116900000000, 0x3366faef00000000, 0xef8a4bd200000000, + 0x8bbf999400000000, 0x575328a900000000, 0x43d53d1900000000, + 0x9f398c2400000000, 0xfb0c5e6200000000, 0x27e0ef5f00000000, + 0xd0c7f8b400000000, 0x0c2b498900000000, 0x681e9bcf00000000, + 0xb4f22af200000000, 0xa0743f4200000000, 0x7c988e7f00000000, + 0x18ad5c3900000000, 0xc441ed0400000000, 0x71a7068200000000, + 0xad4bb7bf00000000, 0xc97e65f900000000, 0x1592d4c400000000, + 0x0114c17400000000, 0xddf8704900000000, 0xb9cda20f00000000, + 0x6521133200000000, 0x1684fd0200000000, 0xca684c3f00000000, + 0xae5d9e7900000000, 0x72b12f4400000000, 0x66373af400000000, + 0xbadb8bc900000000, 0xdeee598f00000000, 0x0202e8b200000000, + 0xb7e4033400000000, 0x6b08b20900000000, 0x0f3d604f00000000, + 0xd3d1d17200000000, 0xc757c4c200000000, 0x1bbb75ff00000000, + 0x7f8ea7b900000000, 0xa362168400000000, 0x5445016f00000000, + 0x88a9b05200000000, 0xec9c621400000000, 0x3070d32900000000, + 0x24f6c69900000000, 0xf81a77a400000000, 0x9c2fa5e200000000, + 0x40c314df00000000, 0xf525ff5900000000, 0x29c94e6400000000, + 0x4dfc9c2200000000, 0x91102d1f00000000, 0x859638af00000000, + 0x597a899200000000, 0x3d4f5bd400000000, 0xe1a3eae900000000, + 0xdb0586b500000000, 0x07e9378800000000, 0x63dce5ce00000000, + 0xbf3054f300000000, 0xabb6414300000000, 0x775af07e00000000, + 0x136f223800000000, 0xcf83930500000000, 0x7a65788300000000, + 0xa689c9be00000000, 0xc2bc1bf800000000, 0x1e50aac500000000, + 0x0ad6bf7500000000, 0xd63a0e4800000000, 0xb20fdc0e00000000, + 0x6ee36d3300000000, 0x99c47ad800000000, 0x4528cbe500000000, + 0x211d19a300000000, 0xfdf1a89e00000000, 0xe977bd2e00000000, + 0x359b0c1300000000, 0x51aede5500000000, 0x8d426f6800000000, + 0x38a484ee00000000, 0xe44835d300000000, 0x807de79500000000, + 0x5c9156a800000000, 0x4817431800000000, 0x94fbf22500000000, + 0xf0ce206300000000, 0x2c22915e00000000, 0x5f877f6e00000000, + 0x836bce5300000000, 0xe75e1c1500000000, 0x3bb2ad2800000000, + 0x2f34b89800000000, 0xf3d809a500000000, 0x97eddbe300000000, + 0x4b016ade00000000, 0xfee7815800000000, 0x220b306500000000, + 0x463ee22300000000, 0x9ad2531e00000000, 0x8e5446ae00000000, + 0x52b8f79300000000, 0x368d25d500000000, 0xea6194e800000000, + 0x1d46830300000000, 0xc1aa323e00000000, 0xa59fe07800000000, + 0x7973514500000000, 0x6df544f500000000, 0xb119f5c800000000, + 0xd52c278e00000000, 0x09c096b300000000, 0xbc267d3500000000, + 0x60cacc0800000000, 0x04ff1e4e00000000, 0xd813af7300000000, + 0xcc95bac300000000, 0x10790bfe00000000, 0x744cd9b800000000, + 0xa8a0688500000000}}; + +#else /* W == 4 */ + +local const z_crc_t FAR crc_braid_table[][256] = { + {0x00000000, 0x81256527, 0xd93bcc0f, 0x581ea928, 0x69069e5f, + 0xe823fb78, 0xb03d5250, 0x31183777, 0xd20d3cbe, 0x53285999, + 0x0b36f0b1, 0x8a139596, 0xbb0ba2e1, 0x3a2ec7c6, 0x62306eee, + 0xe3150bc9, 0x7f6b7f3d, 0xfe4e1a1a, 0xa650b332, 0x2775d615, + 0x166de162, 0x97488445, 0xcf562d6d, 0x4e73484a, 0xad664383, + 0x2c4326a4, 0x745d8f8c, 0xf578eaab, 0xc460dddc, 0x4545b8fb, + 0x1d5b11d3, 0x9c7e74f4, 0xfed6fe7a, 0x7ff39b5d, 0x27ed3275, + 0xa6c85752, 0x97d06025, 0x16f50502, 0x4eebac2a, 0xcfcec90d, + 0x2cdbc2c4, 0xadfea7e3, 0xf5e00ecb, 0x74c56bec, 0x45dd5c9b, + 0xc4f839bc, 0x9ce69094, 0x1dc3f5b3, 0x81bd8147, 0x0098e460, + 0x58864d48, 0xd9a3286f, 0xe8bb1f18, 0x699e7a3f, 0x3180d317, + 0xb0a5b630, 0x53b0bdf9, 0xd295d8de, 0x8a8b71f6, 0x0bae14d1, + 0x3ab623a6, 0xbb934681, 0xe38defa9, 0x62a88a8e, 0x26dcfab5, + 0xa7f99f92, 0xffe736ba, 0x7ec2539d, 0x4fda64ea, 0xceff01cd, + 0x96e1a8e5, 0x17c4cdc2, 0xf4d1c60b, 0x75f4a32c, 0x2dea0a04, + 0xaccf6f23, 0x9dd75854, 0x1cf23d73, 0x44ec945b, 0xc5c9f17c, + 0x59b78588, 0xd892e0af, 0x808c4987, 0x01a92ca0, 0x30b11bd7, + 0xb1947ef0, 0xe98ad7d8, 0x68afb2ff, 0x8bbab936, 0x0a9fdc11, + 0x52817539, 0xd3a4101e, 0xe2bc2769, 0x6399424e, 0x3b87eb66, + 0xbaa28e41, 0xd80a04cf, 0x592f61e8, 0x0131c8c0, 0x8014ade7, + 0xb10c9a90, 0x3029ffb7, 0x6837569f, 0xe91233b8, 0x0a073871, + 0x8b225d56, 0xd33cf47e, 0x52199159, 0x6301a62e, 0xe224c309, + 0xba3a6a21, 0x3b1f0f06, 0xa7617bf2, 0x26441ed5, 0x7e5ab7fd, + 0xff7fd2da, 0xce67e5ad, 0x4f42808a, 0x175c29a2, 0x96794c85, + 0x756c474c, 0xf449226b, 0xac578b43, 0x2d72ee64, 0x1c6ad913, + 0x9d4fbc34, 0xc551151c, 0x4474703b, 0x4db9f56a, 0xcc9c904d, + 0x94823965, 0x15a75c42, 0x24bf6b35, 0xa59a0e12, 0xfd84a73a, + 0x7ca1c21d, 0x9fb4c9d4, 0x1e91acf3, 0x468f05db, 0xc7aa60fc, + 0xf6b2578b, 0x779732ac, 0x2f899b84, 0xaeacfea3, 0x32d28a57, + 0xb3f7ef70, 0xebe94658, 0x6acc237f, 0x5bd41408, 0xdaf1712f, + 0x82efd807, 0x03cabd20, 0xe0dfb6e9, 0x61fad3ce, 0x39e47ae6, + 0xb8c11fc1, 0x89d928b6, 0x08fc4d91, 0x50e2e4b9, 0xd1c7819e, + 0xb36f0b10, 0x324a6e37, 0x6a54c71f, 0xeb71a238, 0xda69954f, + 0x5b4cf068, 0x03525940, 0x82773c67, 0x616237ae, 0xe0475289, + 0xb859fba1, 0x397c9e86, 0x0864a9f1, 0x8941ccd6, 0xd15f65fe, + 0x507a00d9, 0xcc04742d, 0x4d21110a, 0x153fb822, 0x941add05, + 0xa502ea72, 0x24278f55, 0x7c39267d, 0xfd1c435a, 0x1e094893, + 0x9f2c2db4, 0xc732849c, 0x4617e1bb, 0x770fd6cc, 0xf62ab3eb, + 0xae341ac3, 0x2f117fe4, 0x6b650fdf, 0xea406af8, 0xb25ec3d0, + 0x337ba6f7, 0x02639180, 0x8346f4a7, 0xdb585d8f, 0x5a7d38a8, + 0xb9683361, 0x384d5646, 0x6053ff6e, 0xe1769a49, 0xd06ead3e, + 0x514bc819, 0x09556131, 0x88700416, 0x140e70e2, 0x952b15c5, + 0xcd35bced, 0x4c10d9ca, 0x7d08eebd, 0xfc2d8b9a, 0xa43322b2, + 0x25164795, 0xc6034c5c, 0x4726297b, 0x1f388053, 0x9e1de574, + 0xaf05d203, 0x2e20b724, 0x763e1e0c, 0xf71b7b2b, 0x95b3f1a5, + 0x14969482, 0x4c883daa, 0xcdad588d, 0xfcb56ffa, 0x7d900add, + 0x258ea3f5, 0xa4abc6d2, 0x47becd1b, 0xc69ba83c, 0x9e850114, + 0x1fa06433, 0x2eb85344, 0xaf9d3663, 0xf7839f4b, 0x76a6fa6c, + 0xead88e98, 0x6bfdebbf, 0x33e34297, 0xb2c627b0, 0x83de10c7, + 0x02fb75e0, 0x5ae5dcc8, 0xdbc0b9ef, 0x38d5b226, 0xb9f0d701, + 0xe1ee7e29, 0x60cb1b0e, 0x51d32c79, 0xd0f6495e, 0x88e8e076, + 0x09cd8551}, + {0x00000000, 0x9b73ead4, 0xed96d3e9, 0x76e5393d, 0x005ca193, + 0x9b2f4b47, 0xedca727a, 0x76b998ae, 0x00b94326, 0x9bcaa9f2, + 0xed2f90cf, 0x765c7a1b, 0x00e5e2b5, 0x9b960861, 0xed73315c, + 0x7600db88, 0x0172864c, 0x9a016c98, 0xece455a5, 0x7797bf71, + 0x012e27df, 0x9a5dcd0b, 0xecb8f436, 0x77cb1ee2, 0x01cbc56a, + 0x9ab82fbe, 0xec5d1683, 0x772efc57, 0x019764f9, 0x9ae48e2d, + 0xec01b710, 0x77725dc4, 0x02e50c98, 0x9996e64c, 0xef73df71, + 0x740035a5, 0x02b9ad0b, 0x99ca47df, 0xef2f7ee2, 0x745c9436, + 0x025c4fbe, 0x992fa56a, 0xefca9c57, 0x74b97683, 0x0200ee2d, + 0x997304f9, 0xef963dc4, 0x74e5d710, 0x03978ad4, 0x98e46000, + 0xee01593d, 0x7572b3e9, 0x03cb2b47, 0x98b8c193, 0xee5df8ae, + 0x752e127a, 0x032ec9f2, 0x985d2326, 0xeeb81a1b, 0x75cbf0cf, + 0x03726861, 0x980182b5, 0xeee4bb88, 0x7597515c, 0x05ca1930, + 0x9eb9f3e4, 0xe85ccad9, 0x732f200d, 0x0596b8a3, 0x9ee55277, + 0xe8006b4a, 0x7373819e, 0x05735a16, 0x9e00b0c2, 0xe8e589ff, + 0x7396632b, 0x052ffb85, 0x9e5c1151, 0xe8b9286c, 0x73cac2b8, + 0x04b89f7c, 0x9fcb75a8, 0xe92e4c95, 0x725da641, 0x04e43eef, + 0x9f97d43b, 0xe972ed06, 0x720107d2, 0x0401dc5a, 0x9f72368e, + 0xe9970fb3, 0x72e4e567, 0x045d7dc9, 0x9f2e971d, 0xe9cbae20, + 0x72b844f4, 0x072f15a8, 0x9c5cff7c, 0xeab9c641, 0x71ca2c95, + 0x0773b43b, 0x9c005eef, 0xeae567d2, 0x71968d06, 0x0796568e, + 0x9ce5bc5a, 0xea008567, 0x71736fb3, 0x07caf71d, 0x9cb91dc9, + 0xea5c24f4, 0x712fce20, 0x065d93e4, 0x9d2e7930, 0xebcb400d, + 0x70b8aad9, 0x06013277, 0x9d72d8a3, 0xeb97e19e, 0x70e40b4a, + 0x06e4d0c2, 0x9d973a16, 0xeb72032b, 0x7001e9ff, 0x06b87151, + 0x9dcb9b85, 0xeb2ea2b8, 0x705d486c, 0x0b943260, 0x90e7d8b4, + 0xe602e189, 0x7d710b5d, 0x0bc893f3, 0x90bb7927, 0xe65e401a, + 0x7d2daace, 0x0b2d7146, 0x905e9b92, 0xe6bba2af, 0x7dc8487b, + 0x0b71d0d5, 0x90023a01, 0xe6e7033c, 0x7d94e9e8, 0x0ae6b42c, + 0x91955ef8, 0xe77067c5, 0x7c038d11, 0x0aba15bf, 0x91c9ff6b, + 0xe72cc656, 0x7c5f2c82, 0x0a5ff70a, 0x912c1dde, 0xe7c924e3, + 0x7cbace37, 0x0a035699, 0x9170bc4d, 0xe7958570, 0x7ce66fa4, + 0x09713ef8, 0x9202d42c, 0xe4e7ed11, 0x7f9407c5, 0x092d9f6b, + 0x925e75bf, 0xe4bb4c82, 0x7fc8a656, 0x09c87dde, 0x92bb970a, + 0xe45eae37, 0x7f2d44e3, 0x0994dc4d, 0x92e73699, 0xe4020fa4, + 0x7f71e570, 0x0803b8b4, 0x93705260, 0xe5956b5d, 0x7ee68189, + 0x085f1927, 0x932cf3f3, 0xe5c9cace, 0x7eba201a, 0x08bafb92, + 0x93c91146, 0xe52c287b, 0x7e5fc2af, 0x08e65a01, 0x9395b0d5, + 0xe57089e8, 0x7e03633c, 0x0e5e2b50, 0x952dc184, 0xe3c8f8b9, + 0x78bb126d, 0x0e028ac3, 0x95716017, 0xe394592a, 0x78e7b3fe, + 0x0ee76876, 0x959482a2, 0xe371bb9f, 0x7802514b, 0x0ebbc9e5, + 0x95c82331, 0xe32d1a0c, 0x785ef0d8, 0x0f2cad1c, 0x945f47c8, + 0xe2ba7ef5, 0x79c99421, 0x0f700c8f, 0x9403e65b, 0xe2e6df66, + 0x799535b2, 0x0f95ee3a, 0x94e604ee, 0xe2033dd3, 0x7970d707, + 0x0fc94fa9, 0x94baa57d, 0xe25f9c40, 0x792c7694, 0x0cbb27c8, + 0x97c8cd1c, 0xe12df421, 0x7a5e1ef5, 0x0ce7865b, 0x97946c8f, + 0xe17155b2, 0x7a02bf66, 0x0c0264ee, 0x97718e3a, 0xe194b707, + 0x7ae75dd3, 0x0c5ec57d, 0x972d2fa9, 0xe1c81694, 0x7abbfc40, + 0x0dc9a184, 0x96ba4b50, 0xe05f726d, 0x7b2c98b9, 0x0d950017, + 0x96e6eac3, 0xe003d3fe, 0x7b70392a, 0x0d70e2a2, 0x96030876, + 0xe0e6314b, 0x7b95db9f, 0x0d2c4331, 0x965fa9e5, 0xe0ba90d8, + 0x7bc97a0c}, + {0x00000000, 0x172864c0, 0x2e50c980, 0x3978ad40, 0x5ca19300, + 0x4b89f7c0, 0x72f15a80, 0x65d93e40, 0xb9432600, 0xae6b42c0, + 0x9713ef80, 0x803b8b40, 0xe5e2b500, 0xf2cad1c0, 0xcbb27c80, + 0xdc9a1840, 0xa9f74a41, 0xbedf2e81, 0x87a783c1, 0x908fe701, + 0xf556d941, 0xe27ebd81, 0xdb0610c1, 0xcc2e7401, 0x10b46c41, + 0x079c0881, 0x3ee4a5c1, 0x29ccc101, 0x4c15ff41, 0x5b3d9b81, + 0x624536c1, 0x756d5201, 0x889f92c3, 0x9fb7f603, 0xa6cf5b43, + 0xb1e73f83, 0xd43e01c3, 0xc3166503, 0xfa6ec843, 0xed46ac83, + 0x31dcb4c3, 0x26f4d003, 0x1f8c7d43, 0x08a41983, 0x6d7d27c3, + 0x7a554303, 0x432dee43, 0x54058a83, 0x2168d882, 0x3640bc42, + 0x0f381102, 0x181075c2, 0x7dc94b82, 0x6ae12f42, 0x53998202, + 0x44b1e6c2, 0x982bfe82, 0x8f039a42, 0xb67b3702, 0xa15353c2, + 0xc48a6d82, 0xd3a20942, 0xeadaa402, 0xfdf2c0c2, 0xca4e23c7, + 0xdd664707, 0xe41eea47, 0xf3368e87, 0x96efb0c7, 0x81c7d407, + 0xb8bf7947, 0xaf971d87, 0x730d05c7, 0x64256107, 0x5d5dcc47, + 0x4a75a887, 0x2fac96c7, 0x3884f207, 0x01fc5f47, 0x16d43b87, + 0x63b96986, 0x74910d46, 0x4de9a006, 0x5ac1c4c6, 0x3f18fa86, + 0x28309e46, 0x11483306, 0x066057c6, 0xdafa4f86, 0xcdd22b46, + 0xf4aa8606, 0xe382e2c6, 0x865bdc86, 0x9173b846, 0xa80b1506, + 0xbf2371c6, 0x42d1b104, 0x55f9d5c4, 0x6c817884, 0x7ba91c44, + 0x1e702204, 0x095846c4, 0x3020eb84, 0x27088f44, 0xfb929704, + 0xecbaf3c4, 0xd5c25e84, 0xc2ea3a44, 0xa7330404, 0xb01b60c4, + 0x8963cd84, 0x9e4ba944, 0xeb26fb45, 0xfc0e9f85, 0xc57632c5, + 0xd25e5605, 0xb7876845, 0xa0af0c85, 0x99d7a1c5, 0x8effc505, + 0x5265dd45, 0x454db985, 0x7c3514c5, 0x6b1d7005, 0x0ec44e45, + 0x19ec2a85, 0x209487c5, 0x37bce305, 0x4fed41cf, 0x58c5250f, + 0x61bd884f, 0x7695ec8f, 0x134cd2cf, 0x0464b60f, 0x3d1c1b4f, + 0x2a347f8f, 0xf6ae67cf, 0xe186030f, 0xd8feae4f, 0xcfd6ca8f, + 0xaa0ff4cf, 0xbd27900f, 0x845f3d4f, 0x9377598f, 0xe61a0b8e, + 0xf1326f4e, 0xc84ac20e, 0xdf62a6ce, 0xbabb988e, 0xad93fc4e, + 0x94eb510e, 0x83c335ce, 0x5f592d8e, 0x4871494e, 0x7109e40e, + 0x662180ce, 0x03f8be8e, 0x14d0da4e, 0x2da8770e, 0x3a8013ce, + 0xc772d30c, 0xd05ab7cc, 0xe9221a8c, 0xfe0a7e4c, 0x9bd3400c, + 0x8cfb24cc, 0xb583898c, 0xa2abed4c, 0x7e31f50c, 0x691991cc, + 0x50613c8c, 0x4749584c, 0x2290660c, 0x35b802cc, 0x0cc0af8c, + 0x1be8cb4c, 0x6e85994d, 0x79adfd8d, 0x40d550cd, 0x57fd340d, + 0x32240a4d, 0x250c6e8d, 0x1c74c3cd, 0x0b5ca70d, 0xd7c6bf4d, + 0xc0eedb8d, 0xf99676cd, 0xeebe120d, 0x8b672c4d, 0x9c4f488d, + 0xa537e5cd, 0xb21f810d, 0x85a36208, 0x928b06c8, 0xabf3ab88, + 0xbcdbcf48, 0xd902f108, 0xce2a95c8, 0xf7523888, 0xe07a5c48, + 0x3ce04408, 0x2bc820c8, 0x12b08d88, 0x0598e948, 0x6041d708, + 0x7769b3c8, 0x4e111e88, 0x59397a48, 0x2c542849, 0x3b7c4c89, + 0x0204e1c9, 0x152c8509, 0x70f5bb49, 0x67dddf89, 0x5ea572c9, + 0x498d1609, 0x95170e49, 0x823f6a89, 0xbb47c7c9, 0xac6fa309, + 0xc9b69d49, 0xde9ef989, 0xe7e654c9, 0xf0ce3009, 0x0d3cf0cb, + 0x1a14940b, 0x236c394b, 0x34445d8b, 0x519d63cb, 0x46b5070b, + 0x7fcdaa4b, 0x68e5ce8b, 0xb47fd6cb, 0xa357b20b, 0x9a2f1f4b, + 0x8d077b8b, 0xe8de45cb, 0xfff6210b, 0xc68e8c4b, 0xd1a6e88b, + 0xa4cbba8a, 0xb3e3de4a, 0x8a9b730a, 0x9db317ca, 0xf86a298a, + 0xef424d4a, 0xd63ae00a, 0xc11284ca, 0x1d889c8a, 0x0aa0f84a, + 0x33d8550a, 0x24f031ca, 0x41290f8a, 0x56016b4a, 0x6f79c60a, + 0x7851a2ca}, + {0x00000000, 0x9fda839e, 0xe4c4017d, 0x7b1e82e3, 0x12f904bb, + 0x8d238725, 0xf63d05c6, 0x69e78658, 0x25f20976, 0xba288ae8, + 0xc136080b, 0x5eec8b95, 0x370b0dcd, 0xa8d18e53, 0xd3cf0cb0, + 0x4c158f2e, 0x4be412ec, 0xd43e9172, 0xaf201391, 0x30fa900f, + 0x591d1657, 0xc6c795c9, 0xbdd9172a, 0x220394b4, 0x6e161b9a, + 0xf1cc9804, 0x8ad21ae7, 0x15089979, 0x7cef1f21, 0xe3359cbf, + 0x982b1e5c, 0x07f19dc2, 0x97c825d8, 0x0812a646, 0x730c24a5, + 0xecd6a73b, 0x85312163, 0x1aeba2fd, 0x61f5201e, 0xfe2fa380, + 0xb23a2cae, 0x2de0af30, 0x56fe2dd3, 0xc924ae4d, 0xa0c32815, + 0x3f19ab8b, 0x44072968, 0xdbddaaf6, 0xdc2c3734, 0x43f6b4aa, + 0x38e83649, 0xa732b5d7, 0xced5338f, 0x510fb011, 0x2a1132f2, + 0xb5cbb16c, 0xf9de3e42, 0x6604bddc, 0x1d1a3f3f, 0x82c0bca1, + 0xeb273af9, 0x74fdb967, 0x0fe33b84, 0x9039b81a, 0xf4e14df1, + 0x6b3bce6f, 0x10254c8c, 0x8fffcf12, 0xe618494a, 0x79c2cad4, + 0x02dc4837, 0x9d06cba9, 0xd1134487, 0x4ec9c719, 0x35d745fa, + 0xaa0dc664, 0xc3ea403c, 0x5c30c3a2, 0x272e4141, 0xb8f4c2df, + 0xbf055f1d, 0x20dfdc83, 0x5bc15e60, 0xc41bddfe, 0xadfc5ba6, + 0x3226d838, 0x49385adb, 0xd6e2d945, 0x9af7566b, 0x052dd5f5, + 0x7e335716, 0xe1e9d488, 0x880e52d0, 0x17d4d14e, 0x6cca53ad, + 0xf310d033, 0x63296829, 0xfcf3ebb7, 0x87ed6954, 0x1837eaca, + 0x71d06c92, 0xee0aef0c, 0x95146def, 0x0aceee71, 0x46db615f, + 0xd901e2c1, 0xa21f6022, 0x3dc5e3bc, 0x542265e4, 0xcbf8e67a, + 0xb0e66499, 0x2f3ce707, 0x28cd7ac5, 0xb717f95b, 0xcc097bb8, + 0x53d3f826, 0x3a347e7e, 0xa5eefde0, 0xdef07f03, 0x412afc9d, + 0x0d3f73b3, 0x92e5f02d, 0xe9fb72ce, 0x7621f150, 0x1fc67708, + 0x801cf496, 0xfb027675, 0x64d8f5eb, 0x32b39da3, 0xad691e3d, + 0xd6779cde, 0x49ad1f40, 0x204a9918, 0xbf901a86, 0xc48e9865, + 0x5b541bfb, 0x174194d5, 0x889b174b, 0xf38595a8, 0x6c5f1636, + 0x05b8906e, 0x9a6213f0, 0xe17c9113, 0x7ea6128d, 0x79578f4f, + 0xe68d0cd1, 0x9d938e32, 0x02490dac, 0x6bae8bf4, 0xf474086a, + 0x8f6a8a89, 0x10b00917, 0x5ca58639, 0xc37f05a7, 0xb8618744, + 0x27bb04da, 0x4e5c8282, 0xd186011c, 0xaa9883ff, 0x35420061, + 0xa57bb87b, 0x3aa13be5, 0x41bfb906, 0xde653a98, 0xb782bcc0, + 0x28583f5e, 0x5346bdbd, 0xcc9c3e23, 0x8089b10d, 0x1f533293, + 0x644db070, 0xfb9733ee, 0x9270b5b6, 0x0daa3628, 0x76b4b4cb, + 0xe96e3755, 0xee9faa97, 0x71452909, 0x0a5babea, 0x95812874, + 0xfc66ae2c, 0x63bc2db2, 0x18a2af51, 0x87782ccf, 0xcb6da3e1, + 0x54b7207f, 0x2fa9a29c, 0xb0732102, 0xd994a75a, 0x464e24c4, + 0x3d50a627, 0xa28a25b9, 0xc652d052, 0x598853cc, 0x2296d12f, + 0xbd4c52b1, 0xd4abd4e9, 0x4b715777, 0x306fd594, 0xafb5560a, + 0xe3a0d924, 0x7c7a5aba, 0x0764d859, 0x98be5bc7, 0xf159dd9f, + 0x6e835e01, 0x159ddce2, 0x8a475f7c, 0x8db6c2be, 0x126c4120, + 0x6972c3c3, 0xf6a8405d, 0x9f4fc605, 0x0095459b, 0x7b8bc778, + 0xe45144e6, 0xa844cbc8, 0x379e4856, 0x4c80cab5, 0xd35a492b, + 0xbabdcf73, 0x25674ced, 0x5e79ce0e, 0xc1a34d90, 0x519af58a, + 0xce407614, 0xb55ef4f7, 0x2a847769, 0x4363f131, 0xdcb972af, + 0xa7a7f04c, 0x387d73d2, 0x7468fcfc, 0xebb27f62, 0x90acfd81, + 0x0f767e1f, 0x6691f847, 0xf94b7bd9, 0x8255f93a, 0x1d8f7aa4, + 0x1a7ee766, 0x85a464f8, 0xfebae61b, 0x61606585, 0x0887e3dd, + 0x975d6043, 0xec43e2a0, 0x7399613e, 0x3f8cee10, 0xa0566d8e, + 0xdb48ef6d, 0x44926cf3, 0x2d75eaab, 0xb2af6935, 0xc9b1ebd6, + 0x566b6848}}; + +local const z_word_t FAR crc_braid_big_table[][256] = { + {0x00000000, 0x9e83da9f, 0x7d01c4e4, 0xe3821e7b, 0xbb04f912, + 0x2587238d, 0xc6053df6, 0x5886e769, 0x7609f225, 0xe88a28ba, + 0x0b0836c1, 0x958bec5e, 0xcd0d0b37, 0x538ed1a8, 0xb00ccfd3, + 0x2e8f154c, 0xec12e44b, 0x72913ed4, 0x911320af, 0x0f90fa30, + 0x57161d59, 0xc995c7c6, 0x2a17d9bd, 0xb4940322, 0x9a1b166e, + 0x0498ccf1, 0xe71ad28a, 0x79990815, 0x211fef7c, 0xbf9c35e3, + 0x5c1e2b98, 0xc29df107, 0xd825c897, 0x46a61208, 0xa5240c73, + 0x3ba7d6ec, 0x63213185, 0xfda2eb1a, 0x1e20f561, 0x80a32ffe, + 0xae2c3ab2, 0x30afe02d, 0xd32dfe56, 0x4dae24c9, 0x1528c3a0, + 0x8bab193f, 0x68290744, 0xf6aadddb, 0x34372cdc, 0xaab4f643, + 0x4936e838, 0xd7b532a7, 0x8f33d5ce, 0x11b00f51, 0xf232112a, + 0x6cb1cbb5, 0x423edef9, 0xdcbd0466, 0x3f3f1a1d, 0xa1bcc082, + 0xf93a27eb, 0x67b9fd74, 0x843be30f, 0x1ab83990, 0xf14de1f4, + 0x6fce3b6b, 0x8c4c2510, 0x12cfff8f, 0x4a4918e6, 0xd4cac279, + 0x3748dc02, 0xa9cb069d, 0x874413d1, 0x19c7c94e, 0xfa45d735, + 0x64c60daa, 0x3c40eac3, 0xa2c3305c, 0x41412e27, 0xdfc2f4b8, + 0x1d5f05bf, 0x83dcdf20, 0x605ec15b, 0xfedd1bc4, 0xa65bfcad, + 0x38d82632, 0xdb5a3849, 0x45d9e2d6, 0x6b56f79a, 0xf5d52d05, + 0x1657337e, 0x88d4e9e1, 0xd0520e88, 0x4ed1d417, 0xad53ca6c, + 0x33d010f3, 0x29682963, 0xb7ebf3fc, 0x5469ed87, 0xcaea3718, + 0x926cd071, 0x0cef0aee, 0xef6d1495, 0x71eece0a, 0x5f61db46, + 0xc1e201d9, 0x22601fa2, 0xbce3c53d, 0xe4652254, 0x7ae6f8cb, + 0x9964e6b0, 0x07e73c2f, 0xc57acd28, 0x5bf917b7, 0xb87b09cc, + 0x26f8d353, 0x7e7e343a, 0xe0fdeea5, 0x037ff0de, 0x9dfc2a41, + 0xb3733f0d, 0x2df0e592, 0xce72fbe9, 0x50f12176, 0x0877c61f, + 0x96f41c80, 0x757602fb, 0xebf5d864, 0xa39db332, 0x3d1e69ad, + 0xde9c77d6, 0x401fad49, 0x18994a20, 0x861a90bf, 0x65988ec4, + 0xfb1b545b, 0xd5944117, 0x4b179b88, 0xa89585f3, 0x36165f6c, + 0x6e90b805, 0xf013629a, 0x13917ce1, 0x8d12a67e, 0x4f8f5779, + 0xd10c8de6, 0x328e939d, 0xac0d4902, 0xf48bae6b, 0x6a0874f4, + 0x898a6a8f, 0x1709b010, 0x3986a55c, 0xa7057fc3, 0x448761b8, + 0xda04bb27, 0x82825c4e, 0x1c0186d1, 0xff8398aa, 0x61004235, + 0x7bb87ba5, 0xe53ba13a, 0x06b9bf41, 0x983a65de, 0xc0bc82b7, + 0x5e3f5828, 0xbdbd4653, 0x233e9ccc, 0x0db18980, 0x9332531f, + 0x70b04d64, 0xee3397fb, 0xb6b57092, 0x2836aa0d, 0xcbb4b476, + 0x55376ee9, 0x97aa9fee, 0x09294571, 0xeaab5b0a, 0x74288195, + 0x2cae66fc, 0xb22dbc63, 0x51afa218, 0xcf2c7887, 0xe1a36dcb, + 0x7f20b754, 0x9ca2a92f, 0x022173b0, 0x5aa794d9, 0xc4244e46, + 0x27a6503d, 0xb9258aa2, 0x52d052c6, 0xcc538859, 0x2fd19622, + 0xb1524cbd, 0xe9d4abd4, 0x7757714b, 0x94d56f30, 0x0a56b5af, + 0x24d9a0e3, 0xba5a7a7c, 0x59d86407, 0xc75bbe98, 0x9fdd59f1, + 0x015e836e, 0xe2dc9d15, 0x7c5f478a, 0xbec2b68d, 0x20416c12, + 0xc3c37269, 0x5d40a8f6, 0x05c64f9f, 0x9b459500, 0x78c78b7b, + 0xe64451e4, 0xc8cb44a8, 0x56489e37, 0xb5ca804c, 0x2b495ad3, + 0x73cfbdba, 0xed4c6725, 0x0ece795e, 0x904da3c1, 0x8af59a51, + 0x147640ce, 0xf7f45eb5, 0x6977842a, 0x31f16343, 0xaf72b9dc, + 0x4cf0a7a7, 0xd2737d38, 0xfcfc6874, 0x627fb2eb, 0x81fdac90, + 0x1f7e760f, 0x47f89166, 0xd97b4bf9, 0x3af95582, 0xa47a8f1d, + 0x66e77e1a, 0xf864a485, 0x1be6bafe, 0x85656061, 0xdde38708, + 0x43605d97, 0xa0e243ec, 0x3e619973, 0x10ee8c3f, 0x8e6d56a0, + 0x6def48db, 0xf36c9244, 0xabea752d, 0x3569afb2, 0xd6ebb1c9, + 0x48686b56}, + {0x00000000, 0xc0642817, 0x80c9502e, 0x40ad7839, 0x0093a15c, + 0xc0f7894b, 0x805af172, 0x403ed965, 0x002643b9, 0xc0426bae, + 0x80ef1397, 0x408b3b80, 0x00b5e2e5, 0xc0d1caf2, 0x807cb2cb, + 0x40189adc, 0x414af7a9, 0x812edfbe, 0xc183a787, 0x01e78f90, + 0x41d956f5, 0x81bd7ee2, 0xc11006db, 0x01742ecc, 0x416cb410, + 0x81089c07, 0xc1a5e43e, 0x01c1cc29, 0x41ff154c, 0x819b3d5b, + 0xc1364562, 0x01526d75, 0xc3929f88, 0x03f6b79f, 0x435bcfa6, + 0x833fe7b1, 0xc3013ed4, 0x036516c3, 0x43c86efa, 0x83ac46ed, + 0xc3b4dc31, 0x03d0f426, 0x437d8c1f, 0x8319a408, 0xc3277d6d, + 0x0343557a, 0x43ee2d43, 0x838a0554, 0x82d86821, 0x42bc4036, + 0x0211380f, 0xc2751018, 0x824bc97d, 0x422fe16a, 0x02829953, + 0xc2e6b144, 0x82fe2b98, 0x429a038f, 0x02377bb6, 0xc25353a1, + 0x826d8ac4, 0x4209a2d3, 0x02a4daea, 0xc2c0f2fd, 0xc7234eca, + 0x074766dd, 0x47ea1ee4, 0x878e36f3, 0xc7b0ef96, 0x07d4c781, + 0x4779bfb8, 0x871d97af, 0xc7050d73, 0x07612564, 0x47cc5d5d, + 0x87a8754a, 0xc796ac2f, 0x07f28438, 0x475ffc01, 0x873bd416, + 0x8669b963, 0x460d9174, 0x06a0e94d, 0xc6c4c15a, 0x86fa183f, + 0x469e3028, 0x06334811, 0xc6576006, 0x864ffada, 0x462bd2cd, + 0x0686aaf4, 0xc6e282e3, 0x86dc5b86, 0x46b87391, 0x06150ba8, + 0xc67123bf, 0x04b1d142, 0xc4d5f955, 0x8478816c, 0x441ca97b, + 0x0422701e, 0xc4465809, 0x84eb2030, 0x448f0827, 0x049792fb, + 0xc4f3baec, 0x845ec2d5, 0x443aeac2, 0x040433a7, 0xc4601bb0, + 0x84cd6389, 0x44a94b9e, 0x45fb26eb, 0x859f0efc, 0xc53276c5, + 0x05565ed2, 0x456887b7, 0x850cafa0, 0xc5a1d799, 0x05c5ff8e, + 0x45dd6552, 0x85b94d45, 0xc514357c, 0x05701d6b, 0x454ec40e, + 0x852aec19, 0xc5879420, 0x05e3bc37, 0xcf41ed4f, 0x0f25c558, + 0x4f88bd61, 0x8fec9576, 0xcfd24c13, 0x0fb66404, 0x4f1b1c3d, + 0x8f7f342a, 0xcf67aef6, 0x0f0386e1, 0x4faefed8, 0x8fcad6cf, + 0xcff40faa, 0x0f9027bd, 0x4f3d5f84, 0x8f597793, 0x8e0b1ae6, + 0x4e6f32f1, 0x0ec24ac8, 0xcea662df, 0x8e98bbba, 0x4efc93ad, + 0x0e51eb94, 0xce35c383, 0x8e2d595f, 0x4e497148, 0x0ee40971, + 0xce802166, 0x8ebef803, 0x4edad014, 0x0e77a82d, 0xce13803a, + 0x0cd372c7, 0xccb75ad0, 0x8c1a22e9, 0x4c7e0afe, 0x0c40d39b, + 0xcc24fb8c, 0x8c8983b5, 0x4cedaba2, 0x0cf5317e, 0xcc911969, + 0x8c3c6150, 0x4c584947, 0x0c669022, 0xcc02b835, 0x8cafc00c, + 0x4ccbe81b, 0x4d99856e, 0x8dfdad79, 0xcd50d540, 0x0d34fd57, + 0x4d0a2432, 0x8d6e0c25, 0xcdc3741c, 0x0da75c0b, 0x4dbfc6d7, + 0x8ddbeec0, 0xcd7696f9, 0x0d12beee, 0x4d2c678b, 0x8d484f9c, + 0xcde537a5, 0x0d811fb2, 0x0862a385, 0xc8068b92, 0x88abf3ab, + 0x48cfdbbc, 0x08f102d9, 0xc8952ace, 0x883852f7, 0x485c7ae0, + 0x0844e03c, 0xc820c82b, 0x888db012, 0x48e99805, 0x08d74160, + 0xc8b36977, 0x881e114e, 0x487a3959, 0x4928542c, 0x894c7c3b, + 0xc9e10402, 0x09852c15, 0x49bbf570, 0x89dfdd67, 0xc972a55e, + 0x09168d49, 0x490e1795, 0x896a3f82, 0xc9c747bb, 0x09a36fac, + 0x499db6c9, 0x89f99ede, 0xc954e6e7, 0x0930cef0, 0xcbf03c0d, + 0x0b94141a, 0x4b396c23, 0x8b5d4434, 0xcb639d51, 0x0b07b546, + 0x4baacd7f, 0x8bcee568, 0xcbd67fb4, 0x0bb257a3, 0x4b1f2f9a, + 0x8b7b078d, 0xcb45dee8, 0x0b21f6ff, 0x4b8c8ec6, 0x8be8a6d1, + 0x8abacba4, 0x4adee3b3, 0x0a739b8a, 0xca17b39d, 0x8a296af8, + 0x4a4d42ef, 0x0ae03ad6, 0xca8412c1, 0x8a9c881d, 0x4af8a00a, + 0x0a55d833, 0xca31f024, 0x8a0f2941, 0x4a6b0156, 0x0ac6796f, + 0xcaa25178}, + {0x00000000, 0xd4ea739b, 0xe9d396ed, 0x3d39e576, 0x93a15c00, + 0x474b2f9b, 0x7a72caed, 0xae98b976, 0x2643b900, 0xf2a9ca9b, + 0xcf902fed, 0x1b7a5c76, 0xb5e2e500, 0x6108969b, 0x5c3173ed, + 0x88db0076, 0x4c867201, 0x986c019a, 0xa555e4ec, 0x71bf9777, + 0xdf272e01, 0x0bcd5d9a, 0x36f4b8ec, 0xe21ecb77, 0x6ac5cb01, + 0xbe2fb89a, 0x83165dec, 0x57fc2e77, 0xf9649701, 0x2d8ee49a, + 0x10b701ec, 0xc45d7277, 0x980ce502, 0x4ce69699, 0x71df73ef, + 0xa5350074, 0x0badb902, 0xdf47ca99, 0xe27e2fef, 0x36945c74, + 0xbe4f5c02, 0x6aa52f99, 0x579ccaef, 0x8376b974, 0x2dee0002, + 0xf9047399, 0xc43d96ef, 0x10d7e574, 0xd48a9703, 0x0060e498, + 0x3d5901ee, 0xe9b37275, 0x472bcb03, 0x93c1b898, 0xaef85dee, + 0x7a122e75, 0xf2c92e03, 0x26235d98, 0x1b1ab8ee, 0xcff0cb75, + 0x61687203, 0xb5820198, 0x88bbe4ee, 0x5c519775, 0x3019ca05, + 0xe4f3b99e, 0xd9ca5ce8, 0x0d202f73, 0xa3b89605, 0x7752e59e, + 0x4a6b00e8, 0x9e817373, 0x165a7305, 0xc2b0009e, 0xff89e5e8, + 0x2b639673, 0x85fb2f05, 0x51115c9e, 0x6c28b9e8, 0xb8c2ca73, + 0x7c9fb804, 0xa875cb9f, 0x954c2ee9, 0x41a65d72, 0xef3ee404, + 0x3bd4979f, 0x06ed72e9, 0xd2070172, 0x5adc0104, 0x8e36729f, + 0xb30f97e9, 0x67e5e472, 0xc97d5d04, 0x1d972e9f, 0x20aecbe9, + 0xf444b872, 0xa8152f07, 0x7cff5c9c, 0x41c6b9ea, 0x952cca71, + 0x3bb47307, 0xef5e009c, 0xd267e5ea, 0x068d9671, 0x8e569607, + 0x5abce59c, 0x678500ea, 0xb36f7371, 0x1df7ca07, 0xc91db99c, + 0xf4245cea, 0x20ce2f71, 0xe4935d06, 0x30792e9d, 0x0d40cbeb, + 0xd9aab870, 0x77320106, 0xa3d8729d, 0x9ee197eb, 0x4a0be470, + 0xc2d0e406, 0x163a979d, 0x2b0372eb, 0xffe90170, 0x5171b806, + 0x859bcb9d, 0xb8a22eeb, 0x6c485d70, 0x6032940b, 0xb4d8e790, + 0x89e102e6, 0x5d0b717d, 0xf393c80b, 0x2779bb90, 0x1a405ee6, + 0xceaa2d7d, 0x46712d0b, 0x929b5e90, 0xafa2bbe6, 0x7b48c87d, + 0xd5d0710b, 0x013a0290, 0x3c03e7e6, 0xe8e9947d, 0x2cb4e60a, + 0xf85e9591, 0xc56770e7, 0x118d037c, 0xbf15ba0a, 0x6bffc991, + 0x56c62ce7, 0x822c5f7c, 0x0af75f0a, 0xde1d2c91, 0xe324c9e7, + 0x37ceba7c, 0x9956030a, 0x4dbc7091, 0x708595e7, 0xa46fe67c, + 0xf83e7109, 0x2cd40292, 0x11ede7e4, 0xc507947f, 0x6b9f2d09, + 0xbf755e92, 0x824cbbe4, 0x56a6c87f, 0xde7dc809, 0x0a97bb92, + 0x37ae5ee4, 0xe3442d7f, 0x4ddc9409, 0x9936e792, 0xa40f02e4, + 0x70e5717f, 0xb4b80308, 0x60527093, 0x5d6b95e5, 0x8981e67e, + 0x27195f08, 0xf3f32c93, 0xcecac9e5, 0x1a20ba7e, 0x92fbba08, + 0x4611c993, 0x7b282ce5, 0xafc25f7e, 0x015ae608, 0xd5b09593, + 0xe88970e5, 0x3c63037e, 0x502b5e0e, 0x84c12d95, 0xb9f8c8e3, + 0x6d12bb78, 0xc38a020e, 0x17607195, 0x2a5994e3, 0xfeb3e778, + 0x7668e70e, 0xa2829495, 0x9fbb71e3, 0x4b510278, 0xe5c9bb0e, + 0x3123c895, 0x0c1a2de3, 0xd8f05e78, 0x1cad2c0f, 0xc8475f94, + 0xf57ebae2, 0x2194c979, 0x8f0c700f, 0x5be60394, 0x66dfe6e2, + 0xb2359579, 0x3aee950f, 0xee04e694, 0xd33d03e2, 0x07d77079, + 0xa94fc90f, 0x7da5ba94, 0x409c5fe2, 0x94762c79, 0xc827bb0c, + 0x1ccdc897, 0x21f42de1, 0xf51e5e7a, 0x5b86e70c, 0x8f6c9497, + 0xb25571e1, 0x66bf027a, 0xee64020c, 0x3a8e7197, 0x07b794e1, + 0xd35de77a, 0x7dc55e0c, 0xa92f2d97, 0x9416c8e1, 0x40fcbb7a, + 0x84a1c90d, 0x504bba96, 0x6d725fe0, 0xb9982c7b, 0x1700950d, + 0xc3eae696, 0xfed303e0, 0x2a39707b, 0xa2e2700d, 0x76080396, + 0x4b31e6e0, 0x9fdb957b, 0x31432c0d, 0xe5a95f96, 0xd890bae0, + 0x0c7ac97b}, + {0x00000000, 0x27652581, 0x0fcc3bd9, 0x28a91e58, 0x5f9e0669, + 0x78fb23e8, 0x50523db0, 0x77371831, 0xbe3c0dd2, 0x99592853, + 0xb1f0360b, 0x9695138a, 0xe1a20bbb, 0xc6c72e3a, 0xee6e3062, + 0xc90b15e3, 0x3d7f6b7f, 0x1a1a4efe, 0x32b350a6, 0x15d67527, + 0x62e16d16, 0x45844897, 0x6d2d56cf, 0x4a48734e, 0x834366ad, + 0xa426432c, 0x8c8f5d74, 0xabea78f5, 0xdcdd60c4, 0xfbb84545, + 0xd3115b1d, 0xf4747e9c, 0x7afed6fe, 0x5d9bf37f, 0x7532ed27, + 0x5257c8a6, 0x2560d097, 0x0205f516, 0x2aaceb4e, 0x0dc9cecf, + 0xc4c2db2c, 0xe3a7fead, 0xcb0ee0f5, 0xec6bc574, 0x9b5cdd45, + 0xbc39f8c4, 0x9490e69c, 0xb3f5c31d, 0x4781bd81, 0x60e49800, + 0x484d8658, 0x6f28a3d9, 0x181fbbe8, 0x3f7a9e69, 0x17d38031, + 0x30b6a5b0, 0xf9bdb053, 0xded895d2, 0xf6718b8a, 0xd114ae0b, + 0xa623b63a, 0x814693bb, 0xa9ef8de3, 0x8e8aa862, 0xb5fadc26, + 0x929ff9a7, 0xba36e7ff, 0x9d53c27e, 0xea64da4f, 0xcd01ffce, + 0xe5a8e196, 0xc2cdc417, 0x0bc6d1f4, 0x2ca3f475, 0x040aea2d, + 0x236fcfac, 0x5458d79d, 0x733df21c, 0x5b94ec44, 0x7cf1c9c5, + 0x8885b759, 0xafe092d8, 0x87498c80, 0xa02ca901, 0xd71bb130, + 0xf07e94b1, 0xd8d78ae9, 0xffb2af68, 0x36b9ba8b, 0x11dc9f0a, + 0x39758152, 0x1e10a4d3, 0x6927bce2, 0x4e429963, 0x66eb873b, + 0x418ea2ba, 0xcf040ad8, 0xe8612f59, 0xc0c83101, 0xe7ad1480, + 0x909a0cb1, 0xb7ff2930, 0x9f563768, 0xb83312e9, 0x7138070a, + 0x565d228b, 0x7ef43cd3, 0x59911952, 0x2ea60163, 0x09c324e2, + 0x216a3aba, 0x060f1f3b, 0xf27b61a7, 0xd51e4426, 0xfdb75a7e, + 0xdad27fff, 0xade567ce, 0x8a80424f, 0xa2295c17, 0x854c7996, + 0x4c476c75, 0x6b2249f4, 0x438b57ac, 0x64ee722d, 0x13d96a1c, + 0x34bc4f9d, 0x1c1551c5, 0x3b707444, 0x6af5b94d, 0x4d909ccc, + 0x65398294, 0x425ca715, 0x356bbf24, 0x120e9aa5, 0x3aa784fd, + 0x1dc2a17c, 0xd4c9b49f, 0xf3ac911e, 0xdb058f46, 0xfc60aac7, + 0x8b57b2f6, 0xac329777, 0x849b892f, 0xa3feacae, 0x578ad232, + 0x70eff7b3, 0x5846e9eb, 0x7f23cc6a, 0x0814d45b, 0x2f71f1da, + 0x07d8ef82, 0x20bdca03, 0xe9b6dfe0, 0xced3fa61, 0xe67ae439, + 0xc11fc1b8, 0xb628d989, 0x914dfc08, 0xb9e4e250, 0x9e81c7d1, + 0x100b6fb3, 0x376e4a32, 0x1fc7546a, 0x38a271eb, 0x4f9569da, + 0x68f04c5b, 0x40595203, 0x673c7782, 0xae376261, 0x895247e0, + 0xa1fb59b8, 0x869e7c39, 0xf1a96408, 0xd6cc4189, 0xfe655fd1, + 0xd9007a50, 0x2d7404cc, 0x0a11214d, 0x22b83f15, 0x05dd1a94, + 0x72ea02a5, 0x558f2724, 0x7d26397c, 0x5a431cfd, 0x9348091e, + 0xb42d2c9f, 0x9c8432c7, 0xbbe11746, 0xccd60f77, 0xebb32af6, + 0xc31a34ae, 0xe47f112f, 0xdf0f656b, 0xf86a40ea, 0xd0c35eb2, + 0xf7a67b33, 0x80916302, 0xa7f44683, 0x8f5d58db, 0xa8387d5a, + 0x613368b9, 0x46564d38, 0x6eff5360, 0x499a76e1, 0x3ead6ed0, + 0x19c84b51, 0x31615509, 0x16047088, 0xe2700e14, 0xc5152b95, + 0xedbc35cd, 0xcad9104c, 0xbdee087d, 0x9a8b2dfc, 0xb22233a4, + 0x95471625, 0x5c4c03c6, 0x7b292647, 0x5380381f, 0x74e51d9e, + 0x03d205af, 0x24b7202e, 0x0c1e3e76, 0x2b7b1bf7, 0xa5f1b395, + 0x82949614, 0xaa3d884c, 0x8d58adcd, 0xfa6fb5fc, 0xdd0a907d, + 0xf5a38e25, 0xd2c6aba4, 0x1bcdbe47, 0x3ca89bc6, 0x1401859e, + 0x3364a01f, 0x4453b82e, 0x63369daf, 0x4b9f83f7, 0x6cfaa676, + 0x988ed8ea, 0xbfebfd6b, 0x9742e333, 0xb027c6b2, 0xc710de83, + 0xe075fb02, 0xc8dce55a, 0xefb9c0db, 0x26b2d538, 0x01d7f0b9, + 0x297eeee1, 0x0e1bcb60, 0x792cd351, 0x5e49f6d0, 0x76e0e888, + 0x5185cd09}}; + +#endif + +#endif + +#endif + +local const z_crc_t FAR x2n_table[] = { + 0x40000000, 0x20000000, 0x08000000, 0x00800000, 0x00008000, + 0xedb88320, 0xb1e6b092, 0xa06a2517, 0xed627dae, 0x88d14467, + 0xd7bbfe6a, 0xec447f11, 0x8e7ea170, 0x6427800e, 0x4d47bae0, + 0x09fe548f, 0x83852d0f, 0x30362f1a, 0x7b5a9cc3, 0x31fec169, + 0x9fec022a, 0x6c8dedc4, 0x15d6874d, 0x5fde7a4e, 0xbad90e37, + 0x2e4e5eef, 0x4eaba214, 0xa8a472c0, 0x429a969e, 0x148d302a, + 0xc40ba6d0, 0xc4e22c3c}; diff --git a/common/zlib/deflate.c b/common/zlib/deflate.c old mode 100755 new mode 100644 index 872325f..012ea81 --- a/common/zlib/deflate.c +++ b/common/zlib/deflate.c @@ -1,5 +1,5 @@ /* deflate.c -- compress data using the deflation algorithm - * Copyright (C) 1995-2017 Jean-loup Gailly and Mark Adler + * Copyright (C) 1995-2024 Jean-loup Gailly and Mark Adler * For conditions of distribution and use, see copyright notice in zlib.h */ @@ -52,7 +52,7 @@ #include "deflate.h" const char deflate_copyright[] = - " deflate 1.2.11 Copyright 1995-2017 Jean-loup Gailly and Mark Adler "; + " deflate 1.3.1 Copyright 1995-2024 Jean-loup Gailly and Mark Adler "; /* If you use the zlib library in a product, an acknowledgment is welcome in the documentation of your product. If for some reason you cannot @@ -60,9 +60,6 @@ const char deflate_copyright[] = copyright string in the executable of your product. */ -/* =========================================================================== - * Function prototypes. - */ typedef enum { need_more, /* block not completed, need more input or more output */ block_done, /* block flush performed */ @@ -70,35 +67,16 @@ typedef enum { finish_done /* finish done, accept no more input or output */ } block_state; -typedef block_state (*compress_func) OF((deflate_state *s, int flush)); +typedef block_state (*compress_func)(deflate_state *s, int flush); /* Compression function. Returns the block state after the call. */ -local int deflateStateCheck OF((z_streamp strm)); -local void slide_hash OF((deflate_state *s)); -local void fill_window OF((deflate_state *s)); -local block_state deflate_stored OF((deflate_state *s, int flush)); -local block_state deflate_fast OF((deflate_state *s, int flush)); +local block_state deflate_stored(deflate_state *s, int flush); +local block_state deflate_fast(deflate_state *s, int flush); #ifndef FASTEST -local block_state deflate_slow OF((deflate_state *s, int flush)); -#endif -local block_state deflate_rle OF((deflate_state *s, int flush)); -local block_state deflate_huff OF((deflate_state *s, int flush)); -local void lm_init OF((deflate_state *s)); -local void putShortMSB OF((deflate_state *s, uInt b)); -local void flush_pending OF((z_streamp strm)); -local unsigned read_buf OF((z_streamp strm, Bytef *buf, unsigned size)); -#ifdef ASMV -# pragma message("Assembler code may have bugs -- use at your own risk") - void match_init OF((void)); /* asm code initialization */ - uInt longest_match OF((deflate_state *s, IPos cur_match)); -#else -local uInt longest_match OF((deflate_state *s, IPos cur_match)); -#endif - -#ifdef ZLIB_DEBUG -local void check_match OF((deflate_state *s, IPos start, IPos match, - int length)); +local block_state deflate_slow(deflate_state *s, int flush); #endif +local block_state deflate_rle(deflate_state *s, int flush); +local block_state deflate_huff(deflate_state *s, int flush); /* =========================================================================== * Local data @@ -160,7 +138,7 @@ local const config configuration_table[10] = { * characters, so that a running hash key can be computed from the previous * key instead of complete recalculation each time. */ -#define UPDATE_HASH(s,h,c) (h = (((h)<hash_shift) ^ (c)) & s->hash_mask) +#define UPDATE_HASH(s,h,c) (h = (((h) << s->hash_shift) ^ (c)) & s->hash_mask) /* =========================================================================== @@ -191,9 +169,9 @@ local const config configuration_table[10] = { */ #define CLEAR_HASH(s) \ do { \ - s->head[s->hash_size-1] = NIL; \ + s->head[s->hash_size - 1] = NIL; \ zmemzero((Bytef *)s->head, \ - (unsigned)(s->hash_size-1)*sizeof(*s->head)); \ + (unsigned)(s->hash_size - 1)*sizeof(*s->head)); \ } while (0) /* =========================================================================== @@ -201,9 +179,12 @@ local const config configuration_table[10] = { * bit values at the expense of memory usage). We slide even when level == 0 to * keep the hash table consistent if we switch back to level > 0 later. */ -local void slide_hash(s) - deflate_state *s; -{ +#if defined(__has_feature) +# if __has_feature(memory_sanitizer) + __attribute__((no_sanitize("memory"))) +# endif +#endif +local void slide_hash(deflate_state *s) { unsigned n, m; Posf *p; uInt wsize = s->w_size; @@ -227,39 +208,181 @@ local void slide_hash(s) #endif } +/* =========================================================================== + * Read a new buffer from the current input stream, update the adler32 + * and total number of bytes read. All deflate() input goes through + * this function so some applications may wish to modify it to avoid + * allocating a large strm->next_in buffer and copying from it. + * (See also flush_pending()). + */ +local unsigned read_buf(z_streamp strm, Bytef *buf, unsigned size) { + unsigned len = strm->avail_in; + + if (len > size) len = size; + if (len == 0) return 0; + + strm->avail_in -= len; + + zmemcpy(buf, strm->next_in, len); + if (strm->state->wrap == 1) { + strm->adler = adler32(strm->adler, buf, len); + } +#ifdef GZIP + else if (strm->state->wrap == 2) { + strm->adler = crc32(strm->adler, buf, len); + } +#endif + strm->next_in += len; + strm->total_in += len; + + return len; +} + +/* =========================================================================== + * Fill the window when the lookahead becomes insufficient. + * Updates strstart and lookahead. + * + * IN assertion: lookahead < MIN_LOOKAHEAD + * OUT assertions: strstart <= window_size-MIN_LOOKAHEAD + * At least one byte has been read, or avail_in == 0; reads are + * performed for at least two bytes (required for the zip translate_eol + * option -- not supported here). + */ +local void fill_window(deflate_state *s) { + unsigned n; + unsigned more; /* Amount of free space at the end of the window. */ + uInt wsize = s->w_size; + + Assert(s->lookahead < MIN_LOOKAHEAD, "already enough lookahead"); + + do { + more = (unsigned)(s->window_size -(ulg)s->lookahead -(ulg)s->strstart); + + /* Deal with !@#$% 64K limit: */ + if (sizeof(int) <= 2) { + if (more == 0 && s->strstart == 0 && s->lookahead == 0) { + more = wsize; + + } else if (more == (unsigned)(-1)) { + /* Very unlikely, but possible on 16 bit machine if + * strstart == 0 && lookahead == 1 (input done a byte at time) + */ + more--; + } + } + + /* If the window is almost full and there is insufficient lookahead, + * move the upper half to the lower one to make room in the upper half. + */ + if (s->strstart >= wsize + MAX_DIST(s)) { + + zmemcpy(s->window, s->window + wsize, (unsigned)wsize - more); + s->match_start -= wsize; + s->strstart -= wsize; /* we now have strstart >= MAX_DIST */ + s->block_start -= (long) wsize; + if (s->insert > s->strstart) + s->insert = s->strstart; + slide_hash(s); + more += wsize; + } + if (s->strm->avail_in == 0) break; + + /* If there was no sliding: + * strstart <= WSIZE+MAX_DIST-1 && lookahead <= MIN_LOOKAHEAD - 1 && + * more == window_size - lookahead - strstart + * => more >= window_size - (MIN_LOOKAHEAD-1 + WSIZE + MAX_DIST-1) + * => more >= window_size - 2*WSIZE + 2 + * In the BIG_MEM or MMAP case (not yet supported), + * window_size == input_size + MIN_LOOKAHEAD && + * strstart + s->lookahead <= input_size => more >= MIN_LOOKAHEAD. + * Otherwise, window_size == 2*WSIZE so more >= 2. + * If there was sliding, more >= WSIZE. So in all cases, more >= 2. + */ + Assert(more >= 2, "more < 2"); + + n = read_buf(s->strm, s->window + s->strstart + s->lookahead, more); + s->lookahead += n; + + /* Initialize the hash value now that we have some input: */ + if (s->lookahead + s->insert >= MIN_MATCH) { + uInt str = s->strstart - s->insert; + s->ins_h = s->window[str]; + UPDATE_HASH(s, s->ins_h, s->window[str + 1]); +#if MIN_MATCH != 3 + Call UPDATE_HASH() MIN_MATCH-3 more times +#endif + while (s->insert) { + UPDATE_HASH(s, s->ins_h, s->window[str + MIN_MATCH-1]); +#ifndef FASTEST + s->prev[str & s->w_mask] = s->head[s->ins_h]; +#endif + s->head[s->ins_h] = (Pos)str; + str++; + s->insert--; + if (s->lookahead + s->insert < MIN_MATCH) + break; + } + } + /* If the whole input has less than MIN_MATCH bytes, ins_h is garbage, + * but this is not important since only literal bytes will be emitted. + */ + + } while (s->lookahead < MIN_LOOKAHEAD && s->strm->avail_in != 0); + + /* If the WIN_INIT bytes after the end of the current data have never been + * written, then zero those bytes in order to avoid memory check reports of + * the use of uninitialized (or uninitialised as Julian writes) bytes by + * the longest match routines. Update the high water mark for the next + * time through here. WIN_INIT is set to MAX_MATCH since the longest match + * routines allow scanning to strstart + MAX_MATCH, ignoring lookahead. + */ + if (s->high_water < s->window_size) { + ulg curr = s->strstart + (ulg)(s->lookahead); + ulg init; + + if (s->high_water < curr) { + /* Previous high water mark below current data -- zero WIN_INIT + * bytes or up to end of window, whichever is less. + */ + init = s->window_size - curr; + if (init > WIN_INIT) + init = WIN_INIT; + zmemzero(s->window + curr, (unsigned)init); + s->high_water = curr + init; + } + else if (s->high_water < (ulg)curr + WIN_INIT) { + /* High water mark at or above current data, but below current data + * plus WIN_INIT -- zero out to current data plus WIN_INIT, or up + * to end of window, whichever is less. + */ + init = (ulg)curr + WIN_INIT - s->high_water; + if (init > s->window_size - s->high_water) + init = s->window_size - s->high_water; + zmemzero(s->window + s->high_water, (unsigned)init); + s->high_water += init; + } + } + + Assert((ulg)s->strstart <= s->window_size - MIN_LOOKAHEAD, + "not enough room for search"); +} + /* ========================================================================= */ -int ZEXPORT deflateInit_(strm, level, version, stream_size) - z_streamp strm; - int level; - const char *version; - int stream_size; -{ +int ZEXPORT deflateInit_(z_streamp strm, int level, const char *version, + int stream_size) { return deflateInit2_(strm, level, Z_DEFLATED, MAX_WBITS, DEF_MEM_LEVEL, Z_DEFAULT_STRATEGY, version, stream_size); /* To do: ignore strm->next_in if we use it as window */ } /* ========================================================================= */ -int ZEXPORT deflateInit2_(strm, level, method, windowBits, memLevel, strategy, - version, stream_size) - z_streamp strm; - int level; - int method; - int windowBits; - int memLevel; - int strategy; - const char *version; - int stream_size; -{ +int ZEXPORT deflateInit2_(z_streamp strm, int level, int method, + int windowBits, int memLevel, int strategy, + const char *version, int stream_size) { deflate_state *s; int wrap = 1; static const char my_version[] = ZLIB_VERSION; - ushf *overlay; - /* We overlay pending_buf and d_buf+l_buf. This works since the average - * output size for (length,distance) codes is <= 24 bits. - */ - if (version == Z_NULL || version[0] != my_version[0] || stream_size != sizeof(z_stream)) { return Z_VERSION_ERROR; @@ -290,6 +413,8 @@ int ZEXPORT deflateInit2_(strm, level, method, windowBits, memLevel, strategy, if (windowBits < 0) { /* suppress zlib wrapper */ wrap = 0; + if (windowBits < -15) + return Z_STREAM_ERROR; windowBits = -windowBits; } #ifdef GZIP @@ -319,7 +444,7 @@ int ZEXPORT deflateInit2_(strm, level, method, windowBits, memLevel, strategy, s->hash_bits = (uInt)memLevel + 7; s->hash_size = 1 << s->hash_bits; s->hash_mask = s->hash_size - 1; - s->hash_shift = ((s->hash_bits+MIN_MATCH-1)/MIN_MATCH); + s->hash_shift = ((s->hash_bits + MIN_MATCH-1) / MIN_MATCH); s->window = (Bytef *) ZALLOC(strm, s->w_size, 2*sizeof(Byte)); s->prev = (Posf *) ZALLOC(strm, s->w_size, sizeof(Pos)); @@ -329,9 +454,47 @@ int ZEXPORT deflateInit2_(strm, level, method, windowBits, memLevel, strategy, s->lit_bufsize = 1 << (memLevel + 6); /* 16K elements by default */ - overlay = (ushf *) ZALLOC(strm, s->lit_bufsize, sizeof(ush)+2); - s->pending_buf = (uchf *) overlay; - s->pending_buf_size = (ulg)s->lit_bufsize * (sizeof(ush)+2L); + /* We overlay pending_buf and sym_buf. This works since the average size + * for length/distance pairs over any compressed block is assured to be 31 + * bits or less. + * + * Analysis: The longest fixed codes are a length code of 8 bits plus 5 + * extra bits, for lengths 131 to 257. The longest fixed distance codes are + * 5 bits plus 13 extra bits, for distances 16385 to 32768. The longest + * possible fixed-codes length/distance pair is then 31 bits total. + * + * sym_buf starts one-fourth of the way into pending_buf. So there are + * three bytes in sym_buf for every four bytes in pending_buf. Each symbol + * in sym_buf is three bytes -- two for the distance and one for the + * literal/length. As each symbol is consumed, the pointer to the next + * sym_buf value to read moves forward three bytes. From that symbol, up to + * 31 bits are written to pending_buf. The closest the written pending_buf + * bits gets to the next sym_buf symbol to read is just before the last + * code is written. At that time, 31*(n - 2) bits have been written, just + * after 24*(n - 2) bits have been consumed from sym_buf. sym_buf starts at + * 8*n bits into pending_buf. (Note that the symbol buffer fills when n - 1 + * symbols are written.) The closest the writing gets to what is unread is + * then n + 14 bits. Here n is lit_bufsize, which is 16384 by default, and + * can range from 128 to 32768. + * + * Therefore, at a minimum, there are 142 bits of space between what is + * written and what is read in the overlain buffers, so the symbols cannot + * be overwritten by the compressed data. That space is actually 139 bits, + * due to the three-bit fixed-code block header. + * + * That covers the case where either Z_FIXED is specified, forcing fixed + * codes, or when the use of fixed codes is chosen, because that choice + * results in a smaller compressed block than dynamic codes. That latter + * condition then assures that the above analysis also covers all dynamic + * blocks. A dynamic-code block will only be chosen to be emitted if it has + * fewer bits than a fixed-code block would for the same set of symbols. + * Therefore its average symbol length is assured to be less than 31. So + * the compressed data for a dynamic block also cannot overwrite the + * symbols from which it is being constructed. + */ + + s->pending_buf = (uchf *) ZALLOC(strm, s->lit_bufsize, LIT_BUFS); + s->pending_buf_size = (ulg)s->lit_bufsize * 4; if (s->window == Z_NULL || s->prev == Z_NULL || s->head == Z_NULL || s->pending_buf == Z_NULL) { @@ -340,8 +503,18 @@ int ZEXPORT deflateInit2_(strm, level, method, windowBits, memLevel, strategy, deflateEnd (strm); return Z_MEM_ERROR; } - s->d_buf = overlay + s->lit_bufsize/sizeof(ush); - s->l_buf = s->pending_buf + (1+sizeof(ush))*s->lit_bufsize; +#ifdef LIT_MEM + s->d_buf = (ushf *)(s->pending_buf + (s->lit_bufsize << 1)); + s->l_buf = s->pending_buf + (s->lit_bufsize << 2); + s->sym_end = s->lit_bufsize - 1; +#else + s->sym_buf = s->pending_buf + s->lit_bufsize; + s->sym_end = (s->lit_bufsize - 1) * 3; +#endif + /* We avoid equality with lit_bufsize*3 because of wraparound at 64K + * on 16 bit machines and because stored blocks are restricted to + * 64K-1 bytes. + */ s->level = level; s->strategy = strategy; @@ -353,9 +526,7 @@ int ZEXPORT deflateInit2_(strm, level, method, windowBits, memLevel, strategy, /* ========================================================================= * Check for a valid deflate stream state. Return 0 if ok, 1 if not. */ -local int deflateStateCheck (strm) - z_streamp strm; -{ +local int deflateStateCheck(z_streamp strm) { deflate_state *s; if (strm == Z_NULL || strm->zalloc == (alloc_func)0 || strm->zfree == (free_func)0) @@ -376,11 +547,8 @@ local int deflateStateCheck (strm) } /* ========================================================================= */ -int ZEXPORT deflateSetDictionary (strm, dictionary, dictLength) - z_streamp strm; - const Bytef *dictionary; - uInt dictLength; -{ +int ZEXPORT deflateSetDictionary(z_streamp strm, const Bytef *dictionary, + uInt dictLength) { deflate_state *s; uInt str, n; int wrap; @@ -445,11 +613,8 @@ int ZEXPORT deflateSetDictionary (strm, dictionary, dictLength) } /* ========================================================================= */ -int ZEXPORT deflateGetDictionary (strm, dictionary, dictLength) - z_streamp strm; - Bytef *dictionary; - uInt *dictLength; -{ +int ZEXPORT deflateGetDictionary(z_streamp strm, Bytef *dictionary, + uInt *dictLength) { deflate_state *s; uInt len; @@ -467,9 +632,7 @@ int ZEXPORT deflateGetDictionary (strm, dictionary, dictLength) } /* ========================================================================= */ -int ZEXPORT deflateResetKeep (strm) - z_streamp strm; -{ +int ZEXPORT deflateResetKeep(z_streamp strm) { deflate_state *s; if (deflateStateCheck(strm)) { @@ -491,23 +654,45 @@ int ZEXPORT deflateResetKeep (strm) #ifdef GZIP s->wrap == 2 ? GZIP_STATE : #endif - s->wrap ? INIT_STATE : BUSY_STATE; + INIT_STATE; strm->adler = #ifdef GZIP s->wrap == 2 ? crc32(0L, Z_NULL, 0) : #endif adler32(0L, Z_NULL, 0); - s->last_flush = Z_NO_FLUSH; + s->last_flush = -2; _tr_init(s); return Z_OK; } +/* =========================================================================== + * Initialize the "longest match" routines for a new zlib stream + */ +local void lm_init(deflate_state *s) { + s->window_size = (ulg)2L*s->w_size; + + CLEAR_HASH(s); + + /* Set the default configuration parameters: + */ + s->max_lazy_match = configuration_table[s->level].max_lazy; + s->good_match = configuration_table[s->level].good_length; + s->nice_match = configuration_table[s->level].nice_length; + s->max_chain_length = configuration_table[s->level].max_chain; + + s->strstart = 0; + s->block_start = 0L; + s->lookahead = 0; + s->insert = 0; + s->match_length = s->prev_length = MIN_MATCH-1; + s->match_available = 0; + s->ins_h = 0; +} + /* ========================================================================= */ -int ZEXPORT deflateReset (strm) - z_streamp strm; -{ +int ZEXPORT deflateReset(z_streamp strm) { int ret; ret = deflateResetKeep(strm); @@ -517,10 +702,7 @@ int ZEXPORT deflateReset (strm) } /* ========================================================================= */ -int ZEXPORT deflateSetHeader (strm, head) - z_streamp strm; - gz_headerp head; -{ +int ZEXPORT deflateSetHeader(z_streamp strm, gz_headerp head) { if (deflateStateCheck(strm) || strm->state->wrap != 2) return Z_STREAM_ERROR; strm->state->gzhead = head; @@ -528,11 +710,7 @@ int ZEXPORT deflateSetHeader (strm, head) } /* ========================================================================= */ -int ZEXPORT deflatePending (strm, pending, bits) - unsigned *pending; - int *bits; - z_streamp strm; -{ +int ZEXPORT deflatePending(z_streamp strm, unsigned *pending, int *bits) { if (deflateStateCheck(strm)) return Z_STREAM_ERROR; if (pending != Z_NULL) *pending = strm->state->pending; @@ -542,18 +720,21 @@ int ZEXPORT deflatePending (strm, pending, bits) } /* ========================================================================= */ -int ZEXPORT deflatePrime (strm, bits, value) - z_streamp strm; - int bits; - int value; -{ +int ZEXPORT deflatePrime(z_streamp strm, int bits, int value) { deflate_state *s; int put; if (deflateStateCheck(strm)) return Z_STREAM_ERROR; s = strm->state; - if ((Bytef *)(s->d_buf) < s->pending_out + ((Buf_size + 7) >> 3)) +#ifdef LIT_MEM + if (bits < 0 || bits > 16 || + (uchf *)s->d_buf < s->pending_out + ((Buf_size + 7) >> 3)) return Z_BUF_ERROR; +#else + if (bits < 0 || bits > 16 || + s->sym_buf < s->pending_out + ((Buf_size + 7) >> 3)) + return Z_BUF_ERROR; +#endif do { put = Buf_size - s->bi_valid; if (put > bits) @@ -568,11 +749,7 @@ int ZEXPORT deflatePrime (strm, bits, value) } /* ========================================================================= */ -int ZEXPORT deflateParams(strm, level, strategy) - z_streamp strm; - int level; - int strategy; -{ +int ZEXPORT deflateParams(z_streamp strm, int level, int strategy) { deflate_state *s; compress_func func; @@ -590,21 +767,20 @@ int ZEXPORT deflateParams(strm, level, strategy) func = configuration_table[s->level].func; if ((strategy != s->strategy || func != configuration_table[level].func) && - s->high_water) { + s->last_flush != -2) { /* Flush the last buffer: */ int err = deflate(strm, Z_BLOCK); if (err == Z_STREAM_ERROR) return err; - if (strm->avail_out == 0) + if (strm->avail_in || (s->strstart - s->block_start) + s->lookahead) return Z_BUF_ERROR; } if (s->level != level) { if (s->level == 0 && s->matches != 0) { - if (s->matches == 1) { + if (s->matches == 1) slide_hash(s); - } else { + else CLEAR_HASH(s); - } s->matches = 0; } s->level = level; @@ -618,13 +794,8 @@ int ZEXPORT deflateParams(strm, level, strategy) } /* ========================================================================= */ -int ZEXPORT deflateTune(strm, good_length, max_lazy, nice_length, max_chain) - z_streamp strm; - int good_length; - int max_lazy; - int nice_length; - int max_chain; -{ +int ZEXPORT deflateTune(z_streamp strm, int good_length, int max_lazy, + int nice_length, int max_chain) { deflate_state *s; if (deflateStateCheck(strm)) return Z_STREAM_ERROR; @@ -637,36 +808,47 @@ int ZEXPORT deflateTune(strm, good_length, max_lazy, nice_length, max_chain) } /* ========================================================================= - * For the default windowBits of 15 and memLevel of 8, this function returns - * a close to exact, as well as small, upper bound on the compressed size. - * They are coded as constants here for a reason--if the #define's are - * changed, then this function needs to be changed as well. The return - * value for 15 and 8 only works for those exact settings. + * For the default windowBits of 15 and memLevel of 8, this function returns a + * close to exact, as well as small, upper bound on the compressed size. This + * is an expansion of ~0.03%, plus a small constant. * - * For any setting other than those defaults for windowBits and memLevel, - * the value returned is a conservative worst case for the maximum expansion - * resulting from using fixed blocks instead of stored blocks, which deflate - * can emit on compressed data for some combinations of the parameters. + * For any setting other than those defaults for windowBits and memLevel, one + * of two worst case bounds is returned. This is at most an expansion of ~4% or + * ~13%, plus a small constant. * - * This function could be more sophisticated to provide closer upper bounds for - * every combination of windowBits and memLevel. But even the conservative - * upper bound of about 14% expansion does not seem onerous for output buffer - * allocation. + * Both the 0.03% and 4% derive from the overhead of stored blocks. The first + * one is for stored blocks of 16383 bytes (memLevel == 8), whereas the second + * is for stored blocks of 127 bytes (the worst case memLevel == 1). The + * expansion results from five bytes of header for each stored block. + * + * The larger expansion of 13% results from a window size less than or equal to + * the symbols buffer size (windowBits <= memLevel + 7). In that case some of + * the data being compressed may have slid out of the sliding window, impeding + * a stored block from being emitted. Then the only choice is a fixed or + * dynamic block, where a fixed block limits the maximum expansion to 9 bits + * per 8-bit byte, plus 10 bits for every block. The smallest block size for + * which this can occur is 255 (memLevel == 2). + * + * Shifts are used to approximate divisions, for speed. */ -uLong ZEXPORT deflateBound(strm, sourceLen) - z_streamp strm; - uLong sourceLen; -{ +uLong ZEXPORT deflateBound(z_streamp strm, uLong sourceLen) { deflate_state *s; - uLong complen, wraplen; + uLong fixedlen, storelen, wraplen; - /* conservative upper bound for compressed data */ - complen = sourceLen + - ((sourceLen + 7) >> 3) + ((sourceLen + 63) >> 6) + 5; + /* upper bound for fixed blocks with 9-bit literals and length 255 + (memLevel == 2, which is the lowest that may not use stored blocks) -- + ~13% overhead plus a small constant */ + fixedlen = sourceLen + (sourceLen >> 3) + (sourceLen >> 8) + + (sourceLen >> 9) + 4; - /* if can't get parameters, return conservative bound plus zlib wrapper */ + /* upper bound for stored blocks with length 127 (memLevel == 1) -- + ~4% overhead plus a small constant */ + storelen = sourceLen + (sourceLen >> 5) + (sourceLen >> 7) + + (sourceLen >> 11) + 7; + + /* if can't get parameters, return larger bound plus a zlib wrapper */ if (deflateStateCheck(strm)) - return complen + 6; + return (fixedlen > storelen ? fixedlen : storelen) + 6; /* compute wrapper length */ s = strm->state; @@ -703,11 +885,13 @@ uLong ZEXPORT deflateBound(strm, sourceLen) wraplen = 6; } - /* if not default parameters, return conservative bound */ + /* if not default parameters, return one of the conservative bounds */ if (s->w_bits != 15 || s->hash_bits != 8 + 7) - return complen + wraplen; + return (s->w_bits <= s->hash_bits && s->level ? fixedlen : storelen) + + wraplen; - /* default settings: return tight bound for that case */ + /* default settings: return tight bound for that case -- ~0.03% overhead + plus a small constant */ return sourceLen + (sourceLen >> 12) + (sourceLen >> 14) + (sourceLen >> 25) + 13 - 6 + wraplen; } @@ -717,10 +901,7 @@ uLong ZEXPORT deflateBound(strm, sourceLen) * IN assertion: the stream state is correct and there is enough room in * pending_buf. */ -local void putShortMSB (s, b) - deflate_state *s; - uInt b; -{ +local void putShortMSB(deflate_state *s, uInt b) { put_byte(s, (Byte)(b >> 8)); put_byte(s, (Byte)(b & 0xff)); } @@ -731,9 +912,7 @@ local void putShortMSB (s, b) * applications may wish to modify it to avoid allocating a large * strm->next_out buffer and copying into it. (See also read_buf()). */ -local void flush_pending(strm) - z_streamp strm; -{ +local void flush_pending(z_streamp strm) { unsigned len; deflate_state *s = strm->state; @@ -764,10 +943,7 @@ local void flush_pending(strm) } while (0) /* ========================================================================= */ -int ZEXPORT deflate (strm, flush) - z_streamp strm; - int flush; -{ +int ZEXPORT deflate(z_streamp strm, int flush) { int old_flush; /* value of flush param for previous deflate call */ deflate_state *s; @@ -815,9 +991,11 @@ int ZEXPORT deflate (strm, flush) } /* Write the header */ + if (s->status == INIT_STATE && s->wrap == 0) + s->status = BUSY_STATE; if (s->status == INIT_STATE) { /* zlib header */ - uInt header = (Z_DEFLATED + ((s->w_bits-8)<<4)) << 8; + uInt header = (Z_DEFLATED + ((s->w_bits - 8) << 4)) << 8; uInt level_flags; if (s->strategy >= Z_HUFFMAN_ONLY || s->level < 2) @@ -1077,9 +1255,7 @@ int ZEXPORT deflate (strm, flush) } /* ========================================================================= */ -int ZEXPORT deflateEnd (strm) - z_streamp strm; -{ +int ZEXPORT deflateEnd(z_streamp strm) { int status; if (deflateStateCheck(strm)) return Z_STREAM_ERROR; @@ -1103,16 +1279,14 @@ int ZEXPORT deflateEnd (strm) * To simplify the source, this is not supported for 16-bit MSDOS (which * doesn't have enough memory anyway to duplicate compression states). */ -int ZEXPORT deflateCopy (dest, source) - z_streamp dest; - z_streamp source; -{ +int ZEXPORT deflateCopy(z_streamp dest, z_streamp source) { #ifdef MAXSEG_64K + (void)dest; + (void)source; return Z_STREAM_ERROR; #else deflate_state *ds; deflate_state *ss; - ushf *overlay; if (deflateStateCheck(source) || dest == Z_NULL) { @@ -1121,19 +1295,18 @@ int ZEXPORT deflateCopy (dest, source) ss = source->state; - zmemcpy((Bytef*)dest, (const Bytef*)source, sizeof(z_stream)); + zmemcpy((voidpf)dest, (voidpf)source, sizeof(z_stream)); ds = (deflate_state *) ZALLOC(dest, 1, sizeof(deflate_state)); if (ds == Z_NULL) return Z_MEM_ERROR; dest->state = (struct internal_state FAR *) ds; - zmemcpy((Bytef*)ds, (const Bytef*)ss, sizeof(deflate_state)); + zmemcpy((voidpf)ds, (voidpf)ss, sizeof(deflate_state)); ds->strm = dest; ds->window = (Bytef *) ZALLOC(dest, ds->w_size, 2*sizeof(Byte)); ds->prev = (Posf *) ZALLOC(dest, ds->w_size, sizeof(Pos)); ds->head = (Posf *) ZALLOC(dest, ds->hash_size, sizeof(Pos)); - overlay = (ushf *) ZALLOC(dest, ds->lit_bufsize, sizeof(ush)+2); - ds->pending_buf = (uchf *) overlay; + ds->pending_buf = (uchf *) ZALLOC(dest, ds->lit_bufsize, LIT_BUFS); if (ds->window == Z_NULL || ds->prev == Z_NULL || ds->head == Z_NULL || ds->pending_buf == Z_NULL) { @@ -1142,13 +1315,17 @@ int ZEXPORT deflateCopy (dest, source) } /* following zmemcpy do not work for 16-bit MSDOS */ zmemcpy(ds->window, ss->window, ds->w_size * 2 * sizeof(Byte)); - zmemcpy((Bytef*)ds->prev, (const Bytef*)ss->prev, ds->w_size * sizeof(Pos)); - zmemcpy((Bytef*)ds->head, (const Bytef*)ss->head, ds->hash_size * sizeof(Pos)); - zmemcpy(ds->pending_buf, ss->pending_buf, (uInt)ds->pending_buf_size); + zmemcpy((voidpf)ds->prev, (voidpf)ss->prev, ds->w_size * sizeof(Pos)); + zmemcpy((voidpf)ds->head, (voidpf)ss->head, ds->hash_size * sizeof(Pos)); + zmemcpy(ds->pending_buf, ss->pending_buf, ds->lit_bufsize * LIT_BUFS); ds->pending_out = ds->pending_buf + (ss->pending_out - ss->pending_buf); - ds->d_buf = overlay + ds->lit_bufsize/sizeof(ush); - ds->l_buf = ds->pending_buf + (1+sizeof(ush))*ds->lit_bufsize; +#ifdef LIT_MEM + ds->d_buf = (ushf *)(ds->pending_buf + (ds->lit_bufsize << 1)); + ds->l_buf = ds->pending_buf + (ds->lit_bufsize << 2); +#else + ds->sym_buf = ds->pending_buf + ds->lit_bufsize; +#endif ds->l_desc.dyn_tree = ds->dyn_ltree; ds->d_desc.dyn_tree = ds->dyn_dtree; @@ -1158,71 +1335,6 @@ int ZEXPORT deflateCopy (dest, source) #endif /* MAXSEG_64K */ } -/* =========================================================================== - * Read a new buffer from the current input stream, update the adler32 - * and total number of bytes read. All deflate() input goes through - * this function so some applications may wish to modify it to avoid - * allocating a large strm->next_in buffer and copying from it. - * (See also flush_pending()). - */ -local unsigned read_buf(strm, buf, size) - z_streamp strm; - Bytef *buf; - unsigned size; -{ - unsigned len = strm->avail_in; - - if (len > size) len = size; - if (len == 0) return 0; - - strm->avail_in -= len; - - zmemcpy(buf, strm->next_in, len); - if (strm->state->wrap == 1) { - strm->adler = adler32(strm->adler, buf, len); - } -#ifdef GZIP - else if (strm->state->wrap == 2) { - strm->adler = crc32(strm->adler, buf, len); - } -#endif - strm->next_in += len; - strm->total_in += len; - - return len; -} - -/* =========================================================================== - * Initialize the "longest match" routines for a new zlib stream - */ -local void lm_init (s) - deflate_state *s; -{ - s->window_size = (ulg)2L*s->w_size; - - CLEAR_HASH(s); - - /* Set the default configuration parameters: - */ - s->max_lazy_match = configuration_table[s->level].max_lazy; - s->good_match = configuration_table[s->level].good_length; - s->nice_match = configuration_table[s->level].nice_length; - s->max_chain_length = configuration_table[s->level].max_chain; - - s->strstart = 0; - s->block_start = 0L; - s->lookahead = 0; - s->insert = 0; - s->match_length = s->prev_length = MIN_MATCH-1; - s->match_available = 0; - s->ins_h = 0; -#ifndef FASTEST -#ifdef ASMV - match_init(); /* initialize the asm code */ -#endif -#endif -} - #ifndef FASTEST /* =========================================================================== * Set match_start to the longest match starting at the given string and @@ -1233,14 +1345,7 @@ local void lm_init (s) * string (strstart) and its distance is <= MAX_DIST, and prev_length >= 1 * OUT assertion: the match length is not greater than s->lookahead. */ -#ifndef ASMV -/* For 80x86 and 680x0, an optimized version will be provided in match.asm or - * match.S. The code will be functionally equivalent. - */ -local uInt longest_match(s, cur_match) - deflate_state *s; - IPos cur_match; /* current match */ -{ +local uInt longest_match(deflate_state *s, IPos cur_match) { unsigned chain_length = s->max_chain_length;/* max hash chain length */ register Bytef *scan = s->window + s->strstart; /* current string */ register Bytef *match; /* matched string */ @@ -1261,10 +1366,10 @@ local uInt longest_match(s, cur_match) */ register Bytef *strend = s->window + s->strstart + MAX_MATCH - 1; register ush scan_start = *(ushf*)scan; - register ush scan_end = *(ushf*)(scan+best_len-1); + register ush scan_end = *(ushf*)(scan + best_len - 1); #else register Bytef *strend = s->window + s->strstart + MAX_MATCH; - register Byte scan_end1 = scan[best_len-1]; + register Byte scan_end1 = scan[best_len - 1]; register Byte scan_end = scan[best_len]; #endif @@ -1282,7 +1387,8 @@ local uInt longest_match(s, cur_match) */ if ((uInt)nice_match > s->lookahead) nice_match = (int)s->lookahead; - Assert((ulg)s->strstart <= s->window_size-MIN_LOOKAHEAD, "need lookahead"); + Assert((ulg)s->strstart <= s->window_size - MIN_LOOKAHEAD, + "need lookahead"); do { Assert(cur_match < s->strstart, "no future"); @@ -1300,53 +1406,54 @@ local uInt longest_match(s, cur_match) /* This code assumes sizeof(unsigned short) == 2. Do not use * UNALIGNED_OK if your compiler uses a different size. */ - if (*(ushf*)(match+best_len-1) != scan_end || + if (*(ushf*)(match + best_len - 1) != scan_end || *(ushf*)match != scan_start) continue; /* It is not necessary to compare scan[2] and match[2] since they are * always equal when the other bytes match, given that the hash keys * are equal and that HASH_BITS >= 8. Compare 2 bytes at a time at - * strstart+3, +5, ... up to strstart+257. We check for insufficient + * strstart + 3, + 5, up to strstart + 257. We check for insufficient * lookahead only every 4th comparison; the 128th check will be made - * at strstart+257. If MAX_MATCH-2 is not a multiple of 8, it is + * at strstart + 257. If MAX_MATCH-2 is not a multiple of 8, it is * necessary to put more guard bytes at the end of the window, or * to check more often for insufficient lookahead. */ Assert(scan[2] == match[2], "scan[2]?"); scan++, match++; do { - } while (*(ushf*)(scan+=2) == *(ushf*)(match+=2) && - *(ushf*)(scan+=2) == *(ushf*)(match+=2) && - *(ushf*)(scan+=2) == *(ushf*)(match+=2) && - *(ushf*)(scan+=2) == *(ushf*)(match+=2) && + } while (*(ushf*)(scan += 2) == *(ushf*)(match += 2) && + *(ushf*)(scan += 2) == *(ushf*)(match += 2) && + *(ushf*)(scan += 2) == *(ushf*)(match += 2) && + *(ushf*)(scan += 2) == *(ushf*)(match += 2) && scan < strend); /* The funny "do {}" generates better code on most compilers */ - /* Here, scan <= window+strstart+257 */ - Assert(scan <= s->window+(unsigned)(s->window_size-1), "wild scan"); + /* Here, scan <= window + strstart + 257 */ + Assert(scan <= s->window + (unsigned)(s->window_size - 1), + "wild scan"); if (*scan == *match) scan++; - len = (MAX_MATCH - 1) - (int)(strend-scan); + len = (MAX_MATCH - 1) - (int)(strend - scan); scan = strend - (MAX_MATCH-1); #else /* UNALIGNED_OK */ - if (match[best_len] != scan_end || - match[best_len-1] != scan_end1 || - *match != *scan || - *++match != scan[1]) continue; + if (match[best_len] != scan_end || + match[best_len - 1] != scan_end1 || + *match != *scan || + *++match != scan[1]) continue; - /* The check at best_len-1 can be removed because it will be made + /* The check at best_len - 1 can be removed because it will be made * again later. (This heuristic is not always a win.) * It is not necessary to compare scan[2] and match[2] since they * are always equal when the other bytes match, given that * the hash keys are equal and that HASH_BITS >= 8. */ - scan += 2; match++; + scan += 2, match++; Assert(*scan == *match, "match[2]?"); /* We check for insufficient lookahead only every 8th comparison; - * the 256th check will be made at strstart+258. + * the 256th check will be made at strstart + 258. */ do { } while (*++scan == *++match && *++scan == *++match && @@ -1355,7 +1462,8 @@ local uInt longest_match(s, cur_match) *++scan == *++match && *++scan == *++match && scan < strend); - Assert(scan <= s->window+(unsigned)(s->window_size-1), "wild scan"); + Assert(scan <= s->window + (unsigned)(s->window_size - 1), + "wild scan"); len = MAX_MATCH - (int)(strend - scan); scan = strend - MAX_MATCH; @@ -1367,9 +1475,9 @@ local uInt longest_match(s, cur_match) best_len = len; if (len >= nice_match) break; #ifdef UNALIGNED_OK - scan_end = *(ushf*)(scan+best_len-1); + scan_end = *(ushf*)(scan + best_len - 1); #else - scan_end1 = scan[best_len-1]; + scan_end1 = scan[best_len - 1]; scan_end = scan[best_len]; #endif } @@ -1379,17 +1487,13 @@ local uInt longest_match(s, cur_match) if ((uInt)best_len <= s->lookahead) return (uInt)best_len; return s->lookahead; } -#endif /* ASMV */ #else /* FASTEST */ /* --------------------------------------------------------------------------- * Optimized version for FASTEST only */ -local uInt longest_match(s, cur_match) - deflate_state *s; - IPos cur_match; /* current match */ -{ +local uInt longest_match(deflate_state *s, IPos cur_match) { register Bytef *scan = s->window + s->strstart; /* current string */ register Bytef *match; /* matched string */ register int len; /* length of current match */ @@ -1400,7 +1504,8 @@ local uInt longest_match(s, cur_match) */ Assert(s->hash_bits >= 8 && MAX_MATCH == 258, "Code too clever"); - Assert((ulg)s->strstart <= s->window_size-MIN_LOOKAHEAD, "need lookahead"); + Assert((ulg)s->strstart <= s->window_size - MIN_LOOKAHEAD, + "need lookahead"); Assert(cur_match < s->strstart, "no future"); @@ -1410,7 +1515,7 @@ local uInt longest_match(s, cur_match) */ if (match[0] != scan[0] || match[1] != scan[1]) return MIN_MATCH-1; - /* The check at best_len-1 can be removed because it will be made + /* The check at best_len - 1 can be removed because it will be made * again later. (This heuristic is not always a win.) * It is not necessary to compare scan[2] and match[2] since they * are always equal when the other bytes match, given that @@ -1420,7 +1525,7 @@ local uInt longest_match(s, cur_match) Assert(*scan == *match, "match[2]?"); /* We check for insufficient lookahead only every 8th comparison; - * the 256th check will be made at strstart+258. + * the 256th check will be made at strstart + 258. */ do { } while (*++scan == *++match && *++scan == *++match && @@ -1429,7 +1534,7 @@ local uInt longest_match(s, cur_match) *++scan == *++match && *++scan == *++match && scan < strend); - Assert(scan <= s->window+(unsigned)(s->window_size-1), "wild scan"); + Assert(scan <= s->window + (unsigned)(s->window_size - 1), "wild scan"); len = MAX_MATCH - (int)(strend - scan); @@ -1449,23 +1554,27 @@ local uInt longest_match(s, cur_match) /* =========================================================================== * Check that the match at match_start is indeed a match. */ -local void check_match(s, start, match, length) - deflate_state *s; - IPos start, match; - int length; -{ +local void check_match(deflate_state *s, IPos start, IPos match, int length) { /* check that the match is indeed a match */ - if (zmemcmp(s->window + match, - s->window + start, length) != EQUAL) { - fprintf(stderr, " start %u, match %u, length %d\n", - start, match, length); + Bytef *back = s->window + (int)match, *here = s->window + start; + IPos len = length; + if (match == (IPos)-1) { + /* match starts one byte before the current window -- just compare the + subsequent length-1 bytes */ + back++; + here++; + len--; + } + if (zmemcmp(back, here, len) != EQUAL) { + fprintf(stderr, " start %u, match %d, length %d\n", + start, (int)match, length); do { - fprintf(stderr, "%c%c", s->window[match++], s->window[start++]); - } while (--length != 0); + fprintf(stderr, "(%02x %02x)", *back++, *here++); + } while (--len != 0); z_error("invalid match"); } if (z_verbose > 1) { - fprintf(stderr,"\\[%d,%d]", start-match, length); + fprintf(stderr,"\\[%d,%d]", start - match, length); do { putc(s->window[start++], stderr); } while (--length != 0); } } @@ -1473,135 +1582,6 @@ local void check_match(s, start, match, length) # define check_match(s, start, match, length) #endif /* ZLIB_DEBUG */ -/* =========================================================================== - * Fill the window when the lookahead becomes insufficient. - * Updates strstart and lookahead. - * - * IN assertion: lookahead < MIN_LOOKAHEAD - * OUT assertions: strstart <= window_size-MIN_LOOKAHEAD - * At least one byte has been read, or avail_in == 0; reads are - * performed for at least two bytes (required for the zip translate_eol - * option -- not supported here). - */ -local void fill_window(s) - deflate_state *s; -{ - unsigned n; - unsigned more; /* Amount of free space at the end of the window. */ - uInt wsize = s->w_size; - - Assert(s->lookahead < MIN_LOOKAHEAD, "already enough lookahead"); - - do { - more = (unsigned)(s->window_size -(ulg)s->lookahead -(ulg)s->strstart); - - /* Deal with !@#$% 64K limit: */ - if (sizeof(int) <= 2) { - if (more == 0 && s->strstart == 0 && s->lookahead == 0) { - more = wsize; - - } else if (more == (unsigned)(-1)) { - /* Very unlikely, but possible on 16 bit machine if - * strstart == 0 && lookahead == 1 (input done a byte at time) - */ - more--; - } - } - - /* If the window is almost full and there is insufficient lookahead, - * move the upper half to the lower one to make room in the upper half. - */ - if (s->strstart >= wsize+MAX_DIST(s)) { - - zmemcpy(s->window, s->window+wsize, (unsigned)wsize - more); - s->match_start -= wsize; - s->strstart -= wsize; /* we now have strstart >= MAX_DIST */ - s->block_start -= (long) wsize; - slide_hash(s); - more += wsize; - } - if (s->strm->avail_in == 0) break; - - /* If there was no sliding: - * strstart <= WSIZE+MAX_DIST-1 && lookahead <= MIN_LOOKAHEAD - 1 && - * more == window_size - lookahead - strstart - * => more >= window_size - (MIN_LOOKAHEAD-1 + WSIZE + MAX_DIST-1) - * => more >= window_size - 2*WSIZE + 2 - * In the BIG_MEM or MMAP case (not yet supported), - * window_size == input_size + MIN_LOOKAHEAD && - * strstart + s->lookahead <= input_size => more >= MIN_LOOKAHEAD. - * Otherwise, window_size == 2*WSIZE so more >= 2. - * If there was sliding, more >= WSIZE. So in all cases, more >= 2. - */ - Assert(more >= 2, "more < 2"); - - n = read_buf(s->strm, s->window + s->strstart + s->lookahead, more); - s->lookahead += n; - - /* Initialize the hash value now that we have some input: */ - if (s->lookahead + s->insert >= MIN_MATCH) { - uInt str = s->strstart - s->insert; - s->ins_h = s->window[str]; - UPDATE_HASH(s, s->ins_h, s->window[str + 1]); -#if MIN_MATCH != 3 - Call UPDATE_HASH() MIN_MATCH-3 more times -#endif - while (s->insert) { - UPDATE_HASH(s, s->ins_h, s->window[str + MIN_MATCH-1]); -#ifndef FASTEST - s->prev[str & s->w_mask] = s->head[s->ins_h]; -#endif - s->head[s->ins_h] = (Pos)str; - str++; - s->insert--; - if (s->lookahead + s->insert < MIN_MATCH) - break; - } - } - /* If the whole input has less than MIN_MATCH bytes, ins_h is garbage, - * but this is not important since only literal bytes will be emitted. - */ - - } while (s->lookahead < MIN_LOOKAHEAD && s->strm->avail_in != 0); - - /* If the WIN_INIT bytes after the end of the current data have never been - * written, then zero those bytes in order to avoid memory check reports of - * the use of uninitialized (or uninitialised as Julian writes) bytes by - * the longest match routines. Update the high water mark for the next - * time through here. WIN_INIT is set to MAX_MATCH since the longest match - * routines allow scanning to strstart + MAX_MATCH, ignoring lookahead. - */ - if (s->high_water < s->window_size) { - ulg curr = s->strstart + (ulg)(s->lookahead); - ulg init; - - if (s->high_water < curr) { - /* Previous high water mark below current data -- zero WIN_INIT - * bytes or up to end of window, whichever is less. - */ - init = s->window_size - curr; - if (init > WIN_INIT) - init = WIN_INIT; - zmemzero(s->window + curr, (unsigned)init); - s->high_water = curr + init; - } - else if (s->high_water < (ulg)curr + WIN_INIT) { - /* High water mark at or above current data, but below current data - * plus WIN_INIT -- zero out to current data plus WIN_INIT, or up - * to end of window, whichever is less. - */ - init = (ulg)curr + WIN_INIT - s->high_water; - if (init > s->window_size - s->high_water) - init = s->window_size - s->high_water; - zmemzero(s->window + s->high_water, (unsigned)init); - s->high_water += init; - } - } - - Assert((ulg)s->strstart <= s->window_size - MIN_LOOKAHEAD, - "not enough room for search"); -} - /* =========================================================================== * Flush the current block, with given end-of-file flag. * IN assertion: strstart is set to the end of the current match. @@ -1642,12 +1622,9 @@ local void fill_window(s) * * deflate_stored() is written to minimize the number of times an input byte is * copied. It is most efficient with large input and output buffers, which - * maximizes the opportunites to have a single copy from next_in to next_out. + * maximizes the opportunities to have a single copy from next_in to next_out. */ -local block_state deflate_stored(s, flush) - deflate_state *s; - int flush; -{ +local block_state deflate_stored(deflate_state *s, int flush) { /* Smallest worthy block size when not flushing or finishing. By default * this is 32K. This can be as small as 507 bytes for memLevel == 1. For * large input and output buffers, the stored block size will be larger. @@ -1746,6 +1723,7 @@ local block_state deflate_stored(s, flush) s->matches = 2; /* clear hash */ zmemcpy(s->window, s->strm->next_in - s->w_size, s->w_size); s->strstart = s->w_size; + s->insert = s->strstart; } else { if (s->window_size - s->strstart <= used) { @@ -1754,12 +1732,14 @@ local block_state deflate_stored(s, flush) zmemcpy(s->window, s->window + s->w_size, s->strstart); if (s->matches < 2) s->matches++; /* add a pending slide_hash() */ + if (s->insert > s->strstart) + s->insert = s->strstart; } zmemcpy(s->window + s->strstart, s->strm->next_in - used, used); s->strstart += used; + s->insert += MIN(used, s->w_size - s->insert); } s->block_start = s->strstart; - s->insert += MIN(used, s->w_size - s->insert); } if (s->high_water < s->strstart) s->high_water = s->strstart; @@ -1774,7 +1754,7 @@ local block_state deflate_stored(s, flush) return block_done; /* Fill the window with any remaining input. */ - have = s->window_size - s->strstart - 1; + have = s->window_size - s->strstart; if (s->strm->avail_in > have && s->block_start >= (long)s->w_size) { /* Slide the window down. */ s->block_start -= s->w_size; @@ -1783,12 +1763,15 @@ local block_state deflate_stored(s, flush) if (s->matches < 2) s->matches++; /* add a pending slide_hash() */ have += s->w_size; /* more space now */ + if (s->insert > s->strstart) + s->insert = s->strstart; } if (have > s->strm->avail_in) have = s->strm->avail_in; if (have) { read_buf(s->strm, s->window + s->strstart, have); s->strstart += have; + s->insert += MIN(have, s->w_size - s->insert); } if (s->high_water < s->strstart) s->high_water = s->strstart; @@ -1825,10 +1808,7 @@ local block_state deflate_stored(s, flush) * new strings in the dictionary only for unmatched strings or for short * matches. It is used only for the fast compression options. */ -local block_state deflate_fast(s, flush) - deflate_state *s; - int flush; -{ +local block_state deflate_fast(deflate_state *s, int flush) { IPos hash_head; /* head of the hash chain */ int bflush; /* set if current block must be flushed */ @@ -1846,7 +1826,7 @@ local block_state deflate_fast(s, flush) if (s->lookahead == 0) break; /* flush the current block */ } - /* Insert the string window[strstart .. strstart+2] in the + /* Insert the string window[strstart .. strstart + 2] in the * dictionary, and set hash_head to the head of the hash chain: */ hash_head = NIL; @@ -1894,7 +1874,7 @@ local block_state deflate_fast(s, flush) s->strstart += s->match_length; s->match_length = 0; s->ins_h = s->window[s->strstart]; - UPDATE_HASH(s, s->ins_h, s->window[s->strstart+1]); + UPDATE_HASH(s, s->ins_h, s->window[s->strstart + 1]); #if MIN_MATCH != 3 Call UPDATE_HASH() MIN_MATCH-3 more times #endif @@ -1905,7 +1885,7 @@ local block_state deflate_fast(s, flush) } else { /* No match, output a literal byte */ Tracevv((stderr,"%c", s->window[s->strstart])); - _tr_tally_lit (s, s->window[s->strstart], bflush); + _tr_tally_lit(s, s->window[s->strstart], bflush); s->lookahead--; s->strstart++; } @@ -1916,7 +1896,7 @@ local block_state deflate_fast(s, flush) FLUSH_BLOCK(s, 1); return finish_done; } - if (s->last_lit) + if (s->sym_next) FLUSH_BLOCK(s, 0); return block_done; } @@ -1927,10 +1907,7 @@ local block_state deflate_fast(s, flush) * evaluation for matches: a match is finally adopted only if there is * no better match at the next window position. */ -local block_state deflate_slow(s, flush) - deflate_state *s; - int flush; -{ +local block_state deflate_slow(deflate_state *s, int flush) { IPos hash_head; /* head of hash chain */ int bflush; /* set if current block must be flushed */ @@ -1949,7 +1926,7 @@ local block_state deflate_slow(s, flush) if (s->lookahead == 0) break; /* flush the current block */ } - /* Insert the string window[strstart .. strstart+2] in the + /* Insert the string window[strstart .. strstart + 2] in the * dictionary, and set hash_head to the head of the hash chain: */ hash_head = NIL; @@ -1959,7 +1936,7 @@ local block_state deflate_slow(s, flush) /* Find the longest match, discarding those <= prev_length. */ - s->prev_length = s->match_length; s->prev_match = s->match_start; + s->prev_length = s->match_length, s->prev_match = s->match_start; s->match_length = MIN_MATCH-1; if (hash_head != NIL && s->prev_length < s->max_lazy_match && @@ -1991,17 +1968,17 @@ local block_state deflate_slow(s, flush) uInt max_insert = s->strstart + s->lookahead - MIN_MATCH; /* Do not insert strings in hash table beyond this. */ - check_match(s, s->strstart-1, s->prev_match, s->prev_length); + check_match(s, s->strstart - 1, s->prev_match, s->prev_length); - _tr_tally_dist(s, s->strstart -1 - s->prev_match, + _tr_tally_dist(s, s->strstart - 1 - s->prev_match, s->prev_length - MIN_MATCH, bflush); /* Insert in hash table all strings up to the end of the match. - * strstart-1 and strstart are already inserted. If there is not + * strstart - 1 and strstart are already inserted. If there is not * enough lookahead, the last two strings are not inserted in * the hash table. */ - s->lookahead -= s->prev_length-1; + s->lookahead -= s->prev_length - 1; s->prev_length -= 2; do { if (++s->strstart <= max_insert) { @@ -2019,8 +1996,8 @@ local block_state deflate_slow(s, flush) * single literal. If there was a match but the current match * is longer, truncate the previous match to a single literal. */ - Tracevv((stderr,"%c", s->window[s->strstart-1])); - _tr_tally_lit(s, s->window[s->strstart-1], bflush); + Tracevv((stderr,"%c", s->window[s->strstart - 1])); + _tr_tally_lit(s, s->window[s->strstart - 1], bflush); if (bflush) { FLUSH_BLOCK_ONLY(s, 0); } @@ -2038,8 +2015,8 @@ local block_state deflate_slow(s, flush) } Assert (flush != Z_NO_FLUSH, "no flush?"); if (s->match_available) { - Tracevv((stderr,"%c", s->window[s->strstart-1])); - _tr_tally_lit(s, s->window[s->strstart-1], bflush); + Tracevv((stderr,"%c", s->window[s->strstart - 1])); + _tr_tally_lit(s, s->window[s->strstart - 1], bflush); s->match_available = 0; } s->insert = s->strstart < MIN_MATCH-1 ? s->strstart : MIN_MATCH-1; @@ -2047,7 +2024,7 @@ local block_state deflate_slow(s, flush) FLUSH_BLOCK(s, 1); return finish_done; } - if (s->last_lit) + if (s->sym_next) FLUSH_BLOCK(s, 0); return block_done; } @@ -2058,10 +2035,7 @@ local block_state deflate_slow(s, flush) * one. Do not maintain a hash table. (It will be regenerated if this run of * deflate switches away from Z_RLE.) */ -local block_state deflate_rle(s, flush) - deflate_state *s; - int flush; -{ +local block_state deflate_rle(deflate_state *s, int flush) { int bflush; /* set if current block must be flushed */ uInt prev; /* byte at distance one to match */ Bytef *scan, *strend; /* scan goes up to strend for length of run */ @@ -2096,7 +2070,8 @@ local block_state deflate_rle(s, flush) if (s->match_length > s->lookahead) s->match_length = s->lookahead; } - Assert(scan <= s->window+(uInt)(s->window_size-1), "wild scan"); + Assert(scan <= s->window + (uInt)(s->window_size - 1), + "wild scan"); } /* Emit match if have run of MIN_MATCH or longer, else emit literal */ @@ -2111,7 +2086,7 @@ local block_state deflate_rle(s, flush) } else { /* No match, output a literal byte */ Tracevv((stderr,"%c", s->window[s->strstart])); - _tr_tally_lit (s, s->window[s->strstart], bflush); + _tr_tally_lit(s, s->window[s->strstart], bflush); s->lookahead--; s->strstart++; } @@ -2122,7 +2097,7 @@ local block_state deflate_rle(s, flush) FLUSH_BLOCK(s, 1); return finish_done; } - if (s->last_lit) + if (s->sym_next) FLUSH_BLOCK(s, 0); return block_done; } @@ -2131,10 +2106,7 @@ local block_state deflate_rle(s, flush) * For Z_HUFFMAN_ONLY, do not look for matches. Do not maintain a hash table. * (It will be regenerated if this run of deflate switches away from Huffman.) */ -local block_state deflate_huff(s, flush) - deflate_state *s; - int flush; -{ +local block_state deflate_huff(deflate_state *s, int flush) { int bflush; /* set if current block must be flushed */ for (;;) { @@ -2151,7 +2123,7 @@ local block_state deflate_huff(s, flush) /* Output a literal byte */ s->match_length = 0; Tracevv((stderr,"%c", s->window[s->strstart])); - _tr_tally_lit (s, s->window[s->strstart], bflush); + _tr_tally_lit(s, s->window[s->strstart], bflush); s->lookahead--; s->strstart++; if (bflush) FLUSH_BLOCK(s, 0); @@ -2161,7 +2133,7 @@ local block_state deflate_huff(s, flush) FLUSH_BLOCK(s, 1); return finish_done; } - if (s->last_lit) + if (s->sym_next) FLUSH_BLOCK(s, 0); return block_done; } diff --git a/common/zlib/deflate.h b/common/zlib/deflate.h old mode 100755 new mode 100644 index 23ecdd3..300c6ad --- a/common/zlib/deflate.h +++ b/common/zlib/deflate.h @@ -1,5 +1,5 @@ /* deflate.h -- internal compression state - * Copyright (C) 1995-2016 Jean-loup Gailly + * Copyright (C) 1995-2024 Jean-loup Gailly * For conditions of distribution and use, see copyright notice in zlib.h */ @@ -23,6 +23,10 @@ # define GZIP #endif +/* define LIT_MEM to slightly increase the speed of deflate (order 1% to 2%) at + the cost of a larger memory footprint */ +/* #define LIT_MEM */ + /* =========================================================================== * Internal compression state. */ @@ -217,7 +221,14 @@ typedef struct internal_state { /* Depth of each subtree used as tie breaker for trees of equal frequency */ - uchf *l_buf; /* buffer for literals or lengths */ +#ifdef LIT_MEM +# define LIT_BUFS 5 + ushf *d_buf; /* buffer for distances */ + uchf *l_buf; /* buffer for literals/lengths */ +#else +# define LIT_BUFS 4 + uchf *sym_buf; /* buffer for distances and literals/lengths */ +#endif uInt lit_bufsize; /* Size of match buffer for literals/lengths. There are 4 reasons for @@ -239,13 +250,8 @@ typedef struct internal_state { * - I can't count above 4 */ - uInt last_lit; /* running index in l_buf */ - - ushf *d_buf; - /* Buffer for distances. To simplify the code, d_buf and l_buf have - * the same number of elements. To use different lengths, an extra flag - * array would be necessary. - */ + uInt sym_next; /* running index in symbol buffer */ + uInt sym_end; /* symbol table full when sym_next reaches this */ ulg opt_len; /* bit length of current block with optimal trees */ ulg static_len; /* bit length of current block with static trees */ @@ -296,14 +302,14 @@ typedef struct internal_state { memory checker errors from longest match routines */ /* in trees.c */ -void ZLIB_INTERNAL _tr_init OF((deflate_state *s)); -int ZLIB_INTERNAL _tr_tally OF((deflate_state *s, unsigned dist, unsigned lc)); -void ZLIB_INTERNAL _tr_flush_block OF((deflate_state *s, charf *buf, - ulg stored_len, int last)); -void ZLIB_INTERNAL _tr_flush_bits OF((deflate_state *s)); -void ZLIB_INTERNAL _tr_align OF((deflate_state *s)); -void ZLIB_INTERNAL _tr_stored_block OF((deflate_state *s, charf *buf, - ulg stored_len, int last)); +void ZLIB_INTERNAL _tr_init(deflate_state *s); +int ZLIB_INTERNAL _tr_tally(deflate_state *s, unsigned dist, unsigned lc); +void ZLIB_INTERNAL _tr_flush_block(deflate_state *s, charf *buf, + ulg stored_len, int last); +void ZLIB_INTERNAL _tr_flush_bits(deflate_state *s); +void ZLIB_INTERNAL _tr_align(deflate_state *s); +void ZLIB_INTERNAL _tr_stored_block(deflate_state *s, charf *buf, + ulg stored_len, int last); #define d_code(dist) \ ((dist) < 256 ? _dist_code[dist] : _dist_code[256+((dist)>>7)]) @@ -323,24 +329,46 @@ void ZLIB_INTERNAL _tr_stored_block OF((deflate_state *s, charf *buf, extern const uch ZLIB_INTERNAL _dist_code[]; #endif +#ifdef LIT_MEM # define _tr_tally_lit(s, c, flush) \ { uch cc = (c); \ - s->d_buf[s->last_lit] = 0; \ - s->l_buf[s->last_lit++] = cc; \ + s->d_buf[s->sym_next] = 0; \ + s->l_buf[s->sym_next++] = cc; \ s->dyn_ltree[cc].Freq++; \ - flush = (s->last_lit == s->lit_bufsize-1); \ + flush = (s->sym_next == s->sym_end); \ } # define _tr_tally_dist(s, distance, length, flush) \ { uch len = (uch)(length); \ ush dist = (ush)(distance); \ - s->d_buf[s->last_lit] = dist; \ - s->l_buf[s->last_lit++] = len; \ + s->d_buf[s->sym_next] = dist; \ + s->l_buf[s->sym_next++] = len; \ dist--; \ s->dyn_ltree[_length_code[len]+LITERALS+1].Freq++; \ s->dyn_dtree[d_code(dist)].Freq++; \ - flush = (s->last_lit == s->lit_bufsize-1); \ + flush = (s->sym_next == s->sym_end); \ } #else +# define _tr_tally_lit(s, c, flush) \ + { uch cc = (c); \ + s->sym_buf[s->sym_next++] = 0; \ + s->sym_buf[s->sym_next++] = 0; \ + s->sym_buf[s->sym_next++] = cc; \ + s->dyn_ltree[cc].Freq++; \ + flush = (s->sym_next == s->sym_end); \ + } +# define _tr_tally_dist(s, distance, length, flush) \ + { uch len = (uch)(length); \ + ush dist = (ush)(distance); \ + s->sym_buf[s->sym_next++] = (uch)dist; \ + s->sym_buf[s->sym_next++] = (uch)(dist >> 8); \ + s->sym_buf[s->sym_next++] = len; \ + dist--; \ + s->dyn_ltree[_length_code[len]+LITERALS+1].Freq++; \ + s->dyn_dtree[d_code(dist)].Freq++; \ + flush = (s->sym_next == s->sym_end); \ + } +#endif +#else # define _tr_tally_lit(s, c, flush) flush = _tr_tally(s, 0, c) # define _tr_tally_dist(s, distance, length, flush) \ flush = _tr_tally(s, distance, length) diff --git a/common/zlib/gzclose.c b/common/zlib/gzclose.c old mode 100755 new mode 100644 index caeb99a..48d6a86 --- a/common/zlib/gzclose.c +++ b/common/zlib/gzclose.c @@ -8,9 +8,7 @@ /* gzclose() is in a separate file so that it is linked in only if it is used. That way the other gzclose functions can be used instead to avoid linking in unneeded compression or decompression routines. */ -int ZEXPORT gzclose(file) - gzFile file; -{ +int ZEXPORT gzclose(gzFile file) { #ifndef NO_GZCOMPRESS gz_statep state; diff --git a/common/zlib/gzguts.h b/common/zlib/gzguts.h old mode 100755 new mode 100644 index a2c44f4..23229ca --- a/common/zlib/gzguts.h +++ b/common/zlib/gzguts.h @@ -1,15 +1,19 @@ /* gzguts.h -- zlib internal header definitions for gz* operations - * Copyright (C) 2004, 2005, 2010, 2011, 2012, 2013, 2016 Mark Adler + * Copyright (C) 2004-2024 Mark Adler * For conditions of distribution and use, see copyright notice in zlib.h */ +// UEFITool: required for macOS +#ifndef _WIN32 + #include +#endif + #ifdef _LARGEFILE64_SOURCE # ifndef _LARGEFILE_SOURCE # define _LARGEFILE_SOURCE 1 # endif -# ifdef _FILE_OFFSET_BITS -# undef _FILE_OFFSET_BITS -# endif +# undef _FILE_OFFSET_BITS +# undef _TIME_BITS #endif #ifdef HAVE_HIDDEN @@ -39,7 +43,7 @@ # include #endif -#if defined(_WIN32) || defined(__CYGWIN__) +#if defined(_WIN32) # define WIDECHAR #endif @@ -119,8 +123,8 @@ /* gz* functions always use library allocation functions */ #ifndef STDC - extern voidp malloc OF((uInt size)); - extern void free OF((voidpf ptr)); + extern voidp malloc(uInt size); + extern void free(voidpf ptr); #endif /* get errno and strerror definition */ @@ -138,10 +142,10 @@ /* provide prototypes for these when building zlib without LFS */ #if !defined(_LARGEFILE64_SOURCE) || _LFS64_LARGEFILE-0 == 0 - ZEXTERN gzFile ZEXPORT gzopen64 OF((const char *, const char *)); - ZEXTERN z_off64_t ZEXPORT gzseek64 OF((gzFile, z_off64_t, int)); - ZEXTERN z_off64_t ZEXPORT gztell64 OF((gzFile)); - ZEXTERN z_off64_t ZEXPORT gzoffset64 OF((gzFile)); + ZEXTERN gzFile ZEXPORT gzopen64(const char *, const char *); + ZEXTERN z_off64_t ZEXPORT gzseek64(gzFile, z_off64_t, int); + ZEXTERN z_off64_t ZEXPORT gztell64(gzFile); + ZEXTERN z_off64_t ZEXPORT gzoffset64(gzFile); #endif /* default memLevel */ @@ -190,6 +194,7 @@ typedef struct { /* just for writing */ int level; /* compression level */ int strategy; /* compression strategy */ + int reset; /* true if a reset is pending after a Z_FINISH */ /* seek request */ z_off64_t skip; /* amount to skip (already rewound if backwards) */ int seek; /* true if seek request pending */ @@ -202,22 +207,13 @@ typedef struct { typedef gz_state FAR *gz_statep; /* shared functions */ -void ZLIB_INTERNAL gz_error OF((gz_statep, int, const char *)); +void ZLIB_INTERNAL gz_error(gz_statep, int, const char *); #if defined UNDER_CE -char ZLIB_INTERNAL *gz_strwinerror OF((DWORD error)); +char ZLIB_INTERNAL *gz_strwinerror(DWORD error); #endif /* GT_OFF(x), where x is an unsigned value, is true if x > maximum z_off64_t value -- needed when comparing unsigned to z_off64_t, which is signed (possible z_off64_t types off_t, off64_t, and long are all signed) */ -#ifdef INT_MAX -# define GT_OFF(x) (sizeof(int) == sizeof(z_off64_t) && (x) > INT_MAX) -#else -unsigned ZLIB_INTERNAL gz_intmax OF((void)); -# define GT_OFF(x) (sizeof(int) == sizeof(z_off64_t) && (x) > gz_intmax()) -#endif - -/* UEFITool change, fixes undefined lseek, open, read prototypes. */ -#ifndef _WIN32 -# include -#endif +unsigned ZLIB_INTERNAL gz_intmax(void); +#define GT_OFF(x) (sizeof(int) == sizeof(z_off64_t) && (x) > gz_intmax()) diff --git a/common/zlib/gzlib.c b/common/zlib/gzlib.c old mode 100755 new mode 100644 index 4105e6a..983153c --- a/common/zlib/gzlib.c +++ b/common/zlib/gzlib.c @@ -1,11 +1,11 @@ /* gzlib.c -- zlib functions common to reading and writing gzip files - * Copyright (C) 2004-2017 Mark Adler + * Copyright (C) 2004-2024 Mark Adler * For conditions of distribution and use, see copyright notice in zlib.h */ #include "gzguts.h" -#if defined(_WIN32) && !defined(__BORLANDC__) && !defined(__MINGW32__) +#if defined(_WIN32) && !defined(__BORLANDC__) # define LSEEK _lseeki64 #else #if defined(_LARGEFILE64_SOURCE) && _LFS64_LARGEFILE-0 @@ -15,10 +15,6 @@ #endif #endif -/* Local functions */ -local void gz_reset OF((gz_statep)); -local gzFile gz_open OF((const void *, int, const char *)); - #if defined UNDER_CE /* Map the Windows error number in ERROR to a locale-dependent error message @@ -30,9 +26,7 @@ local gzFile gz_open OF((const void *, int, const char *)); The gz_strwinerror function does not change the current setting of GetLastError. */ -char ZLIB_INTERNAL *gz_strwinerror (error) - DWORD error; -{ +char ZLIB_INTERNAL *gz_strwinerror(DWORD error) { static char buf[1024]; wchar_t *msgbuf; @@ -72,15 +66,15 @@ char ZLIB_INTERNAL *gz_strwinerror (error) #endif /* UNDER_CE */ /* Reset gzip file state */ -local void gz_reset(state) - gz_statep state; -{ +local void gz_reset(gz_statep state) { state->x.have = 0; /* no output data available */ if (state->mode == GZ_READ) { /* for reading ... */ state->eof = 0; /* not at end of file */ state->past = 0; /* have not read past end yet */ state->how = LOOK; /* look for gzip header */ } + else /* for writing ... */ + state->reset = 0; /* no deflateReset pending */ state->seek = 0; /* no seek request pending */ gz_error(state, Z_OK, NULL); /* clear error */ state->x.pos = 0; /* no uncompressed data yet */ @@ -88,11 +82,7 @@ local void gz_reset(state) } /* Open a gzip file either by name or file descriptor. */ -local gzFile gz_open(path, fd, mode) - const void *path; - int fd; - const char *mode; -{ +local gzFile gz_open(const void *path, int fd, const char *mode) { gz_statep state; z_size_t len; int oflag; @@ -267,26 +257,17 @@ local gzFile gz_open(path, fd, mode) } /* -- see zlib.h -- */ -gzFile ZEXPORT gzopen(path, mode) - const char *path; - const char *mode; -{ +gzFile ZEXPORT gzopen(const char *path, const char *mode) { return gz_open(path, -1, mode); } /* -- see zlib.h -- */ -gzFile ZEXPORT gzopen64(path, mode) - const char *path; - const char *mode; -{ +gzFile ZEXPORT gzopen64(const char *path, const char *mode) { return gz_open(path, -1, mode); } /* -- see zlib.h -- */ -gzFile ZEXPORT gzdopen(fd, mode) - int fd; - const char *mode; -{ +gzFile ZEXPORT gzdopen(int fd, const char *mode) { char *path; /* identifier for error messages */ gzFile gz; @@ -304,19 +285,13 @@ gzFile ZEXPORT gzdopen(fd, mode) /* -- see zlib.h -- */ #ifdef WIDECHAR -gzFile ZEXPORT gzopen_w(path, mode) - const wchar_t *path; - const char *mode; -{ +gzFile ZEXPORT gzopen_w(const wchar_t *path, const char *mode) { return gz_open(path, -2, mode); } #endif /* -- see zlib.h -- */ -int ZEXPORT gzbuffer(file, size) - gzFile file; - unsigned size; -{ +int ZEXPORT gzbuffer(gzFile file, unsigned size) { gz_statep state; /* get internal structure and check integrity */ @@ -333,16 +308,14 @@ int ZEXPORT gzbuffer(file, size) /* check and set requested size */ if ((size << 1) < size) return -1; /* need to be able to double it */ - if (size < 2) - size = 2; /* need two bytes to check magic header */ + if (size < 8) + size = 8; /* needed to behave well with flushing */ state->want = size; return 0; } /* -- see zlib.h -- */ -int ZEXPORT gzrewind(file) - gzFile file; -{ +int ZEXPORT gzrewind(gzFile file) { gz_statep state; /* get internal structure */ @@ -363,11 +336,7 @@ int ZEXPORT gzrewind(file) } /* -- see zlib.h -- */ -z_off64_t ZEXPORT gzseek64(file, offset, whence) - gzFile file; - z_off64_t offset; - int whence; -{ +z_off64_t ZEXPORT gzseek64(gzFile file, z_off64_t offset, int whence) { unsigned n; z_off64_t ret; gz_statep state; @@ -397,7 +366,7 @@ z_off64_t ZEXPORT gzseek64(file, offset, whence) /* if within raw area while reading, just go there */ if (state->mode == GZ_READ && state->how == COPY && state->x.pos + offset >= 0) { - ret = LSEEK(state->fd, offset - state->x.have, SEEK_CUR); + ret = LSEEK(state->fd, offset - (z_off64_t)state->x.have, SEEK_CUR); if (ret == -1) return -1; state->x.have = 0; @@ -440,11 +409,7 @@ z_off64_t ZEXPORT gzseek64(file, offset, whence) } /* -- see zlib.h -- */ -z_off_t ZEXPORT gzseek(file, offset, whence) - gzFile file; - z_off_t offset; - int whence; -{ +z_off_t ZEXPORT gzseek(gzFile file, z_off_t offset, int whence) { z_off64_t ret; ret = gzseek64(file, (z_off64_t)offset, whence); @@ -452,9 +417,7 @@ z_off_t ZEXPORT gzseek(file, offset, whence) } /* -- see zlib.h -- */ -z_off64_t ZEXPORT gztell64(file) - gzFile file; -{ +z_off64_t ZEXPORT gztell64(gzFile file) { gz_statep state; /* get internal structure and check integrity */ @@ -469,9 +432,7 @@ z_off64_t ZEXPORT gztell64(file) } /* -- see zlib.h -- */ -z_off_t ZEXPORT gztell(file) - gzFile file; -{ +z_off_t ZEXPORT gztell(gzFile file) { z_off64_t ret; ret = gztell64(file); @@ -479,9 +440,7 @@ z_off_t ZEXPORT gztell(file) } /* -- see zlib.h -- */ -z_off64_t ZEXPORT gzoffset64(file) - gzFile file; -{ +z_off64_t ZEXPORT gzoffset64(gzFile file) { z_off64_t offset; gz_statep state; @@ -502,9 +461,7 @@ z_off64_t ZEXPORT gzoffset64(file) } /* -- see zlib.h -- */ -z_off_t ZEXPORT gzoffset(file) - gzFile file; -{ +z_off_t ZEXPORT gzoffset(gzFile file) { z_off64_t ret; ret = gzoffset64(file); @@ -512,9 +469,7 @@ z_off_t ZEXPORT gzoffset(file) } /* -- see zlib.h -- */ -int ZEXPORT gzeof(file) - gzFile file; -{ +int ZEXPORT gzeof(gzFile file) { gz_statep state; /* get internal structure and check integrity */ @@ -529,10 +484,7 @@ int ZEXPORT gzeof(file) } /* -- see zlib.h -- */ -const char * ZEXPORT gzerror(file, errnum) - gzFile file; - int *errnum; -{ +const char * ZEXPORT gzerror(gzFile file, int *errnum) { gz_statep state; /* get internal structure and check integrity */ @@ -550,9 +502,7 @@ const char * ZEXPORT gzerror(file, errnum) } /* -- see zlib.h -- */ -void ZEXPORT gzclearerr(file) - gzFile file; -{ +void ZEXPORT gzclearerr(gzFile file) { gz_statep state; /* get internal structure and check integrity */ @@ -576,11 +526,7 @@ void ZEXPORT gzclearerr(file) memory). Simply save the error message as a static string. If there is an allocation failure constructing the error message, then convert the error to out of memory. */ -void ZLIB_INTERNAL gz_error(state, err, msg) - gz_statep state; - int err; - const char *msg; -{ +void ZLIB_INTERNAL gz_error(gz_statep state, int err, const char *msg) { /* free previously allocated message and clear */ if (state->msg != NULL) { if (state->err != Z_MEM_ERROR) @@ -617,21 +563,20 @@ void ZLIB_INTERNAL gz_error(state, err, msg) #endif } -#ifndef INT_MAX /* portably return maximum value for an int (when limits.h presumed not available) -- we need to do this to cover cases where 2's complement not used, since C standard permits 1's complement and sign-bit representations, otherwise we could just use ((unsigned)-1) >> 1 */ -unsigned ZLIB_INTERNAL gz_intmax() -{ - unsigned p, q; - - p = 1; +unsigned ZLIB_INTERNAL gz_intmax(void) { +#ifdef INT_MAX + return INT_MAX; +#else + unsigned p = 1, q; do { q = p; p <<= 1; p++; } while (p > q); return q >> 1; -} #endif +} diff --git a/common/zlib/gzread.c b/common/zlib/gzread.c old mode 100755 new mode 100644 index f40e34b..4168cbc --- a/common/zlib/gzread.c +++ b/common/zlib/gzread.c @@ -1,29 +1,16 @@ /* gzread.c -- zlib functions for reading gzip files - * Copyright (C) 2004, 2005, 2010, 2011, 2012, 2013, 2016 Mark Adler + * Copyright (C) 2004-2017 Mark Adler * For conditions of distribution and use, see copyright notice in zlib.h */ #include "gzguts.h" -/* Local functions */ -local int gz_load OF((gz_statep, unsigned char *, unsigned, unsigned *)); -local int gz_avail OF((gz_statep)); -local int gz_look OF((gz_statep)); -local int gz_decomp OF((gz_statep)); -local int gz_fetch OF((gz_statep)); -local int gz_skip OF((gz_statep, z_off64_t)); -local z_size_t gz_read OF((gz_statep, voidp, z_size_t)); - /* Use read() to load a buffer -- return -1 on error, otherwise 0. Read from state->fd, and update state->eof, state->err, and state->msg as appropriate. This function needs to loop on read(), since read() is not guaranteed to read the number of bytes requested, depending on the type of descriptor. */ -local int gz_load(state, buf, len, have) - gz_statep state; - unsigned char *buf; - unsigned len; - unsigned *have; -{ +local int gz_load(gz_statep state, unsigned char *buf, unsigned len, + unsigned *have) { int ret; unsigned get, max = ((unsigned)-1 >> 2) + 1; @@ -53,9 +40,7 @@ local int gz_load(state, buf, len, have) If strm->avail_in != 0, then the current data is moved to the beginning of the input buffer, and then the remainder of the buffer is loaded with the available data from the input file. */ -local int gz_avail(state) - gz_statep state; -{ +local int gz_avail(gz_statep state) { unsigned got; z_streamp strm = &(state->strm); @@ -88,9 +73,7 @@ local int gz_avail(state) case, all further file reads will be directly to either the output buffer or a user buffer. If decompressing, the inflate state will be initialized. gz_look() will return 0 on success or -1 on failure. */ -local int gz_look(state) - gz_statep state; -{ +local int gz_look(gz_statep state) { z_streamp strm = &(state->strm); /* allocate read buffers and inflate memory */ @@ -157,11 +140,9 @@ local int gz_look(state) the output buffer is larger than the input buffer, which also assures space for gzungetc() */ state->x.next = state->out; - if (strm->avail_in) { - memcpy(state->x.next, strm->next_in, strm->avail_in); - state->x.have = strm->avail_in; - strm->avail_in = 0; - } + memcpy(state->x.next, strm->next_in, strm->avail_in); + state->x.have = strm->avail_in; + strm->avail_in = 0; state->how = COPY; state->direct = 1; return 0; @@ -172,9 +153,7 @@ local int gz_look(state) data. If the gzip stream completes, state->how is reset to LOOK to look for the next gzip stream or raw data, once state->x.have is depleted. Returns 0 on success, -1 on failure. */ -local int gz_decomp(state) - gz_statep state; -{ +local int gz_decomp(gz_statep state) { int ret = Z_OK; unsigned had; z_streamp strm = &(state->strm); @@ -226,9 +205,7 @@ local int gz_decomp(state) looked for to determine whether to copy or decompress. Returns -1 on error, otherwise 0. gz_fetch() will leave state->how as COPY or GZIP unless the end of the input file has been reached and all data has been processed. */ -local int gz_fetch(state) - gz_statep state; -{ +local int gz_fetch(gz_statep state) { z_streamp strm = &(state->strm); do { @@ -256,10 +233,7 @@ local int gz_fetch(state) } /* Skip len uncompressed bytes of output. Return -1 on error, 0 on success. */ -local int gz_skip(state, len) - gz_statep state; - z_off64_t len; -{ +local int gz_skip(gz_statep state, z_off64_t len) { unsigned n; /* skip over len bytes or reach end-of-file, whichever comes first */ @@ -291,11 +265,7 @@ local int gz_skip(state, len) input. Return the number of bytes read. If zero is returned, either the end of file was reached, or there was an error. state->err must be consulted in that case to determine which. */ -local z_size_t gz_read(state, buf, len) - gz_statep state; - voidp buf; - z_size_t len; -{ +local z_size_t gz_read(gz_statep state, voidp buf, z_size_t len) { z_size_t got; unsigned n; @@ -314,9 +284,9 @@ local z_size_t gz_read(state, buf, len) got = 0; do { /* set n to the maximum amount of len that fits in an unsigned int */ - n = -1; + n = (unsigned)-1; if (n > len) - n = len; + n = (unsigned)len; /* first just try copying data from the output buffer */ if (state->x.have) { @@ -372,11 +342,7 @@ local z_size_t gz_read(state, buf, len) } /* -- see zlib.h -- */ -int ZEXPORT gzread(file, buf, len) - gzFile file; - voidp buf; - unsigned len; -{ +int ZEXPORT gzread(gzFile file, voidp buf, unsigned len) { gz_statep state; /* get internal structure */ @@ -397,7 +363,7 @@ int ZEXPORT gzread(file, buf, len) } /* read len or fewer bytes to buf */ - len = gz_read(state, buf, len); + len = (unsigned)gz_read(state, buf, len); /* check for an error */ if (len == 0 && state->err != Z_OK && state->err != Z_BUF_ERROR) @@ -408,18 +374,10 @@ int ZEXPORT gzread(file, buf, len) } /* -- see zlib.h -- */ -z_size_t ZEXPORT gzfread(buf, size, nitems, file) - voidp buf; - z_size_t size; - z_size_t nitems; - gzFile file; -{ +z_size_t ZEXPORT gzfread(voidp buf, z_size_t size, z_size_t nitems, gzFile file) { z_size_t len; gz_statep state; - if (nitems == 0 || size == 0) - return 0; - /* get internal structure */ if (file == NULL) return 0; @@ -447,10 +405,7 @@ z_size_t ZEXPORT gzfread(buf, size, nitems, file) #else # undef gzgetc #endif -int ZEXPORT gzgetc(file) - gzFile file; -{ - int ret; +int ZEXPORT gzgetc(gzFile file) { unsigned char buf[1]; gz_statep state; @@ -472,21 +427,15 @@ int ZEXPORT gzgetc(file) } /* nothing there -- try gz_read() */ - ret = gz_read(state, buf, 1); - return ret < 1 ? -1 : buf[0]; + return gz_read(state, buf, 1) < 1 ? -1 : buf[0]; } -int ZEXPORT gzgetc_(file) -gzFile file; -{ +int ZEXPORT gzgetc_(gzFile file) { return gzgetc(file); } /* -- see zlib.h -- */ -int ZEXPORT gzungetc(c, file) - int c; - gzFile file; -{ +int ZEXPORT gzungetc(int c, gzFile file) { gz_statep state; /* get internal structure */ @@ -494,6 +443,10 @@ int ZEXPORT gzungetc(c, file) return -1; state = (gz_statep)file; + /* in case this was just opened, set up the input buffer */ + if (state->mode == GZ_READ && state->how == LOOK && state->x.have == 0) + (void)gz_look(state); + /* check that we're reading and that there's no (serious) error */ if (state->mode != GZ_READ || (state->err != Z_OK && state->err != Z_BUF_ERROR)) @@ -543,11 +496,7 @@ int ZEXPORT gzungetc(c, file) } /* -- see zlib.h -- */ -char * ZEXPORT gzgets(file, buf, len) - gzFile file; - char *buf; - int len; -{ +char * ZEXPORT gzgets(gzFile file, char *buf, int len) { unsigned left, n; char *str; unsigned char *eol; @@ -607,9 +556,7 @@ char * ZEXPORT gzgets(file, buf, len) } /* -- see zlib.h -- */ -int ZEXPORT gzdirect(file) - gzFile file; -{ +int ZEXPORT gzdirect(gzFile file) { gz_statep state; /* get internal structure */ @@ -627,9 +574,7 @@ int ZEXPORT gzdirect(file) } /* -- see zlib.h -- */ -int ZEXPORT gzclose_r(file) - gzFile file; -{ +int ZEXPORT gzclose_r(gzFile file) { int ret, err; gz_statep state; diff --git a/common/zlib/gzwrite.c b/common/zlib/gzwrite.c old mode 100755 new mode 100644 index 6c21870..435b462 --- a/common/zlib/gzwrite.c +++ b/common/zlib/gzwrite.c @@ -1,22 +1,14 @@ /* gzwrite.c -- zlib functions for writing gzip files - * Copyright (C) 2004-2017 Mark Adler + * Copyright (C) 2004-2019 Mark Adler * For conditions of distribution and use, see copyright notice in zlib.h */ #include "gzguts.h" -/* Local functions */ -local int gz_init OF((gz_statep)); -local int gz_comp OF((gz_statep, int)); -local int gz_zero OF((gz_statep, z_off64_t)); -local z_size_t gz_write OF((gz_statep, voidpc, z_size_t)); - /* Initialize state for writing a gzip file. Mark initialization by setting state->size to non-zero. Return -1 on a memory allocation failure, or 0 on success. */ -local int gz_init(state) - gz_statep state; -{ +local int gz_init(gz_statep state) { int ret; z_streamp strm = &(state->strm); @@ -70,10 +62,7 @@ local int gz_init(state) deflate() flush value. If flush is Z_FINISH, then the deflate() state is reset to start a new gzip stream. If gz->direct is true, then simply write to the output file without compressing, and ignore flush. */ -local int gz_comp(state, flush) - gz_statep state; - int flush; -{ +local int gz_comp(gz_statep state, int flush) { int ret, writ; unsigned have, put, max = ((unsigned)-1 >> 2) + 1; z_streamp strm = &(state->strm); @@ -97,6 +86,15 @@ local int gz_comp(state, flush) return 0; } + /* check for a pending reset */ + if (state->reset) { + /* don't start a new gzip member unless there is data to write */ + if (strm->avail_in == 0) + return 0; + deflateReset(strm); + state->reset = 0; + } + /* run deflate() on provided input until it produces no more output */ ret = Z_OK; do { @@ -134,7 +132,7 @@ local int gz_comp(state, flush) /* if that completed a deflate stream, allow another to start */ if (flush == Z_FINISH) - deflateReset(strm); + state->reset = 1; /* all done, no errors */ return 0; @@ -142,10 +140,7 @@ local int gz_comp(state, flush) /* Compress len zeros to output. Return -1 on a write error or memory allocation failure by gz_comp(), or 0 on success. */ -local int gz_zero(state, len) - gz_statep state; - z_off64_t len; -{ +local int gz_zero(gz_statep state, z_off64_t len) { int first; unsigned n; z_streamp strm = &(state->strm); @@ -175,11 +170,7 @@ local int gz_zero(state, len) /* Write len bytes from buf to file. Return the number of bytes written. If the returned value is less than len, then there was an error. */ -local z_size_t gz_write(state, buf, len) - gz_statep state; - voidpc buf; - z_size_t len; -{ +local z_size_t gz_write(gz_statep state, voidpc buf, z_size_t len) { z_size_t put = len; /* if len is zero, avoid unnecessary operations */ @@ -209,7 +200,7 @@ local z_size_t gz_write(state, buf, len) state->in); copy = state->size - have; if (copy > len) - copy = len; + copy = (unsigned)len; memcpy(state->in + have, buf, copy); state->strm.avail_in += copy; state->x.pos += copy; @@ -229,7 +220,7 @@ local z_size_t gz_write(state, buf, len) do { unsigned n = (unsigned)-1; if (n > len) - n = len; + n = (unsigned)len; state->strm.avail_in = n; state->x.pos += n; if (gz_comp(state, Z_NO_FLUSH) == -1) @@ -243,11 +234,7 @@ local z_size_t gz_write(state, buf, len) } /* -- see zlib.h -- */ -int ZEXPORT gzwrite(file, buf, len) - gzFile file; - voidpc buf; - unsigned len; -{ +int ZEXPORT gzwrite(gzFile file, voidpc buf, unsigned len) { gz_statep state; /* get internal structure */ @@ -271,18 +258,11 @@ int ZEXPORT gzwrite(file, buf, len) } /* -- see zlib.h -- */ -z_size_t ZEXPORT gzfwrite(buf, size, nitems, file) - voidpc buf; - z_size_t size; - z_size_t nitems; - gzFile file; -{ +z_size_t ZEXPORT gzfwrite(voidpc buf, z_size_t size, z_size_t nitems, + gzFile file) { z_size_t len; gz_statep state; - if (nitems == 0 || size == 0) - return 0; - /* get internal structure */ if (file == NULL) return 0; @@ -304,10 +284,7 @@ z_size_t ZEXPORT gzfwrite(buf, size, nitems, file) } /* -- see zlib.h -- */ -int ZEXPORT gzputc(file, c) - gzFile file; - int c; -{ +int ZEXPORT gzputc(gzFile file, int c) { unsigned have; unsigned char buf[1]; gz_statep state; @@ -352,12 +329,8 @@ int ZEXPORT gzputc(file, c) } /* -- see zlib.h -- */ -int ZEXPORT gzputs(file, str) - gzFile file; - const char *str; -{ - int ret; - z_size_t len; +int ZEXPORT gzputs(gzFile file, const char *s) { + z_size_t len, put; gz_statep state; /* get internal structure */ @@ -370,17 +343,20 @@ int ZEXPORT gzputs(file, str) return -1; /* write string */ - len = strlen(str); - ret = gz_write(state, str, len); - return ret == 0 && len != 0 ? -1 : ret; + len = strlen(s); + if ((int)len < 0 || (unsigned)len != len) { + gz_error(state, Z_STREAM_ERROR, "string length does not fit in int"); + return -1; + } + put = gz_write(state, s, len); + return put < len ? -1 : (int)len; } #if defined(STDC) || defined(Z_HAVE_STDARG_H) #include /* -- see zlib.h -- */ -int ZEXPORTVA gzvprintf(gzFile file, const char *format, va_list va) -{ +int ZEXPORTVA gzvprintf(gzFile file, const char *format, va_list va) { int len; unsigned left; char *next; @@ -444,15 +420,14 @@ int ZEXPORTVA gzvprintf(gzFile file, const char *format, va_list va) strm->avail_in = state->size; if (gz_comp(state, Z_NO_FLUSH) == -1) return state->err; - memcpy(state->in, state->in + state->size, left); + memmove(state->in, state->in + state->size, left); strm->next_in = state->in; strm->avail_in = left; } return len; } -int ZEXPORTVA gzprintf(gzFile file, const char *format, ...) -{ +int ZEXPORTVA gzprintf(gzFile file, const char *format, ...) { va_list va; int ret; @@ -465,13 +440,10 @@ int ZEXPORTVA gzprintf(gzFile file, const char *format, ...) #else /* !STDC && !Z_HAVE_STDARG_H */ /* -- see zlib.h -- */ -int ZEXPORTVA gzprintf (file, format, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, - a11, a12, a13, a14, a15, a16, a17, a18, a19, a20) - gzFile file; - const char *format; - int a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, - a11, a12, a13, a14, a15, a16, a17, a18, a19, a20; -{ +int ZEXPORTVA gzprintf(gzFile file, const char *format, int a1, int a2, int a3, + int a4, int a5, int a6, int a7, int a8, int a9, int a10, + int a11, int a12, int a13, int a14, int a15, int a16, + int a17, int a18, int a19, int a20) { unsigned len, left; char *next; gz_statep state; @@ -543,7 +515,7 @@ int ZEXPORTVA gzprintf (file, format, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, strm->avail_in = state->size; if (gz_comp(state, Z_NO_FLUSH) == -1) return state->err; - memcpy(state->in, state->in + state->size, left); + memmove(state->in, state->in + state->size, left); strm->next_in = state->in; strm->avail_in = left; } @@ -553,10 +525,7 @@ int ZEXPORTVA gzprintf (file, format, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, #endif /* -- see zlib.h -- */ -int ZEXPORT gzflush(file, flush) - gzFile file; - int flush; -{ +int ZEXPORT gzflush(gzFile file, int flush) { gz_statep state; /* get internal structure */ @@ -585,11 +554,7 @@ int ZEXPORT gzflush(file, flush) } /* -- see zlib.h -- */ -int ZEXPORT gzsetparams(file, level, strategy) - gzFile file; - int level; - int strategy; -{ +int ZEXPORT gzsetparams(gzFile file, int level, int strategy) { gz_statep state; z_streamp strm; @@ -600,7 +565,7 @@ int ZEXPORT gzsetparams(file, level, strategy) strm = &(state->strm); /* check that we're writing and that there's no error */ - if (state->mode != GZ_WRITE || state->err != Z_OK) + if (state->mode != GZ_WRITE || state->err != Z_OK || state->direct) return Z_STREAM_ERROR; /* if no change is requested, then do nothing */ @@ -627,9 +592,7 @@ int ZEXPORT gzsetparams(file, level, strategy) } /* -- see zlib.h -- */ -int ZEXPORT gzclose_w(file) - gzFile file; -{ +int ZEXPORT gzclose_w(gzFile file) { int ret = Z_OK; gz_statep state; diff --git a/common/zlib/infback.c b/common/zlib/infback.c old mode 100755 new mode 100644 index a695152..e7b25b3 --- a/common/zlib/infback.c +++ b/common/zlib/infback.c @@ -1,5 +1,5 @@ /* infback.c -- inflate using a call-back interface - * Copyright (C) 1995-2016 Mark Adler + * Copyright (C) 1995-2022 Mark Adler * For conditions of distribution and use, see copyright notice in zlib.h */ @@ -15,9 +15,6 @@ #include "inflate.h" #include "inffast.h" -/* function prototypes */ -local void fixedtables OF((struct inflate_state FAR *state)); - /* strm provides memory allocation functions in zalloc and zfree, or Z_NULL to use the library memory allocation functions. @@ -25,13 +22,9 @@ local void fixedtables OF((struct inflate_state FAR *state)); windowBits is in the range 8..15, and window is a user-supplied window and output buffer that is 2**windowBits bytes. */ -int ZEXPORT inflateBackInit_(strm, windowBits, window, version, stream_size) -z_streamp strm; -int windowBits; -unsigned char FAR *window; -const char *version; -int stream_size; -{ +int ZEXPORT inflateBackInit_(z_streamp strm, int windowBits, + unsigned char FAR *window, const char *version, + int stream_size) { struct inflate_state FAR *state; if (version == Z_NULL || version[0] != ZLIB_VERSION[0] || @@ -66,6 +59,7 @@ int stream_size; state->window = window; state->wnext = 0; state->whave = 0; + state->sane = 1; return Z_OK; } @@ -79,9 +73,7 @@ int stream_size; used for threaded applications, since the rewriting of the tables and virgin may not be thread-safe. */ -local void fixedtables(state) -struct inflate_state FAR *state; -{ +local void fixedtables(struct inflate_state FAR *state) { #ifdef BUILDFIXED static int virgin = 1; static code *lenfix, *distfix; @@ -247,13 +239,8 @@ struct inflate_state FAR *state; inflateBack() can also return Z_STREAM_ERROR if the input parameters are not correct, i.e. strm is Z_NULL or the state was not initialized. */ -int ZEXPORT inflateBack(strm, in, in_desc, out, out_desc) -z_streamp strm; -in_func in; -void FAR *in_desc; -out_func out; -void FAR *out_desc; -{ +int ZEXPORT inflateBack(z_streamp strm, in_func in, void FAR *in_desc, + out_func out, void FAR *out_desc) { struct inflate_state FAR *state; z_const unsigned char FAR *next; /* next input */ unsigned char FAR *put; /* next output */ @@ -477,7 +464,7 @@ void FAR *out_desc; } Tracev((stderr, "inflate: codes ok\n")); state->mode = LEN; - /* FALLTHROUGH */ + /* fallthrough */ case LEN: /* use inflate_fast() if we have enough input and output */ @@ -605,33 +592,33 @@ void FAR *out_desc; break; case DONE: - /* inflate stream terminated properly -- write leftover output */ + /* inflate stream terminated properly */ ret = Z_STREAM_END; - if (left < state->wsize) { - if (out(out_desc, state->window, state->wsize - left)) - ret = Z_BUF_ERROR; - } goto inf_leave; case BAD: ret = Z_DATA_ERROR; goto inf_leave; - default: /* can't happen, but makes compilers happy */ + default: + /* can't happen, but makes compilers happy */ ret = Z_STREAM_ERROR; goto inf_leave; } - /* Return unused input */ + /* Write leftover output and return unused input */ inf_leave: + if (left < state->wsize) { + if (out(out_desc, state->window, state->wsize - left) && + ret == Z_STREAM_END) + ret = Z_BUF_ERROR; + } strm->next_in = next; strm->avail_in = have; return ret; } -int ZEXPORT inflateBackEnd(strm) -z_streamp strm; -{ +int ZEXPORT inflateBackEnd(z_streamp strm) { if (strm == Z_NULL || strm->state == Z_NULL || strm->zfree == (free_func)0) return Z_STREAM_ERROR; ZFREE(strm, strm->state); diff --git a/common/zlib/inffast.c b/common/zlib/inffast.c old mode 100755 new mode 100644 index 0dbd1db..9354676 --- a/common/zlib/inffast.c +++ b/common/zlib/inffast.c @@ -47,10 +47,7 @@ requires strm->avail_out >= 258 for each loop to avoid checking for output space. */ -void ZLIB_INTERNAL inflate_fast(strm, start) -z_streamp strm; -unsigned start; /* inflate()'s starting value for strm->avail_out */ -{ +void ZLIB_INTERNAL inflate_fast(z_streamp strm, unsigned start) { struct inflate_state FAR *state; z_const unsigned char FAR *in; /* local strm->next_in */ z_const unsigned char FAR *last; /* have enough input while in < last */ @@ -70,7 +67,7 @@ unsigned start; /* inflate()'s starting value for strm->avail_out */ code const FAR *dcode; /* local strm->distcode */ unsigned lmask; /* mask for first level of length codes */ unsigned dmask; /* mask for first level of distance codes */ - code here; /* retrieved table entry */ + code const *here; /* retrieved table entry */ unsigned op; /* code bits, operation, extra bits, or */ /* window position, window bytes to copy */ unsigned len; /* match length, unused bytes */ @@ -107,20 +104,20 @@ unsigned start; /* inflate()'s starting value for strm->avail_out */ hold += (unsigned long)(*in++) << bits; bits += 8; } - here = lcode[hold & lmask]; + here = lcode + (hold & lmask); dolen: - op = (unsigned)(here.bits); + op = (unsigned)(here->bits); hold >>= op; bits -= op; - op = (unsigned)(here.op); + op = (unsigned)(here->op); if (op == 0) { /* literal */ - Tracevv((stderr, here.val >= 0x20 && here.val < 0x7f ? + Tracevv((stderr, here->val >= 0x20 && here->val < 0x7f ? "inflate: literal '%c'\n" : - "inflate: literal 0x%02x\n", here.val)); - *out++ = (unsigned char)(here.val); + "inflate: literal 0x%02x\n", here->val)); + *out++ = (unsigned char)(here->val); } else if (op & 16) { /* length base */ - len = (unsigned)(here.val); + len = (unsigned)(here->val); op &= 15; /* number of extra bits */ if (op) { if (bits < op) { @@ -138,14 +135,14 @@ unsigned start; /* inflate()'s starting value for strm->avail_out */ hold += (unsigned long)(*in++) << bits; bits += 8; } - here = dcode[hold & dmask]; + here = dcode + (hold & dmask); dodist: - op = (unsigned)(here.bits); + op = (unsigned)(here->bits); hold >>= op; bits -= op; - op = (unsigned)(here.op); + op = (unsigned)(here->op); if (op & 16) { /* distance base */ - dist = (unsigned)(here.val); + dist = (unsigned)(here->val); op &= 15; /* number of extra bits */ if (bits < op) { hold += (unsigned long)(*in++) << bits; @@ -264,7 +261,7 @@ unsigned start; /* inflate()'s starting value for strm->avail_out */ } } else if ((op & 64) == 0) { /* 2nd level distance code */ - here = dcode[here.val + (hold & ((1U << op) - 1))]; + here = dcode + here->val + (hold & ((1U << op) - 1)); goto dodist; } else { @@ -274,7 +271,7 @@ unsigned start; /* inflate()'s starting value for strm->avail_out */ } } else if ((op & 64) == 0) { /* 2nd level length code */ - here = lcode[here.val + (hold & ((1U << op) - 1))]; + here = lcode + here->val + (hold & ((1U << op) - 1)); goto dolen; } else if (op & 32) { /* end-of-block */ diff --git a/common/zlib/inffast.h b/common/zlib/inffast.h old mode 100755 new mode 100644 index e5c1aa4..49c6d15 --- a/common/zlib/inffast.h +++ b/common/zlib/inffast.h @@ -8,4 +8,4 @@ subject to change. Applications should only use zlib.h. */ -void ZLIB_INTERNAL inflate_fast OF((z_streamp strm, unsigned start)); +void ZLIB_INTERNAL inflate_fast(z_streamp strm, unsigned start); diff --git a/common/zlib/inffixed.h b/common/zlib/inffixed.h old mode 100755 new mode 100644 diff --git a/common/zlib/inflate.c b/common/zlib/inflate.c old mode 100755 new mode 100644 index a336d2b..94ecff0 --- a/common/zlib/inflate.c +++ b/common/zlib/inflate.c @@ -1,5 +1,5 @@ /* inflate.c -- zlib decompression - * Copyright (C) 1995-2016 Mark Adler + * Copyright (C) 1995-2022 Mark Adler * For conditions of distribution and use, see copyright notice in zlib.h */ @@ -91,20 +91,7 @@ # endif #endif -/* function prototypes */ -local int inflateStateCheck OF((z_streamp strm)); -local void fixedtables OF((struct inflate_state FAR *state)); -local int updatewindow OF((z_streamp strm, const unsigned char FAR *end, - unsigned copy)); -#ifdef BUILDFIXED - void makefixed OF((void)); -#endif -local unsigned syncsearch OF((unsigned FAR *have, const unsigned char FAR *buf, - unsigned len)); - -local int inflateStateCheck(strm) -z_streamp strm; -{ +local int inflateStateCheck(z_streamp strm) { struct inflate_state FAR *state; if (strm == Z_NULL || strm->zalloc == (alloc_func)0 || strm->zfree == (free_func)0) @@ -116,9 +103,7 @@ z_streamp strm; return 0; } -int ZEXPORT inflateResetKeep(strm) -z_streamp strm; -{ +int ZEXPORT inflateResetKeep(z_streamp strm) { struct inflate_state FAR *state; if (inflateStateCheck(strm)) return Z_STREAM_ERROR; @@ -130,6 +115,7 @@ z_streamp strm; state->mode = HEAD; state->last = 0; state->havedict = 0; + state->flags = -1; state->dmax = 32768U; state->head = Z_NULL; state->hold = 0; @@ -141,9 +127,7 @@ z_streamp strm; return Z_OK; } -int ZEXPORT inflateReset(strm) -z_streamp strm; -{ +int ZEXPORT inflateReset(z_streamp strm) { struct inflate_state FAR *state; if (inflateStateCheck(strm)) return Z_STREAM_ERROR; @@ -154,10 +138,7 @@ z_streamp strm; return inflateResetKeep(strm); } -int ZEXPORT inflateReset2(strm, windowBits) -z_streamp strm; -int windowBits; -{ +int ZEXPORT inflateReset2(z_streamp strm, int windowBits) { int wrap; struct inflate_state FAR *state; @@ -167,6 +148,8 @@ int windowBits; /* extract wrap request from windowBits parameter */ if (windowBits < 0) { + if (windowBits < -15) + return Z_STREAM_ERROR; wrap = 0; windowBits = -windowBits; } @@ -192,12 +175,8 @@ int windowBits; return inflateReset(strm); } -int ZEXPORT inflateInit2_(strm, windowBits, version, stream_size) -z_streamp strm; -int windowBits; -const char *version; -int stream_size; -{ +int ZEXPORT inflateInit2_(z_streamp strm, int windowBits, + const char *version, int stream_size) { int ret; struct inflate_state FAR *state; @@ -236,22 +215,17 @@ int stream_size; return ret; } -int ZEXPORT inflateInit_(strm, version, stream_size) -z_streamp strm; -const char *version; -int stream_size; -{ +int ZEXPORT inflateInit_(z_streamp strm, const char *version, + int stream_size) { return inflateInit2_(strm, DEF_WBITS, version, stream_size); } -int ZEXPORT inflatePrime(strm, bits, value) -z_streamp strm; -int bits; -int value; -{ +int ZEXPORT inflatePrime(z_streamp strm, int bits, int value) { struct inflate_state FAR *state; if (inflateStateCheck(strm)) return Z_STREAM_ERROR; + if (bits == 0) + return Z_OK; state = (struct inflate_state FAR *)strm->state; if (bits < 0) { state->hold = 0; @@ -275,9 +249,7 @@ int value; used for threaded applications, since the rewriting of the tables and virgin may not be thread-safe. */ -local void fixedtables(state) -struct inflate_state FAR *state; -{ +local void fixedtables(struct inflate_state FAR *state) { #ifdef BUILDFIXED static int virgin = 1; static code *lenfix, *distfix; @@ -339,7 +311,7 @@ struct inflate_state FAR *state; a.out > inffixed.h */ -void makefixed() +void makefixed(void) { unsigned low, size; struct inflate_state state; @@ -393,11 +365,7 @@ void makefixed() output will fall in the output data, making match copies simpler and faster. The advantage may be dependent on the size of the processor's data caches. */ -local int updatewindow(strm, end, copy) -z_streamp strm; -const Bytef *end; -unsigned copy; -{ +local int updatewindow(z_streamp strm, const Bytef *end, unsigned copy) { struct inflate_state FAR *state; unsigned dist; @@ -447,10 +415,10 @@ unsigned copy; /* check function to use adler32() for zlib or crc32() for gzip */ #ifdef GUNZIP -# define UPDATE(check, buf, len) \ +# define UPDATE_CHECK(check, buf, len) \ (state->flags ? crc32(check, buf, len) : adler32(check, buf, len)) #else -# define UPDATE(check, buf, len) adler32(check, buf, len) +# define UPDATE_CHECK(check, buf, len) adler32(check, buf, len) #endif /* check macros for header crc */ @@ -619,10 +587,7 @@ unsigned copy; will return Z_BUF_ERROR if it has not reached the end of the stream. */ -int ZEXPORT inflate(strm, flush) -z_streamp strm; -int flush; -{ +int ZEXPORT inflate(z_streamp strm, int flush) { struct inflate_state FAR *state; z_const unsigned char FAR *next; /* next input */ unsigned char FAR *put; /* next output */ @@ -670,7 +635,6 @@ int flush; state->mode = FLAGS; break; } - state->flags = 0; /* expect zlib header */ if (state->head != Z_NULL) state->head->done = -1; if (!(state->wrap & 1) || /* check if zlib header allowed */ @@ -697,6 +661,7 @@ int flush; break; } state->dmax = 1U << len; + state->flags = 0; /* indicate zlib header */ Tracev((stderr, "inflate: zlib header ok\n")); strm->adler = state->check = adler32(0L, Z_NULL, 0); state->mode = hold & 0x200 ? DICTID : TYPE; @@ -722,7 +687,7 @@ int flush; CRC2(state->check, hold); INITBITS(); state->mode = TIME; - /* FALLTHROUGH */ + /* fallthrough */ case TIME: NEEDBITS(32); if (state->head != Z_NULL) @@ -731,7 +696,7 @@ int flush; CRC4(state->check, hold); INITBITS(); state->mode = OS; - /* FALLTHROUGH */ + /* fallthrough */ case OS: NEEDBITS(16); if (state->head != Z_NULL) { @@ -742,7 +707,7 @@ int flush; CRC2(state->check, hold); INITBITS(); state->mode = EXLEN; - /* FALLTHROUGH */ + /* fallthrough */ case EXLEN: if (state->flags & 0x0400) { NEEDBITS(16); @@ -756,15 +721,16 @@ int flush; else if (state->head != Z_NULL) state->head->extra = Z_NULL; state->mode = EXTRA; - /* FALLTHROUGH */ + /* fallthrough */ case EXTRA: if (state->flags & 0x0400) { copy = state->length; if (copy > have) copy = have; if (copy) { if (state->head != Z_NULL && - state->head->extra != Z_NULL) { - len = state->head->extra_len - state->length; + state->head->extra != Z_NULL && + (len = state->head->extra_len - state->length) < + state->head->extra_max) { zmemcpy(state->head->extra + len, next, len + copy > state->head->extra_max ? state->head->extra_max - len : copy); @@ -779,7 +745,7 @@ int flush; } state->length = 0; state->mode = NAME; - /* FALLTHROUGH */ + /* fallthrough */ case NAME: if (state->flags & 0x0800) { if (have == 0) goto inf_leave; @@ -801,7 +767,7 @@ int flush; state->head->name = Z_NULL; state->length = 0; state->mode = COMMENT; - /* FALLTHROUGH */ + /* fallthrough */ case COMMENT: if (state->flags & 0x1000) { if (have == 0) goto inf_leave; @@ -822,7 +788,7 @@ int flush; else if (state->head != Z_NULL) state->head->comment = Z_NULL; state->mode = HCRC; - /* FALLTHROUGH */ + /* fallthrough */ case HCRC: if (state->flags & 0x0200) { NEEDBITS(16); @@ -846,7 +812,7 @@ int flush; strm->adler = state->check = ZSWAP32(hold); INITBITS(); state->mode = DICT; - /* FALLTHROUGH */ + /* fallthrough */ case DICT: if (state->havedict == 0) { RESTORE(); @@ -854,10 +820,10 @@ int flush; } strm->adler = state->check = adler32(0L, Z_NULL, 0); state->mode = TYPE; - /* FALLTHROUGH */ + /* fallthrough */ case TYPE: if (flush == Z_BLOCK || flush == Z_TREES) goto inf_leave; - /* FALLTHROUGH */ + /* fallthrough */ case TYPEDO: if (state->last) { BYTEBITS(); @@ -908,10 +874,10 @@ int flush; INITBITS(); state->mode = COPY_; if (flush == Z_TREES) goto inf_leave; - /* FALLTHROUGH */ + /* fallthrough */ case COPY_: state->mode = COPY; - /* FALLTHROUGH */ + /* fallthrough */ case COPY: copy = state->length; if (copy) { @@ -947,7 +913,7 @@ int flush; Tracev((stderr, "inflate: table sizes ok\n")); state->have = 0; state->mode = LENLENS; - /* FALLTHROUGH */ + /* fallthrough */ case LENLENS: while (state->have < state->ncode) { NEEDBITS(3); @@ -969,7 +935,7 @@ int flush; Tracev((stderr, "inflate: code lengths ok\n")); state->have = 0; state->mode = CODELENS; - /* FALLTHROUGH */ + /* fallthrough */ case CODELENS: while (state->have < state->nlen + state->ndist) { for (;;) { @@ -1053,10 +1019,10 @@ int flush; Tracev((stderr, "inflate: codes ok\n")); state->mode = LEN_; if (flush == Z_TREES) goto inf_leave; - /* FALLTHROUGH */ + /* fallthrough */ case LEN_: state->mode = LEN; - /* FALLTHROUGH */ + /* fallthrough */ case LEN: if (have >= 6 && left >= 258) { RESTORE(); @@ -1106,7 +1072,7 @@ int flush; } state->extra = (unsigned)(here.op) & 15; state->mode = LENEXT; - /* FALLTHROUGH */ + /* fallthrough */ case LENEXT: if (state->extra) { NEEDBITS(state->extra); @@ -1117,7 +1083,7 @@ int flush; Tracevv((stderr, "inflate: length %u\n", state->length)); state->was = state->length; state->mode = DIST; - /* FALLTHROUGH */ + /* fallthrough */ case DIST: for (;;) { here = state->distcode[BITS(state->distbits)]; @@ -1145,7 +1111,7 @@ int flush; state->offset = (unsigned)here.val; state->extra = (unsigned)(here.op) & 15; state->mode = DISTEXT; - /* FALLTHROUGH */ + /* fallthrough */ case DISTEXT: if (state->extra) { NEEDBITS(state->extra); @@ -1162,7 +1128,7 @@ int flush; #endif Tracevv((stderr, "inflate: distance %u\n", state->offset)); state->mode = MATCH; - /* FALLTHROUGH */ + /* fallthrough */ case MATCH: if (left == 0) goto inf_leave; copy = out - left; @@ -1222,7 +1188,7 @@ int flush; state->total += out; if ((state->wrap & 4) && out) strm->adler = state->check = - UPDATE(state->check, put - out, out); + UPDATE_CHECK(state->check, put - out, out); out = left; if ((state->wrap & 4) && ( #ifdef GUNZIP @@ -1238,11 +1204,11 @@ int flush; } #ifdef GUNZIP state->mode = LENGTH; - /* FALLTHROUGH */ + /* fallthrough */ case LENGTH: if (state->wrap && state->flags) { NEEDBITS(32); - if (hold != (state->total & 0xffffffffUL)) { + if ((state->wrap & 4) && hold != (state->total & 0xffffffff)) { strm->msg = (char *)"incorrect length check"; state->mode = BAD; break; @@ -1252,7 +1218,7 @@ int flush; } #endif state->mode = DONE; - /* FALLTHROUGH */ + /* fallthrough */ case DONE: ret = Z_STREAM_END; goto inf_leave; @@ -1262,6 +1228,7 @@ int flush; case MEM: return Z_MEM_ERROR; case SYNC: + /* fallthrough */ default: return Z_STREAM_ERROR; } @@ -1287,7 +1254,7 @@ int flush; state->total += out; if ((state->wrap & 4) && out) strm->adler = state->check = - UPDATE(state->check, strm->next_out - out, out); + UPDATE_CHECK(state->check, strm->next_out - out, out); strm->data_type = (int)state->bits + (state->last ? 64 : 0) + (state->mode == TYPE ? 128 : 0) + (state->mode == LEN_ || state->mode == COPY_ ? 256 : 0); @@ -1296,9 +1263,7 @@ int flush; return ret; } -int ZEXPORT inflateEnd(strm) -z_streamp strm; -{ +int ZEXPORT inflateEnd(z_streamp strm) { struct inflate_state FAR *state; if (inflateStateCheck(strm)) return Z_STREAM_ERROR; @@ -1310,11 +1275,8 @@ z_streamp strm; return Z_OK; } -int ZEXPORT inflateGetDictionary(strm, dictionary, dictLength) -z_streamp strm; -Bytef *dictionary; -uInt *dictLength; -{ +int ZEXPORT inflateGetDictionary(z_streamp strm, Bytef *dictionary, + uInt *dictLength) { struct inflate_state FAR *state; /* check state */ @@ -1333,11 +1295,8 @@ uInt *dictLength; return Z_OK; } -int ZEXPORT inflateSetDictionary(strm, dictionary, dictLength) -z_streamp strm; -const Bytef *dictionary; -uInt dictLength; -{ +int ZEXPORT inflateSetDictionary(z_streamp strm, const Bytef *dictionary, + uInt dictLength) { struct inflate_state FAR *state; unsigned long dictid; int ret; @@ -1368,10 +1327,7 @@ uInt dictLength; return Z_OK; } -int ZEXPORT inflateGetHeader(strm, head) -z_streamp strm; -gz_headerp head; -{ +int ZEXPORT inflateGetHeader(z_streamp strm, gz_headerp head) { struct inflate_state FAR *state; /* check state */ @@ -1396,11 +1352,8 @@ gz_headerp head; called again with more data and the *have state. *have is initialized to zero for the first call. */ -local unsigned syncsearch(have, buf, len) -unsigned FAR *have; -const unsigned char FAR *buf; -unsigned len; -{ +local unsigned syncsearch(unsigned FAR *have, const unsigned char FAR *buf, + unsigned len) { unsigned got; unsigned next; @@ -1419,10 +1372,9 @@ unsigned len; return next; } -int ZEXPORT inflateSync(strm) -z_streamp strm; -{ +int ZEXPORT inflateSync(z_streamp strm) { unsigned len; /* number of bytes to look at or looked at */ + int flags; /* temporary to save header status */ unsigned long in, out; /* temporary to save total_in and total_out */ unsigned char buf[4]; /* to restore bit buffer to byte string */ struct inflate_state FAR *state; @@ -1435,7 +1387,7 @@ z_streamp strm; /* if first time, start search in bit buffer */ if (state->mode != SYNC) { state->mode = SYNC; - state->hold <<= state->bits & 7; + state->hold >>= state->bits & 7; state->bits -= state->bits & 7; len = 0; while (state->bits >= 8) { @@ -1455,9 +1407,15 @@ z_streamp strm; /* return no joy or set up to restart inflate() on a new block */ if (state->have != 4) return Z_DATA_ERROR; + if (state->flags == -1) + state->wrap = 0; /* if no header yet, treat as raw */ + else + state->wrap &= ~4; /* no point in computing a check value now */ + flags = state->flags; in = strm->total_in; out = strm->total_out; inflateReset(strm); strm->total_in = in; strm->total_out = out; + state->flags = flags; state->mode = TYPE; return Z_OK; } @@ -1470,9 +1428,7 @@ z_streamp strm; block. When decompressing, PPP checks that at the end of input packet, inflate is waiting for these length bytes. */ -int ZEXPORT inflateSyncPoint(strm) -z_streamp strm; -{ +int ZEXPORT inflateSyncPoint(z_streamp strm) { struct inflate_state FAR *state; if (inflateStateCheck(strm)) return Z_STREAM_ERROR; @@ -1480,10 +1436,7 @@ z_streamp strm; return state->mode == STORED && state->bits == 0; } -int ZEXPORT inflateCopy(dest, source) -z_streamp dest; -z_streamp source; -{ +int ZEXPORT inflateCopy(z_streamp dest, z_streamp source) { struct inflate_state FAR *state; struct inflate_state FAR *copy; unsigned char FAR *window; @@ -1509,8 +1462,8 @@ z_streamp source; } /* copy state */ - zmemcpy((Bytef*)dest, (const Bytef*)source, sizeof(z_stream)); - zmemcpy((Bytef*)copy, (const Bytef*)state, sizeof(struct inflate_state)); + zmemcpy((voidpf)dest, (voidpf)source, sizeof(z_stream)); + zmemcpy((voidpf)copy, (voidpf)state, sizeof(struct inflate_state)); copy->strm = dest; if (state->lencode >= state->codes && state->lencode <= state->codes + ENOUGH - 1) { @@ -1527,10 +1480,7 @@ z_streamp source; return Z_OK; } -int ZEXPORT inflateUndermine(strm, subvert) -z_streamp strm; -int subvert; -{ +int ZEXPORT inflateUndermine(z_streamp strm, int subvert) { struct inflate_state FAR *state; if (inflateStateCheck(strm)) return Z_STREAM_ERROR; @@ -1545,24 +1495,19 @@ int subvert; #endif } -int ZEXPORT inflateValidate(strm, check) -z_streamp strm; -int check; -{ +int ZEXPORT inflateValidate(z_streamp strm, int check) { struct inflate_state FAR *state; if (inflateStateCheck(strm)) return Z_STREAM_ERROR; state = (struct inflate_state FAR *)strm->state; - if (check) + if (check && state->wrap) state->wrap |= 4; else state->wrap &= ~4; return Z_OK; } -long ZEXPORT inflateMark(strm) -z_streamp strm; -{ +long ZEXPORT inflateMark(z_streamp strm) { struct inflate_state FAR *state; if (inflateStateCheck(strm)) @@ -1573,9 +1518,7 @@ z_streamp strm; (state->mode == MATCH ? state->was - state->length : 0)); } -unsigned long ZEXPORT inflateCodesUsed(strm) -z_streamp strm; -{ +unsigned long ZEXPORT inflateCodesUsed(z_streamp strm) { struct inflate_state FAR *state; if (inflateStateCheck(strm)) return (unsigned long)-1; state = (struct inflate_state FAR *)strm->state; diff --git a/common/zlib/inflate.h b/common/zlib/inflate.h old mode 100755 new mode 100644 index a46cce6..f127b6b --- a/common/zlib/inflate.h +++ b/common/zlib/inflate.h @@ -1,5 +1,5 @@ /* inflate.h -- internal inflate state definition - * Copyright (C) 1995-2016 Mark Adler + * Copyright (C) 1995-2019 Mark Adler * For conditions of distribution and use, see copyright notice in zlib.h */ @@ -86,7 +86,8 @@ struct inflate_state { int wrap; /* bit 0 true for zlib, bit 1 true for gzip, bit 2 true to validate check value */ int havedict; /* true if dictionary provided */ - int flags; /* gzip header method and flags (0 if zlib) */ + int flags; /* gzip header method and flags, 0 if zlib, or + -1 if raw or no header yet */ unsigned dmax; /* zlib header max distance (INFLATE_STRICT) */ unsigned long check; /* protected copy of check value */ unsigned long total; /* protected copy of output count */ diff --git a/common/zlib/inftrees.c b/common/zlib/inftrees.c old mode 100755 new mode 100644 index 2ea08fc..98cfe16 --- a/common/zlib/inftrees.c +++ b/common/zlib/inftrees.c @@ -1,5 +1,5 @@ /* inftrees.c -- generate Huffman trees for efficient decoding - * Copyright (C) 1995-2017 Mark Adler + * Copyright (C) 1995-2024 Mark Adler * For conditions of distribution and use, see copyright notice in zlib.h */ @@ -9,7 +9,7 @@ #define MAXBITS 15 const char inflate_copyright[] = - " inflate 1.2.11 Copyright 1995-2017 Mark Adler "; + " inflate 1.3.1 Copyright 1995-2024 Mark Adler "; /* If you use the zlib library in a product, an acknowledgment is welcome in the documentation of your product. If for some reason you cannot @@ -29,14 +29,9 @@ const char inflate_copyright[] = table index bits. It will differ if the request is greater than the longest code or if it is less than the shortest code. */ -int ZLIB_INTERNAL inflate_table(type, lens, codes, table, bits, work) -codetype type; -unsigned short FAR *lens; -unsigned codes; -code FAR * FAR *table; -unsigned FAR *bits; -unsigned short FAR *work; -{ +int ZLIB_INTERNAL inflate_table(codetype type, unsigned short FAR *lens, + unsigned codes, code FAR * FAR *table, + unsigned FAR *bits, unsigned short FAR *work) { unsigned len; /* a code's length in bits */ unsigned sym; /* index of code symbols */ unsigned min, max; /* minimum and maximum code lengths */ @@ -62,7 +57,7 @@ unsigned short FAR *work; 35, 43, 51, 59, 67, 83, 99, 115, 131, 163, 195, 227, 258, 0, 0}; static const unsigned short lext[31] = { /* Length codes 257..285 extra */ 16, 16, 16, 16, 16, 16, 16, 16, 17, 17, 17, 17, 18, 18, 18, 18, - 19, 19, 19, 19, 20, 20, 20, 20, 21, 21, 21, 21, 16, 77, 202}; + 19, 19, 19, 19, 20, 20, 20, 20, 21, 21, 21, 21, 16, 203, 77}; static const unsigned short dbase[32] = { /* Distance codes 0..29 base */ 1, 2, 3, 4, 5, 7, 9, 13, 17, 25, 33, 49, 65, 97, 129, 193, 257, 385, 513, 769, 1025, 1537, 2049, 3073, 4097, 6145, diff --git a/common/zlib/inftrees.h b/common/zlib/inftrees.h old mode 100755 new mode 100644 index baa53a0..396f74b --- a/common/zlib/inftrees.h +++ b/common/zlib/inftrees.h @@ -38,11 +38,11 @@ typedef struct { /* Maximum size of the dynamic table. The maximum number of code structures is 1444, which is the sum of 852 for literal/length codes and 592 for distance codes. These values were found by exhaustive searches using the program - examples/enough.c found in the zlib distribtution. The arguments to that + examples/enough.c found in the zlib distribution. The arguments to that program are the number of symbols, the initial root table size, and the maximum bit length of a code. "enough 286 9 15" for literal/length codes - returns returns 852, and "enough 30 6 15" for distance codes returns 592. - The initial root table size (9 or 6) is found in the fifth argument of the + returns 852, and "enough 30 6 15" for distance codes returns 592. The + initial root table size (9 or 6) is found in the fifth argument of the inflate_table() calls in inflate.c and infback.c. If the root table size is changed, then these maximum sizes would be need to be recalculated and updated. */ @@ -57,6 +57,6 @@ typedef enum { DISTS } codetype; -int ZLIB_INTERNAL inflate_table OF((codetype type, unsigned short FAR *lens, - unsigned codes, code FAR * FAR *table, - unsigned FAR *bits, unsigned short FAR *work)); +int ZLIB_INTERNAL inflate_table(codetype type, unsigned short FAR *lens, + unsigned codes, code FAR * FAR *table, + unsigned FAR *bits, unsigned short FAR *work); diff --git a/common/zlib/trees.c b/common/zlib/trees.c old mode 100755 new mode 100644 index 53cf47d..6a523ef --- a/common/zlib/trees.c +++ b/common/zlib/trees.c @@ -1,5 +1,5 @@ /* trees.c -- output deflated data using Huffman coding - * Copyright (C) 1995-2017 Jean-loup Gailly + * Copyright (C) 1995-2024 Jean-loup Gailly * detect_data_type() function provided freely by Cosmin Truta, 2006 * For conditions of distribution and use, see copyright notice in zlib.h */ @@ -122,39 +122,116 @@ struct static_tree_desc_s { int max_length; /* max bit length for the codes */ }; -local const static_tree_desc static_l_desc = +#ifdef NO_INIT_GLOBAL_POINTERS +# define TCONST +#else +# define TCONST const +#endif + +local TCONST static_tree_desc static_l_desc = {static_ltree, extra_lbits, LITERALS+1, L_CODES, MAX_BITS}; -local const static_tree_desc static_d_desc = +local TCONST static_tree_desc static_d_desc = {static_dtree, extra_dbits, 0, D_CODES, MAX_BITS}; -local const static_tree_desc static_bl_desc = +local TCONST static_tree_desc static_bl_desc = {(const ct_data *)0, extra_blbits, 0, BL_CODES, MAX_BL_BITS}; /* =========================================================================== - * Local (static) routines in this file. + * Output a short LSB first on the stream. + * IN assertion: there is enough room in pendingBuf. */ +#define put_short(s, w) { \ + put_byte(s, (uch)((w) & 0xff)); \ + put_byte(s, (uch)((ush)(w) >> 8)); \ +} -local void tr_static_init OF((void)); -local void init_block OF((deflate_state *s)); -local void pqdownheap OF((deflate_state *s, ct_data *tree, int k)); -local void gen_bitlen OF((deflate_state *s, tree_desc *desc)); -local void gen_codes OF((ct_data *tree, int max_code, ushf *bl_count)); -local void build_tree OF((deflate_state *s, tree_desc *desc)); -local void scan_tree OF((deflate_state *s, ct_data *tree, int max_code)); -local void send_tree OF((deflate_state *s, ct_data *tree, int max_code)); -local int build_bl_tree OF((deflate_state *s)); -local void send_all_trees OF((deflate_state *s, int lcodes, int dcodes, - int blcodes)); -local void compress_block OF((deflate_state *s, const ct_data *ltree, - const ct_data *dtree)); -local int detect_data_type OF((deflate_state *s)); -local unsigned bi_reverse OF((unsigned value, int length)); -local void bi_windup OF((deflate_state *s)); -local void bi_flush OF((deflate_state *s)); +/* =========================================================================== + * Reverse the first len bits of a code, using straightforward code (a faster + * method would use a table) + * IN assertion: 1 <= len <= 15 + */ +local unsigned bi_reverse(unsigned code, int len) { + register unsigned res = 0; + do { + res |= code & 1; + code >>= 1, res <<= 1; + } while (--len > 0); + return res >> 1; +} + +/* =========================================================================== + * Flush the bit buffer, keeping at most 7 bits in it. + */ +local void bi_flush(deflate_state *s) { + if (s->bi_valid == 16) { + put_short(s, s->bi_buf); + s->bi_buf = 0; + s->bi_valid = 0; + } else if (s->bi_valid >= 8) { + put_byte(s, (Byte)s->bi_buf); + s->bi_buf >>= 8; + s->bi_valid -= 8; + } +} + +/* =========================================================================== + * Flush the bit buffer and align the output on a byte boundary + */ +local void bi_windup(deflate_state *s) { + if (s->bi_valid > 8) { + put_short(s, s->bi_buf); + } else if (s->bi_valid > 0) { + put_byte(s, (Byte)s->bi_buf); + } + s->bi_buf = 0; + s->bi_valid = 0; +#ifdef ZLIB_DEBUG + s->bits_sent = (s->bits_sent + 7) & ~7; +#endif +} + +/* =========================================================================== + * Generate the codes for a given tree and bit counts (which need not be + * optimal). + * IN assertion: the array bl_count contains the bit length statistics for + * the given tree and the field len is set for all tree elements. + * OUT assertion: the field code is set for all tree elements of non + * zero code length. + */ +local void gen_codes(ct_data *tree, int max_code, ushf *bl_count) { + ush next_code[MAX_BITS+1]; /* next code value for each bit length */ + unsigned code = 0; /* running code value */ + int bits; /* bit index */ + int n; /* code index */ + + /* The distribution counts are first used to generate the code values + * without bit reversal. + */ + for (bits = 1; bits <= MAX_BITS; bits++) { + code = (code + bl_count[bits - 1]) << 1; + next_code[bits] = (ush)code; + } + /* Check that the bit counts in bl_count are consistent. The last code + * must be all ones. + */ + Assert (code + bl_count[MAX_BITS] - 1 == (1 << MAX_BITS) - 1, + "inconsistent bit counts"); + Tracev((stderr,"\ngen_codes: max_code %d ", max_code)); + + for (n = 0; n <= max_code; n++) { + int len = tree[n].Len; + if (len == 0) continue; + /* Now reverse the bits */ + tree[n].Code = (ush)bi_reverse(next_code[len]++, len); + + Tracecv(tree != static_ltree, (stderr,"\nn %3d %c l %2d c %4x (%x) ", + n, (isgraph(n) ? n : ' '), len, tree[n].Code, next_code[len] - 1)); + } +} #ifdef GEN_TREES_H -local void gen_trees_header OF((void)); +local void gen_trees_header(void); #endif #ifndef ZLIB_DEBUG @@ -167,33 +244,18 @@ local void gen_trees_header OF((void)); send_bits(s, tree[c].Code, tree[c].Len); } #endif -/* =========================================================================== - * Output a short LSB first on the stream. - * IN assertion: there is enough room in pendingBuf. - */ -#define put_short(s, w) { \ - put_byte(s, (uch)((w) & 0xff)); \ - put_byte(s, (uch)((ush)(w) >> 8)); \ -} - /* =========================================================================== * Send a value on a given number of bits. * IN assertion: length <= 16 and value fits in length bits. */ #ifdef ZLIB_DEBUG -local void send_bits OF((deflate_state *s, int value, int length)); - -local void send_bits(s, value, length) - deflate_state *s; - int value; /* value to send */ - int length; /* number of bits */ -{ +local void send_bits(deflate_state *s, int value, int length) { Tracevv((stderr," l %2d v %4x ", length, value)); Assert(length > 0 && length <= 15, "invalid length"); s->bits_sent += (ulg)length; /* If not enough room in bi_buf, use (valid) bits from bi_buf and - * (16 - bi_valid) bits from value, leaving (width - (16-bi_valid)) + * (16 - bi_valid) bits from value, leaving (width - (16 - bi_valid)) * unused bits in value. */ if (s->bi_valid > (int)Buf_size - length) { @@ -229,8 +291,7 @@ local void send_bits(s, value, length) /* =========================================================================== * Initialize the various 'constant' tables. */ -local void tr_static_init() -{ +local void tr_static_init(void) { #if defined(GEN_TREES_H) || !defined(STDC) static int static_init_done = 0; int n; /* iterates over tree elements */ @@ -256,7 +317,7 @@ local void tr_static_init() length = 0; for (code = 0; code < LENGTH_CODES-1; code++) { base_length[code] = length; - for (n = 0; n < (1< dist code (0..29) */ dist = 0; for (code = 0 ; code < 16; code++) { base_dist[code] = dist; - for (n = 0; n < (1<>= 7; /* from now on, all distances are divided by 128 */ for ( ; code < D_CODES; code++) { base_dist[code] = dist << 7; - for (n = 0; n < (1<<(extra_dbits[code]-7)); n++) { + for (n = 0; n < (1 << (extra_dbits[code] - 7)); n++) { _dist_code[256 + dist++] = (uch)code; } } - Assert (dist == 256, "tr_static_init: 256+dist != 512"); + Assert (dist == 256, "tr_static_init: 256 + dist != 512"); /* Construct the codes of the static literal tree */ for (bits = 0; bits <= MAX_BITS; bits++) bl_count[bits] = 0; @@ -312,7 +373,7 @@ local void tr_static_init() } /* =========================================================================== - * Genererate the file trees.h describing the static trees. + * Generate the file trees.h describing the static trees. */ #ifdef GEN_TREES_H # ifndef ZLIB_DEBUG @@ -321,10 +382,9 @@ local void tr_static_init() # define SEPARATOR(i, last, width) \ ((i) == (last)? "\n};\n\n" : \ - ((i) % (width) == (width)-1 ? ",\n" : ", ")) + ((i) % (width) == (width) - 1 ? ",\n" : ", ")) -void gen_trees_header() -{ +void gen_trees_header(void) { FILE *header = fopen("trees.h", "w"); int i; @@ -373,12 +433,26 @@ void gen_trees_header() } #endif /* GEN_TREES_H */ +/* =========================================================================== + * Initialize a new block. + */ +local void init_block(deflate_state *s) { + int n; /* iterates over tree elements */ + + /* Initialize the trees. */ + for (n = 0; n < L_CODES; n++) s->dyn_ltree[n].Freq = 0; + for (n = 0; n < D_CODES; n++) s->dyn_dtree[n].Freq = 0; + for (n = 0; n < BL_CODES; n++) s->bl_tree[n].Freq = 0; + + s->dyn_ltree[END_BLOCK].Freq = 1; + s->opt_len = s->static_len = 0L; + s->sym_next = s->matches = 0; +} + /* =========================================================================== * Initialize the tree data structures for a new zlib stream. */ -void ZLIB_INTERNAL _tr_init(s) - deflate_state *s; -{ +void ZLIB_INTERNAL _tr_init(deflate_state *s) { tr_static_init(); s->l_desc.dyn_tree = s->dyn_ltree; @@ -401,24 +475,6 @@ void ZLIB_INTERNAL _tr_init(s) init_block(s); } -/* =========================================================================== - * Initialize a new block. - */ -local void init_block(s) - deflate_state *s; -{ - int n; /* iterates over tree elements */ - - /* Initialize the trees. */ - for (n = 0; n < L_CODES; n++) s->dyn_ltree[n].Freq = 0; - for (n = 0; n < D_CODES; n++) s->dyn_dtree[n].Freq = 0; - for (n = 0; n < BL_CODES; n++) s->bl_tree[n].Freq = 0; - - s->dyn_ltree[END_BLOCK].Freq = 1; - s->opt_len = s->static_len = 0L; - s->last_lit = s->matches = 0; -} - #define SMALLEST 1 /* Index within the heap array of least frequent node in the Huffman tree */ @@ -448,17 +504,13 @@ local void init_block(s) * when the heap property is re-established (each father smaller than its * two sons). */ -local void pqdownheap(s, tree, k) - deflate_state *s; - ct_data *tree; /* the tree to restore */ - int k; /* node to move down */ -{ +local void pqdownheap(deflate_state *s, ct_data *tree, int k) { int v = s->heap[k]; int j = k << 1; /* left son of k */ while (j <= s->heap_len) { /* Set j to the smallest of the two sons: */ if (j < s->heap_len && - smaller(tree, s->heap[j+1], s->heap[j], s->depth)) { + smaller(tree, s->heap[j + 1], s->heap[j], s->depth)) { j++; } /* Exit if v is smaller than both sons */ @@ -483,10 +535,7 @@ local void pqdownheap(s, tree, k) * The length opt_len is updated; static_len is also updated if stree is * not null. */ -local void gen_bitlen(s, desc) - deflate_state *s; - tree_desc *desc; /* the tree descriptor */ -{ +local void gen_bitlen(deflate_state *s, tree_desc *desc) { ct_data *tree = desc->dyn_tree; int max_code = desc->max_code; const ct_data *stree = desc->stat_desc->static_tree; @@ -507,10 +556,10 @@ local void gen_bitlen(s, desc) */ tree[s->heap[s->heap_max]].Len = 0; /* root of the heap */ - for (h = s->heap_max+1; h < HEAP_SIZE; h++) { + for (h = s->heap_max + 1; h < HEAP_SIZE; h++) { n = s->heap[h]; bits = tree[tree[n].Dad].Len + 1; - if (bits > max_length) {bits = max_length; overflow++;} + if (bits > max_length) bits = max_length, overflow++; tree[n].Len = (ush)bits; /* We overwrite tree[n].Dad which is no longer needed */ @@ -518,7 +567,7 @@ local void gen_bitlen(s, desc) s->bl_count[bits]++; xbits = 0; - if (n >= base) xbits = extra[n-base]; + if (n >= base) xbits = extra[n - base]; f = tree[n].Freq; s->opt_len += (ulg)f * (unsigned)(bits + xbits); if (stree) s->static_len += (ulg)f * (unsigned)(stree[n].Len + xbits); @@ -530,10 +579,10 @@ local void gen_bitlen(s, desc) /* Find the first bit length which could increase: */ do { - bits = max_length-1; + bits = max_length - 1; while (s->bl_count[bits] == 0) bits--; - s->bl_count[bits]--; /* move one leaf down the tree */ - s->bl_count[bits+1] += 2; /* move one overflow item as its brother */ + s->bl_count[bits]--; /* move one leaf down the tree */ + s->bl_count[bits + 1] += 2; /* move one overflow item as its brother */ s->bl_count[max_length]--; /* The brother of the overflow item also moves one step up, * but this does not affect bl_count[max_length] @@ -561,48 +610,9 @@ local void gen_bitlen(s, desc) } } -/* =========================================================================== - * Generate the codes for a given tree and bit counts (which need not be - * optimal). - * IN assertion: the array bl_count contains the bit length statistics for - * the given tree and the field len is set for all tree elements. - * OUT assertion: the field code is set for all tree elements of non - * zero code length. - */ -local void gen_codes (tree, max_code, bl_count) - ct_data *tree; /* the tree to decorate */ - int max_code; /* largest code with non zero frequency */ - ushf *bl_count; /* number of codes at each bit length */ -{ - ush next_code[MAX_BITS+1]; /* next code value for each bit length */ - unsigned code = 0; /* running code value */ - int bits; /* bit index */ - int n; /* code index */ - - /* The distribution counts are first used to generate the code values - * without bit reversal. - */ - for (bits = 1; bits <= MAX_BITS; bits++) { - code = (code + bl_count[bits-1]) << 1; - next_code[bits] = (ush)code; - } - /* Check that the bit counts in bl_count are consistent. The last code - * must be all ones. - */ - Assert (code + bl_count[MAX_BITS]-1 == (1< +#endif /* =========================================================================== * Construct one Huffman tree and assigns the code bit strings and lengths. @@ -612,10 +622,7 @@ local void gen_codes (tree, max_code, bl_count) * and corresponding code. The length opt_len is updated; static_len is * also updated if stree is not null. The field max_code is set. */ -local void build_tree(s, desc) - deflate_state *s; - tree_desc *desc; /* the tree descriptor */ -{ +local void build_tree(deflate_state *s, tree_desc *desc) { ct_data *tree = desc->dyn_tree; const ct_data *stree = desc->stat_desc->static_tree; int elems = desc->stat_desc->elems; @@ -624,10 +631,10 @@ local void build_tree(s, desc) int node; /* new node being created */ /* Construct the initial heap, with least frequent element in - * heap[SMALLEST]. The sons of heap[n] are heap[2*n] and heap[2*n+1]. + * heap[SMALLEST]. The sons of heap[n] are heap[2*n] and heap[2*n + 1]. * heap[0] is not used. */ - s->heap_len = 0; s->heap_max = HEAP_SIZE; + s->heap_len = 0, s->heap_max = HEAP_SIZE; for (n = 0; n < elems; n++) { if (tree[n].Freq != 0) { @@ -652,7 +659,7 @@ local void build_tree(s, desc) } desc->max_code = max_code; - /* The elements heap[heap_len/2+1 .. heap_len] are leaves of the tree, + /* The elements heap[heap_len/2 + 1 .. heap_len] are leaves of the tree, * establish sub-heaps of increasing lengths: */ for (n = s->heap_len/2; n >= 1; n--) pqdownheap(s, tree, n); @@ -700,11 +707,7 @@ local void build_tree(s, desc) * Scan a literal or distance tree to determine the frequencies of the codes * in the bit length tree. */ -local void scan_tree (s, tree, max_code) - deflate_state *s; - ct_data *tree; /* the tree to be scanned */ - int max_code; /* and its largest code of non zero frequency */ -{ +local void scan_tree(deflate_state *s, ct_data *tree, int max_code) { int n; /* iterates over all tree elements */ int prevlen = -1; /* last emitted length */ int curlen; /* length of current code */ @@ -713,11 +716,11 @@ local void scan_tree (s, tree, max_code) int max_count = 7; /* max repeat count */ int min_count = 4; /* min repeat count */ - if (nextlen == 0) {max_count = 138; min_count = 3;} - tree[max_code+1].Len = (ush)0xffff; /* guard */ + if (nextlen == 0) max_count = 138, min_count = 3; + tree[max_code + 1].Len = (ush)0xffff; /* guard */ for (n = 0; n <= max_code; n++) { - curlen = nextlen; nextlen = tree[n+1].Len; + curlen = nextlen; nextlen = tree[n + 1].Len; if (++count < max_count && curlen == nextlen) { continue; } else if (count < min_count) { @@ -732,11 +735,11 @@ local void scan_tree (s, tree, max_code) } count = 0; prevlen = curlen; if (nextlen == 0) { - max_count = 138; min_count = 3; + max_count = 138, min_count = 3; } else if (curlen == nextlen) { - max_count = 6; min_count = 3; + max_count = 6, min_count = 3; } else { - max_count = 7; min_count = 4; + max_count = 7, min_count = 4; } } } @@ -745,11 +748,7 @@ local void scan_tree (s, tree, max_code) * Send a literal or distance tree in compressed form, using the codes in * bl_tree. */ -local void send_tree (s, tree, max_code) - deflate_state *s; - ct_data *tree; /* the tree to be scanned */ - int max_code; /* and its largest code of non zero frequency */ -{ +local void send_tree(deflate_state *s, ct_data *tree, int max_code) { int n; /* iterates over all tree elements */ int prevlen = -1; /* last emitted length */ int curlen; /* length of current code */ @@ -758,11 +757,11 @@ local void send_tree (s, tree, max_code) int max_count = 7; /* max repeat count */ int min_count = 4; /* min repeat count */ - /* tree[max_code+1].Len = -1; */ /* guard already set */ - if (nextlen == 0) {max_count = 138; min_count = 3;} + /* tree[max_code + 1].Len = -1; */ /* guard already set */ + if (nextlen == 0) max_count = 138, min_count = 3; for (n = 0; n <= max_code; n++) { - curlen = nextlen; nextlen = tree[n+1].Len; + curlen = nextlen; nextlen = tree[n + 1].Len; if (++count < max_count && curlen == nextlen) { continue; } else if (count < min_count) { @@ -773,21 +772,21 @@ local void send_tree (s, tree, max_code) send_code(s, curlen, s->bl_tree); count--; } Assert(count >= 3 && count <= 6, " 3_6?"); - send_code(s, REP_3_6, s->bl_tree); send_bits(s, count-3, 2); + send_code(s, REP_3_6, s->bl_tree); send_bits(s, count - 3, 2); } else if (count <= 10) { - send_code(s, REPZ_3_10, s->bl_tree); send_bits(s, count-3, 3); + send_code(s, REPZ_3_10, s->bl_tree); send_bits(s, count - 3, 3); } else { - send_code(s, REPZ_11_138, s->bl_tree); send_bits(s, count-11, 7); + send_code(s, REPZ_11_138, s->bl_tree); send_bits(s, count - 11, 7); } count = 0; prevlen = curlen; if (nextlen == 0) { - max_count = 138; min_count = 3; + max_count = 138, min_count = 3; } else if (curlen == nextlen) { - max_count = 6; min_count = 3; + max_count = 6, min_count = 3; } else { - max_count = 7; min_count = 4; + max_count = 7, min_count = 4; } } } @@ -796,9 +795,7 @@ local void send_tree (s, tree, max_code) * Construct the Huffman tree for the bit lengths and return the index in * bl_order of the last bit length code to send. */ -local int build_bl_tree(s) - deflate_state *s; -{ +local int build_bl_tree(deflate_state *s) { int max_blindex; /* index of last bit length code of non zero freq */ /* Determine the bit length frequencies for literal and distance trees */ @@ -807,8 +804,8 @@ local int build_bl_tree(s) /* Build the bit length tree: */ build_tree(s, (tree_desc *)(&(s->bl_desc))); - /* opt_len now includes the length of the tree representations, except - * the lengths of the bit lengths codes and the 5+5+4 bits for the counts. + /* opt_len now includes the length of the tree representations, except the + * lengths of the bit lengths codes and the 5 + 5 + 4 bits for the counts. */ /* Determine the number of bit length codes to send. The pkzip format @@ -819,7 +816,7 @@ local int build_bl_tree(s) if (s->bl_tree[bl_order[max_blindex]].Len != 0) break; } /* Update opt_len to include the bit length tree and counts */ - s->opt_len += 3*((ulg)max_blindex+1) + 5+5+4; + s->opt_len += 3*((ulg)max_blindex + 1) + 5 + 5 + 4; Tracev((stderr, "\ndyn trees: dyn %ld, stat %ld", s->opt_len, s->static_len)); @@ -831,61 +828,54 @@ local int build_bl_tree(s) * lengths of the bit length codes, the literal tree and the distance tree. * IN assertion: lcodes >= 257, dcodes >= 1, blcodes >= 4. */ -local void send_all_trees(s, lcodes, dcodes, blcodes) - deflate_state *s; - int lcodes, dcodes, blcodes; /* number of codes for each tree */ -{ +local void send_all_trees(deflate_state *s, int lcodes, int dcodes, + int blcodes) { int rank; /* index in bl_order */ Assert (lcodes >= 257 && dcodes >= 1 && blcodes >= 4, "not enough codes"); Assert (lcodes <= L_CODES && dcodes <= D_CODES && blcodes <= BL_CODES, "too many codes"); Tracev((stderr, "\nbl counts: ")); - send_bits(s, lcodes-257, 5); /* not +255 as stated in appnote.txt */ - send_bits(s, dcodes-1, 5); - send_bits(s, blcodes-4, 4); /* not -3 as stated in appnote.txt */ + send_bits(s, lcodes - 257, 5); /* not +255 as stated in appnote.txt */ + send_bits(s, dcodes - 1, 5); + send_bits(s, blcodes - 4, 4); /* not -3 as stated in appnote.txt */ for (rank = 0; rank < blcodes; rank++) { Tracev((stderr, "\nbl code %2d ", bl_order[rank])); send_bits(s, s->bl_tree[bl_order[rank]].Len, 3); } Tracev((stderr, "\nbl tree: sent %ld", s->bits_sent)); - send_tree(s, (ct_data *)s->dyn_ltree, lcodes-1); /* literal tree */ + send_tree(s, (ct_data *)s->dyn_ltree, lcodes - 1); /* literal tree */ Tracev((stderr, "\nlit tree: sent %ld", s->bits_sent)); - send_tree(s, (ct_data *)s->dyn_dtree, dcodes-1); /* distance tree */ + send_tree(s, (ct_data *)s->dyn_dtree, dcodes - 1); /* distance tree */ Tracev((stderr, "\ndist tree: sent %ld", s->bits_sent)); } /* =========================================================================== * Send a stored block */ -void ZLIB_INTERNAL _tr_stored_block(s, buf, stored_len, last) - deflate_state *s; - charf *buf; /* input block */ - ulg stored_len; /* length of input block */ - int last; /* one if this is the last block for a file */ -{ - send_bits(s, (STORED_BLOCK<<1)+last, 3); /* send block type */ +void ZLIB_INTERNAL _tr_stored_block(deflate_state *s, charf *buf, + ulg stored_len, int last) { + send_bits(s, (STORED_BLOCK<<1) + last, 3); /* send block type */ bi_windup(s); /* align on byte boundary */ put_short(s, (ush)stored_len); put_short(s, (ush)~stored_len); - zmemcpy(s->pending_buf + s->pending, (Bytef *)buf, stored_len); + if (stored_len) + zmemcpy(s->pending_buf + s->pending, (Bytef *)buf, stored_len); s->pending += stored_len; #ifdef ZLIB_DEBUG s->compressed_len = (s->compressed_len + 3 + 7) & (ulg)~7L; s->compressed_len += (stored_len + 4) << 3; s->bits_sent += 2*16; - s->bits_sent += stored_len<<3; + s->bits_sent += stored_len << 3; #endif } /* =========================================================================== * Flush the bits in the bit buffer to pending output (leaves at most 7 bits) */ -void ZLIB_INTERNAL _tr_flush_bits(s) - deflate_state *s; -{ +void ZLIB_INTERNAL _tr_flush_bits(deflate_state *s) { bi_flush(s); } @@ -893,9 +883,7 @@ void ZLIB_INTERNAL _tr_flush_bits(s) * Send one empty static block to give enough lookahead for inflate. * This takes 10 bits, of which 7 may remain in the bit buffer. */ -void ZLIB_INTERNAL _tr_align(s) - deflate_state *s; -{ +void ZLIB_INTERNAL _tr_align(deflate_state *s) { send_bits(s, STATIC_TREES<<1, 3); send_code(s, END_BLOCK, static_ltree); #ifdef ZLIB_DEBUG @@ -904,16 +892,108 @@ void ZLIB_INTERNAL _tr_align(s) bi_flush(s); } +/* =========================================================================== + * Send the block data compressed using the given Huffman trees + */ +local void compress_block(deflate_state *s, const ct_data *ltree, + const ct_data *dtree) { + unsigned dist; /* distance of matched string */ + int lc; /* match length or unmatched char (if dist == 0) */ + unsigned sx = 0; /* running index in symbol buffers */ + unsigned code; /* the code to send */ + int extra; /* number of extra bits to send */ + + if (s->sym_next != 0) do { +#ifdef LIT_MEM + dist = s->d_buf[sx]; + lc = s->l_buf[sx++]; +#else + dist = s->sym_buf[sx++] & 0xff; + dist += (unsigned)(s->sym_buf[sx++] & 0xff) << 8; + lc = s->sym_buf[sx++]; +#endif + if (dist == 0) { + send_code(s, lc, ltree); /* send a literal byte */ + Tracecv(isgraph(lc), (stderr," '%c' ", lc)); + } else { + /* Here, lc is the match length - MIN_MATCH */ + code = _length_code[lc]; + send_code(s, code + LITERALS + 1, ltree); /* send length code */ + extra = extra_lbits[code]; + if (extra != 0) { + lc -= base_length[code]; + send_bits(s, lc, extra); /* send the extra length bits */ + } + dist--; /* dist is now the match distance - 1 */ + code = d_code(dist); + Assert (code < D_CODES, "bad d_code"); + + send_code(s, code, dtree); /* send the distance code */ + extra = extra_dbits[code]; + if (extra != 0) { + dist -= (unsigned)base_dist[code]; + send_bits(s, dist, extra); /* send the extra distance bits */ + } + } /* literal or match pair ? */ + + /* Check for no overlay of pending_buf on needed symbols */ +#ifdef LIT_MEM + Assert(s->pending < 2 * (s->lit_bufsize + sx), "pendingBuf overflow"); +#else + Assert(s->pending < s->lit_bufsize + sx, "pendingBuf overflow"); +#endif + + } while (sx < s->sym_next); + + send_code(s, END_BLOCK, ltree); +} + +/* =========================================================================== + * Check if the data type is TEXT or BINARY, using the following algorithm: + * - TEXT if the two conditions below are satisfied: + * a) There are no non-portable control characters belonging to the + * "block list" (0..6, 14..25, 28..31). + * b) There is at least one printable character belonging to the + * "allow list" (9 {TAB}, 10 {LF}, 13 {CR}, 32..255). + * - BINARY otherwise. + * - The following partially-portable control characters form a + * "gray list" that is ignored in this detection algorithm: + * (7 {BEL}, 8 {BS}, 11 {VT}, 12 {FF}, 26 {SUB}, 27 {ESC}). + * IN assertion: the fields Freq of dyn_ltree are set. + */ +local int detect_data_type(deflate_state *s) { + /* block_mask is the bit mask of block-listed bytes + * set bits 0..6, 14..25, and 28..31 + * 0xf3ffc07f = binary 11110011111111111100000001111111 + */ + unsigned long block_mask = 0xf3ffc07fUL; + int n; + + /* Check for non-textual ("block-listed") bytes. */ + for (n = 0; n <= 31; n++, block_mask >>= 1) + if ((block_mask & 1) && (s->dyn_ltree[n].Freq != 0)) + return Z_BINARY; + + /* Check for textual ("allow-listed") bytes. */ + if (s->dyn_ltree[9].Freq != 0 || s->dyn_ltree[10].Freq != 0 + || s->dyn_ltree[13].Freq != 0) + return Z_TEXT; + for (n = 32; n < LITERALS; n++) + if (s->dyn_ltree[n].Freq != 0) + return Z_TEXT; + + /* There are no "block-listed" or "allow-listed" bytes: + * this stream either is empty or has tolerated ("gray-listed") bytes only. + */ + return Z_BINARY; +} + /* =========================================================================== * Determine the best encoding for the current block: dynamic trees, static * trees or store, and write out the encoded block. */ -void ZLIB_INTERNAL _tr_flush_block(s, buf, stored_len, last) - deflate_state *s; - charf *buf; /* input block, or NULL if too old */ - ulg stored_len; /* length of input block */ - int last; /* one if this is the last block for a file */ -{ +void ZLIB_INTERNAL _tr_flush_block(deflate_state *s, charf *buf, + ulg stored_len, int last) { ulg opt_lenb, static_lenb; /* opt_len and static_len in bytes */ int max_blindex = 0; /* index of last bit length code of non zero freq */ @@ -942,14 +1022,17 @@ void ZLIB_INTERNAL _tr_flush_block(s, buf, stored_len, last) max_blindex = build_bl_tree(s); /* Determine the best encoding. Compute the block lengths in bytes. */ - opt_lenb = (s->opt_len+3+7)>>3; - static_lenb = (s->static_len+3+7)>>3; + opt_lenb = (s->opt_len + 3 + 7) >> 3; + static_lenb = (s->static_len + 3 + 7) >> 3; Tracev((stderr, "\nopt %lu(%lu) stat %lu(%lu) stored %lu lit %u ", opt_lenb, s->opt_len, static_lenb, s->static_len, stored_len, - s->last_lit)); + s->sym_next / 3)); - if (static_lenb <= opt_lenb) opt_lenb = static_lenb; +#ifndef FORCE_STATIC + if (static_lenb <= opt_lenb || s->strategy == Z_FIXED) +#endif + opt_lenb = static_lenb; } else { Assert(buf != (char*)0, "lost buf"); @@ -959,7 +1042,7 @@ void ZLIB_INTERNAL _tr_flush_block(s, buf, stored_len, last) #ifdef FORCE_STORED if (buf != (char*)0) { /* force stored block */ #else - if (stored_len+4 <= opt_lenb && buf != (char*)0) { + if (stored_len + 4 <= opt_lenb && buf != (char*)0) { /* 4: two words for the lengths */ #endif /* The test buf != NULL is only necessary if LIT_BUFSIZE > WSIZE. @@ -970,21 +1053,17 @@ void ZLIB_INTERNAL _tr_flush_block(s, buf, stored_len, last) */ _tr_stored_block(s, buf, stored_len, last); -#ifdef FORCE_STATIC - } else if (static_lenb >= 0) { /* force static trees */ -#else - } else if (s->strategy == Z_FIXED || static_lenb == opt_lenb) { -#endif - send_bits(s, (STATIC_TREES<<1)+last, 3); + } else if (static_lenb == opt_lenb) { + send_bits(s, (STATIC_TREES<<1) + last, 3); compress_block(s, (const ct_data *)static_ltree, (const ct_data *)static_dtree); #ifdef ZLIB_DEBUG s->compressed_len += 3 + s->static_len; #endif } else { - send_bits(s, (DYN_TREES<<1)+last, 3); - send_all_trees(s, s->l_desc.max_code+1, s->d_desc.max_code+1, - max_blindex+1); + send_bits(s, (DYN_TREES<<1) + last, 3); + send_all_trees(s, s->l_desc.max_code + 1, s->d_desc.max_code + 1, + max_blindex + 1); compress_block(s, (const ct_data *)s->dyn_ltree, (const ct_data *)s->dyn_dtree); #ifdef ZLIB_DEBUG @@ -1003,21 +1082,23 @@ void ZLIB_INTERNAL _tr_flush_block(s, buf, stored_len, last) s->compressed_len += 7; /* align on byte boundary */ #endif } - Tracev((stderr,"\ncomprlen %lu(%lu) ", s->compressed_len>>3, - s->compressed_len-7*last)); + Tracev((stderr,"\ncomprlen %lu(%lu) ", s->compressed_len >> 3, + s->compressed_len - 7*last)); } /* =========================================================================== * Save the match info and tally the frequency counts. Return true if * the current block must be flushed. */ -int ZLIB_INTERNAL _tr_tally (s, dist, lc) - deflate_state *s; - unsigned dist; /* distance of matched string */ - unsigned lc; /* match length-MIN_MATCH or unmatched char (if dist==0) */ -{ - s->d_buf[s->last_lit] = (ush)dist; - s->l_buf[s->last_lit++] = (uch)lc; +int ZLIB_INTERNAL _tr_tally(deflate_state *s, unsigned dist, unsigned lc) { +#ifdef LIT_MEM + s->d_buf[s->sym_next] = (ush)dist; + s->l_buf[s->sym_next++] = (uch)lc; +#else + s->sym_buf[s->sym_next++] = (uch)dist; + s->sym_buf[s->sym_next++] = (uch)(dist >> 8); + s->sym_buf[s->sym_next++] = (uch)lc; +#endif if (dist == 0) { /* lc is the unmatched char */ s->dyn_ltree[lc].Freq++; @@ -1029,175 +1110,8 @@ int ZLIB_INTERNAL _tr_tally (s, dist, lc) (ush)lc <= (ush)(MAX_MATCH-MIN_MATCH) && (ush)d_code(dist) < (ush)D_CODES, "_tr_tally: bad match"); - s->dyn_ltree[_length_code[lc]+LITERALS+1].Freq++; + s->dyn_ltree[_length_code[lc] + LITERALS + 1].Freq++; s->dyn_dtree[d_code(dist)].Freq++; } - -#ifdef TRUNCATE_BLOCK - /* Try to guess if it is profitable to stop the current block here */ - if ((s->last_lit & 0x1fff) == 0 && s->level > 2) { - /* Compute an upper bound for the compressed length */ - ulg out_length = (ulg)s->last_lit*8L; - ulg in_length = (ulg)((long)s->strstart - s->block_start); - int dcode; - for (dcode = 0; dcode < D_CODES; dcode++) { - out_length += (ulg)s->dyn_dtree[dcode].Freq * - (5L+extra_dbits[dcode]); - } - out_length >>= 3; - Tracev((stderr,"\nlast_lit %u, in %ld, out ~%ld(%ld%%) ", - s->last_lit, in_length, out_length, - 100L - out_length*100L/in_length)); - if (s->matches < s->last_lit/2 && out_length < in_length/2) return 1; - } -#endif - return (s->last_lit == s->lit_bufsize-1); - /* We avoid equality with lit_bufsize because of wraparound at 64K - * on 16 bit machines and because stored blocks are restricted to - * 64K-1 bytes. - */ -} - -/* =========================================================================== - * Send the block data compressed using the given Huffman trees - */ -local void compress_block(s, ltree, dtree) - deflate_state *s; - const ct_data *ltree; /* literal tree */ - const ct_data *dtree; /* distance tree */ -{ - unsigned dist; /* distance of matched string */ - int lc; /* match length or unmatched char (if dist == 0) */ - unsigned lx = 0; /* running index in l_buf */ - unsigned code; /* the code to send */ - int extra; /* number of extra bits to send */ - - if (s->last_lit != 0) do { - dist = s->d_buf[lx]; - lc = s->l_buf[lx++]; - if (dist == 0) { - send_code(s, lc, ltree); /* send a literal byte */ - Tracecv(isgraph(lc), (stderr," '%c' ", lc)); - } else { - /* Here, lc is the match length - MIN_MATCH */ - code = _length_code[lc]; - send_code(s, code+LITERALS+1, ltree); /* send the length code */ - extra = extra_lbits[code]; - if (extra != 0) { - lc -= base_length[code]; - send_bits(s, lc, extra); /* send the extra length bits */ - } - dist--; /* dist is now the match distance - 1 */ - code = d_code(dist); - Assert (code < D_CODES, "bad d_code"); - - send_code(s, code, dtree); /* send the distance code */ - extra = extra_dbits[code]; - if (extra != 0) { - dist -= (unsigned)base_dist[code]; - send_bits(s, dist, extra); /* send the extra distance bits */ - } - } /* literal or match pair ? */ - - /* Check that the overlay between pending_buf and d_buf+l_buf is ok: */ - Assert((uInt)(s->pending) < s->lit_bufsize + 2*lx, - "pendingBuf overflow"); - - } while (lx < s->last_lit); - - send_code(s, END_BLOCK, ltree); -} - -/* =========================================================================== - * Check if the data type is TEXT or BINARY, using the following algorithm: - * - TEXT if the two conditions below are satisfied: - * a) There are no non-portable control characters belonging to the - * "black list" (0..6, 14..25, 28..31). - * b) There is at least one printable character belonging to the - * "white list" (9 {TAB}, 10 {LF}, 13 {CR}, 32..255). - * - BINARY otherwise. - * - The following partially-portable control characters form a - * "gray list" that is ignored in this detection algorithm: - * (7 {BEL}, 8 {BS}, 11 {VT}, 12 {FF}, 26 {SUB}, 27 {ESC}). - * IN assertion: the fields Freq of dyn_ltree are set. - */ -local int detect_data_type(s) - deflate_state *s; -{ - /* black_mask is the bit mask of black-listed bytes - * set bits 0..6, 14..25, and 28..31 - * 0xf3ffc07f = binary 11110011111111111100000001111111 - */ - unsigned long black_mask = 0xf3ffc07fUL; - int n; - - /* Check for non-textual ("black-listed") bytes. */ - for (n = 0; n <= 31; n++, black_mask >>= 1) - if ((black_mask & 1) && (s->dyn_ltree[n].Freq != 0)) - return Z_BINARY; - - /* Check for textual ("white-listed") bytes. */ - if (s->dyn_ltree[9].Freq != 0 || s->dyn_ltree[10].Freq != 0 - || s->dyn_ltree[13].Freq != 0) - return Z_TEXT; - for (n = 32; n < LITERALS; n++) - if (s->dyn_ltree[n].Freq != 0) - return Z_TEXT; - - /* There are no "black-listed" or "white-listed" bytes: - * this stream either is empty or has tolerated ("gray-listed") bytes only. - */ - return Z_BINARY; -} - -/* =========================================================================== - * Reverse the first len bits of a code, using straightforward code (a faster - * method would use a table) - * IN assertion: 1 <= len <= 15 - */ -local unsigned bi_reverse(code, len) - unsigned code; /* the value to invert */ - int len; /* its bit length */ -{ - register unsigned res = 0; - do { - res |= code & 1; - code >>= 1; res <<= 1; - } while (--len > 0); - return res >> 1; -} - -/* =========================================================================== - * Flush the bit buffer, keeping at most 7 bits in it. - */ -local void bi_flush(s) - deflate_state *s; -{ - if (s->bi_valid == 16) { - put_short(s, s->bi_buf); - s->bi_buf = 0; - s->bi_valid = 0; - } else if (s->bi_valid >= 8) { - put_byte(s, (Byte)s->bi_buf); - s->bi_buf >>= 8; - s->bi_valid -= 8; - } -} - -/* =========================================================================== - * Flush the bit buffer and align the output on a byte boundary - */ -local void bi_windup(s) - deflate_state *s; -{ - if (s->bi_valid > 8) { - put_short(s, s->bi_buf); - } else if (s->bi_valid > 0) { - put_byte(s, (Byte)s->bi_buf); - } - s->bi_buf = 0; - s->bi_valid = 0; -#ifdef ZLIB_DEBUG - s->bits_sent = (s->bits_sent+7) & ~7; -#endif + return (s->sym_next == s->sym_end); } diff --git a/common/zlib/trees.h b/common/zlib/trees.h old mode 100755 new mode 100644 diff --git a/common/zlib/uncompr.c b/common/zlib/uncompr.c old mode 100755 new mode 100644 index f03a1a8..5e25666 --- a/common/zlib/uncompr.c +++ b/common/zlib/uncompr.c @@ -24,12 +24,8 @@ Z_DATA_ERROR if the input data was corrupted, including if the input data is an incomplete zlib stream. */ -int ZEXPORT uncompress2 (dest, destLen, source, sourceLen) - Bytef *dest; - uLongf *destLen; - const Bytef *source; - uLong *sourceLen; -{ +int ZEXPORT uncompress2(Bytef *dest, uLongf *destLen, const Bytef *source, + uLong *sourceLen) { z_stream stream; int err; const uInt max = (uInt)-1; @@ -83,11 +79,7 @@ int ZEXPORT uncompress2 (dest, destLen, source, sourceLen) err; } -int ZEXPORT uncompress (dest, destLen, source, sourceLen) - Bytef *dest; - uLongf *destLen; - const Bytef *source; - uLong sourceLen; -{ +int ZEXPORT uncompress(Bytef *dest, uLongf *destLen, const Bytef *source, + uLong sourceLen) { return uncompress2(dest, destLen, source, &sourceLen); } diff --git a/common/zlib/zconf.h b/common/zlib/zconf.h old mode 100755 new mode 100644 index 5e1d68a..62adc8d --- a/common/zlib/zconf.h +++ b/common/zlib/zconf.h @@ -1,5 +1,5 @@ /* zconf.h -- configuration of the zlib compression library - * Copyright (C) 1995-2016 Jean-loup Gailly, Mark Adler + * Copyright (C) 1995-2024 Jean-loup Gailly, Mark Adler * For conditions of distribution and use, see copyright notice in zlib.h */ @@ -38,6 +38,9 @@ # define crc32 z_crc32 # define crc32_combine z_crc32_combine # define crc32_combine64 z_crc32_combine64 +# define crc32_combine_gen z_crc32_combine_gen +# define crc32_combine_gen64 z_crc32_combine_gen64 +# define crc32_combine_op z_crc32_combine_op # define crc32_z z_crc32_z # define deflate z_deflate # define deflateBound z_deflateBound @@ -238,7 +241,11 @@ #endif #ifdef Z_SOLO - typedef unsigned long z_size_t; +# ifdef _WIN64 + typedef unsigned long long z_size_t; +# else + typedef unsigned long z_size_t; +# endif #else # define z_longlong long long # if defined(NO_SIZE_T) @@ -293,14 +300,6 @@ # endif #endif -#ifndef Z_ARG /* function prototypes for stdarg */ -# if defined(STDC) || defined(Z_HAVE_STDARG_H) -# define Z_ARG(args) args -# else -# define Z_ARG(args) () -# endif -#endif - /* The following definitions for FAR are needed only for MSDOS mixed * model programming (small or medium model with some far allocations). * This was tested only with MSC; for other MSDOS compilers you may have @@ -349,6 +348,9 @@ # ifdef FAR # undef FAR # endif +# ifndef WIN32_LEAN_AND_MEAN +# define WIN32_LEAN_AND_MEAN +# endif # include /* No need for _export, use ZLIB.DEF instead. */ /* For complete Windows compatibility, use WINAPI, not __stdcall. */ @@ -467,11 +469,18 @@ typedef uLong FAR uLongf; # undef _LARGEFILE64_SOURCE #endif -#if defined(__WATCOMC__) && !defined(Z_HAVE_UNISTD_H) -# define Z_HAVE_UNISTD_H +#ifndef Z_HAVE_UNISTD_H +# ifdef __WATCOMC__ +# define Z_HAVE_UNISTD_H +# endif +#endif +#ifndef Z_HAVE_UNISTD_H +# if defined(_LARGEFILE64_SOURCE) && !defined(_WIN32) +# define Z_HAVE_UNISTD_H +# endif #endif #ifndef Z_SOLO -# if defined(Z_HAVE_UNISTD_H) || defined(_LARGEFILE64_SOURCE) +# if defined(Z_HAVE_UNISTD_H) # include /* for SEEK_*, off_t, and _LFS64_LARGEFILE */ # ifdef VMS # include /* for off_t */ @@ -507,7 +516,7 @@ typedef uLong FAR uLongf; #if !defined(_WIN32) && defined(Z_LARGE64) # define z_off64_t off64_t #else -# if defined(_WIN32) && !defined(__GNUC__) && !defined(Z_SOLO) +# if defined(_WIN32) && !defined(__GNUC__) # define z_off64_t __int64 # else # define z_off64_t z_off_t diff --git a/common/zlib/zlib.h b/common/zlib/zlib.h old mode 100755 new mode 100644 index f09cdaf..8d4b932 --- a/common/zlib/zlib.h +++ b/common/zlib/zlib.h @@ -1,7 +1,7 @@ /* zlib.h -- interface of the 'zlib' general purpose compression library - version 1.2.11, January 15th, 2017 + version 1.3.1, January 22nd, 2024 - Copyright (C) 1995-2017 Jean-loup Gailly and Mark Adler + Copyright (C) 1995-2024 Jean-loup Gailly and Mark Adler This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages @@ -37,11 +37,11 @@ extern "C" { #endif -#define ZLIB_VERSION "1.2.11" -#define ZLIB_VERNUM 0x12b0 +#define ZLIB_VERSION "1.3.1" +#define ZLIB_VERNUM 0x1310 #define ZLIB_VER_MAJOR 1 -#define ZLIB_VER_MINOR 2 -#define ZLIB_VER_REVISION 11 +#define ZLIB_VER_MINOR 3 +#define ZLIB_VER_REVISION 1 #define ZLIB_VER_SUBREVISION 0 /* @@ -78,8 +78,8 @@ extern "C" { even in the case of corrupted input. */ -typedef voidpf (*alloc_func) OF((voidpf opaque, uInt items, uInt size)); -typedef void (*free_func) OF((voidpf opaque, voidpf address)); +typedef voidpf (*alloc_func)(voidpf opaque, uInt items, uInt size); +typedef void (*free_func)(voidpf opaque, voidpf address); struct internal_state; @@ -217,7 +217,7 @@ typedef gz_header FAR *gz_headerp; /* basic functions */ -ZEXTERN const char * ZEXPORT zlibVersion OF((void)); +ZEXTERN const char * ZEXPORT zlibVersion(void); /* The application can compare zlibVersion and ZLIB_VERSION for consistency. If the first character differs, the library code actually used is not compatible with the zlib.h header file used by the application. This check @@ -225,12 +225,12 @@ ZEXTERN const char * ZEXPORT zlibVersion OF((void)); */ /* -ZEXTERN int ZEXPORT deflateInit OF((z_streamp strm, int level)); +ZEXTERN int ZEXPORT deflateInit(z_streamp strm, int level); Initializes the internal stream state for compression. The fields zalloc, zfree and opaque must be initialized before by the caller. If zalloc and zfree are set to Z_NULL, deflateInit updates them to use default - allocation functions. + allocation functions. total_in, total_out, adler, and msg are initialized. The compression level must be Z_DEFAULT_COMPRESSION, or between 0 and 9: 1 gives best speed, 9 gives best compression, 0 gives no compression at all @@ -247,7 +247,7 @@ ZEXTERN int ZEXPORT deflateInit OF((z_streamp strm, int level)); */ -ZEXTERN int ZEXPORT deflate OF((z_streamp strm, int flush)); +ZEXTERN int ZEXPORT deflate(z_streamp strm, int flush); /* deflate compresses as much data as possible, and stops when the input buffer becomes empty or the output buffer becomes full. It may introduce @@ -276,7 +276,7 @@ ZEXTERN int ZEXPORT deflate OF((z_streamp strm, int flush)); == 0), or after each call of deflate(). If deflate returns Z_OK and with zero avail_out, it must be called again after making room in the output buffer because there might be more output pending. See deflatePending(), - which can be used if desired to determine whether or not there is more ouput + which can be used if desired to determine whether or not there is more output in that case. Normally the parameter flush is set to Z_NO_FLUSH, which allows deflate to @@ -320,8 +320,8 @@ ZEXTERN int ZEXPORT deflate OF((z_streamp strm, int flush)); with the same value of the flush parameter and more output space (updated avail_out), until the flush is complete (deflate returns with non-zero avail_out). In the case of a Z_FULL_FLUSH or Z_SYNC_FLUSH, make sure that - avail_out is greater than six to avoid repeated flush markers due to - avail_out == 0 on return. + avail_out is greater than six when the flush marker begins, in order to avoid + repeated flush markers upon calling deflate() again when avail_out == 0. If the parameter flush is set to Z_FINISH, pending input is processed, pending output is flushed and deflate returns with Z_STREAM_END if there was @@ -360,7 +360,7 @@ ZEXTERN int ZEXPORT deflate OF((z_streamp strm, int flush)); */ -ZEXTERN int ZEXPORT deflateEnd OF((z_streamp strm)); +ZEXTERN int ZEXPORT deflateEnd(z_streamp strm); /* All dynamically allocated data structures for this stream are freed. This function discards any unprocessed input and does not flush any pending @@ -375,7 +375,7 @@ ZEXTERN int ZEXPORT deflateEnd OF((z_streamp strm)); /* -ZEXTERN int ZEXPORT inflateInit OF((z_streamp strm)); +ZEXTERN int ZEXPORT inflateInit(z_streamp strm); Initializes the internal stream state for decompression. The fields next_in, avail_in, zalloc, zfree and opaque must be initialized before by @@ -383,7 +383,8 @@ ZEXTERN int ZEXPORT inflateInit OF((z_streamp strm)); read or consumed. The allocation of a sliding window will be deferred to the first call of inflate (if the decompression does not complete on the first call). If zalloc and zfree are set to Z_NULL, inflateInit updates - them to use default allocation functions. + them to use default allocation functions. total_in, total_out, adler, and + msg are initialized. inflateInit returns Z_OK if success, Z_MEM_ERROR if there was not enough memory, Z_VERSION_ERROR if the zlib library version is incompatible with the @@ -397,7 +398,7 @@ ZEXTERN int ZEXPORT inflateInit OF((z_streamp strm)); */ -ZEXTERN int ZEXPORT inflate OF((z_streamp strm, int flush)); +ZEXTERN int ZEXPORT inflate(z_streamp strm, int flush); /* inflate decompresses as much data as possible, and stops when the input buffer becomes empty or the output buffer becomes full. It may introduce @@ -517,7 +518,7 @@ ZEXTERN int ZEXPORT inflate OF((z_streamp strm, int flush)); */ -ZEXTERN int ZEXPORT inflateEnd OF((z_streamp strm)); +ZEXTERN int ZEXPORT inflateEnd(z_streamp strm); /* All dynamically allocated data structures for this stream are freed. This function discards any unprocessed input and does not flush any pending @@ -535,16 +536,15 @@ ZEXTERN int ZEXPORT inflateEnd OF((z_streamp strm)); */ /* -ZEXTERN int ZEXPORT deflateInit2 OF((z_streamp strm, - int level, - int method, - int windowBits, - int memLevel, - int strategy)); +ZEXTERN int ZEXPORT deflateInit2(z_streamp strm, + int level, + int method, + int windowBits, + int memLevel, + int strategy); This is another version of deflateInit with more compression options. The - fields next_in, zalloc, zfree and opaque must be initialized before by the - caller. + fields zalloc, zfree and opaque must be initialized before by the caller. The method parameter is the compression method. It must be Z_DEFLATED in this version of the library. @@ -608,9 +608,9 @@ ZEXTERN int ZEXPORT deflateInit2 OF((z_streamp strm, compression: this will be done by deflate(). */ -ZEXTERN int ZEXPORT deflateSetDictionary OF((z_streamp strm, - const Bytef *dictionary, - uInt dictLength)); +ZEXTERN int ZEXPORT deflateSetDictionary(z_streamp strm, + const Bytef *dictionary, + uInt dictLength); /* Initializes the compression dictionary from the given byte sequence without producing any compressed output. When using the zlib format, this @@ -652,16 +652,16 @@ ZEXTERN int ZEXPORT deflateSetDictionary OF((z_streamp strm, not perform any compression: this will be done by deflate(). */ -ZEXTERN int ZEXPORT deflateGetDictionary OF((z_streamp strm, - Bytef *dictionary, - uInt *dictLength)); +ZEXTERN int ZEXPORT deflateGetDictionary(z_streamp strm, + Bytef *dictionary, + uInt *dictLength); /* Returns the sliding dictionary being maintained by deflate. dictLength is set to the number of bytes in the dictionary, and that many bytes are copied to dictionary. dictionary must have enough space, where 32768 bytes is always enough. If deflateGetDictionary() is called with dictionary equal to Z_NULL, then only the dictionary length is returned, and nothing is copied. - Similary, if dictLength is Z_NULL, then it is not set. + Similarly, if dictLength is Z_NULL, then it is not set. deflateGetDictionary() may return a length less than the window size, even when more than the window size in input has been provided. It may return up @@ -674,8 +674,8 @@ ZEXTERN int ZEXPORT deflateGetDictionary OF((z_streamp strm, stream state is inconsistent. */ -ZEXTERN int ZEXPORT deflateCopy OF((z_streamp dest, - z_streamp source)); +ZEXTERN int ZEXPORT deflateCopy(z_streamp dest, + z_streamp source); /* Sets the destination stream as a complete copy of the source stream. @@ -692,31 +692,32 @@ ZEXTERN int ZEXPORT deflateCopy OF((z_streamp dest, destination. */ -ZEXTERN int ZEXPORT deflateReset OF((z_streamp strm)); +ZEXTERN int ZEXPORT deflateReset(z_streamp strm); /* This function is equivalent to deflateEnd followed by deflateInit, but does not free and reallocate the internal compression state. The stream will leave the compression level and any other attributes that may have been - set unchanged. + set unchanged. total_in, total_out, adler, and msg are initialized. deflateReset returns Z_OK if success, or Z_STREAM_ERROR if the source stream state was inconsistent (such as zalloc or state being Z_NULL). */ -ZEXTERN int ZEXPORT deflateParams OF((z_streamp strm, - int level, - int strategy)); +ZEXTERN int ZEXPORT deflateParams(z_streamp strm, + int level, + int strategy); /* Dynamically update the compression level and compression strategy. The interpretation of level and strategy is as in deflateInit2(). This can be used to switch between compression and straight copy of the input data, or to switch to a different kind of input data requiring a different strategy. If the compression approach (which is a function of the level) or the - strategy is changed, and if any input has been consumed in a previous - deflate() call, then the input available so far is compressed with the old - level and strategy using deflate(strm, Z_BLOCK). There are three approaches - for the compression levels 0, 1..3, and 4..9 respectively. The new level - and strategy will take effect at the next call of deflate(). + strategy is changed, and if there have been any deflate() calls since the + state was initialized or reset, then the input available so far is + compressed with the old level and strategy using deflate(strm, Z_BLOCK). + There are three approaches for the compression levels 0, 1..3, and 4..9 + respectively. The new level and strategy will take effect at the next call + of deflate(). If a deflate(strm, Z_BLOCK) is performed by deflateParams(), and it does not have enough output space to complete, then the parameter change will not @@ -729,7 +730,7 @@ ZEXTERN int ZEXPORT deflateParams OF((z_streamp strm, Then no more input data should be provided before the deflateParams() call. If this is done, the old level and strategy will be applied to the data compressed before deflateParams(), and the new level and strategy will be - applied to the the data compressed after deflateParams(). + applied to the data compressed after deflateParams(). deflateParams returns Z_OK on success, Z_STREAM_ERROR if the source stream state was inconsistent or if a parameter was invalid, or Z_BUF_ERROR if @@ -740,11 +741,11 @@ ZEXTERN int ZEXPORT deflateParams OF((z_streamp strm, retried with more output space. */ -ZEXTERN int ZEXPORT deflateTune OF((z_streamp strm, - int good_length, - int max_lazy, - int nice_length, - int max_chain)); +ZEXTERN int ZEXPORT deflateTune(z_streamp strm, + int good_length, + int max_lazy, + int nice_length, + int max_chain); /* Fine tune deflate's internal compression parameters. This should only be used by someone who understands the algorithm used by zlib's deflate for @@ -757,8 +758,8 @@ ZEXTERN int ZEXPORT deflateTune OF((z_streamp strm, returns Z_OK on success, or Z_STREAM_ERROR for an invalid deflate stream. */ -ZEXTERN uLong ZEXPORT deflateBound OF((z_streamp strm, - uLong sourceLen)); +ZEXTERN uLong ZEXPORT deflateBound(z_streamp strm, + uLong sourceLen); /* deflateBound() returns an upper bound on the compressed size after deflation of sourceLen bytes. It must be called after deflateInit() or @@ -772,9 +773,9 @@ ZEXTERN uLong ZEXPORT deflateBound OF((z_streamp strm, than Z_FINISH or Z_NO_FLUSH are used. */ -ZEXTERN int ZEXPORT deflatePending OF((z_streamp strm, - unsigned *pending, - int *bits)); +ZEXTERN int ZEXPORT deflatePending(z_streamp strm, + unsigned *pending, + int *bits); /* deflatePending() returns the number of bytes and bits of output that have been generated, but not yet provided in the available output. The bytes not @@ -787,9 +788,9 @@ ZEXTERN int ZEXPORT deflatePending OF((z_streamp strm, stream state was inconsistent. */ -ZEXTERN int ZEXPORT deflatePrime OF((z_streamp strm, - int bits, - int value)); +ZEXTERN int ZEXPORT deflatePrime(z_streamp strm, + int bits, + int value); /* deflatePrime() inserts bits in the deflate output stream. The intent is that this function is used to start off the deflate output with the bits @@ -804,8 +805,8 @@ ZEXTERN int ZEXPORT deflatePrime OF((z_streamp strm, source stream state was inconsistent. */ -ZEXTERN int ZEXPORT deflateSetHeader OF((z_streamp strm, - gz_headerp head)); +ZEXTERN int ZEXPORT deflateSetHeader(z_streamp strm, + gz_headerp head); /* deflateSetHeader() provides gzip header information for when a gzip stream is requested by deflateInit2(). deflateSetHeader() may be called @@ -821,16 +822,17 @@ ZEXTERN int ZEXPORT deflateSetHeader OF((z_streamp strm, gzip file" and give up. If deflateSetHeader is not used, the default gzip header has text false, - the time set to zero, and os set to 255, with no extra, name, or comment - fields. The gzip header is returned to the default state by deflateReset(). + the time set to zero, and os set to the current operating system, with no + extra, name, or comment fields. The gzip header is returned to the default + state by deflateReset(). deflateSetHeader returns Z_OK if success, or Z_STREAM_ERROR if the source stream state was inconsistent. */ /* -ZEXTERN int ZEXPORT inflateInit2 OF((z_streamp strm, - int windowBits)); +ZEXTERN int ZEXPORT inflateInit2(z_streamp strm, + int windowBits); This is another version of inflateInit with an extra parameter. The fields next_in, avail_in, zalloc, zfree and opaque must be initialized @@ -865,9 +867,11 @@ ZEXTERN int ZEXPORT inflateInit2 OF((z_streamp strm, detection, or add 16 to decode only the gzip format (the zlib format will return a Z_DATA_ERROR). If a gzip stream is being decoded, strm->adler is a CRC-32 instead of an Adler-32. Unlike the gunzip utility and gzread() (see - below), inflate() will not automatically decode concatenated gzip streams. - inflate() will return Z_STREAM_END at the end of the gzip stream. The state - would need to be reset to continue decoding a subsequent gzip stream. + below), inflate() will *not* automatically decode concatenated gzip members. + inflate() will return Z_STREAM_END at the end of the gzip member. The state + would need to be reset to continue decoding a subsequent gzip member. This + *must* be done if there is more data after a gzip member, in order for the + decompression to be compliant with the gzip standard (RFC 1952). inflateInit2 returns Z_OK if success, Z_MEM_ERROR if there was not enough memory, Z_VERSION_ERROR if the zlib library version is incompatible with the @@ -881,9 +885,9 @@ ZEXTERN int ZEXPORT inflateInit2 OF((z_streamp strm, deferred until inflate() is called. */ -ZEXTERN int ZEXPORT inflateSetDictionary OF((z_streamp strm, - const Bytef *dictionary, - uInt dictLength)); +ZEXTERN int ZEXPORT inflateSetDictionary(z_streamp strm, + const Bytef *dictionary, + uInt dictLength); /* Initializes the decompression dictionary from the given uncompressed byte sequence. This function must be called immediately after a call of inflate, @@ -904,22 +908,22 @@ ZEXTERN int ZEXPORT inflateSetDictionary OF((z_streamp strm, inflate(). */ -ZEXTERN int ZEXPORT inflateGetDictionary OF((z_streamp strm, - Bytef *dictionary, - uInt *dictLength)); +ZEXTERN int ZEXPORT inflateGetDictionary(z_streamp strm, + Bytef *dictionary, + uInt *dictLength); /* Returns the sliding dictionary being maintained by inflate. dictLength is set to the number of bytes in the dictionary, and that many bytes are copied to dictionary. dictionary must have enough space, where 32768 bytes is always enough. If inflateGetDictionary() is called with dictionary equal to Z_NULL, then only the dictionary length is returned, and nothing is copied. - Similary, if dictLength is Z_NULL, then it is not set. + Similarly, if dictLength is Z_NULL, then it is not set. inflateGetDictionary returns Z_OK on success, or Z_STREAM_ERROR if the stream state is inconsistent. */ -ZEXTERN int ZEXPORT inflateSync OF((z_streamp strm)); +ZEXTERN int ZEXPORT inflateSync(z_streamp strm); /* Skips invalid compressed data until a possible full flush point (see above for the description of deflate with Z_FULL_FLUSH) can be found, or until all @@ -932,14 +936,14 @@ ZEXTERN int ZEXPORT inflateSync OF((z_streamp strm)); inflateSync returns Z_OK if a possible full flush point has been found, Z_BUF_ERROR if no more input was provided, Z_DATA_ERROR if no flush point has been found, or Z_STREAM_ERROR if the stream structure was inconsistent. - In the success case, the application may save the current current value of - total_in which indicates where valid compressed data was found. In the - error case, the application may repeatedly call inflateSync, providing more - input each time, until success or end of the input data. + In the success case, the application may save the current value of total_in + which indicates where valid compressed data was found. In the error case, + the application may repeatedly call inflateSync, providing more input each + time, until success or end of the input data. */ -ZEXTERN int ZEXPORT inflateCopy OF((z_streamp dest, - z_streamp source)); +ZEXTERN int ZEXPORT inflateCopy(z_streamp dest, + z_streamp source); /* Sets the destination stream as a complete copy of the source stream. @@ -954,18 +958,19 @@ ZEXTERN int ZEXPORT inflateCopy OF((z_streamp dest, destination. */ -ZEXTERN int ZEXPORT inflateReset OF((z_streamp strm)); +ZEXTERN int ZEXPORT inflateReset(z_streamp strm); /* This function is equivalent to inflateEnd followed by inflateInit, but does not free and reallocate the internal decompression state. The stream will keep attributes that may have been set by inflateInit2. + total_in, total_out, adler, and msg are initialized. inflateReset returns Z_OK if success, or Z_STREAM_ERROR if the source stream state was inconsistent (such as zalloc or state being Z_NULL). */ -ZEXTERN int ZEXPORT inflateReset2 OF((z_streamp strm, - int windowBits)); +ZEXTERN int ZEXPORT inflateReset2(z_streamp strm, + int windowBits); /* This function is the same as inflateReset, but it also permits changing the wrap and window size requests. The windowBits parameter is interpreted @@ -978,9 +983,9 @@ ZEXTERN int ZEXPORT inflateReset2 OF((z_streamp strm, the windowBits parameter is invalid. */ -ZEXTERN int ZEXPORT inflatePrime OF((z_streamp strm, - int bits, - int value)); +ZEXTERN int ZEXPORT inflatePrime(z_streamp strm, + int bits, + int value); /* This function inserts bits in the inflate input stream. The intent is that this function is used to start inflating at a bit position in the @@ -999,7 +1004,7 @@ ZEXTERN int ZEXPORT inflatePrime OF((z_streamp strm, stream state was inconsistent. */ -ZEXTERN long ZEXPORT inflateMark OF((z_streamp strm)); +ZEXTERN long ZEXPORT inflateMark(z_streamp strm); /* This function returns two values, one in the lower 16 bits of the return value, and the other in the remaining upper bits, obtained by shifting the @@ -1027,8 +1032,8 @@ ZEXTERN long ZEXPORT inflateMark OF((z_streamp strm)); source stream state was inconsistent. */ -ZEXTERN int ZEXPORT inflateGetHeader OF((z_streamp strm, - gz_headerp head)); +ZEXTERN int ZEXPORT inflateGetHeader(z_streamp strm, + gz_headerp head); /* inflateGetHeader() requests that gzip header information be stored in the provided gz_header structure. inflateGetHeader() may be called after @@ -1068,8 +1073,8 @@ ZEXTERN int ZEXPORT inflateGetHeader OF((z_streamp strm, */ /* -ZEXTERN int ZEXPORT inflateBackInit OF((z_streamp strm, int windowBits, - unsigned char FAR *window)); +ZEXTERN int ZEXPORT inflateBackInit(z_streamp strm, int windowBits, + unsigned char FAR *window); Initialize the internal stream state for decompression using inflateBack() calls. The fields zalloc, zfree and opaque in strm must be initialized @@ -1089,13 +1094,13 @@ ZEXTERN int ZEXPORT inflateBackInit OF((z_streamp strm, int windowBits, the version of the header file. */ -typedef unsigned (*in_func) OF((void FAR *, - z_const unsigned char FAR * FAR *)); -typedef int (*out_func) OF((void FAR *, unsigned char FAR *, unsigned)); +typedef unsigned (*in_func)(void FAR *, + z_const unsigned char FAR * FAR *); +typedef int (*out_func)(void FAR *, unsigned char FAR *, unsigned); -ZEXTERN int ZEXPORT inflateBack OF((z_streamp strm, - in_func in, void FAR *in_desc, - out_func out, void FAR *out_desc)); +ZEXTERN int ZEXPORT inflateBack(z_streamp strm, + in_func in, void FAR *in_desc, + out_func out, void FAR *out_desc); /* inflateBack() does a raw inflate with a single call using a call-back interface for input and output. This is potentially more efficient than @@ -1163,7 +1168,7 @@ ZEXTERN int ZEXPORT inflateBack OF((z_streamp strm, cannot return Z_OK. */ -ZEXTERN int ZEXPORT inflateBackEnd OF((z_streamp strm)); +ZEXTERN int ZEXPORT inflateBackEnd(z_streamp strm); /* All memory allocated by inflateBackInit() is freed. @@ -1171,7 +1176,7 @@ ZEXTERN int ZEXPORT inflateBackEnd OF((z_streamp strm)); state was inconsistent. */ -ZEXTERN uLong ZEXPORT zlibCompileFlags OF((void)); +ZEXTERN uLong ZEXPORT zlibCompileFlags(void); /* Return flags indicating compile-time options. Type sizes, two bits each, 00 = 16 bits, 01 = 32, 10 = 64, 11 = other: @@ -1224,8 +1229,8 @@ ZEXTERN uLong ZEXPORT zlibCompileFlags OF((void)); you need special options. */ -ZEXTERN int ZEXPORT compress OF((Bytef *dest, uLongf *destLen, - const Bytef *source, uLong sourceLen)); +ZEXTERN int ZEXPORT compress(Bytef *dest, uLongf *destLen, + const Bytef *source, uLong sourceLen); /* Compresses the source buffer into the destination buffer. sourceLen is the byte length of the source buffer. Upon entry, destLen is the total size @@ -1239,9 +1244,9 @@ ZEXTERN int ZEXPORT compress OF((Bytef *dest, uLongf *destLen, buffer. */ -ZEXTERN int ZEXPORT compress2 OF((Bytef *dest, uLongf *destLen, - const Bytef *source, uLong sourceLen, - int level)); +ZEXTERN int ZEXPORT compress2(Bytef *dest, uLongf *destLen, + const Bytef *source, uLong sourceLen, + int level); /* Compresses the source buffer into the destination buffer. The level parameter has the same meaning as in deflateInit. sourceLen is the byte @@ -1255,15 +1260,15 @@ ZEXTERN int ZEXPORT compress2 OF((Bytef *dest, uLongf *destLen, Z_STREAM_ERROR if the level parameter is invalid. */ -ZEXTERN uLong ZEXPORT compressBound OF((uLong sourceLen)); +ZEXTERN uLong ZEXPORT compressBound(uLong sourceLen); /* compressBound() returns an upper bound on the compressed size after compress() or compress2() on sourceLen bytes. It would be used before a compress() or compress2() call to allocate the destination buffer. */ -ZEXTERN int ZEXPORT uncompress OF((Bytef *dest, uLongf *destLen, - const Bytef *source, uLong sourceLen)); +ZEXTERN int ZEXPORT uncompress(Bytef *dest, uLongf *destLen, + const Bytef *source, uLong sourceLen); /* Decompresses the source buffer into the destination buffer. sourceLen is the byte length of the source buffer. Upon entry, destLen is the total size @@ -1280,8 +1285,8 @@ ZEXTERN int ZEXPORT uncompress OF((Bytef *dest, uLongf *destLen, buffer with the uncompressed data up to that point. */ -ZEXTERN int ZEXPORT uncompress2 OF((Bytef *dest, uLongf *destLen, - const Bytef *source, uLong *sourceLen)); +ZEXTERN int ZEXPORT uncompress2(Bytef *dest, uLongf *destLen, + const Bytef *source, uLong *sourceLen); /* Same as uncompress, except that sourceLen is a pointer, where the length of the source is *sourceLen. On return, *sourceLen is the number of @@ -1300,16 +1305,16 @@ ZEXTERN int ZEXPORT uncompress2 OF((Bytef *dest, uLongf *destLen, typedef struct gzFile_s *gzFile; /* semi-opaque gzip file descriptor */ /* -ZEXTERN gzFile ZEXPORT gzopen OF((const char *path, const char *mode)); +ZEXTERN gzFile ZEXPORT gzopen(const char *path, const char *mode); - Opens a gzip (.gz) file for reading or writing. The mode parameter is as - in fopen ("rb" or "wb") but can also include a compression level ("wb9") or - a strategy: 'f' for filtered data as in "wb6f", 'h' for Huffman-only - compression as in "wb1h", 'R' for run-length encoding as in "wb1R", or 'F' - for fixed code compression as in "wb9F". (See the description of - deflateInit2 for more information about the strategy parameter.) 'T' will - request transparent writing or appending with no compression and not using - the gzip format. + Open the gzip (.gz) file at path for reading and decompressing, or + compressing and writing. The mode parameter is as in fopen ("rb" or "wb") + but can also include a compression level ("wb9") or a strategy: 'f' for + filtered data as in "wb6f", 'h' for Huffman-only compression as in "wb1h", + 'R' for run-length encoding as in "wb1R", or 'F' for fixed code compression + as in "wb9F". (See the description of deflateInit2 for more information + about the strategy parameter.) 'T' will request transparent writing or + appending with no compression and not using the gzip format. "a" can be used instead of "w" to request that the gzip stream that will be written be appended to the file. "+" will result in an error, since @@ -1337,11 +1342,11 @@ ZEXTERN gzFile ZEXPORT gzopen OF((const char *path, const char *mode)); file could not be opened. */ -ZEXTERN gzFile ZEXPORT gzdopen OF((int fd, const char *mode)); +ZEXTERN gzFile ZEXPORT gzdopen(int fd, const char *mode); /* - gzdopen associates a gzFile with the file descriptor fd. File descriptors - are obtained from calls like open, dup, creat, pipe or fileno (if the file - has been previously opened with fopen). The mode parameter is as in gzopen. + Associate a gzFile with the file descriptor fd. File descriptors are + obtained from calls like open, dup, creat, pipe or fileno (if the file has + been previously opened with fopen). The mode parameter is as in gzopen. The next call of gzclose on the returned gzFile will also close the file descriptor fd, just like fclose(fdopen(fd, mode)) closes the file descriptor @@ -1360,15 +1365,15 @@ ZEXTERN gzFile ZEXPORT gzdopen OF((int fd, const char *mode)); will not detect if fd is invalid (unless fd is -1). */ -ZEXTERN int ZEXPORT gzbuffer OF((gzFile file, unsigned size)); +ZEXTERN int ZEXPORT gzbuffer(gzFile file, unsigned size); /* - Set the internal buffer size used by this library's functions. The - default buffer size is 8192 bytes. This function must be called after - gzopen() or gzdopen(), and before any other calls that read or write the - file. The buffer memory allocation is always deferred to the first read or - write. Three times that size in buffer space is allocated. A larger buffer - size of, for example, 64K or 128K bytes will noticeably increase the speed - of decompression (reading). + Set the internal buffer size used by this library's functions for file to + size. The default buffer size is 8192 bytes. This function must be called + after gzopen() or gzdopen(), and before any other calls that read or write + the file. The buffer memory allocation is always deferred to the first read + or write. Three times that size in buffer space is allocated. A larger + buffer size of, for example, 64K or 128K bytes will noticeably increase the + speed of decompression (reading). The new buffer size also affects the maximum length for gzprintf(). @@ -1376,20 +1381,20 @@ ZEXTERN int ZEXPORT gzbuffer OF((gzFile file, unsigned size)); too late. */ -ZEXTERN int ZEXPORT gzsetparams OF((gzFile file, int level, int strategy)); +ZEXTERN int ZEXPORT gzsetparams(gzFile file, int level, int strategy); /* - Dynamically update the compression level or strategy. See the description - of deflateInit2 for the meaning of these parameters. Previously provided - data is flushed before the parameter change. + Dynamically update the compression level and strategy for file. See the + description of deflateInit2 for the meaning of these parameters. Previously + provided data is flushed before applying the parameter changes. gzsetparams returns Z_OK if success, Z_STREAM_ERROR if the file was not opened for writing, Z_ERRNO if there is an error writing the flushed data, or Z_MEM_ERROR if there is a memory allocation error. */ -ZEXTERN int ZEXPORT gzread OF((gzFile file, voidp buf, unsigned len)); +ZEXTERN int ZEXPORT gzread(gzFile file, voidp buf, unsigned len); /* - Reads the given number of uncompressed bytes from the compressed file. If + Read and decompress up to len uncompressed bytes from file into buf. If the input file is not in gzip format, gzread copies the given number of bytes into the buffer directly from the file. @@ -1417,14 +1422,14 @@ ZEXTERN int ZEXPORT gzread OF((gzFile file, voidp buf, unsigned len)); Z_STREAM_ERROR. */ -ZEXTERN z_size_t ZEXPORT gzfread OF((voidp buf, z_size_t size, z_size_t nitems, - gzFile file)); +ZEXTERN z_size_t ZEXPORT gzfread(voidp buf, z_size_t size, z_size_t nitems, + gzFile file); /* - Read up to nitems items of size size from file to buf, otherwise operating - as gzread() does. This duplicates the interface of stdio's fread(), with - size_t request and return types. If the library defines size_t, then - z_size_t is identical to size_t. If not, then z_size_t is an unsigned - integer type that can contain a pointer. + Read and decompress up to nitems items of size size from file into buf, + otherwise operating as gzread() does. This duplicates the interface of + stdio's fread(), with size_t request and return types. If the library + defines size_t, then z_size_t is identical to size_t. If not, then z_size_t + is an unsigned integer type that can contain a pointer. gzfread() returns the number of full items read of size size, or zero if the end of the file was reached and a full item could not be read, or if @@ -1435,26 +1440,24 @@ ZEXTERN z_size_t ZEXPORT gzfread OF((voidp buf, z_size_t size, z_size_t nitems, In the event that the end of file is reached and only a partial item is available at the end, i.e. the remaining uncompressed data length is not a - multiple of size, then the final partial item is nevetheless read into buf + multiple of size, then the final partial item is nevertheless read into buf and the end-of-file flag is set. The length of the partial item read is not provided, but could be inferred from the result of gztell(). This behavior is the same as the behavior of fread() implementations in common libraries, but it prevents the direct use of gzfread() to read a concurrently written - file, reseting and retrying on end-of-file, when size is not 1. + file, resetting and retrying on end-of-file, when size is not 1. */ -ZEXTERN int ZEXPORT gzwrite OF((gzFile file, - voidpc buf, unsigned len)); +ZEXTERN int ZEXPORT gzwrite(gzFile file, voidpc buf, unsigned len); /* - Writes the given number of uncompressed bytes into the compressed file. - gzwrite returns the number of uncompressed bytes written or 0 in case of - error. + Compress and write the len uncompressed bytes at buf to file. gzwrite + returns the number of uncompressed bytes written or 0 in case of error. */ -ZEXTERN z_size_t ZEXPORT gzfwrite OF((voidpc buf, z_size_t size, - z_size_t nitems, gzFile file)); +ZEXTERN z_size_t ZEXPORT gzfwrite(voidpc buf, z_size_t size, + z_size_t nitems, gzFile file); /* - gzfwrite() writes nitems items of size size from buf to file, duplicating + Compress and write nitems items of size size from buf to file, duplicating the interface of stdio's fwrite(), with size_t request and return types. If the library defines size_t, then z_size_t is identical to size_t. If not, then z_size_t is an unsigned integer type that can contain a pointer. @@ -1465,61 +1468,62 @@ ZEXTERN z_size_t ZEXPORT gzfwrite OF((voidpc buf, z_size_t size, is returned, and the error state is set to Z_STREAM_ERROR. */ -ZEXTERN int ZEXPORTVA gzprintf Z_ARG((gzFile file, const char *format, ...)); +ZEXTERN int ZEXPORTVA gzprintf(gzFile file, const char *format, ...); /* - Converts, formats, and writes the arguments to the compressed file under - control of the format string, as in fprintf. gzprintf returns the number of + Convert, format, compress, and write the arguments (...) to file under + control of the string format, as in fprintf. gzprintf returns the number of uncompressed bytes actually written, or a negative zlib error code in case of error. The number of uncompressed bytes written is limited to 8191, or one less than the buffer size given to gzbuffer(). The caller should assure that this limit is not exceeded. If it is exceeded, then gzprintf() will return an error (0) with nothing written. In this case, there may also be a buffer overflow with unpredictable consequences, which is possible only if - zlib was compiled with the insecure functions sprintf() or vsprintf() + zlib was compiled with the insecure functions sprintf() or vsprintf(), because the secure snprintf() or vsnprintf() functions were not available. This can be determined using zlibCompileFlags(). */ -ZEXTERN int ZEXPORT gzputs OF((gzFile file, const char *s)); +ZEXTERN int ZEXPORT gzputs(gzFile file, const char *s); /* - Writes the given null-terminated string to the compressed file, excluding + Compress and write the given null-terminated string s to file, excluding the terminating null character. gzputs returns the number of characters written, or -1 in case of error. */ -ZEXTERN char * ZEXPORT gzgets OF((gzFile file, char *buf, int len)); +ZEXTERN char * ZEXPORT gzgets(gzFile file, char *buf, int len); /* - Reads bytes from the compressed file until len-1 characters are read, or a - newline character is read and transferred to buf, or an end-of-file - condition is encountered. If any characters are read or if len == 1, the - string is terminated with a null character. If no characters are read due - to an end-of-file or len < 1, then the buffer is left untouched. + Read and decompress bytes from file into buf, until len-1 characters are + read, or until a newline character is read and transferred to buf, or an + end-of-file condition is encountered. If any characters are read or if len + is one, the string is terminated with a null character. If no characters + are read due to an end-of-file or len is less than one, then the buffer is + left untouched. gzgets returns buf which is a null-terminated string, or it returns NULL for end-of-file or in case of error. If there was an error, the contents at buf are indeterminate. */ -ZEXTERN int ZEXPORT gzputc OF((gzFile file, int c)); +ZEXTERN int ZEXPORT gzputc(gzFile file, int c); /* - Writes c, converted to an unsigned char, into the compressed file. gzputc + Compress and write c, converted to an unsigned char, into file. gzputc returns the value that was written, or -1 in case of error. */ -ZEXTERN int ZEXPORT gzgetc OF((gzFile file)); +ZEXTERN int ZEXPORT gzgetc(gzFile file); /* - Reads one byte from the compressed file. gzgetc returns this byte or -1 + Read and decompress one byte from file. gzgetc returns this byte or -1 in case of end of file or error. This is implemented as a macro for speed. As such, it does not do all of the checking the other functions do. I.e. it does not check to see if file is NULL, nor whether the structure file points to has been clobbered or not. */ -ZEXTERN int ZEXPORT gzungetc OF((int c, gzFile file)); +ZEXTERN int ZEXPORT gzungetc(int c, gzFile file); /* - Push one character back onto the stream to be read as the first character - on the next read. At least one character of push-back is allowed. + Push c back onto the stream for file to be read as the first character on + the next read. At least one character of push-back is always allowed. gzungetc() returns the character pushed, or -1 on failure. gzungetc() will fail if c is -1, and may fail if a character has been pushed but not read yet. If gzungetc is used immediately after gzopen or gzdopen, at least the @@ -1528,11 +1532,11 @@ ZEXTERN int ZEXPORT gzungetc OF((int c, gzFile file)); gzseek() or gzrewind(). */ -ZEXTERN int ZEXPORT gzflush OF((gzFile file, int flush)); +ZEXTERN int ZEXPORT gzflush(gzFile file, int flush); /* - Flushes all pending output into the compressed file. The parameter flush - is as in the deflate() function. The return value is the zlib error number - (see function gzerror below). gzflush is only permitted when writing. + Flush all pending output to file. The parameter flush is as in the + deflate() function. The return value is the zlib error number (see function + gzerror below). gzflush is only permitted when writing. If the flush parameter is Z_FINISH, the remaining data is written and the gzip stream is completed in the output. If gzwrite() is called again, a new @@ -1544,11 +1548,11 @@ ZEXTERN int ZEXPORT gzflush OF((gzFile file, int flush)); */ /* -ZEXTERN z_off_t ZEXPORT gzseek OF((gzFile file, - z_off_t offset, int whence)); +ZEXTERN z_off_t ZEXPORT gzseek(gzFile file, + z_off_t offset, int whence); - Sets the starting position for the next gzread or gzwrite on the given - compressed file. The offset represents a number of bytes in the + Set the starting position to offset relative to whence for the next gzread + or gzwrite on file. The offset represents a number of bytes in the uncompressed data stream. The whence parameter is defined as in lseek(2); the value SEEK_END is not supported. @@ -1563,52 +1567,52 @@ ZEXTERN z_off_t ZEXPORT gzseek OF((gzFile file, would be before the current position. */ -ZEXTERN int ZEXPORT gzrewind OF((gzFile file)); +ZEXTERN int ZEXPORT gzrewind(gzFile file); /* - Rewinds the given file. This function is supported only for reading. + Rewind file. This function is supported only for reading. - gzrewind(file) is equivalent to (int)gzseek(file, 0L, SEEK_SET) + gzrewind(file) is equivalent to (int)gzseek(file, 0L, SEEK_SET). */ /* -ZEXTERN z_off_t ZEXPORT gztell OF((gzFile file)); +ZEXTERN z_off_t ZEXPORT gztell(gzFile file); - Returns the starting position for the next gzread or gzwrite on the given - compressed file. This position represents a number of bytes in the - uncompressed data stream, and is zero when starting, even if appending or - reading a gzip stream from the middle of a file using gzdopen(). + Return the starting position for the next gzread or gzwrite on file. + This position represents a number of bytes in the uncompressed data stream, + and is zero when starting, even if appending or reading a gzip stream from + the middle of a file using gzdopen(). gztell(file) is equivalent to gzseek(file, 0L, SEEK_CUR) */ /* -ZEXTERN z_off_t ZEXPORT gzoffset OF((gzFile file)); +ZEXTERN z_off_t ZEXPORT gzoffset(gzFile file); - Returns the current offset in the file being read or written. This offset - includes the count of bytes that precede the gzip stream, for example when - appending or when using gzdopen() for reading. When reading, the offset - does not include as yet unused buffered input. This information can be used - for a progress indicator. On error, gzoffset() returns -1. + Return the current compressed (actual) read or write offset of file. This + offset includes the count of bytes that precede the gzip stream, for example + when appending or when using gzdopen() for reading. When reading, the + offset does not include as yet unused buffered input. This information can + be used for a progress indicator. On error, gzoffset() returns -1. */ -ZEXTERN int ZEXPORT gzeof OF((gzFile file)); +ZEXTERN int ZEXPORT gzeof(gzFile file); /* - Returns true (1) if the end-of-file indicator has been set while reading, - false (0) otherwise. Note that the end-of-file indicator is set only if the - read tried to go past the end of the input, but came up short. Therefore, - just like feof(), gzeof() may return false even if there is no more data to - read, in the event that the last read request was for the exact number of - bytes remaining in the input file. This will happen if the input file size - is an exact multiple of the buffer size. + Return true (1) if the end-of-file indicator for file has been set while + reading, false (0) otherwise. Note that the end-of-file indicator is set + only if the read tried to go past the end of the input, but came up short. + Therefore, just like feof(), gzeof() may return false even if there is no + more data to read, in the event that the last read request was for the exact + number of bytes remaining in the input file. This will happen if the input + file size is an exact multiple of the buffer size. If gzeof() returns true, then the read functions will return no more data, unless the end-of-file indicator is reset by gzclearerr() and the input file has grown since the previous end of file was detected. */ -ZEXTERN int ZEXPORT gzdirect OF((gzFile file)); +ZEXTERN int ZEXPORT gzdirect(gzFile file); /* - Returns true (1) if file is being copied directly while reading, or false + Return true (1) if file is being copied directly while reading, or false (0) if file is a gzip stream being decompressed. If the input file is empty, gzdirect() will return true, since the input @@ -1627,10 +1631,10 @@ ZEXTERN int ZEXPORT gzdirect OF((gzFile file)); gzip file reading and decompression, which may not be desired.) */ -ZEXTERN int ZEXPORT gzclose OF((gzFile file)); +ZEXTERN int ZEXPORT gzclose(gzFile file); /* - Flushes all pending output if necessary, closes the compressed file and - deallocates the (de)compression state. Note that once file is closed, you + Flush all pending output for file, if necessary, close file and + deallocate the (de)compression state. Note that once file is closed, you cannot call gzerror with file, since its structures have been deallocated. gzclose must not be called more than once on the same file, just as free must not be called more than once on the same allocation. @@ -1640,8 +1644,8 @@ ZEXTERN int ZEXPORT gzclose OF((gzFile file)); last read ended in the middle of a gzip stream, or Z_OK on success. */ -ZEXTERN int ZEXPORT gzclose_r OF((gzFile file)); -ZEXTERN int ZEXPORT gzclose_w OF((gzFile file)); +ZEXTERN int ZEXPORT gzclose_r(gzFile file); +ZEXTERN int ZEXPORT gzclose_w(gzFile file); /* Same as gzclose(), but gzclose_r() is only for use when reading, and gzclose_w() is only for use when writing or appending. The advantage to @@ -1652,12 +1656,12 @@ ZEXTERN int ZEXPORT gzclose_w OF((gzFile file)); zlib library. */ -ZEXTERN const char * ZEXPORT gzerror OF((gzFile file, int *errnum)); +ZEXTERN const char * ZEXPORT gzerror(gzFile file, int *errnum); /* - Returns the error message for the last error which occurred on the given - compressed file. errnum is set to zlib error number. If an error occurred - in the file system and not in the compression library, errnum is set to - Z_ERRNO and the application may consult errno to get the exact error code. + Return the error message for the last error which occurred on file. + errnum is set to zlib error number. If an error occurred in the file system + and not in the compression library, errnum is set to Z_ERRNO and the + application may consult errno to get the exact error code. The application must not modify the returned string. Future calls to this function may invalidate the previously returned string. If file is @@ -1668,9 +1672,9 @@ ZEXTERN const char * ZEXPORT gzerror OF((gzFile file, int *errnum)); functions above that do not distinguish those cases in their return values. */ -ZEXTERN void ZEXPORT gzclearerr OF((gzFile file)); +ZEXTERN void ZEXPORT gzclearerr(gzFile file); /* - Clears the error and end-of-file flags for file. This is analogous to the + Clear the error and end-of-file flags for file. This is analogous to the clearerr() function in stdio. This is useful for continuing to read a gzip file that is being written concurrently. */ @@ -1685,11 +1689,12 @@ ZEXTERN void ZEXPORT gzclearerr OF((gzFile file)); library. */ -ZEXTERN uLong ZEXPORT adler32 OF((uLong adler, const Bytef *buf, uInt len)); +ZEXTERN uLong ZEXPORT adler32(uLong adler, const Bytef *buf, uInt len); /* Update a running Adler-32 checksum with the bytes buf[0..len-1] and - return the updated checksum. If buf is Z_NULL, this function returns the - required initial value for the checksum. + return the updated checksum. An Adler-32 value is in the range of a 32-bit + unsigned integer. If buf is Z_NULL, this function returns the required + initial value for the checksum. An Adler-32 checksum is almost as reliable as a CRC-32 but can be computed much faster. @@ -1704,15 +1709,15 @@ ZEXTERN uLong ZEXPORT adler32 OF((uLong adler, const Bytef *buf, uInt len)); if (adler != original_adler) error(); */ -ZEXTERN uLong ZEXPORT adler32_z OF((uLong adler, const Bytef *buf, - z_size_t len)); +ZEXTERN uLong ZEXPORT adler32_z(uLong adler, const Bytef *buf, + z_size_t len); /* Same as adler32(), but with a size_t length. */ /* -ZEXTERN uLong ZEXPORT adler32_combine OF((uLong adler1, uLong adler2, - z_off_t len2)); +ZEXTERN uLong ZEXPORT adler32_combine(uLong adler1, uLong adler2, + z_off_t len2); Combine two Adler-32 checksums into one. For two sequences of bytes, seq1 and seq2 with lengths len1 and len2, Adler-32 checksums were calculated for @@ -1722,12 +1727,13 @@ ZEXTERN uLong ZEXPORT adler32_combine OF((uLong adler1, uLong adler2, negative, the result has no meaning or utility. */ -ZEXTERN uLong ZEXPORT crc32 OF((uLong crc, const Bytef *buf, uInt len)); +ZEXTERN uLong ZEXPORT crc32(uLong crc, const Bytef *buf, uInt len); /* Update a running CRC-32 with the bytes buf[0..len-1] and return the - updated CRC-32. If buf is Z_NULL, this function returns the required - initial value for the crc. Pre- and post-conditioning (one's complement) is - performed within this function so it shouldn't be done by the application. + updated CRC-32. A CRC-32 value is in the range of a 32-bit unsigned integer. + If buf is Z_NULL, this function returns the required initial value for the + crc. Pre- and post-conditioning (one's complement) is performed within this + function so it shouldn't be done by the application. Usage example: @@ -1739,20 +1745,34 @@ ZEXTERN uLong ZEXPORT crc32 OF((uLong crc, const Bytef *buf, uInt len)); if (crc != original_crc) error(); */ -ZEXTERN uLong ZEXPORT crc32_z OF((uLong adler, const Bytef *buf, - z_size_t len)); +ZEXTERN uLong ZEXPORT crc32_z(uLong crc, const Bytef *buf, + z_size_t len); /* Same as crc32(), but with a size_t length. */ /* -ZEXTERN uLong ZEXPORT crc32_combine OF((uLong crc1, uLong crc2, z_off_t len2)); +ZEXTERN uLong ZEXPORT crc32_combine(uLong crc1, uLong crc2, z_off_t len2); Combine two CRC-32 check values into one. For two sequences of bytes, seq1 and seq2 with lengths len1 and len2, CRC-32 check values were calculated for each, crc1 and crc2. crc32_combine() returns the CRC-32 check value of seq1 and seq2 concatenated, requiring only crc1, crc2, and - len2. + len2. len2 must be non-negative. +*/ + +/* +ZEXTERN uLong ZEXPORT crc32_combine_gen(z_off_t len2); + + Return the operator corresponding to length len2, to be used with + crc32_combine_op(). len2 must be non-negative. +*/ + +ZEXTERN uLong ZEXPORT crc32_combine_op(uLong crc1, uLong crc2, uLong op); +/* + Give the same result as crc32_combine(), using op in place of len2. op is + is generated from len2 by crc32_combine_gen(). This will be faster than + crc32_combine() if the generated op is used more than once. */ @@ -1761,20 +1781,20 @@ ZEXTERN uLong ZEXPORT crc32_combine OF((uLong crc1, uLong crc2, z_off_t len2)); /* deflateInit and inflateInit are macros to allow checking the zlib version * and the compiler's view of z_stream: */ -ZEXTERN int ZEXPORT deflateInit_ OF((z_streamp strm, int level, - const char *version, int stream_size)); -ZEXTERN int ZEXPORT inflateInit_ OF((z_streamp strm, - const char *version, int stream_size)); -ZEXTERN int ZEXPORT deflateInit2_ OF((z_streamp strm, int level, int method, - int windowBits, int memLevel, - int strategy, const char *version, - int stream_size)); -ZEXTERN int ZEXPORT inflateInit2_ OF((z_streamp strm, int windowBits, - const char *version, int stream_size)); -ZEXTERN int ZEXPORT inflateBackInit_ OF((z_streamp strm, int windowBits, - unsigned char FAR *window, - const char *version, - int stream_size)); +ZEXTERN int ZEXPORT deflateInit_(z_streamp strm, int level, + const char *version, int stream_size); +ZEXTERN int ZEXPORT inflateInit_(z_streamp strm, + const char *version, int stream_size); +ZEXTERN int ZEXPORT deflateInit2_(z_streamp strm, int level, int method, + int windowBits, int memLevel, + int strategy, const char *version, + int stream_size); +ZEXTERN int ZEXPORT inflateInit2_(z_streamp strm, int windowBits, + const char *version, int stream_size); +ZEXTERN int ZEXPORT inflateBackInit_(z_streamp strm, int windowBits, + unsigned char FAR *window, + const char *version, + int stream_size); #ifdef Z_PREFIX_SET # define z_deflateInit(strm, level) \ deflateInit_((strm), (level), ZLIB_VERSION, (int)sizeof(z_stream)) @@ -1819,7 +1839,7 @@ struct gzFile_s { unsigned char *next; z_off64_t pos; }; -ZEXTERN int ZEXPORT gzgetc_ OF((gzFile file)); /* backward compatibility */ +ZEXTERN int ZEXPORT gzgetc_(gzFile file); /* backward compatibility */ #ifdef Z_PREFIX_SET # undef z_gzgetc # define z_gzgetc(g) \ @@ -1836,12 +1856,13 @@ ZEXTERN int ZEXPORT gzgetc_ OF((gzFile file)); /* backward compatibility */ * without large file support, _LFS64_LARGEFILE must also be true */ #ifdef Z_LARGE64 - ZEXTERN gzFile ZEXPORT gzopen64 OF((const char *, const char *)); - ZEXTERN z_off64_t ZEXPORT gzseek64 OF((gzFile, z_off64_t, int)); - ZEXTERN z_off64_t ZEXPORT gztell64 OF((gzFile)); - ZEXTERN z_off64_t ZEXPORT gzoffset64 OF((gzFile)); - ZEXTERN uLong ZEXPORT adler32_combine64 OF((uLong, uLong, z_off64_t)); - ZEXTERN uLong ZEXPORT crc32_combine64 OF((uLong, uLong, z_off64_t)); + ZEXTERN gzFile ZEXPORT gzopen64(const char *, const char *); + ZEXTERN z_off64_t ZEXPORT gzseek64(gzFile, z_off64_t, int); + ZEXTERN z_off64_t ZEXPORT gztell64(gzFile); + ZEXTERN z_off64_t ZEXPORT gzoffset64(gzFile); + ZEXTERN uLong ZEXPORT adler32_combine64(uLong, uLong, z_off64_t); + ZEXTERN uLong ZEXPORT crc32_combine64(uLong, uLong, z_off64_t); + ZEXTERN uLong ZEXPORT crc32_combine_gen64(z_off64_t); #endif #if !defined(ZLIB_INTERNAL) && defined(Z_WANT64) @@ -1852,6 +1873,7 @@ ZEXTERN int ZEXPORT gzgetc_ OF((gzFile file)); /* backward compatibility */ # define z_gzoffset z_gzoffset64 # define z_adler32_combine z_adler32_combine64 # define z_crc32_combine z_crc32_combine64 +# define z_crc32_combine_gen z_crc32_combine_gen64 # else # define gzopen gzopen64 # define gzseek gzseek64 @@ -1859,49 +1881,53 @@ ZEXTERN int ZEXPORT gzgetc_ OF((gzFile file)); /* backward compatibility */ # define gzoffset gzoffset64 # define adler32_combine adler32_combine64 # define crc32_combine crc32_combine64 +# define crc32_combine_gen crc32_combine_gen64 # endif # ifndef Z_LARGE64 - ZEXTERN gzFile ZEXPORT gzopen64 OF((const char *, const char *)); - ZEXTERN z_off_t ZEXPORT gzseek64 OF((gzFile, z_off_t, int)); - ZEXTERN z_off_t ZEXPORT gztell64 OF((gzFile)); - ZEXTERN z_off_t ZEXPORT gzoffset64 OF((gzFile)); - ZEXTERN uLong ZEXPORT adler32_combine64 OF((uLong, uLong, z_off_t)); - ZEXTERN uLong ZEXPORT crc32_combine64 OF((uLong, uLong, z_off_t)); + ZEXTERN gzFile ZEXPORT gzopen64(const char *, const char *); + ZEXTERN z_off_t ZEXPORT gzseek64(gzFile, z_off_t, int); + ZEXTERN z_off_t ZEXPORT gztell64(gzFile); + ZEXTERN z_off_t ZEXPORT gzoffset64(gzFile); + ZEXTERN uLong ZEXPORT adler32_combine64(uLong, uLong, z_off_t); + ZEXTERN uLong ZEXPORT crc32_combine64(uLong, uLong, z_off_t); + ZEXTERN uLong ZEXPORT crc32_combine_gen64(z_off_t); # endif #else - ZEXTERN gzFile ZEXPORT gzopen OF((const char *, const char *)); - ZEXTERN z_off_t ZEXPORT gzseek OF((gzFile, z_off_t, int)); - ZEXTERN z_off_t ZEXPORT gztell OF((gzFile)); - ZEXTERN z_off_t ZEXPORT gzoffset OF((gzFile)); - ZEXTERN uLong ZEXPORT adler32_combine OF((uLong, uLong, z_off_t)); - ZEXTERN uLong ZEXPORT crc32_combine OF((uLong, uLong, z_off_t)); + ZEXTERN gzFile ZEXPORT gzopen(const char *, const char *); + ZEXTERN z_off_t ZEXPORT gzseek(gzFile, z_off_t, int); + ZEXTERN z_off_t ZEXPORT gztell(gzFile); + ZEXTERN z_off_t ZEXPORT gzoffset(gzFile); + ZEXTERN uLong ZEXPORT adler32_combine(uLong, uLong, z_off_t); + ZEXTERN uLong ZEXPORT crc32_combine(uLong, uLong, z_off_t); + ZEXTERN uLong ZEXPORT crc32_combine_gen(z_off_t); #endif #else /* Z_SOLO */ - ZEXTERN uLong ZEXPORT adler32_combine OF((uLong, uLong, z_off_t)); - ZEXTERN uLong ZEXPORT crc32_combine OF((uLong, uLong, z_off_t)); + ZEXTERN uLong ZEXPORT adler32_combine(uLong, uLong, z_off_t); + ZEXTERN uLong ZEXPORT crc32_combine(uLong, uLong, z_off_t); + ZEXTERN uLong ZEXPORT crc32_combine_gen(z_off_t); #endif /* !Z_SOLO */ /* undocumented functions */ -ZEXTERN const char * ZEXPORT zError OF((int)); -ZEXTERN int ZEXPORT inflateSyncPoint OF((z_streamp)); -ZEXTERN const z_crc_t FAR * ZEXPORT get_crc_table OF((void)); -ZEXTERN int ZEXPORT inflateUndermine OF((z_streamp, int)); -ZEXTERN int ZEXPORT inflateValidate OF((z_streamp, int)); -ZEXTERN unsigned long ZEXPORT inflateCodesUsed OF ((z_streamp)); -ZEXTERN int ZEXPORT inflateResetKeep OF((z_streamp)); -ZEXTERN int ZEXPORT deflateResetKeep OF((z_streamp)); -#if (defined(_WIN32) || defined(__CYGWIN__)) && !defined(Z_SOLO) -ZEXTERN gzFile ZEXPORT gzopen_w OF((const wchar_t *path, - const char *mode)); +ZEXTERN const char * ZEXPORT zError(int); +ZEXTERN int ZEXPORT inflateSyncPoint(z_streamp); +ZEXTERN const z_crc_t FAR * ZEXPORT get_crc_table(void); +ZEXTERN int ZEXPORT inflateUndermine(z_streamp, int); +ZEXTERN int ZEXPORT inflateValidate(z_streamp, int); +ZEXTERN unsigned long ZEXPORT inflateCodesUsed(z_streamp); +ZEXTERN int ZEXPORT inflateResetKeep(z_streamp); +ZEXTERN int ZEXPORT deflateResetKeep(z_streamp); +#if defined(_WIN32) && !defined(Z_SOLO) +ZEXTERN gzFile ZEXPORT gzopen_w(const wchar_t *path, + const char *mode); #endif #if defined(STDC) || defined(Z_HAVE_STDARG_H) # ifndef Z_SOLO -ZEXTERN int ZEXPORTVA gzvprintf Z_ARG((gzFile file, - const char *format, - va_list va)); +ZEXTERN int ZEXPORTVA gzvprintf(gzFile file, + const char *format, + va_list va); # endif #endif diff --git a/common/zlib/zutil.c b/common/zlib/zutil.c old mode 100755 new mode 100644 index a76c6b0..b1c5d2d --- a/common/zlib/zutil.c +++ b/common/zlib/zutil.c @@ -24,13 +24,11 @@ z_const char * const z_errmsg[10] = { }; -const char * ZEXPORT zlibVersion() -{ +const char * ZEXPORT zlibVersion(void) { return ZLIB_VERSION; } -uLong ZEXPORT zlibCompileFlags() -{ +uLong ZEXPORT zlibCompileFlags(void) { uLong flags; flags = 0; @@ -61,9 +59,11 @@ uLong ZEXPORT zlibCompileFlags() #ifdef ZLIB_DEBUG flags += 1 << 8; #endif + /* #if defined(ASMV) || defined(ASMINF) flags += 1 << 9; #endif + */ #ifdef ZLIB_WINAPI flags += 1 << 10; #endif @@ -119,9 +119,7 @@ uLong ZEXPORT zlibCompileFlags() # endif int ZLIB_INTERNAL z_verbose = verbose; -void ZLIB_INTERNAL z_error (m) - char *m; -{ +void ZLIB_INTERNAL z_error(char *m) { fprintf(stderr, "%s\n", m); exit(1); } @@ -130,14 +128,12 @@ void ZLIB_INTERNAL z_error (m) /* exported to allow conversion of error code to string for compress() and * uncompress() */ -const char * ZEXPORT zError(err) - int err; -{ +const char * ZEXPORT zError(int err) { return ERR_MSG(err); } -#if defined(_WIN32_WCE) - /* The Microsoft C Run-Time Library for Windows CE doesn't have +#if defined(_WIN32_WCE) && _WIN32_WCE < 0x800 + /* The older Microsoft C Run-Time Library for Windows CE doesn't have * errno. We define it as a global variable to simplify porting. * Its value is always 0 and should not be used. */ @@ -146,22 +142,14 @@ const char * ZEXPORT zError(err) #ifndef HAVE_MEMCPY -void ZLIB_INTERNAL zmemcpy(dest, source, len) - Bytef* dest; - const Bytef* source; - uInt len; -{ +void ZLIB_INTERNAL zmemcpy(Bytef* dest, const Bytef* source, uInt len) { if (len == 0) return; do { *dest++ = *source++; /* ??? to be unrolled */ } while (--len != 0); } -int ZLIB_INTERNAL zmemcmp(s1, s2, len) - const Bytef* s1; - const Bytef* s2; - uInt len; -{ +int ZLIB_INTERNAL zmemcmp(const Bytef* s1, const Bytef* s2, uInt len) { uInt j; for (j = 0; j < len; j++) { @@ -170,10 +158,7 @@ int ZLIB_INTERNAL zmemcmp(s1, s2, len) return 0; } -void ZLIB_INTERNAL zmemzero(dest, len) - Bytef* dest; - uInt len; -{ +void ZLIB_INTERNAL zmemzero(Bytef* dest, uInt len) { if (len == 0) return; do { *dest++ = 0; /* ??? to be unrolled */ @@ -214,8 +199,7 @@ local ptr_table table[MAX_PTR]; * a protected system like OS/2. Use Microsoft C instead. */ -voidpf ZLIB_INTERNAL zcalloc (voidpf opaque, unsigned items, unsigned size) -{ +voidpf ZLIB_INTERNAL zcalloc(voidpf opaque, unsigned items, unsigned size) { voidpf buf; ulg bsize = (ulg)items*size; @@ -240,8 +224,7 @@ voidpf ZLIB_INTERNAL zcalloc (voidpf opaque, unsigned items, unsigned size) return buf; } -void ZLIB_INTERNAL zcfree (voidpf opaque, voidpf ptr) -{ +void ZLIB_INTERNAL zcfree(voidpf opaque, voidpf ptr) { int n; (void)opaque; @@ -277,14 +260,12 @@ void ZLIB_INTERNAL zcfree (voidpf opaque, voidpf ptr) # define _hfree hfree #endif -voidpf ZLIB_INTERNAL zcalloc (voidpf opaque, uInt items, uInt size) -{ +voidpf ZLIB_INTERNAL zcalloc(voidpf opaque, uInt items, uInt size) { (void)opaque; return _halloc((long)items, size); } -void ZLIB_INTERNAL zcfree (voidpf opaque, voidpf ptr) -{ +void ZLIB_INTERNAL zcfree(voidpf opaque, voidpf ptr) { (void)opaque; _hfree(ptr); } @@ -297,25 +278,18 @@ void ZLIB_INTERNAL zcfree (voidpf opaque, voidpf ptr) #ifndef MY_ZCALLOC /* Any system without a special alloc function */ #ifndef STDC -extern voidp malloc OF((uInt size)); -extern voidp calloc OF((uInt items, uInt size)); -extern void free OF((voidpf ptr)); +extern voidp malloc(uInt size); +extern voidp calloc(uInt items, uInt size); +extern void free(voidpf ptr); #endif -voidpf ZLIB_INTERNAL zcalloc (opaque, items, size) - voidpf opaque; - unsigned items; - unsigned size; -{ +voidpf ZLIB_INTERNAL zcalloc(voidpf opaque, unsigned items, unsigned size) { (void)opaque; return sizeof(uInt) > 2 ? (voidpf)malloc(items * size) : (voidpf)calloc(items, size); } -void ZLIB_INTERNAL zcfree (opaque, ptr) - voidpf opaque; - voidpf ptr; -{ +void ZLIB_INTERNAL zcfree(voidpf opaque, voidpf ptr) { (void)opaque; free(ptr); } diff --git a/common/zlib/zutil.h b/common/zlib/zutil.h old mode 100755 new mode 100644 index b079ea6..48dd7fe --- a/common/zlib/zutil.h +++ b/common/zlib/zutil.h @@ -1,5 +1,5 @@ /* zutil.h -- internal interface and configuration of the compression library - * Copyright (C) 1995-2016 Jean-loup Gailly, Mark Adler + * Copyright (C) 1995-2024 Jean-loup Gailly, Mark Adler * For conditions of distribution and use, see copyright notice in zlib.h */ @@ -29,10 +29,6 @@ # include #endif -#ifdef Z_SOLO - typedef long ptrdiff_t; /* guess -- will be caught if guess is wrong */ -#endif - #ifndef local # define local static #endif @@ -46,10 +42,21 @@ typedef unsigned short ush; typedef ush FAR ushf; typedef unsigned long ulg; +#if !defined(Z_U8) && !defined(Z_SOLO) && defined(STDC) +# include +# if (ULONG_MAX == 0xffffffffffffffff) +# define Z_U8 unsigned long +# elif (ULLONG_MAX == 0xffffffffffffffff) +# define Z_U8 unsigned long long +# elif (UINT_MAX == 0xffffffffffffffff) +# define Z_U8 unsigned +# endif +#endif + extern z_const char * const z_errmsg[10]; /* indexed by 2-zlib_error */ /* (size given to avoid silly warnings with Visual C++) */ -#define ERR_MSG(err) z_errmsg[Z_NEED_DICT-(err)] +#define ERR_MSG(err) z_errmsg[(err) < -6 || (err) > 2 ? 9 : 2 - (err)] #define ERR_RETURN(strm,err) \ return (strm->msg = ERR_MSG(err), (err)) @@ -130,17 +137,8 @@ extern z_const char * const z_errmsg[10]; /* indexed by 2-zlib_error */ # endif #endif -#if defined(MACOS) || defined(TARGET_OS_MAC) +#if defined(MACOS) # define OS_CODE 7 -# ifndef Z_SOLO -# if defined(__MWERKS__) && __dest_os != __be_os && __dest_os != __win32_os -# include /* for fdopen */ -# else -# ifndef fdopen -# define fdopen(fd,mode) NULL /* No fdopen() */ -# endif -# endif -# endif #endif #ifdef __acorn @@ -163,22 +161,6 @@ extern z_const char * const z_errmsg[10]; /* indexed by 2-zlib_error */ # define OS_CODE 19 #endif -#if defined(_BEOS_) || defined(RISCOS) -# define fdopen(fd,mode) NULL /* No fdopen() */ -#endif - -#if (defined(_MSC_VER) && (_MSC_VER > 600)) && !defined __INTERIX -# if defined(_WIN32_WCE) -# define fdopen(fd,mode) NULL /* No fdopen() */ -# ifndef _PTRDIFF_T_DEFINED - typedef int ptrdiff_t; -# define _PTRDIFF_T_DEFINED -# endif -# else -# define fdopen(fd,type) _fdopen(fd,type) -# endif -#endif - #if defined(__BORLANDC__) && !defined(MSDOS) #pragma warn -8004 #pragma warn -8008 @@ -188,8 +170,9 @@ extern z_const char * const z_errmsg[10]; /* indexed by 2-zlib_error */ /* provide prototypes for these when building zlib without LFS */ #if !defined(_WIN32) && \ (!defined(_LARGEFILE64_SOURCE) || _LFS64_LARGEFILE-0 == 0) - ZEXTERN uLong ZEXPORT adler32_combine64 OF((uLong, uLong, z_off_t)); - ZEXTERN uLong ZEXPORT crc32_combine64 OF((uLong, uLong, z_off_t)); + ZEXTERN uLong ZEXPORT adler32_combine64(uLong, uLong, z_off_t); + ZEXTERN uLong ZEXPORT crc32_combine64(uLong, uLong, z_off_t); + ZEXTERN uLong ZEXPORT crc32_combine_gen64(z_off_t); #endif /* common defaults */ @@ -228,16 +211,16 @@ extern z_const char * const z_errmsg[10]; /* indexed by 2-zlib_error */ # define zmemzero(dest, len) memset(dest, 0, len) # endif #else - void ZLIB_INTERNAL zmemcpy OF((Bytef* dest, const Bytef* source, uInt len)); - int ZLIB_INTERNAL zmemcmp OF((const Bytef* s1, const Bytef* s2, uInt len)); - void ZLIB_INTERNAL zmemzero OF((Bytef* dest, uInt len)); + void ZLIB_INTERNAL zmemcpy(Bytef* dest, const Bytef* source, uInt len); + int ZLIB_INTERNAL zmemcmp(const Bytef* s1, const Bytef* s2, uInt len); + void ZLIB_INTERNAL zmemzero(Bytef* dest, uInt len); #endif /* Diagnostic functions */ #ifdef ZLIB_DEBUG # include extern int ZLIB_INTERNAL z_verbose; - extern void ZLIB_INTERNAL z_error OF((char *m)); + extern void ZLIB_INTERNAL z_error(char *m); # define Assert(cond,msg) {if(!(cond)) z_error(msg);} # define Trace(x) {if (z_verbose>=0) fprintf x ;} # define Tracev(x) {if (z_verbose>0) fprintf x ;} @@ -254,9 +237,9 @@ extern z_const char * const z_errmsg[10]; /* indexed by 2-zlib_error */ #endif #ifndef Z_SOLO - voidpf ZLIB_INTERNAL zcalloc OF((voidpf opaque, unsigned items, - unsigned size)); - void ZLIB_INTERNAL zcfree OF((voidpf opaque, voidpf ptr)); + voidpf ZLIB_INTERNAL zcalloc(voidpf opaque, unsigned items, + unsigned size); + void ZLIB_INTERNAL zcfree(voidpf opaque, voidpf ptr); #endif #define ZALLOC(strm, items, size) \ diff --git a/fuzzing/CMakeLists.txt b/fuzzing/CMakeLists.txt index 5a9f9a4..245aa6b 100644 --- a/fuzzing/CMakeLists.txt +++ b/fuzzing/CMakeLists.txt @@ -1,4 +1,4 @@ -CMAKE_MINIMUM_REQUIRED(VERSION 3.1.0 FATAL_ERROR) +CMAKE_MINIMUM_REQUIRED(VERSION 3.22) PROJECT(ffsparser_fuzzer LANGUAGES C CXX) @@ -32,6 +32,17 @@ SET(PROJECT_SOURCES ../common/Tiano/EfiTianoDecompress.c ../common/ustring.cpp ../common/generated/ami_nvar.cpp + ../common/generated/apple_sysf.cpp + ../common/generated/dell_dvar.cpp + ../common/generated/edk2_vss.cpp + ../common/generated/edk2_vss2.cpp + ../common/generated/edk2_ftw.cpp + ../common/generated/insyde_fdc.cpp + ../common/generated/insyde_fdm.cpp + ../common/generated/ms_slic_marker.cpp + ../common/generated/ms_slic_pubkey.cpp + ../common/generated/phoenix_flm.cpp + ../common/generated/phoenix_evsa.cpp ../common/generated/intel_acbp_v1.cpp ../common/generated/intel_acbp_v2.cpp ../common/generated/intel_keym_v1.cpp diff --git a/kaitai_regenerate.sh b/kaitai_regenerate.sh index 4c2a881..c97e003 100755 --- a/kaitai_regenerate.sh +++ b/kaitai_regenerate.sh @@ -7,12 +7,10 @@ if [ "$UTARGET" = "Darwin" ]; then export UPLATFORM="mac" export UFIND="find -E" export UFINDOPT="" - export USEDOPT="''" elif [ "$UTARGET" = "Linux" ]; then export UPLATFORM="linux_$(uname -m)" export UFIND="find" export UFINDOPT="-regextype posix-extended" - export USEDOPT="" else export UPLATFORM="$UTARGET" echo "Please run this script on Linux or macOS" @@ -30,26 +28,39 @@ ${UFIND} common/generated ${UFINDOPT} \ # Replace global includes for kaitai with local ones (<> -> "") ${UFIND} common/generated ${UFINDOPT} \ -regex '.*\.(cpp|h)' \ - -exec sed -i ${USEDOPT} '/^#include ]/\"/g' {} + || exit 1 + -exec sed -i.bak '/^#include ]/\"/g' {} + || exit 1 # Add .. to the include path for kaitai includes ${UFIND} common/generated ${UFINDOPT} \ -regex '.*\.(cpp|h)' \ - -exec sed -i ${USEDOPT} '/^#include \"kaitai\//s/kaitai\//..\/kaitai\//g' {} + || exit 1 + -exec sed -i.bak '/^#include \"kaitai\//s/kaitai\//..\/kaitai\//g' {} + || exit 1 # Suppress "p__root - unused parameter" warning ${UFIND} common/generated ${UFINDOPT} \ -regex '.*\.(cpp)' \ - -exec sed -i ${USEDOPT} '/^ m__root = this;/s/;/; (void)p__root;/g' {} + || exit 1 + -exec sed -i.bak '/^ m__root = this;/s/;/; (void)p__root;/g' {} + || exit 1 # Add uint64_t to enum structure_ids_t ${UFIND} common/generated ${UFINDOPT} \ -regex '.*\.(h)' \ - -exec sed -i ${USEDOPT} '/^ enum structure_ids_t {/s/{/: uint64_t {/g' {} + || exit 1 + -exec sed -i.bak '/^ enum structure_ids_t {/s/{/: uint64_t {/g' {} + || exit 1 # Suppress type downcast warning in ami_nvar.cpp ${UFIND} common/generated ${UFINDOPT} \ -name 'ami_nvar.cpp' \ - -exec sed -i ${USEDOPT} 's/_offset = _io()->pos();/_offset = (int32_t)_io()->pos();/g' {} + || exit 1 + -exec sed -i.bak 's/_offset = _io()->pos();/_offset = (int32_t)_io()->pos();/g' {} + || exit 1 + +# Suppress type downcast warning in edk2_vss2.cpp +${UFIND} common/generated ${UFINDOPT} \ + -name 'edk2_vss2.cpp' \ + -exec sed -i.bak 's/_offset = _io()->pos();/_offset = (int32_t)_io()->pos();/g' {} + || exit 1 +${UFIND} common/generated ${UFINDOPT} \ + -name 'edk2_vss2.cpp' \ + -exec sed -i.bak 's/_offset_auth = _io()->pos();/_offset_auth = (int32_t)_io()->pos();/g' {} + || exit 1 + +# Remove backup files +${UFIND} common/generated ${UFINDOPT} \ + -regex '.*\.(bak)' \ + -exec rm {} + || exit 1 exit 0 diff --git a/meson.build b/meson.build index 2468d91..36455a6 100644 --- a/meson.build +++ b/meson.build @@ -1,5 +1,5 @@ project('UEFITool', ['c', 'cpp'], - version: 'A67', + version: 'A71', license: 'BSD-2-Clause', meson_version: '>=0.45.0', default_options : ['c_std=c11', 'cpp_std=c++11'], diff --git a/version.h b/version.h index 43dbbf9..3829888 100644 --- a/version.h +++ b/version.h @@ -14,6 +14,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. #ifndef VERSION_H #define VERSION_H -#define PROGRAM_VERSION "NE alpha 67" " (" __DATE__ ")" +#define PROGRAM_VERSION "NE alpha 71" " (" __DATE__ ")" #endif // VERSION_H