(root)/
xz-5.4.5/
src/
liblzma/
check/
crc64_table.c
       1  ///////////////////////////////////////////////////////////////////////////////
       2  //
       3  /// \file       crc64_table.c
       4  /// \brief      Precalculated CRC64 table with correct endianness
       5  //
       6  //  Author:     Lasse Collin
       7  //
       8  //  This file has been put into the public domain.
       9  //  You can do whatever you want with this file.
      10  //
      11  ///////////////////////////////////////////////////////////////////////////////
      12  
      13  #include "common.h"
      14  
      15  
      16  // FIXME: Compared to crc64_fast.c this has to check for __x86_64__ too
      17  // so that in 32-bit builds crc64_x86.S won't break due to a missing table.
      18  #if (defined(__x86_64__) && defined(__SSSE3__) \
      19  			&& defined(__SSE4_1__) && defined(__PCLMUL__)) \
      20  		|| (defined(__e2k__) && __iset__ >= 6)
      21  // No table needed. Use a typedef to avoid an empty translation unit.
      22  typedef void lzma_crc64_dummy;
      23  
      24  #else
      25  // Having the declaration here silences clang -Wmissing-variable-declarations.
      26  extern const uint64_t lzma_crc64_table[4][256];
      27  
      28  #	if defined(WORDS_BIGENDIAN)
      29  #		include "crc64_table_be.h"
      30  #	else
      31  #		include "crc64_table_le.h"
      32  #	endif
      33  #endif