modernc.org/z@v1.7.4/lib/z_openbsd_amd64.go (about)

     1  // Code generated by 'ccgo -export-defines "" -export-enums "" -export-externs X -export-fields F -export-structs "" -export-typedefs "" -o lib/z_openbsd_amd64.go -pkgname z -trace-translation-units /tmp/go-generate-4169310015/cdb.json libz.a', DO NOT EDIT.
     2  
     3  package z
     4  
     5  import (
     6  	"math"
     7  	"reflect"
     8  	"sync/atomic"
     9  	"unsafe"
    10  
    11  	"modernc.org/libc"
    12  	"modernc.org/libc/sys/types"
    13  )
    14  
    15  var _ = math.Pi
    16  var _ reflect.Kind
    17  var _ atomic.Value
    18  var _ unsafe.Pointer
    19  var _ *libc.TLS
    20  var _ types.Size_t
    21  
    22  const (
    23  	ARG_MAX                              = 524288
    24  	BASE                                 = 65521
    25  	BC_BASE_MAX                          = 2147483647
    26  	BC_DIM_MAX                           = 65535
    27  	BC_SCALE_MAX                         = 2147483647
    28  	BC_STRING_MAX                        = 2147483647
    29  	BIG_ENDIAN                           = 4321
    30  	BYTE_ORDER                           = 1234
    31  	CHAR_BIT                             = 8
    32  	CHAR_MAX                             = 0x7f
    33  	CHAR_MIN                             = -128
    34  	CHILD_MAX                            = 80
    35  	COLL_WEIGHTS_MAX                     = 2
    36  	DEF_MEM_LEVEL                        = 8
    37  	DEF_WBITS                            = 15
    38  	DYN_TREES                            = 2
    39  	EXIT_FAILURE                         = 1
    40  	EXIT_SUCCESS                         = 0
    41  	EXPR_NEST_MAX                        = 32
    42  	FAR                                  = 0
    43  	F_LOCK                               = 1
    44  	F_OK                                 = 0
    45  	F_TEST                               = 3
    46  	F_TLOCK                              = 2
    47  	F_ULOCK                              = 0
    48  	GID_MAX                              = 4294967295
    49  	HAVE_HIDDEN                          = 1
    50  	HAVE_MEMCPY                          = 0
    51  	HOST_NAME_MAX                        = 255
    52  	INT_MAX                              = 0x7fffffff
    53  	INT_MIN                              = -2147483648
    54  	IOV_MAX                              = 1024
    55  	KBIND_BLOCK_MAX                      = 2
    56  	KBIND_DATA_MAX                       = 24
    57  	LINE_MAX                             = 2048
    58  	LINK_MAX                             = 32767
    59  	LITTLE_ENDIAN                        = 1234
    60  	LLONG_MAX                            = 0x7fffffffffffffff
    61  	LLONG_MIN                            = -9223372036854775808
    62  	LOGIN_NAME_MAX                       = 32
    63  	LONG_BIT                             = 64
    64  	LONG_MAX                             = 0x7fffffffffffffff
    65  	LONG_MIN                             = -9223372036854775808
    66  	L_INCR                               = 1
    67  	L_SET                                = 0
    68  	L_XTND                               = 2
    69  	MAX_CANON                            = 255
    70  	MAX_INPUT                            = 255
    71  	MAX_MATCH                            = 258
    72  	MAX_MEM_LEVEL                        = 9
    73  	MAX_WBITS                            = 15
    74  	MB_LEN_MAX                           = 4
    75  	MIN_MATCH                            = 3
    76  	NAME_MAX                             = 255
    77  	NGROUPS_MAX                          = 16
    78  	NL_ARGMAX                            = 9
    79  	NL_LANGMAX                           = 14
    80  	NL_MSGMAX                            = 32767
    81  	NL_SETMAX                            = 255
    82  	NL_TEXTMAX                           = 255
    83  	NMAX                                 = 5552
    84  	NZERO                                = 20
    85  	OPEN_MAX                             = 64
    86  	OS_CODE                              = 3
    87  	PATH_MAX                             = 1024
    88  	PDP_ENDIAN                           = 3412
    89  	PIPE_BUF                             = 512
    90  	PRESET_DICT                          = 0x20
    91  	QUAD_MAX                             = 0x7fffffffffffffff
    92  	QUAD_MIN                             = -9223372036854775808
    93  	RAND_MAX                             = 0x7fffffff
    94  	RE_DUP_MAX                           = 255
    95  	R_OK                                 = 0x04
    96  	SCHAR_MAX                            = 0x7f
    97  	SCHAR_MIN                            = -128
    98  	SEEK_CUR                             = 1
    99  	SEEK_END                             = 2
   100  	SEEK_SET                             = 0
   101  	SEM_VALUE_MAX                        = 4294967295
   102  	SHRT_MAX                             = 0x7fff
   103  	SHRT_MIN                             = -32768
   104  	SIZE_T_MAX                           = 18446744073709551615
   105  	SSIZE_MAX                            = 9223372036854775807
   106  	STATIC_TREES                         = 1
   107  	STDC                                 = 0
   108  	STDC99                               = 0
   109  	STDERR_FILENO                        = 2
   110  	STDIN_FILENO                         = 0
   111  	STDOUT_FILENO                        = 1
   112  	STORED_BLOCK                         = 0
   113  	SYMLINK_MAX                          = 1024
   114  	SYMLOOP_MAX                          = 32
   115  	TTY_NAME_MAX                         = 260
   116  	UCHAR_MAX                            = 0xff
   117  	UID_MAX                              = 4294967295
   118  	UINT_MAX                             = 0xffffffff
   119  	ULLONG_MAX                           = 0xffffffffffffffff
   120  	ULONG_MAX                            = 0xffffffffffffffff
   121  	UQUAD_MAX                            = 0xffffffffffffffff
   122  	USHRT_MAX                            = 0xffff
   123  	WORD_BIT                             = 32
   124  	W_OK                                 = 0x02
   125  	X_OK                                 = 0x01
   126  	ZCONF_H                              = 0
   127  	ZEXPORT                              = 0
   128  	ZEXPORTVA                            = 0
   129  	ZLIB_H                               = 0
   130  	ZLIB_VERNUM                          = 0x12b0
   131  	ZLIB_VERSION                         = "1.2.11"
   132  	ZLIB_VER_MAJOR                       = 1
   133  	ZLIB_VER_MINOR                       = 2
   134  	ZLIB_VER_REVISION                    = 11
   135  	ZLIB_VER_SUBREVISION                 = 0
   136  	ZUTIL_H                              = 0
   137  	Z_ASCII                              = 1
   138  	Z_BEST_COMPRESSION                   = 9
   139  	Z_BEST_SPEED                         = 1
   140  	Z_BINARY                             = 0
   141  	Z_BLOCK                              = 5
   142  	Z_BUF_ERROR                          = -5
   143  	Z_DATA_ERROR                         = -3
   144  	Z_DEFAULT_COMPRESSION                = -1
   145  	Z_DEFAULT_STRATEGY                   = 0
   146  	Z_DEFLATED                           = 8
   147  	Z_ERRNO                              = -1
   148  	Z_FILTERED                           = 1
   149  	Z_FINISH                             = 4
   150  	Z_FIXED                              = 4
   151  	Z_FULL_FLUSH                         = 3
   152  	Z_HAVE_STDARG_H                      = 0
   153  	Z_HAVE_UNISTD_H                      = 0
   154  	Z_HUFFMAN_ONLY                       = 2
   155  	Z_MEM_ERROR                          = -4
   156  	Z_NEED_DICT                          = 2
   157  	Z_NO_COMPRESSION                     = 0
   158  	Z_NO_FLUSH                           = 0
   159  	Z_NULL                               = 0
   160  	Z_OK                                 = 0
   161  	Z_PARTIAL_FLUSH                      = 1
   162  	Z_RLE                                = 3
   163  	Z_STREAM_END                         = 1
   164  	Z_STREAM_ERROR                       = -2
   165  	Z_SYNC_FLUSH                         = 2
   166  	Z_TEXT                               = 1
   167  	Z_TREES                              = 6
   168  	Z_UNKNOWN                            = 2
   169  	Z_VERSION_ERROR                      = -6
   170  	X_BIG_ENDIAN                         = 4321
   171  	X_BYTE_ORDER                         = 1234
   172  	X_CLOCKID_T_DEFINED_                 = 0
   173  	X_CLOCK_T_DEFINED_                   = 0
   174  	X_CS_PATH                            = 1
   175  	X_CS_POSIX_V6_ILP32_OFF32_CFLAGS     = 2
   176  	X_CS_POSIX_V6_ILP32_OFF32_LDFLAGS    = 3
   177  	X_CS_POSIX_V6_ILP32_OFF32_LIBS       = 4
   178  	X_CS_POSIX_V6_ILP32_OFFBIG_CFLAGS    = 5
   179  	X_CS_POSIX_V6_ILP32_OFFBIG_LDFLAGS   = 6
   180  	X_CS_POSIX_V6_ILP32_OFFBIG_LIBS      = 7
   181  	X_CS_POSIX_V6_LP64_OFF64_CFLAGS      = 8
   182  	X_CS_POSIX_V6_LP64_OFF64_LDFLAGS     = 9
   183  	X_CS_POSIX_V6_LP64_OFF64_LIBS        = 10
   184  	X_CS_POSIX_V6_LPBIG_OFFBIG_CFLAGS    = 11
   185  	X_CS_POSIX_V6_LPBIG_OFFBIG_LDFLAGS   = 12
   186  	X_CS_POSIX_V6_LPBIG_OFFBIG_LIBS      = 13
   187  	X_CS_POSIX_V6_WIDTH_RESTRICTED_ENVS  = 14
   188  	X_CS_POSIX_V7_ILP32_OFF32_CFLAGS     = 16
   189  	X_CS_POSIX_V7_ILP32_OFF32_LDFLAGS    = 17
   190  	X_CS_POSIX_V7_ILP32_OFF32_LIBS       = 18
   191  	X_CS_POSIX_V7_ILP32_OFFBIG_CFLAGS    = 19
   192  	X_CS_POSIX_V7_ILP32_OFFBIG_LDFLAGS   = 20
   193  	X_CS_POSIX_V7_ILP32_OFFBIG_LIBS      = 21
   194  	X_CS_POSIX_V7_LP64_OFF64_CFLAGS      = 22
   195  	X_CS_POSIX_V7_LP64_OFF64_LDFLAGS     = 23
   196  	X_CS_POSIX_V7_LP64_OFF64_LIBS        = 24
   197  	X_CS_POSIX_V7_LPBIG_OFFBIG_CFLAGS    = 25
   198  	X_CS_POSIX_V7_LPBIG_OFFBIG_LDFLAGS   = 26
   199  	X_CS_POSIX_V7_LPBIG_OFFBIG_LIBS      = 27
   200  	X_CS_POSIX_V7_THREADS_CFLAGS         = 28
   201  	X_CS_POSIX_V7_THREADS_LDFLAGS        = 29
   202  	X_CS_POSIX_V7_WIDTH_RESTRICTED_ENVS  = 30
   203  	X_CS_V6_ENV                          = 15
   204  	X_CS_V7_ENV                          = 31
   205  	X_FILE_OFFSET_BITS                   = 64
   206  	X_GETOPT_DEFINED_                    = 0
   207  	X_INT16_T_DEFINED_                   = 0
   208  	X_INT32_T_DEFINED_                   = 0
   209  	X_INT64_T_DEFINED_                   = 0
   210  	X_INT8_T_DEFINED_                    = 0
   211  	X_INTPTR_T_DEFINED_                  = 0
   212  	X_LIMITS_H_                          = 0
   213  	X_LITTLE_ENDIAN                      = 1234
   214  	X_LOCALE_T_DEFINED_                  = 0
   215  	X_LP64                               = 1
   216  	X_MACHINE_CDEFS_H_                   = 0
   217  	X_MACHINE_ENDIAN_H_                  = 0
   218  	X_MACHINE_LIMITS_H_                  = 0
   219  	X_MACHINE__TYPES_H_                  = 0
   220  	X_MAX_PAGE_SHIFT                     = 12
   221  	X_MBSTATE_T_DEFINED_                 = 0
   222  	X_OFF_T_DEFINED_                     = 0
   223  	X_PC_2_SYMLINKS                      = 10
   224  	X_PC_ALLOC_SIZE_MIN                  = 11
   225  	X_PC_ASYNC_IO                        = 12
   226  	X_PC_CHOWN_RESTRICTED                = 7
   227  	X_PC_FILESIZEBITS                    = 13
   228  	X_PC_LINK_MAX                        = 1
   229  	X_PC_MAX_CANON                       = 2
   230  	X_PC_MAX_INPUT                       = 3
   231  	X_PC_NAME_MAX                        = 4
   232  	X_PC_NO_TRUNC                        = 8
   233  	X_PC_PATH_MAX                        = 5
   234  	X_PC_PIPE_BUF                        = 6
   235  	X_PC_PRIO_IO                         = 14
   236  	X_PC_REC_INCR_XFER_SIZE              = 15
   237  	X_PC_REC_MAX_XFER_SIZE               = 16
   238  	X_PC_REC_MIN_XFER_SIZE               = 17
   239  	X_PC_REC_XFER_ALIGN                  = 18
   240  	X_PC_SYMLINK_MAX                     = 19
   241  	X_PC_SYNC_IO                         = 20
   242  	X_PC_TIMESTAMP_RESOLUTION            = 21
   243  	X_PC_VDISABLE                        = 9
   244  	X_PDP_ENDIAN                         = 3412
   245  	X_PID_T_DEFINED_                     = 0
   246  	X_POSIX2_BC_BASE_MAX                 = 99
   247  	X_POSIX2_BC_DIM_MAX                  = 2048
   248  	X_POSIX2_BC_SCALE_MAX                = 99
   249  	X_POSIX2_BC_STRING_MAX               = 1000
   250  	X_POSIX2_CHARCLASS_NAME_MAX          = 14
   251  	X_POSIX2_CHAR_TERM                   = 1
   252  	X_POSIX2_COLL_WEIGHTS_MAX            = 2
   253  	X_POSIX2_C_BIND                      = 200112
   254  	X_POSIX2_C_DEV                       = -1
   255  	X_POSIX2_EXPR_NEST_MAX               = 32
   256  	X_POSIX2_FORT_DEV                    = -1
   257  	X_POSIX2_FORT_RUN                    = -1
   258  	X_POSIX2_LINE_MAX                    = 2048
   259  	X_POSIX2_LOCALEDEF                   = -1
   260  	X_POSIX2_PBS                         = -1
   261  	X_POSIX2_PBS_ACCOUNTING              = -1
   262  	X_POSIX2_PBS_CHECKPOINT              = -1
   263  	X_POSIX2_PBS_LOCATE                  = -1
   264  	X_POSIX2_PBS_MESSAGE                 = -1
   265  	X_POSIX2_PBS_TRACK                   = -1
   266  	X_POSIX2_RE_DUP_MAX                  = 255
   267  	X_POSIX2_SW_DEV                      = 200112
   268  	X_POSIX2_UPE                         = 200112
   269  	X_POSIX2_VERSION                     = 200809
   270  	X_POSIX_ADVISORY_INFO                = -1
   271  	X_POSIX_ARG_MAX                      = 4096
   272  	X_POSIX_ASYNCHRONOUS_IO              = -1
   273  	X_POSIX_ASYNC_IO                     = -1
   274  	X_POSIX_BARRIERS                     = 200112
   275  	X_POSIX_CHILD_MAX                    = 25
   276  	X_POSIX_CHOWN_RESTRICTED             = 1
   277  	X_POSIX_CLOCKRES_MIN                 = 20000000
   278  	X_POSIX_CLOCK_SELECTION              = -1
   279  	X_POSIX_CPUTIME                      = 200809
   280  	X_POSIX_FSYNC                        = 200112
   281  	X_POSIX_HOST_NAME_MAX                = 255
   282  	X_POSIX_IPV6                         = 0
   283  	X_POSIX_JOB_CONTROL                  = 1
   284  	X_POSIX_LINK_MAX                     = 8
   285  	X_POSIX_LOGIN_NAME_MAX               = 9
   286  	X_POSIX_MAPPED_FILES                 = 200112
   287  	X_POSIX_MAX_CANON                    = 255
   288  	X_POSIX_MAX_INPUT                    = 255
   289  	X_POSIX_MEMLOCK                      = 200112
   290  	X_POSIX_MEMLOCK_RANGE                = 200112
   291  	X_POSIX_MEMORY_PROTECTION            = 200112
   292  	X_POSIX_MESSAGE_PASSING              = -1
   293  	X_POSIX_MONOTONIC_CLOCK              = 200112
   294  	X_POSIX_NAME_MAX                     = 14
   295  	X_POSIX_NGROUPS_MAX                  = 8
   296  	X_POSIX_NO_TRUNC                     = 1
   297  	X_POSIX_OPEN_MAX                     = 20
   298  	X_POSIX_PATH_MAX                     = 256
   299  	X_POSIX_PIPE_BUF                     = 512
   300  	X_POSIX_PRIORITIZED_IO               = -1
   301  	X_POSIX_PRIORITY_SCHEDULING          = -1
   302  	X_POSIX_PRIO_IO                      = -1
   303  	X_POSIX_RAW_SOCKETS                  = 200112
   304  	X_POSIX_READER_WRITER_LOCKS          = 200112
   305  	X_POSIX_REALTIME_SIGNALS             = -1
   306  	X_POSIX_REGEXP                       = 1
   307  	X_POSIX_RE_DUP_MAX                   = 255
   308  	X_POSIX_SAVED_IDS                    = 1
   309  	X_POSIX_SEMAPHORES                   = 200112
   310  	X_POSIX_SEM_NSEMS_MAX                = 256
   311  	X_POSIX_SEM_VALUE_MAX                = 32767
   312  	X_POSIX_SHARED_MEMORY_OBJECTS        = 200809
   313  	X_POSIX_SHELL                        = 1
   314  	X_POSIX_SPAWN                        = 200112
   315  	X_POSIX_SPIN_LOCKS                   = 200112
   316  	X_POSIX_SPORADIC_SERVER              = -1
   317  	X_POSIX_SSIZE_MAX                    = 32767
   318  	X_POSIX_STREAM_MAX                   = 8
   319  	X_POSIX_SYMLINK_MAX                  = 255
   320  	X_POSIX_SYMLOOP_MAX                  = 8
   321  	X_POSIX_SYNCHRONIZED_IO              = -1
   322  	X_POSIX_SYNC_IO                      = -1
   323  	X_POSIX_THREADS                      = 200112
   324  	X_POSIX_THREAD_ATTR_STACKADDR        = 200112
   325  	X_POSIX_THREAD_ATTR_STACKSIZE        = 200112
   326  	X_POSIX_THREAD_CPUTIME               = 200809
   327  	X_POSIX_THREAD_DESTRUCTOR_ITERATIONS = 4
   328  	X_POSIX_THREAD_KEYS_MAX              = 128
   329  	X_POSIX_THREAD_PRIORITY_SCHEDULING   = -1
   330  	X_POSIX_THREAD_PRIO_INHERIT          = -1
   331  	X_POSIX_THREAD_PRIO_PROTECT          = -1
   332  	X_POSIX_THREAD_PROCESS_SHARED        = -1
   333  	X_POSIX_THREAD_ROBUST_PRIO_INHERIT   = -1
   334  	X_POSIX_THREAD_ROBUST_PRIO_PROTECT   = -1
   335  	X_POSIX_THREAD_SAFE_FUNCTIONS        = 200112
   336  	X_POSIX_THREAD_SPORADIC_SERVER       = -1
   337  	X_POSIX_THREAD_THREADS_MAX           = 4
   338  	X_POSIX_TIMEOUTS                     = 200112
   339  	X_POSIX_TIMERS                       = -1
   340  	X_POSIX_TRACE                        = -1
   341  	X_POSIX_TRACE_EVENT_FILTER           = -1
   342  	X_POSIX_TRACE_INHERIT                = -1
   343  	X_POSIX_TRACE_LOG                    = -1
   344  	X_POSIX_TTY_NAME_MAX                 = 9
   345  	X_POSIX_TYPED_MEMORY_OBJECTS         = -1
   346  	X_POSIX_TZNAME_MAX                   = 6
   347  	X_POSIX_V6_ILP32_OFF32               = -1
   348  	X_POSIX_V6_ILP32_OFFBIG              = 0
   349  	X_POSIX_V6_LP64_OFF64                = 0
   350  	X_POSIX_V6_LPBIG_OFFBIG              = 0
   351  	X_POSIX_V7_ILP32_OFF32               = -1
   352  	X_POSIX_V7_ILP32_OFFBIG              = 0
   353  	X_POSIX_V7_LP64_OFF64                = 0
   354  	X_POSIX_V7_LPBIG_OFFBIG              = 0
   355  	X_POSIX_VDISABLE                     = 255
   356  	X_POSIX_VERSION                      = 200809
   357  	X_PTRDIFF_T_DEFINED_                 = 0
   358  	X_QUAD_HIGHWORD                      = 1
   359  	X_QUAD_LOWWORD                       = 0
   360  	X_RET_PROTECTOR                      = 1
   361  	X_SC_2_CHAR_TERM                     = 20
   362  	X_SC_2_C_BIND                        = 18
   363  	X_SC_2_C_DEV                         = 19
   364  	X_SC_2_FORT_DEV                      = 21
   365  	X_SC_2_FORT_RUN                      = 22
   366  	X_SC_2_LOCALEDEF                     = 23
   367  	X_SC_2_PBS                           = 35
   368  	X_SC_2_PBS_ACCOUNTING                = 36
   369  	X_SC_2_PBS_CHECKPOINT                = 37
   370  	X_SC_2_PBS_LOCATE                    = 38
   371  	X_SC_2_PBS_MESSAGE                   = 39
   372  	X_SC_2_PBS_TRACK                     = 40
   373  	X_SC_2_SW_DEV                        = 24
   374  	X_SC_2_UPE                           = 25
   375  	X_SC_2_VERSION                       = 17
   376  	X_SC_ADVISORY_INFO                   = 41
   377  	X_SC_AIO_LISTIO_MAX                  = 42
   378  	X_SC_AIO_MAX                         = 43
   379  	X_SC_AIO_PRIO_DELTA_MAX              = 44
   380  	X_SC_ARG_MAX                         = 1
   381  	X_SC_ASYNCHRONOUS_IO                 = 45
   382  	X_SC_ATEXIT_MAX                      = 46
   383  	X_SC_AVPHYS_PAGES                    = 501
   384  	X_SC_BARRIERS                        = 47
   385  	X_SC_BC_BASE_MAX                     = 9
   386  	X_SC_BC_DIM_MAX                      = 10
   387  	X_SC_BC_SCALE_MAX                    = 11
   388  	X_SC_BC_STRING_MAX                   = 12
   389  	X_SC_CHILD_MAX                       = 2
   390  	X_SC_CLK_TCK                         = 3
   391  	X_SC_CLOCK_SELECTION                 = 48
   392  	X_SC_COLL_WEIGHTS_MAX                = 13
   393  	X_SC_CPUTIME                         = 49
   394  	X_SC_DELAYTIMER_MAX                  = 50
   395  	X_SC_EXPR_NEST_MAX                   = 14
   396  	X_SC_FSYNC                           = 29
   397  	X_SC_GETGR_R_SIZE_MAX                = 100
   398  	X_SC_GETPW_R_SIZE_MAX                = 101
   399  	X_SC_HOST_NAME_MAX                   = 33
   400  	X_SC_IOV_MAX                         = 51
   401  	X_SC_IPV6                            = 52
   402  	X_SC_JOB_CONTROL                     = 6
   403  	X_SC_LINE_MAX                        = 15
   404  	X_SC_LOGIN_NAME_MAX                  = 102
   405  	X_SC_MAPPED_FILES                    = 53
   406  	X_SC_MEMLOCK                         = 54
   407  	X_SC_MEMLOCK_RANGE                   = 55
   408  	X_SC_MEMORY_PROTECTION               = 56
   409  	X_SC_MESSAGE_PASSING                 = 57
   410  	X_SC_MONOTONIC_CLOCK                 = 34
   411  	X_SC_MQ_OPEN_MAX                     = 58
   412  	X_SC_MQ_PRIO_MAX                     = 59
   413  	X_SC_NGROUPS_MAX                     = 4
   414  	X_SC_NPROCESSORS_CONF                = 502
   415  	X_SC_NPROCESSORS_ONLN                = 503
   416  	X_SC_OPEN_MAX                        = 5
   417  	X_SC_PAGESIZE                        = 28
   418  	X_SC_PAGE_SIZE                       = 28
   419  	X_SC_PHYS_PAGES                      = 500
   420  	X_SC_PRIORITIZED_IO                  = 60
   421  	X_SC_PRIORITY_SCHEDULING             = 61
   422  	X_SC_RAW_SOCKETS                     = 62
   423  	X_SC_READER_WRITER_LOCKS             = 63
   424  	X_SC_REALTIME_SIGNALS                = 64
   425  	X_SC_REGEXP                          = 65
   426  	X_SC_RE_DUP_MAX                      = 16
   427  	X_SC_RTSIG_MAX                       = 66
   428  	X_SC_SAVED_IDS                       = 7
   429  	X_SC_SEMAPHORES                      = 67
   430  	X_SC_SEM_NSEMS_MAX                   = 31
   431  	X_SC_SEM_VALUE_MAX                   = 32
   432  	X_SC_SHARED_MEMORY_OBJECTS           = 68
   433  	X_SC_SHELL                           = 69
   434  	X_SC_SIGQUEUE_MAX                    = 70
   435  	X_SC_SPAWN                           = 71
   436  	X_SC_SPIN_LOCKS                      = 72
   437  	X_SC_SPORADIC_SERVER                 = 73
   438  	X_SC_SS_REPL_MAX                     = 74
   439  	X_SC_STREAM_MAX                      = 26
   440  	X_SC_SYMLOOP_MAX                     = 76
   441  	X_SC_SYNCHRONIZED_IO                 = 75
   442  	X_SC_THREADS                         = 91
   443  	X_SC_THREAD_ATTR_STACKADDR           = 77
   444  	X_SC_THREAD_ATTR_STACKSIZE           = 78
   445  	X_SC_THREAD_CPUTIME                  = 79
   446  	X_SC_THREAD_DESTRUCTOR_ITERATIONS    = 80
   447  	X_SC_THREAD_KEYS_MAX                 = 81
   448  	X_SC_THREAD_PRIORITY_SCHEDULING      = 84
   449  	X_SC_THREAD_PRIO_INHERIT             = 82
   450  	X_SC_THREAD_PRIO_PROTECT             = 83
   451  	X_SC_THREAD_PROCESS_SHARED           = 85
   452  	X_SC_THREAD_ROBUST_PRIO_INHERIT      = 86
   453  	X_SC_THREAD_ROBUST_PRIO_PROTECT      = 87
   454  	X_SC_THREAD_SAFE_FUNCTIONS           = 103
   455  	X_SC_THREAD_SPORADIC_SERVER          = 88
   456  	X_SC_THREAD_STACK_MIN                = 89
   457  	X_SC_THREAD_THREADS_MAX              = 90
   458  	X_SC_TIMEOUTS                        = 92
   459  	X_SC_TIMERS                          = 94
   460  	X_SC_TIMER_MAX                       = 93
   461  	X_SC_TRACE                           = 95
   462  	X_SC_TRACE_EVENT_FILTER              = 96
   463  	X_SC_TRACE_EVENT_NAME_MAX            = 97
   464  	X_SC_TRACE_INHERIT                   = 98
   465  	X_SC_TRACE_LOG                       = 99
   466  	X_SC_TRACE_NAME_MAX                  = 104
   467  	X_SC_TRACE_SYS_MAX                   = 105
   468  	X_SC_TRACE_USER_EVENT_MAX            = 106
   469  	X_SC_TTY_NAME_MAX                    = 107
   470  	X_SC_TYPED_MEMORY_OBJECTS            = 108
   471  	X_SC_TZNAME_MAX                      = 27
   472  	X_SC_V6_ILP32_OFF32                  = 109
   473  	X_SC_V6_ILP32_OFFBIG                 = 110
   474  	X_SC_V6_LP64_OFF64                   = 111
   475  	X_SC_V6_LPBIG_OFFBIG                 = 112
   476  	X_SC_V7_ILP32_OFF32                  = 113
   477  	X_SC_V7_ILP32_OFFBIG                 = 114
   478  	X_SC_V7_LP64_OFF64                   = 115
   479  	X_SC_V7_LPBIG_OFFBIG                 = 116
   480  	X_SC_VERSION                         = 8
   481  	X_SC_XOPEN_CRYPT                     = 117
   482  	X_SC_XOPEN_ENH_I18N                  = 118
   483  	X_SC_XOPEN_LEGACY                    = 119
   484  	X_SC_XOPEN_REALTIME                  = 120
   485  	X_SC_XOPEN_REALTIME_THREADS          = 121
   486  	X_SC_XOPEN_SHM                       = 30
   487  	X_SC_XOPEN_STREAMS                   = 122
   488  	X_SC_XOPEN_UNIX                      = 123
   489  	X_SC_XOPEN_UUCP                      = 124
   490  	X_SC_XOPEN_VERSION                   = 125
   491  	X_SIZE_T_DEFINED_                    = 0
   492  	X_SSIZE_T_DEFINED_                   = 0
   493  	X_STACKALIGNBYTES                    = 15
   494  	X_STDARG_H_                          = 0
   495  	X_STDDEF_H_                          = 0
   496  	X_STDLIB_H_                          = 0
   497  	X_STRINGS_H_                         = 0
   498  	X_STRING_H_                          = 0
   499  	X_SYS_CDEFS_H_                       = 0
   500  	X_SYS_ENDIAN_H_                      = 0
   501  	X_SYS_LIMITS_H_                      = 0
   502  	X_SYS_TYPES_H_                       = 0
   503  	X_SYS_UNISTD_H_                      = 0
   504  	X_SYS__ENDIAN_H_                     = 0
   505  	X_SYS__TYPES_H_                      = 0
   506  	X_TIMER_T_DEFINED_                   = 0
   507  	X_TIME_T_DEFINED_                    = 0
   508  	X_UINT16_T_DEFINED_                  = 0
   509  	X_UINT32_T_DEFINED_                  = 0
   510  	X_UINT64_T_DEFINED_                  = 0
   511  	X_UINT8_T_DEFINED_                   = 0
   512  	X_UNISTD_H_                          = 0
   513  	X_WCHAR_T_DEFINED_                   = 0
   514  	X_WINT_T_DEFINED_                    = 0
   515  	X_XOPEN_CRYPT                        = 1
   516  	X_XOPEN_ENH_I18N                     = -1
   517  	X_XOPEN_IOV_MAX                      = 16
   518  	X_XOPEN_LEGACY                       = -1
   519  	X_XOPEN_NAME_MAX                     = 255
   520  	X_XOPEN_PATH_MAX                     = 1024
   521  	X_XOPEN_REALTIME                     = -1
   522  	X_XOPEN_REALTIME_THREADS             = -1
   523  	X_XOPEN_SHM                          = 1
   524  	X_XOPEN_STREAMS                      = -1
   525  	X_XOPEN_UNIX                         = -1
   526  	X_XOPEN_UUCP                         = -1
   527  	Unix                                 = 1
   528  	Z_const                              = 0
   529  	BYFOUR                               = 0
   530  	GF2_DIM                              = 32
   531  	TBLS                                 = 8
   532  	BL_CODES                             = 19
   533  	BUSY_STATE                           = 113
   534  	Buf_size                             = 16
   535  	COMMENT_STATE                        = 91
   536  	DEFLATE_H                            = 0
   537  	D_CODES                              = 30
   538  	EXTRA_STATE                          = 69
   539  	FINISH_STATE                         = 666
   540  	GZIP                                 = 0
   541  	GZIP_STATE                           = 57
   542  	HCRC_STATE                           = 103
   543  	HEAP_SIZE                            = 573
   544  	INIT_STATE                           = 42
   545  	LENGTH_CODES                         = 29
   546  	LITERALS                             = 256
   547  	L_CODES                              = 286
   548  	MAX_BITS                             = 15
   549  	MAX_STORED                           = 65535
   550  	MIN_LOOKAHEAD                        = 262
   551  	NAME_STATE                           = 73
   552  	NIL                                  = 0
   553  	TOO_FAR                              = 4096
   554  	WIN_INIT                             = 258
   555  	AT_EACCESS                           = 0x01
   556  	AT_FDCWD                             = -100
   557  	AT_REMOVEDIR                         = 0x08
   558  	AT_SYMLINK_FOLLOW                    = 0x04
   559  	AT_SYMLINK_NOFOLLOW                  = 0x02
   560  	BUFSIZ                               = 1024
   561  	COPY1                                = 1
   562  	E2BIG                                = 7
   563  	EACCES                               = 13
   564  	EADDRINUSE                           = 48
   565  	EADDRNOTAVAIL                        = 49
   566  	EAFNOSUPPORT                         = 47
   567  	EAGAIN                               = 35
   568  	EALREADY                             = 37
   569  	EAUTH                                = 80
   570  	EBADF                                = 9
   571  	EBADMSG                              = 92
   572  	EBADRPC                              = 72
   573  	EBUSY                                = 16
   574  	ECANCELED                            = 88
   575  	ECHILD                               = 10
   576  	ECONNABORTED                         = 53
   577  	ECONNREFUSED                         = 61
   578  	ECONNRESET                           = 54
   579  	EDEADLK                              = 11
   580  	EDESTADDRREQ                         = 39
   581  	EDOM                                 = 33
   582  	EDQUOT                               = 69
   583  	EEXIST                               = 17
   584  	EFAULT                               = 14
   585  	EFBIG                                = 27
   586  	EFTYPE                               = 79
   587  	EHOSTDOWN                            = 64
   588  	EHOSTUNREACH                         = 65
   589  	EIDRM                                = 89
   590  	EILSEQ                               = 84
   591  	EINPROGRESS                          = 36
   592  	EINTR                                = 4
   593  	EINVAL                               = 22
   594  	EIO                                  = 5
   595  	EIPSEC                               = 82
   596  	EISCONN                              = 56
   597  	EISDIR                               = 21
   598  	ELAST                                = 95
   599  	ELOOP                                = 62
   600  	EMEDIUMTYPE                          = 86
   601  	EMFILE                               = 24
   602  	EMLINK                               = 31
   603  	EMSGSIZE                             = 40
   604  	ENAMETOOLONG                         = 63
   605  	ENEEDAUTH                            = 81
   606  	ENETDOWN                             = 50
   607  	ENETRESET                            = 52
   608  	ENETUNREACH                          = 51
   609  	ENFILE                               = 23
   610  	ENOATTR                              = 83
   611  	ENOBUFS                              = 55
   612  	ENODEV                               = 19
   613  	ENOENT                               = 2
   614  	ENOEXEC                              = 8
   615  	ENOLCK                               = 77
   616  	ENOMEDIUM                            = 85
   617  	ENOMEM                               = 12
   618  	ENOMSG                               = 90
   619  	ENOPROTOOPT                          = 42
   620  	ENOSPC                               = 28
   621  	ENOSYS                               = 78
   622  	ENOTBLK                              = 15
   623  	ENOTCONN                             = 57
   624  	ENOTDIR                              = 20
   625  	ENOTEMPTY                            = 66
   626  	ENOTRECOVERABLE                      = 93
   627  	ENOTSOCK                             = 38
   628  	ENOTSUP                              = 91
   629  	ENOTTY                               = 25
   630  	ENXIO                                = 6
   631  	EOF                                  = -1
   632  	EOPNOTSUPP                           = 45
   633  	EOVERFLOW                            = 87
   634  	EOWNERDEAD                           = 94
   635  	EPERM                                = 1
   636  	EPFNOSUPPORT                         = 46
   637  	EPIPE                                = 32
   638  	EPROCLIM                             = 67
   639  	EPROCUNAVAIL                         = 76
   640  	EPROGMISMATCH                        = 75
   641  	EPROGUNAVAIL                         = 74
   642  	EPROTO                               = 95
   643  	EPROTONOSUPPORT                      = 43
   644  	EPROTOTYPE                           = 41
   645  	ERANGE                               = 34
   646  	EREMOTE                              = 71
   647  	EROFS                                = 30
   648  	ERPCMISMATCH                         = 73
   649  	ESHUTDOWN                            = 58
   650  	ESOCKTNOSUPPORT                      = 44
   651  	ESPIPE                               = 29
   652  	ESRCH                                = 3
   653  	ESTALE                               = 70
   654  	ETIMEDOUT                            = 60
   655  	ETOOMANYREFS                         = 59
   656  	ETXTBSY                              = 26
   657  	EUSERS                               = 68
   658  	EWOULDBLOCK                          = 35
   659  	EXDEV                                = 18
   660  	FAPPEND                              = 8
   661  	FASYNC                               = 64
   662  	FD_CLOEXEC                           = 1
   663  	FFSYNC                               = 128
   664  	FILENAME_MAX                         = 1024
   665  	FNDELAY                              = 4
   666  	FNONBLOCK                            = 4
   667  	FOPEN_MAX                            = 20
   668  	FREAD                                = 0x0001
   669  	FWRITE                               = 0x0002
   670  	F_DUPFD                              = 0
   671  	F_DUPFD_CLOEXEC                      = 10
   672  	F_GETFD                              = 1
   673  	F_GETFL                              = 3
   674  	F_GETLK                              = 7
   675  	F_GETOWN                             = 5
   676  	F_ISATTY                             = 11
   677  	F_RDLCK                              = 1
   678  	F_SETFD                              = 2
   679  	F_SETFL                              = 4
   680  	F_SETLK                              = 8
   681  	F_SETLKW                             = 9
   682  	F_SETOWN                             = 6
   683  	F_UNLCK                              = 2
   684  	F_WRLCK                              = 3
   685  	GZBUFSIZE                            = 8192
   686  	GZ_APPEND                            = 1
   687  	GZ_NONE                              = 0
   688  	GZ_READ                              = 7247
   689  	GZ_WRITE                             = 31153
   690  	HAVE_VSNPRINTF                       = 0
   691  	LOCK_EX                              = 0x02
   692  	LOCK_NB                              = 0x04
   693  	LOCK_SH                              = 0x01
   694  	LOCK_UN                              = 0x08
   695  	LOOK                                 = 0
   696  	L_ctermid                            = 1024
   697  	L_tmpnam                             = 1024
   698  	O_ACCMODE                            = 0x0003
   699  	O_APPEND                             = 0x0008
   700  	O_ASYNC                              = 0x0040
   701  	O_CLOEXEC                            = 0x10000
   702  	O_CREAT                              = 0x0200
   703  	O_DIRECTORY                          = 0x20000
   704  	O_DSYNC                              = 128
   705  	O_EXCL                               = 0x0800
   706  	O_EXLOCK                             = 0x0020
   707  	O_FSYNC                              = 0x0080
   708  	O_NDELAY                             = 4
   709  	O_NOCTTY                             = 0x8000
   710  	O_NOFOLLOW                           = 0x0100
   711  	O_NONBLOCK                           = 0x0004
   712  	O_RDONLY                             = 0x0000
   713  	O_RDWR                               = 0x0002
   714  	O_RSYNC                              = 128
   715  	O_SHLOCK                             = 0x0010
   716  	O_SYNC                               = 0x0080
   717  	O_TRUNC                              = 0x0400
   718  	O_WRONLY                             = 0x0001
   719  	P_tmpdir                             = "/tmp/"
   720  	TMP_MAX                              = 0x7fffffff
   721  	X_ERRNO_H_                           = 0
   722  	X_FSTDIO                             = 0
   723  	X_IOFBF                              = 0
   724  	X_IOLBF                              = 1
   725  	X_IONBF                              = 2
   726  	X_POSIX_SOURCE                       = 0
   727  	X_STDIO_H_                           = 0
   728  	X_SYS_FCNTL_H_                       = 0
   729  	ENOUGH                               = 1444
   730  	ENOUGH_DISTS                         = 592
   731  	ENOUGH_LENS                          = 852
   732  	GUNZIP                               = 0
   733  	MAXBITS                              = 15
   734  	DIST_CODE_LEN                        = 512
   735  	END_BLOCK                            = 256
   736  	MAX_BL_BITS                          = 7
   737  	REPZ_11_138                          = 18
   738  	REPZ_3_10                            = 17
   739  	REP_3_6                              = 16
   740  	SMALLEST                             = 1
   741  )
   742  
   743  //
   744  //   If you use the zlib library in a product, an acknowledgment is welcome
   745  //   in the documentation of your product. If for some reason you cannot
   746  //   include such an acknowledgment, I would appreciate that you keep this
   747  //   copyright string in the executable of your product.
   748  //
   749  
   750  // ===========================================================================
   751  //  Function prototypes.
   752  const ( /* deflate.c:66:1: */
   753  	Need_more      = 0 // block not completed, need more input or more output
   754  	Block_done     = 1 // block flush performed
   755  	Finish_started = 2 // finish started, need only more output at next deflate
   756  	Finish_done    = 3
   757  )
   758  
   759  // inflate.h -- internal inflate state definition
   760  // Copyright (C) 1995-2016 Mark Adler
   761  // For conditions of distribution and use, see copyright notice in zlib.h
   762  
   763  // WARNING: this file should *not* be used by applications. It is
   764  //    part of the implementation of the compression library and is
   765  //    subject to change. Applications should only use zlib.h.
   766  //
   767  
   768  // define NO_GZIP when compiling if you want to disable gzip header and
   769  //    trailer decoding by inflate().  NO_GZIP would be used to avoid linking in
   770  //    the crc code when it is not needed.  For shared libraries, gzip decoding
   771  //    should be left enabled.
   772  
   773  // Possible inflate modes between inflate() calls
   774  const ( /* inflate.h:20:1: */
   775  	HEAD     = 16180 // i: waiting for magic header
   776  	FLAGS    = 16181 // i: waiting for method and flags (gzip)
   777  	TIME     = 16182 // i: waiting for modification time (gzip)
   778  	OS       = 16183 // i: waiting for extra flags and operating system (gzip)
   779  	EXLEN    = 16184 // i: waiting for extra length (gzip)
   780  	EXTRA    = 16185 // i: waiting for extra bytes (gzip)
   781  	NAME     = 16186 // i: waiting for end of file name (gzip)
   782  	COMMENT  = 16187 // i: waiting for end of comment (gzip)
   783  	HCRC     = 16188 // i: waiting for header crc (gzip)
   784  	DICTID   = 16189 // i: waiting for dictionary check value
   785  	DICT     = 16190 // waiting for inflateSetDictionary() call
   786  	TYPE     = 16191 // i: waiting for type bits, including last-flag bit
   787  	TYPEDO   = 16192 // i: same, but skip check to exit inflate on new block
   788  	STORED   = 16193 // i: waiting for stored size (length and complement)
   789  	COPY_    = 16194 // i/o: same as COPY below, but only first time in
   790  	COPY     = 16195 // i/o: waiting for input or output to copy stored block
   791  	TABLE    = 16196 // i: waiting for dynamic block table lengths
   792  	LENLENS  = 16197 // i: waiting for code length code lengths
   793  	CODELENS = 16198 // i: waiting for length/lit and distance code lengths
   794  	LEN_     = 16199 // i: same as LEN below, but only first time in
   795  	LEN      = 16200 // i: waiting for length/lit/eob code
   796  	LENEXT   = 16201 // i: waiting for length extra bits
   797  	DIST     = 16202 // i: waiting for distance code
   798  	DISTEXT  = 16203 // i: waiting for distance extra bits
   799  	MATCH    = 16204 // o: waiting for output space to copy string
   800  	LIT      = 16205 // o: waiting for output space to write literal
   801  	CHECK    = 16206 // i: waiting for 32-bit check value
   802  	LENGTH   = 16207 // i: waiting for 32-bit length (gzip)
   803  	DONE     = 16208 // finished check, done -- remain here until reset
   804  	BAD      = 16209 // got a data error -- remain here until reset
   805  	MEM      = 16210 // got an inflate() memory error -- remain here until reset
   806  	SYNC     = 16211
   807  )
   808  
   809  // op values as set by inflate_table():
   810  //     00000000 - literal
   811  //     0000tttt - table link, tttt != 0 is the number of table index bits
   812  //     0001eeee - length or distance, eeee is the number of extra bits
   813  //     01100000 - end of block
   814  //     01000000 - invalid code
   815  //
   816  
   817  // Maximum size of the dynamic table.  The maximum number of code structures is
   818  //    1444, which is the sum of 852 for literal/length codes and 592 for distance
   819  //    codes.  These values were found by exhaustive searches using the program
   820  //    examples/enough.c found in the zlib distribtution.  The arguments to that
   821  //    program are the number of symbols, the initial root table size, and the
   822  //    maximum bit length of a code.  "enough 286 9 15" for literal/length codes
   823  //    returns returns 852, and "enough 30 6 15" for distance codes returns 592.
   824  //    The initial root table size (9 or 6) is found in the fifth argument of the
   825  //    inflate_table() calls in inflate.c and infback.c.  If the root table size is
   826  //    changed, then these maximum sizes would be need to be recalculated and
   827  //    updated.
   828  
   829  // Type of code to build for inflate_table()
   830  const ( /* inftrees.h:54:1: */
   831  	CODES = 0
   832  	LENS  = 1
   833  	DISTS = 2
   834  )
   835  
   836  type Ptrdiff_t = int64 /* <builtin>:3:26 */
   837  
   838  type Size_t = uint64 /* <builtin>:9:23 */
   839  
   840  type Wchar_t = int32 /* <builtin>:15:24 */
   841  
   842  type X__int128_t = struct {
   843  	Flo int64
   844  	Fhi int64
   845  } /* <builtin>:21:43 */ // must match modernc.org/mathutil.Int128
   846  type X__uint128_t = struct {
   847  	Flo uint64
   848  	Fhi uint64
   849  } /* <builtin>:22:44 */ // must match modernc.org/mathutil.Int128
   850  
   851  type X__builtin_va_list = uintptr /* <builtin>:46:14 */
   852  type X__float128 = float64        /* <builtin>:47:21 */
   853  
   854  // adler32.c -- compute the Adler-32 checksum of a data stream
   855  // Copyright (C) 1995-2011, 2016 Mark Adler
   856  // For conditions of distribution and use, see copyright notice in zlib.h
   857  
   858  // @(#) $Id$
   859  
   860  // zutil.h -- internal interface and configuration of the compression library
   861  // Copyright (C) 1995-2016 Jean-loup Gailly, Mark Adler
   862  // For conditions of distribution and use, see copyright notice in zlib.h
   863  
   864  // WARNING: this file should *not* be used by applications. It is
   865  //    part of the implementation of the compression library and is
   866  //    subject to change. Applications should only use zlib.h.
   867  //
   868  
   869  // @(#) $Id$
   870  
   871  // zlib.h -- interface of the 'zlib' general purpose compression library
   872  //   version 1.2.11, January 15th, 2017
   873  //
   874  //   Copyright (C) 1995-2017 Jean-loup Gailly and Mark Adler
   875  //
   876  //   This software is provided 'as-is', without any express or implied
   877  //   warranty.  In no event will the authors be held liable for any damages
   878  //   arising from the use of this software.
   879  //
   880  //   Permission is granted to anyone to use this software for any purpose,
   881  //   including commercial applications, and to alter it and redistribute it
   882  //   freely, subject to the following restrictions:
   883  //
   884  //   1. The origin of this software must not be misrepresented; you must not
   885  //      claim that you wrote the original software. If you use this software
   886  //      in a product, an acknowledgment in the product documentation would be
   887  //      appreciated but is not required.
   888  //   2. Altered source versions must be plainly marked as such, and must not be
   889  //      misrepresented as being the original software.
   890  //   3. This notice may not be removed or altered from any source distribution.
   891  //
   892  //   Jean-loup Gailly        Mark Adler
   893  //   jloup@gzip.org          madler@alumni.caltech.edu
   894  //
   895  //
   896  //   The data format used by the zlib library is described by RFCs (Request for
   897  //   Comments) 1950 to 1952 in the files http://tools.ietf.org/html/rfc1950
   898  //   (zlib format), rfc1951 (deflate format) and rfc1952 (gzip format).
   899  
   900  // zconf.h -- configuration of the zlib compression library
   901  // Copyright (C) 1995-2016 Jean-loup Gailly, Mark Adler
   902  // For conditions of distribution and use, see copyright notice in zlib.h
   903  
   904  // @(#) $Id$
   905  
   906  // If you *really* need a unique prefix for all types and library functions,
   907  // compile with -DZ_PREFIX. The "standard" zlib should be compiled without it.
   908  // Even better than compiling with -DZ_PREFIX would be to use configure to set
   909  // this permanently in zconf.h using "./configure --zprefix".
   910  
   911  // Compile with -DMAXSEG_64K if the alloc function cannot allocate more
   912  // than 64k bytes at a time (needed on systems with 16-bit int).
   913  
   914  //	$OpenBSD: stddef.h,v 1.14 2017/01/06 14:36:50 kettenis Exp $
   915  //	$NetBSD: stddef.h,v 1.4 1994/10/26 00:56:26 cgd Exp $
   916  
   917  // -
   918  // Copyright (c) 1990 The Regents of the University of California.
   919  // All rights reserved.
   920  //
   921  // Redistribution and use in source and binary forms, with or without
   922  // modification, are permitted provided that the following conditions
   923  // are met:
   924  // 1. Redistributions of source code must retain the above copyright
   925  //    notice, this list of conditions and the following disclaimer.
   926  // 2. Redistributions in binary form must reproduce the above copyright
   927  //    notice, this list of conditions and the following disclaimer in the
   928  //    documentation and/or other materials provided with the distribution.
   929  // 3. Neither the name of the University nor the names of its contributors
   930  //    may be used to endorse or promote products derived from this software
   931  //    without specific prior written permission.
   932  //
   933  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
   934  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
   935  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
   936  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
   937  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
   938  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
   939  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
   940  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
   941  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
   942  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
   943  // SUCH DAMAGE.
   944  //
   945  //	@(#)stddef.h	5.5 (Berkeley) 4/3/91
   946  
   947  //	$OpenBSD: cdefs.h,v 1.43 2018/10/29 17:10:40 guenther Exp $
   948  //	$NetBSD: cdefs.h,v 1.16 1996/04/03 20:46:39 christos Exp $
   949  
   950  // Copyright (c) 1991, 1993
   951  //	The Regents of the University of California.  All rights reserved.
   952  //
   953  // This code is derived from software contributed to Berkeley by
   954  // Berkeley Software Design, Inc.
   955  //
   956  // Redistribution and use in source and binary forms, with or without
   957  // modification, are permitted provided that the following conditions
   958  // are met:
   959  // 1. Redistributions of source code must retain the above copyright
   960  //    notice, this list of conditions and the following disclaimer.
   961  // 2. Redistributions in binary form must reproduce the above copyright
   962  //    notice, this list of conditions and the following disclaimer in the
   963  //    documentation and/or other materials provided with the distribution.
   964  // 3. Neither the name of the University nor the names of its contributors
   965  //    may be used to endorse or promote products derived from this software
   966  //    without specific prior written permission.
   967  //
   968  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
   969  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
   970  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
   971  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
   972  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
   973  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
   974  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
   975  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
   976  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
   977  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
   978  // SUCH DAMAGE.
   979  //
   980  //	@(#)cdefs.h	8.7 (Berkeley) 1/21/94
   981  
   982  //	$OpenBSD: cdefs.h,v 1.3 2013/03/28 17:30:45 martynas Exp $
   983  
   984  // Written by J.T. Conklin <jtc@wimsey.com> 01/17/95.
   985  // Public domain.
   986  
   987  // Macro to test if we're using a specific version of gcc or later.
   988  
   989  // The __CONCAT macro is used to concatenate parts of symbol names, e.g.
   990  // with "#define OLD(foo) __CONCAT(old,foo)", OLD(foo) produces oldfoo.
   991  // The __CONCAT macro is a bit tricky -- make sure you don't put spaces
   992  // in between its arguments.  Do not use __CONCAT on double-quoted strings,
   993  // such as those from the __STRING macro: to concatenate strings just put
   994  // them next to each other.
   995  
   996  // GCC1 and some versions of GCC2 declare dead (non-returning) and
   997  // pure (no side effects) functions using "volatile" and "const";
   998  // unfortunately, these then cause warnings under "-ansi -pedantic".
   999  // GCC >= 2.5 uses the __attribute__((attrs)) style.  All of these
  1000  // work for GNU C++ (modulo a slight glitch in the C++ grammar in
  1001  // the distribution version of 2.5.5).
  1002  
  1003  // __returns_twice makes the compiler not assume the function
  1004  // only returns once.  This affects registerisation of variables:
  1005  // even local variables need to be in memory across such a call.
  1006  // Example: setjmp()
  1007  
  1008  // __only_inline makes the compiler only use this function definition
  1009  // for inlining; references that can't be inlined will be left as
  1010  // external references instead of generating a local copy.  The
  1011  // matching library should include a simple extern definition for
  1012  // the function to handle those references.  c.f. ctype.h
  1013  
  1014  // GNU C version 2.96 adds explicit branch prediction so that
  1015  // the CPU back-end can hint the processor and also so that
  1016  // code blocks can be reordered such that the predicted path
  1017  // sees a more linear flow, thus improving cache behavior, etc.
  1018  //
  1019  // The following two macros provide us with a way to utilize this
  1020  // compiler feature.  Use __predict_true() if you expect the expression
  1021  // to evaluate to true, and __predict_false() if you expect the
  1022  // expression to evaluate to false.
  1023  //
  1024  // A few notes about usage:
  1025  //
  1026  //	* Generally, __predict_false() error condition checks (unless
  1027  //	  you have some _strong_ reason to do otherwise, in which case
  1028  //	  document it), and/or __predict_true() `no-error' condition
  1029  //	  checks, assuming you want to optimize for the no-error case.
  1030  //
  1031  //	* Other than that, if you don't know the likelihood of a test
  1032  //	  succeeding from empirical or other `hard' evidence, don't
  1033  //	  make predictions.
  1034  //
  1035  //	* These are meant to be used in places that are run `a lot'.
  1036  //	  It is wasteful to make predictions in code that is run
  1037  //	  seldomly (e.g. at subsystem initialization time) as the
  1038  //	  basic block reordering that this affects can often generate
  1039  //	  larger code.
  1040  
  1041  // Delete pseudo-keywords wherever they are not available or needed.
  1042  
  1043  // The __packed macro indicates that a variable or structure members
  1044  // should have the smallest possible alignment, despite any host CPU
  1045  // alignment requirements.
  1046  //
  1047  // The __aligned(x) macro specifies the minimum alignment of a
  1048  // variable or structure.
  1049  //
  1050  // These macros together are useful for describing the layout and
  1051  // alignment of messages exchanged with hardware or other systems.
  1052  
  1053  // "The nice thing about standards is that there are so many to choose from."
  1054  // There are a number of "feature test macros" specified by (different)
  1055  // standards that determine which interfaces and types the header files
  1056  // should expose.
  1057  //
  1058  // Because of inconsistencies in these macros, we define our own
  1059  // set in the private name space that end in _VISIBLE.  These are
  1060  // always defined and so headers can test their values easily.
  1061  // Things can get tricky when multiple feature macros are defined.
  1062  // We try to take the union of all the features requested.
  1063  //
  1064  // The following macros are guaranteed to have a value after cdefs.h
  1065  // has been included:
  1066  //	__POSIX_VISIBLE
  1067  //	__XPG_VISIBLE
  1068  //	__ISO_C_VISIBLE
  1069  //	__BSD_VISIBLE
  1070  
  1071  // X/Open Portability Guides and Single Unix Specifications.
  1072  // _XOPEN_SOURCE				XPG3
  1073  // _XOPEN_SOURCE && _XOPEN_VERSION = 4		XPG4
  1074  // _XOPEN_SOURCE && _XOPEN_SOURCE_EXTENDED = 1	XPG4v2
  1075  // _XOPEN_SOURCE == 500				XPG5
  1076  // _XOPEN_SOURCE == 520				XPG5v2
  1077  // _XOPEN_SOURCE == 600				POSIX 1003.1-2001 with XSI
  1078  // _XOPEN_SOURCE == 700				POSIX 1003.1-2008 with XSI
  1079  //
  1080  // The XPG spec implies a specific value for _POSIX_C_SOURCE.
  1081  
  1082  // POSIX macros, these checks must follow the XOPEN ones above.
  1083  //
  1084  // _POSIX_SOURCE == 1		1003.1-1988 (superseded by _POSIX_C_SOURCE)
  1085  // _POSIX_C_SOURCE == 1		1003.1-1990
  1086  // _POSIX_C_SOURCE == 2		1003.2-1992
  1087  // _POSIX_C_SOURCE == 199309L	1003.1b-1993
  1088  // _POSIX_C_SOURCE == 199506L   1003.1c-1995, 1003.1i-1995,
  1089  //				and the omnibus ISO/IEC 9945-1:1996
  1090  // _POSIX_C_SOURCE == 200112L   1003.1-2001
  1091  // _POSIX_C_SOURCE == 200809L   1003.1-2008
  1092  //
  1093  // The POSIX spec implies a specific value for __ISO_C_VISIBLE, though
  1094  // this may be overridden by the _ISOC99_SOURCE macro later.
  1095  
  1096  // _ANSI_SOURCE means to expose ANSI C89 interfaces only.
  1097  // If the user defines it in addition to one of the POSIX or XOPEN
  1098  // macros, assume the POSIX/XOPEN macro(s) should take precedence.
  1099  
  1100  // _ISOC99_SOURCE, _ISOC11_SOURCE, __STDC_VERSION__, and __cplusplus
  1101  // override any of the other macros since they are non-exclusive.
  1102  
  1103  // Finally deal with BSD-specific interfaces that are not covered
  1104  // by any standards.  We expose these when none of the POSIX or XPG
  1105  // macros is defined or if the user explicitly asks for them.
  1106  
  1107  // Default values.
  1108  
  1109  //	$OpenBSD: _null.h,v 1.2 2016/09/09 22:07:58 millert Exp $
  1110  
  1111  // Written by Todd C. Miller, September 9, 2016
  1112  // Public domain.
  1113  
  1114  //	$OpenBSD: _types.h,v 1.9 2014/08/22 23:05:15 krw Exp $
  1115  
  1116  // -
  1117  // Copyright (c) 1990, 1993
  1118  //	The Regents of the University of California.  All rights reserved.
  1119  //
  1120  // Redistribution and use in source and binary forms, with or without
  1121  // modification, are permitted provided that the following conditions
  1122  // are met:
  1123  // 1. Redistributions of source code must retain the above copyright
  1124  //    notice, this list of conditions and the following disclaimer.
  1125  // 2. Redistributions in binary form must reproduce the above copyright
  1126  //    notice, this list of conditions and the following disclaimer in the
  1127  //    documentation and/or other materials provided with the distribution.
  1128  // 3. Neither the name of the University nor the names of its contributors
  1129  //    may be used to endorse or promote products derived from this software
  1130  //    without specific prior written permission.
  1131  //
  1132  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1133  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1134  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1135  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1136  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1137  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1138  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1139  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1140  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1141  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1142  // SUCH DAMAGE.
  1143  //
  1144  //	@(#)types.h	8.3 (Berkeley) 1/5/94
  1145  
  1146  //	$OpenBSD: _types.h,v 1.17 2018/03/05 01:15:25 deraadt Exp $
  1147  
  1148  // -
  1149  // Copyright (c) 1990, 1993
  1150  //	The Regents of the University of California.  All rights reserved.
  1151  //
  1152  // Redistribution and use in source and binary forms, with or without
  1153  // modification, are permitted provided that the following conditions
  1154  // are met:
  1155  // 1. Redistributions of source code must retain the above copyright
  1156  //    notice, this list of conditions and the following disclaimer.
  1157  // 2. Redistributions in binary form must reproduce the above copyright
  1158  //    notice, this list of conditions and the following disclaimer in the
  1159  //    documentation and/or other materials provided with the distribution.
  1160  // 3. Neither the name of the University nor the names of its contributors
  1161  //    may be used to endorse or promote products derived from this software
  1162  //    without specific prior written permission.
  1163  //
  1164  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1165  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1166  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1167  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1168  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1169  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1170  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1171  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1172  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1173  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1174  // SUCH DAMAGE.
  1175  //
  1176  //	@(#)types.h	8.3 (Berkeley) 1/5/94
  1177  //	@(#)ansi.h	8.2 (Berkeley) 1/4/94
  1178  
  1179  // _ALIGN(p) rounds p (pointer or byte index) up to a correctly-aligned
  1180  // value for all data types (int, long, ...).   The result is an
  1181  // unsigned long and must be cast to any desired pointer type.
  1182  //
  1183  // _ALIGNED_POINTER is a boolean macro that checks whether an address
  1184  // is valid to fetch data elements of type t from on this architecture.
  1185  // This does not reflect the optimal alignment, just the possibility
  1186  // (within reasonable limits).
  1187  
  1188  // 7.18.1.1 Exact-width integer types
  1189  type X__int8_t = int8     /* _types.h:61:22 */
  1190  type X__uint8_t = uint8   /* _types.h:62:24 */
  1191  type X__int16_t = int16   /* _types.h:63:17 */
  1192  type X__uint16_t = uint16 /* _types.h:64:25 */
  1193  type X__int32_t = int32   /* _types.h:65:15 */
  1194  type X__uint32_t = uint32 /* _types.h:66:23 */
  1195  type X__int64_t = int64   /* _types.h:67:20 */
  1196  type X__uint64_t = uint64 /* _types.h:68:28 */
  1197  
  1198  // 7.18.1.2 Minimum-width integer types
  1199  type X__int_least8_t = X__int8_t     /* _types.h:71:19 */
  1200  type X__uint_least8_t = X__uint8_t   /* _types.h:72:20 */
  1201  type X__int_least16_t = X__int16_t   /* _types.h:73:20 */
  1202  type X__uint_least16_t = X__uint16_t /* _types.h:74:21 */
  1203  type X__int_least32_t = X__int32_t   /* _types.h:75:20 */
  1204  type X__uint_least32_t = X__uint32_t /* _types.h:76:21 */
  1205  type X__int_least64_t = X__int64_t   /* _types.h:77:20 */
  1206  type X__uint_least64_t = X__uint64_t /* _types.h:78:21 */
  1207  
  1208  // 7.18.1.3 Fastest minimum-width integer types
  1209  type X__int_fast8_t = X__int32_t    /* _types.h:81:20 */
  1210  type X__uint_fast8_t = X__uint32_t  /* _types.h:82:21 */
  1211  type X__int_fast16_t = X__int32_t   /* _types.h:83:20 */
  1212  type X__uint_fast16_t = X__uint32_t /* _types.h:84:21 */
  1213  type X__int_fast32_t = X__int32_t   /* _types.h:85:20 */
  1214  type X__uint_fast32_t = X__uint32_t /* _types.h:86:21 */
  1215  type X__int_fast64_t = X__int64_t   /* _types.h:87:20 */
  1216  type X__uint_fast64_t = X__uint64_t /* _types.h:88:21 */
  1217  
  1218  // 7.18.1.4 Integer types capable of holding object pointers
  1219  type X__intptr_t = int64   /* _types.h:103:16 */
  1220  type X__uintptr_t = uint64 /* _types.h:104:24 */
  1221  
  1222  // 7.18.1.5 Greatest-width integer types
  1223  type X__intmax_t = X__int64_t   /* _types.h:107:20 */
  1224  type X__uintmax_t = X__uint64_t /* _types.h:108:21 */
  1225  
  1226  // Register size
  1227  type X__register_t = int64 /* _types.h:111:16 */
  1228  
  1229  // VM system types
  1230  type X__vaddr_t = uint64 /* _types.h:114:24 */
  1231  type X__paddr_t = uint64 /* _types.h:115:24 */
  1232  type X__vsize_t = uint64 /* _types.h:116:24 */
  1233  type X__psize_t = uint64 /* _types.h:117:24 */
  1234  
  1235  // Standard system types
  1236  type X__double_t = float64           /* _types.h:120:18 */
  1237  type X__float_t = float32            /* _types.h:121:17 */
  1238  type X__ptrdiff_t = int64            /* _types.h:122:16 */
  1239  type X__size_t = uint64              /* _types.h:123:24 */
  1240  type X__ssize_t = int64              /* _types.h:124:16 */
  1241  type X__va_list = X__builtin_va_list /* _types.h:126:27 */
  1242  
  1243  // Wide character support types
  1244  type X__wchar_t = int32     /* _types.h:133:15 */
  1245  type X__wint_t = int32      /* _types.h:135:15 */
  1246  type X__rune_t = int32      /* _types.h:136:15 */
  1247  type X__wctrans_t = uintptr /* _types.h:137:14 */
  1248  type X__wctype_t = uintptr  /* _types.h:138:14 */
  1249  
  1250  type X__blkcnt_t = X__int64_t    /* _types.h:39:19 */ // blocks allocated for file
  1251  type X__blksize_t = X__int32_t   /* _types.h:40:19 */ // optimal blocksize for I/O
  1252  type X__clock_t = X__int64_t     /* _types.h:41:19 */ // ticks in CLOCKS_PER_SEC
  1253  type X__clockid_t = X__int32_t   /* _types.h:42:19 */ // CLOCK_* identifiers
  1254  type X__cpuid_t = uint64         /* _types.h:43:23 */ // CPU id
  1255  type X__dev_t = X__int32_t       /* _types.h:44:19 */ // device number
  1256  type X__fixpt_t = X__uint32_t    /* _types.h:45:20 */ // fixed point number
  1257  type X__fsblkcnt_t = X__uint64_t /* _types.h:46:20 */ // file system block count
  1258  type X__fsfilcnt_t = X__uint64_t /* _types.h:47:20 */ // file system file count
  1259  type X__gid_t = X__uint32_t      /* _types.h:48:20 */ // group id
  1260  type X__id_t = X__uint32_t       /* _types.h:49:20 */ // may contain pid, uid or gid
  1261  type X__in_addr_t = X__uint32_t  /* _types.h:50:20 */ // base type for internet address
  1262  type X__in_port_t = X__uint16_t  /* _types.h:51:20 */ // IP port type
  1263  type X__ino_t = X__uint64_t      /* _types.h:52:20 */ // inode number
  1264  type X__key_t = int64            /* _types.h:53:15 */ // IPC key (for Sys V IPC)
  1265  type X__mode_t = X__uint32_t     /* _types.h:54:20 */ // permissions
  1266  type X__nlink_t = X__uint32_t    /* _types.h:55:20 */ // link count
  1267  type X__off_t = X__int64_t       /* _types.h:56:19 */ // file offset or size
  1268  type X__pid_t = X__int32_t       /* _types.h:57:19 */ // process id
  1269  type X__rlim_t = X__uint64_t     /* _types.h:58:20 */ // resource limit
  1270  type X__sa_family_t = X__uint8_t /* _types.h:59:19 */ // sockaddr address family type
  1271  type X__segsz_t = X__int32_t     /* _types.h:60:19 */ // segment size
  1272  type X__socklen_t = X__uint32_t  /* _types.h:61:20 */ // length type for network syscalls
  1273  type X__suseconds_t = int64      /* _types.h:62:15 */ // microseconds (signed)
  1274  type X__swblk_t = X__int32_t     /* _types.h:63:19 */ // swap offset
  1275  type X__time_t = X__int64_t      /* _types.h:64:19 */ // epoch time
  1276  type X__timer_t = X__int32_t     /* _types.h:65:19 */ // POSIX timer identifiers
  1277  type X__uid_t = X__uint32_t      /* _types.h:66:20 */ // user id
  1278  type X__useconds_t = X__uint32_t /* _types.h:67:20 */ // microseconds
  1279  
  1280  // mbstate_t is an opaque object to keep conversion state, during multibyte
  1281  // stream conversions. The content must not be referenced by user programs.
  1282  type X__mbstate_t = struct {
  1283  	F__ccgo_pad1 [0]uint64
  1284  	F__mbstate8  [128]int8
  1285  } /* _types.h:76:3 */
  1286  
  1287  type Wint_t = X__wint_t /* stddef.h:60:18 */
  1288  
  1289  type Mbstate_t = X__mbstate_t /* stddef.h:65:21 */
  1290  
  1291  type Max_align_t = struct {
  1292  	F__max_align_ll int64
  1293  	F__max_align_ld float64
  1294  } /* stddef.h:80:3 */
  1295  
  1296  type Z_size_t = Size_t /* zconf.h:248:21 */
  1297  
  1298  // Maximum value for memLevel in deflateInit2
  1299  
  1300  // Maximum value for windowBits in deflateInit2 and inflateInit2.
  1301  // WARNING: reducing MAX_WBITS makes minigzip unable to extract .gz files
  1302  // created by gzip. (Files created by minigzip can still be extracted by
  1303  // gzip.)
  1304  
  1305  // The memory requirements for deflate are (in bytes):
  1306  //             (1 << (windowBits+2)) +  (1 << (memLevel+9))
  1307  //  that is: 128K for windowBits=15  +  128K for memLevel = 8  (default values)
  1308  //  plus a few kilobytes for small objects. For example, if you want to reduce
  1309  //  the default memory requirements from 256K to 128K, compile with
  1310  //      make CFLAGS="-O -DMAX_WBITS=14 -DMAX_MEM_LEVEL=7"
  1311  //  Of course this will generally degrade compression (there's no free lunch).
  1312  //
  1313  //    The memory requirements for inflate are (in bytes) 1 << windowBits
  1314  //  that is, 32K for windowBits=15 (default value) plus about 7 kilobytes
  1315  //  for small objects.
  1316  
  1317  // Type declarations
  1318  
  1319  // The following definitions for FAR are needed only for MSDOS mixed
  1320  // model programming (small or medium model with some far allocations).
  1321  // This was tested only with MSC; for other MSDOS compilers you may have
  1322  // to define NO_MEMCPY in zutil.h.  If you don't need the mixed model,
  1323  // just define FAR to be empty.
  1324  
  1325  type Byte = uint8   /* zconf.h:391:24 */ // 8 bits
  1326  type UInt = uint32  /* zconf.h:393:24 */ // 16 bits or more
  1327  type ULong = uint64 /* zconf.h:394:24 */ // 32 bits or more
  1328  
  1329  type Bytef = Byte   /* zconf.h:400:22 */
  1330  type Charf = int8   /* zconf.h:402:19 */
  1331  type Intf = int32   /* zconf.h:403:19 */
  1332  type UIntf = UInt   /* zconf.h:404:19 */
  1333  type ULongf = ULong /* zconf.h:405:19 */
  1334  
  1335  type Voidpc = uintptr /* zconf.h:408:23 */
  1336  type Voidpf = uintptr /* zconf.h:409:23 */
  1337  type Voidp = uintptr  /* zconf.h:410:23 */
  1338  
  1339  //	$OpenBSD: limits.h,v 1.19 2015/01/20 22:09:50 tedu Exp $
  1340  //	$NetBSD: limits.h,v 1.7 1994/10/26 00:56:00 cgd Exp $
  1341  
  1342  // Copyright (c) 1988 The Regents of the University of California.
  1343  // All rights reserved.
  1344  //
  1345  // Redistribution and use in source and binary forms, with or without
  1346  // modification, are permitted provided that the following conditions
  1347  // are met:
  1348  // 1. Redistributions of source code must retain the above copyright
  1349  //    notice, this list of conditions and the following disclaimer.
  1350  // 2. Redistributions in binary form must reproduce the above copyright
  1351  //    notice, this list of conditions and the following disclaimer in the
  1352  //    documentation and/or other materials provided with the distribution.
  1353  // 3. Neither the name of the University nor the names of its contributors
  1354  //    may be used to endorse or promote products derived from this software
  1355  //    without specific prior written permission.
  1356  //
  1357  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1358  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1359  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1360  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1361  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1362  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1363  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1364  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1365  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1366  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1367  // SUCH DAMAGE.
  1368  //
  1369  //	@(#)limits.h	5.9 (Berkeley) 4/3/91
  1370  
  1371  //	$OpenBSD: cdefs.h,v 1.43 2018/10/29 17:10:40 guenther Exp $
  1372  //	$NetBSD: cdefs.h,v 1.16 1996/04/03 20:46:39 christos Exp $
  1373  
  1374  // Copyright (c) 1991, 1993
  1375  //	The Regents of the University of California.  All rights reserved.
  1376  //
  1377  // This code is derived from software contributed to Berkeley by
  1378  // Berkeley Software Design, Inc.
  1379  //
  1380  // Redistribution and use in source and binary forms, with or without
  1381  // modification, are permitted provided that the following conditions
  1382  // are met:
  1383  // 1. Redistributions of source code must retain the above copyright
  1384  //    notice, this list of conditions and the following disclaimer.
  1385  // 2. Redistributions in binary form must reproduce the above copyright
  1386  //    notice, this list of conditions and the following disclaimer in the
  1387  //    documentation and/or other materials provided with the distribution.
  1388  // 3. Neither the name of the University nor the names of its contributors
  1389  //    may be used to endorse or promote products derived from this software
  1390  //    without specific prior written permission.
  1391  //
  1392  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1393  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1394  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1395  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1396  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1397  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1398  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1399  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1400  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1401  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1402  // SUCH DAMAGE.
  1403  //
  1404  //	@(#)cdefs.h	8.7 (Berkeley) 1/21/94
  1405  
  1406  // $OpenBSD: limits.h,v 1.10 2012/06/30 20:21:10 guenther Exp $
  1407  // Copyright (c) 2002 Marc Espie.
  1408  //
  1409  // Redistribution and use in source and binary forms, with or without
  1410  // modification, are permitted provided that the following conditions
  1411  // are met:
  1412  // 1. Redistributions of source code must retain the above copyright
  1413  //    notice, this list of conditions and the following disclaimer.
  1414  // 2. Redistributions in binary form must reproduce the above copyright
  1415  //    notice, this list of conditions and the following disclaimer in the
  1416  //    documentation and/or other materials provided with the distribution.
  1417  //
  1418  // THIS SOFTWARE IS PROVIDED BY THE OPENBSD PROJECT AND CONTRIBUTORS
  1419  // ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
  1420  // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
  1421  // A PARTICULAR PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE OPENBSD
  1422  // PROJECT OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  1423  // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  1424  // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
  1425  // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
  1426  // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  1427  // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
  1428  // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  1429  
  1430  //	$OpenBSD: cdefs.h,v 1.43 2018/10/29 17:10:40 guenther Exp $
  1431  //	$NetBSD: cdefs.h,v 1.16 1996/04/03 20:46:39 christos Exp $
  1432  
  1433  // Copyright (c) 1991, 1993
  1434  //	The Regents of the University of California.  All rights reserved.
  1435  //
  1436  // This code is derived from software contributed to Berkeley by
  1437  // Berkeley Software Design, Inc.
  1438  //
  1439  // Redistribution and use in source and binary forms, with or without
  1440  // modification, are permitted provided that the following conditions
  1441  // are met:
  1442  // 1. Redistributions of source code must retain the above copyright
  1443  //    notice, this list of conditions and the following disclaimer.
  1444  // 2. Redistributions in binary form must reproduce the above copyright
  1445  //    notice, this list of conditions and the following disclaimer in the
  1446  //    documentation and/or other materials provided with the distribution.
  1447  // 3. Neither the name of the University nor the names of its contributors
  1448  //    may be used to endorse or promote products derived from this software
  1449  //    without specific prior written permission.
  1450  //
  1451  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1452  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1453  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1454  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1455  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1456  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1457  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1458  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1459  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1460  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1461  // SUCH DAMAGE.
  1462  //
  1463  //	@(#)cdefs.h	8.7 (Berkeley) 1/21/94
  1464  
  1465  // Common definitions for limits.h.
  1466  
  1467  // Legacy
  1468  //	$OpenBSD: limits.h,v 1.6 2015/04/30 13:42:08 millert Exp $
  1469  
  1470  // Copyright (c) 1988 The Regents of the University of California.
  1471  // All rights reserved.
  1472  //
  1473  // Redistribution and use in source and binary forms, with or without
  1474  // modification, are permitted provided that the following conditions
  1475  // are met:
  1476  // 1. Redistributions of source code must retain the above copyright
  1477  //    notice, this list of conditions and the following disclaimer.
  1478  // 2. Redistributions in binary form must reproduce the above copyright
  1479  //    notice, this list of conditions and the following disclaimer in the
  1480  //    documentation and/or other materials provided with the distribution.
  1481  // 3. Neither the name of the University nor the names of its contributors
  1482  //    may be used to endorse or promote products derived from this software
  1483  //    without specific prior written permission.
  1484  //
  1485  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1486  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1487  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1488  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1489  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1490  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1491  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1492  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1493  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1494  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1495  // SUCH DAMAGE.
  1496  //
  1497  //	@(#)limits.h	7.2 (Berkeley) 6/28/90
  1498  
  1499  //	$OpenBSD: cdefs.h,v 1.43 2018/10/29 17:10:40 guenther Exp $
  1500  //	$NetBSD: cdefs.h,v 1.16 1996/04/03 20:46:39 christos Exp $
  1501  
  1502  // Copyright (c) 1991, 1993
  1503  //	The Regents of the University of California.  All rights reserved.
  1504  //
  1505  // This code is derived from software contributed to Berkeley by
  1506  // Berkeley Software Design, Inc.
  1507  //
  1508  // Redistribution and use in source and binary forms, with or without
  1509  // modification, are permitted provided that the following conditions
  1510  // are met:
  1511  // 1. Redistributions of source code must retain the above copyright
  1512  //    notice, this list of conditions and the following disclaimer.
  1513  // 2. Redistributions in binary form must reproduce the above copyright
  1514  //    notice, this list of conditions and the following disclaimer in the
  1515  //    documentation and/or other materials provided with the distribution.
  1516  // 3. Neither the name of the University nor the names of its contributors
  1517  //    may be used to endorse or promote products derived from this software
  1518  //    without specific prior written permission.
  1519  //
  1520  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1521  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1522  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1523  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1524  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1525  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1526  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1527  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1528  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1529  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1530  // SUCH DAMAGE.
  1531  //
  1532  //	@(#)cdefs.h	8.7 (Berkeley) 1/21/94
  1533  
  1534  // max value for unsigned long
  1535  // max value for a signed long
  1536  // min value for a signed long
  1537  
  1538  // max value for unsigned long long
  1539  // max value for a signed long long
  1540  // min value for a signed long long
  1541  
  1542  //	$OpenBSD: syslimits.h,v 1.14 2020/04/02 18:00:00 deraadt Exp $
  1543  //	$NetBSD: syslimits.h,v 1.12 1995/10/05 05:26:19 thorpej Exp $
  1544  
  1545  // Copyright (c) 1988, 1993
  1546  //	The Regents of the University of California.  All rights reserved.
  1547  //
  1548  // Redistribution and use in source and binary forms, with or without
  1549  // modification, are permitted provided that the following conditions
  1550  // are met:
  1551  // 1. Redistributions of source code must retain the above copyright
  1552  //    notice, this list of conditions and the following disclaimer.
  1553  // 2. Redistributions in binary form must reproduce the above copyright
  1554  //    notice, this list of conditions and the following disclaimer in the
  1555  //    documentation and/or other materials provided with the distribution.
  1556  // 3. Neither the name of the University nor the names of its contributors
  1557  //    may be used to endorse or promote products derived from this software
  1558  //    without specific prior written permission.
  1559  //
  1560  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1561  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1562  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1563  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1564  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1565  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1566  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1567  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1568  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1569  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1570  // SUCH DAMAGE.
  1571  //
  1572  //	@(#)syslimits.h	8.1 (Berkeley) 6/2/93
  1573  
  1574  //	$OpenBSD: cdefs.h,v 1.43 2018/10/29 17:10:40 guenther Exp $
  1575  //	$NetBSD: cdefs.h,v 1.16 1996/04/03 20:46:39 christos Exp $
  1576  
  1577  // Copyright (c) 1991, 1993
  1578  //	The Regents of the University of California.  All rights reserved.
  1579  //
  1580  // This code is derived from software contributed to Berkeley by
  1581  // Berkeley Software Design, Inc.
  1582  //
  1583  // Redistribution and use in source and binary forms, with or without
  1584  // modification, are permitted provided that the following conditions
  1585  // are met:
  1586  // 1. Redistributions of source code must retain the above copyright
  1587  //    notice, this list of conditions and the following disclaimer.
  1588  // 2. Redistributions in binary form must reproduce the above copyright
  1589  //    notice, this list of conditions and the following disclaimer in the
  1590  //    documentation and/or other materials provided with the distribution.
  1591  // 3. Neither the name of the University nor the names of its contributors
  1592  //    may be used to endorse or promote products derived from this software
  1593  //    without specific prior written permission.
  1594  //
  1595  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1596  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1597  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1598  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1599  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1600  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1601  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1602  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1603  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1604  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1605  // SUCH DAMAGE.
  1606  //
  1607  //	@(#)cdefs.h	8.7 (Berkeley) 1/21/94
  1608  
  1609  type Z_crc_t = uint32 /* zconf.h:429:17 */
  1610  
  1611  // Tell sys/endian.h we have MD variants of the swap macros.
  1612  
  1613  // Note that these macros evaluate their arguments several times.
  1614  
  1615  // Public names
  1616  
  1617  // These are specified to be function-like macros to match the spec
  1618  
  1619  // POSIX names
  1620  
  1621  // original BSD names
  1622  
  1623  // these were exposed here before
  1624  
  1625  // ancient stuff
  1626  
  1627  type U_char = uint8   /* types.h:51:23 */
  1628  type U_short = uint16 /* types.h:52:24 */
  1629  type U_int = uint32   /* types.h:53:22 */
  1630  type U_long = uint64  /* types.h:54:23 */
  1631  
  1632  type Unchar = uint8  /* types.h:56:23 */ // Sys V compatibility
  1633  type Ushort = uint16 /* types.h:57:24 */ // Sys V compatibility
  1634  type Uint = uint32   /* types.h:58:22 */ // Sys V compatibility
  1635  type Ulong = uint64  /* types.h:59:23 */ // Sys V compatibility
  1636  
  1637  type Cpuid_t = X__cpuid_t       /* types.h:61:19 */ // CPU id
  1638  type Register_t = X__register_t /* types.h:62:22 */ // register-sized type
  1639  
  1640  // XXX The exact-width bit types should only be exposed if __BSD_VISIBLE
  1641  //     but the rest of the includes are not ready for that yet.
  1642  
  1643  type Int8_t = X__int8_t /* types.h:75:19 */
  1644  
  1645  type Uint8_t = X__uint8_t /* types.h:80:20 */
  1646  
  1647  type Int16_t = X__int16_t /* types.h:85:20 */
  1648  
  1649  type Uint16_t = X__uint16_t /* types.h:90:21 */
  1650  
  1651  type Int32_t = X__int32_t /* types.h:95:20 */
  1652  
  1653  type Uint32_t = X__uint32_t /* types.h:100:21 */
  1654  
  1655  type Int64_t = X__int64_t /* types.h:105:20 */
  1656  
  1657  type Uint64_t = X__uint64_t /* types.h:110:21 */
  1658  
  1659  // BSD-style unsigned bits types
  1660  type U_int8_t = X__uint8_t   /* types.h:114:19 */
  1661  type U_int16_t = X__uint16_t /* types.h:115:20 */
  1662  type U_int32_t = X__uint32_t /* types.h:116:20 */
  1663  type U_int64_t = X__uint64_t /* types.h:117:20 */
  1664  
  1665  // quads, deprecated in favor of 64 bit int types
  1666  type Quad_t = X__int64_t    /* types.h:120:19 */
  1667  type U_quad_t = X__uint64_t /* types.h:121:20 */
  1668  
  1669  // VM system types
  1670  type Vaddr_t = X__vaddr_t /* types.h:125:19 */
  1671  type Paddr_t = X__paddr_t /* types.h:126:19 */
  1672  type Vsize_t = X__vsize_t /* types.h:127:19 */
  1673  type Psize_t = X__psize_t /* types.h:128:19 */
  1674  
  1675  // Standard system types
  1676  type Blkcnt_t = X__blkcnt_t       /* types.h:132:20 */ // blocks allocated for file
  1677  type Blksize_t = X__blksize_t     /* types.h:133:21 */ // optimal blocksize for I/O
  1678  type Caddr_t = uintptr            /* types.h:134:14 */ // core address
  1679  type Daddr32_t = X__int32_t       /* types.h:135:19 */ // 32-bit disk address
  1680  type Daddr_t = X__int64_t         /* types.h:136:19 */ // 64-bit disk address
  1681  type Dev_t = X__dev_t             /* types.h:137:18 */ // device number
  1682  type Fixpt_t = X__fixpt_t         /* types.h:138:19 */ // fixed point number
  1683  type Gid_t = X__gid_t             /* types.h:139:18 */ // group id
  1684  type Id_t = X__id_t               /* types.h:140:17 */ // may contain pid, uid or gid
  1685  type Ino_t = X__ino_t             /* types.h:141:18 */ // inode number
  1686  type Key_t = X__key_t             /* types.h:142:18 */ // IPC key (for Sys V IPC)
  1687  type Mode_t = X__mode_t           /* types.h:143:18 */ // permissions
  1688  type Nlink_t = X__nlink_t         /* types.h:144:19 */ // link count
  1689  type Rlim_t = X__rlim_t           /* types.h:145:18 */ // resource limit
  1690  type Segsz_t = X__segsz_t         /* types.h:146:19 */ // segment size
  1691  type Swblk_t = X__swblk_t         /* types.h:147:19 */ // swap offset
  1692  type Uid_t = X__uid_t             /* types.h:148:18 */ // user id
  1693  type Useconds_t = X__useconds_t   /* types.h:149:22 */ // microseconds
  1694  type Suseconds_t = X__suseconds_t /* types.h:150:23 */ // microseconds (signed)
  1695  type Fsblkcnt_t = X__fsblkcnt_t   /* types.h:151:22 */ // file system block count
  1696  type Fsfilcnt_t = X__fsfilcnt_t   /* types.h:152:22 */ // file system file count
  1697  
  1698  // The following types may be defined in multiple header files.
  1699  type Clock_t = X__clock_t /* types.h:159:19 */
  1700  
  1701  type Clockid_t = X__clockid_t /* types.h:164:21 */
  1702  
  1703  type Pid_t = X__pid_t /* types.h:169:18 */
  1704  
  1705  type Ssize_t = X__ssize_t /* types.h:179:19 */
  1706  
  1707  type Time_t = X__time_t /* types.h:184:18 */
  1708  
  1709  type Timer_t = X__timer_t /* types.h:189:19 */
  1710  
  1711  type Off_t = X__off_t /* types.h:194:18 */
  1712  
  1713  // Major, minor numbers, dev_t's.
  1714  
  1715  //	$OpenBSD: stdarg.h,v 1.10 2020/07/21 23:09:00 daniel Exp $
  1716  // Copyright (c) 2003, 2004  Marc espie <espie@openbsd.org>
  1717  //
  1718  // Permission to use, copy, modify, and distribute this software for any
  1719  // purpose with or without fee is hereby granted, provided that the above
  1720  // copyright notice and this permission notice appear in all copies.
  1721  //
  1722  // THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
  1723  // WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
  1724  // MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
  1725  // ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
  1726  // WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
  1727  // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
  1728  // OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  1729  
  1730  //	$OpenBSD: cdefs.h,v 1.43 2018/10/29 17:10:40 guenther Exp $
  1731  //	$NetBSD: cdefs.h,v 1.16 1996/04/03 20:46:39 christos Exp $
  1732  
  1733  // Copyright (c) 1991, 1993
  1734  //	The Regents of the University of California.  All rights reserved.
  1735  //
  1736  // This code is derived from software contributed to Berkeley by
  1737  // Berkeley Software Design, Inc.
  1738  //
  1739  // Redistribution and use in source and binary forms, with or without
  1740  // modification, are permitted provided that the following conditions
  1741  // are met:
  1742  // 1. Redistributions of source code must retain the above copyright
  1743  //    notice, this list of conditions and the following disclaimer.
  1744  // 2. Redistributions in binary form must reproduce the above copyright
  1745  //    notice, this list of conditions and the following disclaimer in the
  1746  //    documentation and/or other materials provided with the distribution.
  1747  // 3. Neither the name of the University nor the names of its contributors
  1748  //    may be used to endorse or promote products derived from this software
  1749  //    without specific prior written permission.
  1750  //
  1751  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1752  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1753  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1754  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1755  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1756  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1757  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1758  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1759  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1760  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1761  // SUCH DAMAGE.
  1762  //
  1763  //	@(#)cdefs.h	8.7 (Berkeley) 1/21/94
  1764  
  1765  // Define __gnuc_va_list.
  1766  
  1767  type X__gnuc_va_list = X__builtin_va_list /* stdarg.h:27:27 */
  1768  
  1769  // Note that the type used in va_arg is supposed to match the
  1770  //    actual type **after default promotions**.
  1771  //    Thus, va_arg (..., short) is not valid.
  1772  
  1773  type Va_list = X__gnuc_va_list /* stdarg.h:39:24 */
  1774  
  1775  // a little trick to accommodate both "#define _LARGEFILE64_SOURCE" and
  1776  // "#define _LARGEFILE64_SOURCE 1" as requesting 64-bit operations, (even
  1777  // though the former does not conform to the LFS document), but considering
  1778  // both "#undef _LARGEFILE64_SOURCE" and "#define _LARGEFILE64_SOURCE 0" as
  1779  // equivalently requesting no 64-bit operations
  1780  
  1781  //	$OpenBSD: unistd.h,v 1.106 2018/07/13 09:25:22 beck Exp $
  1782  //	$NetBSD: unistd.h,v 1.26.4.1 1996/05/28 02:31:51 mrg Exp $
  1783  
  1784  // -
  1785  // Copyright (c) 1991 The Regents of the University of California.
  1786  // All rights reserved.
  1787  //
  1788  // Redistribution and use in source and binary forms, with or without
  1789  // modification, are permitted provided that the following conditions
  1790  // are met:
  1791  // 1. Redistributions of source code must retain the above copyright
  1792  //    notice, this list of conditions and the following disclaimer.
  1793  // 2. Redistributions in binary form must reproduce the above copyright
  1794  //    notice, this list of conditions and the following disclaimer in the
  1795  //    documentation and/or other materials provided with the distribution.
  1796  // 3. Neither the name of the University nor the names of its contributors
  1797  //    may be used to endorse or promote products derived from this software
  1798  //    without specific prior written permission.
  1799  //
  1800  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1801  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1802  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1803  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1804  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1805  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1806  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1807  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1808  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1809  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1810  // SUCH DAMAGE.
  1811  //
  1812  //	@(#)unistd.h	5.13 (Berkeley) 6/17/91
  1813  
  1814  //	$OpenBSD: _null.h,v 1.2 2016/09/09 22:07:58 millert Exp $
  1815  
  1816  // Written by Todd C. Miller, September 9, 2016
  1817  // Public domain.
  1818  
  1819  //	$OpenBSD: types.h,v 1.48 2019/02/09 04:54:11 guenther Exp $
  1820  //	$NetBSD: types.h,v 1.29 1996/11/15 22:48:25 jtc Exp $
  1821  
  1822  // -
  1823  // Copyright (c) 1982, 1986, 1991, 1993
  1824  //	The Regents of the University of California.  All rights reserved.
  1825  // (c) UNIX System Laboratories, Inc.
  1826  // All or some portions of this file are derived from material licensed
  1827  // to the University of California by American Telephone and Telegraph
  1828  // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  1829  // the permission of UNIX System Laboratories, Inc.
  1830  //
  1831  // Redistribution and use in source and binary forms, with or without
  1832  // modification, are permitted provided that the following conditions
  1833  // are met:
  1834  // 1. Redistributions of source code must retain the above copyright
  1835  //    notice, this list of conditions and the following disclaimer.
  1836  // 2. Redistributions in binary form must reproduce the above copyright
  1837  //    notice, this list of conditions and the following disclaimer in the
  1838  //    documentation and/or other materials provided with the distribution.
  1839  // 3. Neither the name of the University nor the names of its contributors
  1840  //    may be used to endorse or promote products derived from this software
  1841  //    without specific prior written permission.
  1842  //
  1843  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1844  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1845  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1846  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1847  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1848  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1849  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1850  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1851  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1852  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1853  // SUCH DAMAGE.
  1854  //
  1855  //	@(#)types.h	8.4 (Berkeley) 1/21/94
  1856  
  1857  //	$OpenBSD: unistd.h,v 1.31 2015/07/20 00:56:10 guenther Exp $
  1858  //	$NetBSD: unistd.h,v 1.10 1994/06/29 06:46:06 cgd Exp $
  1859  
  1860  // Copyright (c) 1989, 1993
  1861  //	The Regents of the University of California.  All rights reserved.
  1862  //
  1863  // Redistribution and use in source and binary forms, with or without
  1864  // modification, are permitted provided that the following conditions
  1865  // are met:
  1866  // 1. Redistributions of source code must retain the above copyright
  1867  //    notice, this list of conditions and the following disclaimer.
  1868  // 2. Redistributions in binary form must reproduce the above copyright
  1869  //    notice, this list of conditions and the following disclaimer in the
  1870  //    documentation and/or other materials provided with the distribution.
  1871  // 3. Neither the name of the University nor the names of its contributors
  1872  //    may be used to endorse or promote products derived from this software
  1873  //    without specific prior written permission.
  1874  //
  1875  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1876  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1877  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1878  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1879  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1880  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1881  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1882  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1883  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1884  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1885  // SUCH DAMAGE.
  1886  //
  1887  //	@(#)unistd.h	8.2 (Berkeley) 1/7/94
  1888  
  1889  //	$OpenBSD: cdefs.h,v 1.43 2018/10/29 17:10:40 guenther Exp $
  1890  //	$NetBSD: cdefs.h,v 1.16 1996/04/03 20:46:39 christos Exp $
  1891  
  1892  // Copyright (c) 1991, 1993
  1893  //	The Regents of the University of California.  All rights reserved.
  1894  //
  1895  // This code is derived from software contributed to Berkeley by
  1896  // Berkeley Software Design, Inc.
  1897  //
  1898  // Redistribution and use in source and binary forms, with or without
  1899  // modification, are permitted provided that the following conditions
  1900  // are met:
  1901  // 1. Redistributions of source code must retain the above copyright
  1902  //    notice, this list of conditions and the following disclaimer.
  1903  // 2. Redistributions in binary form must reproduce the above copyright
  1904  //    notice, this list of conditions and the following disclaimer in the
  1905  //    documentation and/or other materials provided with the distribution.
  1906  // 3. Neither the name of the University nor the names of its contributors
  1907  //    may be used to endorse or promote products derived from this software
  1908  //    without specific prior written permission.
  1909  //
  1910  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  1911  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  1912  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  1913  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  1914  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  1915  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  1916  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  1917  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  1918  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  1919  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  1920  // SUCH DAMAGE.
  1921  //
  1922  //	@(#)cdefs.h	8.7 (Berkeley) 1/21/94
  1923  
  1924  // Define the POSIX.1 version we target for compliance.
  1925  
  1926  // access function
  1927  
  1928  // whence values for lseek(2)
  1929  
  1930  // old BSD whence values for lseek(2); renamed by POSIX 1003.1
  1931  
  1932  // the parameters argument passed to the __tfork() syscall
  1933  type X__tfork = struct {
  1934  	Ftf_tcb   uintptr
  1935  	Ftf_tid   uintptr
  1936  	Ftf_stack uintptr
  1937  } /* unistd.h:66:1 */
  1938  
  1939  // the parameters argument for the kbind() syscall
  1940  type X__kbind = struct {
  1941  	Fkb_addr uintptr
  1942  	Fkb_size Size_t
  1943  } /* unistd.h:73:1 */
  1944  
  1945  // the pathconf(2) variable values are part of the ABI
  1946  
  1947  // configurable pathname variables
  1948  
  1949  // POSIX options and option groups we unconditionally do or don't
  1950  // implement.  Please keep this list in alphabetical order.
  1951  //
  1952  // Anything which is defined as zero below **must** have an
  1953  // implementation for the corresponding sysconf() which is able to
  1954  // determine conclusively whether or not the feature is supported.
  1955  // Anything which is defined as other than -1 below **must** have
  1956  // complete headers, types, and function declarations as specified by
  1957  // the POSIX standard; however, if the relevant sysconf() function
  1958  // returns -1, the functions may be stubbed out.
  1959  
  1960  // Define the POSIX.2 version we target for compliance.
  1961  
  1962  // the sysconf(3) variable values are part of the ABI
  1963  
  1964  // configurable system variables
  1965  
  1966  // configurable system strings
  1967  
  1968  type Intptr_t = X__intptr_t /* unistd.h:320:21 */
  1969  
  1970  // MVS linker does not support external names larger than 8 bytes
  1971  
  1972  //
  1973  //     The 'zlib' compression library provides in-memory compression and
  1974  //   decompression functions, including integrity checks of the uncompressed data.
  1975  //   This version of the library supports only one compression method (deflation)
  1976  //   but other algorithms will be added later and will have the same stream
  1977  //   interface.
  1978  //
  1979  //     Compression can be done in a single step if the buffers are large enough,
  1980  //   or can be done by repeated calls of the compression function.  In the latter
  1981  //   case, the application must provide more input and/or consume the output
  1982  //   (providing more output space) before each call.
  1983  //
  1984  //     The compressed data format used by default by the in-memory functions is
  1985  //   the zlib format, which is a zlib wrapper documented in RFC 1950, wrapped
  1986  //   around a deflate stream, which is itself documented in RFC 1951.
  1987  //
  1988  //     The library also supports reading and writing files in gzip (.gz) format
  1989  //   with an interface similar to that of stdio using the functions that start
  1990  //   with "gz".  The gzip format is different from the zlib format.  gzip is a
  1991  //   gzip wrapper, documented in RFC 1952, wrapped around a deflate stream.
  1992  //
  1993  //     This library can optionally read and write gzip and raw deflate streams in
  1994  //   memory as well.
  1995  //
  1996  //     The zlib format was designed to be compact and fast for use in memory
  1997  //   and on communications channels.  The gzip format was designed for single-
  1998  //   file compression on file systems, has a larger header than zlib to maintain
  1999  //   directory information, and uses a different, slower check method than zlib.
  2000  //
  2001  //     The library does not install any signal handler.  The decoder checks
  2002  //   the consistency of the compressed data, so the library should never crash
  2003  //   even in the case of corrupted input.
  2004  
  2005  type Alloc_func = uintptr /* zlib.h:81:16 */
  2006  type Free_func = uintptr  /* zlib.h:82:16 */
  2007  
  2008  type Internal_state = struct {
  2009  	Fstrm             Z_streamp
  2010  	Fstatus           int32
  2011  	F__ccgo_pad1      [4]byte
  2012  	Fpending_buf      uintptr
  2013  	Fpending_buf_size Ulg
  2014  	Fpending_out      uintptr
  2015  	Fpending          Ulg
  2016  	Fwrap             int32
  2017  	F__ccgo_pad2      [4]byte
  2018  	Fgzhead           Gz_headerp
  2019  	Fgzindex          Ulg
  2020  	Fmethod           Byte
  2021  	F__ccgo_pad3      [3]byte
  2022  	Flast_flush       int32
  2023  	Fw_size           UInt
  2024  	Fw_bits           UInt
  2025  	Fw_mask           UInt
  2026  	F__ccgo_pad4      [4]byte
  2027  	Fwindow           uintptr
  2028  	Fwindow_size      Ulg
  2029  	Fprev             uintptr
  2030  	Fhead             uintptr
  2031  	Fins_h            UInt
  2032  	Fhash_size        UInt
  2033  	Fhash_bits        UInt
  2034  	Fhash_mask        UInt
  2035  	Fhash_shift       UInt
  2036  	F__ccgo_pad5      [4]byte
  2037  	Fblock_start      int64
  2038  	Fmatch_length     UInt
  2039  	Fprev_match       IPos
  2040  	Fmatch_available  int32
  2041  	Fstrstart         UInt
  2042  	Fmatch_start      UInt
  2043  	Flookahead        UInt
  2044  	Fprev_length      UInt
  2045  	Fmax_chain_length UInt
  2046  	Fmax_lazy_match   UInt
  2047  	Flevel            int32
  2048  	Fstrategy         int32
  2049  	Fgood_match       UInt
  2050  	Fnice_match       int32
  2051  	Fdyn_ltree        [573]struct {
  2052  		Ffc struct{ Ffreq Ush }
  2053  		Fdl struct{ Fdad Ush }
  2054  	}
  2055  	Fdyn_dtree [61]struct {
  2056  		Ffc struct{ Ffreq Ush }
  2057  		Fdl struct{ Fdad Ush }
  2058  	}
  2059  	Fbl_tree [39]struct {
  2060  		Ffc struct{ Ffreq Ush }
  2061  		Fdl struct{ Fdad Ush }
  2062  	}
  2063  	Fl_desc struct {
  2064  		Fdyn_tree    uintptr
  2065  		Fmax_code    int32
  2066  		F__ccgo_pad1 [4]byte
  2067  		Fstat_desc   uintptr
  2068  	}
  2069  	Fd_desc struct {
  2070  		Fdyn_tree    uintptr
  2071  		Fmax_code    int32
  2072  		F__ccgo_pad1 [4]byte
  2073  		Fstat_desc   uintptr
  2074  	}
  2075  	Fbl_desc struct {
  2076  		Fdyn_tree    uintptr
  2077  		Fmax_code    int32
  2078  		F__ccgo_pad1 [4]byte
  2079  		Fstat_desc   uintptr
  2080  	}
  2081  	Fbl_count    [16]Ush
  2082  	Fheap        [573]int32
  2083  	Fheap_len    int32
  2084  	Fheap_max    int32
  2085  	Fdepth       [573]Uch
  2086  	F__ccgo_pad6 [7]byte
  2087  	Fl_buf       uintptr
  2088  	Flit_bufsize UInt
  2089  	Flast_lit    UInt
  2090  	Fd_buf       uintptr
  2091  	Fopt_len     Ulg
  2092  	Fstatic_len  Ulg
  2093  	Fmatches     UInt
  2094  	Finsert      UInt
  2095  	Fbi_buf      Ush
  2096  	F__ccgo_pad7 [2]byte
  2097  	Fbi_valid    int32
  2098  	Fhigh_water  Ulg
  2099  } /* zlib.h:84:1 */
  2100  
  2101  type Z_stream_s = struct {
  2102  	Fnext_in     uintptr
  2103  	Favail_in    UInt
  2104  	F__ccgo_pad1 [4]byte
  2105  	Ftotal_in    ULong
  2106  	Fnext_out    uintptr
  2107  	Favail_out   UInt
  2108  	F__ccgo_pad2 [4]byte
  2109  	Ftotal_out   ULong
  2110  	Fmsg         uintptr
  2111  	Fstate       uintptr
  2112  	Fzalloc      Alloc_func
  2113  	Fzfree       Free_func
  2114  	Fopaque      Voidpf
  2115  	Fdata_type   int32
  2116  	F__ccgo_pad3 [4]byte
  2117  	Fadler       ULong
  2118  	Freserved    ULong
  2119  } /* zlib.h:86:9 */
  2120  
  2121  type Z_stream = Z_stream_s /* zlib.h:106:3 */
  2122  
  2123  type Z_streamp = uintptr /* zlib.h:108:22 */
  2124  
  2125  //
  2126  //      gzip header information passed to and from zlib routines.  See RFC 1952
  2127  //   for more details on the meanings of these fields.
  2128  type Gz_header_s = struct {
  2129  	Ftext        int32
  2130  	F__ccgo_pad1 [4]byte
  2131  	Ftime        ULong
  2132  	Fxflags      int32
  2133  	Fos          int32
  2134  	Fextra       uintptr
  2135  	Fextra_len   UInt
  2136  	Fextra_max   UInt
  2137  	Fname        uintptr
  2138  	Fname_max    UInt
  2139  	F__ccgo_pad2 [4]byte
  2140  	Fcomment     uintptr
  2141  	Fcomm_max    UInt
  2142  	Fhcrc        int32
  2143  	Fdone        int32
  2144  	F__ccgo_pad3 [4]byte
  2145  } /* zlib.h:114:9 */
  2146  
  2147  //
  2148  //      gzip header information passed to and from zlib routines.  See RFC 1952
  2149  //   for more details on the meanings of these fields.
  2150  type Gz_header = Gz_header_s /* zlib.h:129:3 */
  2151  
  2152  type Gz_headerp = uintptr /* zlib.h:131:23 */
  2153  //
  2154  //      inflateGetHeader() requests that gzip header information be stored in the
  2155  //    provided gz_header structure.  inflateGetHeader() may be called after
  2156  //    inflateInit2() or inflateReset(), and before the first call of inflate().
  2157  //    As inflate() processes the gzip stream, head->done is zero until the header
  2158  //    is completed, at which time head->done is set to one.  If a zlib stream is
  2159  //    being decoded, then head->done is set to -1 to indicate that there will be
  2160  //    no gzip header information forthcoming.  Note that Z_BLOCK or Z_TREES can be
  2161  //    used to force inflate() to return immediately after header processing is
  2162  //    complete and before any actual data is decompressed.
  2163  //
  2164  //      The text, time, xflags, and os fields are filled in with the gzip header
  2165  //    contents.  hcrc is set to true if there is a header CRC.  (The header CRC
  2166  //    was valid if done is set to one.) If extra is not Z_NULL, then extra_max
  2167  //    contains the maximum number of bytes to write to extra.  Once done is true,
  2168  //    extra_len contains the actual extra field length, and extra contains the
  2169  //    extra field, or that field truncated if extra_max is less than extra_len.
  2170  //    If name is not Z_NULL, then up to name_max characters are written there,
  2171  //    terminated with a zero unless the length is greater than name_max.  If
  2172  //    comment is not Z_NULL, then up to comm_max characters are written there,
  2173  //    terminated with a zero unless the length is greater than comm_max.  When any
  2174  //    of extra, name, or comment are not Z_NULL and the respective field is not
  2175  //    present in the header, then that field is set to Z_NULL to signal its
  2176  //    absence.  This allows the use of deflateSetHeader() with the returned
  2177  //    structure to duplicate the header.  However if those fields are set to
  2178  //    allocated memory, then the application will need to save those pointers
  2179  //    elsewhere so that they can be eventually freed.
  2180  //
  2181  //      If inflateGetHeader is not used, then the header information is simply
  2182  //    discarded.  The header is always checked for validity, including the header
  2183  //    CRC if present.  inflateReset() will reset the process to discard the header
  2184  //    information.  The application would need to call inflateGetHeader() again to
  2185  //    retrieve the header from the next gzip stream.
  2186  //
  2187  //      inflateGetHeader returns Z_OK if success, or Z_STREAM_ERROR if the source
  2188  //    stream state was inconsistent.
  2189  
  2190  //
  2191  // ZEXTERN int ZEXPORT inflateBackInit OF((z_streamp strm, int windowBits,
  2192  //                                         unsigned char FAR *window));
  2193  //
  2194  //      Initialize the internal stream state for decompression using inflateBack()
  2195  //    calls.  The fields zalloc, zfree and opaque in strm must be initialized
  2196  //    before the call.  If zalloc and zfree are Z_NULL, then the default library-
  2197  //    derived memory allocation routines are used.  windowBits is the base two
  2198  //    logarithm of the window size, in the range 8..15.  window is a caller
  2199  //    supplied buffer of that size.  Except for special applications where it is
  2200  //    assured that deflate was used with small window sizes, windowBits must be 15
  2201  //    and a 32K byte window must be supplied to be able to decompress general
  2202  //    deflate streams.
  2203  //
  2204  //      See inflateBack() for the usage of these routines.
  2205  //
  2206  //      inflateBackInit will return Z_OK on success, Z_STREAM_ERROR if any of
  2207  //    the parameters are invalid, Z_MEM_ERROR if the internal state could not be
  2208  //    allocated, or Z_VERSION_ERROR if the version of the library does not match
  2209  //    the version of the header file.
  2210  
  2211  type In_func = uintptr  /* zlib.h:1092:18 */
  2212  type Out_func = uintptr /* zlib.h:1094:13 */
  2213  //
  2214  //      Same as uncompress, except that sourceLen is a pointer, where the
  2215  //    length of the source is *sourceLen.  On return, *sourceLen is the number of
  2216  //    source bytes consumed.
  2217  
  2218  // gzip file access functions
  2219  
  2220  //
  2221  //      This library supports reading and writing files in gzip (.gz) format with
  2222  //    an interface similar to that of stdio, using the functions that start with
  2223  //    "gz".  The gzip format is different from the zlib format.  gzip is a gzip
  2224  //    wrapper, documented in RFC 1952, wrapped around a deflate stream.
  2225  
  2226  type GzFile_s = struct {
  2227  	Fhave        uint32
  2228  	F__ccgo_pad1 [4]byte
  2229  	Fnext        uintptr
  2230  	Fpos         Off_t
  2231  } /* zlib.h:1300:9 */
  2232  
  2233  //
  2234  //      Same as uncompress, except that sourceLen is a pointer, where the
  2235  //    length of the source is *sourceLen.  On return, *sourceLen is the number of
  2236  //    source bytes consumed.
  2237  
  2238  // gzip file access functions
  2239  
  2240  //
  2241  //      This library supports reading and writing files in gzip (.gz) format with
  2242  //    an interface similar to that of stdio, using the functions that start with
  2243  //    "gz".  The gzip format is different from the zlib format.  gzip is a gzip
  2244  //    wrapper, documented in RFC 1952, wrapped around a deflate stream.
  2245  
  2246  type GzFile = uintptr /* zlib.h:1300:25 */
  2247  
  2248  //	$OpenBSD: stddef.h,v 1.14 2017/01/06 14:36:50 kettenis Exp $
  2249  //	$NetBSD: stddef.h,v 1.4 1994/10/26 00:56:26 cgd Exp $
  2250  
  2251  // -
  2252  // Copyright (c) 1990 The Regents of the University of California.
  2253  // All rights reserved.
  2254  //
  2255  // Redistribution and use in source and binary forms, with or without
  2256  // modification, are permitted provided that the following conditions
  2257  // are met:
  2258  // 1. Redistributions of source code must retain the above copyright
  2259  //    notice, this list of conditions and the following disclaimer.
  2260  // 2. Redistributions in binary form must reproduce the above copyright
  2261  //    notice, this list of conditions and the following disclaimer in the
  2262  //    documentation and/or other materials provided with the distribution.
  2263  // 3. Neither the name of the University nor the names of its contributors
  2264  //    may be used to endorse or promote products derived from this software
  2265  //    without specific prior written permission.
  2266  //
  2267  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2268  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2269  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2270  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2271  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2272  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2273  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2274  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2275  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2276  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2277  // SUCH DAMAGE.
  2278  //
  2279  //	@(#)stddef.h	5.5 (Berkeley) 4/3/91
  2280  
  2281  //	$OpenBSD: string.h,v 1.32 2017/09/05 03:16:13 schwarze Exp $
  2282  //	$NetBSD: string.h,v 1.6 1994/10/26 00:56:30 cgd Exp $
  2283  
  2284  // -
  2285  // Copyright (c) 1990 The Regents of the University of California.
  2286  // All rights reserved.
  2287  //
  2288  // Redistribution and use in source and binary forms, with or without
  2289  // modification, are permitted provided that the following conditions
  2290  // are met:
  2291  // 1. Redistributions of source code must retain the above copyright
  2292  //    notice, this list of conditions and the following disclaimer.
  2293  // 2. Redistributions in binary form must reproduce the above copyright
  2294  //    notice, this list of conditions and the following disclaimer in the
  2295  //    documentation and/or other materials provided with the distribution.
  2296  // 3. Neither the name of the University nor the names of its contributors
  2297  //    may be used to endorse or promote products derived from this software
  2298  //    without specific prior written permission.
  2299  //
  2300  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2301  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2302  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2303  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2304  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2305  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2306  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2307  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2308  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2309  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2310  // SUCH DAMAGE.
  2311  //
  2312  //	@(#)string.h	5.10 (Berkeley) 3/9/91
  2313  
  2314  //	$OpenBSD: cdefs.h,v 1.43 2018/10/29 17:10:40 guenther Exp $
  2315  //	$NetBSD: cdefs.h,v 1.16 1996/04/03 20:46:39 christos Exp $
  2316  
  2317  // Copyright (c) 1991, 1993
  2318  //	The Regents of the University of California.  All rights reserved.
  2319  //
  2320  // This code is derived from software contributed to Berkeley by
  2321  // Berkeley Software Design, Inc.
  2322  //
  2323  // Redistribution and use in source and binary forms, with or without
  2324  // modification, are permitted provided that the following conditions
  2325  // are met:
  2326  // 1. Redistributions of source code must retain the above copyright
  2327  //    notice, this list of conditions and the following disclaimer.
  2328  // 2. Redistributions in binary form must reproduce the above copyright
  2329  //    notice, this list of conditions and the following disclaimer in the
  2330  //    documentation and/or other materials provided with the distribution.
  2331  // 3. Neither the name of the University nor the names of its contributors
  2332  //    may be used to endorse or promote products derived from this software
  2333  //    without specific prior written permission.
  2334  //
  2335  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2336  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2337  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2338  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2339  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2340  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2341  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2342  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2343  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2344  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2345  // SUCH DAMAGE.
  2346  //
  2347  //	@(#)cdefs.h	8.7 (Berkeley) 1/21/94
  2348  
  2349  //	$OpenBSD: _null.h,v 1.2 2016/09/09 22:07:58 millert Exp $
  2350  
  2351  // Written by Todd C. Miller, September 9, 2016
  2352  // Public domain.
  2353  
  2354  //	$OpenBSD: _types.h,v 1.17 2018/03/05 01:15:25 deraadt Exp $
  2355  
  2356  // -
  2357  // Copyright (c) 1990, 1993
  2358  //	The Regents of the University of California.  All rights reserved.
  2359  //
  2360  // Redistribution and use in source and binary forms, with or without
  2361  // modification, are permitted provided that the following conditions
  2362  // are met:
  2363  // 1. Redistributions of source code must retain the above copyright
  2364  //    notice, this list of conditions and the following disclaimer.
  2365  // 2. Redistributions in binary form must reproduce the above copyright
  2366  //    notice, this list of conditions and the following disclaimer in the
  2367  //    documentation and/or other materials provided with the distribution.
  2368  // 3. Neither the name of the University nor the names of its contributors
  2369  //    may be used to endorse or promote products derived from this software
  2370  //    without specific prior written permission.
  2371  //
  2372  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2373  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2374  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2375  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2376  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2377  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2378  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2379  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2380  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2381  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2382  // SUCH DAMAGE.
  2383  //
  2384  //	@(#)types.h	8.3 (Berkeley) 1/5/94
  2385  //	@(#)ansi.h	8.2 (Berkeley) 1/4/94
  2386  
  2387  // POSIX mandates that certain string functions not present in ISO C
  2388  // be prototyped in strings.h.  Historically, we've included them here.
  2389  //	$OpenBSD: strings.h,v 1.6 2017/09/10 21:50:36 schwarze Exp $
  2390  
  2391  // -
  2392  // Copyright (c) 1990 The Regents of the University of California.
  2393  // All rights reserved.
  2394  //
  2395  // Redistribution and use in source and binary forms, with or without
  2396  // modification, are permitted provided that the following conditions
  2397  // are met:
  2398  // 1. Redistributions of source code must retain the above copyright
  2399  //    notice, this list of conditions and the following disclaimer.
  2400  // 2. Redistributions in binary form must reproduce the above copyright
  2401  //    notice, this list of conditions and the following disclaimer in the
  2402  //    documentation and/or other materials provided with the distribution.
  2403  // 3. Neither the name of the University nor the names of its contributors
  2404  //    may be used to endorse or promote products derived from this software
  2405  //    without specific prior written permission.
  2406  //
  2407  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2408  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2409  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2410  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2411  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2412  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2413  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2414  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2415  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2416  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2417  // SUCH DAMAGE.
  2418  //
  2419  //	@(#)strings.h	5.8 (Berkeley) 5/15/90
  2420  
  2421  //	$OpenBSD: cdefs.h,v 1.43 2018/10/29 17:10:40 guenther Exp $
  2422  //	$NetBSD: cdefs.h,v 1.16 1996/04/03 20:46:39 christos Exp $
  2423  
  2424  // Copyright (c) 1991, 1993
  2425  //	The Regents of the University of California.  All rights reserved.
  2426  //
  2427  // This code is derived from software contributed to Berkeley by
  2428  // Berkeley Software Design, Inc.
  2429  //
  2430  // Redistribution and use in source and binary forms, with or without
  2431  // modification, are permitted provided that the following conditions
  2432  // are met:
  2433  // 1. Redistributions of source code must retain the above copyright
  2434  //    notice, this list of conditions and the following disclaimer.
  2435  // 2. Redistributions in binary form must reproduce the above copyright
  2436  //    notice, this list of conditions and the following disclaimer in the
  2437  //    documentation and/or other materials provided with the distribution.
  2438  // 3. Neither the name of the University nor the names of its contributors
  2439  //    may be used to endorse or promote products derived from this software
  2440  //    without specific prior written permission.
  2441  //
  2442  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2443  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2444  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2445  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2446  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2447  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2448  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2449  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2450  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2451  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2452  // SUCH DAMAGE.
  2453  //
  2454  //	@(#)cdefs.h	8.7 (Berkeley) 1/21/94
  2455  
  2456  //	$OpenBSD: _types.h,v 1.17 2018/03/05 01:15:25 deraadt Exp $
  2457  
  2458  // -
  2459  // Copyright (c) 1990, 1993
  2460  //	The Regents of the University of California.  All rights reserved.
  2461  //
  2462  // Redistribution and use in source and binary forms, with or without
  2463  // modification, are permitted provided that the following conditions
  2464  // are met:
  2465  // 1. Redistributions of source code must retain the above copyright
  2466  //    notice, this list of conditions and the following disclaimer.
  2467  // 2. Redistributions in binary form must reproduce the above copyright
  2468  //    notice, this list of conditions and the following disclaimer in the
  2469  //    documentation and/or other materials provided with the distribution.
  2470  // 3. Neither the name of the University nor the names of its contributors
  2471  //    may be used to endorse or promote products derived from this software
  2472  //    without specific prior written permission.
  2473  //
  2474  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2475  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2476  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2477  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2478  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2479  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2480  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2481  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2482  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2483  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2484  // SUCH DAMAGE.
  2485  //
  2486  //	@(#)types.h	8.3 (Berkeley) 1/5/94
  2487  //	@(#)ansi.h	8.2 (Berkeley) 1/4/94
  2488  
  2489  // POSIX mandates that certain string functions not present in ISO C
  2490  // be prototyped in strings.h.
  2491  
  2492  type Locale_t = uintptr /* strings.h:53:14 */
  2493  
  2494  //	$OpenBSD: stdlib.h,v 1.76 2019/05/10 15:03:24 otto Exp $
  2495  //	$NetBSD: stdlib.h,v 1.25 1995/12/27 21:19:08 jtc Exp $
  2496  
  2497  // -
  2498  // Copyright (c) 1990 The Regents of the University of California.
  2499  // All rights reserved.
  2500  //
  2501  // Redistribution and use in source and binary forms, with or without
  2502  // modification, are permitted provided that the following conditions
  2503  // are met:
  2504  // 1. Redistributions of source code must retain the above copyright
  2505  //    notice, this list of conditions and the following disclaimer.
  2506  // 2. Redistributions in binary form must reproduce the above copyright
  2507  //    notice, this list of conditions and the following disclaimer in the
  2508  //    documentation and/or other materials provided with the distribution.
  2509  // 3. Neither the name of the University nor the names of its contributors
  2510  //    may be used to endorse or promote products derived from this software
  2511  //    without specific prior written permission.
  2512  //
  2513  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2514  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2515  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2516  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2517  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2518  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2519  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2520  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2521  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2522  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2523  // SUCH DAMAGE.
  2524  //
  2525  //	@(#)stdlib.h	5.13 (Berkeley) 6/4/91
  2526  
  2527  //	$OpenBSD: cdefs.h,v 1.43 2018/10/29 17:10:40 guenther Exp $
  2528  //	$NetBSD: cdefs.h,v 1.16 1996/04/03 20:46:39 christos Exp $
  2529  
  2530  // Copyright (c) 1991, 1993
  2531  //	The Regents of the University of California.  All rights reserved.
  2532  //
  2533  // This code is derived from software contributed to Berkeley by
  2534  // Berkeley Software Design, Inc.
  2535  //
  2536  // Redistribution and use in source and binary forms, with or without
  2537  // modification, are permitted provided that the following conditions
  2538  // are met:
  2539  // 1. Redistributions of source code must retain the above copyright
  2540  //    notice, this list of conditions and the following disclaimer.
  2541  // 2. Redistributions in binary form must reproduce the above copyright
  2542  //    notice, this list of conditions and the following disclaimer in the
  2543  //    documentation and/or other materials provided with the distribution.
  2544  // 3. Neither the name of the University nor the names of its contributors
  2545  //    may be used to endorse or promote products derived from this software
  2546  //    without specific prior written permission.
  2547  //
  2548  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2549  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2550  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2551  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2552  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2553  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2554  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2555  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2556  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2557  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2558  // SUCH DAMAGE.
  2559  //
  2560  //	@(#)cdefs.h	8.7 (Berkeley) 1/21/94
  2561  
  2562  //	$OpenBSD: _null.h,v 1.2 2016/09/09 22:07:58 millert Exp $
  2563  
  2564  // Written by Todd C. Miller, September 9, 2016
  2565  // Public domain.
  2566  
  2567  //	$OpenBSD: _types.h,v 1.17 2018/03/05 01:15:25 deraadt Exp $
  2568  
  2569  // -
  2570  // Copyright (c) 1990, 1993
  2571  //	The Regents of the University of California.  All rights reserved.
  2572  //
  2573  // Redistribution and use in source and binary forms, with or without
  2574  // modification, are permitted provided that the following conditions
  2575  // are met:
  2576  // 1. Redistributions of source code must retain the above copyright
  2577  //    notice, this list of conditions and the following disclaimer.
  2578  // 2. Redistributions in binary form must reproduce the above copyright
  2579  //    notice, this list of conditions and the following disclaimer in the
  2580  //    documentation and/or other materials provided with the distribution.
  2581  // 3. Neither the name of the University nor the names of its contributors
  2582  //    may be used to endorse or promote products derived from this software
  2583  //    without specific prior written permission.
  2584  //
  2585  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2586  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2587  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2588  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2589  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2590  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2591  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2592  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2593  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2594  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2595  // SUCH DAMAGE.
  2596  //
  2597  //	@(#)types.h	8.3 (Berkeley) 1/5/94
  2598  //	@(#)ansi.h	8.2 (Berkeley) 1/4/94
  2599  
  2600  //	$OpenBSD: types.h,v 1.48 2019/02/09 04:54:11 guenther Exp $
  2601  //	$NetBSD: types.h,v 1.29 1996/11/15 22:48:25 jtc Exp $
  2602  
  2603  // -
  2604  // Copyright (c) 1982, 1986, 1991, 1993
  2605  //	The Regents of the University of California.  All rights reserved.
  2606  // (c) UNIX System Laboratories, Inc.
  2607  // All or some portions of this file are derived from material licensed
  2608  // to the University of California by American Telephone and Telegraph
  2609  // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  2610  // the permission of UNIX System Laboratories, Inc.
  2611  //
  2612  // Redistribution and use in source and binary forms, with or without
  2613  // modification, are permitted provided that the following conditions
  2614  // are met:
  2615  // 1. Redistributions of source code must retain the above copyright
  2616  //    notice, this list of conditions and the following disclaimer.
  2617  // 2. Redistributions in binary form must reproduce the above copyright
  2618  //    notice, this list of conditions and the following disclaimer in the
  2619  //    documentation and/or other materials provided with the distribution.
  2620  // 3. Neither the name of the University nor the names of its contributors
  2621  //    may be used to endorse or promote products derived from this software
  2622  //    without specific prior written permission.
  2623  //
  2624  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  2625  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  2626  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  2627  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  2628  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  2629  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  2630  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  2631  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  2632  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  2633  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  2634  // SUCH DAMAGE.
  2635  //
  2636  //	@(#)types.h	8.4 (Berkeley) 1/21/94
  2637  
  2638  // in C++, wchar_t is a built-in type
  2639  
  2640  type Div_t = struct {
  2641  	Fquot int32
  2642  	Frem  int32
  2643  } /* stdlib.h:59:3 */
  2644  
  2645  type Ldiv_t = struct {
  2646  	Fquot int64
  2647  	Frem  int64
  2648  } /* stdlib.h:64:3 */
  2649  
  2650  type Lldiv_t = struct {
  2651  	Fquot int64
  2652  	Frem  int64
  2653  } /* stdlib.h:70:3 */
  2654  
  2655  type Qdiv_t = struct {
  2656  	Fquot Quad_t
  2657  	Frem  Quad_t
  2658  } /* stdlib.h:77:3 */
  2659  
  2660  // since "static" is used to mean two completely different things in C, we
  2661  //    define "local" for the non-static meaning of "static", for readability
  2662  //    (compile with -Dlocal if your debugger can't find static symbols)
  2663  
  2664  type Uch = uint8  /* zutil.h:43:24 */
  2665  type Uchf = Uch   /* zutil.h:44:17 */
  2666  type Ush = uint16 /* zutil.h:45:24 */
  2667  type Ushf = Ush   /* zutil.h:46:17 */
  2668  type Ulg = uint64 /* zutil.h:47:24 */
  2669  
  2670  // NMAX is the largest n such that 255n(n+1)/2 + (n+1)(BASE-1) <= 2^32-1
  2671  
  2672  // use NO_DIVIDE if your processor does not do division in hardware --
  2673  //    try it both ways to see which is faster
  2674  
  2675  // =========================================================================
  2676  func Xadler32_z(tls *libc.TLS, adler ULong, buf uintptr, len Z_size_t) ULong { /* adler32.c:63:15: */
  2677  	var sum2 uint64
  2678  	var n uint32
  2679  
  2680  	// split Adler-32 into component sums
  2681  	sum2 = adler >> 16 & uint64(0xffff)
  2682  	adler = adler & uint64(0xffff)
  2683  
  2684  	// in case user likes doing a byte at a time, keep it fast
  2685  	if len == uint64(1) {
  2686  		adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf)))
  2687  		if adler >= uint64(BASE) {
  2688  			adler = adler - uint64(BASE)
  2689  		}
  2690  		sum2 = sum2 + adler
  2691  		if sum2 >= uint64(BASE) {
  2692  			sum2 = sum2 - uint64(BASE)
  2693  		}
  2694  		return adler | sum2<<16
  2695  	}
  2696  
  2697  	// initial Adler-32 value (deferred check for len == 1 speed)
  2698  	if buf == uintptr(Z_NULL) {
  2699  		return uint64(1)
  2700  	}
  2701  
  2702  	// in case short lengths are provided, keep it somewhat fast
  2703  	if len < uint64(16) {
  2704  		for libc.PostDecUint64(&len, 1) != 0 {
  2705  			adler = adler + ULong(*(*Bytef)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1))))
  2706  			sum2 = sum2 + adler
  2707  		}
  2708  		if adler >= uint64(BASE) {
  2709  			adler = adler - uint64(BASE)
  2710  		}
  2711  		sum2 = sum2 % uint64(BASE) // only added so many BASE's
  2712  		return adler | sum2<<16
  2713  	}
  2714  
  2715  	// do length NMAX blocks -- requires just one modulo operation
  2716  	for len >= uint64(NMAX) {
  2717  		len = len - uint64(NMAX)
  2718  		n = uint32(NMAX / 16) // NMAX is divisible by 16
  2719  		for ok := true; ok; ok = libc.PreDecUint32(&n, 1) != 0 {
  2720  			{
  2721  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf)))
  2722  				sum2 = sum2 + adler
  2723  			}
  2724  			{
  2725  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 1)))
  2726  				sum2 = sum2 + adler
  2727  			}
  2728  
  2729  			{
  2730  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 2)))
  2731  				sum2 = sum2 + adler
  2732  			}
  2733  			{
  2734  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 3)))
  2735  				sum2 = sum2 + adler
  2736  			}
  2737  
  2738  			{
  2739  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 4)))
  2740  				sum2 = sum2 + adler
  2741  			}
  2742  			{
  2743  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 5)))
  2744  				sum2 = sum2 + adler
  2745  			}
  2746  
  2747  			{
  2748  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 6)))
  2749  				sum2 = sum2 + adler
  2750  			}
  2751  			{
  2752  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 7)))
  2753  				sum2 = sum2 + adler
  2754  			}
  2755  
  2756  			{
  2757  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 8)))
  2758  				sum2 = sum2 + adler
  2759  			}
  2760  			{
  2761  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 9)))
  2762  				sum2 = sum2 + adler
  2763  			}
  2764  
  2765  			{
  2766  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 10)))
  2767  				sum2 = sum2 + adler
  2768  			}
  2769  			{
  2770  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 11)))
  2771  				sum2 = sum2 + adler
  2772  			}
  2773  
  2774  			{
  2775  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 12)))
  2776  				sum2 = sum2 + adler
  2777  			}
  2778  			{
  2779  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 13)))
  2780  				sum2 = sum2 + adler
  2781  			}
  2782  
  2783  			{
  2784  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 14)))
  2785  				sum2 = sum2 + adler
  2786  			}
  2787  			{
  2788  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 15)))
  2789  				sum2 = sum2 + adler
  2790  			}
  2791  
  2792  			// 16 sums unrolled
  2793  			buf += uintptr(16)
  2794  		}
  2795  		adler = adler % uint64(BASE)
  2796  		sum2 = sum2 % uint64(BASE)
  2797  	}
  2798  
  2799  	// do remaining bytes (less than NMAX, still just one modulo)
  2800  	if len != 0 { // avoid modulos if none remaining
  2801  		for len >= uint64(16) {
  2802  			len = len - uint64(16)
  2803  			{
  2804  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf)))
  2805  				sum2 = sum2 + adler
  2806  			}
  2807  			{
  2808  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 1)))
  2809  				sum2 = sum2 + adler
  2810  			}
  2811  
  2812  			{
  2813  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 2)))
  2814  				sum2 = sum2 + adler
  2815  			}
  2816  			{
  2817  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 3)))
  2818  				sum2 = sum2 + adler
  2819  			}
  2820  
  2821  			{
  2822  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 4)))
  2823  				sum2 = sum2 + adler
  2824  			}
  2825  			{
  2826  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 5)))
  2827  				sum2 = sum2 + adler
  2828  			}
  2829  
  2830  			{
  2831  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 6)))
  2832  				sum2 = sum2 + adler
  2833  			}
  2834  			{
  2835  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 7)))
  2836  				sum2 = sum2 + adler
  2837  			}
  2838  
  2839  			{
  2840  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 8)))
  2841  				sum2 = sum2 + adler
  2842  			}
  2843  			{
  2844  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 9)))
  2845  				sum2 = sum2 + adler
  2846  			}
  2847  
  2848  			{
  2849  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 10)))
  2850  				sum2 = sum2 + adler
  2851  			}
  2852  			{
  2853  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 11)))
  2854  				sum2 = sum2 + adler
  2855  			}
  2856  
  2857  			{
  2858  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 12)))
  2859  				sum2 = sum2 + adler
  2860  			}
  2861  			{
  2862  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 13)))
  2863  				sum2 = sum2 + adler
  2864  			}
  2865  
  2866  			{
  2867  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 14)))
  2868  				sum2 = sum2 + adler
  2869  			}
  2870  			{
  2871  				adler = adler + ULong(*(*Bytef)(unsafe.Pointer(buf + 15)))
  2872  				sum2 = sum2 + adler
  2873  			}
  2874  
  2875  			buf += uintptr(16)
  2876  		}
  2877  		for libc.PostDecUint64(&len, 1) != 0 {
  2878  			adler = adler + ULong(*(*Bytef)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1))))
  2879  			sum2 = sum2 + adler
  2880  		}
  2881  		adler = adler % uint64(BASE)
  2882  		sum2 = sum2 % uint64(BASE)
  2883  	}
  2884  
  2885  	// return recombined sums
  2886  	return adler | sum2<<16
  2887  }
  2888  
  2889  // =========================================================================
  2890  func Xadler32(tls *libc.TLS, adler ULong, buf uintptr, len UInt) ULong { /* adler32.c:134:15: */
  2891  	return Xadler32_z(tls, adler, buf, uint64(len))
  2892  }
  2893  
  2894  // =========================================================================
  2895  func adler32_combine_(tls *libc.TLS, adler1 ULong, adler2 ULong, len2 Off_t) ULong { /* adler32.c:143:13: */
  2896  	var sum1 uint64
  2897  	var sum2 uint64
  2898  	var rem uint32
  2899  
  2900  	// for negative len, return invalid adler32 as a clue for debugging
  2901  	if len2 < int64(0) {
  2902  		return 0xffffffff
  2903  	}
  2904  
  2905  	// the derivation of this formula is left as an exercise for the reader
  2906  	len2 = len2 % int64(BASE) // assumes len2 >= 0
  2907  	rem = uint32(len2)
  2908  	sum1 = adler1 & uint64(0xffff)
  2909  	sum2 = uint64(rem) * sum1
  2910  	sum2 = sum2 % uint64(BASE)
  2911  	sum1 = sum1 + (adler2&uint64(0xffff) + uint64(BASE) - uint64(1))
  2912  	sum2 = sum2 + (adler1>>16&uint64(0xffff) + adler2>>16&uint64(0xffff) + uint64(BASE) - ULong(rem))
  2913  	if sum1 >= uint64(BASE) {
  2914  		sum1 = sum1 - uint64(BASE)
  2915  	}
  2916  	if sum1 >= uint64(BASE) {
  2917  		sum1 = sum1 - uint64(BASE)
  2918  	}
  2919  	if sum2 >= uint64(uint64(BASE))<<1 {
  2920  		sum2 = sum2 - uint64(uint64(BASE))<<1
  2921  	}
  2922  	if sum2 >= uint64(BASE) {
  2923  		sum2 = sum2 - uint64(BASE)
  2924  	}
  2925  	return sum1 | sum2<<16
  2926  }
  2927  
  2928  // =========================================================================
  2929  func Xadler32_combine(tls *libc.TLS, adler1 ULong, adler2 ULong, len2 Off_t) ULong { /* adler32.c:172:15: */
  2930  	return adler32_combine_(tls, adler1, adler2, len2)
  2931  }
  2932  
  2933  func Xadler32_combine64(tls *libc.TLS, adler1 ULong, adler2 ULong, len2 Off_t) ULong { /* adler32.c:180:15: */
  2934  	return adler32_combine_(tls, adler1, adler2, len2)
  2935  }
  2936  
  2937  // ===========================================================================
  2938  //      Compresses the source buffer into the destination buffer. The level
  2939  //    parameter has the same meaning as in deflateInit.  sourceLen is the byte
  2940  //    length of the source buffer. Upon entry, destLen is the total size of the
  2941  //    destination buffer, which must be at least 0.1% larger than sourceLen plus
  2942  //    12 bytes. Upon exit, destLen is the actual size of the compressed buffer.
  2943  //
  2944  //      compress2 returns Z_OK if success, Z_MEM_ERROR if there was not enough
  2945  //    memory, Z_BUF_ERROR if there was not enough room in the output buffer,
  2946  //    Z_STREAM_ERROR if the level parameter is invalid.
  2947  func Xcompress2(tls *libc.TLS, dest uintptr, destLen uintptr, source uintptr, sourceLen ULong, level int32) int32 { /* compress.c:22:13: */
  2948  	bp := tls.Alloc(112)
  2949  	defer tls.Free(112)
  2950  
  2951  	// var stream Z_stream at bp, 112
  2952  
  2953  	var err int32
  2954  	var max UInt = libc.Uint32(libc.Uint32FromInt32(-1))
  2955  	var left ULong
  2956  
  2957  	left = *(*ULongf)(unsafe.Pointer(destLen))
  2958  	*(*ULongf)(unsafe.Pointer(destLen)) = uint64(0)
  2959  
  2960  	(*Z_stream)(unsafe.Pointer(bp /* &stream */)).Fzalloc = uintptr(0)
  2961  	(*Z_stream)(unsafe.Pointer(bp /* &stream */)).Fzfree = uintptr(0)
  2962  	(*Z_stream)(unsafe.Pointer(bp /* &stream */)).Fopaque = uintptr(0)
  2963  
  2964  	err = XdeflateInit_(tls, bp, level, ts, int32(unsafe.Sizeof(Z_stream{})))
  2965  	if err != Z_OK {
  2966  		return err
  2967  	}
  2968  
  2969  	(*Z_stream)(unsafe.Pointer(bp /* &stream */)).Fnext_out = dest
  2970  	(*Z_stream)(unsafe.Pointer(bp /* &stream */)).Favail_out = UInt(0)
  2971  	(*Z_stream)(unsafe.Pointer(bp /* &stream */)).Fnext_in = source
  2972  	(*Z_stream)(unsafe.Pointer(bp /* &stream */)).Favail_in = UInt(0)
  2973  
  2974  	for ok := true; ok; ok = err == Z_OK {
  2975  		if (*Z_stream)(unsafe.Pointer(bp)).Favail_out == UInt(0) {
  2976  			(*Z_stream)(unsafe.Pointer(bp /* &stream */)).Favail_out = func() uint32 {
  2977  				if left > ULong(max) {
  2978  					return max
  2979  				}
  2980  				return UInt(left)
  2981  			}()
  2982  			left = left - ULong((*Z_stream)(unsafe.Pointer(bp)).Favail_out)
  2983  		}
  2984  		if (*Z_stream)(unsafe.Pointer(bp)).Favail_in == UInt(0) {
  2985  			(*Z_stream)(unsafe.Pointer(bp /* &stream */)).Favail_in = func() uint32 {
  2986  				if sourceLen > ULong(max) {
  2987  					return max
  2988  				}
  2989  				return UInt(sourceLen)
  2990  			}()
  2991  			sourceLen = sourceLen - ULong((*Z_stream)(unsafe.Pointer(bp)).Favail_in)
  2992  		}
  2993  		err = Xdeflate(tls, bp, func() int32 {
  2994  			if sourceLen != 0 {
  2995  				return Z_NO_FLUSH
  2996  			}
  2997  			return Z_FINISH
  2998  		}())
  2999  	}
  3000  
  3001  	*(*ULongf)(unsafe.Pointer(destLen)) = (*Z_stream)(unsafe.Pointer(bp /* &stream */)).Ftotal_out
  3002  	XdeflateEnd(tls, bp)
  3003  	if err == Z_STREAM_END {
  3004  		return Z_OK
  3005  	}
  3006  	return err
  3007  }
  3008  
  3009  // ===========================================================================
  3010  func Xcompress(tls *libc.TLS, dest uintptr, destLen uintptr, source uintptr, sourceLen ULong) int32 { /* compress.c:68:13: */
  3011  	return Xcompress2(tls, dest, destLen, source, sourceLen, -1)
  3012  }
  3013  
  3014  // ===========================================================================
  3015  //      If the default memLevel or windowBits for deflateInit() is changed, then
  3016  //    this function needs to be updated.
  3017  //
  3018  func XcompressBound(tls *libc.TLS, sourceLen ULong) ULong { /* compress.c:81:15: */
  3019  	return sourceLen + sourceLen>>12 + sourceLen>>14 + sourceLen>>25 + uint64(13)
  3020  }
  3021  
  3022  // ========================================================================
  3023  // Tables of CRC-32s of all single-byte values, made by make_crc_table().
  3024  // crc32.h -- tables for rapid CRC calculation
  3025  // Generated automatically by crc32.c
  3026  
  3027  var crc_table = [8][256]Z_crc_t{
  3028  	{
  3029  		uint32(0x00000000), uint32(0x77073096), uint32(0xee0e612c), uint32(0x990951ba), uint32(0x076dc419),
  3030  		uint32(0x706af48f), uint32(0xe963a535), uint32(0x9e6495a3), uint32(0x0edb8832), uint32(0x79dcb8a4),
  3031  		uint32(0xe0d5e91e), uint32(0x97d2d988), uint32(0x09b64c2b), uint32(0x7eb17cbd), uint32(0xe7b82d07),
  3032  		uint32(0x90bf1d91), uint32(0x1db71064), uint32(0x6ab020f2), uint32(0xf3b97148), uint32(0x84be41de),
  3033  		uint32(0x1adad47d), uint32(0x6ddde4eb), uint32(0xf4d4b551), uint32(0x83d385c7), uint32(0x136c9856),
  3034  		uint32(0x646ba8c0), uint32(0xfd62f97a), uint32(0x8a65c9ec), uint32(0x14015c4f), uint32(0x63066cd9),
  3035  		uint32(0xfa0f3d63), uint32(0x8d080df5), uint32(0x3b6e20c8), uint32(0x4c69105e), uint32(0xd56041e4),
  3036  		uint32(0xa2677172), uint32(0x3c03e4d1), uint32(0x4b04d447), uint32(0xd20d85fd), uint32(0xa50ab56b),
  3037  		uint32(0x35b5a8fa), uint32(0x42b2986c), uint32(0xdbbbc9d6), uint32(0xacbcf940), uint32(0x32d86ce3),
  3038  		uint32(0x45df5c75), uint32(0xdcd60dcf), uint32(0xabd13d59), uint32(0x26d930ac), uint32(0x51de003a),
  3039  		uint32(0xc8d75180), uint32(0xbfd06116), uint32(0x21b4f4b5), uint32(0x56b3c423), uint32(0xcfba9599),
  3040  		uint32(0xb8bda50f), uint32(0x2802b89e), uint32(0x5f058808), uint32(0xc60cd9b2), uint32(0xb10be924),
  3041  		uint32(0x2f6f7c87), uint32(0x58684c11), uint32(0xc1611dab), uint32(0xb6662d3d), uint32(0x76dc4190),
  3042  		uint32(0x01db7106), uint32(0x98d220bc), uint32(0xefd5102a), uint32(0x71b18589), uint32(0x06b6b51f),
  3043  		uint32(0x9fbfe4a5), uint32(0xe8b8d433), uint32(0x7807c9a2), uint32(0x0f00f934), uint32(0x9609a88e),
  3044  		uint32(0xe10e9818), uint32(0x7f6a0dbb), uint32(0x086d3d2d), uint32(0x91646c97), uint32(0xe6635c01),
  3045  		uint32(0x6b6b51f4), uint32(0x1c6c6162), uint32(0x856530d8), uint32(0xf262004e), uint32(0x6c0695ed),
  3046  		uint32(0x1b01a57b), uint32(0x8208f4c1), uint32(0xf50fc457), uint32(0x65b0d9c6), uint32(0x12b7e950),
  3047  		uint32(0x8bbeb8ea), uint32(0xfcb9887c), uint32(0x62dd1ddf), uint32(0x15da2d49), uint32(0x8cd37cf3),
  3048  		uint32(0xfbd44c65), uint32(0x4db26158), uint32(0x3ab551ce), uint32(0xa3bc0074), uint32(0xd4bb30e2),
  3049  		uint32(0x4adfa541), uint32(0x3dd895d7), uint32(0xa4d1c46d), uint32(0xd3d6f4fb), uint32(0x4369e96a),
  3050  		uint32(0x346ed9fc), uint32(0xad678846), uint32(0xda60b8d0), uint32(0x44042d73), uint32(0x33031de5),
  3051  		uint32(0xaa0a4c5f), uint32(0xdd0d7cc9), uint32(0x5005713c), uint32(0x270241aa), uint32(0xbe0b1010),
  3052  		uint32(0xc90c2086), uint32(0x5768b525), uint32(0x206f85b3), uint32(0xb966d409), uint32(0xce61e49f),
  3053  		uint32(0x5edef90e), uint32(0x29d9c998), uint32(0xb0d09822), uint32(0xc7d7a8b4), uint32(0x59b33d17),
  3054  		uint32(0x2eb40d81), uint32(0xb7bd5c3b), uint32(0xc0ba6cad), uint32(0xedb88320), uint32(0x9abfb3b6),
  3055  		uint32(0x03b6e20c), uint32(0x74b1d29a), uint32(0xead54739), uint32(0x9dd277af), uint32(0x04db2615),
  3056  		uint32(0x73dc1683), uint32(0xe3630b12), uint32(0x94643b84), uint32(0x0d6d6a3e), uint32(0x7a6a5aa8),
  3057  		uint32(0xe40ecf0b), uint32(0x9309ff9d), uint32(0x0a00ae27), uint32(0x7d079eb1), uint32(0xf00f9344),
  3058  		uint32(0x8708a3d2), uint32(0x1e01f268), uint32(0x6906c2fe), uint32(0xf762575d), uint32(0x806567cb),
  3059  		uint32(0x196c3671), uint32(0x6e6b06e7), uint32(0xfed41b76), uint32(0x89d32be0), uint32(0x10da7a5a),
  3060  		uint32(0x67dd4acc), uint32(0xf9b9df6f), uint32(0x8ebeeff9), uint32(0x17b7be43), uint32(0x60b08ed5),
  3061  		uint32(0xd6d6a3e8), uint32(0xa1d1937e), uint32(0x38d8c2c4), uint32(0x4fdff252), uint32(0xd1bb67f1),
  3062  		uint32(0xa6bc5767), uint32(0x3fb506dd), uint32(0x48b2364b), uint32(0xd80d2bda), uint32(0xaf0a1b4c),
  3063  		uint32(0x36034af6), uint32(0x41047a60), uint32(0xdf60efc3), uint32(0xa867df55), uint32(0x316e8eef),
  3064  		uint32(0x4669be79), uint32(0xcb61b38c), uint32(0xbc66831a), uint32(0x256fd2a0), uint32(0x5268e236),
  3065  		uint32(0xcc0c7795), uint32(0xbb0b4703), uint32(0x220216b9), uint32(0x5505262f), uint32(0xc5ba3bbe),
  3066  		uint32(0xb2bd0b28), uint32(0x2bb45a92), uint32(0x5cb36a04), uint32(0xc2d7ffa7), uint32(0xb5d0cf31),
  3067  		uint32(0x2cd99e8b), uint32(0x5bdeae1d), uint32(0x9b64c2b0), uint32(0xec63f226), uint32(0x756aa39c),
  3068  		uint32(0x026d930a), uint32(0x9c0906a9), uint32(0xeb0e363f), uint32(0x72076785), uint32(0x05005713),
  3069  		uint32(0x95bf4a82), uint32(0xe2b87a14), uint32(0x7bb12bae), uint32(0x0cb61b38), uint32(0x92d28e9b),
  3070  		uint32(0xe5d5be0d), uint32(0x7cdcefb7), uint32(0x0bdbdf21), uint32(0x86d3d2d4), uint32(0xf1d4e242),
  3071  		uint32(0x68ddb3f8), uint32(0x1fda836e), uint32(0x81be16cd), uint32(0xf6b9265b), uint32(0x6fb077e1),
  3072  		uint32(0x18b74777), uint32(0x88085ae6), uint32(0xff0f6a70), uint32(0x66063bca), uint32(0x11010b5c),
  3073  		uint32(0x8f659eff), uint32(0xf862ae69), uint32(0x616bffd3), uint32(0x166ccf45), uint32(0xa00ae278),
  3074  		uint32(0xd70dd2ee), uint32(0x4e048354), uint32(0x3903b3c2), uint32(0xa7672661), uint32(0xd06016f7),
  3075  		uint32(0x4969474d), uint32(0x3e6e77db), uint32(0xaed16a4a), uint32(0xd9d65adc), uint32(0x40df0b66),
  3076  		uint32(0x37d83bf0), uint32(0xa9bcae53), uint32(0xdebb9ec5), uint32(0x47b2cf7f), uint32(0x30b5ffe9),
  3077  		uint32(0xbdbdf21c), uint32(0xcabac28a), uint32(0x53b39330), uint32(0x24b4a3a6), uint32(0xbad03605),
  3078  		uint32(0xcdd70693), uint32(0x54de5729), uint32(0x23d967bf), uint32(0xb3667a2e), uint32(0xc4614ab8),
  3079  		uint32(0x5d681b02), uint32(0x2a6f2b94), uint32(0xb40bbe37), uint32(0xc30c8ea1), uint32(0x5a05df1b),
  3080  		uint32(0x2d02ef8d),
  3081  	},
  3082  	{
  3083  		uint32(0x00000000), uint32(0x191b3141), uint32(0x32366282), uint32(0x2b2d53c3), uint32(0x646cc504),
  3084  		uint32(0x7d77f445), uint32(0x565aa786), uint32(0x4f4196c7), uint32(0xc8d98a08), uint32(0xd1c2bb49),
  3085  		uint32(0xfaefe88a), uint32(0xe3f4d9cb), uint32(0xacb54f0c), uint32(0xb5ae7e4d), uint32(0x9e832d8e),
  3086  		uint32(0x87981ccf), uint32(0x4ac21251), uint32(0x53d92310), uint32(0x78f470d3), uint32(0x61ef4192),
  3087  		uint32(0x2eaed755), uint32(0x37b5e614), uint32(0x1c98b5d7), uint32(0x05838496), uint32(0x821b9859),
  3088  		uint32(0x9b00a918), uint32(0xb02dfadb), uint32(0xa936cb9a), uint32(0xe6775d5d), uint32(0xff6c6c1c),
  3089  		uint32(0xd4413fdf), uint32(0xcd5a0e9e), uint32(0x958424a2), uint32(0x8c9f15e3), uint32(0xa7b24620),
  3090  		uint32(0xbea97761), uint32(0xf1e8e1a6), uint32(0xe8f3d0e7), uint32(0xc3de8324), uint32(0xdac5b265),
  3091  		uint32(0x5d5daeaa), uint32(0x44469feb), uint32(0x6f6bcc28), uint32(0x7670fd69), uint32(0x39316bae),
  3092  		uint32(0x202a5aef), uint32(0x0b07092c), uint32(0x121c386d), uint32(0xdf4636f3), uint32(0xc65d07b2),
  3093  		uint32(0xed705471), uint32(0xf46b6530), uint32(0xbb2af3f7), uint32(0xa231c2b6), uint32(0x891c9175),
  3094  		uint32(0x9007a034), uint32(0x179fbcfb), uint32(0x0e848dba), uint32(0x25a9de79), uint32(0x3cb2ef38),
  3095  		uint32(0x73f379ff), uint32(0x6ae848be), uint32(0x41c51b7d), uint32(0x58de2a3c), uint32(0xf0794f05),
  3096  		uint32(0xe9627e44), uint32(0xc24f2d87), uint32(0xdb541cc6), uint32(0x94158a01), uint32(0x8d0ebb40),
  3097  		uint32(0xa623e883), uint32(0xbf38d9c2), uint32(0x38a0c50d), uint32(0x21bbf44c), uint32(0x0a96a78f),
  3098  		uint32(0x138d96ce), uint32(0x5ccc0009), uint32(0x45d73148), uint32(0x6efa628b), uint32(0x77e153ca),
  3099  		uint32(0xbabb5d54), uint32(0xa3a06c15), uint32(0x888d3fd6), uint32(0x91960e97), uint32(0xded79850),
  3100  		uint32(0xc7cca911), uint32(0xece1fad2), uint32(0xf5facb93), uint32(0x7262d75c), uint32(0x6b79e61d),
  3101  		uint32(0x4054b5de), uint32(0x594f849f), uint32(0x160e1258), uint32(0x0f152319), uint32(0x243870da),
  3102  		uint32(0x3d23419b), uint32(0x65fd6ba7), uint32(0x7ce65ae6), uint32(0x57cb0925), uint32(0x4ed03864),
  3103  		uint32(0x0191aea3), uint32(0x188a9fe2), uint32(0x33a7cc21), uint32(0x2abcfd60), uint32(0xad24e1af),
  3104  		uint32(0xb43fd0ee), uint32(0x9f12832d), uint32(0x8609b26c), uint32(0xc94824ab), uint32(0xd05315ea),
  3105  		uint32(0xfb7e4629), uint32(0xe2657768), uint32(0x2f3f79f6), uint32(0x362448b7), uint32(0x1d091b74),
  3106  		uint32(0x04122a35), uint32(0x4b53bcf2), uint32(0x52488db3), uint32(0x7965de70), uint32(0x607eef31),
  3107  		uint32(0xe7e6f3fe), uint32(0xfefdc2bf), uint32(0xd5d0917c), uint32(0xcccba03d), uint32(0x838a36fa),
  3108  		uint32(0x9a9107bb), uint32(0xb1bc5478), uint32(0xa8a76539), uint32(0x3b83984b), uint32(0x2298a90a),
  3109  		uint32(0x09b5fac9), uint32(0x10aecb88), uint32(0x5fef5d4f), uint32(0x46f46c0e), uint32(0x6dd93fcd),
  3110  		uint32(0x74c20e8c), uint32(0xf35a1243), uint32(0xea412302), uint32(0xc16c70c1), uint32(0xd8774180),
  3111  		uint32(0x9736d747), uint32(0x8e2de606), uint32(0xa500b5c5), uint32(0xbc1b8484), uint32(0x71418a1a),
  3112  		uint32(0x685abb5b), uint32(0x4377e898), uint32(0x5a6cd9d9), uint32(0x152d4f1e), uint32(0x0c367e5f),
  3113  		uint32(0x271b2d9c), uint32(0x3e001cdd), uint32(0xb9980012), uint32(0xa0833153), uint32(0x8bae6290),
  3114  		uint32(0x92b553d1), uint32(0xddf4c516), uint32(0xc4eff457), uint32(0xefc2a794), uint32(0xf6d996d5),
  3115  		uint32(0xae07bce9), uint32(0xb71c8da8), uint32(0x9c31de6b), uint32(0x852aef2a), uint32(0xca6b79ed),
  3116  		uint32(0xd37048ac), uint32(0xf85d1b6f), uint32(0xe1462a2e), uint32(0x66de36e1), uint32(0x7fc507a0),
  3117  		uint32(0x54e85463), uint32(0x4df36522), uint32(0x02b2f3e5), uint32(0x1ba9c2a4), uint32(0x30849167),
  3118  		uint32(0x299fa026), uint32(0xe4c5aeb8), uint32(0xfdde9ff9), uint32(0xd6f3cc3a), uint32(0xcfe8fd7b),
  3119  		uint32(0x80a96bbc), uint32(0x99b25afd), uint32(0xb29f093e), uint32(0xab84387f), uint32(0x2c1c24b0),
  3120  		uint32(0x350715f1), uint32(0x1e2a4632), uint32(0x07317773), uint32(0x4870e1b4), uint32(0x516bd0f5),
  3121  		uint32(0x7a468336), uint32(0x635db277), uint32(0xcbfad74e), uint32(0xd2e1e60f), uint32(0xf9ccb5cc),
  3122  		uint32(0xe0d7848d), uint32(0xaf96124a), uint32(0xb68d230b), uint32(0x9da070c8), uint32(0x84bb4189),
  3123  		uint32(0x03235d46), uint32(0x1a386c07), uint32(0x31153fc4), uint32(0x280e0e85), uint32(0x674f9842),
  3124  		uint32(0x7e54a903), uint32(0x5579fac0), uint32(0x4c62cb81), uint32(0x8138c51f), uint32(0x9823f45e),
  3125  		uint32(0xb30ea79d), uint32(0xaa1596dc), uint32(0xe554001b), uint32(0xfc4f315a), uint32(0xd7626299),
  3126  		uint32(0xce7953d8), uint32(0x49e14f17), uint32(0x50fa7e56), uint32(0x7bd72d95), uint32(0x62cc1cd4),
  3127  		uint32(0x2d8d8a13), uint32(0x3496bb52), uint32(0x1fbbe891), uint32(0x06a0d9d0), uint32(0x5e7ef3ec),
  3128  		uint32(0x4765c2ad), uint32(0x6c48916e), uint32(0x7553a02f), uint32(0x3a1236e8), uint32(0x230907a9),
  3129  		uint32(0x0824546a), uint32(0x113f652b), uint32(0x96a779e4), uint32(0x8fbc48a5), uint32(0xa4911b66),
  3130  		uint32(0xbd8a2a27), uint32(0xf2cbbce0), uint32(0xebd08da1), uint32(0xc0fdde62), uint32(0xd9e6ef23),
  3131  		uint32(0x14bce1bd), uint32(0x0da7d0fc), uint32(0x268a833f), uint32(0x3f91b27e), uint32(0x70d024b9),
  3132  		uint32(0x69cb15f8), uint32(0x42e6463b), uint32(0x5bfd777a), uint32(0xdc656bb5), uint32(0xc57e5af4),
  3133  		uint32(0xee530937), uint32(0xf7483876), uint32(0xb809aeb1), uint32(0xa1129ff0), uint32(0x8a3fcc33),
  3134  		uint32(0x9324fd72),
  3135  	},
  3136  	{
  3137  		uint32(0x00000000), uint32(0x01c26a37), uint32(0x0384d46e), uint32(0x0246be59), uint32(0x0709a8dc),
  3138  		uint32(0x06cbc2eb), uint32(0x048d7cb2), uint32(0x054f1685), uint32(0x0e1351b8), uint32(0x0fd13b8f),
  3139  		uint32(0x0d9785d6), uint32(0x0c55efe1), uint32(0x091af964), uint32(0x08d89353), uint32(0x0a9e2d0a),
  3140  		uint32(0x0b5c473d), uint32(0x1c26a370), uint32(0x1de4c947), uint32(0x1fa2771e), uint32(0x1e601d29),
  3141  		uint32(0x1b2f0bac), uint32(0x1aed619b), uint32(0x18abdfc2), uint32(0x1969b5f5), uint32(0x1235f2c8),
  3142  		uint32(0x13f798ff), uint32(0x11b126a6), uint32(0x10734c91), uint32(0x153c5a14), uint32(0x14fe3023),
  3143  		uint32(0x16b88e7a), uint32(0x177ae44d), uint32(0x384d46e0), uint32(0x398f2cd7), uint32(0x3bc9928e),
  3144  		uint32(0x3a0bf8b9), uint32(0x3f44ee3c), uint32(0x3e86840b), uint32(0x3cc03a52), uint32(0x3d025065),
  3145  		uint32(0x365e1758), uint32(0x379c7d6f), uint32(0x35dac336), uint32(0x3418a901), uint32(0x3157bf84),
  3146  		uint32(0x3095d5b3), uint32(0x32d36bea), uint32(0x331101dd), uint32(0x246be590), uint32(0x25a98fa7),
  3147  		uint32(0x27ef31fe), uint32(0x262d5bc9), uint32(0x23624d4c), uint32(0x22a0277b), uint32(0x20e69922),
  3148  		uint32(0x2124f315), uint32(0x2a78b428), uint32(0x2bbade1f), uint32(0x29fc6046), uint32(0x283e0a71),
  3149  		uint32(0x2d711cf4), uint32(0x2cb376c3), uint32(0x2ef5c89a), uint32(0x2f37a2ad), uint32(0x709a8dc0),
  3150  		uint32(0x7158e7f7), uint32(0x731e59ae), uint32(0x72dc3399), uint32(0x7793251c), uint32(0x76514f2b),
  3151  		uint32(0x7417f172), uint32(0x75d59b45), uint32(0x7e89dc78), uint32(0x7f4bb64f), uint32(0x7d0d0816),
  3152  		uint32(0x7ccf6221), uint32(0x798074a4), uint32(0x78421e93), uint32(0x7a04a0ca), uint32(0x7bc6cafd),
  3153  		uint32(0x6cbc2eb0), uint32(0x6d7e4487), uint32(0x6f38fade), uint32(0x6efa90e9), uint32(0x6bb5866c),
  3154  		uint32(0x6a77ec5b), uint32(0x68315202), uint32(0x69f33835), uint32(0x62af7f08), uint32(0x636d153f),
  3155  		uint32(0x612bab66), uint32(0x60e9c151), uint32(0x65a6d7d4), uint32(0x6464bde3), uint32(0x662203ba),
  3156  		uint32(0x67e0698d), uint32(0x48d7cb20), uint32(0x4915a117), uint32(0x4b531f4e), uint32(0x4a917579),
  3157  		uint32(0x4fde63fc), uint32(0x4e1c09cb), uint32(0x4c5ab792), uint32(0x4d98dda5), uint32(0x46c49a98),
  3158  		uint32(0x4706f0af), uint32(0x45404ef6), uint32(0x448224c1), uint32(0x41cd3244), uint32(0x400f5873),
  3159  		uint32(0x4249e62a), uint32(0x438b8c1d), uint32(0x54f16850), uint32(0x55330267), uint32(0x5775bc3e),
  3160  		uint32(0x56b7d609), uint32(0x53f8c08c), uint32(0x523aaabb), uint32(0x507c14e2), uint32(0x51be7ed5),
  3161  		uint32(0x5ae239e8), uint32(0x5b2053df), uint32(0x5966ed86), uint32(0x58a487b1), uint32(0x5deb9134),
  3162  		uint32(0x5c29fb03), uint32(0x5e6f455a), uint32(0x5fad2f6d), uint32(0xe1351b80), uint32(0xe0f771b7),
  3163  		uint32(0xe2b1cfee), uint32(0xe373a5d9), uint32(0xe63cb35c), uint32(0xe7fed96b), uint32(0xe5b86732),
  3164  		uint32(0xe47a0d05), uint32(0xef264a38), uint32(0xeee4200f), uint32(0xeca29e56), uint32(0xed60f461),
  3165  		uint32(0xe82fe2e4), uint32(0xe9ed88d3), uint32(0xebab368a), uint32(0xea695cbd), uint32(0xfd13b8f0),
  3166  		uint32(0xfcd1d2c7), uint32(0xfe976c9e), uint32(0xff5506a9), uint32(0xfa1a102c), uint32(0xfbd87a1b),
  3167  		uint32(0xf99ec442), uint32(0xf85cae75), uint32(0xf300e948), uint32(0xf2c2837f), uint32(0xf0843d26),
  3168  		uint32(0xf1465711), uint32(0xf4094194), uint32(0xf5cb2ba3), uint32(0xf78d95fa), uint32(0xf64fffcd),
  3169  		uint32(0xd9785d60), uint32(0xd8ba3757), uint32(0xdafc890e), uint32(0xdb3ee339), uint32(0xde71f5bc),
  3170  		uint32(0xdfb39f8b), uint32(0xddf521d2), uint32(0xdc374be5), uint32(0xd76b0cd8), uint32(0xd6a966ef),
  3171  		uint32(0xd4efd8b6), uint32(0xd52db281), uint32(0xd062a404), uint32(0xd1a0ce33), uint32(0xd3e6706a),
  3172  		uint32(0xd2241a5d), uint32(0xc55efe10), uint32(0xc49c9427), uint32(0xc6da2a7e), uint32(0xc7184049),
  3173  		uint32(0xc25756cc), uint32(0xc3953cfb), uint32(0xc1d382a2), uint32(0xc011e895), uint32(0xcb4dafa8),
  3174  		uint32(0xca8fc59f), uint32(0xc8c97bc6), uint32(0xc90b11f1), uint32(0xcc440774), uint32(0xcd866d43),
  3175  		uint32(0xcfc0d31a), uint32(0xce02b92d), uint32(0x91af9640), uint32(0x906dfc77), uint32(0x922b422e),
  3176  		uint32(0x93e92819), uint32(0x96a63e9c), uint32(0x976454ab), uint32(0x9522eaf2), uint32(0x94e080c5),
  3177  		uint32(0x9fbcc7f8), uint32(0x9e7eadcf), uint32(0x9c381396), uint32(0x9dfa79a1), uint32(0x98b56f24),
  3178  		uint32(0x99770513), uint32(0x9b31bb4a), uint32(0x9af3d17d), uint32(0x8d893530), uint32(0x8c4b5f07),
  3179  		uint32(0x8e0de15e), uint32(0x8fcf8b69), uint32(0x8a809dec), uint32(0x8b42f7db), uint32(0x89044982),
  3180  		uint32(0x88c623b5), uint32(0x839a6488), uint32(0x82580ebf), uint32(0x801eb0e6), uint32(0x81dcdad1),
  3181  		uint32(0x8493cc54), uint32(0x8551a663), uint32(0x8717183a), uint32(0x86d5720d), uint32(0xa9e2d0a0),
  3182  		uint32(0xa820ba97), uint32(0xaa6604ce), uint32(0xaba46ef9), uint32(0xaeeb787c), uint32(0xaf29124b),
  3183  		uint32(0xad6fac12), uint32(0xacadc625), uint32(0xa7f18118), uint32(0xa633eb2f), uint32(0xa4755576),
  3184  		uint32(0xa5b73f41), uint32(0xa0f829c4), uint32(0xa13a43f3), uint32(0xa37cfdaa), uint32(0xa2be979d),
  3185  		uint32(0xb5c473d0), uint32(0xb40619e7), uint32(0xb640a7be), uint32(0xb782cd89), uint32(0xb2cddb0c),
  3186  		uint32(0xb30fb13b), uint32(0xb1490f62), uint32(0xb08b6555), uint32(0xbbd72268), uint32(0xba15485f),
  3187  		uint32(0xb853f606), uint32(0xb9919c31), uint32(0xbcde8ab4), uint32(0xbd1ce083), uint32(0xbf5a5eda),
  3188  		uint32(0xbe9834ed),
  3189  	},
  3190  	{
  3191  		uint32(0x00000000), uint32(0xb8bc6765), uint32(0xaa09c88b), uint32(0x12b5afee), uint32(0x8f629757),
  3192  		uint32(0x37def032), uint32(0x256b5fdc), uint32(0x9dd738b9), uint32(0xc5b428ef), uint32(0x7d084f8a),
  3193  		uint32(0x6fbde064), uint32(0xd7018701), uint32(0x4ad6bfb8), uint32(0xf26ad8dd), uint32(0xe0df7733),
  3194  		uint32(0x58631056), uint32(0x5019579f), uint32(0xe8a530fa), uint32(0xfa109f14), uint32(0x42acf871),
  3195  		uint32(0xdf7bc0c8), uint32(0x67c7a7ad), uint32(0x75720843), uint32(0xcdce6f26), uint32(0x95ad7f70),
  3196  		uint32(0x2d111815), uint32(0x3fa4b7fb), uint32(0x8718d09e), uint32(0x1acfe827), uint32(0xa2738f42),
  3197  		uint32(0xb0c620ac), uint32(0x087a47c9), uint32(0xa032af3e), uint32(0x188ec85b), uint32(0x0a3b67b5),
  3198  		uint32(0xb28700d0), uint32(0x2f503869), uint32(0x97ec5f0c), uint32(0x8559f0e2), uint32(0x3de59787),
  3199  		uint32(0x658687d1), uint32(0xdd3ae0b4), uint32(0xcf8f4f5a), uint32(0x7733283f), uint32(0xeae41086),
  3200  		uint32(0x525877e3), uint32(0x40edd80d), uint32(0xf851bf68), uint32(0xf02bf8a1), uint32(0x48979fc4),
  3201  		uint32(0x5a22302a), uint32(0xe29e574f), uint32(0x7f496ff6), uint32(0xc7f50893), uint32(0xd540a77d),
  3202  		uint32(0x6dfcc018), uint32(0x359fd04e), uint32(0x8d23b72b), uint32(0x9f9618c5), uint32(0x272a7fa0),
  3203  		uint32(0xbafd4719), uint32(0x0241207c), uint32(0x10f48f92), uint32(0xa848e8f7), uint32(0x9b14583d),
  3204  		uint32(0x23a83f58), uint32(0x311d90b6), uint32(0x89a1f7d3), uint32(0x1476cf6a), uint32(0xaccaa80f),
  3205  		uint32(0xbe7f07e1), uint32(0x06c36084), uint32(0x5ea070d2), uint32(0xe61c17b7), uint32(0xf4a9b859),
  3206  		uint32(0x4c15df3c), uint32(0xd1c2e785), uint32(0x697e80e0), uint32(0x7bcb2f0e), uint32(0xc377486b),
  3207  		uint32(0xcb0d0fa2), uint32(0x73b168c7), uint32(0x6104c729), uint32(0xd9b8a04c), uint32(0x446f98f5),
  3208  		uint32(0xfcd3ff90), uint32(0xee66507e), uint32(0x56da371b), uint32(0x0eb9274d), uint32(0xb6054028),
  3209  		uint32(0xa4b0efc6), uint32(0x1c0c88a3), uint32(0x81dbb01a), uint32(0x3967d77f), uint32(0x2bd27891),
  3210  		uint32(0x936e1ff4), uint32(0x3b26f703), uint32(0x839a9066), uint32(0x912f3f88), uint32(0x299358ed),
  3211  		uint32(0xb4446054), uint32(0x0cf80731), uint32(0x1e4da8df), uint32(0xa6f1cfba), uint32(0xfe92dfec),
  3212  		uint32(0x462eb889), uint32(0x549b1767), uint32(0xec277002), uint32(0x71f048bb), uint32(0xc94c2fde),
  3213  		uint32(0xdbf98030), uint32(0x6345e755), uint32(0x6b3fa09c), uint32(0xd383c7f9), uint32(0xc1366817),
  3214  		uint32(0x798a0f72), uint32(0xe45d37cb), uint32(0x5ce150ae), uint32(0x4e54ff40), uint32(0xf6e89825),
  3215  		uint32(0xae8b8873), uint32(0x1637ef16), uint32(0x048240f8), uint32(0xbc3e279d), uint32(0x21e91f24),
  3216  		uint32(0x99557841), uint32(0x8be0d7af), uint32(0x335cb0ca), uint32(0xed59b63b), uint32(0x55e5d15e),
  3217  		uint32(0x47507eb0), uint32(0xffec19d5), uint32(0x623b216c), uint32(0xda874609), uint32(0xc832e9e7),
  3218  		uint32(0x708e8e82), uint32(0x28ed9ed4), uint32(0x9051f9b1), uint32(0x82e4565f), uint32(0x3a58313a),
  3219  		uint32(0xa78f0983), uint32(0x1f336ee6), uint32(0x0d86c108), uint32(0xb53aa66d), uint32(0xbd40e1a4),
  3220  		uint32(0x05fc86c1), uint32(0x1749292f), uint32(0xaff54e4a), uint32(0x322276f3), uint32(0x8a9e1196),
  3221  		uint32(0x982bbe78), uint32(0x2097d91d), uint32(0x78f4c94b), uint32(0xc048ae2e), uint32(0xd2fd01c0),
  3222  		uint32(0x6a4166a5), uint32(0xf7965e1c), uint32(0x4f2a3979), uint32(0x5d9f9697), uint32(0xe523f1f2),
  3223  		uint32(0x4d6b1905), uint32(0xf5d77e60), uint32(0xe762d18e), uint32(0x5fdeb6eb), uint32(0xc2098e52),
  3224  		uint32(0x7ab5e937), uint32(0x680046d9), uint32(0xd0bc21bc), uint32(0x88df31ea), uint32(0x3063568f),
  3225  		uint32(0x22d6f961), uint32(0x9a6a9e04), uint32(0x07bda6bd), uint32(0xbf01c1d8), uint32(0xadb46e36),
  3226  		uint32(0x15080953), uint32(0x1d724e9a), uint32(0xa5ce29ff), uint32(0xb77b8611), uint32(0x0fc7e174),
  3227  		uint32(0x9210d9cd), uint32(0x2aacbea8), uint32(0x38191146), uint32(0x80a57623), uint32(0xd8c66675),
  3228  		uint32(0x607a0110), uint32(0x72cfaefe), uint32(0xca73c99b), uint32(0x57a4f122), uint32(0xef189647),
  3229  		uint32(0xfdad39a9), uint32(0x45115ecc), uint32(0x764dee06), uint32(0xcef18963), uint32(0xdc44268d),
  3230  		uint32(0x64f841e8), uint32(0xf92f7951), uint32(0x41931e34), uint32(0x5326b1da), uint32(0xeb9ad6bf),
  3231  		uint32(0xb3f9c6e9), uint32(0x0b45a18c), uint32(0x19f00e62), uint32(0xa14c6907), uint32(0x3c9b51be),
  3232  		uint32(0x842736db), uint32(0x96929935), uint32(0x2e2efe50), uint32(0x2654b999), uint32(0x9ee8defc),
  3233  		uint32(0x8c5d7112), uint32(0x34e11677), uint32(0xa9362ece), uint32(0x118a49ab), uint32(0x033fe645),
  3234  		uint32(0xbb838120), uint32(0xe3e09176), uint32(0x5b5cf613), uint32(0x49e959fd), uint32(0xf1553e98),
  3235  		uint32(0x6c820621), uint32(0xd43e6144), uint32(0xc68bceaa), uint32(0x7e37a9cf), uint32(0xd67f4138),
  3236  		uint32(0x6ec3265d), uint32(0x7c7689b3), uint32(0xc4caeed6), uint32(0x591dd66f), uint32(0xe1a1b10a),
  3237  		uint32(0xf3141ee4), uint32(0x4ba87981), uint32(0x13cb69d7), uint32(0xab770eb2), uint32(0xb9c2a15c),
  3238  		uint32(0x017ec639), uint32(0x9ca9fe80), uint32(0x241599e5), uint32(0x36a0360b), uint32(0x8e1c516e),
  3239  		uint32(0x866616a7), uint32(0x3eda71c2), uint32(0x2c6fde2c), uint32(0x94d3b949), uint32(0x090481f0),
  3240  		uint32(0xb1b8e695), uint32(0xa30d497b), uint32(0x1bb12e1e), uint32(0x43d23e48), uint32(0xfb6e592d),
  3241  		uint32(0xe9dbf6c3), uint32(0x516791a6), uint32(0xccb0a91f), uint32(0x740cce7a), uint32(0x66b96194),
  3242  		uint32(0xde0506f1),
  3243  	},
  3244  	{
  3245  		uint32(0x00000000), uint32(0x96300777), uint32(0x2c610eee), uint32(0xba510999), uint32(0x19c46d07),
  3246  		uint32(0x8ff46a70), uint32(0x35a563e9), uint32(0xa395649e), uint32(0x3288db0e), uint32(0xa4b8dc79),
  3247  		uint32(0x1ee9d5e0), uint32(0x88d9d297), uint32(0x2b4cb609), uint32(0xbd7cb17e), uint32(0x072db8e7),
  3248  		uint32(0x911dbf90), uint32(0x6410b71d), uint32(0xf220b06a), uint32(0x4871b9f3), uint32(0xde41be84),
  3249  		uint32(0x7dd4da1a), uint32(0xebe4dd6d), uint32(0x51b5d4f4), uint32(0xc785d383), uint32(0x56986c13),
  3250  		uint32(0xc0a86b64), uint32(0x7af962fd), uint32(0xecc9658a), uint32(0x4f5c0114), uint32(0xd96c0663),
  3251  		uint32(0x633d0ffa), uint32(0xf50d088d), uint32(0xc8206e3b), uint32(0x5e10694c), uint32(0xe44160d5),
  3252  		uint32(0x727167a2), uint32(0xd1e4033c), uint32(0x47d4044b), uint32(0xfd850dd2), uint32(0x6bb50aa5),
  3253  		uint32(0xfaa8b535), uint32(0x6c98b242), uint32(0xd6c9bbdb), uint32(0x40f9bcac), uint32(0xe36cd832),
  3254  		uint32(0x755cdf45), uint32(0xcf0dd6dc), uint32(0x593dd1ab), uint32(0xac30d926), uint32(0x3a00de51),
  3255  		uint32(0x8051d7c8), uint32(0x1661d0bf), uint32(0xb5f4b421), uint32(0x23c4b356), uint32(0x9995bacf),
  3256  		uint32(0x0fa5bdb8), uint32(0x9eb80228), uint32(0x0888055f), uint32(0xb2d90cc6), uint32(0x24e90bb1),
  3257  		uint32(0x877c6f2f), uint32(0x114c6858), uint32(0xab1d61c1), uint32(0x3d2d66b6), uint32(0x9041dc76),
  3258  		uint32(0x0671db01), uint32(0xbc20d298), uint32(0x2a10d5ef), uint32(0x8985b171), uint32(0x1fb5b606),
  3259  		uint32(0xa5e4bf9f), uint32(0x33d4b8e8), uint32(0xa2c90778), uint32(0x34f9000f), uint32(0x8ea80996),
  3260  		uint32(0x18980ee1), uint32(0xbb0d6a7f), uint32(0x2d3d6d08), uint32(0x976c6491), uint32(0x015c63e6),
  3261  		uint32(0xf4516b6b), uint32(0x62616c1c), uint32(0xd8306585), uint32(0x4e0062f2), uint32(0xed95066c),
  3262  		uint32(0x7ba5011b), uint32(0xc1f40882), uint32(0x57c40ff5), uint32(0xc6d9b065), uint32(0x50e9b712),
  3263  		uint32(0xeab8be8b), uint32(0x7c88b9fc), uint32(0xdf1ddd62), uint32(0x492dda15), uint32(0xf37cd38c),
  3264  		uint32(0x654cd4fb), uint32(0x5861b24d), uint32(0xce51b53a), uint32(0x7400bca3), uint32(0xe230bbd4),
  3265  		uint32(0x41a5df4a), uint32(0xd795d83d), uint32(0x6dc4d1a4), uint32(0xfbf4d6d3), uint32(0x6ae96943),
  3266  		uint32(0xfcd96e34), uint32(0x468867ad), uint32(0xd0b860da), uint32(0x732d0444), uint32(0xe51d0333),
  3267  		uint32(0x5f4c0aaa), uint32(0xc97c0ddd), uint32(0x3c710550), uint32(0xaa410227), uint32(0x10100bbe),
  3268  		uint32(0x86200cc9), uint32(0x25b56857), uint32(0xb3856f20), uint32(0x09d466b9), uint32(0x9fe461ce),
  3269  		uint32(0x0ef9de5e), uint32(0x98c9d929), uint32(0x2298d0b0), uint32(0xb4a8d7c7), uint32(0x173db359),
  3270  		uint32(0x810db42e), uint32(0x3b5cbdb7), uint32(0xad6cbac0), uint32(0x2083b8ed), uint32(0xb6b3bf9a),
  3271  		uint32(0x0ce2b603), uint32(0x9ad2b174), uint32(0x3947d5ea), uint32(0xaf77d29d), uint32(0x1526db04),
  3272  		uint32(0x8316dc73), uint32(0x120b63e3), uint32(0x843b6494), uint32(0x3e6a6d0d), uint32(0xa85a6a7a),
  3273  		uint32(0x0bcf0ee4), uint32(0x9dff0993), uint32(0x27ae000a), uint32(0xb19e077d), uint32(0x44930ff0),
  3274  		uint32(0xd2a30887), uint32(0x68f2011e), uint32(0xfec20669), uint32(0x5d5762f7), uint32(0xcb676580),
  3275  		uint32(0x71366c19), uint32(0xe7066b6e), uint32(0x761bd4fe), uint32(0xe02bd389), uint32(0x5a7ada10),
  3276  		uint32(0xcc4add67), uint32(0x6fdfb9f9), uint32(0xf9efbe8e), uint32(0x43beb717), uint32(0xd58eb060),
  3277  		uint32(0xe8a3d6d6), uint32(0x7e93d1a1), uint32(0xc4c2d838), uint32(0x52f2df4f), uint32(0xf167bbd1),
  3278  		uint32(0x6757bca6), uint32(0xdd06b53f), uint32(0x4b36b248), uint32(0xda2b0dd8), uint32(0x4c1b0aaf),
  3279  		uint32(0xf64a0336), uint32(0x607a0441), uint32(0xc3ef60df), uint32(0x55df67a8), uint32(0xef8e6e31),
  3280  		uint32(0x79be6946), uint32(0x8cb361cb), uint32(0x1a8366bc), uint32(0xa0d26f25), uint32(0x36e26852),
  3281  		uint32(0x95770ccc), uint32(0x03470bbb), uint32(0xb9160222), uint32(0x2f260555), uint32(0xbe3bbac5),
  3282  		uint32(0x280bbdb2), uint32(0x925ab42b), uint32(0x046ab35c), uint32(0xa7ffd7c2), uint32(0x31cfd0b5),
  3283  		uint32(0x8b9ed92c), uint32(0x1daede5b), uint32(0xb0c2649b), uint32(0x26f263ec), uint32(0x9ca36a75),
  3284  		uint32(0x0a936d02), uint32(0xa906099c), uint32(0x3f360eeb), uint32(0x85670772), uint32(0x13570005),
  3285  		uint32(0x824abf95), uint32(0x147ab8e2), uint32(0xae2bb17b), uint32(0x381bb60c), uint32(0x9b8ed292),
  3286  		uint32(0x0dbed5e5), uint32(0xb7efdc7c), uint32(0x21dfdb0b), uint32(0xd4d2d386), uint32(0x42e2d4f1),
  3287  		uint32(0xf8b3dd68), uint32(0x6e83da1f), uint32(0xcd16be81), uint32(0x5b26b9f6), uint32(0xe177b06f),
  3288  		uint32(0x7747b718), uint32(0xe65a0888), uint32(0x706a0fff), uint32(0xca3b0666), uint32(0x5c0b0111),
  3289  		uint32(0xff9e658f), uint32(0x69ae62f8), uint32(0xd3ff6b61), uint32(0x45cf6c16), uint32(0x78e20aa0),
  3290  		uint32(0xeed20dd7), uint32(0x5483044e), uint32(0xc2b30339), uint32(0x612667a7), uint32(0xf71660d0),
  3291  		uint32(0x4d476949), uint32(0xdb776e3e), uint32(0x4a6ad1ae), uint32(0xdc5ad6d9), uint32(0x660bdf40),
  3292  		uint32(0xf03bd837), uint32(0x53aebca9), uint32(0xc59ebbde), uint32(0x7fcfb247), uint32(0xe9ffb530),
  3293  		uint32(0x1cf2bdbd), uint32(0x8ac2baca), uint32(0x3093b353), uint32(0xa6a3b424), uint32(0x0536d0ba),
  3294  		uint32(0x9306d7cd), uint32(0x2957de54), uint32(0xbf67d923), uint32(0x2e7a66b3), uint32(0xb84a61c4),
  3295  		uint32(0x021b685d), uint32(0x942b6f2a), uint32(0x37be0bb4), uint32(0xa18e0cc3), uint32(0x1bdf055a),
  3296  		uint32(0x8def022d),
  3297  	},
  3298  	{
  3299  		uint32(0x00000000), uint32(0x41311b19), uint32(0x82623632), uint32(0xc3532d2b), uint32(0x04c56c64),
  3300  		uint32(0x45f4777d), uint32(0x86a75a56), uint32(0xc796414f), uint32(0x088ad9c8), uint32(0x49bbc2d1),
  3301  		uint32(0x8ae8effa), uint32(0xcbd9f4e3), uint32(0x0c4fb5ac), uint32(0x4d7eaeb5), uint32(0x8e2d839e),
  3302  		uint32(0xcf1c9887), uint32(0x5112c24a), uint32(0x1023d953), uint32(0xd370f478), uint32(0x9241ef61),
  3303  		uint32(0x55d7ae2e), uint32(0x14e6b537), uint32(0xd7b5981c), uint32(0x96848305), uint32(0x59981b82),
  3304  		uint32(0x18a9009b), uint32(0xdbfa2db0), uint32(0x9acb36a9), uint32(0x5d5d77e6), uint32(0x1c6c6cff),
  3305  		uint32(0xdf3f41d4), uint32(0x9e0e5acd), uint32(0xa2248495), uint32(0xe3159f8c), uint32(0x2046b2a7),
  3306  		uint32(0x6177a9be), uint32(0xa6e1e8f1), uint32(0xe7d0f3e8), uint32(0x2483dec3), uint32(0x65b2c5da),
  3307  		uint32(0xaaae5d5d), uint32(0xeb9f4644), uint32(0x28cc6b6f), uint32(0x69fd7076), uint32(0xae6b3139),
  3308  		uint32(0xef5a2a20), uint32(0x2c09070b), uint32(0x6d381c12), uint32(0xf33646df), uint32(0xb2075dc6),
  3309  		uint32(0x715470ed), uint32(0x30656bf4), uint32(0xf7f32abb), uint32(0xb6c231a2), uint32(0x75911c89),
  3310  		uint32(0x34a00790), uint32(0xfbbc9f17), uint32(0xba8d840e), uint32(0x79dea925), uint32(0x38efb23c),
  3311  		uint32(0xff79f373), uint32(0xbe48e86a), uint32(0x7d1bc541), uint32(0x3c2ade58), uint32(0x054f79f0),
  3312  		uint32(0x447e62e9), uint32(0x872d4fc2), uint32(0xc61c54db), uint32(0x018a1594), uint32(0x40bb0e8d),
  3313  		uint32(0x83e823a6), uint32(0xc2d938bf), uint32(0x0dc5a038), uint32(0x4cf4bb21), uint32(0x8fa7960a),
  3314  		uint32(0xce968d13), uint32(0x0900cc5c), uint32(0x4831d745), uint32(0x8b62fa6e), uint32(0xca53e177),
  3315  		uint32(0x545dbbba), uint32(0x156ca0a3), uint32(0xd63f8d88), uint32(0x970e9691), uint32(0x5098d7de),
  3316  		uint32(0x11a9ccc7), uint32(0xd2fae1ec), uint32(0x93cbfaf5), uint32(0x5cd76272), uint32(0x1de6796b),
  3317  		uint32(0xdeb55440), uint32(0x9f844f59), uint32(0x58120e16), uint32(0x1923150f), uint32(0xda703824),
  3318  		uint32(0x9b41233d), uint32(0xa76bfd65), uint32(0xe65ae67c), uint32(0x2509cb57), uint32(0x6438d04e),
  3319  		uint32(0xa3ae9101), uint32(0xe29f8a18), uint32(0x21cca733), uint32(0x60fdbc2a), uint32(0xafe124ad),
  3320  		uint32(0xeed03fb4), uint32(0x2d83129f), uint32(0x6cb20986), uint32(0xab2448c9), uint32(0xea1553d0),
  3321  		uint32(0x29467efb), uint32(0x687765e2), uint32(0xf6793f2f), uint32(0xb7482436), uint32(0x741b091d),
  3322  		uint32(0x352a1204), uint32(0xf2bc534b), uint32(0xb38d4852), uint32(0x70de6579), uint32(0x31ef7e60),
  3323  		uint32(0xfef3e6e7), uint32(0xbfc2fdfe), uint32(0x7c91d0d5), uint32(0x3da0cbcc), uint32(0xfa368a83),
  3324  		uint32(0xbb07919a), uint32(0x7854bcb1), uint32(0x3965a7a8), uint32(0x4b98833b), uint32(0x0aa99822),
  3325  		uint32(0xc9fab509), uint32(0x88cbae10), uint32(0x4f5def5f), uint32(0x0e6cf446), uint32(0xcd3fd96d),
  3326  		uint32(0x8c0ec274), uint32(0x43125af3), uint32(0x022341ea), uint32(0xc1706cc1), uint32(0x804177d8),
  3327  		uint32(0x47d73697), uint32(0x06e62d8e), uint32(0xc5b500a5), uint32(0x84841bbc), uint32(0x1a8a4171),
  3328  		uint32(0x5bbb5a68), uint32(0x98e87743), uint32(0xd9d96c5a), uint32(0x1e4f2d15), uint32(0x5f7e360c),
  3329  		uint32(0x9c2d1b27), uint32(0xdd1c003e), uint32(0x120098b9), uint32(0x533183a0), uint32(0x9062ae8b),
  3330  		uint32(0xd153b592), uint32(0x16c5f4dd), uint32(0x57f4efc4), uint32(0x94a7c2ef), uint32(0xd596d9f6),
  3331  		uint32(0xe9bc07ae), uint32(0xa88d1cb7), uint32(0x6bde319c), uint32(0x2aef2a85), uint32(0xed796bca),
  3332  		uint32(0xac4870d3), uint32(0x6f1b5df8), uint32(0x2e2a46e1), uint32(0xe136de66), uint32(0xa007c57f),
  3333  		uint32(0x6354e854), uint32(0x2265f34d), uint32(0xe5f3b202), uint32(0xa4c2a91b), uint32(0x67918430),
  3334  		uint32(0x26a09f29), uint32(0xb8aec5e4), uint32(0xf99fdefd), uint32(0x3accf3d6), uint32(0x7bfde8cf),
  3335  		uint32(0xbc6ba980), uint32(0xfd5ab299), uint32(0x3e099fb2), uint32(0x7f3884ab), uint32(0xb0241c2c),
  3336  		uint32(0xf1150735), uint32(0x32462a1e), uint32(0x73773107), uint32(0xb4e17048), uint32(0xf5d06b51),
  3337  		uint32(0x3683467a), uint32(0x77b25d63), uint32(0x4ed7facb), uint32(0x0fe6e1d2), uint32(0xccb5ccf9),
  3338  		uint32(0x8d84d7e0), uint32(0x4a1296af), uint32(0x0b238db6), uint32(0xc870a09d), uint32(0x8941bb84),
  3339  		uint32(0x465d2303), uint32(0x076c381a), uint32(0xc43f1531), uint32(0x850e0e28), uint32(0x42984f67),
  3340  		uint32(0x03a9547e), uint32(0xc0fa7955), uint32(0x81cb624c), uint32(0x1fc53881), uint32(0x5ef42398),
  3341  		uint32(0x9da70eb3), uint32(0xdc9615aa), uint32(0x1b0054e5), uint32(0x5a314ffc), uint32(0x996262d7),
  3342  		uint32(0xd85379ce), uint32(0x174fe149), uint32(0x567efa50), uint32(0x952dd77b), uint32(0xd41ccc62),
  3343  		uint32(0x138a8d2d), uint32(0x52bb9634), uint32(0x91e8bb1f), uint32(0xd0d9a006), uint32(0xecf37e5e),
  3344  		uint32(0xadc26547), uint32(0x6e91486c), uint32(0x2fa05375), uint32(0xe836123a), uint32(0xa9070923),
  3345  		uint32(0x6a542408), uint32(0x2b653f11), uint32(0xe479a796), uint32(0xa548bc8f), uint32(0x661b91a4),
  3346  		uint32(0x272a8abd), uint32(0xe0bccbf2), uint32(0xa18dd0eb), uint32(0x62defdc0), uint32(0x23efe6d9),
  3347  		uint32(0xbde1bc14), uint32(0xfcd0a70d), uint32(0x3f838a26), uint32(0x7eb2913f), uint32(0xb924d070),
  3348  		uint32(0xf815cb69), uint32(0x3b46e642), uint32(0x7a77fd5b), uint32(0xb56b65dc), uint32(0xf45a7ec5),
  3349  		uint32(0x370953ee), uint32(0x763848f7), uint32(0xb1ae09b8), uint32(0xf09f12a1), uint32(0x33cc3f8a),
  3350  		uint32(0x72fd2493),
  3351  	},
  3352  	{
  3353  		uint32(0x00000000), uint32(0x376ac201), uint32(0x6ed48403), uint32(0x59be4602), uint32(0xdca80907),
  3354  		uint32(0xebc2cb06), uint32(0xb27c8d04), uint32(0x85164f05), uint32(0xb851130e), uint32(0x8f3bd10f),
  3355  		uint32(0xd685970d), uint32(0xe1ef550c), uint32(0x64f91a09), uint32(0x5393d808), uint32(0x0a2d9e0a),
  3356  		uint32(0x3d475c0b), uint32(0x70a3261c), uint32(0x47c9e41d), uint32(0x1e77a21f), uint32(0x291d601e),
  3357  		uint32(0xac0b2f1b), uint32(0x9b61ed1a), uint32(0xc2dfab18), uint32(0xf5b56919), uint32(0xc8f23512),
  3358  		uint32(0xff98f713), uint32(0xa626b111), uint32(0x914c7310), uint32(0x145a3c15), uint32(0x2330fe14),
  3359  		uint32(0x7a8eb816), uint32(0x4de47a17), uint32(0xe0464d38), uint32(0xd72c8f39), uint32(0x8e92c93b),
  3360  		uint32(0xb9f80b3a), uint32(0x3cee443f), uint32(0x0b84863e), uint32(0x523ac03c), uint32(0x6550023d),
  3361  		uint32(0x58175e36), uint32(0x6f7d9c37), uint32(0x36c3da35), uint32(0x01a91834), uint32(0x84bf5731),
  3362  		uint32(0xb3d59530), uint32(0xea6bd332), uint32(0xdd011133), uint32(0x90e56b24), uint32(0xa78fa925),
  3363  		uint32(0xfe31ef27), uint32(0xc95b2d26), uint32(0x4c4d6223), uint32(0x7b27a022), uint32(0x2299e620),
  3364  		uint32(0x15f32421), uint32(0x28b4782a), uint32(0x1fdeba2b), uint32(0x4660fc29), uint32(0x710a3e28),
  3365  		uint32(0xf41c712d), uint32(0xc376b32c), uint32(0x9ac8f52e), uint32(0xada2372f), uint32(0xc08d9a70),
  3366  		uint32(0xf7e75871), uint32(0xae591e73), uint32(0x9933dc72), uint32(0x1c259377), uint32(0x2b4f5176),
  3367  		uint32(0x72f11774), uint32(0x459bd575), uint32(0x78dc897e), uint32(0x4fb64b7f), uint32(0x16080d7d),
  3368  		uint32(0x2162cf7c), uint32(0xa4748079), uint32(0x931e4278), uint32(0xcaa0047a), uint32(0xfdcac67b),
  3369  		uint32(0xb02ebc6c), uint32(0x87447e6d), uint32(0xdefa386f), uint32(0xe990fa6e), uint32(0x6c86b56b),
  3370  		uint32(0x5bec776a), uint32(0x02523168), uint32(0x3538f369), uint32(0x087faf62), uint32(0x3f156d63),
  3371  		uint32(0x66ab2b61), uint32(0x51c1e960), uint32(0xd4d7a665), uint32(0xe3bd6464), uint32(0xba032266),
  3372  		uint32(0x8d69e067), uint32(0x20cbd748), uint32(0x17a11549), uint32(0x4e1f534b), uint32(0x7975914a),
  3373  		uint32(0xfc63de4f), uint32(0xcb091c4e), uint32(0x92b75a4c), uint32(0xa5dd984d), uint32(0x989ac446),
  3374  		uint32(0xaff00647), uint32(0xf64e4045), uint32(0xc1248244), uint32(0x4432cd41), uint32(0x73580f40),
  3375  		uint32(0x2ae64942), uint32(0x1d8c8b43), uint32(0x5068f154), uint32(0x67023355), uint32(0x3ebc7557),
  3376  		uint32(0x09d6b756), uint32(0x8cc0f853), uint32(0xbbaa3a52), uint32(0xe2147c50), uint32(0xd57ebe51),
  3377  		uint32(0xe839e25a), uint32(0xdf53205b), uint32(0x86ed6659), uint32(0xb187a458), uint32(0x3491eb5d),
  3378  		uint32(0x03fb295c), uint32(0x5a456f5e), uint32(0x6d2fad5f), uint32(0x801b35e1), uint32(0xb771f7e0),
  3379  		uint32(0xeecfb1e2), uint32(0xd9a573e3), uint32(0x5cb33ce6), uint32(0x6bd9fee7), uint32(0x3267b8e5),
  3380  		uint32(0x050d7ae4), uint32(0x384a26ef), uint32(0x0f20e4ee), uint32(0x569ea2ec), uint32(0x61f460ed),
  3381  		uint32(0xe4e22fe8), uint32(0xd388ede9), uint32(0x8a36abeb), uint32(0xbd5c69ea), uint32(0xf0b813fd),
  3382  		uint32(0xc7d2d1fc), uint32(0x9e6c97fe), uint32(0xa90655ff), uint32(0x2c101afa), uint32(0x1b7ad8fb),
  3383  		uint32(0x42c49ef9), uint32(0x75ae5cf8), uint32(0x48e900f3), uint32(0x7f83c2f2), uint32(0x263d84f0),
  3384  		uint32(0x115746f1), uint32(0x944109f4), uint32(0xa32bcbf5), uint32(0xfa958df7), uint32(0xcdff4ff6),
  3385  		uint32(0x605d78d9), uint32(0x5737bad8), uint32(0x0e89fcda), uint32(0x39e33edb), uint32(0xbcf571de),
  3386  		uint32(0x8b9fb3df), uint32(0xd221f5dd), uint32(0xe54b37dc), uint32(0xd80c6bd7), uint32(0xef66a9d6),
  3387  		uint32(0xb6d8efd4), uint32(0x81b22dd5), uint32(0x04a462d0), uint32(0x33cea0d1), uint32(0x6a70e6d3),
  3388  		uint32(0x5d1a24d2), uint32(0x10fe5ec5), uint32(0x27949cc4), uint32(0x7e2adac6), uint32(0x494018c7),
  3389  		uint32(0xcc5657c2), uint32(0xfb3c95c3), uint32(0xa282d3c1), uint32(0x95e811c0), uint32(0xa8af4dcb),
  3390  		uint32(0x9fc58fca), uint32(0xc67bc9c8), uint32(0xf1110bc9), uint32(0x740744cc), uint32(0x436d86cd),
  3391  		uint32(0x1ad3c0cf), uint32(0x2db902ce), uint32(0x4096af91), uint32(0x77fc6d90), uint32(0x2e422b92),
  3392  		uint32(0x1928e993), uint32(0x9c3ea696), uint32(0xab546497), uint32(0xf2ea2295), uint32(0xc580e094),
  3393  		uint32(0xf8c7bc9f), uint32(0xcfad7e9e), uint32(0x9613389c), uint32(0xa179fa9d), uint32(0x246fb598),
  3394  		uint32(0x13057799), uint32(0x4abb319b), uint32(0x7dd1f39a), uint32(0x3035898d), uint32(0x075f4b8c),
  3395  		uint32(0x5ee10d8e), uint32(0x698bcf8f), uint32(0xec9d808a), uint32(0xdbf7428b), uint32(0x82490489),
  3396  		uint32(0xb523c688), uint32(0x88649a83), uint32(0xbf0e5882), uint32(0xe6b01e80), uint32(0xd1dadc81),
  3397  		uint32(0x54cc9384), uint32(0x63a65185), uint32(0x3a181787), uint32(0x0d72d586), uint32(0xa0d0e2a9),
  3398  		uint32(0x97ba20a8), uint32(0xce0466aa), uint32(0xf96ea4ab), uint32(0x7c78ebae), uint32(0x4b1229af),
  3399  		uint32(0x12ac6fad), uint32(0x25c6adac), uint32(0x1881f1a7), uint32(0x2feb33a6), uint32(0x765575a4),
  3400  		uint32(0x413fb7a5), uint32(0xc429f8a0), uint32(0xf3433aa1), uint32(0xaafd7ca3), uint32(0x9d97bea2),
  3401  		uint32(0xd073c4b5), uint32(0xe71906b4), uint32(0xbea740b6), uint32(0x89cd82b7), uint32(0x0cdbcdb2),
  3402  		uint32(0x3bb10fb3), uint32(0x620f49b1), uint32(0x55658bb0), uint32(0x6822d7bb), uint32(0x5f4815ba),
  3403  		uint32(0x06f653b8), uint32(0x319c91b9), uint32(0xb48adebc), uint32(0x83e01cbd), uint32(0xda5e5abf),
  3404  		uint32(0xed3498be),
  3405  	},
  3406  	{
  3407  		uint32(0x00000000), uint32(0x6567bcb8), uint32(0x8bc809aa), uint32(0xeeafb512), uint32(0x5797628f),
  3408  		uint32(0x32f0de37), uint32(0xdc5f6b25), uint32(0xb938d79d), uint32(0xef28b4c5), uint32(0x8a4f087d),
  3409  		uint32(0x64e0bd6f), uint32(0x018701d7), uint32(0xb8bfd64a), uint32(0xddd86af2), uint32(0x3377dfe0),
  3410  		uint32(0x56106358), uint32(0x9f571950), uint32(0xfa30a5e8), uint32(0x149f10fa), uint32(0x71f8ac42),
  3411  		uint32(0xc8c07bdf), uint32(0xada7c767), uint32(0x43087275), uint32(0x266fcecd), uint32(0x707fad95),
  3412  		uint32(0x1518112d), uint32(0xfbb7a43f), uint32(0x9ed01887), uint32(0x27e8cf1a), uint32(0x428f73a2),
  3413  		uint32(0xac20c6b0), uint32(0xc9477a08), uint32(0x3eaf32a0), uint32(0x5bc88e18), uint32(0xb5673b0a),
  3414  		uint32(0xd00087b2), uint32(0x6938502f), uint32(0x0c5fec97), uint32(0xe2f05985), uint32(0x8797e53d),
  3415  		uint32(0xd1878665), uint32(0xb4e03add), uint32(0x5a4f8fcf), uint32(0x3f283377), uint32(0x8610e4ea),
  3416  		uint32(0xe3775852), uint32(0x0dd8ed40), uint32(0x68bf51f8), uint32(0xa1f82bf0), uint32(0xc49f9748),
  3417  		uint32(0x2a30225a), uint32(0x4f579ee2), uint32(0xf66f497f), uint32(0x9308f5c7), uint32(0x7da740d5),
  3418  		uint32(0x18c0fc6d), uint32(0x4ed09f35), uint32(0x2bb7238d), uint32(0xc518969f), uint32(0xa07f2a27),
  3419  		uint32(0x1947fdba), uint32(0x7c204102), uint32(0x928ff410), uint32(0xf7e848a8), uint32(0x3d58149b),
  3420  		uint32(0x583fa823), uint32(0xb6901d31), uint32(0xd3f7a189), uint32(0x6acf7614), uint32(0x0fa8caac),
  3421  		uint32(0xe1077fbe), uint32(0x8460c306), uint32(0xd270a05e), uint32(0xb7171ce6), uint32(0x59b8a9f4),
  3422  		uint32(0x3cdf154c), uint32(0x85e7c2d1), uint32(0xe0807e69), uint32(0x0e2fcb7b), uint32(0x6b4877c3),
  3423  		uint32(0xa20f0dcb), uint32(0xc768b173), uint32(0x29c70461), uint32(0x4ca0b8d9), uint32(0xf5986f44),
  3424  		uint32(0x90ffd3fc), uint32(0x7e5066ee), uint32(0x1b37da56), uint32(0x4d27b90e), uint32(0x284005b6),
  3425  		uint32(0xc6efb0a4), uint32(0xa3880c1c), uint32(0x1ab0db81), uint32(0x7fd76739), uint32(0x9178d22b),
  3426  		uint32(0xf41f6e93), uint32(0x03f7263b), uint32(0x66909a83), uint32(0x883f2f91), uint32(0xed589329),
  3427  		uint32(0x546044b4), uint32(0x3107f80c), uint32(0xdfa84d1e), uint32(0xbacff1a6), uint32(0xecdf92fe),
  3428  		uint32(0x89b82e46), uint32(0x67179b54), uint32(0x027027ec), uint32(0xbb48f071), uint32(0xde2f4cc9),
  3429  		uint32(0x3080f9db), uint32(0x55e74563), uint32(0x9ca03f6b), uint32(0xf9c783d3), uint32(0x176836c1),
  3430  		uint32(0x720f8a79), uint32(0xcb375de4), uint32(0xae50e15c), uint32(0x40ff544e), uint32(0x2598e8f6),
  3431  		uint32(0x73888bae), uint32(0x16ef3716), uint32(0xf8408204), uint32(0x9d273ebc), uint32(0x241fe921),
  3432  		uint32(0x41785599), uint32(0xafd7e08b), uint32(0xcab05c33), uint32(0x3bb659ed), uint32(0x5ed1e555),
  3433  		uint32(0xb07e5047), uint32(0xd519ecff), uint32(0x6c213b62), uint32(0x094687da), uint32(0xe7e932c8),
  3434  		uint32(0x828e8e70), uint32(0xd49eed28), uint32(0xb1f95190), uint32(0x5f56e482), uint32(0x3a31583a),
  3435  		uint32(0x83098fa7), uint32(0xe66e331f), uint32(0x08c1860d), uint32(0x6da63ab5), uint32(0xa4e140bd),
  3436  		uint32(0xc186fc05), uint32(0x2f294917), uint32(0x4a4ef5af), uint32(0xf3762232), uint32(0x96119e8a),
  3437  		uint32(0x78be2b98), uint32(0x1dd99720), uint32(0x4bc9f478), uint32(0x2eae48c0), uint32(0xc001fdd2),
  3438  		uint32(0xa566416a), uint32(0x1c5e96f7), uint32(0x79392a4f), uint32(0x97969f5d), uint32(0xf2f123e5),
  3439  		uint32(0x05196b4d), uint32(0x607ed7f5), uint32(0x8ed162e7), uint32(0xebb6de5f), uint32(0x528e09c2),
  3440  		uint32(0x37e9b57a), uint32(0xd9460068), uint32(0xbc21bcd0), uint32(0xea31df88), uint32(0x8f566330),
  3441  		uint32(0x61f9d622), uint32(0x049e6a9a), uint32(0xbda6bd07), uint32(0xd8c101bf), uint32(0x366eb4ad),
  3442  		uint32(0x53090815), uint32(0x9a4e721d), uint32(0xff29cea5), uint32(0x11867bb7), uint32(0x74e1c70f),
  3443  		uint32(0xcdd91092), uint32(0xa8beac2a), uint32(0x46111938), uint32(0x2376a580), uint32(0x7566c6d8),
  3444  		uint32(0x10017a60), uint32(0xfeaecf72), uint32(0x9bc973ca), uint32(0x22f1a457), uint32(0x479618ef),
  3445  		uint32(0xa939adfd), uint32(0xcc5e1145), uint32(0x06ee4d76), uint32(0x6389f1ce), uint32(0x8d2644dc),
  3446  		uint32(0xe841f864), uint32(0x51792ff9), uint32(0x341e9341), uint32(0xdab12653), uint32(0xbfd69aeb),
  3447  		uint32(0xe9c6f9b3), uint32(0x8ca1450b), uint32(0x620ef019), uint32(0x07694ca1), uint32(0xbe519b3c),
  3448  		uint32(0xdb362784), uint32(0x35999296), uint32(0x50fe2e2e), uint32(0x99b95426), uint32(0xfcdee89e),
  3449  		uint32(0x12715d8c), uint32(0x7716e134), uint32(0xce2e36a9), uint32(0xab498a11), uint32(0x45e63f03),
  3450  		uint32(0x208183bb), uint32(0x7691e0e3), uint32(0x13f65c5b), uint32(0xfd59e949), uint32(0x983e55f1),
  3451  		uint32(0x2106826c), uint32(0x44613ed4), uint32(0xaace8bc6), uint32(0xcfa9377e), uint32(0x38417fd6),
  3452  		uint32(0x5d26c36e), uint32(0xb389767c), uint32(0xd6eecac4), uint32(0x6fd61d59), uint32(0x0ab1a1e1),
  3453  		uint32(0xe41e14f3), uint32(0x8179a84b), uint32(0xd769cb13), uint32(0xb20e77ab), uint32(0x5ca1c2b9),
  3454  		uint32(0x39c67e01), uint32(0x80fea99c), uint32(0xe5991524), uint32(0x0b36a036), uint32(0x6e511c8e),
  3455  		uint32(0xa7166686), uint32(0xc271da3e), uint32(0x2cde6f2c), uint32(0x49b9d394), uint32(0xf0810409),
  3456  		uint32(0x95e6b8b1), uint32(0x7b490da3), uint32(0x1e2eb11b), uint32(0x483ed243), uint32(0x2d596efb),
  3457  		uint32(0xc3f6dbe9), uint32(0xa6916751), uint32(0x1fa9b0cc), uint32(0x7ace0c74), uint32(0x9461b966),
  3458  		uint32(0xf10605de),
  3459  	},
  3460  } /* crc32.h:5:25 */
  3461  
  3462  // =========================================================================
  3463  // This function can be used by asm versions of crc32()
  3464  func Xget_crc_table(tls *libc.TLS) uintptr { /* crc32.c:188:19: */
  3465  	return uintptr(uintptr(unsafe.Pointer(&crc_table)))
  3466  }
  3467  
  3468  // =========================================================================
  3469  
  3470  // =========================================================================
  3471  func Xcrc32_z(tls *libc.TLS, crc uint64, buf uintptr, len Z_size_t) uint64 { /* crc32.c:202:23: */
  3472  	bp := tls.Alloc(4)
  3473  	defer tls.Free(4)
  3474  
  3475  	if buf == uintptr(Z_NULL) {
  3476  		return 0
  3477  	}
  3478  
  3479  	if uint64(unsafe.Sizeof(uintptr(0))) == uint64(unsafe.Sizeof(Ptrdiff_t(0))) {
  3480  		// var endian Z_crc_t at bp, 4
  3481  
  3482  		*(*Z_crc_t)(unsafe.Pointer(bp /* endian */)) = Z_crc_t(1)
  3483  		if *(*uint8)(unsafe.Pointer(bp)) != 0 {
  3484  			return crc32_little(tls, crc, buf, len)
  3485  		} else {
  3486  			return crc32_big(tls, crc, buf, len)
  3487  		}
  3488  	}
  3489  	crc = crc ^ 0xffffffff
  3490  	for len >= uint64(8) {
  3491  		crc = uint64(*(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr((int32(crc)^int32(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1)))))&0xff)*4))) ^ crc>>8
  3492  		crc = uint64(*(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr((int32(crc)^int32(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1)))))&0xff)*4))) ^ crc>>8
  3493  		crc = uint64(*(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr((int32(crc)^int32(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1)))))&0xff)*4))) ^ crc>>8
  3494  		crc = uint64(*(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr((int32(crc)^int32(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1)))))&0xff)*4))) ^ crc>>8
  3495  		crc = uint64(*(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr((int32(crc)^int32(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1)))))&0xff)*4))) ^ crc>>8
  3496  		crc = uint64(*(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr((int32(crc)^int32(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1)))))&0xff)*4))) ^ crc>>8
  3497  		crc = uint64(*(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr((int32(crc)^int32(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1)))))&0xff)*4))) ^ crc>>8
  3498  		crc = uint64(*(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr((int32(crc)^int32(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1)))))&0xff)*4))) ^ crc>>8
  3499  		len = len - uint64(8)
  3500  	}
  3501  	if len != 0 {
  3502  		for ok := true; ok; ok = libc.PreDecUint64(&len, 1) != 0 {
  3503  			crc = uint64(*(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr((int32(crc)^int32(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1)))))&0xff)*4))) ^ crc>>8
  3504  		}
  3505  	}
  3506  	return crc ^ 0xffffffff
  3507  }
  3508  
  3509  // =========================================================================
  3510  func Xcrc32(tls *libc.TLS, crc uint64, buf uintptr, len UInt) uint64 { /* crc32.c:237:23: */
  3511  	return Xcrc32_z(tls, crc, buf, uint64(len))
  3512  }
  3513  
  3514  //
  3515  //    This BYFOUR code accesses the passed unsigned char * buffer with a 32-bit
  3516  //    integer pointer type. This violates the strict aliasing rule, where a
  3517  //    compiler can assume, for optimization purposes, that two pointers to
  3518  //    fundamentally different types won't ever point to the same memory. This can
  3519  //    manifest as a problem only if one of the pointers is written to. This code
  3520  //    only reads from those pointers. So long as this code remains isolated in
  3521  //    this compilation unit, there won't be a problem. For this reason, this code
  3522  //    should not be copied and pasted into a compilation unit in which other code
  3523  //    writes to the buffer that is passed to these routines.
  3524  //
  3525  
  3526  // =========================================================================
  3527  
  3528  // =========================================================================
  3529  func crc32_little(tls *libc.TLS, crc uint64, buf uintptr, len Z_size_t) uint64 { /* crc32.c:266:21: */
  3530  	var c Z_crc_t
  3531  	var buf4 uintptr
  3532  
  3533  	c = Z_crc_t(crc)
  3534  	c = ^c
  3535  	for len != 0 && Ptrdiff_t(buf)&int64(3) != 0 {
  3536  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr((c^Z_crc_t(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1)))))&Z_crc_t(0xff))*4)) ^ c>>8
  3537  		len--
  3538  	}
  3539  
  3540  	buf4 = buf
  3541  	for len >= uint64(32) {
  3542  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3543  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 3*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 2*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 1*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr(c>>24)*4))
  3544  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3545  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 3*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 2*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 1*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr(c>>24)*4))
  3546  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3547  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 3*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 2*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 1*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr(c>>24)*4))
  3548  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3549  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 3*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 2*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 1*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr(c>>24)*4))
  3550  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3551  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 3*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 2*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 1*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr(c>>24)*4))
  3552  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3553  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 3*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 2*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 1*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr(c>>24)*4))
  3554  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3555  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 3*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 2*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 1*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr(c>>24)*4))
  3556  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3557  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 3*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 2*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 1*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr(c>>24)*4))
  3558  		len = len - uint64(32)
  3559  	}
  3560  	for len >= uint64(4) {
  3561  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3562  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 3*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 2*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 1*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr(c>>24)*4))
  3563  		len = len - uint64(4)
  3564  	}
  3565  	buf = buf4
  3566  
  3567  	if len != 0 {
  3568  		for ok := true; ok; ok = libc.PreDecUint64(&len, 1) != 0 {
  3569  			c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + uintptr((c^Z_crc_t(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1)))))&Z_crc_t(0xff))*4)) ^ c>>8
  3570  		}
  3571  	}
  3572  	c = ^c
  3573  	return uint64(c)
  3574  }
  3575  
  3576  // =========================================================================
  3577  
  3578  // =========================================================================
  3579  func crc32_big(tls *libc.TLS, crc uint64, buf uintptr, len Z_size_t) uint64 { /* crc32.c:306:21: */
  3580  	var c Z_crc_t
  3581  	var buf4 uintptr
  3582  
  3583  	c = Z_crc_t(crc)>>24&Z_crc_t(0xff) + Z_crc_t(crc)>>8&Z_crc_t(0xff00) + Z_crc_t(crc)&Z_crc_t(0xff00)<<8 + Z_crc_t(crc)&Z_crc_t(0xff)<<24
  3584  	c = ^c
  3585  	for len != 0 && Ptrdiff_t(buf)&int64(3) != 0 {
  3586  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 4*1024 + uintptr(c>>24^Z_crc_t(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1)))))*4)) ^ c<<8
  3587  		len--
  3588  	}
  3589  
  3590  	buf4 = buf
  3591  	for len >= uint64(32) {
  3592  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3593  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 4*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 5*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 6*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 7*1024 + uintptr(c>>24)*4))
  3594  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3595  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 4*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 5*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 6*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 7*1024 + uintptr(c>>24)*4))
  3596  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3597  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 4*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 5*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 6*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 7*1024 + uintptr(c>>24)*4))
  3598  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3599  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 4*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 5*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 6*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 7*1024 + uintptr(c>>24)*4))
  3600  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3601  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 4*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 5*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 6*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 7*1024 + uintptr(c>>24)*4))
  3602  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3603  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 4*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 5*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 6*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 7*1024 + uintptr(c>>24)*4))
  3604  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3605  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 4*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 5*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 6*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 7*1024 + uintptr(c>>24)*4))
  3606  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3607  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 4*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 5*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 6*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 7*1024 + uintptr(c>>24)*4))
  3608  		len = len - uint64(32)
  3609  	}
  3610  	for len >= uint64(4) {
  3611  		c = c ^ *(*Z_crc_t)(unsafe.Pointer(libc.PostIncUintptr(&buf4, 4)))
  3612  		c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 4*1024 + uintptr(c&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 5*1024 + uintptr(c>>8&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 6*1024 + uintptr(c>>16&Z_crc_t(0xff))*4)) ^ *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 7*1024 + uintptr(c>>24)*4))
  3613  		len = len - uint64(4)
  3614  	}
  3615  	buf = buf4
  3616  
  3617  	if len != 0 {
  3618  		for ok := true; ok; ok = libc.PreDecUint64(&len, 1) != 0 {
  3619  			c = *(*Z_crc_t)(unsafe.Pointer(uintptr(unsafe.Pointer(&crc_table)) + 4*1024 + uintptr(c>>24^Z_crc_t(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&buf, 1)))))*4)) ^ c<<8
  3620  		}
  3621  	}
  3622  	c = ^c
  3623  	return uint64(c>>24&Z_crc_t(0xff) + c>>8&Z_crc_t(0xff00) + c&Z_crc_t(0xff00)<<8 + c&Z_crc_t(0xff)<<24)
  3624  }
  3625  
  3626  // =========================================================================
  3627  func gf2_matrix_times(tls *libc.TLS, mat uintptr, vec uint64) uint64 { /* crc32.c:344:21: */
  3628  	var sum uint64
  3629  
  3630  	sum = uint64(0)
  3631  	for vec != 0 {
  3632  		if vec&uint64(1) != 0 {
  3633  			sum = sum ^ *(*uint64)(unsafe.Pointer(mat))
  3634  		}
  3635  		vec >>= 1
  3636  		mat += 8
  3637  	}
  3638  	return sum
  3639  }
  3640  
  3641  // =========================================================================
  3642  func gf2_matrix_square(tls *libc.TLS, square uintptr, mat uintptr) { /* crc32.c:361:12: */
  3643  	var n int32
  3644  
  3645  	for n = 0; n < GF2_DIM; n++ {
  3646  		*(*uint64)(unsafe.Pointer(square + uintptr(n)*8)) = gf2_matrix_times(tls, mat, *(*uint64)(unsafe.Pointer(mat + uintptr(n)*8)))
  3647  	}
  3648  }
  3649  
  3650  // =========================================================================
  3651  func crc32_combine_(tls *libc.TLS, crc1 ULong, crc2 ULong, len2 Off_t) ULong { /* crc32.c:372:13: */
  3652  	bp := tls.Alloc(512)
  3653  	defer tls.Free(512)
  3654  
  3655  	var n int32
  3656  	var row uint64
  3657  	// var even [32]uint64 at bp+256, 256
  3658  	// even-power-of-two zeros operator
  3659  	// var odd [32]uint64 at bp, 256
  3660  	// odd-power-of-two zeros operator
  3661  
  3662  	// degenerate case (also disallow negative lengths)
  3663  	if len2 <= int64(0) {
  3664  		return crc1
  3665  	}
  3666  
  3667  	// put operator for one zero bit in odd
  3668  	*(*uint64)(unsafe.Pointer(bp)) = 0xedb88320 // CRC-32 polynomial
  3669  	row = uint64(1)
  3670  	for n = 1; n < GF2_DIM; n++ {
  3671  		*(*uint64)(unsafe.Pointer(bp + uintptr(n)*8)) = row
  3672  		row <<= 1
  3673  	}
  3674  
  3675  	// put operator for two zero bits in even
  3676  	gf2_matrix_square(tls, bp+256, bp)
  3677  
  3678  	// put operator for four zero bits in odd
  3679  	gf2_matrix_square(tls, bp, bp+256)
  3680  
  3681  	// apply len2 zeros to crc1 (first square will put the operator for one
  3682  	//        zero byte, eight zero bits, in even)
  3683  	for ok := true; ok; ok = len2 != int64(0) {
  3684  		// apply zeros operator for this bit of len2
  3685  		gf2_matrix_square(tls, bp+256, bp)
  3686  		if len2&int64(1) != 0 {
  3687  			crc1 = gf2_matrix_times(tls, bp+256, crc1)
  3688  		}
  3689  		len2 >>= 1
  3690  
  3691  		// if no more bits set, then done
  3692  		if len2 == int64(0) {
  3693  			break
  3694  		}
  3695  
  3696  		// another iteration of the loop with odd and even swapped
  3697  		gf2_matrix_square(tls, bp, bp+256)
  3698  		if len2&int64(1) != 0 {
  3699  			crc1 = gf2_matrix_times(tls, bp, crc1)
  3700  		}
  3701  		len2 >>= 1
  3702  
  3703  		// if no more bits set, then done
  3704  	}
  3705  
  3706  	// return combined crc
  3707  	crc1 = crc1 ^ crc2
  3708  	return crc1
  3709  }
  3710  
  3711  // =========================================================================
  3712  func Xcrc32_combine(tls *libc.TLS, crc1 ULong, crc2 ULong, len2 Off_t) ULong { /* crc32.c:428:15: */
  3713  	return crc32_combine_(tls, crc1, crc2, len2)
  3714  }
  3715  
  3716  func Xcrc32_combine64(tls *libc.TLS, crc1 ULong, crc2 ULong, len2 Off_t) ULong { /* crc32.c:436:15: */
  3717  	return crc32_combine_(tls, crc1, crc2, len2)
  3718  }
  3719  
  3720  // Reverse the bytes in a 32-bit value
  3721  
  3722  // define NO_GZIP when compiling if you want to disable gzip header and
  3723  //    trailer creation by deflate().  NO_GZIP would be used to avoid linking in
  3724  //    the crc code when it is not needed.  For shared libraries, gzip encoding
  3725  //    should be left enabled.
  3726  
  3727  // ===========================================================================
  3728  // Internal compression state.
  3729  
  3730  // number of length codes, not counting the special END_BLOCK code
  3731  
  3732  // number of literal bytes 0..255
  3733  
  3734  // number of Literal or Length codes, including the END_BLOCK code
  3735  
  3736  // number of distance codes
  3737  
  3738  // number of codes used to transfer the bit lengths
  3739  
  3740  // maximum heap size
  3741  
  3742  // All codes must not exceed MAX_BITS bits
  3743  
  3744  // size of bit buffer in bi_buf
  3745  
  3746  // Stream status
  3747  
  3748  // Data structure describing a single value and its code string.
  3749  type Ct_data_s = struct {
  3750  	Ffc struct{ Ffreq Ush }
  3751  	Fdl struct{ Fdad Ush }
  3752  } /* zlib.h:84:1 */
  3753  
  3754  // Reverse the bytes in a 32-bit value
  3755  
  3756  // define NO_GZIP when compiling if you want to disable gzip header and
  3757  //    trailer creation by deflate().  NO_GZIP would be used to avoid linking in
  3758  //    the crc code when it is not needed.  For shared libraries, gzip encoding
  3759  //    should be left enabled.
  3760  
  3761  // ===========================================================================
  3762  // Internal compression state.
  3763  
  3764  // number of length codes, not counting the special END_BLOCK code
  3765  
  3766  // number of literal bytes 0..255
  3767  
  3768  // number of Literal or Length codes, including the END_BLOCK code
  3769  
  3770  // number of distance codes
  3771  
  3772  // number of codes used to transfer the bit lengths
  3773  
  3774  // maximum heap size
  3775  
  3776  // All codes must not exceed MAX_BITS bits
  3777  
  3778  // size of bit buffer in bi_buf
  3779  
  3780  // Stream status
  3781  
  3782  // Data structure describing a single value and its code string.
  3783  type Ct_data = Ct_data_s /* deflate.h:77:7 */
  3784  
  3785  type Static_tree_desc_s = struct {
  3786  	Fstatic_tree uintptr
  3787  	Fextra_bits  uintptr
  3788  	Fextra_base  int32
  3789  	Felems       int32
  3790  	Fmax_length  int32
  3791  	F__ccgo_pad1 [4]byte
  3792  } /* deflate.h:84:9 */
  3793  
  3794  type Tree_desc_s = struct {
  3795  	Fdyn_tree    uintptr
  3796  	Fmax_code    int32
  3797  	F__ccgo_pad1 [4]byte
  3798  	Fstat_desc   uintptr
  3799  } /* zlib.h:84:1 */
  3800  
  3801  type Tree_desc = Tree_desc_s /* deflate.h:90:7 */
  3802  
  3803  type Pos = Ush     /* deflate.h:92:13 */
  3804  type Posf = Pos    /* deflate.h:93:17 */
  3805  type IPos = uint32 /* deflate.h:94:18 */
  3806  
  3807  // A Pos is an index in the character window. We use short instead of int to
  3808  // save space in the various tables. IPos is used only for parameter passing.
  3809  
  3810  type Deflate_state = Internal_state /* deflate.h:276:7 */
  3811  
  3812  var Xdeflate_copyright = *(*[69]int8)(unsafe.Pointer(ts + 7)) /* deflate.c:54:12 */
  3813  //
  3814  //   If you use the zlib library in a product, an acknowledgment is welcome
  3815  //   in the documentation of your product. If for some reason you cannot
  3816  //   include such an acknowledgment, I would appreciate that you keep this
  3817  //   copyright string in the executable of your product.
  3818  //
  3819  
  3820  // ===========================================================================
  3821  //  Function prototypes.
  3822  type Block_state = uint32 /* deflate.c:71:3 */
  3823  
  3824  type Compress_func = uintptr /* deflate.c:73:21 */
  3825  
  3826  // ===========================================================================
  3827  // Local data
  3828  
  3829  // Tail of hash chains
  3830  
  3831  // Matches of length 3 are discarded if their distance exceeds TOO_FAR
  3832  
  3833  // Values for max_lazy_match, good_match and max_chain_length, depending on
  3834  // the desired pack level (0..9). The values given below have been tuned to
  3835  // exclude worst case performance for pathological files. Better values may be
  3836  // found for specific files.
  3837  type Config_s = struct {
  3838  	Fgood_length Ush
  3839  	Fmax_lazy    Ush
  3840  	Fnice_length Ush
  3841  	Fmax_chain   Ush
  3842  	Ffunc        Compress_func
  3843  } /* deflate.c:120:9 */
  3844  
  3845  // ===========================================================================
  3846  // Local data
  3847  
  3848  // Tail of hash chains
  3849  
  3850  // Matches of length 3 are discarded if their distance exceeds TOO_FAR
  3851  
  3852  // Values for max_lazy_match, good_match and max_chain_length, depending on
  3853  // the desired pack level (0..9). The values given below have been tuned to
  3854  // exclude worst case performance for pathological files. Better values may be
  3855  // found for specific files.
  3856  type Config = Config_s /* deflate.c:126:3 */
  3857  
  3858  var configuration_table = [10]Config{
  3859  	//      good lazy nice chain
  3860  	/* 0 */ {Ffunc: 0}, // store only
  3861  	/* 1 */ {Fgood_length: Ush(4), Fmax_lazy: Ush(4), Fnice_length: Ush(8), Fmax_chain: Ush(4), Ffunc: 0}, // max speed, no lazy matches
  3862  	/* 2 */ {Fgood_length: Ush(4), Fmax_lazy: Ush(5), Fnice_length: Ush(16), Fmax_chain: Ush(8), Ffunc: 0},
  3863  	/* 3 */ {Fgood_length: Ush(4), Fmax_lazy: Ush(6), Fnice_length: Ush(32), Fmax_chain: Ush(32), Ffunc: 0},
  3864  
  3865  	/* 4 */ {Fgood_length: Ush(4), Fmax_lazy: Ush(4), Fnice_length: Ush(16), Fmax_chain: Ush(16), Ffunc: 0}, // lazy matches
  3866  	/* 5 */ {Fgood_length: Ush(8), Fmax_lazy: Ush(16), Fnice_length: Ush(32), Fmax_chain: Ush(32), Ffunc: 0},
  3867  	/* 6 */ {Fgood_length: Ush(8), Fmax_lazy: Ush(16), Fnice_length: Ush(128), Fmax_chain: Ush(128), Ffunc: 0},
  3868  	/* 7 */ {Fgood_length: Ush(8), Fmax_lazy: Ush(32), Fnice_length: Ush(128), Fmax_chain: Ush(256), Ffunc: 0},
  3869  	/* 8 */ {Fgood_length: Ush(32), Fmax_lazy: Ush(128), Fnice_length: Ush(258), Fmax_chain: Ush(1024), Ffunc: 0},
  3870  	/* 9 */ {Fgood_length: Ush(32), Fmax_lazy: Ush(258), Fnice_length: Ush(258), Fmax_chain: Ush(4096), Ffunc: 0}} /* deflate.c:134:20 */
  3871  
  3872  // max compression
  3873  
  3874  // Note: the deflate() code requires max_lazy >= MIN_MATCH and max_chain >= 4
  3875  // For deflate_fast() (levels <= 3) good is ignored and lazy has a different
  3876  // meaning.
  3877  
  3878  // rank Z_BLOCK between Z_NO_FLUSH and Z_PARTIAL_FLUSH
  3879  
  3880  // ===========================================================================
  3881  // Update a hash value with the given input byte
  3882  // IN  assertion: all calls to UPDATE_HASH are made with consecutive input
  3883  //    characters, so that a running hash key can be computed from the previous
  3884  //    key instead of complete recalculation each time.
  3885  
  3886  // ===========================================================================
  3887  // Insert string str in the dictionary and set match_head to the previous head
  3888  // of the hash chain (the most recent string with same hash key). Return
  3889  // the previous length of the hash chain.
  3890  // If this file is compiled with -DFASTEST, the compression level is forced
  3891  // to 1, and no hash chains are maintained.
  3892  // IN  assertion: all calls to INSERT_STRING are made with consecutive input
  3893  //    characters and the first MIN_MATCH bytes of str are valid (except for
  3894  //    the last MIN_MATCH-1 bytes of the input file).
  3895  
  3896  // ===========================================================================
  3897  // Initialize the hash table (avoiding 64K overflow for 16 bit systems).
  3898  // prev[] will be initialized on the fly.
  3899  
  3900  // ===========================================================================
  3901  // Slide the hash table when sliding the window down (could be avoided with 32
  3902  // bit values at the expense of memory usage). We slide even when level == 0 to
  3903  // keep the hash table consistent if we switch back to level > 0 later.
  3904  func slide_hash(tls *libc.TLS, s uintptr) { /* deflate.c:201:12: */
  3905  	var n uint32
  3906  	var m uint32
  3907  	var p uintptr
  3908  	var wsize UInt = (*Deflate_state)(unsafe.Pointer(s)).Fw_size
  3909  
  3910  	n = (*Deflate_state)(unsafe.Pointer(s)).Fhash_size
  3911  	p = (*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr(n)*2
  3912  	for ok := true; ok; ok = libc.PreDecUint32(&n, 1) != 0 {
  3913  		m = uint32(*(*Posf)(unsafe.Pointer(libc.PreDecUintptr(&p, 2))))
  3914  		*(*Posf)(unsafe.Pointer(p)) = func() uint16 {
  3915  			if m >= wsize {
  3916  				return uint16(m - wsize)
  3917  			}
  3918  			return uint16(NIL)
  3919  		}()
  3920  	}
  3921  	n = wsize
  3922  	p = (*Deflate_state)(unsafe.Pointer(s)).Fprev + uintptr(n)*2
  3923  	for ok1 := true; ok1; ok1 = libc.PreDecUint32(&n, 1) != 0 {
  3924  		m = uint32(*(*Posf)(unsafe.Pointer(libc.PreDecUintptr(&p, 2))))
  3925  		*(*Posf)(unsafe.Pointer(p)) = func() uint16 {
  3926  			if m >= wsize {
  3927  				return uint16(m - wsize)
  3928  			}
  3929  			return uint16(NIL)
  3930  		}()
  3931  		// If n is not on any hash chain, prev[n] is garbage but
  3932  		// its value will never be used.
  3933  	}
  3934  }
  3935  
  3936  // =========================================================================
  3937  func XdeflateInit_(tls *libc.TLS, strm Z_streamp, level int32, version uintptr, stream_size int32) int32 { /* deflate.c:228:13: */
  3938  	return XdeflateInit2_(tls, strm, level, Z_DEFLATED, MAX_WBITS, DEF_MEM_LEVEL,
  3939  		Z_DEFAULT_STRATEGY, version, stream_size)
  3940  	// To do: ignore strm->next_in if we use it as window
  3941  }
  3942  
  3943  // =========================================================================
  3944  func XdeflateInit2_(tls *libc.TLS, strm Z_streamp, level int32, method int32, windowBits int32, memLevel int32, strategy int32, version uintptr, stream_size int32) int32 { /* deflate.c:240:13: */
  3945  	var s uintptr
  3946  	var wrap int32 = 1
  3947  	var overlay uintptr
  3948  	// We overlay pending_buf and d_buf+l_buf. This works since the average
  3949  	// output size for (length,distance) codes is <= 24 bits.
  3950  
  3951  	if version == uintptr(Z_NULL) || int32(*(*int8)(unsafe.Pointer(version))) != int32(my_version[0]) || uint64(stream_size) != uint64(unsafe.Sizeof(Z_stream{})) {
  3952  		return -6
  3953  	}
  3954  	if strm == uintptr(Z_NULL) {
  3955  		return -2
  3956  	}
  3957  
  3958  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = uintptr(Z_NULL)
  3959  	if (*Z_stream)(unsafe.Pointer(strm)).Fzalloc == uintptr(0) {
  3960  		(*Z_stream)(unsafe.Pointer(strm)).Fzalloc = *(*uintptr)(unsafe.Pointer(&struct {
  3961  			f func(*libc.TLS, Voidpf, uint32, uint32) Voidpf
  3962  		}{Xzcalloc}))
  3963  		(*Z_stream)(unsafe.Pointer(strm)).Fopaque = uintptr(0)
  3964  	}
  3965  	if (*Z_stream)(unsafe.Pointer(strm)).Fzfree == uintptr(0) {
  3966  		(*Z_stream)(unsafe.Pointer(strm)).Fzfree = *(*uintptr)(unsafe.Pointer(&struct {
  3967  			f func(*libc.TLS, Voidpf, Voidpf)
  3968  		}{Xzcfree}))
  3969  	}
  3970  
  3971  	if level == -1 {
  3972  		level = 6
  3973  	}
  3974  
  3975  	if windowBits < 0 { // suppress zlib wrapper
  3976  		wrap = 0
  3977  		windowBits = -windowBits
  3978  	} else if windowBits > 15 {
  3979  		wrap = 2 // write gzip wrapper instead
  3980  		windowBits = windowBits - 16
  3981  	}
  3982  	if memLevel < 1 || memLevel > MAX_MEM_LEVEL || method != Z_DEFLATED || windowBits < 8 || windowBits > 15 || level < 0 || level > 9 || strategy < 0 || strategy > Z_FIXED || windowBits == 8 && wrap != 1 {
  3983  		return -2
  3984  	}
  3985  	if windowBits == 8 {
  3986  		windowBits = 9
  3987  	} // until 256-byte window bug fixed
  3988  	s = (*struct {
  3989  		f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
  3990  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, uint32(1), uint32(unsafe.Sizeof(Deflate_state{})))
  3991  	if s == uintptr(Z_NULL) {
  3992  		return -4
  3993  	}
  3994  	(*Z_stream)(unsafe.Pointer(strm)).Fstate = s
  3995  	(*Deflate_state)(unsafe.Pointer(s)).Fstrm = strm
  3996  	(*Deflate_state)(unsafe.Pointer(s)).Fstatus = INIT_STATE // to pass state test in deflateReset()
  3997  
  3998  	(*Deflate_state)(unsafe.Pointer(s)).Fwrap = wrap
  3999  	(*Deflate_state)(unsafe.Pointer(s)).Fgzhead = Gz_headerp(Z_NULL)
  4000  	(*Deflate_state)(unsafe.Pointer(s)).Fw_bits = UInt(windowBits)
  4001  	(*Deflate_state)(unsafe.Pointer(s)).Fw_size = UInt(int32(1) << (*Deflate_state)(unsafe.Pointer(s)).Fw_bits)
  4002  	(*Deflate_state)(unsafe.Pointer(s)).Fw_mask = (*Deflate_state)(unsafe.Pointer(s)).Fw_size - UInt(1)
  4003  
  4004  	(*Deflate_state)(unsafe.Pointer(s)).Fhash_bits = UInt(memLevel) + UInt(7)
  4005  	(*Deflate_state)(unsafe.Pointer(s)).Fhash_size = UInt(int32(1) << (*Deflate_state)(unsafe.Pointer(s)).Fhash_bits)
  4006  	(*Deflate_state)(unsafe.Pointer(s)).Fhash_mask = (*Deflate_state)(unsafe.Pointer(s)).Fhash_size - UInt(1)
  4007  	(*Deflate_state)(unsafe.Pointer(s)).Fhash_shift = ((*Deflate_state)(unsafe.Pointer(s)).Fhash_bits + UInt(MIN_MATCH) - UInt(1)) / UInt(MIN_MATCH)
  4008  
  4009  	(*Deflate_state)(unsafe.Pointer(s)).Fwindow = (*struct {
  4010  		f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
  4011  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, (*Deflate_state)(unsafe.Pointer(s)).Fw_size, uint32(uint64(2)*uint64(unsafe.Sizeof(Byte(0)))))
  4012  	(*Deflate_state)(unsafe.Pointer(s)).Fprev = (*struct {
  4013  		f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
  4014  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, (*Deflate_state)(unsafe.Pointer(s)).Fw_size, uint32(unsafe.Sizeof(Pos(0))))
  4015  	(*Deflate_state)(unsafe.Pointer(s)).Fhead = (*struct {
  4016  		f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
  4017  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, (*Deflate_state)(unsafe.Pointer(s)).Fhash_size, uint32(unsafe.Sizeof(Pos(0))))
  4018  
  4019  	(*Deflate_state)(unsafe.Pointer(s)).Fhigh_water = uint64(0) // nothing written to s->window yet
  4020  
  4021  	(*Deflate_state)(unsafe.Pointer(s)).Flit_bufsize = UInt(int32(1) << (memLevel + 6)) // 16K elements by default
  4022  
  4023  	overlay = (*struct {
  4024  		f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
  4025  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, (*Deflate_state)(unsafe.Pointer(s)).Flit_bufsize, uint32(uint64(unsafe.Sizeof(Ush(0)))+uint64(2)))
  4026  	(*Deflate_state)(unsafe.Pointer(s)).Fpending_buf = overlay
  4027  	(*Deflate_state)(unsafe.Pointer(s)).Fpending_buf_size = Ulg((*Deflate_state)(unsafe.Pointer(s)).Flit_bufsize) * (uint64(unsafe.Sizeof(Ush(0))) + uint64(2))
  4028  
  4029  	if (*Deflate_state)(unsafe.Pointer(s)).Fwindow == uintptr(Z_NULL) || (*Deflate_state)(unsafe.Pointer(s)).Fprev == uintptr(Z_NULL) || (*Deflate_state)(unsafe.Pointer(s)).Fhead == uintptr(Z_NULL) || (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf == uintptr(Z_NULL) {
  4030  		(*Deflate_state)(unsafe.Pointer(s)).Fstatus = FINISH_STATE
  4031  		(*Z_stream)(unsafe.Pointer(strm)).Fmsg = Xz_errmsg[Z_NEED_DICT - -4]
  4032  		XdeflateEnd(tls, strm)
  4033  		return -4
  4034  	}
  4035  	(*Deflate_state)(unsafe.Pointer(s)).Fd_buf = overlay + uintptr(uint64((*Deflate_state)(unsafe.Pointer(s)).Flit_bufsize)/uint64(unsafe.Sizeof(Ush(0))))*2
  4036  	(*Deflate_state)(unsafe.Pointer(s)).Fl_buf = (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr((uint64(1)+uint64(unsafe.Sizeof(Ush(0))))*uint64((*Deflate_state)(unsafe.Pointer(s)).Flit_bufsize))
  4037  
  4038  	(*Deflate_state)(unsafe.Pointer(s)).Flevel = level
  4039  	(*Deflate_state)(unsafe.Pointer(s)).Fstrategy = strategy
  4040  	(*Deflate_state)(unsafe.Pointer(s)).Fmethod = Byte(method)
  4041  
  4042  	return XdeflateReset(tls, strm)
  4043  }
  4044  
  4045  var my_version = *(*[7]int8)(unsafe.Pointer(ts)) /* deflate.c:253:23 */
  4046  
  4047  // =========================================================================
  4048  // Check for a valid deflate stream state. Return 0 if ok, 1 if not.
  4049  func deflateStateCheck(tls *libc.TLS, strm Z_streamp) int32 { /* deflate.c:353:11: */
  4050  	var s uintptr
  4051  	if strm == uintptr(Z_NULL) || (*Z_stream)(unsafe.Pointer(strm)).Fzalloc == uintptr(0) || (*Z_stream)(unsafe.Pointer(strm)).Fzfree == uintptr(0) {
  4052  		return 1
  4053  	}
  4054  	s = (*Z_stream)(unsafe.Pointer(strm)).Fstate
  4055  	if s == uintptr(Z_NULL) || (*Deflate_state)(unsafe.Pointer(s)).Fstrm != strm || (*Deflate_state)(unsafe.Pointer(s)).Fstatus != INIT_STATE && (*Deflate_state)(unsafe.Pointer(s)).Fstatus != GZIP_STATE && (*Deflate_state)(unsafe.Pointer(s)).Fstatus != EXTRA_STATE && (*Deflate_state)(unsafe.Pointer(s)).Fstatus != NAME_STATE && (*Deflate_state)(unsafe.Pointer(s)).Fstatus != COMMENT_STATE && (*Deflate_state)(unsafe.Pointer(s)).Fstatus != HCRC_STATE && (*Deflate_state)(unsafe.Pointer(s)).Fstatus != BUSY_STATE && (*Deflate_state)(unsafe.Pointer(s)).Fstatus != FINISH_STATE {
  4056  		return 1
  4057  	}
  4058  	return 0
  4059  }
  4060  
  4061  // =========================================================================
  4062  func XdeflateSetDictionary(tls *libc.TLS, strm Z_streamp, dictionary uintptr, dictLength UInt) int32 { /* deflate.c:376:13: */
  4063  	var s uintptr
  4064  	var str UInt
  4065  	var n UInt
  4066  	var wrap int32
  4067  	var avail uint32
  4068  	var next uintptr
  4069  
  4070  	if deflateStateCheck(tls, strm) != 0 || dictionary == uintptr(Z_NULL) {
  4071  		return -2
  4072  	}
  4073  	s = (*Z_stream)(unsafe.Pointer(strm)).Fstate
  4074  	wrap = (*Deflate_state)(unsafe.Pointer(s)).Fwrap
  4075  	if wrap == 2 || wrap == 1 && (*Deflate_state)(unsafe.Pointer(s)).Fstatus != INIT_STATE || (*Deflate_state)(unsafe.Pointer(s)).Flookahead != 0 {
  4076  		return -2
  4077  	}
  4078  
  4079  	// when using zlib wrappers, compute Adler-32 for provided dictionary
  4080  	if wrap == 1 {
  4081  		(*Z_stream)(unsafe.Pointer(strm)).Fadler = Xadler32(tls, (*Z_stream)(unsafe.Pointer(strm)).Fadler, dictionary, dictLength)
  4082  	}
  4083  	(*Deflate_state)(unsafe.Pointer(s)).Fwrap = 0 // avoid computing Adler-32 in read_buf
  4084  
  4085  	// if dictionary would fill window, just replace the history
  4086  	if dictLength >= (*Deflate_state)(unsafe.Pointer(s)).Fw_size {
  4087  		if wrap == 0 { // already empty otherwise
  4088  			*(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fhash_size-UInt(1))*2)) = Posf(NIL)
  4089  			libc.Xmemset(tls, (*Deflate_state)(unsafe.Pointer(s)).Fhead, 0, uint64((*Deflate_state)(unsafe.Pointer(s)).Fhash_size-UInt(1))*uint64(unsafe.Sizeof(Posf(0))))
  4090  
  4091  			(*Deflate_state)(unsafe.Pointer(s)).Fstrstart = UInt(0)
  4092  			(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = 0
  4093  			(*Deflate_state)(unsafe.Pointer(s)).Finsert = UInt(0)
  4094  		}
  4095  		dictionary += uintptr(dictLength - (*Deflate_state)(unsafe.Pointer(s)).Fw_size) // use the tail
  4096  		dictLength = (*Deflate_state)(unsafe.Pointer(s)).Fw_size
  4097  	}
  4098  
  4099  	// insert dictionary into window and hash
  4100  	avail = (*Z_stream)(unsafe.Pointer(strm)).Favail_in
  4101  	next = (*Z_stream)(unsafe.Pointer(strm)).Fnext_in
  4102  	(*Z_stream)(unsafe.Pointer(strm)).Favail_in = dictLength
  4103  	(*Z_stream)(unsafe.Pointer(strm)).Fnext_in = dictionary
  4104  	fill_window(tls, s)
  4105  	for (*Deflate_state)(unsafe.Pointer(s)).Flookahead >= UInt(MIN_MATCH) {
  4106  		str = (*Deflate_state)(unsafe.Pointer(s)).Fstrstart
  4107  		n = (*Deflate_state)(unsafe.Pointer(s)).Flookahead - UInt(MIN_MATCH-1)
  4108  		for ok := true; ok; ok = libc.PreDecUint32(&n, 1) != 0 {
  4109  			(*Deflate_state)(unsafe.Pointer(s)).Fins_h = ((*Deflate_state)(unsafe.Pointer(s)).Fins_h<<(*Deflate_state)(unsafe.Pointer(s)).Fhash_shift ^ UInt(*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(str+UInt(MIN_MATCH)-UInt(1)))))) & (*Deflate_state)(unsafe.Pointer(s)).Fhash_mask
  4110  			*(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fprev + uintptr(str&(*Deflate_state)(unsafe.Pointer(s)).Fw_mask)*2)) = *(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fins_h)*2))
  4111  			*(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fins_h)*2)) = Pos(str)
  4112  			str++
  4113  		}
  4114  		(*Deflate_state)(unsafe.Pointer(s)).Fstrstart = str
  4115  		(*Deflate_state)(unsafe.Pointer(s)).Flookahead = UInt(MIN_MATCH - 1)
  4116  		fill_window(tls, s)
  4117  	}
  4118  	*(*UInt)(unsafe.Pointer(s + 172)) += (*Deflate_state)(unsafe.Pointer(s)).Flookahead
  4119  	(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  4120  	(*Deflate_state)(unsafe.Pointer(s)).Finsert = (*Deflate_state)(unsafe.Pointer(s)).Flookahead
  4121  	(*Deflate_state)(unsafe.Pointer(s)).Flookahead = UInt(0)
  4122  	(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length = libc.AssignPtrUint32(s+184, UInt(MIN_MATCH-1))
  4123  	(*Deflate_state)(unsafe.Pointer(s)).Fmatch_available = 0
  4124  	(*Z_stream)(unsafe.Pointer(strm)).Fnext_in = next
  4125  	(*Z_stream)(unsafe.Pointer(strm)).Favail_in = avail
  4126  	(*Deflate_state)(unsafe.Pointer(s)).Fwrap = wrap
  4127  	return Z_OK
  4128  }
  4129  
  4130  // =========================================================================
  4131  func XdeflateGetDictionary(tls *libc.TLS, strm Z_streamp, dictionary uintptr, dictLength uintptr) int32 { /* deflate.c:445:13: */
  4132  	var s uintptr
  4133  	var len UInt
  4134  
  4135  	if deflateStateCheck(tls, strm) != 0 {
  4136  		return -2
  4137  	}
  4138  	s = (*Z_stream)(unsafe.Pointer(strm)).Fstate
  4139  	len = (*Deflate_state)(unsafe.Pointer(s)).Fstrstart + (*Deflate_state)(unsafe.Pointer(s)).Flookahead
  4140  	if len > (*Deflate_state)(unsafe.Pointer(s)).Fw_size {
  4141  		len = (*Deflate_state)(unsafe.Pointer(s)).Fw_size
  4142  	}
  4143  	if dictionary != uintptr(Z_NULL) && len != 0 {
  4144  		libc.Xmemcpy(tls, dictionary, (*Deflate_state)(unsafe.Pointer(s)).Fwindow+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)+uintptr((*Deflate_state)(unsafe.Pointer(s)).Flookahead)-uintptr(len), uint64(len))
  4145  	}
  4146  	if dictLength != uintptr(Z_NULL) {
  4147  		*(*UInt)(unsafe.Pointer(dictLength)) = len
  4148  	}
  4149  	return Z_OK
  4150  }
  4151  
  4152  // =========================================================================
  4153  func XdeflateResetKeep(tls *libc.TLS, strm Z_streamp) int32 { /* deflate.c:467:13: */
  4154  	var s uintptr
  4155  
  4156  	if deflateStateCheck(tls, strm) != 0 {
  4157  		return -2
  4158  	}
  4159  
  4160  	(*Z_stream)(unsafe.Pointer(strm)).Ftotal_in = libc.AssignPtrUint64(strm+40, uint64(0))
  4161  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = uintptr(Z_NULL) // use zfree if we ever allocate msg dynamically
  4162  	(*Z_stream)(unsafe.Pointer(strm)).Fdata_type = Z_UNKNOWN
  4163  
  4164  	s = (*Z_stream)(unsafe.Pointer(strm)).Fstate
  4165  	(*Deflate_state)(unsafe.Pointer(s)).Fpending = uint64(0)
  4166  	(*Deflate_state)(unsafe.Pointer(s)).Fpending_out = (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf
  4167  
  4168  	if (*Deflate_state)(unsafe.Pointer(s)).Fwrap < 0 {
  4169  		(*Deflate_state)(unsafe.Pointer(s)).Fwrap = -(*Deflate_state)(unsafe.Pointer(s)).Fwrap // was made negative by deflate(..., Z_FINISH);
  4170  	}
  4171  	(*Deflate_state)(unsafe.Pointer(s)).Fstatus = func() int32 {
  4172  		if (*Deflate_state)(unsafe.Pointer(s)).Fwrap == 2 {
  4173  			return GZIP_STATE
  4174  		}
  4175  		return func() int32 {
  4176  			if (*Deflate_state)(unsafe.Pointer(s)).Fwrap != 0 {
  4177  				return INIT_STATE
  4178  			}
  4179  			return BUSY_STATE
  4180  		}()
  4181  	}()
  4182  	(*Z_stream)(unsafe.Pointer(strm)).Fadler = func() uint64 {
  4183  		if (*Deflate_state)(unsafe.Pointer(s)).Fwrap == 2 {
  4184  			return Xcrc32(tls, uint64(0), uintptr(Z_NULL), uint32(0))
  4185  		}
  4186  		return Xadler32(tls, uint64(0), uintptr(Z_NULL), uint32(0))
  4187  	}()
  4188  	(*Deflate_state)(unsafe.Pointer(s)).Flast_flush = Z_NO_FLUSH
  4189  
  4190  	X_tr_init(tls, s)
  4191  
  4192  	return Z_OK
  4193  }
  4194  
  4195  // =========================================================================
  4196  func XdeflateReset(tls *libc.TLS, strm Z_streamp) int32 { /* deflate.c:505:13: */
  4197  	var ret int32
  4198  
  4199  	ret = XdeflateResetKeep(tls, strm)
  4200  	if ret == Z_OK {
  4201  		lm_init(tls, (*Z_stream)(unsafe.Pointer(strm)).Fstate)
  4202  	}
  4203  	return ret
  4204  }
  4205  
  4206  // =========================================================================
  4207  func XdeflateSetHeader(tls *libc.TLS, strm Z_streamp, head Gz_headerp) int32 { /* deflate.c:517:13: */
  4208  	if deflateStateCheck(tls, strm) != 0 || (*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fwrap != 2 {
  4209  		return -2
  4210  	}
  4211  	(*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fgzhead = head
  4212  	return Z_OK
  4213  }
  4214  
  4215  // =========================================================================
  4216  func XdeflatePending(tls *libc.TLS, strm Z_streamp, pending uintptr, bits uintptr) int32 { /* deflate.c:528:13: */
  4217  	if deflateStateCheck(tls, strm) != 0 {
  4218  		return -2
  4219  	}
  4220  	if pending != uintptr(Z_NULL) {
  4221  		*(*uint32)(unsafe.Pointer(pending)) = uint32((*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fpending)
  4222  	}
  4223  	if bits != uintptr(Z_NULL) {
  4224  		*(*int32)(unsafe.Pointer(bits)) = (*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fbi_valid
  4225  	}
  4226  	return Z_OK
  4227  }
  4228  
  4229  // =========================================================================
  4230  func XdeflatePrime(tls *libc.TLS, strm Z_streamp, bits int32, value int32) int32 { /* deflate.c:542:13: */
  4231  	var s uintptr
  4232  	var put int32
  4233  
  4234  	if deflateStateCheck(tls, strm) != 0 {
  4235  		return -2
  4236  	}
  4237  	s = (*Z_stream)(unsafe.Pointer(strm)).Fstate
  4238  	if (*Deflate_state)(unsafe.Pointer(s)).Fd_buf < (*Deflate_state)(unsafe.Pointer(s)).Fpending_out+uintptr(int32(Buf_size+7)>>3) {
  4239  		return -5
  4240  	}
  4241  	for ok := true; ok; ok = bits != 0 {
  4242  		put = Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid
  4243  		if put > bits {
  4244  			put = bits
  4245  		}
  4246  		*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(value & (int32(1)<<put - 1) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)))
  4247  		*(*int32)(unsafe.Pointer(s + 5940)) += put
  4248  		X_tr_flush_bits(tls, s)
  4249  		value >>= put
  4250  		bits = bits - put
  4251  	}
  4252  	return Z_OK
  4253  }
  4254  
  4255  // =========================================================================
  4256  func XdeflateParams(tls *libc.TLS, strm Z_streamp, level int32, strategy int32) int32 { /* deflate.c:568:13: */
  4257  	var s uintptr
  4258  	var func1 Compress_func
  4259  
  4260  	if deflateStateCheck(tls, strm) != 0 {
  4261  		return -2
  4262  	}
  4263  	s = (*Z_stream)(unsafe.Pointer(strm)).Fstate
  4264  
  4265  	if level == -1 {
  4266  		level = 6
  4267  	}
  4268  	if level < 0 || level > 9 || strategy < 0 || strategy > Z_FIXED {
  4269  		return -2
  4270  	}
  4271  	func1 = configuration_table[(*Deflate_state)(unsafe.Pointer(s)).Flevel].Ffunc
  4272  
  4273  	if (strategy != (*Deflate_state)(unsafe.Pointer(s)).Fstrategy || func1 != configuration_table[level].Ffunc) && (*Deflate_state)(unsafe.Pointer(s)).Fhigh_water != 0 {
  4274  		// Flush the last buffer:
  4275  		var err int32 = Xdeflate(tls, strm, Z_BLOCK)
  4276  		if err == -2 {
  4277  			return err
  4278  		}
  4279  		if (*Z_stream)(unsafe.Pointer(strm)).Favail_out == UInt(0) {
  4280  			return -5
  4281  		}
  4282  	}
  4283  	if (*Deflate_state)(unsafe.Pointer(s)).Flevel != level {
  4284  		if (*Deflate_state)(unsafe.Pointer(s)).Flevel == 0 && (*Deflate_state)(unsafe.Pointer(s)).Fmatches != UInt(0) {
  4285  			if (*Deflate_state)(unsafe.Pointer(s)).Fmatches == UInt(1) {
  4286  				slide_hash(tls, s)
  4287  			} else {
  4288  				*(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fhash_size-UInt(1))*2)) = Posf(NIL)
  4289  			}
  4290  			libc.Xmemset(tls, (*Deflate_state)(unsafe.Pointer(s)).Fhead, 0, uint64((*Deflate_state)(unsafe.Pointer(s)).Fhash_size-UInt(1))*uint64(unsafe.Sizeof(Posf(0))))
  4291  
  4292  			(*Deflate_state)(unsafe.Pointer(s)).Fmatches = UInt(0)
  4293  		}
  4294  		(*Deflate_state)(unsafe.Pointer(s)).Flevel = level
  4295  		(*Deflate_state)(unsafe.Pointer(s)).Fmax_lazy_match = UInt(configuration_table[level].Fmax_lazy)
  4296  		(*Deflate_state)(unsafe.Pointer(s)).Fgood_match = UInt(configuration_table[level].Fgood_length)
  4297  		(*Deflate_state)(unsafe.Pointer(s)).Fnice_match = int32(configuration_table[level].Fnice_length)
  4298  		(*Deflate_state)(unsafe.Pointer(s)).Fmax_chain_length = UInt(configuration_table[level].Fmax_chain)
  4299  	}
  4300  	(*Deflate_state)(unsafe.Pointer(s)).Fstrategy = strategy
  4301  	return Z_OK
  4302  }
  4303  
  4304  // =========================================================================
  4305  func XdeflateTune(tls *libc.TLS, strm Z_streamp, good_length int32, max_lazy int32, nice_length int32, max_chain int32) int32 { /* deflate.c:617:13: */
  4306  	var s uintptr
  4307  
  4308  	if deflateStateCheck(tls, strm) != 0 {
  4309  		return -2
  4310  	}
  4311  	s = (*Z_stream)(unsafe.Pointer(strm)).Fstate
  4312  	(*Deflate_state)(unsafe.Pointer(s)).Fgood_match = UInt(good_length)
  4313  	(*Deflate_state)(unsafe.Pointer(s)).Fmax_lazy_match = UInt(max_lazy)
  4314  	(*Deflate_state)(unsafe.Pointer(s)).Fnice_match = nice_length
  4315  	(*Deflate_state)(unsafe.Pointer(s)).Fmax_chain_length = UInt(max_chain)
  4316  	return Z_OK
  4317  }
  4318  
  4319  // =========================================================================
  4320  // For the default windowBits of 15 and memLevel of 8, this function returns
  4321  // a close to exact, as well as small, upper bound on the compressed size.
  4322  // They are coded as constants here for a reason--if the #define's are
  4323  // changed, then this function needs to be changed as well.  The return
  4324  // value for 15 and 8 only works for those exact settings.
  4325  //
  4326  // For any setting other than those defaults for windowBits and memLevel,
  4327  // the value returned is a conservative worst case for the maximum expansion
  4328  // resulting from using fixed blocks instead of stored blocks, which deflate
  4329  // can emit on compressed data for some combinations of the parameters.
  4330  //
  4331  // This function could be more sophisticated to provide closer upper bounds for
  4332  // every combination of windowBits and memLevel.  But even the conservative
  4333  // upper bound of about 14% expansion does not seem onerous for output buffer
  4334  // allocation.
  4335  func XdeflateBound(tls *libc.TLS, strm Z_streamp, sourceLen ULong) ULong { /* deflate.c:652:15: */
  4336  	var s uintptr
  4337  	var complen ULong
  4338  	var wraplen ULong
  4339  
  4340  	// conservative upper bound for compressed data
  4341  	complen = sourceLen + (sourceLen+uint64(7))>>3 + (sourceLen+uint64(63))>>6 + uint64(5)
  4342  
  4343  	// if can't get parameters, return conservative bound plus zlib wrapper
  4344  	if deflateStateCheck(tls, strm) != 0 {
  4345  		return complen + uint64(6)
  4346  	}
  4347  
  4348  	// compute wrapper length
  4349  	s = (*Z_stream)(unsafe.Pointer(strm)).Fstate
  4350  	switch (*Deflate_state)(unsafe.Pointer(s)).Fwrap {
  4351  	case 0: // raw deflate
  4352  		wraplen = uint64(0)
  4353  		break
  4354  	case 1: // zlib wrapper
  4355  		wraplen = ULong(6 + func() int32 {
  4356  			if (*Deflate_state)(unsafe.Pointer(s)).Fstrstart != 0 {
  4357  				return 4
  4358  			}
  4359  			return 0
  4360  		}())
  4361  		break
  4362  	case 2: // gzip wrapper
  4363  		wraplen = uint64(18)
  4364  		if (*Deflate_state)(unsafe.Pointer(s)).Fgzhead != uintptr(Z_NULL) { // user-supplied gzip header
  4365  			var str uintptr
  4366  			if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fextra != uintptr(Z_NULL) {
  4367  				wraplen = wraplen + ULong(UInt(2)+(*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fextra_len)
  4368  			}
  4369  			str = (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fname
  4370  			if str != uintptr(Z_NULL) {
  4371  				for ok := true; ok; ok = *(*Bytef)(unsafe.Pointer(libc.PostIncUintptr(&str, 1))) != 0 {
  4372  					wraplen++
  4373  				}
  4374  			}
  4375  			str = (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fcomment
  4376  			if str != uintptr(Z_NULL) {
  4377  				for ok1 := true; ok1; ok1 = *(*Bytef)(unsafe.Pointer(libc.PostIncUintptr(&str, 1))) != 0 {
  4378  					wraplen++
  4379  				}
  4380  			}
  4381  			if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fhcrc != 0 {
  4382  				wraplen = wraplen + uint64(2)
  4383  			}
  4384  		}
  4385  		break
  4386  	default: // for compiler happiness
  4387  		wraplen = uint64(6)
  4388  	}
  4389  
  4390  	// if not default parameters, return conservative bound
  4391  	if (*Deflate_state)(unsafe.Pointer(s)).Fw_bits != UInt(15) || (*Deflate_state)(unsafe.Pointer(s)).Fhash_bits != UInt(8+7) {
  4392  		return complen + wraplen
  4393  	}
  4394  
  4395  	// default settings: return tight bound for that case
  4396  	return sourceLen + sourceLen>>12 + sourceLen>>14 + sourceLen>>25 + uint64(13) - uint64(6) + wraplen
  4397  }
  4398  
  4399  // =========================================================================
  4400  // Put a short in the pending buffer. The 16-bit value is put in MSB order.
  4401  // IN assertion: the stream state is correct and there is enough room in
  4402  // pending_buf.
  4403  func putShortMSB(tls *libc.TLS, s uintptr, b UInt) { /* deflate.c:716:12: */
  4404  	{
  4405  		*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte(b >> 8)
  4406  	}
  4407  
  4408  	{
  4409  		*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte(b & UInt(0xff))
  4410  	}
  4411  
  4412  }
  4413  
  4414  // =========================================================================
  4415  // Flush as much pending output as possible. All deflate() output, except for
  4416  // some deflate_stored() output, goes through this function so some
  4417  // applications may wish to modify it to avoid allocating a large
  4418  // strm->next_out buffer and copying into it. (See also read_buf()).
  4419  func flush_pending(tls *libc.TLS, strm Z_streamp) { /* deflate.c:730:12: */
  4420  	var len uint32
  4421  	var s uintptr = (*Z_stream)(unsafe.Pointer(strm)).Fstate
  4422  
  4423  	X_tr_flush_bits(tls, s)
  4424  	len = uint32((*Deflate_state)(unsafe.Pointer(s)).Fpending)
  4425  	if len > (*Z_stream)(unsafe.Pointer(strm)).Favail_out {
  4426  		len = (*Z_stream)(unsafe.Pointer(strm)).Favail_out
  4427  	}
  4428  	if len == uint32(0) {
  4429  		return
  4430  	}
  4431  
  4432  	libc.Xmemcpy(tls, (*Z_stream)(unsafe.Pointer(strm)).Fnext_out, (*Deflate_state)(unsafe.Pointer(s)).Fpending_out, uint64(len))
  4433  	*(*uintptr)(unsafe.Pointer(strm + 24)) += uintptr(len)
  4434  	*(*uintptr)(unsafe.Pointer(s + 32)) += uintptr(len)
  4435  	*(*ULong)(unsafe.Pointer(strm + 40)) += ULong(len)
  4436  	*(*UInt)(unsafe.Pointer(strm + 32)) -= len
  4437  	*(*Ulg)(unsafe.Pointer(s + 40)) -= Ulg(len)
  4438  	if (*Deflate_state)(unsafe.Pointer(s)).Fpending == uint64(0) {
  4439  		(*Deflate_state)(unsafe.Pointer(s)).Fpending_out = (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf
  4440  	}
  4441  }
  4442  
  4443  // ===========================================================================
  4444  // Update the header CRC with the bytes s->pending_buf[beg..s->pending - 1].
  4445  
  4446  // =========================================================================
  4447  func Xdeflate(tls *libc.TLS, strm Z_streamp, flush int32) int32 { /* deflate.c:763:13: */
  4448  	var old_flush int32 // value of flush param for previous deflate call
  4449  	var s uintptr
  4450  
  4451  	if deflateStateCheck(tls, strm) != 0 || flush > Z_BLOCK || flush < 0 {
  4452  		return -2
  4453  	}
  4454  	s = (*Z_stream)(unsafe.Pointer(strm)).Fstate
  4455  
  4456  	if (*Z_stream)(unsafe.Pointer(strm)).Fnext_out == uintptr(Z_NULL) || (*Z_stream)(unsafe.Pointer(strm)).Favail_in != UInt(0) && (*Z_stream)(unsafe.Pointer(strm)).Fnext_in == uintptr(Z_NULL) || (*Deflate_state)(unsafe.Pointer(s)).Fstatus == FINISH_STATE && flush != Z_FINISH {
  4457  		return func() int32 { (*Z_stream)(unsafe.Pointer(strm)).Fmsg = Xz_errmsg[Z_NEED_DICT - -2]; return -2 }()
  4458  	}
  4459  	if (*Z_stream)(unsafe.Pointer(strm)).Favail_out == UInt(0) {
  4460  		return func() int32 { (*Z_stream)(unsafe.Pointer(strm)).Fmsg = Xz_errmsg[Z_NEED_DICT - -5]; return -5 }()
  4461  	}
  4462  
  4463  	old_flush = (*Deflate_state)(unsafe.Pointer(s)).Flast_flush
  4464  	(*Deflate_state)(unsafe.Pointer(s)).Flast_flush = flush
  4465  
  4466  	// Flush as much pending output as possible
  4467  	if (*Deflate_state)(unsafe.Pointer(s)).Fpending != uint64(0) {
  4468  		flush_pending(tls, strm)
  4469  		if (*Z_stream)(unsafe.Pointer(strm)).Favail_out == UInt(0) {
  4470  			// Since avail_out is 0, deflate will be called again with
  4471  			// more output space, but possibly with both pending and
  4472  			// avail_in equal to zero. There won't be anything to do,
  4473  			// but this is not an error situation so make sure we
  4474  			// return OK instead of BUF_ERROR at next call of deflate:
  4475  			(*Deflate_state)(unsafe.Pointer(s)).Flast_flush = -1
  4476  			return Z_OK
  4477  		}
  4478  
  4479  		// Make sure there is something to do and avoid duplicate consecutive
  4480  		// flushes. For repeated and useless calls with Z_FINISH, we keep
  4481  		// returning Z_STREAM_END instead of Z_BUF_ERROR.
  4482  	} else if (*Z_stream)(unsafe.Pointer(strm)).Favail_in == UInt(0) && flush*2-func() int32 {
  4483  		if flush > 4 {
  4484  			return 9
  4485  		}
  4486  		return 0
  4487  	}() <= old_flush*2-func() int32 {
  4488  		if old_flush > 4 {
  4489  			return 9
  4490  		}
  4491  		return 0
  4492  	}() && flush != Z_FINISH {
  4493  		return func() int32 { (*Z_stream)(unsafe.Pointer(strm)).Fmsg = Xz_errmsg[Z_NEED_DICT - -5]; return -5 }()
  4494  	}
  4495  
  4496  	// User must not provide more input after the first FINISH:
  4497  	if (*Deflate_state)(unsafe.Pointer(s)).Fstatus == FINISH_STATE && (*Z_stream)(unsafe.Pointer(strm)).Favail_in != UInt(0) {
  4498  		return func() int32 { (*Z_stream)(unsafe.Pointer(strm)).Fmsg = Xz_errmsg[Z_NEED_DICT - -5]; return -5 }()
  4499  	}
  4500  
  4501  	// Write the header
  4502  	if (*Deflate_state)(unsafe.Pointer(s)).Fstatus == INIT_STATE {
  4503  		// zlib header
  4504  		var header UInt = (UInt(Z_DEFLATED) + ((*Deflate_state)(unsafe.Pointer(s)).Fw_bits-UInt(8))<<4) << 8
  4505  		var level_flags UInt
  4506  
  4507  		if (*Deflate_state)(unsafe.Pointer(s)).Fstrategy >= Z_HUFFMAN_ONLY || (*Deflate_state)(unsafe.Pointer(s)).Flevel < 2 {
  4508  			level_flags = UInt(0)
  4509  		} else if (*Deflate_state)(unsafe.Pointer(s)).Flevel < 6 {
  4510  			level_flags = UInt(1)
  4511  		} else if (*Deflate_state)(unsafe.Pointer(s)).Flevel == 6 {
  4512  			level_flags = UInt(2)
  4513  		} else {
  4514  			level_flags = UInt(3)
  4515  		}
  4516  		header = header | level_flags<<6
  4517  		if (*Deflate_state)(unsafe.Pointer(s)).Fstrstart != UInt(0) {
  4518  			header = header | UInt(PRESET_DICT)
  4519  		}
  4520  		header = header + (UInt(31) - header%UInt(31))
  4521  
  4522  		putShortMSB(tls, s, header)
  4523  
  4524  		// Save the adler32 of the preset dictionary:
  4525  		if (*Deflate_state)(unsafe.Pointer(s)).Fstrstart != UInt(0) {
  4526  			putShortMSB(tls, s, UInt((*Z_stream)(unsafe.Pointer(strm)).Fadler>>16))
  4527  			putShortMSB(tls, s, UInt((*Z_stream)(unsafe.Pointer(strm)).Fadler&uint64(0xffff)))
  4528  		}
  4529  		(*Z_stream)(unsafe.Pointer(strm)).Fadler = Xadler32(tls, uint64(0), uintptr(Z_NULL), uint32(0))
  4530  		(*Deflate_state)(unsafe.Pointer(s)).Fstatus = BUSY_STATE
  4531  
  4532  		// Compression must start with an empty pending buffer
  4533  		flush_pending(tls, strm)
  4534  		if (*Deflate_state)(unsafe.Pointer(s)).Fpending != uint64(0) {
  4535  			(*Deflate_state)(unsafe.Pointer(s)).Flast_flush = -1
  4536  			return Z_OK
  4537  		}
  4538  	}
  4539  	if (*Deflate_state)(unsafe.Pointer(s)).Fstatus == GZIP_STATE {
  4540  		// gzip header
  4541  		(*Z_stream)(unsafe.Pointer(strm)).Fadler = Xcrc32(tls, uint64(0), uintptr(Z_NULL), uint32(0))
  4542  		{
  4543  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef(31)
  4544  		}
  4545  
  4546  		{
  4547  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef(139)
  4548  		}
  4549  
  4550  		{
  4551  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef(8)
  4552  		}
  4553  
  4554  		if (*Deflate_state)(unsafe.Pointer(s)).Fgzhead == uintptr(Z_NULL) {
  4555  			{
  4556  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef(0)
  4557  			}
  4558  
  4559  			{
  4560  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef(0)
  4561  			}
  4562  
  4563  			{
  4564  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef(0)
  4565  			}
  4566  
  4567  			{
  4568  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef(0)
  4569  			}
  4570  
  4571  			{
  4572  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef(0)
  4573  			}
  4574  
  4575  			{
  4576  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = func() uint8 {
  4577  					if (*Deflate_state)(unsafe.Pointer(s)).Flevel == 9 {
  4578  						return uint8(2)
  4579  					}
  4580  					return func() uint8 {
  4581  						if (*Deflate_state)(unsafe.Pointer(s)).Fstrategy >= Z_HUFFMAN_ONLY || (*Deflate_state)(unsafe.Pointer(s)).Flevel < 2 {
  4582  							return uint8(4)
  4583  						}
  4584  						return uint8(0)
  4585  					}()
  4586  				}()
  4587  			}
  4588  
  4589  			{
  4590  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef(OS_CODE)
  4591  			}
  4592  
  4593  			(*Deflate_state)(unsafe.Pointer(s)).Fstatus = BUSY_STATE
  4594  
  4595  			// Compression must start with an empty pending buffer
  4596  			flush_pending(tls, strm)
  4597  			if (*Deflate_state)(unsafe.Pointer(s)).Fpending != uint64(0) {
  4598  				(*Deflate_state)(unsafe.Pointer(s)).Flast_flush = -1
  4599  				return Z_OK
  4600  			}
  4601  		} else {
  4602  			{
  4603  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef(func() int32 {
  4604  					if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Ftext != 0 {
  4605  						return 1
  4606  					}
  4607  					return 0
  4608  				}() + func() int32 {
  4609  					if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fhcrc != 0 {
  4610  						return 2
  4611  					}
  4612  					return 0
  4613  				}() + func() int32 {
  4614  					if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fextra == uintptr(Z_NULL) {
  4615  						return 0
  4616  					}
  4617  					return 4
  4618  				}() + func() int32 {
  4619  					if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fname == uintptr(Z_NULL) {
  4620  						return 0
  4621  					}
  4622  					return 8
  4623  				}() + func() int32 {
  4624  					if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fcomment == uintptr(Z_NULL) {
  4625  						return 0
  4626  					}
  4627  					return 16
  4628  				}())
  4629  			}
  4630  
  4631  			{
  4632  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Ftime & uint64(0xff))
  4633  			}
  4634  
  4635  			{
  4636  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Ftime >> 8 & uint64(0xff))
  4637  			}
  4638  
  4639  			{
  4640  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Ftime >> 16 & uint64(0xff))
  4641  			}
  4642  
  4643  			{
  4644  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Ftime >> 24 & uint64(0xff))
  4645  			}
  4646  
  4647  			{
  4648  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = func() uint8 {
  4649  					if (*Deflate_state)(unsafe.Pointer(s)).Flevel == 9 {
  4650  						return uint8(2)
  4651  					}
  4652  					return func() uint8 {
  4653  						if (*Deflate_state)(unsafe.Pointer(s)).Fstrategy >= Z_HUFFMAN_ONLY || (*Deflate_state)(unsafe.Pointer(s)).Flevel < 2 {
  4654  							return uint8(4)
  4655  						}
  4656  						return uint8(0)
  4657  					}()
  4658  				}()
  4659  			}
  4660  
  4661  			{
  4662  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef((*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fos & 0xff)
  4663  			}
  4664  
  4665  			if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fextra != uintptr(Z_NULL) {
  4666  				{
  4667  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef((*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fextra_len & UInt(0xff))
  4668  				}
  4669  
  4670  				{
  4671  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef((*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fextra_len >> 8 & UInt(0xff))
  4672  				}
  4673  
  4674  			}
  4675  			if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fhcrc != 0 {
  4676  				(*Z_stream)(unsafe.Pointer(strm)).Fadler = Xcrc32(tls, (*Z_stream)(unsafe.Pointer(strm)).Fadler, (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf,
  4677  					uint32((*Deflate_state)(unsafe.Pointer(s)).Fpending))
  4678  			}
  4679  			(*Deflate_state)(unsafe.Pointer(s)).Fgzindex = uint64(0)
  4680  			(*Deflate_state)(unsafe.Pointer(s)).Fstatus = EXTRA_STATE
  4681  		}
  4682  	}
  4683  	if (*Deflate_state)(unsafe.Pointer(s)).Fstatus == EXTRA_STATE {
  4684  		if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fextra != uintptr(Z_NULL) {
  4685  			var beg Ulg = (*Deflate_state)(unsafe.Pointer(s)).Fpending // start of bytes to update crc
  4686  			var left UInt = UInt(Ulg((*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fextra_len&UInt(0xffff)) - (*Deflate_state)(unsafe.Pointer(s)).Fgzindex)
  4687  			for (*Deflate_state)(unsafe.Pointer(s)).Fpending+Ulg(left) > (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf_size {
  4688  				var copy UInt = UInt((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fpending)
  4689  				libc.Xmemcpy(tls, (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fpending),
  4690  					(*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fextra+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fgzindex), uint64(copy))
  4691  				(*Deflate_state)(unsafe.Pointer(s)).Fpending = (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf_size
  4692  				for ok := true; ok; ok = 0 != 0 {
  4693  					if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fhcrc != 0 && (*Deflate_state)(unsafe.Pointer(s)).Fpending > beg {
  4694  						(*Z_stream)(unsafe.Pointer(strm)).Fadler = Xcrc32(tls, (*Z_stream)(unsafe.Pointer(strm)).Fadler, (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf+uintptr(beg), uint32((*Deflate_state)(unsafe.Pointer(s)).Fpending-beg))
  4695  					}
  4696  				}
  4697  				*(*Ulg)(unsafe.Pointer(s + 64)) += Ulg(copy)
  4698  				flush_pending(tls, strm)
  4699  				if (*Deflate_state)(unsafe.Pointer(s)).Fpending != uint64(0) {
  4700  					(*Deflate_state)(unsafe.Pointer(s)).Flast_flush = -1
  4701  					return Z_OK
  4702  				}
  4703  				beg = uint64(0)
  4704  				left = left - copy
  4705  			}
  4706  			libc.Xmemcpy(tls, (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fpending),
  4707  				(*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fextra+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fgzindex), uint64(left))
  4708  			*(*Ulg)(unsafe.Pointer(s + 40)) += Ulg(left)
  4709  			for ok1 := true; ok1; ok1 = 0 != 0 {
  4710  				if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fhcrc != 0 && (*Deflate_state)(unsafe.Pointer(s)).Fpending > beg {
  4711  					(*Z_stream)(unsafe.Pointer(strm)).Fadler = Xcrc32(tls, (*Z_stream)(unsafe.Pointer(strm)).Fadler, (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf+uintptr(beg), uint32((*Deflate_state)(unsafe.Pointer(s)).Fpending-beg))
  4712  				}
  4713  			}
  4714  			(*Deflate_state)(unsafe.Pointer(s)).Fgzindex = uint64(0)
  4715  		}
  4716  		(*Deflate_state)(unsafe.Pointer(s)).Fstatus = NAME_STATE
  4717  	}
  4718  	if (*Deflate_state)(unsafe.Pointer(s)).Fstatus == NAME_STATE {
  4719  		if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fname != uintptr(Z_NULL) {
  4720  			var beg Ulg = (*Deflate_state)(unsafe.Pointer(s)).Fpending // start of bytes to update crc
  4721  			var val int32
  4722  			for ok2 := true; ok2; ok2 = val != 0 {
  4723  				if (*Deflate_state)(unsafe.Pointer(s)).Fpending == (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf_size {
  4724  					for ok3 := true; ok3; ok3 = 0 != 0 {
  4725  						if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fhcrc != 0 && (*Deflate_state)(unsafe.Pointer(s)).Fpending > beg {
  4726  							(*Z_stream)(unsafe.Pointer(strm)).Fadler = Xcrc32(tls, (*Z_stream)(unsafe.Pointer(strm)).Fadler, (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf+uintptr(beg), uint32((*Deflate_state)(unsafe.Pointer(s)).Fpending-beg))
  4727  						}
  4728  					}
  4729  					flush_pending(tls, strm)
  4730  					if (*Deflate_state)(unsafe.Pointer(s)).Fpending != uint64(0) {
  4731  						(*Deflate_state)(unsafe.Pointer(s)).Flast_flush = -1
  4732  						return Z_OK
  4733  					}
  4734  					beg = uint64(0)
  4735  				}
  4736  				val = int32(*(*Bytef)(unsafe.Pointer((*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fname + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fgzindex, 1)))))
  4737  				{
  4738  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef(val)
  4739  				}
  4740  
  4741  			}
  4742  			for ok4 := true; ok4; ok4 = 0 != 0 {
  4743  				if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fhcrc != 0 && (*Deflate_state)(unsafe.Pointer(s)).Fpending > beg {
  4744  					(*Z_stream)(unsafe.Pointer(strm)).Fadler = Xcrc32(tls, (*Z_stream)(unsafe.Pointer(strm)).Fadler, (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf+uintptr(beg), uint32((*Deflate_state)(unsafe.Pointer(s)).Fpending-beg))
  4745  				}
  4746  			}
  4747  			(*Deflate_state)(unsafe.Pointer(s)).Fgzindex = uint64(0)
  4748  		}
  4749  		(*Deflate_state)(unsafe.Pointer(s)).Fstatus = COMMENT_STATE
  4750  	}
  4751  	if (*Deflate_state)(unsafe.Pointer(s)).Fstatus == COMMENT_STATE {
  4752  		if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fcomment != uintptr(Z_NULL) {
  4753  			var beg Ulg = (*Deflate_state)(unsafe.Pointer(s)).Fpending // start of bytes to update crc
  4754  			var val int32
  4755  			for ok5 := true; ok5; ok5 = val != 0 {
  4756  				if (*Deflate_state)(unsafe.Pointer(s)).Fpending == (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf_size {
  4757  					for ok6 := true; ok6; ok6 = 0 != 0 {
  4758  						if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fhcrc != 0 && (*Deflate_state)(unsafe.Pointer(s)).Fpending > beg {
  4759  							(*Z_stream)(unsafe.Pointer(strm)).Fadler = Xcrc32(tls, (*Z_stream)(unsafe.Pointer(strm)).Fadler, (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf+uintptr(beg), uint32((*Deflate_state)(unsafe.Pointer(s)).Fpending-beg))
  4760  						}
  4761  					}
  4762  					flush_pending(tls, strm)
  4763  					if (*Deflate_state)(unsafe.Pointer(s)).Fpending != uint64(0) {
  4764  						(*Deflate_state)(unsafe.Pointer(s)).Flast_flush = -1
  4765  						return Z_OK
  4766  					}
  4767  					beg = uint64(0)
  4768  				}
  4769  				val = int32(*(*Bytef)(unsafe.Pointer((*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fcomment + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fgzindex, 1)))))
  4770  				{
  4771  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Bytef(val)
  4772  				}
  4773  
  4774  			}
  4775  			for ok7 := true; ok7; ok7 = 0 != 0 {
  4776  				if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fhcrc != 0 && (*Deflate_state)(unsafe.Pointer(s)).Fpending > beg {
  4777  					(*Z_stream)(unsafe.Pointer(strm)).Fadler = Xcrc32(tls, (*Z_stream)(unsafe.Pointer(strm)).Fadler, (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf+uintptr(beg), uint32((*Deflate_state)(unsafe.Pointer(s)).Fpending-beg))
  4778  				}
  4779  			}
  4780  		}
  4781  		(*Deflate_state)(unsafe.Pointer(s)).Fstatus = HCRC_STATE
  4782  	}
  4783  	if (*Deflate_state)(unsafe.Pointer(s)).Fstatus == HCRC_STATE {
  4784  		if (*Gz_header)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fgzhead)).Fhcrc != 0 {
  4785  			if (*Deflate_state)(unsafe.Pointer(s)).Fpending+uint64(2) > (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf_size {
  4786  				flush_pending(tls, strm)
  4787  				if (*Deflate_state)(unsafe.Pointer(s)).Fpending != uint64(0) {
  4788  					(*Deflate_state)(unsafe.Pointer(s)).Flast_flush = -1
  4789  					return Z_OK
  4790  				}
  4791  			}
  4792  			{
  4793  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Z_stream)(unsafe.Pointer(strm)).Fadler & uint64(0xff))
  4794  			}
  4795  
  4796  			{
  4797  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Z_stream)(unsafe.Pointer(strm)).Fadler >> 8 & uint64(0xff))
  4798  			}
  4799  
  4800  			(*Z_stream)(unsafe.Pointer(strm)).Fadler = Xcrc32(tls, uint64(0), uintptr(Z_NULL), uint32(0))
  4801  		}
  4802  		(*Deflate_state)(unsafe.Pointer(s)).Fstatus = BUSY_STATE
  4803  
  4804  		// Compression must start with an empty pending buffer
  4805  		flush_pending(tls, strm)
  4806  		if (*Deflate_state)(unsafe.Pointer(s)).Fpending != uint64(0) {
  4807  			(*Deflate_state)(unsafe.Pointer(s)).Flast_flush = -1
  4808  			return Z_OK
  4809  		}
  4810  	}
  4811  
  4812  	// Start a new block or continue the current one.
  4813  	if (*Z_stream)(unsafe.Pointer(strm)).Favail_in != UInt(0) || (*Deflate_state)(unsafe.Pointer(s)).Flookahead != UInt(0) || flush != Z_NO_FLUSH && (*Deflate_state)(unsafe.Pointer(s)).Fstatus != FINISH_STATE {
  4814  		var bstate Block_state
  4815  
  4816  		if (*Deflate_state)(unsafe.Pointer(s)).Flevel == 0 {
  4817  			bstate = deflate_stored(tls, s, flush)
  4818  		} else {
  4819  			if (*Deflate_state)(unsafe.Pointer(s)).Fstrategy == Z_HUFFMAN_ONLY {
  4820  				bstate = deflate_huff(tls, s, flush)
  4821  			} else {
  4822  				if (*Deflate_state)(unsafe.Pointer(s)).Fstrategy == Z_RLE {
  4823  					bstate = deflate_rle(tls, s, flush)
  4824  				} else {
  4825  					bstate = (*struct {
  4826  						f func(*libc.TLS, uintptr, int32) Block_state
  4827  					})(unsafe.Pointer(&struct{ uintptr }{configuration_table[(*Deflate_state)(unsafe.Pointer(s)).Flevel].Ffunc})).f(tls, s, flush)
  4828  				}
  4829  			}
  4830  		}
  4831  
  4832  		if bstate == Finish_started || bstate == Finish_done {
  4833  			(*Deflate_state)(unsafe.Pointer(s)).Fstatus = FINISH_STATE
  4834  		}
  4835  		if bstate == Need_more || bstate == Finish_started {
  4836  			if (*Z_stream)(unsafe.Pointer(strm)).Favail_out == UInt(0) {
  4837  				(*Deflate_state)(unsafe.Pointer(s)).Flast_flush = -1 // avoid BUF_ERROR next call, see above
  4838  			}
  4839  			return Z_OK
  4840  			// If flush != Z_NO_FLUSH && avail_out == 0, the next call
  4841  			// of deflate should use the same flush parameter to make sure
  4842  			// that the flush is complete. So we don't have to output an
  4843  			// empty block here, this will be done at next call. This also
  4844  			// ensures that for a very small output buffer, we emit at most
  4845  			// one empty block.
  4846  		}
  4847  		if bstate == Block_done {
  4848  			if flush == Z_PARTIAL_FLUSH {
  4849  				X_tr_align(tls, s)
  4850  			} else if flush != Z_BLOCK { // FULL_FLUSH or SYNC_FLUSH
  4851  				X_tr_stored_block(tls, s, uintptr(0), uint64(0), 0)
  4852  				// For a full flush, this empty block will be recognized
  4853  				// as a special marker by inflate_sync().
  4854  				if flush == Z_FULL_FLUSH {
  4855  					*(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fhash_size-UInt(1))*2)) = Posf(NIL)
  4856  					libc.Xmemset(tls, (*Deflate_state)(unsafe.Pointer(s)).Fhead, 0, uint64((*Deflate_state)(unsafe.Pointer(s)).Fhash_size-UInt(1))*uint64(unsafe.Sizeof(Posf(0))))
  4857  					// forget history
  4858  					if (*Deflate_state)(unsafe.Pointer(s)).Flookahead == UInt(0) {
  4859  						(*Deflate_state)(unsafe.Pointer(s)).Fstrstart = UInt(0)
  4860  						(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = 0
  4861  						(*Deflate_state)(unsafe.Pointer(s)).Finsert = UInt(0)
  4862  					}
  4863  				}
  4864  			}
  4865  			flush_pending(tls, strm)
  4866  			if (*Z_stream)(unsafe.Pointer(strm)).Favail_out == UInt(0) {
  4867  				(*Deflate_state)(unsafe.Pointer(s)).Flast_flush = -1 // avoid BUF_ERROR at next call, see above
  4868  				return Z_OK
  4869  			}
  4870  		}
  4871  	}
  4872  
  4873  	if flush != Z_FINISH {
  4874  		return Z_OK
  4875  	}
  4876  	if (*Deflate_state)(unsafe.Pointer(s)).Fwrap <= 0 {
  4877  		return Z_STREAM_END
  4878  	}
  4879  
  4880  	// Write the trailer
  4881  	if (*Deflate_state)(unsafe.Pointer(s)).Fwrap == 2 {
  4882  		{
  4883  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Z_stream)(unsafe.Pointer(strm)).Fadler & uint64(0xff))
  4884  		}
  4885  
  4886  		{
  4887  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Z_stream)(unsafe.Pointer(strm)).Fadler >> 8 & uint64(0xff))
  4888  		}
  4889  
  4890  		{
  4891  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Z_stream)(unsafe.Pointer(strm)).Fadler >> 16 & uint64(0xff))
  4892  		}
  4893  
  4894  		{
  4895  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Z_stream)(unsafe.Pointer(strm)).Fadler >> 24 & uint64(0xff))
  4896  		}
  4897  
  4898  		{
  4899  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Z_stream)(unsafe.Pointer(strm)).Ftotal_in & uint64(0xff))
  4900  		}
  4901  
  4902  		{
  4903  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Z_stream)(unsafe.Pointer(strm)).Ftotal_in >> 8 & uint64(0xff))
  4904  		}
  4905  
  4906  		{
  4907  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Z_stream)(unsafe.Pointer(strm)).Ftotal_in >> 16 & uint64(0xff))
  4908  		}
  4909  
  4910  		{
  4911  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Z_stream)(unsafe.Pointer(strm)).Ftotal_in >> 24 & uint64(0xff))
  4912  		}
  4913  
  4914  	} else {
  4915  		putShortMSB(tls, s, UInt((*Z_stream)(unsafe.Pointer(strm)).Fadler>>16))
  4916  		putShortMSB(tls, s, UInt((*Z_stream)(unsafe.Pointer(strm)).Fadler&uint64(0xffff)))
  4917  	}
  4918  	flush_pending(tls, strm)
  4919  	// If avail_out is zero, the application will call deflate again
  4920  	// to flush the rest.
  4921  	if (*Deflate_state)(unsafe.Pointer(s)).Fwrap > 0 {
  4922  		(*Deflate_state)(unsafe.Pointer(s)).Fwrap = -(*Deflate_state)(unsafe.Pointer(s)).Fwrap
  4923  	} // write the trailer only once!
  4924  	if (*Deflate_state)(unsafe.Pointer(s)).Fpending != uint64(0) {
  4925  		return Z_OK
  4926  	}
  4927  	return Z_STREAM_END
  4928  }
  4929  
  4930  // =========================================================================
  4931  func XdeflateEnd(tls *libc.TLS, strm Z_streamp) int32 { /* deflate.c:1076:13: */
  4932  	var status int32
  4933  
  4934  	if deflateStateCheck(tls, strm) != 0 {
  4935  		return -2
  4936  	}
  4937  
  4938  	status = (*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fstatus
  4939  
  4940  	/* Deallocate in reverse order of allocations: */
  4941  	{
  4942  		if (*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fpending_buf != 0 {
  4943  			(*struct {
  4944  				f func(*libc.TLS, Voidpf, Voidpf)
  4945  			})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzfree})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, (*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fpending_buf)
  4946  		}
  4947  	}
  4948  
  4949  	{
  4950  		if (*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fhead != 0 {
  4951  			(*struct {
  4952  				f func(*libc.TLS, Voidpf, Voidpf)
  4953  			})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzfree})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, (*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fhead)
  4954  		}
  4955  	}
  4956  
  4957  	{
  4958  		if (*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fprev != 0 {
  4959  			(*struct {
  4960  				f func(*libc.TLS, Voidpf, Voidpf)
  4961  			})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzfree})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, (*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fprev)
  4962  		}
  4963  	}
  4964  
  4965  	{
  4966  		if (*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fwindow != 0 {
  4967  			(*struct {
  4968  				f func(*libc.TLS, Voidpf, Voidpf)
  4969  			})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzfree})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, (*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fwindow)
  4970  		}
  4971  	}
  4972  
  4973  	(*struct {
  4974  		f func(*libc.TLS, Voidpf, Voidpf)
  4975  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzfree})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, (*Z_stream)(unsafe.Pointer(strm)).Fstate)
  4976  	(*Z_stream)(unsafe.Pointer(strm)).Fstate = uintptr(Z_NULL)
  4977  
  4978  	if status == BUSY_STATE {
  4979  		return -3
  4980  	}
  4981  	return Z_OK
  4982  }
  4983  
  4984  // =========================================================================
  4985  // Copy the source state to the destination state.
  4986  // To simplify the source, this is not supported for 16-bit MSDOS (which
  4987  // doesn't have enough memory anyway to duplicate compression states).
  4988  func XdeflateCopy(tls *libc.TLS, dest Z_streamp, source Z_streamp) int32 { /* deflate.c:1102:13: */
  4989  	var ds uintptr
  4990  	var ss uintptr
  4991  	var overlay uintptr
  4992  
  4993  	if deflateStateCheck(tls, source) != 0 || dest == uintptr(Z_NULL) {
  4994  		return -2
  4995  	}
  4996  
  4997  	ss = (*Z_stream)(unsafe.Pointer(source)).Fstate
  4998  
  4999  	libc.Xmemcpy(tls, dest, source, uint64(unsafe.Sizeof(Z_stream{})))
  5000  
  5001  	ds = (*struct {
  5002  		f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
  5003  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(dest)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(dest)).Fopaque, uint32(1), uint32(unsafe.Sizeof(Deflate_state{})))
  5004  	if ds == uintptr(Z_NULL) {
  5005  		return -4
  5006  	}
  5007  	(*Z_stream)(unsafe.Pointer(dest)).Fstate = ds
  5008  	libc.Xmemcpy(tls, ds, ss, uint64(unsafe.Sizeof(Deflate_state{})))
  5009  	(*Deflate_state)(unsafe.Pointer(ds)).Fstrm = dest
  5010  
  5011  	(*Deflate_state)(unsafe.Pointer(ds)).Fwindow = (*struct {
  5012  		f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
  5013  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(dest)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(dest)).Fopaque, (*Deflate_state)(unsafe.Pointer(ds)).Fw_size, uint32(uint64(2)*uint64(unsafe.Sizeof(Byte(0)))))
  5014  	(*Deflate_state)(unsafe.Pointer(ds)).Fprev = (*struct {
  5015  		f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
  5016  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(dest)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(dest)).Fopaque, (*Deflate_state)(unsafe.Pointer(ds)).Fw_size, uint32(unsafe.Sizeof(Pos(0))))
  5017  	(*Deflate_state)(unsafe.Pointer(ds)).Fhead = (*struct {
  5018  		f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
  5019  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(dest)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(dest)).Fopaque, (*Deflate_state)(unsafe.Pointer(ds)).Fhash_size, uint32(unsafe.Sizeof(Pos(0))))
  5020  	overlay = (*struct {
  5021  		f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
  5022  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(dest)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(dest)).Fopaque, (*Deflate_state)(unsafe.Pointer(ds)).Flit_bufsize, uint32(uint64(unsafe.Sizeof(Ush(0)))+uint64(2)))
  5023  	(*Deflate_state)(unsafe.Pointer(ds)).Fpending_buf = overlay
  5024  
  5025  	if (*Deflate_state)(unsafe.Pointer(ds)).Fwindow == uintptr(Z_NULL) || (*Deflate_state)(unsafe.Pointer(ds)).Fprev == uintptr(Z_NULL) || (*Deflate_state)(unsafe.Pointer(ds)).Fhead == uintptr(Z_NULL) || (*Deflate_state)(unsafe.Pointer(ds)).Fpending_buf == uintptr(Z_NULL) {
  5026  		XdeflateEnd(tls, dest)
  5027  		return -4
  5028  	}
  5029  	// following zmemcpy do not work for 16-bit MSDOS
  5030  	libc.Xmemcpy(tls, (*Deflate_state)(unsafe.Pointer(ds)).Fwindow, (*Deflate_state)(unsafe.Pointer(ss)).Fwindow, uint64((*Deflate_state)(unsafe.Pointer(ds)).Fw_size*UInt(2))*uint64(unsafe.Sizeof(Byte(0))))
  5031  	libc.Xmemcpy(tls, (*Deflate_state)(unsafe.Pointer(ds)).Fprev, (*Deflate_state)(unsafe.Pointer(ss)).Fprev, uint64((*Deflate_state)(unsafe.Pointer(ds)).Fw_size)*uint64(unsafe.Sizeof(Pos(0))))
  5032  	libc.Xmemcpy(tls, (*Deflate_state)(unsafe.Pointer(ds)).Fhead, (*Deflate_state)(unsafe.Pointer(ss)).Fhead, uint64((*Deflate_state)(unsafe.Pointer(ds)).Fhash_size)*uint64(unsafe.Sizeof(Pos(0))))
  5033  	libc.Xmemcpy(tls, (*Deflate_state)(unsafe.Pointer(ds)).Fpending_buf, (*Deflate_state)(unsafe.Pointer(ss)).Fpending_buf, uint64(UInt((*Deflate_state)(unsafe.Pointer(ds)).Fpending_buf_size)))
  5034  
  5035  	(*Deflate_state)(unsafe.Pointer(ds)).Fpending_out = (*Deflate_state)(unsafe.Pointer(ds)).Fpending_buf + uintptr((int64((*Deflate_state)(unsafe.Pointer(ss)).Fpending_out)-int64((*Deflate_state)(unsafe.Pointer(ss)).Fpending_buf))/1)
  5036  	(*Deflate_state)(unsafe.Pointer(ds)).Fd_buf = overlay + uintptr(uint64((*Deflate_state)(unsafe.Pointer(ds)).Flit_bufsize)/uint64(unsafe.Sizeof(Ush(0))))*2
  5037  	(*Deflate_state)(unsafe.Pointer(ds)).Fl_buf = (*Deflate_state)(unsafe.Pointer(ds)).Fpending_buf + uintptr((uint64(1)+uint64(unsafe.Sizeof(Ush(0))))*uint64((*Deflate_state)(unsafe.Pointer(ds)).Flit_bufsize))
  5038  
  5039  	(*Deflate_state)(unsafe.Pointer(ds)).Fl_desc.Fdyn_tree = ds + 212   /* &.dyn_ltree */
  5040  	(*Deflate_state)(unsafe.Pointer(ds)).Fd_desc.Fdyn_tree = ds + 2504  /* &.dyn_dtree */
  5041  	(*Deflate_state)(unsafe.Pointer(ds)).Fbl_desc.Fdyn_tree = ds + 2748 /* &.bl_tree */
  5042  
  5043  	return Z_OK
  5044  }
  5045  
  5046  // ===========================================================================
  5047  // Read a new buffer from the current input stream, update the adler32
  5048  // and total number of bytes read.  All deflate() input goes through
  5049  // this function so some applications may wish to modify it to avoid
  5050  // allocating a large strm->next_in buffer and copying from it.
  5051  // (See also flush_pending()).
  5052  func read_buf(tls *libc.TLS, strm Z_streamp, buf uintptr, size uint32) uint32 { /* deflate.c:1164:16: */
  5053  	var len uint32 = (*Z_stream)(unsafe.Pointer(strm)).Favail_in
  5054  
  5055  	if len > size {
  5056  		len = size
  5057  	}
  5058  	if len == uint32(0) {
  5059  		return uint32(0)
  5060  	}
  5061  
  5062  	*(*UInt)(unsafe.Pointer(strm + 8)) -= len
  5063  
  5064  	libc.Xmemcpy(tls, buf, (*Z_stream)(unsafe.Pointer(strm)).Fnext_in, uint64(len))
  5065  	if (*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fwrap == 1 {
  5066  		(*Z_stream)(unsafe.Pointer(strm)).Fadler = Xadler32(tls, (*Z_stream)(unsafe.Pointer(strm)).Fadler, buf, len)
  5067  	} else if (*Internal_state)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fstate)).Fwrap == 2 {
  5068  		(*Z_stream)(unsafe.Pointer(strm)).Fadler = Xcrc32(tls, (*Z_stream)(unsafe.Pointer(strm)).Fadler, buf, len)
  5069  	}
  5070  	*(*uintptr)(unsafe.Pointer(strm)) += uintptr(len)
  5071  	*(*ULong)(unsafe.Pointer(strm + 16)) += ULong(len)
  5072  
  5073  	return len
  5074  }
  5075  
  5076  // ===========================================================================
  5077  // Initialize the "longest match" routines for a new zlib stream
  5078  func lm_init(tls *libc.TLS, s uintptr) { /* deflate.c:1194:12: */
  5079  	(*Deflate_state)(unsafe.Pointer(s)).Fwindow_size = uint64(2) * Ulg((*Deflate_state)(unsafe.Pointer(s)).Fw_size)
  5080  
  5081  	*(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fhash_size-UInt(1))*2)) = Posf(NIL)
  5082  	libc.Xmemset(tls, (*Deflate_state)(unsafe.Pointer(s)).Fhead, 0, uint64((*Deflate_state)(unsafe.Pointer(s)).Fhash_size-UInt(1))*uint64(unsafe.Sizeof(Posf(0))))
  5083  
  5084  	// Set the default configuration parameters:
  5085  	(*Deflate_state)(unsafe.Pointer(s)).Fmax_lazy_match = UInt(configuration_table[(*Deflate_state)(unsafe.Pointer(s)).Flevel].Fmax_lazy)
  5086  	(*Deflate_state)(unsafe.Pointer(s)).Fgood_match = UInt(configuration_table[(*Deflate_state)(unsafe.Pointer(s)).Flevel].Fgood_length)
  5087  	(*Deflate_state)(unsafe.Pointer(s)).Fnice_match = int32(configuration_table[(*Deflate_state)(unsafe.Pointer(s)).Flevel].Fnice_length)
  5088  	(*Deflate_state)(unsafe.Pointer(s)).Fmax_chain_length = UInt(configuration_table[(*Deflate_state)(unsafe.Pointer(s)).Flevel].Fmax_chain)
  5089  
  5090  	(*Deflate_state)(unsafe.Pointer(s)).Fstrstart = UInt(0)
  5091  	(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = 0
  5092  	(*Deflate_state)(unsafe.Pointer(s)).Flookahead = UInt(0)
  5093  	(*Deflate_state)(unsafe.Pointer(s)).Finsert = UInt(0)
  5094  	(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length = libc.AssignPtrUint32(s+184, UInt(MIN_MATCH-1))
  5095  	(*Deflate_state)(unsafe.Pointer(s)).Fmatch_available = 0
  5096  	(*Deflate_state)(unsafe.Pointer(s)).Fins_h = UInt(0)
  5097  }
  5098  
  5099  // ===========================================================================
  5100  // Set match_start to the longest match starting at the given string and
  5101  // return its length. Matches shorter or equal to prev_length are discarded,
  5102  // in which case the result is equal to prev_length and match_start is
  5103  // garbage.
  5104  // IN assertions: cur_match is the head of the hash chain for the current
  5105  //   string (strstart) and its distance is <= MAX_DIST, and prev_length >= 1
  5106  // OUT assertion: the match length is not greater than s->lookahead.
  5107  // For 80x86 and 680x0, an optimized version will be provided in match.asm or
  5108  // match.S. The code will be functionally equivalent.
  5109  func longest_match(tls *libc.TLS, s uintptr, cur_match IPos) UInt { /* deflate.c:1236:12: */
  5110  	var chain_length uint32 = (*Deflate_state)(unsafe.Pointer(s)).Fmax_chain_length                                         // max hash chain length
  5111  	var scan uintptr = (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart) // current string
  5112  	var match uintptr                                                                                                       // matched string
  5113  	var len int32                                                                                                           // length of current match
  5114  	var best_len int32 = int32((*Deflate_state)(unsafe.Pointer(s)).Fprev_length)                                            // best match length so far
  5115  	var nice_match int32 = (*Deflate_state)(unsafe.Pointer(s)).Fnice_match                                                  // stop if match long enough
  5116  	var limit IPos
  5117  	if (*Deflate_state)(unsafe.Pointer(s)).Fstrstart > (*Deflate_state)(unsafe.Pointer(s)).Fw_size-UInt(MAX_MATCH+MIN_MATCH+1) {
  5118  		limit = (*Deflate_state)(unsafe.Pointer(s)).Fstrstart - ((*Deflate_state)(unsafe.Pointer(s)).Fw_size - UInt(MAX_MATCH+MIN_MATCH+1))
  5119  	} else {
  5120  		limit = uint32(NIL)
  5121  	}
  5122  	// Stop when cur_match becomes <= limit. To simplify the code,
  5123  	// we prevent matches with the string of window index 0.
  5124  	var prev uintptr = (*Deflate_state)(unsafe.Pointer(s)).Fprev
  5125  	var wmask UInt = (*Deflate_state)(unsafe.Pointer(s)).Fw_mask
  5126  
  5127  	var strend uintptr = (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart) + uintptr(MAX_MATCH)
  5128  	var scan_end1 Byte = *(*Bytef)(unsafe.Pointer(scan + uintptr(best_len-1)))
  5129  	var scan_end Byte = *(*Bytef)(unsafe.Pointer(scan + uintptr(best_len)))
  5130  
  5131  	// The code is optimized for HASH_BITS >= 8 and MAX_MATCH-2 multiple of 16.
  5132  	// It is easy to get rid of this optimization if necessary.
  5133  
  5134  	// Do not waste too much time if we already have a good match:
  5135  	if (*Deflate_state)(unsafe.Pointer(s)).Fprev_length >= (*Deflate_state)(unsafe.Pointer(s)).Fgood_match {
  5136  		chain_length >>= 2
  5137  	}
  5138  	// Do not look for matches beyond the end of the input. This is necessary
  5139  	// to make deflate deterministic.
  5140  	if UInt(nice_match) > (*Deflate_state)(unsafe.Pointer(s)).Flookahead {
  5141  		nice_match = int32((*Deflate_state)(unsafe.Pointer(s)).Flookahead)
  5142  	}
  5143  
  5144  	for ok := true; ok; ok = libc.AssignUint32(&cur_match, IPos(*(*Posf)(unsafe.Pointer(prev + uintptr(cur_match&wmask)*2)))) > limit &&
  5145  		libc.PreDecUint32(&chain_length, 1) != uint32(0) {
  5146  
  5147  		match = (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(cur_match)
  5148  
  5149  		// Skip to next match if the match length cannot increase
  5150  		// or if the match length is less than 2.  Note that the checks below
  5151  		// for insufficient lookahead only occur occasionally for performance
  5152  		// reasons.  Therefore uninitialized memory will be accessed, and
  5153  		// conditional jumps will be made that depend on those values.
  5154  		// However the length of the match is limited to the lookahead, so
  5155  		// the output of deflate is not affected by the uninitialized values.
  5156  
  5157  		if int32(*(*Bytef)(unsafe.Pointer(match + uintptr(best_len)))) != int32(scan_end) || int32(*(*Bytef)(unsafe.Pointer(match + uintptr(best_len-1)))) != int32(scan_end1) || int32(*(*Bytef)(unsafe.Pointer(match))) != int32(*(*Bytef)(unsafe.Pointer(scan))) || int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&match, 1)))) != int32(*(*Bytef)(unsafe.Pointer(scan + 1))) {
  5158  			continue
  5159  		}
  5160  
  5161  		// The check at best_len-1 can be removed because it will be made
  5162  		// again later. (This heuristic is not always a win.)
  5163  		// It is not necessary to compare scan[2] and match[2] since they
  5164  		// are always equal when the other bytes match, given that
  5165  		// the hash keys are equal and that HASH_BITS >= 8.
  5166  		scan += uintptr(2)
  5167  		match++
  5168  
  5169  		// We check for insufficient lookahead only every 8th comparison;
  5170  		// the 256th check will be made at strstart+258.
  5171  		for ok1 := true; ok1; ok1 = int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) == int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&match, 1)))) && int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) == int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&match, 1)))) && int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) == int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&match, 1)))) && int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) == int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&match, 1)))) && int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) == int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&match, 1)))) && int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) == int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&match, 1)))) && int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) == int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&match, 1)))) && int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) == int32(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&match, 1)))) && scan < strend {
  5172  		}
  5173  
  5174  		len = MAX_MATCH - int32((int64(strend)-int64(scan))/1)
  5175  		scan = strend - uintptr(MAX_MATCH)
  5176  
  5177  		if len > best_len {
  5178  			(*Deflate_state)(unsafe.Pointer(s)).Fmatch_start = cur_match
  5179  			best_len = len
  5180  			if len >= nice_match {
  5181  				break
  5182  			}
  5183  			scan_end1 = *(*Bytef)(unsafe.Pointer(scan + uintptr(best_len-1)))
  5184  			scan_end = *(*Bytef)(unsafe.Pointer(scan + uintptr(best_len)))
  5185  		}
  5186  	}
  5187  
  5188  	if UInt(best_len) <= (*Deflate_state)(unsafe.Pointer(s)).Flookahead {
  5189  		return UInt(best_len)
  5190  	}
  5191  	return (*Deflate_state)(unsafe.Pointer(s)).Flookahead
  5192  }
  5193  
  5194  // ===========================================================================
  5195  // Fill the window when the lookahead becomes insufficient.
  5196  // Updates strstart and lookahead.
  5197  //
  5198  // IN assertion: lookahead < MIN_LOOKAHEAD
  5199  // OUT assertions: strstart <= window_size-MIN_LOOKAHEAD
  5200  //    At least one byte has been read, or avail_in == 0; reads are
  5201  //    performed for at least two bytes (required for the zip translate_eol
  5202  //    option -- not supported here).
  5203  func fill_window(tls *libc.TLS, s uintptr) { /* deflate.c:1482:12: */
  5204  	var n uint32
  5205  	var more uint32 // Amount of free space at the end of the window.
  5206  	var wsize UInt = (*Deflate_state)(unsafe.Pointer(s)).Fw_size
  5207  
  5208  	for ok := true; ok; ok = (*Deflate_state)(unsafe.Pointer(s)).Flookahead < UInt(MAX_MATCH+MIN_MATCH+1) && (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_in != UInt(0) {
  5209  		more = uint32((*Deflate_state)(unsafe.Pointer(s)).Fwindow_size - Ulg((*Deflate_state)(unsafe.Pointer(s)).Flookahead) - Ulg((*Deflate_state)(unsafe.Pointer(s)).Fstrstart))
  5210  
  5211  		// Deal with !@#$% 64K limit:
  5212  		if uint64(unsafe.Sizeof(int32(0))) <= uint64(2) {
  5213  			if more == uint32(0) && (*Deflate_state)(unsafe.Pointer(s)).Fstrstart == UInt(0) && (*Deflate_state)(unsafe.Pointer(s)).Flookahead == UInt(0) {
  5214  				more = wsize
  5215  
  5216  			} else if more == libc.Uint32(libc.Uint32FromInt32(-1)) {
  5217  				// Very unlikely, but possible on 16 bit machine if
  5218  				// strstart == 0 && lookahead == 1 (input done a byte at time)
  5219  				more--
  5220  			}
  5221  		}
  5222  
  5223  		// If the window is almost full and there is insufficient lookahead,
  5224  		// move the upper half to the lower one to make room in the upper half.
  5225  		if (*Deflate_state)(unsafe.Pointer(s)).Fstrstart >= wsize+((*Deflate_state)(unsafe.Pointer(s)).Fw_size-UInt(MAX_MATCH+MIN_MATCH+1)) {
  5226  
  5227  			libc.Xmemcpy(tls, (*Deflate_state)(unsafe.Pointer(s)).Fwindow, (*Deflate_state)(unsafe.Pointer(s)).Fwindow+uintptr(wsize), uint64(wsize-more))
  5228  			*(*UInt)(unsafe.Pointer(s + 176)) -= wsize
  5229  			*(*UInt)(unsafe.Pointer(s + 172)) -= wsize // we now have strstart >= MAX_DIST
  5230  			*(*int64)(unsafe.Pointer(s + 152)) -= int64(wsize)
  5231  			slide_hash(tls, s)
  5232  			more = more + wsize
  5233  		}
  5234  		if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_in == UInt(0) {
  5235  			break
  5236  		}
  5237  
  5238  		// If there was no sliding:
  5239  		//    strstart <= WSIZE+MAX_DIST-1 && lookahead <= MIN_LOOKAHEAD - 1 &&
  5240  		//    more == window_size - lookahead - strstart
  5241  		// => more >= window_size - (MIN_LOOKAHEAD-1 + WSIZE + MAX_DIST-1)
  5242  		// => more >= window_size - 2*WSIZE + 2
  5243  		// In the BIG_MEM or MMAP case (not yet supported),
  5244  		//   window_size == input_size + MIN_LOOKAHEAD  &&
  5245  		//   strstart + s->lookahead <= input_size => more >= MIN_LOOKAHEAD.
  5246  		// Otherwise, window_size == 2*WSIZE so more >= 2.
  5247  		// If there was sliding, more >= WSIZE. So in all cases, more >= 2.
  5248  
  5249  		n = read_buf(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm, (*Deflate_state)(unsafe.Pointer(s)).Fwindow+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)+uintptr((*Deflate_state)(unsafe.Pointer(s)).Flookahead), more)
  5250  		*(*UInt)(unsafe.Pointer(s + 180)) += n
  5251  
  5252  		// Initialize the hash value now that we have some input:
  5253  		if (*Deflate_state)(unsafe.Pointer(s)).Flookahead+(*Deflate_state)(unsafe.Pointer(s)).Finsert >= UInt(MIN_MATCH) {
  5254  			var str UInt = (*Deflate_state)(unsafe.Pointer(s)).Fstrstart - (*Deflate_state)(unsafe.Pointer(s)).Finsert
  5255  			(*Deflate_state)(unsafe.Pointer(s)).Fins_h = UInt(*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(str))))
  5256  			(*Deflate_state)(unsafe.Pointer(s)).Fins_h = ((*Deflate_state)(unsafe.Pointer(s)).Fins_h<<(*Deflate_state)(unsafe.Pointer(s)).Fhash_shift ^ UInt(*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(str+UInt(1)))))) & (*Deflate_state)(unsafe.Pointer(s)).Fhash_mask
  5257  			for (*Deflate_state)(unsafe.Pointer(s)).Finsert != 0 {
  5258  				(*Deflate_state)(unsafe.Pointer(s)).Fins_h = ((*Deflate_state)(unsafe.Pointer(s)).Fins_h<<(*Deflate_state)(unsafe.Pointer(s)).Fhash_shift ^ UInt(*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(str+UInt(MIN_MATCH)-UInt(1)))))) & (*Deflate_state)(unsafe.Pointer(s)).Fhash_mask
  5259  				*(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fprev + uintptr(str&(*Deflate_state)(unsafe.Pointer(s)).Fw_mask)*2)) = *(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fins_h)*2))
  5260  				*(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fins_h)*2)) = Pos(str)
  5261  				str++
  5262  				(*Deflate_state)(unsafe.Pointer(s)).Finsert--
  5263  				if (*Deflate_state)(unsafe.Pointer(s)).Flookahead+(*Deflate_state)(unsafe.Pointer(s)).Finsert < UInt(MIN_MATCH) {
  5264  					break
  5265  				}
  5266  			}
  5267  		}
  5268  		// If the whole input has less than MIN_MATCH bytes, ins_h is garbage,
  5269  		// but this is not important since only literal bytes will be emitted.
  5270  
  5271  	}
  5272  
  5273  	// If the WIN_INIT bytes after the end of the current data have never been
  5274  	// written, then zero those bytes in order to avoid memory check reports of
  5275  	// the use of uninitialized (or uninitialised as Julian writes) bytes by
  5276  	// the longest match routines.  Update the high water mark for the next
  5277  	// time through here.  WIN_INIT is set to MAX_MATCH since the longest match
  5278  	// routines allow scanning to strstart + MAX_MATCH, ignoring lookahead.
  5279  	if (*Deflate_state)(unsafe.Pointer(s)).Fhigh_water < (*Deflate_state)(unsafe.Pointer(s)).Fwindow_size {
  5280  		var curr Ulg = Ulg((*Deflate_state)(unsafe.Pointer(s)).Fstrstart) + Ulg((*Deflate_state)(unsafe.Pointer(s)).Flookahead)
  5281  		var init1 Ulg
  5282  
  5283  		if (*Deflate_state)(unsafe.Pointer(s)).Fhigh_water < curr {
  5284  			// Previous high water mark below current data -- zero WIN_INIT
  5285  			// bytes or up to end of window, whichever is less.
  5286  			init1 = (*Deflate_state)(unsafe.Pointer(s)).Fwindow_size - curr
  5287  			if init1 > uint64(MAX_MATCH) {
  5288  				init1 = uint64(MAX_MATCH)
  5289  			}
  5290  			libc.Xmemset(tls, (*Deflate_state)(unsafe.Pointer(s)).Fwindow+uintptr(curr), 0, uint64(uint32(init1)))
  5291  			(*Deflate_state)(unsafe.Pointer(s)).Fhigh_water = curr + init1
  5292  		} else if (*Deflate_state)(unsafe.Pointer(s)).Fhigh_water < curr+uint64(MAX_MATCH) {
  5293  			// High water mark at or above current data, but below current data
  5294  			// plus WIN_INIT -- zero out to current data plus WIN_INIT, or up
  5295  			// to end of window, whichever is less.
  5296  			init1 = curr + uint64(MAX_MATCH) - (*Deflate_state)(unsafe.Pointer(s)).Fhigh_water
  5297  			if init1 > (*Deflate_state)(unsafe.Pointer(s)).Fwindow_size-(*Deflate_state)(unsafe.Pointer(s)).Fhigh_water {
  5298  				init1 = (*Deflate_state)(unsafe.Pointer(s)).Fwindow_size - (*Deflate_state)(unsafe.Pointer(s)).Fhigh_water
  5299  			}
  5300  			libc.Xmemset(tls, (*Deflate_state)(unsafe.Pointer(s)).Fwindow+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fhigh_water), 0, uint64(uint32(init1)))
  5301  			*(*Ulg)(unsafe.Pointer(s + 5944)) += init1
  5302  		}
  5303  	}
  5304  
  5305  }
  5306  
  5307  // ===========================================================================
  5308  // Flush the current block, with given end-of-file flag.
  5309  // IN assertion: strstart is set to the end of the current match.
  5310  
  5311  // Same but force premature exit if necessary.
  5312  
  5313  // Maximum stored block length in deflate format (not including header).
  5314  
  5315  // Minimum of a and b.
  5316  
  5317  // ===========================================================================
  5318  // Copy without compression as much as possible from the input stream, return
  5319  // the current block state.
  5320  //
  5321  // In case deflateParams() is used to later switch to a non-zero compression
  5322  // level, s->matches (otherwise unused when storing) keeps track of the number
  5323  // of hash table slides to perform. If s->matches is 1, then one hash table
  5324  // slide will be done when switching. If s->matches is 2, the maximum value
  5325  // allowed here, then the hash table will be cleared, since two or more slides
  5326  // is the same as a clear.
  5327  //
  5328  // deflate_stored() is written to minimize the number of times an input byte is
  5329  // copied. It is most efficient with large input and output buffers, which
  5330  // maximizes the opportunites to have a single copy from next_in to next_out.
  5331  func deflate_stored(tls *libc.TLS, s uintptr, flush int32) Block_state { /* deflate.c:1643:19: */
  5332  	// Smallest worthy block size when not flushing or finishing. By default
  5333  	// this is 32K. This can be as small as 507 bytes for memLevel == 1. For
  5334  	// large input and output buffers, the stored block size will be larger.
  5335  	var min_block uint32 = func() uint32 {
  5336  		if (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf_size-uint64(5) > Ulg((*Deflate_state)(unsafe.Pointer(s)).Fw_size) {
  5337  			return (*Deflate_state)(unsafe.Pointer(s)).Fw_size
  5338  		}
  5339  		return uint32((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf_size - uint64(5))
  5340  	}()
  5341  
  5342  	// Copy as many min_block or larger stored blocks directly to next_out as
  5343  	// possible. If flushing, copy the remaining available input to next_out as
  5344  	// stored blocks, if there is enough space.
  5345  	var len uint32
  5346  	var left uint32
  5347  	var have uint32
  5348  	var last uint32 = uint32(0)
  5349  	var used uint32 = (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_in
  5350  	for ok := true; ok; ok = last == uint32(0) {
  5351  		// Set len to the maximum size block that we can copy directly with the
  5352  		// available input data and output space. Set left to how much of that
  5353  		// would be copied from what's left in the window.
  5354  		len = uint32(MAX_STORED)                                                                      // maximum deflate stored block length
  5355  		have = uint32(((*Deflate_state)(unsafe.Pointer(s)).Fbi_valid + 42) >> 3)                      // number of header bytes
  5356  		if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out < have { // need room for header
  5357  			break
  5358  		}
  5359  		// maximum stored block length that will fit in avail_out:
  5360  		have = (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out - have
  5361  		left = uint32(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart) - (*Deflate_state)(unsafe.Pointer(s)).Fblock_start) // bytes left in window
  5362  		if Ulg(len) > Ulg(left)+Ulg((*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_in) {
  5363  			len = left + (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_in
  5364  		} // limit len to the input
  5365  		if len > have {
  5366  			len = have
  5367  		} // limit len to the output
  5368  
  5369  		// If the stored block would be less than min_block in length, or if
  5370  		// unable to copy all of the available input when flushing, then try
  5371  		// copying to the window and the pending buffer instead. Also don't
  5372  		// write an empty block when flushing -- deflate() does that.
  5373  		if len < min_block && (len == uint32(0) && flush != Z_FINISH || flush == Z_NO_FLUSH || len != left+(*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_in) {
  5374  			break
  5375  		}
  5376  
  5377  		// Make a dummy stored block in pending to get the header bytes,
  5378  		// including any pending bits. This also updates the debugging counts.
  5379  		if flush == Z_FINISH && len == left+(*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_in {
  5380  			last = uint32(1)
  5381  		} else {
  5382  			last = uint32(0)
  5383  		}
  5384  		X_tr_stored_block(tls, s, uintptr(0), uint64(0), int32(last))
  5385  
  5386  		// Replace the lengths in the dummy stored block with len.
  5387  		*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fpending-uint64(4)))) = Bytef(len)
  5388  		*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fpending-uint64(3)))) = Bytef(len >> 8)
  5389  		*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fpending-uint64(2)))) = Bytef(^len)
  5390  		*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fpending-uint64(1)))) = Bytef(^len >> 8)
  5391  
  5392  		// Write the stored block header bytes.
  5393  		flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  5394  
  5395  		// Copy uncompressed bytes from the window to next_out.
  5396  		if left != 0 {
  5397  			if left > len {
  5398  				left = len
  5399  			}
  5400  			libc.Xmemcpy(tls, (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Fnext_out, (*Deflate_state)(unsafe.Pointer(s)).Fwindow+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fblock_start), uint64(left))
  5401  			*(*uintptr)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm + 24)) += uintptr(left)
  5402  			*(*UInt)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm + 32)) -= left
  5403  			*(*ULong)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm + 40)) += ULong(left)
  5404  			*(*int64)(unsafe.Pointer(s + 152)) += int64(left)
  5405  			len = len - left
  5406  		}
  5407  
  5408  		// Copy uncompressed bytes directly from next_in to next_out, updating
  5409  		// the check value.
  5410  		if len != 0 {
  5411  			read_buf(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm, (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Fnext_out, len)
  5412  			*(*uintptr)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm + 24)) += uintptr(len)
  5413  			*(*UInt)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm + 32)) -= len
  5414  			*(*ULong)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm + 40)) += ULong(len)
  5415  		}
  5416  	}
  5417  
  5418  	// Update the sliding window with the last s->w_size bytes of the copied
  5419  	// data, or append all of the copied data to the existing window if less
  5420  	// than s->w_size bytes were copied. Also update the number of bytes to
  5421  	// insert in the hash tables, in the event that deflateParams() switches to
  5422  	// a non-zero compression level.
  5423  	used = used - (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_in // number of input bytes directly copied
  5424  	if used != 0 {
  5425  		// If any input was used, then no unused input remains in the window,
  5426  		// therefore s->block_start == s->strstart.
  5427  		if used >= (*Deflate_state)(unsafe.Pointer(s)).Fw_size { // supplant the previous history
  5428  			(*Deflate_state)(unsafe.Pointer(s)).Fmatches = UInt(2) // clear hash
  5429  			libc.Xmemcpy(tls, (*Deflate_state)(unsafe.Pointer(s)).Fwindow, (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Fnext_in-uintptr((*Deflate_state)(unsafe.Pointer(s)).Fw_size), uint64((*Deflate_state)(unsafe.Pointer(s)).Fw_size))
  5430  			(*Deflate_state)(unsafe.Pointer(s)).Fstrstart = (*Deflate_state)(unsafe.Pointer(s)).Fw_size
  5431  		} else {
  5432  			if (*Deflate_state)(unsafe.Pointer(s)).Fwindow_size-Ulg((*Deflate_state)(unsafe.Pointer(s)).Fstrstart) <= Ulg(used) {
  5433  				// Slide the window down.
  5434  				*(*UInt)(unsafe.Pointer(s + 172)) -= (*Deflate_state)(unsafe.Pointer(s)).Fw_size
  5435  				libc.Xmemcpy(tls, (*Deflate_state)(unsafe.Pointer(s)).Fwindow, (*Deflate_state)(unsafe.Pointer(s)).Fwindow+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fw_size), uint64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart))
  5436  				if (*Deflate_state)(unsafe.Pointer(s)).Fmatches < UInt(2) {
  5437  					(*Deflate_state)(unsafe.Pointer(s)).Fmatches++
  5438  				} // add a pending slide_hash()
  5439  			}
  5440  			libc.Xmemcpy(tls, (*Deflate_state)(unsafe.Pointer(s)).Fwindow+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart), (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Fnext_in-uintptr(used), uint64(used))
  5441  			*(*UInt)(unsafe.Pointer(s + 172)) += used
  5442  		}
  5443  		(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5444  		*(*UInt)(unsafe.Pointer(s + 5932)) += func() uint32 {
  5445  			if used > (*Deflate_state)(unsafe.Pointer(s)).Fw_size-(*Deflate_state)(unsafe.Pointer(s)).Finsert {
  5446  				return (*Deflate_state)(unsafe.Pointer(s)).Fw_size - (*Deflate_state)(unsafe.Pointer(s)).Finsert
  5447  			}
  5448  			return used
  5449  		}()
  5450  	}
  5451  	if (*Deflate_state)(unsafe.Pointer(s)).Fhigh_water < Ulg((*Deflate_state)(unsafe.Pointer(s)).Fstrstart) {
  5452  		(*Deflate_state)(unsafe.Pointer(s)).Fhigh_water = Ulg((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5453  	}
  5454  
  5455  	// If the last block was written to next_out, then done.
  5456  	if last != 0 {
  5457  		return Finish_done
  5458  	}
  5459  
  5460  	// If flushing and all input has been consumed, then done.
  5461  	if flush != Z_NO_FLUSH && flush != Z_FINISH && (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_in == UInt(0) && int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart) == (*Deflate_state)(unsafe.Pointer(s)).Fblock_start {
  5462  		return Block_done
  5463  	}
  5464  
  5465  	// Fill the window with any remaining input.
  5466  	have = uint32((*Deflate_state)(unsafe.Pointer(s)).Fwindow_size - Ulg((*Deflate_state)(unsafe.Pointer(s)).Fstrstart) - uint64(1))
  5467  	if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_in > have && (*Deflate_state)(unsafe.Pointer(s)).Fblock_start >= int64((*Deflate_state)(unsafe.Pointer(s)).Fw_size) {
  5468  		// Slide the window down.
  5469  		*(*int64)(unsafe.Pointer(s + 152)) -= int64((*Deflate_state)(unsafe.Pointer(s)).Fw_size)
  5470  		*(*UInt)(unsafe.Pointer(s + 172)) -= (*Deflate_state)(unsafe.Pointer(s)).Fw_size
  5471  		libc.Xmemcpy(tls, (*Deflate_state)(unsafe.Pointer(s)).Fwindow, (*Deflate_state)(unsafe.Pointer(s)).Fwindow+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fw_size), uint64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart))
  5472  		if (*Deflate_state)(unsafe.Pointer(s)).Fmatches < UInt(2) {
  5473  			(*Deflate_state)(unsafe.Pointer(s)).Fmatches++
  5474  		} // add a pending slide_hash()
  5475  		have = have + (*Deflate_state)(unsafe.Pointer(s)).Fw_size // more space now
  5476  	}
  5477  	if have > (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_in {
  5478  		have = (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_in
  5479  	}
  5480  	if have != 0 {
  5481  		read_buf(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm, (*Deflate_state)(unsafe.Pointer(s)).Fwindow+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart), have)
  5482  		*(*UInt)(unsafe.Pointer(s + 172)) += have
  5483  	}
  5484  	if (*Deflate_state)(unsafe.Pointer(s)).Fhigh_water < Ulg((*Deflate_state)(unsafe.Pointer(s)).Fstrstart) {
  5485  		(*Deflate_state)(unsafe.Pointer(s)).Fhigh_water = Ulg((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5486  	}
  5487  
  5488  	// There was not enough avail_out to write a complete worthy or flushed
  5489  	// stored block to next_out. Write a stored block to pending instead, if we
  5490  	// have enough input for a worthy block, or if flushing and there is enough
  5491  	// room for the remaining input as a stored block in the pending buffer.
  5492  	have = uint32(((*Deflate_state)(unsafe.Pointer(s)).Fbi_valid + 42) >> 3) // number of header bytes
  5493  	// maximum stored block length that will fit in pending:
  5494  	have = func() uint32 {
  5495  		if (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf_size-Ulg(have) > uint64(MAX_STORED) {
  5496  			return uint32(MAX_STORED)
  5497  		}
  5498  		return uint32((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf_size - Ulg(have))
  5499  	}()
  5500  	min_block = func() uint32 {
  5501  		if have > (*Deflate_state)(unsafe.Pointer(s)).Fw_size {
  5502  			return (*Deflate_state)(unsafe.Pointer(s)).Fw_size
  5503  		}
  5504  		return have
  5505  	}()
  5506  	left = uint32(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart) - (*Deflate_state)(unsafe.Pointer(s)).Fblock_start)
  5507  	if left >= min_block || (left != 0 || flush == Z_FINISH) && flush != Z_NO_FLUSH && (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_in == UInt(0) && left <= have {
  5508  		len = func() uint32 {
  5509  			if left > have {
  5510  				return have
  5511  			}
  5512  			return left
  5513  		}()
  5514  		if flush == Z_FINISH && (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_in == UInt(0) && len == left {
  5515  			last = uint32(1)
  5516  		} else {
  5517  			last = uint32(0)
  5518  		}
  5519  		X_tr_stored_block(tls, s, (*Deflate_state)(unsafe.Pointer(s)).Fwindow+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fblock_start), uint64(len), int32(last))
  5520  		*(*int64)(unsafe.Pointer(s + 152)) += int64(len)
  5521  		flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  5522  	}
  5523  
  5524  	// We've done all we can with the available input and output.
  5525  	if last != 0 {
  5526  		return Finish_started
  5527  	}
  5528  	return Need_more
  5529  }
  5530  
  5531  // ===========================================================================
  5532  // Compress as much as possible from the input stream, return the current
  5533  // block state.
  5534  // This function does not perform lazy evaluation of matches and inserts
  5535  // new strings in the dictionary only for unmatched strings or for short
  5536  // matches. It is used only for the fast compression options.
  5537  func deflate_fast(tls *libc.TLS, s uintptr, flush int32) Block_state { /* deflate.c:1824:19: */
  5538  	var hash_head IPos // head of the hash chain
  5539  	var bflush int32   // set if current block must be flushed
  5540  
  5541  	for {
  5542  		// Make sure that we always have enough lookahead, except
  5543  		// at the end of the input file. We need MAX_MATCH bytes
  5544  		// for the next match, plus MIN_MATCH bytes to insert the
  5545  		// string following the next match.
  5546  		if (*Deflate_state)(unsafe.Pointer(s)).Flookahead < UInt(MAX_MATCH+MIN_MATCH+1) {
  5547  			fill_window(tls, s)
  5548  			if (*Deflate_state)(unsafe.Pointer(s)).Flookahead < UInt(MAX_MATCH+MIN_MATCH+1) && flush == Z_NO_FLUSH {
  5549  				return Need_more
  5550  			}
  5551  			if (*Deflate_state)(unsafe.Pointer(s)).Flookahead == UInt(0) {
  5552  				break
  5553  			} // flush the current block
  5554  		}
  5555  
  5556  		// Insert the string window[strstart .. strstart+2] in the
  5557  		// dictionary, and set hash_head to the head of the hash chain:
  5558  		hash_head = IPos(NIL)
  5559  		if (*Deflate_state)(unsafe.Pointer(s)).Flookahead >= UInt(MIN_MATCH) {
  5560  			(*Deflate_state)(unsafe.Pointer(s)).Fins_h = ((*Deflate_state)(unsafe.Pointer(s)).Fins_h<<(*Deflate_state)(unsafe.Pointer(s)).Fhash_shift ^ UInt(*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart+UInt(MIN_MATCH-1)))))) & (*Deflate_state)(unsafe.Pointer(s)).Fhash_mask
  5561  			hash_head = IPos(libc.AssignPtrUint16((*Deflate_state)(unsafe.Pointer(s)).Fprev+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart&(*Deflate_state)(unsafe.Pointer(s)).Fw_mask)*2, *(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fins_h)*2))))
  5562  			*(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fins_h)*2)) = Pos((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5563  		}
  5564  
  5565  		// Find the longest match, discarding those <= prev_length.
  5566  		// At this point we have always match_length < MIN_MATCH
  5567  		if hash_head != IPos(NIL) && (*Deflate_state)(unsafe.Pointer(s)).Fstrstart-hash_head <= (*Deflate_state)(unsafe.Pointer(s)).Fw_size-UInt(MAX_MATCH+MIN_MATCH+1) {
  5568  			// To simplify the code, we prevent matches with the string
  5569  			// of window index 0 (in particular we have to avoid a match
  5570  			// of the string with itself at the start of the input file).
  5571  			(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length = longest_match(tls, s, hash_head)
  5572  			// longest_match() sets match_start
  5573  		}
  5574  		if (*Deflate_state)(unsafe.Pointer(s)).Fmatch_length >= UInt(MIN_MATCH) {
  5575  
  5576  			{
  5577  				var len Uch = Uch((*Deflate_state)(unsafe.Pointer(s)).Fmatch_length - UInt(MIN_MATCH))
  5578  				var dist Ush = Ush((*Deflate_state)(unsafe.Pointer(s)).Fstrstart - (*Deflate_state)(unsafe.Pointer(s)).Fmatch_start)
  5579  				*(*Ushf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fd_buf + uintptr((*Deflate_state)(unsafe.Pointer(s)).Flast_lit)*2)) = dist
  5580  				*(*Uchf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fl_buf + uintptr(libc.PostIncUint32(&(*Deflate_state)(unsafe.Pointer(s)).Flast_lit, 1)))) = len
  5581  				dist--
  5582  				*(*Ush)(unsafe.Pointer(s + 212 + uintptr(int32(X_length_code[len])+LITERALS+1)*4))++
  5583  				*(*Ush)(unsafe.Pointer(s + 2504 + uintptr(func() int32 {
  5584  					if int32(dist) < 256 {
  5585  						return int32(X_dist_code[dist])
  5586  					}
  5587  					return int32(X_dist_code[256+int32(dist)>>7])
  5588  				}())*4))++
  5589  				bflush = libc.Bool32((*Deflate_state)(unsafe.Pointer(s)).Flast_lit == (*Deflate_state)(unsafe.Pointer(s)).Flit_bufsize-UInt(1))
  5590  			}
  5591  
  5592  			*(*UInt)(unsafe.Pointer(s + 180)) -= (*Deflate_state)(unsafe.Pointer(s)).Fmatch_length
  5593  
  5594  			// Insert new strings in the hash table only if the match length
  5595  			// is not too large. This saves time but degrades compression.
  5596  			if (*Deflate_state)(unsafe.Pointer(s)).Fmatch_length <= (*Deflate_state)(unsafe.Pointer(s)).Fmax_lazy_match && (*Deflate_state)(unsafe.Pointer(s)).Flookahead >= UInt(MIN_MATCH) {
  5597  				(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length-- // string at strstart already in table
  5598  				for ok := true; ok; ok = libc.PreDecUint32(&(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length, 1) != UInt(0) {
  5599  					(*Deflate_state)(unsafe.Pointer(s)).Fstrstart++
  5600  					(*Deflate_state)(unsafe.Pointer(s)).Fins_h = ((*Deflate_state)(unsafe.Pointer(s)).Fins_h<<(*Deflate_state)(unsafe.Pointer(s)).Fhash_shift ^ UInt(*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart+UInt(MIN_MATCH-1)))))) & (*Deflate_state)(unsafe.Pointer(s)).Fhash_mask
  5601  					hash_head = IPos(libc.AssignPtrUint16((*Deflate_state)(unsafe.Pointer(s)).Fprev+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart&(*Deflate_state)(unsafe.Pointer(s)).Fw_mask)*2, *(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fins_h)*2))))
  5602  					*(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fins_h)*2)) = Pos((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5603  					// strstart never exceeds WSIZE-MAX_MATCH, so there are
  5604  					// always MIN_MATCH bytes ahead.
  5605  				}
  5606  				(*Deflate_state)(unsafe.Pointer(s)).Fstrstart++
  5607  			} else {
  5608  				*(*UInt)(unsafe.Pointer(s + 172)) += (*Deflate_state)(unsafe.Pointer(s)).Fmatch_length
  5609  				(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length = UInt(0)
  5610  				(*Deflate_state)(unsafe.Pointer(s)).Fins_h = UInt(*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart))))
  5611  				(*Deflate_state)(unsafe.Pointer(s)).Fins_h = ((*Deflate_state)(unsafe.Pointer(s)).Fins_h<<(*Deflate_state)(unsafe.Pointer(s)).Fhash_shift ^ UInt(*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart+UInt(1)))))) & (*Deflate_state)(unsafe.Pointer(s)).Fhash_mask
  5612  				// If lookahead < MIN_MATCH, ins_h is garbage, but it does not
  5613  				// matter since it will be recomputed at next deflate call.
  5614  			}
  5615  		} else {
  5616  			// No match, output a literal byte
  5617  
  5618  			{
  5619  				var cc Uch = *(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)))
  5620  				*(*Ushf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fd_buf + uintptr((*Deflate_state)(unsafe.Pointer(s)).Flast_lit)*2)) = Ushf(0)
  5621  				*(*Uchf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fl_buf + uintptr(libc.PostIncUint32(&(*Deflate_state)(unsafe.Pointer(s)).Flast_lit, 1)))) = cc
  5622  				*(*Ush)(unsafe.Pointer(s + 212 + uintptr(cc)*4))++
  5623  				bflush = libc.Bool32((*Deflate_state)(unsafe.Pointer(s)).Flast_lit == (*Deflate_state)(unsafe.Pointer(s)).Flit_bufsize-UInt(1))
  5624  			}
  5625  
  5626  			(*Deflate_state)(unsafe.Pointer(s)).Flookahead--
  5627  			(*Deflate_state)(unsafe.Pointer(s)).Fstrstart++
  5628  		}
  5629  		if bflush != 0 {
  5630  			{
  5631  				X_tr_flush_block(tls, s, func() uintptr {
  5632  					if (*Deflate_state)(unsafe.Pointer(s)).Fblock_start >= 0 {
  5633  						return (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(uint32((*Deflate_state)(unsafe.Pointer(s)).Fblock_start))
  5634  					}
  5635  					return uintptr(Z_NULL)
  5636  				}(), Ulg(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)-(*Deflate_state)(unsafe.Pointer(s)).Fblock_start), 0)
  5637  				(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5638  				flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  5639  			}
  5640  			if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out == UInt(0) {
  5641  				if 0 != 0 {
  5642  					return Finish_started
  5643  				}
  5644  				return Need_more
  5645  			}
  5646  		}
  5647  
  5648  	}
  5649  	(*Deflate_state)(unsafe.Pointer(s)).Finsert = func() uint32 {
  5650  		if (*Deflate_state)(unsafe.Pointer(s)).Fstrstart < UInt(MIN_MATCH-1) {
  5651  			return (*Deflate_state)(unsafe.Pointer(s)).Fstrstart
  5652  		}
  5653  		return uint32(MIN_MATCH - 1)
  5654  	}()
  5655  	if flush == Z_FINISH {
  5656  		{
  5657  			{
  5658  				X_tr_flush_block(tls, s, func() uintptr {
  5659  					if (*Deflate_state)(unsafe.Pointer(s)).Fblock_start >= 0 {
  5660  						return (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(uint32((*Deflate_state)(unsafe.Pointer(s)).Fblock_start))
  5661  					}
  5662  					return uintptr(Z_NULL)
  5663  				}(), Ulg(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)-(*Deflate_state)(unsafe.Pointer(s)).Fblock_start), 1)
  5664  				(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5665  				flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  5666  			}
  5667  			if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out == UInt(0) {
  5668  				if 1 != 0 {
  5669  					return Finish_started
  5670  				}
  5671  				return Need_more
  5672  			}
  5673  		}
  5674  
  5675  		return Finish_done
  5676  	}
  5677  	if (*Deflate_state)(unsafe.Pointer(s)).Flast_lit != 0 {
  5678  		{
  5679  			X_tr_flush_block(tls, s, func() uintptr {
  5680  				if (*Deflate_state)(unsafe.Pointer(s)).Fblock_start >= 0 {
  5681  					return (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(uint32((*Deflate_state)(unsafe.Pointer(s)).Fblock_start))
  5682  				}
  5683  				return uintptr(Z_NULL)
  5684  			}(), Ulg(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)-(*Deflate_state)(unsafe.Pointer(s)).Fblock_start), 0)
  5685  			(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5686  			flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  5687  		}
  5688  		if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out == UInt(0) {
  5689  			if 0 != 0 {
  5690  				return Finish_started
  5691  			}
  5692  			return Need_more
  5693  		}
  5694  	}
  5695  
  5696  	return Block_done
  5697  }
  5698  
  5699  // ===========================================================================
  5700  // Same as above, but achieves better compression. We use a lazy
  5701  // evaluation for matches: a match is finally adopted only if there is
  5702  // no better match at the next window position.
  5703  func deflate_slow(tls *libc.TLS, s uintptr, flush int32) Block_state { /* deflate.c:1926:19: */
  5704  	var hash_head IPos // head of hash chain
  5705  	var bflush int32   // set if current block must be flushed
  5706  
  5707  	// Process the input block.
  5708  	for {
  5709  		// Make sure that we always have enough lookahead, except
  5710  		// at the end of the input file. We need MAX_MATCH bytes
  5711  		// for the next match, plus MIN_MATCH bytes to insert the
  5712  		// string following the next match.
  5713  		if (*Deflate_state)(unsafe.Pointer(s)).Flookahead < UInt(MAX_MATCH+MIN_MATCH+1) {
  5714  			fill_window(tls, s)
  5715  			if (*Deflate_state)(unsafe.Pointer(s)).Flookahead < UInt(MAX_MATCH+MIN_MATCH+1) && flush == Z_NO_FLUSH {
  5716  				return Need_more
  5717  			}
  5718  			if (*Deflate_state)(unsafe.Pointer(s)).Flookahead == UInt(0) {
  5719  				break
  5720  			} // flush the current block
  5721  		}
  5722  
  5723  		// Insert the string window[strstart .. strstart+2] in the
  5724  		// dictionary, and set hash_head to the head of the hash chain:
  5725  		hash_head = IPos(NIL)
  5726  		if (*Deflate_state)(unsafe.Pointer(s)).Flookahead >= UInt(MIN_MATCH) {
  5727  			(*Deflate_state)(unsafe.Pointer(s)).Fins_h = ((*Deflate_state)(unsafe.Pointer(s)).Fins_h<<(*Deflate_state)(unsafe.Pointer(s)).Fhash_shift ^ UInt(*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart+UInt(MIN_MATCH-1)))))) & (*Deflate_state)(unsafe.Pointer(s)).Fhash_mask
  5728  			hash_head = IPos(libc.AssignPtrUint16((*Deflate_state)(unsafe.Pointer(s)).Fprev+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart&(*Deflate_state)(unsafe.Pointer(s)).Fw_mask)*2, *(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fins_h)*2))))
  5729  			*(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fins_h)*2)) = Pos((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5730  		}
  5731  
  5732  		// Find the longest match, discarding those <= prev_length.
  5733  		(*Deflate_state)(unsafe.Pointer(s)).Fprev_length = (*Deflate_state)(unsafe.Pointer(s)).Fmatch_length
  5734  		(*Deflate_state)(unsafe.Pointer(s)).Fprev_match = (*Deflate_state)(unsafe.Pointer(s)).Fmatch_start
  5735  		(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length = UInt(MIN_MATCH - 1)
  5736  
  5737  		if hash_head != IPos(NIL) && (*Deflate_state)(unsafe.Pointer(s)).Fprev_length < (*Deflate_state)(unsafe.Pointer(s)).Fmax_lazy_match && (*Deflate_state)(unsafe.Pointer(s)).Fstrstart-hash_head <= (*Deflate_state)(unsafe.Pointer(s)).Fw_size-UInt(MAX_MATCH+MIN_MATCH+1) {
  5738  			// To simplify the code, we prevent matches with the string
  5739  			// of window index 0 (in particular we have to avoid a match
  5740  			// of the string with itself at the start of the input file).
  5741  			(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length = longest_match(tls, s, hash_head)
  5742  			// longest_match() sets match_start
  5743  
  5744  			if (*Deflate_state)(unsafe.Pointer(s)).Fmatch_length <= UInt(5) && ((*Deflate_state)(unsafe.Pointer(s)).Fstrategy == Z_FILTERED ||
  5745  				(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length == UInt(MIN_MATCH) && (*Deflate_state)(unsafe.Pointer(s)).Fstrstart-(*Deflate_state)(unsafe.Pointer(s)).Fmatch_start > UInt(TOO_FAR)) {
  5746  
  5747  				// If prev_match is also MIN_MATCH, match_start is garbage
  5748  				// but we will ignore the current match anyway.
  5749  				(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length = UInt(MIN_MATCH - 1)
  5750  			}
  5751  		}
  5752  		// If there was a match at the previous step and the current
  5753  		// match is not better, output the previous match:
  5754  		if (*Deflate_state)(unsafe.Pointer(s)).Fprev_length >= UInt(MIN_MATCH) && (*Deflate_state)(unsafe.Pointer(s)).Fmatch_length <= (*Deflate_state)(unsafe.Pointer(s)).Fprev_length {
  5755  			var max_insert UInt = (*Deflate_state)(unsafe.Pointer(s)).Fstrstart + (*Deflate_state)(unsafe.Pointer(s)).Flookahead - UInt(MIN_MATCH)
  5756  			// Do not insert strings in hash table beyond this.
  5757  
  5758  			{
  5759  				var len Uch = Uch((*Deflate_state)(unsafe.Pointer(s)).Fprev_length - UInt(MIN_MATCH))
  5760  				var dist Ush = Ush((*Deflate_state)(unsafe.Pointer(s)).Fstrstart - UInt(1) - (*Deflate_state)(unsafe.Pointer(s)).Fprev_match)
  5761  				*(*Ushf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fd_buf + uintptr((*Deflate_state)(unsafe.Pointer(s)).Flast_lit)*2)) = dist
  5762  				*(*Uchf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fl_buf + uintptr(libc.PostIncUint32(&(*Deflate_state)(unsafe.Pointer(s)).Flast_lit, 1)))) = len
  5763  				dist--
  5764  				*(*Ush)(unsafe.Pointer(s + 212 + uintptr(int32(X_length_code[len])+LITERALS+1)*4))++
  5765  				*(*Ush)(unsafe.Pointer(s + 2504 + uintptr(func() int32 {
  5766  					if int32(dist) < 256 {
  5767  						return int32(X_dist_code[dist])
  5768  					}
  5769  					return int32(X_dist_code[256+int32(dist)>>7])
  5770  				}())*4))++
  5771  				bflush = libc.Bool32((*Deflate_state)(unsafe.Pointer(s)).Flast_lit == (*Deflate_state)(unsafe.Pointer(s)).Flit_bufsize-UInt(1))
  5772  			}
  5773  
  5774  			// Insert in hash table all strings up to the end of the match.
  5775  			// strstart-1 and strstart are already inserted. If there is not
  5776  			// enough lookahead, the last two strings are not inserted in
  5777  			// the hash table.
  5778  			*(*UInt)(unsafe.Pointer(s + 180)) -= (*Deflate_state)(unsafe.Pointer(s)).Fprev_length - UInt(1)
  5779  			*(*UInt)(unsafe.Pointer(s + 184)) -= UInt(2)
  5780  			for ok := true; ok; ok = libc.PreDecUint32(&(*Deflate_state)(unsafe.Pointer(s)).Fprev_length, 1) != UInt(0) {
  5781  				if libc.PreIncUint32(&(*Deflate_state)(unsafe.Pointer(s)).Fstrstart, 1) <= max_insert {
  5782  					(*Deflate_state)(unsafe.Pointer(s)).Fins_h = ((*Deflate_state)(unsafe.Pointer(s)).Fins_h<<(*Deflate_state)(unsafe.Pointer(s)).Fhash_shift ^ UInt(*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart+UInt(MIN_MATCH-1)))))) & (*Deflate_state)(unsafe.Pointer(s)).Fhash_mask
  5783  					hash_head = IPos(libc.AssignPtrUint16((*Deflate_state)(unsafe.Pointer(s)).Fprev+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart&(*Deflate_state)(unsafe.Pointer(s)).Fw_mask)*2, *(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fins_h)*2))))
  5784  					*(*Posf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fhead + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fins_h)*2)) = Pos((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5785  				}
  5786  			}
  5787  			(*Deflate_state)(unsafe.Pointer(s)).Fmatch_available = 0
  5788  			(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length = UInt(MIN_MATCH - 1)
  5789  			(*Deflate_state)(unsafe.Pointer(s)).Fstrstart++
  5790  
  5791  			if bflush != 0 {
  5792  				{
  5793  					X_tr_flush_block(tls, s, func() uintptr {
  5794  						if (*Deflate_state)(unsafe.Pointer(s)).Fblock_start >= 0 {
  5795  							return (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(uint32((*Deflate_state)(unsafe.Pointer(s)).Fblock_start))
  5796  						}
  5797  						return uintptr(Z_NULL)
  5798  					}(), Ulg(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)-(*Deflate_state)(unsafe.Pointer(s)).Fblock_start), 0)
  5799  					(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5800  					flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  5801  				}
  5802  				if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out == UInt(0) {
  5803  					if 0 != 0 {
  5804  						return Finish_started
  5805  					}
  5806  					return Need_more
  5807  				}
  5808  			}
  5809  
  5810  		} else if (*Deflate_state)(unsafe.Pointer(s)).Fmatch_available != 0 {
  5811  			// If there was no match at the previous position, output a
  5812  			// single literal. If there was a match but the current match
  5813  			// is longer, truncate the previous match to a single literal.
  5814  
  5815  			{
  5816  				var cc Uch = *(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart-UInt(1))))
  5817  				*(*Ushf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fd_buf + uintptr((*Deflate_state)(unsafe.Pointer(s)).Flast_lit)*2)) = Ushf(0)
  5818  				*(*Uchf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fl_buf + uintptr(libc.PostIncUint32(&(*Deflate_state)(unsafe.Pointer(s)).Flast_lit, 1)))) = cc
  5819  				*(*Ush)(unsafe.Pointer(s + 212 + uintptr(cc)*4))++
  5820  				bflush = libc.Bool32((*Deflate_state)(unsafe.Pointer(s)).Flast_lit == (*Deflate_state)(unsafe.Pointer(s)).Flit_bufsize-UInt(1))
  5821  			}
  5822  
  5823  			if bflush != 0 {
  5824  				{
  5825  					X_tr_flush_block(tls, s, func() uintptr {
  5826  						if (*Deflate_state)(unsafe.Pointer(s)).Fblock_start >= 0 {
  5827  							return (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(uint32((*Deflate_state)(unsafe.Pointer(s)).Fblock_start))
  5828  						}
  5829  						return uintptr(Z_NULL)
  5830  					}(), Ulg(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)-(*Deflate_state)(unsafe.Pointer(s)).Fblock_start), 0)
  5831  					(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5832  					flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  5833  				}
  5834  
  5835  			}
  5836  			(*Deflate_state)(unsafe.Pointer(s)).Fstrstart++
  5837  			(*Deflate_state)(unsafe.Pointer(s)).Flookahead--
  5838  			if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out == UInt(0) {
  5839  				return Need_more
  5840  			}
  5841  		} else {
  5842  			// There is no previous match to compare with, wait for
  5843  			// the next step to decide.
  5844  			(*Deflate_state)(unsafe.Pointer(s)).Fmatch_available = 1
  5845  			(*Deflate_state)(unsafe.Pointer(s)).Fstrstart++
  5846  			(*Deflate_state)(unsafe.Pointer(s)).Flookahead--
  5847  		}
  5848  	}
  5849  
  5850  	if (*Deflate_state)(unsafe.Pointer(s)).Fmatch_available != 0 {
  5851  
  5852  		{
  5853  			var cc Uch = *(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart-UInt(1))))
  5854  			*(*Ushf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fd_buf + uintptr((*Deflate_state)(unsafe.Pointer(s)).Flast_lit)*2)) = Ushf(0)
  5855  			*(*Uchf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fl_buf + uintptr(libc.PostIncUint32(&(*Deflate_state)(unsafe.Pointer(s)).Flast_lit, 1)))) = cc
  5856  			*(*Ush)(unsafe.Pointer(s + 212 + uintptr(cc)*4))++
  5857  			bflush = libc.Bool32((*Deflate_state)(unsafe.Pointer(s)).Flast_lit == (*Deflate_state)(unsafe.Pointer(s)).Flit_bufsize-UInt(1))
  5858  		}
  5859  
  5860  		(*Deflate_state)(unsafe.Pointer(s)).Fmatch_available = 0
  5861  	}
  5862  	(*Deflate_state)(unsafe.Pointer(s)).Finsert = func() uint32 {
  5863  		if (*Deflate_state)(unsafe.Pointer(s)).Fstrstart < UInt(MIN_MATCH-1) {
  5864  			return (*Deflate_state)(unsafe.Pointer(s)).Fstrstart
  5865  		}
  5866  		return uint32(MIN_MATCH - 1)
  5867  	}()
  5868  	if flush == Z_FINISH {
  5869  		{
  5870  			{
  5871  				X_tr_flush_block(tls, s, func() uintptr {
  5872  					if (*Deflate_state)(unsafe.Pointer(s)).Fblock_start >= 0 {
  5873  						return (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(uint32((*Deflate_state)(unsafe.Pointer(s)).Fblock_start))
  5874  					}
  5875  					return uintptr(Z_NULL)
  5876  				}(), Ulg(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)-(*Deflate_state)(unsafe.Pointer(s)).Fblock_start), 1)
  5877  				(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5878  				flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  5879  			}
  5880  			if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out == UInt(0) {
  5881  				if 1 != 0 {
  5882  					return Finish_started
  5883  				}
  5884  				return Need_more
  5885  			}
  5886  		}
  5887  
  5888  		return Finish_done
  5889  	}
  5890  	if (*Deflate_state)(unsafe.Pointer(s)).Flast_lit != 0 {
  5891  		{
  5892  			X_tr_flush_block(tls, s, func() uintptr {
  5893  				if (*Deflate_state)(unsafe.Pointer(s)).Fblock_start >= 0 {
  5894  					return (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(uint32((*Deflate_state)(unsafe.Pointer(s)).Fblock_start))
  5895  				}
  5896  				return uintptr(Z_NULL)
  5897  			}(), Ulg(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)-(*Deflate_state)(unsafe.Pointer(s)).Fblock_start), 0)
  5898  			(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5899  			flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  5900  		}
  5901  		if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out == UInt(0) {
  5902  			if 0 != 0 {
  5903  				return Finish_started
  5904  			}
  5905  			return Need_more
  5906  		}
  5907  	}
  5908  
  5909  	return Block_done
  5910  }
  5911  
  5912  // ===========================================================================
  5913  // For Z_RLE, simply look for runs of bytes, generate matches only of distance
  5914  // one.  Do not maintain a hash table.  (It will be regenerated if this run of
  5915  // deflate switches away from Z_RLE.)
  5916  func deflate_rle(tls *libc.TLS, s uintptr, flush int32) Block_state { /* deflate.c:2057:19: */
  5917  	var bflush int32 // set if current block must be flushed
  5918  	var prev UInt    // byte at distance one to match
  5919  	var scan uintptr
  5920  	var strend uintptr // scan goes up to strend for length of run
  5921  
  5922  	for {
  5923  		// Make sure that we always have enough lookahead, except
  5924  		// at the end of the input file. We need MAX_MATCH bytes
  5925  		// for the longest run, plus one for the unrolled loop.
  5926  		if (*Deflate_state)(unsafe.Pointer(s)).Flookahead <= UInt(MAX_MATCH) {
  5927  			fill_window(tls, s)
  5928  			if (*Deflate_state)(unsafe.Pointer(s)).Flookahead <= UInt(MAX_MATCH) && flush == Z_NO_FLUSH {
  5929  				return Need_more
  5930  			}
  5931  			if (*Deflate_state)(unsafe.Pointer(s)).Flookahead == UInt(0) {
  5932  				break
  5933  			} // flush the current block
  5934  		}
  5935  
  5936  		// See how many times the previous byte repeats
  5937  		(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length = UInt(0)
  5938  		if (*Deflate_state)(unsafe.Pointer(s)).Flookahead >= UInt(MIN_MATCH) && (*Deflate_state)(unsafe.Pointer(s)).Fstrstart > UInt(0) {
  5939  			scan = (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart) - uintptr(1)
  5940  			prev = UInt(*(*Bytef)(unsafe.Pointer(scan)))
  5941  			if prev == UInt(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) && prev == UInt(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) && prev == UInt(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) {
  5942  				strend = (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart) + uintptr(MAX_MATCH)
  5943  				for ok := true; ok; ok = prev == UInt(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) && prev == UInt(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) && prev == UInt(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) && prev == UInt(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) && prev == UInt(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) && prev == UInt(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) && prev == UInt(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) && prev == UInt(*(*Bytef)(unsafe.Pointer(libc.PreIncUintptr(&scan, 1)))) && scan < strend {
  5944  				}
  5945  				(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length = UInt(MAX_MATCH) - UInt((int64(strend)-int64(scan))/1)
  5946  				if (*Deflate_state)(unsafe.Pointer(s)).Fmatch_length > (*Deflate_state)(unsafe.Pointer(s)).Flookahead {
  5947  					(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length = (*Deflate_state)(unsafe.Pointer(s)).Flookahead
  5948  				}
  5949  			}
  5950  
  5951  		}
  5952  
  5953  		// Emit match if have run of MIN_MATCH or longer, else emit literal
  5954  		if (*Deflate_state)(unsafe.Pointer(s)).Fmatch_length >= UInt(MIN_MATCH) {
  5955  
  5956  			{
  5957  				var len Uch = Uch((*Deflate_state)(unsafe.Pointer(s)).Fmatch_length - UInt(MIN_MATCH))
  5958  				var dist Ush = Ush(1)
  5959  				*(*Ushf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fd_buf + uintptr((*Deflate_state)(unsafe.Pointer(s)).Flast_lit)*2)) = dist
  5960  				*(*Uchf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fl_buf + uintptr(libc.PostIncUint32(&(*Deflate_state)(unsafe.Pointer(s)).Flast_lit, 1)))) = len
  5961  				dist--
  5962  				*(*Ush)(unsafe.Pointer(s + 212 + uintptr(int32(X_length_code[len])+LITERALS+1)*4))++
  5963  				*(*Ush)(unsafe.Pointer(s + 2504 + uintptr(func() int32 {
  5964  					if int32(dist) < 256 {
  5965  						return int32(X_dist_code[dist])
  5966  					}
  5967  					return int32(X_dist_code[256+int32(dist)>>7])
  5968  				}())*4))++
  5969  				bflush = libc.Bool32((*Deflate_state)(unsafe.Pointer(s)).Flast_lit == (*Deflate_state)(unsafe.Pointer(s)).Flit_bufsize-UInt(1))
  5970  			}
  5971  
  5972  			*(*UInt)(unsafe.Pointer(s + 180)) -= (*Deflate_state)(unsafe.Pointer(s)).Fmatch_length
  5973  			*(*UInt)(unsafe.Pointer(s + 172)) += (*Deflate_state)(unsafe.Pointer(s)).Fmatch_length
  5974  			(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length = UInt(0)
  5975  		} else {
  5976  			// No match, output a literal byte
  5977  
  5978  			{
  5979  				var cc Uch = *(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)))
  5980  				*(*Ushf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fd_buf + uintptr((*Deflate_state)(unsafe.Pointer(s)).Flast_lit)*2)) = Ushf(0)
  5981  				*(*Uchf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fl_buf + uintptr(libc.PostIncUint32(&(*Deflate_state)(unsafe.Pointer(s)).Flast_lit, 1)))) = cc
  5982  				*(*Ush)(unsafe.Pointer(s + 212 + uintptr(cc)*4))++
  5983  				bflush = libc.Bool32((*Deflate_state)(unsafe.Pointer(s)).Flast_lit == (*Deflate_state)(unsafe.Pointer(s)).Flit_bufsize-UInt(1))
  5984  			}
  5985  
  5986  			(*Deflate_state)(unsafe.Pointer(s)).Flookahead--
  5987  			(*Deflate_state)(unsafe.Pointer(s)).Fstrstart++
  5988  		}
  5989  		if bflush != 0 {
  5990  			{
  5991  				X_tr_flush_block(tls, s, func() uintptr {
  5992  					if (*Deflate_state)(unsafe.Pointer(s)).Fblock_start >= 0 {
  5993  						return (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(uint32((*Deflate_state)(unsafe.Pointer(s)).Fblock_start))
  5994  					}
  5995  					return uintptr(Z_NULL)
  5996  				}(), Ulg(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)-(*Deflate_state)(unsafe.Pointer(s)).Fblock_start), 0)
  5997  				(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  5998  				flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  5999  			}
  6000  			if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out == UInt(0) {
  6001  				if 0 != 0 {
  6002  					return Finish_started
  6003  				}
  6004  				return Need_more
  6005  			}
  6006  		}
  6007  
  6008  	}
  6009  	(*Deflate_state)(unsafe.Pointer(s)).Finsert = UInt(0)
  6010  	if flush == Z_FINISH {
  6011  		{
  6012  			{
  6013  				X_tr_flush_block(tls, s, func() uintptr {
  6014  					if (*Deflate_state)(unsafe.Pointer(s)).Fblock_start >= 0 {
  6015  						return (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(uint32((*Deflate_state)(unsafe.Pointer(s)).Fblock_start))
  6016  					}
  6017  					return uintptr(Z_NULL)
  6018  				}(), Ulg(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)-(*Deflate_state)(unsafe.Pointer(s)).Fblock_start), 1)
  6019  				(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  6020  				flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  6021  			}
  6022  			if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out == UInt(0) {
  6023  				if 1 != 0 {
  6024  					return Finish_started
  6025  				}
  6026  				return Need_more
  6027  			}
  6028  		}
  6029  
  6030  		return Finish_done
  6031  	}
  6032  	if (*Deflate_state)(unsafe.Pointer(s)).Flast_lit != 0 {
  6033  		{
  6034  			X_tr_flush_block(tls, s, func() uintptr {
  6035  				if (*Deflate_state)(unsafe.Pointer(s)).Fblock_start >= 0 {
  6036  					return (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(uint32((*Deflate_state)(unsafe.Pointer(s)).Fblock_start))
  6037  				}
  6038  				return uintptr(Z_NULL)
  6039  			}(), Ulg(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)-(*Deflate_state)(unsafe.Pointer(s)).Fblock_start), 0)
  6040  			(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  6041  			flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  6042  		}
  6043  		if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out == UInt(0) {
  6044  			if 0 != 0 {
  6045  				return Finish_started
  6046  			}
  6047  			return Need_more
  6048  		}
  6049  	}
  6050  
  6051  	return Block_done
  6052  }
  6053  
  6054  // ===========================================================================
  6055  // For Z_HUFFMAN_ONLY, do not look for matches.  Do not maintain a hash table.
  6056  // (It will be regenerated if this run of deflate switches away from Huffman.)
  6057  func deflate_huff(tls *libc.TLS, s uintptr, flush int32) Block_state { /* deflate.c:2130:19: */
  6058  	var bflush int32 // set if current block must be flushed
  6059  
  6060  	for {
  6061  		// Make sure that we have a literal to write.
  6062  		if (*Deflate_state)(unsafe.Pointer(s)).Flookahead == UInt(0) {
  6063  			fill_window(tls, s)
  6064  			if (*Deflate_state)(unsafe.Pointer(s)).Flookahead == UInt(0) {
  6065  				if flush == Z_NO_FLUSH {
  6066  					return Need_more
  6067  				}
  6068  				break // flush the current block
  6069  			}
  6070  		}
  6071  
  6072  		// Output a literal byte
  6073  		(*Deflate_state)(unsafe.Pointer(s)).Fmatch_length = UInt(0)
  6074  
  6075  		{
  6076  			var cc Uch = *(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)))
  6077  			*(*Ushf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fd_buf + uintptr((*Deflate_state)(unsafe.Pointer(s)).Flast_lit)*2)) = Ushf(0)
  6078  			*(*Uchf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fl_buf + uintptr(libc.PostIncUint32(&(*Deflate_state)(unsafe.Pointer(s)).Flast_lit, 1)))) = cc
  6079  			*(*Ush)(unsafe.Pointer(s + 212 + uintptr(cc)*4))++
  6080  			bflush = libc.Bool32((*Deflate_state)(unsafe.Pointer(s)).Flast_lit == (*Deflate_state)(unsafe.Pointer(s)).Flit_bufsize-UInt(1))
  6081  		}
  6082  
  6083  		(*Deflate_state)(unsafe.Pointer(s)).Flookahead--
  6084  		(*Deflate_state)(unsafe.Pointer(s)).Fstrstart++
  6085  		if bflush != 0 {
  6086  			{
  6087  				X_tr_flush_block(tls, s, func() uintptr {
  6088  					if (*Deflate_state)(unsafe.Pointer(s)).Fblock_start >= 0 {
  6089  						return (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(uint32((*Deflate_state)(unsafe.Pointer(s)).Fblock_start))
  6090  					}
  6091  					return uintptr(Z_NULL)
  6092  				}(), Ulg(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)-(*Deflate_state)(unsafe.Pointer(s)).Fblock_start), 0)
  6093  				(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  6094  				flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  6095  			}
  6096  			if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out == UInt(0) {
  6097  				if 0 != 0 {
  6098  					return Finish_started
  6099  				}
  6100  				return Need_more
  6101  			}
  6102  		}
  6103  
  6104  	}
  6105  	(*Deflate_state)(unsafe.Pointer(s)).Finsert = UInt(0)
  6106  	if flush == Z_FINISH {
  6107  		{
  6108  			{
  6109  				X_tr_flush_block(tls, s, func() uintptr {
  6110  					if (*Deflate_state)(unsafe.Pointer(s)).Fblock_start >= 0 {
  6111  						return (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(uint32((*Deflate_state)(unsafe.Pointer(s)).Fblock_start))
  6112  					}
  6113  					return uintptr(Z_NULL)
  6114  				}(), Ulg(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)-(*Deflate_state)(unsafe.Pointer(s)).Fblock_start), 1)
  6115  				(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  6116  				flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  6117  			}
  6118  			if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out == UInt(0) {
  6119  				if 1 != 0 {
  6120  					return Finish_started
  6121  				}
  6122  				return Need_more
  6123  			}
  6124  		}
  6125  
  6126  		return Finish_done
  6127  	}
  6128  	if (*Deflate_state)(unsafe.Pointer(s)).Flast_lit != 0 {
  6129  		{
  6130  			X_tr_flush_block(tls, s, func() uintptr {
  6131  				if (*Deflate_state)(unsafe.Pointer(s)).Fblock_start >= 0 {
  6132  					return (*Deflate_state)(unsafe.Pointer(s)).Fwindow + uintptr(uint32((*Deflate_state)(unsafe.Pointer(s)).Fblock_start))
  6133  				}
  6134  				return uintptr(Z_NULL)
  6135  			}(), Ulg(int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)-(*Deflate_state)(unsafe.Pointer(s)).Fblock_start), 0)
  6136  			(*Deflate_state)(unsafe.Pointer(s)).Fblock_start = int64((*Deflate_state)(unsafe.Pointer(s)).Fstrstart)
  6137  			flush_pending(tls, (*Deflate_state)(unsafe.Pointer(s)).Fstrm)
  6138  		}
  6139  		if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Favail_out == UInt(0) {
  6140  			if 0 != 0 {
  6141  				return Finish_started
  6142  			}
  6143  			return Need_more
  6144  		}
  6145  	}
  6146  
  6147  	return Block_done
  6148  }
  6149  
  6150  // Major, minor numbers, dev_t's.
  6151  
  6152  type Fpos_t = Off_t /* stdio.h:61:15 */ // stdio file position type
  6153  
  6154  // NB: to fit things in six character monocase externals, the stdio
  6155  // code uses the prefix `__s' for stdio objects, typically followed
  6156  // by a three-character attempt at a mnemonic.
  6157  
  6158  // stdio buffers
  6159  type X__sbuf = struct {
  6160  	F_base       uintptr
  6161  	F_size       int32
  6162  	F__ccgo_pad1 [4]byte
  6163  } /* stdio.h:70:1 */
  6164  
  6165  // stdio state variables.
  6166  //
  6167  // The following always hold:
  6168  //
  6169  //	if (_flags&(__SLBF|__SWR)) == (__SLBF|__SWR),
  6170  //		_lbfsize is -_bf._size, else _lbfsize is 0
  6171  //	if _flags&__SRD, _w is 0
  6172  //	if _flags&__SWR, _r is 0
  6173  //
  6174  // This ensures that the getc and putc macros (or inline functions) never
  6175  // try to write or read from a file that is in `read' or `write' mode.
  6176  // (Moreover, they can, and do, automatically switch from read mode to
  6177  // write mode, and back, on "r+" and "w+" files.)
  6178  //
  6179  // _lbfsize is used only to make the inline line-buffered output stream
  6180  // code as compact as possible.
  6181  //
  6182  // _ub, _up, and _ur are used when ungetc() pushes back more characters
  6183  // than fit in the current _bf, or when ungetc() pushes back a character
  6184  // that does not match the previous one in _bf.  When this happens,
  6185  // _ub._base becomes non-nil (i.e., a stream has ungetc() data iff
  6186  // _ub._base!=NULL) and _up and _ur save the current values of _p and _r.
  6187  type X__sFILE = struct {
  6188  	F_p          uintptr
  6189  	F_r          int32
  6190  	F_w          int32
  6191  	F_flags      int16
  6192  	F_file       int16
  6193  	F__ccgo_pad1 [4]byte
  6194  	F_bf         struct {
  6195  		F_base       uintptr
  6196  		F_size       int32
  6197  		F__ccgo_pad1 [4]byte
  6198  	}
  6199  	F_lbfsize    int32
  6200  	F__ccgo_pad2 [4]byte
  6201  	F_cookie     uintptr
  6202  	F_close      uintptr
  6203  	F_read       uintptr
  6204  	F_seek       uintptr
  6205  	F_write      uintptr
  6206  	F_ext        struct {
  6207  		F_base       uintptr
  6208  		F_size       int32
  6209  		F__ccgo_pad1 [4]byte
  6210  	}
  6211  	F_up   uintptr
  6212  	F_ur   int32
  6213  	F_ubuf [3]uint8
  6214  	F_nbuf [1]uint8
  6215  	F_lb   struct {
  6216  		F_base       uintptr
  6217  		F_size       int32
  6218  		F__ccgo_pad1 [4]byte
  6219  	}
  6220  	F_blksize    int32
  6221  	F__ccgo_pad3 [4]byte
  6222  	F_offset     Fpos_t
  6223  } /* stdio.h:99:9 */
  6224  
  6225  // stdio state variables.
  6226  //
  6227  // The following always hold:
  6228  //
  6229  //	if (_flags&(__SLBF|__SWR)) == (__SLBF|__SWR),
  6230  //		_lbfsize is -_bf._size, else _lbfsize is 0
  6231  //	if _flags&__SRD, _w is 0
  6232  //	if _flags&__SWR, _r is 0
  6233  //
  6234  // This ensures that the getc and putc macros (or inline functions) never
  6235  // try to write or read from a file that is in `read' or `write' mode.
  6236  // (Moreover, they can, and do, automatically switch from read mode to
  6237  // write mode, and back, on "r+" and "w+" files.)
  6238  //
  6239  // _lbfsize is used only to make the inline line-buffered output stream
  6240  // code as compact as possible.
  6241  //
  6242  // _ub, _up, and _ur are used when ungetc() pushes back more characters
  6243  // than fit in the current _bf, or when ungetc() pushes back a character
  6244  // that does not match the previous one in _bf.  When this happens,
  6245  // _ub._base becomes non-nil (i.e., a stream has ungetc() data iff
  6246  // _ub._base!=NULL) and _up and _ur save the current values of _p and _r.
  6247  type FILE = X__sFILE /* stdio.h:131:3 */
  6248  
  6249  //	$OpenBSD: limits.h,v 1.19 2015/01/20 22:09:50 tedu Exp $
  6250  //	$NetBSD: limits.h,v 1.7 1994/10/26 00:56:00 cgd Exp $
  6251  
  6252  // Copyright (c) 1988 The Regents of the University of California.
  6253  // All rights reserved.
  6254  //
  6255  // Redistribution and use in source and binary forms, with or without
  6256  // modification, are permitted provided that the following conditions
  6257  // are met:
  6258  // 1. Redistributions of source code must retain the above copyright
  6259  //    notice, this list of conditions and the following disclaimer.
  6260  // 2. Redistributions in binary form must reproduce the above copyright
  6261  //    notice, this list of conditions and the following disclaimer in the
  6262  //    documentation and/or other materials provided with the distribution.
  6263  // 3. Neither the name of the University nor the names of its contributors
  6264  //    may be used to endorse or promote products derived from this software
  6265  //    without specific prior written permission.
  6266  //
  6267  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  6268  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  6269  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  6270  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  6271  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  6272  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  6273  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  6274  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  6275  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  6276  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  6277  // SUCH DAMAGE.
  6278  //
  6279  //	@(#)limits.h	5.9 (Berkeley) 4/3/91
  6280  
  6281  //	$OpenBSD: fcntl.h,v 1.22 2019/01/21 18:09:21 anton Exp $
  6282  //	$NetBSD: fcntl.h,v 1.8 1995/03/26 20:24:12 jtc Exp $
  6283  
  6284  // -
  6285  // Copyright (c) 1983, 1990, 1993
  6286  //	The Regents of the University of California.  All rights reserved.
  6287  // (c) UNIX System Laboratories, Inc.
  6288  // All or some portions of this file are derived from material licensed
  6289  // to the University of California by American Telephone and Telegraph
  6290  // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  6291  // the permission of UNIX System Laboratories, Inc.
  6292  //
  6293  // Redistribution and use in source and binary forms, with or without
  6294  // modification, are permitted provided that the following conditions
  6295  // are met:
  6296  // 1. Redistributions of source code must retain the above copyright
  6297  //    notice, this list of conditions and the following disclaimer.
  6298  // 2. Redistributions in binary form must reproduce the above copyright
  6299  //    notice, this list of conditions and the following disclaimer in the
  6300  //    documentation and/or other materials provided with the distribution.
  6301  // 3. Neither the name of the University nor the names of its contributors
  6302  //    may be used to endorse or promote products derived from this software
  6303  //    without specific prior written permission.
  6304  //
  6305  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  6306  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  6307  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  6308  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  6309  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  6310  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  6311  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  6312  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  6313  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  6314  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  6315  // SUCH DAMAGE.
  6316  //
  6317  //	@(#)fcntl.h	8.3 (Berkeley) 1/21/94
  6318  
  6319  // This file includes the definitions for open and fcntl
  6320  // described by POSIX for <fcntl.h>; it also includes
  6321  // related kernel definitions.
  6322  
  6323  //	$OpenBSD: cdefs.h,v 1.43 2018/10/29 17:10:40 guenther Exp $
  6324  //	$NetBSD: cdefs.h,v 1.16 1996/04/03 20:46:39 christos Exp $
  6325  
  6326  // Copyright (c) 1991, 1993
  6327  //	The Regents of the University of California.  All rights reserved.
  6328  //
  6329  // This code is derived from software contributed to Berkeley by
  6330  // Berkeley Software Design, Inc.
  6331  //
  6332  // Redistribution and use in source and binary forms, with or without
  6333  // modification, are permitted provided that the following conditions
  6334  // are met:
  6335  // 1. Redistributions of source code must retain the above copyright
  6336  //    notice, this list of conditions and the following disclaimer.
  6337  // 2. Redistributions in binary form must reproduce the above copyright
  6338  //    notice, this list of conditions and the following disclaimer in the
  6339  //    documentation and/or other materials provided with the distribution.
  6340  // 3. Neither the name of the University nor the names of its contributors
  6341  //    may be used to endorse or promote products derived from this software
  6342  //    without specific prior written permission.
  6343  //
  6344  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  6345  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  6346  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  6347  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  6348  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  6349  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  6350  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  6351  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  6352  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  6353  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  6354  // SUCH DAMAGE.
  6355  //
  6356  //	@(#)cdefs.h	8.7 (Berkeley) 1/21/94
  6357  
  6358  //	$OpenBSD: types.h,v 1.48 2019/02/09 04:54:11 guenther Exp $
  6359  //	$NetBSD: types.h,v 1.29 1996/11/15 22:48:25 jtc Exp $
  6360  
  6361  // -
  6362  // Copyright (c) 1982, 1986, 1991, 1993
  6363  //	The Regents of the University of California.  All rights reserved.
  6364  // (c) UNIX System Laboratories, Inc.
  6365  // All or some portions of this file are derived from material licensed
  6366  // to the University of California by American Telephone and Telegraph
  6367  // Co. or Unix System Laboratories, Inc. and are reproduced herein with
  6368  // the permission of UNIX System Laboratories, Inc.
  6369  //
  6370  // Redistribution and use in source and binary forms, with or without
  6371  // modification, are permitted provided that the following conditions
  6372  // are met:
  6373  // 1. Redistributions of source code must retain the above copyright
  6374  //    notice, this list of conditions and the following disclaimer.
  6375  // 2. Redistributions in binary form must reproduce the above copyright
  6376  //    notice, this list of conditions and the following disclaimer in the
  6377  //    documentation and/or other materials provided with the distribution.
  6378  // 3. Neither the name of the University nor the names of its contributors
  6379  //    may be used to endorse or promote products derived from this software
  6380  //    without specific prior written permission.
  6381  //
  6382  // THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
  6383  // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  6384  // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  6385  // ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
  6386  // FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  6387  // DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
  6388  // OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
  6389  // HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  6390  // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
  6391  // OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  6392  // SUCH DAMAGE.
  6393  //
  6394  //	@(#)types.h	8.4 (Berkeley) 1/21/94
  6395  
  6396  // File status flags: these are used by open(2), fcntl(2).
  6397  // They are also used (indirectly) in the kernel file structure f_flags,
  6398  // which is a superset of the open/fcntl flags.  Open flags and f_flags
  6399  // are inter-convertible using OFLAGS(fflags) and FFLAGS(oflags).
  6400  // Open/fcntl flags begin with O_; kernel-internal flags begin with F.
  6401  // open-only flags
  6402  
  6403  // Kernel encoding of open mode; separate read and write bits that are
  6404  // independently testable: 1 greater than the above.
  6405  //
  6406  // XXX
  6407  // FREAD and FWRITE are excluded from the #ifdef _KERNEL so that TIOCFLUSH,
  6408  // which was documented to use FREAD/FWRITE, continues to work.
  6409  
  6410  // POSIX 1003.1 specifies a higher granularity for synchronous operations
  6411  // than we support.  Since synchronicity is all or nothing in OpenBSD
  6412  // we just define these to be the same as O_SYNC.
  6413  
  6414  // defined by POSIX 1003.1; BSD default, this bit is not required
  6415  
  6416  // defined by POSIX Issue 7
  6417  
  6418  // The O_* flags used to have only F* names, which were used in the kernel
  6419  // and by fcntl.  We retain the F* names for the kernel f_flags field
  6420  // and for backward compatibility for fcntl.
  6421  
  6422  // Constants used for fcntl(2)
  6423  
  6424  // command values
  6425  
  6426  // file descriptor flags (F_GETFD, F_SETFD)
  6427  
  6428  // record locking flags (F_GETLK, F_SETLK, F_SETLKW)
  6429  
  6430  // Advisory file segment locking data type -
  6431  // information passed to system by user
  6432  type Flock = struct {
  6433  	Fl_start  Off_t
  6434  	Fl_len    Off_t
  6435  	Fl_pid    Pid_t
  6436  	Fl_type   int16
  6437  	Fl_whence int16
  6438  } /* fcntl.h:180:1 */
  6439  
  6440  // default memLevel
  6441  
  6442  // default i/o buffer size -- double this for output when reading (this and
  6443  //    twice this must be able to fit in an unsigned type)
  6444  
  6445  // gzip modes, also provide a little integrity check on the passed structure
  6446  
  6447  // values for gz_state how
  6448  
  6449  // internal gzip file state data structure
  6450  type Gz_state = struct {
  6451  	Fx        GzFile_s
  6452  	Fmode     int32
  6453  	Ffd       int32
  6454  	Fpath     uintptr
  6455  	Fsize     uint32
  6456  	Fwant     uint32
  6457  	Fin       uintptr
  6458  	Fout      uintptr
  6459  	Fdirect   int32
  6460  	Fhow      int32
  6461  	Fstart    Off_t
  6462  	Feof      int32
  6463  	Fpast     int32
  6464  	Flevel    int32
  6465  	Fstrategy int32
  6466  	Fskip     Off_t
  6467  	Fseek     int32
  6468  	Ferr      int32
  6469  	Fmsg      uintptr
  6470  	Fstrm     Z_stream
  6471  }                        /* gzguts.h:201:3 */
  6472  type Gz_statep = uintptr /* gzguts.h:202:22 */
  6473  
  6474  // GT_OFF(x), where x is an unsigned value, is true if x > maximum z_off64_t
  6475  //    value -- needed when comparing unsigned to z_off64_t, which is signed
  6476  //    (possible z_off64_t types off_t, off64_t, and long are all signed)
  6477  
  6478  // gzclose() is in a separate file so that it is linked in only if it is used.
  6479  //    That way the other gzclose functions can be used instead to avoid linking in
  6480  //    unneeded compression or decompression routines.
  6481  func Xgzclose(tls *libc.TLS, file GzFile) int32 { /* gzclose.c:11:13: */
  6482  	var state Gz_statep
  6483  
  6484  	if file == uintptr(0) {
  6485  		return -2
  6486  	}
  6487  	state = file
  6488  
  6489  	if (*Gz_state)(unsafe.Pointer(state)).Fmode == GZ_READ {
  6490  		return Xgzclose_r(tls, file)
  6491  	}
  6492  	return Xgzclose_w(tls, file)
  6493  }
  6494  
  6495  // Reset gzip file state
  6496  func gz_reset(tls *libc.TLS, state Gz_statep) { /* gzlib.c:75:12: */
  6497  	(*Gz_state)(unsafe.Pointer(state)).Fx.Fhave = uint32(0)  // no output data available
  6498  	if (*Gz_state)(unsafe.Pointer(state)).Fmode == GZ_READ { // for reading ...
  6499  		(*Gz_state)(unsafe.Pointer(state)).Feof = 0    // not at end of file
  6500  		(*Gz_state)(unsafe.Pointer(state)).Fpast = 0   // have not read past end yet
  6501  		(*Gz_state)(unsafe.Pointer(state)).Fhow = LOOK // look for gzip header
  6502  	}
  6503  	(*Gz_state)(unsafe.Pointer(state)).Fseek = 0                 // no seek request pending
  6504  	Xgz_error(tls, state, Z_OK, uintptr(0))                      // clear error
  6505  	(*Gz_state)(unsafe.Pointer(state)).Fx.Fpos = int64(0)        // no uncompressed data yet
  6506  	(*Gz_state)(unsafe.Pointer(state)).Fstrm.Favail_in = UInt(0) // no input data yet
  6507  }
  6508  
  6509  // Open a gzip file either by name or file descriptor.
  6510  func gz_open(tls *libc.TLS, path uintptr, fd int32, mode uintptr) GzFile { /* gzlib.c:91:14: */
  6511  	bp := tls.Alloc(16)
  6512  	defer tls.Free(16)
  6513  
  6514  	var state Gz_statep
  6515  	var len Z_size_t
  6516  	var oflag int32
  6517  	var cloexec int32 = 0
  6518  	var exclusive int32 = 0
  6519  
  6520  	// check input
  6521  	if path == uintptr(0) {
  6522  		return uintptr(0)
  6523  	}
  6524  
  6525  	// allocate gzFile structure to return
  6526  	state = libc.Xmalloc(tls, uint64(unsafe.Sizeof(Gz_state{})))
  6527  	if state == uintptr(0) {
  6528  		return uintptr(0)
  6529  	}
  6530  	(*Gz_state)(unsafe.Pointer(state)).Fsize = uint32(0)         // no buffers allocated yet
  6531  	(*Gz_state)(unsafe.Pointer(state)).Fwant = uint32(GZBUFSIZE) // requested buffer size
  6532  	(*Gz_state)(unsafe.Pointer(state)).Fmsg = uintptr(0)         // no error message yet
  6533  
  6534  	// interpret mode
  6535  	(*Gz_state)(unsafe.Pointer(state)).Fmode = GZ_NONE
  6536  	(*Gz_state)(unsafe.Pointer(state)).Flevel = -1
  6537  	(*Gz_state)(unsafe.Pointer(state)).Fstrategy = Z_DEFAULT_STRATEGY
  6538  	(*Gz_state)(unsafe.Pointer(state)).Fdirect = 0
  6539  	for *(*int8)(unsafe.Pointer(mode)) != 0 {
  6540  		if int32(*(*int8)(unsafe.Pointer(mode))) >= '0' && int32(*(*int8)(unsafe.Pointer(mode))) <= '9' {
  6541  			(*Gz_state)(unsafe.Pointer(state)).Flevel = int32(*(*int8)(unsafe.Pointer(mode))) - '0'
  6542  		} else {
  6543  			switch int32(*(*int8)(unsafe.Pointer(mode))) {
  6544  			case 'r':
  6545  				(*Gz_state)(unsafe.Pointer(state)).Fmode = GZ_READ
  6546  				break
  6547  				fallthrough
  6548  			case 'w':
  6549  				(*Gz_state)(unsafe.Pointer(state)).Fmode = GZ_WRITE
  6550  				break
  6551  				fallthrough
  6552  			case 'a':
  6553  				(*Gz_state)(unsafe.Pointer(state)).Fmode = GZ_APPEND
  6554  				break
  6555  				fallthrough
  6556  			case '+': // can't read and write at the same time
  6557  				libc.Xfree(tls, state)
  6558  				return uintptr(0)
  6559  				fallthrough
  6560  			case 'b': // ignore -- will request binary anyway
  6561  				break
  6562  				fallthrough
  6563  			case 'e':
  6564  				cloexec = 1
  6565  				break
  6566  				fallthrough
  6567  			case 'x':
  6568  				exclusive = 1
  6569  				break
  6570  				fallthrough
  6571  			case 'f':
  6572  				(*Gz_state)(unsafe.Pointer(state)).Fstrategy = Z_FILTERED
  6573  				break
  6574  				fallthrough
  6575  			case 'h':
  6576  				(*Gz_state)(unsafe.Pointer(state)).Fstrategy = Z_HUFFMAN_ONLY
  6577  				break
  6578  				fallthrough
  6579  			case 'R':
  6580  				(*Gz_state)(unsafe.Pointer(state)).Fstrategy = Z_RLE
  6581  				break
  6582  				fallthrough
  6583  			case 'F':
  6584  				(*Gz_state)(unsafe.Pointer(state)).Fstrategy = Z_FIXED
  6585  				break
  6586  				fallthrough
  6587  			case 'T':
  6588  				(*Gz_state)(unsafe.Pointer(state)).Fdirect = 1
  6589  				break
  6590  				fallthrough
  6591  			default: // could consider as an error, but just ignore
  6592  
  6593  			}
  6594  		}
  6595  		mode++
  6596  	}
  6597  
  6598  	// must provide an "r", "w", or "a"
  6599  	if (*Gz_state)(unsafe.Pointer(state)).Fmode == GZ_NONE {
  6600  		libc.Xfree(tls, state)
  6601  		return uintptr(0)
  6602  	}
  6603  
  6604  	// can't force transparent read
  6605  	if (*Gz_state)(unsafe.Pointer(state)).Fmode == GZ_READ {
  6606  		if (*Gz_state)(unsafe.Pointer(state)).Fdirect != 0 {
  6607  			libc.Xfree(tls, state)
  6608  			return uintptr(0)
  6609  		}
  6610  		(*Gz_state)(unsafe.Pointer(state)).Fdirect = 1 // for empty file
  6611  	}
  6612  
  6613  	// save the path name for error messages
  6614  	len = libc.Xstrlen(tls, path)
  6615  	(*Gz_state)(unsafe.Pointer(state)).Fpath = libc.Xmalloc(tls, len+uint64(1))
  6616  	if (*Gz_state)(unsafe.Pointer(state)).Fpath == uintptr(0) {
  6617  		libc.Xfree(tls, state)
  6618  		return uintptr(0)
  6619  	}
  6620  	libc.Xsnprintf(tls, (*Gz_state)(unsafe.Pointer(state)).Fpath, len+uint64(1), ts+76, libc.VaList(bp, path))
  6621  
  6622  	// compute the flags for open()
  6623  	oflag = func() int32 {
  6624  		if cloexec != 0 {
  6625  			return O_CLOEXEC
  6626  		}
  6627  		return 0
  6628  	}() | func() int32 {
  6629  		if (*Gz_state)(unsafe.Pointer(state)).Fmode == GZ_READ {
  6630  			return O_RDONLY
  6631  		}
  6632  		return O_WRONLY | O_CREAT | func() int32 {
  6633  			if exclusive != 0 {
  6634  				return O_EXCL
  6635  			}
  6636  			return 0
  6637  		}() | func() int32 {
  6638  			if (*Gz_state)(unsafe.Pointer(state)).Fmode == GZ_WRITE {
  6639  				return O_TRUNC
  6640  			}
  6641  			return O_APPEND
  6642  		}()
  6643  	}()
  6644  
  6645  	// open the file with the appropriate flags (or just use fd)
  6646  	(*Gz_state)(unsafe.Pointer(state)).Ffd = func() int32 {
  6647  		if fd > -1 {
  6648  			return fd
  6649  		}
  6650  		return libc.Xopen(tls, path, oflag, libc.VaList(bp+8, 0666))
  6651  	}()
  6652  	if (*Gz_state)(unsafe.Pointer(state)).Ffd == -1 {
  6653  		libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fpath)
  6654  		libc.Xfree(tls, state)
  6655  		return uintptr(0)
  6656  	}
  6657  	if (*Gz_state)(unsafe.Pointer(state)).Fmode == GZ_APPEND {
  6658  		libc.Xlseek(tls, (*Gz_state)(unsafe.Pointer(state)).Ffd, int64(0), SEEK_END) // so gzoffset() is correct
  6659  		(*Gz_state)(unsafe.Pointer(state)).Fmode = GZ_WRITE                          // simplify later checks
  6660  	}
  6661  
  6662  	// save the current position for rewinding (only if reading)
  6663  	if (*Gz_state)(unsafe.Pointer(state)).Fmode == GZ_READ {
  6664  		(*Gz_state)(unsafe.Pointer(state)).Fstart = libc.Xlseek(tls, (*Gz_state)(unsafe.Pointer(state)).Ffd, int64(0), SEEK_CUR)
  6665  		if (*Gz_state)(unsafe.Pointer(state)).Fstart == int64(-1) {
  6666  			(*Gz_state)(unsafe.Pointer(state)).Fstart = int64(0)
  6667  		}
  6668  	}
  6669  
  6670  	// initialize stream
  6671  	gz_reset(tls, state)
  6672  
  6673  	// return stream
  6674  	return state
  6675  }
  6676  
  6677  // -- see zlib.h --
  6678  func Xgzopen(tls *libc.TLS, path uintptr, mode uintptr) GzFile { /* gzlib.c:270:16: */
  6679  	return gz_open(tls, path, -1, mode)
  6680  }
  6681  
  6682  // -- see zlib.h --
  6683  func Xgzopen64(tls *libc.TLS, path uintptr, mode uintptr) GzFile { /* gzlib.c:278:16: */
  6684  	return gz_open(tls, path, -1, mode)
  6685  }
  6686  
  6687  // -- see zlib.h --
  6688  func Xgzdopen(tls *libc.TLS, fd int32, mode uintptr) GzFile { /* gzlib.c:286:16: */
  6689  	bp := tls.Alloc(8)
  6690  	defer tls.Free(8)
  6691  
  6692  	var path uintptr // identifier for error messages
  6693  	var gz GzFile
  6694  
  6695  	if fd == -1 || libc.AssignUintptr(&path, libc.Xmalloc(tls, uint64(7)+uint64(3)*uint64(unsafe.Sizeof(int32(0))))) == uintptr(0) {
  6696  		return uintptr(0)
  6697  	}
  6698  	libc.Xsnprintf(tls, path, uint64(7)+uint64(3)*uint64(unsafe.Sizeof(int32(0))), ts+79, libc.VaList(bp, fd))
  6699  	gz = gz_open(tls, path, fd, mode)
  6700  	libc.Xfree(tls, path)
  6701  	return gz
  6702  }
  6703  
  6704  // -- see zlib.h --
  6705  
  6706  // -- see zlib.h --
  6707  func Xgzbuffer(tls *libc.TLS, file GzFile, size uint32) int32 { /* gzlib.c:316:13: */
  6708  	var state Gz_statep
  6709  
  6710  	// get internal structure and check integrity
  6711  	if file == uintptr(0) {
  6712  		return -1
  6713  	}
  6714  	state = file
  6715  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ && (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE {
  6716  		return -1
  6717  	}
  6718  
  6719  	// make sure we haven't already allocated memory
  6720  	if (*Gz_state)(unsafe.Pointer(state)).Fsize != uint32(0) {
  6721  		return -1
  6722  	}
  6723  
  6724  	// check and set requested size
  6725  	if size<<1 < size {
  6726  		return -1
  6727  	} // need to be able to double it
  6728  	if size < uint32(2) {
  6729  		size = uint32(2)
  6730  	} // need two bytes to check magic header
  6731  	(*Gz_state)(unsafe.Pointer(state)).Fwant = size
  6732  	return 0
  6733  }
  6734  
  6735  // -- see zlib.h --
  6736  func Xgzrewind(tls *libc.TLS, file GzFile) int32 { /* gzlib.c:343:13: */
  6737  	var state Gz_statep
  6738  
  6739  	// get internal structure
  6740  	if file == uintptr(0) {
  6741  		return -1
  6742  	}
  6743  	state = file
  6744  
  6745  	// check that we're reading and that there's no error
  6746  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ || (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK && (*Gz_state)(unsafe.Pointer(state)).Ferr != -5 {
  6747  		return -1
  6748  	}
  6749  
  6750  	// back up and start over
  6751  	if libc.Xlseek(tls, (*Gz_state)(unsafe.Pointer(state)).Ffd, (*Gz_state)(unsafe.Pointer(state)).Fstart, SEEK_SET) == int64(-1) {
  6752  		return -1
  6753  	}
  6754  	gz_reset(tls, state)
  6755  	return 0
  6756  }
  6757  
  6758  // -- see zlib.h --
  6759  func Xgzseek64(tls *libc.TLS, file GzFile, offset Off_t, whence int32) Off_t { /* gzlib.c:366:19: */
  6760  	var n uint32
  6761  	var ret Off_t
  6762  	var state Gz_statep
  6763  
  6764  	// get internal structure and check integrity
  6765  	if file == uintptr(0) {
  6766  		return int64(-1)
  6767  	}
  6768  	state = file
  6769  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ && (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE {
  6770  		return int64(-1)
  6771  	}
  6772  
  6773  	// check that there's no error
  6774  	if (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK && (*Gz_state)(unsafe.Pointer(state)).Ferr != -5 {
  6775  		return int64(-1)
  6776  	}
  6777  
  6778  	// can only seek from start or relative to current position
  6779  	if whence != SEEK_SET && whence != SEEK_CUR {
  6780  		return int64(-1)
  6781  	}
  6782  
  6783  	// normalize offset to a SEEK_CUR specification
  6784  	if whence == SEEK_SET {
  6785  		offset = offset - (*Gz_state)(unsafe.Pointer(state)).Fx.Fpos
  6786  	} else if (*Gz_state)(unsafe.Pointer(state)).Fseek != 0 {
  6787  		offset = offset + (*Gz_state)(unsafe.Pointer(state)).Fskip
  6788  	}
  6789  	(*Gz_state)(unsafe.Pointer(state)).Fseek = 0
  6790  
  6791  	// if within raw area while reading, just go there
  6792  	if (*Gz_state)(unsafe.Pointer(state)).Fmode == GZ_READ && (*Gz_state)(unsafe.Pointer(state)).Fhow == COPY1 && (*Gz_state)(unsafe.Pointer(state)).Fx.Fpos+offset >= int64(0) {
  6793  		ret = libc.Xlseek(tls, (*Gz_state)(unsafe.Pointer(state)).Ffd, offset-Off_t((*Gz_state)(unsafe.Pointer(state)).Fx.Fhave), SEEK_CUR)
  6794  		if ret == int64(-1) {
  6795  			return int64(-1)
  6796  		}
  6797  		(*Gz_state)(unsafe.Pointer(state)).Fx.Fhave = uint32(0)
  6798  		(*Gz_state)(unsafe.Pointer(state)).Feof = 0
  6799  		(*Gz_state)(unsafe.Pointer(state)).Fpast = 0
  6800  		(*Gz_state)(unsafe.Pointer(state)).Fseek = 0
  6801  		Xgz_error(tls, state, Z_OK, uintptr(0))
  6802  		(*Gz_state)(unsafe.Pointer(state)).Fstrm.Favail_in = UInt(0)
  6803  		*(*Off_t)(unsafe.Pointer(state + 16)) += offset
  6804  		return (*Gz_state)(unsafe.Pointer(state)).Fx.Fpos
  6805  	}
  6806  
  6807  	// calculate skip amount, rewinding if needed for back seek when reading
  6808  	if offset < int64(0) {
  6809  		if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ { // writing -- can't go backwards
  6810  			return int64(-1)
  6811  		}
  6812  		offset = offset + (*Gz_state)(unsafe.Pointer(state)).Fx.Fpos
  6813  		if offset < int64(0) { // before start of file!
  6814  			return int64(-1)
  6815  		}
  6816  		if Xgzrewind(tls, file) == -1 { // rewind, then skip to offset
  6817  			return int64(-1)
  6818  		}
  6819  	}
  6820  
  6821  	// if reading, skip what's in output buffer (one less gzgetc() check)
  6822  	if (*Gz_state)(unsafe.Pointer(state)).Fmode == GZ_READ {
  6823  		if uint64(unsafe.Sizeof(int32(0))) == uint64(unsafe.Sizeof(Off_t(0))) && (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave > uint32(INT_MAX) || Off_t((*Gz_state)(unsafe.Pointer(state)).Fx.Fhave) > offset {
  6824  			n = uint32(offset)
  6825  		} else {
  6826  			n = (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave
  6827  		}
  6828  		*(*uint32)(unsafe.Pointer(state)) -= n
  6829  		*(*uintptr)(unsafe.Pointer(state + 8)) += uintptr(n)
  6830  		*(*Off_t)(unsafe.Pointer(state + 16)) += Off_t(n)
  6831  		offset = offset - Off_t(n)
  6832  	}
  6833  
  6834  	// request skip (if not zero)
  6835  	if offset != 0 {
  6836  		(*Gz_state)(unsafe.Pointer(state)).Fseek = 1
  6837  		(*Gz_state)(unsafe.Pointer(state)).Fskip = offset
  6838  	}
  6839  	return (*Gz_state)(unsafe.Pointer(state)).Fx.Fpos + offset
  6840  }
  6841  
  6842  // -- see zlib.h --
  6843  func Xgzseek(tls *libc.TLS, file GzFile, offset Off_t, whence int32) Off_t { /* gzlib.c:443:17: */
  6844  	var ret Off_t
  6845  
  6846  	ret = Xgzseek64(tls, file, offset, whence)
  6847  	if ret == ret {
  6848  		return ret
  6849  	}
  6850  	return int64(-1)
  6851  }
  6852  
  6853  // -- see zlib.h --
  6854  func Xgztell64(tls *libc.TLS, file GzFile) Off_t { /* gzlib.c:455:19: */
  6855  	var state Gz_statep
  6856  
  6857  	// get internal structure and check integrity
  6858  	if file == uintptr(0) {
  6859  		return int64(-1)
  6860  	}
  6861  	state = file
  6862  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ && (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE {
  6863  		return int64(-1)
  6864  	}
  6865  
  6866  	// return position
  6867  	return (*Gz_state)(unsafe.Pointer(state)).Fx.Fpos + func() int64 {
  6868  		if (*Gz_state)(unsafe.Pointer(state)).Fseek != 0 {
  6869  			return (*Gz_state)(unsafe.Pointer(state)).Fskip
  6870  		}
  6871  		return int64(0)
  6872  	}()
  6873  }
  6874  
  6875  // -- see zlib.h --
  6876  func Xgztell(tls *libc.TLS, file GzFile) Off_t { /* gzlib.c:472:17: */
  6877  	var ret Off_t
  6878  
  6879  	ret = Xgztell64(tls, file)
  6880  	if ret == ret {
  6881  		return ret
  6882  	}
  6883  	return int64(-1)
  6884  }
  6885  
  6886  // -- see zlib.h --
  6887  func Xgzoffset64(tls *libc.TLS, file GzFile) Off_t { /* gzlib.c:482:19: */
  6888  	var offset Off_t
  6889  	var state Gz_statep
  6890  
  6891  	// get internal structure and check integrity
  6892  	if file == uintptr(0) {
  6893  		return int64(-1)
  6894  	}
  6895  	state = file
  6896  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ && (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE {
  6897  		return int64(-1)
  6898  	}
  6899  
  6900  	// compute and return effective offset in file
  6901  	offset = libc.Xlseek(tls, (*Gz_state)(unsafe.Pointer(state)).Ffd, int64(0), SEEK_CUR)
  6902  	if offset == int64(-1) {
  6903  		return int64(-1)
  6904  	}
  6905  	if (*Gz_state)(unsafe.Pointer(state)).Fmode == GZ_READ { // reading
  6906  		offset = offset - Off_t((*Gz_state)(unsafe.Pointer(state)).Fstrm.Favail_in)
  6907  	} // don't count buffered input
  6908  	return offset
  6909  }
  6910  
  6911  // -- see zlib.h --
  6912  func Xgzoffset(tls *libc.TLS, file GzFile) Off_t { /* gzlib.c:505:17: */
  6913  	var ret Off_t
  6914  
  6915  	ret = Xgzoffset64(tls, file)
  6916  	if ret == ret {
  6917  		return ret
  6918  	}
  6919  	return int64(-1)
  6920  }
  6921  
  6922  // -- see zlib.h --
  6923  func Xgzeof(tls *libc.TLS, file GzFile) int32 { /* gzlib.c:515:13: */
  6924  	var state Gz_statep
  6925  
  6926  	// get internal structure and check integrity
  6927  	if file == uintptr(0) {
  6928  		return 0
  6929  	}
  6930  	state = file
  6931  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ && (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE {
  6932  		return 0
  6933  	}
  6934  
  6935  	// return end-of-file state
  6936  	if (*Gz_state)(unsafe.Pointer(state)).Fmode == GZ_READ {
  6937  		return (*Gz_state)(unsafe.Pointer(state)).Fpast
  6938  	}
  6939  	return 0
  6940  }
  6941  
  6942  // -- see zlib.h --
  6943  func Xgzerror(tls *libc.TLS, file GzFile, errnum uintptr) uintptr { /* gzlib.c:532:12: */
  6944  	var state Gz_statep
  6945  
  6946  	// get internal structure and check integrity
  6947  	if file == uintptr(0) {
  6948  		return uintptr(0)
  6949  	}
  6950  	state = file
  6951  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ && (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE {
  6952  		return uintptr(0)
  6953  	}
  6954  
  6955  	// return error information
  6956  	if errnum != uintptr(0) {
  6957  		*(*int32)(unsafe.Pointer(errnum)) = (*Gz_state)(unsafe.Pointer(state)).Ferr
  6958  	}
  6959  	if (*Gz_state)(unsafe.Pointer(state)).Ferr == -4 {
  6960  		return ts + 87 /* "out of memory" */
  6961  	}
  6962  	return func() uintptr {
  6963  		if (*Gz_state)(unsafe.Pointer(state)).Fmsg == uintptr(0) {
  6964  			return ts + 101
  6965  		}
  6966  		return (*Gz_state)(unsafe.Pointer(state)).Fmsg
  6967  	}()
  6968  }
  6969  
  6970  // -- see zlib.h --
  6971  func Xgzclearerr(tls *libc.TLS, file GzFile) { /* gzlib.c:553:14: */
  6972  	var state Gz_statep
  6973  
  6974  	// get internal structure and check integrity
  6975  	if file == uintptr(0) {
  6976  		return
  6977  	}
  6978  	state = file
  6979  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ && (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE {
  6980  		return
  6981  	}
  6982  
  6983  	// clear error and end-of-file
  6984  	if (*Gz_state)(unsafe.Pointer(state)).Fmode == GZ_READ {
  6985  		(*Gz_state)(unsafe.Pointer(state)).Feof = 0
  6986  		(*Gz_state)(unsafe.Pointer(state)).Fpast = 0
  6987  	}
  6988  	Xgz_error(tls, state, Z_OK, uintptr(0))
  6989  }
  6990  
  6991  // Create an error message in allocated memory and set state->err and
  6992  //    state->msg accordingly.  Free any previous error message already there.  Do
  6993  //    not try to free or allocate space if the error is Z_MEM_ERROR (out of
  6994  //    memory).  Simply save the error message as a static string.  If there is an
  6995  //    allocation failure constructing the error message, then convert the error to
  6996  //    out of memory.
  6997  func Xgz_error(tls *libc.TLS, state Gz_statep, err int32, msg uintptr) { /* gzlib.c:579:20: */
  6998  	bp := tls.Alloc(24)
  6999  	defer tls.Free(24)
  7000  
  7001  	// free previously allocated message and clear
  7002  	if (*Gz_state)(unsafe.Pointer(state)).Fmsg != uintptr(0) {
  7003  		if (*Gz_state)(unsafe.Pointer(state)).Ferr != -4 {
  7004  			libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fmsg)
  7005  		}
  7006  		(*Gz_state)(unsafe.Pointer(state)).Fmsg = uintptr(0)
  7007  	}
  7008  
  7009  	// if fatal, set state->x.have to 0 so that the gzgetc() macro fails
  7010  	if err != Z_OK && err != -5 {
  7011  		(*Gz_state)(unsafe.Pointer(state)).Fx.Fhave = uint32(0)
  7012  	}
  7013  
  7014  	// set error code, and if no message, then done
  7015  	(*Gz_state)(unsafe.Pointer(state)).Ferr = err
  7016  	if msg == uintptr(0) {
  7017  		return
  7018  	}
  7019  
  7020  	// for an out of memory error, return literal string when requested
  7021  	if err == -4 {
  7022  		return
  7023  	}
  7024  
  7025  	// construct error message with path
  7026  	if libc.AssignPtrUintptr(state+112, libc.Xmalloc(tls, libc.Xstrlen(tls, (*Gz_state)(unsafe.Pointer(state)).Fpath)+libc.Xstrlen(tls, msg)+uint64(3))) == uintptr(0) {
  7027  		(*Gz_state)(unsafe.Pointer(state)).Ferr = -4
  7028  		return
  7029  	}
  7030  	libc.Xsnprintf(tls, (*Gz_state)(unsafe.Pointer(state)).Fmsg, libc.Xstrlen(tls, (*Gz_state)(unsafe.Pointer(state)).Fpath)+libc.Xstrlen(tls, msg)+uint64(3),
  7031  		ts+102, libc.VaList(bp, (*Gz_state)(unsafe.Pointer(state)).Fpath, ts+109, msg))
  7032  }
  7033  
  7034  // Use read() to load a buffer -- return -1 on error, otherwise 0.  Read from
  7035  //    state->fd, and update state->eof, state->err, and state->msg as appropriate.
  7036  //    This function needs to loop on read(), since read() is not guaranteed to
  7037  //    read the number of bytes requested, depending on the type of descriptor.
  7038  func gz_load(tls *libc.TLS, state Gz_statep, buf uintptr, len uint32, have uintptr) int32 { /* gzread.c:21:11: */
  7039  	var ret int32
  7040  	var get uint32
  7041  	var max uint32 = uint32(libc.Uint32(libc.Uint32FromInt32(-1)))>>2 + uint32(1)
  7042  
  7043  	*(*uint32)(unsafe.Pointer(have)) = uint32(0)
  7044  	for ok := true; ok; ok = *(*uint32)(unsafe.Pointer(have)) < len {
  7045  		get = len - *(*uint32)(unsafe.Pointer(have))
  7046  		if get > max {
  7047  			get = max
  7048  		}
  7049  		ret = int32(libc.Xread(tls, (*Gz_state)(unsafe.Pointer(state)).Ffd, buf+uintptr(*(*uint32)(unsafe.Pointer(have))), uint64(get)))
  7050  		if ret <= 0 {
  7051  			break
  7052  		}
  7053  		*(*uint32)(unsafe.Pointer(have)) += uint32(ret)
  7054  	}
  7055  	if ret < 0 {
  7056  		Xgz_error(tls, state, -1, libc.Xstrerror(tls, *(*int32)(unsafe.Pointer(libc.X__errno(tls)))))
  7057  		return -1
  7058  	}
  7059  	if ret == 0 {
  7060  		(*Gz_state)(unsafe.Pointer(state)).Feof = 1
  7061  	}
  7062  	return 0
  7063  }
  7064  
  7065  // Load up input buffer and set eof flag if last data loaded -- return -1 on
  7066  //    error, 0 otherwise.  Note that the eof flag is set when the end of the input
  7067  //    file is reached, even though there may be unused data in the buffer.  Once
  7068  //    that data has been used, no more attempts will be made to read the file.
  7069  //    If strm->avail_in != 0, then the current data is moved to the beginning of
  7070  //    the input buffer, and then the remainder of the buffer is loaded with the
  7071  //    available data from the input file.
  7072  func gz_avail(tls *libc.TLS, state Gz_statep) int32 { /* gzread.c:56:11: */
  7073  	bp := tls.Alloc(4)
  7074  	defer tls.Free(4)
  7075  
  7076  	// var got uint32 at bp, 4
  7077  
  7078  	var strm Z_streamp = state + 120
  7079  
  7080  	if (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK && (*Gz_state)(unsafe.Pointer(state)).Ferr != -5 {
  7081  		return -1
  7082  	}
  7083  	if (*Gz_state)(unsafe.Pointer(state)).Feof == 0 {
  7084  		if (*Z_stream)(unsafe.Pointer(strm)).Favail_in != 0 { // copy what's there to the start
  7085  			var p uintptr = (*Gz_state)(unsafe.Pointer(state)).Fin
  7086  			var q uintptr = (*Z_stream)(unsafe.Pointer(strm)).Fnext_in
  7087  			var n uint32 = (*Z_stream)(unsafe.Pointer(strm)).Favail_in
  7088  			for ok := true; ok; ok = libc.PreDecUint32(&n, 1) != 0 {
  7089  				*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&p, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&q, 1)))
  7090  			}
  7091  		}
  7092  		if gz_load(tls, state, (*Gz_state)(unsafe.Pointer(state)).Fin+uintptr((*Z_stream)(unsafe.Pointer(strm)).Favail_in),
  7093  			(*Gz_state)(unsafe.Pointer(state)).Fsize-(*Z_stream)(unsafe.Pointer(strm)).Favail_in, bp) == -1 {
  7094  			return -1
  7095  		}
  7096  		*(*UInt)(unsafe.Pointer(strm + 8)) += *(*uint32)(unsafe.Pointer(bp))
  7097  		(*Z_stream)(unsafe.Pointer(strm)).Fnext_in = (*Gz_state)(unsafe.Pointer(state)).Fin
  7098  	}
  7099  	return 0
  7100  }
  7101  
  7102  // Look for gzip header, set up for inflate or copy.  state->x.have must be 0.
  7103  //    If this is the first time in, allocate required memory.  state->how will be
  7104  //    left unchanged if there is no more input data available, will be set to COPY
  7105  //    if there is no gzip header and direct copying will be performed, or it will
  7106  //    be set to GZIP for decompression.  If direct copying, then leftover input
  7107  //    data from the input buffer will be copied to the output buffer.  In that
  7108  //    case, all further file reads will be directly to either the output buffer or
  7109  //    a user buffer.  If decompressing, the inflate state will be initialized.
  7110  //    gz_look() will return 0 on success or -1 on failure.
  7111  func gz_look(tls *libc.TLS, state Gz_statep) int32 { /* gzread.c:91:11: */
  7112  	var strm Z_streamp = state + 120
  7113  
  7114  	// allocate read buffers and inflate memory
  7115  	if (*Gz_state)(unsafe.Pointer(state)).Fsize == uint32(0) {
  7116  		// allocate buffers
  7117  		(*Gz_state)(unsafe.Pointer(state)).Fin = libc.Xmalloc(tls, uint64((*Gz_state)(unsafe.Pointer(state)).Fwant))
  7118  		(*Gz_state)(unsafe.Pointer(state)).Fout = libc.Xmalloc(tls, uint64((*Gz_state)(unsafe.Pointer(state)).Fwant<<1))
  7119  		if (*Gz_state)(unsafe.Pointer(state)).Fin == uintptr(0) || (*Gz_state)(unsafe.Pointer(state)).Fout == uintptr(0) {
  7120  			libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fout)
  7121  			libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fin)
  7122  			Xgz_error(tls, state, -4, ts+87)
  7123  			return -1
  7124  		}
  7125  		(*Gz_state)(unsafe.Pointer(state)).Fsize = (*Gz_state)(unsafe.Pointer(state)).Fwant
  7126  
  7127  		// allocate inflate memory
  7128  		(*Gz_state)(unsafe.Pointer(state)).Fstrm.Fzalloc = Alloc_func(Z_NULL)
  7129  		(*Gz_state)(unsafe.Pointer(state)).Fstrm.Fzfree = Free_func(Z_NULL)
  7130  		(*Gz_state)(unsafe.Pointer(state)).Fstrm.Fopaque = Voidpf(Z_NULL)
  7131  		(*Gz_state)(unsafe.Pointer(state)).Fstrm.Favail_in = UInt(0)
  7132  		(*Gz_state)(unsafe.Pointer(state)).Fstrm.Fnext_in = uintptr(Z_NULL)
  7133  		if XinflateInit2_(tls, state+120, 15+16, ts, int32(unsafe.Sizeof(Z_stream{}))) != Z_OK { // gunzip
  7134  			libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fout)
  7135  			libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fin)
  7136  			(*Gz_state)(unsafe.Pointer(state)).Fsize = uint32(0)
  7137  			Xgz_error(tls, state, -4, ts+87)
  7138  			return -1
  7139  		}
  7140  	}
  7141  
  7142  	// get at least the magic bytes in the input buffer
  7143  	if (*Z_stream)(unsafe.Pointer(strm)).Favail_in < UInt(2) {
  7144  		if gz_avail(tls, state) == -1 {
  7145  			return -1
  7146  		}
  7147  		if (*Z_stream)(unsafe.Pointer(strm)).Favail_in == UInt(0) {
  7148  			return 0
  7149  		}
  7150  	}
  7151  
  7152  	// look for gzip magic bytes -- if there, do gzip decoding (note: there is
  7153  	//        a logical dilemma here when considering the case of a partially written
  7154  	//        gzip file, to wit, if a single 31 byte is written, then we cannot tell
  7155  	//        whether this is a single-byte file, or just a partially written gzip
  7156  	//        file -- for here we assume that if a gzip file is being written, then
  7157  	//        the header will be written in a single operation, so that reading a
  7158  	//        single byte is sufficient indication that it is not a gzip file)
  7159  	if (*Z_stream)(unsafe.Pointer(strm)).Favail_in > UInt(1) && int32(*(*Bytef)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fnext_in))) == 31 && int32(*(*Bytef)(unsafe.Pointer((*Z_stream)(unsafe.Pointer(strm)).Fnext_in + 1))) == 139 {
  7160  		XinflateReset(tls, strm)
  7161  		(*Gz_state)(unsafe.Pointer(state)).Fhow = /* GZIP */ 2
  7162  		(*Gz_state)(unsafe.Pointer(state)).Fdirect = 0
  7163  		return 0
  7164  	}
  7165  
  7166  	// no gzip header -- if we were decoding gzip before, then this is trailing
  7167  	//        garbage.  Ignore the trailing garbage and finish.
  7168  	if (*Gz_state)(unsafe.Pointer(state)).Fdirect == 0 {
  7169  		(*Z_stream)(unsafe.Pointer(strm)).Favail_in = UInt(0)
  7170  		(*Gz_state)(unsafe.Pointer(state)).Feof = 1
  7171  		(*Gz_state)(unsafe.Pointer(state)).Fx.Fhave = uint32(0)
  7172  		return 0
  7173  	}
  7174  
  7175  	// doing raw i/o, copy any leftover input to output -- this assumes that
  7176  	//        the output buffer is larger than the input buffer, which also assures
  7177  	//        space for gzungetc()
  7178  	(*Gz_state)(unsafe.Pointer(state)).Fx.Fnext = (*Gz_state)(unsafe.Pointer(state)).Fout
  7179  	if (*Z_stream)(unsafe.Pointer(strm)).Favail_in != 0 {
  7180  		libc.Xmemcpy(tls, (*Gz_state)(unsafe.Pointer(state)).Fx.Fnext, (*Z_stream)(unsafe.Pointer(strm)).Fnext_in, uint64((*Z_stream)(unsafe.Pointer(strm)).Favail_in))
  7181  		(*Gz_state)(unsafe.Pointer(state)).Fx.Fhave = (*Z_stream)(unsafe.Pointer(strm)).Favail_in
  7182  		(*Z_stream)(unsafe.Pointer(strm)).Favail_in = UInt(0)
  7183  	}
  7184  	(*Gz_state)(unsafe.Pointer(state)).Fhow = COPY1
  7185  	(*Gz_state)(unsafe.Pointer(state)).Fdirect = 1
  7186  	return 0
  7187  }
  7188  
  7189  // Decompress from input to the provided next_out and avail_out in the state.
  7190  //    On return, state->x.have and state->x.next point to the just decompressed
  7191  //    data.  If the gzip stream completes, state->how is reset to LOOK to look for
  7192  //    the next gzip stream or raw data, once state->x.have is depleted.  Returns 0
  7193  //    on success, -1 on failure.
  7194  func gz_decomp(tls *libc.TLS, state Gz_statep) int32 { /* gzread.c:175:11: */
  7195  	var ret int32 = Z_OK
  7196  	var had uint32
  7197  	var strm Z_streamp = state + 120
  7198  
  7199  	// fill output buffer up to end of deflate stream
  7200  	had = (*Z_stream)(unsafe.Pointer(strm)).Favail_out
  7201  	for ok := true; ok; ok = (*Z_stream)(unsafe.Pointer(strm)).Favail_out != 0 && ret != Z_STREAM_END {
  7202  		// get more input for inflate()
  7203  		if (*Z_stream)(unsafe.Pointer(strm)).Favail_in == UInt(0) && gz_avail(tls, state) == -1 {
  7204  			return -1
  7205  		}
  7206  		if (*Z_stream)(unsafe.Pointer(strm)).Favail_in == UInt(0) {
  7207  			Xgz_error(tls, state, -5, ts+112)
  7208  			break
  7209  		}
  7210  
  7211  		// decompress and handle errors
  7212  		ret = Xinflate(tls, strm, Z_NO_FLUSH)
  7213  		if ret == -2 || ret == Z_NEED_DICT {
  7214  			Xgz_error(tls, state, -2,
  7215  				ts+135)
  7216  			return -1
  7217  		}
  7218  		if ret == -4 {
  7219  			Xgz_error(tls, state, -4, ts+87)
  7220  			return -1
  7221  		}
  7222  		if ret == -3 { // deflate stream invalid
  7223  			Xgz_error(tls, state, -3,
  7224  				func() uintptr {
  7225  					if (*Z_stream)(unsafe.Pointer(strm)).Fmsg == uintptr(0) {
  7226  						return ts + 174 /* "compressed data ..." */
  7227  					}
  7228  					return (*Z_stream)(unsafe.Pointer(strm)).Fmsg
  7229  				}())
  7230  			return -1
  7231  		}
  7232  	}
  7233  
  7234  	// update available output
  7235  	(*Gz_state)(unsafe.Pointer(state)).Fx.Fhave = had - (*Z_stream)(unsafe.Pointer(strm)).Favail_out
  7236  	(*Gz_state)(unsafe.Pointer(state)).Fx.Fnext = (*Z_stream)(unsafe.Pointer(strm)).Fnext_out - uintptr((*Gz_state)(unsafe.Pointer(state)).Fx.Fhave)
  7237  
  7238  	// if the gzip stream completed successfully, look for another
  7239  	if ret == Z_STREAM_END {
  7240  		(*Gz_state)(unsafe.Pointer(state)).Fhow = LOOK
  7241  	}
  7242  
  7243  	// good decompression
  7244  	return 0
  7245  }
  7246  
  7247  // Fetch data and put it in the output buffer.  Assumes state->x.have is 0.
  7248  //    Data is either copied from the input file or decompressed from the input
  7249  //    file depending on state->how.  If state->how is LOOK, then a gzip header is
  7250  //    looked for to determine whether to copy or decompress.  Returns -1 on error,
  7251  //    otherwise 0.  gz_fetch() will leave state->how as COPY or GZIP unless the
  7252  //    end of the input file has been reached and all data has been processed.
  7253  func gz_fetch(tls *libc.TLS, state Gz_statep) int32 { /* gzread.c:229:11: */
  7254  	var strm Z_streamp = state + 120
  7255  
  7256  	for ok := true; ok; ok = (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave == uint32(0) && (!((*Gz_state)(unsafe.Pointer(state)).Feof != 0) || (*Z_stream)(unsafe.Pointer(strm)).Favail_in != 0) {
  7257  		switch (*Gz_state)(unsafe.Pointer(state)).Fhow {
  7258  		case LOOK: // -> LOOK, COPY (only if never GZIP), or GZIP
  7259  			if gz_look(tls, state) == -1 {
  7260  				return -1
  7261  			}
  7262  			if (*Gz_state)(unsafe.Pointer(state)).Fhow == LOOK {
  7263  				return 0
  7264  			}
  7265  			break
  7266  		case COPY1: // -> COPY
  7267  			if gz_load(tls, state, (*Gz_state)(unsafe.Pointer(state)).Fout, (*Gz_state)(unsafe.Pointer(state)).Fsize<<1, state) ==
  7268  				-1 {
  7269  				return -1
  7270  			}
  7271  			(*Gz_state)(unsafe.Pointer(state)).Fx.Fnext = (*Gz_state)(unsafe.Pointer(state)).Fout
  7272  			return 0
  7273  		case /* GZIP */ 2: // -> GZIP or LOOK (if end of gzip stream)
  7274  			(*Z_stream)(unsafe.Pointer(strm)).Favail_out = (*Gz_state)(unsafe.Pointer(state)).Fsize << 1
  7275  			(*Z_stream)(unsafe.Pointer(strm)).Fnext_out = (*Gz_state)(unsafe.Pointer(state)).Fout
  7276  			if gz_decomp(tls, state) == -1 {
  7277  				return -1
  7278  			}
  7279  		}
  7280  	}
  7281  	return 0
  7282  }
  7283  
  7284  // Skip len uncompressed bytes of output.  Return -1 on error, 0 on success.
  7285  func gz_skip(tls *libc.TLS, state Gz_statep, len Off_t) int32 { /* gzread.c:259:11: */
  7286  	var n uint32
  7287  
  7288  	// skip over len bytes or reach end-of-file, whichever comes first
  7289  	for len != 0 {
  7290  		// skip over whatever is in output buffer
  7291  		if (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave != 0 {
  7292  			if uint64(unsafe.Sizeof(int32(0))) == uint64(unsafe.Sizeof(Off_t(0))) && (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave > uint32(INT_MAX) || Off_t((*Gz_state)(unsafe.Pointer(state)).Fx.Fhave) > len {
  7293  				n = uint32(len)
  7294  			} else {
  7295  				n = (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave
  7296  			}
  7297  			*(*uint32)(unsafe.Pointer(state)) -= n
  7298  			*(*uintptr)(unsafe.Pointer(state + 8)) += uintptr(n)
  7299  			*(*Off_t)(unsafe.Pointer(state + 16)) += Off_t(n)
  7300  			len = len - Off_t(n)
  7301  		} else if (*Gz_state)(unsafe.Pointer(state)).Feof != 0 && (*Gz_state)(unsafe.Pointer(state)).Fstrm.Favail_in == UInt(0) {
  7302  			break
  7303  		} else {
  7304  			// get more output, looking for header if required
  7305  			if gz_fetch(tls, state) == -1 {
  7306  				return -1
  7307  			}
  7308  		}
  7309  	}
  7310  	return 0
  7311  }
  7312  
  7313  // Read len bytes into buf from file, or less than len up to the end of the
  7314  //    input.  Return the number of bytes read.  If zero is returned, either the
  7315  //    end of file was reached, or there was an error.  state->err must be
  7316  //    consulted in that case to determine which.
  7317  func gz_read(tls *libc.TLS, state Gz_statep, buf Voidp, len Z_size_t) Z_size_t { /* gzread.c:294:16: */
  7318  	bp := tls.Alloc(4)
  7319  	defer tls.Free(4)
  7320  
  7321  	var got Z_size_t
  7322  	// var n uint32 at bp, 4
  7323  
  7324  	// if len is zero, avoid unnecessary operations
  7325  	if len == uint64(0) {
  7326  		return uint64(0)
  7327  	}
  7328  
  7329  	// process a skip request
  7330  	if (*Gz_state)(unsafe.Pointer(state)).Fseek != 0 {
  7331  		(*Gz_state)(unsafe.Pointer(state)).Fseek = 0
  7332  		if gz_skip(tls, state, (*Gz_state)(unsafe.Pointer(state)).Fskip) == -1 {
  7333  			return uint64(0)
  7334  		}
  7335  	}
  7336  
  7337  	// get len bytes to buf, or less than len if at the end
  7338  	got = uint64(0)
  7339  	for ok := true; ok; ok = len != 0 {
  7340  		// set n to the maximum amount of len that fits in an unsigned int
  7341  		*(*uint32)(unsafe.Pointer(bp /* n */)) = libc.Uint32FromInt32(-1)
  7342  		if Z_size_t(*(*uint32)(unsafe.Pointer(bp))) > len {
  7343  			*(*uint32)(unsafe.Pointer(bp /* n */)) = uint32(len)
  7344  		}
  7345  
  7346  		// first just try copying data from the output buffer
  7347  		if (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave != 0 {
  7348  			if (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave < *(*uint32)(unsafe.Pointer(bp)) {
  7349  				*(*uint32)(unsafe.Pointer(bp /* n */)) = (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave
  7350  			}
  7351  			libc.Xmemcpy(tls, buf, (*Gz_state)(unsafe.Pointer(state)).Fx.Fnext, uint64(*(*uint32)(unsafe.Pointer(bp /* n */))))
  7352  			*(*uintptr)(unsafe.Pointer(state + 8)) += uintptr(*(*uint32)(unsafe.Pointer(bp)))
  7353  			*(*uint32)(unsafe.Pointer(state)) -= *(*uint32)(unsafe.Pointer(bp))
  7354  		} else if (*Gz_state)(unsafe.Pointer(state)).Feof != 0 && (*Gz_state)(unsafe.Pointer(state)).Fstrm.Favail_in == UInt(0) {
  7355  			(*Gz_state)(unsafe.Pointer(state)).Fpast = 1 // tried to read past end
  7356  			break
  7357  		} else if (*Gz_state)(unsafe.Pointer(state)).Fhow == LOOK || *(*uint32)(unsafe.Pointer(bp)) < (*Gz_state)(unsafe.Pointer(state)).Fsize<<1 {
  7358  			// get more output, looking for header if required
  7359  			if gz_fetch(tls, state) == -1 {
  7360  				return uint64(0)
  7361  			}
  7362  			continue // no progress yet -- go back to copy above
  7363  			// the copy above assures that we will leave with space in the
  7364  			//                output buffer, allowing at least one gzungetc() to succeed
  7365  		} else if (*Gz_state)(unsafe.Pointer(state)).Fhow == COPY1 { // read directly
  7366  			if gz_load(tls, state, buf, *(*uint32)(unsafe.Pointer(bp)), bp) == -1 {
  7367  				return uint64(0)
  7368  			}
  7369  		} else { // state->how == GZIP
  7370  			(*Gz_state)(unsafe.Pointer(state)).Fstrm.Favail_out = *(*uint32)(unsafe.Pointer(bp /* n */))
  7371  			(*Gz_state)(unsafe.Pointer(state)).Fstrm.Fnext_out = buf
  7372  			if gz_decomp(tls, state) == -1 {
  7373  				return uint64(0)
  7374  			}
  7375  			*(*uint32)(unsafe.Pointer(bp /* n */)) = (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave
  7376  			(*Gz_state)(unsafe.Pointer(state)).Fx.Fhave = uint32(0)
  7377  		}
  7378  
  7379  		// update progress
  7380  		len = len - Z_size_t(*(*uint32)(unsafe.Pointer(bp)))
  7381  		buf = buf + uintptr(*(*uint32)(unsafe.Pointer(bp)))
  7382  		got = got + Z_size_t(*(*uint32)(unsafe.Pointer(bp)))
  7383  		*(*Off_t)(unsafe.Pointer(state + 16)) += Off_t(*(*uint32)(unsafe.Pointer(bp)))
  7384  	}
  7385  
  7386  	// return number of bytes read into user buffer
  7387  	return got
  7388  }
  7389  
  7390  // -- see zlib.h --
  7391  func Xgzread(tls *libc.TLS, file GzFile, buf Voidp, len uint32) int32 { /* gzread.c:375:13: */
  7392  	var state Gz_statep
  7393  
  7394  	// get internal structure
  7395  	if file == uintptr(0) {
  7396  		return -1
  7397  	}
  7398  	state = file
  7399  
  7400  	// check that we're reading and that there's no (serious) error
  7401  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ || (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK && (*Gz_state)(unsafe.Pointer(state)).Ferr != -5 {
  7402  		return -1
  7403  	}
  7404  
  7405  	// since an int is returned, make sure len fits in one, otherwise return
  7406  	//        with an error (this avoids a flaw in the interface)
  7407  	if int32(len) < 0 {
  7408  		Xgz_error(tls, state, -2, ts+196)
  7409  		return -1
  7410  	}
  7411  
  7412  	// read len or fewer bytes to buf
  7413  	len = uint32(gz_read(tls, state, buf, uint64(len)))
  7414  
  7415  	// check for an error
  7416  	if len == uint32(0) && (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK && (*Gz_state)(unsafe.Pointer(state)).Ferr != -5 {
  7417  		return -1
  7418  	}
  7419  
  7420  	// return the number of bytes read (this is assured to fit in an int)
  7421  	return int32(len)
  7422  }
  7423  
  7424  // -- see zlib.h --
  7425  func Xgzfread(tls *libc.TLS, buf Voidp, size Z_size_t, nitems Z_size_t, file GzFile) Z_size_t { /* gzread.c:411:18: */
  7426  	var len Z_size_t
  7427  	var state Gz_statep
  7428  
  7429  	// get internal structure
  7430  	if file == uintptr(0) {
  7431  		return uint64(0)
  7432  	}
  7433  	state = file
  7434  
  7435  	// check that we're reading and that there's no (serious) error
  7436  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ || (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK && (*Gz_state)(unsafe.Pointer(state)).Ferr != -5 {
  7437  		return uint64(0)
  7438  	}
  7439  
  7440  	// compute bytes to read -- error on overflow
  7441  	len = nitems * size
  7442  	if size != 0 && len/size != nitems {
  7443  		Xgz_error(tls, state, -2, ts+227)
  7444  		return uint64(0)
  7445  	}
  7446  
  7447  	// read len or fewer bytes to buf, return the number of full items read
  7448  	if len != 0 {
  7449  		return gz_read(tls, state, buf, len) / size
  7450  	}
  7451  	return uint64(0)
  7452  }
  7453  
  7454  // -- see zlib.h --
  7455  func Xgzgetc(tls *libc.TLS, file GzFile) int32 { /* gzread.c:447:13: */
  7456  	bp := tls.Alloc(1)
  7457  	defer tls.Free(1)
  7458  
  7459  	var ret int32
  7460  	// var buf [1]uint8 at bp, 1
  7461  
  7462  	var state Gz_statep
  7463  
  7464  	// get internal structure
  7465  	if file == uintptr(0) {
  7466  		return -1
  7467  	}
  7468  	state = file
  7469  
  7470  	// check that we're reading and that there's no (serious) error
  7471  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ || (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK && (*Gz_state)(unsafe.Pointer(state)).Ferr != -5 {
  7472  		return -1
  7473  	}
  7474  
  7475  	// try output buffer (no need to check for skip request)
  7476  	if (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave != 0 {
  7477  		(*Gz_state)(unsafe.Pointer(state)).Fx.Fhave--
  7478  		(*Gz_state)(unsafe.Pointer(state)).Fx.Fpos++
  7479  		return int32(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&(*Gz_state)(unsafe.Pointer(state)).Fx.Fnext, 1))))
  7480  	}
  7481  
  7482  	// nothing there -- try gz_read()
  7483  	ret = int32(gz_read(tls, state, bp, uint64(1)))
  7484  	if ret < 1 {
  7485  		return -1
  7486  	}
  7487  	return int32(*(*uint8)(unsafe.Pointer(bp)))
  7488  }
  7489  
  7490  func Xgzgetc_(tls *libc.TLS, file GzFile) int32 { /* gzread.c:476:13: */
  7491  	return Xgzgetc(tls, file)
  7492  }
  7493  
  7494  // -- see zlib.h --
  7495  func Xgzungetc(tls *libc.TLS, c int32, file GzFile) int32 { /* gzread.c:483:13: */
  7496  	var state Gz_statep
  7497  
  7498  	// get internal structure
  7499  	if file == uintptr(0) {
  7500  		return -1
  7501  	}
  7502  	state = file
  7503  
  7504  	// check that we're reading and that there's no (serious) error
  7505  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ || (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK && (*Gz_state)(unsafe.Pointer(state)).Ferr != -5 {
  7506  		return -1
  7507  	}
  7508  
  7509  	// process a skip request
  7510  	if (*Gz_state)(unsafe.Pointer(state)).Fseek != 0 {
  7511  		(*Gz_state)(unsafe.Pointer(state)).Fseek = 0
  7512  		if gz_skip(tls, state, (*Gz_state)(unsafe.Pointer(state)).Fskip) == -1 {
  7513  			return -1
  7514  		}
  7515  	}
  7516  
  7517  	// can't push EOF
  7518  	if c < 0 {
  7519  		return -1
  7520  	}
  7521  
  7522  	// if output buffer empty, put byte at end (allows more pushing)
  7523  	if (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave == uint32(0) {
  7524  		(*Gz_state)(unsafe.Pointer(state)).Fx.Fhave = uint32(1)
  7525  		(*Gz_state)(unsafe.Pointer(state)).Fx.Fnext = (*Gz_state)(unsafe.Pointer(state)).Fout + uintptr((*Gz_state)(unsafe.Pointer(state)).Fsize<<1) - uintptr(1)
  7526  		*(*uint8)(unsafe.Pointer((*Gz_state)(unsafe.Pointer(state)).Fx.Fnext)) = uint8(c)
  7527  		(*Gz_state)(unsafe.Pointer(state)).Fx.Fpos--
  7528  		(*Gz_state)(unsafe.Pointer(state)).Fpast = 0
  7529  		return c
  7530  	}
  7531  
  7532  	// if no room, give up (must have already done a gzungetc())
  7533  	if (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave == (*Gz_state)(unsafe.Pointer(state)).Fsize<<1 {
  7534  		Xgz_error(tls, state, -3, ts+260)
  7535  		return -1
  7536  	}
  7537  
  7538  	// slide output data if needed and insert byte before existing data
  7539  	if (*Gz_state)(unsafe.Pointer(state)).Fx.Fnext == (*Gz_state)(unsafe.Pointer(state)).Fout {
  7540  		var src uintptr = (*Gz_state)(unsafe.Pointer(state)).Fout + uintptr((*Gz_state)(unsafe.Pointer(state)).Fx.Fhave)
  7541  		var dest uintptr = (*Gz_state)(unsafe.Pointer(state)).Fout + uintptr((*Gz_state)(unsafe.Pointer(state)).Fsize<<1)
  7542  		for src > (*Gz_state)(unsafe.Pointer(state)).Fout {
  7543  			*(*uint8)(unsafe.Pointer(libc.PreDecUintptr(&dest, 1))) = *(*uint8)(unsafe.Pointer(libc.PreDecUintptr(&src, 1)))
  7544  		}
  7545  		(*Gz_state)(unsafe.Pointer(state)).Fx.Fnext = dest
  7546  	}
  7547  	(*Gz_state)(unsafe.Pointer(state)).Fx.Fhave++
  7548  	(*Gz_state)(unsafe.Pointer(state)).Fx.Fnext--
  7549  	*(*uint8)(unsafe.Pointer((*Gz_state)(unsafe.Pointer(state)).Fx.Fnext)) = uint8(c)
  7550  	(*Gz_state)(unsafe.Pointer(state)).Fx.Fpos--
  7551  	(*Gz_state)(unsafe.Pointer(state)).Fpast = 0
  7552  	return c
  7553  }
  7554  
  7555  // -- see zlib.h --
  7556  func Xgzgets(tls *libc.TLS, file GzFile, buf uintptr, len int32) uintptr { /* gzread.c:543:6: */
  7557  	var left uint32
  7558  	var n uint32
  7559  	var str uintptr
  7560  	var eol uintptr
  7561  	var state Gz_statep
  7562  
  7563  	// check parameters and get internal structure
  7564  	if file == uintptr(0) || buf == uintptr(0) || len < 1 {
  7565  		return uintptr(0)
  7566  	}
  7567  	state = file
  7568  
  7569  	// check that we're reading and that there's no (serious) error
  7570  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ || (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK && (*Gz_state)(unsafe.Pointer(state)).Ferr != -5 {
  7571  		return uintptr(0)
  7572  	}
  7573  
  7574  	// process a skip request
  7575  	if (*Gz_state)(unsafe.Pointer(state)).Fseek != 0 {
  7576  		(*Gz_state)(unsafe.Pointer(state)).Fseek = 0
  7577  		if gz_skip(tls, state, (*Gz_state)(unsafe.Pointer(state)).Fskip) == -1 {
  7578  			return uintptr(0)
  7579  		}
  7580  	}
  7581  
  7582  	// copy output bytes up to new line or len - 1, whichever comes first --
  7583  	//        append a terminating zero to the string (we don't check for a zero in
  7584  	//        the contents, let the user worry about that)
  7585  	str = buf
  7586  	left = uint32(len) - uint32(1)
  7587  	if left != 0 {
  7588  		for ok := true; ok; ok = left != 0 && eol == uintptr(0) {
  7589  			// assure that something is in the output buffer
  7590  			if (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave == uint32(0) && gz_fetch(tls, state) == -1 {
  7591  				return uintptr(0)
  7592  			} // error
  7593  			if (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave == uint32(0) { // end of file
  7594  				(*Gz_state)(unsafe.Pointer(state)).Fpast = 1 // read past end
  7595  				break                                        // return what we have
  7596  			}
  7597  
  7598  			// look for end-of-line in current output buffer
  7599  			if (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave > left {
  7600  				n = left
  7601  			} else {
  7602  				n = (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave
  7603  			}
  7604  			eol = libc.Xmemchr(tls, (*Gz_state)(unsafe.Pointer(state)).Fx.Fnext, '\n', uint64(n))
  7605  			if eol != uintptr(0) {
  7606  				n = uint32((int64(eol)-int64((*Gz_state)(unsafe.Pointer(state)).Fx.Fnext))/1) + uint32(1)
  7607  			}
  7608  
  7609  			// copy through end-of-line, or remainder if not found
  7610  			libc.Xmemcpy(tls, buf, (*Gz_state)(unsafe.Pointer(state)).Fx.Fnext, uint64(n))
  7611  			*(*uint32)(unsafe.Pointer(state)) -= n
  7612  			*(*uintptr)(unsafe.Pointer(state + 8)) += uintptr(n)
  7613  			*(*Off_t)(unsafe.Pointer(state + 16)) += Off_t(n)
  7614  			left = left - n
  7615  			buf += uintptr(n)
  7616  		}
  7617  	}
  7618  
  7619  	// return terminated string, or if nothing, end of file
  7620  	if buf == str {
  7621  		return uintptr(0)
  7622  	}
  7623  	*(*int8)(unsafe.Pointer(buf)) = int8(0)
  7624  	return str
  7625  }
  7626  
  7627  // -- see zlib.h --
  7628  func Xgzdirect(tls *libc.TLS, file GzFile) int32 { /* gzread.c:607:13: */
  7629  	var state Gz_statep
  7630  
  7631  	// get internal structure
  7632  	if file == uintptr(0) {
  7633  		return 0
  7634  	}
  7635  	state = file
  7636  
  7637  	// if the state is not known, but we can find out, then do so (this is
  7638  	//        mainly for right after a gzopen() or gzdopen())
  7639  	if (*Gz_state)(unsafe.Pointer(state)).Fmode == GZ_READ && (*Gz_state)(unsafe.Pointer(state)).Fhow == LOOK && (*Gz_state)(unsafe.Pointer(state)).Fx.Fhave == uint32(0) {
  7640  		gz_look(tls, state)
  7641  	}
  7642  
  7643  	// return 1 if transparent, 0 if processing a gzip stream
  7644  	return (*Gz_state)(unsafe.Pointer(state)).Fdirect
  7645  }
  7646  
  7647  // -- see zlib.h --
  7648  func Xgzclose_r(tls *libc.TLS, file GzFile) int32 { /* gzread.c:627:13: */
  7649  	var ret int32
  7650  	var err int32
  7651  	var state Gz_statep
  7652  
  7653  	// get internal structure
  7654  	if file == uintptr(0) {
  7655  		return -2
  7656  	}
  7657  	state = file
  7658  
  7659  	// check that we're reading
  7660  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_READ {
  7661  		return -2
  7662  	}
  7663  
  7664  	// free memory and close file
  7665  	if (*Gz_state)(unsafe.Pointer(state)).Fsize != 0 {
  7666  		XinflateEnd(tls, state+120)
  7667  		libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fout)
  7668  		libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fin)
  7669  	}
  7670  	if (*Gz_state)(unsafe.Pointer(state)).Ferr == -5 {
  7671  		err = -5
  7672  	} else {
  7673  		err = Z_OK
  7674  	}
  7675  	Xgz_error(tls, state, Z_OK, uintptr(0))
  7676  	libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fpath)
  7677  	ret = libc.Xclose(tls, (*Gz_state)(unsafe.Pointer(state)).Ffd)
  7678  	libc.Xfree(tls, state)
  7679  	if ret != 0 {
  7680  		return -1
  7681  	}
  7682  	return err
  7683  }
  7684  
  7685  // Initialize state for writing a gzip file.  Mark initialization by setting
  7686  //    state->size to non-zero.  Return -1 on a memory allocation failure, or 0 on
  7687  //    success.
  7688  func gz_init(tls *libc.TLS, state Gz_statep) int32 { /* gzwrite.c:17:11: */
  7689  	var ret int32
  7690  	var strm Z_streamp = state + 120
  7691  
  7692  	// allocate input buffer (double size for gzprintf)
  7693  	(*Gz_state)(unsafe.Pointer(state)).Fin = libc.Xmalloc(tls, uint64((*Gz_state)(unsafe.Pointer(state)).Fwant<<1))
  7694  	if (*Gz_state)(unsafe.Pointer(state)).Fin == uintptr(0) {
  7695  		Xgz_error(tls, state, -4, ts+87)
  7696  		return -1
  7697  	}
  7698  
  7699  	// only need output buffer and deflate state if compressing
  7700  	if !((*Gz_state)(unsafe.Pointer(state)).Fdirect != 0) {
  7701  		// allocate output buffer
  7702  		(*Gz_state)(unsafe.Pointer(state)).Fout = libc.Xmalloc(tls, uint64((*Gz_state)(unsafe.Pointer(state)).Fwant))
  7703  		if (*Gz_state)(unsafe.Pointer(state)).Fout == uintptr(0) {
  7704  			libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fin)
  7705  			Xgz_error(tls, state, -4, ts+87)
  7706  			return -1
  7707  		}
  7708  
  7709  		// allocate deflate memory, set up for gzip compression
  7710  		(*Z_stream)(unsafe.Pointer(strm)).Fzalloc = Alloc_func(Z_NULL)
  7711  		(*Z_stream)(unsafe.Pointer(strm)).Fzfree = Free_func(Z_NULL)
  7712  		(*Z_stream)(unsafe.Pointer(strm)).Fopaque = Voidpf(Z_NULL)
  7713  		ret = XdeflateInit2_(tls, strm, (*Gz_state)(unsafe.Pointer(state)).Flevel, Z_DEFLATED, MAX_WBITS+16, DEF_MEM_LEVEL, (*Gz_state)(unsafe.Pointer(state)).Fstrategy, ts, int32(unsafe.Sizeof(Z_stream{})))
  7714  		if ret != Z_OK {
  7715  			libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fout)
  7716  			libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fin)
  7717  			Xgz_error(tls, state, -4, ts+87)
  7718  			return -1
  7719  		}
  7720  		(*Z_stream)(unsafe.Pointer(strm)).Fnext_in = uintptr(0)
  7721  	}
  7722  
  7723  	// mark state as initialized
  7724  	(*Gz_state)(unsafe.Pointer(state)).Fsize = (*Gz_state)(unsafe.Pointer(state)).Fwant
  7725  
  7726  	// initialize write buffer if compressing
  7727  	if !((*Gz_state)(unsafe.Pointer(state)).Fdirect != 0) {
  7728  		(*Z_stream)(unsafe.Pointer(strm)).Favail_out = (*Gz_state)(unsafe.Pointer(state)).Fsize
  7729  		(*Z_stream)(unsafe.Pointer(strm)).Fnext_out = (*Gz_state)(unsafe.Pointer(state)).Fout
  7730  		(*Gz_state)(unsafe.Pointer(state)).Fx.Fnext = (*Z_stream)(unsafe.Pointer(strm)).Fnext_out
  7731  	}
  7732  	return 0
  7733  }
  7734  
  7735  // Compress whatever is at avail_in and next_in and write to the output file.
  7736  //    Return -1 if there is an error writing to the output file or if gz_init()
  7737  //    fails to allocate memory, otherwise 0.  flush is assumed to be a valid
  7738  //    deflate() flush value.  If flush is Z_FINISH, then the deflate() state is
  7739  //    reset to start a new gzip stream.  If gz->direct is true, then simply write
  7740  //    to the output file without compressing, and ignore flush.
  7741  func gz_comp(tls *libc.TLS, state Gz_statep, flush int32) int32 { /* gzwrite.c:73:11: */
  7742  	var ret int32
  7743  	var writ int32
  7744  	var have uint32
  7745  	var put uint32
  7746  	var max uint32 = uint32(libc.Uint32(libc.Uint32FromInt32(-1)))>>2 + uint32(1)
  7747  	var strm Z_streamp = state + 120
  7748  
  7749  	// allocate memory if this is the first time through
  7750  	if (*Gz_state)(unsafe.Pointer(state)).Fsize == uint32(0) && gz_init(tls, state) == -1 {
  7751  		return -1
  7752  	}
  7753  
  7754  	// write directly if requested
  7755  	if (*Gz_state)(unsafe.Pointer(state)).Fdirect != 0 {
  7756  		for (*Z_stream)(unsafe.Pointer(strm)).Favail_in != 0 {
  7757  			if (*Z_stream)(unsafe.Pointer(strm)).Favail_in > max {
  7758  				put = max
  7759  			} else {
  7760  				put = (*Z_stream)(unsafe.Pointer(strm)).Favail_in
  7761  			}
  7762  			writ = int32(libc.Xwrite(tls, (*Gz_state)(unsafe.Pointer(state)).Ffd, (*Z_stream)(unsafe.Pointer(strm)).Fnext_in, uint64(put)))
  7763  			if writ < 0 {
  7764  				Xgz_error(tls, state, -1, libc.Xstrerror(tls, *(*int32)(unsafe.Pointer(libc.X__errno(tls)))))
  7765  				return -1
  7766  			}
  7767  			*(*UInt)(unsafe.Pointer(strm + 8)) -= uint32(writ)
  7768  			*(*uintptr)(unsafe.Pointer(strm)) += uintptr(writ)
  7769  		}
  7770  		return 0
  7771  	}
  7772  
  7773  	// run deflate() on provided input until it produces no more output
  7774  	ret = Z_OK
  7775  	for ok := true; ok; ok = have != 0 {
  7776  		// write out current buffer contents if full, or if flushing, but if
  7777  		//            doing Z_FINISH then don't write until we get to Z_STREAM_END
  7778  		if (*Z_stream)(unsafe.Pointer(strm)).Favail_out == UInt(0) || flush != Z_NO_FLUSH && (flush != Z_FINISH || ret == Z_STREAM_END) {
  7779  			for (*Z_stream)(unsafe.Pointer(strm)).Fnext_out > (*Gz_state)(unsafe.Pointer(state)).Fx.Fnext {
  7780  				if (int64((*Z_stream)(unsafe.Pointer(strm)).Fnext_out)-int64((*Gz_state)(unsafe.Pointer(state)).Fx.Fnext))/1 > int64(int32(max)) {
  7781  					put = max
  7782  				} else {
  7783  					put = uint32((int64((*Z_stream)(unsafe.Pointer(strm)).Fnext_out) - int64((*Gz_state)(unsafe.Pointer(state)).Fx.Fnext)) / 1)
  7784  				}
  7785  				writ = int32(libc.Xwrite(tls, (*Gz_state)(unsafe.Pointer(state)).Ffd, (*Gz_state)(unsafe.Pointer(state)).Fx.Fnext, uint64(put)))
  7786  				if writ < 0 {
  7787  					Xgz_error(tls, state, -1, libc.Xstrerror(tls, *(*int32)(unsafe.Pointer(libc.X__errno(tls)))))
  7788  					return -1
  7789  				}
  7790  				*(*uintptr)(unsafe.Pointer(state + 8)) += uintptr(writ)
  7791  			}
  7792  			if (*Z_stream)(unsafe.Pointer(strm)).Favail_out == UInt(0) {
  7793  				(*Z_stream)(unsafe.Pointer(strm)).Favail_out = (*Gz_state)(unsafe.Pointer(state)).Fsize
  7794  				(*Z_stream)(unsafe.Pointer(strm)).Fnext_out = (*Gz_state)(unsafe.Pointer(state)).Fout
  7795  				(*Gz_state)(unsafe.Pointer(state)).Fx.Fnext = (*Gz_state)(unsafe.Pointer(state)).Fout
  7796  			}
  7797  		}
  7798  
  7799  		// compress
  7800  		have = (*Z_stream)(unsafe.Pointer(strm)).Favail_out
  7801  		ret = Xdeflate(tls, strm, flush)
  7802  		if ret == -2 {
  7803  			Xgz_error(tls, state, -2,
  7804  				ts+291)
  7805  			return -1
  7806  		}
  7807  		have = have - (*Z_stream)(unsafe.Pointer(strm)).Favail_out
  7808  	}
  7809  
  7810  	// if that completed a deflate stream, allow another to start
  7811  	if flush == Z_FINISH {
  7812  		XdeflateReset(tls, strm)
  7813  	}
  7814  
  7815  	// all done, no errors
  7816  	return 0
  7817  }
  7818  
  7819  // Compress len zeros to output.  Return -1 on a write error or memory
  7820  //    allocation failure by gz_comp(), or 0 on success.
  7821  func gz_zero(tls *libc.TLS, state Gz_statep, len Off_t) int32 { /* gzwrite.c:145:11: */
  7822  	var first int32
  7823  	var n uint32
  7824  	var strm Z_streamp = state + 120
  7825  
  7826  	// consume whatever's left in the input buffer
  7827  	if (*Z_stream)(unsafe.Pointer(strm)).Favail_in != 0 && gz_comp(tls, state, Z_NO_FLUSH) == -1 {
  7828  		return -1
  7829  	}
  7830  
  7831  	// compress len zeros (len guaranteed > 0)
  7832  	first = 1
  7833  	for len != 0 {
  7834  		if uint64(unsafe.Sizeof(int32(0))) == uint64(unsafe.Sizeof(Off_t(0))) && (*Gz_state)(unsafe.Pointer(state)).Fsize > uint32(INT_MAX) || Off_t((*Gz_state)(unsafe.Pointer(state)).Fsize) > len {
  7835  			n = uint32(len)
  7836  		} else {
  7837  			n = (*Gz_state)(unsafe.Pointer(state)).Fsize
  7838  		}
  7839  		if first != 0 {
  7840  			libc.Xmemset(tls, (*Gz_state)(unsafe.Pointer(state)).Fin, 0, uint64(n))
  7841  			first = 0
  7842  		}
  7843  		(*Z_stream)(unsafe.Pointer(strm)).Favail_in = n
  7844  		(*Z_stream)(unsafe.Pointer(strm)).Fnext_in = (*Gz_state)(unsafe.Pointer(state)).Fin
  7845  		*(*Off_t)(unsafe.Pointer(state + 16)) += Off_t(n)
  7846  		if gz_comp(tls, state, Z_NO_FLUSH) == -1 {
  7847  			return -1
  7848  		}
  7849  		len = len - Off_t(n)
  7850  	}
  7851  	return 0
  7852  }
  7853  
  7854  // Write len bytes from buf to file.  Return the number of bytes written.  If
  7855  //    the returned value is less than len, then there was an error.
  7856  func gz_write(tls *libc.TLS, state Gz_statep, buf Voidpc, len Z_size_t) Z_size_t { /* gzwrite.c:178:16: */
  7857  	var put Z_size_t = len
  7858  
  7859  	// if len is zero, avoid unnecessary operations
  7860  	if len == uint64(0) {
  7861  		return uint64(0)
  7862  	}
  7863  
  7864  	// allocate memory if this is the first time through
  7865  	if (*Gz_state)(unsafe.Pointer(state)).Fsize == uint32(0) && gz_init(tls, state) == -1 {
  7866  		return uint64(0)
  7867  	}
  7868  
  7869  	// check for seek request
  7870  	if (*Gz_state)(unsafe.Pointer(state)).Fseek != 0 {
  7871  		(*Gz_state)(unsafe.Pointer(state)).Fseek = 0
  7872  		if gz_zero(tls, state, (*Gz_state)(unsafe.Pointer(state)).Fskip) == -1 {
  7873  			return uint64(0)
  7874  		}
  7875  	}
  7876  
  7877  	// for small len, copy to input buffer, otherwise compress directly
  7878  	if len < Z_size_t((*Gz_state)(unsafe.Pointer(state)).Fsize) {
  7879  		// copy to input buffer, compress when full
  7880  		for ok := true; ok; ok = len != 0 {
  7881  			var have uint32
  7882  			var copy uint32
  7883  
  7884  			if (*Gz_state)(unsafe.Pointer(state)).Fstrm.Favail_in == UInt(0) {
  7885  				(*Gz_state)(unsafe.Pointer(state)).Fstrm.Fnext_in = (*Gz_state)(unsafe.Pointer(state)).Fin
  7886  			}
  7887  			have = uint32((int64((*Gz_state)(unsafe.Pointer(state)).Fstrm.Fnext_in+uintptr((*Gz_state)(unsafe.Pointer(state)).Fstrm.Favail_in)) - int64((*Gz_state)(unsafe.Pointer(state)).Fin)) / 1)
  7888  			copy = (*Gz_state)(unsafe.Pointer(state)).Fsize - have
  7889  			if Z_size_t(copy) > len {
  7890  				copy = uint32(len)
  7891  			}
  7892  			libc.Xmemcpy(tls, (*Gz_state)(unsafe.Pointer(state)).Fin+uintptr(have), buf, uint64(copy))
  7893  			*(*UInt)(unsafe.Pointer(state + 120 + 8)) += copy
  7894  			*(*Off_t)(unsafe.Pointer(state + 16)) += Off_t(copy)
  7895  			buf = buf + uintptr(copy)
  7896  			len = len - Z_size_t(copy)
  7897  			if len != 0 && gz_comp(tls, state, Z_NO_FLUSH) == -1 {
  7898  				return uint64(0)
  7899  			}
  7900  		}
  7901  	} else {
  7902  		// consume whatever's left in the input buffer
  7903  		if (*Gz_state)(unsafe.Pointer(state)).Fstrm.Favail_in != 0 && gz_comp(tls, state, Z_NO_FLUSH) == -1 {
  7904  			return uint64(0)
  7905  		}
  7906  
  7907  		// directly compress user buffer to file
  7908  		(*Gz_state)(unsafe.Pointer(state)).Fstrm.Fnext_in = buf
  7909  		for ok1 := true; ok1; ok1 = len != 0 {
  7910  			var n uint32 = libc.Uint32(libc.Uint32FromInt32(-1))
  7911  			if Z_size_t(n) > len {
  7912  				n = uint32(len)
  7913  			}
  7914  			(*Gz_state)(unsafe.Pointer(state)).Fstrm.Favail_in = n
  7915  			*(*Off_t)(unsafe.Pointer(state + 16)) += Off_t(n)
  7916  			if gz_comp(tls, state, Z_NO_FLUSH) == -1 {
  7917  				return uint64(0)
  7918  			}
  7919  			len = len - Z_size_t(n)
  7920  		}
  7921  	}
  7922  
  7923  	// input was all buffered or compressed
  7924  	return put
  7925  }
  7926  
  7927  // -- see zlib.h --
  7928  func Xgzwrite(tls *libc.TLS, file GzFile, buf Voidpc, len uint32) int32 { /* gzwrite.c:246:13: */
  7929  	var state Gz_statep
  7930  
  7931  	// get internal structure
  7932  	if file == uintptr(0) {
  7933  		return 0
  7934  	}
  7935  	state = file
  7936  
  7937  	// check that we're writing and that there's no error
  7938  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE || (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK {
  7939  		return 0
  7940  	}
  7941  
  7942  	// since an int is returned, make sure len fits in one, otherwise return
  7943  	//        with an error (this avoids a flaw in the interface)
  7944  	if int32(len) < 0 {
  7945  		Xgz_error(tls, state, -3, ts+330)
  7946  		return 0
  7947  	}
  7948  
  7949  	// write len bytes from buf (the return value will fit in an int)
  7950  	return int32(gz_write(tls, state, buf, uint64(len)))
  7951  }
  7952  
  7953  // -- see zlib.h --
  7954  func Xgzfwrite(tls *libc.TLS, buf Voidpc, size Z_size_t, nitems Z_size_t, file GzFile) Z_size_t { /* gzwrite.c:274:18: */
  7955  	var len Z_size_t
  7956  	var state Gz_statep
  7957  
  7958  	// get internal structure
  7959  	if file == uintptr(0) {
  7960  		return uint64(0)
  7961  	}
  7962  	state = file
  7963  
  7964  	// check that we're writing and that there's no error
  7965  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE || (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK {
  7966  		return uint64(0)
  7967  	}
  7968  
  7969  	// compute bytes to read -- error on overflow
  7970  	len = nitems * size
  7971  	if size != 0 && len/size != nitems {
  7972  		Xgz_error(tls, state, -2, ts+227)
  7973  		return uint64(0)
  7974  	}
  7975  
  7976  	// write len bytes to buf, return the number of full items written
  7977  	if len != 0 {
  7978  		return gz_write(tls, state, buf, len) / size
  7979  	}
  7980  	return uint64(0)
  7981  }
  7982  
  7983  // -- see zlib.h --
  7984  func Xgzputc(tls *libc.TLS, file GzFile, c int32) int32 { /* gzwrite.c:304:13: */
  7985  	bp := tls.Alloc(1)
  7986  	defer tls.Free(1)
  7987  
  7988  	var have uint32
  7989  	// var buf [1]uint8 at bp, 1
  7990  
  7991  	var state Gz_statep
  7992  	var strm Z_streamp
  7993  
  7994  	// get internal structure
  7995  	if file == uintptr(0) {
  7996  		return -1
  7997  	}
  7998  	state = file
  7999  	strm = state + 120
  8000  
  8001  	// check that we're writing and that there's no error
  8002  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE || (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK {
  8003  		return -1
  8004  	}
  8005  
  8006  	// check for seek request
  8007  	if (*Gz_state)(unsafe.Pointer(state)).Fseek != 0 {
  8008  		(*Gz_state)(unsafe.Pointer(state)).Fseek = 0
  8009  		if gz_zero(tls, state, (*Gz_state)(unsafe.Pointer(state)).Fskip) == -1 {
  8010  			return -1
  8011  		}
  8012  	}
  8013  
  8014  	// try writing to input buffer for speed (state->size == 0 if buffer not
  8015  	//        initialized)
  8016  	if (*Gz_state)(unsafe.Pointer(state)).Fsize != 0 {
  8017  		if (*Z_stream)(unsafe.Pointer(strm)).Favail_in == UInt(0) {
  8018  			(*Z_stream)(unsafe.Pointer(strm)).Fnext_in = (*Gz_state)(unsafe.Pointer(state)).Fin
  8019  		}
  8020  		have = uint32((int64((*Z_stream)(unsafe.Pointer(strm)).Fnext_in+uintptr((*Z_stream)(unsafe.Pointer(strm)).Favail_in)) - int64((*Gz_state)(unsafe.Pointer(state)).Fin)) / 1)
  8021  		if have < (*Gz_state)(unsafe.Pointer(state)).Fsize {
  8022  			*(*uint8)(unsafe.Pointer((*Gz_state)(unsafe.Pointer(state)).Fin + uintptr(have))) = uint8(c)
  8023  			(*Z_stream)(unsafe.Pointer(strm)).Favail_in++
  8024  			(*Gz_state)(unsafe.Pointer(state)).Fx.Fpos++
  8025  			return c & 0xff
  8026  		}
  8027  	}
  8028  
  8029  	// no room in buffer or not initialized, use gz_write()
  8030  	*(*uint8)(unsafe.Pointer(bp)) = uint8(c)
  8031  	if gz_write(tls, state, bp, uint64(1)) != uint64(1) {
  8032  		return -1
  8033  	}
  8034  	return c & 0xff
  8035  }
  8036  
  8037  // -- see zlib.h --
  8038  func Xgzputs(tls *libc.TLS, file GzFile, str uintptr) int32 { /* gzwrite.c:352:13: */
  8039  	var ret int32
  8040  	var len Z_size_t
  8041  	var state Gz_statep
  8042  
  8043  	// get internal structure
  8044  	if file == uintptr(0) {
  8045  		return -1
  8046  	}
  8047  	state = file
  8048  
  8049  	// check that we're writing and that there's no error
  8050  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE || (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK {
  8051  		return -1
  8052  	}
  8053  
  8054  	// write string
  8055  	len = libc.Xstrlen(tls, str)
  8056  	ret = int32(gz_write(tls, state, str, len))
  8057  	if ret == 0 && len != uint64(0) {
  8058  		return -1
  8059  	}
  8060  	return ret
  8061  }
  8062  
  8063  //	$OpenBSD: stdarg.h,v 1.10 2020/07/21 23:09:00 daniel Exp $
  8064  // Copyright (c) 2003, 2004  Marc espie <espie@openbsd.org>
  8065  //
  8066  // Permission to use, copy, modify, and distribute this software for any
  8067  // purpose with or without fee is hereby granted, provided that the above
  8068  // copyright notice and this permission notice appear in all copies.
  8069  //
  8070  // THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
  8071  // WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
  8072  // MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
  8073  // ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
  8074  // WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
  8075  // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
  8076  // OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  8077  
  8078  // -- see zlib.h --
  8079  func Xgzvprintf(tls *libc.TLS, file GzFile, format uintptr, va Va_list) int32 { /* gzwrite.c:379:15: */
  8080  	var len int32
  8081  	var left uint32
  8082  	var next uintptr
  8083  	var state Gz_statep
  8084  	var strm Z_streamp
  8085  
  8086  	// get internal structure
  8087  	if file == uintptr(0) {
  8088  		return -2
  8089  	}
  8090  	state = file
  8091  	strm = state + 120
  8092  
  8093  	// check that we're writing and that there's no error
  8094  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE || (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK {
  8095  		return -2
  8096  	}
  8097  
  8098  	// make sure we have some buffer space
  8099  	if (*Gz_state)(unsafe.Pointer(state)).Fsize == uint32(0) && gz_init(tls, state) == -1 {
  8100  		return (*Gz_state)(unsafe.Pointer(state)).Ferr
  8101  	}
  8102  
  8103  	// check for seek request
  8104  	if (*Gz_state)(unsafe.Pointer(state)).Fseek != 0 {
  8105  		(*Gz_state)(unsafe.Pointer(state)).Fseek = 0
  8106  		if gz_zero(tls, state, (*Gz_state)(unsafe.Pointer(state)).Fskip) == -1 {
  8107  			return (*Gz_state)(unsafe.Pointer(state)).Ferr
  8108  		}
  8109  	}
  8110  
  8111  	// do the printf() into the input buffer, put length in len -- the input
  8112  	//        buffer is double-sized just for this function, so there is guaranteed to
  8113  	//        be state->size bytes available after the current contents
  8114  	if (*Z_stream)(unsafe.Pointer(strm)).Favail_in == UInt(0) {
  8115  		(*Z_stream)(unsafe.Pointer(strm)).Fnext_in = (*Gz_state)(unsafe.Pointer(state)).Fin
  8116  	}
  8117  	next = (*Gz_state)(unsafe.Pointer(state)).Fin + uintptr((int64((*Z_stream)(unsafe.Pointer(strm)).Fnext_in)-int64((*Gz_state)(unsafe.Pointer(state)).Fin))/1) + uintptr((*Z_stream)(unsafe.Pointer(strm)).Favail_in)
  8118  	*(*int8)(unsafe.Pointer(next + uintptr((*Gz_state)(unsafe.Pointer(state)).Fsize-uint32(1)))) = int8(0)
  8119  	len = libc.Xvsnprintf(tls, next, uint64((*Gz_state)(unsafe.Pointer(state)).Fsize), format, va)
  8120  
  8121  	// check that printf() results fit in buffer
  8122  	if len == 0 || uint32(len) >= (*Gz_state)(unsafe.Pointer(state)).Fsize || int32(*(*int8)(unsafe.Pointer(next + uintptr((*Gz_state)(unsafe.Pointer(state)).Fsize-uint32(1))))) != 0 {
  8123  		return 0
  8124  	}
  8125  
  8126  	// update buffer and position, compress first half if past that
  8127  	*(*UInt)(unsafe.Pointer(strm + 8)) += uint32(len)
  8128  	*(*Off_t)(unsafe.Pointer(state + 16)) += Off_t(len)
  8129  	if (*Z_stream)(unsafe.Pointer(strm)).Favail_in >= (*Gz_state)(unsafe.Pointer(state)).Fsize {
  8130  		left = (*Z_stream)(unsafe.Pointer(strm)).Favail_in - (*Gz_state)(unsafe.Pointer(state)).Fsize
  8131  		(*Z_stream)(unsafe.Pointer(strm)).Favail_in = (*Gz_state)(unsafe.Pointer(state)).Fsize
  8132  		if gz_comp(tls, state, Z_NO_FLUSH) == -1 {
  8133  			return (*Gz_state)(unsafe.Pointer(state)).Ferr
  8134  		}
  8135  		libc.Xmemcpy(tls, (*Gz_state)(unsafe.Pointer(state)).Fin, (*Gz_state)(unsafe.Pointer(state)).Fin+uintptr((*Gz_state)(unsafe.Pointer(state)).Fsize), uint64(left))
  8136  		(*Z_stream)(unsafe.Pointer(strm)).Fnext_in = (*Gz_state)(unsafe.Pointer(state)).Fin
  8137  		(*Z_stream)(unsafe.Pointer(strm)).Favail_in = left
  8138  	}
  8139  	return len
  8140  }
  8141  
  8142  func Xgzprintf(tls *libc.TLS, file GzFile, format uintptr, va uintptr) int32 { /* gzwrite.c:451:15: */
  8143  	var va1 Va_list
  8144  	_ = va1
  8145  	var ret int32
  8146  
  8147  	va1 = va
  8148  	ret = Xgzvprintf(tls, file, format, va1)
  8149  	_ = va1
  8150  	return ret
  8151  }
  8152  
  8153  // -- see zlib.h --
  8154  func Xgzflush(tls *libc.TLS, file GzFile, flush int32) int32 { /* gzwrite.c:553:13: */
  8155  	var state Gz_statep
  8156  
  8157  	// get internal structure
  8158  	if file == uintptr(0) {
  8159  		return -2
  8160  	}
  8161  	state = file
  8162  
  8163  	// check that we're writing and that there's no error
  8164  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE || (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK {
  8165  		return -2
  8166  	}
  8167  
  8168  	// check flush parameter
  8169  	if flush < 0 || flush > Z_FINISH {
  8170  		return -2
  8171  	}
  8172  
  8173  	// check for seek request
  8174  	if (*Gz_state)(unsafe.Pointer(state)).Fseek != 0 {
  8175  		(*Gz_state)(unsafe.Pointer(state)).Fseek = 0
  8176  		if gz_zero(tls, state, (*Gz_state)(unsafe.Pointer(state)).Fskip) == -1 {
  8177  			return (*Gz_state)(unsafe.Pointer(state)).Ferr
  8178  		}
  8179  	}
  8180  
  8181  	// compress remaining data with requested flush
  8182  	gz_comp(tls, state, flush)
  8183  	return (*Gz_state)(unsafe.Pointer(state)).Ferr
  8184  }
  8185  
  8186  // -- see zlib.h --
  8187  func Xgzsetparams(tls *libc.TLS, file GzFile, level int32, strategy int32) int32 { /* gzwrite.c:585:13: */
  8188  	var state Gz_statep
  8189  	var strm Z_streamp
  8190  
  8191  	// get internal structure
  8192  	if file == uintptr(0) {
  8193  		return -2
  8194  	}
  8195  	state = file
  8196  	strm = state + 120
  8197  
  8198  	// check that we're writing and that there's no error
  8199  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE || (*Gz_state)(unsafe.Pointer(state)).Ferr != Z_OK {
  8200  		return -2
  8201  	}
  8202  
  8203  	// if no change is requested, then do nothing
  8204  	if level == (*Gz_state)(unsafe.Pointer(state)).Flevel && strategy == (*Gz_state)(unsafe.Pointer(state)).Fstrategy {
  8205  		return Z_OK
  8206  	}
  8207  
  8208  	// check for seek request
  8209  	if (*Gz_state)(unsafe.Pointer(state)).Fseek != 0 {
  8210  		(*Gz_state)(unsafe.Pointer(state)).Fseek = 0
  8211  		if gz_zero(tls, state, (*Gz_state)(unsafe.Pointer(state)).Fskip) == -1 {
  8212  			return (*Gz_state)(unsafe.Pointer(state)).Ferr
  8213  		}
  8214  	}
  8215  
  8216  	// change compression parameters for subsequent input
  8217  	if (*Gz_state)(unsafe.Pointer(state)).Fsize != 0 {
  8218  		// flush previous input with previous parameters before changing
  8219  		if (*Z_stream)(unsafe.Pointer(strm)).Favail_in != 0 && gz_comp(tls, state, Z_BLOCK) == -1 {
  8220  			return (*Gz_state)(unsafe.Pointer(state)).Ferr
  8221  		}
  8222  		XdeflateParams(tls, strm, level, strategy)
  8223  	}
  8224  	(*Gz_state)(unsafe.Pointer(state)).Flevel = level
  8225  	(*Gz_state)(unsafe.Pointer(state)).Fstrategy = strategy
  8226  	return Z_OK
  8227  }
  8228  
  8229  // -- see zlib.h --
  8230  func Xgzclose_w(tls *libc.TLS, file GzFile) int32 { /* gzwrite.c:627:13: */
  8231  	var ret int32 = Z_OK
  8232  	var state Gz_statep
  8233  
  8234  	// get internal structure
  8235  	if file == uintptr(0) {
  8236  		return -2
  8237  	}
  8238  	state = file
  8239  
  8240  	// check that we're writing
  8241  	if (*Gz_state)(unsafe.Pointer(state)).Fmode != GZ_WRITE {
  8242  		return -2
  8243  	}
  8244  
  8245  	// check for seek request
  8246  	if (*Gz_state)(unsafe.Pointer(state)).Fseek != 0 {
  8247  		(*Gz_state)(unsafe.Pointer(state)).Fseek = 0
  8248  		if gz_zero(tls, state, (*Gz_state)(unsafe.Pointer(state)).Fskip) == -1 {
  8249  			ret = (*Gz_state)(unsafe.Pointer(state)).Ferr
  8250  		}
  8251  	}
  8252  
  8253  	// flush, free memory, and close file
  8254  	if gz_comp(tls, state, Z_FINISH) == -1 {
  8255  		ret = (*Gz_state)(unsafe.Pointer(state)).Ferr
  8256  	}
  8257  	if (*Gz_state)(unsafe.Pointer(state)).Fsize != 0 {
  8258  		if !((*Gz_state)(unsafe.Pointer(state)).Fdirect != 0) {
  8259  			XdeflateEnd(tls, state+120)
  8260  			libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fout)
  8261  		}
  8262  		libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fin)
  8263  	}
  8264  	Xgz_error(tls, state, Z_OK, uintptr(0))
  8265  	libc.Xfree(tls, (*Gz_state)(unsafe.Pointer(state)).Fpath)
  8266  	if libc.Xclose(tls, (*Gz_state)(unsafe.Pointer(state)).Ffd) == -1 {
  8267  		ret = -1
  8268  	}
  8269  	libc.Xfree(tls, state)
  8270  	return ret
  8271  }
  8272  
  8273  // Reverse the bytes in a 32-bit value
  8274  
  8275  // inftrees.h -- header to use inftrees.c
  8276  // Copyright (C) 1995-2005, 2010 Mark Adler
  8277  // For conditions of distribution and use, see copyright notice in zlib.h
  8278  
  8279  // WARNING: this file should *not* be used by applications. It is
  8280  //    part of the implementation of the compression library and is
  8281  //    subject to change. Applications should only use zlib.h.
  8282  //
  8283  
  8284  // Structure for decoding tables.  Each entry provides either the
  8285  //    information needed to do the operation requested by the code that
  8286  //    indexed that table entry, or it provides a pointer to another
  8287  //    table that indexes more bits of the code.  op indicates whether
  8288  //    the entry is a pointer to another table, a literal, a length or
  8289  //    distance, an end-of-block, or an invalid code.  For a table
  8290  //    pointer, the low four bits of op is the number of index bits of
  8291  //    that table.  For a length or distance, the low four bits of op
  8292  //    is the number of extra bits to get after the code.  bits is
  8293  //    the number of bits in this code or part of the code to drop off
  8294  //    of the bit buffer.  val is the actual byte to output in the case
  8295  //    of a literal, the base length or distance, or the offset from
  8296  //    the current table to the next table.  Each entry is four bytes.
  8297  type Code = struct {
  8298  	Fop   uint8
  8299  	Fbits uint8
  8300  	Fval  uint16
  8301  } /* inftrees.h:28:3 */
  8302  
  8303  // op values as set by inflate_table():
  8304  //     00000000 - literal
  8305  //     0000tttt - table link, tttt != 0 is the number of table index bits
  8306  //     0001eeee - length or distance, eeee is the number of extra bits
  8307  //     01100000 - end of block
  8308  //     01000000 - invalid code
  8309  //
  8310  
  8311  // Maximum size of the dynamic table.  The maximum number of code structures is
  8312  //    1444, which is the sum of 852 for literal/length codes and 592 for distance
  8313  //    codes.  These values were found by exhaustive searches using the program
  8314  //    examples/enough.c found in the zlib distribtution.  The arguments to that
  8315  //    program are the number of symbols, the initial root table size, and the
  8316  //    maximum bit length of a code.  "enough 286 9 15" for literal/length codes
  8317  //    returns returns 852, and "enough 30 6 15" for distance codes returns 592.
  8318  //    The initial root table size (9 or 6) is found in the fifth argument of the
  8319  //    inflate_table() calls in inflate.c and infback.c.  If the root table size is
  8320  //    changed, then these maximum sizes would be need to be recalculated and
  8321  //    updated.
  8322  
  8323  // Type of code to build for inflate_table()
  8324  type Codetype = uint32 /* inftrees.h:58:3 */
  8325  // inflate.h -- internal inflate state definition
  8326  // Copyright (C) 1995-2016 Mark Adler
  8327  // For conditions of distribution and use, see copyright notice in zlib.h
  8328  
  8329  // WARNING: this file should *not* be used by applications. It is
  8330  //    part of the implementation of the compression library and is
  8331  //    subject to change. Applications should only use zlib.h.
  8332  //
  8333  
  8334  // define NO_GZIP when compiling if you want to disable gzip header and
  8335  //    trailer decoding by inflate().  NO_GZIP would be used to avoid linking in
  8336  //    the crc code when it is not needed.  For shared libraries, gzip decoding
  8337  //    should be left enabled.
  8338  
  8339  // Possible inflate modes between inflate() calls
  8340  type Inflate_mode = uint32 /* inflate.h:53:3 */
  8341  
  8342  //
  8343  //     State transitions between above modes -
  8344  //
  8345  //     (most modes can go to BAD or MEM on error -- not shown for clarity)
  8346  //
  8347  //     Process header:
  8348  //         HEAD -> (gzip) or (zlib) or (raw)
  8349  //         (gzip) -> FLAGS -> TIME -> OS -> EXLEN -> EXTRA -> NAME -> COMMENT ->
  8350  //                   HCRC -> TYPE
  8351  //         (zlib) -> DICTID or TYPE
  8352  //         DICTID -> DICT -> TYPE
  8353  //         (raw) -> TYPEDO
  8354  //     Read deflate blocks:
  8355  //             TYPE -> TYPEDO -> STORED or TABLE or LEN_ or CHECK
  8356  //             STORED -> COPY_ -> COPY -> TYPE
  8357  //             TABLE -> LENLENS -> CODELENS -> LEN_
  8358  //             LEN_ -> LEN
  8359  //     Read deflate codes in fixed or dynamic block:
  8360  //                 LEN -> LENEXT or LIT or TYPE
  8361  //                 LENEXT -> DIST -> DISTEXT -> MATCH -> LEN
  8362  //                 LIT -> LEN
  8363  //     Process trailer:
  8364  //         CHECK -> LENGTH -> DONE
  8365  //
  8366  
  8367  // State maintained between inflate() calls -- approximately 7K bytes, not
  8368  //    including the allocated sliding window, which is up to 32K bytes.
  8369  type Inflate_state = struct {
  8370  	Fstrm        Z_streamp
  8371  	Fmode        Inflate_mode
  8372  	Flast        int32
  8373  	Fwrap        int32
  8374  	Fhavedict    int32
  8375  	Fflags       int32
  8376  	Fdmax        uint32
  8377  	Fcheck       uint64
  8378  	Ftotal       uint64
  8379  	Fhead        Gz_headerp
  8380  	Fwbits       uint32
  8381  	Fwsize       uint32
  8382  	Fwhave       uint32
  8383  	Fwnext       uint32
  8384  	Fwindow      uintptr
  8385  	Fhold        uint64
  8386  	Fbits        uint32
  8387  	Flength      uint32
  8388  	Foffset      uint32
  8389  	Fextra       uint32
  8390  	Flencode     uintptr
  8391  	Fdistcode    uintptr
  8392  	Flenbits     uint32
  8393  	Fdistbits    uint32
  8394  	Fncode       uint32
  8395  	Fnlen        uint32
  8396  	Fndist       uint32
  8397  	Fhave        uint32
  8398  	Fnext        uintptr
  8399  	Flens        [320]uint16
  8400  	Fwork        [288]uint16
  8401  	Fcodes       [1444]Code
  8402  	Fsane        int32
  8403  	Fback        int32
  8404  	Fwas         uint32
  8405  	F__ccgo_pad1 [4]byte
  8406  } /* inflate.h:82:1 */
  8407  
  8408  //
  8409  //    strm provides memory allocation functions in zalloc and zfree, or
  8410  //    Z_NULL to use the library memory allocation functions.
  8411  //
  8412  //    windowBits is in the range 8..15, and window is a user-supplied
  8413  //    window and output buffer that is 2**windowBits bytes.
  8414  //
  8415  func XinflateBackInit_(tls *libc.TLS, strm Z_streamp, windowBits int32, window uintptr, version uintptr, stream_size int32) int32 { /* infback.c:28:13: */
  8416  	var state uintptr
  8417  
  8418  	if version == uintptr(Z_NULL) || int32(*(*int8)(unsafe.Pointer(version))) != int32(*(*int8)(unsafe.Pointer(ts))) || stream_size != int32(unsafe.Sizeof(Z_stream{})) {
  8419  		return -6
  8420  	}
  8421  	if strm == uintptr(Z_NULL) || window == uintptr(Z_NULL) || windowBits < 8 || windowBits > 15 {
  8422  		return -2
  8423  	}
  8424  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = uintptr(Z_NULL) // in case we return an error
  8425  	if (*Z_stream)(unsafe.Pointer(strm)).Fzalloc == uintptr(0) {
  8426  		(*Z_stream)(unsafe.Pointer(strm)).Fzalloc = *(*uintptr)(unsafe.Pointer(&struct {
  8427  			f func(*libc.TLS, Voidpf, uint32, uint32) Voidpf
  8428  		}{Xzcalloc}))
  8429  		(*Z_stream)(unsafe.Pointer(strm)).Fopaque = uintptr(0)
  8430  	}
  8431  	if (*Z_stream)(unsafe.Pointer(strm)).Fzfree == uintptr(0) {
  8432  		(*Z_stream)(unsafe.Pointer(strm)).Fzfree = *(*uintptr)(unsafe.Pointer(&struct {
  8433  			f func(*libc.TLS, Voidpf, Voidpf)
  8434  		}{Xzcfree}))
  8435  	}
  8436  	state = (*struct {
  8437  		f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
  8438  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, uint32(1), uint32(unsafe.Sizeof(Inflate_state{})))
  8439  	if state == uintptr(Z_NULL) {
  8440  		return -4
  8441  	}
  8442  
  8443  	(*Z_stream)(unsafe.Pointer(strm)).Fstate = state
  8444  	(*Inflate_state)(unsafe.Pointer(state)).Fdmax = 32768
  8445  	(*Inflate_state)(unsafe.Pointer(state)).Fwbits = UInt(windowBits)
  8446  	(*Inflate_state)(unsafe.Pointer(state)).Fwsize = uint32(1) << windowBits
  8447  	(*Inflate_state)(unsafe.Pointer(state)).Fwindow = window
  8448  	(*Inflate_state)(unsafe.Pointer(state)).Fwnext = uint32(0)
  8449  	(*Inflate_state)(unsafe.Pointer(state)).Fwhave = uint32(0)
  8450  	return Z_OK
  8451  }
  8452  
  8453  //
  8454  //    Return state with length and distance decoding tables and index sizes set to
  8455  //    fixed code decoding.  Normally this returns fixed tables from inffixed.h.
  8456  //    If BUILDFIXED is defined, then instead this routine builds the tables the
  8457  //    first time it's called, and returns those tables the first time and
  8458  //    thereafter.  This reduces the size of the code by about 2K bytes, in
  8459  //    exchange for a little execution time.  However, BUILDFIXED should not be
  8460  //    used for threaded applications, since the rewriting of the tables and virgin
  8461  //    may not be thread-safe.
  8462  //
  8463  func fixedtables(tls *libc.TLS, state uintptr) { /* infback.c:82:12: */
  8464  	(*Inflate_state)(unsafe.Pointer(state)).Flencode = uintptr(unsafe.Pointer(&lenfix))
  8465  	(*Inflate_state)(unsafe.Pointer(state)).Flenbits = uint32(9)
  8466  	(*Inflate_state)(unsafe.Pointer(state)).Fdistcode = uintptr(unsafe.Pointer(&distfix))
  8467  	(*Inflate_state)(unsafe.Pointer(state)).Fdistbits = uint32(5)
  8468  }
  8469  
  8470  var lenfix = [512]Code{
  8471  	{Fop: uint8(96), Fbits: uint8(7)}, {Fbits: uint8(8), Fval: uint16(80)}, {Fbits: uint8(8), Fval: uint16(16)}, {Fop: uint8(20), Fbits: uint8(8), Fval: uint16(115)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(31)}, {Fbits: uint8(8), Fval: uint16(112)}, {Fbits: uint8(8), Fval: uint16(48)},
  8472  	{Fbits: uint8(9), Fval: uint16(192)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(10)}, {Fbits: uint8(8), Fval: uint16(96)}, {Fbits: uint8(8), Fval: uint16(32)}, {Fbits: uint8(9), Fval: uint16(160)}, {Fbits: uint8(8)}, {Fbits: uint8(8), Fval: uint16(128)},
  8473  	{Fbits: uint8(8), Fval: uint16(64)}, {Fbits: uint8(9), Fval: uint16(224)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(6)}, {Fbits: uint8(8), Fval: uint16(88)}, {Fbits: uint8(8), Fval: uint16(24)}, {Fbits: uint8(9), Fval: uint16(144)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(59)},
  8474  	{Fbits: uint8(8), Fval: uint16(120)}, {Fbits: uint8(8), Fval: uint16(56)}, {Fbits: uint8(9), Fval: uint16(208)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(17)}, {Fbits: uint8(8), Fval: uint16(104)}, {Fbits: uint8(8), Fval: uint16(40)}, {Fbits: uint8(9), Fval: uint16(176)},
  8475  	{Fbits: uint8(8), Fval: uint16(8)}, {Fbits: uint8(8), Fval: uint16(136)}, {Fbits: uint8(8), Fval: uint16(72)}, {Fbits: uint8(9), Fval: uint16(240)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(4)}, {Fbits: uint8(8), Fval: uint16(84)}, {Fbits: uint8(8), Fval: uint16(20)},
  8476  	{Fop: uint8(21), Fbits: uint8(8), Fval: uint16(227)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(43)}, {Fbits: uint8(8), Fval: uint16(116)}, {Fbits: uint8(8), Fval: uint16(52)}, {Fbits: uint8(9), Fval: uint16(200)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(13)}, {Fbits: uint8(8), Fval: uint16(100)},
  8477  	{Fbits: uint8(8), Fval: uint16(36)}, {Fbits: uint8(9), Fval: uint16(168)}, {Fbits: uint8(8), Fval: uint16(4)}, {Fbits: uint8(8), Fval: uint16(132)}, {Fbits: uint8(8), Fval: uint16(68)}, {Fbits: uint8(9), Fval: uint16(232)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(8)},
  8478  	{Fbits: uint8(8), Fval: uint16(92)}, {Fbits: uint8(8), Fval: uint16(28)}, {Fbits: uint8(9), Fval: uint16(152)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(83)}, {Fbits: uint8(8), Fval: uint16(124)}, {Fbits: uint8(8), Fval: uint16(60)}, {Fbits: uint8(9), Fval: uint16(216)},
  8479  	{Fop: uint8(18), Fbits: uint8(7), Fval: uint16(23)}, {Fbits: uint8(8), Fval: uint16(108)}, {Fbits: uint8(8), Fval: uint16(44)}, {Fbits: uint8(9), Fval: uint16(184)}, {Fbits: uint8(8), Fval: uint16(12)}, {Fbits: uint8(8), Fval: uint16(140)}, {Fbits: uint8(8), Fval: uint16(76)},
  8480  	{Fbits: uint8(9), Fval: uint16(248)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(3)}, {Fbits: uint8(8), Fval: uint16(82)}, {Fbits: uint8(8), Fval: uint16(18)}, {Fop: uint8(21), Fbits: uint8(8), Fval: uint16(163)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(35)}, {Fbits: uint8(8), Fval: uint16(114)},
  8481  	{Fbits: uint8(8), Fval: uint16(50)}, {Fbits: uint8(9), Fval: uint16(196)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(11)}, {Fbits: uint8(8), Fval: uint16(98)}, {Fbits: uint8(8), Fval: uint16(34)}, {Fbits: uint8(9), Fval: uint16(164)}, {Fbits: uint8(8), Fval: uint16(2)},
  8482  	{Fbits: uint8(8), Fval: uint16(130)}, {Fbits: uint8(8), Fval: uint16(66)}, {Fbits: uint8(9), Fval: uint16(228)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(7)}, {Fbits: uint8(8), Fval: uint16(90)}, {Fbits: uint8(8), Fval: uint16(26)}, {Fbits: uint8(9), Fval: uint16(148)},
  8483  	{Fop: uint8(20), Fbits: uint8(7), Fval: uint16(67)}, {Fbits: uint8(8), Fval: uint16(122)}, {Fbits: uint8(8), Fval: uint16(58)}, {Fbits: uint8(9), Fval: uint16(212)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(19)}, {Fbits: uint8(8), Fval: uint16(106)}, {Fbits: uint8(8), Fval: uint16(42)},
  8484  	{Fbits: uint8(9), Fval: uint16(180)}, {Fbits: uint8(8), Fval: uint16(10)}, {Fbits: uint8(8), Fval: uint16(138)}, {Fbits: uint8(8), Fval: uint16(74)}, {Fbits: uint8(9), Fval: uint16(244)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(5)}, {Fbits: uint8(8), Fval: uint16(86)},
  8485  	{Fbits: uint8(8), Fval: uint16(22)}, {Fop: uint8(64), Fbits: uint8(8)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(51)}, {Fbits: uint8(8), Fval: uint16(118)}, {Fbits: uint8(8), Fval: uint16(54)}, {Fbits: uint8(9), Fval: uint16(204)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(15)},
  8486  	{Fbits: uint8(8), Fval: uint16(102)}, {Fbits: uint8(8), Fval: uint16(38)}, {Fbits: uint8(9), Fval: uint16(172)}, {Fbits: uint8(8), Fval: uint16(6)}, {Fbits: uint8(8), Fval: uint16(134)}, {Fbits: uint8(8), Fval: uint16(70)}, {Fbits: uint8(9), Fval: uint16(236)},
  8487  	{Fop: uint8(16), Fbits: uint8(7), Fval: uint16(9)}, {Fbits: uint8(8), Fval: uint16(94)}, {Fbits: uint8(8), Fval: uint16(30)}, {Fbits: uint8(9), Fval: uint16(156)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(99)}, {Fbits: uint8(8), Fval: uint16(126)}, {Fbits: uint8(8), Fval: uint16(62)},
  8488  	{Fbits: uint8(9), Fval: uint16(220)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(27)}, {Fbits: uint8(8), Fval: uint16(110)}, {Fbits: uint8(8), Fval: uint16(46)}, {Fbits: uint8(9), Fval: uint16(188)}, {Fbits: uint8(8), Fval: uint16(14)}, {Fbits: uint8(8), Fval: uint16(142)},
  8489  	{Fbits: uint8(8), Fval: uint16(78)}, {Fbits: uint8(9), Fval: uint16(252)}, {Fop: uint8(96), Fbits: uint8(7)}, {Fbits: uint8(8), Fval: uint16(81)}, {Fbits: uint8(8), Fval: uint16(17)}, {Fop: uint8(21), Fbits: uint8(8), Fval: uint16(131)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(31)},
  8490  	{Fbits: uint8(8), Fval: uint16(113)}, {Fbits: uint8(8), Fval: uint16(49)}, {Fbits: uint8(9), Fval: uint16(194)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(10)}, {Fbits: uint8(8), Fval: uint16(97)}, {Fbits: uint8(8), Fval: uint16(33)}, {Fbits: uint8(9), Fval: uint16(162)},
  8491  	{Fbits: uint8(8), Fval: uint16(1)}, {Fbits: uint8(8), Fval: uint16(129)}, {Fbits: uint8(8), Fval: uint16(65)}, {Fbits: uint8(9), Fval: uint16(226)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(6)}, {Fbits: uint8(8), Fval: uint16(89)}, {Fbits: uint8(8), Fval: uint16(25)},
  8492  	{Fbits: uint8(9), Fval: uint16(146)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(59)}, {Fbits: uint8(8), Fval: uint16(121)}, {Fbits: uint8(8), Fval: uint16(57)}, {Fbits: uint8(9), Fval: uint16(210)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(17)}, {Fbits: uint8(8), Fval: uint16(105)},
  8493  	{Fbits: uint8(8), Fval: uint16(41)}, {Fbits: uint8(9), Fval: uint16(178)}, {Fbits: uint8(8), Fval: uint16(9)}, {Fbits: uint8(8), Fval: uint16(137)}, {Fbits: uint8(8), Fval: uint16(73)}, {Fbits: uint8(9), Fval: uint16(242)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(4)},
  8494  	{Fbits: uint8(8), Fval: uint16(85)}, {Fbits: uint8(8), Fval: uint16(21)}, {Fop: uint8(16), Fbits: uint8(8), Fval: uint16(258)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(43)}, {Fbits: uint8(8), Fval: uint16(117)}, {Fbits: uint8(8), Fval: uint16(53)}, {Fbits: uint8(9), Fval: uint16(202)},
  8495  	{Fop: uint8(17), Fbits: uint8(7), Fval: uint16(13)}, {Fbits: uint8(8), Fval: uint16(101)}, {Fbits: uint8(8), Fval: uint16(37)}, {Fbits: uint8(9), Fval: uint16(170)}, {Fbits: uint8(8), Fval: uint16(5)}, {Fbits: uint8(8), Fval: uint16(133)}, {Fbits: uint8(8), Fval: uint16(69)},
  8496  	{Fbits: uint8(9), Fval: uint16(234)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(8)}, {Fbits: uint8(8), Fval: uint16(93)}, {Fbits: uint8(8), Fval: uint16(29)}, {Fbits: uint8(9), Fval: uint16(154)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(83)}, {Fbits: uint8(8), Fval: uint16(125)},
  8497  	{Fbits: uint8(8), Fval: uint16(61)}, {Fbits: uint8(9), Fval: uint16(218)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(23)}, {Fbits: uint8(8), Fval: uint16(109)}, {Fbits: uint8(8), Fval: uint16(45)}, {Fbits: uint8(9), Fval: uint16(186)}, {Fbits: uint8(8), Fval: uint16(13)},
  8498  	{Fbits: uint8(8), Fval: uint16(141)}, {Fbits: uint8(8), Fval: uint16(77)}, {Fbits: uint8(9), Fval: uint16(250)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(3)}, {Fbits: uint8(8), Fval: uint16(83)}, {Fbits: uint8(8), Fval: uint16(19)}, {Fop: uint8(21), Fbits: uint8(8), Fval: uint16(195)},
  8499  	{Fop: uint8(19), Fbits: uint8(7), Fval: uint16(35)}, {Fbits: uint8(8), Fval: uint16(115)}, {Fbits: uint8(8), Fval: uint16(51)}, {Fbits: uint8(9), Fval: uint16(198)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(11)}, {Fbits: uint8(8), Fval: uint16(99)}, {Fbits: uint8(8), Fval: uint16(35)},
  8500  	{Fbits: uint8(9), Fval: uint16(166)}, {Fbits: uint8(8), Fval: uint16(3)}, {Fbits: uint8(8), Fval: uint16(131)}, {Fbits: uint8(8), Fval: uint16(67)}, {Fbits: uint8(9), Fval: uint16(230)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(7)}, {Fbits: uint8(8), Fval: uint16(91)},
  8501  	{Fbits: uint8(8), Fval: uint16(27)}, {Fbits: uint8(9), Fval: uint16(150)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(67)}, {Fbits: uint8(8), Fval: uint16(123)}, {Fbits: uint8(8), Fval: uint16(59)}, {Fbits: uint8(9), Fval: uint16(214)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(19)},
  8502  	{Fbits: uint8(8), Fval: uint16(107)}, {Fbits: uint8(8), Fval: uint16(43)}, {Fbits: uint8(9), Fval: uint16(182)}, {Fbits: uint8(8), Fval: uint16(11)}, {Fbits: uint8(8), Fval: uint16(139)}, {Fbits: uint8(8), Fval: uint16(75)}, {Fbits: uint8(9), Fval: uint16(246)},
  8503  	{Fop: uint8(16), Fbits: uint8(7), Fval: uint16(5)}, {Fbits: uint8(8), Fval: uint16(87)}, {Fbits: uint8(8), Fval: uint16(23)}, {Fop: uint8(64), Fbits: uint8(8)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(51)}, {Fbits: uint8(8), Fval: uint16(119)}, {Fbits: uint8(8), Fval: uint16(55)},
  8504  	{Fbits: uint8(9), Fval: uint16(206)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(15)}, {Fbits: uint8(8), Fval: uint16(103)}, {Fbits: uint8(8), Fval: uint16(39)}, {Fbits: uint8(9), Fval: uint16(174)}, {Fbits: uint8(8), Fval: uint16(7)}, {Fbits: uint8(8), Fval: uint16(135)},
  8505  	{Fbits: uint8(8), Fval: uint16(71)}, {Fbits: uint8(9), Fval: uint16(238)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(9)}, {Fbits: uint8(8), Fval: uint16(95)}, {Fbits: uint8(8), Fval: uint16(31)}, {Fbits: uint8(9), Fval: uint16(158)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(99)},
  8506  	{Fbits: uint8(8), Fval: uint16(127)}, {Fbits: uint8(8), Fval: uint16(63)}, {Fbits: uint8(9), Fval: uint16(222)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(27)}, {Fbits: uint8(8), Fval: uint16(111)}, {Fbits: uint8(8), Fval: uint16(47)}, {Fbits: uint8(9), Fval: uint16(190)},
  8507  	{Fbits: uint8(8), Fval: uint16(15)}, {Fbits: uint8(8), Fval: uint16(143)}, {Fbits: uint8(8), Fval: uint16(79)}, {Fbits: uint8(9), Fval: uint16(254)}, {Fop: uint8(96), Fbits: uint8(7)}, {Fbits: uint8(8), Fval: uint16(80)}, {Fbits: uint8(8), Fval: uint16(16)},
  8508  	{Fop: uint8(20), Fbits: uint8(8), Fval: uint16(115)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(31)}, {Fbits: uint8(8), Fval: uint16(112)}, {Fbits: uint8(8), Fval: uint16(48)}, {Fbits: uint8(9), Fval: uint16(193)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(10)}, {Fbits: uint8(8), Fval: uint16(96)},
  8509  	{Fbits: uint8(8), Fval: uint16(32)}, {Fbits: uint8(9), Fval: uint16(161)}, {Fbits: uint8(8)}, {Fbits: uint8(8), Fval: uint16(128)}, {Fbits: uint8(8), Fval: uint16(64)}, {Fbits: uint8(9), Fval: uint16(225)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(6)},
  8510  	{Fbits: uint8(8), Fval: uint16(88)}, {Fbits: uint8(8), Fval: uint16(24)}, {Fbits: uint8(9), Fval: uint16(145)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(59)}, {Fbits: uint8(8), Fval: uint16(120)}, {Fbits: uint8(8), Fval: uint16(56)}, {Fbits: uint8(9), Fval: uint16(209)},
  8511  	{Fop: uint8(17), Fbits: uint8(7), Fval: uint16(17)}, {Fbits: uint8(8), Fval: uint16(104)}, {Fbits: uint8(8), Fval: uint16(40)}, {Fbits: uint8(9), Fval: uint16(177)}, {Fbits: uint8(8), Fval: uint16(8)}, {Fbits: uint8(8), Fval: uint16(136)}, {Fbits: uint8(8), Fval: uint16(72)},
  8512  	{Fbits: uint8(9), Fval: uint16(241)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(4)}, {Fbits: uint8(8), Fval: uint16(84)}, {Fbits: uint8(8), Fval: uint16(20)}, {Fop: uint8(21), Fbits: uint8(8), Fval: uint16(227)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(43)}, {Fbits: uint8(8), Fval: uint16(116)},
  8513  	{Fbits: uint8(8), Fval: uint16(52)}, {Fbits: uint8(9), Fval: uint16(201)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(13)}, {Fbits: uint8(8), Fval: uint16(100)}, {Fbits: uint8(8), Fval: uint16(36)}, {Fbits: uint8(9), Fval: uint16(169)}, {Fbits: uint8(8), Fval: uint16(4)},
  8514  	{Fbits: uint8(8), Fval: uint16(132)}, {Fbits: uint8(8), Fval: uint16(68)}, {Fbits: uint8(9), Fval: uint16(233)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(8)}, {Fbits: uint8(8), Fval: uint16(92)}, {Fbits: uint8(8), Fval: uint16(28)}, {Fbits: uint8(9), Fval: uint16(153)},
  8515  	{Fop: uint8(20), Fbits: uint8(7), Fval: uint16(83)}, {Fbits: uint8(8), Fval: uint16(124)}, {Fbits: uint8(8), Fval: uint16(60)}, {Fbits: uint8(9), Fval: uint16(217)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(23)}, {Fbits: uint8(8), Fval: uint16(108)}, {Fbits: uint8(8), Fval: uint16(44)},
  8516  	{Fbits: uint8(9), Fval: uint16(185)}, {Fbits: uint8(8), Fval: uint16(12)}, {Fbits: uint8(8), Fval: uint16(140)}, {Fbits: uint8(8), Fval: uint16(76)}, {Fbits: uint8(9), Fval: uint16(249)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(3)}, {Fbits: uint8(8), Fval: uint16(82)},
  8517  	{Fbits: uint8(8), Fval: uint16(18)}, {Fop: uint8(21), Fbits: uint8(8), Fval: uint16(163)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(35)}, {Fbits: uint8(8), Fval: uint16(114)}, {Fbits: uint8(8), Fval: uint16(50)}, {Fbits: uint8(9), Fval: uint16(197)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(11)},
  8518  	{Fbits: uint8(8), Fval: uint16(98)}, {Fbits: uint8(8), Fval: uint16(34)}, {Fbits: uint8(9), Fval: uint16(165)}, {Fbits: uint8(8), Fval: uint16(2)}, {Fbits: uint8(8), Fval: uint16(130)}, {Fbits: uint8(8), Fval: uint16(66)}, {Fbits: uint8(9), Fval: uint16(229)},
  8519  	{Fop: uint8(16), Fbits: uint8(7), Fval: uint16(7)}, {Fbits: uint8(8), Fval: uint16(90)}, {Fbits: uint8(8), Fval: uint16(26)}, {Fbits: uint8(9), Fval: uint16(149)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(67)}, {Fbits: uint8(8), Fval: uint16(122)}, {Fbits: uint8(8), Fval: uint16(58)},
  8520  	{Fbits: uint8(9), Fval: uint16(213)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(19)}, {Fbits: uint8(8), Fval: uint16(106)}, {Fbits: uint8(8), Fval: uint16(42)}, {Fbits: uint8(9), Fval: uint16(181)}, {Fbits: uint8(8), Fval: uint16(10)}, {Fbits: uint8(8), Fval: uint16(138)},
  8521  	{Fbits: uint8(8), Fval: uint16(74)}, {Fbits: uint8(9), Fval: uint16(245)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(5)}, {Fbits: uint8(8), Fval: uint16(86)}, {Fbits: uint8(8), Fval: uint16(22)}, {Fop: uint8(64), Fbits: uint8(8)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(51)},
  8522  	{Fbits: uint8(8), Fval: uint16(118)}, {Fbits: uint8(8), Fval: uint16(54)}, {Fbits: uint8(9), Fval: uint16(205)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(15)}, {Fbits: uint8(8), Fval: uint16(102)}, {Fbits: uint8(8), Fval: uint16(38)}, {Fbits: uint8(9), Fval: uint16(173)},
  8523  	{Fbits: uint8(8), Fval: uint16(6)}, {Fbits: uint8(8), Fval: uint16(134)}, {Fbits: uint8(8), Fval: uint16(70)}, {Fbits: uint8(9), Fval: uint16(237)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(9)}, {Fbits: uint8(8), Fval: uint16(94)}, {Fbits: uint8(8), Fval: uint16(30)},
  8524  	{Fbits: uint8(9), Fval: uint16(157)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(99)}, {Fbits: uint8(8), Fval: uint16(126)}, {Fbits: uint8(8), Fval: uint16(62)}, {Fbits: uint8(9), Fval: uint16(221)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(27)}, {Fbits: uint8(8), Fval: uint16(110)},
  8525  	{Fbits: uint8(8), Fval: uint16(46)}, {Fbits: uint8(9), Fval: uint16(189)}, {Fbits: uint8(8), Fval: uint16(14)}, {Fbits: uint8(8), Fval: uint16(142)}, {Fbits: uint8(8), Fval: uint16(78)}, {Fbits: uint8(9), Fval: uint16(253)}, {Fop: uint8(96), Fbits: uint8(7)},
  8526  	{Fbits: uint8(8), Fval: uint16(81)}, {Fbits: uint8(8), Fval: uint16(17)}, {Fop: uint8(21), Fbits: uint8(8), Fval: uint16(131)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(31)}, {Fbits: uint8(8), Fval: uint16(113)}, {Fbits: uint8(8), Fval: uint16(49)}, {Fbits: uint8(9), Fval: uint16(195)},
  8527  	{Fop: uint8(16), Fbits: uint8(7), Fval: uint16(10)}, {Fbits: uint8(8), Fval: uint16(97)}, {Fbits: uint8(8), Fval: uint16(33)}, {Fbits: uint8(9), Fval: uint16(163)}, {Fbits: uint8(8), Fval: uint16(1)}, {Fbits: uint8(8), Fval: uint16(129)}, {Fbits: uint8(8), Fval: uint16(65)},
  8528  	{Fbits: uint8(9), Fval: uint16(227)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(6)}, {Fbits: uint8(8), Fval: uint16(89)}, {Fbits: uint8(8), Fval: uint16(25)}, {Fbits: uint8(9), Fval: uint16(147)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(59)}, {Fbits: uint8(8), Fval: uint16(121)},
  8529  	{Fbits: uint8(8), Fval: uint16(57)}, {Fbits: uint8(9), Fval: uint16(211)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(17)}, {Fbits: uint8(8), Fval: uint16(105)}, {Fbits: uint8(8), Fval: uint16(41)}, {Fbits: uint8(9), Fval: uint16(179)}, {Fbits: uint8(8), Fval: uint16(9)},
  8530  	{Fbits: uint8(8), Fval: uint16(137)}, {Fbits: uint8(8), Fval: uint16(73)}, {Fbits: uint8(9), Fval: uint16(243)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(4)}, {Fbits: uint8(8), Fval: uint16(85)}, {Fbits: uint8(8), Fval: uint16(21)}, {Fop: uint8(16), Fbits: uint8(8), Fval: uint16(258)},
  8531  	{Fop: uint8(19), Fbits: uint8(7), Fval: uint16(43)}, {Fbits: uint8(8), Fval: uint16(117)}, {Fbits: uint8(8), Fval: uint16(53)}, {Fbits: uint8(9), Fval: uint16(203)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(13)}, {Fbits: uint8(8), Fval: uint16(101)}, {Fbits: uint8(8), Fval: uint16(37)},
  8532  	{Fbits: uint8(9), Fval: uint16(171)}, {Fbits: uint8(8), Fval: uint16(5)}, {Fbits: uint8(8), Fval: uint16(133)}, {Fbits: uint8(8), Fval: uint16(69)}, {Fbits: uint8(9), Fval: uint16(235)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(8)}, {Fbits: uint8(8), Fval: uint16(93)},
  8533  	{Fbits: uint8(8), Fval: uint16(29)}, {Fbits: uint8(9), Fval: uint16(155)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(83)}, {Fbits: uint8(8), Fval: uint16(125)}, {Fbits: uint8(8), Fval: uint16(61)}, {Fbits: uint8(9), Fval: uint16(219)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(23)},
  8534  	{Fbits: uint8(8), Fval: uint16(109)}, {Fbits: uint8(8), Fval: uint16(45)}, {Fbits: uint8(9), Fval: uint16(187)}, {Fbits: uint8(8), Fval: uint16(13)}, {Fbits: uint8(8), Fval: uint16(141)}, {Fbits: uint8(8), Fval: uint16(77)}, {Fbits: uint8(9), Fval: uint16(251)},
  8535  	{Fop: uint8(16), Fbits: uint8(7), Fval: uint16(3)}, {Fbits: uint8(8), Fval: uint16(83)}, {Fbits: uint8(8), Fval: uint16(19)}, {Fop: uint8(21), Fbits: uint8(8), Fval: uint16(195)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(35)}, {Fbits: uint8(8), Fval: uint16(115)}, {Fbits: uint8(8), Fval: uint16(51)},
  8536  	{Fbits: uint8(9), Fval: uint16(199)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(11)}, {Fbits: uint8(8), Fval: uint16(99)}, {Fbits: uint8(8), Fval: uint16(35)}, {Fbits: uint8(9), Fval: uint16(167)}, {Fbits: uint8(8), Fval: uint16(3)}, {Fbits: uint8(8), Fval: uint16(131)},
  8537  	{Fbits: uint8(8), Fval: uint16(67)}, {Fbits: uint8(9), Fval: uint16(231)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(7)}, {Fbits: uint8(8), Fval: uint16(91)}, {Fbits: uint8(8), Fval: uint16(27)}, {Fbits: uint8(9), Fval: uint16(151)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(67)},
  8538  	{Fbits: uint8(8), Fval: uint16(123)}, {Fbits: uint8(8), Fval: uint16(59)}, {Fbits: uint8(9), Fval: uint16(215)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(19)}, {Fbits: uint8(8), Fval: uint16(107)}, {Fbits: uint8(8), Fval: uint16(43)}, {Fbits: uint8(9), Fval: uint16(183)},
  8539  	{Fbits: uint8(8), Fval: uint16(11)}, {Fbits: uint8(8), Fval: uint16(139)}, {Fbits: uint8(8), Fval: uint16(75)}, {Fbits: uint8(9), Fval: uint16(247)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(5)}, {Fbits: uint8(8), Fval: uint16(87)}, {Fbits: uint8(8), Fval: uint16(23)},
  8540  	{Fop: uint8(64), Fbits: uint8(8)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(51)}, {Fbits: uint8(8), Fval: uint16(119)}, {Fbits: uint8(8), Fval: uint16(55)}, {Fbits: uint8(9), Fval: uint16(207)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(15)}, {Fbits: uint8(8), Fval: uint16(103)},
  8541  	{Fbits: uint8(8), Fval: uint16(39)}, {Fbits: uint8(9), Fval: uint16(175)}, {Fbits: uint8(8), Fval: uint16(7)}, {Fbits: uint8(8), Fval: uint16(135)}, {Fbits: uint8(8), Fval: uint16(71)}, {Fbits: uint8(9), Fval: uint16(239)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(9)},
  8542  	{Fbits: uint8(8), Fval: uint16(95)}, {Fbits: uint8(8), Fval: uint16(31)}, {Fbits: uint8(9), Fval: uint16(159)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(99)}, {Fbits: uint8(8), Fval: uint16(127)}, {Fbits: uint8(8), Fval: uint16(63)}, {Fbits: uint8(9), Fval: uint16(223)},
  8543  	{Fop: uint8(18), Fbits: uint8(7), Fval: uint16(27)}, {Fbits: uint8(8), Fval: uint16(111)}, {Fbits: uint8(8), Fval: uint16(47)}, {Fbits: uint8(9), Fval: uint16(191)}, {Fbits: uint8(8), Fval: uint16(15)}, {Fbits: uint8(8), Fval: uint16(143)}, {Fbits: uint8(8), Fval: uint16(79)},
  8544  	{Fbits: uint8(9), Fval: uint16(255)},
  8545  } /* inffixed.h:10:23 */
  8546  var distfix = [32]Code{
  8547  	{Fop: uint8(16), Fbits: uint8(5), Fval: uint16(1)}, {Fop: uint8(23), Fbits: uint8(5), Fval: uint16(257)}, {Fop: uint8(19), Fbits: uint8(5), Fval: uint16(17)}, {Fop: uint8(27), Fbits: uint8(5), Fval: uint16(4097)}, {Fop: uint8(17), Fbits: uint8(5), Fval: uint16(5)}, {Fop: uint8(25), Fbits: uint8(5), Fval: uint16(1025)},
  8548  	{Fop: uint8(21), Fbits: uint8(5), Fval: uint16(65)}, {Fop: uint8(29), Fbits: uint8(5), Fval: uint16(16385)}, {Fop: uint8(16), Fbits: uint8(5), Fval: uint16(3)}, {Fop: uint8(24), Fbits: uint8(5), Fval: uint16(513)}, {Fop: uint8(20), Fbits: uint8(5), Fval: uint16(33)}, {Fop: uint8(28), Fbits: uint8(5), Fval: uint16(8193)},
  8549  	{Fop: uint8(18), Fbits: uint8(5), Fval: uint16(9)}, {Fop: uint8(26), Fbits: uint8(5), Fval: uint16(2049)}, {Fop: uint8(22), Fbits: uint8(5), Fval: uint16(129)}, {Fop: uint8(64), Fbits: uint8(5)}, {Fop: uint8(16), Fbits: uint8(5), Fval: uint16(2)}, {Fop: uint8(23), Fbits: uint8(5), Fval: uint16(385)},
  8550  	{Fop: uint8(19), Fbits: uint8(5), Fval: uint16(25)}, {Fop: uint8(27), Fbits: uint8(5), Fval: uint16(6145)}, {Fop: uint8(17), Fbits: uint8(5), Fval: uint16(7)}, {Fop: uint8(25), Fbits: uint8(5), Fval: uint16(1537)}, {Fop: uint8(21), Fbits: uint8(5), Fval: uint16(97)}, {Fop: uint8(29), Fbits: uint8(5), Fval: uint16(24577)},
  8551  	{Fop: uint8(16), Fbits: uint8(5), Fval: uint16(4)}, {Fop: uint8(24), Fbits: uint8(5), Fval: uint16(769)}, {Fop: uint8(20), Fbits: uint8(5), Fval: uint16(49)}, {Fop: uint8(28), Fbits: uint8(5), Fval: uint16(12289)}, {Fop: uint8(18), Fbits: uint8(5), Fval: uint16(13)}, {Fop: uint8(26), Fbits: uint8(5), Fval: uint16(3073)},
  8552  	{Fop: uint8(22), Fbits: uint8(5), Fval: uint16(193)}, {Fop: uint8(64), Fbits: uint8(5)},
  8553  } /* inffixed.h:87:23 */
  8554  
  8555  // Macros for inflateBack():
  8556  
  8557  // Load returned state from inflate_fast()
  8558  
  8559  // Set state from registers for inflate_fast()
  8560  
  8561  // Clear the input bit accumulator
  8562  
  8563  // Assure that some input is available.  If input is requested, but denied,
  8564  //    then return a Z_BUF_ERROR from inflateBack().
  8565  
  8566  // Get a byte of input into the bit accumulator, or return from inflateBack()
  8567  //    with an error if there is no input available.
  8568  
  8569  // Assure that there are at least n bits in the bit accumulator.  If there is
  8570  //    not enough available input to do that, then return from inflateBack() with
  8571  //    an error.
  8572  
  8573  // Return the low n bits of the bit accumulator (n < 16)
  8574  
  8575  // Remove n bits from the bit accumulator
  8576  
  8577  // Remove zero to seven bits as needed to go to a byte boundary
  8578  
  8579  // Assure that some output space is available, by writing out the window
  8580  //    if it's full.  If the write fails, return from inflateBack() with a
  8581  //    Z_BUF_ERROR.
  8582  
  8583  //
  8584  //    strm provides the memory allocation functions and window buffer on input,
  8585  //    and provides information on the unused input on return.  For Z_DATA_ERROR
  8586  //    returns, strm will also provide an error message.
  8587  //
  8588  //    in() and out() are the call-back input and output functions.  When
  8589  //    inflateBack() needs more input, it calls in().  When inflateBack() has
  8590  //    filled the window with output, or when it completes with data in the
  8591  //    window, it calls out() to write out the data.  The application must not
  8592  //    change the provided input until in() is called again or inflateBack()
  8593  //    returns.  The application must not change the window/output buffer until
  8594  //    inflateBack() returns.
  8595  //
  8596  //    in() and out() are called with a descriptor parameter provided in the
  8597  //    inflateBack() call.  This parameter can be a structure that provides the
  8598  //    information required to do the read or write, as well as accumulated
  8599  //    information on the input and output such as totals and check values.
  8600  //
  8601  //    in() should return zero on failure.  out() should return non-zero on
  8602  //    failure.  If either in() or out() fails, than inflateBack() returns a
  8603  //    Z_BUF_ERROR.  strm->next_in can be checked for Z_NULL to see whether it
  8604  //    was in() or out() that caused in the error.  Otherwise,  inflateBack()
  8605  //    returns Z_STREAM_END on success, Z_DATA_ERROR for an deflate format
  8606  //    error, or Z_MEM_ERROR if it could not allocate memory for the state.
  8607  //    inflateBack() can also return Z_STREAM_ERROR if the input parameters
  8608  //    are not correct, i.e. strm is Z_NULL or the state was not initialized.
  8609  //
  8610  func XinflateBack(tls *libc.TLS, strm Z_streamp, in In_func, in_desc uintptr, out Out_func, out_desc uintptr) int32 { /* infback.c:250:13: */
  8611  	bp := tls.Alloc(8)
  8612  	defer tls.Free(8)
  8613  
  8614  	var state uintptr
  8615  	// var next uintptr at bp, 8
  8616  	// next input
  8617  	var put uintptr // next output
  8618  	var have uint32
  8619  	var left uint32  // available input and output
  8620  	var hold uint64  // bit buffer
  8621  	var bits uint32  // bits in bit buffer
  8622  	var copy uint32  // number of stored or match bytes to copy
  8623  	var from uintptr // where to copy match bytes from
  8624  	var here Code    // current decoding table entry
  8625  	var last Code    // parent table entry
  8626  	var len uint32   // length to copy for repeats, bits to drop
  8627  	var ret int32
  8628  
  8629  	// Check that the strm exists and that the state was initialized
  8630  	if !(strm == uintptr(Z_NULL) || (*Z_stream)(unsafe.Pointer(strm)).Fstate == uintptr(Z_NULL)) {
  8631  		goto __1
  8632  	}
  8633  	return -2
  8634  __1:
  8635  	;
  8636  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
  8637  
  8638  	// Reset the state
  8639  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = uintptr(Z_NULL)
  8640  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = TYPE
  8641  	(*Inflate_state)(unsafe.Pointer(state)).Flast = 0
  8642  	(*Inflate_state)(unsafe.Pointer(state)).Fwhave = uint32(0)
  8643  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = (*Z_stream)(unsafe.Pointer(strm)).Fnext_in
  8644  	if *(*uintptr)(unsafe.Pointer(bp)) != uintptr(Z_NULL) {
  8645  		have = (*Z_stream)(unsafe.Pointer(strm)).Favail_in
  8646  	} else {
  8647  		have = uint32(0)
  8648  	}
  8649  	hold = uint64(0)
  8650  	bits = uint32(0)
  8651  	put = (*Inflate_state)(unsafe.Pointer(state)).Fwindow
  8652  	left = (*Inflate_state)(unsafe.Pointer(state)).Fwsize
  8653  
  8654  	// Inflate until end of block marked as last
  8655  __2:
  8656  	switch (*Inflate_state)(unsafe.Pointer(state)).Fmode {
  8657  	case TYPE:
  8658  		goto __6
  8659  
  8660  	case STORED:
  8661  		goto __7
  8662  
  8663  	case TABLE:
  8664  		goto __8
  8665  
  8666  	case LEN:
  8667  		goto __9
  8668  
  8669  	case DONE:
  8670  		goto __10
  8671  
  8672  	case BAD:
  8673  		goto __11
  8674  
  8675  	default:
  8676  		goto __12
  8677  	}
  8678  	goto __5
  8679  __6:
  8680  	// determine and dispatch block type
  8681  	if !((*Inflate_state)(unsafe.Pointer(state)).Flast != 0) {
  8682  		goto __13
  8683  	}
  8684  __14:
  8685  	hold >>= bits & uint32(7)
  8686  	bits = bits - bits&uint32(7)
  8687  	goto __15
  8688  __15:
  8689  	if 0 != 0 {
  8690  		goto __14
  8691  	}
  8692  	goto __16
  8693  __16:
  8694  	;
  8695  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = DONE
  8696  	goto __5
  8697  __13:
  8698  	;
  8699  __17:
  8700  __20:
  8701  	if !(bits < uint32(3)) {
  8702  		goto __21
  8703  	}
  8704  __22:
  8705  __25:
  8706  	if !(have == uint32(0)) {
  8707  		goto __28
  8708  	}
  8709  	have = (*struct {
  8710  		f func(*libc.TLS, uintptr, uintptr) uint32
  8711  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
  8712  	if !(have == uint32(0)) {
  8713  		goto __29
  8714  	}
  8715  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
  8716  	ret = -5
  8717  	goto inf_leave
  8718  __29:
  8719  	;
  8720  __28:
  8721  	;
  8722  	goto __26
  8723  __26:
  8724  	if 0 != 0 {
  8725  		goto __25
  8726  	}
  8727  	goto __27
  8728  __27:
  8729  	;
  8730  	have--
  8731  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(bp /* next */)), 1))))<<bits
  8732  	bits = bits + uint32(8)
  8733  	goto __23
  8734  __23:
  8735  	if 0 != 0 {
  8736  		goto __22
  8737  	}
  8738  	goto __24
  8739  __24:
  8740  	;
  8741  	goto __20
  8742  __21:
  8743  	;
  8744  	goto __18
  8745  __18:
  8746  	if 0 != 0 {
  8747  		goto __17
  8748  	}
  8749  	goto __19
  8750  __19:
  8751  	;
  8752  	(*Inflate_state)(unsafe.Pointer(state)).Flast = int32(uint32(hold) & (uint32(1)<<1 - uint32(1)))
  8753  __30:
  8754  	hold >>= 1
  8755  	bits = bits - uint32(1)
  8756  	goto __31
  8757  __31:
  8758  	if 0 != 0 {
  8759  		goto __30
  8760  	}
  8761  	goto __32
  8762  __32:
  8763  	;
  8764  	switch uint32(hold) & (uint32(1)<<2 - uint32(1)) {
  8765  	case uint32(0):
  8766  		goto __34
  8767  	case uint32(1):
  8768  		goto __35
  8769  	case uint32(2):
  8770  		goto __36
  8771  	case uint32(3):
  8772  		goto __37
  8773  	}
  8774  	goto __33
  8775  __34: // stored block
  8776  	;
  8777  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = STORED
  8778  	goto __33
  8779  __35: // fixed block
  8780  	fixedtables(tls, state)
  8781  
  8782  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = LEN // decode codes
  8783  	goto __33
  8784  __36: // dynamic block
  8785  	;
  8786  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = TABLE
  8787  	goto __33
  8788  __37:
  8789  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 367 /* "invalid block ty..." */
  8790  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
  8791  __33:
  8792  	;
  8793  __38:
  8794  	hold >>= 2
  8795  	bits = bits - uint32(2)
  8796  	goto __39
  8797  __39:
  8798  	if 0 != 0 {
  8799  		goto __38
  8800  	}
  8801  	goto __40
  8802  __40:
  8803  	;
  8804  	goto __5
  8805  
  8806  __7:
  8807  	// get and verify stored block length
  8808  __41:
  8809  	hold >>= bits & uint32(7)
  8810  	bits = bits - bits&uint32(7)
  8811  	goto __42
  8812  __42:
  8813  	if 0 != 0 {
  8814  		goto __41
  8815  	}
  8816  	goto __43
  8817  __43:
  8818  	; // go to byte boundary
  8819  __44:
  8820  __47:
  8821  	if !(bits < uint32(32)) {
  8822  		goto __48
  8823  	}
  8824  __49:
  8825  __52:
  8826  	if !(have == uint32(0)) {
  8827  		goto __55
  8828  	}
  8829  	have = (*struct {
  8830  		f func(*libc.TLS, uintptr, uintptr) uint32
  8831  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
  8832  	if !(have == uint32(0)) {
  8833  		goto __56
  8834  	}
  8835  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
  8836  	ret = -5
  8837  	goto inf_leave
  8838  __56:
  8839  	;
  8840  __55:
  8841  	;
  8842  	goto __53
  8843  __53:
  8844  	if 0 != 0 {
  8845  		goto __52
  8846  	}
  8847  	goto __54
  8848  __54:
  8849  	;
  8850  	have--
  8851  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(bp /* next */)), 1))))<<bits
  8852  	bits = bits + uint32(8)
  8853  	goto __50
  8854  __50:
  8855  	if 0 != 0 {
  8856  		goto __49
  8857  	}
  8858  	goto __51
  8859  __51:
  8860  	;
  8861  	goto __47
  8862  __48:
  8863  	;
  8864  	goto __45
  8865  __45:
  8866  	if 0 != 0 {
  8867  		goto __44
  8868  	}
  8869  	goto __46
  8870  __46:
  8871  	;
  8872  	if !(hold&uint64(0xffff) != hold>>16^uint64(0xffff)) {
  8873  		goto __57
  8874  	}
  8875  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 386 /* "invalid stored b..." */
  8876  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
  8877  	goto __5
  8878  __57:
  8879  	;
  8880  	(*Inflate_state)(unsafe.Pointer(state)).Flength = uint32(hold) & uint32(0xffff)
  8881  
  8882  __58:
  8883  	hold = uint64(0)
  8884  	bits = uint32(0)
  8885  	goto __59
  8886  __59:
  8887  	if 0 != 0 {
  8888  		goto __58
  8889  	}
  8890  	goto __60
  8891  __60:
  8892  	;
  8893  
  8894  	// copy stored block from input to output
  8895  __61:
  8896  	if !((*Inflate_state)(unsafe.Pointer(state)).Flength != uint32(0)) {
  8897  		goto __62
  8898  	}
  8899  	copy = (*Inflate_state)(unsafe.Pointer(state)).Flength
  8900  __63:
  8901  	if !(have == uint32(0)) {
  8902  		goto __66
  8903  	}
  8904  	have = (*struct {
  8905  		f func(*libc.TLS, uintptr, uintptr) uint32
  8906  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
  8907  	if !(have == uint32(0)) {
  8908  		goto __67
  8909  	}
  8910  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
  8911  	ret = -5
  8912  	goto inf_leave
  8913  __67:
  8914  	;
  8915  __66:
  8916  	;
  8917  	goto __64
  8918  __64:
  8919  	if 0 != 0 {
  8920  		goto __63
  8921  	}
  8922  	goto __65
  8923  __65:
  8924  	;
  8925  __68:
  8926  	if !(left == uint32(0)) {
  8927  		goto __71
  8928  	}
  8929  	put = (*Inflate_state)(unsafe.Pointer(state)).Fwindow
  8930  	left = (*Inflate_state)(unsafe.Pointer(state)).Fwsize
  8931  	(*Inflate_state)(unsafe.Pointer(state)).Fwhave = left
  8932  	if !((*struct {
  8933  		f func(*libc.TLS, uintptr, uintptr, uint32) int32
  8934  	})(unsafe.Pointer(&struct{ uintptr }{out})).f(tls, out_desc, put, left) != 0) {
  8935  		goto __72
  8936  	}
  8937  	ret = -5
  8938  	goto inf_leave
  8939  __72:
  8940  	;
  8941  __71:
  8942  	;
  8943  	goto __69
  8944  __69:
  8945  	if 0 != 0 {
  8946  		goto __68
  8947  	}
  8948  	goto __70
  8949  __70:
  8950  	;
  8951  	if !(copy > have) {
  8952  		goto __73
  8953  	}
  8954  	copy = have
  8955  __73:
  8956  	;
  8957  	if !(copy > left) {
  8958  		goto __74
  8959  	}
  8960  	copy = left
  8961  __74:
  8962  	;
  8963  	libc.Xmemcpy(tls, put, *(*uintptr)(unsafe.Pointer(bp /* next */)), uint64(copy))
  8964  	have = have - copy
  8965  	*(*uintptr)(unsafe.Pointer(bp /* next */)) += uintptr(copy)
  8966  	left = left - copy
  8967  	put += uintptr(copy)
  8968  	*(*uint32)(unsafe.Pointer(state + 92)) -= copy
  8969  	goto __61
  8970  __62:
  8971  	;
  8972  
  8973  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = TYPE
  8974  	goto __5
  8975  
  8976  __8:
  8977  	// get dynamic table entries descriptor
  8978  __75:
  8979  __78:
  8980  	if !(bits < uint32(14)) {
  8981  		goto __79
  8982  	}
  8983  __80:
  8984  __83:
  8985  	if !(have == uint32(0)) {
  8986  		goto __86
  8987  	}
  8988  	have = (*struct {
  8989  		f func(*libc.TLS, uintptr, uintptr) uint32
  8990  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
  8991  	if !(have == uint32(0)) {
  8992  		goto __87
  8993  	}
  8994  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
  8995  	ret = -5
  8996  	goto inf_leave
  8997  __87:
  8998  	;
  8999  __86:
  9000  	;
  9001  	goto __84
  9002  __84:
  9003  	if 0 != 0 {
  9004  		goto __83
  9005  	}
  9006  	goto __85
  9007  __85:
  9008  	;
  9009  	have--
  9010  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(bp /* next */)), 1))))<<bits
  9011  	bits = bits + uint32(8)
  9012  	goto __81
  9013  __81:
  9014  	if 0 != 0 {
  9015  		goto __80
  9016  	}
  9017  	goto __82
  9018  __82:
  9019  	;
  9020  	goto __78
  9021  __79:
  9022  	;
  9023  	goto __76
  9024  __76:
  9025  	if 0 != 0 {
  9026  		goto __75
  9027  	}
  9028  	goto __77
  9029  __77:
  9030  	;
  9031  	(*Inflate_state)(unsafe.Pointer(state)).Fnlen = uint32(hold)&(uint32(1)<<5-uint32(1)) + uint32(257)
  9032  __88:
  9033  	hold >>= 5
  9034  	bits = bits - uint32(5)
  9035  	goto __89
  9036  __89:
  9037  	if 0 != 0 {
  9038  		goto __88
  9039  	}
  9040  	goto __90
  9041  __90:
  9042  	;
  9043  	(*Inflate_state)(unsafe.Pointer(state)).Fndist = uint32(hold)&(uint32(1)<<5-uint32(1)) + uint32(1)
  9044  __91:
  9045  	hold >>= 5
  9046  	bits = bits - uint32(5)
  9047  	goto __92
  9048  __92:
  9049  	if 0 != 0 {
  9050  		goto __91
  9051  	}
  9052  	goto __93
  9053  __93:
  9054  	;
  9055  	(*Inflate_state)(unsafe.Pointer(state)).Fncode = uint32(hold)&(uint32(1)<<4-uint32(1)) + uint32(4)
  9056  __94:
  9057  	hold >>= 4
  9058  	bits = bits - uint32(4)
  9059  	goto __95
  9060  __95:
  9061  	if 0 != 0 {
  9062  		goto __94
  9063  	}
  9064  	goto __96
  9065  __96:
  9066  	;
  9067  	if !((*Inflate_state)(unsafe.Pointer(state)).Fnlen > uint32(286) || (*Inflate_state)(unsafe.Pointer(state)).Fndist > uint32(30)) {
  9068  		goto __97
  9069  	}
  9070  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 415 /* "too many length ..." */
  9071  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
  9072  	goto __5
  9073  __97:
  9074  	;
  9075  
  9076  	// get code length code lengths (not a typo)
  9077  	(*Inflate_state)(unsafe.Pointer(state)).Fhave = uint32(0)
  9078  __98:
  9079  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhave < (*Inflate_state)(unsafe.Pointer(state)).Fncode) {
  9080  		goto __99
  9081  	}
  9082  __100:
  9083  __103:
  9084  	if !(bits < uint32(3)) {
  9085  		goto __104
  9086  	}
  9087  __105:
  9088  __108:
  9089  	if !(have == uint32(0)) {
  9090  		goto __111
  9091  	}
  9092  	have = (*struct {
  9093  		f func(*libc.TLS, uintptr, uintptr) uint32
  9094  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
  9095  	if !(have == uint32(0)) {
  9096  		goto __112
  9097  	}
  9098  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
  9099  	ret = -5
  9100  	goto inf_leave
  9101  __112:
  9102  	;
  9103  __111:
  9104  	;
  9105  	goto __109
  9106  __109:
  9107  	if 0 != 0 {
  9108  		goto __108
  9109  	}
  9110  	goto __110
  9111  __110:
  9112  	;
  9113  	have--
  9114  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(bp /* next */)), 1))))<<bits
  9115  	bits = bits + uint32(8)
  9116  	goto __106
  9117  __106:
  9118  	if 0 != 0 {
  9119  		goto __105
  9120  	}
  9121  	goto __107
  9122  __107:
  9123  	;
  9124  	goto __103
  9125  __104:
  9126  	;
  9127  	goto __101
  9128  __101:
  9129  	if 0 != 0 {
  9130  		goto __100
  9131  	}
  9132  	goto __102
  9133  __102:
  9134  	;
  9135  	*(*uint16)(unsafe.Pointer(state + 152 + uintptr(order[libc.PostIncUint32(&(*Inflate_state)(unsafe.Pointer(state)).Fhave, 1)])*2)) = uint16(uint32(hold) & (uint32(1)<<3 - uint32(1)))
  9136  __113:
  9137  	hold >>= 3
  9138  	bits = bits - uint32(3)
  9139  	goto __114
  9140  __114:
  9141  	if 0 != 0 {
  9142  		goto __113
  9143  	}
  9144  	goto __115
  9145  __115:
  9146  	;
  9147  	goto __98
  9148  __99:
  9149  	;
  9150  __116:
  9151  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhave < uint32(19)) {
  9152  		goto __117
  9153  	}
  9154  	*(*uint16)(unsafe.Pointer(state + 152 + uintptr(order[libc.PostIncUint32(&(*Inflate_state)(unsafe.Pointer(state)).Fhave, 1)])*2)) = uint16(0)
  9155  	goto __116
  9156  __117:
  9157  	;
  9158  	(*Inflate_state)(unsafe.Pointer(state)).Fnext = state + 1368 /* &.codes */
  9159  	(*Inflate_state)(unsafe.Pointer(state)).Flencode = (*Inflate_state)(unsafe.Pointer(state)).Fnext
  9160  	(*Inflate_state)(unsafe.Pointer(state)).Flenbits = uint32(7)
  9161  	ret = Xinflate_table(tls, CODES, state+152, uint32(19), state+144,
  9162  		state+120, state+792)
  9163  	if !(ret != 0) {
  9164  		goto __118
  9165  	}
  9166  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 451 /* "invalid code len..." */
  9167  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
  9168  	goto __5
  9169  __118:
  9170  	;
  9171  
  9172  	// get length and distance code code lengths
  9173  	(*Inflate_state)(unsafe.Pointer(state)).Fhave = uint32(0)
  9174  __119:
  9175  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhave < (*Inflate_state)(unsafe.Pointer(state)).Fnlen+(*Inflate_state)(unsafe.Pointer(state)).Fndist) {
  9176  		goto __120
  9177  	}
  9178  __121:
  9179  	here = *(*Code)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Flencode + uintptr(uint32(hold)&(uint32(1)<<(*Inflate_state)(unsafe.Pointer(state)).Flenbits-uint32(1)))*4))
  9180  	if !(uint32(here.Fbits) <= bits) {
  9181  		goto __124
  9182  	}
  9183  	goto __123
  9184  __124:
  9185  	;
  9186  __125:
  9187  __128:
  9188  	if !(have == uint32(0)) {
  9189  		goto __131
  9190  	}
  9191  	have = (*struct {
  9192  		f func(*libc.TLS, uintptr, uintptr) uint32
  9193  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
  9194  	if !(have == uint32(0)) {
  9195  		goto __132
  9196  	}
  9197  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
  9198  	ret = -5
  9199  	goto inf_leave
  9200  __132:
  9201  	;
  9202  __131:
  9203  	;
  9204  	goto __129
  9205  __129:
  9206  	if 0 != 0 {
  9207  		goto __128
  9208  	}
  9209  	goto __130
  9210  __130:
  9211  	;
  9212  	have--
  9213  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(bp /* next */)), 1))))<<bits
  9214  	bits = bits + uint32(8)
  9215  	goto __126
  9216  __126:
  9217  	if 0 != 0 {
  9218  		goto __125
  9219  	}
  9220  	goto __127
  9221  __127:
  9222  	;
  9223  	goto __122
  9224  __122:
  9225  	goto __121
  9226  	goto __123
  9227  __123:
  9228  	;
  9229  	if !(int32(here.Fval) < 16) {
  9230  		goto __133
  9231  	}
  9232  __135:
  9233  	hold >>= int32(here.Fbits)
  9234  	bits = bits - uint32(here.Fbits)
  9235  	goto __136
  9236  __136:
  9237  	if 0 != 0 {
  9238  		goto __135
  9239  	}
  9240  	goto __137
  9241  __137:
  9242  	;
  9243  	*(*uint16)(unsafe.Pointer(state + 152 + uintptr(libc.PostIncUint32(&(*Inflate_state)(unsafe.Pointer(state)).Fhave, 1))*2)) = here.Fval
  9244  	goto __134
  9245  __133:
  9246  	if !(int32(here.Fval) == 16) {
  9247  		goto __138
  9248  	}
  9249  __140:
  9250  __143:
  9251  	if !(bits < uint32(int32(here.Fbits)+2)) {
  9252  		goto __144
  9253  	}
  9254  __145:
  9255  __148:
  9256  	if !(have == uint32(0)) {
  9257  		goto __151
  9258  	}
  9259  	have = (*struct {
  9260  		f func(*libc.TLS, uintptr, uintptr) uint32
  9261  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
  9262  	if !(have == uint32(0)) {
  9263  		goto __152
  9264  	}
  9265  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
  9266  	ret = -5
  9267  	goto inf_leave
  9268  __152:
  9269  	;
  9270  __151:
  9271  	;
  9272  	goto __149
  9273  __149:
  9274  	if 0 != 0 {
  9275  		goto __148
  9276  	}
  9277  	goto __150
  9278  __150:
  9279  	;
  9280  	have--
  9281  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(bp /* next */)), 1))))<<bits
  9282  	bits = bits + uint32(8)
  9283  	goto __146
  9284  __146:
  9285  	if 0 != 0 {
  9286  		goto __145
  9287  	}
  9288  	goto __147
  9289  __147:
  9290  	;
  9291  	goto __143
  9292  __144:
  9293  	;
  9294  	goto __141
  9295  __141:
  9296  	if 0 != 0 {
  9297  		goto __140
  9298  	}
  9299  	goto __142
  9300  __142:
  9301  	;
  9302  __153:
  9303  	hold >>= int32(here.Fbits)
  9304  	bits = bits - uint32(here.Fbits)
  9305  	goto __154
  9306  __154:
  9307  	if 0 != 0 {
  9308  		goto __153
  9309  	}
  9310  	goto __155
  9311  __155:
  9312  	;
  9313  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhave == uint32(0)) {
  9314  		goto __156
  9315  	}
  9316  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 476 /* "invalid bit leng..." */
  9317  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
  9318  	goto __120
  9319  __156:
  9320  	;
  9321  	len = uint32(*(*uint16)(unsafe.Pointer(state + 152 + uintptr((*Inflate_state)(unsafe.Pointer(state)).Fhave-uint32(1))*2)))
  9322  	copy = uint32(3) + uint32(hold)&(uint32(1)<<2-uint32(1))
  9323  __157:
  9324  	hold >>= 2
  9325  	bits = bits - uint32(2)
  9326  	goto __158
  9327  __158:
  9328  	if 0 != 0 {
  9329  		goto __157
  9330  	}
  9331  	goto __159
  9332  __159:
  9333  	;
  9334  	goto __139
  9335  __138:
  9336  	if !(int32(here.Fval) == 17) {
  9337  		goto __160
  9338  	}
  9339  __162:
  9340  __165:
  9341  	if !(bits < uint32(int32(here.Fbits)+3)) {
  9342  		goto __166
  9343  	}
  9344  __167:
  9345  __170:
  9346  	if !(have == uint32(0)) {
  9347  		goto __173
  9348  	}
  9349  	have = (*struct {
  9350  		f func(*libc.TLS, uintptr, uintptr) uint32
  9351  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
  9352  	if !(have == uint32(0)) {
  9353  		goto __174
  9354  	}
  9355  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
  9356  	ret = -5
  9357  	goto inf_leave
  9358  __174:
  9359  	;
  9360  __173:
  9361  	;
  9362  	goto __171
  9363  __171:
  9364  	if 0 != 0 {
  9365  		goto __170
  9366  	}
  9367  	goto __172
  9368  __172:
  9369  	;
  9370  	have--
  9371  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(bp /* next */)), 1))))<<bits
  9372  	bits = bits + uint32(8)
  9373  	goto __168
  9374  __168:
  9375  	if 0 != 0 {
  9376  		goto __167
  9377  	}
  9378  	goto __169
  9379  __169:
  9380  	;
  9381  	goto __165
  9382  __166:
  9383  	;
  9384  	goto __163
  9385  __163:
  9386  	if 0 != 0 {
  9387  		goto __162
  9388  	}
  9389  	goto __164
  9390  __164:
  9391  	;
  9392  __175:
  9393  	hold >>= int32(here.Fbits)
  9394  	bits = bits - uint32(here.Fbits)
  9395  	goto __176
  9396  __176:
  9397  	if 0 != 0 {
  9398  		goto __175
  9399  	}
  9400  	goto __177
  9401  __177:
  9402  	;
  9403  	len = uint32(0)
  9404  	copy = uint32(3) + uint32(hold)&(uint32(1)<<3-uint32(1))
  9405  __178:
  9406  	hold >>= 3
  9407  	bits = bits - uint32(3)
  9408  	goto __179
  9409  __179:
  9410  	if 0 != 0 {
  9411  		goto __178
  9412  	}
  9413  	goto __180
  9414  __180:
  9415  	;
  9416  	goto __161
  9417  __160:
  9418  __181:
  9419  __184:
  9420  	if !(bits < uint32(int32(here.Fbits)+7)) {
  9421  		goto __185
  9422  	}
  9423  __186:
  9424  __189:
  9425  	if !(have == uint32(0)) {
  9426  		goto __192
  9427  	}
  9428  	have = (*struct {
  9429  		f func(*libc.TLS, uintptr, uintptr) uint32
  9430  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
  9431  	if !(have == uint32(0)) {
  9432  		goto __193
  9433  	}
  9434  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
  9435  	ret = -5
  9436  	goto inf_leave
  9437  __193:
  9438  	;
  9439  __192:
  9440  	;
  9441  	goto __190
  9442  __190:
  9443  	if 0 != 0 {
  9444  		goto __189
  9445  	}
  9446  	goto __191
  9447  __191:
  9448  	;
  9449  	have--
  9450  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(bp /* next */)), 1))))<<bits
  9451  	bits = bits + uint32(8)
  9452  	goto __187
  9453  __187:
  9454  	if 0 != 0 {
  9455  		goto __186
  9456  	}
  9457  	goto __188
  9458  __188:
  9459  	;
  9460  	goto __184
  9461  __185:
  9462  	;
  9463  	goto __182
  9464  __182:
  9465  	if 0 != 0 {
  9466  		goto __181
  9467  	}
  9468  	goto __183
  9469  __183:
  9470  	;
  9471  __194:
  9472  	hold >>= int32(here.Fbits)
  9473  	bits = bits - uint32(here.Fbits)
  9474  	goto __195
  9475  __195:
  9476  	if 0 != 0 {
  9477  		goto __194
  9478  	}
  9479  	goto __196
  9480  __196:
  9481  	;
  9482  	len = uint32(0)
  9483  	copy = uint32(11) + uint32(hold)&(uint32(1)<<7-uint32(1))
  9484  __197:
  9485  	hold >>= 7
  9486  	bits = bits - uint32(7)
  9487  	goto __198
  9488  __198:
  9489  	if 0 != 0 {
  9490  		goto __197
  9491  	}
  9492  	goto __199
  9493  __199:
  9494  	;
  9495  __161:
  9496  	;
  9497  __139:
  9498  	;
  9499  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhave+copy > (*Inflate_state)(unsafe.Pointer(state)).Fnlen+(*Inflate_state)(unsafe.Pointer(state)).Fndist) {
  9500  		goto __200
  9501  	}
  9502  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 476 /* "invalid bit leng..." */
  9503  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
  9504  	goto __120
  9505  __200:
  9506  	;
  9507  __201:
  9508  	if !(libc.PostDecUint32(&copy, 1) != 0) {
  9509  		goto __202
  9510  	}
  9511  	*(*uint16)(unsafe.Pointer(state + 152 + uintptr(libc.PostIncUint32(&(*Inflate_state)(unsafe.Pointer(state)).Fhave, 1))*2)) = uint16(len)
  9512  	goto __201
  9513  __202:
  9514  	;
  9515  __134:
  9516  	;
  9517  	goto __119
  9518  __120:
  9519  	;
  9520  
  9521  	// handle error breaks in while
  9522  	if !((*Inflate_state)(unsafe.Pointer(state)).Fmode == BAD) {
  9523  		goto __203
  9524  	}
  9525  	goto __5
  9526  __203:
  9527  	;
  9528  
  9529  	// check for end-of-block code (better have one)
  9530  	if !(int32(*(*uint16)(unsafe.Pointer(state + 152 + 256*2))) == 0) {
  9531  		goto __204
  9532  	}
  9533  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 502 /* "invalid code -- ..." */
  9534  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
  9535  	goto __5
  9536  __204:
  9537  	;
  9538  
  9539  	// build code tables -- note: do not change the lenbits or distbits
  9540  	//                values here (9 and 6) without reading the comments in inftrees.h
  9541  	//                concerning the ENOUGH constants, which depend on those values
  9542  	(*Inflate_state)(unsafe.Pointer(state)).Fnext = state + 1368 /* &.codes */
  9543  	(*Inflate_state)(unsafe.Pointer(state)).Flencode = (*Inflate_state)(unsafe.Pointer(state)).Fnext
  9544  	(*Inflate_state)(unsafe.Pointer(state)).Flenbits = uint32(9)
  9545  	ret = Xinflate_table(tls, LENS, state+152, (*Inflate_state)(unsafe.Pointer(state)).Fnlen, state+144,
  9546  		state+120, state+792)
  9547  	if !(ret != 0) {
  9548  		goto __205
  9549  	}
  9550  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 539 /* "invalid literal/..." */
  9551  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
  9552  	goto __5
  9553  __205:
  9554  	;
  9555  	(*Inflate_state)(unsafe.Pointer(state)).Fdistcode = (*Inflate_state)(unsafe.Pointer(state)).Fnext
  9556  	(*Inflate_state)(unsafe.Pointer(state)).Fdistbits = uint32(6)
  9557  	ret = Xinflate_table(tls, DISTS, state+152+uintptr((*Inflate_state)(unsafe.Pointer(state)).Fnlen)*2, (*Inflate_state)(unsafe.Pointer(state)).Fndist,
  9558  		state+144, state+124, state+792)
  9559  	if !(ret != 0) {
  9560  		goto __206
  9561  	}
  9562  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 567 /* "invalid distance..." */
  9563  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
  9564  	goto __5
  9565  __206:
  9566  	;
  9567  
  9568  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = LEN
  9569  
  9570  __9:
  9571  	// use inflate_fast() if we have enough input and output
  9572  	if !(have >= uint32(6) && left >= uint32(258)) {
  9573  		goto __207
  9574  	}
  9575  __208:
  9576  	(*Z_stream)(unsafe.Pointer(strm)).Fnext_out = put
  9577  	(*Z_stream)(unsafe.Pointer(strm)).Favail_out = left
  9578  	(*Z_stream)(unsafe.Pointer(strm)).Fnext_in = *(*uintptr)(unsafe.Pointer(bp /* next */))
  9579  	(*Z_stream)(unsafe.Pointer(strm)).Favail_in = have
  9580  	(*Inflate_state)(unsafe.Pointer(state)).Fhold = hold
  9581  	(*Inflate_state)(unsafe.Pointer(state)).Fbits = bits
  9582  	goto __209
  9583  __209:
  9584  	if 0 != 0 {
  9585  		goto __208
  9586  	}
  9587  	goto __210
  9588  __210:
  9589  	;
  9590  	if !((*Inflate_state)(unsafe.Pointer(state)).Fwhave < (*Inflate_state)(unsafe.Pointer(state)).Fwsize) {
  9591  		goto __211
  9592  	}
  9593  	(*Inflate_state)(unsafe.Pointer(state)).Fwhave = (*Inflate_state)(unsafe.Pointer(state)).Fwsize - left
  9594  __211:
  9595  	;
  9596  	Xinflate_fast(tls, strm, (*Inflate_state)(unsafe.Pointer(state)).Fwsize)
  9597  __212:
  9598  	put = (*Z_stream)(unsafe.Pointer(strm)).Fnext_out
  9599  	left = (*Z_stream)(unsafe.Pointer(strm)).Favail_out
  9600  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = (*Z_stream)(unsafe.Pointer(strm)).Fnext_in
  9601  	have = (*Z_stream)(unsafe.Pointer(strm)).Favail_in
  9602  	hold = (*Inflate_state)(unsafe.Pointer(state)).Fhold
  9603  	bits = (*Inflate_state)(unsafe.Pointer(state)).Fbits
  9604  	goto __213
  9605  __213:
  9606  	if 0 != 0 {
  9607  		goto __212
  9608  	}
  9609  	goto __214
  9610  __214:
  9611  	;
  9612  	goto __5
  9613  __207:
  9614  	;
  9615  
  9616  	// get a literal, length, or end-of-block code
  9617  __215:
  9618  	here = *(*Code)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Flencode + uintptr(uint32(hold)&(uint32(1)<<(*Inflate_state)(unsafe.Pointer(state)).Flenbits-uint32(1)))*4))
  9619  	if !(uint32(here.Fbits) <= bits) {
  9620  		goto __218
  9621  	}
  9622  	goto __217
  9623  __218:
  9624  	;
  9625  __219:
  9626  __222:
  9627  	if !(have == uint32(0)) {
  9628  		goto __225
  9629  	}
  9630  	have = (*struct {
  9631  		f func(*libc.TLS, uintptr, uintptr) uint32
  9632  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
  9633  	if !(have == uint32(0)) {
  9634  		goto __226
  9635  	}
  9636  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
  9637  	ret = -5
  9638  	goto inf_leave
  9639  __226:
  9640  	;
  9641  __225:
  9642  	;
  9643  	goto __223
  9644  __223:
  9645  	if 0 != 0 {
  9646  		goto __222
  9647  	}
  9648  	goto __224
  9649  __224:
  9650  	;
  9651  	have--
  9652  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(bp /* next */)), 1))))<<bits
  9653  	bits = bits + uint32(8)
  9654  	goto __220
  9655  __220:
  9656  	if 0 != 0 {
  9657  		goto __219
  9658  	}
  9659  	goto __221
  9660  __221:
  9661  	;
  9662  	goto __216
  9663  __216:
  9664  	goto __215
  9665  	goto __217
  9666  __217:
  9667  	;
  9668  	if !(here.Fop != 0 && int32(here.Fop)&0xf0 == 0) {
  9669  		goto __227
  9670  	}
  9671  	last = here
  9672  __228:
  9673  	here = *(*Code)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Flencode + uintptr(uint32(last.Fval)+uint32(hold)&(uint32(1)<<(int32(last.Fbits)+int32(last.Fop))-uint32(1))>>int32(last.Fbits))*4))
  9674  	if !(uint32(int32(last.Fbits)+int32(here.Fbits)) <= bits) {
  9675  		goto __231
  9676  	}
  9677  	goto __230
  9678  __231:
  9679  	;
  9680  __232:
  9681  __235:
  9682  	if !(have == uint32(0)) {
  9683  		goto __238
  9684  	}
  9685  	have = (*struct {
  9686  		f func(*libc.TLS, uintptr, uintptr) uint32
  9687  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
  9688  	if !(have == uint32(0)) {
  9689  		goto __239
  9690  	}
  9691  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
  9692  	ret = -5
  9693  	goto inf_leave
  9694  __239:
  9695  	;
  9696  __238:
  9697  	;
  9698  	goto __236
  9699  __236:
  9700  	if 0 != 0 {
  9701  		goto __235
  9702  	}
  9703  	goto __237
  9704  __237:
  9705  	;
  9706  	have--
  9707  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(bp /* next */)), 1))))<<bits
  9708  	bits = bits + uint32(8)
  9709  	goto __233
  9710  __233:
  9711  	if 0 != 0 {
  9712  		goto __232
  9713  	}
  9714  	goto __234
  9715  __234:
  9716  	;
  9717  	goto __229
  9718  __229:
  9719  	goto __228
  9720  	goto __230
  9721  __230:
  9722  	;
  9723  __240:
  9724  	hold >>= int32(last.Fbits)
  9725  	bits = bits - uint32(last.Fbits)
  9726  	goto __241
  9727  __241:
  9728  	if 0 != 0 {
  9729  		goto __240
  9730  	}
  9731  	goto __242
  9732  __242:
  9733  	;
  9734  __227:
  9735  	;
  9736  __243:
  9737  	hold >>= int32(here.Fbits)
  9738  	bits = bits - uint32(here.Fbits)
  9739  	goto __244
  9740  __244:
  9741  	if 0 != 0 {
  9742  		goto __243
  9743  	}
  9744  	goto __245
  9745  __245:
  9746  	;
  9747  	(*Inflate_state)(unsafe.Pointer(state)).Flength = uint32(here.Fval)
  9748  
  9749  	// process literal
  9750  	if !(int32(here.Fop) == 0) {
  9751  		goto __246
  9752  	}
  9753  
  9754  __247:
  9755  	if !(left == uint32(0)) {
  9756  		goto __250
  9757  	}
  9758  	put = (*Inflate_state)(unsafe.Pointer(state)).Fwindow
  9759  	left = (*Inflate_state)(unsafe.Pointer(state)).Fwsize
  9760  	(*Inflate_state)(unsafe.Pointer(state)).Fwhave = left
  9761  	if !((*struct {
  9762  		f func(*libc.TLS, uintptr, uintptr, uint32) int32
  9763  	})(unsafe.Pointer(&struct{ uintptr }{out})).f(tls, out_desc, put, left) != 0) {
  9764  		goto __251
  9765  	}
  9766  	ret = -5
  9767  	goto inf_leave
  9768  __251:
  9769  	;
  9770  __250:
  9771  	;
  9772  	goto __248
  9773  __248:
  9774  	if 0 != 0 {
  9775  		goto __247
  9776  	}
  9777  	goto __249
  9778  __249:
  9779  	;
  9780  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&put, 1))) = uint8((*Inflate_state)(unsafe.Pointer(state)).Flength)
  9781  	left--
  9782  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = LEN
  9783  	goto __5
  9784  __246:
  9785  	;
  9786  
  9787  	// process end of block
  9788  	if !(int32(here.Fop)&32 != 0) {
  9789  		goto __252
  9790  	}
  9791  
  9792  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = TYPE
  9793  	goto __5
  9794  __252:
  9795  	;
  9796  
  9797  	// invalid code
  9798  	if !(int32(here.Fop)&64 != 0) {
  9799  		goto __253
  9800  	}
  9801  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 589 /* "invalid literal/..." */
  9802  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
  9803  	goto __5
  9804  __253:
  9805  	;
  9806  
  9807  	// length code -- get extra bits, if any
  9808  	(*Inflate_state)(unsafe.Pointer(state)).Fextra = uint32(here.Fop) & uint32(15)
  9809  	if !((*Inflate_state)(unsafe.Pointer(state)).Fextra != uint32(0)) {
  9810  		goto __254
  9811  	}
  9812  __255:
  9813  __258:
  9814  	if !(bits < (*Inflate_state)(unsafe.Pointer(state)).Fextra) {
  9815  		goto __259
  9816  	}
  9817  __260:
  9818  __263:
  9819  	if !(have == uint32(0)) {
  9820  		goto __266
  9821  	}
  9822  	have = (*struct {
  9823  		f func(*libc.TLS, uintptr, uintptr) uint32
  9824  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
  9825  	if !(have == uint32(0)) {
  9826  		goto __267
  9827  	}
  9828  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
  9829  	ret = -5
  9830  	goto inf_leave
  9831  __267:
  9832  	;
  9833  __266:
  9834  	;
  9835  	goto __264
  9836  __264:
  9837  	if 0 != 0 {
  9838  		goto __263
  9839  	}
  9840  	goto __265
  9841  __265:
  9842  	;
  9843  	have--
  9844  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(bp /* next */)), 1))))<<bits
  9845  	bits = bits + uint32(8)
  9846  	goto __261
  9847  __261:
  9848  	if 0 != 0 {
  9849  		goto __260
  9850  	}
  9851  	goto __262
  9852  __262:
  9853  	;
  9854  	goto __258
  9855  __259:
  9856  	;
  9857  	goto __256
  9858  __256:
  9859  	if 0 != 0 {
  9860  		goto __255
  9861  	}
  9862  	goto __257
  9863  __257:
  9864  	;
  9865  	*(*uint32)(unsafe.Pointer(state + 92)) += uint32(hold) & (uint32(1)<<(*Inflate_state)(unsafe.Pointer(state)).Fextra - uint32(1))
  9866  __268:
  9867  	hold >>= (*Inflate_state)(unsafe.Pointer(state)).Fextra
  9868  	bits = bits - (*Inflate_state)(unsafe.Pointer(state)).Fextra
  9869  	goto __269
  9870  __269:
  9871  	if 0 != 0 {
  9872  		goto __268
  9873  	}
  9874  	goto __270
  9875  __270:
  9876  	;
  9877  __254:
  9878  	;
  9879  
  9880  	// get distance code
  9881  __271:
  9882  	here = *(*Code)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fdistcode + uintptr(uint32(hold)&(uint32(1)<<(*Inflate_state)(unsafe.Pointer(state)).Fdistbits-uint32(1)))*4))
  9883  	if !(uint32(here.Fbits) <= bits) {
  9884  		goto __274
  9885  	}
  9886  	goto __273
  9887  __274:
  9888  	;
  9889  __275:
  9890  __278:
  9891  	if !(have == uint32(0)) {
  9892  		goto __281
  9893  	}
  9894  	have = (*struct {
  9895  		f func(*libc.TLS, uintptr, uintptr) uint32
  9896  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
  9897  	if !(have == uint32(0)) {
  9898  		goto __282
  9899  	}
  9900  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
  9901  	ret = -5
  9902  	goto inf_leave
  9903  __282:
  9904  	;
  9905  __281:
  9906  	;
  9907  	goto __279
  9908  __279:
  9909  	if 0 != 0 {
  9910  		goto __278
  9911  	}
  9912  	goto __280
  9913  __280:
  9914  	;
  9915  	have--
  9916  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(bp /* next */)), 1))))<<bits
  9917  	bits = bits + uint32(8)
  9918  	goto __276
  9919  __276:
  9920  	if 0 != 0 {
  9921  		goto __275
  9922  	}
  9923  	goto __277
  9924  __277:
  9925  	;
  9926  	goto __272
  9927  __272:
  9928  	goto __271
  9929  	goto __273
  9930  __273:
  9931  	;
  9932  	if !(int32(here.Fop)&0xf0 == 0) {
  9933  		goto __283
  9934  	}
  9935  	last = here
  9936  __284:
  9937  	here = *(*Code)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fdistcode + uintptr(uint32(last.Fval)+uint32(hold)&(uint32(1)<<(int32(last.Fbits)+int32(last.Fop))-uint32(1))>>int32(last.Fbits))*4))
  9938  	if !(uint32(int32(last.Fbits)+int32(here.Fbits)) <= bits) {
  9939  		goto __287
  9940  	}
  9941  	goto __286
  9942  __287:
  9943  	;
  9944  __288:
  9945  __291:
  9946  	if !(have == uint32(0)) {
  9947  		goto __294
  9948  	}
  9949  	have = (*struct {
  9950  		f func(*libc.TLS, uintptr, uintptr) uint32
  9951  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
  9952  	if !(have == uint32(0)) {
  9953  		goto __295
  9954  	}
  9955  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
  9956  	ret = -5
  9957  	goto inf_leave
  9958  __295:
  9959  	;
  9960  __294:
  9961  	;
  9962  	goto __292
  9963  __292:
  9964  	if 0 != 0 {
  9965  		goto __291
  9966  	}
  9967  	goto __293
  9968  __293:
  9969  	;
  9970  	have--
  9971  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(bp /* next */)), 1))))<<bits
  9972  	bits = bits + uint32(8)
  9973  	goto __289
  9974  __289:
  9975  	if 0 != 0 {
  9976  		goto __288
  9977  	}
  9978  	goto __290
  9979  __290:
  9980  	;
  9981  	goto __285
  9982  __285:
  9983  	goto __284
  9984  	goto __286
  9985  __286:
  9986  	;
  9987  __296:
  9988  	hold >>= int32(last.Fbits)
  9989  	bits = bits - uint32(last.Fbits)
  9990  	goto __297
  9991  __297:
  9992  	if 0 != 0 {
  9993  		goto __296
  9994  	}
  9995  	goto __298
  9996  __298:
  9997  	;
  9998  __283:
  9999  	;
 10000  __299:
 10001  	hold >>= int32(here.Fbits)
 10002  	bits = bits - uint32(here.Fbits)
 10003  	goto __300
 10004  __300:
 10005  	if 0 != 0 {
 10006  		goto __299
 10007  	}
 10008  	goto __301
 10009  __301:
 10010  	;
 10011  	if !(int32(here.Fop)&64 != 0) {
 10012  		goto __302
 10013  	}
 10014  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 617 /* "invalid distance..." */
 10015  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 10016  	goto __5
 10017  __302:
 10018  	;
 10019  	(*Inflate_state)(unsafe.Pointer(state)).Foffset = uint32(here.Fval)
 10020  
 10021  	// get distance extra bits, if any
 10022  	(*Inflate_state)(unsafe.Pointer(state)).Fextra = uint32(here.Fop) & uint32(15)
 10023  	if !((*Inflate_state)(unsafe.Pointer(state)).Fextra != uint32(0)) {
 10024  		goto __303
 10025  	}
 10026  __304:
 10027  __307:
 10028  	if !(bits < (*Inflate_state)(unsafe.Pointer(state)).Fextra) {
 10029  		goto __308
 10030  	}
 10031  __309:
 10032  __312:
 10033  	if !(have == uint32(0)) {
 10034  		goto __315
 10035  	}
 10036  	have = (*struct {
 10037  		f func(*libc.TLS, uintptr, uintptr) uint32
 10038  	})(unsafe.Pointer(&struct{ uintptr }{in})).f(tls, in_desc, bp /* &next */)
 10039  	if !(have == uint32(0)) {
 10040  		goto __316
 10041  	}
 10042  	*(*uintptr)(unsafe.Pointer(bp /* next */)) = uintptr(Z_NULL)
 10043  	ret = -5
 10044  	goto inf_leave
 10045  __316:
 10046  	;
 10047  __315:
 10048  	;
 10049  	goto __313
 10050  __313:
 10051  	if 0 != 0 {
 10052  		goto __312
 10053  	}
 10054  	goto __314
 10055  __314:
 10056  	;
 10057  	have--
 10058  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(bp /* next */)), 1))))<<bits
 10059  	bits = bits + uint32(8)
 10060  	goto __310
 10061  __310:
 10062  	if 0 != 0 {
 10063  		goto __309
 10064  	}
 10065  	goto __311
 10066  __311:
 10067  	;
 10068  	goto __307
 10069  __308:
 10070  	;
 10071  	goto __305
 10072  __305:
 10073  	if 0 != 0 {
 10074  		goto __304
 10075  	}
 10076  	goto __306
 10077  __306:
 10078  	;
 10079  	*(*uint32)(unsafe.Pointer(state + 96)) += uint32(hold) & (uint32(1)<<(*Inflate_state)(unsafe.Pointer(state)).Fextra - uint32(1))
 10080  __317:
 10081  	hold >>= (*Inflate_state)(unsafe.Pointer(state)).Fextra
 10082  	bits = bits - (*Inflate_state)(unsafe.Pointer(state)).Fextra
 10083  	goto __318
 10084  __318:
 10085  	if 0 != 0 {
 10086  		goto __317
 10087  	}
 10088  	goto __319
 10089  __319:
 10090  	;
 10091  __303:
 10092  	;
 10093  	if !((*Inflate_state)(unsafe.Pointer(state)).Foffset > (*Inflate_state)(unsafe.Pointer(state)).Fwsize-func() uint32 {
 10094  		if (*Inflate_state)(unsafe.Pointer(state)).Fwhave < (*Inflate_state)(unsafe.Pointer(state)).Fwsize {
 10095  			return left
 10096  		}
 10097  		return uint32(0)
 10098  	}()) {
 10099  		goto __320
 10100  	}
 10101  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 639 /* "invalid distance..." */
 10102  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 10103  	goto __5
 10104  __320:
 10105  	;
 10106  
 10107  	// copy match from window to output
 10108  __321:
 10109  __324:
 10110  	if !(left == uint32(0)) {
 10111  		goto __327
 10112  	}
 10113  	put = (*Inflate_state)(unsafe.Pointer(state)).Fwindow
 10114  	left = (*Inflate_state)(unsafe.Pointer(state)).Fwsize
 10115  	(*Inflate_state)(unsafe.Pointer(state)).Fwhave = left
 10116  	if !((*struct {
 10117  		f func(*libc.TLS, uintptr, uintptr, uint32) int32
 10118  	})(unsafe.Pointer(&struct{ uintptr }{out})).f(tls, out_desc, put, left) != 0) {
 10119  		goto __328
 10120  	}
 10121  	ret = -5
 10122  	goto inf_leave
 10123  __328:
 10124  	;
 10125  __327:
 10126  	;
 10127  	goto __325
 10128  __325:
 10129  	if 0 != 0 {
 10130  		goto __324
 10131  	}
 10132  	goto __326
 10133  __326:
 10134  	;
 10135  	copy = (*Inflate_state)(unsafe.Pointer(state)).Fwsize - (*Inflate_state)(unsafe.Pointer(state)).Foffset
 10136  	if !(copy < left) {
 10137  		goto __329
 10138  	}
 10139  	from = put + uintptr(copy)
 10140  	copy = left - copy
 10141  	goto __330
 10142  __329:
 10143  	from = put - uintptr((*Inflate_state)(unsafe.Pointer(state)).Foffset)
 10144  	copy = left
 10145  __330:
 10146  	;
 10147  	if !(copy > (*Inflate_state)(unsafe.Pointer(state)).Flength) {
 10148  		goto __331
 10149  	}
 10150  	copy = (*Inflate_state)(unsafe.Pointer(state)).Flength
 10151  __331:
 10152  	;
 10153  	*(*uint32)(unsafe.Pointer(state + 92)) -= copy
 10154  	left = left - copy
 10155  __332:
 10156  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&put, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10157  	goto __333
 10158  __333:
 10159  	if libc.PreDecUint32(&copy, 1) != 0 {
 10160  		goto __332
 10161  	}
 10162  	goto __334
 10163  __334:
 10164  	;
 10165  	goto __322
 10166  __322:
 10167  	if (*Inflate_state)(unsafe.Pointer(state)).Flength != uint32(0) {
 10168  		goto __321
 10169  	}
 10170  	goto __323
 10171  __323:
 10172  	;
 10173  	goto __5
 10174  
 10175  __10:
 10176  	// inflate stream terminated properly -- write leftover output
 10177  	ret = Z_STREAM_END
 10178  	if !(left < (*Inflate_state)(unsafe.Pointer(state)).Fwsize) {
 10179  		goto __335
 10180  	}
 10181  	if !((*struct {
 10182  		f func(*libc.TLS, uintptr, uintptr, uint32) int32
 10183  	})(unsafe.Pointer(&struct{ uintptr }{out})).f(tls, out_desc, (*Inflate_state)(unsafe.Pointer(state)).Fwindow, (*Inflate_state)(unsafe.Pointer(state)).Fwsize-left) != 0) {
 10184  		goto __336
 10185  	}
 10186  	ret = -5
 10187  __336:
 10188  	;
 10189  __335:
 10190  	;
 10191  	goto inf_leave
 10192  
 10193  __11:
 10194  	ret = -3
 10195  	goto inf_leave
 10196  
 10197  __12: // can't happen, but makes compilers happy
 10198  	ret = -2
 10199  	goto inf_leave
 10200  __5:
 10201  	;
 10202  	goto __3
 10203  __3:
 10204  	goto __2
 10205  	goto __4
 10206  __4:
 10207  	;
 10208  
 10209  	// Return unused input
 10210  inf_leave:
 10211  	(*Z_stream)(unsafe.Pointer(strm)).Fnext_in = *(*uintptr)(unsafe.Pointer(bp /* next */))
 10212  	(*Z_stream)(unsafe.Pointer(strm)).Favail_in = have
 10213  	return ret
 10214  }
 10215  
 10216  var order =                                                                                                                                                                                                                          // permutation of code lengths
 10217  [19]uint16{uint16(16), uint16(17), uint16(18), uint16(0), uint16(8), uint16(7), uint16(9), uint16(6), uint16(10), uint16(5), uint16(11), uint16(4), uint16(12), uint16(3), uint16(13), uint16(2), uint16(14), uint16(1), uint16(15)} /* infback.c:269:33 */
 10218  
 10219  func XinflateBackEnd(tls *libc.TLS, strm Z_streamp) int32 { /* infback.c:631:13: */
 10220  	if strm == uintptr(Z_NULL) || (*Z_stream)(unsafe.Pointer(strm)).Fstate == uintptr(Z_NULL) || (*Z_stream)(unsafe.Pointer(strm)).Fzfree == uintptr(0) {
 10221  		return -2
 10222  	}
 10223  	(*struct {
 10224  		f func(*libc.TLS, Voidpf, Voidpf)
 10225  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzfree})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, (*Z_stream)(unsafe.Pointer(strm)).Fstate)
 10226  	(*Z_stream)(unsafe.Pointer(strm)).Fstate = uintptr(Z_NULL)
 10227  
 10228  	return Z_OK
 10229  }
 10230  
 10231  //
 10232  //    Decode literal, length, and distance codes and write out the resulting
 10233  //    literal and match bytes until either not enough input or output is
 10234  //    available, an end-of-block is encountered, or a data error is encountered.
 10235  //    When large enough input and output buffers are supplied to inflate(), for
 10236  //    example, a 16K input buffer and a 64K output buffer, more than 95% of the
 10237  //    inflate execution time is spent in this routine.
 10238  //
 10239  //    Entry assumptions:
 10240  //
 10241  //         state->mode == LEN
 10242  //         strm->avail_in >= 6
 10243  //         strm->avail_out >= 258
 10244  //         start >= strm->avail_out
 10245  //         state->bits < 8
 10246  //
 10247  //    On return, state->mode is one of:
 10248  //
 10249  //         LEN -- ran out of enough output space or enough available input
 10250  //         TYPE -- reached end of block code, inflate() to interpret next block
 10251  //         BAD -- error in block data
 10252  //
 10253  //    Notes:
 10254  //
 10255  //     - The maximum input bits used by a length/distance pair is 15 bits for the
 10256  //       length code, 5 bits for the length extra, 15 bits for the distance code,
 10257  //       and 13 bits for the distance extra.  This totals 48 bits, or six bytes.
 10258  //       Therefore if strm->avail_in >= 6, then there is enough input to avoid
 10259  //       checking for available input while decoding.
 10260  //
 10261  //     - The maximum bytes that a single length/distance pair can output is 258
 10262  //       bytes, which is the maximum length that can be coded.  inflate_fast()
 10263  //       requires strm->avail_out >= 258 for each loop to avoid checking for
 10264  //       output space.
 10265  //
 10266  func Xinflate_fast(tls *libc.TLS, strm Z_streamp, start uint32) { /* inffast.c:50:20: */
 10267  	var state uintptr
 10268  	var in uintptr     // local strm->next_in
 10269  	var last uintptr   // have enough input while in < last
 10270  	var out uintptr    // local strm->next_out
 10271  	var beg uintptr    // inflate()'s initial strm->next_out
 10272  	var end uintptr    // while out < end, enough space available
 10273  	var wsize uint32   // window size or zero if not using window
 10274  	var whave uint32   // valid bytes in the window
 10275  	var wnext uint32   // window write index
 10276  	var window uintptr // allocated sliding window, if wsize != 0
 10277  	var hold uint64    // local strm->hold
 10278  	var bits uint32    // local strm->bits
 10279  	var lcode uintptr  // local strm->lencode
 10280  	var dcode uintptr  // local strm->distcode
 10281  	var lmask uint32   // mask for first level of length codes
 10282  	var dmask uint32   // mask for first level of distance codes
 10283  	var here Code      // retrieved table entry
 10284  	var op uint32      // code bits, operation, extra bits, or
 10285  	//  window position, window bytes to copy
 10286  	var len uint32   // match length, unused bytes
 10287  	var dist uint32  // match distance
 10288  	var from uintptr // where to copy match from
 10289  
 10290  	// copy state to local variables
 10291  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 10292  	in = (*Z_stream)(unsafe.Pointer(strm)).Fnext_in
 10293  	last = in + uintptr((*Z_stream)(unsafe.Pointer(strm)).Favail_in-UInt(5))
 10294  	out = (*Z_stream)(unsafe.Pointer(strm)).Fnext_out
 10295  	beg = out - uintptr(start-(*Z_stream)(unsafe.Pointer(strm)).Favail_out)
 10296  	end = out + uintptr((*Z_stream)(unsafe.Pointer(strm)).Favail_out-UInt(257))
 10297  	wsize = (*Inflate_state)(unsafe.Pointer(state)).Fwsize
 10298  	whave = (*Inflate_state)(unsafe.Pointer(state)).Fwhave
 10299  	wnext = (*Inflate_state)(unsafe.Pointer(state)).Fwnext
 10300  	window = (*Inflate_state)(unsafe.Pointer(state)).Fwindow
 10301  	hold = (*Inflate_state)(unsafe.Pointer(state)).Fhold
 10302  	bits = (*Inflate_state)(unsafe.Pointer(state)).Fbits
 10303  	lcode = (*Inflate_state)(unsafe.Pointer(state)).Flencode
 10304  	dcode = (*Inflate_state)(unsafe.Pointer(state)).Fdistcode
 10305  	lmask = uint32(1)<<(*Inflate_state)(unsafe.Pointer(state)).Flenbits - uint32(1)
 10306  	dmask = uint32(1)<<(*Inflate_state)(unsafe.Pointer(state)).Fdistbits - uint32(1)
 10307  
 10308  	// decode literals and length/distances until end-of-block or not enough
 10309  	//        input data or output space
 10310  __1:
 10311  	if !(bits < uint32(15)) {
 10312  		goto __4
 10313  	}
 10314  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&in, 1))))<<bits
 10315  	bits = bits + uint32(8)
 10316  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&in, 1))))<<bits
 10317  	bits = bits + uint32(8)
 10318  __4:
 10319  	;
 10320  	here = *(*Code)(unsafe.Pointer(lcode + uintptr(hold&uint64(lmask))*4))
 10321  dolen:
 10322  	op = uint32(here.Fbits)
 10323  	hold >>= op
 10324  	bits = bits - op
 10325  	op = uint32(here.Fop)
 10326  	if !(op == uint32(0)) {
 10327  		goto __5
 10328  	} // literal
 10329  
 10330  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = uint8(here.Fval)
 10331  	goto __6
 10332  __5:
 10333  	if !(op&uint32(16) != 0) {
 10334  		goto __7
 10335  	} // length base
 10336  	len = uint32(here.Fval)
 10337  	op = op & uint32(15) // number of extra bits
 10338  	if !(op != 0) {
 10339  		goto __9
 10340  	}
 10341  	if !(bits < op) {
 10342  		goto __10
 10343  	}
 10344  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&in, 1))))<<bits
 10345  	bits = bits + uint32(8)
 10346  __10:
 10347  	;
 10348  	len = len + uint32(hold)&(uint32(1)<<op-uint32(1))
 10349  	hold >>= op
 10350  	bits = bits - op
 10351  __9:
 10352  	;
 10353  
 10354  	if !(bits < uint32(15)) {
 10355  		goto __11
 10356  	}
 10357  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&in, 1))))<<bits
 10358  	bits = bits + uint32(8)
 10359  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&in, 1))))<<bits
 10360  	bits = bits + uint32(8)
 10361  __11:
 10362  	;
 10363  	here = *(*Code)(unsafe.Pointer(dcode + uintptr(hold&uint64(dmask))*4))
 10364  dodist:
 10365  	op = uint32(here.Fbits)
 10366  	hold >>= op
 10367  	bits = bits - op
 10368  	op = uint32(here.Fop)
 10369  	if !(op&uint32(16) != 0) {
 10370  		goto __12
 10371  	} // distance base
 10372  	dist = uint32(here.Fval)
 10373  	op = op & uint32(15) // number of extra bits
 10374  	if !(bits < op) {
 10375  		goto __14
 10376  	}
 10377  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&in, 1))))<<bits
 10378  	bits = bits + uint32(8)
 10379  	if !(bits < op) {
 10380  		goto __15
 10381  	}
 10382  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&in, 1))))<<bits
 10383  	bits = bits + uint32(8)
 10384  __15:
 10385  	;
 10386  __14:
 10387  	;
 10388  	dist = dist + uint32(hold)&(uint32(1)<<op-uint32(1))
 10389  	hold >>= op
 10390  	bits = bits - op
 10391  
 10392  	op = uint32((int64(out) - int64(beg)) / 1) // max distance in output
 10393  	if !(dist > op) {
 10394  		goto __16
 10395  	} // see if copy from window
 10396  	op = dist - op // distance back in window
 10397  	if !(op > whave) {
 10398  		goto __18
 10399  	}
 10400  	if !((*Inflate_state)(unsafe.Pointer(state)).Fsane != 0) {
 10401  		goto __19
 10402  	}
 10403  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 639 /* "invalid distance..." */
 10404  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 10405  	goto __3
 10406  __19:
 10407  	;
 10408  __18:
 10409  	;
 10410  	from = window
 10411  	if !(wnext == uint32(0)) {
 10412  		goto __20
 10413  	} // very common case
 10414  	from += uintptr(wsize - op)
 10415  	if !(op < len) {
 10416  		goto __22
 10417  	} // some from window
 10418  	len = len - op
 10419  __23:
 10420  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10421  	goto __24
 10422  __24:
 10423  	if libc.PreDecUint32(&op, 1) != 0 {
 10424  		goto __23
 10425  	}
 10426  	goto __25
 10427  __25:
 10428  	;
 10429  	from = out - uintptr(dist) // rest from output
 10430  __22:
 10431  	;
 10432  	goto __21
 10433  __20:
 10434  	if !(wnext < op) {
 10435  		goto __26
 10436  	} // wrap around window
 10437  	from += uintptr(wsize + wnext - op)
 10438  	op = op - wnext
 10439  	if !(op < len) {
 10440  		goto __28
 10441  	} // some from end of window
 10442  	len = len - op
 10443  __29:
 10444  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10445  	goto __30
 10446  __30:
 10447  	if libc.PreDecUint32(&op, 1) != 0 {
 10448  		goto __29
 10449  	}
 10450  	goto __31
 10451  __31:
 10452  	;
 10453  	from = window
 10454  	if !(wnext < len) {
 10455  		goto __32
 10456  	} // some from start of window
 10457  	op = wnext
 10458  	len = len - op
 10459  __33:
 10460  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10461  	goto __34
 10462  __34:
 10463  	if libc.PreDecUint32(&op, 1) != 0 {
 10464  		goto __33
 10465  	}
 10466  	goto __35
 10467  __35:
 10468  	;
 10469  	from = out - uintptr(dist) // rest from output
 10470  __32:
 10471  	;
 10472  __28:
 10473  	;
 10474  	goto __27
 10475  __26: // contiguous in window
 10476  	from += uintptr(wnext - op)
 10477  	if !(op < len) {
 10478  		goto __36
 10479  	} // some from window
 10480  	len = len - op
 10481  __37:
 10482  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10483  	goto __38
 10484  __38:
 10485  	if libc.PreDecUint32(&op, 1) != 0 {
 10486  		goto __37
 10487  	}
 10488  	goto __39
 10489  __39:
 10490  	;
 10491  	from = out - uintptr(dist) // rest from output
 10492  __36:
 10493  	;
 10494  __27:
 10495  	;
 10496  __21:
 10497  	;
 10498  __40:
 10499  	if !(len > uint32(2)) {
 10500  		goto __41
 10501  	}
 10502  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10503  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10504  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10505  	len = len - uint32(3)
 10506  	goto __40
 10507  __41:
 10508  	;
 10509  	if !(len != 0) {
 10510  		goto __42
 10511  	}
 10512  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10513  	if !(len > uint32(1)) {
 10514  		goto __43
 10515  	}
 10516  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10517  __43:
 10518  	;
 10519  __42:
 10520  	;
 10521  	goto __17
 10522  __16:
 10523  	from = out - uintptr(dist) // copy direct from output
 10524  __44: // minimum length is three
 10525  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10526  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10527  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10528  	len = len - uint32(3)
 10529  	goto __45
 10530  __45:
 10531  	if len > uint32(2) {
 10532  		goto __44
 10533  	}
 10534  	goto __46
 10535  __46:
 10536  	;
 10537  	if !(len != 0) {
 10538  		goto __47
 10539  	}
 10540  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10541  	if !(len > uint32(1)) {
 10542  		goto __48
 10543  	}
 10544  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&out, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 10545  __48:
 10546  	;
 10547  __47:
 10548  	;
 10549  __17:
 10550  	;
 10551  	goto __13
 10552  __12:
 10553  	if !(op&uint32(64) == uint32(0)) {
 10554  		goto __49
 10555  	} // 2nd level distance code
 10556  	here = *(*Code)(unsafe.Pointer(dcode + uintptr(uint64(here.Fval)+hold&uint64(uint32(1)<<op-uint32(1)))*4))
 10557  	goto dodist
 10558  	goto __50
 10559  __49:
 10560  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 617 /* "invalid distance..." */
 10561  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 10562  	goto __3
 10563  __50:
 10564  	;
 10565  __13:
 10566  	;
 10567  	goto __8
 10568  __7:
 10569  	if !(op&uint32(64) == uint32(0)) {
 10570  		goto __51
 10571  	} // 2nd level length code
 10572  	here = *(*Code)(unsafe.Pointer(lcode + uintptr(uint64(here.Fval)+hold&uint64(uint32(1)<<op-uint32(1)))*4))
 10573  	goto dolen
 10574  	goto __52
 10575  __51:
 10576  	if !(op&uint32(32) != 0) {
 10577  		goto __53
 10578  	} // end-of-block
 10579  
 10580  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = TYPE
 10581  	goto __3
 10582  	goto __54
 10583  __53:
 10584  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 589 /* "invalid literal/..." */
 10585  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 10586  	goto __3
 10587  __54:
 10588  	;
 10589  __52:
 10590  	;
 10591  __8:
 10592  	;
 10593  __6:
 10594  	;
 10595  	goto __2
 10596  __2:
 10597  	if in < last && out < end {
 10598  		goto __1
 10599  	}
 10600  	goto __3
 10601  __3:
 10602  	;
 10603  
 10604  	// return unused bytes (on entry, bits < 8, so in won't go too far back)
 10605  	len = bits >> 3
 10606  	in -= uintptr(len)
 10607  	bits = bits - len<<3
 10608  	hold = hold & uint64(uint32(1)<<bits-uint32(1))
 10609  
 10610  	// update state and return
 10611  	(*Z_stream)(unsafe.Pointer(strm)).Fnext_in = in
 10612  	(*Z_stream)(unsafe.Pointer(strm)).Fnext_out = out
 10613  	(*Z_stream)(unsafe.Pointer(strm)).Favail_in = func() uint32 {
 10614  		if in < last {
 10615  			return uint32(int64(5) + (int64(last)-int64(in))/1)
 10616  		}
 10617  		return uint32(int64(5) - (int64(in)-int64(last))/1)
 10618  	}()
 10619  	(*Z_stream)(unsafe.Pointer(strm)).Favail_out = func() uint32 {
 10620  		if out < end {
 10621  			return uint32(int64(257) + (int64(end)-int64(out))/1)
 10622  		}
 10623  		return uint32(int64(257) - (int64(out)-int64(end))/1)
 10624  	}()
 10625  	(*Inflate_state)(unsafe.Pointer(state)).Fhold = hold
 10626  	(*Inflate_state)(unsafe.Pointer(state)).Fbits = bits
 10627  	return
 10628  }
 10629  
 10630  //
 10631  //    inflate_fast() speedups that turned out slower (on a PowerPC G3 750CXe):
 10632  //    - Using bit fields for code structure
 10633  //    - Different op definition to avoid & for extra bits (do & for table bits)
 10634  //    - Three separate decoding do-loops for direct, window, and wnext == 0
 10635  //    - Special case for distance > 1 copies to do overlapped load and store copy
 10636  //    - Explicit branch predictions (based on measured branch probabilities)
 10637  //    - Deferring match copy and interspersed it with decoding subsequent codes
 10638  //    - Swapping literal/length else
 10639  //    - Swapping window/direct else
 10640  //    - Larger unrolled copy loops (three is about right)
 10641  //    - Moving len -= 3 statement into middle of loop
 10642  //
 10643  
 10644  func inflateStateCheck(tls *libc.TLS, strm Z_streamp) int32 { /* inflate.c:105:11: */
 10645  	var state uintptr
 10646  	if strm == uintptr(Z_NULL) || (*Z_stream)(unsafe.Pointer(strm)).Fzalloc == uintptr(0) || (*Z_stream)(unsafe.Pointer(strm)).Fzfree == uintptr(0) {
 10647  		return 1
 10648  	}
 10649  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 10650  	if state == uintptr(Z_NULL) || (*Inflate_state)(unsafe.Pointer(state)).Fstrm != strm || (*Inflate_state)(unsafe.Pointer(state)).Fmode < HEAD || (*Inflate_state)(unsafe.Pointer(state)).Fmode > SYNC {
 10651  		return 1
 10652  	}
 10653  	return 0
 10654  }
 10655  
 10656  func XinflateResetKeep(tls *libc.TLS, strm Z_streamp) int32 { /* inflate.c:119:13: */
 10657  	var state uintptr
 10658  
 10659  	if inflateStateCheck(tls, strm) != 0 {
 10660  		return -2
 10661  	}
 10662  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 10663  	(*Z_stream)(unsafe.Pointer(strm)).Ftotal_in = libc.AssignPtrUint64(strm+40, libc.AssignPtrUint64(state+40, uint64(0)))
 10664  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = uintptr(Z_NULL)
 10665  	if (*Inflate_state)(unsafe.Pointer(state)).Fwrap != 0 { // to support ill-conceived Java test suite
 10666  		(*Z_stream)(unsafe.Pointer(strm)).Fadler = ULong((*Inflate_state)(unsafe.Pointer(state)).Fwrap & 1)
 10667  	}
 10668  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = HEAD
 10669  	(*Inflate_state)(unsafe.Pointer(state)).Flast = 0
 10670  	(*Inflate_state)(unsafe.Pointer(state)).Fhavedict = 0
 10671  	(*Inflate_state)(unsafe.Pointer(state)).Fdmax = 32768
 10672  	(*Inflate_state)(unsafe.Pointer(state)).Fhead = Gz_headerp(Z_NULL)
 10673  	(*Inflate_state)(unsafe.Pointer(state)).Fhold = uint64(0)
 10674  	(*Inflate_state)(unsafe.Pointer(state)).Fbits = uint32(0)
 10675  	(*Inflate_state)(unsafe.Pointer(state)).Flencode = libc.AssignPtrUintptr(state+112, libc.AssignPtrUintptr(state+144, state+1368 /* &.codes */))
 10676  	(*Inflate_state)(unsafe.Pointer(state)).Fsane = 1
 10677  	(*Inflate_state)(unsafe.Pointer(state)).Fback = -1
 10678  
 10679  	return Z_OK
 10680  }
 10681  
 10682  func XinflateReset(tls *libc.TLS, strm Z_streamp) int32 { /* inflate.c:144:13: */
 10683  	var state uintptr
 10684  
 10685  	if inflateStateCheck(tls, strm) != 0 {
 10686  		return -2
 10687  	}
 10688  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 10689  	(*Inflate_state)(unsafe.Pointer(state)).Fwsize = uint32(0)
 10690  	(*Inflate_state)(unsafe.Pointer(state)).Fwhave = uint32(0)
 10691  	(*Inflate_state)(unsafe.Pointer(state)).Fwnext = uint32(0)
 10692  	return XinflateResetKeep(tls, strm)
 10693  }
 10694  
 10695  func XinflateReset2(tls *libc.TLS, strm Z_streamp, windowBits int32) int32 { /* inflate.c:157:13: */
 10696  	var wrap int32
 10697  	var state uintptr
 10698  
 10699  	// get the state
 10700  	if inflateStateCheck(tls, strm) != 0 {
 10701  		return -2
 10702  	}
 10703  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 10704  
 10705  	// extract wrap request from windowBits parameter
 10706  	if windowBits < 0 {
 10707  		wrap = 0
 10708  		windowBits = -windowBits
 10709  	} else {
 10710  		wrap = windowBits>>4 + 5
 10711  		if windowBits < 48 {
 10712  			windowBits = windowBits & 15
 10713  		}
 10714  	}
 10715  
 10716  	// set number of window bits, free window if different
 10717  	if windowBits != 0 && (windowBits < 8 || windowBits > 15) {
 10718  		return -2
 10719  	}
 10720  	if (*Inflate_state)(unsafe.Pointer(state)).Fwindow != uintptr(Z_NULL) && (*Inflate_state)(unsafe.Pointer(state)).Fwbits != uint32(windowBits) {
 10721  		(*struct {
 10722  			f func(*libc.TLS, Voidpf, Voidpf)
 10723  		})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzfree})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, (*Inflate_state)(unsafe.Pointer(state)).Fwindow)
 10724  		(*Inflate_state)(unsafe.Pointer(state)).Fwindow = uintptr(Z_NULL)
 10725  	}
 10726  
 10727  	// update state and reset the rest of it
 10728  	(*Inflate_state)(unsafe.Pointer(state)).Fwrap = wrap
 10729  	(*Inflate_state)(unsafe.Pointer(state)).Fwbits = uint32(windowBits)
 10730  	return XinflateReset(tls, strm)
 10731  }
 10732  
 10733  func XinflateInit2_(tls *libc.TLS, strm Z_streamp, windowBits int32, version uintptr, stream_size int32) int32 { /* inflate.c:195:13: */
 10734  	var ret int32
 10735  	var state uintptr
 10736  
 10737  	if version == uintptr(Z_NULL) || int32(*(*int8)(unsafe.Pointer(version))) != int32(*(*int8)(unsafe.Pointer(ts))) || stream_size != int32(unsafe.Sizeof(Z_stream{})) {
 10738  		return -6
 10739  	}
 10740  	if strm == uintptr(Z_NULL) {
 10741  		return -2
 10742  	}
 10743  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = uintptr(Z_NULL) // in case we return an error
 10744  	if (*Z_stream)(unsafe.Pointer(strm)).Fzalloc == uintptr(0) {
 10745  		(*Z_stream)(unsafe.Pointer(strm)).Fzalloc = *(*uintptr)(unsafe.Pointer(&struct {
 10746  			f func(*libc.TLS, Voidpf, uint32, uint32) Voidpf
 10747  		}{Xzcalloc}))
 10748  		(*Z_stream)(unsafe.Pointer(strm)).Fopaque = uintptr(0)
 10749  	}
 10750  	if (*Z_stream)(unsafe.Pointer(strm)).Fzfree == uintptr(0) {
 10751  		(*Z_stream)(unsafe.Pointer(strm)).Fzfree = *(*uintptr)(unsafe.Pointer(&struct {
 10752  			f func(*libc.TLS, Voidpf, Voidpf)
 10753  		}{Xzcfree}))
 10754  	}
 10755  	state = (*struct {
 10756  		f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
 10757  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, uint32(1), uint32(unsafe.Sizeof(Inflate_state{})))
 10758  	if state == uintptr(Z_NULL) {
 10759  		return -4
 10760  	}
 10761  
 10762  	(*Z_stream)(unsafe.Pointer(strm)).Fstate = state
 10763  	(*Inflate_state)(unsafe.Pointer(state)).Fstrm = strm
 10764  	(*Inflate_state)(unsafe.Pointer(state)).Fwindow = uintptr(Z_NULL)
 10765  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = HEAD // to pass state test in inflateReset2()
 10766  	ret = XinflateReset2(tls, strm, windowBits)
 10767  	if ret != Z_OK {
 10768  		(*struct {
 10769  			f func(*libc.TLS, Voidpf, Voidpf)
 10770  		})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzfree})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, state)
 10771  		(*Z_stream)(unsafe.Pointer(strm)).Fstate = uintptr(Z_NULL)
 10772  	}
 10773  	return ret
 10774  }
 10775  
 10776  func XinflateInit_(tls *libc.TLS, strm Z_streamp, version uintptr, stream_size int32) int32 { /* inflate.c:239:13: */
 10777  	return XinflateInit2_(tls, strm, MAX_WBITS, version, stream_size)
 10778  }
 10779  
 10780  func XinflatePrime(tls *libc.TLS, strm Z_streamp, bits int32, value int32) int32 { /* inflate.c:247:13: */
 10781  	var state uintptr
 10782  
 10783  	if inflateStateCheck(tls, strm) != 0 {
 10784  		return -2
 10785  	}
 10786  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 10787  	if bits < 0 {
 10788  		(*Inflate_state)(unsafe.Pointer(state)).Fhold = uint64(0)
 10789  		(*Inflate_state)(unsafe.Pointer(state)).Fbits = uint32(0)
 10790  		return Z_OK
 10791  	}
 10792  	if bits > 16 || (*Inflate_state)(unsafe.Pointer(state)).Fbits+UInt(bits) > uint32(32) {
 10793  		return -2
 10794  	}
 10795  	value = int32(int64(value) & (int64(1)<<bits - int64(1)))
 10796  	*(*uint64)(unsafe.Pointer(state + 80)) += uint64(uint32(value) << (*Inflate_state)(unsafe.Pointer(state)).Fbits)
 10797  	*(*uint32)(unsafe.Pointer(state + 88)) += UInt(bits)
 10798  	return Z_OK
 10799  }
 10800  
 10801  //
 10802  //    Return state with length and distance decoding tables and index sizes set to
 10803  //    fixed code decoding.  Normally this returns fixed tables from inffixed.h.
 10804  //    If BUILDFIXED is defined, then instead this routine builds the tables the
 10805  //    first time it's called, and returns those tables the first time and
 10806  //    thereafter.  This reduces the size of the code by about 2K bytes, in
 10807  //    exchange for a little execution time.  However, BUILDFIXED should not be
 10808  //    used for threaded applications, since the rewriting of the tables and virgin
 10809  //    may not be thread-safe.
 10810  //
 10811  func fixedtables1(tls *libc.TLS, state uintptr) { /* inflate.c:278:12: */
 10812  	(*Inflate_state)(unsafe.Pointer(state)).Flencode = uintptr(unsafe.Pointer(&lenfix1))
 10813  	(*Inflate_state)(unsafe.Pointer(state)).Flenbits = uint32(9)
 10814  	(*Inflate_state)(unsafe.Pointer(state)).Fdistcode = uintptr(unsafe.Pointer(&distfix1))
 10815  	(*Inflate_state)(unsafe.Pointer(state)).Fdistbits = uint32(5)
 10816  }
 10817  
 10818  var lenfix1 = [512]Code{
 10819  	{Fop: uint8(96), Fbits: uint8(7)}, {Fbits: uint8(8), Fval: uint16(80)}, {Fbits: uint8(8), Fval: uint16(16)}, {Fop: uint8(20), Fbits: uint8(8), Fval: uint16(115)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(31)}, {Fbits: uint8(8), Fval: uint16(112)}, {Fbits: uint8(8), Fval: uint16(48)},
 10820  	{Fbits: uint8(9), Fval: uint16(192)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(10)}, {Fbits: uint8(8), Fval: uint16(96)}, {Fbits: uint8(8), Fval: uint16(32)}, {Fbits: uint8(9), Fval: uint16(160)}, {Fbits: uint8(8)}, {Fbits: uint8(8), Fval: uint16(128)},
 10821  	{Fbits: uint8(8), Fval: uint16(64)}, {Fbits: uint8(9), Fval: uint16(224)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(6)}, {Fbits: uint8(8), Fval: uint16(88)}, {Fbits: uint8(8), Fval: uint16(24)}, {Fbits: uint8(9), Fval: uint16(144)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(59)},
 10822  	{Fbits: uint8(8), Fval: uint16(120)}, {Fbits: uint8(8), Fval: uint16(56)}, {Fbits: uint8(9), Fval: uint16(208)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(17)}, {Fbits: uint8(8), Fval: uint16(104)}, {Fbits: uint8(8), Fval: uint16(40)}, {Fbits: uint8(9), Fval: uint16(176)},
 10823  	{Fbits: uint8(8), Fval: uint16(8)}, {Fbits: uint8(8), Fval: uint16(136)}, {Fbits: uint8(8), Fval: uint16(72)}, {Fbits: uint8(9), Fval: uint16(240)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(4)}, {Fbits: uint8(8), Fval: uint16(84)}, {Fbits: uint8(8), Fval: uint16(20)},
 10824  	{Fop: uint8(21), Fbits: uint8(8), Fval: uint16(227)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(43)}, {Fbits: uint8(8), Fval: uint16(116)}, {Fbits: uint8(8), Fval: uint16(52)}, {Fbits: uint8(9), Fval: uint16(200)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(13)}, {Fbits: uint8(8), Fval: uint16(100)},
 10825  	{Fbits: uint8(8), Fval: uint16(36)}, {Fbits: uint8(9), Fval: uint16(168)}, {Fbits: uint8(8), Fval: uint16(4)}, {Fbits: uint8(8), Fval: uint16(132)}, {Fbits: uint8(8), Fval: uint16(68)}, {Fbits: uint8(9), Fval: uint16(232)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(8)},
 10826  	{Fbits: uint8(8), Fval: uint16(92)}, {Fbits: uint8(8), Fval: uint16(28)}, {Fbits: uint8(9), Fval: uint16(152)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(83)}, {Fbits: uint8(8), Fval: uint16(124)}, {Fbits: uint8(8), Fval: uint16(60)}, {Fbits: uint8(9), Fval: uint16(216)},
 10827  	{Fop: uint8(18), Fbits: uint8(7), Fval: uint16(23)}, {Fbits: uint8(8), Fval: uint16(108)}, {Fbits: uint8(8), Fval: uint16(44)}, {Fbits: uint8(9), Fval: uint16(184)}, {Fbits: uint8(8), Fval: uint16(12)}, {Fbits: uint8(8), Fval: uint16(140)}, {Fbits: uint8(8), Fval: uint16(76)},
 10828  	{Fbits: uint8(9), Fval: uint16(248)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(3)}, {Fbits: uint8(8), Fval: uint16(82)}, {Fbits: uint8(8), Fval: uint16(18)}, {Fop: uint8(21), Fbits: uint8(8), Fval: uint16(163)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(35)}, {Fbits: uint8(8), Fval: uint16(114)},
 10829  	{Fbits: uint8(8), Fval: uint16(50)}, {Fbits: uint8(9), Fval: uint16(196)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(11)}, {Fbits: uint8(8), Fval: uint16(98)}, {Fbits: uint8(8), Fval: uint16(34)}, {Fbits: uint8(9), Fval: uint16(164)}, {Fbits: uint8(8), Fval: uint16(2)},
 10830  	{Fbits: uint8(8), Fval: uint16(130)}, {Fbits: uint8(8), Fval: uint16(66)}, {Fbits: uint8(9), Fval: uint16(228)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(7)}, {Fbits: uint8(8), Fval: uint16(90)}, {Fbits: uint8(8), Fval: uint16(26)}, {Fbits: uint8(9), Fval: uint16(148)},
 10831  	{Fop: uint8(20), Fbits: uint8(7), Fval: uint16(67)}, {Fbits: uint8(8), Fval: uint16(122)}, {Fbits: uint8(8), Fval: uint16(58)}, {Fbits: uint8(9), Fval: uint16(212)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(19)}, {Fbits: uint8(8), Fval: uint16(106)}, {Fbits: uint8(8), Fval: uint16(42)},
 10832  	{Fbits: uint8(9), Fval: uint16(180)}, {Fbits: uint8(8), Fval: uint16(10)}, {Fbits: uint8(8), Fval: uint16(138)}, {Fbits: uint8(8), Fval: uint16(74)}, {Fbits: uint8(9), Fval: uint16(244)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(5)}, {Fbits: uint8(8), Fval: uint16(86)},
 10833  	{Fbits: uint8(8), Fval: uint16(22)}, {Fop: uint8(64), Fbits: uint8(8)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(51)}, {Fbits: uint8(8), Fval: uint16(118)}, {Fbits: uint8(8), Fval: uint16(54)}, {Fbits: uint8(9), Fval: uint16(204)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(15)},
 10834  	{Fbits: uint8(8), Fval: uint16(102)}, {Fbits: uint8(8), Fval: uint16(38)}, {Fbits: uint8(9), Fval: uint16(172)}, {Fbits: uint8(8), Fval: uint16(6)}, {Fbits: uint8(8), Fval: uint16(134)}, {Fbits: uint8(8), Fval: uint16(70)}, {Fbits: uint8(9), Fval: uint16(236)},
 10835  	{Fop: uint8(16), Fbits: uint8(7), Fval: uint16(9)}, {Fbits: uint8(8), Fval: uint16(94)}, {Fbits: uint8(8), Fval: uint16(30)}, {Fbits: uint8(9), Fval: uint16(156)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(99)}, {Fbits: uint8(8), Fval: uint16(126)}, {Fbits: uint8(8), Fval: uint16(62)},
 10836  	{Fbits: uint8(9), Fval: uint16(220)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(27)}, {Fbits: uint8(8), Fval: uint16(110)}, {Fbits: uint8(8), Fval: uint16(46)}, {Fbits: uint8(9), Fval: uint16(188)}, {Fbits: uint8(8), Fval: uint16(14)}, {Fbits: uint8(8), Fval: uint16(142)},
 10837  	{Fbits: uint8(8), Fval: uint16(78)}, {Fbits: uint8(9), Fval: uint16(252)}, {Fop: uint8(96), Fbits: uint8(7)}, {Fbits: uint8(8), Fval: uint16(81)}, {Fbits: uint8(8), Fval: uint16(17)}, {Fop: uint8(21), Fbits: uint8(8), Fval: uint16(131)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(31)},
 10838  	{Fbits: uint8(8), Fval: uint16(113)}, {Fbits: uint8(8), Fval: uint16(49)}, {Fbits: uint8(9), Fval: uint16(194)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(10)}, {Fbits: uint8(8), Fval: uint16(97)}, {Fbits: uint8(8), Fval: uint16(33)}, {Fbits: uint8(9), Fval: uint16(162)},
 10839  	{Fbits: uint8(8), Fval: uint16(1)}, {Fbits: uint8(8), Fval: uint16(129)}, {Fbits: uint8(8), Fval: uint16(65)}, {Fbits: uint8(9), Fval: uint16(226)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(6)}, {Fbits: uint8(8), Fval: uint16(89)}, {Fbits: uint8(8), Fval: uint16(25)},
 10840  	{Fbits: uint8(9), Fval: uint16(146)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(59)}, {Fbits: uint8(8), Fval: uint16(121)}, {Fbits: uint8(8), Fval: uint16(57)}, {Fbits: uint8(9), Fval: uint16(210)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(17)}, {Fbits: uint8(8), Fval: uint16(105)},
 10841  	{Fbits: uint8(8), Fval: uint16(41)}, {Fbits: uint8(9), Fval: uint16(178)}, {Fbits: uint8(8), Fval: uint16(9)}, {Fbits: uint8(8), Fval: uint16(137)}, {Fbits: uint8(8), Fval: uint16(73)}, {Fbits: uint8(9), Fval: uint16(242)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(4)},
 10842  	{Fbits: uint8(8), Fval: uint16(85)}, {Fbits: uint8(8), Fval: uint16(21)}, {Fop: uint8(16), Fbits: uint8(8), Fval: uint16(258)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(43)}, {Fbits: uint8(8), Fval: uint16(117)}, {Fbits: uint8(8), Fval: uint16(53)}, {Fbits: uint8(9), Fval: uint16(202)},
 10843  	{Fop: uint8(17), Fbits: uint8(7), Fval: uint16(13)}, {Fbits: uint8(8), Fval: uint16(101)}, {Fbits: uint8(8), Fval: uint16(37)}, {Fbits: uint8(9), Fval: uint16(170)}, {Fbits: uint8(8), Fval: uint16(5)}, {Fbits: uint8(8), Fval: uint16(133)}, {Fbits: uint8(8), Fval: uint16(69)},
 10844  	{Fbits: uint8(9), Fval: uint16(234)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(8)}, {Fbits: uint8(8), Fval: uint16(93)}, {Fbits: uint8(8), Fval: uint16(29)}, {Fbits: uint8(9), Fval: uint16(154)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(83)}, {Fbits: uint8(8), Fval: uint16(125)},
 10845  	{Fbits: uint8(8), Fval: uint16(61)}, {Fbits: uint8(9), Fval: uint16(218)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(23)}, {Fbits: uint8(8), Fval: uint16(109)}, {Fbits: uint8(8), Fval: uint16(45)}, {Fbits: uint8(9), Fval: uint16(186)}, {Fbits: uint8(8), Fval: uint16(13)},
 10846  	{Fbits: uint8(8), Fval: uint16(141)}, {Fbits: uint8(8), Fval: uint16(77)}, {Fbits: uint8(9), Fval: uint16(250)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(3)}, {Fbits: uint8(8), Fval: uint16(83)}, {Fbits: uint8(8), Fval: uint16(19)}, {Fop: uint8(21), Fbits: uint8(8), Fval: uint16(195)},
 10847  	{Fop: uint8(19), Fbits: uint8(7), Fval: uint16(35)}, {Fbits: uint8(8), Fval: uint16(115)}, {Fbits: uint8(8), Fval: uint16(51)}, {Fbits: uint8(9), Fval: uint16(198)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(11)}, {Fbits: uint8(8), Fval: uint16(99)}, {Fbits: uint8(8), Fval: uint16(35)},
 10848  	{Fbits: uint8(9), Fval: uint16(166)}, {Fbits: uint8(8), Fval: uint16(3)}, {Fbits: uint8(8), Fval: uint16(131)}, {Fbits: uint8(8), Fval: uint16(67)}, {Fbits: uint8(9), Fval: uint16(230)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(7)}, {Fbits: uint8(8), Fval: uint16(91)},
 10849  	{Fbits: uint8(8), Fval: uint16(27)}, {Fbits: uint8(9), Fval: uint16(150)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(67)}, {Fbits: uint8(8), Fval: uint16(123)}, {Fbits: uint8(8), Fval: uint16(59)}, {Fbits: uint8(9), Fval: uint16(214)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(19)},
 10850  	{Fbits: uint8(8), Fval: uint16(107)}, {Fbits: uint8(8), Fval: uint16(43)}, {Fbits: uint8(9), Fval: uint16(182)}, {Fbits: uint8(8), Fval: uint16(11)}, {Fbits: uint8(8), Fval: uint16(139)}, {Fbits: uint8(8), Fval: uint16(75)}, {Fbits: uint8(9), Fval: uint16(246)},
 10851  	{Fop: uint8(16), Fbits: uint8(7), Fval: uint16(5)}, {Fbits: uint8(8), Fval: uint16(87)}, {Fbits: uint8(8), Fval: uint16(23)}, {Fop: uint8(64), Fbits: uint8(8)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(51)}, {Fbits: uint8(8), Fval: uint16(119)}, {Fbits: uint8(8), Fval: uint16(55)},
 10852  	{Fbits: uint8(9), Fval: uint16(206)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(15)}, {Fbits: uint8(8), Fval: uint16(103)}, {Fbits: uint8(8), Fval: uint16(39)}, {Fbits: uint8(9), Fval: uint16(174)}, {Fbits: uint8(8), Fval: uint16(7)}, {Fbits: uint8(8), Fval: uint16(135)},
 10853  	{Fbits: uint8(8), Fval: uint16(71)}, {Fbits: uint8(9), Fval: uint16(238)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(9)}, {Fbits: uint8(8), Fval: uint16(95)}, {Fbits: uint8(8), Fval: uint16(31)}, {Fbits: uint8(9), Fval: uint16(158)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(99)},
 10854  	{Fbits: uint8(8), Fval: uint16(127)}, {Fbits: uint8(8), Fval: uint16(63)}, {Fbits: uint8(9), Fval: uint16(222)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(27)}, {Fbits: uint8(8), Fval: uint16(111)}, {Fbits: uint8(8), Fval: uint16(47)}, {Fbits: uint8(9), Fval: uint16(190)},
 10855  	{Fbits: uint8(8), Fval: uint16(15)}, {Fbits: uint8(8), Fval: uint16(143)}, {Fbits: uint8(8), Fval: uint16(79)}, {Fbits: uint8(9), Fval: uint16(254)}, {Fop: uint8(96), Fbits: uint8(7)}, {Fbits: uint8(8), Fval: uint16(80)}, {Fbits: uint8(8), Fval: uint16(16)},
 10856  	{Fop: uint8(20), Fbits: uint8(8), Fval: uint16(115)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(31)}, {Fbits: uint8(8), Fval: uint16(112)}, {Fbits: uint8(8), Fval: uint16(48)}, {Fbits: uint8(9), Fval: uint16(193)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(10)}, {Fbits: uint8(8), Fval: uint16(96)},
 10857  	{Fbits: uint8(8), Fval: uint16(32)}, {Fbits: uint8(9), Fval: uint16(161)}, {Fbits: uint8(8)}, {Fbits: uint8(8), Fval: uint16(128)}, {Fbits: uint8(8), Fval: uint16(64)}, {Fbits: uint8(9), Fval: uint16(225)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(6)},
 10858  	{Fbits: uint8(8), Fval: uint16(88)}, {Fbits: uint8(8), Fval: uint16(24)}, {Fbits: uint8(9), Fval: uint16(145)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(59)}, {Fbits: uint8(8), Fval: uint16(120)}, {Fbits: uint8(8), Fval: uint16(56)}, {Fbits: uint8(9), Fval: uint16(209)},
 10859  	{Fop: uint8(17), Fbits: uint8(7), Fval: uint16(17)}, {Fbits: uint8(8), Fval: uint16(104)}, {Fbits: uint8(8), Fval: uint16(40)}, {Fbits: uint8(9), Fval: uint16(177)}, {Fbits: uint8(8), Fval: uint16(8)}, {Fbits: uint8(8), Fval: uint16(136)}, {Fbits: uint8(8), Fval: uint16(72)},
 10860  	{Fbits: uint8(9), Fval: uint16(241)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(4)}, {Fbits: uint8(8), Fval: uint16(84)}, {Fbits: uint8(8), Fval: uint16(20)}, {Fop: uint8(21), Fbits: uint8(8), Fval: uint16(227)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(43)}, {Fbits: uint8(8), Fval: uint16(116)},
 10861  	{Fbits: uint8(8), Fval: uint16(52)}, {Fbits: uint8(9), Fval: uint16(201)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(13)}, {Fbits: uint8(8), Fval: uint16(100)}, {Fbits: uint8(8), Fval: uint16(36)}, {Fbits: uint8(9), Fval: uint16(169)}, {Fbits: uint8(8), Fval: uint16(4)},
 10862  	{Fbits: uint8(8), Fval: uint16(132)}, {Fbits: uint8(8), Fval: uint16(68)}, {Fbits: uint8(9), Fval: uint16(233)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(8)}, {Fbits: uint8(8), Fval: uint16(92)}, {Fbits: uint8(8), Fval: uint16(28)}, {Fbits: uint8(9), Fval: uint16(153)},
 10863  	{Fop: uint8(20), Fbits: uint8(7), Fval: uint16(83)}, {Fbits: uint8(8), Fval: uint16(124)}, {Fbits: uint8(8), Fval: uint16(60)}, {Fbits: uint8(9), Fval: uint16(217)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(23)}, {Fbits: uint8(8), Fval: uint16(108)}, {Fbits: uint8(8), Fval: uint16(44)},
 10864  	{Fbits: uint8(9), Fval: uint16(185)}, {Fbits: uint8(8), Fval: uint16(12)}, {Fbits: uint8(8), Fval: uint16(140)}, {Fbits: uint8(8), Fval: uint16(76)}, {Fbits: uint8(9), Fval: uint16(249)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(3)}, {Fbits: uint8(8), Fval: uint16(82)},
 10865  	{Fbits: uint8(8), Fval: uint16(18)}, {Fop: uint8(21), Fbits: uint8(8), Fval: uint16(163)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(35)}, {Fbits: uint8(8), Fval: uint16(114)}, {Fbits: uint8(8), Fval: uint16(50)}, {Fbits: uint8(9), Fval: uint16(197)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(11)},
 10866  	{Fbits: uint8(8), Fval: uint16(98)}, {Fbits: uint8(8), Fval: uint16(34)}, {Fbits: uint8(9), Fval: uint16(165)}, {Fbits: uint8(8), Fval: uint16(2)}, {Fbits: uint8(8), Fval: uint16(130)}, {Fbits: uint8(8), Fval: uint16(66)}, {Fbits: uint8(9), Fval: uint16(229)},
 10867  	{Fop: uint8(16), Fbits: uint8(7), Fval: uint16(7)}, {Fbits: uint8(8), Fval: uint16(90)}, {Fbits: uint8(8), Fval: uint16(26)}, {Fbits: uint8(9), Fval: uint16(149)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(67)}, {Fbits: uint8(8), Fval: uint16(122)}, {Fbits: uint8(8), Fval: uint16(58)},
 10868  	{Fbits: uint8(9), Fval: uint16(213)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(19)}, {Fbits: uint8(8), Fval: uint16(106)}, {Fbits: uint8(8), Fval: uint16(42)}, {Fbits: uint8(9), Fval: uint16(181)}, {Fbits: uint8(8), Fval: uint16(10)}, {Fbits: uint8(8), Fval: uint16(138)},
 10869  	{Fbits: uint8(8), Fval: uint16(74)}, {Fbits: uint8(9), Fval: uint16(245)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(5)}, {Fbits: uint8(8), Fval: uint16(86)}, {Fbits: uint8(8), Fval: uint16(22)}, {Fop: uint8(64), Fbits: uint8(8)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(51)},
 10870  	{Fbits: uint8(8), Fval: uint16(118)}, {Fbits: uint8(8), Fval: uint16(54)}, {Fbits: uint8(9), Fval: uint16(205)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(15)}, {Fbits: uint8(8), Fval: uint16(102)}, {Fbits: uint8(8), Fval: uint16(38)}, {Fbits: uint8(9), Fval: uint16(173)},
 10871  	{Fbits: uint8(8), Fval: uint16(6)}, {Fbits: uint8(8), Fval: uint16(134)}, {Fbits: uint8(8), Fval: uint16(70)}, {Fbits: uint8(9), Fval: uint16(237)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(9)}, {Fbits: uint8(8), Fval: uint16(94)}, {Fbits: uint8(8), Fval: uint16(30)},
 10872  	{Fbits: uint8(9), Fval: uint16(157)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(99)}, {Fbits: uint8(8), Fval: uint16(126)}, {Fbits: uint8(8), Fval: uint16(62)}, {Fbits: uint8(9), Fval: uint16(221)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(27)}, {Fbits: uint8(8), Fval: uint16(110)},
 10873  	{Fbits: uint8(8), Fval: uint16(46)}, {Fbits: uint8(9), Fval: uint16(189)}, {Fbits: uint8(8), Fval: uint16(14)}, {Fbits: uint8(8), Fval: uint16(142)}, {Fbits: uint8(8), Fval: uint16(78)}, {Fbits: uint8(9), Fval: uint16(253)}, {Fop: uint8(96), Fbits: uint8(7)},
 10874  	{Fbits: uint8(8), Fval: uint16(81)}, {Fbits: uint8(8), Fval: uint16(17)}, {Fop: uint8(21), Fbits: uint8(8), Fval: uint16(131)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(31)}, {Fbits: uint8(8), Fval: uint16(113)}, {Fbits: uint8(8), Fval: uint16(49)}, {Fbits: uint8(9), Fval: uint16(195)},
 10875  	{Fop: uint8(16), Fbits: uint8(7), Fval: uint16(10)}, {Fbits: uint8(8), Fval: uint16(97)}, {Fbits: uint8(8), Fval: uint16(33)}, {Fbits: uint8(9), Fval: uint16(163)}, {Fbits: uint8(8), Fval: uint16(1)}, {Fbits: uint8(8), Fval: uint16(129)}, {Fbits: uint8(8), Fval: uint16(65)},
 10876  	{Fbits: uint8(9), Fval: uint16(227)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(6)}, {Fbits: uint8(8), Fval: uint16(89)}, {Fbits: uint8(8), Fval: uint16(25)}, {Fbits: uint8(9), Fval: uint16(147)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(59)}, {Fbits: uint8(8), Fval: uint16(121)},
 10877  	{Fbits: uint8(8), Fval: uint16(57)}, {Fbits: uint8(9), Fval: uint16(211)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(17)}, {Fbits: uint8(8), Fval: uint16(105)}, {Fbits: uint8(8), Fval: uint16(41)}, {Fbits: uint8(9), Fval: uint16(179)}, {Fbits: uint8(8), Fval: uint16(9)},
 10878  	{Fbits: uint8(8), Fval: uint16(137)}, {Fbits: uint8(8), Fval: uint16(73)}, {Fbits: uint8(9), Fval: uint16(243)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(4)}, {Fbits: uint8(8), Fval: uint16(85)}, {Fbits: uint8(8), Fval: uint16(21)}, {Fop: uint8(16), Fbits: uint8(8), Fval: uint16(258)},
 10879  	{Fop: uint8(19), Fbits: uint8(7), Fval: uint16(43)}, {Fbits: uint8(8), Fval: uint16(117)}, {Fbits: uint8(8), Fval: uint16(53)}, {Fbits: uint8(9), Fval: uint16(203)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(13)}, {Fbits: uint8(8), Fval: uint16(101)}, {Fbits: uint8(8), Fval: uint16(37)},
 10880  	{Fbits: uint8(9), Fval: uint16(171)}, {Fbits: uint8(8), Fval: uint16(5)}, {Fbits: uint8(8), Fval: uint16(133)}, {Fbits: uint8(8), Fval: uint16(69)}, {Fbits: uint8(9), Fval: uint16(235)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(8)}, {Fbits: uint8(8), Fval: uint16(93)},
 10881  	{Fbits: uint8(8), Fval: uint16(29)}, {Fbits: uint8(9), Fval: uint16(155)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(83)}, {Fbits: uint8(8), Fval: uint16(125)}, {Fbits: uint8(8), Fval: uint16(61)}, {Fbits: uint8(9), Fval: uint16(219)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(23)},
 10882  	{Fbits: uint8(8), Fval: uint16(109)}, {Fbits: uint8(8), Fval: uint16(45)}, {Fbits: uint8(9), Fval: uint16(187)}, {Fbits: uint8(8), Fval: uint16(13)}, {Fbits: uint8(8), Fval: uint16(141)}, {Fbits: uint8(8), Fval: uint16(77)}, {Fbits: uint8(9), Fval: uint16(251)},
 10883  	{Fop: uint8(16), Fbits: uint8(7), Fval: uint16(3)}, {Fbits: uint8(8), Fval: uint16(83)}, {Fbits: uint8(8), Fval: uint16(19)}, {Fop: uint8(21), Fbits: uint8(8), Fval: uint16(195)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(35)}, {Fbits: uint8(8), Fval: uint16(115)}, {Fbits: uint8(8), Fval: uint16(51)},
 10884  	{Fbits: uint8(9), Fval: uint16(199)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(11)}, {Fbits: uint8(8), Fval: uint16(99)}, {Fbits: uint8(8), Fval: uint16(35)}, {Fbits: uint8(9), Fval: uint16(167)}, {Fbits: uint8(8), Fval: uint16(3)}, {Fbits: uint8(8), Fval: uint16(131)},
 10885  	{Fbits: uint8(8), Fval: uint16(67)}, {Fbits: uint8(9), Fval: uint16(231)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(7)}, {Fbits: uint8(8), Fval: uint16(91)}, {Fbits: uint8(8), Fval: uint16(27)}, {Fbits: uint8(9), Fval: uint16(151)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(67)},
 10886  	{Fbits: uint8(8), Fval: uint16(123)}, {Fbits: uint8(8), Fval: uint16(59)}, {Fbits: uint8(9), Fval: uint16(215)}, {Fop: uint8(18), Fbits: uint8(7), Fval: uint16(19)}, {Fbits: uint8(8), Fval: uint16(107)}, {Fbits: uint8(8), Fval: uint16(43)}, {Fbits: uint8(9), Fval: uint16(183)},
 10887  	{Fbits: uint8(8), Fval: uint16(11)}, {Fbits: uint8(8), Fval: uint16(139)}, {Fbits: uint8(8), Fval: uint16(75)}, {Fbits: uint8(9), Fval: uint16(247)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(5)}, {Fbits: uint8(8), Fval: uint16(87)}, {Fbits: uint8(8), Fval: uint16(23)},
 10888  	{Fop: uint8(64), Fbits: uint8(8)}, {Fop: uint8(19), Fbits: uint8(7), Fval: uint16(51)}, {Fbits: uint8(8), Fval: uint16(119)}, {Fbits: uint8(8), Fval: uint16(55)}, {Fbits: uint8(9), Fval: uint16(207)}, {Fop: uint8(17), Fbits: uint8(7), Fval: uint16(15)}, {Fbits: uint8(8), Fval: uint16(103)},
 10889  	{Fbits: uint8(8), Fval: uint16(39)}, {Fbits: uint8(9), Fval: uint16(175)}, {Fbits: uint8(8), Fval: uint16(7)}, {Fbits: uint8(8), Fval: uint16(135)}, {Fbits: uint8(8), Fval: uint16(71)}, {Fbits: uint8(9), Fval: uint16(239)}, {Fop: uint8(16), Fbits: uint8(7), Fval: uint16(9)},
 10890  	{Fbits: uint8(8), Fval: uint16(95)}, {Fbits: uint8(8), Fval: uint16(31)}, {Fbits: uint8(9), Fval: uint16(159)}, {Fop: uint8(20), Fbits: uint8(7), Fval: uint16(99)}, {Fbits: uint8(8), Fval: uint16(127)}, {Fbits: uint8(8), Fval: uint16(63)}, {Fbits: uint8(9), Fval: uint16(223)},
 10891  	{Fop: uint8(18), Fbits: uint8(7), Fval: uint16(27)}, {Fbits: uint8(8), Fval: uint16(111)}, {Fbits: uint8(8), Fval: uint16(47)}, {Fbits: uint8(9), Fval: uint16(191)}, {Fbits: uint8(8), Fval: uint16(15)}, {Fbits: uint8(8), Fval: uint16(143)}, {Fbits: uint8(8), Fval: uint16(79)},
 10892  	{Fbits: uint8(9), Fval: uint16(255)},
 10893  } /* inffixed.h:10:23 */
 10894  var distfix1 = [32]Code{
 10895  	{Fop: uint8(16), Fbits: uint8(5), Fval: uint16(1)}, {Fop: uint8(23), Fbits: uint8(5), Fval: uint16(257)}, {Fop: uint8(19), Fbits: uint8(5), Fval: uint16(17)}, {Fop: uint8(27), Fbits: uint8(5), Fval: uint16(4097)}, {Fop: uint8(17), Fbits: uint8(5), Fval: uint16(5)}, {Fop: uint8(25), Fbits: uint8(5), Fval: uint16(1025)},
 10896  	{Fop: uint8(21), Fbits: uint8(5), Fval: uint16(65)}, {Fop: uint8(29), Fbits: uint8(5), Fval: uint16(16385)}, {Fop: uint8(16), Fbits: uint8(5), Fval: uint16(3)}, {Fop: uint8(24), Fbits: uint8(5), Fval: uint16(513)}, {Fop: uint8(20), Fbits: uint8(5), Fval: uint16(33)}, {Fop: uint8(28), Fbits: uint8(5), Fval: uint16(8193)},
 10897  	{Fop: uint8(18), Fbits: uint8(5), Fval: uint16(9)}, {Fop: uint8(26), Fbits: uint8(5), Fval: uint16(2049)}, {Fop: uint8(22), Fbits: uint8(5), Fval: uint16(129)}, {Fop: uint8(64), Fbits: uint8(5)}, {Fop: uint8(16), Fbits: uint8(5), Fval: uint16(2)}, {Fop: uint8(23), Fbits: uint8(5), Fval: uint16(385)},
 10898  	{Fop: uint8(19), Fbits: uint8(5), Fval: uint16(25)}, {Fop: uint8(27), Fbits: uint8(5), Fval: uint16(6145)}, {Fop: uint8(17), Fbits: uint8(5), Fval: uint16(7)}, {Fop: uint8(25), Fbits: uint8(5), Fval: uint16(1537)}, {Fop: uint8(21), Fbits: uint8(5), Fval: uint16(97)}, {Fop: uint8(29), Fbits: uint8(5), Fval: uint16(24577)},
 10899  	{Fop: uint8(16), Fbits: uint8(5), Fval: uint16(4)}, {Fop: uint8(24), Fbits: uint8(5), Fval: uint16(769)}, {Fop: uint8(20), Fbits: uint8(5), Fval: uint16(49)}, {Fop: uint8(28), Fbits: uint8(5), Fval: uint16(12289)}, {Fop: uint8(18), Fbits: uint8(5), Fval: uint16(13)}, {Fop: uint8(26), Fbits: uint8(5), Fval: uint16(3073)},
 10900  	{Fop: uint8(22), Fbits: uint8(5), Fval: uint16(193)}, {Fop: uint8(64), Fbits: uint8(5)},
 10901  } /* inffixed.h:87:23 */
 10902  
 10903  //
 10904  //    Update the window with the last wsize (normally 32K) bytes written before
 10905  //    returning.  If window does not exist yet, create it.  This is only called
 10906  //    when a window is already in use, or when output has been written during this
 10907  //    inflate call, but the end of the deflate stream has not been reached yet.
 10908  //    It is also called to create a window for dictionary data when a dictionary
 10909  //    is loaded.
 10910  //
 10911  //    Providing output buffers larger than 32K to inflate() should provide a speed
 10912  //    advantage, since only the last 32K of output is copied to the sliding window
 10913  //    upon return from inflate(), and since all distances after the first 32K of
 10914  //    output will fall in the output data, making match copies simpler and faster.
 10915  //    The advantage may be dependent on the size of the processor's data caches.
 10916  //
 10917  func updatewindow(tls *libc.TLS, strm Z_streamp, end uintptr, copy uint32) int32 { /* inflate.c:396:11: */
 10918  	var state uintptr
 10919  	var dist uint32
 10920  
 10921  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 10922  
 10923  	// if it hasn't been done already, allocate space for the window
 10924  	if (*Inflate_state)(unsafe.Pointer(state)).Fwindow == uintptr(Z_NULL) {
 10925  		(*Inflate_state)(unsafe.Pointer(state)).Fwindow = (*struct {
 10926  			f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
 10927  		})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, uint32(1)<<(*Inflate_state)(unsafe.Pointer(state)).Fwbits, uint32(unsafe.Sizeof(uint8(0))))
 10928  		if (*Inflate_state)(unsafe.Pointer(state)).Fwindow == uintptr(Z_NULL) {
 10929  			return 1
 10930  		}
 10931  	}
 10932  
 10933  	// if window not in use yet, initialize
 10934  	if (*Inflate_state)(unsafe.Pointer(state)).Fwsize == uint32(0) {
 10935  		(*Inflate_state)(unsafe.Pointer(state)).Fwsize = uint32(1) << (*Inflate_state)(unsafe.Pointer(state)).Fwbits
 10936  		(*Inflate_state)(unsafe.Pointer(state)).Fwnext = uint32(0)
 10937  		(*Inflate_state)(unsafe.Pointer(state)).Fwhave = uint32(0)
 10938  	}
 10939  
 10940  	// copy state->wsize or less output bytes into the circular window
 10941  	if copy >= (*Inflate_state)(unsafe.Pointer(state)).Fwsize {
 10942  		libc.Xmemcpy(tls, (*Inflate_state)(unsafe.Pointer(state)).Fwindow, end-uintptr((*Inflate_state)(unsafe.Pointer(state)).Fwsize), uint64((*Inflate_state)(unsafe.Pointer(state)).Fwsize))
 10943  		(*Inflate_state)(unsafe.Pointer(state)).Fwnext = uint32(0)
 10944  		(*Inflate_state)(unsafe.Pointer(state)).Fwhave = (*Inflate_state)(unsafe.Pointer(state)).Fwsize
 10945  	} else {
 10946  		dist = (*Inflate_state)(unsafe.Pointer(state)).Fwsize - (*Inflate_state)(unsafe.Pointer(state)).Fwnext
 10947  		if dist > copy {
 10948  			dist = copy
 10949  		}
 10950  		libc.Xmemcpy(tls, (*Inflate_state)(unsafe.Pointer(state)).Fwindow+uintptr((*Inflate_state)(unsafe.Pointer(state)).Fwnext), end-uintptr(copy), uint64(dist))
 10951  		copy = copy - dist
 10952  		if copy != 0 {
 10953  			libc.Xmemcpy(tls, (*Inflate_state)(unsafe.Pointer(state)).Fwindow, end-uintptr(copy), uint64(copy))
 10954  			(*Inflate_state)(unsafe.Pointer(state)).Fwnext = copy
 10955  			(*Inflate_state)(unsafe.Pointer(state)).Fwhave = (*Inflate_state)(unsafe.Pointer(state)).Fwsize
 10956  		} else {
 10957  			*(*uint32)(unsafe.Pointer(state + 68)) += dist
 10958  			if (*Inflate_state)(unsafe.Pointer(state)).Fwnext == (*Inflate_state)(unsafe.Pointer(state)).Fwsize {
 10959  				(*Inflate_state)(unsafe.Pointer(state)).Fwnext = uint32(0)
 10960  			}
 10961  			if (*Inflate_state)(unsafe.Pointer(state)).Fwhave < (*Inflate_state)(unsafe.Pointer(state)).Fwsize {
 10962  				*(*uint32)(unsafe.Pointer(state + 64)) += dist
 10963  			}
 10964  		}
 10965  	}
 10966  	return 0
 10967  }
 10968  
 10969  // Macros for inflate():
 10970  
 10971  // check function to use adler32() for zlib or crc32() for gzip
 10972  
 10973  // check macros for header crc
 10974  
 10975  // Load registers with state in inflate() for speed
 10976  
 10977  // Restore state from registers in inflate()
 10978  
 10979  // Clear the input bit accumulator
 10980  
 10981  // Get a byte of input into the bit accumulator, or return from inflate()
 10982  //    if there is no input available.
 10983  
 10984  // Assure that there are at least n bits in the bit accumulator.  If there is
 10985  //    not enough available input to do that, then return from inflate().
 10986  
 10987  // Return the low n bits of the bit accumulator (n < 16)
 10988  
 10989  // Remove n bits from the bit accumulator
 10990  
 10991  // Remove zero to seven bits as needed to go to a byte boundary
 10992  
 10993  //
 10994  //    inflate() uses a state machine to process as much input data and generate as
 10995  //    much output data as possible before returning.  The state machine is
 10996  //    structured roughly as follows:
 10997  //
 10998  //     for (;;) switch (state) {
 10999  //     ...
 11000  //     case STATEn:
 11001  //         if (not enough input data or output space to make progress)
 11002  //             return;
 11003  //         ... make progress ...
 11004  //         state = STATEm;
 11005  //         break;
 11006  //     ...
 11007  //     }
 11008  //
 11009  //    so when inflate() is called again, the same case is attempted again, and
 11010  //    if the appropriate resources are provided, the machine proceeds to the
 11011  //    next state.  The NEEDBITS() macro is usually the way the state evaluates
 11012  //    whether it can proceed or should return.  NEEDBITS() does the return if
 11013  //    the requested bits are not available.  The typical use of the BITS macros
 11014  //    is:
 11015  //
 11016  //         NEEDBITS(n);
 11017  //         ... do something with BITS(n) ...
 11018  //         DROPBITS(n);
 11019  //
 11020  //    where NEEDBITS(n) either returns from inflate() if there isn't enough
 11021  //    input left to load n bits into the accumulator, or it continues.  BITS(n)
 11022  //    gives the low n bits in the accumulator.  When done, DROPBITS(n) drops
 11023  //    the low n bits off the accumulator.  INITBITS() clears the accumulator
 11024  //    and sets the number of available bits to zero.  BYTEBITS() discards just
 11025  //    enough bits to put the accumulator on a byte boundary.  After BYTEBITS()
 11026  //    and a NEEDBITS(8), then BITS(8) would return the next byte in the stream.
 11027  //
 11028  //    NEEDBITS(n) uses PULLBYTE() to get an available byte of input, or to return
 11029  //    if there is no input available.  The decoding of variable length codes uses
 11030  //    PULLBYTE() directly in order to pull just enough bytes to decode the next
 11031  //    code, and no more.
 11032  //
 11033  //    Some states loop until they get enough input, making sure that enough
 11034  //    state information is maintained to continue the loop where it left off
 11035  //    if NEEDBITS() returns in the loop.  For example, want, need, and keep
 11036  //    would all have to actually be part of the saved state in case NEEDBITS()
 11037  //    returns:
 11038  //
 11039  //     case STATEw:
 11040  //         while (want < need) {
 11041  //             NEEDBITS(n);
 11042  //             keep[want++] = BITS(n);
 11043  //             DROPBITS(n);
 11044  //         }
 11045  //         state = STATEx;
 11046  //     case STATEx:
 11047  //
 11048  //    As shown above, if the next state is also the next case, then the break
 11049  //    is omitted.
 11050  //
 11051  //    A state may also return if there is not enough output space available to
 11052  //    complete that state.  Those states are copying stored data, writing a
 11053  //    literal byte, and copying a matching string.
 11054  //
 11055  //    When returning, a "goto inf_leave" is used to update the total counters,
 11056  //    update the check value, and determine whether any progress has been made
 11057  //    during that inflate() call in order to return the proper return code.
 11058  //    Progress is defined as a change in either strm->avail_in or strm->avail_out.
 11059  //    When there is a window, goto inf_leave will update the window with the last
 11060  //    output written.  If a goto inf_leave occurs in the middle of decompression
 11061  //    and there is no window currently, goto inf_leave will create one and copy
 11062  //    output to the window for the next call of inflate().
 11063  //
 11064  //    In this implementation, the flush parameter of inflate() only affects the
 11065  //    return code (per zlib.h).  inflate() always writes as much as possible to
 11066  //    strm->next_out, given the space available and the provided input--the effect
 11067  //    documented in zlib.h of Z_SYNC_FLUSH.  Furthermore, inflate() always defers
 11068  //    the allocation of and copying into a sliding window until necessary, which
 11069  //    provides the effect documented in zlib.h for Z_FINISH when the entire input
 11070  //    stream available.  So the only thing the flush parameter actually does is:
 11071  //    when flush is set to Z_FINISH, inflate() cannot return Z_OK.  Instead it
 11072  //    will return Z_BUF_ERROR if it has not reached the end of the stream.
 11073  //
 11074  
 11075  func Xinflate(tls *libc.TLS, strm Z_streamp, flush int32) int32 { /* inflate.c:622:13: */
 11076  	bp := tls.Alloc(4)
 11077  	defer tls.Free(4)
 11078  
 11079  	var state uintptr
 11080  	var next uintptr // next input
 11081  	var put uintptr  // next output
 11082  	var have uint32
 11083  	var left uint32 // available input and output
 11084  	var hold uint64 // bit buffer
 11085  	var bits uint32 // bits in bit buffer
 11086  	var in uint32
 11087  	var out uint32   // save starting available input and output
 11088  	var copy uint32  // number of stored or match bytes to copy
 11089  	var from uintptr // where to copy match bytes from
 11090  	var here Code    // current decoding table entry
 11091  	var last Code    // parent table entry
 11092  	var len uint32   // length to copy for repeats, bits to drop
 11093  	var ret int32    // return code
 11094  	// var hbuf [4]uint8 at bp, 4
 11095  
 11096  	if !(inflateStateCheck(tls, strm) != 0 || (*Z_stream)(unsafe.Pointer(strm)).Fnext_out == uintptr(Z_NULL) || (*Z_stream)(unsafe.Pointer(strm)).Fnext_in == uintptr(Z_NULL) && (*Z_stream)(unsafe.Pointer(strm)).Favail_in != UInt(0)) {
 11097  		goto __1
 11098  	}
 11099  	return -2
 11100  __1:
 11101  	;
 11102  
 11103  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 11104  	if !((*Inflate_state)(unsafe.Pointer(state)).Fmode == TYPE) {
 11105  		goto __2
 11106  	}
 11107  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = TYPEDO
 11108  __2:
 11109  	; // skip check
 11110  __3:
 11111  	put = (*Z_stream)(unsafe.Pointer(strm)).Fnext_out
 11112  	left = (*Z_stream)(unsafe.Pointer(strm)).Favail_out
 11113  	next = (*Z_stream)(unsafe.Pointer(strm)).Fnext_in
 11114  	have = (*Z_stream)(unsafe.Pointer(strm)).Favail_in
 11115  	hold = (*Inflate_state)(unsafe.Pointer(state)).Fhold
 11116  	bits = (*Inflate_state)(unsafe.Pointer(state)).Fbits
 11117  	goto __4
 11118  __4:
 11119  	if 0 != 0 {
 11120  		goto __3
 11121  	}
 11122  	goto __5
 11123  __5:
 11124  	;
 11125  	in = have
 11126  	out = left
 11127  	ret = Z_OK
 11128  __6:
 11129  	switch (*Inflate_state)(unsafe.Pointer(state)).Fmode {
 11130  	case HEAD:
 11131  		goto __10
 11132  	case FLAGS:
 11133  		goto __11
 11134  	case TIME:
 11135  		goto __12
 11136  	case OS:
 11137  		goto __13
 11138  	case EXLEN:
 11139  		goto __14
 11140  	case EXTRA:
 11141  		goto __15
 11142  	case NAME:
 11143  		goto __16
 11144  	case COMMENT:
 11145  		goto __17
 11146  	case HCRC:
 11147  		goto __18
 11148  	case DICTID:
 11149  		goto __19
 11150  	case DICT:
 11151  		goto __20
 11152  	case TYPE:
 11153  		goto __21
 11154  	case TYPEDO:
 11155  		goto __22
 11156  	case STORED:
 11157  		goto __23
 11158  	case COPY_:
 11159  		goto __24
 11160  	case COPY:
 11161  		goto __25
 11162  	case TABLE:
 11163  		goto __26
 11164  	case LENLENS:
 11165  		goto __27
 11166  	case CODELENS:
 11167  		goto __28
 11168  	case LEN_:
 11169  		goto __29
 11170  	case LEN:
 11171  		goto __30
 11172  	case LENEXT:
 11173  		goto __31
 11174  	case DIST:
 11175  		goto __32
 11176  	case DISTEXT:
 11177  		goto __33
 11178  	case MATCH:
 11179  		goto __34
 11180  	case LIT:
 11181  		goto __35
 11182  	case CHECK:
 11183  		goto __36
 11184  	case LENGTH:
 11185  		goto __37
 11186  	case DONE:
 11187  		goto __38
 11188  	case BAD:
 11189  		goto __39
 11190  	case MEM:
 11191  		goto __40
 11192  	case SYNC:
 11193  		goto __41
 11194  	default:
 11195  		goto __42
 11196  	}
 11197  	goto __9
 11198  __10:
 11199  	if !((*Inflate_state)(unsafe.Pointer(state)).Fwrap == 0) {
 11200  		goto __43
 11201  	}
 11202  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = TYPEDO
 11203  	goto __9
 11204  __43:
 11205  	;
 11206  __44:
 11207  __47:
 11208  	if !(bits < uint32(16)) {
 11209  		goto __48
 11210  	}
 11211  __49:
 11212  	if !(have == uint32(0)) {
 11213  		goto __52
 11214  	}
 11215  	goto inf_leave
 11216  __52:
 11217  	;
 11218  	have--
 11219  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 11220  	bits = bits + uint32(8)
 11221  	goto __50
 11222  __50:
 11223  	if 0 != 0 {
 11224  		goto __49
 11225  	}
 11226  	goto __51
 11227  __51:
 11228  	;
 11229  	goto __47
 11230  __48:
 11231  	;
 11232  	goto __45
 11233  __45:
 11234  	if 0 != 0 {
 11235  		goto __44
 11236  	}
 11237  	goto __46
 11238  __46:
 11239  	;
 11240  	if !((*Inflate_state)(unsafe.Pointer(state)).Fwrap&2 != 0 && hold == uint64(0x8b1f)) {
 11241  		goto __53
 11242  	} // gzip header
 11243  	if !((*Inflate_state)(unsafe.Pointer(state)).Fwbits == uint32(0)) {
 11244  		goto __54
 11245  	}
 11246  	(*Inflate_state)(unsafe.Pointer(state)).Fwbits = uint32(15)
 11247  __54:
 11248  	;
 11249  	(*Inflate_state)(unsafe.Pointer(state)).Fcheck = Xcrc32(tls, uint64(0), uintptr(Z_NULL), uint32(0))
 11250  __55:
 11251  	*(*uint8)(unsafe.Pointer(bp)) = uint8(hold)
 11252  	*(*uint8)(unsafe.Pointer(bp + 1)) = uint8(hold >> 8)
 11253  	(*Inflate_state)(unsafe.Pointer(state)).Fcheck = Xcrc32(tls, (*Inflate_state)(unsafe.Pointer(state)).Fcheck, bp, uint32(2))
 11254  	goto __56
 11255  __56:
 11256  	if 0 != 0 {
 11257  		goto __55
 11258  	}
 11259  	goto __57
 11260  __57:
 11261  	;
 11262  __58:
 11263  	hold = uint64(0)
 11264  	bits = uint32(0)
 11265  	goto __59
 11266  __59:
 11267  	if 0 != 0 {
 11268  		goto __58
 11269  	}
 11270  	goto __60
 11271  __60:
 11272  	;
 11273  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = FLAGS
 11274  	goto __9
 11275  __53:
 11276  	;
 11277  	(*Inflate_state)(unsafe.Pointer(state)).Fflags = 0 // expect zlib header
 11278  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhead != uintptr(Z_NULL)) {
 11279  		goto __61
 11280  	}
 11281  	(*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fdone = -1
 11282  __61:
 11283  	;
 11284  	if !(!((*Inflate_state)(unsafe.Pointer(state)).Fwrap&1 != 0) || (uint64(uint32(hold)&(uint32(1)<<8-uint32(1))<<8)+hold>>8)%uint64(31) != 0) {
 11285  		goto __62
 11286  	}
 11287  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 669 /* "incorrect header..." */
 11288  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 11289  	goto __9
 11290  __62:
 11291  	;
 11292  	if !(uint32(hold)&(uint32(1)<<4-uint32(1)) != uint32(Z_DEFLATED)) {
 11293  		goto __63
 11294  	}
 11295  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 692 /* "unknown compress..." */
 11296  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 11297  	goto __9
 11298  __63:
 11299  	;
 11300  __64:
 11301  	hold >>= 4
 11302  	bits = bits - uint32(4)
 11303  	goto __65
 11304  __65:
 11305  	if 0 != 0 {
 11306  		goto __64
 11307  	}
 11308  	goto __66
 11309  __66:
 11310  	;
 11311  	len = uint32(hold)&(uint32(1)<<4-uint32(1)) + uint32(8)
 11312  	if !((*Inflate_state)(unsafe.Pointer(state)).Fwbits == uint32(0)) {
 11313  		goto __67
 11314  	}
 11315  	(*Inflate_state)(unsafe.Pointer(state)).Fwbits = len
 11316  __67:
 11317  	;
 11318  	if !(len > uint32(15) || len > (*Inflate_state)(unsafe.Pointer(state)).Fwbits) {
 11319  		goto __68
 11320  	}
 11321  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 719 /* "invalid window s..." */
 11322  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 11323  	goto __9
 11324  __68:
 11325  	;
 11326  	(*Inflate_state)(unsafe.Pointer(state)).Fdmax = uint32(1) << len
 11327  
 11328  	(*Z_stream)(unsafe.Pointer(strm)).Fadler = libc.AssignPtrUint64(state+32, Xadler32(tls, uint64(0), uintptr(Z_NULL), uint32(0)))
 11329  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = func() uint32 {
 11330  		if hold&uint64(0x200) != 0 {
 11331  			return DICTID
 11332  		}
 11333  		return TYPE
 11334  	}()
 11335  __69:
 11336  	hold = uint64(0)
 11337  	bits = uint32(0)
 11338  	goto __70
 11339  __70:
 11340  	if 0 != 0 {
 11341  		goto __69
 11342  	}
 11343  	goto __71
 11344  __71:
 11345  	;
 11346  	goto __9
 11347  __11:
 11348  __72:
 11349  __75:
 11350  	if !(bits < uint32(16)) {
 11351  		goto __76
 11352  	}
 11353  __77:
 11354  	if !(have == uint32(0)) {
 11355  		goto __80
 11356  	}
 11357  	goto inf_leave
 11358  __80:
 11359  	;
 11360  	have--
 11361  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 11362  	bits = bits + uint32(8)
 11363  	goto __78
 11364  __78:
 11365  	if 0 != 0 {
 11366  		goto __77
 11367  	}
 11368  	goto __79
 11369  __79:
 11370  	;
 11371  	goto __75
 11372  __76:
 11373  	;
 11374  	goto __73
 11375  __73:
 11376  	if 0 != 0 {
 11377  		goto __72
 11378  	}
 11379  	goto __74
 11380  __74:
 11381  	;
 11382  	(*Inflate_state)(unsafe.Pointer(state)).Fflags = int32(hold)
 11383  	if !((*Inflate_state)(unsafe.Pointer(state)).Fflags&0xff != Z_DEFLATED) {
 11384  		goto __81
 11385  	}
 11386  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 692 /* "unknown compress..." */
 11387  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 11388  	goto __9
 11389  __81:
 11390  	;
 11391  	if !((*Inflate_state)(unsafe.Pointer(state)).Fflags&0xe000 != 0) {
 11392  		goto __82
 11393  	}
 11394  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 739 /* "unknown header f..." */
 11395  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 11396  	goto __9
 11397  __82:
 11398  	;
 11399  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhead != uintptr(Z_NULL)) {
 11400  		goto __83
 11401  	}
 11402  	(*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Ftext = int32(hold >> 8 & uint64(1))
 11403  __83:
 11404  	;
 11405  	if !((*Inflate_state)(unsafe.Pointer(state)).Fflags&0x0200 != 0 && (*Inflate_state)(unsafe.Pointer(state)).Fwrap&4 != 0) {
 11406  		goto __84
 11407  	}
 11408  __85:
 11409  	*(*uint8)(unsafe.Pointer(bp)) = uint8(hold)
 11410  	*(*uint8)(unsafe.Pointer(bp + 1)) = uint8(hold >> 8)
 11411  	(*Inflate_state)(unsafe.Pointer(state)).Fcheck = Xcrc32(tls, (*Inflate_state)(unsafe.Pointer(state)).Fcheck, bp, uint32(2))
 11412  	goto __86
 11413  __86:
 11414  	if 0 != 0 {
 11415  		goto __85
 11416  	}
 11417  	goto __87
 11418  __87:
 11419  	;
 11420  __84:
 11421  	;
 11422  __88:
 11423  	hold = uint64(0)
 11424  	bits = uint32(0)
 11425  	goto __89
 11426  __89:
 11427  	if 0 != 0 {
 11428  		goto __88
 11429  	}
 11430  	goto __90
 11431  __90:
 11432  	;
 11433  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = TIME
 11434  __12:
 11435  __91:
 11436  __94:
 11437  	if !(bits < uint32(32)) {
 11438  		goto __95
 11439  	}
 11440  __96:
 11441  	if !(have == uint32(0)) {
 11442  		goto __99
 11443  	}
 11444  	goto inf_leave
 11445  __99:
 11446  	;
 11447  	have--
 11448  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 11449  	bits = bits + uint32(8)
 11450  	goto __97
 11451  __97:
 11452  	if 0 != 0 {
 11453  		goto __96
 11454  	}
 11455  	goto __98
 11456  __98:
 11457  	;
 11458  	goto __94
 11459  __95:
 11460  	;
 11461  	goto __92
 11462  __92:
 11463  	if 0 != 0 {
 11464  		goto __91
 11465  	}
 11466  	goto __93
 11467  __93:
 11468  	;
 11469  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhead != uintptr(Z_NULL)) {
 11470  		goto __100
 11471  	}
 11472  	(*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Ftime = hold
 11473  __100:
 11474  	;
 11475  	if !((*Inflate_state)(unsafe.Pointer(state)).Fflags&0x0200 != 0 && (*Inflate_state)(unsafe.Pointer(state)).Fwrap&4 != 0) {
 11476  		goto __101
 11477  	}
 11478  __102:
 11479  	*(*uint8)(unsafe.Pointer(bp)) = uint8(hold)
 11480  	*(*uint8)(unsafe.Pointer(bp + 1)) = uint8(hold >> 8)
 11481  	*(*uint8)(unsafe.Pointer(bp + 2)) = uint8(hold >> 16)
 11482  	*(*uint8)(unsafe.Pointer(bp + 3)) = uint8(hold >> 24)
 11483  	(*Inflate_state)(unsafe.Pointer(state)).Fcheck = Xcrc32(tls, (*Inflate_state)(unsafe.Pointer(state)).Fcheck, bp, uint32(4))
 11484  	goto __103
 11485  __103:
 11486  	if 0 != 0 {
 11487  		goto __102
 11488  	}
 11489  	goto __104
 11490  __104:
 11491  	;
 11492  __101:
 11493  	;
 11494  __105:
 11495  	hold = uint64(0)
 11496  	bits = uint32(0)
 11497  	goto __106
 11498  __106:
 11499  	if 0 != 0 {
 11500  		goto __105
 11501  	}
 11502  	goto __107
 11503  __107:
 11504  	;
 11505  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = OS
 11506  __13:
 11507  __108:
 11508  __111:
 11509  	if !(bits < uint32(16)) {
 11510  		goto __112
 11511  	}
 11512  __113:
 11513  	if !(have == uint32(0)) {
 11514  		goto __116
 11515  	}
 11516  	goto inf_leave
 11517  __116:
 11518  	;
 11519  	have--
 11520  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 11521  	bits = bits + uint32(8)
 11522  	goto __114
 11523  __114:
 11524  	if 0 != 0 {
 11525  		goto __113
 11526  	}
 11527  	goto __115
 11528  __115:
 11529  	;
 11530  	goto __111
 11531  __112:
 11532  	;
 11533  	goto __109
 11534  __109:
 11535  	if 0 != 0 {
 11536  		goto __108
 11537  	}
 11538  	goto __110
 11539  __110:
 11540  	;
 11541  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhead != uintptr(Z_NULL)) {
 11542  		goto __117
 11543  	}
 11544  	(*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fxflags = int32(hold & uint64(0xff))
 11545  	(*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fos = int32(hold >> 8)
 11546  __117:
 11547  	;
 11548  	if !((*Inflate_state)(unsafe.Pointer(state)).Fflags&0x0200 != 0 && (*Inflate_state)(unsafe.Pointer(state)).Fwrap&4 != 0) {
 11549  		goto __118
 11550  	}
 11551  __119:
 11552  	*(*uint8)(unsafe.Pointer(bp)) = uint8(hold)
 11553  	*(*uint8)(unsafe.Pointer(bp + 1)) = uint8(hold >> 8)
 11554  	(*Inflate_state)(unsafe.Pointer(state)).Fcheck = Xcrc32(tls, (*Inflate_state)(unsafe.Pointer(state)).Fcheck, bp, uint32(2))
 11555  	goto __120
 11556  __120:
 11557  	if 0 != 0 {
 11558  		goto __119
 11559  	}
 11560  	goto __121
 11561  __121:
 11562  	;
 11563  __118:
 11564  	;
 11565  __122:
 11566  	hold = uint64(0)
 11567  	bits = uint32(0)
 11568  	goto __123
 11569  __123:
 11570  	if 0 != 0 {
 11571  		goto __122
 11572  	}
 11573  	goto __124
 11574  __124:
 11575  	;
 11576  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = EXLEN
 11577  __14:
 11578  	if !((*Inflate_state)(unsafe.Pointer(state)).Fflags&0x0400 != 0) {
 11579  		goto __125
 11580  	}
 11581  __127:
 11582  __130:
 11583  	if !(bits < uint32(16)) {
 11584  		goto __131
 11585  	}
 11586  __132:
 11587  	if !(have == uint32(0)) {
 11588  		goto __135
 11589  	}
 11590  	goto inf_leave
 11591  __135:
 11592  	;
 11593  	have--
 11594  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 11595  	bits = bits + uint32(8)
 11596  	goto __133
 11597  __133:
 11598  	if 0 != 0 {
 11599  		goto __132
 11600  	}
 11601  	goto __134
 11602  __134:
 11603  	;
 11604  	goto __130
 11605  __131:
 11606  	;
 11607  	goto __128
 11608  __128:
 11609  	if 0 != 0 {
 11610  		goto __127
 11611  	}
 11612  	goto __129
 11613  __129:
 11614  	;
 11615  	(*Inflate_state)(unsafe.Pointer(state)).Flength = uint32(hold)
 11616  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhead != uintptr(Z_NULL)) {
 11617  		goto __136
 11618  	}
 11619  	(*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fextra_len = uint32(hold)
 11620  __136:
 11621  	;
 11622  	if !((*Inflate_state)(unsafe.Pointer(state)).Fflags&0x0200 != 0 && (*Inflate_state)(unsafe.Pointer(state)).Fwrap&4 != 0) {
 11623  		goto __137
 11624  	}
 11625  __138:
 11626  	*(*uint8)(unsafe.Pointer(bp)) = uint8(hold)
 11627  	*(*uint8)(unsafe.Pointer(bp + 1)) = uint8(hold >> 8)
 11628  	(*Inflate_state)(unsafe.Pointer(state)).Fcheck = Xcrc32(tls, (*Inflate_state)(unsafe.Pointer(state)).Fcheck, bp, uint32(2))
 11629  	goto __139
 11630  __139:
 11631  	if 0 != 0 {
 11632  		goto __138
 11633  	}
 11634  	goto __140
 11635  __140:
 11636  	;
 11637  __137:
 11638  	;
 11639  __141:
 11640  	hold = uint64(0)
 11641  	bits = uint32(0)
 11642  	goto __142
 11643  __142:
 11644  	if 0 != 0 {
 11645  		goto __141
 11646  	}
 11647  	goto __143
 11648  __143:
 11649  	;
 11650  	goto __126
 11651  __125:
 11652  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhead != uintptr(Z_NULL)) {
 11653  		goto __144
 11654  	}
 11655  	(*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fextra = uintptr(Z_NULL)
 11656  __144:
 11657  	;
 11658  __126:
 11659  	;
 11660  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = EXTRA
 11661  __15:
 11662  	if !((*Inflate_state)(unsafe.Pointer(state)).Fflags&0x0400 != 0) {
 11663  		goto __145
 11664  	}
 11665  	copy = (*Inflate_state)(unsafe.Pointer(state)).Flength
 11666  	if !(copy > have) {
 11667  		goto __146
 11668  	}
 11669  	copy = have
 11670  __146:
 11671  	;
 11672  	if !(copy != 0) {
 11673  		goto __147
 11674  	}
 11675  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhead != uintptr(Z_NULL) && (*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fextra != uintptr(Z_NULL)) {
 11676  		goto __148
 11677  	}
 11678  	len = (*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fextra_len - (*Inflate_state)(unsafe.Pointer(state)).Flength
 11679  	libc.Xmemcpy(tls, (*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fextra+uintptr(len), next,
 11680  		func() uint64 {
 11681  			if len+copy > (*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fextra_max {
 11682  				return uint64((*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fextra_max - len)
 11683  			}
 11684  			return uint64(copy)
 11685  		}())
 11686  __148:
 11687  	;
 11688  	if !((*Inflate_state)(unsafe.Pointer(state)).Fflags&0x0200 != 0 && (*Inflate_state)(unsafe.Pointer(state)).Fwrap&4 != 0) {
 11689  		goto __149
 11690  	}
 11691  	(*Inflate_state)(unsafe.Pointer(state)).Fcheck = Xcrc32(tls, (*Inflate_state)(unsafe.Pointer(state)).Fcheck, next, copy)
 11692  __149:
 11693  	;
 11694  	have = have - copy
 11695  	next += uintptr(copy)
 11696  	*(*uint32)(unsafe.Pointer(state + 92)) -= copy
 11697  __147:
 11698  	;
 11699  	if !((*Inflate_state)(unsafe.Pointer(state)).Flength != 0) {
 11700  		goto __150
 11701  	}
 11702  	goto inf_leave
 11703  __150:
 11704  	;
 11705  __145:
 11706  	;
 11707  	(*Inflate_state)(unsafe.Pointer(state)).Flength = uint32(0)
 11708  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = NAME
 11709  __16:
 11710  	if !((*Inflate_state)(unsafe.Pointer(state)).Fflags&0x0800 != 0) {
 11711  		goto __151
 11712  	}
 11713  	if !(have == uint32(0)) {
 11714  		goto __153
 11715  	}
 11716  	goto inf_leave
 11717  __153:
 11718  	;
 11719  	copy = uint32(0)
 11720  __154:
 11721  	len = uint32(*(*uint8)(unsafe.Pointer(next + uintptr(libc.PostIncUint32(&copy, 1)))))
 11722  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhead != uintptr(Z_NULL) && (*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fname != uintptr(Z_NULL) && (*Inflate_state)(unsafe.Pointer(state)).Flength < (*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fname_max) {
 11723  		goto __157
 11724  	}
 11725  	*(*Bytef)(unsafe.Pointer((*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fname + uintptr(libc.PostIncUint32(&(*Inflate_state)(unsafe.Pointer(state)).Flength, 1)))) = Bytef(len)
 11726  __157:
 11727  	;
 11728  	goto __155
 11729  __155:
 11730  	if len != 0 && copy < have {
 11731  		goto __154
 11732  	}
 11733  	goto __156
 11734  __156:
 11735  	;
 11736  	if !((*Inflate_state)(unsafe.Pointer(state)).Fflags&0x0200 != 0 && (*Inflate_state)(unsafe.Pointer(state)).Fwrap&4 != 0) {
 11737  		goto __158
 11738  	}
 11739  	(*Inflate_state)(unsafe.Pointer(state)).Fcheck = Xcrc32(tls, (*Inflate_state)(unsafe.Pointer(state)).Fcheck, next, copy)
 11740  __158:
 11741  	;
 11742  	have = have - copy
 11743  	next += uintptr(copy)
 11744  	if !(len != 0) {
 11745  		goto __159
 11746  	}
 11747  	goto inf_leave
 11748  __159:
 11749  	;
 11750  	goto __152
 11751  __151:
 11752  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhead != uintptr(Z_NULL)) {
 11753  		goto __160
 11754  	}
 11755  	(*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fname = uintptr(Z_NULL)
 11756  __160:
 11757  	;
 11758  __152:
 11759  	;
 11760  	(*Inflate_state)(unsafe.Pointer(state)).Flength = uint32(0)
 11761  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = COMMENT
 11762  __17:
 11763  	if !((*Inflate_state)(unsafe.Pointer(state)).Fflags&0x1000 != 0) {
 11764  		goto __161
 11765  	}
 11766  	if !(have == uint32(0)) {
 11767  		goto __163
 11768  	}
 11769  	goto inf_leave
 11770  __163:
 11771  	;
 11772  	copy = uint32(0)
 11773  __164:
 11774  	len = uint32(*(*uint8)(unsafe.Pointer(next + uintptr(libc.PostIncUint32(&copy, 1)))))
 11775  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhead != uintptr(Z_NULL) && (*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fcomment != uintptr(Z_NULL) && (*Inflate_state)(unsafe.Pointer(state)).Flength < (*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fcomm_max) {
 11776  		goto __167
 11777  	}
 11778  	*(*Bytef)(unsafe.Pointer((*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fcomment + uintptr(libc.PostIncUint32(&(*Inflate_state)(unsafe.Pointer(state)).Flength, 1)))) = Bytef(len)
 11779  __167:
 11780  	;
 11781  	goto __165
 11782  __165:
 11783  	if len != 0 && copy < have {
 11784  		goto __164
 11785  	}
 11786  	goto __166
 11787  __166:
 11788  	;
 11789  	if !((*Inflate_state)(unsafe.Pointer(state)).Fflags&0x0200 != 0 && (*Inflate_state)(unsafe.Pointer(state)).Fwrap&4 != 0) {
 11790  		goto __168
 11791  	}
 11792  	(*Inflate_state)(unsafe.Pointer(state)).Fcheck = Xcrc32(tls, (*Inflate_state)(unsafe.Pointer(state)).Fcheck, next, copy)
 11793  __168:
 11794  	;
 11795  	have = have - copy
 11796  	next += uintptr(copy)
 11797  	if !(len != 0) {
 11798  		goto __169
 11799  	}
 11800  	goto inf_leave
 11801  __169:
 11802  	;
 11803  	goto __162
 11804  __161:
 11805  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhead != uintptr(Z_NULL)) {
 11806  		goto __170
 11807  	}
 11808  	(*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fcomment = uintptr(Z_NULL)
 11809  __170:
 11810  	;
 11811  __162:
 11812  	;
 11813  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = HCRC
 11814  __18:
 11815  	if !((*Inflate_state)(unsafe.Pointer(state)).Fflags&0x0200 != 0) {
 11816  		goto __171
 11817  	}
 11818  __172:
 11819  __175:
 11820  	if !(bits < uint32(16)) {
 11821  		goto __176
 11822  	}
 11823  __177:
 11824  	if !(have == uint32(0)) {
 11825  		goto __180
 11826  	}
 11827  	goto inf_leave
 11828  __180:
 11829  	;
 11830  	have--
 11831  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 11832  	bits = bits + uint32(8)
 11833  	goto __178
 11834  __178:
 11835  	if 0 != 0 {
 11836  		goto __177
 11837  	}
 11838  	goto __179
 11839  __179:
 11840  	;
 11841  	goto __175
 11842  __176:
 11843  	;
 11844  	goto __173
 11845  __173:
 11846  	if 0 != 0 {
 11847  		goto __172
 11848  	}
 11849  	goto __174
 11850  __174:
 11851  	;
 11852  	if !((*Inflate_state)(unsafe.Pointer(state)).Fwrap&4 != 0 && hold != (*Inflate_state)(unsafe.Pointer(state)).Fcheck&uint64(0xffff)) {
 11853  		goto __181
 11854  	}
 11855  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 764 /* "header crc misma..." */
 11856  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 11857  	goto __9
 11858  __181:
 11859  	;
 11860  __182:
 11861  	hold = uint64(0)
 11862  	bits = uint32(0)
 11863  	goto __183
 11864  __183:
 11865  	if 0 != 0 {
 11866  		goto __182
 11867  	}
 11868  	goto __184
 11869  __184:
 11870  	;
 11871  __171:
 11872  	;
 11873  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhead != uintptr(Z_NULL)) {
 11874  		goto __185
 11875  	}
 11876  	(*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fhcrc = (*Inflate_state)(unsafe.Pointer(state)).Fflags >> 9 & 1
 11877  	(*Gz_header)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fhead)).Fdone = 1
 11878  __185:
 11879  	;
 11880  	(*Z_stream)(unsafe.Pointer(strm)).Fadler = libc.AssignPtrUint64(state+32, Xcrc32(tls, uint64(0), uintptr(Z_NULL), uint32(0)))
 11881  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = TYPE
 11882  	goto __9
 11883  __19:
 11884  __186:
 11885  __189:
 11886  	if !(bits < uint32(32)) {
 11887  		goto __190
 11888  	}
 11889  __191:
 11890  	if !(have == uint32(0)) {
 11891  		goto __194
 11892  	}
 11893  	goto inf_leave
 11894  __194:
 11895  	;
 11896  	have--
 11897  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 11898  	bits = bits + uint32(8)
 11899  	goto __192
 11900  __192:
 11901  	if 0 != 0 {
 11902  		goto __191
 11903  	}
 11904  	goto __193
 11905  __193:
 11906  	;
 11907  	goto __189
 11908  __190:
 11909  	;
 11910  	goto __187
 11911  __187:
 11912  	if 0 != 0 {
 11913  		goto __186
 11914  	}
 11915  	goto __188
 11916  __188:
 11917  	;
 11918  	(*Z_stream)(unsafe.Pointer(strm)).Fadler = libc.AssignPtrUint64(state+32, hold>>24&uint64(0xff)+hold>>8&uint64(0xff00)+hold&uint64(0xff00)<<8+hold&uint64(0xff)<<24)
 11919  __195:
 11920  	hold = uint64(0)
 11921  	bits = uint32(0)
 11922  	goto __196
 11923  __196:
 11924  	if 0 != 0 {
 11925  		goto __195
 11926  	}
 11927  	goto __197
 11928  __197:
 11929  	;
 11930  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = DICT
 11931  __20:
 11932  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhavedict == 0) {
 11933  		goto __198
 11934  	}
 11935  __199:
 11936  	(*Z_stream)(unsafe.Pointer(strm)).Fnext_out = put
 11937  	(*Z_stream)(unsafe.Pointer(strm)).Favail_out = left
 11938  	(*Z_stream)(unsafe.Pointer(strm)).Fnext_in = next
 11939  	(*Z_stream)(unsafe.Pointer(strm)).Favail_in = have
 11940  	(*Inflate_state)(unsafe.Pointer(state)).Fhold = hold
 11941  	(*Inflate_state)(unsafe.Pointer(state)).Fbits = bits
 11942  	goto __200
 11943  __200:
 11944  	if 0 != 0 {
 11945  		goto __199
 11946  	}
 11947  	goto __201
 11948  __201:
 11949  	;
 11950  	return Z_NEED_DICT
 11951  __198:
 11952  	;
 11953  	(*Z_stream)(unsafe.Pointer(strm)).Fadler = libc.AssignPtrUint64(state+32, Xadler32(tls, uint64(0), uintptr(Z_NULL), uint32(0)))
 11954  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = TYPE
 11955  __21:
 11956  	if !(flush == Z_BLOCK || flush == Z_TREES) {
 11957  		goto __202
 11958  	}
 11959  	goto inf_leave
 11960  __202:
 11961  	;
 11962  __22:
 11963  	if !((*Inflate_state)(unsafe.Pointer(state)).Flast != 0) {
 11964  		goto __203
 11965  	}
 11966  __204:
 11967  	hold >>= bits & uint32(7)
 11968  	bits = bits - bits&uint32(7)
 11969  	goto __205
 11970  __205:
 11971  	if 0 != 0 {
 11972  		goto __204
 11973  	}
 11974  	goto __206
 11975  __206:
 11976  	;
 11977  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = CHECK
 11978  	goto __9
 11979  __203:
 11980  	;
 11981  __207:
 11982  __210:
 11983  	if !(bits < uint32(3)) {
 11984  		goto __211
 11985  	}
 11986  __212:
 11987  	if !(have == uint32(0)) {
 11988  		goto __215
 11989  	}
 11990  	goto inf_leave
 11991  __215:
 11992  	;
 11993  	have--
 11994  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 11995  	bits = bits + uint32(8)
 11996  	goto __213
 11997  __213:
 11998  	if 0 != 0 {
 11999  		goto __212
 12000  	}
 12001  	goto __214
 12002  __214:
 12003  	;
 12004  	goto __210
 12005  __211:
 12006  	;
 12007  	goto __208
 12008  __208:
 12009  	if 0 != 0 {
 12010  		goto __207
 12011  	}
 12012  	goto __209
 12013  __209:
 12014  	;
 12015  	(*Inflate_state)(unsafe.Pointer(state)).Flast = int32(uint32(hold) & (uint32(1)<<1 - uint32(1)))
 12016  __216:
 12017  	hold >>= 1
 12018  	bits = bits - uint32(1)
 12019  	goto __217
 12020  __217:
 12021  	if 0 != 0 {
 12022  		goto __216
 12023  	}
 12024  	goto __218
 12025  __218:
 12026  	;
 12027  	switch uint32(hold) & (uint32(1)<<2 - uint32(1)) {
 12028  	case uint32(0):
 12029  		goto __220
 12030  	case uint32(1):
 12031  		goto __221
 12032  	case uint32(2):
 12033  		goto __222
 12034  	case uint32(3):
 12035  		goto __223
 12036  	}
 12037  	goto __219
 12038  __220: // stored block
 12039  	;
 12040  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = STORED
 12041  	goto __219
 12042  __221: // fixed block
 12043  	fixedtables1(tls, state)
 12044  
 12045  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = LEN_ // decode codes
 12046  	if !(flush == Z_TREES) {
 12047  		goto __224
 12048  	}
 12049  __225:
 12050  	hold >>= 2
 12051  	bits = bits - uint32(2)
 12052  	goto __226
 12053  __226:
 12054  	if 0 != 0 {
 12055  		goto __225
 12056  	}
 12057  	goto __227
 12058  __227:
 12059  	;
 12060  	goto inf_leave
 12061  __224:
 12062  	;
 12063  	goto __219
 12064  __222: // dynamic block
 12065  	;
 12066  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = TABLE
 12067  	goto __219
 12068  __223:
 12069  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 367 /* "invalid block ty..." */
 12070  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 12071  __219:
 12072  	;
 12073  __228:
 12074  	hold >>= 2
 12075  	bits = bits - uint32(2)
 12076  	goto __229
 12077  __229:
 12078  	if 0 != 0 {
 12079  		goto __228
 12080  	}
 12081  	goto __230
 12082  __230:
 12083  	;
 12084  	goto __9
 12085  __23:
 12086  __231:
 12087  	hold >>= bits & uint32(7)
 12088  	bits = bits - bits&uint32(7)
 12089  	goto __232
 12090  __232:
 12091  	if 0 != 0 {
 12092  		goto __231
 12093  	}
 12094  	goto __233
 12095  __233:
 12096  	; // go to byte boundary
 12097  __234:
 12098  __237:
 12099  	if !(bits < uint32(32)) {
 12100  		goto __238
 12101  	}
 12102  __239:
 12103  	if !(have == uint32(0)) {
 12104  		goto __242
 12105  	}
 12106  	goto inf_leave
 12107  __242:
 12108  	;
 12109  	have--
 12110  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 12111  	bits = bits + uint32(8)
 12112  	goto __240
 12113  __240:
 12114  	if 0 != 0 {
 12115  		goto __239
 12116  	}
 12117  	goto __241
 12118  __241:
 12119  	;
 12120  	goto __237
 12121  __238:
 12122  	;
 12123  	goto __235
 12124  __235:
 12125  	if 0 != 0 {
 12126  		goto __234
 12127  	}
 12128  	goto __236
 12129  __236:
 12130  	;
 12131  	if !(hold&uint64(0xffff) != hold>>16^uint64(0xffff)) {
 12132  		goto __243
 12133  	}
 12134  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 386 /* "invalid stored b..." */
 12135  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 12136  	goto __9
 12137  __243:
 12138  	;
 12139  	(*Inflate_state)(unsafe.Pointer(state)).Flength = uint32(hold) & uint32(0xffff)
 12140  
 12141  __244:
 12142  	hold = uint64(0)
 12143  	bits = uint32(0)
 12144  	goto __245
 12145  __245:
 12146  	if 0 != 0 {
 12147  		goto __244
 12148  	}
 12149  	goto __246
 12150  __246:
 12151  	;
 12152  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = COPY_
 12153  	if !(flush == Z_TREES) {
 12154  		goto __247
 12155  	}
 12156  	goto inf_leave
 12157  __247:
 12158  	;
 12159  __24:
 12160  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = COPY
 12161  __25:
 12162  	copy = (*Inflate_state)(unsafe.Pointer(state)).Flength
 12163  	if !(copy != 0) {
 12164  		goto __248
 12165  	}
 12166  	if !(copy > have) {
 12167  		goto __249
 12168  	}
 12169  	copy = have
 12170  __249:
 12171  	;
 12172  	if !(copy > left) {
 12173  		goto __250
 12174  	}
 12175  	copy = left
 12176  __250:
 12177  	;
 12178  	if !(copy == uint32(0)) {
 12179  		goto __251
 12180  	}
 12181  	goto inf_leave
 12182  __251:
 12183  	;
 12184  	libc.Xmemcpy(tls, put, next, uint64(copy))
 12185  	have = have - copy
 12186  	next += uintptr(copy)
 12187  	left = left - copy
 12188  	put += uintptr(copy)
 12189  	*(*uint32)(unsafe.Pointer(state + 92)) -= copy
 12190  	goto __9
 12191  __248:
 12192  	;
 12193  
 12194  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = TYPE
 12195  	goto __9
 12196  __26:
 12197  __252:
 12198  __255:
 12199  	if !(bits < uint32(14)) {
 12200  		goto __256
 12201  	}
 12202  __257:
 12203  	if !(have == uint32(0)) {
 12204  		goto __260
 12205  	}
 12206  	goto inf_leave
 12207  __260:
 12208  	;
 12209  	have--
 12210  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 12211  	bits = bits + uint32(8)
 12212  	goto __258
 12213  __258:
 12214  	if 0 != 0 {
 12215  		goto __257
 12216  	}
 12217  	goto __259
 12218  __259:
 12219  	;
 12220  	goto __255
 12221  __256:
 12222  	;
 12223  	goto __253
 12224  __253:
 12225  	if 0 != 0 {
 12226  		goto __252
 12227  	}
 12228  	goto __254
 12229  __254:
 12230  	;
 12231  	(*Inflate_state)(unsafe.Pointer(state)).Fnlen = uint32(hold)&(uint32(1)<<5-uint32(1)) + uint32(257)
 12232  __261:
 12233  	hold >>= 5
 12234  	bits = bits - uint32(5)
 12235  	goto __262
 12236  __262:
 12237  	if 0 != 0 {
 12238  		goto __261
 12239  	}
 12240  	goto __263
 12241  __263:
 12242  	;
 12243  	(*Inflate_state)(unsafe.Pointer(state)).Fndist = uint32(hold)&(uint32(1)<<5-uint32(1)) + uint32(1)
 12244  __264:
 12245  	hold >>= 5
 12246  	bits = bits - uint32(5)
 12247  	goto __265
 12248  __265:
 12249  	if 0 != 0 {
 12250  		goto __264
 12251  	}
 12252  	goto __266
 12253  __266:
 12254  	;
 12255  	(*Inflate_state)(unsafe.Pointer(state)).Fncode = uint32(hold)&(uint32(1)<<4-uint32(1)) + uint32(4)
 12256  __267:
 12257  	hold >>= 4
 12258  	bits = bits - uint32(4)
 12259  	goto __268
 12260  __268:
 12261  	if 0 != 0 {
 12262  		goto __267
 12263  	}
 12264  	goto __269
 12265  __269:
 12266  	;
 12267  	if !((*Inflate_state)(unsafe.Pointer(state)).Fnlen > uint32(286) || (*Inflate_state)(unsafe.Pointer(state)).Fndist > uint32(30)) {
 12268  		goto __270
 12269  	}
 12270  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 415 /* "too many length ..." */
 12271  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 12272  	goto __9
 12273  __270:
 12274  	;
 12275  
 12276  	(*Inflate_state)(unsafe.Pointer(state)).Fhave = uint32(0)
 12277  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = LENLENS
 12278  __27:
 12279  __271:
 12280  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhave < (*Inflate_state)(unsafe.Pointer(state)).Fncode) {
 12281  		goto __272
 12282  	}
 12283  __273:
 12284  __276:
 12285  	if !(bits < uint32(3)) {
 12286  		goto __277
 12287  	}
 12288  __278:
 12289  	if !(have == uint32(0)) {
 12290  		goto __281
 12291  	}
 12292  	goto inf_leave
 12293  __281:
 12294  	;
 12295  	have--
 12296  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 12297  	bits = bits + uint32(8)
 12298  	goto __279
 12299  __279:
 12300  	if 0 != 0 {
 12301  		goto __278
 12302  	}
 12303  	goto __280
 12304  __280:
 12305  	;
 12306  	goto __276
 12307  __277:
 12308  	;
 12309  	goto __274
 12310  __274:
 12311  	if 0 != 0 {
 12312  		goto __273
 12313  	}
 12314  	goto __275
 12315  __275:
 12316  	;
 12317  	*(*uint16)(unsafe.Pointer(state + 152 + uintptr(order1[libc.PostIncUint32(&(*Inflate_state)(unsafe.Pointer(state)).Fhave, 1)])*2)) = uint16(uint32(hold) & (uint32(1)<<3 - uint32(1)))
 12318  __282:
 12319  	hold >>= 3
 12320  	bits = bits - uint32(3)
 12321  	goto __283
 12322  __283:
 12323  	if 0 != 0 {
 12324  		goto __282
 12325  	}
 12326  	goto __284
 12327  __284:
 12328  	;
 12329  	goto __271
 12330  __272:
 12331  	;
 12332  __285:
 12333  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhave < uint32(19)) {
 12334  		goto __286
 12335  	}
 12336  	*(*uint16)(unsafe.Pointer(state + 152 + uintptr(order1[libc.PostIncUint32(&(*Inflate_state)(unsafe.Pointer(state)).Fhave, 1)])*2)) = uint16(0)
 12337  	goto __285
 12338  __286:
 12339  	;
 12340  	(*Inflate_state)(unsafe.Pointer(state)).Fnext = state + 1368 /* &.codes */
 12341  	(*Inflate_state)(unsafe.Pointer(state)).Flencode = (*Inflate_state)(unsafe.Pointer(state)).Fnext
 12342  	(*Inflate_state)(unsafe.Pointer(state)).Flenbits = uint32(7)
 12343  	ret = Xinflate_table(tls, CODES, state+152, uint32(19), state+144,
 12344  		state+120, state+792)
 12345  	if !(ret != 0) {
 12346  		goto __287
 12347  	}
 12348  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 451 /* "invalid code len..." */
 12349  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 12350  	goto __9
 12351  __287:
 12352  	;
 12353  
 12354  	(*Inflate_state)(unsafe.Pointer(state)).Fhave = uint32(0)
 12355  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = CODELENS
 12356  __28:
 12357  __288:
 12358  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhave < (*Inflate_state)(unsafe.Pointer(state)).Fnlen+(*Inflate_state)(unsafe.Pointer(state)).Fndist) {
 12359  		goto __289
 12360  	}
 12361  __290:
 12362  	here = *(*Code)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Flencode + uintptr(uint32(hold)&(uint32(1)<<(*Inflate_state)(unsafe.Pointer(state)).Flenbits-uint32(1)))*4))
 12363  	if !(uint32(here.Fbits) <= bits) {
 12364  		goto __293
 12365  	}
 12366  	goto __292
 12367  __293:
 12368  	;
 12369  __294:
 12370  	if !(have == uint32(0)) {
 12371  		goto __297
 12372  	}
 12373  	goto inf_leave
 12374  __297:
 12375  	;
 12376  	have--
 12377  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 12378  	bits = bits + uint32(8)
 12379  	goto __295
 12380  __295:
 12381  	if 0 != 0 {
 12382  		goto __294
 12383  	}
 12384  	goto __296
 12385  __296:
 12386  	;
 12387  	goto __291
 12388  __291:
 12389  	goto __290
 12390  	goto __292
 12391  __292:
 12392  	;
 12393  	if !(int32(here.Fval) < 16) {
 12394  		goto __298
 12395  	}
 12396  __300:
 12397  	hold >>= int32(here.Fbits)
 12398  	bits = bits - uint32(here.Fbits)
 12399  	goto __301
 12400  __301:
 12401  	if 0 != 0 {
 12402  		goto __300
 12403  	}
 12404  	goto __302
 12405  __302:
 12406  	;
 12407  	*(*uint16)(unsafe.Pointer(state + 152 + uintptr(libc.PostIncUint32(&(*Inflate_state)(unsafe.Pointer(state)).Fhave, 1))*2)) = here.Fval
 12408  	goto __299
 12409  __298:
 12410  	if !(int32(here.Fval) == 16) {
 12411  		goto __303
 12412  	}
 12413  __305:
 12414  __308:
 12415  	if !(bits < uint32(int32(here.Fbits)+2)) {
 12416  		goto __309
 12417  	}
 12418  __310:
 12419  	if !(have == uint32(0)) {
 12420  		goto __313
 12421  	}
 12422  	goto inf_leave
 12423  __313:
 12424  	;
 12425  	have--
 12426  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 12427  	bits = bits + uint32(8)
 12428  	goto __311
 12429  __311:
 12430  	if 0 != 0 {
 12431  		goto __310
 12432  	}
 12433  	goto __312
 12434  __312:
 12435  	;
 12436  	goto __308
 12437  __309:
 12438  	;
 12439  	goto __306
 12440  __306:
 12441  	if 0 != 0 {
 12442  		goto __305
 12443  	}
 12444  	goto __307
 12445  __307:
 12446  	;
 12447  __314:
 12448  	hold >>= int32(here.Fbits)
 12449  	bits = bits - uint32(here.Fbits)
 12450  	goto __315
 12451  __315:
 12452  	if 0 != 0 {
 12453  		goto __314
 12454  	}
 12455  	goto __316
 12456  __316:
 12457  	;
 12458  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhave == uint32(0)) {
 12459  		goto __317
 12460  	}
 12461  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 476 /* "invalid bit leng..." */
 12462  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 12463  	goto __289
 12464  __317:
 12465  	;
 12466  	len = uint32(*(*uint16)(unsafe.Pointer(state + 152 + uintptr((*Inflate_state)(unsafe.Pointer(state)).Fhave-uint32(1))*2)))
 12467  	copy = uint32(3) + uint32(hold)&(uint32(1)<<2-uint32(1))
 12468  __318:
 12469  	hold >>= 2
 12470  	bits = bits - uint32(2)
 12471  	goto __319
 12472  __319:
 12473  	if 0 != 0 {
 12474  		goto __318
 12475  	}
 12476  	goto __320
 12477  __320:
 12478  	;
 12479  	goto __304
 12480  __303:
 12481  	if !(int32(here.Fval) == 17) {
 12482  		goto __321
 12483  	}
 12484  __323:
 12485  __326:
 12486  	if !(bits < uint32(int32(here.Fbits)+3)) {
 12487  		goto __327
 12488  	}
 12489  __328:
 12490  	if !(have == uint32(0)) {
 12491  		goto __331
 12492  	}
 12493  	goto inf_leave
 12494  __331:
 12495  	;
 12496  	have--
 12497  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 12498  	bits = bits + uint32(8)
 12499  	goto __329
 12500  __329:
 12501  	if 0 != 0 {
 12502  		goto __328
 12503  	}
 12504  	goto __330
 12505  __330:
 12506  	;
 12507  	goto __326
 12508  __327:
 12509  	;
 12510  	goto __324
 12511  __324:
 12512  	if 0 != 0 {
 12513  		goto __323
 12514  	}
 12515  	goto __325
 12516  __325:
 12517  	;
 12518  __332:
 12519  	hold >>= int32(here.Fbits)
 12520  	bits = bits - uint32(here.Fbits)
 12521  	goto __333
 12522  __333:
 12523  	if 0 != 0 {
 12524  		goto __332
 12525  	}
 12526  	goto __334
 12527  __334:
 12528  	;
 12529  	len = uint32(0)
 12530  	copy = uint32(3) + uint32(hold)&(uint32(1)<<3-uint32(1))
 12531  __335:
 12532  	hold >>= 3
 12533  	bits = bits - uint32(3)
 12534  	goto __336
 12535  __336:
 12536  	if 0 != 0 {
 12537  		goto __335
 12538  	}
 12539  	goto __337
 12540  __337:
 12541  	;
 12542  	goto __322
 12543  __321:
 12544  __338:
 12545  __341:
 12546  	if !(bits < uint32(int32(here.Fbits)+7)) {
 12547  		goto __342
 12548  	}
 12549  __343:
 12550  	if !(have == uint32(0)) {
 12551  		goto __346
 12552  	}
 12553  	goto inf_leave
 12554  __346:
 12555  	;
 12556  	have--
 12557  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 12558  	bits = bits + uint32(8)
 12559  	goto __344
 12560  __344:
 12561  	if 0 != 0 {
 12562  		goto __343
 12563  	}
 12564  	goto __345
 12565  __345:
 12566  	;
 12567  	goto __341
 12568  __342:
 12569  	;
 12570  	goto __339
 12571  __339:
 12572  	if 0 != 0 {
 12573  		goto __338
 12574  	}
 12575  	goto __340
 12576  __340:
 12577  	;
 12578  __347:
 12579  	hold >>= int32(here.Fbits)
 12580  	bits = bits - uint32(here.Fbits)
 12581  	goto __348
 12582  __348:
 12583  	if 0 != 0 {
 12584  		goto __347
 12585  	}
 12586  	goto __349
 12587  __349:
 12588  	;
 12589  	len = uint32(0)
 12590  	copy = uint32(11) + uint32(hold)&(uint32(1)<<7-uint32(1))
 12591  __350:
 12592  	hold >>= 7
 12593  	bits = bits - uint32(7)
 12594  	goto __351
 12595  __351:
 12596  	if 0 != 0 {
 12597  		goto __350
 12598  	}
 12599  	goto __352
 12600  __352:
 12601  	;
 12602  __322:
 12603  	;
 12604  __304:
 12605  	;
 12606  	if !((*Inflate_state)(unsafe.Pointer(state)).Fhave+copy > (*Inflate_state)(unsafe.Pointer(state)).Fnlen+(*Inflate_state)(unsafe.Pointer(state)).Fndist) {
 12607  		goto __353
 12608  	}
 12609  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 476 /* "invalid bit leng..." */
 12610  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 12611  	goto __289
 12612  __353:
 12613  	;
 12614  __354:
 12615  	if !(libc.PostDecUint32(&copy, 1) != 0) {
 12616  		goto __355
 12617  	}
 12618  	*(*uint16)(unsafe.Pointer(state + 152 + uintptr(libc.PostIncUint32(&(*Inflate_state)(unsafe.Pointer(state)).Fhave, 1))*2)) = uint16(len)
 12619  	goto __354
 12620  __355:
 12621  	;
 12622  __299:
 12623  	;
 12624  	goto __288
 12625  __289:
 12626  	;
 12627  
 12628  	// handle error breaks in while
 12629  	if !((*Inflate_state)(unsafe.Pointer(state)).Fmode == BAD) {
 12630  		goto __356
 12631  	}
 12632  	goto __9
 12633  __356:
 12634  	;
 12635  
 12636  	// check for end-of-block code (better have one)
 12637  	if !(int32(*(*uint16)(unsafe.Pointer(state + 152 + 256*2))) == 0) {
 12638  		goto __357
 12639  	}
 12640  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 502 /* "invalid code -- ..." */
 12641  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 12642  	goto __9
 12643  __357:
 12644  	;
 12645  
 12646  	// build code tables -- note: do not change the lenbits or distbits
 12647  	//                values here (9 and 6) without reading the comments in inftrees.h
 12648  	//                concerning the ENOUGH constants, which depend on those values
 12649  	(*Inflate_state)(unsafe.Pointer(state)).Fnext = state + 1368 /* &.codes */
 12650  	(*Inflate_state)(unsafe.Pointer(state)).Flencode = (*Inflate_state)(unsafe.Pointer(state)).Fnext
 12651  	(*Inflate_state)(unsafe.Pointer(state)).Flenbits = uint32(9)
 12652  	ret = Xinflate_table(tls, LENS, state+152, (*Inflate_state)(unsafe.Pointer(state)).Fnlen, state+144,
 12653  		state+120, state+792)
 12654  	if !(ret != 0) {
 12655  		goto __358
 12656  	}
 12657  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 539 /* "invalid literal/..." */
 12658  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 12659  	goto __9
 12660  __358:
 12661  	;
 12662  	(*Inflate_state)(unsafe.Pointer(state)).Fdistcode = (*Inflate_state)(unsafe.Pointer(state)).Fnext
 12663  	(*Inflate_state)(unsafe.Pointer(state)).Fdistbits = uint32(6)
 12664  	ret = Xinflate_table(tls, DISTS, state+152+uintptr((*Inflate_state)(unsafe.Pointer(state)).Fnlen)*2, (*Inflate_state)(unsafe.Pointer(state)).Fndist,
 12665  		state+144, state+124, state+792)
 12666  	if !(ret != 0) {
 12667  		goto __359
 12668  	}
 12669  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 567 /* "invalid distance..." */
 12670  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 12671  	goto __9
 12672  __359:
 12673  	;
 12674  
 12675  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = LEN_
 12676  	if !(flush == Z_TREES) {
 12677  		goto __360
 12678  	}
 12679  	goto inf_leave
 12680  __360:
 12681  	;
 12682  __29:
 12683  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = LEN
 12684  __30:
 12685  	if !(have >= uint32(6) && left >= uint32(258)) {
 12686  		goto __361
 12687  	}
 12688  __362:
 12689  	(*Z_stream)(unsafe.Pointer(strm)).Fnext_out = put
 12690  	(*Z_stream)(unsafe.Pointer(strm)).Favail_out = left
 12691  	(*Z_stream)(unsafe.Pointer(strm)).Fnext_in = next
 12692  	(*Z_stream)(unsafe.Pointer(strm)).Favail_in = have
 12693  	(*Inflate_state)(unsafe.Pointer(state)).Fhold = hold
 12694  	(*Inflate_state)(unsafe.Pointer(state)).Fbits = bits
 12695  	goto __363
 12696  __363:
 12697  	if 0 != 0 {
 12698  		goto __362
 12699  	}
 12700  	goto __364
 12701  __364:
 12702  	;
 12703  	Xinflate_fast(tls, strm, out)
 12704  __365:
 12705  	put = (*Z_stream)(unsafe.Pointer(strm)).Fnext_out
 12706  	left = (*Z_stream)(unsafe.Pointer(strm)).Favail_out
 12707  	next = (*Z_stream)(unsafe.Pointer(strm)).Fnext_in
 12708  	have = (*Z_stream)(unsafe.Pointer(strm)).Favail_in
 12709  	hold = (*Inflate_state)(unsafe.Pointer(state)).Fhold
 12710  	bits = (*Inflate_state)(unsafe.Pointer(state)).Fbits
 12711  	goto __366
 12712  __366:
 12713  	if 0 != 0 {
 12714  		goto __365
 12715  	}
 12716  	goto __367
 12717  __367:
 12718  	;
 12719  	if !((*Inflate_state)(unsafe.Pointer(state)).Fmode == TYPE) {
 12720  		goto __368
 12721  	}
 12722  	(*Inflate_state)(unsafe.Pointer(state)).Fback = -1
 12723  __368:
 12724  	;
 12725  	goto __9
 12726  __361:
 12727  	;
 12728  	(*Inflate_state)(unsafe.Pointer(state)).Fback = 0
 12729  __369:
 12730  	here = *(*Code)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Flencode + uintptr(uint32(hold)&(uint32(1)<<(*Inflate_state)(unsafe.Pointer(state)).Flenbits-uint32(1)))*4))
 12731  	if !(uint32(here.Fbits) <= bits) {
 12732  		goto __372
 12733  	}
 12734  	goto __371
 12735  __372:
 12736  	;
 12737  __373:
 12738  	if !(have == uint32(0)) {
 12739  		goto __376
 12740  	}
 12741  	goto inf_leave
 12742  __376:
 12743  	;
 12744  	have--
 12745  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 12746  	bits = bits + uint32(8)
 12747  	goto __374
 12748  __374:
 12749  	if 0 != 0 {
 12750  		goto __373
 12751  	}
 12752  	goto __375
 12753  __375:
 12754  	;
 12755  	goto __370
 12756  __370:
 12757  	goto __369
 12758  	goto __371
 12759  __371:
 12760  	;
 12761  	if !(here.Fop != 0 && int32(here.Fop)&0xf0 == 0) {
 12762  		goto __377
 12763  	}
 12764  	last = here
 12765  __378:
 12766  	here = *(*Code)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Flencode + uintptr(uint32(last.Fval)+uint32(hold)&(uint32(1)<<(int32(last.Fbits)+int32(last.Fop))-uint32(1))>>int32(last.Fbits))*4))
 12767  	if !(uint32(int32(last.Fbits)+int32(here.Fbits)) <= bits) {
 12768  		goto __381
 12769  	}
 12770  	goto __380
 12771  __381:
 12772  	;
 12773  __382:
 12774  	if !(have == uint32(0)) {
 12775  		goto __385
 12776  	}
 12777  	goto inf_leave
 12778  __385:
 12779  	;
 12780  	have--
 12781  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 12782  	bits = bits + uint32(8)
 12783  	goto __383
 12784  __383:
 12785  	if 0 != 0 {
 12786  		goto __382
 12787  	}
 12788  	goto __384
 12789  __384:
 12790  	;
 12791  	goto __379
 12792  __379:
 12793  	goto __378
 12794  	goto __380
 12795  __380:
 12796  	;
 12797  __386:
 12798  	hold >>= int32(last.Fbits)
 12799  	bits = bits - uint32(last.Fbits)
 12800  	goto __387
 12801  __387:
 12802  	if 0 != 0 {
 12803  		goto __386
 12804  	}
 12805  	goto __388
 12806  __388:
 12807  	;
 12808  	*(*int32)(unsafe.Pointer(state + 7148)) += int32(last.Fbits)
 12809  __377:
 12810  	;
 12811  __389:
 12812  	hold >>= int32(here.Fbits)
 12813  	bits = bits - uint32(here.Fbits)
 12814  	goto __390
 12815  __390:
 12816  	if 0 != 0 {
 12817  		goto __389
 12818  	}
 12819  	goto __391
 12820  __391:
 12821  	;
 12822  	*(*int32)(unsafe.Pointer(state + 7148)) += int32(here.Fbits)
 12823  	(*Inflate_state)(unsafe.Pointer(state)).Flength = uint32(here.Fval)
 12824  	if !(int32(here.Fop) == 0) {
 12825  		goto __392
 12826  	}
 12827  
 12828  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = LIT
 12829  	goto __9
 12830  __392:
 12831  	;
 12832  	if !(int32(here.Fop)&32 != 0) {
 12833  		goto __393
 12834  	}
 12835  
 12836  	(*Inflate_state)(unsafe.Pointer(state)).Fback = -1
 12837  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = TYPE
 12838  	goto __9
 12839  __393:
 12840  	;
 12841  	if !(int32(here.Fop)&64 != 0) {
 12842  		goto __394
 12843  	}
 12844  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 589 /* "invalid literal/..." */
 12845  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 12846  	goto __9
 12847  __394:
 12848  	;
 12849  	(*Inflate_state)(unsafe.Pointer(state)).Fextra = uint32(here.Fop) & uint32(15)
 12850  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = LENEXT
 12851  __31:
 12852  	if !((*Inflate_state)(unsafe.Pointer(state)).Fextra != 0) {
 12853  		goto __395
 12854  	}
 12855  __396:
 12856  __399:
 12857  	if !(bits < (*Inflate_state)(unsafe.Pointer(state)).Fextra) {
 12858  		goto __400
 12859  	}
 12860  __401:
 12861  	if !(have == uint32(0)) {
 12862  		goto __404
 12863  	}
 12864  	goto inf_leave
 12865  __404:
 12866  	;
 12867  	have--
 12868  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 12869  	bits = bits + uint32(8)
 12870  	goto __402
 12871  __402:
 12872  	if 0 != 0 {
 12873  		goto __401
 12874  	}
 12875  	goto __403
 12876  __403:
 12877  	;
 12878  	goto __399
 12879  __400:
 12880  	;
 12881  	goto __397
 12882  __397:
 12883  	if 0 != 0 {
 12884  		goto __396
 12885  	}
 12886  	goto __398
 12887  __398:
 12888  	;
 12889  	*(*uint32)(unsafe.Pointer(state + 92)) += uint32(hold) & (uint32(1)<<(*Inflate_state)(unsafe.Pointer(state)).Fextra - uint32(1))
 12890  __405:
 12891  	hold >>= (*Inflate_state)(unsafe.Pointer(state)).Fextra
 12892  	bits = bits - (*Inflate_state)(unsafe.Pointer(state)).Fextra
 12893  	goto __406
 12894  __406:
 12895  	if 0 != 0 {
 12896  		goto __405
 12897  	}
 12898  	goto __407
 12899  __407:
 12900  	;
 12901  	*(*int32)(unsafe.Pointer(state + 7148)) += int32((*Inflate_state)(unsafe.Pointer(state)).Fextra)
 12902  __395:
 12903  	;
 12904  
 12905  	(*Inflate_state)(unsafe.Pointer(state)).Fwas = (*Inflate_state)(unsafe.Pointer(state)).Flength
 12906  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = DIST
 12907  __32:
 12908  __408:
 12909  	here = *(*Code)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fdistcode + uintptr(uint32(hold)&(uint32(1)<<(*Inflate_state)(unsafe.Pointer(state)).Fdistbits-uint32(1)))*4))
 12910  	if !(uint32(here.Fbits) <= bits) {
 12911  		goto __411
 12912  	}
 12913  	goto __410
 12914  __411:
 12915  	;
 12916  __412:
 12917  	if !(have == uint32(0)) {
 12918  		goto __415
 12919  	}
 12920  	goto inf_leave
 12921  __415:
 12922  	;
 12923  	have--
 12924  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 12925  	bits = bits + uint32(8)
 12926  	goto __413
 12927  __413:
 12928  	if 0 != 0 {
 12929  		goto __412
 12930  	}
 12931  	goto __414
 12932  __414:
 12933  	;
 12934  	goto __409
 12935  __409:
 12936  	goto __408
 12937  	goto __410
 12938  __410:
 12939  	;
 12940  	if !(int32(here.Fop)&0xf0 == 0) {
 12941  		goto __416
 12942  	}
 12943  	last = here
 12944  __417:
 12945  	here = *(*Code)(unsafe.Pointer((*Inflate_state)(unsafe.Pointer(state)).Fdistcode + uintptr(uint32(last.Fval)+uint32(hold)&(uint32(1)<<(int32(last.Fbits)+int32(last.Fop))-uint32(1))>>int32(last.Fbits))*4))
 12946  	if !(uint32(int32(last.Fbits)+int32(here.Fbits)) <= bits) {
 12947  		goto __420
 12948  	}
 12949  	goto __419
 12950  __420:
 12951  	;
 12952  __421:
 12953  	if !(have == uint32(0)) {
 12954  		goto __424
 12955  	}
 12956  	goto inf_leave
 12957  __424:
 12958  	;
 12959  	have--
 12960  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 12961  	bits = bits + uint32(8)
 12962  	goto __422
 12963  __422:
 12964  	if 0 != 0 {
 12965  		goto __421
 12966  	}
 12967  	goto __423
 12968  __423:
 12969  	;
 12970  	goto __418
 12971  __418:
 12972  	goto __417
 12973  	goto __419
 12974  __419:
 12975  	;
 12976  __425:
 12977  	hold >>= int32(last.Fbits)
 12978  	bits = bits - uint32(last.Fbits)
 12979  	goto __426
 12980  __426:
 12981  	if 0 != 0 {
 12982  		goto __425
 12983  	}
 12984  	goto __427
 12985  __427:
 12986  	;
 12987  	*(*int32)(unsafe.Pointer(state + 7148)) += int32(last.Fbits)
 12988  __416:
 12989  	;
 12990  __428:
 12991  	hold >>= int32(here.Fbits)
 12992  	bits = bits - uint32(here.Fbits)
 12993  	goto __429
 12994  __429:
 12995  	if 0 != 0 {
 12996  		goto __428
 12997  	}
 12998  	goto __430
 12999  __430:
 13000  	;
 13001  	*(*int32)(unsafe.Pointer(state + 7148)) += int32(here.Fbits)
 13002  	if !(int32(here.Fop)&64 != 0) {
 13003  		goto __431
 13004  	}
 13005  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 617 /* "invalid distance..." */
 13006  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 13007  	goto __9
 13008  __431:
 13009  	;
 13010  	(*Inflate_state)(unsafe.Pointer(state)).Foffset = uint32(here.Fval)
 13011  	(*Inflate_state)(unsafe.Pointer(state)).Fextra = uint32(here.Fop) & uint32(15)
 13012  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = DISTEXT
 13013  __33:
 13014  	if !((*Inflate_state)(unsafe.Pointer(state)).Fextra != 0) {
 13015  		goto __432
 13016  	}
 13017  __433:
 13018  __436:
 13019  	if !(bits < (*Inflate_state)(unsafe.Pointer(state)).Fextra) {
 13020  		goto __437
 13021  	}
 13022  __438:
 13023  	if !(have == uint32(0)) {
 13024  		goto __441
 13025  	}
 13026  	goto inf_leave
 13027  __441:
 13028  	;
 13029  	have--
 13030  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 13031  	bits = bits + uint32(8)
 13032  	goto __439
 13033  __439:
 13034  	if 0 != 0 {
 13035  		goto __438
 13036  	}
 13037  	goto __440
 13038  __440:
 13039  	;
 13040  	goto __436
 13041  __437:
 13042  	;
 13043  	goto __434
 13044  __434:
 13045  	if 0 != 0 {
 13046  		goto __433
 13047  	}
 13048  	goto __435
 13049  __435:
 13050  	;
 13051  	*(*uint32)(unsafe.Pointer(state + 96)) += uint32(hold) & (uint32(1)<<(*Inflate_state)(unsafe.Pointer(state)).Fextra - uint32(1))
 13052  __442:
 13053  	hold >>= (*Inflate_state)(unsafe.Pointer(state)).Fextra
 13054  	bits = bits - (*Inflate_state)(unsafe.Pointer(state)).Fextra
 13055  	goto __443
 13056  __443:
 13057  	if 0 != 0 {
 13058  		goto __442
 13059  	}
 13060  	goto __444
 13061  __444:
 13062  	;
 13063  	*(*int32)(unsafe.Pointer(state + 7148)) += int32((*Inflate_state)(unsafe.Pointer(state)).Fextra)
 13064  __432:
 13065  	;
 13066  
 13067  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = MATCH
 13068  __34:
 13069  	if !(left == uint32(0)) {
 13070  		goto __445
 13071  	}
 13072  	goto inf_leave
 13073  __445:
 13074  	;
 13075  	copy = out - left
 13076  	if !((*Inflate_state)(unsafe.Pointer(state)).Foffset > copy) {
 13077  		goto __446
 13078  	} // copy from window
 13079  	copy = (*Inflate_state)(unsafe.Pointer(state)).Foffset - copy
 13080  	if !(copy > (*Inflate_state)(unsafe.Pointer(state)).Fwhave) {
 13081  		goto __448
 13082  	}
 13083  	if !((*Inflate_state)(unsafe.Pointer(state)).Fsane != 0) {
 13084  		goto __449
 13085  	}
 13086  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 639 /* "invalid distance..." */
 13087  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 13088  	goto __9
 13089  __449:
 13090  	;
 13091  __448:
 13092  	;
 13093  	if !(copy > (*Inflate_state)(unsafe.Pointer(state)).Fwnext) {
 13094  		goto __450
 13095  	}
 13096  	copy = copy - (*Inflate_state)(unsafe.Pointer(state)).Fwnext
 13097  	from = (*Inflate_state)(unsafe.Pointer(state)).Fwindow + uintptr((*Inflate_state)(unsafe.Pointer(state)).Fwsize-copy)
 13098  	goto __451
 13099  __450:
 13100  	from = (*Inflate_state)(unsafe.Pointer(state)).Fwindow + uintptr((*Inflate_state)(unsafe.Pointer(state)).Fwnext-copy)
 13101  __451:
 13102  	;
 13103  	if !(copy > (*Inflate_state)(unsafe.Pointer(state)).Flength) {
 13104  		goto __452
 13105  	}
 13106  	copy = (*Inflate_state)(unsafe.Pointer(state)).Flength
 13107  __452:
 13108  	;
 13109  	goto __447
 13110  __446: // copy from output
 13111  	from = put - uintptr((*Inflate_state)(unsafe.Pointer(state)).Foffset)
 13112  	copy = (*Inflate_state)(unsafe.Pointer(state)).Flength
 13113  __447:
 13114  	;
 13115  	if !(copy > left) {
 13116  		goto __453
 13117  	}
 13118  	copy = left
 13119  __453:
 13120  	;
 13121  	left = left - copy
 13122  	*(*uint32)(unsafe.Pointer(state + 92)) -= copy
 13123  __454:
 13124  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&put, 1))) = *(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&from, 1)))
 13125  	goto __455
 13126  __455:
 13127  	if libc.PreDecUint32(&copy, 1) != 0 {
 13128  		goto __454
 13129  	}
 13130  	goto __456
 13131  __456:
 13132  	;
 13133  	if !((*Inflate_state)(unsafe.Pointer(state)).Flength == uint32(0)) {
 13134  		goto __457
 13135  	}
 13136  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = LEN
 13137  __457:
 13138  	;
 13139  	goto __9
 13140  __35:
 13141  	if !(left == uint32(0)) {
 13142  		goto __458
 13143  	}
 13144  	goto inf_leave
 13145  __458:
 13146  	;
 13147  	*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&put, 1))) = uint8((*Inflate_state)(unsafe.Pointer(state)).Flength)
 13148  	left--
 13149  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = LEN
 13150  	goto __9
 13151  __36:
 13152  	if !((*Inflate_state)(unsafe.Pointer(state)).Fwrap != 0) {
 13153  		goto __459
 13154  	}
 13155  __460:
 13156  __463:
 13157  	if !(bits < uint32(32)) {
 13158  		goto __464
 13159  	}
 13160  __465:
 13161  	if !(have == uint32(0)) {
 13162  		goto __468
 13163  	}
 13164  	goto inf_leave
 13165  __468:
 13166  	;
 13167  	have--
 13168  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 13169  	bits = bits + uint32(8)
 13170  	goto __466
 13171  __466:
 13172  	if 0 != 0 {
 13173  		goto __465
 13174  	}
 13175  	goto __467
 13176  __467:
 13177  	;
 13178  	goto __463
 13179  __464:
 13180  	;
 13181  	goto __461
 13182  __461:
 13183  	if 0 != 0 {
 13184  		goto __460
 13185  	}
 13186  	goto __462
 13187  __462:
 13188  	;
 13189  	out = out - left
 13190  	*(*ULong)(unsafe.Pointer(strm + 40)) += ULong(out)
 13191  	*(*uint64)(unsafe.Pointer(state + 40)) += uint64(out)
 13192  	if !((*Inflate_state)(unsafe.Pointer(state)).Fwrap&4 != 0 && out != 0) {
 13193  		goto __469
 13194  	}
 13195  	(*Z_stream)(unsafe.Pointer(strm)).Fadler = libc.AssignPtrUint64(state+32, func() uint64 {
 13196  		if (*Inflate_state)(unsafe.Pointer(state)).Fflags != 0 {
 13197  			return Xcrc32(tls, (*Inflate_state)(unsafe.Pointer(state)).Fcheck, put-uintptr(out), out)
 13198  		}
 13199  		return Xadler32(tls, (*Inflate_state)(unsafe.Pointer(state)).Fcheck, put-uintptr(out), out)
 13200  	}())
 13201  __469:
 13202  	;
 13203  	out = left
 13204  	if !((*Inflate_state)(unsafe.Pointer(state)).Fwrap&4 != 0 && func() uint64 {
 13205  		if (*Inflate_state)(unsafe.Pointer(state)).Fflags != 0 {
 13206  			return hold
 13207  		}
 13208  		return hold>>24&uint64(0xff) + hold>>8&uint64(0xff00) + hold&uint64(0xff00)<<8 + hold&uint64(0xff)<<24
 13209  	}() != (*Inflate_state)(unsafe.Pointer(state)).Fcheck) {
 13210  		goto __470
 13211  	}
 13212  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 784 /* "incorrect data c..." */
 13213  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 13214  	goto __9
 13215  __470:
 13216  	;
 13217  __471:
 13218  	hold = uint64(0)
 13219  	bits = uint32(0)
 13220  	goto __472
 13221  __472:
 13222  	if 0 != 0 {
 13223  		goto __471
 13224  	}
 13225  	goto __473
 13226  __473:
 13227  	;
 13228  
 13229  __459:
 13230  	;
 13231  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = LENGTH
 13232  __37:
 13233  	if !((*Inflate_state)(unsafe.Pointer(state)).Fwrap != 0 && (*Inflate_state)(unsafe.Pointer(state)).Fflags != 0) {
 13234  		goto __474
 13235  	}
 13236  __475:
 13237  __478:
 13238  	if !(bits < uint32(32)) {
 13239  		goto __479
 13240  	}
 13241  __480:
 13242  	if !(have == uint32(0)) {
 13243  		goto __483
 13244  	}
 13245  	goto inf_leave
 13246  __483:
 13247  	;
 13248  	have--
 13249  	hold = hold + uint64(*(*uint8)(unsafe.Pointer(libc.PostIncUintptr(&next, 1))))<<bits
 13250  	bits = bits + uint32(8)
 13251  	goto __481
 13252  __481:
 13253  	if 0 != 0 {
 13254  		goto __480
 13255  	}
 13256  	goto __482
 13257  __482:
 13258  	;
 13259  	goto __478
 13260  __479:
 13261  	;
 13262  	goto __476
 13263  __476:
 13264  	if 0 != 0 {
 13265  		goto __475
 13266  	}
 13267  	goto __477
 13268  __477:
 13269  	;
 13270  	if !(hold != (*Inflate_state)(unsafe.Pointer(state)).Ftotal&0xffffffff) {
 13271  		goto __484
 13272  	}
 13273  	(*Z_stream)(unsafe.Pointer(strm)).Fmsg = ts + 805 /* "incorrect length..." */
 13274  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = BAD
 13275  	goto __9
 13276  __484:
 13277  	;
 13278  __485:
 13279  	hold = uint64(0)
 13280  	bits = uint32(0)
 13281  	goto __486
 13282  __486:
 13283  	if 0 != 0 {
 13284  		goto __485
 13285  	}
 13286  	goto __487
 13287  __487:
 13288  	;
 13289  
 13290  __474:
 13291  	;
 13292  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = DONE
 13293  __38:
 13294  	ret = Z_STREAM_END
 13295  	goto inf_leave
 13296  __39:
 13297  	ret = -3
 13298  	goto inf_leave
 13299  __40:
 13300  	return -4
 13301  __41:
 13302  __42:
 13303  	return -2
 13304  __9:
 13305  	;
 13306  	goto __7
 13307  __7:
 13308  	goto __6
 13309  	goto __8
 13310  __8:
 13311  	;
 13312  
 13313  	//
 13314  	//        Return from inflate(), updating the total counts and the check value.
 13315  	//        If there was no progress during the inflate() call, return a buffer
 13316  	//        error.  Call updatewindow() to create and/or update the window state.
 13317  	//        Note: a memory error from inflate() is non-recoverable.
 13318  	//
 13319  inf_leave:
 13320  __488:
 13321  	(*Z_stream)(unsafe.Pointer(strm)).Fnext_out = put
 13322  	(*Z_stream)(unsafe.Pointer(strm)).Favail_out = left
 13323  	(*Z_stream)(unsafe.Pointer(strm)).Fnext_in = next
 13324  	(*Z_stream)(unsafe.Pointer(strm)).Favail_in = have
 13325  	(*Inflate_state)(unsafe.Pointer(state)).Fhold = hold
 13326  	(*Inflate_state)(unsafe.Pointer(state)).Fbits = bits
 13327  	goto __489
 13328  __489:
 13329  	if 0 != 0 {
 13330  		goto __488
 13331  	}
 13332  	goto __490
 13333  __490:
 13334  	;
 13335  	if !((*Inflate_state)(unsafe.Pointer(state)).Fwsize != 0 || out != (*Z_stream)(unsafe.Pointer(strm)).Favail_out && (*Inflate_state)(unsafe.Pointer(state)).Fmode < BAD && ((*Inflate_state)(unsafe.Pointer(state)).Fmode < CHECK || flush != Z_FINISH)) {
 13336  		goto __491
 13337  	}
 13338  	if !(updatewindow(tls, strm, (*Z_stream)(unsafe.Pointer(strm)).Fnext_out, out-(*Z_stream)(unsafe.Pointer(strm)).Favail_out) != 0) {
 13339  		goto __492
 13340  	}
 13341  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = MEM
 13342  	return -4
 13343  __492:
 13344  	;
 13345  __491:
 13346  	;
 13347  	in = in - (*Z_stream)(unsafe.Pointer(strm)).Favail_in
 13348  	out = out - (*Z_stream)(unsafe.Pointer(strm)).Favail_out
 13349  	*(*ULong)(unsafe.Pointer(strm + 16)) += ULong(in)
 13350  	*(*ULong)(unsafe.Pointer(strm + 40)) += ULong(out)
 13351  	*(*uint64)(unsafe.Pointer(state + 40)) += uint64(out)
 13352  	if !((*Inflate_state)(unsafe.Pointer(state)).Fwrap&4 != 0 && out != 0) {
 13353  		goto __493
 13354  	}
 13355  	(*Z_stream)(unsafe.Pointer(strm)).Fadler = libc.AssignPtrUint64(state+32, func() uint64 {
 13356  		if (*Inflate_state)(unsafe.Pointer(state)).Fflags != 0 {
 13357  			return Xcrc32(tls, (*Inflate_state)(unsafe.Pointer(state)).Fcheck, (*Z_stream)(unsafe.Pointer(strm)).Fnext_out-uintptr(out), out)
 13358  		}
 13359  		return Xadler32(tls, (*Inflate_state)(unsafe.Pointer(state)).Fcheck, (*Z_stream)(unsafe.Pointer(strm)).Fnext_out-uintptr(out), out)
 13360  	}())
 13361  __493:
 13362  	;
 13363  	(*Z_stream)(unsafe.Pointer(strm)).Fdata_type = int32((*Inflate_state)(unsafe.Pointer(state)).Fbits) + func() int32 {
 13364  		if (*Inflate_state)(unsafe.Pointer(state)).Flast != 0 {
 13365  			return 64
 13366  		}
 13367  		return 0
 13368  	}() + func() int32 {
 13369  		if (*Inflate_state)(unsafe.Pointer(state)).Fmode == TYPE {
 13370  			return 128
 13371  		}
 13372  		return 0
 13373  	}() + func() int32 {
 13374  		if (*Inflate_state)(unsafe.Pointer(state)).Fmode == LEN_ || (*Inflate_state)(unsafe.Pointer(state)).Fmode == COPY_ {
 13375  			return 256
 13376  		}
 13377  		return 0
 13378  	}()
 13379  	if !((in == uint32(0) && out == uint32(0) || flush == Z_FINISH) && ret == Z_OK) {
 13380  		goto __494
 13381  	}
 13382  	ret = -5
 13383  __494:
 13384  	;
 13385  	return ret
 13386  }
 13387  
 13388  var order1 =                                                                                                                                                                                                                         // permutation of code lengths
 13389  [19]uint16{uint16(16), uint16(17), uint16(18), uint16(0), uint16(8), uint16(7), uint16(9), uint16(6), uint16(10), uint16(5), uint16(11), uint16(4), uint16(12), uint16(3), uint16(13), uint16(2), uint16(14), uint16(1), uint16(15)} /* inflate.c:642:33 */
 13390  
 13391  func XinflateEnd(tls *libc.TLS, strm Z_streamp) int32 { /* inflate.c:1277:13: */
 13392  	var state uintptr
 13393  	if inflateStateCheck(tls, strm) != 0 {
 13394  		return -2
 13395  	}
 13396  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 13397  	if (*Inflate_state)(unsafe.Pointer(state)).Fwindow != uintptr(Z_NULL) {
 13398  		(*struct {
 13399  			f func(*libc.TLS, Voidpf, Voidpf)
 13400  		})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzfree})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, (*Inflate_state)(unsafe.Pointer(state)).Fwindow)
 13401  	}
 13402  	(*struct {
 13403  		f func(*libc.TLS, Voidpf, Voidpf)
 13404  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(strm)).Fzfree})).f(tls, (*Z_stream)(unsafe.Pointer(strm)).Fopaque, (*Z_stream)(unsafe.Pointer(strm)).Fstate)
 13405  	(*Z_stream)(unsafe.Pointer(strm)).Fstate = uintptr(Z_NULL)
 13406  
 13407  	return Z_OK
 13408  }
 13409  
 13410  func XinflateGetDictionary(tls *libc.TLS, strm Z_streamp, dictionary uintptr, dictLength uintptr) int32 { /* inflate.c:1291:13: */
 13411  	var state uintptr
 13412  
 13413  	// check state
 13414  	if inflateStateCheck(tls, strm) != 0 {
 13415  		return -2
 13416  	}
 13417  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 13418  
 13419  	// copy dictionary
 13420  	if (*Inflate_state)(unsafe.Pointer(state)).Fwhave != 0 && dictionary != uintptr(Z_NULL) {
 13421  		libc.Xmemcpy(tls, dictionary, (*Inflate_state)(unsafe.Pointer(state)).Fwindow+uintptr((*Inflate_state)(unsafe.Pointer(state)).Fwnext),
 13422  			uint64((*Inflate_state)(unsafe.Pointer(state)).Fwhave-(*Inflate_state)(unsafe.Pointer(state)).Fwnext))
 13423  		libc.Xmemcpy(tls, dictionary+uintptr((*Inflate_state)(unsafe.Pointer(state)).Fwhave)-uintptr((*Inflate_state)(unsafe.Pointer(state)).Fwnext),
 13424  			(*Inflate_state)(unsafe.Pointer(state)).Fwindow, uint64((*Inflate_state)(unsafe.Pointer(state)).Fwnext))
 13425  	}
 13426  	if dictLength != uintptr(Z_NULL) {
 13427  		*(*UInt)(unsafe.Pointer(dictLength)) = (*Inflate_state)(unsafe.Pointer(state)).Fwhave
 13428  	}
 13429  	return Z_OK
 13430  }
 13431  
 13432  func XinflateSetDictionary(tls *libc.TLS, strm Z_streamp, dictionary uintptr, dictLength UInt) int32 { /* inflate.c:1314:13: */
 13433  	var state uintptr
 13434  	var dictid uint64
 13435  	var ret int32
 13436  
 13437  	// check state
 13438  	if inflateStateCheck(tls, strm) != 0 {
 13439  		return -2
 13440  	}
 13441  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 13442  	if (*Inflate_state)(unsafe.Pointer(state)).Fwrap != 0 && (*Inflate_state)(unsafe.Pointer(state)).Fmode != DICT {
 13443  		return -2
 13444  	}
 13445  
 13446  	// check for correct dictionary identifier
 13447  	if (*Inflate_state)(unsafe.Pointer(state)).Fmode == DICT {
 13448  		dictid = Xadler32(tls, uint64(0), uintptr(Z_NULL), uint32(0))
 13449  		dictid = Xadler32(tls, dictid, dictionary, dictLength)
 13450  		if dictid != (*Inflate_state)(unsafe.Pointer(state)).Fcheck {
 13451  			return -3
 13452  		}
 13453  	}
 13454  
 13455  	// copy dictionary to window using updatewindow(), which will amend the
 13456  	//        existing dictionary if appropriate
 13457  	ret = updatewindow(tls, strm, dictionary+uintptr(dictLength), dictLength)
 13458  	if ret != 0 {
 13459  		(*Inflate_state)(unsafe.Pointer(state)).Fmode = MEM
 13460  		return -4
 13461  	}
 13462  	(*Inflate_state)(unsafe.Pointer(state)).Fhavedict = 1
 13463  
 13464  	return Z_OK
 13465  }
 13466  
 13467  func XinflateGetHeader(tls *libc.TLS, strm Z_streamp, head Gz_headerp) int32 { /* inflate.c:1349:13: */
 13468  	var state uintptr
 13469  
 13470  	// check state
 13471  	if inflateStateCheck(tls, strm) != 0 {
 13472  		return -2
 13473  	}
 13474  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 13475  	if (*Inflate_state)(unsafe.Pointer(state)).Fwrap&2 == 0 {
 13476  		return -2
 13477  	}
 13478  
 13479  	// save header structure
 13480  	(*Inflate_state)(unsafe.Pointer(state)).Fhead = head
 13481  	(*Gz_header)(unsafe.Pointer(head)).Fdone = 0
 13482  	return Z_OK
 13483  }
 13484  
 13485  //
 13486  //    Search buf[0..len-1] for the pattern: 0, 0, 0xff, 0xff.  Return when found
 13487  //    or when out of input.  When called, *have is the number of pattern bytes
 13488  //    found in order so far, in 0..3.  On return *have is updated to the new
 13489  //    state.  If on return *have equals four, then the pattern was found and the
 13490  //    return value is how many bytes were read including the last byte of the
 13491  //    pattern.  If *have is less than four, then the pattern has not been found
 13492  //    yet and the return value is len.  In the latter case, syncsearch() can be
 13493  //    called again with more data and the *have state.  *have is initialized to
 13494  //    zero for the first call.
 13495  //
 13496  func syncsearch(tls *libc.TLS, have uintptr, buf uintptr, len uint32) uint32 { /* inflate.c:1377:16: */
 13497  	var got uint32
 13498  	var next uint32
 13499  
 13500  	got = *(*uint32)(unsafe.Pointer(have))
 13501  	next = uint32(0)
 13502  	for next < len && got < uint32(4) {
 13503  		if int32(*(*uint8)(unsafe.Pointer(buf + uintptr(next)))) == func() int32 {
 13504  			if got < uint32(2) {
 13505  				return 0
 13506  			}
 13507  			return 0xff
 13508  		}() {
 13509  			got++
 13510  		} else if *(*uint8)(unsafe.Pointer(buf + uintptr(next))) != 0 {
 13511  			got = uint32(0)
 13512  		} else {
 13513  			got = uint32(4) - got
 13514  		}
 13515  		next++
 13516  	}
 13517  	*(*uint32)(unsafe.Pointer(have)) = got
 13518  	return next
 13519  }
 13520  
 13521  func XinflateSync(tls *libc.TLS, strm Z_streamp) int32 { /* inflate.c:1400:13: */
 13522  	bp := tls.Alloc(4)
 13523  	defer tls.Free(4)
 13524  
 13525  	var len uint32 // number of bytes to look at or looked at
 13526  	var in uint64
 13527  	var out uint64 // temporary to save total_in and total_out
 13528  	// var buf [4]uint8 at bp, 4
 13529  	// to restore bit buffer to byte string
 13530  	var state uintptr
 13531  
 13532  	// check parameters
 13533  	if inflateStateCheck(tls, strm) != 0 {
 13534  		return -2
 13535  	}
 13536  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 13537  	if (*Z_stream)(unsafe.Pointer(strm)).Favail_in == UInt(0) && (*Inflate_state)(unsafe.Pointer(state)).Fbits < uint32(8) {
 13538  		return -5
 13539  	}
 13540  
 13541  	// if first time, start search in bit buffer
 13542  	if (*Inflate_state)(unsafe.Pointer(state)).Fmode != SYNC {
 13543  		(*Inflate_state)(unsafe.Pointer(state)).Fmode = SYNC
 13544  		libc.AssignShlPtrUint64(state+80, int((*Inflate_state)(unsafe.Pointer(state)).Fbits&uint32(7)))
 13545  		*(*uint32)(unsafe.Pointer(state + 88)) -= (*Inflate_state)(unsafe.Pointer(state)).Fbits & uint32(7)
 13546  		len = uint32(0)
 13547  		for (*Inflate_state)(unsafe.Pointer(state)).Fbits >= uint32(8) {
 13548  			*(*uint8)(unsafe.Pointer(bp + uintptr(libc.PostIncUint32(&len, 1)))) = uint8((*Inflate_state)(unsafe.Pointer(state)).Fhold)
 13549  			libc.AssignShrPtrUint64(state+80, int(8))
 13550  			*(*uint32)(unsafe.Pointer(state + 88)) -= uint32(8)
 13551  		}
 13552  		(*Inflate_state)(unsafe.Pointer(state)).Fhave = uint32(0)
 13553  		syncsearch(tls, state+140, bp, len)
 13554  	}
 13555  
 13556  	// search available input
 13557  	len = syncsearch(tls, state+140, (*Z_stream)(unsafe.Pointer(strm)).Fnext_in, (*Z_stream)(unsafe.Pointer(strm)).Favail_in)
 13558  	*(*UInt)(unsafe.Pointer(strm + 8)) -= len
 13559  	*(*uintptr)(unsafe.Pointer(strm)) += uintptr(len)
 13560  	*(*ULong)(unsafe.Pointer(strm + 16)) += ULong(len)
 13561  
 13562  	// return no joy or set up to restart inflate() on a new block
 13563  	if (*Inflate_state)(unsafe.Pointer(state)).Fhave != uint32(4) {
 13564  		return -3
 13565  	}
 13566  	in = (*Z_stream)(unsafe.Pointer(strm)).Ftotal_in
 13567  	out = (*Z_stream)(unsafe.Pointer(strm)).Ftotal_out
 13568  	XinflateReset(tls, strm)
 13569  	(*Z_stream)(unsafe.Pointer(strm)).Ftotal_in = in
 13570  	(*Z_stream)(unsafe.Pointer(strm)).Ftotal_out = out
 13571  	(*Inflate_state)(unsafe.Pointer(state)).Fmode = TYPE
 13572  	return Z_OK
 13573  }
 13574  
 13575  //
 13576  //    Returns true if inflate is currently at the end of a block generated by
 13577  //    Z_SYNC_FLUSH or Z_FULL_FLUSH. This function is used by one PPP
 13578  //    implementation to provide an additional safety check. PPP uses
 13579  //    Z_SYNC_FLUSH but removes the length bytes of the resulting empty stored
 13580  //    block. When decompressing, PPP checks that at the end of input packet,
 13581  //    inflate is waiting for these length bytes.
 13582  //
 13583  func XinflateSyncPoint(tls *libc.TLS, strm Z_streamp) int32 { /* inflate.c:1451:13: */
 13584  	var state uintptr
 13585  
 13586  	if inflateStateCheck(tls, strm) != 0 {
 13587  		return -2
 13588  	}
 13589  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 13590  	return libc.Bool32((*Inflate_state)(unsafe.Pointer(state)).Fmode == STORED && (*Inflate_state)(unsafe.Pointer(state)).Fbits == uint32(0))
 13591  }
 13592  
 13593  func XinflateCopy(tls *libc.TLS, dest Z_streamp, source Z_streamp) int32 { /* inflate.c:1461:13: */
 13594  	var state uintptr
 13595  	var copy uintptr
 13596  	var window uintptr
 13597  	var wsize uint32
 13598  
 13599  	// check input
 13600  	if inflateStateCheck(tls, source) != 0 || dest == uintptr(Z_NULL) {
 13601  		return -2
 13602  	}
 13603  	state = (*Z_stream)(unsafe.Pointer(source)).Fstate
 13604  
 13605  	// allocate space
 13606  	copy = (*struct {
 13607  		f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
 13608  	})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(source)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(source)).Fopaque, uint32(1), uint32(unsafe.Sizeof(Inflate_state{})))
 13609  	if copy == uintptr(Z_NULL) {
 13610  		return -4
 13611  	}
 13612  	window = uintptr(Z_NULL)
 13613  	if (*Inflate_state)(unsafe.Pointer(state)).Fwindow != uintptr(Z_NULL) {
 13614  		window = (*struct {
 13615  			f func(*libc.TLS, Voidpf, UInt, UInt) Voidpf
 13616  		})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(source)).Fzalloc})).f(tls, (*Z_stream)(unsafe.Pointer(source)).Fopaque, uint32(1)<<(*Inflate_state)(unsafe.Pointer(state)).Fwbits, uint32(unsafe.Sizeof(uint8(0))))
 13617  		if window == uintptr(Z_NULL) {
 13618  			(*struct {
 13619  				f func(*libc.TLS, Voidpf, Voidpf)
 13620  			})(unsafe.Pointer(&struct{ uintptr }{(*Z_stream)(unsafe.Pointer(source)).Fzfree})).f(tls, (*Z_stream)(unsafe.Pointer(source)).Fopaque, copy)
 13621  			return -4
 13622  		}
 13623  	}
 13624  
 13625  	// copy state
 13626  	libc.Xmemcpy(tls, dest, source, uint64(unsafe.Sizeof(Z_stream{})))
 13627  	libc.Xmemcpy(tls, copy, state, uint64(unsafe.Sizeof(Inflate_state{})))
 13628  	(*Inflate_state)(unsafe.Pointer(copy)).Fstrm = dest
 13629  	if (*Inflate_state)(unsafe.Pointer(state)).Flencode >= state+1368 && (*Inflate_state)(unsafe.Pointer(state)).Flencode <= state+1368+uintptr(ENOUGH_LENS+ENOUGH_DISTS)*4-uintptr(1)*4 {
 13630  		(*Inflate_state)(unsafe.Pointer(copy)).Flencode = copy + 1368 + uintptr(int64(((*Inflate_state)(unsafe.Pointer(state)).Flencode-(state+1368))/4))*4
 13631  		(*Inflate_state)(unsafe.Pointer(copy)).Fdistcode = copy + 1368 + uintptr(int64(((*Inflate_state)(unsafe.Pointer(state)).Fdistcode-(state+1368))/4))*4
 13632  	}
 13633  	(*Inflate_state)(unsafe.Pointer(copy)).Fnext = copy + 1368 + uintptr(int64(((*Inflate_state)(unsafe.Pointer(state)).Fnext-(state+1368))/4))*4
 13634  	if window != uintptr(Z_NULL) {
 13635  		wsize = uint32(1) << (*Inflate_state)(unsafe.Pointer(state)).Fwbits
 13636  		libc.Xmemcpy(tls, window, (*Inflate_state)(unsafe.Pointer(state)).Fwindow, uint64(wsize))
 13637  	}
 13638  	(*Inflate_state)(unsafe.Pointer(copy)).Fwindow = window
 13639  	(*Z_stream)(unsafe.Pointer(dest)).Fstate = copy
 13640  	return Z_OK
 13641  }
 13642  
 13643  func XinflateUndermine(tls *libc.TLS, strm Z_streamp, subvert int32) int32 { /* inflate.c:1508:13: */
 13644  	var state uintptr
 13645  
 13646  	if inflateStateCheck(tls, strm) != 0 {
 13647  		return -2
 13648  	}
 13649  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 13650  	_ = subvert
 13651  	(*Inflate_state)(unsafe.Pointer(state)).Fsane = 1
 13652  	return -3
 13653  }
 13654  
 13655  func XinflateValidate(tls *libc.TLS, strm Z_streamp, check int32) int32 { /* inflate.c:1526:13: */
 13656  	var state uintptr
 13657  
 13658  	if inflateStateCheck(tls, strm) != 0 {
 13659  		return -2
 13660  	}
 13661  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 13662  	if check != 0 {
 13663  		*(*int32)(unsafe.Pointer(state + 16)) |= 4
 13664  	} else {
 13665  		*(*int32)(unsafe.Pointer(state + 16)) &= libc.CplInt32(4)
 13666  	}
 13667  	return Z_OK
 13668  }
 13669  
 13670  func XinflateMark(tls *libc.TLS, strm Z_streamp) int64 { /* inflate.c:1541:14: */
 13671  	var state uintptr
 13672  
 13673  	if inflateStateCheck(tls, strm) != 0 {
 13674  		return -(int64(1) << 16)
 13675  	}
 13676  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 13677  	return int64(uint64(int64((*Inflate_state)(unsafe.Pointer(state)).Fback))<<16) + func() int64 {
 13678  		if (*Inflate_state)(unsafe.Pointer(state)).Fmode == COPY {
 13679  			return int64((*Inflate_state)(unsafe.Pointer(state)).Flength)
 13680  		}
 13681  		return func() int64 {
 13682  			if (*Inflate_state)(unsafe.Pointer(state)).Fmode == MATCH {
 13683  				return int64((*Inflate_state)(unsafe.Pointer(state)).Fwas - (*Inflate_state)(unsafe.Pointer(state)).Flength)
 13684  			}
 13685  			return int64(0)
 13686  		}()
 13687  	}()
 13688  }
 13689  
 13690  func XinflateCodesUsed(tls *libc.TLS, strm Z_streamp) uint64 { /* inflate.c:1554:23: */
 13691  	var state uintptr
 13692  	if inflateStateCheck(tls, strm) != 0 {
 13693  		return libc.Uint64(libc.Uint64FromInt32(-1))
 13694  	}
 13695  	state = (*Z_stream)(unsafe.Pointer(strm)).Fstate
 13696  	return uint64(int64(((*Inflate_state)(unsafe.Pointer(state)).Fnext - (state + 1368)) / 4))
 13697  }
 13698  
 13699  var Xinflate_copyright = *(*[48]int8)(unsafe.Pointer(ts + 828)) /* inftrees.c:11:12 */
 13700  
 13701  //
 13702  //   If you use the zlib library in a product, an acknowledgment is welcome
 13703  //   in the documentation of your product. If for some reason you cannot
 13704  //   include such an acknowledgment, I would appreciate that you keep this
 13705  //   copyright string in the executable of your product.
 13706  //
 13707  
 13708  //
 13709  //    Build a set of tables to decode the provided canonical Huffman code.
 13710  //    The code lengths are lens[0..codes-1].  The result starts at *table,
 13711  //    whose indices are 0..2^bits-1.  work is a writable array of at least
 13712  //    lens shorts, which is used as a work area.  type is the type of code
 13713  //    to be generated, CODES, LENS, or DISTS.  On return, zero is success,
 13714  //    -1 is an invalid code, and +1 means that ENOUGH isn't enough.  table
 13715  //    on return points to the next available entry's address.  bits is the
 13716  //    requested root table index bits, and on return it is the actual root
 13717  //    table index bits.  It will differ if the request is greater than the
 13718  //    longest code or if it is less than the shortest code.
 13719  //
 13720  func Xinflate_table(tls *libc.TLS, type1 Codetype, lens uintptr, codes uint32, table uintptr, bits uintptr, work uintptr) int32 { /* inftrees.c:32:19: */
 13721  	bp := tls.Alloc(64)
 13722  	defer tls.Free(64)
 13723  
 13724  	var len uint32 // a code's length in bits
 13725  	var sym uint32 // index of code symbols
 13726  	var min uint32
 13727  	var max uint32    // minimum and maximum code lengths
 13728  	var root uint32   // number of index bits for root table
 13729  	var curr uint32   // number of index bits for current table
 13730  	var drop uint32   // code bits to drop for sub-table
 13731  	var left int32    // number of prefix codes available
 13732  	var used uint32   // code entries in table used
 13733  	var huff uint32   // Huffman code
 13734  	var incr uint32   // for incrementing code, index
 13735  	var fill uint32   // index for replicating entries
 13736  	var low uint32    // low bits for current root entry
 13737  	var mask uint32   // mask for low root bits
 13738  	var here Code     // table entry for duplication
 13739  	var next uintptr  // next available space in table
 13740  	var base uintptr  // base value table to use
 13741  	var extra uintptr // extra bits table to use
 13742  	var match uint32  // use base and extra for symbol >= match
 13743  	// var count [16]uint16 at bp, 32
 13744  	// number of codes of each length
 13745  	// var offs [16]uint16 at bp+32, 32
 13746  
 13747  	//
 13748  	//        Process a set of code lengths to create a canonical Huffman code.  The
 13749  	//        code lengths are lens[0..codes-1].  Each length corresponds to the
 13750  	//        symbols 0..codes-1.  The Huffman code is generated by first sorting the
 13751  	//        symbols by length from short to long, and retaining the symbol order
 13752  	//        for codes with equal lengths.  Then the code starts with all zero bits
 13753  	//        for the first code of the shortest length, and the codes are integer
 13754  	//        increments for the same length, and zeros are appended as the length
 13755  	//        increases.  For the deflate format, these bits are stored backwards
 13756  	//        from their more natural integer increment ordering, and so when the
 13757  	//        decoding tables are built in the large loop below, the integer codes
 13758  	//        are incremented backwards.
 13759  	//
 13760  	//        This routine assumes, but does not check, that all of the entries in
 13761  	//        lens[] are in the range 0..MAXBITS.  The caller must assure this.
 13762  	//        1..MAXBITS is interpreted as that code length.  zero means that that
 13763  	//        symbol does not occur in this code.
 13764  	//
 13765  	//        The codes are sorted by computing a count of codes for each length,
 13766  	//        creating from that a table of starting indices for each length in the
 13767  	//        sorted table, and then entering the symbols in order in the sorted
 13768  	//        table.  The sorted table is work[], with that space being provided by
 13769  	//        the caller.
 13770  	//
 13771  	//        The length counts are used for other purposes as well, i.e. finding
 13772  	//        the minimum and maximum length codes, determining if there are any
 13773  	//        codes at all, checking for a valid set of lengths, and looking ahead
 13774  	//        at length counts to determine sub-table sizes when building the
 13775  	//        decoding tables.
 13776  	//
 13777  
 13778  	// accumulate lengths for codes (assumes lens[] all in 0..MAXBITS)
 13779  	for len = uint32(0); len <= uint32(MAXBITS); len++ {
 13780  		*(*uint16)(unsafe.Pointer(bp + uintptr(len)*2)) = uint16(0)
 13781  	}
 13782  	for sym = uint32(0); sym < codes; sym++ {
 13783  		*(*uint16)(unsafe.Pointer(bp + uintptr(*(*uint16)(unsafe.Pointer(lens + uintptr(sym)*2)))*2))++
 13784  	}
 13785  
 13786  	// bound code lengths, force root to be within code lengths
 13787  	root = *(*uint32)(unsafe.Pointer(bits))
 13788  	for max = uint32(MAXBITS); max >= uint32(1); max-- {
 13789  		if int32(*(*uint16)(unsafe.Pointer(bp + uintptr(max)*2))) != 0 {
 13790  			break
 13791  		}
 13792  	}
 13793  	if root > max {
 13794  		root = max
 13795  	}
 13796  	if max == uint32(0) { // no symbols to code at all
 13797  		here.Fop = uint8(64) // invalid code marker
 13798  		here.Fbits = uint8(1)
 13799  		here.Fval = uint16(0)
 13800  		*(*Code)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(table)), 4))) = here // make a table to force an error
 13801  		*(*Code)(unsafe.Pointer(libc.PostIncUintptr(&*(*uintptr)(unsafe.Pointer(table)), 4))) = here
 13802  		*(*uint32)(unsafe.Pointer(bits)) = uint32(1)
 13803  		return 0 // no symbols, but wait for decoding to report error
 13804  	}
 13805  	for min = uint32(1); min < max; min++ {
 13806  		if int32(*(*uint16)(unsafe.Pointer(bp + uintptr(min)*2))) != 0 {
 13807  			break
 13808  		}
 13809  	}
 13810  	if root < min {
 13811  		root = min
 13812  	}
 13813  
 13814  	// check for an over-subscribed or incomplete set of lengths
 13815  	left = 1
 13816  	for len = uint32(1); len <= uint32(MAXBITS); len++ {
 13817  		left <<= 1
 13818  		left = left - int32(*(*uint16)(unsafe.Pointer(bp + uintptr(len)*2)))
 13819  		if left < 0 {
 13820  			return -1
 13821  		} // over-subscribed
 13822  	}
 13823  	if left > 0 && (type1 == CODES || max != uint32(1)) {
 13824  		return -1
 13825  	} // incomplete set
 13826  
 13827  	// generate offsets into symbol table for each length for sorting
 13828  	*(*uint16)(unsafe.Pointer(bp + 32 + 1*2)) = uint16(0)
 13829  	for len = uint32(1); len < uint32(MAXBITS); len++ {
 13830  		*(*uint16)(unsafe.Pointer(bp + 32 + uintptr(len+uint32(1))*2)) = uint16(int32(*(*uint16)(unsafe.Pointer(bp + 32 + uintptr(len)*2))) + int32(*(*uint16)(unsafe.Pointer(bp + uintptr(len)*2))))
 13831  	}
 13832  
 13833  	// sort symbols by length, by symbol order within each length
 13834  	for sym = uint32(0); sym < codes; sym++ {
 13835  		if int32(*(*uint16)(unsafe.Pointer(lens + uintptr(sym)*2))) != 0 {
 13836  			*(*uint16)(unsafe.Pointer(work + uintptr(libc.PostIncUint16(&*(*uint16)(unsafe.Pointer(bp + 32 + uintptr(*(*uint16)(unsafe.Pointer(lens + uintptr(sym)*2)))*2)), 1))*2)) = uint16(sym)
 13837  		}
 13838  	}
 13839  
 13840  	//
 13841  	//        Create and fill in decoding tables.  In this loop, the table being
 13842  	//        filled is at next and has curr index bits.  The code being used is huff
 13843  	//        with length len.  That code is converted to an index by dropping drop
 13844  	//        bits off of the bottom.  For codes where len is less than drop + curr,
 13845  	//        those top drop + curr - len bits are incremented through all values to
 13846  	//        fill the table with replicated entries.
 13847  	//
 13848  	//        root is the number of index bits for the root table.  When len exceeds
 13849  	//        root, sub-tables are created pointed to by the root entry with an index
 13850  	//        of the low root bits of huff.  This is saved in low to check for when a
 13851  	//        new sub-table should be started.  drop is zero when the root table is
 13852  	//        being filled, and drop is root when sub-tables are being filled.
 13853  	//
 13854  	//        When a new sub-table is needed, it is necessary to look ahead in the
 13855  	//        code lengths to determine what size sub-table is needed.  The length
 13856  	//        counts are used for this, and so count[] is decremented as codes are
 13857  	//        entered in the tables.
 13858  	//
 13859  	//        used keeps track of how many table entries have been allocated from the
 13860  	//        provided *table space.  It is checked for LENS and DIST tables against
 13861  	//        the constants ENOUGH_LENS and ENOUGH_DISTS to guard against changes in
 13862  	//        the initial root table size constants.  See the comments in inftrees.h
 13863  	//        for more information.
 13864  	//
 13865  	//        sym increments through all symbols, and the loop terminates when
 13866  	//        all codes of length max, i.e. all codes, have been processed.  This
 13867  	//        routine permits incomplete codes, so another loop after this one fills
 13868  	//        in the rest of the decoding tables with invalid code markers.
 13869  	//
 13870  
 13871  	// set up for code type
 13872  	switch type1 {
 13873  	case CODES:
 13874  		base = libc.AssignUintptr(&extra, work) // dummy value--not used
 13875  		match = uint32(20)
 13876  		break
 13877  	case LENS:
 13878  		base = uintptr(unsafe.Pointer(&lbase))
 13879  		extra = uintptr(unsafe.Pointer(&lext))
 13880  		match = uint32(257)
 13881  		break
 13882  	default: // DISTS
 13883  		base = uintptr(unsafe.Pointer(&dbase))
 13884  		extra = uintptr(unsafe.Pointer(&dext))
 13885  		match = uint32(0)
 13886  	}
 13887  
 13888  	// initialize state for loop
 13889  	huff = uint32(0)                            // starting code
 13890  	sym = uint32(0)                             // starting code symbol
 13891  	len = min                                   // starting code length
 13892  	next = *(*uintptr)(unsafe.Pointer(table))   // current table to fill in
 13893  	curr = root                                 // current table index bits
 13894  	drop = uint32(0)                            // current bits to drop from code for index
 13895  	low = libc.Uint32(libc.Uint32FromInt32(-1)) // trigger new sub-table when len > root
 13896  	used = uint32(1) << root                    // use root table entries
 13897  	mask = used - uint32(1)                     // mask for comparing low
 13898  
 13899  	// check available table space
 13900  	if type1 == LENS && used > uint32(ENOUGH_LENS) || type1 == DISTS && used > uint32(ENOUGH_DISTS) {
 13901  		return 1
 13902  	}
 13903  
 13904  	// process all codes and make table entries
 13905  	for {
 13906  		// create table entry
 13907  		here.Fbits = uint8(len - drop)
 13908  		if uint32(*(*uint16)(unsafe.Pointer(work + uintptr(sym)*2)))+1 < match {
 13909  			here.Fop = uint8(0)
 13910  			here.Fval = *(*uint16)(unsafe.Pointer(work + uintptr(sym)*2))
 13911  		} else if uint32(*(*uint16)(unsafe.Pointer(work + uintptr(sym)*2))) >= match {
 13912  			here.Fop = uint8(*(*uint16)(unsafe.Pointer(extra + uintptr(uint32(*(*uint16)(unsafe.Pointer(work + uintptr(sym)*2)))-match)*2)))
 13913  			here.Fval = *(*uint16)(unsafe.Pointer(base + uintptr(uint32(*(*uint16)(unsafe.Pointer(work + uintptr(sym)*2)))-match)*2))
 13914  		} else {
 13915  			here.Fop = uint8(32 + 64) // end of block
 13916  			here.Fval = uint16(0)
 13917  		}
 13918  
 13919  		// replicate for those indices with low len bits equal to huff
 13920  		incr = uint32(1) << (len - drop)
 13921  		fill = uint32(1) << curr
 13922  		min = fill // save offset to next table
 13923  		for ok := true; ok; ok = fill != uint32(0) {
 13924  			fill = fill - incr
 13925  			*(*Code)(unsafe.Pointer(next + uintptr(huff>>drop+fill)*4)) = here
 13926  		}
 13927  
 13928  		// backwards increment the len-bit code huff
 13929  		incr = uint32(1) << (len - uint32(1))
 13930  		for huff&incr != 0 {
 13931  			incr >>= 1
 13932  		}
 13933  		if incr != uint32(0) {
 13934  			huff = huff & (incr - uint32(1))
 13935  			huff = huff + incr
 13936  		} else {
 13937  			huff = uint32(0)
 13938  		}
 13939  
 13940  		// go to next symbol, update count, len
 13941  		sym++
 13942  		if int32(libc.PreDecUint16(&*(*uint16)(unsafe.Pointer(bp + uintptr(len)*2)), 1)) == 0 {
 13943  			if len == max {
 13944  				break
 13945  			}
 13946  			len = uint32(*(*uint16)(unsafe.Pointer(lens + uintptr(*(*uint16)(unsafe.Pointer(work + uintptr(sym)*2)))*2)))
 13947  		}
 13948  
 13949  		// create new sub-table if needed
 13950  		if len > root && huff&mask != low {
 13951  			// if first time, transition to sub-tables
 13952  			if drop == uint32(0) {
 13953  				drop = root
 13954  			}
 13955  
 13956  			// increment past last table
 13957  			next += 4 * uintptr(min) // here min is 1 << curr
 13958  
 13959  			// determine length of next table
 13960  			curr = len - drop
 13961  			left = int32(1) << curr
 13962  			for curr+drop < max {
 13963  				left = left - int32(*(*uint16)(unsafe.Pointer(bp + uintptr(curr+drop)*2)))
 13964  				if left <= 0 {
 13965  					break
 13966  				}
 13967  				curr++
 13968  				left <<= 1
 13969  			}
 13970  
 13971  			// check for enough space
 13972  			used = used + uint32(1)<<curr
 13973  			if type1 == LENS && used > uint32(ENOUGH_LENS) || type1 == DISTS && used > uint32(ENOUGH_DISTS) {
 13974  				return 1
 13975  			}
 13976  
 13977  			// point entry in root table to sub-table
 13978  			low = huff & mask
 13979  			(*Code)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(table)) + uintptr(low)*4)).Fop = uint8(curr)
 13980  			(*Code)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(table)) + uintptr(low)*4)).Fbits = uint8(root)
 13981  			(*Code)(unsafe.Pointer(*(*uintptr)(unsafe.Pointer(table)) + uintptr(low)*4)).Fval = uint16((int64(next) - int64(*(*uintptr)(unsafe.Pointer(table)))) / 4)
 13982  		}
 13983  	}
 13984  
 13985  	// fill in remaining table entry if code is incomplete (guaranteed to have
 13986  	//        at most one remaining entry, since if the code is incomplete, the
 13987  	//        maximum code length that was allowed to get this far is one bit)
 13988  	if huff != uint32(0) {
 13989  		here.Fop = uint8(64) // invalid code marker
 13990  		here.Fbits = uint8(len - drop)
 13991  		here.Fval = uint16(0)
 13992  		*(*Code)(unsafe.Pointer(next + uintptr(huff)*4)) = here
 13993  	}
 13994  
 13995  	// set return parameters
 13996  	*(*uintptr)(unsafe.Pointer(table)) += uintptr(used) * 4
 13997  	*(*uint32)(unsafe.Pointer(bits)) = root
 13998  	return 0
 13999  }
 14000  
 14001  var lbase = [31]uint16{ // Length codes 257..285 base
 14002  	uint16(3), uint16(4), uint16(5), uint16(6), uint16(7), uint16(8), uint16(9), uint16(10), uint16(11), uint16(13), uint16(15), uint16(17), uint16(19), uint16(23), uint16(27), uint16(31),
 14003  			uint16(35), uint16(43), uint16(51), uint16(59), uint16(67), uint16(83), uint16(99), uint16(115), uint16(131), uint16(163), uint16(195), uint16(227), uint16(258), uint16(0), uint16(0)} /* inftrees.c:60:33 */
 14004  var lext = [31]uint16{ // Length codes 257..285 extra
 14005  	uint16(16), uint16(16), uint16(16), uint16(16), uint16(16), uint16(16), uint16(16), uint16(16), uint16(17), uint16(17), uint16(17), uint16(17), uint16(18), uint16(18), uint16(18), uint16(18),
 14006  			uint16(19), uint16(19), uint16(19), uint16(19), uint16(20), uint16(20), uint16(20), uint16(20), uint16(21), uint16(21), uint16(21), uint16(21), uint16(16), uint16(77), uint16(202)} /* inftrees.c:63:33 */
 14007  var dbase = [32]uint16{ // Distance codes 0..29 base
 14008  	uint16(1), uint16(2), uint16(3), uint16(4), uint16(5), uint16(7), uint16(9), uint16(13), uint16(17), uint16(25), uint16(33), uint16(49), uint16(65), uint16(97), uint16(129), uint16(193),
 14009  	uint16(257), uint16(385), uint16(513), uint16(769), uint16(1025), uint16(1537), uint16(2049), uint16(3073), uint16(4097), uint16(6145),
 14010  			uint16(8193), uint16(12289), uint16(16385), uint16(24577), uint16(0), uint16(0)} /* inftrees.c:66:33 */
 14011  var dext = [32]uint16{ // Distance codes 0..29 extra
 14012  	uint16(16), uint16(16), uint16(16), uint16(16), uint16(17), uint16(17), uint16(18), uint16(18), uint16(19), uint16(19), uint16(20), uint16(20), uint16(21), uint16(21), uint16(22), uint16(22),
 14013  	uint16(23), uint16(23), uint16(24), uint16(24), uint16(25), uint16(25), uint16(26), uint16(26), uint16(27), uint16(27),
 14014  	uint16(28), uint16(28), uint16(29), uint16(29), uint16(64), uint16(64)} /* inftrees.c:70:33 */
 14015  
 14016  type Static_tree_desc = Static_tree_desc_s /* deflate.h:84:36 */
 14017  
 14018  // ===========================================================================
 14019  // Constants
 14020  
 14021  // Bit length codes must not exceed MAX_BL_BITS bits
 14022  
 14023  // end of block literal code
 14024  
 14025  // repeat previous bit length 3-6 times (2 bits of repeat count)
 14026  
 14027  // repeat a zero length 3-10 times  (3 bits of repeat count)
 14028  
 14029  // repeat a zero length 11-138 times  (7 bits of repeat count)
 14030  
 14031  var extra_lbits = [29]int32{0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 0} /* trees.c:62:17 */
 14032  
 14033  var extra_dbits = [30]int32{0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 7, 7, 8, 8, 9, 9, 10, 10, 11, 11, 12, 12, 13, 13} /* trees.c:65:17 */
 14034  
 14035  var extra_blbits = [19]int32{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 3, 7} /* trees.c:68:17 */
 14036  
 14037  var bl_order = [19]Uch{Uch(16), Uch(17), Uch(18), Uch(0), Uch(8), Uch(7), Uch(9), Uch(6), Uch(10), Uch(5), Uch(11), Uch(4), Uch(12), Uch(3), Uch(13), Uch(2), Uch(14), Uch(1), Uch(15)} /* trees.c:71:17 */
 14038  // The lengths of the bit length codes are sent in order of decreasing
 14039  // probability, to avoid transmitting the lengths for unused bit length codes.
 14040  
 14041  // ===========================================================================
 14042  // Local data. These are initialized only once.
 14043  
 14044  // header created automatically with -DGEN_TREES_H
 14045  
 14046  var static_ltree = [288]Ct_data{{Ffc: func() (r struct{ Ffreq Ush }) {
 14047  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(12)
 14048  	return r
 14049  }(), Fdl: func() (r struct{ Fdad Ush }) {
 14050  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14051  	return r
 14052  }()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14053  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(140)
 14054  	return r
 14055  }(), Fdl: func() (r struct{ Fdad Ush }) {
 14056  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14057  	return r
 14058  }()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14059  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(76)
 14060  	return r
 14061  }(), Fdl: func() (r struct{ Fdad Ush }) {
 14062  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14063  	return r
 14064  }()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14065  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(204)
 14066  	return r
 14067  }(), Fdl: func() (r struct{ Fdad Ush }) {
 14068  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14069  	return r
 14070  }()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14071  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(44)
 14072  	return r
 14073  }(), Fdl: func() (r struct{ Fdad Ush }) {
 14074  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14075  	return r
 14076  }()},
 14077  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14078  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(172)
 14079  		return r
 14080  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14081  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14082  		return r
 14083  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14084  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(108)
 14085  		return r
 14086  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14087  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14088  		return r
 14089  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14090  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(236)
 14091  		return r
 14092  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14093  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14094  		return r
 14095  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14096  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(28)
 14097  		return r
 14098  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14099  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14100  		return r
 14101  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14102  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(156)
 14103  		return r
 14104  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14105  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14106  		return r
 14107  	}()},
 14108  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14109  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(92)
 14110  		return r
 14111  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14112  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14113  		return r
 14114  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14115  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(220)
 14116  		return r
 14117  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14118  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14119  		return r
 14120  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14121  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(60)
 14122  		return r
 14123  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14124  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14125  		return r
 14126  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14127  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(188)
 14128  		return r
 14129  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14130  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14131  		return r
 14132  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14133  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(124)
 14134  		return r
 14135  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14136  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14137  		return r
 14138  	}()},
 14139  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14140  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(252)
 14141  		return r
 14142  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14143  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14144  		return r
 14145  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14146  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(2)
 14147  		return r
 14148  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14149  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14150  		return r
 14151  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14152  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(130)
 14153  		return r
 14154  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14155  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14156  		return r
 14157  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14158  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(66)
 14159  		return r
 14160  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14161  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14162  		return r
 14163  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14164  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(194)
 14165  		return r
 14166  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14167  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14168  		return r
 14169  	}()},
 14170  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14171  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(34)
 14172  		return r
 14173  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14174  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14175  		return r
 14176  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14177  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(162)
 14178  		return r
 14179  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14180  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14181  		return r
 14182  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14183  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(98)
 14184  		return r
 14185  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14186  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14187  		return r
 14188  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14189  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(226)
 14190  		return r
 14191  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14192  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14193  		return r
 14194  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14195  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(18)
 14196  		return r
 14197  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14198  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14199  		return r
 14200  	}()},
 14201  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14202  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(146)
 14203  		return r
 14204  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14205  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14206  		return r
 14207  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14208  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(82)
 14209  		return r
 14210  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14211  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14212  		return r
 14213  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14214  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(210)
 14215  		return r
 14216  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14217  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14218  		return r
 14219  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14220  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(50)
 14221  		return r
 14222  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14223  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14224  		return r
 14225  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14226  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(178)
 14227  		return r
 14228  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14229  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14230  		return r
 14231  	}()},
 14232  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14233  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(114)
 14234  		return r
 14235  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14236  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14237  		return r
 14238  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14239  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(242)
 14240  		return r
 14241  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14242  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14243  		return r
 14244  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14245  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(10)
 14246  		return r
 14247  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14248  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14249  		return r
 14250  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14251  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(138)
 14252  		return r
 14253  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14254  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14255  		return r
 14256  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14257  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(74)
 14258  		return r
 14259  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14260  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14261  		return r
 14262  	}()},
 14263  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14264  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(202)
 14265  		return r
 14266  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14267  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14268  		return r
 14269  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14270  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(42)
 14271  		return r
 14272  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14273  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14274  		return r
 14275  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14276  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(170)
 14277  		return r
 14278  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14279  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14280  		return r
 14281  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14282  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(106)
 14283  		return r
 14284  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14285  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14286  		return r
 14287  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14288  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(234)
 14289  		return r
 14290  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14291  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14292  		return r
 14293  	}()},
 14294  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14295  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(26)
 14296  		return r
 14297  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14298  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14299  		return r
 14300  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14301  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(154)
 14302  		return r
 14303  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14304  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14305  		return r
 14306  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14307  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(90)
 14308  		return r
 14309  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14310  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14311  		return r
 14312  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14313  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(218)
 14314  		return r
 14315  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14316  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14317  		return r
 14318  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14319  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(58)
 14320  		return r
 14321  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14322  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14323  		return r
 14324  	}()},
 14325  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14326  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(186)
 14327  		return r
 14328  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14329  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14330  		return r
 14331  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14332  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(122)
 14333  		return r
 14334  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14335  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14336  		return r
 14337  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14338  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(250)
 14339  		return r
 14340  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14341  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14342  		return r
 14343  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14344  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(6)
 14345  		return r
 14346  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14347  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14348  		return r
 14349  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14350  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(134)
 14351  		return r
 14352  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14353  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14354  		return r
 14355  	}()},
 14356  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14357  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(70)
 14358  		return r
 14359  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14360  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14361  		return r
 14362  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14363  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(198)
 14364  		return r
 14365  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14366  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14367  		return r
 14368  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14369  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(38)
 14370  		return r
 14371  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14372  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14373  		return r
 14374  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14375  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(166)
 14376  		return r
 14377  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14378  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14379  		return r
 14380  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14381  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(102)
 14382  		return r
 14383  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14384  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14385  		return r
 14386  	}()},
 14387  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14388  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(230)
 14389  		return r
 14390  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14391  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14392  		return r
 14393  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14394  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(22)
 14395  		return r
 14396  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14397  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14398  		return r
 14399  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14400  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(150)
 14401  		return r
 14402  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14403  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14404  		return r
 14405  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14406  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(86)
 14407  		return r
 14408  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14409  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14410  		return r
 14411  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14412  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(214)
 14413  		return r
 14414  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14415  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14416  		return r
 14417  	}()},
 14418  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14419  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(54)
 14420  		return r
 14421  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14422  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14423  		return r
 14424  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14425  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(182)
 14426  		return r
 14427  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14428  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14429  		return r
 14430  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14431  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(118)
 14432  		return r
 14433  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14434  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14435  		return r
 14436  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14437  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(246)
 14438  		return r
 14439  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14440  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14441  		return r
 14442  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14443  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(14)
 14444  		return r
 14445  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14446  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14447  		return r
 14448  	}()},
 14449  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14450  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(142)
 14451  		return r
 14452  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14453  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14454  		return r
 14455  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14456  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(78)
 14457  		return r
 14458  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14459  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14460  		return r
 14461  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14462  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(206)
 14463  		return r
 14464  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14465  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14466  		return r
 14467  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14468  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(46)
 14469  		return r
 14470  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14471  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14472  		return r
 14473  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14474  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(174)
 14475  		return r
 14476  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14477  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14478  		return r
 14479  	}()},
 14480  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14481  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(110)
 14482  		return r
 14483  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14484  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14485  		return r
 14486  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14487  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(238)
 14488  		return r
 14489  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14490  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14491  		return r
 14492  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14493  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(30)
 14494  		return r
 14495  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14496  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14497  		return r
 14498  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14499  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(158)
 14500  		return r
 14501  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14502  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14503  		return r
 14504  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14505  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(94)
 14506  		return r
 14507  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14508  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14509  		return r
 14510  	}()},
 14511  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14512  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(222)
 14513  		return r
 14514  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14515  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14516  		return r
 14517  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14518  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(62)
 14519  		return r
 14520  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14521  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14522  		return r
 14523  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14524  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(190)
 14525  		return r
 14526  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14527  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14528  		return r
 14529  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14530  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(126)
 14531  		return r
 14532  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14533  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14534  		return r
 14535  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14536  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(254)
 14537  		return r
 14538  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14539  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14540  		return r
 14541  	}()},
 14542  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14543  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(1)
 14544  		return r
 14545  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14546  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14547  		return r
 14548  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14549  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(129)
 14550  		return r
 14551  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14552  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14553  		return r
 14554  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14555  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(65)
 14556  		return r
 14557  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14558  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14559  		return r
 14560  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14561  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(193)
 14562  		return r
 14563  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14564  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14565  		return r
 14566  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14567  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(33)
 14568  		return r
 14569  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14570  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14571  		return r
 14572  	}()},
 14573  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14574  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(161)
 14575  		return r
 14576  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14577  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14578  		return r
 14579  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14580  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(97)
 14581  		return r
 14582  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14583  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14584  		return r
 14585  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14586  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(225)
 14587  		return r
 14588  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14589  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14590  		return r
 14591  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14592  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(17)
 14593  		return r
 14594  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14595  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14596  		return r
 14597  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14598  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(145)
 14599  		return r
 14600  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14601  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14602  		return r
 14603  	}()},
 14604  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14605  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(81)
 14606  		return r
 14607  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14608  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14609  		return r
 14610  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14611  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(209)
 14612  		return r
 14613  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14614  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14615  		return r
 14616  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14617  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(49)
 14618  		return r
 14619  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14620  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14621  		return r
 14622  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14623  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(177)
 14624  		return r
 14625  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14626  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14627  		return r
 14628  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14629  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(113)
 14630  		return r
 14631  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14632  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14633  		return r
 14634  	}()},
 14635  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14636  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(241)
 14637  		return r
 14638  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14639  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14640  		return r
 14641  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14642  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 14643  		return r
 14644  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14645  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14646  		return r
 14647  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14648  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(137)
 14649  		return r
 14650  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14651  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14652  		return r
 14653  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14654  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(73)
 14655  		return r
 14656  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14657  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14658  		return r
 14659  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14660  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(201)
 14661  		return r
 14662  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14663  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14664  		return r
 14665  	}()},
 14666  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14667  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(41)
 14668  		return r
 14669  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14670  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14671  		return r
 14672  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14673  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(169)
 14674  		return r
 14675  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14676  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14677  		return r
 14678  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14679  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(105)
 14680  		return r
 14681  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14682  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14683  		return r
 14684  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14685  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(233)
 14686  		return r
 14687  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14688  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14689  		return r
 14690  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14691  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(25)
 14692  		return r
 14693  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14694  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14695  		return r
 14696  	}()},
 14697  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14698  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(153)
 14699  		return r
 14700  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14701  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14702  		return r
 14703  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14704  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(89)
 14705  		return r
 14706  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14707  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14708  		return r
 14709  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14710  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(217)
 14711  		return r
 14712  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14713  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14714  		return r
 14715  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14716  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(57)
 14717  		return r
 14718  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14719  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14720  		return r
 14721  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14722  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(185)
 14723  		return r
 14724  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14725  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14726  		return r
 14727  	}()},
 14728  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14729  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(121)
 14730  		return r
 14731  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14732  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14733  		return r
 14734  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14735  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(249)
 14736  		return r
 14737  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14738  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14739  		return r
 14740  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14741  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 14742  		return r
 14743  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14744  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14745  		return r
 14746  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14747  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(133)
 14748  		return r
 14749  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14750  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14751  		return r
 14752  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14753  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(69)
 14754  		return r
 14755  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14756  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14757  		return r
 14758  	}()},
 14759  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14760  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(197)
 14761  		return r
 14762  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14763  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14764  		return r
 14765  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14766  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(37)
 14767  		return r
 14768  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14769  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14770  		return r
 14771  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14772  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(165)
 14773  		return r
 14774  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14775  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14776  		return r
 14777  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14778  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(101)
 14779  		return r
 14780  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14781  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14782  		return r
 14783  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14784  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(229)
 14785  		return r
 14786  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14787  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14788  		return r
 14789  	}()},
 14790  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14791  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(21)
 14792  		return r
 14793  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14794  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14795  		return r
 14796  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14797  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(149)
 14798  		return r
 14799  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14800  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14801  		return r
 14802  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14803  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(85)
 14804  		return r
 14805  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14806  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14807  		return r
 14808  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14809  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(213)
 14810  		return r
 14811  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14812  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14813  		return r
 14814  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14815  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(53)
 14816  		return r
 14817  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14818  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14819  		return r
 14820  	}()},
 14821  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14822  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(181)
 14823  		return r
 14824  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14825  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14826  		return r
 14827  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14828  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(117)
 14829  		return r
 14830  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14831  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14832  		return r
 14833  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14834  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(245)
 14835  		return r
 14836  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14837  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14838  		return r
 14839  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14840  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(13)
 14841  		return r
 14842  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14843  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14844  		return r
 14845  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14846  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(141)
 14847  		return r
 14848  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14849  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14850  		return r
 14851  	}()},
 14852  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14853  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(77)
 14854  		return r
 14855  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14856  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14857  		return r
 14858  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14859  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(205)
 14860  		return r
 14861  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14862  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14863  		return r
 14864  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14865  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(45)
 14866  		return r
 14867  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14868  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14869  		return r
 14870  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14871  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(173)
 14872  		return r
 14873  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14874  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14875  		return r
 14876  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14877  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(109)
 14878  		return r
 14879  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14880  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14881  		return r
 14882  	}()},
 14883  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14884  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(237)
 14885  		return r
 14886  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14887  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14888  		return r
 14889  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14890  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(29)
 14891  		return r
 14892  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14893  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14894  		return r
 14895  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14896  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(157)
 14897  		return r
 14898  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14899  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14900  		return r
 14901  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14902  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(93)
 14903  		return r
 14904  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14905  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14906  		return r
 14907  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14908  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(221)
 14909  		return r
 14910  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14911  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14912  		return r
 14913  	}()},
 14914  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14915  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(61)
 14916  		return r
 14917  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14918  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14919  		return r
 14920  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14921  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(189)
 14922  		return r
 14923  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14924  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14925  		return r
 14926  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14927  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(125)
 14928  		return r
 14929  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14930  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14931  		return r
 14932  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14933  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(253)
 14934  		return r
 14935  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14936  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 14937  		return r
 14938  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14939  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(19)
 14940  		return r
 14941  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14942  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 14943  		return r
 14944  	}()},
 14945  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14946  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(275)
 14947  		return r
 14948  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14949  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 14950  		return r
 14951  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14952  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(147)
 14953  		return r
 14954  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14955  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 14956  		return r
 14957  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14958  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(403)
 14959  		return r
 14960  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14961  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 14962  		return r
 14963  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14964  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(83)
 14965  		return r
 14966  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14967  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 14968  		return r
 14969  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14970  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(339)
 14971  		return r
 14972  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14973  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 14974  		return r
 14975  	}()},
 14976  	{Ffc: func() (r struct{ Ffreq Ush }) {
 14977  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(211)
 14978  		return r
 14979  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14980  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 14981  		return r
 14982  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14983  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(467)
 14984  		return r
 14985  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14986  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 14987  		return r
 14988  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14989  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(51)
 14990  		return r
 14991  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14992  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 14993  		return r
 14994  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 14995  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(307)
 14996  		return r
 14997  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 14998  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 14999  		return r
 15000  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15001  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(179)
 15002  		return r
 15003  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15004  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15005  		return r
 15006  	}()},
 15007  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15008  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(435)
 15009  		return r
 15010  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15011  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15012  		return r
 15013  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15014  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(115)
 15015  		return r
 15016  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15017  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15018  		return r
 15019  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15020  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(371)
 15021  		return r
 15022  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15023  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15024  		return r
 15025  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15026  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(243)
 15027  		return r
 15028  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15029  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15030  		return r
 15031  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15032  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(499)
 15033  		return r
 15034  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15035  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15036  		return r
 15037  	}()},
 15038  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15039  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(11)
 15040  		return r
 15041  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15042  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15043  		return r
 15044  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15045  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(267)
 15046  		return r
 15047  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15048  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15049  		return r
 15050  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15051  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(139)
 15052  		return r
 15053  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15054  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15055  		return r
 15056  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15057  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(395)
 15058  		return r
 15059  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15060  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15061  		return r
 15062  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15063  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(75)
 15064  		return r
 15065  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15066  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15067  		return r
 15068  	}()},
 15069  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15070  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(331)
 15071  		return r
 15072  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15073  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15074  		return r
 15075  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15076  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(203)
 15077  		return r
 15078  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15079  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15080  		return r
 15081  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15082  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(459)
 15083  		return r
 15084  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15085  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15086  		return r
 15087  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15088  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(43)
 15089  		return r
 15090  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15091  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15092  		return r
 15093  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15094  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(299)
 15095  		return r
 15096  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15097  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15098  		return r
 15099  	}()},
 15100  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15101  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(171)
 15102  		return r
 15103  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15104  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15105  		return r
 15106  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15107  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(427)
 15108  		return r
 15109  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15110  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15111  		return r
 15112  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15113  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(107)
 15114  		return r
 15115  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15116  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15117  		return r
 15118  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15119  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(363)
 15120  		return r
 15121  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15122  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15123  		return r
 15124  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15125  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(235)
 15126  		return r
 15127  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15128  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15129  		return r
 15130  	}()},
 15131  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15132  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(491)
 15133  		return r
 15134  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15135  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15136  		return r
 15137  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15138  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(27)
 15139  		return r
 15140  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15141  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15142  		return r
 15143  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15144  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(283)
 15145  		return r
 15146  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15147  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15148  		return r
 15149  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15150  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(155)
 15151  		return r
 15152  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15153  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15154  		return r
 15155  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15156  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(411)
 15157  		return r
 15158  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15159  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15160  		return r
 15161  	}()},
 15162  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15163  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(91)
 15164  		return r
 15165  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15166  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15167  		return r
 15168  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15169  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(347)
 15170  		return r
 15171  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15172  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15173  		return r
 15174  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15175  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(219)
 15176  		return r
 15177  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15178  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15179  		return r
 15180  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15181  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(475)
 15182  		return r
 15183  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15184  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15185  		return r
 15186  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15187  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(59)
 15188  		return r
 15189  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15190  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15191  		return r
 15192  	}()},
 15193  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15194  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(315)
 15195  		return r
 15196  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15197  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15198  		return r
 15199  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15200  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(187)
 15201  		return r
 15202  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15203  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15204  		return r
 15205  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15206  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(443)
 15207  		return r
 15208  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15209  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15210  		return r
 15211  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15212  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(123)
 15213  		return r
 15214  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15215  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15216  		return r
 15217  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15218  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(379)
 15219  		return r
 15220  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15221  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15222  		return r
 15223  	}()},
 15224  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15225  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(251)
 15226  		return r
 15227  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15228  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15229  		return r
 15230  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15231  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(507)
 15232  		return r
 15233  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15234  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15235  		return r
 15236  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15237  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15238  		return r
 15239  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15240  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15241  		return r
 15242  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15243  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(263)
 15244  		return r
 15245  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15246  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15247  		return r
 15248  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15249  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(135)
 15250  		return r
 15251  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15252  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15253  		return r
 15254  	}()},
 15255  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15256  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(391)
 15257  		return r
 15258  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15259  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15260  		return r
 15261  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15262  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(71)
 15263  		return r
 15264  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15265  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15266  		return r
 15267  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15268  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(327)
 15269  		return r
 15270  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15271  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15272  		return r
 15273  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15274  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(199)
 15275  		return r
 15276  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15277  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15278  		return r
 15279  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15280  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(455)
 15281  		return r
 15282  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15283  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15284  		return r
 15285  	}()},
 15286  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15287  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(39)
 15288  		return r
 15289  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15290  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15291  		return r
 15292  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15293  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(295)
 15294  		return r
 15295  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15296  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15297  		return r
 15298  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15299  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(167)
 15300  		return r
 15301  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15302  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15303  		return r
 15304  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15305  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(423)
 15306  		return r
 15307  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15308  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15309  		return r
 15310  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15311  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(103)
 15312  		return r
 15313  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15314  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15315  		return r
 15316  	}()},
 15317  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15318  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(359)
 15319  		return r
 15320  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15321  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15322  		return r
 15323  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15324  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(231)
 15325  		return r
 15326  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15327  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15328  		return r
 15329  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15330  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(487)
 15331  		return r
 15332  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15333  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15334  		return r
 15335  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15336  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(23)
 15337  		return r
 15338  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15339  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15340  		return r
 15341  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15342  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(279)
 15343  		return r
 15344  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15345  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15346  		return r
 15347  	}()},
 15348  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15349  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(151)
 15350  		return r
 15351  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15352  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15353  		return r
 15354  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15355  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(407)
 15356  		return r
 15357  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15358  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15359  		return r
 15360  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15361  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(87)
 15362  		return r
 15363  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15364  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15365  		return r
 15366  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15367  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(343)
 15368  		return r
 15369  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15370  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15371  		return r
 15372  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15373  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(215)
 15374  		return r
 15375  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15376  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15377  		return r
 15378  	}()},
 15379  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15380  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(471)
 15381  		return r
 15382  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15383  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15384  		return r
 15385  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15386  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(55)
 15387  		return r
 15388  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15389  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15390  		return r
 15391  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15392  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(311)
 15393  		return r
 15394  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15395  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15396  		return r
 15397  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15398  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(183)
 15399  		return r
 15400  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15401  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15402  		return r
 15403  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15404  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(439)
 15405  		return r
 15406  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15407  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15408  		return r
 15409  	}()},
 15410  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15411  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(119)
 15412  		return r
 15413  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15414  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15415  		return r
 15416  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15417  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(375)
 15418  		return r
 15419  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15420  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15421  		return r
 15422  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15423  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(247)
 15424  		return r
 15425  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15426  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15427  		return r
 15428  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15429  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(503)
 15430  		return r
 15431  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15432  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15433  		return r
 15434  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15435  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(15)
 15436  		return r
 15437  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15438  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15439  		return r
 15440  	}()},
 15441  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15442  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(271)
 15443  		return r
 15444  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15445  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15446  		return r
 15447  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15448  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(143)
 15449  		return r
 15450  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15451  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15452  		return r
 15453  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15454  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(399)
 15455  		return r
 15456  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15457  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15458  		return r
 15459  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15460  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(79)
 15461  		return r
 15462  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15463  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15464  		return r
 15465  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15466  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(335)
 15467  		return r
 15468  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15469  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15470  		return r
 15471  	}()},
 15472  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15473  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(207)
 15474  		return r
 15475  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15476  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15477  		return r
 15478  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15479  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(463)
 15480  		return r
 15481  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15482  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15483  		return r
 15484  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15485  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(47)
 15486  		return r
 15487  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15488  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15489  		return r
 15490  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15491  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(303)
 15492  		return r
 15493  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15494  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15495  		return r
 15496  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15497  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(175)
 15498  		return r
 15499  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15500  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15501  		return r
 15502  	}()},
 15503  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15504  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(431)
 15505  		return r
 15506  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15507  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15508  		return r
 15509  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15510  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(111)
 15511  		return r
 15512  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15513  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15514  		return r
 15515  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15516  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(367)
 15517  		return r
 15518  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15519  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15520  		return r
 15521  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15522  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(239)
 15523  		return r
 15524  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15525  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15526  		return r
 15527  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15528  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(495)
 15529  		return r
 15530  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15531  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15532  		return r
 15533  	}()},
 15534  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15535  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(31)
 15536  		return r
 15537  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15538  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15539  		return r
 15540  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15541  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(287)
 15542  		return r
 15543  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15544  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15545  		return r
 15546  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15547  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(159)
 15548  		return r
 15549  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15550  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15551  		return r
 15552  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15553  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(415)
 15554  		return r
 15555  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15556  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15557  		return r
 15558  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15559  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(95)
 15560  		return r
 15561  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15562  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15563  		return r
 15564  	}()},
 15565  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15566  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(351)
 15567  		return r
 15568  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15569  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15570  		return r
 15571  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15572  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(223)
 15573  		return r
 15574  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15575  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15576  		return r
 15577  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15578  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(479)
 15579  		return r
 15580  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15581  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15582  		return r
 15583  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15584  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(63)
 15585  		return r
 15586  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15587  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15588  		return r
 15589  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15590  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(319)
 15591  		return r
 15592  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15593  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15594  		return r
 15595  	}()},
 15596  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15597  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(191)
 15598  		return r
 15599  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15600  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15601  		return r
 15602  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15603  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(447)
 15604  		return r
 15605  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15606  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15607  		return r
 15608  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15609  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(127)
 15610  		return r
 15611  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15612  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15613  		return r
 15614  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15615  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(383)
 15616  		return r
 15617  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15618  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15619  		return r
 15620  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15621  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(255)
 15622  		return r
 15623  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15624  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15625  		return r
 15626  	}()},
 15627  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15628  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(511)
 15629  		return r
 15630  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15631  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15632  		return r
 15633  	}()}, {Fdl: func() (r struct{ Fdad Ush }) {
 15634  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15635  		return r
 15636  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15637  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(64)
 15638  		return r
 15639  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15640  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15641  		return r
 15642  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15643  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(32)
 15644  		return r
 15645  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15646  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15647  		return r
 15648  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15649  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(96)
 15650  		return r
 15651  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15652  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15653  		return r
 15654  	}()},
 15655  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15656  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(16)
 15657  		return r
 15658  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15659  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15660  		return r
 15661  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15662  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(80)
 15663  		return r
 15664  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15665  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15666  		return r
 15667  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15668  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(48)
 15669  		return r
 15670  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15671  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15672  		return r
 15673  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15674  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(112)
 15675  		return r
 15676  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15677  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15678  		return r
 15679  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15680  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 15681  		return r
 15682  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15683  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15684  		return r
 15685  	}()},
 15686  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15687  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(72)
 15688  		return r
 15689  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15690  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15691  		return r
 15692  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15693  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(40)
 15694  		return r
 15695  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15696  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15697  		return r
 15698  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15699  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(104)
 15700  		return r
 15701  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15702  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15703  		return r
 15704  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15705  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(24)
 15706  		return r
 15707  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15708  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15709  		return r
 15710  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15711  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(88)
 15712  		return r
 15713  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15714  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15715  		return r
 15716  	}()},
 15717  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15718  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(56)
 15719  		return r
 15720  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15721  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15722  		return r
 15723  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15724  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(120)
 15725  		return r
 15726  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15727  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15728  		return r
 15729  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15730  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(4)
 15731  		return r
 15732  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15733  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15734  		return r
 15735  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15736  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(68)
 15737  		return r
 15738  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15739  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15740  		return r
 15741  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15742  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(36)
 15743  		return r
 15744  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15745  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15746  		return r
 15747  	}()},
 15748  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15749  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(100)
 15750  		return r
 15751  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15752  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15753  		return r
 15754  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15755  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(20)
 15756  		return r
 15757  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15758  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15759  		return r
 15760  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15761  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(84)
 15762  		return r
 15763  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15764  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15765  		return r
 15766  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15767  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(52)
 15768  		return r
 15769  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15770  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15771  		return r
 15772  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15773  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(116)
 15774  		return r
 15775  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15776  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 15777  		return r
 15778  	}()},
 15779  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15780  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(3)
 15781  		return r
 15782  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15783  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 15784  		return r
 15785  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15786  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(131)
 15787  		return r
 15788  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15789  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 15790  		return r
 15791  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15792  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(67)
 15793  		return r
 15794  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15795  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 15796  		return r
 15797  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15798  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(195)
 15799  		return r
 15800  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15801  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 15802  		return r
 15803  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15804  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(35)
 15805  		return r
 15806  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15807  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 15808  		return r
 15809  	}()},
 15810  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15811  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(163)
 15812  		return r
 15813  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15814  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 15815  		return r
 15816  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15817  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(99)
 15818  		return r
 15819  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15820  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 15821  		return r
 15822  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15823  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(227)
 15824  		return r
 15825  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15826  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 15827  		return r
 15828  	}()}} /* trees.h:3:21 */
 15829  
 15830  var static_dtree = [30]Ct_data{{Fdl: func() (r struct{ Fdad Ush }) {
 15831  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15832  	return r
 15833  }()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15834  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(16)
 15835  	return r
 15836  }(), Fdl: func() (r struct{ Fdad Ush }) {
 15837  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15838  	return r
 15839  }()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15840  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(8)
 15841  	return r
 15842  }(), Fdl: func() (r struct{ Fdad Ush }) {
 15843  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15844  	return r
 15845  }()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15846  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(24)
 15847  	return r
 15848  }(), Fdl: func() (r struct{ Fdad Ush }) {
 15849  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15850  	return r
 15851  }()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15852  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(4)
 15853  	return r
 15854  }(), Fdl: func() (r struct{ Fdad Ush }) {
 15855  	*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15856  	return r
 15857  }()},
 15858  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15859  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(20)
 15860  		return r
 15861  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15862  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15863  		return r
 15864  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15865  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(12)
 15866  		return r
 15867  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15868  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15869  		return r
 15870  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15871  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(28)
 15872  		return r
 15873  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15874  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15875  		return r
 15876  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15877  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(2)
 15878  		return r
 15879  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15880  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15881  		return r
 15882  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15883  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(18)
 15884  		return r
 15885  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15886  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15887  		return r
 15888  	}()},
 15889  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15890  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(10)
 15891  		return r
 15892  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15893  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15894  		return r
 15895  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15896  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(26)
 15897  		return r
 15898  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15899  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15900  		return r
 15901  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15902  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(6)
 15903  		return r
 15904  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15905  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15906  		return r
 15907  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15908  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(22)
 15909  		return r
 15910  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15911  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15912  		return r
 15913  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15914  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(14)
 15915  		return r
 15916  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15917  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15918  		return r
 15919  	}()},
 15920  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15921  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(30)
 15922  		return r
 15923  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15924  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15925  		return r
 15926  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15927  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(1)
 15928  		return r
 15929  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15930  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15931  		return r
 15932  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15933  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(17)
 15934  		return r
 15935  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15936  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15937  		return r
 15938  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15939  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(9)
 15940  		return r
 15941  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15942  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15943  		return r
 15944  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15945  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(25)
 15946  		return r
 15947  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15948  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15949  		return r
 15950  	}()},
 15951  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15952  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15953  		return r
 15954  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15955  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15956  		return r
 15957  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15958  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(21)
 15959  		return r
 15960  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15961  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15962  		return r
 15963  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15964  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(13)
 15965  		return r
 15966  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15967  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15968  		return r
 15969  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15970  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(29)
 15971  		return r
 15972  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15973  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15974  		return r
 15975  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15976  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(3)
 15977  		return r
 15978  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15979  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15980  		return r
 15981  	}()},
 15982  	{Ffc: func() (r struct{ Ffreq Ush }) {
 15983  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(19)
 15984  		return r
 15985  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15986  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15987  		return r
 15988  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15989  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(11)
 15990  		return r
 15991  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15992  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15993  		return r
 15994  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 15995  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(27)
 15996  		return r
 15997  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 15998  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 15999  		return r
 16000  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 16001  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(7)
 16002  		return r
 16003  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 16004  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 16005  		return r
 16006  	}()}, {Ffc: func() (r struct{ Ffreq Ush }) {
 16007  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(23)
 16008  		return r
 16009  	}(), Fdl: func() (r struct{ Fdad Ush }) {
 16010  		*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&r)) + 0)) = Ush(5)
 16011  		return r
 16012  	}()}} /* trees.h:64:21 */
 16013  
 16014  var X_dist_code = [512]Uch{
 16015  	Uch(0), Uch(1), Uch(2), Uch(3), Uch(4), Uch(4), Uch(5), Uch(5), Uch(6), Uch(6), Uch(6), Uch(6), Uch(7), Uch(7), Uch(7), Uch(7), Uch(8), Uch(8), Uch(8), Uch(8),
 16016  	Uch(8), Uch(8), Uch(8), Uch(8), Uch(9), Uch(9), Uch(9), Uch(9), Uch(9), Uch(9), Uch(9), Uch(9), Uch(10), Uch(10), Uch(10), Uch(10), Uch(10), Uch(10), Uch(10), Uch(10),
 16017  	Uch(10), Uch(10), Uch(10), Uch(10), Uch(10), Uch(10), Uch(10), Uch(10), Uch(11), Uch(11), Uch(11), Uch(11), Uch(11), Uch(11), Uch(11), Uch(11), Uch(11), Uch(11), Uch(11), Uch(11),
 16018  	Uch(11), Uch(11), Uch(11), Uch(11), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12),
 16019  	Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(12), Uch(13), Uch(13), Uch(13), Uch(13),
 16020  	Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13),
 16021  	Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(13), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14),
 16022  	Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14),
 16023  	Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14),
 16024  	Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(14), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15),
 16025  	Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15),
 16026  	Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15),
 16027  	Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(15), Uch(0), Uch(0), Uch(16), Uch(17),
 16028  	Uch(18), Uch(18), Uch(19), Uch(19), Uch(20), Uch(20), Uch(20), Uch(20), Uch(21), Uch(21), Uch(21), Uch(21), Uch(22), Uch(22), Uch(22), Uch(22), Uch(22), Uch(22), Uch(22), Uch(22),
 16029  	Uch(23), Uch(23), Uch(23), Uch(23), Uch(23), Uch(23), Uch(23), Uch(23), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24),
 16030  	Uch(24), Uch(24), Uch(24), Uch(24), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25),
 16031  	Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26),
 16032  	Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27),
 16033  	Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27),
 16034  	Uch(27), Uch(27), Uch(27), Uch(27), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28),
 16035  	Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28),
 16036  	Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28),
 16037  	Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(28), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29),
 16038  	Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29),
 16039  	Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29),
 16040  	Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29), Uch(29),
 16041  } /* trees.h:73:25 */
 16042  
 16043  var X_length_code = [256]Uch{
 16044  	Uch(0), Uch(1), Uch(2), Uch(3), Uch(4), Uch(5), Uch(6), Uch(7), Uch(8), Uch(8), Uch(9), Uch(9), Uch(10), Uch(10), Uch(11), Uch(11), Uch(12), Uch(12), Uch(12), Uch(12),
 16045  	Uch(13), Uch(13), Uch(13), Uch(13), Uch(14), Uch(14), Uch(14), Uch(14), Uch(15), Uch(15), Uch(15), Uch(15), Uch(16), Uch(16), Uch(16), Uch(16), Uch(16), Uch(16), Uch(16), Uch(16),
 16046  	Uch(17), Uch(17), Uch(17), Uch(17), Uch(17), Uch(17), Uch(17), Uch(17), Uch(18), Uch(18), Uch(18), Uch(18), Uch(18), Uch(18), Uch(18), Uch(18), Uch(19), Uch(19), Uch(19), Uch(19),
 16047  	Uch(19), Uch(19), Uch(19), Uch(19), Uch(20), Uch(20), Uch(20), Uch(20), Uch(20), Uch(20), Uch(20), Uch(20), Uch(20), Uch(20), Uch(20), Uch(20), Uch(20), Uch(20), Uch(20), Uch(20),
 16048  	Uch(21), Uch(21), Uch(21), Uch(21), Uch(21), Uch(21), Uch(21), Uch(21), Uch(21), Uch(21), Uch(21), Uch(21), Uch(21), Uch(21), Uch(21), Uch(21), Uch(22), Uch(22), Uch(22), Uch(22),
 16049  	Uch(22), Uch(22), Uch(22), Uch(22), Uch(22), Uch(22), Uch(22), Uch(22), Uch(22), Uch(22), Uch(22), Uch(22), Uch(23), Uch(23), Uch(23), Uch(23), Uch(23), Uch(23), Uch(23), Uch(23),
 16050  	Uch(23), Uch(23), Uch(23), Uch(23), Uch(23), Uch(23), Uch(23), Uch(23), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24),
 16051  	Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24), Uch(24),
 16052  	Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25),
 16053  	Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(25), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26),
 16054  	Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26), Uch(26),
 16055  	Uch(26), Uch(26), Uch(26), Uch(26), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27),
 16056  	Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(27), Uch(28),
 16057  } /* trees.h:102:25 */
 16058  
 16059  var base_length = [29]int32{
 16060  	0, 1, 2, 3, 4, 5, 6, 7, 8, 10, 12, 14, 16, 20, 24, 28, 32, 40, 48, 56,
 16061  	64, 80, 96, 112, 128, 160, 192, 224, 0,
 16062  } /* trees.h:118:17 */
 16063  
 16064  var base_dist = [30]int32{
 16065  	0, 1, 2, 3, 4, 6, 8, 12, 16, 24,
 16066  	32, 48, 64, 96, 128, 192, 256, 384, 512, 768,
 16067  	1024, 1536, 2048, 3072, 4096, 6144, 8192, 12288, 16384, 24576,
 16068  } /* trees.h:123:17 */
 16069  
 16070  var static_l_desc = Static_tree_desc{Fstatic_tree: 0, Fextra_bits: 0, Fextra_base: LITERALS + 1, Felems: LITERALS + 1 + LENGTH_CODES, Fmax_length: MAX_BITS} /* trees.c:125:31 */
 16071  
 16072  var static_d_desc = Static_tree_desc{Fstatic_tree: 0, Fextra_bits: 0, Felems: D_CODES, Fmax_length: MAX_BITS} /* trees.c:128:31 */
 16073  
 16074  var static_bl_desc = Static_tree_desc{Fextra_bits: 0, Felems: BL_CODES, Fmax_length: MAX_BL_BITS} /* trees.c:131:31 */
 16075  
 16076  // Send a code of the given tree. c and tree must not have side effects
 16077  
 16078  // ===========================================================================
 16079  // Output a short LSB first on the stream.
 16080  // IN assertion: there is enough room in pendingBuf.
 16081  
 16082  // ===========================================================================
 16083  // Send a value on a given number of bits.
 16084  // IN assertion: length <= 16 and value fits in length bits.
 16085  
 16086  // the arguments must not have side effects
 16087  
 16088  // ===========================================================================
 16089  // Initialize the various 'constant' tables.
 16090  func tr_static_init(tls *libc.TLS) { /* trees.c:232:12: */
 16091  }
 16092  
 16093  // ===========================================================================
 16094  // Genererate the file trees.h describing the static trees.
 16095  
 16096  // ===========================================================================
 16097  // Initialize the tree data structures for a new zlib stream.
 16098  func X_tr_init(tls *libc.TLS, s uintptr) { /* trees.c:379:20: */
 16099  	tr_static_init(tls)
 16100  
 16101  	(*Deflate_state)(unsafe.Pointer(s)).Fl_desc.Fdyn_tree = s + 212 /* &.dyn_ltree */
 16102  	(*Deflate_state)(unsafe.Pointer(s)).Fl_desc.Fstat_desc = uintptr(unsafe.Pointer(&static_l_desc))
 16103  
 16104  	(*Deflate_state)(unsafe.Pointer(s)).Fd_desc.Fdyn_tree = s + 2504 /* &.dyn_dtree */
 16105  	(*Deflate_state)(unsafe.Pointer(s)).Fd_desc.Fstat_desc = uintptr(unsafe.Pointer(&static_d_desc))
 16106  
 16107  	(*Deflate_state)(unsafe.Pointer(s)).Fbl_desc.Fdyn_tree = s + 2748 /* &.bl_tree */
 16108  	(*Deflate_state)(unsafe.Pointer(s)).Fbl_desc.Fstat_desc = uintptr(unsafe.Pointer(&static_bl_desc))
 16109  
 16110  	(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(0)
 16111  	(*Deflate_state)(unsafe.Pointer(s)).Fbi_valid = 0
 16112  
 16113  	// Initialize the first block of the first file:
 16114  	init_block(tls, s)
 16115  }
 16116  
 16117  // ===========================================================================
 16118  // Initialize a new block.
 16119  func init_block(tls *libc.TLS, s uintptr) { /* trees.c:407:12: */
 16120  	var n int32 // iterates over tree elements
 16121  
 16122  	// Initialize the trees.
 16123  	for n = 0; n < LITERALS+1+LENGTH_CODES; n++ {
 16124  		*(*Ush)(unsafe.Pointer(s + 212 + uintptr(n)*4)) = Ush(0)
 16125  	}
 16126  	for n = 0; n < D_CODES; n++ {
 16127  		*(*Ush)(unsafe.Pointer(s + 2504 + uintptr(n)*4)) = Ush(0)
 16128  	}
 16129  	for n = 0; n < BL_CODES; n++ {
 16130  		*(*Ush)(unsafe.Pointer(s + 2748 + uintptr(n)*4)) = Ush(0)
 16131  	}
 16132  
 16133  	*(*Ush)(unsafe.Pointer(s + 212 + 256*4)) = Ush(1)
 16134  	(*Deflate_state)(unsafe.Pointer(s)).Fopt_len = libc.AssignPtrUint64(s+5920, uint64(0))
 16135  	(*Deflate_state)(unsafe.Pointer(s)).Flast_lit = libc.AssignPtrUint32(s+5928, UInt(0))
 16136  }
 16137  
 16138  // Index within the heap array of least frequent node in the Huffman tree
 16139  
 16140  // ===========================================================================
 16141  // Remove the smallest element from the heap and recreate the heap with
 16142  // one less element. Updates heap and heap_len.
 16143  
 16144  // ===========================================================================
 16145  // Compares to subtrees, using the tree depth as tie breaker when
 16146  // the subtrees have equal frequency. This minimizes the worst case length.
 16147  
 16148  // ===========================================================================
 16149  // Restore the heap property by moving down the tree starting at node k,
 16150  // exchanging a node with the smallest of its two sons if necessary, stopping
 16151  // when the heap property is re-established (each father smaller than its
 16152  // two sons).
 16153  func pqdownheap(tls *libc.TLS, s uintptr, tree uintptr, k int32) { /* trees.c:451:12: */
 16154  	var v int32 = *(*int32)(unsafe.Pointer(s + 3008 + uintptr(k)*4))
 16155  	var j int32 = k << 1 // left son of k
 16156  	for j <= (*Deflate_state)(unsafe.Pointer(s)).Fheap_len {
 16157  		// Set j to the smallest of the two sons:
 16158  		if j < (*Deflate_state)(unsafe.Pointer(s)).Fheap_len && (int32(*(*Ush)(unsafe.Pointer(tree + uintptr(*(*int32)(unsafe.Pointer(s + 3008 + uintptr(j+1)*4)))*4))) < int32(*(*Ush)(unsafe.Pointer(tree + uintptr(*(*int32)(unsafe.Pointer(s + 3008 + uintptr(j)*4)))*4))) || int32(*(*Ush)(unsafe.Pointer(tree + uintptr(*(*int32)(unsafe.Pointer(s + 3008 + uintptr(j+1)*4)))*4))) == int32(*(*Ush)(unsafe.Pointer(tree + uintptr(*(*int32)(unsafe.Pointer(s + 3008 + uintptr(j)*4)))*4))) && int32(*(*Uch)(unsafe.Pointer(s + 5308 + uintptr(*(*int32)(unsafe.Pointer(s + 3008 + uintptr(j+1)*4)))))) <= int32(*(*Uch)(unsafe.Pointer(s + 5308 + uintptr(*(*int32)(unsafe.Pointer(s + 3008 + uintptr(j)*4))))))) {
 16159  			j++
 16160  		}
 16161  		// Exit if v is smaller than both sons
 16162  		if int32(*(*Ush)(unsafe.Pointer(tree + uintptr(v)*4))) < int32(*(*Ush)(unsafe.Pointer(tree + uintptr(*(*int32)(unsafe.Pointer(s + 3008 + uintptr(j)*4)))*4))) || int32(*(*Ush)(unsafe.Pointer(tree + uintptr(v)*4))) == int32(*(*Ush)(unsafe.Pointer(tree + uintptr(*(*int32)(unsafe.Pointer(s + 3008 + uintptr(j)*4)))*4))) && int32(*(*Uch)(unsafe.Pointer(s + 5308 + uintptr(v)))) <= int32(*(*Uch)(unsafe.Pointer(s + 5308 + uintptr(*(*int32)(unsafe.Pointer(s + 3008 + uintptr(j)*4)))))) {
 16163  			break
 16164  		}
 16165  
 16166  		// Exchange v with the smallest son
 16167  		*(*int32)(unsafe.Pointer(s + 3008 + uintptr(k)*4)) = *(*int32)(unsafe.Pointer(s + 3008 + uintptr(j)*4))
 16168  		k = j
 16169  
 16170  		// And continue down the tree, setting j to the left son of k
 16171  		j <<= 1
 16172  	}
 16173  	*(*int32)(unsafe.Pointer(s + 3008 + uintptr(k)*4)) = v
 16174  }
 16175  
 16176  // ===========================================================================
 16177  // Compute the optimal bit lengths for a tree and update the total bit length
 16178  // for the current block.
 16179  // IN assertion: the fields freq and dad are set, heap[heap_max] and
 16180  //    above are the tree nodes sorted by increasing frequency.
 16181  // OUT assertions: the field len is set to the optimal bit length, the
 16182  //     array bl_count contains the frequencies for each bit length.
 16183  //     The length opt_len is updated; static_len is also updated if stree is
 16184  //     not null.
 16185  func gen_bitlen(tls *libc.TLS, s uintptr, desc uintptr) { /* trees.c:486:12: */
 16186  	var tree uintptr = (*Tree_desc)(unsafe.Pointer(desc)).Fdyn_tree
 16187  	var max_code int32 = (*Tree_desc)(unsafe.Pointer(desc)).Fmax_code
 16188  	var stree uintptr = (*Static_tree_desc)(unsafe.Pointer((*Tree_desc)(unsafe.Pointer(desc)).Fstat_desc)).Fstatic_tree
 16189  	var extra uintptr = (*Static_tree_desc)(unsafe.Pointer((*Tree_desc)(unsafe.Pointer(desc)).Fstat_desc)).Fextra_bits
 16190  	var base int32 = (*Static_tree_desc)(unsafe.Pointer((*Tree_desc)(unsafe.Pointer(desc)).Fstat_desc)).Fextra_base
 16191  	var max_length int32 = (*Static_tree_desc)(unsafe.Pointer((*Tree_desc)(unsafe.Pointer(desc)).Fstat_desc)).Fmax_length
 16192  	var h int32 // heap index
 16193  	var n int32
 16194  	var m int32            // iterate over the tree elements
 16195  	var bits int32         // bit length
 16196  	var xbits int32        // extra bits
 16197  	var f Ush              // frequency
 16198  	var overflow int32 = 0 // number of elements with bit length too large
 16199  
 16200  	for bits = 0; bits <= MAX_BITS; bits++ {
 16201  		*(*Ush)(unsafe.Pointer(s + 2976 + uintptr(bits)*2)) = Ush(0)
 16202  	}
 16203  
 16204  	// In a first pass, compute the optimal bit lengths (which may
 16205  	// overflow in the case of the bit length tree).
 16206  	*(*Ush)(unsafe.Pointer(tree + uintptr(*(*int32)(unsafe.Pointer(s + 3008 + uintptr((*Deflate_state)(unsafe.Pointer(s)).Fheap_max)*4)))*4 + 2)) = Ush(0) // root of the heap
 16207  
 16208  	for h = (*Deflate_state)(unsafe.Pointer(s)).Fheap_max + 1; h < 2*(LITERALS+1+LENGTH_CODES)+1; h++ {
 16209  		n = *(*int32)(unsafe.Pointer(s + 3008 + uintptr(h)*4))
 16210  		bits = int32(*(*Ush)(unsafe.Pointer(tree + uintptr(*(*Ush)(unsafe.Pointer(tree + uintptr(n)*4 + 2)))*4 + 2))) + 1
 16211  		if bits > max_length {
 16212  			bits = max_length
 16213  			overflow++
 16214  		}
 16215  		*(*Ush)(unsafe.Pointer(tree + uintptr(n)*4 + 2)) = Ush(bits)
 16216  		// We overwrite tree[n].Dad which is no longer needed
 16217  
 16218  		if n > max_code {
 16219  			continue
 16220  		} // not a leaf node
 16221  
 16222  		*(*Ush)(unsafe.Pointer(s + 2976 + uintptr(bits)*2))++
 16223  		xbits = 0
 16224  		if n >= base {
 16225  			xbits = *(*Intf)(unsafe.Pointer(extra + uintptr(n-base)*4))
 16226  		}
 16227  		f = *(*Ush)(unsafe.Pointer(tree + uintptr(n)*4))
 16228  		*(*Ulg)(unsafe.Pointer(s + 5912)) += Ulg(f) * Ulg(uint32(bits+xbits))
 16229  		if stree != 0 {
 16230  			*(*Ulg)(unsafe.Pointer(s + 5920)) += Ulg(f) * Ulg(uint32(int32(*(*Ush)(unsafe.Pointer(stree + uintptr(n)*4 + 2)))+xbits))
 16231  		}
 16232  	}
 16233  	if overflow == 0 {
 16234  		return
 16235  	}
 16236  
 16237  	// This happens for example on obj2 and pic of the Calgary corpus
 16238  
 16239  	// Find the first bit length which could increase:
 16240  	for ok := true; ok; ok = overflow > 0 {
 16241  		bits = max_length - 1
 16242  		for int32(*(*Ush)(unsafe.Pointer(s + 2976 + uintptr(bits)*2))) == 0 {
 16243  			bits--
 16244  		}
 16245  		*(*Ush)(unsafe.Pointer(s + 2976 + uintptr(bits)*2))--           // move one leaf down the tree
 16246  		*(*Ush)(unsafe.Pointer(s + 2976 + uintptr(bits+1)*2)) += Ush(2) // move one overflow item as its brother
 16247  		*(*Ush)(unsafe.Pointer(s + 2976 + uintptr(max_length)*2))--
 16248  		// The brother of the overflow item also moves one step up,
 16249  		// but this does not affect bl_count[max_length]
 16250  		overflow = overflow - 2
 16251  	}
 16252  
 16253  	// Now recompute all bit lengths, scanning in increasing frequency.
 16254  	// h is still equal to HEAP_SIZE. (It is simpler to reconstruct all
 16255  	// lengths instead of fixing only the wrong ones. This idea is taken
 16256  	// from 'ar' written by Haruhiko Okumura.)
 16257  	for bits = max_length; bits != 0; bits-- {
 16258  		n = int32(*(*Ush)(unsafe.Pointer(s + 2976 + uintptr(bits)*2)))
 16259  		for n != 0 {
 16260  			m = *(*int32)(unsafe.Pointer(s + 3008 + uintptr(libc.PreDecInt32(&h, 1))*4))
 16261  			if m > max_code {
 16262  				continue
 16263  			}
 16264  			if uint32(*(*Ush)(unsafe.Pointer(tree + uintptr(m)*4 + 2))) != uint32(bits) {
 16265  
 16266  				*(*Ulg)(unsafe.Pointer(s + 5912)) += (Ulg(bits) - Ulg(*(*Ush)(unsafe.Pointer(tree + uintptr(m)*4 + 2)))) * Ulg(*(*Ush)(unsafe.Pointer(tree + uintptr(m)*4)))
 16267  				*(*Ush)(unsafe.Pointer(tree + uintptr(m)*4 + 2)) = Ush(bits)
 16268  			}
 16269  			n--
 16270  		}
 16271  	}
 16272  }
 16273  
 16274  // ===========================================================================
 16275  // Generate the codes for a given tree and bit counts (which need not be
 16276  // optimal).
 16277  // IN assertion: the array bl_count contains the bit length statistics for
 16278  // the given tree and the field len is set for all tree elements.
 16279  // OUT assertion: the field code is set for all tree elements of non
 16280  //     zero code length.
 16281  func gen_codes(tls *libc.TLS, tree uintptr, max_code int32, bl_count uintptr) { /* trees.c:572:12: */
 16282  	bp := tls.Alloc(32)
 16283  	defer tls.Free(32)
 16284  
 16285  	// var next_code [16]Ush at bp, 32
 16286  	// next code value for each bit length
 16287  	var code uint32 = uint32(0) // running code value
 16288  	var bits int32              // bit index
 16289  	var n int32                 // code index
 16290  
 16291  	// The distribution counts are first used to generate the code values
 16292  	// without bit reversal.
 16293  	for bits = 1; bits <= MAX_BITS; bits++ {
 16294  		code = (code + uint32(*(*Ushf)(unsafe.Pointer(bl_count + uintptr(bits-1)*2)))) << 1
 16295  		*(*Ush)(unsafe.Pointer(bp + uintptr(bits)*2)) = Ush(code)
 16296  	}
 16297  	// Check that the bit counts in bl_count are consistent. The last code
 16298  	// must be all ones.
 16299  
 16300  	for n = 0; n <= max_code; n++ {
 16301  		var len int32 = int32(*(*Ush)(unsafe.Pointer(tree + uintptr(n)*4 + 2)))
 16302  		if len == 0 {
 16303  			continue
 16304  		}
 16305  		// Now reverse the bits
 16306  		*(*Ush)(unsafe.Pointer(tree + uintptr(n)*4)) = Ush(bi_reverse(tls, uint32(libc.PostIncUint16(&*(*Ush)(unsafe.Pointer(bp + uintptr(len)*2)), 1)), len))
 16307  
 16308  	}
 16309  }
 16310  
 16311  // ===========================================================================
 16312  // Construct one Huffman tree and assigns the code bit strings and lengths.
 16313  // Update the total bit length for the current block.
 16314  // IN assertion: the field freq is set for all tree elements.
 16315  // OUT assertions: the fields len and code are set to the optimal bit length
 16316  //     and corresponding code. The length opt_len is updated; static_len is
 16317  //     also updated if stree is not null. The field max_code is set.
 16318  func build_tree(tls *libc.TLS, s uintptr, desc uintptr) { /* trees.c:615:12: */
 16319  	var tree uintptr = (*Tree_desc)(unsafe.Pointer(desc)).Fdyn_tree
 16320  	var stree uintptr = (*Static_tree_desc)(unsafe.Pointer((*Tree_desc)(unsafe.Pointer(desc)).Fstat_desc)).Fstatic_tree
 16321  	var elems int32 = (*Static_tree_desc)(unsafe.Pointer((*Tree_desc)(unsafe.Pointer(desc)).Fstat_desc)).Felems
 16322  	var n int32
 16323  	var m int32             // iterate over heap elements
 16324  	var max_code int32 = -1 // largest code with non zero frequency
 16325  	var node int32          // new node being created
 16326  
 16327  	// Construct the initial heap, with least frequent element in
 16328  	// heap[SMALLEST]. The sons of heap[n] are heap[2*n] and heap[2*n+1].
 16329  	// heap[0] is not used.
 16330  	(*Deflate_state)(unsafe.Pointer(s)).Fheap_len = 0
 16331  	(*Deflate_state)(unsafe.Pointer(s)).Fheap_max = 2*(LITERALS+1+LENGTH_CODES) + 1
 16332  
 16333  	for n = 0; n < elems; n++ {
 16334  		if int32(*(*Ush)(unsafe.Pointer(tree + uintptr(n)*4))) != 0 {
 16335  			*(*int32)(unsafe.Pointer(s + 3008 + uintptr(libc.PreIncInt32(&(*Deflate_state)(unsafe.Pointer(s)).Fheap_len, 1))*4)) = libc.AssignInt32(&max_code, n)
 16336  			*(*Uch)(unsafe.Pointer(s + 5308 + uintptr(n))) = Uch(0)
 16337  		} else {
 16338  			*(*Ush)(unsafe.Pointer(tree + uintptr(n)*4 + 2)) = Ush(0)
 16339  		}
 16340  	}
 16341  
 16342  	// The pkzip format requires that at least one distance code exists,
 16343  	// and that at least one bit should be sent even if there is only one
 16344  	// possible code. So to avoid special checks later on we force at least
 16345  	// two codes of non zero frequency.
 16346  	for (*Deflate_state)(unsafe.Pointer(s)).Fheap_len < 2 {
 16347  		node = libc.AssignPtrInt32(s+3008+uintptr(libc.PreIncInt32(&(*Deflate_state)(unsafe.Pointer(s)).Fheap_len, 1))*4, func() int32 {
 16348  			if max_code < 2 {
 16349  				return libc.PreIncInt32(&max_code, 1)
 16350  			}
 16351  			return 0
 16352  		}())
 16353  		*(*Ush)(unsafe.Pointer(tree + uintptr(node)*4)) = Ush(1)
 16354  		*(*Uch)(unsafe.Pointer(s + 5308 + uintptr(node))) = Uch(0)
 16355  		(*Deflate_state)(unsafe.Pointer(s)).Fopt_len--
 16356  		if stree != 0 {
 16357  			*(*Ulg)(unsafe.Pointer(s + 5920)) -= Ulg(*(*Ush)(unsafe.Pointer(stree + uintptr(node)*4 + 2)))
 16358  		}
 16359  		// node is 0 or 1 so it does not have extra bits
 16360  	}
 16361  	(*Tree_desc)(unsafe.Pointer(desc)).Fmax_code = max_code
 16362  
 16363  	// The elements heap[heap_len/2+1 .. heap_len] are leaves of the tree,
 16364  	// establish sub-heaps of increasing lengths:
 16365  	for n = (*Deflate_state)(unsafe.Pointer(s)).Fheap_len / 2; n >= 1; n-- {
 16366  		pqdownheap(tls, s, tree, n)
 16367  	}
 16368  
 16369  	// Construct the Huffman tree by repeatedly combining the least two
 16370  	// frequent nodes.
 16371  	node = elems // next internal node of the tree
 16372  	for ok := true; ok; ok = (*Deflate_state)(unsafe.Pointer(s)).Fheap_len >= 2 {
 16373  		{
 16374  			n = *(*int32)(unsafe.Pointer(s + 3008 + 1*4))
 16375  			*(*int32)(unsafe.Pointer(s + 3008 + 1*4)) = *(*int32)(unsafe.Pointer(s + 3008 + uintptr(libc.PostDecInt32(&(*Deflate_state)(unsafe.Pointer(s)).Fheap_len, 1))*4))
 16376  			pqdownheap(tls, s, tree, SMALLEST)
 16377  		}
 16378  		// n = node of least frequency
 16379  		m = *(*int32)(unsafe.Pointer(s + 3008 + 1*4)) // m = node of next least frequency
 16380  
 16381  		*(*int32)(unsafe.Pointer(s + 3008 + uintptr(libc.PreDecInt32(&(*Deflate_state)(unsafe.Pointer(s)).Fheap_max, 1))*4)) = n // keep the nodes sorted by frequency
 16382  		*(*int32)(unsafe.Pointer(s + 3008 + uintptr(libc.PreDecInt32(&(*Deflate_state)(unsafe.Pointer(s)).Fheap_max, 1))*4)) = m
 16383  
 16384  		// Create a new node father of n and m
 16385  		*(*Ush)(unsafe.Pointer(tree + uintptr(node)*4)) = Ush(int32(*(*Ush)(unsafe.Pointer(tree + uintptr(n)*4))) + int32(*(*Ush)(unsafe.Pointer(tree + uintptr(m)*4))))
 16386  		*(*Uch)(unsafe.Pointer(s + 5308 + uintptr(node))) = Uch(func() int32 {
 16387  			if int32(*(*Uch)(unsafe.Pointer(s + 5308 + uintptr(n)))) >= int32(*(*Uch)(unsafe.Pointer(s + 5308 + uintptr(m)))) {
 16388  				return int32(*(*Uch)(unsafe.Pointer(s + 5308 + uintptr(n))))
 16389  			}
 16390  			return int32(*(*Uch)(unsafe.Pointer(s + 5308 + uintptr(m))))
 16391  		}() + 1)
 16392  		*(*Ush)(unsafe.Pointer(tree + uintptr(n)*4 + 2)) = libc.AssignPtrUint16(tree+uintptr(m)*4+2, Ush(node))
 16393  		// and insert the new node in the heap
 16394  		*(*int32)(unsafe.Pointer(s + 3008 + 1*4)) = libc.PostIncInt32(&node, 1)
 16395  		pqdownheap(tls, s, tree, SMALLEST)
 16396  
 16397  	}
 16398  
 16399  	*(*int32)(unsafe.Pointer(s + 3008 + uintptr(libc.PreDecInt32(&(*Deflate_state)(unsafe.Pointer(s)).Fheap_max, 1))*4)) = *(*int32)(unsafe.Pointer(s + 3008 + 1*4))
 16400  
 16401  	// At this point, the fields freq and dad are set. We can now
 16402  	// generate the bit lengths.
 16403  	gen_bitlen(tls, s, desc)
 16404  
 16405  	// The field len is now set, we can generate the bit codes
 16406  	gen_codes(tls, tree, max_code, s+2976)
 16407  }
 16408  
 16409  // ===========================================================================
 16410  // Scan a literal or distance tree to determine the frequencies of the codes
 16411  // in the bit length tree.
 16412  func scan_tree(tls *libc.TLS, s uintptr, tree uintptr, max_code int32) { /* trees.c:703:12: */
 16413  	var n int32                                                  // iterates over all tree elements
 16414  	var prevlen int32 = -1                                       // last emitted length
 16415  	var curlen int32                                             // length of current code
 16416  	var nextlen int32 = int32(*(*Ush)(unsafe.Pointer(tree + 2))) // length of next code
 16417  	var count int32 = 0                                          // repeat count of the current code
 16418  	var max_count int32 = 7                                      // max repeat count
 16419  	var min_count int32 = 4                                      // min repeat count
 16420  
 16421  	if nextlen == 0 {
 16422  		max_count = 138
 16423  		min_count = 3
 16424  	}
 16425  	*(*Ush)(unsafe.Pointer(tree + uintptr(max_code+1)*4 + 2)) = Ush(0xffff) // guard
 16426  
 16427  	for n = 0; n <= max_code; n++ {
 16428  		curlen = nextlen
 16429  		nextlen = int32(*(*Ush)(unsafe.Pointer(tree + uintptr(n+1)*4 + 2)))
 16430  		if libc.PreIncInt32(&count, 1) < max_count && curlen == nextlen {
 16431  			continue
 16432  		} else if count < min_count {
 16433  			*(*Ush)(unsafe.Pointer(s + 2748 + uintptr(curlen)*4)) += Ush(count)
 16434  		} else if curlen != 0 {
 16435  			if curlen != prevlen {
 16436  				*(*Ush)(unsafe.Pointer(s + 2748 + uintptr(curlen)*4))++
 16437  			}
 16438  			*(*Ush)(unsafe.Pointer(s + 2748 + 16*4))++
 16439  		} else if count <= 10 {
 16440  			*(*Ush)(unsafe.Pointer(s + 2748 + 17*4))++
 16441  		} else {
 16442  			*(*Ush)(unsafe.Pointer(s + 2748 + 18*4))++
 16443  		}
 16444  		count = 0
 16445  		prevlen = curlen
 16446  		if nextlen == 0 {
 16447  			max_count = 138
 16448  			min_count = 3
 16449  		} else if curlen == nextlen {
 16450  			max_count = 6
 16451  			min_count = 3
 16452  		} else {
 16453  			max_count = 7
 16454  			min_count = 4
 16455  		}
 16456  	}
 16457  }
 16458  
 16459  // ===========================================================================
 16460  // Send a literal or distance tree in compressed form, using the codes in
 16461  // bl_tree.
 16462  func send_tree(tls *libc.TLS, s uintptr, tree uintptr, max_code int32) { /* trees.c:748:12: */
 16463  	var n int32                                                  // iterates over all tree elements
 16464  	var prevlen int32 = -1                                       // last emitted length
 16465  	var curlen int32                                             // length of current code
 16466  	var nextlen int32 = int32(*(*Ush)(unsafe.Pointer(tree + 2))) // length of next code
 16467  	var count int32 = 0                                          // repeat count of the current code
 16468  	var max_count int32 = 7                                      // max repeat count
 16469  	var min_count int32 = 4                                      // min repeat count
 16470  
 16471  	/* tree[max_code+1].Len = -1; */ // guard already set
 16472  	if nextlen == 0 {
 16473  		max_count = 138
 16474  		min_count = 3
 16475  	}
 16476  
 16477  	for n = 0; n <= max_code; n++ {
 16478  		curlen = nextlen
 16479  		nextlen = int32(*(*Ush)(unsafe.Pointer(tree + uintptr(n+1)*4 + 2)))
 16480  		if libc.PreIncInt32(&count, 1) < max_count && curlen == nextlen {
 16481  			continue
 16482  		} else if count < min_count {
 16483  			for ok := true; ok; ok = libc.PreDecInt32(&count, 1) != 0 {
 16484  				{
 16485  					var len int32 = int32(*(*Ush)(unsafe.Pointer(s + 2748 + uintptr(curlen)*4 + 2)))
 16486  					if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16487  						var val int32 = int32(*(*Ush)(unsafe.Pointer(s + 2748 + uintptr(curlen)*4)))
 16488  						*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16489  						{
 16490  							{
 16491  								*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16492  							}
 16493  							{
 16494  								*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16495  							}
 16496  
 16497  						}
 16498  						(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16499  						*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16500  					} else {
 16501  						*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(*(*Ush)(unsafe.Pointer(s + 2748 + uintptr(curlen)*4))) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16502  						*(*int32)(unsafe.Pointer(s + 5940)) += len
 16503  					}
 16504  				}
 16505  			}
 16506  
 16507  		} else if curlen != 0 {
 16508  			if curlen != prevlen {
 16509  				{
 16510  					var len int32 = int32(*(*Ush)(unsafe.Pointer(s + 2748 + uintptr(curlen)*4 + 2)))
 16511  					if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16512  						var val int32 = int32(*(*Ush)(unsafe.Pointer(s + 2748 + uintptr(curlen)*4)))
 16513  						*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16514  						{
 16515  							{
 16516  								*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16517  							}
 16518  							{
 16519  								*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16520  							}
 16521  
 16522  						}
 16523  						(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16524  						*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16525  					} else {
 16526  						*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(*(*Ush)(unsafe.Pointer(s + 2748 + uintptr(curlen)*4))) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16527  						*(*int32)(unsafe.Pointer(s + 5940)) += len
 16528  					}
 16529  				}
 16530  				count--
 16531  			}
 16532  
 16533  			{
 16534  				var len int32 = int32(*(*Ush)(unsafe.Pointer(s + 2748 + 16*4 + 2)))
 16535  				if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16536  					var val int32 = int32(*(*Ush)(unsafe.Pointer(s + 2748 + 16*4)))
 16537  					*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16538  					{
 16539  						{
 16540  							*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16541  						}
 16542  						{
 16543  							*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16544  						}
 16545  
 16546  					}
 16547  					(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16548  					*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16549  				} else {
 16550  					*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(*(*Ush)(unsafe.Pointer(s + 2748 + 16*4))) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16551  					*(*int32)(unsafe.Pointer(s + 5940)) += len
 16552  				}
 16553  			}
 16554  			{
 16555  				var len int32 = 2
 16556  				if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16557  					var val int32 = count - 3
 16558  					*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16559  					{
 16560  						{
 16561  							*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16562  						}
 16563  						{
 16564  							*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16565  						}
 16566  
 16567  					}
 16568  					(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16569  					*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16570  				} else {
 16571  					*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(count-3)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16572  					*(*int32)(unsafe.Pointer(s + 5940)) += len
 16573  				}
 16574  			}
 16575  
 16576  		} else if count <= 10 {
 16577  			{
 16578  				var len int32 = int32(*(*Ush)(unsafe.Pointer(s + 2748 + 17*4 + 2)))
 16579  				if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16580  					var val int32 = int32(*(*Ush)(unsafe.Pointer(s + 2748 + 17*4)))
 16581  					*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16582  					{
 16583  						{
 16584  							*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16585  						}
 16586  						{
 16587  							*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16588  						}
 16589  
 16590  					}
 16591  					(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16592  					*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16593  				} else {
 16594  					*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(*(*Ush)(unsafe.Pointer(s + 2748 + 17*4))) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16595  					*(*int32)(unsafe.Pointer(s + 5940)) += len
 16596  				}
 16597  			}
 16598  			{
 16599  				var len int32 = 3
 16600  				if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16601  					var val int32 = count - 3
 16602  					*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16603  					{
 16604  						{
 16605  							*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16606  						}
 16607  						{
 16608  							*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16609  						}
 16610  
 16611  					}
 16612  					(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16613  					*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16614  				} else {
 16615  					*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(count-3)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16616  					*(*int32)(unsafe.Pointer(s + 5940)) += len
 16617  				}
 16618  			}
 16619  
 16620  		} else {
 16621  			{
 16622  				var len int32 = int32(*(*Ush)(unsafe.Pointer(s + 2748 + 18*4 + 2)))
 16623  				if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16624  					var val int32 = int32(*(*Ush)(unsafe.Pointer(s + 2748 + 18*4)))
 16625  					*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16626  					{
 16627  						{
 16628  							*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16629  						}
 16630  						{
 16631  							*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16632  						}
 16633  
 16634  					}
 16635  					(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16636  					*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16637  				} else {
 16638  					*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(*(*Ush)(unsafe.Pointer(s + 2748 + 18*4))) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16639  					*(*int32)(unsafe.Pointer(s + 5940)) += len
 16640  				}
 16641  			}
 16642  			{
 16643  				var len int32 = 7
 16644  				if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16645  					var val int32 = count - 11
 16646  					*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16647  					{
 16648  						{
 16649  							*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16650  						}
 16651  						{
 16652  							*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16653  						}
 16654  
 16655  					}
 16656  					(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16657  					*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16658  				} else {
 16659  					*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(count-11)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16660  					*(*int32)(unsafe.Pointer(s + 5940)) += len
 16661  				}
 16662  			}
 16663  
 16664  		}
 16665  		count = 0
 16666  		prevlen = curlen
 16667  		if nextlen == 0 {
 16668  			max_count = 138
 16669  			min_count = 3
 16670  		} else if curlen == nextlen {
 16671  			max_count = 6
 16672  			min_count = 3
 16673  		} else {
 16674  			max_count = 7
 16675  			min_count = 4
 16676  		}
 16677  	}
 16678  }
 16679  
 16680  // ===========================================================================
 16681  // Construct the Huffman tree for the bit lengths and return the index in
 16682  // bl_order of the last bit length code to send.
 16683  func build_bl_tree(tls *libc.TLS, s uintptr) int32 { /* trees.c:799:11: */
 16684  	var max_blindex int32 // index of last bit length code of non zero freq
 16685  
 16686  	// Determine the bit length frequencies for literal and distance trees
 16687  	scan_tree(tls, s, s+212 /* &.dyn_ltree */, (*Deflate_state)(unsafe.Pointer(s)).Fl_desc.Fmax_code)
 16688  	scan_tree(tls, s, s+2504 /* &.dyn_dtree */, (*Deflate_state)(unsafe.Pointer(s)).Fd_desc.Fmax_code)
 16689  
 16690  	// Build the bit length tree:
 16691  	build_tree(tls, s, s+2952)
 16692  	// opt_len now includes the length of the tree representations, except
 16693  	// the lengths of the bit lengths codes and the 5+5+4 bits for the counts.
 16694  
 16695  	// Determine the number of bit length codes to send. The pkzip format
 16696  	// requires that at least 4 bit length codes be sent. (appnote.txt says
 16697  	// 3 but the actual value used is 4.)
 16698  	for max_blindex = BL_CODES - 1; max_blindex >= 3; max_blindex-- {
 16699  		if int32(*(*Ush)(unsafe.Pointer(s + 2748 + uintptr(bl_order[max_blindex])*4 + 2))) != 0 {
 16700  			break
 16701  		}
 16702  	}
 16703  	// Update opt_len to include the bit length tree and counts
 16704  	*(*Ulg)(unsafe.Pointer(s + 5912)) += uint64(3)*(Ulg(max_blindex)+uint64(1)) + uint64(5) + uint64(5) + uint64(4)
 16705  
 16706  	return max_blindex
 16707  }
 16708  
 16709  // ===========================================================================
 16710  // Send the header for a block using dynamic Huffman trees: the counts, the
 16711  // lengths of the bit length codes, the literal tree and the distance tree.
 16712  // IN assertion: lcodes >= 257, dcodes >= 1, blcodes >= 4.
 16713  func send_all_trees(tls *libc.TLS, s uintptr, lcodes int32, dcodes int32, blcodes int32) { /* trees.c:834:12: */
 16714  	var rank int32 // index in bl_order
 16715  
 16716  	{
 16717  		var len int32 = 5
 16718  		if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16719  			var val int32 = lcodes - 257
 16720  			*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16721  			{
 16722  				{
 16723  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16724  				}
 16725  				{
 16726  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16727  				}
 16728  
 16729  			}
 16730  			(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16731  			*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16732  		} else {
 16733  			*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(lcodes-257)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16734  			*(*int32)(unsafe.Pointer(s + 5940)) += len
 16735  		}
 16736  	}
 16737  	/* not +255 as stated in appnote.txt */
 16738  	{
 16739  		var len int32 = 5
 16740  		if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16741  			var val int32 = dcodes - 1
 16742  			*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16743  			{
 16744  				{
 16745  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16746  				}
 16747  				{
 16748  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16749  				}
 16750  
 16751  			}
 16752  			(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16753  			*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16754  		} else {
 16755  			*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(dcodes-1)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16756  			*(*int32)(unsafe.Pointer(s + 5940)) += len
 16757  		}
 16758  	}
 16759  
 16760  	{
 16761  		var len int32 = 4
 16762  		if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16763  			var val int32 = blcodes - 4
 16764  			*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16765  			{
 16766  				{
 16767  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16768  				}
 16769  				{
 16770  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16771  				}
 16772  
 16773  			}
 16774  			(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16775  			*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16776  		} else {
 16777  			*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(blcodes-4)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16778  			*(*int32)(unsafe.Pointer(s + 5940)) += len
 16779  		}
 16780  	}
 16781  	// not -3 as stated in appnote.txt
 16782  	for rank = 0; rank < blcodes; rank++ {
 16783  
 16784  		{
 16785  			var len int32 = 3
 16786  			if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16787  				var val int32 = int32(*(*Ush)(unsafe.Pointer(s + 2748 + uintptr(bl_order[rank])*4 + 2)))
 16788  				*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16789  				{
 16790  					{
 16791  						*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16792  					}
 16793  					{
 16794  						*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16795  					}
 16796  
 16797  				}
 16798  				(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16799  				*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16800  			} else {
 16801  				*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(*(*Ush)(unsafe.Pointer(s + 2748 + uintptr(bl_order[rank])*4 + 2))) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16802  				*(*int32)(unsafe.Pointer(s + 5940)) += len
 16803  			}
 16804  		}
 16805  
 16806  	}
 16807  
 16808  	send_tree(tls, s, s+212 /* &.dyn_ltree */, lcodes-1) // literal tree
 16809  
 16810  	send_tree(tls, s, s+2504 /* &.dyn_dtree */, dcodes-1) // distance tree
 16811  
 16812  }
 16813  
 16814  // ===========================================================================
 16815  // Send a stored block
 16816  func X_tr_stored_block(tls *libc.TLS, s uintptr, buf uintptr, stored_len Ulg, last int32) { /* trees.c:863:20: */
 16817  	{
 16818  		var len int32 = 3
 16819  		if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16820  			var val int32 = int32(STORED_BLOCK)<<1 + last
 16821  			*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16822  			{
 16823  				{
 16824  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16825  				}
 16826  				{
 16827  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16828  				}
 16829  
 16830  			}
 16831  			(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16832  			*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16833  		} else {
 16834  			*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(int32(STORED_BLOCK)<<1+last)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16835  			*(*int32)(unsafe.Pointer(s + 5940)) += len
 16836  		}
 16837  	}
 16838  	// send block type
 16839  	bi_windup(tls, s) /* align on byte boundary */
 16840  	{
 16841  		{
 16842  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32(Ush(stored_len)) & 0xff)
 16843  		}
 16844  		{
 16845  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32(Ush(stored_len)) >> 8)
 16846  		}
 16847  
 16848  	}
 16849  
 16850  	{
 16851  		{
 16852  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32(Ush(^stored_len)) & 0xff)
 16853  		}
 16854  		{
 16855  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32(Ush(^stored_len)) >> 8)
 16856  		}
 16857  
 16858  	}
 16859  
 16860  	libc.Xmemcpy(tls, (*Deflate_state)(unsafe.Pointer(s)).Fpending_buf+uintptr((*Deflate_state)(unsafe.Pointer(s)).Fpending), buf, stored_len)
 16861  	*(*Ulg)(unsafe.Pointer(s + 40)) += stored_len
 16862  }
 16863  
 16864  // ===========================================================================
 16865  // Flush the bits in the bit buffer to pending output (leaves at most 7 bits)
 16866  func X_tr_flush_bits(tls *libc.TLS, s uintptr) { /* trees.c:886:20: */
 16867  	bi_flush(tls, s)
 16868  }
 16869  
 16870  // ===========================================================================
 16871  // Send one empty static block to give enough lookahead for inflate.
 16872  // This takes 10 bits, of which 7 may remain in the bit buffer.
 16873  func X_tr_align(tls *libc.TLS, s uintptr) { /* trees.c:896:20: */
 16874  	{
 16875  		var len int32 = 3
 16876  		if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16877  			var val int32 = int32(STATIC_TREES) << 1
 16878  			*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16879  			{
 16880  				{
 16881  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16882  				}
 16883  				{
 16884  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16885  				}
 16886  
 16887  			}
 16888  			(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16889  			*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16890  		} else {
 16891  			*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(int32(Ush(int32(STATIC_TREES)<<1))) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16892  			*(*int32)(unsafe.Pointer(s + 5940)) += len
 16893  		}
 16894  	}
 16895  
 16896  	{
 16897  		var len int32 = int32(*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&static_ltree)) + 256*4 + 2)))
 16898  		if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16899  			var val int32 = int32(*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&static_ltree)) + 256*4)))
 16900  			*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16901  			{
 16902  				{
 16903  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16904  				}
 16905  				{
 16906  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16907  				}
 16908  
 16909  			}
 16910  			(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16911  			*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16912  		} else {
 16913  			*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(*(*Ush)(unsafe.Pointer(uintptr(unsafe.Pointer(&static_ltree)) + 256*4))) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16914  			*(*int32)(unsafe.Pointer(s + 5940)) += len
 16915  		}
 16916  	}
 16917  
 16918  	bi_flush(tls, s)
 16919  }
 16920  
 16921  // ===========================================================================
 16922  // Determine the best encoding for the current block: dynamic trees, static
 16923  // trees or store, and write out the encoded block.
 16924  func X_tr_flush_block(tls *libc.TLS, s uintptr, buf uintptr, stored_len Ulg, last int32) { /* trees.c:911:20: */
 16925  	var opt_lenb Ulg
 16926  	var static_lenb Ulg       // opt_len and static_len in bytes
 16927  	var max_blindex int32 = 0 // index of last bit length code of non zero freq
 16928  
 16929  	// Build the Huffman trees unless a stored block is forced
 16930  	if (*Deflate_state)(unsafe.Pointer(s)).Flevel > 0 {
 16931  
 16932  		// Check if the file is binary or text
 16933  		if (*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Fdata_type == Z_UNKNOWN {
 16934  			(*Z_stream)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fstrm)).Fdata_type = detect_data_type(tls, s)
 16935  		}
 16936  
 16937  		// Construct the literal and distance trees
 16938  		build_tree(tls, s, s+2904)
 16939  
 16940  		build_tree(tls, s, s+2928)
 16941  
 16942  		// At this point, opt_len and static_len are the total bit lengths of
 16943  		// the compressed block data, excluding the tree representations.
 16944  
 16945  		// Build the bit length tree for the above two trees, and get the index
 16946  		// in bl_order of the last bit length code to send.
 16947  		max_blindex = build_bl_tree(tls, s)
 16948  
 16949  		// Determine the best encoding. Compute the block lengths in bytes.
 16950  		opt_lenb = ((*Deflate_state)(unsafe.Pointer(s)).Fopt_len + uint64(3) + uint64(7)) >> 3
 16951  		static_lenb = ((*Deflate_state)(unsafe.Pointer(s)).Fstatic_len + uint64(3) + uint64(7)) >> 3
 16952  
 16953  		if static_lenb <= opt_lenb {
 16954  			opt_lenb = static_lenb
 16955  		}
 16956  
 16957  	} else {
 16958  
 16959  		opt_lenb = libc.AssignUint64(&static_lenb, stored_len+uint64(5)) // force a stored block
 16960  	}
 16961  
 16962  	if stored_len+uint64(4) <= opt_lenb && buf != uintptr(0) {
 16963  		// 4: two words for the lengths
 16964  		// The test buf != NULL is only necessary if LIT_BUFSIZE > WSIZE.
 16965  		// Otherwise we can't have processed more than WSIZE input bytes since
 16966  		// the last block flush, because compression would have been
 16967  		// successful. If LIT_BUFSIZE <= WSIZE, it is never too late to
 16968  		// transform a block into a stored block.
 16969  		X_tr_stored_block(tls, s, buf, stored_len, last)
 16970  
 16971  	} else if (*Deflate_state)(unsafe.Pointer(s)).Fstrategy == Z_FIXED || static_lenb == opt_lenb {
 16972  		{
 16973  			var len int32 = 3
 16974  			if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 16975  				var val int32 = int32(STATIC_TREES)<<1 + last
 16976  				*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16977  				{
 16978  					{
 16979  						*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 16980  					}
 16981  					{
 16982  						*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 16983  					}
 16984  
 16985  				}
 16986  				(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 16987  				*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 16988  			} else {
 16989  				*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(int32(STATIC_TREES)<<1+last)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 16990  				*(*int32)(unsafe.Pointer(s + 5940)) += len
 16991  			}
 16992  		}
 16993  
 16994  		compress_block(tls, s, uintptr(uintptr(unsafe.Pointer(&static_ltree))),
 16995  			uintptr(uintptr(unsafe.Pointer(&static_dtree))))
 16996  	} else {
 16997  		{
 16998  			var len int32 = 3
 16999  			if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 17000  				var val int32 = int32(DYN_TREES)<<1 + last
 17001  				*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 17002  				{
 17003  					{
 17004  						*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 17005  					}
 17006  					{
 17007  						*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 17008  					}
 17009  
 17010  				}
 17011  				(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 17012  				*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 17013  			} else {
 17014  				*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(int32(DYN_TREES)<<1+last)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 17015  				*(*int32)(unsafe.Pointer(s + 5940)) += len
 17016  			}
 17017  		}
 17018  
 17019  		send_all_trees(tls, s, (*Deflate_state)(unsafe.Pointer(s)).Fl_desc.Fmax_code+1, (*Deflate_state)(unsafe.Pointer(s)).Fd_desc.Fmax_code+1,
 17020  			max_blindex+1)
 17021  		compress_block(tls, s, s+212, /* &.dyn_ltree */
 17022  			s+2504 /* &.dyn_dtree */)
 17023  	}
 17024  
 17025  	// The above check is made mod 2^32, for files larger than 512 MB
 17026  	// and uLong implemented on 32 bits.
 17027  	init_block(tls, s)
 17028  
 17029  	if last != 0 {
 17030  		bi_windup(tls, s)
 17031  	}
 17032  
 17033  }
 17034  
 17035  // ===========================================================================
 17036  // Save the match info and tally the frequency counts. Return true if
 17037  // the current block must be flushed.
 17038  func X_tr_tally(tls *libc.TLS, s uintptr, dist uint32, lc uint32) int32 { /* trees.c:1014:19: */
 17039  	*(*Ushf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fd_buf + uintptr((*Deflate_state)(unsafe.Pointer(s)).Flast_lit)*2)) = Ush(dist)
 17040  	*(*Uchf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fl_buf + uintptr(libc.PostIncUint32(&(*Deflate_state)(unsafe.Pointer(s)).Flast_lit, 1)))) = Uch(lc)
 17041  	if dist == uint32(0) {
 17042  		// lc is the unmatched char
 17043  		*(*Ush)(unsafe.Pointer(s + 212 + uintptr(lc)*4))++
 17044  	} else {
 17045  		(*Deflate_state)(unsafe.Pointer(s)).Fmatches++
 17046  		// Here, lc is the match length - MIN_MATCH
 17047  		dist-- // dist = match distance - 1
 17048  
 17049  		*(*Ush)(unsafe.Pointer(s + 212 + uintptr(int32(X_length_code[lc])+LITERALS+1)*4))++
 17050  		*(*Ush)(unsafe.Pointer(s + 2504 + uintptr(func() int32 {
 17051  			if dist < uint32(256) {
 17052  				return int32(X_dist_code[dist])
 17053  			}
 17054  			return int32(X_dist_code[uint32(256)+dist>>7])
 17055  		}())*4))++
 17056  	}
 17057  
 17058  	return libc.Bool32((*Deflate_state)(unsafe.Pointer(s)).Flast_lit == (*Deflate_state)(unsafe.Pointer(s)).Flit_bufsize-UInt(1))
 17059  	// We avoid equality with lit_bufsize because of wraparound at 64K
 17060  	// on 16 bit machines and because stored blocks are restricted to
 17061  	// 64K-1 bytes.
 17062  }
 17063  
 17064  // ===========================================================================
 17065  // Send the block data compressed using the given Huffman trees
 17066  func compress_block(tls *libc.TLS, s uintptr, ltree uintptr, dtree uintptr) { /* trees.c:1064:12: */
 17067  	var dist uint32           // distance of matched string
 17068  	var lc int32              // match length or unmatched char (if dist == 0)
 17069  	var lx uint32 = uint32(0) // running index in l_buf
 17070  	var code uint32           // the code to send
 17071  	var extra int32           // number of extra bits to send
 17072  
 17073  	if (*Deflate_state)(unsafe.Pointer(s)).Flast_lit != UInt(0) {
 17074  		for ok := true; ok; ok = lx < (*Deflate_state)(unsafe.Pointer(s)).Flast_lit {
 17075  			dist = uint32(*(*Ushf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fd_buf + uintptr(lx)*2)))
 17076  			lc = int32(*(*Uchf)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fl_buf + uintptr(libc.PostIncUint32(&lx, 1)))))
 17077  			if dist == uint32(0) {
 17078  				{
 17079  					var len int32 = int32(*(*Ush)(unsafe.Pointer(ltree + uintptr(lc)*4 + 2)))
 17080  					if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 17081  						var val int32 = int32(*(*Ush)(unsafe.Pointer(ltree + uintptr(lc)*4)))
 17082  						*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 17083  						{
 17084  							{
 17085  								*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 17086  							}
 17087  							{
 17088  								*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 17089  							}
 17090  
 17091  						}
 17092  						(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 17093  						*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 17094  					} else {
 17095  						*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(*(*Ush)(unsafe.Pointer(ltree + uintptr(lc)*4))) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 17096  						*(*int32)(unsafe.Pointer(s + 5940)) += len
 17097  					}
 17098  				}
 17099  				// send a literal byte
 17100  
 17101  			} else {
 17102  				// Here, lc is the match length - MIN_MATCH
 17103  				code = uint32(X_length_code[lc])
 17104  				{
 17105  					var len int32 = int32(*(*Ush)(unsafe.Pointer(ltree + uintptr(code+uint32(LITERALS)+uint32(1))*4 + 2)))
 17106  					if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 17107  						var val int32 = int32(*(*Ush)(unsafe.Pointer(ltree + uintptr(code+uint32(LITERALS)+uint32(1))*4)))
 17108  						*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 17109  						{
 17110  							{
 17111  								*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 17112  							}
 17113  							{
 17114  								*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 17115  							}
 17116  
 17117  						}
 17118  						(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 17119  						*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 17120  					} else {
 17121  						*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(*(*Ush)(unsafe.Pointer(ltree + uintptr(code+uint32(LITERALS)+uint32(1))*4))) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 17122  						*(*int32)(unsafe.Pointer(s + 5940)) += len
 17123  					}
 17124  				}
 17125  				// send the length code
 17126  				extra = extra_lbits[code]
 17127  				if extra != 0 {
 17128  					lc = lc - base_length[code]
 17129  					{
 17130  						var len int32 = extra
 17131  						if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 17132  							var val int32 = lc
 17133  							*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 17134  							{
 17135  								{
 17136  									*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 17137  								}
 17138  								{
 17139  									*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 17140  								}
 17141  
 17142  							}
 17143  							(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 17144  							*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 17145  						} else {
 17146  							*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(lc)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 17147  							*(*int32)(unsafe.Pointer(s + 5940)) += len
 17148  						}
 17149  					}
 17150  					// send the extra length bits
 17151  				}
 17152  				dist-- // dist is now the match distance - 1
 17153  				code = func() uint32 {
 17154  					if dist < uint32(256) {
 17155  						return uint32(X_dist_code[dist])
 17156  					}
 17157  					return uint32(X_dist_code[uint32(256)+dist>>7])
 17158  				}()
 17159  
 17160  				{
 17161  					var len int32 = int32(*(*Ush)(unsafe.Pointer(dtree + uintptr(code)*4 + 2)))
 17162  					if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 17163  						var val int32 = int32(*(*Ush)(unsafe.Pointer(dtree + uintptr(code)*4)))
 17164  						*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 17165  						{
 17166  							{
 17167  								*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 17168  							}
 17169  							{
 17170  								*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 17171  							}
 17172  
 17173  						}
 17174  						(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 17175  						*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 17176  					} else {
 17177  						*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(*(*Ush)(unsafe.Pointer(dtree + uintptr(code)*4))) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 17178  						*(*int32)(unsafe.Pointer(s + 5940)) += len
 17179  					}
 17180  				}
 17181  				// send the distance code
 17182  				extra = extra_dbits[code]
 17183  				if extra != 0 {
 17184  					dist = dist - uint32(base_dist[code])
 17185  					{
 17186  						var len int32 = extra
 17187  						if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 17188  							var val int32 = int32(dist)
 17189  							*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 17190  							{
 17191  								{
 17192  									*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 17193  								}
 17194  								{
 17195  									*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 17196  								}
 17197  
 17198  							}
 17199  							(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 17200  							*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 17201  						} else {
 17202  							*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(dist)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 17203  							*(*int32)(unsafe.Pointer(s + 5940)) += len
 17204  						}
 17205  					}
 17206  					// send the extra distance bits
 17207  				}
 17208  			} // literal or match pair ?
 17209  
 17210  			// Check that the overlay between pending_buf and d_buf+l_buf is ok:
 17211  
 17212  		}
 17213  	}
 17214  
 17215  	{
 17216  		var len int32 = int32(*(*Ush)(unsafe.Pointer(ltree + 256*4 + 2)))
 17217  		if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > Buf_size-len {
 17218  			var val int32 = int32(*(*Ush)(unsafe.Pointer(ltree + 256*4)))
 17219  			*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(Ush(val)) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 17220  			{
 17221  				{
 17222  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 17223  				}
 17224  				{
 17225  					*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 17226  				}
 17227  
 17228  			}
 17229  			(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(int32(Ush(val)) >> (Buf_size - (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid))
 17230  			*(*int32)(unsafe.Pointer(s + 5940)) += len - Buf_size
 17231  		} else {
 17232  			*(*Ush)(unsafe.Pointer(s + 5936)) |= Ush(int32(*(*Ush)(unsafe.Pointer(ltree + 256*4))) << (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid)
 17233  			*(*int32)(unsafe.Pointer(s + 5940)) += len
 17234  		}
 17235  	}
 17236  
 17237  }
 17238  
 17239  // ===========================================================================
 17240  // Check if the data type is TEXT or BINARY, using the following algorithm:
 17241  // - TEXT if the two conditions below are satisfied:
 17242  //    a) There are no non-portable control characters belonging to the
 17243  //       "black list" (0..6, 14..25, 28..31).
 17244  //    b) There is at least one printable character belonging to the
 17245  //       "white list" (9 {TAB}, 10 {LF}, 13 {CR}, 32..255).
 17246  // - BINARY otherwise.
 17247  // - The following partially-portable control characters form a
 17248  //   "gray list" that is ignored in this detection algorithm:
 17249  //   (7 {BEL}, 8 {BS}, 11 {VT}, 12 {FF}, 26 {SUB}, 27 {ESC}).
 17250  // IN assertion: the fields Freq of dyn_ltree are set.
 17251  func detect_data_type(tls *libc.TLS, s uintptr) int32 { /* trees.c:1124:11: */
 17252  	// black_mask is the bit mask of black-listed bytes
 17253  	// set bits 0..6, 14..25, and 28..31
 17254  	// 0xf3ffc07f = binary 11110011111111111100000001111111
 17255  	var black_mask uint64 = 0xf3ffc07f
 17256  	var n int32
 17257  
 17258  	// Check for non-textual ("black-listed") bytes.
 17259  	n = 0
 17260  __1:
 17261  	if !(n <= 31) {
 17262  		goto __3
 17263  	}
 17264  	if black_mask&uint64(1) != 0 && int32(*(*Ush)(unsafe.Pointer(s + 212 + uintptr(n)*4))) != 0 {
 17265  		return Z_BINARY
 17266  	}
 17267  	goto __2
 17268  __2:
 17269  	n++
 17270  	black_mask >>= 1
 17271  	goto __1
 17272  	goto __3
 17273  __3:
 17274  	;
 17275  
 17276  	// Check for textual ("white-listed") bytes.
 17277  	if int32(*(*Ush)(unsafe.Pointer(s + 212 + 9*4))) != 0 || int32(*(*Ush)(unsafe.Pointer(s + 212 + 10*4))) != 0 ||
 17278  		int32(*(*Ush)(unsafe.Pointer(s + 212 + 13*4))) != 0 {
 17279  		return Z_TEXT
 17280  	}
 17281  	for n = 32; n < LITERALS; n++ {
 17282  		if int32(*(*Ush)(unsafe.Pointer(s + 212 + uintptr(n)*4))) != 0 {
 17283  			return Z_TEXT
 17284  		}
 17285  	}
 17286  
 17287  	// There are no "black-listed" or "white-listed" bytes:
 17288  	// this stream either is empty or has tolerated ("gray-listed") bytes only.
 17289  	return Z_BINARY
 17290  }
 17291  
 17292  // ===========================================================================
 17293  // Reverse the first len bits of a code, using straightforward code (a faster
 17294  // method would use a table)
 17295  // IN assertion: 1 <= len <= 15
 17296  func bi_reverse(tls *libc.TLS, code uint32, len int32) uint32 { /* trees.c:1158:16: */
 17297  	var res uint32 = uint32(0)
 17298  	for ok := true; ok; ok = libc.PreDecInt32(&len, 1) > 0 {
 17299  		res = res | code&uint32(1)
 17300  		code >>= 1
 17301  		res <<= 1
 17302  	}
 17303  	return res >> 1
 17304  }
 17305  
 17306  // ===========================================================================
 17307  // Flush the bit buffer, keeping at most 7 bits in it.
 17308  func bi_flush(tls *libc.TLS, s uintptr) { /* trees.c:1173:12: */
 17309  	if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid == 16 {
 17310  		{
 17311  			{
 17312  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 17313  			}
 17314  			{
 17315  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 17316  			}
 17317  
 17318  		}
 17319  
 17320  		(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(0)
 17321  		(*Deflate_state)(unsafe.Pointer(s)).Fbi_valid = 0
 17322  	} else if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid >= 8 {
 17323  		{
 17324  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf)
 17325  		}
 17326  
 17327  		libc.AssignShrPtrUint16(s+5936, int(8))
 17328  		*(*int32)(unsafe.Pointer(s + 5940)) -= 8
 17329  	}
 17330  }
 17331  
 17332  // ===========================================================================
 17333  // Flush the bit buffer and align the output on a byte boundary
 17334  func bi_windup(tls *libc.TLS, s uintptr) { /* trees.c:1190:12: */
 17335  	if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > 8 {
 17336  		{
 17337  			{
 17338  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) & 0xff)
 17339  			}
 17340  			{
 17341  				*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Uch(int32((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf) >> 8)
 17342  			}
 17343  
 17344  		}
 17345  
 17346  	} else if (*Deflate_state)(unsafe.Pointer(s)).Fbi_valid > 0 {
 17347  		{
 17348  			*(*Bytef)(unsafe.Pointer((*Deflate_state)(unsafe.Pointer(s)).Fpending_buf + uintptr(libc.PostIncUint64(&(*Deflate_state)(unsafe.Pointer(s)).Fpending, 1)))) = Byte((*Deflate_state)(unsafe.Pointer(s)).Fbi_buf)
 17349  		}
 17350  
 17351  	}
 17352  	(*Deflate_state)(unsafe.Pointer(s)).Fbi_buf = Ush(0)
 17353  	(*Deflate_state)(unsafe.Pointer(s)).Fbi_valid = 0
 17354  }
 17355  
 17356  // ===========================================================================
 17357  //      Decompresses the source buffer into the destination buffer.  *sourceLen is
 17358  //    the byte length of the source buffer. Upon entry, *destLen is the total size
 17359  //    of the destination buffer, which must be large enough to hold the entire
 17360  //    uncompressed data. (The size of the uncompressed data must have been saved
 17361  //    previously by the compressor and transmitted to the decompressor by some
 17362  //    mechanism outside the scope of this compression library.) Upon exit,
 17363  //    *destLen is the size of the decompressed data and *sourceLen is the number
 17364  //    of source bytes consumed. Upon return, source + *sourceLen points to the
 17365  //    first unused input byte.
 17366  //
 17367  //      uncompress returns Z_OK if success, Z_MEM_ERROR if there was not enough
 17368  //    memory, Z_BUF_ERROR if there was not enough room in the output buffer, or
 17369  //    Z_DATA_ERROR if the input data was corrupted, including if the input data is
 17370  //    an incomplete zlib stream.
 17371  func Xuncompress2(tls *libc.TLS, dest uintptr, destLen uintptr, source uintptr, sourceLen uintptr) int32 { /* uncompr.c:27:13: */
 17372  	bp := tls.Alloc(120)
 17373  	defer tls.Free(120)
 17374  
 17375  	// var stream Z_stream at bp+8, 112
 17376  
 17377  	var err int32
 17378  	var max UInt = libc.Uint32(libc.Uint32FromInt32(-1))
 17379  	var len ULong
 17380  	var left ULong
 17381  	// var buf [1]Byte at bp, 1
 17382  	// for detection of incomplete stream when *destLen == 0
 17383  
 17384  	len = *(*ULong)(unsafe.Pointer(sourceLen))
 17385  	if *(*ULongf)(unsafe.Pointer(destLen)) != 0 {
 17386  		left = *(*ULongf)(unsafe.Pointer(destLen))
 17387  		*(*ULongf)(unsafe.Pointer(destLen)) = uint64(0)
 17388  	} else {
 17389  		left = uint64(1)
 17390  		dest = bp /* &buf[0] */
 17391  	}
 17392  
 17393  	(*Z_stream)(unsafe.Pointer(bp + 8 /* &stream */)).Fnext_in = source
 17394  	(*Z_stream)(unsafe.Pointer(bp + 8 /* &stream */)).Favail_in = UInt(0)
 17395  	(*Z_stream)(unsafe.Pointer(bp + 8 /* &stream */)).Fzalloc = uintptr(0)
 17396  	(*Z_stream)(unsafe.Pointer(bp + 8 /* &stream */)).Fzfree = uintptr(0)
 17397  	(*Z_stream)(unsafe.Pointer(bp + 8 /* &stream */)).Fopaque = uintptr(0)
 17398  
 17399  	err = XinflateInit_(tls, bp+8, ts, int32(unsafe.Sizeof(Z_stream{})))
 17400  	if err != Z_OK {
 17401  		return err
 17402  	}
 17403  
 17404  	(*Z_stream)(unsafe.Pointer(bp + 8 /* &stream */)).Fnext_out = dest
 17405  	(*Z_stream)(unsafe.Pointer(bp + 8 /* &stream */)).Favail_out = UInt(0)
 17406  
 17407  	for ok := true; ok; ok = err == Z_OK {
 17408  		if (*Z_stream)(unsafe.Pointer(bp+8)).Favail_out == UInt(0) {
 17409  			(*Z_stream)(unsafe.Pointer(bp + 8 /* &stream */)).Favail_out = func() uint32 {
 17410  				if left > ULong(max) {
 17411  					return max
 17412  				}
 17413  				return UInt(left)
 17414  			}()
 17415  			left = left - ULong((*Z_stream)(unsafe.Pointer(bp+8)).Favail_out)
 17416  		}
 17417  		if (*Z_stream)(unsafe.Pointer(bp+8)).Favail_in == UInt(0) {
 17418  			(*Z_stream)(unsafe.Pointer(bp + 8 /* &stream */)).Favail_in = func() uint32 {
 17419  				if len > ULong(max) {
 17420  					return max
 17421  				}
 17422  				return UInt(len)
 17423  			}()
 17424  			len = len - ULong((*Z_stream)(unsafe.Pointer(bp+8)).Favail_in)
 17425  		}
 17426  		err = Xinflate(tls, bp+8, Z_NO_FLUSH)
 17427  	}
 17428  
 17429  	*(*ULong)(unsafe.Pointer(sourceLen)) -= len + ULong((*Z_stream)(unsafe.Pointer(bp+8)).Favail_in)
 17430  	if dest != bp {
 17431  		*(*ULongf)(unsafe.Pointer(destLen)) = (*Z_stream)(unsafe.Pointer(bp + 8 /* &stream */)).Ftotal_out
 17432  	} else if (*Z_stream)(unsafe.Pointer(bp+8)).Ftotal_out != 0 && err == -5 {
 17433  		left = uint64(1)
 17434  	}
 17435  
 17436  	XinflateEnd(tls, bp+8)
 17437  	if err == Z_STREAM_END {
 17438  		return Z_OK
 17439  	}
 17440  	if err == Z_NEED_DICT {
 17441  		return -3
 17442  	}
 17443  	if err == -5 && left+ULong((*Z_stream)(unsafe.Pointer(bp+8)).Favail_out) != 0 {
 17444  		return -3
 17445  	}
 17446  	return err
 17447  }
 17448  
 17449  func Xuncompress(tls *libc.TLS, dest uintptr, destLen uintptr, source uintptr, sourceLen ULong) int32 { /* uncompr.c:86:13: */
 17450  	bp := tls.Alloc(8)
 17451  	defer tls.Free(8)
 17452  	*(*ULong)(unsafe.Pointer(bp)) = sourceLen
 17453  
 17454  	return Xuncompress2(tls, dest, destLen, source, bp)
 17455  }
 17456  
 17457  // GT_OFF(x), where x is an unsigned value, is true if x > maximum z_off64_t
 17458  //    value -- needed when comparing unsigned to z_off64_t, which is signed
 17459  //    (possible z_off64_t types off_t, off64_t, and long are all signed)
 17460  
 17461  var Xz_errmsg = [10]uintptr{
 17462  	uintptr(ts + 876),
 17463  	uintptr(ts + 892),
 17464  	uintptr(ts + 101),
 17465  	uintptr(ts + 903),
 17466  	uintptr(ts + 914),
 17467  	uintptr(ts + 927),
 17468  	uintptr(ts + 938),
 17469  	uintptr(ts + 958),
 17470  	uintptr(ts + 971),
 17471  	uintptr(ts + 101),
 17472  } /* zutil.c:13:14 */
 17473  
 17474  func XzlibVersion(tls *libc.TLS) uintptr { /* zutil.c:27:12: */
 17475  	return ts /* "1.2.11" */
 17476  }
 17477  
 17478  func XzlibCompileFlags(tls *libc.TLS) ULong { /* zutil.c:32:15: */
 17479  	var flags ULong
 17480  
 17481  	flags = uint64(0)
 17482  	switch int32(unsafe.Sizeof(UInt(0))) {
 17483  	case 2:
 17484  		break
 17485  	case 4:
 17486  		flags = flags + uint64(1)
 17487  		break
 17488  	case 8:
 17489  		flags = flags + uint64(2)
 17490  		break
 17491  	default:
 17492  		flags = flags + uint64(3)
 17493  	}
 17494  	switch int32(unsafe.Sizeof(ULong(0))) {
 17495  	case 2:
 17496  		break
 17497  	case 4:
 17498  		flags = flags + uint64(int32(1)<<2)
 17499  		break
 17500  	case 8:
 17501  		flags = flags + uint64(int32(2)<<2)
 17502  		break
 17503  	default:
 17504  		flags = flags + uint64(int32(3)<<2)
 17505  	}
 17506  	switch int32(unsafe.Sizeof(Voidpf(0))) {
 17507  	case 2:
 17508  		break
 17509  	case 4:
 17510  		flags = flags + uint64(int32(1)<<4)
 17511  		break
 17512  	case 8:
 17513  		flags = flags + uint64(int32(2)<<4)
 17514  		break
 17515  	default:
 17516  		flags = flags + uint64(int32(3)<<4)
 17517  	}
 17518  	switch int32(unsafe.Sizeof(Off_t(0))) {
 17519  	case 2:
 17520  		break
 17521  	case 4:
 17522  		flags = flags + uint64(int32(1)<<6)
 17523  		break
 17524  	case 8:
 17525  		flags = flags + uint64(int32(2)<<6)
 17526  		break
 17527  	default:
 17528  		flags = flags + uint64(int32(3)<<6)
 17529  	}
 17530  	return flags
 17531  }
 17532  
 17533  // exported to allow conversion of error code to string for compress() and
 17534  // uncompress()
 17535  func XzError(tls *libc.TLS, err int32) uintptr { /* zutil.c:133:12: */
 17536  	return Xz_errmsg[Z_NEED_DICT-err]
 17537  }
 17538  
 17539  func Xzcalloc(tls *libc.TLS, opaque Voidpf, items uint32, size uint32) Voidpf { /* zutil.c:305:22: */
 17540  	_ = opaque
 17541  	if uint64(unsafe.Sizeof(UInt(0))) > uint64(2) {
 17542  		return libc.Xmalloc(tls, uint64(items*size))
 17543  	}
 17544  	return libc.Xcalloc(tls, uint64(items), uint64(size))
 17545  }
 17546  
 17547  func Xzcfree(tls *libc.TLS, opaque Voidpf, ptr Voidpf) { /* zutil.c:315:20: */
 17548  	_ = opaque
 17549  	libc.Xfree(tls, ptr)
 17550  }
 17551  
 17552  func init() {
 17553  	*(*func(*libc.TLS, uintptr, int32) Block_state)(unsafe.Pointer(uintptr(unsafe.Pointer(&configuration_table)) + 8)) = deflate_stored  // deflate.c:136:29:
 17554  	*(*func(*libc.TLS, uintptr, int32) Block_state)(unsafe.Pointer(uintptr(unsafe.Pointer(&configuration_table)) + 24)) = deflate_fast   // deflate.c:137:29:
 17555  	*(*func(*libc.TLS, uintptr, int32) Block_state)(unsafe.Pointer(uintptr(unsafe.Pointer(&configuration_table)) + 40)) = deflate_fast   // deflate.c:138:29:
 17556  	*(*func(*libc.TLS, uintptr, int32) Block_state)(unsafe.Pointer(uintptr(unsafe.Pointer(&configuration_table)) + 56)) = deflate_fast   // deflate.c:139:29:
 17557  	*(*func(*libc.TLS, uintptr, int32) Block_state)(unsafe.Pointer(uintptr(unsafe.Pointer(&configuration_table)) + 72)) = deflate_slow   // deflate.c:141:29:
 17558  	*(*func(*libc.TLS, uintptr, int32) Block_state)(unsafe.Pointer(uintptr(unsafe.Pointer(&configuration_table)) + 88)) = deflate_slow   // deflate.c:142:29:
 17559  	*(*func(*libc.TLS, uintptr, int32) Block_state)(unsafe.Pointer(uintptr(unsafe.Pointer(&configuration_table)) + 104)) = deflate_slow  // deflate.c:143:29:
 17560  	*(*func(*libc.TLS, uintptr, int32) Block_state)(unsafe.Pointer(uintptr(unsafe.Pointer(&configuration_table)) + 120)) = deflate_slow  // deflate.c:144:29:
 17561  	*(*func(*libc.TLS, uintptr, int32) Block_state)(unsafe.Pointer(uintptr(unsafe.Pointer(&configuration_table)) + 136)) = deflate_slow  // deflate.c:145:30:
 17562  	*(*func(*libc.TLS, uintptr, int32) Block_state)(unsafe.Pointer(uintptr(unsafe.Pointer(&configuration_table)) + 152)) = deflate_slow  // deflate.c:146:30:
 17563  	*(*uintptr)(unsafe.Pointer(uintptr(unsafe.Pointer(&static_bl_desc)) + 8 /* .extra_bits */)) = uintptr(unsafe.Pointer(&extra_blbits)) // trees.c:132:22:
 17564  	*(*uintptr)(unsafe.Pointer(uintptr(unsafe.Pointer(&static_d_desc)) + 0 /* .static_tree */)) = uintptr(unsafe.Pointer(&static_dtree)) // trees.c:129:2:
 17565  	*(*uintptr)(unsafe.Pointer(uintptr(unsafe.Pointer(&static_d_desc)) + 8 /* .extra_bits */)) = uintptr(unsafe.Pointer(&extra_dbits))   // trees.c:129:16:
 17566  	*(*uintptr)(unsafe.Pointer(uintptr(unsafe.Pointer(&static_l_desc)) + 0 /* .static_tree */)) = uintptr(unsafe.Pointer(&static_ltree)) // trees.c:126:2:
 17567  	*(*uintptr)(unsafe.Pointer(uintptr(unsafe.Pointer(&static_l_desc)) + 8 /* .extra_bits */)) = uintptr(unsafe.Pointer(&extra_lbits))   // trees.c:126:16:
 17568  }
 17569  
 17570  var ts1 = "1.2.11\x00 deflate 1.2.11 Copyright 1995-2017 Jean-loup Gailly and Mark Adler \x00%s\x00<fd:%d>\x00out of memory\x00\x00%s%s%s\x00: \x00unexpected end of file\x00internal error: inflate stream corrupt\x00compressed data error\x00request does not fit in an int\x00request does not fit in a size_t\x00out of room to push characters\x00internal error: deflate stream corrupt\x00requested length does not fit in int\x00invalid block type\x00invalid stored block lengths\x00too many length or distance symbols\x00invalid code lengths set\x00invalid bit length repeat\x00invalid code -- missing end-of-block\x00invalid literal/lengths set\x00invalid distances set\x00invalid literal/length code\x00invalid distance code\x00invalid distance too far back\x00incorrect header check\x00unknown compression method\x00invalid window size\x00unknown header flags set\x00header crc mismatch\x00incorrect data check\x00incorrect length check\x00 inflate 1.2.11 Copyright 1995-2017 Mark Adler \x00need dictionary\x00stream end\x00file error\x00stream error\x00data error\x00insufficient memory\x00buffer error\x00incompatible version\x00"
 17571  var ts = (*reflect.StringHeader)(unsafe.Pointer(&ts1)).Data