[med-svn] [sra-sdk] 02/06: Imported Upstream version 2.3.5-2+dfsg
Andreas Tille
tille at debian.org
Wed Jul 30 12:22:34 UTC 2014
This is an automated email from the git hooks/post-receive script.
tille pushed a commit to branch master
in repository sra-sdk.
commit 888f953cb2be8a5678441f6cc70d85d44c8d223e
Author: Andreas Tille <tille at debian.org>
Date: Wed Jul 30 13:56:07 2014 +0200
Imported Upstream version 2.3.5-2+dfsg
---
README | 3 -
README-build.txt | 20 -
build/Makefile.env | 39 +-
build/Makefile.gcc | 11 +-
build/Makefile.rules | 31 +-
build/Makefile.vc++ | 2 +-
build/ld.win.cmn.sh | 8 +
configuration-assistant.perl | 2 +-
interfaces/align/align-access.h | 22 +-
interfaces/align/bam.h | 26 +-
interfaces/align/reader-refseq.h | 7 +-
interfaces/align/writer-reference.h | 13 +-
interfaces/cc/gcc/i386/arch-impl.h | 16 +
interfaces/cc/gcc/x86_64/arch-impl.h | 31 +
interfaces/cc/vc++/stdint.h | 73 +-
interfaces/insdc/insdc.vschema | 8 +
interfaces/{klib => kfc}/callconv.h | 6 +-
interfaces/kfc/ctx.h | 214 +
interfaces/{klib => kfc}/defs.h | 122 +-
interfaces/kfc/except.h | 149 +
interfaces/{klib => kfc}/extern.h | 20 +-
interfaces/{klib => kfc}/rc.h | 147 +-
libs/vfs/keyring-priv.h => interfaces/kfc/rsrc.h | 60 +-
interfaces/kfc/xc.h | 94 +
interfaces/{kns/manager-ext.h => kfc/xcdefs.h} | 48 +-
.../bsd/syslock-priv.h => interfaces/kfc/xcext.h | 44 +-
interfaces/{kns/url-fetcher.h => kfc/xcgen.h} | 50 +-
interfaces/kfs/file.h | 107 +
interfaces/kfs/impl.h | 7 +
interfaces/kfs/kfs-priv.h | 19 +-
interfaces/klib/callconv.h | 23 +-
interfaces/klib/debug.h | 14 +-
interfaces/klib/defs.h | 69 +-
interfaces/klib/extern.h | 29 +-
libs/kns/stream-priv.h => interfaces/klib/misc.h | 24 +-
interfaces/klib/namelist.h | 16 +
interfaces/klib/rc.h | 314 +-
interfaces/klib/time.h | 8 +-
interfaces/kns/KCurlRequest.h | 69 -
interfaces/kns/ascp.h | 43 +-
interfaces/kns/endpoint.h | 12 +-
interfaces/kns/entrez-fetcher.h | 88 -
interfaces/kns/http.h | 33 +-
interfaces/kns/impl.h | 7 +
interfaces/kns/manager-ext.h | 2 +-
interfaces/kns/manager.h | 26 +-
interfaces/kns/socket.h | 43 +-
interfaces/kns/stream.h | 84 +
interfaces/kproc/cond.h | 3 +-
interfaces/kproc/lock.h | 22 +-
interfaces/krypto/encfile-priv.h | 8 +-
interfaces/krypto/extern.h | 7 +-
interfaces/ktst/test_tools.hpp | 2 +-
interfaces/ktst/unit_test.hpp | 30 +-
interfaces/ktst/unit_test_suite.hpp | 5 +-
.../{kns/curl-file.h => ncbi/vdb-blast-priv.h} | 24 +-
interfaces/ncbi/vdb-blast.h | 489 ++
interfaces/sra/fastq.h | 2 +-
interfaces/vdb/manager.h | 12 +
interfaces/vfs/manager.h | 3 +
interfaces/vfs/resolver.h | 6 +-
libs/Makefile | 1 +
libs/align/align-access.c | 28 +-
libs/align/bam.c | 1114 ++-
libs/align/refseq-mgr.c | 4 +
libs/align/writer-alignment.c | 2 +-
libs/align/writer-reference.c | 48 +-
libs/ascp/linux/ascp-path.c | 28 +
libs/ascp/mac/ascp-path.c | 2 +-
libs/ascp/win/connect.c | 71 +-
libs/{vfs => blast}/Makefile | 63 +-
libs/blast/blast.c | 5243 ++++++++++++++
libs/kapp/args_debug.h | 2 +-
libs/kdb/dbmgr-cmn.c | 112 +-
libs/kdb/dbmgr-priv.h | 2 +
libs/kdb/wmeta.c | 6 +-
libs/kfg/config-lex.c | 330 +-
libs/kfg/config.c | 45 +
libs/kfg/default.kfg | 19 +-
libs/kfs/Makefile | 27 +-
libs/kfs/file.c | 435 +-
libs/kfs/from_to_namelist.c | 307 +
libs/kfs/gzip.c | 65 +-
libs/kfs/win/sysdir-priv.h | 7 +
libs/kfs/win/sysdir.c | 3 +
libs/klib/Makefile | 1 +
libs/klib/printf.c | 2 +-
libs/klib/release-vers.h | 2 +-
libs/klib/report.c | 17 +-
libs/{kns/unix/sysmgr.c => klib/unix/misc.c} | 12 +-
libs/klib/unix/systime.c | 31 +
libs/klib/vector_namelist.c | 36 +-
libs/{kns/unix/sysmgr.c => klib/win/misc.c} | 12 +-
libs/kns/KCurlFile.c | 716 --
libs/kns/KCurlRequest.c | 438 --
libs/kns/Makefile | 56 +-
libs/kns/curlhdr/curl.h | 1600 -----
libs/kns/curlhdr/curlver.h | 56 -
libs/kns/curlhdr/easy.h | 81 -
libs/kns/curlhdr/multi.h | 344 -
libs/kns/curlhdr/types.h | 1 -
libs/kns/entrez-fetcher.c | 221 -
libs/kns/http-priv.h | 25 +-
libs/kns/http-test.c | 4 +-
libs/kns/http.c | 393 +-
libs/kns/kns_manager-ext.c | 21 +-
libs/kns/kns_manager.c | 7 +
libs/kns/kns_mgr_priv.h | 71 -
libs/kns/{unix => linux}/sysendpoint.c | 24 +-
libs/kns/linux/syspoll.c | 107 +
libs/kns/{unix => mac}/sysendpoint.c | 0
libs/kns/mac/syspoll.c | 96 +
libs/kns/manager.c | 307 +
libs/{kproc/win/syslock-priv.h => kns/mgr-priv.h} | 23 +-
interfaces/kns/curl-file.h => libs/kns/poll-priv.h | 20 +-
libs/kns/stream-priv.h | 4 +
libs/kns/stream.c | 474 +-
libs/kns/{unix/sysmgr.c => sysmgr.h} | 20 +-
libs/kns/undyinghttp.c | 362 +
libs/kns/unix/sysmgr.c | 8 +-
libs/kns/unix/syssock.c | 817 ++-
libs/kns/win/sysmgr.c | 44 +-
libs/kns/win/syssock.c | 1388 ++--
libs/kproc/bsd/syslock-priv.h | 12 +-
libs/kproc/bsd/syslock.c | 507 +-
libs/kproc/linux/syslock-priv.h | 6 +
libs/kproc/linux/syslock.c | 123 +-
libs/kproc/win/syslock-priv.h | 11 +
libs/kproc/win/syslock.c | 122 +-
libs/krypto/Makefile | 2 +-
libs/ktst/testenv.cpp | 11 +-
libs/ktst/unix/runprocesstestcase.cpp | 16 +-
libs/ktst/win/runprocesstestcase.cpp | 41 +-
libs/loader/common-writer.c | 25 +-
libs/ncbi-vdb/Makefile | 2 +-
libs/ncbi-vdb/libncbi-vdb.vers | 2 +-
libs/ncbi-vdb/libncbi-wvdb.vers | 2 +-
libs/search/agrep-dp.c | 18 +-
libs/search/agrep-myers.c | 150 +-
libs/search/fgrep-aho.c | 2 +-
libs/search/fgrep-boyermoore.c | 4 +-
libs/search/fgrep-dumb.c | 2 +-
libs/search/search-priv.h | 4 +-
libs/sra/Makefile | 2 +-
libs/sra/reader-abi.c | 14 +-
libs/sra/reader-fastq.c | 20 +-
libs/sra/sra-schema.c | 7238 ++++++++++----------
libs/vdb/blob.c | 14 +-
libs/vdb/cursor-cmn.c | 35 +-
libs/vdb/database-depend.c | 11 +-
libs/vdb/dbmgr-cmn.c | 78 +
libs/vdb/prod-priv.h | 3 +
libs/vdb/report-vdb.c | 2 +-
libs/vdb/table-cmn.c | 2 +-
libs/vdb/wcursor.c | 2 -
libs/vfs/Makefile | 29 +-
libs/vfs/keyring.h | 9 +-
libs/vfs/manager.c | 218 +-
libs/vfs/path.c | 31 +-
libs/vfs/resolver.c | 216 +-
libs/vfs/unix/syskeyring.c | 149 +-
libs/vfs/win/syskeyring.c | 8 +-
tools/align-info/align-info.c | 37 +-
tools/align-info/align-info.vers | 2 +-
tools/bam-loader/bam-load.vers | 2 +-
tools/bam-loader/loader-imp.c | 91 +-
tools/cache-mgr/cache-mgr.vers | 2 +-
tools/cg-load/cg-load.vers | 2 +-
tools/fastq-loader/fastq-grammar.c | 679 +-
tools/fastq-loader/fastq-lex.c | 403 +-
tools/fastq-loader/fastq-loader.c | 6 +-
tools/fastq-loader/fastq-parse.h | 54 +-
tools/fastq-loader/fastq-reader.c | 80 +-
tools/fastq-loader/fastq-tokens.h | 3 +-
tools/fastq-loader/latf-load.vers | 2 +-
tools/kar/kar.vers | 2 +-
tools/kar/sra-kar.vers | 2 +-
tools/nenctool/Makefile | 4 +-
tools/nenctool/nenctest.vers | 2 +-
tools/nenctool/nenctool.vers | 2 +-
tools/nencvalid/Makefile | 2 +-
tools/nencvalid/nencvalid.vers | 2 +-
tools/prefetch/prefetch.c | 55 +-
tools/prefetch/prefetch.vers | 2 +-
tools/sra-dbcc/sra-dbcc.vers | 2 +-
tools/sra-dump/abi-dump.vers | 2 +-
tools/sra-dump/abi.c | 2 +
tools/sra-dump/core.c | 16 +-
tools/sra-dump/core.h | 1 +
tools/sra-dump/factory.c | 4 +
tools/sra-dump/fastq-dump.vers | 2 +-
tools/sra-dump/fastq.c | 29 +-
tools/sra-dump/illumina-dump.vers | 2 +-
tools/sra-dump/sff-dump.vers | 2 +-
tools/sra-dump/sra-dump.vers | 2 +-
tools/sra-load/abi-load.vers | 2 +-
tools/sra-load/fastq-load.vers | 2 +-
tools/sra-load/helicos-load.vers | 2 +-
tools/sra-load/illumina-load.vers | 2 +-
tools/sra-load/pacbio-loadxml.vers | 2 +-
tools/sra-load/sff-load.vers | 2 +-
tools/sra-load/srf-load.vers | 2 +-
tools/sra-load/writer-absolid.c | 6 +-
tools/sra-load/writer-absolid.h | 3 +-
tools/sra-pileup/cg_tools.c | 8 +-
tools/sra-pileup/cg_tools.h | 4 +-
tools/sra-pileup/read_fkt.h | 164 +-
tools/sra-pileup/sam-aligned.c | 6 +-
tools/sra-pileup/sam-aligned.h | 90 +-
tools/sra-pileup/sam-dump-opts.c | 16 +
tools/sra-pileup/sam-dump-opts.h | 7 +-
tools/sra-pileup/sam-dump.vers | 2 +-
tools/sra-pileup/sam-dump3.c | 7 +-
tools/sra-pileup/sam-hdr.c | 416 +-
tools/sra-pileup/sam-unaligned.h | 2 +-
tools/sra-pileup/sra-pileup.vers | 2 +-
tools/sra-sort/sort-defs.h | 15 +
tools/sra-sort/sra-sort.vers | 2 +-
tools/sra-stat/sra-stat.vers | 2 +-
tools/srapath/srapath.vers | 2 +-
tools/util/kdbmeta.c | 74 +-
tools/util/kdbmeta.vers | 2 +-
tools/util/mac/syspass.c | 2 +-
tools/util/md5cp.vers | 2 +-
tools/util/rcexplain.vers | 2 +-
tools/util/rowwritetest.vers | 2 +-
tools/util/schema-replace.vers | 2 +-
tools/util/test-sra.c | 163 +-
tools/util/test-sra.vers | 2 +-
tools/util/testld.vers | 2 +-
tools/util/txt2kdb.vers | 2 +-
tools/util/vdb-lock.vers | 2 +-
tools/util/vdb-passwd.vers | 2 +-
tools/util/vdb-unlock.vers | 2 +-
tools/vdb-config/vdb-config.c | 56 +-
tools/vdb-config/vdb-config.vers | 2 +-
tools/vdb-copy/vdb-copy.vers | 2 +-
tools/vdb-decrypt/vdb-decrypt.vers | 2 +-
tools/vdb-decrypt/vdb-encrypt.vers | 2 +-
tools/vdb-dump/vdb-dump-coldefs.c | 27 +-
tools/vdb-dump/vdb-dump-coldefs.h | 6 +-
tools/vdb-dump/vdb-dump-context.c | 4 +-
tools/vdb-dump/vdb-dump-context.h | 4 +-
tools/vdb-dump/vdb-dump-fastq.c | 3 +
tools/vdb-dump/vdb-dump.c | 86 +-
tools/vdb-dump/vdb-dump.vers | 2 +-
tools/vdb-validate/vdb-validate.c | 569 +-
tools/vdb-validate/vdb-validate.vers | 2 +-
248 files changed, 19551 insertions(+), 11609 deletions(-)
diff --git a/README b/README
index b9cb81e..7dc5b1c 100644
--- a/README
+++ b/README
@@ -32,9 +32,6 @@ http://trace.ncbi.nlm.nih.gov/Traces/sra/std
The SRA Toolkit and SDK from NCBI is a collection of tools and
libraries for using data in the INSDC Sequence Read Archives.
-With this release, NCBI has implemented Automatic Remote Access by accession,
-making it possible to access data using NCBI servers without prior download.
-
For additional information on using and building the toolkit,
please visit our web site at:
diff --git a/README-build.txt b/README-build.txt
index 300f138..3a508c6 100644
--- a/README-build.txt
+++ b/README-build.txt
@@ -44,7 +44,6 @@ operating systems on Intel x86-compatible 32 and 64 bit architectures.
make # GNU make version 3.81 or later
gcc, g++ # tested with 4.4.2, but should work with others
libxml2 # tested with version 2.7.6
- libcurl # tested with version 7.27
WINDOWS BUILD:
@@ -204,12 +203,6 @@ STATIC BUILD RESULTS:
libwvdb # virtual layer update library
libz # gzip library
-<OUTDIR>/mod64/ # (mod32 for 32-bit builds)
- -- empty --
-
-<OUTDIR>/wmod64/ # (wmod32 for 32-bit builds)
- -- empty --
-
DYNAMIC BUILD RESULTS:
@@ -244,16 +237,3 @@ DYNAMIC BUILD RESULTS:
libwsraschema # static version of SRA schema for update
libwvdb # virtual layer update library
libz # static gzip library
-
-<OUTDIR>/mod64/ # (mod32 for 32-bit builds)
- libaxf # cSRA-specific VDB external functions
- libsraxf # SRA-specific VDB external functions
- libvxf # generic VDB external functions
- libwgsxf # WGS-specific VDB external functions
-
-<OUTDIR>/wmod64/ # (wmod32 for 32-bit builds)
- libwaxf # cSRA-specific VDB external functions for update
- libwsraxf # SRA-specific VDB external functions for update
- libwvxf # update VDB external functions
- libwwgsxf # WGS-specific VDB external functions for update
-
diff --git a/build/Makefile.env b/build/Makefile.env
index ac28d96..fcc653c 100644
--- a/build/Makefile.env
+++ b/build/Makefile.env
@@ -249,6 +249,7 @@ ITF = $(TOP)/interfaces
OSINC = $(TOP)/interfaces/os
CCINC = $(TOP)/interfaces/cc
XTINC = $(TOP)/interfaces/ext
+OVERRIDEINC = $(TOP)/interfaces/override
# OS specific source and include dirs
SRCDIRS_OS = $(SRCDIR)/$(OS)
@@ -289,6 +290,7 @@ VPATH = \
$(SRCDIR)
INCDIRS = \
+ $(addprefix -I,$(OVERRIDEINC)) \
$(addprefix -I,$(SRCDIRS_OS)) \
$(addprefix -I,$(SRCDIR) $(ITF)) \
$(addprefix -I,$(INCDIRS_COMP)) \
@@ -304,40 +306,3 @@ ARCHDEFS = -D_ARCH_BITS=$(BITS) -DLIBPREFIX=$(LPFX) -DSHLIBEXT=$(DLLX)
CFLAGS = $(DEBUG) $(DBG) $(CARCH) $(PROF) $(PED) $(LINKAGE) $(DEFINES) $(ARCHDEFS) $(MIN_DEPLOY_OS_OPT) $(INCDIRS)
CPFLAGS = $(DEBUG) $(DBG) $(CARCH) $(PROF) $(LINKAGE) $(DEFINES) $(ARCHDEFS) $(MIN_DEPLOY_OS_OPT) $(INCDIRS)
LDFLAGS = $(DBG) $(PROF) $(CARCH) $(MIN_DEPLOY_OS_OPT)
-
-#-------------------------------------------------------------------------------
-# runtests
-#
-# MallocScribble=1 is for catching allocation problems on Mac
-#
-ifeq ($(RUNTESTS_OVERRIDE),)
-runtests: std $(TEST_TOOLS)
- @ echo "$0 $*"; export LD_LIBRARY_PATH=$(LIBDIR);export MallocScribble=1;\
- for i in $(TEST_TOOLS);\
- do\
- echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++;\
- echo Run $(TEST_BINDIR)/$$i;eval $(RUN_REMOTELY) $(TEST_BINDIR)/$$i;r=$$?; \
- if [ "$$r" != "0" ] ; then exit $$r; fi; \
- done
-
-.PHONY: runtests
-endif
-
-#-------------------------------------------------------------------------------
-# buildtests
-#
-buildtests: std $(TEST_TOOLS) $(SLOW_TEST_TOOLS)
-
-#-------------------------------------------------------------------------------
-# slowtests
-#
-slowtests: std $(SLOW_TEST_TOOLS)
- @ echo "$0 $*"; export LD_LIBRARY_PATH=$(LIBDIR);\
- for i in $(SLOW_TEST_TOOLS);\
- do\
- echo ++++++++++++++++++++++++++++++++++++++++++++++++++++++;\
- echo Run $(TEST_BINDIR)/$$i;eval $(TEST_BINDIR)/$$i;r=$$?; \
- if [ "$$r" != "0" ] ; then exit $$r; fi; \
- done
-
-.PHONY: slowtests buildtests
diff --git a/build/Makefile.gcc b/build/Makefile.gcc
index 271dff3..d391d1b 100644
--- a/build/Makefile.gcc
+++ b/build/Makefile.gcc
@@ -38,8 +38,10 @@ LD = @ $(TOP)/build/ld.sh $(OS) $(ARCH) gcc \
$(STATICSYSLIBS) $(CHECKSUM) --objx $(OBJX) --shlx $(SHLX) --libx $(LIBX) \
-MD --srcdir $(SRCDIR) --bindir $(BINDIR) -L$(LIBDIR):$(ILIBDIR)
+LPFLAGS = $(LDFLAGS)
+
LP = @ $(TOP)/build/ld.sh $(OS) $(ARCH) g++ \
- --build $(BUILD) --ldflags "$(LDFLAGS)" $(STATIC) \
+ --build $(BUILD) --ldflags "$(LPFLAGS)" $(STATIC) \
$(STATICSYSLIBS) $(CHECKSUM) --objx $(OBJX) --shlx $(SHLX) --libx $(LIBX) \
-MD --srcdir $(SRCDIR) --bindir $(BINDIR) -L$(LIBDIR):$(ILIBDIR)
@@ -70,7 +72,7 @@ ifeq (dbg, $(BUILD))
# GCC seems unable to use c99 without ansi, which
# basically clobbers features back to c89. the options
# must be specified in the order shown.
- PED = -std=c99 -ansi -pedantic # -fdiagnostics-show-option
+ PED = -std=gnu99 -pedantic # -fdiagnostics-show-option
else
ifeq (x86_64, $(ARCH))
@@ -79,3 +81,8 @@ else
OPT = -O3 -Wno-variadic-macros -fno-strict-aliasing
endif
endif
+
+ifeq (mac,$(OS))
+ # g++ linker on mac needs to be told which standard c++ library to use
+ LPFLAGS += -lstdc++
+endif
diff --git a/build/Makefile.rules b/build/Makefile.rules
index bb18f20..0313504 100644
--- a/build/Makefile.rules
+++ b/build/Makefile.rules
@@ -24,46 +24,47 @@
## build rules
+LOC_INFO = -D__mod_name__=$(MODULE) -D__file_name__=$*
# executable image
%.$(OBJX): %.c
- $(CC) -o $@ $(OPT) $<
+ $(CC) -o $@ $(OPT) $< $(LOC_INFO) -D__file_ext__=c
%.$(OBJX): %.cpp
- $(CP) -o $@ $(OPT) $<
+ $(CP) -o $@ $(OPT) $< $(LOC_INFO) -D__file_ext__=cpp
%.$(OBJX): %.cxx
- $(CP) -o $@ $(OPT) $<
+ $(CP) -o $@ $(OPT) $< $(LOC_INFO) -D__file_ext__=cxx
# non-optimized executable image
%.nopt.$(OBJX): %.c
- $(CC) -o $@ $(NOPT) $<
+ $(CC) -o $@ $(NOPT) $< $(LOC_INFO) -D__file_ext__=c
%.nopt.$(OBJX): %.cpp
- $(CP) -o $@ $(NOPT) $<
+ $(CP) -o $@ $(NOPT) $< $(LOC_INFO) -D__file_ext__=cpp
%.nopt.$(OBJX): %.cxx
- $(CP) -o $@ $(NOPT) $<
+ $(CP) -o $@ $(NOPT) $< $(LOC_INFO) -D__file_ext__=cxx
# relocatable image
%.$(LOBX): %.c
- $(CC) -o $@ -fPIC $(OPT) -D_LIBRARY $<
+ $(CC) -o $@ -fPIC $(OPT) -D_LIBRARY $< $(LOC_INFO) -D__file_ext__=c
%.$(LOBX): %.cpp
- $(CP) -o $@ -fPIC $(OPT) -D_LIBRARY $<
+ $(CP) -o $@ -fPIC $(OPT) -D_LIBRARY $< $(LOC_INFO) -D__file_ext__=cpp
%.$(LOBX): %.cxx
- $(CP) -o $@ -fPIC $(OPT) -D_LIBRARY $<
+ $(CP) -o $@ -fPIC $(OPT) -D_LIBRARY $< $(LOC_INFO) -D__file_ext__=cxx
# non-optimized relocatable image
%.nopt.$(LOBX): %.c
- $(CC) -o $@ -fPIC $(NOPT) -D_LIBRARY $<
+ $(CC) -o $@ -fPIC $(NOPT) -D_LIBRARY $< $(LOC_INFO) -D__file_ext__=c
%.nopt.$(LOBX): %.cpp
- $(CP) -o $@ -fPIC $(NOPT) -D_LIBRARY $<
+ $(CP) -o $@ -fPIC $(NOPT) -D_LIBRARY $< $(LOC_INFO) -D__file_ext__=cpp
%.nopt.$(LOBX): %.cxx
- $(CP) -o $@ -fPIC $(NOPT) -D_LIBRARY $<
+ $(CP) -o $@ -fPIC $(NOPT) -D_LIBRARY $< $(LOC_INFO) -D__file_ext__=cxx
# non-optimized relocatable image with persisted image byte swapping
%.swap.nopt.$(LOBX): %.c
- $(CC) -o $@ -fPIC -DSWAP_PERSISTED $(NOPT) -D_LIBRARY $<
+ $(CC) -o $@ -fPIC -DSWAP_PERSISTED $(NOPT) -D_LIBRARY $< $(LOC_INFO) -D__file_ext__=c
%.swap.nopt.$(LOBX): %.cpp
- $(CP) -o $@ -fPIC -DSWAP_PERSISTED $(NOPT) -D_LIBRARY $<
+ $(CP) -o $@ -fPIC -DSWAP_PERSISTED $(NOPT) -D_LIBRARY $< $(LOC_INFO) -D__file_ext__=cpp
%.swap.nopt.$(LOBX): %.cxx
- $(CP) -o $@ -fPIC -DSWAP_PERSISTED $(NOPT) -D_LIBRARY $<
+ $(CP) -o $@ -fPIC -DSWAP_PERSISTED $(NOPT) -D_LIBRARY $< $(LOC_INFO) -D__file_ext__=cxx
# assembly
%.$(OBJX) %.$(LOBX): %.s
diff --git a/build/Makefile.vc++ b/build/Makefile.vc++
index e2c3815..e480497 100644
--- a/build/Makefile.vc++
+++ b/build/Makefile.vc++
@@ -25,7 +25,7 @@
# RFLAGS have to go before any other flags since they can affect their handling
# compilers
CC = @ $(TOP)/build/win-cc.sh $(BUILD_OS) "cl /c /D_WIN32_WINNT=0x0502" \
- $(CHECKSUM) --objx $(OBJX) $(RFLAGS) $(CFLAGS) -MD
+ $(CHECKSUM) --objx $(OBJX) $(RFLAGS) $(CFLAGS) -MD -D_CRT_SECURE_NO_WARNINGS
CP = @ $(TOP)/build/win-cc.sh $(BUILD_OS) "cl /c" \
$(CHECKSUM) --objx $(OBJX) $(RFLAGS) $(CPFLAGS) -MD -EHsc
diff --git a/build/ld.win.cmn.sh b/build/ld.win.cmn.sh
index 33d0b0a..19fae3a 100755
--- a/build/ld.win.cmn.sh
+++ b/build/ld.win.cmn.sh
@@ -94,6 +94,14 @@ HAVE_XML=0
CHECKSUM=$(expr $SCMFLAGS % 2)
STATICSYSLIBS=$(expr $SCMFLAGS / 2)
+# set target architecture
+if [ "$ARCH" == "i386" ]
+then
+ LDFLAGS="$LDFLAGS /MACHINE:x86"
+else
+ LDFLAGS="$LDFLAGS /MACHINE:x64"
+fi
+
if [ "$VERBOSE" != "" ]
then
echo "LD =$LD"
diff --git a/configuration-assistant.perl b/configuration-assistant.perl
index 599f291..08e23ba 100755
--- a/configuration-assistant.perl
+++ b/configuration-assistant.perl
@@ -4,7 +4,7 @@
# N.B. Run "perl configuration-assistant.perl" if you see a message like:
# configuration-assistant.perl: /usr/bin/perl: bad interpreter: No such file or directory
################################################################################
-my $VERSION = '2.3.4-2';
+my $VERSION = '2.3.5-2';
################################################################################
use strict;
diff --git a/interfaces/align/align-access.h b/interfaces/align/align-access.h
index 75f92ea..1f96f0e 100644
--- a/interfaces/align/align-access.h
+++ b/interfaces/align/align-access.h
@@ -114,11 +114,16 @@ ALIGN_EXTERN rc_t CC AlignAccessDBRelease ( const AlignAccessDB *self );
*/
typedef struct AlignAccessRefSeqEnumerator AlignAccessRefSeqEnumerator;
+#define AlignAccessRefSeqEnumeratorEOFCode (RC(rcAlign, rcTable, rcReading, rcRow, rcNotFound))
+#define AlignAccessRefSeqEnumeratorIsEOF(RESULT_CODE) (GetRCObject(RESULT_CODE) == rcRow && GetRCState(RESULT_CODE) == rcNotFound)
/* EnumerateRefSequences
* make an enumerator of reference sequences visible in database
*
* "refseq_enum" [ OUT ] - return parameter for enumerator
+ *
+ * return codes:
+ * object: rcRow, state: rcNotFound - if the index is empty
*/
ALIGN_EXTERN rc_t CC AlignAccessDBEnumerateRefSequences ( const AlignAccessDB *self,
AlignAccessRefSeqEnumerator **refseq_enum );
@@ -130,7 +135,11 @@ ALIGN_EXTERN rc_t CC AlignAccessDBEnumerateRefSequences ( const AlignAccessDB *s
ALIGN_EXTERN rc_t CC AlignAccessRefSeqEnumeratorAddRef ( const AlignAccessRefSeqEnumerator *self );
ALIGN_EXTERN rc_t CC AlignAccessRefSeqEnumeratorRelease ( const AlignAccessRefSeqEnumerator *self );
-/* advance the enumerator to the next element */
+/* advance the enumerator to the next element
+ *
+ * return codes:
+ * object: rcRow, state: rcNotFound - if there is no next element
+ */
ALIGN_EXTERN rc_t CC AlignAccessRefSeqEnumeratorNext(const AlignAccessRefSeqEnumerator *cself);
/* GetID
@@ -157,12 +166,17 @@ ALIGN_EXTERN rc_t CC AlignAccessRefSeqEnumeratorGetLength
*/
typedef struct AlignAccessAlignmentEnumerator AlignAccessAlignmentEnumerator;
+#define AlignAccessAlignmentEnumeratorEOFCode (RC(rcAlign, rcTable, rcReading, rcRow, rcNotFound))
+#define AlignAccessAlignmentEnumeratorIsEOF(RESULT_CODE) (GetRCObject(RESULT_CODE) == rcRow && GetRCState(RESULT_CODE) == rcNotFound)
/* EnumerateAlignments
* make an enumerator of all alignments in database
*
* "align_enum" [ OUT ] - return parameter for enumerator
*
+ * return codes:
+ * object: rcRow, state: rcNotFound - if there is no first element
+ *
* NB - this is a BAD interface, here only to support dumping a BAM file
* it may not be available under all circumstances
*/
@@ -179,6 +193,9 @@ ALIGN_EXTERN rc_t CC AlignAccessDBEnumerateAlignments ( const AlignAccessDB *sel
*
* "pos" [ IN ] and "wsize" [ IN ] - starting position and size of window
* on reference sequence
+ *
+ * return codes:
+ * object: rcRow, state: rcNotFound - if there is no first element
*/
ALIGN_EXTERN rc_t CC AlignAccessDBWindowedAlignments ( const AlignAccessDB *self,
AlignAccessAlignmentEnumerator **align_enum, const char *refseq_id,
@@ -194,6 +211,9 @@ ALIGN_EXTERN rc_t CC AlignAccessAlignmentEnumeratorRelease ( const AlignAccessAl
/* Next
* advance the enumerator to the next element
+ *
+ * return codes:
+ * object: rcRow, state: rcNotFound - if there is no next element
*/
ALIGN_EXTERN rc_t CC AlignAccessAlignmentEnumeratorNext ( const AlignAccessAlignmentEnumerator *self );
diff --git a/interfaces/align/bam.h b/interfaces/align/bam.h
index 8be9a8d..fafd578 100644
--- a/interfaces/align/bam.h
+++ b/interfaces/align/bam.h
@@ -351,6 +351,10 @@ ALIGN_EXTERN rc_t CC BAMAlignmentGetCigar ( const BAMAlignment *self,
*/
ALIGN_EXTERN rc_t CC BAMAlignmentGetInsertSize ( const BAMAlignment *self, int64_t *size );
+ALIGN_EXTERN rc_t CC BAMAlignmentFormatSAM(const BAMAlignment *self,
+ size_t *actsize,
+ size_t maxsize,
+ char *buffer);
/* OptDataForEach
* DANGER
@@ -371,7 +375,9 @@ enum BAMOptDataValueTypes
dt_INT = 'i',
dt_UINT = 'I',
dt_FLOAT32 = 'f',
- dt_FLOAT64 = 'd',
+#if 0
+ dt_FLOAT64 = 'd', /* removed? not in Dec 19 2013 version of SAMv1.pdf */
+#endif
dt_ASCII = 'A',
dt_HEXSTRING = 'H',
dt_NUM_ARRAY = 'B'
@@ -590,6 +596,24 @@ ALIGN_EXTERN float CC BAMFileGetProportionalPosition ( const BAMFile *self );
*/
ALIGN_EXTERN rc_t CC BAMFileRead ( const BAMFile *self, const BAMAlignment **result );
+
+/* Read
+ * read an aligment
+ *
+ * "result" [ OUT ] - return param for BAMAlignment object
+ * must be released with BAMAlignmentRelease, is invalidated or contents
+ * change on next call to BAMFileRead2. Unlike with BAMFileRead, no attempt is
+ * made to preserve this object.
+ *
+ * returns:
+ * RC(..., ..., ..., rcRow, rcNotFound) at end
+ * RC(..., ..., ..., rcRow, rcInvalid) and RC(..., ..., ..., rcRow, rcEmpty)
+ * are not fatal and are resumable
+ *
+ * tries to use static buffers and will log messages about parsing errors
+ */
+ALIGN_EXTERN rc_t CC BAMFileRead2 ( const BAMFile *self, const BAMAlignment **result );
+
/* Rewind
* reset the position back to the first aligment in the file
diff --git a/interfaces/align/reader-refseq.h b/interfaces/align/reader-refseq.h
index e7c4ac1..8fbd017 100644
--- a/interfaces/align/reader-refseq.h
+++ b/interfaces/align/reader-refseq.h
@@ -34,14 +34,17 @@
extern "C" {
#endif
+struct VDBManager;
+struct VTable;
+
enum ETableReaderRefSeq_Options {
errefseq_4NA = 0x01 /* read in INSDC:4na:bin, INSDC:dna:text is default */
};
typedef struct TableReaderRefSeq TableReaderRefSeq;
-ALIGN_EXTERN rc_t CC TableReaderRefSeq_MakeTable(const TableReaderRefSeq** cself, const VDBManager* vmgr,
- const VTable* table, uint32_t options, size_t cache);
+ALIGN_EXTERN rc_t CC TableReaderRefSeq_MakeTable(const TableReaderRefSeq** cself, const struct VDBManager* vmgr,
+ const struct VTable* table, uint32_t options, size_t cache);
ALIGN_EXTERN rc_t CC TableReaderRefSeq_MakePath(const TableReaderRefSeq** cself, const VDBManager* vmgr,
const char* path, uint32_t options, size_t cache);
diff --git a/interfaces/align/writer-reference.h b/interfaces/align/writer-reference.h
index 2e9a190..e5fae09 100644
--- a/interfaces/align/writer-reference.h
+++ b/interfaces/align/writer-reference.h
@@ -98,12 +98,6 @@ ALIGN_EXTERN rc_t CC ReferenceMgr_Compress(const ReferenceMgr* cself, uint32_t o
const void* allele_cigar, uint32_t allele_cigar_len,
TableWriterAlgnData* data);
-/* After calling ReferenceMgr_Compress, ReferenceMgr_CompressHelper
- * can be used to compress other byte-sized arrays
- */
-ALIGN_EXTERN size_t CC ReferenceMgr_CompressHelper(uint8_t cmp_rslt[],
- TableWriterAlgnData const *const data,
- uint8_t const input[]);
/* Read refseq chunk of 'len' bases into provided 'buffer' (must be enough big for len);
ref_len - on return has number of bases written to the buffer
@@ -120,6 +114,13 @@ ALIGN_EXTERN rc_t CC ReferenceSeq_Compress(const ReferenceSeq* cself, uint32_t o
INSDC_coord_zero allele_offset, const char* allele, INSDC_coord_len allele_len,INSDC_coord_zero offset_in_allele,
const void* allele_cigar, uint32_t allele_cigar_len,
TableWriterAlgnData* data);
+
+ALIGN_EXTERN rc_t CC ReferenceSeq_TranslateOffset_int(ReferenceSeq const *const cself,
+ INSDC_coord_zero const offset,
+ int64_t *const ref_id,
+ INSDC_coord_zero *const ref_start,
+ uint64_t *const global_ref_start);
+
enum ReferenceSeqCoverageTableType {
ewrefcov_primary_table = 0,
diff --git a/interfaces/cc/gcc/i386/arch-impl.h b/interfaces/cc/gcc/i386/arch-impl.h
index 5163ddc..68c9433 100644
--- a/interfaces/cc/gcc/i386/arch-impl.h
+++ b/interfaces/cc/gcc/i386/arch-impl.h
@@ -29,6 +29,14 @@
#include <stdint.h>
+#ifndef USE_GCC_BUILTIN
+#define USE_GCC_BUILTIN 1
+#endif
+
+#if USE_GCC_BUILTIN
+#include <strings.h>
+#endif
+
#ifdef __cplusplus
extern "C" {
#endif
@@ -37,6 +45,9 @@ static __inline__
int16_t uint16_lsbit ( uint16_t self )
{
int16_t rtn;
+#if USE_GCC_BUILTIN
+ rtn = ( int16_t ) __builtin_ffs ( self ) - 1;
+#else
__asm__ __volatile__
(
"bsf %%ax, %%ax;"
@@ -46,6 +57,7 @@ int16_t uint16_lsbit ( uint16_t self )
: "=a" ( rtn )
: "a" ( self )
);
+#endif
return rtn;
}
@@ -53,6 +65,9 @@ static __inline__
int32_t uint32_lsbit ( uint32_t self )
{
int32_t rtn;
+#if USE_GCC_BUILTIN
+ rtn = __builtin_ffs ( self ) - 1;
+#else
__asm__ __volatile__
(
"bsf %%eax, %%eax;"
@@ -62,6 +77,7 @@ int32_t uint32_lsbit ( uint32_t self )
: "=a" ( rtn )
: "a" ( self )
);
+#endif
return rtn;
}
diff --git a/interfaces/cc/gcc/x86_64/arch-impl.h b/interfaces/cc/gcc/x86_64/arch-impl.h
index 7008721..1773d72 100644
--- a/interfaces/cc/gcc/x86_64/arch-impl.h
+++ b/interfaces/cc/gcc/x86_64/arch-impl.h
@@ -29,6 +29,21 @@
#include <stdint.h>
+/* Intel versions from 11.0 through 13.0 mangle certain shift
+ * statements in inline assembly. */
+#if defined(__INTEL_COMPILER) && __INTEL_COMPILER_BUILD_DATE >= 20090131 \
+ && __INTEL_COMPILER_BUILD_DATE < 20130607
+# define HAVE_ICC_SHIFT_BUG 1
+#endif
+
+#ifndef USE_GCC_BUILTIN
+#define USE_GCC_BUILTIN 1
+#endif
+
+#if USE_GCC_BUILTIN
+#include <strings.h>
+#endif
+
#ifdef __cplusplus
extern "C" {
#endif
@@ -37,6 +52,9 @@ static __inline__
int16_t uint16_lsbit ( uint16_t self )
{
int16_t rtn;
+#if USE_GCC_BUILTIN
+ rtn = ( int16_t ) __builtin_ffs ( self ) - 1;
+#else
__asm__ __volatile__
(
"bsf %%ax, %%ax;"
@@ -46,6 +64,7 @@ int16_t uint16_lsbit ( uint16_t self )
: "=a" ( rtn )
: "a" ( self )
);
+#endif
return rtn;
}
@@ -53,6 +72,9 @@ static __inline__
int32_t uint32_lsbit ( uint32_t self )
{
int32_t rtn;
+#if USE_GCC_BUILTIN
+ rtn = __builtin_ffs ( self ) - 1;
+#else
__asm__ __volatile__
(
"bsf %%eax, %%eax;"
@@ -62,6 +84,7 @@ int32_t uint32_lsbit ( uint32_t self )
: "=a" ( rtn )
: "a" ( self )
);
+#endif
return rtn;
}
@@ -260,6 +283,13 @@ void uint128_not ( uint128_t *self )
static __inline__
void uint128_shr ( uint128_t *self, uint32_t i )
{
+#ifdef HAVE_ICC_SHIFT_BUG
+ if (i > 0) {
+ self->lo >>= i;
+ self->lo |= self->hi << (64 - i);
+ self->hi >>= i;
+ }
+#else
__asm__ __volatile__
(
"mov %%esi, %%ecx;"
@@ -271,6 +301,7 @@ void uint128_shr ( uint128_t *self, uint32_t i )
: "D" ( self ), "S" ( i )
: "%rax", "%rcx"
);
+#endif
}
static __inline__
diff --git a/interfaces/cc/vc++/stdint.h b/interfaces/cc/vc++/stdint.h
index 057374c..44c124d 100644
--- a/interfaces/cc/vc++/stdint.h
+++ b/interfaces/cc/vc++/stdint.h
@@ -37,81 +37,12 @@ extern "C" {
#define __inline__ __inline
#endif
-typedef __int8 int8_t;
-typedef __int16 int16_t;
-typedef __int32 int32_t;
-typedef __int64 int64_t;
-
-typedef unsigned __int8 uint8_t;
-typedef unsigned __int16 uint16_t;
-typedef unsigned __int32 uint32_t;
-typedef unsigned __int64 uint64_t;
-
-#ifndef INT8_MAX
-#define INT8_MAX _I8_MAX
-#endif
-
-#ifndef INT8_MIN
-#define INT8_MIN _I8_MIN
-#endif
-
-#ifndef UINT8_MAX
-#define UINT8_MAX _UI8_MAX
-#endif
-
-#ifndef INT16_MAX
-#define INT16_MAX _I16_MAX
-#endif
-
-#ifndef INT16_MIN
-#define INT16_MIN _I16_MIN
-#endif
-
-#ifndef UINT16_MAX
-#define UINT16_MAX _UI16_MAX
-#endif
-
-#ifndef INT32_MAX
-#define INT32_MAX _I32_MAX
-#endif
-
-#ifndef INT32_MIN
-#define INT32_MIN _I32_MIN
-#endif
-
-#ifndef UINT32_MAX
-#define UINT32_MAX _UI32_MAX
-#endif
-
-#ifndef INT64_MAX
-#define INT64_MAX _I64_MAX
-#endif
-
-#ifndef INT64_MIN
-#define INT64_MIN _I64_MIN
-#endif
-
-#ifndef UINT64_MAX
-#define UINT64_MAX _UI64_MAX
-#endif
-
-#ifndef SIZE_T_MAX
-#define SIZE_T_MAX ((size_t)(-(1ULL)))
-#endif
-
-#if !defined(__cplusplus) || defined(__STDC_CONSTANT_MACROS)
-#ifndef UINT64_C
-#define UINT64_C(x) (x ## ULL)
-#endif
-#ifndef INT64_C
-#define INT64_C(x) (x ## LL)
-#endif
-#endif
-
#ifndef __func__
#define __func__ __FUNCTION__
#endif
+#include <../include/stdint.h>
+
#ifdef __cplusplus
}
#endif
diff --git a/interfaces/insdc/insdc.vschema b/interfaces/insdc/insdc.vschema
index e344869..47fdf63 100644
--- a/interfaces/insdc/insdc.vschema
+++ b/interfaces/insdc/insdc.vschema
@@ -200,3 +200,11 @@ typedef INSDC:coord:val INSDC:coord:one;
// POSITION types for relating bases to their location in signal
typedef INSDC:coord:zero INSDC:position:zero;
typedef INSDC:coord:one INSDC:position:one;
+
+// one-based coordinate limits
+const INSDC:coord:one INSDC:coord:min:one = 0x80000001;
+const INSDC:coord:one INSDC:coord:max:one = 0x3FFFFFFF;
+
+// zero-based coordinate limits
+const INSDC:coord:zero INSDC:coord:min:zero = 0x80000000;
+const INSDC:coord:zero INSDC:coord:max:zero = 0x3FFFFFFE;
diff --git a/interfaces/klib/callconv.h b/interfaces/kfc/callconv.h
similarity index 95%
copy from interfaces/klib/callconv.h
copy to interfaces/kfc/callconv.h
index 043f211..17bdd53 100644
--- a/interfaces/klib/callconv.h
+++ b/interfaces/kfc/callconv.h
@@ -24,8 +24,8 @@
*
*/
-#ifndef _h_klib_callconv_
-#define _h_klib_callconv_
+#ifndef _h_kfc_callconv_
+#define _h_kfc_callconv_
#ifdef __cplusplus
extern "C" {
@@ -50,4 +50,4 @@ extern "C" {
}
#endif
-#endif /* _h_klib_callconv_ */
+#endif /* _h_kfc_callconv_ */
diff --git a/interfaces/kfc/ctx.h b/interfaces/kfc/ctx.h
new file mode 100644
index 0000000..20f7a78
--- /dev/null
+++ b/interfaces/kfc/ctx.h
@@ -0,0 +1,214 @@
+/*===========================================================================
+ *
+ * PUBLIC DOMAIN NOTICE
+ * National Center for Biotechnology Information
+ *
+ * This software/database is a "United States Government Work" under the
+ * terms of the United States Copyright Act. It was written as part of
+ * the author's official duties as a United States Government employee and
+ * thus cannot be copyrighted. This software/database is freely available
+ * to the public for use. The National Library of Medicine and the U.S.
+ * Government have not placed any restriction on its use or reproduction.
+ *
+ * Although all reasonable efforts have been taken to ensure the accuracy
+ * and reliability of the software and data, the NLM and the U.S.
+ * Government do not and cannot warrant the performance or results that
+ * may be obtained by using this software or data. The NLM and the U.S.
+ * Government disclaim all warranties, express or implied, including
+ * warranties of performance, merchantability or fitness for any particular
+ * purpose.
+ *
+ * Please cite the author in any work or product based on this material.
+ *
+ * ===========================================================================
+ *
+ */
+
+#ifndef _h_kfc_ctx_
+#define _h_kfc_ctx_
+
+#ifndef _h_kfc_extern_
+#include <kfc/extern.h>
+#endif
+
+#ifndef _h_kfc_defs_
+#include <kfc/defs.h>
+#endif
+
+#ifndef _h_kfc_rc_
+#include <kfc/rc.h>
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+
+/*--------------------------------------------------------------------------
+ * forwards
+ */
+struct KRsrc;
+
+
+/*--------------------------------------------------------------------------
+ * KSourceLoc
+ * holds a static block identifying module, file and file extension.
+ * by including this file in a source compilation, a static block
+ * called "s_src_loc" will be automatically defined.
+ */
+typedef struct KSourceLoc KSourceLoc;
+struct KSourceLoc
+{
+ const char * mod;
+ const char * file;
+ const char * ext;
+};
+
+#ifndef SRC_LOC_DEFINED
+static KSourceLoc s_src_loc = { __mod__, __file__, __fext__ };
+#define SRC_LOC_DEFINED 1
+#endif
+
+
+/*--------------------------------------------------------------------------
+ * KFuncLoc
+ * holds a static block identifying function and source file.
+ */
+typedef struct KFuncLoc KFuncLoc;
+struct KFuncLoc
+{
+ const KSourceLoc * src;
+ const char * func;
+ rc_t rc_context;
+};
+
+#define DECLARE_FUNC_LOC( rc_mod, rc_targ, rc_ctx ) \
+ static KFuncLoc s_func_loc = \
+ { & s_src_loc, __func__, RAW_CTX ( rc_mod, rc_targ, rc_ctx ) }
+
+
+/*--------------------------------------------------------------------------
+ * ctx_t
+ * modified from vdb-3
+ */
+typedef struct KCtx KCtx;
+struct KCtx
+{
+ struct KRsrc const * rsrc;
+ const KFuncLoc * loc;
+ const KCtx * caller;
+
+ /* here for hybrid-mode */
+ volatile rc_t rc;
+
+ /* set to true when an annotation/error
+ occurs - propagated up stack until stop */
+ volatile bool annotated;
+ volatile bool error;
+
+ /* set to true when an annotation/error
+ arrives at a stack frame with a previous
+ annotation or error - used as a marker
+ for clearing annotations/errors */
+ volatile bool clear_annot_stop;
+ volatile bool clear_error_stop;
+};
+
+/* assert
+ * rsrc_assert
+ */
+#define ctx_assert( ctx ) \
+ assert ( ctx != NULL )
+#define ctx_rsrc_assert( ctx ) \
+ ctx_assert ( ctx ); \
+ assert ( ctx -> rsrc != NULL )
+
+
+/* init
+ * initialize local context block
+ * performs a particular contortion to allow:
+ * a) initialization of a local ctx_t block
+ * b) reassignment of "ctx" pointer to new block
+ * c) use as an initializer to allow declarations to follow
+ */
+static __inline__
+KCtx ctx_init ( KCtx * new_ctx, ctx_t * ctxp, const KFuncLoc * func_loc )
+{
+ /* extract caller's ctx pointer */
+ ctx_t ctx = * ctxp;
+
+ /* construct a local copy of ctx_t as return value
+ allow compiler to zero trailing members more
+ efficiently than by explicit initialization */
+ KCtx local_ctx = { ctx -> rsrc, func_loc, ctx };
+
+ /* reassign the "ctx" pointer for stack frame */
+ * ctxp = new_ctx;
+
+ /* "return" the new block - a noop that permits
+ use of this function as an initializer, and
+ further declarations of local variables */
+ return local_ctx;
+}
+
+
+/* FUNC_ENTRY
+ * establishes context within a function
+ * legal to use wherever a normal declaration is allowed
+ */
+#define FUNC_ENTRY( ctx, rc_mod, rc_targ, rc_ctx ) \
+ DECLARE_FUNC_LOC ( rc_mod, rc_targ, rc_ctx ); \
+ KCtx local_ctx = ctx_init ( & local_ctx, & ( ctx ), & s_func_loc )
+
+
+/* POP_CTX [ RESERVED USAGE ]
+ * unlinks ctx for a stack frame
+ * used ONLY for code that wants to remove itself from call chain
+ * after having executed FUNC_ENTRY, i.e. for thunk operations
+ *
+ * normally, a thunk or other piece of code that does not want
+ * to participate in the call chain ctx linkage would simply
+ * avoid using FUNC_ENTRY. however, this can be dangerous if any
+ * errors occur during operation.
+ *
+ * to handle this condition, a thunk-like function can use
+ * FUNC_ENTRY in a normal fashion, but unlink with POP_CTX
+ * just prior to calling through to the next function, usually
+ * as a tail-call.
+ */
+#define POP_CTX( ctx ) \
+ ctx = ctx -> caller
+
+
+/* recover
+ * queries thread for previously stored KRsrc block
+ * creates a new one if necessary
+ * ensures that requested resources are present
+ * initializes a local ctx_t
+ * see <kfc/rsrc.h> for bitfield definitions
+ */
+KFC_EXTERN ctx_t CC ctx_recover ( KCtx * new_ctx,
+ const KFuncLoc * func_loc, uint32_t rsrc_bits );
+
+
+/* HYBRID_FUNC_ENTRY
+ * recovers or creates thread-specific KRsrc block
+ * initializes a local ctx_t
+ * declares a local ctx pointer variable
+ *
+ * "bits" [ BITFIELD, DFLT ZERO ] - optional bits for requesting resource caps
+ * normally, the resources available would be determined in KMane + KMain, but
+ * for the hybrid approach when being used without KMain, we need to be able
+ * to create a resource block out of nothing. these bits assist in so doing.
+ * ( see <kfc/rsrc.h> for bitfield definitions )
+ */
+#define HYBRID_FUNC_ENTRY( rc_mod, rc_targ, rc_ctx, bits ) \
+ KCtx local_ctx; \
+ DECLARE_FUNC_LOC ( rc_mod, rc_targ, rc_ctx ); \
+ ctx_t ctx = ctx_recover ( & local_ctx, & s_func_loc, bits )
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* _h_kfc_ctx_ */
diff --git a/interfaces/klib/defs.h b/interfaces/kfc/defs.h
similarity index 65%
copy from interfaces/klib/defs.h
copy to interfaces/kfc/defs.h
index 1872442..d790a4c 100644
--- a/interfaces/klib/defs.h
+++ b/interfaces/kfc/defs.h
@@ -24,15 +24,17 @@
*
*/
-#ifndef _h_klib_defs_
-#define _h_klib_defs_
+#ifndef _h_kfc_defs_
+#define _h_kfc_defs_
-#ifndef _h_klib_callconv_
-#include <klib/callconv.h>
+#ifndef _h_kfc_callconv_
+#include <kfc/callconv.h>
#endif
#include <stdint.h>
#include <stddef.h>
+#include <stdlib.h>
+#include <assert.h>
#ifdef __cplusplus
extern "C" {
@@ -41,54 +43,68 @@ extern "C" {
#endif
/*--------------------------------------------------------------------------
- * rc_t
- * upon success, all functions will return code 0
- * other codes indicate failure or additional status information
+ * ctx_t
+ * a thread context block
*/
-typedef uint32_t rc_t;
+typedef struct KCtx const * ctx_t;
+
+
+/*--------------------------------------------------------------------------
+ * xobj_t
+ * describes the type of object having problems
+ */
+typedef struct { const char *name; } const xobj_t [ 1 ];
/*--------------------------------------------------------------------------
- * bitsz_t
- * where size_t always denotes a quantity of bytes,
- * bitsz_t denotes a quantity of bits.
+ * xstate_t
+ * describes the state of an object having problems
*/
-typedef uint64_t bitsz_t;
+typedef struct { const char *name; } const xstate_t [ 1 ];
/*--------------------------------------------------------------------------
- * fptr_t
- * "generic" function pointer type
- * has very little real use other than to calm down compilers
+ * xc_t
+ * describes a class of error
*/
-typedef int ( CC * fptr_t ) ( void );
+typedef struct { const char *name; } const xc_t [ 1 ];
/*--------------------------------------------------------------------------
- * remove_t
- * usually when message signatures change, the compiler can
- * and will pick up the changes and trigger an error. sometimes
- * it will just issue a warning, and other times will not pick
- * up on the significance of a change.
- *
- * to ensure that a change of signature gets caught everywhere
- * by the compiler, we can introduce an extra parameter that
- * causes us to visit all dependent code.
+ * under normal usage, the declarations below will create simple externs.
+ * however, they may be redefined to create static objects
*/
-typedef struct remove_t remove_t;
+#ifndef XC_DEFINE
+
+#define XOBJ( name, desc, rc ) \
+ extern xobj_t name
+#define XOBJ_EXT( name, supr, desc, rc ) \
+ extern xobj_t name
+
+#define XSTATE( name, desc, rc ) \
+ extern xstate_t name
+#define XSTATE_EXT( name, supr, desc, rc ) \
+ extern xstate_t name
+
+#define XC( name, obj, state ) \
+ extern xc_t name
+#define XC_EXT( name, supr ) \
+ extern xc_t name
+
+#endif /* XC_DEFINE */
/*--------------------------------------------------------------------------
- * KTime_t
- * 64 bit time_t
- * operations are declared in <klib/time.h>
+ * rc_t - VDB.2 LEGACY
+ * upon success, all functions will return code 0
+ * other codes indicate failure or additional status information
*/
-typedef int64_t KTime_t;
+typedef uint32_t rc_t;
/*--------------------------------------------------------------------------
- * ver_t
- * 32 bit 4 part type
+ * ver_t - VDB.2 LEGACY
+ * 32 bit 3 part type
*/
typedef uint32_t ver_t;
@@ -112,13 +128,6 @@ typedef uint32_t ver_t;
/*--------------------------------------------------------------------------
- * KCreateMode
- * values are defined in <kfs/defs.h>
- */
-typedef uint32_t KCreateMode;
-
-
-/*--------------------------------------------------------------------------
* stringize
* it is useful to be able to convert PP defines on the command line
*/
@@ -143,41 +152,8 @@ typedef uint32_t KCreateMode;
#define __fext__ stringize ( __file_ext__ )
#endif
-
-#if 1
-
-/*--------------------------------------------------------------------------
- * LPFX
- * SHLX
- * MODX
- * take their input from make
- */
-#ifndef LIBPREFIX
- #define LPFX ""
-#else
- #define LPFXSTR2( str ) # str
- #define LPFXSTR( str ) LPFXSTR2 ( str )
- #define LPFX LPFXSTR ( LIBPREFIX )
-#endif
-#ifndef SHLIBEXT
- #define SHLX ""
-#else
- #define SHLXSTR2( str ) "." # str
- #define SHLXSTR( str ) SHLXSTR2 ( str )
- #define SHLX SHLXSTR ( SHLIBEXT )
-#endif
-#ifndef MODEXT
- #define MODX SHLX
-#else
- #define MODXSTR2( str ) "." # str
- #define MODXSTR( str ) MODXSTR2 ( str )
- #define MODX MODXSTR ( MODIBEXT )
-#endif
-
-#endif
-
#ifdef __cplusplus
}
#endif
-#endif /* _h_klib_defs_ */
+#endif /* _h_kfc_defs_ */
diff --git a/interfaces/kfc/except.h b/interfaces/kfc/except.h
new file mode 100644
index 0000000..ed6e535
--- /dev/null
+++ b/interfaces/kfc/except.h
@@ -0,0 +1,149 @@
+/*===========================================================================
+ *
+ * PUBLIC DOMAIN NOTICE
+ * National Center for Biotechnology Information
+ *
+ * This software/database is a "United States Government Work" under the
+ * terms of the United States Copyright Act. It was written as part of
+ * the author's official duties as a United States Government employee and
+ * thus cannot be copyrighted. This software/database is freely available
+ * to the public for use. The National Library of Medicine and the U.S.
+ * Government have not placed any restriction on its use or reproduction.
+ *
+ * Although all reasonable efforts have been taken to ensure the accuracy
+ * and reliability of the software and data, the NLM and the U.S.
+ * Government do not and cannot warrant the performance or results that
+ * may be obtained by using this software or data. The NLM and the U.S.
+ * Government disclaim all warranties, express or implied, including
+ * warranties of performance, merchantability or fitness for any particular
+ * purpose.
+ *
+ * Please cite the author in any work or product based on this material.
+ *
+ * ===========================================================================
+ *
+ */
+
+#ifndef _h_kfc_except_
+#define _h_kfc_except_
+
+#ifndef _h_kfc_defs_
+#include <kfc/defs.h>
+#endif
+
+#undef ERROR
+#undef FAILED
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+
+/*--------------------------------------------------------------------------
+ * exception-related macros
+ */
+
+/* xc_sev_t
+ * severity
+ */
+typedef enum xc_sev_t { xc_sev_system, xc_sev_internal, xc_sev_user } xc_sev_t;
+
+
+/* ANNOTATE
+ * make some annotation
+ * but not an error
+ */
+void ctx_annotate ( ctx_t ctx, uint32_t lineno, const char *msg, ... );
+#define ANNOTATE( ... ) \
+ ctx_annotate ( ctx, __LINE__, __VA_ARGS__ )
+
+
+/* ERROR
+ * make an annotation
+ * record an error as an xc_t
+ */
+void ctx_error ( ctx_t ctx, uint32_t lineno, xc_sev_t sev, xc_t xc, const char *msg, ... );
+#define SYSTEM_ERROR( xc, ... ) \
+ ctx_error ( ctx, __LINE__, xc_sev_system, xc, __VA_ARGS__ )
+#define INTERNAL_ERROR( xc, ... ) \
+ ctx_error ( ctx, __LINE__, xc_sev_internal, xc, __VA_ARGS__ )
+#define USER_ERROR( xc, ... ) \
+ ctx_error ( ctx, __LINE__, xc_sev_user, xc, __VA_ARGS__ )
+
+
+/* ABORT
+ * make an annotation
+ * record an error as an x_t
+ * exit thread ( actually, exit process )
+ */
+void ctx_abort ( ctx_t ctx, uint32_t lineno, xc_t xc, const char *msg, ... );
+#define ABORT( xc, ... ) \
+ ctx_abort ( ctx, __LINE__, xc, __VA_ARGS__ )
+#define FATAL_ERROR( xc, ... ) \
+ ctx_abort ( ctx, __LINE__, xc, __VA_ARGS__ )
+
+
+/* FAILED
+ * a test of rc within ctx_t
+ */
+#define FAILED() \
+ ( ctx -> error != false )
+
+
+/* TRY
+ * another C language "try" macro
+ */
+#define TRY( expr ) \
+ expr; \
+ if ( ! FAILED () )
+
+
+/* CATCH
+ * attempts to catch rc on certain types
+ */
+bool ctx_xc_isa ( xc_t xc );
+bool ctx_xstate_isa ( xstate_t xs );
+bool ctx_xobj_isa ( xobj_t xs );
+
+#define CATCH( xc ) \
+ else if ( ctx_xc_isa ( xc ) )
+#define CATCH_OBJ( xo ) \
+ else if ( ctx_xobj_isa ( xo ) )
+#define CATCH_STATE( xs ) \
+ else if ( ctx_xstate_isa ( xs ) )
+#define CATCH_ALL() \
+ else
+
+
+/* ON_FAIL
+ * reverses TRY logic
+ * generally used for less-structured code,
+ * e.g. ON_FAIL ( x ) return y;
+ */
+#define ON_FAIL( expr ) \
+ expr; \
+ if ( FAILED () )
+
+
+/* CLEAR
+ * clears annotation and error
+ * used from within CATCH handler
+ */
+void ctx_clear_all ( ctx_t ctx );
+#define CLEAR() \
+ ctx_clear_all ( ctx )
+
+
+/* CLEAR_ERR
+ * clears just error state, leaving any annotation
+ */
+void ctx_clear_error ( ctx_t ctx );
+#define CLEAR_ERR() \
+ ctx_clear_error ( ctx )
+
+#ifdef __cplusplus
+}
+#endif
+
+
+#endif /* _h_kfc_except_ */
diff --git a/interfaces/klib/extern.h b/interfaces/kfc/extern.h
similarity index 84%
copy from interfaces/klib/extern.h
copy to interfaces/kfc/extern.h
index 92727f0..0f9e9bf 100644
--- a/interfaces/klib/extern.h
+++ b/interfaces/kfc/extern.h
@@ -24,27 +24,21 @@
*
*/
-#ifndef _h_klib_extern_
-#define _h_klib_extern_
+#ifndef _h_kfc_extern_
+#define _h_kfc_extern_
-#ifndef _h_klib_callconv_
-#include <klib/callconv.h>
+#ifndef _h_kfc_callconv_
+#include <kfc/callconv.h>
#endif
#if ! defined EXPORT_LATCH && _LIBRARY
-#define KLIB_EXTERN LIB_EXPORT
-#define KLIB_EXTERN_DATA extern LIB_EXPORT
+#define KFC_EXTERN LIB_EXPORT
#define EXPORT_LATCH 1
#else
-#define KLIB_EXTERN LIB_IMPORT
-#ifdef __cplusplus
-#define KLIB_EXTERN_DATA extern /* LIB_IMPORT_DATA */
-#else
-#define KLIB_EXTERN_DATA LIB_IMPORT_DATA
-#endif
+#define KFC_EXTERN LIB_IMPORT
#endif
@@ -71,4 +65,4 @@
#endif
-#endif /* _h_klib_extern_ */
+#endif /* _h_kfc_extern_ */
diff --git a/interfaces/klib/rc.h b/interfaces/kfc/rc.h
similarity index 76%
copy from interfaces/klib/rc.h
copy to interfaces/kfc/rc.h
index e7ad1a4..4527445 100644
--- a/interfaces/klib/rc.h
+++ b/interfaces/kfc/rc.h
@@ -24,25 +24,8 @@
*
*/
-#ifndef _h_klib_rc_
-#define _h_klib_rc_
-
-#ifndef _h_klib_extern_
-#include <klib/extern.h>
-#endif
-
-#ifndef _h_klib_defs_
-#include <klib/defs.h>
-#endif
-
-#if _DEBUGGING
-
-#ifndef _h_compiler_
-#include <compiler.h>
-#endif
-
-#include <assert.h>
-#endif
+#ifndef _h_kfc_rc_
+#define _h_kfc_rc_
#ifdef __cplusplus
extern "C" {
@@ -76,12 +59,6 @@ extern "C" {
* other codes indicate failure or additional status information
*/
-#if _DEBUGGING && ! defined RECORD_RC_FILE_LINE
-#define RECORD_RC_FILE_LINE 1
-#elif ! defined RECORD_RC_FILE_LINE
-#define RECORD_RC_FILE_LINE 0
-#endif
-
/* RCModule
* what code module generated the error
@@ -359,125 +336,17 @@ RC_ENUM ( RCState )
RC_LAST ( rcLastState_v1_1 )
};
-#if RC_EMIT
-
-KLIB_EXTERN const char * CC GetRCFilename ( void );
-KLIB_EXTERN const char * CC GetRCFunction ( void );
-KLIB_EXTERN uint32_t CC GetRCLineno ( void );
-KLIB_EXTERN rc_t CC SetRCFileFuncLine ( rc_t rc, const char *filename, const char *funcname, uint32_t lineno );
-KLIB_EXTERN bool CC GetUnreadRCInfo ( rc_t *rc, const char **filename, const char **funcname, uint32_t *lineno );
-
-#if RECORD_RC_FILE_LINE
-
- #if defined(__SUNPRO_CC) && __SUNPRO_CC <= 0x590 && defined(__cplusplus)
-
- #define SET_RC_FILE_FUNC_LINE( rc ) \
- SetRCFileFuncLine ( ( rc ), __FILE__, "(unknown)", __LINE__ )
-
- #else
-
- #define SET_RC_FILE_FUNC_LINE( rc ) \
- SetRCFileFuncLine ( ( rc ), __FILE__, __func__, __LINE__ )
-
- #endif
-
-#else
-
- #define SET_RC_FILE_FUNC_LINE( rc ) \
- ( rc_t ) ( rc )
-
-#endif
-
-#ifdef assert
-#define ASSERT_MOD_TARG_CTX() \
- assert ( ( int ) rcLastModule_v1_1 < ( 1 << 5 ) ), \
- assert ( ( int ) rcLastTarget_v1_1 < ( 1 << 6 ) ), \
- assert ( ( int ) rcLastContext_v1_1 < ( 1 << 7 ) )
-
-#define ASSERT_OBJ_STATE() \
- assert ( ( int ) rcLastObject_v1_1 < ( 1 << 8 ) ), \
- assert ( ( int ) rcLastState_v1_1 < ( 1 << 6 ) )
-#else
-#define ASSERT_MOD_TARG_CTX() ( void ) 0
-
-#define ASSERT_OBJ_STATE() ( void ) 0
-#endif
-
-/* CTX
+/* RAW_CTX
* form a context from parts
*/
-#define CTX( mod, targ, ctx ) \
- ( rc_t ) ( ASSERT_MOD_TARG_CTX (), ( \
- ( ( rc_t ) ( mod ) << 27 ) | /* 5 bits */ \
- ( ( rc_t ) ( targ ) << 21 ) | /* 6 bits */ \
- ( ( rc_t ) ( ctx ) << 14 ) ) /* 7 bits */ \
- )
-
-/* RC
- * form a complete return code from parts
- */
-#define SILENT_RC( mod, targ, ctx, obj, state ) \
- ( rc_t ) ( ASSERT_OBJ_STATE (), \
- CTX ( mod, targ, ctx ) | /* 18 bits */ \
- ( ( rc_t ) ( obj ) << 6 ) | /* 8 bits */ \
- ( ( rc_t ) ( state ) ) ) /* 6 bits */
-
-#define RC( mod, targ, ctx, obj, state ) \
- ( rc_t ) ( ASSERT_OBJ_STATE (), \
- SET_RC_FILE_FUNC_LINE ( \
- CTX ( mod, targ, ctx ) | /* 18 bits */ \
- ( ( rc_t ) ( obj ) << 6 ) | /* 8 bits */ \
- ( ( rc_t ) ( state ) ) ) ) /* 6 bits */
-
-/* ResetRCContext
- * rewrite rc to reflect different context
- * typically used to pass out return codes
- */
-#define ResetRCContext( rc, mod, targ, ctx ) \
- ( ( ( rc ) & 0x3FFF ) | CTX ( mod, targ, ctx ) )
-
-/* ResetRCState
- * rewrite rc to reflect different state
- * typically used to pass out return codes
- */
-#define ResetRCState( rc, obj, state ) \
- ( ( ( rc ) & 0xFFFFFFC0 ) | ( rc_t ) ( state ) )
-
-#endif /* __cplusplus */
-
-/* GetRCModule
- * extract the module portion
- */
-#define GetRCModule( rc ) \
- ( enum RCModule ) ( ( ( rc ) >> 27 ) & 0x1F )
-
-/* GetRCTarget
- * extract the target portion
- */
-#define GetRCTarget( rc ) \
- ( enum RCTarget ) ( ( ( rc ) >> 21 ) & 0x3F )
-
-/* GetRCContext
- * extract the context portion
- */
-#define GetRCContext( rc ) \
- ( enum RCContext ) ( ( ( rc ) >> 14 ) & 0x7F )
-
-/* GetRCObject
- * extract the target object portion
- */
-#define GetRCObject( rc ) \
- ( enum RCObject ) ( ( ( rc ) >> 6 ) & 0xFF )
-
-/* GetRCState
- * extract the state portion
- */
-#define GetRCState( rc ) \
- ( enum RCState ) ( ( rc ) & 0x3F )
+#define RAW_CTX( mod, targ, ctx ) \
+ ( ( ( rc_t ) ( mod ) << 27 ) | /* 5 bits */ \
+ ( ( rc_t ) ( targ ) << 21 ) | /* 6 bits */ \
+ ( ( rc_t ) ( ctx ) << 14 ) ) /* 7 bits */
#ifdef __cplusplus
}
#endif
-#endif /* _h_klib_rc_ */
+#endif /* _h_kfc_rc_ */
diff --git a/libs/vfs/keyring-priv.h b/interfaces/kfc/rsrc.h
similarity index 55%
rename from libs/vfs/keyring-priv.h
rename to interfaces/kfc/rsrc.h
index 42fb6a0..b852e90 100644
--- a/libs/vfs/keyring-priv.h
+++ b/interfaces/kfc/rsrc.h
@@ -24,23 +24,57 @@
*
*/
-#ifndef _h_keyring_priv_
-#define _h_keyring_priv_
+#ifndef _h_kfc_rsrc_
+#define _h_kfc_rsrc_
-#ifndef _h_klib_defs_
-#include <klib/defs.h>
+#ifndef _h_kfc_defs_
+#include <kfc/defs.h>
#endif
-#ifdef __cplusplus
-extern "C" {
-#endif
+/*--------------------------------------------------------------------------
+ * forwards
+ */
+struct KMemMgr;
+struct KConfig;
+struct KDBManager;
+struct VDBManager;
+
-struct KStream;
+/*--------------------------------------------------------------------------
+ * KRsrc
+ * a very watered-down version of vdb-3 resource capabilities
+ */
+typedef struct KRsrc KRsrc;
+struct KRsrc
+{
+ struct KMemMgr * mem;
+ struct KConfig * cfg;
+ struct KDBManager * kdb;
+ struct VDBManager * vdb;
+};
-extern rc_t StartKeyRing(struct KStream** ipc);
-#ifdef __cplusplus
-}
-#endif
+/* Init
+ * initialize a local block from another
+ */
+void KRsrcInit ( KRsrc *rsrc, ctx_t ctx );
+
+
+/* Whack
+ * release references
+ */
+void KRsrcWhack ( KRsrc *self, ctx_t ctx );
+
+
+/*--------------------------------------------------------------------------
+ * KRsrcBits
+ * bitfield definitions for optional resources
+ * for use in hybrid approach of VDB-2
+ */
+enum KRsrcBits
+{
+ rbKDBManager = ( 1 << 0 ),
+ rbVDBManager = ( 1 << 1 )
+};
-#endif /* _h_keyring_priv_ */
+#endif /* _h_kfc_rsrc_ */
diff --git a/interfaces/kfc/xc.h b/interfaces/kfc/xc.h
new file mode 100644
index 0000000..c95aaa9
--- /dev/null
+++ b/interfaces/kfc/xc.h
@@ -0,0 +1,94 @@
+/*===========================================================================
+ *
+ * PUBLIC DOMAIN NOTICE
+ * National Center for Biotechnology Information
+ *
+ * This software/database is a "United States Government Work" under the
+ * terms of the United States Copyright Act. It was written as part of
+ * the author's official duties as a United States Government employee and
+ * thus cannot be copyrighted. This software/database is freely available
+ * to the public for use. The National Library of Medicine and the U.S.
+ * Government have not placed any restriction on its use or reproduction.
+ *
+ * Although all reasonable efforts have been taken to ensure the accuracy
+ * and reliability of the software and data, the NLM and the U.S.
+ * Government do not and cannot warrant the performance or results that
+ * may be obtained by using this software or data. The NLM and the U.S.
+ * Government disclaim all warranties, express or implied, including
+ * warranties of performance, merchantability or fitness for any particular
+ * purpose.
+ *
+ * Please cite the author in any work or product based on this material.
+ *
+ * ===========================================================================
+ *
+ */
+
+#ifndef _h_kfc_xc_
+#define _h_kfc_xc_
+
+#ifndef _h_kfc_extern_
+#include <kfc/extern.h>
+#endif
+
+#ifndef _h_kfc_defs_
+#include <kfc/defs.h>
+#endif
+
+
+/*--------------------------------------------------------------------------
+ * XOBJ
+ * objects that can have problems
+ */
+XOBJ ( xoSelf, "target object reference", rcSelf );
+XOBJ ( xoParam, "parameter", rcParam );
+XOBJ ( xoString, "string", rcString );
+XOBJ ( xoMemory, "process memory", rcMemory );
+XOBJ ( xoError, "error", rcNoObj );
+XOBJ ( xoBehavior, "behavior", rcFunction );
+XOBJ ( xoTable, "table", rcTable );
+XOBJ ( xoCursor, "cursor", rcCursor );
+XOBJ ( xoColumn, "column", rcColumn );
+XOBJ ( xoInteger, "integer", rcParam );
+XOBJ ( xoRow, "row", rcRow );
+
+
+/*--------------------------------------------------------------------------
+ * XSTATE
+ * states that things can be in
+ */
+XSTATE ( xsIsNull, "is null", rcNull );
+XSTATE ( xsEmpty, "is empty", rcEmpty );
+XSTATE ( xsExhausted, "exhausted", rcExhausted );
+XSTATE ( xsUnexpected, "unexpected", rcUnexpected );
+XSTATE ( xsUnimplemented, "unimplemented", rcUnknown );
+XSTATE ( xsCreateFailed, "failed to create", rcUnknown );
+XSTATE ( xsOpenFailed, "failed to open", rcUnknown );
+XSTATE ( xsNotFound, "not found", rcNotFound );
+XSTATE ( xsReadFailed, "failed to read", rcUnknown );
+XSTATE ( xsOutOfBounds, "out of bounds", rcOutofrange );
+XSTATE ( xsAccessFailed, "failed to access", rcUnknown );
+
+
+/*--------------------------------------------------------------------------
+ * XC
+ * error types
+ */
+XC ( xcSelfNull, xoSelf, xsIsNull );
+XC ( xcParamNull, xoParam, xsIsNull );
+XC ( xcStringEmpty, xoString, xsEmpty );
+XC ( xcNoMemory, xoMemory, xsExhausted );
+XC ( xcUnexpected, xoError, xsUnexpected );
+XC ( xcUnimplemented, xoBehavior, xsUnimplemented );
+XC ( xcTableOpenFailed, xoTable, xsOpenFailed );
+XC ( xcCursorCreateFailed, xoCursor, xsCreateFailed );
+XC ( xcCursorOpenFailed, xoCursor, xsOpenFailed );
+XC ( xcColumnNotFound, xoColumn, xsNotFound );
+XC ( xcColumnReadFailed, xoColumn, xsReadFailed );
+XC ( xcIntegerOutOfBounds, xoInteger, xsOutOfBounds );
+XC ( xcCursorAccessFailed, xoCursor, xsAccessFailed );
+XC ( xcRowNotFound, xoRow, xsNotFound );
+
+
+
+#endif /* _h_kfc_xc_ */
diff --git a/interfaces/kns/manager-ext.h b/interfaces/kfc/xcdefs.h
similarity index 69%
copy from interfaces/kns/manager-ext.h
copy to interfaces/kfc/xcdefs.h
index fc9e667..7d88abe 100644
--- a/interfaces/kns/manager-ext.h
+++ b/interfaces/kfc/xcdefs.h
@@ -23,11 +23,12 @@
* ===========================================================================
*
*/
-#ifndef _h_kns_manager_ext_
-#define _h_kns_manager_ext_
-#ifndef _h_kns_manager_
-#include <kns/manager.h>
+#ifndef _h_kfc_xcdefs_
+#define _h_kfc_xcdefs_
+
+#ifndef _h_kfc_defs_
+#include <kfc/defs.h>
#endif
#ifdef __cplusplus
@@ -36,24 +37,45 @@ extern "C" {
/*--------------------------------------------------------------------------
- * forwards
+ * XCObj
*/
-struct SraReleaseVersion;
+typedef struct XCObj XCObj;
+struct XCObj
+{
+ const char *name;
+ const char *desc;
+ const XCObj *dad;
+ uint32_t rc_obj;
+};
/*--------------------------------------------------------------------------
- * KNSManager
+ * XCState
*/
+typedef struct XCState XCState;
+struct XCState
+{
+ const char *name;
+ const char *desc;
+ const XCState *dad;
+ uint32_t rc_state;
+};
-/* NewReleaseVersion
- * Get release version of the new (latest available) public SRA Toolkit
- */
-KNS_EXTERN rc_t CC KNSManagerNewReleaseVersion ( const KNSManager *self,
- struct SraReleaseVersion *newVersion );
+/*--------------------------------------------------------------------------
+ * XCErr
+ */
+typedef struct XCErr XCErr;
+struct XCErr
+{
+ const char *name;
+ const XCErr *dad;
+ const XCObj *obj;
+ const XCState *state;
+};
#ifdef __cplusplus
}
#endif
-#endif /* _h_kns_manager_ext_ */
+#endif /* _h_kfc_xcdefs_ */
diff --git a/libs/kproc/bsd/syslock-priv.h b/interfaces/kfc/xcext.h
similarity index 64%
copy from libs/kproc/bsd/syslock-priv.h
copy to interfaces/kfc/xcext.h
index e7542e5..712e262 100644
--- a/libs/kproc/bsd/syslock-priv.h
+++ b/interfaces/kfc/xcext.h
@@ -24,39 +24,41 @@
*
*/
-#ifndef _h_syslock_priv_
-#define _h_syslock_priv_
+#ifndef _h_kfc_xcext_
+#define _h_kfc_xcext_
-#include <pthread.h>
+/* turn off default macros */
+#define XC_DEFINE 1
-#ifndef _h_klib_defs_
-#include <klib/defs.h>
+#ifdef _h_kfc_defs_
+#error "<kfc/defs.h> must not be included before <kfc/xcext.h>"
#endif
-#ifndef _h_atomic32_
-#include <atomic32.h>
+#ifndef _h_kfc_xcdefs_
+#include <kfc/xcdefs.h>
#endif
#ifdef __cplusplus
extern "C" {
#endif
-/*--------------------------------------------------------------------------
- * KLock
- * a POSIX-style mutual exclusion lock
- * with some facilities for timed operations
- */
-struct KLock
-{
- pthread_mutex_t mutex;
- pthread_mutex_t cond_lock;
- pthread_cond_t cond;
- uint32_t waiters;
- atomic32_t refcount;
-};
+#define XOBJ( name, desc, rc ) \
+ extern const XCObj name
+#define XOBJ_EXT( name, supr, desc, rc ) \
+ extern const XCObj name
+
+#define XSTATE( name, desc, rc ) \
+ extern const XCState name
+#define XSTATE_EXT( name, supr, desc, rc ) \
+ extern const XCState name
+
+#define XC( name, obj, state ) \
+ extern const XCErr name
+#define XC_EXT( name, supr ) \
+ extern const XCErr name
#ifdef __cplusplus
}
#endif
-#endif /* _h_syslock_priv_ */
+#endif /* _h_kfc_xcext_ */
diff --git a/interfaces/kns/url-fetcher.h b/interfaces/kfc/xcgen.h
similarity index 59%
rename from interfaces/kns/url-fetcher.h
rename to interfaces/kfc/xcgen.h
index 36ac6a7..9a64311 100644
--- a/interfaces/kns/url-fetcher.h
+++ b/interfaces/kfc/xcgen.h
@@ -23,44 +23,46 @@
* ===========================================================================
*
*/
-#ifndef _h_url_fetcher_
-#define _h_url_fetcher_
-#ifndef _h_kns_extern_
-#include <kns/extern.h>
+#ifndef _h_kfc_xcgen_
+#define _h_kfc_xcgen_
+
+#ifndef _h_kfc_xcext_
+#include <kfc/xcext.h>
#endif
-#ifndef _h_klib_defs_
-#include <klib/defs.h>
+#ifndef _h_kfc_rc_
+#include <kfc/rc.h>
#endif
#ifdef __cplusplus
extern "C" {
#endif
-/*--------------------------------------------------------------------------
- * KUrlFetcher
- * a generic way of fetching data from a url
- */
-typedef struct KUrlFetcher KUrlFetcher;
-
-/* AddRef
- * Release
- * ignores NULL references
- */
-KNS_EXTERN rc_t CC KUrlFetcherAddRef ( const KUrlFetcher *self );
-KNS_EXTERN rc_t CC KUrlFetcherRelease ( const KUrlFetcher *self );
+#undef XOBJ
+#undef XOBJ_EXT
+#undef XSTATE
+#undef XSTATE_EXT
+#undef XC
+#undef XC_EXT
-KNS_EXTERN rc_t CC KUrlFetcherRead( KUrlFetcher *self, const char *uri,
- void *dst, size_t to_read, size_t *num_read );
+#define XOBJ( name, desc, rc ) \
+ const XCObj name = { # name, desc, NULL, rc }
+#define XOBJ_EXT( name, supr, desc, rc ) \
+ const XCObj name = { # name, desc, & supr, rc }
-/* this typedef has to stay here for the virtual interface to work...*/
-typedef struct KUrlFetcherCurl KUrlFetcherCurl;
+#define XSTATE( name, desc, rc ) \
+ const XCState name = { # name, desc, NULL, rc }
+#define XSTATE_EXT( name, supr, desc, rc ) \
+ const XCState name = { # name, desc, & super, rc }
-KNS_EXTERN rc_t CC KUrlFetcherCurlMake( KUrlFetcher **fetcher, const bool verbose );
+#define XC( name, obj, state ) \
+ const XCErr name = { # name, NULL, & obj, & state }
+#define XC_EXT( name, supr ) \
+ const XCErr name = { # name, & supr }
#ifdef __cplusplus
}
#endif
-#endif
+#endif /* _h_kfc_xcgen_ */
diff --git a/interfaces/kfs/file.h b/interfaces/kfs/file.h
index 47fe143..d27a34d 100644
--- a/interfaces/kfs/file.h
+++ b/interfaces/kfs/file.h
@@ -35,12 +35,22 @@
#include <klib/defs.h>
#endif
+#ifndef _h_klib_namelist_
+#include <klib/namelist.h>
+#endif
+
#ifdef __cplusplus
extern "C" {
#endif
/*--------------------------------------------------------------------------
+ * forwards
+ */
+struct timeout_t;
+
+
+/*--------------------------------------------------------------------------
* KFileDesc
* describes basic file types
*/
@@ -73,6 +83,7 @@ typedef struct KFile KFile;
KFS_EXTERN rc_t CC KFileAddRef ( const KFile *self );
KFS_EXTERN rc_t CC KFileRelease ( const KFile *self );
+
/* RandomAccess
* ALMOST by definition, the file is random access
*
@@ -84,6 +95,7 @@ KFS_EXTERN rc_t CC KFileRelease ( const KFile *self );
*/
KFS_EXTERN rc_t CC KFileRandomAccess ( const KFile *self );
+
/* Type
* returns a KFileDesc
* not intended to be a content type,
@@ -91,6 +103,7 @@ KFS_EXTERN rc_t CC KFileRandomAccess ( const KFile *self );
*/
KFS_EXTERN uint32_t CC KFileType ( const KFile *self );
+
/* Size
* returns size in bytes of file
*
@@ -98,6 +111,7 @@ KFS_EXTERN uint32_t CC KFileType ( const KFile *self );
*/
KFS_EXTERN rc_t CC KFileSize ( const KFile *self, uint64_t *size );
+
/* SetSize
* sets size in bytes of file
*
@@ -105,7 +119,9 @@ KFS_EXTERN rc_t CC KFileSize ( const KFile *self, uint64_t *size );
*/
KFS_EXTERN rc_t CC KFileSetSize ( KFile *self, uint64_t size );
+
/* Read
+ * TimedRead
* read file from known position
*
* "pos" [ IN ] - starting position within file
@@ -115,11 +131,21 @@ KFS_EXTERN rc_t CC KFileSetSize ( KFile *self, uint64_t size );
* "num_read" [ OUT ] - return parameter giving number of bytes
* actually read. when returned value is zero and return code is
* also zero, interpreted as end of file.
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed reads. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
*/
KFS_EXTERN rc_t CC KFileRead ( const KFile *self, uint64_t pos,
void *buffer, size_t bsize, size_t *num_read );
+KFS_EXTERN rc_t CC KFileTimedRead ( const KFile *self, uint64_t pos,
+ void *buffer, size_t bsize, size_t *num_read, struct timeout_t *tm );
/* ReadAll
+ * TimedReadAll
* read from file until "bsize" bytes have been retrieved
* or until end-of-input
*
@@ -130,11 +156,42 @@ KFS_EXTERN rc_t CC KFileRead ( const KFile *self, uint64_t pos,
* "num_read" [ OUT ] - return parameter giving number of bytes
* actually read. when returned value is zero and return code is
* also zero, interpreted as end of file.
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed reads. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
*/
KFS_EXTERN rc_t CC KFileReadAll ( const KFile *self, uint64_t pos,
void *buffer, size_t bsize, size_t *num_read );
+KFS_EXTERN rc_t CC KFileTimedReadAll ( const KFile *self, uint64_t pos,
+ void *buffer, size_t bsize, size_t *num_read, struct timeout_t *tm );
+
+/* ReadExactly
+ * TimedReadExactly
+ * read from file until "bytes" have been retrieved
+ * or return incomplete transfer error
+ *
+ * "pos" [ IN ] - starting position within file
+ *
+ * "buffer" [ OUT ] and "bytes" [ IN ] - return buffer for read
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed reads. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
+ */
+KFS_EXTERN rc_t CC KFileReadExactly ( const KFile *self,
+ uint64_t pos, void *buffer, size_t bytes );
+KFS_EXTERN rc_t CC KFileTimedReadExactly ( const KFile *self,
+ uint64_t pos, void *buffer, size_t bytes, struct timeout_t *tm );
/* Write
+ * TimedWrite
* write file at known position
*
* "pos" [ IN ] - starting position within file
@@ -143,11 +200,21 @@ KFS_EXTERN rc_t CC KFileReadAll ( const KFile *self, uint64_t pos,
*
* "num_writ" [ OUT, NULL OKAY ] - optional return parameter
* giving number of bytes actually written
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed writes. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
*/
KFS_EXTERN rc_t CC KFileWrite ( KFile *self, uint64_t pos,
const void *buffer, size_t size, size_t *num_writ );
+KFS_EXTERN rc_t CC KFileTimedWrite ( KFile *self, uint64_t pos,
+ const void *buffer, size_t size, size_t *num_writ, struct timeout_t *tm );
/* WriteAll
+ * TimedWriteAll
* write to file until "size" bytes have been transferred
* or until no further progress can be made
*
@@ -157,9 +224,39 @@ KFS_EXTERN rc_t CC KFileWrite ( KFile *self, uint64_t pos,
*
* "num_writ" [ OUT, NULL OKAY ] - optional return parameter
* giving number of bytes actually written
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed writes. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
*/
KFS_EXTERN rc_t CC KFileWriteAll ( KFile *self, uint64_t pos,
const void *buffer, size_t size, size_t *num_writ );
+KFS_EXTERN rc_t CC KFileTimedWriteAll ( KFile *self, uint64_t pos,
+ const void *buffer, size_t size, size_t *num_writ, struct timeout_t *tm );
+
+/* WriteExactly
+ * TimedWriteExactly
+ * write to file until "bytes" have been transferred
+ * or return incomplete transfer error
+ *
+ * "pos" [ IN ] - starting position within file
+ *
+ * "buffer" [ IN ] and "bytes" [ IN ] - data to be written
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed writes. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
+ */
+KFS_EXTERN rc_t CC KFileWriteExactly ( KFile *self,
+ uint64_t pos, const void *buffer, size_t bytes );
+KFS_EXTERN rc_t CC KFileTimedWriteExactly ( KFile *self,
+ uint64_t pos, const void *buffer, size_t bytes, struct timeout_t *tm );
/* MakeStdIn
* creates a read-only file on stdin
@@ -173,6 +270,16 @@ KFS_EXTERN rc_t CC KFileMakeStdIn ( const KFile **std_in );
KFS_EXTERN rc_t CC KFileMakeStdOut ( KFile **std_out );
KFS_EXTERN rc_t CC KFileMakeStdErr ( KFile **std_err );
+
+KFS_EXTERN rc_t CC LoadKFileToNameList( struct KFile const * self, struct VNamelist * namelist );
+KFS_EXTERN rc_t CC LoadFileByNameToNameList( struct VNamelist * namelist, const char * filename );
+
+KFS_EXTERN rc_t CC WriteNameListToKFile( struct KFile * self, const VNamelist * namelist,
+ const char * delim );
+LIB_EXPORT rc_t CC WriteNamelistToFileByName( const VNamelist * namelist, const char * filename,
+ const char * delim );
+
+
#ifdef __cplusplus
}
#endif
diff --git a/interfaces/kfs/impl.h b/interfaces/kfs/impl.h
index 94f3636..086d2d6 100644
--- a/interfaces/kfs/impl.h
+++ b/interfaces/kfs/impl.h
@@ -108,6 +108,13 @@ struct KFile_vt_v1
uint32_t ( CC * get_type ) ( const KFILE_IMPL * self );
/* end minor version == 1 */
+ /* start minor version == 2 */
+ rc_t ( CC * timed_read ) ( const KFILE_IMPL *self, uint64_t pos,
+ void *buffer, size_t bsize, size_t *num_read, struct timeout_t *tm );
+ rc_t ( CC * timed_write ) ( KFILE_IMPL *self, uint64_t pos,
+ const void *buffer, size_t size, size_t *num_writ, struct timeout_t *tm );
+ /* end minor version == 2 */
+
/* ANY NEW ENTRIES MUST BE REFLECTED IN libs/kfs/file.c
BY BOTH THE CORRESPONDING MESSAGE DISPATCH FUNCTION(s) AND
VTABLE VALIDITY CHECKS IN KFileInit */
diff --git a/interfaces/kfs/kfs-priv.h b/interfaces/kfs/kfs-priv.h
index e7dc3de..49d0c9c 100644
--- a/interfaces/kfs/kfs-priv.h
+++ b/interfaces/kfs/kfs-priv.h
@@ -43,13 +43,12 @@ extern "C" {
/*--------------------------------------------------------------------------
* struct/class forwards
*/
+struct KArrayFile;
struct KDirectory;
-struct KSysDir;
-struct KFile;
-struct KPath;
struct KDlset;
-struct KArrayFile;
+struct KFile;
struct KNamelist;
+struct KPath;
/* MakeFDFile
* creates a file from a file-descriptor
@@ -76,24 +75,18 @@ KFS_EXTERN rc_t CC KDlsetList ( struct KDlset const *self, struct KNamelist **li
#if WINDOWS
+
/* PosixStringToSystemString
* converts posix path string to system path
* "buffer" [ OUT ] - NUL terminated system path string
* "bsize" [ IN ] - buffer length
* "path" [ IN ] - NUL terminated posix path string
*/
-KFS_EXTERN rc_t KDirectoryPosixStringToSystemString (
+KFS_EXTERN rc_t CC KDirectoryPosixStringToSystemString (
const struct KDirectory *self,
char *buffer, size_t bsize, const char *path, ... );
-#endif
-
-
-/* OSPath
- * returns a real OS path
- */
-rc_t KSysDirOSPath ( struct KSysDir const *self,
- wchar_t *real, size_t bsize, const char *path, va_list args );
+#endif
#ifdef __cplusplus
}
diff --git a/interfaces/klib/callconv.h b/interfaces/klib/callconv.h
index 043f211..34eafc6 100644
--- a/interfaces/klib/callconv.h
+++ b/interfaces/klib/callconv.h
@@ -27,27 +27,8 @@
#ifndef _h_klib_callconv_
#define _h_klib_callconv_
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*--------------------------------------------------------------------------
- * CC
- * calling convention
- * should be declared within compiler/os-specific files
- * but to make external client builds work, do so here...
- */
-#ifndef CC
- #if defined _MSC_VER
- #define CC __cdecl
- #else
- #define CC
- #endif
-#endif
-
-
-#ifdef __cplusplus
-}
+#ifndef _h_kfc_callconv_
+#include <kfc/callconv.h>
#endif
#endif /* _h_klib_callconv_ */
diff --git a/interfaces/klib/debug.h b/interfaces/klib/debug.h
index 3b321ef..7a046b4 100644
--- a/interfaces/klib/debug.h
+++ b/interfaces/klib/debug.h
@@ -102,10 +102,13 @@ extern "C" {
*/
#define MODULE_NAMES() \
- _module(APP) _module(BLAST) _module(KDB) _module(REF) _module(LEGREF) \
- _module(KFS) _module(XML) _module(VDB) _module(SRA) \
- _module(XARC) _module(ALIGN) _module(KFG) _module(KRYPTO) \
- _module(SEARCH) _module(LOADLIB) _module(VFS) _module(AES) _module(ARGS)
+ _module(AES) _module(ALIGN) _module(APP) _module(ARGS) \
+ _module(BLAST) _module(KDB) \
+ _module(KFG) _module(KFS) _module(KNS) _module(KRYPTO) \
+ _module(LEGREF) _module(LOADLIB) \
+ _module(REF) _module(SEARCH) _module(SRA) \
+ _module(VDB) _module(VFS) _module(XARC) _module(XML) \
+
#define APP_CONDITIONS() \
_condition(APP,0) _condition(APP,1) _condition(APP,2) _condition(APP,3) \
@@ -144,6 +147,9 @@ extern "C" {
_condition(KFS,TARENTRY) _condition(KFS,TAR) _condition(KFS,SRASORT) _condition(KFS,GZIP) \
_condition(KFS,DIR) _condition(KFS,COUNTER) _condition(KFS,BZIP) _condition(KFS,SYS)
+#define KNS_CONDITIONS() \
+ _condition(KNS,ERR) _condition(KNS,HTTP) _condition(KNS,MGR)
+
#define VFS_CONDITIONS() \
_condition(VFS,MGR) _condition(VFS,PATH)
diff --git a/interfaces/klib/defs.h b/interfaces/klib/defs.h
index 1872442..d28c5a5 100644
--- a/interfaces/klib/defs.h
+++ b/interfaces/klib/defs.h
@@ -27,28 +27,15 @@
#ifndef _h_klib_defs_
#define _h_klib_defs_
-#ifndef _h_klib_callconv_
-#include <klib/callconv.h>
+#ifndef _h_kfc_defs_
+#include <kfc/defs.h>
#endif
-#include <stdint.h>
-#include <stddef.h>
-
#ifdef __cplusplus
extern "C" {
-#else
-#include <stdbool.h>
#endif
/*--------------------------------------------------------------------------
- * rc_t
- * upon success, all functions will return code 0
- * other codes indicate failure or additional status information
- */
-typedef uint32_t rc_t;
-
-
-/*--------------------------------------------------------------------------
* bitsz_t
* where size_t always denotes a quantity of bytes,
* bitsz_t denotes a quantity of bits.
@@ -87,63 +74,11 @@ typedef int64_t KTime_t;
/*--------------------------------------------------------------------------
- * ver_t
- * 32 bit 4 part type
- */
-typedef uint32_t ver_t;
-
-/* GetMajor
- * return major component
- */
-#define VersionGetMajor( self ) \
- ( ( self ) >> 24 )
-
-/* GetMinor
- * return minor component
- */
-#define VersionGetMinor( self ) \
- ( ( ( self ) >> 16 ) & 0xFF )
-
-/* GetRelease
- * return release component
- */
-#define VersionGetRelease( self ) \
- ( ( self ) & 0xFFFF )
-
-
-/*--------------------------------------------------------------------------
* KCreateMode
* values are defined in <kfs/defs.h>
*/
typedef uint32_t KCreateMode;
-
-/*--------------------------------------------------------------------------
- * stringize
- * it is useful to be able to convert PP defines on the command line
- */
-#define stringize( tok ) tok_to_string ( tok )
-#define tok_to_string( tok ) # tok
-
-
-/*--------------------------------------------------------------------------
- * __mod__, __file__ and __fext__
- * these guys are slightly different from __FILE__
- * and they complement __func__
- */
-#if ! defined __mod__ && defined __mod_name__
-#define __mod__ stringize ( __mod_name__ )
-#endif
-
-#if ! defined __file__ && defined __file_name__
-#define __file__ stringize ( __file_name__ )
-#endif
-
-#if ! defined __fext__ && defined __file_ext__
-#define __fext__ stringize ( __file_ext__ )
-#endif
-
-
#if 1
/*--------------------------------------------------------------------------
diff --git a/interfaces/klib/extern.h b/interfaces/klib/extern.h
index 92727f0..39aaac5 100644
--- a/interfaces/klib/extern.h
+++ b/interfaces/klib/extern.h
@@ -27,11 +27,7 @@
#ifndef _h_klib_extern_
#define _h_klib_extern_
-#ifndef _h_klib_callconv_
-#include <klib/callconv.h>
-#endif
-
-#if ! defined EXPORT_LATCH && _LIBRARY
+#if ! defined EXPORT_LATCH && defined _LIBRARY
#define KLIB_EXTERN LIB_EXPORT
#define KLIB_EXTERN_DATA extern LIB_EXPORT
@@ -48,27 +44,8 @@
#endif
-#if defined _MSC_VER && ! _STATIC
-
-/* __declspec ( dllimport ) will cause creation of
- function pointers rather than thunks, which makes
- the code that imports unable to link statically
- against a library. we leave this symbol defined as
- "extern" to use thunks instead. as a result, all
- function addresses resolve to the thunk and not
- the actual function. */
-#define LIB_IMPORT extern
-#define LIB_IMPORT_DATA extern __declspec ( dllimport )
-#define LIB_EXPORT __declspec ( dllexport )
-#define LIB_EXPORT_DATA __declspec ( dllexport )
-
-#else
-
-#define LIB_IMPORT extern
-#define LIB_IMPORT_DATA extern
-#define LIB_EXPORT
-#define LIB_EXPORT_DATA
-
+#ifndef _h_kfc_extern_
+#include <kfc/extern.h>
#endif
#endif /* _h_klib_extern_ */
diff --git a/libs/kns/stream-priv.h b/interfaces/klib/misc.h
similarity index 81%
copy from libs/kns/stream-priv.h
copy to interfaces/klib/misc.h
index 6919869..69bd5fd 100644
--- a/libs/kns/stream-priv.h
+++ b/interfaces/klib/misc.h
@@ -24,13 +24,25 @@
*
*/
+#ifndef _h_klib_misc_
+#define _h_klib_misc_
-/* VDB.v2 is end of life, and introducing new object types is
- dangerous. For our purposes, just call a stream a file */
-#ifndef rcStream
-#define rcStream rcFile
+#ifndef _h_klib_extern_
+#include <klib/extern.h>
#endif
-#ifndef rcUrl
-#define rcUrl rcPath
+#ifndef _h_klib_defs_
+#include <klib/defs.h>
#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+KLIB_EXTERN bool CC is_iser_an_admin(void);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* _h_klib_misc_ */
diff --git a/interfaces/klib/namelist.h b/interfaces/klib/namelist.h
index 319bb26..751a172 100644
--- a/interfaces/klib/namelist.h
+++ b/interfaces/klib/namelist.h
@@ -122,6 +122,20 @@ KLIB_EXTERN rc_t CC VNamelistAppendString ( VNamelist *self, const String * src
*/
KLIB_EXTERN rc_t CC VNamelistRemove( VNamelist *self, const char* s );
+/* Remove all
+ * removes all strings from the namelist ( calls free on them internally )
+ *
+ */
+KLIB_EXTERN rc_t CC VNamelistRemoveAll( VNamelist *self );
+
+
+/* Remove string at index ( and calls fron on it internally )
+ * returns error code if index is invalid
+ *
+ */
+KLIB_EXTERN rc_t CC VNamelistRemoveIdx( VNamelist *self, uint32_t idx );
+
+
/* IndexOf
* searches linear in the namelist for the string
*
@@ -129,6 +143,8 @@ KLIB_EXTERN rc_t CC VNamelistRemove( VNamelist *self, const char* s );
*
* "found" [ OUT ] - index of the string if found
* unchanged if not found
+ *
+ * returns RC( rcCont, rcNamelist, rcSearching, rcString, rcNotFound ) if not found
*/
KLIB_EXTERN rc_t CC VNamelistIndexOf( VNamelist *self, const char* s, uint32_t *found );
diff --git a/interfaces/klib/rc.h b/interfaces/klib/rc.h
index e7ad1a4..08236ec 100644
--- a/interfaces/klib/rc.h
+++ b/interfaces/klib/rc.h
@@ -44,31 +44,6 @@
#include <assert.h>
#endif
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-
-/*--------------------------------------------------------------------------
- * under normal usage, the declarations below will create simple enums.
- * however, they may be redefined to create textual lookup tables.
- */
-#ifndef RC_ENUM
-
-#define RC_ENUM( type ) enum type
-
-#undef RC_ENTRY
-#define RC_ENTRY( id, txt ) id,
-
-#undef RC_VLAST
-#define RC_VLAST( id ) id,
-
-#undef RC_LAST
-#define RC_LAST( id ) id
-
-#define RC_EMIT 1
-
-#endif
/*--------------------------------------------------------------------------
* RC
@@ -82,282 +57,12 @@ extern "C" {
#define RECORD_RC_FILE_LINE 0
#endif
+/* actual code declarations are in <kfc/rc.h> */
+#include <kfc/rc.h>
-/* RCModule
- * what code module generated the error
- */
-RC_ENUM ( RCModule )
-{
- RC_ENTRY ( rcExe, NULL )
- RC_ENTRY ( rcRuntime, "runtime" )
- RC_ENTRY ( rcText, "text" )
- RC_ENTRY ( rcCont, "container" )
- RC_ENTRY ( rcCS, "checksum" )
- RC_ENTRY ( rcFF, "file format detection" )
- RC_ENTRY ( rcFS, "file system" )
- RC_ENTRY ( rcPS, "process system" )
- RC_ENTRY ( rcXF, "transform" )
- RC_ENTRY ( rcDB, "database" )
- RC_ENTRY ( rcVDB, "virtual database" )
- RC_ENTRY ( rcApp, "application support" )
- RC_ENTRY ( rcXML, "xml support" )
- RC_ENTRY ( rcSRA, "short read archive" )
- RC_VLAST ( rcLastModule_v1_0 )
- RC_ENTRY ( rcKFG = rcLastModule_v1_0, "configuration" )
- RC_ENTRY ( rcAlign, "alignment" )
- RC_ENTRY ( rcKrypto, "cryptographic" )
- RC_ENTRY ( rcRDBMS, "RDBMS" )
- RC_ENTRY ( rcNS, "network system" )
- RC_ENTRY ( rcVFS, "virtual file system" )
- RC_LAST ( rcLastModule_v1_1 )
-};
-
-/* RCTarget
- * describes the target object of the message
- */
-RC_ENUM ( RCTarget )
-{
- RC_ENTRY ( rcNoTarg, NULL )
- RC_ENTRY ( rcArc, "archive file" )
- RC_ENTRY ( rcToc, "file system table of contents" )
- RC_ENTRY ( rcTocEntry, "file table of contents entry" )
- RC_ENTRY ( rcArgv, "argument list" )
- RC_ENTRY ( rcAttr, "attribute" )
- RC_ENTRY ( rcBarrier, "barrier" )
- RC_ENTRY ( rcBlob, "binary large object" )
- RC_ENTRY ( rcBuffer, "buffer" )
- RC_ENTRY ( rcChar, "character" )
- RC_ENTRY ( rcColumn, "column" )
- RC_ENTRY ( rcCondition, "condition" )
- RC_ENTRY ( rcCursor, "cursor" )
- RC_ENTRY ( rcDatabase, "database" )
- RC_ENTRY ( rcDirectory, "directory" )
- RC_ENTRY ( rcDoc, "document" )
- RC_ENTRY ( rcXmlDoc, "XML document" )
- RC_ENTRY ( rcFile, "file" )
- RC_ENTRY ( rcFileDesc, "file descriptor" )
- RC_ENTRY ( rcFileFormat, "file format" )
- RC_ENTRY ( rcFunction, "function" )
- RC_ENTRY ( rcFormatter, "formatter" )
- RC_ENTRY ( rcFunctParam, "function parameter" )
- RC_ENTRY ( rcHeader, "header" )
- RC_ENTRY ( rcIndex, "index" )
- RC_ENTRY ( rcIterator, "iterator" )
- RC_ENTRY ( rcLock, "lock" )
- RC_ENTRY ( rcLog, "log" )
- RC_ENTRY ( rcMD5SumFmt, "MD5 sum file" )
- RC_ENTRY ( rcMemMap, "memory map" )
- RC_ENTRY ( rcMetadata, "metadata" )
- RC_ENTRY ( rcMgr, "manager" )
- RC_ENTRY ( rcNamelist, "name list" )
- RC_ENTRY ( rcNode, "node" )
- RC_ENTRY ( rcNumeral, "numeral" )
- RC_ENTRY ( rcPagemap, "page map" )
- RC_ENTRY ( rcPath, "path" )
- RC_ENTRY ( rcProcess, "process" )
- RC_ENTRY ( rcQueue, "queue" )
- RC_ENTRY ( rcRWLock, "read/write lock" )
- RC_ENTRY ( rcSchema, "schema" )
- RC_ENTRY ( rcSemaphore, "semaphore" )
- RC_ENTRY ( rcStorage, "storage" )
- RC_ENTRY ( rcString, "string" )
- RC_ENTRY ( rcTable, "table" )
- RC_ENTRY ( rcThread, "thread" )
- RC_ENTRY ( rcTimeout, "timeout" )
- RC_ENTRY ( rcToken, "token" )
- RC_ENTRY ( rcTree, "tree" )
- RC_ENTRY ( rcTrie, "trie" )
- RC_ENTRY ( rcType, "type" )
- RC_ENTRY ( rcVector, "vector" )
- RC_ENTRY ( rcDylib, "dynamic library" )
- RC_ENTRY ( rcExpression, "expression" )
- RC_VLAST ( rcLastTarget_v1_0 )
- RC_ENTRY ( rcProduction = rcLastTarget_v1_0, "schema production" )
- RC_ENTRY ( rcEncryptionKey, "encryption key" )
- RC_ENTRY ( rcRng, "random number generator" )
- RC_ENTRY ( rcCmd, "command" )
- RC_ENTRY ( rcData, "data" )
- RC_ENTRY ( rcQuery, "query" )
- RC_ENTRY ( rcUri, "uri" )
- RC_LAST ( rcLastTarget_v1_1 )
-};
-
-/* RCContext
- * context under which error occurred
- */
-RC_ENUM ( RCContext )
-{
- RC_ENTRY ( rcAllocating, "allocating" )
- RC_ENTRY ( rcCasting, "type-casting" )
- RC_ENTRY ( rcConstructing, "constructing" )
- RC_ENTRY ( rcDestroying, "destroying" )
- RC_ENTRY ( rcReleasing, "releasing" )
- RC_ENTRY ( rcAccessing, "accessing" )
- RC_ENTRY ( rcListing, "listing" )
- RC_ENTRY ( rcVisiting, "visiting" )
- RC_ENTRY ( rcResolving, "resolving" )
- RC_ENTRY ( rcLocking, "locking" )
- RC_ENTRY ( rcUnlocking, "unlocking" )
- RC_ENTRY ( rcRenaming, "renaming" )
- RC_ENTRY ( rcAliasing, "aliasing" )
- RC_ENTRY ( rcSelecting, "selecting" )
- RC_ENTRY ( rcProjecting, "projecting" )
- RC_ENTRY ( rcInserting, "inserting" )
- RC_ENTRY ( rcRemoving, "removing" )
- RC_ENTRY ( rcClearing, "clearing" )
- RC_ENTRY ( rcUpdating, "updating" )
- RC_ENTRY ( rcCreating, "creating" )
- RC_ENTRY ( rcOpening, "opening" )
- RC_ENTRY ( rcClosing, "closing" )
- RC_ENTRY ( rcResizing, "resizing" )
- RC_ENTRY ( rcReading, "reading" )
- RC_ENTRY ( rcWriting, "writing" )
- RC_ENTRY ( rcCommitting, "committing" )
- RC_ENTRY ( rcReverting, "reverting" )
- RC_ENTRY ( rcResetting, "resetting" )
- RC_ENTRY ( rcPersisting, "persisting" )
- RC_ENTRY ( rcFreezing, "freezing" )
- RC_ENTRY ( rcCopying, "copying" )
- RC_ENTRY ( rcConcatenating, "concatenating" )
- RC_ENTRY ( rcFormatting, "formatting" )
- RC_ENTRY ( rcPositioning, "positioning" )
- RC_ENTRY ( rcPacking, "packing" )
- RC_ENTRY ( rcUnpacking, "unpacking" )
- RC_ENTRY ( rcEncoding, "encoding" )
- RC_ENTRY ( rcDecoding,"decoding" )
- RC_ENTRY ( rcValidating, "validating" )
- RC_ENTRY ( rcExecuting, "executing" )
- RC_ENTRY ( rcHuffmanCoding, "Huffman coding" )
- RC_ENTRY ( rcReindexing, "re-indexing" )
- RC_ENTRY ( rcRegistering, "registering" )
- RC_ENTRY ( rcTokenizing, "tokenizing" )
- RC_ENTRY ( rcParsing, "parsing" )
- RC_ENTRY ( rcConverting, "converting" )
- RC_ENTRY ( rcSignaling, "signaling" )
- RC_ENTRY ( rcWaiting, "waiting" )
- RC_ENTRY ( rcAttaching, "attaching" )
- RC_ENTRY ( rcDetaching, "detaching" )
- RC_ENTRY ( rcLogging, "logging" )
- RC_ENTRY ( rcFPCoding, "floating point coding" )
- RC_ENTRY ( rcMultiplexing, "(de)multiplexing" )
- RC_ENTRY ( rcClassifying, "classifying" )
- RC_ENTRY ( rcSearching, "searching" )
- RC_ENTRY ( rcLoading, "loading" )
- RC_ENTRY ( rcEvaluating, "evaluating" )
- RC_ENTRY ( rcInflating, "inflating" )
- RC_VLAST ( rcLastContext_v1_0 )
- RC_ENTRY ( rcFlushing = rcLastContext_v1_0, "flushing" )
- RC_ENTRY ( rcAppending, "appending" )
- RC_ENTRY ( rcEncrypting, "encrypting" )
- RC_ENTRY ( rcDecrypting, "decrypting" )
- RC_ENTRY ( rcComparing, "comparing" )
- RC_ENTRY ( rcInitializing, "initializing" )
- RC_ENTRY ( rcRetrieving, "retrieving" )
- RC_ENTRY ( rcSending, "sending" )
- RC_ENTRY ( rcProcessing, "processing" )
- RC_ENTRY ( rcIdentifying, "type identifying" )
- RC_LAST ( rcLastContext_v1_1 )
-};
-
-/* RCObject
- * type of object described by state
- */
-RC_ENUM ( RCObject )
-{
- RC_ENTRY ( rcNoObj, NULL )
- RC_ENTRY ( rcLink = ( int ) rcLastTarget_v1_1, "symbolic link" )
- RC_ENTRY ( rcSelf, "self" )
- RC_ENTRY ( rcParam, "param" )
- RC_ENTRY ( rcOffset, "offset" )
- RC_ENTRY ( rcMemory, "memory" )
- RC_ENTRY ( rcName, "name" )
- RC_ENTRY ( rcFormat, "format" )
- RC_ENTRY ( rcTransfer, "transfer" )
- RC_ENTRY ( rcInterface, "interface" )
- RC_ENTRY ( rcId, "id" )
- RC_ENTRY ( rcRange, "range" )
- RC_ENTRY ( rcConstraint, "constraint" )
- RC_ENTRY ( rcByteOrder, "byte order" )
- RC_ENTRY ( rcMessage, "message" )
- RC_ENTRY ( rcTag, "tag" )
- RC_ENTRY ( rcResources, "system resources" )
- RC_ENTRY ( rcDirEntry, "directory-toc entry" )
- RC_ENTRY ( rcArcHardLink, "archive hard link" )
- RC_ENTRY ( rcRow, "row" )
- RC_ENTRY ( rcLibrary, "loadable library" )
- RC_VLAST ( rcLastObject_v1_0 )
- RC_ENTRY ( rcItem = rcLastObject_v1_0, "item" )
- RC_ENTRY ( rcMode, "mode" )
- RC_ENTRY ( rcEncryption, "encryption" )
- RC_ENTRY ( rcCrc, "crc" )
- RC_ENTRY ( rcChecksum, "checksum" )
- RC_ENTRY ( rcSeed, "seed" )
- RC_ENTRY ( rcConnection, "connection" )
- RC_ENTRY ( rcError, "error" )
- RC_ENTRY ( rcEnvironment, "environment" )
- RC_ENTRY ( rcSignalSet, "signal set" )
- RC_ENTRY ( rcSize, "size" )
- RC_ENTRY ( rcRefcount, "reference count" )
- RC_LAST ( rcLastObject_v1_1 )
-};
-
-/* RCState
- * state of object described
- */
-RC_ENUM ( RCState )
-{
- RC_ENTRY ( rcNoErr, "no error" )
- RC_ENTRY ( rcDone, "done" )
- RC_ENTRY ( rcUnknown, "unknown" )
- RC_ENTRY ( rcUnsupported, "unsupported" )
- RC_ENTRY ( rcUnexpected, "unexpected" )
- RC_ENTRY ( rcUnrecognized, "unrecognized" )
- RC_ENTRY ( rcAmbiguous, "ambiguous" )
- RC_ENTRY ( rcNull, "NULL" )
- RC_ENTRY ( rcBadVersion, "bad version" )
- RC_ENTRY ( rcDestroyed, "destroyed" )
- RC_ENTRY ( rcInvalid, "invalid" )
- RC_ENTRY ( rcCorrupt, "corrupt" )
- RC_ENTRY ( rcIncorrect, "incorrect" )
- RC_ENTRY ( rcInconsistent, "inconsistent" )
- RC_ENTRY ( rcBusy, "busy" )
- RC_ENTRY ( rcIncomplete, "incomplete" )
- RC_ENTRY ( rcInterrupted, "interrupted" )
- RC_ENTRY ( rcCanceled, "canceled" )
- RC_ENTRY ( rcEmpty, "empty" )
- RC_ENTRY ( rcExhausted, "exhausted" )
- RC_ENTRY ( rcInsufficient, "insufficient" )
- RC_ENTRY ( rcExcessive, "excessive" )
- RC_ENTRY ( rcViolated, "violated" )
- RC_ENTRY ( rcExists, "exists" )
- RC_ENTRY ( rcNotFound, "not found" )
- RC_ENTRY ( rcLocked, "locked" )
- RC_ENTRY ( rcUnlocked, "unlocked" )
- RC_ENTRY ( rcDetached, "detached" )
- RC_ENTRY ( rcDeadlock, "deadlock" )
- RC_ENTRY ( rcUnauthorized, "unauthorized" )
- RC_ENTRY ( rcReadonly, "read-only" )
- RC_ENTRY ( rcWriteonly, "write-only" )
- RC_ENTRY ( rcNoPerm, "no permission" )
- RC_ENTRY ( rcInPlaceNotAllowed, "update in-place prohibited" )
- RC_ENTRY ( rcTooShort, "too short" )
- RC_ENTRY ( rcTooLong, "too long" )
- RC_ENTRY ( rcTooBig, "too big" )
- RC_ENTRY ( rcDuplicate, "duplicate" )
- RC_ENTRY ( rcOutOfKDirectory, "path out of this KDirectory FS" )
- RC_ENTRY ( rcIgnored, "ignored" )
- RC_ENTRY ( rcOutofrange, "out of range" )
- RC_VLAST ( rcLastState_v1_0 )
- RC_ENTRY ( rcOpen = rcLastState_v1_0, "open" )
- RC_ENTRY ( rcOutoforder, "out of order" )
- RC_ENTRY ( rcNotOpen, "not open" )
- RC_ENTRY ( rcUndefined, "undefined" )
- RC_ENTRY ( rcUnequal, "unequal" )
- RC_ENTRY ( rcFailed, "failed" )
- RC_ENTRY ( rcNotAvailable, "not available" )
- RC_ENTRY ( rcWrongType, "wrong type" )
- RC_LAST ( rcLastState_v1_1 )
-};
+#ifdef __cplusplus
+extern "C" {
+#endif
#if RC_EMIT
@@ -406,12 +111,9 @@ KLIB_EXTERN bool CC GetUnreadRCInfo ( rc_t *rc, const char **filename, const cha
/* CTX
* form a context from parts
*/
-#define CTX( mod, targ, ctx ) \
- ( rc_t ) ( ASSERT_MOD_TARG_CTX (), ( \
- ( ( rc_t ) ( mod ) << 27 ) | /* 5 bits */ \
- ( ( rc_t ) ( targ ) << 21 ) | /* 6 bits */ \
- ( ( rc_t ) ( ctx ) << 14 ) ) /* 7 bits */ \
- )
+#define CTX( mod, targ, ctx ) \
+ ( rc_t ) ( ASSERT_MOD_TARG_CTX (), \
+ RAW_CTX ( mod, targ, ctx ) )
/* RC
* form a complete return code from parts
diff --git a/interfaces/klib/time.h b/interfaces/klib/time.h
index 19c5959..73760a0 100644
--- a/interfaces/klib/time.h
+++ b/interfaces/klib/time.h
@@ -66,7 +66,7 @@ struct KTime
int16_t tzoff; /* -719 .. +719 minutes from Prime Meridian */
uint8_t hour; /* 0 .. 23 */
uint8_t minute; /* 0 .. 59 */
- uint8_t second; /* 0 .. 60 : 60 used for leap seconds */
+ uint8_t second; /* 0 .. 61 : 61 used for leap seconds */
bool dst; /* true if Daylight Savings Time in effect */
};
@@ -83,6 +83,12 @@ KLIB_EXTERN const KTime* CC KTimeLocal ( KTime *kt, KTime_t ts );
KLIB_EXTERN const KTime* CC KTimeGlobal ( KTime *kt, KTime_t ts );
+/* MakeTime
+ * make a KTime_t from KTime
+ */
+KLIB_EXTERN KTime_t CC KTimeMakeTime ( const KTime *self );
+
+
#ifdef __cplusplus
}
#endif
diff --git a/interfaces/kns/KCurlRequest.h b/interfaces/kns/KCurlRequest.h
deleted file mode 100644
index abe0149..0000000
--- a/interfaces/kns/KCurlRequest.h
+++ /dev/null
@@ -1,69 +0,0 @@
-/*===========================================================================
-*
-* PUBLIC DOMAIN NOTICE
-* National Center for Biotechnology Information
-*
-* This software/database is a "United States Government Work" under the
-* terms of the United States Copyright Act. It was written as part of
-* the author's official duties as a United States Government employee and
-* thus cannot be copyrighted. This software/database is freely available
-* to the public for use. The National Library of Medicine and the U.S.
-* Government have not placed any restriction on its use or reproduction.
-*
-* Although all reasonable efforts have been taken to ensure the accuracy
-* and reliability of the software and data, the NLM and the U.S.
-* Government do not and cannot warrant the performance or results that
-* may be obtained by using this software or data. The NLM and the U.S.
-* Government disclaim all warranties, express or implied, including
-* warranties of performance, merchantability or fitness for any particular
-* purpose.
-*
-* Please cite the author in any work or product based on this material.
-*
-* ===========================================================================
-*
-*/
-#ifndef _h_kns_request_
-#define _h_kns_request_
-
-#ifndef _h_kns_extern_
-#include <kns/extern.h>
-#endif
-
-#ifndef _h_klib_defs_
-#include <klib/defs.h>
-#endif
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-
-struct String;
-struct KNSManager;
-struct KDataBuffer;
-
-struct KCurlRequest;
-
-KNS_EXTERN rc_t CC KNSManagerMakeCurlRequest( struct KNSManager const *kns_mgr, struct KCurlRequest **self, const char * url, bool verbose );
-
-KNS_EXTERN rc_t CC KCurlRequestAddRef ( const struct KCurlRequest *self );
-
-KNS_EXTERN rc_t CC KCurlRequestRelease( const struct KCurlRequest *self );
-
-KNS_EXTERN rc_t CC KCurlRequestAddFields( struct KCurlRequest *self, const char * fields );
-
-KNS_EXTERN rc_t CC KCurlRequestAddSFields( struct KCurlRequest *self, struct String const * fields );
-
-KNS_EXTERN rc_t CC KCurlRequestAddField( struct KCurlRequest *self, const char * name, const char * value );
-
-KNS_EXTERN rc_t CC KCurlRequestAddSField( struct KCurlRequest *self, struct String const * name, struct String const * value );
-
-KNS_EXTERN rc_t CC KCurlRequestPerform( struct KCurlRequest *self, struct KDataBuffer * buffer );
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
diff --git a/interfaces/kns/ascp.h b/interfaces/kns/ascp.h
index cf1bf88..eea8bda 100644
--- a/interfaces/kns/ascp.h
+++ b/interfaces/kns/ascp.h
@@ -39,52 +39,57 @@
extern "C" {
#endif
-enum {
+enum
+{
eAscpStateRunning,
eAscpStateExitSuccess,
eAscpStateExitWriteFailure,
eAscpStateExitFailure
};
-typedef rc_t TQuitting(void);
-typedef bool TProgress(uint64_t id,
- uint64_t state, uint64_t size, uint64_t percentage);
+typedef rc_t TQuitting ( void );
+typedef bool TProgress ( uint64_t id,
+ uint64_t state, uint64_t size, uint64_t percentage );
+
+typedef struct AscpOptions AscpOptions;
+struct AscpOptions
+{
+ uint64_t src_size;
+
+ uint64_t heartbeat; /* in milliseconds */
+
+ uint64_t id; /* to pass to the callback */
-typedef struct {
const char *host;
const char *user;
const char *target_rate;
/* -l MAX-RATE Set the target transfer rate in Kbps */
- bool cache_key; /* Add the server's host key to PuTTY's cache */
-
/* progress logging */
const char *name;
- uint64_t src_size;
- bool status; /* whether to call STSMSG */
-
- uint64_t heartbeat; /* in milliseconds */
-
- uint64_t id; /* to pass to the callback */
TProgress *callback;
TQuitting *quitting;
+ bool status; /* whether to call STSMSG */
+
+ bool cache_key; /* Add the server's host key to PuTTY's cache */
+
bool disabled; /* output parameter for aspera_options */
-} AscpOptions;
+};
/** status - whether to print STSMSG(1-2) - information messages
ascp_bin and private_file should be freed by the caller */
-KNS_EXTERN rc_t CC ascp_locate(const char **ascp_bin, const char **private_file,
- bool use_config, bool status);
+KNS_EXTERN rc_t CC ascp_locate ( const char **ascp_bin, const char **private_file,
+ bool use_config, bool status );
/** Get a file by running aspera ascp binary */
-KNS_EXTERN rc_t CC aspera_get(const char *ascp_bin, const char *private_file,
- const char *src, const char *dest, AscpOptions *opt);
+KNS_EXTERN rc_t CC aspera_get ( const char *ascp_bin, const char *private_file,
+ const char *src, const char *dest, AscpOptions *opt );
/** Fill AscpOptions members initialized by ascp library */
-KNS_EXTERN rc_t CC aspera_options(AscpOptions *opt);
+KNS_EXTERN rc_t CC aspera_options ( AscpOptions *opt );
#ifdef __cplusplus
diff --git a/interfaces/kns/endpoint.h b/interfaces/kns/endpoint.h
index 7c9df11..22e0df1 100644
--- a/interfaces/kns/endpoint.h
+++ b/interfaces/kns/endpoint.h
@@ -47,11 +47,12 @@ struct KNSManager;
* describe a socket endpoint
*/
-enum {
+typedef uint32_t KEndPointType;
+enum
+{
epIPV4,
epIPC
};
-typedef uint32_t KEndPointType;
#define IPC_NAME_MAX 256
@@ -65,8 +66,10 @@ struct KEndPoint
uint32_t addr;
uint16_t port;
} ipv4;
- char ipc_name[IPC_NAME_MAX];
+
+ char ipc_name [ IPC_NAME_MAX ];
} u;
+
KEndPointType type;
};
@@ -105,7 +108,8 @@ KNS_EXTERN rc_t CC KNSManagerInitDNSEndpoint ( struct KNSManager const *self,
*
* "ep" [ OUT ] - address of endpoint block to be intialized
*
- * "name" [ IN ] - IPC channel name (a POSIX path to a Unix socket, or a name of a Windows pipe)
+ * "name" [ IN ] - IPC channel name
+ * ( a POSIX path to a Unix socket, or a name of a Windows pipe )
*/
KNS_EXTERN rc_t CC KNSManagerInitIPCEndpoint ( struct KNSManager const *self,
KEndPoint *ep, struct String const * name );
diff --git a/interfaces/kns/entrez-fetcher.h b/interfaces/kns/entrez-fetcher.h
deleted file mode 100644
index 7d79cd7..0000000
--- a/interfaces/kns/entrez-fetcher.h
+++ /dev/null
@@ -1,88 +0,0 @@
-/*===========================================================================
-*
-* PUBLIC DOMAIN NOTICE
-* National Center for Biotechnology Information
-*
-* This software/database is a "United States Government Work" under the
-* terms of the United States Copyright Act. It was written as part of
-* the author's official duties as a United States Government employee and
-* thus cannot be copyrighted. This software/database is freely available
-* to the public for use. The National Library of Medicine and the U.S.
-* Government have not placed any restriction on its use or reproduction.
-*
-* Although all reasonable efforts have been taken to ensure the accuracy
-* and reliability of the software and data, the NLM and the U.S.
-* Government do not and cannot warrant the performance or results that
-* may be obtained by using this software or data. The NLM and the U.S.
-* Government disclaim all warranties, express or implied, including
-* warranties of performance, merchantability or fitness for any particular
-* purpose.
-*
-* Please cite the author in any work or product based on this material.
-*
-* ===========================================================================
-*
-*/
-#ifndef _h_entrez_fetcher_
-#define _h_entrez_fetcher_
-
-#ifndef _h_url_fetcher_
-#include <kns/url-fetcher.h>
-#endif
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*--------------------------------------------------------------------------
- * KEntrezFetcher
- * everything to fetch DNA-text from entrez - server
- */
-typedef struct KEntrezFetcher KEntrezFetcher;
-
-
-/* Make
- * create a fetcher object
- */
-rc_t KEntrezFetcherMake ( KEntrezFetcher **fetcher, KUrlFetcher * url_fetcher );
-
-/* Setup
- * prepares a fetch and indicates to caller the buffer size
- *
- * "server" [ IN ] - NUL terminated URI, e.g.
- * "http://eutils.ncbi.nlm.nih.gov/entrez/eutils/efetch.fcgi"
- *
- * "seq_id" [ IN ] - NUL terminated sequence identifier, e.g. "NC_000001"
- * max_seq_len : 1024
- * row_id : 11
- * row_count : 1
- */
-rc_t KEntrezFetcherSetup ( KEntrezFetcher *self,
- const char * server, const char * seq_id,
- const size_t max_seq_len, const uint64_t row_id, const size_t row_count,
- size_t * buffsize );
-
-
-/* Setup
- * prepares a fetch by giving it a usable url
- */
-rc_t KEntrezFetcherSetupUri ( KEntrezFetcher *self, const char * uri );
-
-
-/* AddRef
- * Release
- */
-rc_t KEntrezFetcherAddRef ( const KEntrezFetcher *self );
-rc_t KEntrezFetcherRelease ( const KEntrezFetcher *self );
-
-/* Read
- * reads data from prepared URI
- */
-rc_t KEntrezFetcherRead ( KEntrezFetcher *self,
- void *dst, size_t dst_size, size_t *num_read );
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif /* _h_entrez_fetcher_ */
diff --git a/interfaces/kns/http.h b/interfaces/kns/http.h
index f006a09..8d14063 100644
--- a/interfaces/kns/http.h
+++ b/interfaces/kns/http.h
@@ -52,6 +52,21 @@ struct KNSManager;
/*--------------------------------------------------------------------------
+ * KNSManager
+ */
+
+/* SetHTTPTimeouts
+ * sets default read/write timeouts to supply to HTTP connections
+ *
+ * "readMillis" [ IN ] and "writeMillis" - when negative, infinite timeout
+ * when 0, return immediately, positive gives maximum wait time in mS
+ * for reads and writes respectively.
+ */
+KNS_EXTERN rc_t CC KNSManagerSetHTTPTimeouts ( struct KNSManager *self,
+ int32_t readMillis, int32_t writeMillis );
+
+
+/*--------------------------------------------------------------------------
* KHttp
* hyper text transfer protocol
*/
@@ -63,11 +78,15 @@ typedef struct KHttp KHttp;
*
* "http" [ OUT ] - return parameter for HTTP object
*
- * "conn" [ IN, NULL OKAY ] - previously opened stream for communications.
+ * "opt_conn" [ IN, NULL OKAY ] - previously opened stream for communications.
*
* "vers" [ IN ] - http version
* the only legal types are 1.0 ( 0x01000000 ) and 1.1 ( 0x01010000 )
*
+ * "readMillis" [ IN ] and "writeMillis" - when negative, infinite timeout
+ * when 0, return immediately, positive gives maximum wait time in mS
+ * for reads and writes respectively.
+ *
* "host" [ IN ] - parameter to give the host dns name for the connection
*
* "port" [ IN, DEFAULT ZERO ] - if zero, defaults to standard for scheme
@@ -77,6 +96,10 @@ KNS_EXTERN rc_t CC KNSManagerMakeHttp ( struct KNSManager const *self,
KHttp **http, struct KStream *conn, ver_t vers,
struct String const *host, uint32_t port );
+KNS_EXTERN rc_t CC KNSManagerMakeTimedHttp ( struct KNSManager const *self, KHttp **http,
+ struct KStream *opt_conn, ver_t vers, int32_t readMillis, int32_t writeMillis,
+ struct String const *host, uint32_t port );
+
/* AddRef
* Release
@@ -87,8 +110,8 @@ KNS_EXTERN rc_t CC KHttpRelease ( const KHttp *self );
-/*--------------------------------------------------------------------------
- * KHttpFile
+/*------------------------------------------------------------------------------
+ * KFile
* a KFile over HTTP
*/
@@ -100,7 +123,7 @@ KNS_EXTERN rc_t CC KNSManagerVMakeHttpFile ( struct KNSManager const *self,
struct KFile const **file, struct KStream *conn, ver_t vers, const char *url, va_list args );
-/*--------------------------------------------------------------------------
+/*------------------------------------------------------------------------------
* KHttpRequest
* hyper text transfer protocol
*/
@@ -196,7 +219,7 @@ KNS_EXTERN rc_t CC KHttpRequestHEAD ( KHttpRequest *self, KHttpResult **rslt );
*/
KNS_EXTERN rc_t CC KHttpRequestGET ( KHttpRequest *self, KHttpResult **rslt );
- /* POST
+/* POST
* send POST message
* query parameters are sent in URL
* post parameters are sent in body
diff --git a/interfaces/kns/impl.h b/interfaces/kns/impl.h
index eec1bd8..f04ad86 100644
--- a/interfaces/kns/impl.h
+++ b/interfaces/kns/impl.h
@@ -81,6 +81,13 @@ struct KStream_vt_v1
rc_t ( CC * write ) ( KSTREAM_IMPL *self,
const void *buffer, size_t size, size_t *num_writ );
/* end minor version == 0 */
+
+ /* start minor version == 1 */
+ rc_t ( CC * timed_read ) ( const KSTREAM_IMPL *self,
+ void *buffer, size_t bsize, size_t *num_read, struct timeout_t *tm );
+ rc_t ( CC * timed_write ) ( KSTREAM_IMPL *self,
+ const void *buffer, size_t size, size_t *num_writ, struct timeout_t *tm );
+ /* end minor version == 1 */
};
union KStream_vt
diff --git a/interfaces/kns/manager-ext.h b/interfaces/kns/manager-ext.h
index fc9e667..cdab1d5 100644
--- a/interfaces/kns/manager-ext.h
+++ b/interfaces/kns/manager-ext.h
@@ -42,7 +42,7 @@ struct SraReleaseVersion;
/*--------------------------------------------------------------------------
- * KNSManager
+ * KNSManager Extension
*/
/* NewReleaseVersion
diff --git a/interfaces/kns/manager.h b/interfaces/kns/manager.h
index f07b6d7..fe731b2 100644
--- a/interfaces/kns/manager.h
+++ b/interfaces/kns/manager.h
@@ -65,24 +65,11 @@ KNS_EXTERN rc_t CC KNSManagerAddRef ( const KNSManager *self );
KNS_EXTERN rc_t CC KNSManagerRelease ( const KNSManager *self );
-/* Avail - DEPRECATED
- * indicate to caller whether networking services are available
- * mainly here to support libcurl
- */
-KNS_EXTERN rc_t CC KNSManagerAvail ( const KNSManager *self );
-
-/* CurlVersion - DEPRECATED
- * indicate which version of curl is available
- * return this as a string, because this is how libcurl does it
- */
-KNS_EXTERN rc_t CC KNSManagerCurlVersion ( const KNSManager *self, const char ** version_string );
-
-
/* SetVerbose
* set/clear verbosity flag of manager ( dflt is false )...
* the network-code has to request it
*/
-KNS_EXTERN void CC KNSManagerSetVerbose ( struct KNSManager *self, bool verbosity );
+KNS_EXTERN void CC KNSManagerSetVerbose ( KNSManager *self, bool verbosity );
/* IsVerbose
@@ -91,6 +78,17 @@ KNS_EXTERN void CC KNSManagerSetVerbose ( struct KNSManager *self, bool verbosit
KNS_EXTERN bool CC KNSManagerIsVerbose ( const KNSManager *self );
+/* SetConnectionTimeouts
+ * sets default connect/read/write timeouts to supply to sockets
+ *
+ * "connectMillis", "readMillis", "writeMillis" [ IN ] - when negative, infinite timeout
+ * when 0, return immediately, positive gives maximum wait time in sec/mS
+ * for connects, reads and writes respectively.
+ */
+KNS_EXTERN rc_t CC KNSManagerSetConnectionTimeouts ( KNSManager *self,
+ int32_t connectSecs, int32_t readMillis, int32_t writeMillis );
+
+
#ifdef __cplusplus
}
#endif
diff --git a/interfaces/kns/socket.h b/interfaces/kns/socket.h
index e83c752..e47f55d 100644
--- a/interfaces/kns/socket.h
+++ b/interfaces/kns/socket.h
@@ -53,10 +53,20 @@ typedef struct KSocket KSocket;
/* MakeConnection
+ * MakeTimedConnection
+ * MakeRetryConnection
+ * MakeRetryTimedConnection
* create a connection-oriented stream
*
* "conn" [ OUT ] - a stream for communication with the server
*
+ * "retryTimeout" [ IN ] - if connection is refused, retry with 1ms intervals: when negative, retry infinitely,
+ * when 0, do not retry, positive gives maximum wait time in seconds
+ *
+ * "readMillis" [ IN ] and "writeMillis" - when negative, infinite timeout
+ * when 0, return immediately, positive gives maximum wait time in mS
+ * for reads and writes respectively.
+ *
* "from" [ IN ] - client endpoint
*
* "to" [ IN ] - server endpoint
@@ -66,29 +76,28 @@ typedef struct KSocket KSocket;
KNS_EXTERN rc_t CC KNSManagerMakeConnection ( struct KNSManager const * self,
struct KStream **conn, struct KEndPoint const *from, struct KEndPoint const *to );
-/* MakeIPCConnection
- * create a connection-oriented stream connected to an IPC server
- *
- * "conn" [ OUT ] - a stream for communication with the server
- *
- * "to" [ IN ] - server endpoint (must be of type epIPC)
- *
- * "max_retries" [ IN ] - number of retries to be made if connection is refused.
- * Will sleep for 1 second between retries
- */
-KNS_EXTERN rc_t CC KNSManagerMakeIPCConnection ( struct KNSManager const *self,
- struct KStream **conn, struct KEndPoint const *to, uint32_t max_retries );
+KNS_EXTERN rc_t CC KNSManagerMakeTimedConnection ( struct KNSManager const * self,
+ struct KStream **conn, int32_t readMillis, int32_t writeMillis,
+ struct KEndPoint const *from, struct KEndPoint const *to );
+
+KNS_EXTERN rc_t CC KNSManagerMakeRetryConnection ( struct KNSManager const * self,
+ struct KStream **conn, int32_t retryTimeout, struct KEndPoint const *from, struct KEndPoint const *to );
+
+KNS_EXTERN rc_t CC KNSManagerMakeRetryTimedConnection ( struct KNSManager const * self,
+ struct KStream **conn, int32_t retryTimeout, int32_t readMillis, int32_t writeMillis,
+ struct KEndPoint const *from, struct KEndPoint const *to );
/* MakeListener
* create a listener socket for accepting incoming IPC connections
*
- * "ep" [ IN ] - a endpoint of type epIPC
+ * "ep" [ IN ] - a local endpoint
*
- * "listener" [ IN ] - a listener socket, to be called KSocketListen() on
+ * "listener" [ IN ] - a listener socket
*/
KNS_EXTERN rc_t CC KNSManagerMakeListener ( struct KNSManager const *self,
KSocket **listener, struct KEndPoint const * ep );
+
/* AddRef
* Release
*/
@@ -96,12 +105,14 @@ KNS_EXTERN rc_t CC KSocketAddRef ( KSocket *self );
KNS_EXTERN rc_t CC KSocketRelease ( KSocket *self );
-/* Listen
+/* Accept
+ * enter listening state upon first use,
* wait for an incoming connection
*
* "conn" [ OUT ] - a stream for communication with the client
*/
-KNS_EXTERN rc_t CC KSocketListen ( KSocket *self, struct KStream **conn );
+KNS_EXTERN rc_t CC KSocketAccept ( KSocket *self, struct KStream **conn );
+KNS_EXTERN rc_t CC KSocketListen ( KSocket *self, struct KStream **conn, remove_t *ignore );
#ifdef __cplusplus
diff --git a/interfaces/kns/stream.h b/interfaces/kns/stream.h
index a7c1bf7..31ac047 100644
--- a/interfaces/kns/stream.h
+++ b/interfaces/kns/stream.h
@@ -41,6 +41,12 @@ extern "C" {
/*--------------------------------------------------------------------------
+ * forwards
+ */
+struct timeout_t;
+
+
+/*--------------------------------------------------------------------------
* KStream
* the stream is defined to have no concept of size,
* and to not support any form of random access
@@ -57,6 +63,7 @@ KNS_EXTERN rc_t CC KStreamRelease ( const KStream *self );
/* Read
+ * TimedRead
* read data from stream
*
* "buffer" [ OUT ] and "bsize" [ IN ] - return buffer for read
@@ -64,11 +71,21 @@ KNS_EXTERN rc_t CC KStreamRelease ( const KStream *self );
* "num_read" [ OUT ] - return parameter giving number of bytes
* actually read. when returned value is zero and return code is
* also zero, interpreted as end of stream.
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed reads. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
*/
KNS_EXTERN rc_t CC KStreamRead ( const KStream *self,
void *buffer, size_t bsize, size_t *num_read );
+KNS_EXTERN rc_t CC KStreamTimedRead ( const KStream *self,
+ void *buffer, size_t bsize, size_t *num_read, struct timeout_t *tm );
/* ReadAll
+ * TimedReadAll
* read from stream until "bsize" bytes have been retrieved
* or until end-of-input
*
@@ -77,23 +94,62 @@ KNS_EXTERN rc_t CC KStreamRead ( const KStream *self,
* "num_read" [ OUT ] - return parameter giving number of bytes
* actually read. when returned value is zero and return code is
* also zero, interpreted as end of stream.
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed reads. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
*/
KNS_EXTERN rc_t CC KStreamReadAll ( const KStream *self,
void *buffer, size_t bsize, size_t *num_read );
+KNS_EXTERN rc_t CC KStreamTimedReadAll ( const KStream *self,
+ void *buffer, size_t bsize, size_t *num_read, struct timeout_t *tm );
+
+/* ReadExactly
+ * TimedReadExactly
+ * read from stream until "bytes" have been retrieved
+ * or return incomplete transfer
+ *
+ * "buffer" [ OUT ] and "bytes" [ IN ] - return buffer for read
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed reads. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
+ */
+KNS_EXTERN rc_t CC KStreamReadExactly ( const KStream *self,
+ void *buffer, size_t bytes );
+KNS_EXTERN rc_t CC KStreamTimedReadExactly ( const KStream *self,
+ void *buffer, size_t bytes, struct timeout_t *tm );
/* Write
+ * TimedWrite
* send data to stream
*
* "buffer" [ IN ] and "size" [ IN ] - data to be written
*
* "num_writ" [ OUT, NULL OKAY ] - optional return parameter
* giving number of bytes actually written
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed writes. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
*/
KNS_EXTERN rc_t CC KStreamWrite ( KStream *self,
const void *buffer, size_t size, size_t *num_writ );
+KNS_EXTERN rc_t CC KStreamTimedWrite ( KStream *self,
+ const void *buffer, size_t size, size_t *num_writ, struct timeout_t *tm );
/* WriteAll
+ * TimedWriteAll
* write to stream until "size" bytes have been transferred
* or until no further progress can be made
*
@@ -101,9 +157,37 @@ KNS_EXTERN rc_t CC KStreamWrite ( KStream *self,
*
* "num_writ" [ OUT, NULL OKAY ] - optional return parameter
* giving number of bytes actually written
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed writes. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
*/
KNS_EXTERN rc_t CC KStreamWriteAll ( KStream *self,
const void *buffer, size_t size, size_t *num_writ );
+KNS_EXTERN rc_t CC KStreamTimedWriteAll ( KStream *self,
+ const void *buffer, size_t size, size_t *num_writ, struct timeout_t *tm );
+
+/* WriteExactly
+ * TimedWriteExactly
+ * write to stream until "bytes" have been transferred
+ * or return incomplete transfer error
+ *
+ * "buffer" [ IN ] and "bytes" [ IN ] - data to be written
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed writes. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
+ */
+KNS_EXTERN rc_t CC KStreamWriteExactly ( KStream *self,
+ const void *buffer, size_t bytes );
+KNS_EXTERN rc_t CC KStreamTimedWriteExactly ( KStream *self,
+ const void *buffer, size_t bytes, struct timeout_t *tm );
/* MakeStdIn
diff --git a/interfaces/kproc/cond.h b/interfaces/kproc/cond.h
index 516a47e..f9eb4ad 100644
--- a/interfaces/kproc/cond.h
+++ b/interfaces/kproc/cond.h
@@ -73,7 +73,7 @@ KPROC_EXTERN rc_t CC KConditionRelease ( const KCondition *self );
/* Wait
- * block on external lock until signaled
+ * block on external lock until signalled
*/
KPROC_EXTERN rc_t CC KConditionWait ( KCondition *self, struct KLock *lock );
KPROC_EXTERN rc_t CC KConditionTimedWait ( KCondition *self, struct KLock *lock, struct timeout_t *tm );
@@ -96,7 +96,6 @@ KPROC_EXTERN rc_t CC KConditionSignal ( KCondition *self );
*/
KPROC_EXTERN rc_t CC KConditionBroadcast ( KCondition *self );
-
#ifdef __cplusplus
}
#endif
diff --git a/interfaces/kproc/lock.h b/interfaces/kproc/lock.h
index c186f63..17109e1 100644
--- a/interfaces/kproc/lock.h
+++ b/interfaces/kproc/lock.h
@@ -47,15 +47,26 @@ struct timeout_t;
/*--------------------------------------------------------------------------
* KLock
+ * KTimedLock
* a POSIX-style mutual exclusion lock
+ *
+ * Mac/BSD doesn't supply proper support for timed pthread_mutex,
+ * so we have to provide additional structure to support it.
+ * in doing so, the timed version has become incompatible with
+ * the KCondition interface.
+ *
+ * For reasons given above, we are dividing KLock into two classes
+ * to separate out support for timed acquire.
*/
typedef struct KLock KLock;
+typedef struct KTimedLock KTimedLock;
/* Make
* make a simple mutex
*/
KPROC_EXTERN rc_t CC KLockMake ( KLock **lock );
+KPROC_EXTERN rc_t CC KTimedLockMake ( KTimedLock **lock );
/* AddRef
@@ -63,18 +74,23 @@ KPROC_EXTERN rc_t CC KLockMake ( KLock **lock );
*/
KPROC_EXTERN rc_t CC KLockAddRef ( const KLock *self );
KPROC_EXTERN rc_t CC KLockRelease ( const KLock *self );
+KPROC_EXTERN rc_t CC KTimedLockAddRef ( const KTimedLock *self );
+KPROC_EXTERN rc_t CC KTimedLockRelease ( const KTimedLock *self );
/* Acquire
* acquires lock
+ *
+ * a NULL "tm" parameter should mean infinite
*/
KPROC_EXTERN rc_t CC KLockAcquire ( KLock *self );
-KPROC_EXTERN rc_t CC KLockTimedAcquire ( KLock *self, struct timeout_t *tm );
+KPROC_EXTERN rc_t CC KTimedLockAcquire ( KTimedLock *self, struct timeout_t *tm );
/* Unlock
* releases lock
*/
KPROC_EXTERN rc_t CC KLockUnlock ( KLock *self );
+KPROC_EXTERN rc_t CC KTimedLockUnlock ( KTimedLock *self );
/*--------------------------------------------------------------------------
@@ -99,6 +115,8 @@ KPROC_EXTERN rc_t CC KRWLockRelease ( const KRWLock *self );
/* AcquireShared
* acquires read ( shared ) lock
+ *
+ * a NULL "tm" parameter should mean infinite
*/
KPROC_EXTERN rc_t CC KRWLockAcquireShared ( KRWLock *self );
KPROC_EXTERN rc_t CC KRWLockTimedAcquireShared ( KRWLock *self, struct timeout_t *tm );
@@ -106,6 +124,8 @@ KPROC_EXTERN rc_t CC KRWLockTimedAcquireShared ( KRWLock *self, struct timeout_t
/* AcquireExcl
* acquires write ( exclusive ) lock
+ *
+ * a NULL "tm" parameter should mean infinite
*/
KPROC_EXTERN rc_t CC KRWLockAcquireExcl ( KRWLock *self );
KPROC_EXTERN rc_t CC KRWLockTimedAcquireExcl ( KRWLock *self, struct timeout_t *tm );
diff --git a/interfaces/krypto/encfile-priv.h b/interfaces/krypto/encfile-priv.h
index 79d2fd1..84deaf7 100644
--- a/interfaces/krypto/encfile-priv.h
+++ b/interfaces/krypto/encfile-priv.h
@@ -94,9 +94,9 @@ struct KEncFileHeader
* same size as the rest but with only some of the data portion being
* a part of the file.
*
- * An crypted file is longer than an unencrypted file by
+ * An encrypted file is longer than an unencrypted file by
* a constant: the lengths of the header and the footer
- * proportinally by the length of the block key and crc
+ * proportionally by the length of the block key and crc
*/
/* -----
@@ -208,8 +208,8 @@ KRYPTO_EXTERN rc_t CC KEncFileMakeUpdate_v2 (struct KFile ** pself,
/* ----------
* Validate mode can not be read or written.
- * Upon open the whole file is read from begining to end and all CRC
- * and other integrity checks are performed immedaitely
+ * Upon open the whole file is read from beginning to end and all CRC
+ * and other integrity checks are performed immediately
*/
KRYPTO_EXTERN rc_t CC KEncFileValidate_v1 (const struct KFile * encrypted);
diff --git a/interfaces/krypto/extern.h b/interfaces/krypto/extern.h
index a567690..70c1b0c 100644
--- a/interfaces/krypto/extern.h
+++ b/interfaces/krypto/extern.h
@@ -29,13 +29,18 @@
#if ! defined EXPORT_LATCH && defined _LIBRARY
#define KRYPTO_EXTERN LIB_EXPORT
-#define KRYPTO_EXTERN_DATA LIB_EXPORT_DATA
+#define KRYPTO_EXTERN_DATA extern LIB_EXPORT
#define EXPORT_LATCH 1
#else
#define KRYPTO_EXTERN LIB_IMPORT
+#ifdef __cplusplus
+#define KRYPTO_EXTERN_DATA extern /* LIB_IMPORT_DATA */
+#else
#define KRYPTO_EXTERN_DATA LIB_IMPORT_DATA
#endif
+#endif
+
#ifndef _h_klib_extern_
#include <klib/extern.h>
#endif
diff --git a/interfaces/ktst/test_tools.hpp b/interfaces/ktst/test_tools.hpp
index b6644da..2e46d54 100644
--- a/interfaces/ktst/test_tools.hpp
+++ b/interfaces/ktst/test_tools.hpp
@@ -5,7 +5,7 @@
// these macros are available outside of test cases' code
#define LOG(log_level, msg) \
-if (log_level >= ncbi::NK::TestEnv::verbosity) std::cerr << msg
+ (log_level >= ncbi::NK::TestEnv::verbosity ? (std::cerr << msg) : std::cerr)
#define TEST_MESSAGE(M) \
{ ncbi_NK_saveLocation(__FILE__,__LINE__); \
diff --git a/interfaces/ktst/unit_test.hpp b/interfaces/ktst/unit_test.hpp
index 1cdbd50..e97b231 100644
--- a/interfaces/ktst/unit_test.hpp
+++ b/interfaces/ktst/unit_test.hpp
@@ -208,10 +208,12 @@ private:
DECLARE_EXTERN_C_ENTRYPOINTS \
typedef F AUTO_TEST_CASE_FIXTURE; \
int suite_name(int argc, char* argv[]) { \
- ncbi::NK::TestEnv args(argc, argv); \
- if (args.catch_system_errors) { \
- args.set_handlers(); \
- } \
+ try { \
+ ncbi::NK::TestEnv args(argc, argv); \
+ if (args.catch_system_errors) { \
+ args.set_handlers(); \
+ } \
+ } catch (...) { return 1; } \
ncbi::NK::counter_t ec = ncbi::NK::Main<AUTO_TEST_CASE_FIXTURE>(argc, argv, #suite_name); \
return ec == 0 ? 0 : -ec; /* positive rc represents the signal that killed the process */ \
}
@@ -222,10 +224,12 @@ int suite_name(int argc, char* argv[]) { \
DECLARE_EXTERN_C_ENTRYPOINTS \
typedef F AUTO_TEST_CASE_FIXTURE; \
int suite_name(int argc, char* argv[]) { \
- ncbi::NK::TestEnv args(argc, argv, Handler); \
- if (args.catch_system_errors) { \
- args.set_handlers(); \
- } \
+ try { \
+ ncbi::NK::TestEnv args(argc, argv, Handler); \
+ if (args.catch_system_errors) { \
+ args.set_handlers(); \
+ } \
+ } catch (...) { return 1; } \
ncbi::NK::counter_t ec = ncbi::NK::Main<AUTO_TEST_CASE_FIXTURE>(argc, argv, #suite_name); \
return ec == 0 ? 0 : -ec; /* positive rc represents the signal that killed the process */ \
}
@@ -234,10 +238,12 @@ int suite_name(int argc, char* argv[]) { \
#define FIXTURE_TEST_SUITE_WITH_USAGE( suite_name, F ) \
typedef F AUTO_TEST_CASE_FIXTURE; \
int suite_name(int argc, char* argv[]) { \
- ncbi::NK::TestEnv args(argc, argv); \
- if (args.catch_system_errors) { \
- args.set_handlers(); \
- } \
+ try { \
+ ncbi::NK::TestEnv args(argc, argv); \
+ if (args.catch_system_errors) { \
+ args.set_handlers(); \
+ } \
+ } catch (...) { return 1; } \
ncbi::NK::counter_t ec = ncbi::NK::Main<AUTO_TEST_CASE_FIXTURE>(argc, argv, #suite_name); \
return ec == 0 ? 0 : -ec; /* positive rc represents the signal that killed the process */ \
}
diff --git a/interfaces/ktst/unit_test_suite.hpp b/interfaces/ktst/unit_test_suite.hpp
index 8b3a3d7..9b260f8 100644
--- a/interfaces/ktst/unit_test_suite.hpp
+++ b/interfaces/ktst/unit_test_suite.hpp
@@ -110,7 +110,10 @@ public:
bool catch_system_errors;
static int RunProcessTestCase(TestCase&, void(TestCase::*)(), int);
- static unsigned int Sleep(unsigned int seconds);
+
+ // Sleep functions return false if sleep was interrupted
+ static bool Sleep(unsigned int seconds);
+ static bool SleepMs(unsigned int milliseconds);
static const int TEST_CASE_TIMED_OUT=14;
static const int TEST_CASE_FAILED=255;
diff --git a/interfaces/kns/curl-file.h b/interfaces/ncbi/vdb-blast-priv.h
similarity index 76%
copy from interfaces/kns/curl-file.h
copy to interfaces/ncbi/vdb-blast-priv.h
index 77aabe4..065b866 100644
--- a/interfaces/kns/curl-file.h
+++ b/interfaces/ncbi/vdb-blast-priv.h
@@ -23,27 +23,29 @@
* ===========================================================================
*
*/
-#ifndef _h_curl_file_
-#define _h_curl_file_
-#ifndef _h_kns_extern_
-#include <kns/extern.h>
+#ifndef _h_ncbi_vdb_blast_priv_
+#define _h_ncbi_vdb_blast_priv_
+
+#ifndef _h_vdb_extern_
+#include <vdb/extern.h>
#endif
+#include <stddef.h>
+#include <stdint.h>
+
#ifdef __cplusplus
extern "C" {
#endif
+struct VdbBlast2naReader;
-/*--------------------------------------------------------------------------
- * KCurlFile
- * a remote file, fetched (in parts) via http using libcurl
- */
-KNS_EXTERN rc_t CC KCurlFileMake ( struct KFile const **self, const char * url, bool verbose );
-
+VDB_EXTERN uint64_t CC _VdbBlast2naReaderRead(const struct VdbBlast2naReader *self,
+ uint32_t *status, uint64_t *read_id, size_t *starting_base,
+ uint8_t *buffer, size_t buffer_size);
#ifdef __cplusplus
}
#endif
-#endif
+#endif /* _h_ncbi_vdb_blast_priv_ */
diff --git a/interfaces/ncbi/vdb-blast.h b/interfaces/ncbi/vdb-blast.h
new file mode 100644
index 0000000..6f8c1fe
--- /dev/null
+++ b/interfaces/ncbi/vdb-blast.h
@@ -0,0 +1,489 @@
+/*===========================================================================
+*
+* PUBLIC DOMAIN NOTICE
+* National Center for Biotechnology Information
+*
+* This software/database is a "United States Government Work" under the
+* terms of the United States Copyright Act. It was written as part of
+* the author's official duties as a United States Government employee and
+* thus cannot be copyrighted. This software/database is freely available
+* to the public for use. The National Library of Medicine and the U.S.
+* Government have not placed any restriction on its use or reproduction.
+*
+* Although all reasonable efforts have been taken to ensure the accuracy
+* and reliability of the software and data, the NLM and the U.S.
+* Government do not and cannot warrant the performance or results that
+* may be obtained by using this software or data. The NLM and the U.S.
+* Government disclaim all warranties, express or implied, including
+* warranties of performance, merchantability or fitness for any particular
+* purpose.
+*
+* Please cite the author in any work or product based on this material.
+*
+* ===========================================================================
+*
+*/
+
+#ifndef _h_ncbi_vdb_blast_
+#define _h_ncbi_vdb_blast_
+
+#ifndef _h_vdb_extern_
+#include <vdb/extern.h>
+#endif
+
+#include <stdbool.h>
+#include <stddef.h>
+#include <stdint.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+
+/*--------------------------------------------------------------------------
+ * defines
+ */
+#ifdef __cplusplus
+#define VDB_BLAST_DECLARE( cls ) \
+ struct cls
+#else
+#define VDB_BLAST_DECLARE( cls ) \
+ typedef struct cls cls
+#endif
+
+
+/*--------------------------------------------------------------------------
+ * status codes
+ * NB - TO BE COMPLETED DURING DEVELOPMENT OF TESTS AND INITIAL CODE
+ */
+enum
+{
+ eVdbBlastNoErr,
+ eVdbBlastErr,
+ eVdbBlastMemErr,
+ eVdbBlastRunErr,
+ eVdbBlastEndOfSequence,
+ eVdbBlastChunkedSequence, /* can't hand out direct pointer into cache */
+ eVdbBlastTooExpensive,
+ eVdbBlastInvalidId /* an invalid read_id was used as an input parameter:
+ usually accessing a filtered read via 4naReader */
+};
+
+
+/*------------------------------------------------------------------------------
+ * VdbBlastMgr
+ */
+VDB_BLAST_DECLARE ( VdbBlastMgr );
+
+
+/* Init
+ * initialize library
+ *
+ * "status" [ OUT ] - return parameter for status code
+ */
+VDB_EXTERN VdbBlastMgr* CC VdbBlastInit ( uint32_t *status );
+
+
+/* AddRef
+ * attach a reference to existing object
+ * Release
+ * drop reference to object
+ * deletes object when last reference is gone
+ */
+VDB_EXTERN VdbBlastMgr* CC VdbBlastMgrAddRef ( VdbBlastMgr *self );
+VDB_EXTERN void CC VdbBlastMgrRelease ( VdbBlastMgr *self );
+
+
+/* OTHER FUNCTIONS FOR CONFIGURING SESSION BEHAVIOR */
+
+
+/*------------------------------------------------------------------------------
+ * VdbBlastRunSet
+ */
+VDB_BLAST_DECLARE ( VdbBlastRunSet );
+
+
+/* MakeRunSet
+ * create an empty run set
+ *
+ * "status" [ OUT ] - return parameter for status code
+ *
+ * "min_read_length" [ IN ] - min-length parameter for filtering
+ *
+ * "protein" [ IN ] - if true, run set will contain only protein sequences
+ *
+ * returns NULL upon any error
+ */
+VDB_EXTERN VdbBlastRunSet* CC VdbBlastMgrMakeRunSet ( const VdbBlastMgr *self,
+ uint32_t *status, uint32_t min_read_length, bool protein );
+
+
+/* AddRef
+ * attach a reference to existing object
+ * Release
+ * drop reference to object
+ * deletes object when last reference is gone
+ */
+VDB_EXTERN VdbBlastRunSet* CC VdbBlastRunSetAddRef ( VdbBlastRunSet *self );
+VDB_EXTERN void CC VdbBlastRunSetRelease ( VdbBlastRunSet *self );
+
+
+/* AddRun
+ * add a run by accession or path
+ *
+ * "rundesc" [ IN ] - NUL-terminated UTF-8 string
+ * giving run accession or path
+ *
+ * returns status code
+ */
+VDB_EXTERN uint32_t CC VdbBlastRunSetAddRun ( VdbBlastRunSet *self,
+ const char *rundesc );
+
+
+/* GetNumSequences
+ * returns the total number of biological sequences in run set
+ * GetNumSequencesApprox
+ * returns a calculated estimate of the number of biological
+ * sequences in run set. may be used if the exact count function
+ * returns "eVdbBlastTooExpensive".
+ */
+VDB_EXTERN uint64_t CC VdbBlastRunSetGetNumSequences
+ ( const VdbBlastRunSet *self, uint32_t *status );
+VDB_EXTERN uint64_t CC VdbBlastRunSetGetNumSequencesApprox
+ ( const VdbBlastRunSet *self );
+
+
+/* GetTotalLength
+ * returns the total number of bases in run set
+ * GetTotalLengthApprox
+ * returns a calculated estimate of the total number
+ * of bases in run set. may be used if the exact length function
+ * returns "eVdbBlastTooExpensive".
+ */
+VDB_EXTERN uint64_t CC VdbBlastRunSetGetTotalLength
+ ( const VdbBlastRunSet *self, uint32_t *status );
+VDB_EXTERN uint64_t CC VdbBlastRunSetGetTotalLengthApprox
+ ( const VdbBlastRunSet *self );
+
+
+/* GetMinSeqLen
+ * GetMaxSeqLen
+ * GetAvgSeqLen
+ * returns metrics of biological reads
+ * may be the result of estimated calculations ( see above )
+ */
+VDB_EXTERN uint64_t CC VdbBlastRunSetGetMaxSeqLen
+ ( const VdbBlastRunSet *self );
+VDB_EXTERN uint64_t CC VdbBlastRunSetGetMinSeqLen
+ ( const VdbBlastRunSet *self );
+VDB_EXTERN uint64_t CC VdbBlastRunSetGetAvgSeqLen
+ ( const VdbBlastRunSet *self );
+
+
+/* GetName
+ * returns the total number of bytes needed for name
+ * which, if > bsize, means insufficient buffer error
+ * and if == bsize, means the name is NOT NUL-terminated
+ * otherwise, the buffer is NUL-terminated as well.
+ */
+VDB_EXTERN size_t CC VdbBlastRunSetGetName ( const VdbBlastRunSet *self,
+ uint32_t *status, char *name_buffer, size_t bsize );
+
+
+/* IsProtein
+ * return the boolean value given when the set was created
+ */
+VDB_EXTERN bool CC VdbBlastRunSetIsProtein ( const VdbBlastRunSet *self );
+
+
+#if NOT_DEFERRED
+/* LastUpdatedDate
+ * request the modification date of the SEQUENCE data
+ * or the READ DESCRIPTOR data, whichever is more recent
+ */
+time_t VdbBlastRunSetLastUpdatedDate ( const VdbBlastRunSet *self );
+#endif
+
+/* GetReadName
+ */
+VDB_EXTERN size_t CC VdbBlastRunSetGetReadName ( const VdbBlastRunSet *self,
+ uint64_t read_id, char *name_buffer, size_t bsize );
+
+/* GetReadId
+ * Inverse function to GetReadName
+ *
+ * returns status code
+ */
+VDB_EXTERN uint32_t CC VdbBlastRunSetGetReadId ( const VdbBlastRunSet *self,
+ const char *name_buffer, size_t bsize, uint64_t *read_id );
+
+#if NOT_DEFERRED
+/* GetReadLength
+ * this API bothers me, because it has the potential of blowing up the cache
+ * and subverts the guarantee of the readers exclusive use of caches.
+ * Note that by getting a read and its length using the "Data" functions
+ * below, you can get the length as cheaply as you would here, at least in
+ * VDB-2.
+ */
+uint64_t VdbBlastRunSetGetReadLength ( const VdbBlastRunSet *self,
+ uint64_t read_id );
+#endif
+
+
+/*------------------------------------------------------------------------------
+ * VdbBlast2naReader
+ */
+VDB_BLAST_DECLARE ( VdbBlast2naReader );
+
+
+/* Make2naReader
+ * create a reader onto the run set
+ *
+ * "status" [ OUT ] - return parameter for status code
+ *
+ * "initial_read_id" [ IN ] - starting position for reader
+ */
+VDB_EXTERN VdbBlast2naReader* CC VdbBlastRunSetMake2naReader
+ ( const VdbBlastRunSet *self, uint32_t *status, uint64_t initial_read_id );
+
+
+/* AddRef
+ * attach a reference to existing object
+ * Release
+ * drop reference to object
+ * deletes object when last reference is gone
+ */
+VDB_EXTERN VdbBlast2naReader* CC VdbBlast2naReaderAddRef
+ ( VdbBlast2naReader *self );
+VDB_EXTERN void CC VdbBlast2naReaderRelease ( VdbBlast2naReader *self );
+
+
+/* Read
+ * read a single sequence in packed 2na
+ *
+ * "status" [ OUT ] - return parameter for status code
+ *
+ * "read_id" [ OUT ] - id of read that was read
+ *
+ * "buffer" [ OUT ] and "buffer_size" [ IN ] - externally provided buffer
+ * for single sequence in packed 2na, where buffer_size is in bytes.
+ *
+ * returns number of bases read or 0 if no further bases could be read
+ */
+VDB_EXTERN uint64_t CC VdbBlast2naReaderRead ( const VdbBlast2naReader *self,
+ uint32_t *status, uint64_t *read_id,
+ uint8_t *buffer, size_t buffer_size );
+
+
+/* Data
+ * read as many sequences as are available
+ *
+ * "status" [ OUT ] - return parameter for status code
+ *
+ * "buffer" [ OUT ] and "buffer_len" [ IN ] - externally provided buffer
+ * for biological read sequences
+ *
+ * returns number of sequences available in "buffer"
+ * or 0 if nothing could be read
+ */
+typedef struct Packed2naRead Packed2naRead;
+struct Packed2naRead
+{
+ uint64_t read_id;
+ void *starting_byte;
+ uint32_t offset_to_first_bit;
+ uint32_t length_in_bases;
+};
+
+VDB_EXTERN uint32_t CC VdbBlast2naReaderData ( VdbBlast2naReader *self,
+ uint32_t *status, Packed2naRead *buffer, uint32_t buffer_length );
+
+
+/*------------------------------------------------------------------------------
+ * VdbBlast4naReader
+ */
+VDB_BLAST_DECLARE ( VdbBlast4naReader );
+
+
+/* Make4naReader
+ * create a reader onto the run set
+ *
+ * "status" [ OUT ] - return parameter for status code
+ */
+VDB_EXTERN VdbBlast4naReader* CC VdbBlastRunSetMake4naReader
+ ( const VdbBlastRunSet *self, uint32_t *status );
+
+
+/* AddRef
+ * attach a reference to existing object
+ * Release
+ * drop reference to object
+ * deletes object when last reference is gone
+ */
+VDB_EXTERN VdbBlast4naReader* CC VdbBlast4naReaderAddRef
+ ( VdbBlast4naReader *self );
+VDB_EXTERN void CC VdbBlast4naReaderRelease ( VdbBlast4naReader *self );
+
+
+/* Read
+ * read a single sequence in unpacked, std 4na
+ *
+ * "status" [ OUT ] - return parameter for status code
+ *
+ * "read_id" [ IN ] - id of read to be read
+ *
+ * "starting_base" [ IN ] - zero-based starting index into the sequence
+ *
+ * "buffer" [ OUT ] and "buffer_len" [ IN ] - externally provided buffer
+ * for single sequence in unpacked 4na
+ *
+ * returns number of bases read or 0 if no further bases could be read
+ */
+VDB_EXTERN size_t CC VdbBlast4naReaderRead ( const VdbBlast4naReader *self,
+ uint32_t *status, uint64_t read_id, size_t starting_base,
+ uint8_t *buffer, size_t buffer_length );
+
+
+/* Data
+ * access cached data
+ *
+ * "status" [ OUT ] - return parameter for status code
+ *
+ * "read_id" [ IN ] - id of read to be accessed
+ *
+ * "length" [ OUT ] - return parameter for sequence length
+ *
+ * returns pointer to data or NULL upon error
+ */
+VDB_EXTERN const uint8_t* CC VdbBlast4naReaderData
+ ( const VdbBlast4naReader *self,
+ uint32_t *status, uint64_t read_id, size_t *length );
+
+
+/*------------------------------------------------------------------------------
+ * VdbBlastStdaaReader
+ */
+VDB_BLAST_DECLARE ( VdbBlastStdaaReader );
+
+
+/* MakeStdaaReader
+ * create a reader onto the run set
+ */
+VDB_EXTERN VdbBlastStdaaReader* CC VdbBlastRunSetMakeStdaaReader
+ ( const VdbBlastRunSet *self, uint32_t *status );
+
+
+/* AddRef
+ * attach a reference to existing object
+ * Release
+ * drop reference to object
+ * deletes object when last reference is gone
+ */
+VDB_EXTERN VdbBlastStdaaReader* CC VdbBlastStdaaReaderAddRef
+ ( VdbBlastStdaaReader *self );
+VDB_EXTERN void CC VdbBlastStdaaReaderRelease ( VdbBlastStdaaReader *self );
+
+
+/* Read
+ * read a single sequence in stdaa
+ *
+ * "status" [ OUT ] - return parameter for status code
+ *
+ * "pig" [ IN ] - protein id
+ *
+ * "buffer" [ OUT ] and "buffer_len" [ IN ] - externally provided buffer
+ * for single sequence in unpacked Stdaa
+ *
+ * returns number of residues read or 0 upon error
+ */
+VDB_EXTERN size_t CC VdbBlastStdaaReaderRead ( const VdbBlastStdaaReader *self,
+ uint32_t *status, uint64_t pig, uint8_t *buffer, size_t buffer_length );
+
+
+/* Data
+ * access cached data
+ *
+ * "status" [ OUT ] - return parameter for status code
+ *
+ * "length" [ OUT ] - return parameter for sequence length
+ *
+ * returns pointer to data or NULL upon error
+ */
+VDB_EXTERN const uint8_t* CC VdbBlastStdaaReaderData
+ ( const VdbBlastStdaaReader *self,
+ uint32_t *status, uint64_t pig, size_t *length );
+
+
+/* FUNCTIONS TO CONTROL VDB-LIBRARIES LOG GENERATION */
+
+/* KLogLevelSet
+ * set log level of VDB-libraries
+ *
+ * returns status code
+ */
+VDB_EXTERN uint32_t CC VdbBlastMgrKLogLevelSetInfo ( const VdbBlastMgr *self );
+VDB_EXTERN uint32_t CC VdbBlastMgrKLogLevelSetWarn ( const VdbBlastMgr *self );
+
+/* for level description see klib/log.h */
+VDB_EXTERN uint32_t CC VdbBlastMgrKLogLevelSet ( const VdbBlastMgr *self,
+ uint32_t level );
+
+VDB_EXTERN void CC VdbBlastMgrKStsLevelSet ( const VdbBlastMgr *self,
+ uint32_t level );
+
+/* KLogHandlerSet, KLogLibHandlerSet, KStsHandlerSet, KOutHandlerSet
+ * set logging output handlers for different channels
+ *
+ * returns status code
+ */
+VDB_EXTERN uint32_t CC VdbBlastMgrKLogHandlerSetStdOut
+ ( const VdbBlastMgr *self );
+VDB_EXTERN uint32_t CC VdbBlastMgrKLogLibHandlerSetStdOut
+ ( const VdbBlastMgr *self );
+VDB_EXTERN uint32_t CC VdbBlastMgrKStsHandlerSetStdOut
+ ( const VdbBlastMgr *self );
+VDB_EXTERN uint32_t CC VdbBlastMgrKOutHandlerSetStdOut
+ ( const VdbBlastMgr *self );
+
+VDB_EXTERN uint32_t CC VdbBlastMgrKLogHandlerSetStdErr
+ ( const VdbBlastMgr *self );
+VDB_EXTERN uint32_t CC VdbBlastMgrKLogLibHandlerSetStdErr
+ ( const VdbBlastMgr *self );
+VDB_EXTERN uint32_t CC VdbBlastMgrKStsHandlerSetStdErr
+ ( const VdbBlastMgr *self );
+VDB_EXTERN uint32_t CC VdbBlastMgrKOutHandlerSetStdErr
+ ( const VdbBlastMgr *self );
+
+
+/* upon success, the writer will return code 0 */
+typedef uint32_t ( CC * VdbBlastKWrtWriter )
+ ( void * self, const char * buffer, size_t bufsize, size_t * num_writ );
+
+VDB_EXTERN uint32_t CC VdbBlastMgrKLogHandlerSet ( const VdbBlastMgr *self,
+ VdbBlastKWrtWriter writer, void *data );
+VDB_EXTERN uint32_t CC VdbBlastMgrKLogLibHandlerSet ( const VdbBlastMgr *self,
+ VdbBlastKWrtWriter writer, void *data );
+VDB_EXTERN uint32_t CC VdbBlastMgrKOutHandlerSet ( const VdbBlastMgr *self,
+ VdbBlastKWrtWriter writer, void *data );
+
+
+/* KDbgSetString
+ * set a string used to turn on debug messages
+ *
+ * returns status code
+ */
+VDB_EXTERN uint32_t CC VdbBlastMgrKDbgSetString ( const VdbBlastMgr *self,
+ const char *string );
+
+/* KConfigPrint
+ * print current configuration to the output handler
+ *
+ * returns status code
+ */
+VDB_EXTERN uint32_t VdbBlastMgrKConfigPrint ( const VdbBlastMgr *self );
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* _h_ncbi_vdb_blast_ */
diff --git a/interfaces/sra/fastq.h b/interfaces/sra/fastq.h
index 121d3ce..b53c3b3 100644
--- a/interfaces/sra/fastq.h
+++ b/interfaces/sra/fastq.h
@@ -64,7 +64,7 @@ typedef struct FastqReader FastqReader;
SRA_RD_EXTERN rc_t CC FastqReaderMake(const FastqReader** self, const SRATable* table, const char* accession,
bool colorSpace, bool origFormat, bool fasta,
bool printLabel, bool printReadId,
- bool noClip, uint32_t minReadLen,
+ bool noClip, bool SuppressQualForCSKey, uint32_t minReadLen,
char offset, char csKey,
spotid_t minSpotId, spotid_t maxSpotId);
diff --git a/interfaces/vdb/manager.h b/interfaces/vdb/manager.h
index 90ccb2f..d7edd37 100644
--- a/interfaces/vdb/manager.h
+++ b/interfaces/vdb/manager.h
@@ -169,6 +169,18 @@ VDB_EXTERN rc_t CC VDBManagerGetObjVersion ( const VDBManager *self,
ver_t * version, const char *path );
+/* GetObjModDate
+ * returns the load/modification timestamp of the given object
+ *
+ * "ts" [ OUT ] - discovered modification timestamp written in object,
+ * or from filesystem
+ *
+ * "path" [ IN ] - path to the object to be examined ( database or table )
+ */
+VDB_EXTERN rc_t CC VDBManagerGetObjModDate ( const VDBManager *self,
+ KTime_t * ts, const char *path );
+
+
/* PathType
* check the path type of an object/directory path.
*
diff --git a/interfaces/vfs/manager.h b/interfaces/vfs/manager.h
index 3cf2588..f7e19ae 100644
--- a/interfaces/vfs/manager.h
+++ b/interfaces/vfs/manager.h
@@ -51,6 +51,7 @@ struct KFile;
struct VPath;
struct VResolver;
struct KDirectory;
+struct KNSManager;
struct VPath;
/* temporary */
@@ -152,6 +153,8 @@ VFS_EXTERN rc_t CC VFSManagerGetCWD (const VFSManager * self, struct KDirectory
VFS_EXTERN rc_t CC VFSManagerGetResolver ( const VFSManager * self, struct VResolver ** resolver );
+VFS_EXTERN rc_t CC VFSManagerGetKNSMgr ( const VFSManager * self, struct KNSManager ** kns );
+
VFS_EXTERN rc_t CC VFSManagerGetKryptoPassword (const VFSManager * self, char * new_password, size_t max_size, size_t * size);
diff --git a/interfaces/vfs/resolver.h b/interfaces/vfs/resolver.h
index 9922c04..46024d5 100644
--- a/interfaces/vfs/resolver.h
+++ b/interfaces/vfs/resolver.h
@@ -158,14 +158,10 @@ VFS_EXTERN rc_t CC VResolverLocal ( const VResolver * self,
* Accession must be an ncbi-acc scheme or a simple name with no
* directory paths.
*
- * "opt_file_rtn" [ OUT, NULL OKAY ] - optional return parameter for
- * any KFile that may be opened as a result of resolution. This can
- * happen if resolving an accession involves opening a URL to a
- * remote server, for example, in which case the KFile can be returned.
*/
VFS_EXTERN rc_t CC VResolverRemote ( const VResolver * self,
VRemoteProtocols protocols, struct VPath const * accession,
- struct VPath const ** path, struct KFile const ** opt_file_rtn );
+ struct VPath const ** path /* , struct KFile const ** opt_file_rtn */ );
/* Cache - DEPRECATED
* Find a cache directory that might or might not contain a partially
diff --git a/libs/Makefile b/libs/Makefile
index ce40007..ac66110 100644
--- a/libs/Makefile
+++ b/libs/Makefile
@@ -52,6 +52,7 @@ SUBDIRS = \
wgsxf \
ktst \
loader \
+ blast \
ascp \
sra \
ncbi-vdb
diff --git a/libs/align/align-access.c b/libs/align/align-access.c
index 7518d53..642aff2 100644
--- a/libs/align/align-access.c
+++ b/libs/align/align-access.c
@@ -198,7 +198,7 @@ LIB_EXPORT rc_t CC AlignAccessDBEnumerateRefSequences(const AlignAccessDB *self,
while (cur != end && BAMFileIndexHasRefSeqId(self->innerSelf, cur) == 0)
++cur;
if (cur == end)
- return RC(rcAlign, rcTable, rcReading, rcRow, rcNotFound);
+ return AlignAccessRefSeqEnumeratorEOFCode;
}
lhs = malloc(sizeof(*lhs));
*refseq_enum = lhs;
@@ -287,7 +287,7 @@ LIB_EXPORT rc_t CC AlignAccessRefSeqEnumeratorNext(const AlignAccessRefSeqEnumer
AlignAccessRefSeqEnumerator *self = (AlignAccessRefSeqEnumerator *)cself;
if (cself->cur + 1 >= cself->end)
- return RC(rcAlign, rcTable, rcReading, rcRow, rcNotFound);
+ return AlignAccessRefSeqEnumeratorEOFCode;
++self->cur;
if (!BAMFileIsIndexed(cself->parent->innerSelf))
@@ -368,9 +368,11 @@ LIB_EXPORT rc_t CC AlignAccessDBWindowedAlignments(
endpos = rs->length;
rc = BAMFileSeek(self->innerSelf, i, pos, endpos);
- if (rc)
+ if (rc) {
+ if (GetRCState(rc) == rcNotFound && GetRCObject(rc) == rcData)
+ rc = AlignAccessAlignmentEnumeratorEOFCode;
return rc;
-
+ }
rc = AlignAccessDBMakeEnumerator(self, &lhs);
if (rc)
return rc;
@@ -394,14 +396,14 @@ AGAIN:
self->innerSelf = NULL;
}
if (self->atend != 0)
- return RC(rcAlign, rcTable, rcReading, rcRow, rcNotFound);
+ return AlignAccessAlignmentEnumeratorEOFCode;
BAMFileGetPosition(self->parent->innerSelf, &self->pos);
rc = BAMFileRead(self->parent->innerSelf, &self->innerSelf);
if (rc) {
if (GetRCState(rc) == rcNotFound && GetRCObject(rc) == rcRow) {
self->atend = 1;
- rc = RC(rcAlign, rcTable, rcReading, rcRow, rcNotFound);
+ rc = AlignAccessAlignmentEnumeratorEOFCode;
}
return rc;
}
@@ -411,9 +413,9 @@ AGAIN:
BAMAlignmentGetRefSeqId(self->innerSelf, &refSeqID);
if (self->refSeqID != refSeqID) {
self->atend = 1;
- rc = RC(rcAlign, rcTable, rcReading, rcRow, rcNotFound);
+ rc = AlignAccessAlignmentEnumeratorEOFCode;
}
- if (self->endpos != 0) {
+ else if (self->endpos != 0) {
int64_t pos;
uint32_t length;
uint64_t endpos;
@@ -421,11 +423,13 @@ AGAIN:
BAMAlignmentGetPosition2(self->innerSelf, &pos, &length);
if (pos < 0 || pos >= (int64_t)self->endpos) {
self->atend = 1;
- return RC(rcAlign, rcTable, rcReading, rcRow, rcNotFound);
+ rc = AlignAccessAlignmentEnumeratorEOFCode;
+ }
+ else {
+ endpos = (uint64_t)pos + length;
+ if (endpos <= self->startpos)
+ goto AGAIN;
}
- endpos = (uint64_t)pos + length;
- if (endpos <= self->startpos)
- goto AGAIN;
}
return rc;
}
diff --git a/libs/align/bam.c b/libs/align/bam.c
index 1d8af69..3fbb09f 100644
--- a/libs/align/bam.c
+++ b/libs/align/bam.c
@@ -35,6 +35,7 @@
#include <klib/printf.h>
#include <klib/log.h>
#include <klib/text.h>
+#include <klib/refcount.h>
#include <sysalloc.h>
#include <atomic32.h>
@@ -82,7 +83,7 @@ static int64_t LE2HI64(void const *X) { int64_t y; memcpy(&y, X, sizeof(y));
typedef struct BAMIndex BAMIndex;
typedef struct BGZFile BGZFile;
-/* #pragma mark BGZFile *** Start *** */
+/* MARK: BGZFile *** Start *** */
#define VALIDATE_BGZF_HEADER 1
#if (ZLIB_VERNUM < 0x1230)
@@ -481,15 +482,14 @@ static rc_t BGZFileInit(BGZFile *self, const KFile *kfp, BGZFile_vt *vt)
return 0;
}
-/* #pragma mark BGZFile *** End *** */
-
#ifndef WINDOWS
+/* MARK: BGZThreadFile *** Start *** */
+
#include <kproc/thread.h>
#include <kproc/lock.h>
#include <kproc/cond.h>
-/* #pragma mark BGZThreadFile *** Start *** */
typedef struct BGZThreadFile_s BGZThreadFile;
#define BUFFER_COUNT (3)
@@ -648,6 +648,8 @@ static rc_t BGZThreadFileInit(BGZThreadFile *self, const KFile *kfp, BGZFile_vt
#endif
+/* MARK: BAMFile structures */
+
struct BAMIndex {
BAMFilePosition *refSeq[1];
};
@@ -671,12 +673,15 @@ struct BAMFile {
char *headerData1; /* gets used for refSeq and readGroup */
uint8_t *headerData2; /* gets used for refSeq */
BAMAlignment *bufLocker;
+ BAMAlignment *nocopy; /* used to hold current record for BAMFileRead2 */
BAMIndex const *ndx;
+ size_t nocopy_size;
+
unsigned refSeqs;
unsigned readGroups;
- atomic32_t refcount;
+ KRefcount refcount;
unsigned ucfirst; /* offset of first record in uncompressed buffer */
unsigned bufSize; /* current size of uncompressed buffer */
unsigned bufCurrent; /* location in uncompressed buffer of read head */
@@ -685,6 +690,8 @@ struct BAMFile {
zlib_block_t buffer; /* uncompressed buffer */
};
+/* MARK: Alignment structures */
+
struct bam_alignment_s {
uint8_t rID[4];
uint8_t pos[4];
@@ -699,7 +706,7 @@ struct bam_alignment_s {
uint8_t ins_size[4];
char read_name[1 /* read_name_len */];
/* if you change length of read_name,
- * adjust calculation of offsets in BAMFileRead */
+ * adjust calculation of offsets in BAMAlignmentSetOffsets */
/* uint32_t cigar[n_cigars];
* uint8_t seq[(read_len + 1) / 2];
* uint8_t qual[read_len];
@@ -718,10 +725,10 @@ struct offset_size_s {
};
struct BAMAlignment {
- atomic32_t refcount;
+ KRefcount refcount;
BAMFile *parent;
- bam_alignment *data;
+ bam_alignment const *data;
uint8_t *storage;
unsigned datasize;
@@ -745,6 +752,8 @@ static const char cigarChars[] = {
/* ct_Overlap must not appear in actual BAM file */
};
+/* MARK: Alignment accessors */
+
static int32_t getRefSeqId(const BAMAlignment *cself) {
return LE2HI32(cself->data->cooked.rID);
}
@@ -891,6 +900,19 @@ static struct offset_size_s const *get_CG_GQ_info(BAMAlignment const *cself)
return kbsearch("GQ", cself->extra, cself->numExtra, sizeof(cself->extra[0]), OptTag_cmp, (void *)cself);
}
+/* MARK: BAMFile Reading functions */
+
+/* returns (rcData, rcInsufficient) if eof */
+static rc_t BAMFileFillBuffer(BAMFile *self)
+{
+ rc_t const rc = self->vt.FileRead(&self->file, self->buffer, &self->bufSize);
+ if (rc)
+ return rc;
+ if (self->bufSize == 0 || self->bufSize <= self->bufCurrent)
+ return RC(rcAlign, rcFile, rcReading, rcData, rcInsufficient);
+ return 0;
+}
+
static rc_t BAMFileReadn(BAMFile *self, const unsigned len, uint8_t dst[/* len */]) {
rc_t rc;
unsigned cur;
@@ -925,14 +947,27 @@ static rc_t BAMFileReadn(BAMFile *self, const unsigned len, uint8_t dst[/* len *
return 0;
}
- rc = self->vt.FileRead(&self->file, self->buffer, &self->bufSize);
+ rc = BAMFileFillBuffer(self);
if (rc)
return rc;
- if (self->bufSize == 0 || self->bufSize <= self->bufCurrent)
- return RC(rcAlign, rcFile, rcReading, rcData, rcInsufficient);
}
}
+static void const *BAMFilePeek(BAMFile const *const self, unsigned const offset)
+{
+ return &self->buffer[self->bufCurrent + offset];
+}
+
+static unsigned BAMFileMaxPeek(BAMFile const *self)
+{
+ return self->bufSize > self->bufCurrent ? self->bufSize - self->bufCurrent : 0;
+}
+
+static int32_t BAMFilePeekI32(BAMFile *self)
+{
+ return LE2HI32(BAMFilePeek(self, 0));
+}
+
static rc_t BAMFileReadI32(BAMFile *self, int32_t *rhs)
{
uint8_t buf[sizeof(int32_t)];
@@ -943,6 +978,8 @@ static rc_t BAMFileReadI32(BAMFile *self, int32_t *rhs)
return rc;
}
+/* MARK: BAM File header parsing functions */
+
static int CC comp_ReadGroup(const void *a, const void *b, void *ignored) {
return strcmp(((BAMReadGroup const *)a)->name, ((BAMReadGroup const *)b)->name);
}
@@ -1558,6 +1595,8 @@ static rc_t ProcessHeader(BAMFile *self, char const headerText[])
return rc;
}
+/* MARK: BAM File destructor */
+
static rc_t BAMIndexWhack(const BAMIndex *);
static rc_t BAMFileWhack(BAMFile *self) {
@@ -1573,12 +1612,16 @@ static rc_t BAMFileWhack(BAMFile *self) {
free((void *)self->headerData2);
if (self->ndx)
BAMIndexWhack(self->ndx);
+ if (self->nocopy)
+ free(self->nocopy);
if (self->vt.FileWhack)
self->vt.FileWhack(&self->file);
return 0;
}
+/* MARK: BAM File constructors */
+
/* file is retained */
static rc_t BAMFileMakeWithKFileAndHeader(BAMFile const **cself,
KFile const *file,
@@ -1591,7 +1634,7 @@ static rc_t BAMFileMakeWithKFileAndHeader(BAMFile const **cself,
if (self == NULL)
return RC(rcAlign, rcFile, rcConstructing, rcMemory, rcExhausted);
- atomic32_set(&self->refcount, 1);
+ KRefcountInit(&self->refcount, 1, "BAMFile", "new", "");
#ifndef WINDOWS
if (threaded)
rc = BGZThreadFileInit(&self->file.thread, file, &self->vt);
@@ -1708,9 +1751,11 @@ LIB_EXPORT rc_t CC BAMFileMakeWithVPath(const BAMFile **cself, const VPath *kpat
return rc;
}
+/* MARK: BAM File ref-counting */
+
LIB_EXPORT rc_t CC BAMFileAddRef(const BAMFile *cself) {
if (cself != NULL)
- atomic32_inc(&((BAMFile *)cself)->refcount);
+ KRefcountAdd(&cself->refcount, "BAMFile");
return 0;
}
@@ -1719,17 +1764,16 @@ LIB_EXPORT rc_t CC BAMFileRelease(const BAMFile *cself) {
BAMFile *self = (BAMFile *)cself;
if (cself != NULL) {
- if (atomic32_dec_and_test(&self->refcount)) {
+ if (KRefcountDrop(&self->refcount, "BAMFile") == krefWhack) {
rc = BAMFileWhack(self);
- if (rc)
- atomic32_set(&self->refcount, 1);
- else
- free(self);
+ free(self);
}
}
return rc;
}
+/* MARK: BAM File positioning */
+
LIB_EXPORT float CC BAMFileGetProportionalPosition(const BAMFile *self)
{
return self->vt.FileProPos(&self->file);
@@ -1778,243 +1822,534 @@ LIB_EXPORT rc_t CC BAMFileRewind(const BAMFile *cself)
return BAMFileSetPositionInt(cself, cself->fpos_first, cself->ucfirst);
}
-typedef bool (* i_OptData_f)(void *ctx, char const tag[2], BAMOptDataValueType type, unsigned length,
- unsigned count, unsigned size, void const *value);
+static void BAMFileAdvance(BAMFile *const self, unsigned distance)
+{
+ self->bufCurrent += distance;
+ if (self->bufCurrent == self->bufSize) {
+ self->fpos_cur = self->vt.FileGetPos(&self->file);
+ self->bufCurrent = 0;
+ self->bufSize = 0;
+ }
+}
+
+/* MARK: BAM Alignment contruction */
+
+static int TagTypeSize(int const type)
+{
+ switch (type) {
+ case dt_ASCII: /* A */
+ case dt_INT8: /* c */
+ case dt_UINT8: /* C */
+ return 1;
+
+ case dt_INT16: /* s */
+ case dt_UINT16: /* S */
+ return 2;
+
+ case dt_INT: /* i */
+ case dt_UINT: /* I */
+ case dt_FLOAT32: /* f */
+ return 4;
+#if 0
+ case dt_FLOAT64: /* d */
+ return 8;
+#endif
+ case dt_CSTRING: /* Z */
+ case dt_HEXSTRING: /* H */
+ return -'S';
+
+ case dt_NUM_ARRAY: /* B */
+ return -'A';
+ }
+ return 0;
+}
-static rc_t ParseOptData(uint8_t const data[], unsigned const n, void *ctx, i_OptData_f f)
+static rc_t ParseOptData(BAMAlignment *const self, size_t const maxsize,
+ size_t const xtra, size_t const datasize)
{
+ size_t const maxExtra = (maxsize - (sizeof(*self) - sizeof(self->extra))) / sizeof(self->extra[0]);
+ char const *const base = (char const *)self->data->raw;
unsigned i = 0;
- rc_t rc = 0;
+ unsigned len;
+ unsigned offset;
- while (rc == 0 && i + 3 < n) {
- char const *const tag = (char const *)&data[i];
- int type = data[i + 2];
- uint8_t const *const vp = &data[i + 3];
- unsigned len = 0;
- unsigned size = 0;
- unsigned count = 1;
- unsigned offset = 0;
+ self->numExtra = 0;
+ for (len = 0, offset = (unsigned)xtra; offset < datasize; offset += len) {
+ int const valuelen1 = TagTypeSize(base[offset + 2]);
+ unsigned valuelen;
- switch (type) {
- case dt_CSTRING:
- case dt_HEXSTRING:
- len = 0;
- while (i + len + 3 != n && vp[len] != '\0')
- ++len;
- if (i + len + 3 == n) {
- rc = RC(rcAlign, rcFile, rcReading, rcData, rcInvalid);
- break;
+ if (valuelen1 < 0) {
+ char const *const value = &base[offset + 3];
+
+ if (-valuelen1 == 'S') {
+ valuelen = 0;
+ while (value[valuelen] != '\0') {
+ ++valuelen;
+ if (offset + valuelen >= datasize) {
+ rc_t const rc = RC(rcAlign, rcFile, rcReading, rcData, rcInvalid);
+ return rc;
+ }
+ }
+ ++valuelen;
}
- size = len;
- ++len;
- break;
- case dt_INT8:
- case dt_UINT8:
- case dt_ASCII:
- size = len = 1;
- break;
- case dt_INT16:
- case dt_UINT16:
- size = len = 2;
- break;
- case dt_INT:
- case dt_FLOAT32:
- case dt_UINT:
- size = len = 4;
- break;
- case dt_FLOAT64:
- size = len = 8;
- break;
- case dt_NUM_ARRAY:
- offset = len = 5;
- {
- unsigned elem_size = 0;
- uint32_t elem_count = 0;
+ else {
+ int const elem_size = TagTypeSize(value[0]);
- switch (vp[0]) {
- case dt_INT8:
- case dt_UINT8:
- elem_size = 1;
- break;
- case dt_INT16:
- case dt_UINT16:
- elem_size = 2;
- break;
- case dt_FLOAT32:
- case dt_INT:
- case dt_UINT:
- elem_size = 4;
- break;
- case dt_FLOAT64:
- elem_size = 8;
- break;
- default:
- rc = RC(rcAlign, rcFile, rcReading, rcData, rcUnexpected);
- break;
+ assert(-valuelen1 == 'A');
+ if (elem_size <= 0) {
+ rc_t const rc = RC(rcAlign, rcFile, rcReading, rcData, rcUnexpected);
+ return rc;
}
- if (rc)
- break;
- elem_count = LE2HUI32(&vp[1]);
- len += elem_size * elem_count;
- if (i + len + 3 > n) {
- rc = RC(rcAlign, rcFile, rcReading, rcData, rcInvalid);
- break;
+ else {
+ int const elem_count = LE2HI32(&value[1]);
+
+ valuelen = elem_size * elem_count + 1 + 4;
+ if (offset + valuelen >= datasize) {
+ rc_t const rc = RC(rcAlign, rcFile, rcReading, rcData, rcInvalid);
+ return rc;
+ }
}
- type = vp[0];
- count = elem_count;
- size = elem_size;
}
- break;
- default:
- rc = RC(rcAlign, rcFile, rcReading, rcData, rcUnexpected);
- break;
}
- if (rc)
- break;
- i += len + 3;
- if (f(ctx, tag, type, len + 3, count, size, &vp[offset]))
- break;
+ else if (valuelen1 == 0) {
+ rc_t const rc = RC(rcAlign, rcFile, rcReading, rcData, rcUnexpected);
+ return rc;
+ }
+ else
+ valuelen = valuelen1;
+
+ len = valuelen + 3;
+ if (i < maxExtra) {
+ self->extra[i].offset = offset;
+ self->extra[i].size = len;
+ }
+ ++i;
}
- return rc;
+ self->numExtra = i;
+ if (2 <= i && i <= maxExtra)
+ ksort(self->extra, i, sizeof(self->extra[0]), OptTag_sort, self);
+
+ return 0;
}
-static bool CountOptTags(void *ctx, char const tag[2], BAMOptDataValueType type, unsigned length,
- unsigned count, unsigned size, void const *value)
+static rc_t ParseOptDataLog(BAMAlignment *const self, unsigned const maxsize,
+ unsigned const xtra, unsigned const datasize)
{
- ++*(unsigned *)ctx;
- return false;
+ unsigned const maxExtra = (maxsize - (sizeof(*self) - sizeof(self->extra))) / sizeof(self->extra[0]);
+ char const *const base = (char const *)self->data->raw;
+ unsigned i = 0;
+ unsigned len;
+ unsigned offset;
+
+ self->numExtra = 0;
+ for (len = 0, offset = (unsigned)xtra; offset < datasize; offset += len) {
+ int const type = base[offset + 2];
+ int const valuelen1 = TagTypeSize(type);
+ unsigned valuelen;
+
+ if (valuelen1 > 0)
+ valuelen = valuelen1;
+ else if (valuelen1 < 0) {
+ char const *const value = &base[offset + 3];
+
+ if (-valuelen1 == 'S') {
+ valuelen = 0;
+ while (value[valuelen] != '\0') {
+ ++valuelen;
+ if (offset + valuelen >= datasize) {
+ rc_t const rc = RC(rcAlign, rcFile, rcReading, rcData, rcInvalid);
+ (void)LOGERR(klogErr, rc,
+ "Parsing BAM optional fields: "
+ "unterminated string");
+ return rc;
+ }
+ }
+ ++valuelen;
+ }
+ else {
+ int const elem_type = value[0];
+ int const elem_size = TagTypeSize(elem_type);
+
+ assert(-valuelen1 == 'A');
+ if (elem_size <= 0) {
+ rc_t const rc = RC(rcAlign, rcFile, rcReading, rcData, rcUnexpected);
+ (void)LOGERR(klogErr, rc,
+ "Parsing BAM optional fields: "
+ "unknown array type");
+ return rc;
+ }
+ else {
+ int const elem_count = LE2HI32(&value[1]);
+
+ valuelen = elem_size * elem_count + 1 + 4;
+ if (offset + valuelen >= datasize) {
+ rc_t const rc = RC(rcAlign, rcFile, rcReading, rcData, rcInvalid);
+ (void)LOGERR(klogErr, rc,
+ "Parsing BAM optional fields: "
+ "array too big");
+ return rc;
+ }
+ }
+ }
+ }
+ else {
+ rc_t const rc = RC(rcAlign, rcFile, rcReading, rcData, rcUnexpected);
+ (void)LOGERR(klogErr, rc,
+ "Parsing BAM optional fields: "
+ "unknown type");
+ return rc;
+ }
+
+ len = valuelen + 3;
+ if (i < maxExtra) {
+ self->extra[i].offset = offset;
+ self->extra[i].size = len;
+ }
+ ++i;
+ }
+ self->numExtra = i;
+ if (2 <= i && i <= maxExtra)
+ ksort(self->extra, i, sizeof(self->extra[0]), OptTag_sort, self);
+
+ return 0;
}
-struct ctx_LoadOptTags_s {
- unsigned i;
- BAMAlignment *self;
-};
+static unsigned CC BAMAlignmentSize(unsigned const max_extra_tags)
+{
+ BAMAlignment const *const y = NULL;
+
+ return sizeof(*y) + (max_extra_tags ? max_extra_tags - 1 : 0) * sizeof(y->extra);
+}
-static bool LoadOptTags(void *Ctx, char const tag[2], BAMOptDataValueType type, unsigned length,
- unsigned count, unsigned size, void const *value)
+static unsigned BAMAlignmentSetOffsets(BAMAlignment *const self)
{
- struct ctx_LoadOptTags_s *ctx = Ctx;
- BAMAlignment *self = ctx->self;
+ unsigned const nameLen = getReadNameLength(self);
+ unsigned const cigCnt = getCigarCount(self);
+ unsigned const readLen = getReadLen(self);
+ unsigned const cigar = (unsigned)(&((struct bam_alignment_s const *)NULL)->read_name[nameLen] - (const char *)NULL);
+ unsigned const seq = cigar + 4 * cigCnt;
+ unsigned const qual = seq + (readLen + 1) / 2;
+ unsigned const xtra = qual + readLen;
- self->extra[ctx->i].offset = (unsigned)((uint8_t const *)&tag[0] - (uint8_t const *)&self->data->raw[0]);
- self->extra[ctx->i].size = length;
- ++ctx->i;
- return false;
+ self->cigar = cigar;
+ self->seq = seq;
+ self->qual = qual;
+
+ return xtra;
}
-LIB_EXPORT rc_t CC BAMFileRead(const BAMFile *cself, const BAMAlignment **rhs)
+static bool BAMAlignmentInit(BAMAlignment *const self, unsigned const maxsize,
+ unsigned const datasize, void const *const data)
{
- BAMFile *self = (BAMFile *)cself;
- BAMAlignment *y;
- BAMAlignment x;
- struct ctx_LoadOptTags_s load_ctx;
- bool local = false;
- int32_t i32;
- rc_t rc;
- unsigned xtra;
+ self->data = data;
+ self->datasize = datasize;
+ {
+ unsigned const xtra = BAMAlignmentSetOffsets(self);
+
+ if ( datasize >= xtra
+ && datasize >= self->cigar
+ && datasize >= self->seq
+ && datasize >= self->qual)
+ {
+ rc_t const rc = ParseOptData(self, maxsize, xtra, datasize);
+
+ if (rc == 0)
+ return true;
+ }
+ return false;
+ }
+}
+
+static bool BAMAlignmentInitLog(BAMAlignment *const self, unsigned const maxsize,
+ unsigned const datasize, void const *const data)
+{
+ self->data = data;
+ self->datasize = datasize;
+ {
+ unsigned const xtra = BAMAlignmentSetOffsets(self);
+
+ if ( datasize >= xtra
+ && datasize >= self->cigar
+ && datasize >= self->seq
+ && datasize >= self->qual)
+ {
+ rc_t const rc = ParseOptDataLog(self, maxsize, xtra, datasize);
+
+ if (rc == 0) {
+ DBGMSG(DBG_ALIGN, DBG_FLAG(DBG_ALIGN_BAM), ("{"
+ "\"BAM record\": "
+ "{ "
+ "\"size\": %u, "
+ "\"name length\": %u, "
+ "\"cigar count\": %u, "
+ "\"read length\": %u, "
+ "\"extra count\": %u "
+ "}"
+ "}\n",
+ (unsigned)datasize,
+ (unsigned)getReadNameLength(self),
+ (unsigned)getCigarCount(self),
+ (unsigned)getReadLen(self),
+ (unsigned)self->numExtra));
+ return true;
+ }
+ }
+ DBGMSG(DBG_ALIGN, DBG_FLAG(DBG_ALIGN_BAM), ("{"
+ "\"BAM record\": "
+ "{ "
+ "\"size\": %u, "
+ "\"name length\": %u, "
+ "\"cigar count\": %u, "
+ "\"read length\": %u "
+ "}"
+ "}\n",
+ (unsigned)datasize,
+ (unsigned)getReadNameLength(self),
+ (unsigned)getCigarCount(self),
+ (unsigned)getReadLen(self)));
+ return false;
+ }
+}
+
+static void BAMAlignmentLogParseError(BAMAlignment const *self)
+{
+ char const *const reason = self->cigar > self->datasize ? "BAM Record CIGAR too long"
+ : self->seq > self->datasize ? "BAM Record SEQ too long"
+ : self->qual > self->datasize ? "BAM Record QUAL too long"
+ : self->qual + getReadLen(self) > self->datasize ? "BAM Record EXTRA too long"
+ : "BAM Record EXTRA parsing failure";
- *rhs = NULL;
+ LOGERR(klogErr, RC(rcAlign, rcFile, rcReading, rcRow, rcInvalid), reason);
+}
- if (cself == NULL)
- return RC(rcAlign, rcFile, rcReading, rcParam, rcNull);
+/* MARK: BAM Alignment readers */
+
+/* returns
+ * (rcAlign, rcFile, rcReading, rcBuffer, rcNotAvailable)
+ * or
+ * (rcAlign, rcFile, rcReading, rcBuffer, rcInsufficient)
+ * if should read with copy
+ */
+static
+rc_t BAMFileReadNoCopy(BAMFile *const self, unsigned actsize[], BAMAlignment rhs[],
+ unsigned const maxsize)
+{
+ unsigned const maxPeek = BAMFileMaxPeek(self);
+ bool isgood;
+
+ *actsize = 0;
- if (cself->bufCurrent >= cself->bufSize && cself->eof)
- return RC(rcAlign, rcFile, rcReading, rcRow, rcNotFound);
+ rhs[0].parent = self;
+ if (maxPeek == 0) {
+ rc_t const rc = BAMFileFillBuffer(self);
+
+ if (rc == 0)
+ return BAMFileReadNoCopy(self, actsize, rhs, maxsize);
+
+ if (GetRCObject(rc) == rcData && GetRCState(rc) == rcInsufficient) {
+ self->eof = true;
+ return RC(rcAlign, rcFile, rcReading, rcRow, rcNotFound);
+ }
+ return rc;
+ }
+ if (maxPeek < 4)
+ return RC(rcAlign, rcFile, rcReading, rcBuffer, rcNotAvailable);
+ else {
+ int32_t const i32 = BAMFilePeekI32(self);
+
+ if (i32 <= 0)
+ return RC(rcAlign, rcFile, rcReading, rcData, rcInvalid);
+
+ if (maxPeek < i32 + 4)
+ return RC(rcAlign, rcFile, rcReading, rcBuffer, rcNotAvailable);
+
+ isgood = BAMAlignmentInitLog(rhs, maxsize, i32, BAMFilePeek(self, 4));
+ KRefcountInit(&rhs->refcount, 1, "BAMAlignment", "ReadNoCopy", "");
+ }
+ *actsize = BAMAlignmentSize(rhs[0].numExtra);
+ if (isgood && *actsize > maxsize)
+ return RC(rcAlign, rcFile, rcReading, rcBuffer, rcInsufficient);
+
+ BAMFileAdvance(self, 4 + rhs->datasize);
+ return isgood ? 0 : RC(rcAlign, rcFile, rcReading, rcRow, rcInvalid);
+}
+
+static
+unsigned BAMAlignmentSizeFromData(unsigned const datasize, void const *data)
+{
+ BAMAlignment temp;
+
+ memset(&temp, 0, sizeof(temp));
+ BAMAlignmentInit(&temp, sizeof(temp), datasize, data);
+
+ return BAMAlignmentSize(temp.numExtra);
+}
+
+static
+rc_t BAMFileReadCopy(BAMFile *const self, BAMAlignment const *rslt[], bool const log)
+{
+ void *storage;
+ void const *data;
+ unsigned datasize;
+ rc_t rc;
+
+ rslt[0] = NULL;
+ {
+ int32_t i32;
+
+ rc = BAMFileReadI32(self, &i32);
+ if (rc) {
+ if (GetRCObject(rc) == rcData && GetRCState(rc) == rcInsufficient) {
+ self->eof = true;
+ rc = RC(rcAlign, rcFile, rcReading, rcRow, rcNotFound);
+ }
+ return rc;
+ }
+ if (i32 <= 0)
+ return RC(rcAlign, rcFile, rcReading, rcData, rcInvalid);
+
+ datasize = i32;
+ }
+ if (BAMFileMaxPeek(self) < datasize) {
+ data = storage = malloc(datasize);
+ if (storage == NULL)
+ return RC(rcAlign, rcFile, rcReading, rcMemory, rcExhausted);
+
+ rc = BAMFileReadn(self, datasize, storage);
+ }
+ else {
+ storage = NULL;
+ data = (bam_alignment *)&self->buffer[self->bufCurrent];
+
+ BAMFileAdvance(self, datasize);
+ }
+ if (rc == 0) {
+ unsigned const rsltsize = BAMAlignmentSizeFromData(datasize, data);
+ BAMAlignment *const y = calloc(rsltsize, 1);
+
+ if (y) {
+ if ((log ? BAMAlignmentInitLog : BAMAlignmentInit)(y, rsltsize, datasize, data)) {
+ if (storage == NULL)
+ self->bufLocker = y;
+ else
+ y->storage = storage;
+ KRefcountInit(&y->refcount, 1, "BAMAlignment", "ReadCopy", "");
+ y->parent = self;
+ BAMFileAddRef(self);
+ rslt[0] = y;
+
+ if (getReadLen(y) == 0 && getCigarCount(y) == 0)
+ return RC(rcAlign, rcFile, rcReading, rcRow, rcEmpty);
+ return 0;
+ }
+ rc = RC(rcAlign, rcFile, rcReading, rcRow, rcInvalid);
+ free(y);
+ }
+ else
+ rc = RC(rcAlign, rcFile, rcReading, rcMemory, rcExhausted);
+ }
+ free(storage);
+
+ return rc;
+}
+
+static
+rc_t BAMFileBreakLock(BAMFile *const self)
+{
if (self->bufLocker != NULL) {
if (self->bufLocker->storage == NULL)
self->bufLocker->storage = malloc(self->bufLocker->datasize);
if (self->bufLocker->storage == NULL)
return RC(rcAlign, rcFile, rcReading, rcMemory, rcExhausted);
+
memcpy(self->bufLocker->storage, self->bufLocker->data, self->bufLocker->datasize);
self->bufLocker->data = (bam_alignment *)&self->bufLocker->storage[0];
self->bufLocker = NULL;
}
+ return 0;
+}
+
+LIB_EXPORT rc_t CC BAMFileRead2(const BAMFile *cself, const BAMAlignment **rhs)
+{
+ BAMFile *const self = (BAMFile *)cself;
+ unsigned actsize = 0;
+ rc_t rc;
- rc = BAMFileReadI32(self, &i32);
- if (rc) {
- if (GetRCObject(rc) == rcData && GetRCState(rc) == rcInsufficient) {
- self->eof = true;
- rc = RC(rcAlign, rcFile, rcReading, rcRow, rcNotFound);
- }
- return rc;
- }
- if (i32 <= 0)
- return RC(rcAlign, rcFile, rcReading, rcData, rcInvalid);
+ if (self == NULL || rhs == NULL)
+ return RC(rcAlign, rcFile, rcReading, rcParam, rcNull);
- DBGMSG(DBG_ALIGN, DBG_FLAG(DBG_ALIGN_BAM), ("BAM record: { size: %i }\n", i32));
- memset(&x, 0, sizeof(x));
- x.datasize = i32;
+ *rhs = NULL;
- if (self->bufCurrent + x.datasize <= self->bufSize) {
- x.data = (bam_alignment *)&self->buffer[self->bufCurrent];
- local = true;
- }
- else {
- x.storage = malloc(x.datasize);
- if (x.storage == NULL)
+ if (self->bufCurrent >= self->bufSize && self->eof)
+ return RC(rcAlign, rcFile, rcReading, rcRow, rcNotFound);
+
+ rc = BAMFileBreakLock(self);
+ if (rc)
+ return rc;
+
+ if (self->nocopy_size == 0) {
+ size_t const size = 4096u;
+ void *const temp = malloc(size);
+
+ if (temp == NULL)
return RC(rcAlign, rcFile, rcReading, rcMemory, rcExhausted);
- rc = BAMFileReadn(self, x.datasize, x.storage);
- if (rc) {
- free(x.storage);
- return rc;
+ self->nocopy = temp;
+ self->nocopy_size = size;
+ }
+
+AGAIN:
+ rc = BAMFileReadNoCopy(self, &actsize, self->nocopy, (unsigned)self->nocopy_size);
+ if (rc == 0) {
+ *rhs = self->nocopy;
+ if (getReadLen(*rhs) == 0 && getCigarCount(*rhs) == 0) {
+ rc = RC(rcAlign, rcFile, rcReading, rcRow, rcEmpty);
+ LOGERR(klogWarn, rc, "BAM Record contains no alignment or sequence data");
}
- x.data = (bam_alignment *)x.storage;
}
- {{
- unsigned const nameLen = getReadNameLength(&x);
- unsigned const cigCnt = getCigarCount(&x);
- unsigned const readLen = getReadLen(&x);
+ else if (GetRCObject(rc) == rcBuffer && GetRCState(rc) == rcInsufficient) {
+ unsigned const size = (actsize + 4095u) & ~4095u;
+ void *const temp = realloc(self->nocopy, size);
+
+ if (temp == NULL)
+ return RC(rcAlign, rcFile, rcReading, rcMemory, rcExhausted);
- DBGMSG(DBG_ALIGN, DBG_FLAG(DBG_ALIGN_BAM), ("BAM record: { name length: %u, cigar count: %u, read length %u }\n", nameLen, cigCnt, readLen));
- x.cigar = sizeof(x.data[0]) + nameLen - 1;
- x.seq = x.cigar + 4 * cigCnt;
- x.qual = x.seq + (readLen + 1) / 2;
- xtra = x.qual + readLen;
- }}
- if ( x.cigar >= x.datasize
- || x.seq > x.datasize
- || x.qual > x.datasize
- || xtra > x.datasize
- || (rc = ParseOptData(&x.data->raw[xtra], x.datasize - xtra, &x.numExtra, CountOptTags)) != 0)
- {
- rc = RC(rcAlign, rcFile, rcReading, rcRow, rcInvalid);
- free(x.storage);
- return rc;
- }
- DBGMSG(DBG_ALIGN, DBG_FLAG(DBG_ALIGN_BAM), ("BAM record: { number of extra fields: %u }\n", x.numExtra));
- y = calloc(sizeof(*y) + (x.numExtra ? x.numExtra - 1 : 0) * sizeof(y->extra), 1);
- if (y == NULL) {
- free(x.storage);
- return RC(rcAlign, rcFile, rcReading, rcMemory, rcExhausted);
+ self->nocopy = temp;
+ self->nocopy_size = size;
+
+ goto AGAIN;
}
- *y = x;
- load_ctx.self = y;
- load_ctx.i = 0;
- if ((rc = ParseOptData(&y->data->raw[xtra], y->datasize - xtra, &load_ctx, LoadOptTags)) != 0) {
- free(x.storage);
- free(y);
- return rc;
+ else if (GetRCObject(rc) == rcBuffer && GetRCState(rc) == rcNotAvailable) {
+ rc = BAMFileReadCopy(self, rhs, true);
}
- ksort(y->extra, y->numExtra, sizeof(y->extra[0]), OptTag_sort, y);
-
- BAMFileAddRef(y->parent = self);
- atomic32_set(&y->refcount, 1);
- if (local) {
- self->bufLocker = y;
- self->bufCurrent += y->datasize;
- if (self->bufCurrent == self->bufSize) {
- self->fpos_cur = self->vt.FileGetPos(&self->file);
- self->bufCurrent = 0;
- self->bufSize = 0;
- }
+ else if (GetRCObject(rc) == rcRow && GetRCState(rc) == rcInvalid) {
+ BAMAlignmentLogParseError(self->nocopy);
}
+ return rc;
+}
+
+LIB_EXPORT rc_t CC BAMFileRead(const BAMFile *cself, const BAMAlignment **rhs)
+{
+ BAMFile *const self = (BAMFile *)cself;
- *rhs = y;
- return 0;
+ if (self == NULL || rhs == NULL)
+ return RC(rcAlign, rcFile, rcReading, rcParam, rcNull);
+
+ *rhs = NULL;
+
+ if (self->bufCurrent >= self->bufSize && self->eof)
+ return RC(rcAlign, rcFile, rcReading, rcRow, rcNotFound);
+ else {
+ rc_t const rc = BAMFileBreakLock(self);
+ if (rc)
+ return rc;
+ }
+ return BAMFileReadCopy(self, rhs, false);
}
+/* MARK: BAM File header info accessor */
+
LIB_EXPORT rc_t CC BAMFileGetRefSeqById(const BAMFile *cself, int32_t id, const BAMRefSeq **rhs)
{
*rhs = NULL;
@@ -2071,33 +2406,34 @@ LIB_EXPORT rc_t CC BAMFileGetHeaderText(BAMFile const *cself, char const **heade
return 0;
}
-/* MARK: BAM Alignment Stuff */
+/* MARK: BAM Alignment destructor */
-LIB_EXPORT rc_t CC BAMAlignmentAddRef(const BAMAlignment *cself)
+static rc_t BAMAlignmentWhack(BAMAlignment *self)
{
- if (cself != NULL)
- atomic32_inc(&((BAMAlignment *)cself)->refcount);
+ if (self->parent->bufLocker == self)
+ self->parent->bufLocker = NULL;
+ if (self != self->parent->nocopy) {
+ BAMFileRelease(self->parent);
+ free(self->storage);
+ free(self);
+ }
return 0;
}
-static rc_t BAMAlignmentWhack(BAMAlignment *self)
+/* MARK: BAM Alignment ref-counting */
+
+LIB_EXPORT rc_t CC BAMAlignmentAddRef(const BAMAlignment *cself)
{
- if (self->parent->bufLocker == self)
- self->parent->bufLocker = NULL;
- BAMFileRelease(self->parent);
- free(self->storage);
- free(self);
+ if (cself != NULL)
+ KRefcountAdd(&cself->refcount, "BAMAlignment");
return 0;
}
LIB_EXPORT rc_t CC BAMAlignmentRelease(const BAMAlignment *cself)
{
- if (cself != NULL) {
- BAMAlignment *self = (BAMAlignment *)cself;
-
- if (atomic32_dec_and_test(&self->refcount))
- BAMAlignmentWhack(self);
- }
+ if (cself && KRefcountDrop(&cself->refcount, "BAMAlignment") == krefWhack)
+ BAMAlignmentWhack((BAMAlignment *)cself);
+
return 0;
}
@@ -2111,6 +2447,8 @@ LIB_EXPORT uint16_t CC BAMAlignmentBadFields(const BAMAlignment *self)
}
#endif
+/* MARK: BAM Alignment accessors */
+
static uint32_t BAMAlignmentGetCigarElement(const BAMAlignment *self, unsigned i)
{
return LE2HUI32(&((uint8_t const *)getCigarBase(self))[i * 4]);
@@ -2135,6 +2473,13 @@ LIB_EXPORT bool CC BAMAlignmentIsMapped(const BAMAlignment *cself)
return false;
}
+static bool BAMAlignmentIsMateMapped(const BAMAlignment *cself)
+{
+ if (((getFlags(cself) & BAMFlags_MateIsUnmapped) == 0) && getMateRefSeqId(cself) >= 0 && getMatePos(cself) >= 0)
+ return true;
+ return false;
+}
+
LIB_EXPORT rc_t CC BAMAlignmentGetAlignmentDetail(
const BAMAlignment *self,
BAMAlignmentDetail *rslt, uint32_t count, uint32_t *actual,
@@ -2514,6 +2859,324 @@ LIB_EXPORT rc_t CC BAMAlignmentGetInsertSize(const BAMAlignment *cself, int64_t
return 0;
}
+static int FormatOptData(BAMAlignment const *const self,
+ size_t const maxsize,
+ char buffer[])
+{
+ char const *const base = (char const *)&self->data->raw[self->qual + getReadLen(self)];
+ unsigned i;
+ unsigned offset;
+ unsigned cur = 0;
+ int j;
+
+ for (i = 0, offset = 0; i < self->numExtra; ++i) {
+ int type;
+ union { float f; uint32_t i; } fi;
+
+ if (cur + 7 > maxsize)
+ return -1;
+ buffer[cur++] = '\t';
+ buffer[cur++] = base[offset++];
+ buffer[cur++] = base[offset++];
+ buffer[cur++] = ':';
+ type = base[offset++];
+
+ switch (type) {
+ case dt_ASCII: /* A */
+ buffer[cur++] = 'A';
+ buffer[cur++] = ':';
+ buffer[cur++] = base[offset++];
+ break;
+
+ case dt_INT8: /* c */
+ buffer[cur++] = 'i';
+ buffer[cur++] = ':';
+ j = snprintf(buffer + cur, maxsize - cur, "%i", (int)*((int8_t const *)(base + offset)));
+ if ((cur += j) >= maxsize)
+ return -1;
+ offset += 1;
+ break;
+
+ case dt_UINT8: /* C */
+ buffer[cur++] = 'i';
+ buffer[cur++] = ':';
+ j = snprintf(buffer + cur, maxsize - cur, "%u", (unsigned)*((uint8_t const *)(base + offset)));
+ if ((cur += j) >= maxsize)
+ return -1;
+ offset += 1;
+ break;
+
+ case dt_INT16: /* s */
+ buffer[cur++] = 'i';
+ buffer[cur++] = ':';
+ j = snprintf(buffer + cur, maxsize - cur, "%i", (int)LE2HI16(base + offset));
+ if ((cur += j) >= maxsize)
+ return -1;
+ offset += 2;
+ break;
+
+ case dt_UINT16: /* S */
+ buffer[cur++] = 'i';
+ buffer[cur++] = ':';
+ j = snprintf(buffer + cur, maxsize - cur, "%u", (unsigned)LE2HUI16(base + offset));
+ if ((cur += j) >= maxsize)
+ return -1;
+ offset += 2;
+ break;
+
+ case dt_INT: /* i */
+ buffer[cur++] = 'i';
+ buffer[cur++] = ':';
+ j = snprintf(buffer + cur, maxsize - cur, "%i", (int)LE2HI32(base + offset));
+ if ((cur += j) >= maxsize)
+ return -1;
+ offset += 4;
+ break;
+
+ case dt_UINT: /* I */
+ buffer[cur++] = 'i';
+ buffer[cur++] = ':';
+ j = snprintf(buffer + cur, maxsize - cur, "%i", (int)LE2HI32(base + offset));
+ if ((cur += j) >= maxsize)
+ return -1;
+ offset += 4;
+ break;
+
+ case dt_FLOAT32: /* f */
+ buffer[cur++] = 'f';
+ buffer[cur++] = ':';
+ fi.i = LE2HUI32(base + offset);
+ j = snprintf(buffer + cur, maxsize - cur, "%f", fi.f);
+ if ((cur += j) >= maxsize)
+ return -1;
+ offset += 4;
+ break;
+
+ case dt_HEXSTRING: /* H */
+ case dt_CSTRING: /* Z */
+ buffer[cur++] = type == dt_CSTRING ? 'Z' : 'H';
+ buffer[cur++] = ':';
+ for ( ; ; ) {
+ int const ch = base[offset++];
+
+ if (ch == '\0')
+ break;
+ if (cur >= maxsize)
+ return -1;
+ buffer[cur++] = ch;
+ }
+ break;
+
+ case dt_NUM_ARRAY: /* B */
+ buffer[cur++] = 'B';
+ buffer[cur++] = ':';
+ {
+ int const elemtype = base[offset++];
+ unsigned const elemcount = LE2HUI32(base + offset);
+ unsigned k;
+
+ if (cur + 2 >= maxsize)
+ return -1;
+ buffer[cur++] = elemtype;
+ offset += 4;
+ for (k = 0; k < elemcount; ++k) {
+ buffer[cur++] = ',';
+ switch (elemtype) {
+ case dt_INT8:
+ j = snprintf(buffer + cur, maxsize - cur, "%i", (int)*((int8_t const *)(base + offset)));
+ if ((cur += j) >= maxsize)
+ return -1;
+ offset += 1;
+ break;
+
+ case dt_UINT8:
+ j = snprintf(buffer + cur, maxsize - cur, "%u", (unsigned)*((uint8_t const *)(base + offset)));
+ if ((cur += j) >= maxsize)
+ return -1;
+ offset += 1;
+ break;
+
+ case dt_INT16:
+ j = snprintf(buffer + cur, maxsize - cur, "%i", (int)LE2HI16(base + offset));
+ if ((cur += j) >= maxsize)
+ return -1;
+ offset += 2;
+ break;
+
+ case dt_UINT16:
+ j = snprintf(buffer + cur, maxsize - cur, "%u", (unsigned)LE2HUI16(base + offset));
+ if ((cur += j) >= maxsize)
+ return -1;
+ offset += 2;
+ break;
+
+ case dt_INT:
+ j = snprintf(buffer + cur, maxsize - cur, "%i", (int)LE2HI32(base + offset));
+ if ((cur += j) >= maxsize)
+ return -1;
+ offset += 4;
+ break;
+
+ case dt_UINT:
+ j = snprintf(buffer + cur, maxsize - cur, "%u", (unsigned)LE2HUI32(base + offset));
+ if ((cur += j) >= maxsize)
+ return -1;
+ offset += 4;
+ break;
+
+ case dt_FLOAT32:
+ fi.i = LE2HUI32(base + offset);
+ j = snprintf(buffer + cur, maxsize - cur, "%f", fi.f);
+ if ((cur += j) >= maxsize)
+ return -1;
+ offset += 4;
+
+ default:
+ return -1;
+ break;
+ }
+ }
+ }
+ break;
+
+ default:
+ return -1;
+ break;
+ }
+ }
+ return cur;
+}
+
+static rc_t FormatSAM(BAMAlignment const *self,
+ size_t *const actsize,
+ size_t const maxsize,
+ char *const buffer)
+{
+ int i = 0;
+ size_t cur = 0;
+ unsigned j;
+ int const refSeqId = getRefSeqId(self);
+ int const refPos = getPosition(self);
+ unsigned const cigCount = getCigarCount(self);
+ uint32_t const *const cigar = getCigarBase(self);
+ int const mateRefSeqId = getMateRefSeqId(self);
+ int const mateRefPos = getMatePos(self);
+ unsigned const readlen = getReadLen(self);
+
+ i = snprintf(&buffer[cur], maxsize - cur,
+ "%s\t%i\t%s\t%i\t%i\t",
+ getReadName(self),
+ getFlags(self),
+ refSeqId < 0 ? "*" : self->parent->refSeq[refSeqId].name,
+ refPos < 0 ? 0 : refPos + 1,
+ getMapQual(self)
+ );
+ if ((cur += i) > maxsize)
+ return RC(rcAlign, rcRow, rcReading, rcData, rcExcessive);
+
+ if (cigCount > 0) {
+ for (j = 0; j < cigCount; ++j) {
+ uint32_t const el = cigar[j];
+ BAMCigarType const type = (BAMCigarType)(cigarChars[el & 0x0F]);
+ unsigned const length = el >> 4;
+
+ i = snprintf(&buffer[cur], maxsize - cur, "%u%c", length, type);
+ if ((cur += i) > maxsize)
+ return RC(rcAlign, rcRow, rcReading, rcData, rcExcessive);
+ }
+ }
+ else {
+ if ((cur + 1) > maxsize)
+ return RC(rcAlign, rcRow, rcReading, rcData, rcExcessive);
+ buffer[cur++] = '*';
+ }
+ i = snprintf(&buffer[cur], maxsize - cur,
+ "\t%s\t%i\t%i\t",
+ mateRefSeqId < 0 ? "*" : mateRefSeqId == refSeqId ? "=" : self->parent->refSeq[mateRefSeqId].name,
+ mateRefPos < 0 ? 0 : mateRefPos + 1,
+ getInsertSize(self)
+ );
+ if ((cur += i) > maxsize)
+ return RC(rcAlign, rcRow, rcReading, rcData, rcExcessive);
+ if (readlen) {
+ uint8_t const *const qual = &self->data->raw[self->qual];
+
+ if (cur + 2 * readlen + 1 > maxsize)
+ return RC(rcAlign, rcRow, rcReading, rcData, rcExcessive);
+ BAMAlignmentGetSequence(self, &buffer[cur]);
+ cur += readlen;
+ buffer[cur] = '\t';
+ ++cur;
+
+ for (j = 0; j < readlen; ++j) {
+ if (qual[j] != 0xFF)
+ goto HAS_QUAL;
+ }
+ if (1) {
+ buffer[cur++] = '*';
+ }
+ else {
+ HAS_QUAL:
+ for (j = 0; j < readlen; ++j)
+ buffer[cur++] = qual[j] + 33;
+ }
+ }
+ else {
+ i = snprintf(&buffer[cur], maxsize - cur, "*\t*");
+ if ((cur += i) > maxsize)
+ return RC(rcAlign, rcRow, rcReading, rcData, rcExcessive);
+ }
+ i = FormatOptData(self, maxsize - cur, &buffer[cur]);
+ if (i < 0)
+ return RC(rcAlign, rcRow, rcReading, rcData, rcExcessive);
+ if ((cur += i) + 2 > maxsize)
+ return RC(rcAlign, rcRow, rcReading, rcData, rcExcessive);
+ buffer[cur++] = '\n';
+ buffer[cur] = '\0';
+ *actsize = cur;
+
+ return 0;
+}
+
+#define FORMAT_SAM_SCRATCH_SIZE ((size_t)(64u * 1024u))
+static rc_t FormatSAMBuffer(BAMAlignment const *self,
+ size_t actSize[],
+ size_t const maxsize,
+ char *const buffer)
+{
+ char scratch[FORMAT_SAM_SCRATCH_SIZE];
+ size_t actsize = 0;
+ rc_t const rc = FormatSAM(self, &actsize, FORMAT_SAM_SCRATCH_SIZE, scratch);
+
+ actSize[0] = actsize;
+ if (rc) return rc;
+
+ if (actsize > maxsize)
+ return RC(rcAlign, rcReading, rcRow, rcBuffer, rcInsufficient);
+
+ memcpy(buffer, scratch, actsize);
+ return 0;
+}
+
+LIB_EXPORT rc_t CC BAMAlignmentFormatSAM(BAMAlignment const *self,
+ size_t *const actSize,
+ size_t const maxsize,
+ char *const buffer)
+{
+ if (self == NULL)
+ return RC(rcAlign, rcReading, rcRow, rcSelf, rcNull);
+ if (buffer == NULL)
+ return RC(rcAlign, rcReading, rcRow, rcParam, rcNull);
+ else {
+ size_t actsize = 0;
+ rc_t const rc = (maxsize < FORMAT_SAM_SCRATCH_SIZE ? FormatSAMBuffer : FormatSAM)(self, &actsize, maxsize, buffer);
+
+ if (actSize)
+ *actSize = actsize;
+ return rc;
+ }
+}
+
typedef struct OptForEach_ctx_s {
BAMOptData *val;
BAMOptData **alloced;
@@ -2544,7 +3207,7 @@ static bool i_OptDataForEach(BAMAlignment const *cself, void *Ctx, char const ta
#if __BYTE_ORDER == __BIG_ENDIAN
{{
unsigned di;
- uint32_t elem_count = ctx->val->element_count;
+ uint32_t elem_count = ctx->val->element_count;
switch (size) {
case 2:
@@ -2611,9 +3274,11 @@ LIB_EXPORT rc_t CC BAMAlignmentOptDataForEach(const BAMAlignment *cself, void *u
case dt_UINT:
elem_size = 4;
break;
+#if 0
case dt_FLOAT64:
elem_size = 8;
break;
+#endif
default:
rc = RC(rcAlign, rcFile, rcReading, rcData, rcUnexpected);
break;
@@ -2636,6 +3301,8 @@ LIB_EXPORT rc_t CC BAMAlignmentOptDataForEach(const BAMAlignment *cself, void *u
return rc;
}
+/* MARK: Complete Genomics stuff */
+
LIB_EXPORT bool CC BAMAlignmentHasCGData(BAMAlignment const *self)
{
return get_CG_GC_info(self) && get_CG_GS_info(self) && get_CG_GQ_info(self);
@@ -3031,6 +3698,7 @@ rc_t CC BAMAlignmentGetCGCigar(BAMAlignment const *self,
return RC(rcAlign, rcRow, rcReading, rcData, rcNotFound);
}
+/* MARK: end CG stuff */
LIB_EXPORT rc_t BAMAlignmentGetTI(BAMAlignment const *self, uint64_t *ti)
{
@@ -3576,7 +4244,7 @@ LIB_EXPORT rc_t CC BAMFileSeek(const BAMFile *self, uint32_t refSeqId, uint64_t
* fix the file and regenerate the index
*/
if (prev_alignPos > alignPos)
- return RC(rcAlign, rcFile, rcPositioning, rcData, rcInvalid);
+ return RC(rcAlign, rcFile, rcPositioning, rcIndex, rcInvalid);
prev_alignPos = alignPos;
} while (1);
}
diff --git a/libs/align/refseq-mgr.c b/libs/align/refseq-mgr.c
index fde6e90..a9e9979 100644
--- a/libs/align/refseq-mgr.c
+++ b/libs/align/refseq-mgr.c
@@ -576,6 +576,10 @@ LIB_EXPORT rc_t RefSeqMgr_Exists(const RefSeqMgr* cself, const char* accession,
rc = VDBManagerOpenTableRead(cself->vmgr, &tbl, NULL, "ncbi-acc:%.*s?vdb-ctx=refseq", accession_sz, accession);
else
rc = VDBManagerOpenTableRead(cself->vmgr, &tbl, NULL, "%.*s", accession_sz, accession);
+ if (tbl == NULL) {
+ ALIGN_DBG("failed to open %.*s", accession_sz, accession);
+ ALIGN_DBGERR(rc);
+ }
VTableRelease(tbl);
#endif
}
diff --git a/libs/align/writer-alignment.c b/libs/align/writer-alignment.c
index 5c985d1..031fde1 100644
--- a/libs/align/writer-alignment.c
+++ b/libs/align/writer-alignment.c
@@ -313,7 +313,7 @@ LIB_EXPORT rc_t CC TableWriterAlgn_TmpKeyStart(const TableWriterAlgn* cself)
memcpy(self->cols_spotid + 1, &TableWriterAlgn_cols[ewalgn_cn_MATE_GLOBAL_REF_START], sizeof(self->cols_spotid[0]));
memcpy(self->cols_spotid + 2, &TableWriterAlgn_cols[ewalgn_cn_MATE_REF_ID], sizeof(self->cols_spotid[0]));
memcpy(self->cols_spotid + 3, &TableWriterAlgn_cols[ewalgn_cn_MATE_REF_START], sizeof(self->cols_spotid[0]));
- memcpy(self->cols_spotid + 3, &TableWriterAlgn_cols[ewalgn_cn_MATE_ALIGN_ID], sizeof(self->cols_spotid[0]));
+ memcpy(self->cols_spotid + 4, &TableWriterAlgn_cols[ewalgn_cn_MATE_ALIGN_ID], sizeof(self->cols_spotid[0]));
self->cols_spotid[0].flags &= ~ewcol_Ignore;
if (self->options & ewalgn_co_MATE_POSITION) {
diff --git a/libs/align/writer-reference.c b/libs/align/writer-reference.c
index 47c5484..8c98e7e 100644
--- a/libs/align/writer-reference.c
+++ b/libs/align/writer-reference.c
@@ -882,6 +882,7 @@ rc_t ReferenceSeq_Attach(ReferenceMgr *const self, ReferenceSeq *const rs)
assert(id_len != 0 || seqid_len != 0);
if (seqid_len) {
+ ALIGN_CF_DBGF(("trying to open refseq: %.*s\n", seqid_len, rs->seqId));
if (RefSeqMgr_Exists(self->rmgr, rs->seqId, seqid_len, NULL) == 0) {
rc = RefSeqMgr_GetSeq(self->rmgr, &rs->u.refseq, rs->seqId, seqid_len);
if (rc == 0) {
@@ -892,6 +893,7 @@ rc_t ReferenceSeq_Attach(ReferenceMgr *const self, ReferenceSeq *const rs)
}
}
if (id_len) {
+ ALIGN_CF_DBGF(("trying to open refseq: %.*s\n", id_len, rs->id));
if (RefSeqMgr_Exists(self->rmgr, rs->id, id_len, NULL) == 0) {
rc = RefSeqMgr_GetSeq(self->rmgr, &rs->u.refseq, rs->id, id_len);
if (rc == 0) {
@@ -902,16 +904,21 @@ rc_t ReferenceSeq_Attach(ReferenceMgr *const self, ReferenceSeq *const rs)
}
}
if (id_len) {
+ ALIGN_CF_DBGF(("trying to open fasta: %.*s\n", id_len, rs->id));
rc = OpenFastaFile(&kf, self->dir, rs->id, id_len);
- if (rc && seqid_len)
+ if (rc && seqid_len) {
+ ALIGN_CF_DBGF(("trying to open fasta: %.*s\n", seqid_len, rs->seqId));
rc = OpenFastaFile(&kf, self->dir, rs->seqId, seqid_len);
+ }
}
- else
+ else {
+ ALIGN_CF_DBGF(("trying to open fasta: %.*s\n", seqid_len, rs->seqId));
rc = OpenFastaFile(&kf, self->dir, rs->seqId, seqid_len);
-
+ }
if (kf) {
ReferenceSeq tmp;
+ ALIGN_CF_DBGF(("importing fasta"));
rc = ReferenceMgr_ImportFastaFile(self, kf, &tmp);
KFileRelease(kf);
if (rc == 0) {
@@ -2199,13 +2206,15 @@ rc_t cigar2offset(const uint32_t options, const void* cigar, uint32_t cigar_len,
return rc;
}
-static
-void ReferenceSeq_TranslateOffset_int(ReferenceSeq const *const cself,
- INSDC_coord_zero const offset,
- int64_t *const ref_id,
- INSDC_coord_zero *const ref_start,
- uint64_t *const global_ref_start)
+LIB_EXPORT rc_t CC ReferenceSeq_TranslateOffset_int(ReferenceSeq const *const cself,
+ INSDC_coord_zero const offset,
+ int64_t *const ref_id,
+ INSDC_coord_zero *const ref_start,
+ uint64_t *const global_ref_start)
{
+ if( cself == NULL )
+ return RC(rcAlign, rcFile, rcProcessing, rcSelf, rcNull);
+
if (ref_id)
*ref_id = cself->start_rowid + offset / cself->mgr->max_seq_len;
@@ -2214,6 +2223,8 @@ void ReferenceSeq_TranslateOffset_int(ReferenceSeq const *const cself,
if (global_ref_start)
*global_ref_start = (cself->start_rowid - 1) * cself->mgr->max_seq_len + offset;
+
+ return 0;
}
LIB_EXPORT rc_t CC ReferenceMgr_Compress(const ReferenceMgr* cself, uint32_t options,
@@ -2239,24 +2250,6 @@ LIB_EXPORT rc_t CC ReferenceMgr_Compress(const ReferenceMgr* cself, uint32_t opt
return rc;
}
-LIB_EXPORT size_t CC ReferenceMgr_CompressHelper(uint8_t cmp_rslt[],
- TableWriterAlgnData const *const data,
- uint8_t const input[])
-{
- size_t const len = data->has_mismatch.elements;
- bool const *const has_mismatch = data->has_mismatch.buffer;
- size_t i;
- size_t n;
-
- for (n = i = 0; i != len; ++i) {
- if (has_mismatch[i]) {
- cmp_rslt[n] = input[i];
- ++n;
- }
- }
- return n;
-}
-
LIB_EXPORT rc_t CC ReferenceSeq_Compress(const ReferenceSeq* cself, uint32_t options, INSDC_coord_zero offset,
const char* seq, INSDC_coord_len seq_len,
const void* cigar, uint32_t cigar_len,
@@ -2433,7 +2426,6 @@ LIB_EXPORT rc_t CC ReferenceSeq_Compress(const ReferenceSeq* cself, uint32_t opt
has_mismatch[seq_pos] = false;
}
}
- data->mismatch.elements = ReferenceMgr_CompressHelper(mismatch, data, (uint8_t const *)seq);
}
}
}
diff --git a/libs/ascp/linux/ascp-path.c b/libs/ascp/linux/ascp-path.c
index 362b0bd..68ebfb7 100644
--- a/libs/ascp/linux/ascp-path.c
+++ b/libs/ascp/linux/ascp-path.c
@@ -1,5 +1,33 @@
+/*===========================================================================
+*
+* PUBLIC DOMAIN NOTICE
+* National Center for Biotechnology Information
+*
+* This software/database is a "United States Government Work" under the
+* terms of the United States Copyright Act. It was written as part of
+* the author's official duties as a United States Government employee and
+* thus cannot be copyrighted. This software/database is freely available
+* to the public for use. The National Library of Medicine and the U.S.
+* Government have not placed any restriction on its use or reproduction.
+*
+* Although all reasonable efforts have been taken to ensure the accuracy
+* and reliability of the software and data, the NLM and the U.S.
+* Government do not and cannot warrant the performance or results that
+* may be obtained by using this software or data. The NLM and the U.S.
+* Government disclaim all warranties, express or implied, including
+* warranties of performance, merchantability or fitness for any particular
+* purpose.
+*
+* Please cite the author in any work or product based on this material.
+*
+* ==============================================================================
+*
+*/
+
#include "ascp-priv.h" /* ascp_path */
+
#include <klib/printf.h> /* string_printf */
+
#include <assert.h>
#include <limits.h> /* PATH_MAX */
#include <stdlib.h> /* getenv */
diff --git a/libs/ascp/mac/ascp-path.c b/libs/ascp/mac/ascp-path.c
index f5ed131..f1e79d4 100644
--- a/libs/ascp/mac/ascp-path.c
+++ b/libs/ascp/mac/ascp-path.c
@@ -62,4 +62,4 @@ bool ascp_path(const char **cmd, const char **key) {
*cmd = *key = NULL;
return false;
}
-}
\ No newline at end of file
+}
diff --git a/libs/ascp/win/connect.c b/libs/ascp/win/connect.c
index d80f2df..301cf79 100644
--- a/libs/ascp/win/connect.c
+++ b/libs/ascp/win/connect.c
@@ -28,7 +28,7 @@
#include <kfs/directory.h> /* KDirectory */
#include <kfs/impl.h> /* KSysDir */
-#include <kfs/kfs-priv.h> /* KSysDirOSPath */
+#include <kfs/kfs-priv.h> /* KDirectoryPosixStringToSystemString */
#include <klib/log.h> /* LOGERR */
#include <klib/out.h> /* OUTMSG */
@@ -41,30 +41,10 @@
#include <assert.h>
#include <stdio.h> /* stderr */
-#define STS_FIN 3
+#define RELEASE(type, obj) do { rc_t rc2 = type##Release(obj); \
+ if (rc2 && !rc) { rc = rc2; } obj = NULL; } while (false)
-static rc_t posixStringToSystemString(char *buffer, size_t len,
- const char *path, ...)
-{
- KDirectory *wd = NULL;
- rc_t rc = KDirectoryNativeDir(&wd);
- struct KSysDir *sysDir = KDirectoryGetSysDir(wd);
- wchar_t wd_path[MAX_PATH];
- size_t ret = 0;
- va_list args;
- va_start(args, path);
- rc = KSysDirOSPath(sysDir, wd_path, sizeof wd_path, path, args);
- va_end(args);
- KDirectoryRelease(wd);
- if (rc == 0) {
- ret = wcstombs(buffer, wd_path, len);
- if (ret >= MAX_PATH) {
- return RC(rcExe, rcPath, rcConverting, rcPath, rcExcessive);
- }
- }
-
- return rc;
-}
+#define STS_FIN 3
static void beat(uint64_t heartbeat, bool flush) {
static int i = 0;
@@ -102,6 +82,7 @@ static rc_t mkAscpCommand(char *buffer, size_t len,
const char *path, const char *key,
const char *src, const char *dest, const AscpOptions *opt)
{
+ KDirectory *dir = NULL;
const char *maxRate = NULL;
const char *host = NULL;
const char *user = NULL;
@@ -110,31 +91,37 @@ static rc_t mkAscpCommand(char *buffer, size_t len,
size_t pos = 0;
char system[MAX_PATH] = "";
- rc_t rc = posixStringToSystemString(system, sizeof system, dest);
+
+ rc_t rc = KDirectoryNativeDir(&dir);
if (rc != 0) {
return rc;
}
- if (opt != NULL) {
- host = opt->host;
- maxRate = opt->target_rate;
- user = opt->user;
- }
+ rc = KDirectoryPosixStringToSystemString(dir, system, sizeof system, dest);
+ if (rc == 0) {
+ if (opt != NULL) {
+ host = opt->host;
+ maxRate = opt->target_rate;
+ user = opt->user;
+ }
- rc = string_printf(buffer, len, &num_writ,
- "\"%s\" -i \"%s\" -pQTk1%s%s%s%s%s%s %s %s",
- path, key,
- maxRate == NULL ? "" : " -l", maxRate == NULL ? "" : maxRate,
- host == NULL ? "" : " --host ", host == NULL ? "" : host,
- user == NULL ? "" : " --user ", user == NULL ? "" : host,
- src, system);
- if (rc != 0) {
- LOGERR(klogInt, rc, "while creating ascp command line");
- }
- else {
- assert(num_writ < len);
+ rc = string_printf(buffer, len, &num_writ,
+ "\"%s\" -i \"%s\" -pQTk1%s%s%s%s%s%s %s %s",
+ path, key,
+ maxRate == NULL ? "" : " -l", maxRate == NULL ? "" : maxRate,
+ host == NULL ? "" : " --host ", host == NULL ? "" : host,
+ user == NULL ? "" : " --user ", user == NULL ? "" : host,
+ src, system);
+ if (rc != 0) {
+ LOGERR(klogInt, rc, "while creating ascp command line");
+ }
+ else {
+ assert(num_writ < len);
+ }
}
+ RELEASE(KDirectory, dir);
+
return rc;
}
diff --git a/libs/vfs/Makefile b/libs/blast/Makefile
similarity index 74%
copy from libs/vfs/Makefile
copy to libs/blast/Makefile
index a3507de..800ba77 100644
--- a/libs/vfs/Makefile
+++ b/libs/blast/Makefile
@@ -24,20 +24,23 @@
default: all
-TOP ?= $(shell ../../build/abspath.sh ../..)
-MODULE = libs/vfs
+TOP ?= $(abspath ../..)
+
+MODULE = libs/blast
INT_LIBS = \
- libvfs
ALL_LIBS = \
- $(INT_LIBS)
-
-TEST_TOOLS = \
+ $(INT_LIBS) \
+ $(EXT_LIBS)
include $(TOP)/build/Makefile.env
-RWORKDIR=$(TOP)/$(MODULE)
+ifeq (linux,$(OS))
+ifeq (64,$(BITS))
+ INT_LIBS += libvdb-blast
+endif
+endif
#-------------------------------------------------------------------------------
# outer targets
@@ -48,10 +51,7 @@ all std: makedirs
$(INT_LIBS): makedirs
@ $(MAKE_CMD) $(ILIBDIR)/$@
-$(TEST_TOOLS): makedirs
- @ $(MAKE_CMD) $(TEST_BINDIR)/$@
-
-.PHONY: all std $(ALL_LIBS) $(TEST_TOOLS)
+.PHONY: all std $(ALL_LIBS)
#-------------------------------------------------------------------------------
# std
@@ -65,36 +65,21 @@ $(TARGDIR)/std: \
# clean
#
clean: stdclean
- @ rm -f $(addsuffix *,$(addprefix $(TEST_BINDIR)/,$(TEST_TOOLS)))
.PHONY: clean
#-------------------------------------------------------------------------------
-# vfs
+# blast
#
-$(ILIBDIR)/libvfs: $(addprefix $(ILIBDIR)/libvfs.,$(ILIBEXT))
-
-VFS_SRC_CMN = \
- syspath \
- manager \
- resolver \
-
-
-VFS_SRC = \
- path \
- $(VFS_SRC_CMN)
-
-VFS_OBJ = \
- $(addsuffix .$(LOBX),$(VFS_SRC))
-
-VFS_LIB = \
- -lkns \
- -lkurl \
- -lkns \
- -lkrypto \
- -lkfg \
- -lkfs \
- -lklib
-
-$(ILIBDIR)/libvfs.$(LIBX): $(VFS_OBJ)
- $(LD) --slib -o $@ $^ $(VFS_LIB)
+$(ILIBDIR)/libvdb-blast: $(addprefix $(ILIBDIR)/libvdb-blast.,$(ILIBEXT))
+
+BLAST_SRC = \
+ blast \
+
+BLAST_OBJ = \
+ $(addsuffix .$(LOBX),$(BLAST_SRC))
+
+BLAST_LIB = \
+
+$(ILIBDIR)/libvdb-blast.$(LIBX): $(BLAST_OBJ)
+ $(LD) --slib -o $@ $^ $(BLAST_LIB)
diff --git a/libs/blast/blast.c b/libs/blast/blast.c
new file mode 100644
index 0000000..143f3ed
--- /dev/null
+++ b/libs/blast/blast.c
@@ -0,0 +1,5243 @@
+/*===========================================================================
+ *
+ * PUBLIC DOMAIN NOTICE
+ * National Center for Biotechnology Information
+ *
+ * This software/database is a "United States Government Work" under the
+ * terms of the United States Copyright Act. It was written as part of
+ * the author's official duties as a United States Government employee and
+ * thus cannot be copyrighted. This software/database is freely available
+ * to the public for use. The National Library of Medicine and the U.S.
+ * Government have not placed any restriction on its use or reproduction.
+ *
+ * Although all reasonable efforts have been taken to ensure the accuracy
+ * and reliability of the software and data, the NLM and the U.S.
+ * Government do not and cannot warrant the performance or results that
+ * may be obtained by using this software or data. The NLM and the U.S.
+ * Government disclaim all warranties, express or implied, including
+ * warranties of performance, merchantability or fitness for any particular
+ * purpose.
+ *
+ * Please cite the author in any work or product based on this material.
+ *
+ * ===========================================================================
+ *
+ */
+
+#include <vdb/extern.h>
+
+#include <ncbi/vdb-blast.h> /* VdbBlastMgr */
+#include <ncbi/vdb-blast-priv.h> /* VdbBlastMgr */
+
+#include <insdc/insdc.h> /* INSDC_read_type */
+#include <insdc/sra.h> /* SRA_READ_TYPE_BIOLOGICAL */
+
+#include <sra/srapath.h> /* SRAPath */
+#include <sra/sraschema.h> /* VDBManagerMakeSRASchema */
+
+#include <vdb/manager.h> /* VDBManager */
+#include <vdb/schema.h> /* VSchema */
+#include <vdb/database.h> /* VDatabase */
+#include <vdb/table.h> /* VTable */
+#include <vdb/cursor.h> /* VCursor */
+#include <vdb/blob.h> /* VBlob */
+#include <vdb/vdb-priv.h> /* VTableOpenKTableRead */
+
+#include <kdb/kdb-priv.h> /* KTableGetPath */
+#include <kdb/manager.h> /* kptDatabase */
+#include <kdb/meta.h> /* KMetadataRelease */
+#include <kdb/table.h> /* KTable */
+
+#include <vfs/manager.h> /* VFSManager */
+#include <vfs/resolver.h> /* VResolver */
+#include <vfs/path.h> /* VPath */
+
+#include <kfg/config.h> /* KConfig */
+
+#include <kproc/lock.h> /* KLock */
+
+#include <klib/printf.h> /* string_printf */
+#include <klib/refcount.h> /* KRefcount */
+#include <klib/log.h> /* PLOGMSG */
+#include <klib/out.h> /* KOutHandlerSetStdOut */
+#include <klib/debug.h> /* DBGMSG */
+#include <klib/status.h>
+#include <klib/text.h> /* String */
+#include <klib/rc.h> /* GetRCState */
+
+#include <sysalloc.h>
+
+#include <assert.h>
+#include <stdlib.h> /* calloc */
+#include <string.h> /* memset */
+#include <time.h> /* time_t */
+
+#include <stdio.h> /* fprintf */
+
+typedef uint32_t VdbBlastStatus;
+
+#if _DEBUGGING
+#define S STSMSG(9,(""));
+#else
+#define S
+#endif
+
+#define RELEASE(type, obj) do { rc_t rc2 = type##Release(obj); \
+ if (rc2 != 0 && rc == 0) { rc = rc2; } obj = NULL; } while (false)
+
+/******************************************************************************/
+
+static void *_NotImplementedP(const char *func) {
+ PLOGERR(klogErr, (klogErr, -1,
+ "$(func): is not implemented", "func=%s", func));
+ return 0;
+}
+
+static size_t _NotImplemented(const char *func)
+{ return (size_t)_NotImplementedP(func); }
+
+/******************************************************************************/
+
+static
+void _Packed2naReadPrint(const Packed2naRead *self, const void *blob)
+{
+ static char *b = NULL;
+ static size_t bsz = 0;
+ int last = 0;
+ unsigned i = 0;
+ size_t size;
+ assert(self);
+ fflush(stderr);
+ if (b == NULL) {
+ bsz = self->length_in_bases + 64;
+ b = malloc(bsz);
+ if (b == NULL)
+ { return; }
+ }
+ else if (bsz < self->length_in_bases + 64) {
+ char *tmp = NULL;
+ bsz = self->length_in_bases + 64;
+ tmp = realloc(b, bsz);
+ if (tmp == NULL)
+ { return; }
+ b = tmp;
+ }
+ sprintf(b, "%lu\t%p\t", self->read_id, blob);
+ last = string_measure(b, &size);
+ {
+ unsigned ib = 0;
+ uint32_t offset = self->offset_to_first_bit;
+ for (ib = 0; ib < self->length_in_bases; ++ib) {
+ int j = 0;
+ uint8_t a[4];
+ uint8_t u = 0;
+ if (i >= self->length_in_bases)
+ { break; }
+ u = ((uint8_t*)self->starting_byte)[ib];
+ a[0] = (u >> 6) & 3;
+ a[1] = (u >> 4) & 3;
+ a[2] = (u >> 2) & 3;
+ a[3] = u & 3;
+ for (j = offset / 2; j < 4; ++j) {
+ const char c[] = "ACGT";
+ uint8_t h = a[j];
+ if (i >= self->length_in_bases)
+ { break; }
+ assert(h < 4);
+ b[last++] = c[h];
+ ++i;
+ }
+ offset = 0;
+ }
+ b[last++] = '\n';
+ b[last++] = '\0';
+ fprintf(stderr, "%s", b);
+ fflush(stderr);
+ }
+}
+
+/******************************************************************************/
+
+static
+rc_t _VTableLogRowData(const VTable *self,
+ const char *column,
+ void *buffer,
+ uint32_t blen)
+{
+ rc_t rc = 0;
+
+#if _DEBUGGING
+ if (buffer && blen == 64) {
+ uint64_t data = *((uint64_t*)buffer);
+ const KTable *ktbl = NULL;
+ rc_t rc = VTableOpenKTableRead(self, &ktbl);
+ if (rc == 0) {
+ const char *path = NULL;
+ rc = KTableGetPath(ktbl, &path);
+ if (rc == 0) {
+ DBGMSG(DBG_BLAST, DBG_FLAG(DBG_BLAST_BLAST),
+ ("%s: %s: %lu\n", path, column, data));
+ }
+ }
+
+ KTableRelease(ktbl);
+ }
+#endif
+
+ if (rc != 0)
+ { PLOGERR(klogInt, (klogInt, rc, "Error in $(f)", "f=%s", __func__)); }
+
+ return rc;
+}
+
+static
+rc_t _VTableMakeCursorImpl(const VTable *self,
+ const VCursor **curs,
+ uint32_t *col_idx,
+ const char *col_name, bool canBeLost)
+{
+ rc_t rc = 0;
+
+ assert(curs && col_name);
+
+ if (rc == 0) {
+ rc = VTableCreateCursorRead(self, curs);
+ if (rc != 0) {
+ LOGERR(klogInt, rc, "Error during VTableCreateCursorRead");
+ }
+ }
+
+ if (rc == 0) {
+ VCursorPermitPostOpenAdd(*curs);
+ if (rc != 0) {
+ LOGERR(klogInt, rc, "Error during VCursorPermitPostOpenAdd");
+ }
+ }
+
+ if (rc == 0) {
+ rc = VCursorOpen(*curs);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VCursorOpen($(name))", "name=%s", col_name));
+ }
+ }
+
+ if (rc == 0) {
+ assert(*curs);
+ rc = VCursorAddColumn(*curs, col_idx, col_name);
+ if (rc != 0 && !canBeLost) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VCursorAddColumn($(name))", "name=%s", col_name));
+ }
+ }
+
+ STSMSG(2, ("Prepared a VCursor to read '%s'", col_name));
+
+ return rc;
+}
+
+static rc_t _VTableMakeCursor(const VTable *self,
+ const VCursor **curs, uint32_t *col_idx, const char *col_name)
+{
+ return _VTableMakeCursorImpl(self, curs, col_idx, col_name, false);
+}
+
+static bool _VTableCSra(const VTable *self) {
+ bool cSra = false;
+
+ KNamelist *names = NULL;
+
+ uint32_t i = 0, count = 0;
+
+ rc_t rc = VTableListPhysColumns(self, &names);
+
+ if (rc == 0) {
+ rc = KNamelistCount(names, &count);
+ }
+
+ for (i = 0 ; i < count && rc == 0; ++i) {
+ const char *name = NULL;
+ rc = KNamelistGet(names, i, &name);
+ if (rc == 0) {
+ const char b[] = "CMP_READ";
+ if (string_cmp(name, string_measure(name, NULL),
+ b, sizeof b - 1, sizeof b - 1) == 0)
+ {
+ cSra = true;
+ break;
+ }
+ }
+ }
+
+ RELEASE(KNamelist, names);
+
+ return cSra;
+}
+
+typedef enum {
+ eColTypeError,
+ eColTypeAbsent,
+ eColTypeStatic,
+ eColTypeNonStatic
+} EColType;
+static
+uint32_t _VTableReadFirstRowImpl(const VTable *self,
+ const char *name,
+ void *buffer,
+ uint32_t blen,
+ EColType *is_static, bool canBeLost)
+{
+ uint32_t status = eVdbBlastNoErr;
+
+ rc_t rc = 0;
+
+ const VCursor *curs = NULL;
+ uint32_t idx = 0;
+ uint32_t row_len = 0;
+
+ assert(self && name);
+
+ blen *= 8;
+
+ rc = _VTableMakeCursorImpl(self, &curs, &idx, name, canBeLost);
+ if (rc != 0) {
+ if (rc ==
+ SILENT_RC(rcVDB, rcCursor, rcOpening, rcColumn, rcUndefined)
+ || rc ==
+ SILENT_RC(rcVDB, rcCursor, rcUpdating, rcColumn, rcNotFound))
+ {
+ if (!canBeLost) {
+ PLOGMSG(klogInfo, (klogInfo, "$(f): Column '$(name)' not found",
+ "f=%s,name=%s", __func__, name));
+ }
+ if (is_static != NULL) {
+ *is_static = eColTypeAbsent;
+ }
+ status = eVdbBlastTooExpensive;
+ }
+ else {
+ status = eVdbBlastErr;
+ if (is_static != NULL) {
+ *is_static = eColTypeError;
+ }
+ }
+ }
+
+ if (status == eVdbBlastNoErr && rc == 0) {
+ rc = VCursorOpenRow(curs);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VCursorOpenRow($(name))", "name=%s", name));
+ }
+ }
+
+ if (status == eVdbBlastNoErr && rc == 0 && buffer != NULL && blen > 0) {
+ rc = VCursorRead(curs, idx, 8, buffer, blen, &row_len);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VCursorRead($(name))", "name=%s", name));
+ }
+ }
+
+/* TODO: needs to be verified what row_len is expected
+ if (row_len != 1) return eVdbBlastErr; */
+
+ STSMSG(2, ("Read the first row of '%s'", name));
+
+ if (status == eVdbBlastNoErr && rc == 0) {
+ if (blen == 64) {
+ _VTableLogRowData(self, name, buffer, blen);
+ }
+ if (is_static != NULL) {
+ bool isStatic = false;
+ rc = VCursorIsStaticColumn(curs, idx, &isStatic);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VCursorIsStaticColumn($(name))",
+ "name=%s", name));
+ }
+ else {
+ *is_static = isStatic ? eColTypeStatic : eColTypeNonStatic;
+ }
+ }
+ }
+
+ VCursorRelease(curs);
+
+ if (status == eVdbBlastNoErr && rc != 0) {
+ status = eVdbBlastErr;
+ }
+ return status;
+}
+
+static uint32_t _VTableReadFirstRow(const VTable *self,
+ const char *name, void *buffer, uint32_t blen, EColType *is_static)
+{
+ return _VTableReadFirstRowImpl(self, name, buffer, blen, is_static, false);
+}
+
+static uint32_t _VTableGetNReads(const VTable *self, uint32_t *nreads) {
+ rc_t rc = 0;
+ uint32_t status = eVdbBlastNoErr;
+ const VCursor *curs = NULL;
+ uint32_t idx = 0;
+
+ const char name[] = "READ_LEN";
+
+ assert(nreads);
+
+ rc = _VTableMakeCursor(self, &curs, &idx, name);
+ if (rc != 0) {
+ status = eVdbBlastErr;
+ if (rc ==
+ SILENT_RC(rcVDB, rcCursor, rcOpening, rcColumn, rcUndefined))
+ {
+ PLOGMSG(klogInfo, (klogInfo, "$(f): Column '$(name)' not found",
+ "f=%s,name=%s", __func__, name));
+ }
+ else {
+ PLOGMSG(klogInfo, (klogInfo, "$(f): Cannot open column '$(name)'",
+ "f=%s,name=%s", __func__, name));
+ }
+ }
+
+ if (status == eVdbBlastNoErr) {
+ uint32_t elem_bits, elem_off, elem_cnt;
+ const void *base = NULL;
+ rc = VCursorCellDataDirect(curs, 1, idx,
+ &elem_bits, &base, &elem_off, &elem_cnt);
+ if (rc != 0) {
+ status = eVdbBlastErr;
+ PLOGMSG(klogInfo, (klogInfo,
+ "$(f): Cannot '$(name)' CellDataDirect",
+ "f=%s,name=%s", __func__, name));
+ }
+ else if (elem_off != 0 || elem_bits != 32) {
+ status = eVdbBlastErr;
+ PLOGERR(klogInt, (klogInt, rc,
+ "Bad VCursorCellDataDirect(READ_LEN) result: "
+ "boff=$(elem_off), elem_bits=$(elem_bits)",
+ "elem_off=%u, elem_bits=%u", elem_off, elem_bits));
+ }
+ else {
+ *nreads = elem_cnt;
+ }
+ }
+
+ RELEASE(VCursor, curs);
+
+ return status;
+}
+
+
+/******************************************************************************/
+
+typedef struct ReaderCols {
+ uint32_t col_PRIMARY_ALIGNMENT_ID;
+ uint32_t col_READ_FILTER;
+ uint32_t col_READ_LEN;
+ uint32_t col_TRIM_LEN;
+ uint32_t col_TRIM_START;
+
+ int64_t *primary_alignment_id;
+ uint8_t *read_filter;
+ uint32_t *read_len;
+ INSDC_coord_len TRIM_LEN;
+ INSDC_coord_val TRIM_START;
+
+ uint8_t nReadsAllocated;
+} ReaderCols;
+static void ReaderColsReset(ReaderCols *self) {
+ assert(self);
+
+ self ->col_PRIMARY_ALIGNMENT_ID
+ = self->col_READ_FILTER
+ = self->col_READ_LEN
+ = self->col_TRIM_LEN
+ = self->col_TRIM_START
+ = 0;
+}
+
+static
+void ReaderColsFini(ReaderCols *self)
+{
+ assert(self);
+
+ free(self->primary_alignment_id);
+ free(self->read_filter);
+ free(self->read_len);
+
+ memset(self, 0, sizeof *self);
+}
+
+/* readId is an index in primary_alignment_id : 0-based */
+static bool ReaderColsIsReadCompressed(const ReaderCols *self, uint32_t readId)
+{
+ assert(self);
+
+ if (self->col_PRIMARY_ALIGNMENT_ID == 0) {
+ return false; /* not cSRA */
+ }
+
+ assert(self->primary_alignment_id);
+ if (self->primary_alignment_id[readId] != 0) {
+ return true; /* has alignment == compressed */
+ }
+ else {
+ /* does not have alignment == not compressed == is stored in CMP_READ */
+ return false;
+ }
+}
+
+/******************************************************************************/
+
+static
+uint32_t _VCursorReadArray(const VCursor *self,
+ int64_t row_id,
+ uint32_t col,
+ void **buffer,
+ uint8_t elem_size,
+ uint8_t nReads,
+ const char *name)
+{
+ rc_t rc = 0;
+ uint32_t row_len = 0;
+
+ assert(buffer && elem_size && nReads && name);
+
+ if (*buffer == NULL) {
+ *buffer = calloc(nReads, elem_size);
+ if (*buffer == NULL)
+ { return eVdbBlastMemErr; }
+ }
+
+ rc = VCursorReadDirect(self,
+ row_id, col, 8, *buffer, nReads * elem_size * 8, &row_len);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VCursorReadDirect($(name))", "name=%s", name));
+ }
+
+/* TODO: needs to be verified what row_len is expected
+ if (row_len != 1) return eVdbBlastErr; */
+
+ S
+
+ return rc == 0 ? eVdbBlastNoErr : eVdbBlastErr;
+}
+
+static
+uint32_t _VCursorAddCols(const VCursor *self,
+ ReaderCols *cols, bool cSra)
+{
+ rc_t rc = 0;
+
+ assert(self && cols);
+
+ if (rc == 0) {
+ const char name[] = "READ_FILTER";
+ rc = VCursorAddColumn(self, &cols->col_READ_FILTER, name);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VCursorOpen($(name))", "name=%s", name));
+ }
+ else {
+ assert(cols->col_READ_FILTER);
+ }
+ }
+
+ if (rc == 0) {
+ const char name[] = "READ_LEN";
+ rc = VCursorAddColumn(self, &cols->col_READ_LEN, name);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VCursorOpen($(name))", "name=%s", name));
+ }
+ else {
+ assert(cols->col_READ_LEN);
+ }
+ }
+
+ if (rc == 0) {
+ const char name[] = "TRIM_LEN";
+ rc = VCursorAddColumn(self, &cols->col_TRIM_LEN, name);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VCursorOpen($(name))", "name=%s", name));
+ }
+ else {
+ assert(cols->col_TRIM_LEN);
+ }
+ }
+
+ if (rc == 0) {
+ const char name[] = "TRIM_START";
+ rc = VCursorAddColumn(self, &cols->col_TRIM_START, name);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VCursorOpen($(name))", "name=%s", name));
+ }
+ else {
+ assert(cols->col_TRIM_START);
+ }
+ }
+
+ if (rc == 0 && cSra) {
+ const char name[] = "PRIMARY_ALIGNMENT_ID";
+ rc = VCursorAddColumn(self, &cols->col_PRIMARY_ALIGNMENT_ID, name);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VCursorOpen($(name))", "name=%s", name));
+ }
+ else {
+ assert(cols->col_PRIMARY_ALIGNMENT_ID);
+ }
+ }
+
+ return rc ? eVdbBlastErr : eVdbBlastNoErr;
+}
+
+static
+uint32_t _VCursorReadCols(const VCursor *self,
+ int64_t row_id,
+ ReaderCols *cols,
+ uint8_t nReads)
+{
+ uint32_t status = eVdbBlastNoErr;
+ rc_t rc = 0;
+ uint32_t row_len = ~0;
+
+ assert(cols);
+
+ if (cols->nReadsAllocated != 0 && cols->nReadsAllocated < nReads) {
+ /* LOG */
+
+ /* TODO: find a better way/place to realloc cols data buffers */
+ free(cols->primary_alignment_id);
+ cols->primary_alignment_id = NULL;
+ free(cols->read_filter);
+ cols->read_filter = NULL;
+ free(cols->read_len);
+ cols->read_len = NULL;
+ }
+
+ status = _VCursorReadArray(self, row_id, cols->col_READ_LEN,
+ (void **)&cols->read_len, sizeof *cols->read_len, nReads,
+ "READ_LEN");
+ if (status != eVdbBlastNoErr)
+ { return status; }
+
+ status = _VCursorReadArray(self, row_id, cols->col_READ_FILTER,
+ (void **)&cols->read_filter, sizeof *cols->read_filter, nReads,
+ "READ_FILTER");
+ if (status != eVdbBlastNoErr)
+ { return status; }
+
+ if (cols->col_PRIMARY_ALIGNMENT_ID != 0) {
+ status = _VCursorReadArray(self, row_id, cols->col_PRIMARY_ALIGNMENT_ID,
+ (void **)&cols->primary_alignment_id, sizeof *cols->primary_alignment_id,
+ nReads, "PRIMARY_ALIGNMENT_ID");
+ if (status != eVdbBlastNoErr) {
+ return status;
+ }
+ }
+
+ cols->nReadsAllocated = nReads;
+
+ rc = VCursorReadDirect(self, row_id, cols->col_TRIM_LEN,
+ 8 * sizeof cols->TRIM_LEN, &cols->TRIM_LEN, sizeof cols->TRIM_LEN,
+ &row_len);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc, "Error in VCursorReadDirect"
+ " TRIM_LEN, spot=$(spot))", "spot=%ld", row_id));
+ return eVdbBlastErr;
+ }
+ else if (row_len != 1) {
+ STSMSG(1, ("Error: VCursorReadDirect(TRIM_LEN, spot=%lu) "
+ "returned row_len=%u", row_id, row_len));
+/* TODO */ return eVdbBlastErr;
+ }
+
+ rc = VCursorReadDirect(self, row_id, cols->col_TRIM_START,
+ 8 * sizeof cols->TRIM_LEN, &cols->TRIM_START, sizeof cols->TRIM_START,
+ &row_len);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc, "Error in VCursorReadDirect"
+ " TRIM_START, spot=$(spot))", "spot=%ld", row_id));
+ return eVdbBlastErr;
+ }
+ else if (row_len != 1) {
+ STSMSG(1, ("Error: VCursorReadDirect(TRIM_START, spot=%lu) "
+ "returned row_len=%u", row_id, row_len));
+/* TODO */ return eVdbBlastErr;
+ }
+
+ return status;
+}
+
+/******************************************************************************/
+typedef uint32_t BTableType;
+enum {
+ btpUndefined
+ , btpSRA
+ , btpWGS
+ , btpREFSEQ
+};
+/******************************************************************************/
+static const char VDB_BLAST_MGR[] = "VdbBlastMgr";
+
+struct VdbBlastMgr {
+ KRefcount refcount;
+#if NO_NO_NO_NO_NO
+ SRAPath *path;
+#endif
+ VSchema *schema;
+ const VDBManager *mgr;
+ const KDBManager *kmgr;
+ VFSManager * vfs;
+ KDirectory *dir;
+ VResolver *resolver;
+};
+
+static
+void _VdbBlastMgrWhack(VdbBlastMgr *self)
+{
+ assert(self);
+
+ VSchemaRelease(self->schema);
+ VDBManagerRelease(self->mgr);
+ KDBManagerRelease(self->kmgr);
+ VFSManagerRelease ( self -> vfs );
+ KDirectoryRelease(self->dir);
+ VResolverRelease(self->resolver);
+
+ memset(self, 0, sizeof *self);
+
+ free(self);
+
+ STSMSG(1, ("Deleted VdbBlastMgr"));
+}
+
+LIB_EXPORT
+VdbBlastMgr* CC VdbBlastInit(uint32_t *status)
+{
+ VdbBlastMgr *obj = NULL;
+ rc_t rc = 0;
+
+ uint32_t dummy = eVdbBlastNoErr;
+ if (status == NULL)
+ { status = &dummy; }
+
+ *status = eVdbBlastErr;
+
+ obj = calloc(1, sizeof *obj);
+ if (obj == NULL) {
+ *status = eVdbBlastMemErr;
+ return obj;
+ }
+
+ if ( rc == 0 )
+ {
+ rc = VFSManagerMake ( & obj -> vfs );
+ if ( rc != 0 )
+ LOGERR ( klogInt, rc, "Error in VFSManagerMake" );
+ }
+
+ if (rc == 0) {
+ rc = VFSManagerGetCWD( obj -> vfs, &obj->dir);
+ if (rc != 0)
+ { LOGERR(klogInt, rc, "Error in VFSManagerGetCWD"); }
+ }
+
+#if 0
+ if (rc == 0) {
+ rc = SRAPathMake(&obj->path, NULL);
+ if (rc != 0) {
+ LOGERR(klogInt, rc,
+ "Error in SRAPathMake: is libsra-path.so in LD_LIBRARY_PATH?");
+ }
+ }
+#endif
+
+ if (rc == 0) {
+ rc = VDBManagerMakeRead(&obj->mgr, NULL);
+ if (rc != 0)
+ { LOGERR(klogInt, rc, "Error in VDBManagerMakeRead"); }
+ }
+
+ if (rc == 0) {
+ rc = VDBManagerOpenKDBManagerRead(obj->mgr, &obj->kmgr);
+ if (rc != 0)
+ { LOGERR(klogInt, rc, "Error in VDBManagerOpenKDBManagerRead"); }
+ }
+
+ if (rc == 0) {
+ rc = VDBManagerMakeSRASchema(obj->mgr, &obj->schema);
+ if (rc != 0)
+ { LOGERR(klogInt, rc, "Error in VDBManagerMakeSRASchema"); }
+ }
+
+ if (rc == 0) {
+ VFSManager* mgr = NULL;
+ KConfig* cfg = NULL;
+ if (rc == 0) {
+ rc = VFSManagerMake(&mgr);
+ }
+ if (rc == 0) {
+ rc = KConfigMake(&cfg, NULL);
+ }
+ if (rc == 0) {
+ rc = VFSManagerMakeResolver(mgr, &obj->resolver, cfg);
+ }
+ RELEASE(KConfig, cfg);
+ RELEASE(VFSManager, mgr);
+ }
+
+ if (rc != 0) {
+ _VdbBlastMgrWhack(obj);
+ obj = NULL;
+ STSMSG(1, ("Error: failed to create VdbBlastMgr"));
+ }
+ else {
+ KRefcountInit(&obj->refcount, 1, VDB_BLAST_MGR, __func__, "mgr");
+ *status = eVdbBlastNoErr;
+ STSMSG(1, ("Created VdbBlastMgr"));
+ }
+
+ return obj;
+}
+
+LIB_EXPORT
+VdbBlastMgr* CC VdbBlastMgrAddRef(VdbBlastMgr *self)
+{
+ if (self == NULL) {
+ STSMSG(1, ("VdbBlastMgrAddRef(NULL)"));
+ return self;
+ }
+
+ if (KRefcountAdd(&self->refcount, VDB_BLAST_MGR) == krefOkay) {
+ STSMSG(1, ("VdbBlastMgrAddRef"));
+ return self;
+ }
+
+ STSMSG(1, ("Error: failed to VdbBlastMgrAddRef"));
+ return NULL;
+}
+
+LIB_EXPORT
+void CC VdbBlastMgrRelease(VdbBlastMgr *self)
+{
+ if (self == NULL)
+ { return; }
+
+ STSMSG(1, ("VdbBlastMgrRelease"));
+ if (KRefcountDrop(&self->refcount, VDB_BLAST_MGR) != krefWhack)
+ { return; }
+
+ _VdbBlastMgrWhack(self);
+}
+
+/* schema at name in metadata for WGS runs starts with "NCBI:WGS:db:contig" */
+static
+bool _VdbBlastMgrIsRunWgs(VdbBlastMgr *self, const char *rundesc)
+{
+ bool wgs = false;
+ rc_t rc = 0;
+ const VDatabase *db = NULL;
+ const KMetadata *meta = NULL;
+ const KMDataNode *node = NULL;
+ char buffer[512] = "";
+ size_t size = 0;
+ assert(self);
+ rc = VDBManagerOpenDBRead(self->mgr, &db, NULL, rundesc);
+ if (rc == 0) {
+ rc = VDatabaseOpenMetadataRead(db, &meta);
+ }
+ if (rc == 0) {
+ rc = KMetadataOpenNodeRead(meta, &node, "schema");
+ }
+ if (rc == 0) {
+ rc = KMDataNodeReadAttr(node, "name", buffer, sizeof buffer, &size);
+ }
+ if (rc == 0) {
+ const char database[] = "NCBI:WGS:db:contig";
+ uint32_t max_chars = sizeof database - 1;
+ STSMSG(2,("%s.schema at name='%.*s'", rundesc, (uint32_t)size, buffer));
+ if (size >= sizeof database &&
+ string_cmp(buffer, max_chars, database, max_chars, max_chars) == 0)
+ {
+ STSMSG(1,("%s is wgs", rundesc));
+ wgs = true;
+ }
+ }
+ RELEASE(KMDataNode, node);
+ RELEASE(KMetadata, meta);
+ RELEASE(VDatabase, db);
+ return wgs;
+}
+
+/* TODO: should be replaced by a function to get the type from run [meta] */
+static
+BTableType _VdbBlastMgrBTableTypeFromPath(VdbBlastMgr *self,
+ const char *rundesc)
+{
+ rc_t rc = 0;
+ VPath *acc = NULL;
+ const VPath *local = NULL;
+ const String *str = NULL;
+ char *s = NULL;
+ BTableType t = btpSRA;
+ const char *log = "UNEXPECTED";
+
+ assert(self && rundesc);
+
+ rc = VFSManagerMakePath ( self -> vfs, &acc, rundesc);
+ if (rc == 0) {
+ rc = VResolverQuery(self->resolver,
+ eProtocolHttp, acc, &local, NULL, NULL);
+ }
+ if (rc == 0) {
+ rc = VPathMakeString(local, &str);
+ }
+
+ if (rc == 0) {
+ s = strstr(str->addr, "/WGS/");
+ if (s != NULL) {
+ t = btpWGS;
+ }
+ else {
+ s = strstr(str->addr, "/refseq/");
+ if (s != NULL) {
+ t = btpREFSEQ;
+ }
+ else {
+ if (_VdbBlastMgrIsRunWgs(self, rundesc)) {
+ t = btpWGS;
+ }
+ }
+ }
+ }
+
+ switch (t) {
+ case btpSRA:
+ log = "SRA";
+ break;
+ case btpWGS:
+ log = "WGS";
+ break;
+ case btpREFSEQ:
+ log = "REFSEQ";
+ break;
+ default:
+ log = "UNEXPECTED";
+ break;
+ }
+
+ STSMSG(1, ("Type of %s is %s", rundesc, log));
+
+ RELEASE(VPath, local);
+ RELEASE(VPath, acc);
+ free((void*)str);
+
+ return t;
+}
+
+static
+uint32_t _VdbBlastMgrOpenTable(const VdbBlastMgr *self,
+ const char *path,
+ const VTable **tbl)
+{
+ KPathType type = kptNotFound;
+ VSchema *schema = NULL;
+
+ assert(self && tbl);
+ *tbl = NULL;
+
+ /* Always use VDBManagerMakeSRASchema to VDBManagerOpenTableRead
+ Otherwise CMP_BASE_COUNT column sometimes cannot be found */
+ schema = self->schema;
+
+ type = KDBManagerPathType(self->kmgr, path);
+ if (type == kptNotFound) {
+ STSMSG(1, ("Error: cannot find '%s'", path));
+ return eVdbBlastErr;
+ }
+
+ if ((type & ~kptAlias) == kptDatabase) {
+ const char *table = "SEQUENCE";
+ const VDatabase *db = NULL;
+ rc_t rc = VDBManagerOpenDBRead(self->mgr, &db, NULL, path);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VDBManagerOpenDBRead($(name))", "name=%s", path));
+ STSMSG(1, ("Error: failed to open DB '%s'", path));
+ return eVdbBlastErr;
+ }
+ rc = VDatabaseOpenTableRead(db, tbl, table);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VDatabaseOpenTableRead($(name), $(tbl))",
+ "name=%s,tbl=%s", path, table));
+ STSMSG(1, ("Error: failed to open DB table '%s/%s'", path, table));
+ }
+ else {
+ STSMSG(1, ("Opened DB table '%s/%s'", path, table));
+ }
+ VDatabaseRelease(db);
+
+ return rc != 0 ? eVdbBlastErr : eVdbBlastNoErr;
+ }
+
+ while (true) {
+ rc_t rc = VDBManagerOpenTableRead(self->mgr, tbl, schema, path);
+ if (rc == 0) {
+ if (schema == NULL) {
+ STSMSG(1, ("Opened table '%s'(schema=NULL)", path));
+ }
+ else {
+ STSMSG(1, ("Opened table '%s'(SRASchema)", path));
+ }
+ return eVdbBlastNoErr;
+ }
+
+ assert(self->schema);
+
+ if (schema == NULL)
+ { schema = self->schema; }
+ else {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VDBManagerOpenTableRead($(name))", "name=%s", path));
+ STSMSG(1, ("Error: failed to open table '%s'", path));
+ return eVdbBlastRunErr;
+ }
+ }
+}
+
+static
+uint32_t _VdbBlastMgrFindNOpenTable(VdbBlastMgr *self,
+ const char *rundesc,
+ const VTable **tbl,
+ BTableType *type,
+ char **fullpath)
+{
+ uint32_t status = eVdbBlastNoErr;
+ char *path = (char*) rundesc;
+
+ assert(self && type);
+
+#if 0
+ if (KDirectoryPathType(self->dir, path) == kptNotFound) {
+ if (!SRAPathTest(self->path, rundesc)) {
+ size_t bufsize = 4096;
+ while (true) {
+ rc_t rc = 0;
+ path = malloc(bufsize);
+ if (path == NULL)
+ { return eVdbBlastMemErr; }
+
+ rc = SRAPathFind(self->path, rundesc, path, bufsize);
+ if (rc == 0) {
+ STSMSG(2, ("%s -> %s", rundesc, path));
+ if (fullpath != NULL)
+ { *fullpath = string_dup(path, bufsize); }
+ break;
+ }
+
+ free(path);
+ path = NULL;
+ if (GetRCState(rc) == rcNotFound) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Not found: '$(path)'", "path=%s", rundesc));
+ STSMSG(1, ("Error: not found '%s'", rundesc));
+ return eVdbBlastRunErr;
+ }
+ else if (GetRCState(rc) == rcInsufficient) {
+ bufsize *= 2;
+ continue;
+ }
+ else {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error while searching for '$(path)'",
+ "path=%s", rundesc));
+ STSMSG(1, ("Error: while searching for '%s'", rundesc));
+ return eVdbBlastErr;
+ }
+ }
+ }
+ }
+#endif
+
+ status = _VdbBlastMgrOpenTable(self, path, tbl);
+ if (status == eVdbBlastNoErr) {
+ STSMSG(1, ("Added run %s(%s)", rundesc, path));
+ }
+ else {
+ STSMSG(1, ("Error: failed to add run %s(%s)", rundesc, path));
+ }
+
+ *type = _VdbBlastMgrBTableTypeFromPath(self, path);
+
+ if (path != rundesc) {
+ free(path);
+ path = NULL;
+ }
+
+ return status;
+}
+
+/******************************************************************************/
+
+LIB_EXPORT uint32_t CC VdbBlastMgrKLogLevelSet(const VdbBlastMgr *self,
+ KLogLevel lvl)
+{
+ rc_t rc = KLogLevelSet(lvl);
+
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ return eVdbBlastNoErr;
+}
+
+LIB_EXPORT uint32_t CC VdbBlastMgrKLogLevelSetInfo(
+ const VdbBlastMgr *self)
+{ return VdbBlastMgrKLogLevelSet(self, klogInfo); }
+
+LIB_EXPORT uint32_t CC VdbBlastMgrKLogLevelSetWarn(
+ const VdbBlastMgr *self)
+{ return VdbBlastMgrKLogLevelSet(self, klogWarn); }
+
+LIB_EXPORT uint32_t CC VdbBlastMgrKLogHandlerSetStdOut(
+ const VdbBlastMgr *self)
+{
+ rc_t rc = KLogHandlerSetStdOut();
+
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ return eVdbBlastNoErr;
+}
+
+LIB_EXPORT
+uint32_t CC VdbBlastMgrKLogLibHandlerSetStdOut(const VdbBlastMgr *self)
+{
+ rc_t rc = KLogLibHandlerSetStdOut();
+
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ return eVdbBlastNoErr;
+}
+
+LIB_EXPORT uint32_t CC VdbBlastMgrKLogHandlerSetStdErr(
+ const VdbBlastMgr *self)
+{
+ rc_t rc = KLogHandlerSetStdErr();
+
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ return eVdbBlastNoErr;
+}
+
+LIB_EXPORT
+uint32_t CC VdbBlastMgrKLogLibHandlerSetStdErr(const VdbBlastMgr *self)
+{
+ rc_t rc = KLogLibHandlerSetStdErr();
+
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ return eVdbBlastNoErr;
+}
+
+LIB_EXPORT uint32_t CC VdbBlastMgrKLogHandlerSet(const VdbBlastMgr *self,
+ KWrtWriter writer, void *data)
+{
+ rc_t rc = KLogHandlerSet(writer, data);
+
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ return eVdbBlastNoErr;
+}
+
+LIB_EXPORT uint32_t CC VdbBlastMgrKLogLibHandlerSet(const VdbBlastMgr *self,
+ KWrtWriter writer, void *data)
+{
+ rc_t rc = KLogLibHandlerSet(writer, data);
+
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ return eVdbBlastNoErr;
+}
+
+/******************************************************************************/
+
+LIB_EXPORT void CC VdbBlastMgrKStsLevelSet(const VdbBlastMgr *self,
+ uint32_t level)
+{ KStsLevelSet(level); }
+
+LIB_EXPORT
+uint32_t CC VdbBlastMgrKStsHandlerSetStdOut(const VdbBlastMgr *self)
+{
+ rc_t rc = KStsHandlerSetStdOut();
+
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ return eVdbBlastNoErr;
+}
+
+LIB_EXPORT
+uint32_t CC VdbBlastMgrKStsHandlerSetStdErr(const VdbBlastMgr *self)
+{
+ rc_t rc = KStsHandlerSetStdErr();
+
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ return eVdbBlastNoErr;
+}
+
+/******************************************************************************/
+/* KOutHandlerSet
+ * set output handler for different channels
+ *
+ * returns status code
+ */
+LIB_EXPORT
+uint32_t CC VdbBlastMgrKOutHandlerSetStdOut(const VdbBlastMgr *self)
+{
+ rc_t rc = KOutHandlerSetStdOut();
+
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ return eVdbBlastNoErr;
+}
+
+LIB_EXPORT
+uint32_t CC VdbBlastMgrKOutHandlerSetStdErr(const VdbBlastMgr *self)
+{
+ rc_t rc = KOutHandlerSetStdErr();
+
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ return eVdbBlastNoErr;
+}
+
+LIB_EXPORT uint32_t CC VdbBlastMgrKOutHandlerSet(const VdbBlastMgr *self,
+ VdbBlastKWrtWriter writer, void *data)
+{
+ rc_t rc = KOutHandlerSet(writer, data);
+
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ return eVdbBlastNoErr;
+}
+
+/******************************************************************************/
+
+LIB_EXPORT uint32_t CC VdbBlastMgrKDbgSetString(const VdbBlastMgr *self,
+ const char *string)
+{
+ rc_t rc = KDbgSetString(string);
+
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ return eVdbBlastNoErr;
+}
+
+/******************************************************************************/
+
+/* KConfigPrint
+ * print current configuration to the output handler
+ */
+LIB_EXPORT uint32_t VdbBlastMgrKConfigPrint ( const VdbBlastMgr *self ) {
+ KConfig *kfg = NULL;
+
+ rc_t rc = KConfigMake(&kfg, NULL);
+
+ if (rc == 0) {
+ rc = KConfigPrint(kfg, 0);
+ }
+
+ {
+ rc_t rc2 = KConfigRelease(kfg);
+ if (rc == 0 && rc2 != 0) {
+ rc = rc2;
+ }
+ }
+
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ return eVdbBlastNoErr;
+}
+
+/******************************************************************************/
+typedef struct {
+ uint64_t spotCount;
+ uint8_t nReads;
+ uint8_t nBioReads; /* knowing filtering (if static) and min_read_len info */
+ uint64_t bioLen; /* per read. is assigned just when allStatic */
+ INSDC_SRA_platform_id platform;
+
+ uint64_t bioBaseCount; /* BIO_BASE_COUNT, ~0 if not found */
+ uint64_t cmpBaseCount; /* CMP_BASE_COUNT, ~0 if not found */
+
+ INSDC_read_type *readType;
+ EColType readTypeStatic;
+
+ uint32_t *readLen;
+ EColType readLenStatic;
+
+ uint8_t *rdFilter;
+ EColType rdFilterStatic;
+
+ bool varReadLen;
+} RunDesc;
+static
+void _RunDescFini(RunDesc *self)
+{
+ assert(self);
+ free(self->readLen);
+ free(self->readType);
+ free(self->rdFilter);
+ memset(self, 0, sizeof *self);
+}
+
+static char* _CanonocalName(const char *name) {
+ size_t noExtSize = 0;
+ size_t namelen = 0;
+ const char ext[] = ".sra";
+
+ if (name == NULL) {
+ return NULL;
+ }
+
+ noExtSize = namelen = string_size(name);
+
+ if (namelen >= sizeof(ext)) {
+ const char *tail = NULL;
+ noExtSize -= sizeof ext - 1;
+ tail = name + noExtSize;
+ if (string_cmp(ext, sizeof ext - 1, tail, sizeof ext - 1, 99) != 0) {
+ noExtSize = namelen;
+ }
+ }
+
+ return string_dup(name, noExtSize);
+}
+
+/******************************************************************************/
+typedef struct VdbBlastRun {
+ /* rundesc; */
+ char *acc;
+ char *path;
+
+ const VTable *tbl;
+ BTableType type;
+ bool cSra;
+
+ uint64_t bioReads; /* numSequences; */
+ bool bioReadsTooExpensive; /* numSequences is TooExpensive */
+ uint64_t bioReadsApprox; /* numSequencesApprox; */
+
+ uint64_t bioBases; /* length; */
+ bool bioBasesTooExpensive; /* totalLength is TooExpensive */
+ uint64_t bioBasesApprox; /* lengthApprox; */
+
+ RunDesc rd;
+
+ uint32_t min_read_length;
+
+ /* WGS */
+ const VCursor *cursACCESSION;
+ uint32_t col_ACCESSION;
+} VdbBlastRun;
+static
+uint32_t _VdbBlastRunFillRunDesc(VdbBlastRun *self)
+{
+ uint32_t status = eVdbBlastNoErr;
+ RunDesc *rd = NULL;
+
+ int i = 0;
+ const char *col = NULL;
+
+ assert(self);
+
+ rd = &self->rd;
+
+ if (rd->spotCount || rd->readType || rd->nReads || rd->nBioReads) {
+ if (self->cSra && rd->cmpBaseCount == ~0) {
+ rc_t rc = RC(rcSRA, rcTable, rcReading, rcColumn, rcNotFound);
+ PLOGERR(klogInt, (klogInt, rc,
+ "Cannot read CMP_BASE_COUNT column for $(p)",
+ "p=%s", self->path));
+ STSMSG(1, ("Error: failed to read %s/%s",
+ self->path, "CMP_BASE_COUNT"));
+ return eVdbBlastErr;
+ }
+ else {
+ S
+ return eVdbBlastNoErr;
+ }
+ }
+
+ assert(self->path);
+
+ col = "SPOT_COUNT";
+ status = _VTableReadFirstRow(self->tbl,
+ col, &rd->spotCount, sizeof rd->spotCount, NULL);
+ if (status != eVdbBlastNoErr) {
+ STSMSG(1, ("Error: failed to read %s/%s", self->path, col));
+ return status;
+ }
+
+ if (self->type == btpWGS) {
+ S
+ status = eVdbBlastNoErr;
+ rd->nReads = rd->spotCount > 0 ? 1 : 0;
+ }
+ else if (self->type == btpREFSEQ) {
+ S
+ status = eVdbBlastNoErr;
+ rd->nReads = 1;
+ }
+ else {
+ uint32_t nreads = 0;
+ status = _VTableGetNReads(self->tbl, &nreads);
+ if (status == eVdbBlastNoErr) {
+ rd->nReads = nreads;
+ }
+ }
+
+ switch (self->type) {
+ case btpSRA:
+ col = "PLATFORM";
+ status = _VTableReadFirstRow(self->tbl,
+ col, &rd->platform, sizeof rd->platform, NULL);
+ if (status != eVdbBlastNoErr) {
+ STSMSG(1, ("Error: failed to read %s/%s", self->path, col));
+ return status;
+ }
+ switch (rd->platform) { /* TODO */
+ case SRA_PLATFORM_ILLUMINA:
+ case SRA_PLATFORM_ABSOLID:
+ case SRA_PLATFORM_COMPLETE_GENOMICS:
+ rd->varReadLen = false;
+ break;
+ case SRA_PLATFORM_UNDEFINED:
+ case SRA_PLATFORM_454:
+ case SRA_PLATFORM_HELICOS:
+ case SRA_PLATFORM_PACBIO_SMRT:
+ case SRA_PLATFORM_ION_TORRENT:
+ default:
+ rd->varReadLen = true;
+ break;
+ }
+ break;
+ case btpWGS:
+ rd->varReadLen = true;
+ break;
+ case btpREFSEQ:
+ break;
+ default:
+ assert(0);
+ break;
+ }
+
+ col = "READ_TYPE";
+ if (rd->readType == NULL) {
+ rd->readType = calloc(rd->nReads, sizeof *rd->readType);
+ if (rd->readType == NULL)
+ { return eVdbBlastMemErr; }
+ }
+ status = _VTableReadFirstRow(self->tbl, col,
+ rd->readType, rd->nReads * sizeof *rd->readType, &rd->readTypeStatic);
+ /* TODO: check case when ($#READ_TYPE == 0 && nreads > 0) */
+ if (status != eVdbBlastNoErr) {
+ if (status == eVdbBlastTooExpensive) {
+ status = eVdbBlastNoErr;
+ }
+ else {
+ STSMSG(1, ("Error: failed to read %s/%s", self->path, col));
+ return status;
+ }
+ }
+
+ col = "READ_LEN";
+ if (rd->readLen == NULL) {
+ rd->readLen = calloc(rd->nReads, sizeof *rd->readLen);
+ if (rd->readLen == NULL)
+ { return eVdbBlastMemErr; }
+ }
+ status = _VTableReadFirstRow(self->tbl, col,
+ rd->readLen, rd->nReads * sizeof *rd->readLen, &rd->readLenStatic);
+ /* TODO: check case when ($#READ_TYPE == 0 && nreads > 0) */
+ if (status != eVdbBlastNoErr) {
+ STSMSG(1, ("Error: failed to read %s/%s", self->path, col));
+ return status;
+ }
+
+ col = "READ_FILTER"; /* col = "RD_FILTER"; */
+ if (rd->rdFilter == NULL) {
+ rd->rdFilter = calloc(rd->nReads, sizeof *rd->rdFilter);
+ if (rd->rdFilter == NULL)
+ { return eVdbBlastMemErr; }
+ }
+ status = _VTableReadFirstRow(self->tbl, col,
+ rd->rdFilter, rd->nReads * sizeof *rd->rdFilter, &rd->rdFilterStatic);
+ if (status != eVdbBlastNoErr) {
+ if (status == eVdbBlastTooExpensive) {
+ status = eVdbBlastNoErr;
+ }
+ else {
+ STSMSG(1, ("Error: failed to read %s/%s", self->path, col));
+ return status;
+ }
+ }
+
+ col = "BIO_BASE_COUNT";
+ status = _VTableReadFirstRowImpl(self->tbl, col,
+ &rd->bioBaseCount, sizeof rd->bioBaseCount, NULL,
+ true);/*Do not generate error message when BIO_BASE_COUNT is not found*/
+
+ if (status != eVdbBlastNoErr) {
+ if (status == eVdbBlastTooExpensive) {
+ status = eVdbBlastNoErr;
+ rd->bioBaseCount = ~0;
+ }
+ else {
+ STSMSG(1, ("Error: failed to read %s/%s", self->path, col));
+ return status;
+ }
+ }
+
+ col = "CMP_BASE_COUNT";
+ status = _VTableReadFirstRow(self->tbl, col,
+ &rd->cmpBaseCount, sizeof rd->cmpBaseCount, NULL);
+ if (status != eVdbBlastNoErr) {
+ if (status == eVdbBlastTooExpensive) {
+ /* CMP_BASE_COUNT should be always found */
+ rc_t rc = RC(rcSRA, rcTable, rcReading, rcColumn, rcNotFound);
+ PLOGERR(klogInt, (klogInt, rc,
+ "Cannot read CMP_BASE_COUNT column for $(p)",
+ "p=%s", self->path));
+ STSMSG(1, ("Error: failed to read %s/%s",
+ self->path, "CMP_BASE_COUNT"));
+ rd->cmpBaseCount = ~0;
+ return eVdbBlastErr;
+ }
+ else {
+ STSMSG(1, ("Error: failed to read %s/%s", self->path, col));
+ return status;
+ }
+ }
+
+ for (rd->nBioReads = 0, i = 0; i < rd->nReads; ++i) {
+ S
+ if (rd->readType[i] & SRA_READ_TYPE_BIOLOGICAL) {
+ if ((rd->rdFilterStatic == eColTypeStatic &&
+ rd->rdFilter[i] == READ_FILTER_PASS)
+ || (rd->rdFilterStatic == eColTypeAbsent))
+ {
+ ++rd->nBioReads;
+ rd->bioLen += rd->readLen[i];
+ }
+ else {
+ ++rd->nBioReads;
+ }
+ }
+ }
+ S /* LOG nBioReads */
+
+ return status;
+}
+
+static VdbBlastStatus _VdbBlastRunInit(VdbBlastRun *self,
+ const VTable *tbl, const char *rundesc, BTableType type,
+ const KDirectory *dir, char *fullpath, uint32_t min_read_length)
+{
+ rc_t rc = 0;
+ const char *acc = rundesc;
+ char rbuff[4096] = "";
+ size_t size = 0;
+
+#if WINDOWS
+ char slash = '\\';
+#else
+ char slash = '/';
+#endif
+
+ assert(self && tbl && type != btpUndefined && rundesc);
+
+/* TODO This is obsolete and incorrect */
+ rc = KDirectoryResolvePath(dir, true, rbuff, sizeof rbuff, rundesc);
+ if (rc != 0) {
+ S
+ return eVdbBlastErr;
+ }
+
+ memset(self, 0, sizeof *self);
+
+ self->tbl = tbl;
+ self->type = type;
+
+ self->bioReads = self->bioReadsApprox
+ = self->bioBases = self->bioBasesApprox = ~0;
+
+ acc = strrchr(rbuff, slash);
+ if (acc == NULL) {
+ acc = rbuff;
+ }
+ else if (string_measure(acc, &size) > 1) {
+ ++acc;
+ }
+ else {
+ acc = rbuff;
+ }
+
+ if (fullpath == NULL) {
+ self->path = string_dup(rbuff, sizeof(rbuff));
+ if (self->path == NULL) {
+ return eVdbBlastMemErr;
+ }
+ }
+ else {
+ self->path = fullpath;
+ }
+ self->acc = _CanonocalName(acc);
+ if (self->acc == NULL) {
+ return eVdbBlastMemErr;
+ }
+
+ self->min_read_length = min_read_length;
+
+ self->cSra = _VTableCSra(self->tbl);
+
+ return eVdbBlastNoErr;
+}
+
+static
+void _VdbBlastRunFini(VdbBlastRun *self)
+{
+ if (self == NULL)
+ { return; }
+
+ VCursorRelease(self->cursACCESSION);
+ VTableRelease(self->tbl);
+
+ free(self->acc);
+ free(self->path);
+
+ _RunDescFini(&self->rd);
+
+ memset(self, 0, sizeof *self);
+}
+
+/* _VdbBlastRunGetNumSequences
+ returns (number of spots) * (number of biological reads in spot).
+ If read_filter is not static: some reads could be filtered,
+ so status is set to eVdbBlastTooExpensive */
+static
+uint64_t _VdbBlastRunGetNumSequences(VdbBlastRun *self,
+ uint32_t *status)
+{
+ assert(self && status);
+
+ *status = eVdbBlastNoErr;
+
+ if (self->bioReads == ~0) {
+ RunDesc *rd = NULL;
+
+ if (self->type == btpREFSEQ) {
+ S
+ self->bioReads = 1;
+ }
+ else {
+ *status = _VdbBlastRunFillRunDesc(self);
+ if (*status != eVdbBlastNoErr) {
+ S
+ return 0;
+ }
+
+ rd = &self->rd;
+
+ if (rd->rdFilterStatic != eColTypeStatic) {
+ self->bioReadsTooExpensive = true;
+ }
+
+ if (self->cSra) {
+ self->bioReadsTooExpensive = true;
+ }
+
+ self->bioReads = rd->spotCount * rd->nBioReads;
+ S
+ }
+ }
+ else {
+ S
+ }
+
+ if (*status == eVdbBlastNoErr && self->bioReadsTooExpensive) {
+ *status = eVdbBlastTooExpensive;
+ }
+ return self->bioReads;
+}
+
+static
+uint64_t _VdbBlastRunGetLength(VdbBlastRun *self,
+ uint32_t *status)
+{
+ uint32_t dummy = eVdbBlastNoErr;
+ if (status == NULL)
+ { status = &dummy; }
+
+ *status = eVdbBlastNoErr;
+
+ if (self->bioBasesTooExpensive) {
+ *status = eVdbBlastTooExpensive;
+ return 0;
+ }
+ else if (self->bioBases == ~0) {
+ if (self->cSra) {
+ *status = _VdbBlastRunFillRunDesc(self);
+ if (*status != eVdbBlastNoErr) {
+ S
+ return 0;
+ }
+ self->bioBases = self->rd.cmpBaseCount;
+ }
+ else {
+// if BIO_BASE_COUNT is not found then status is set to eVdbBlastTooExpensive
+ *status = _VTableReadFirstRowImpl(self->tbl, "BIO_BASE_COUNT",
+ &self->bioBases, sizeof self->bioBases, NULL, true);
+ if (*status == eVdbBlastTooExpensive) {
+ self->bioBasesTooExpensive = true;
+ }
+ }
+ }
+
+ if (*status == eVdbBlastNoErr) {
+ S
+ return self->bioBases;
+ }
+ else {
+ S
+ return 0;
+ }
+}
+static
+rc_t _VCursorCellDataDirect(const VCursor *self,
+ int64_t row_id,
+ uint32_t col_idx,
+ uint32_t elemBits,
+ const void **base,
+ uint32_t nreads,
+ const char *name)
+{
+ uint32_t elem_bits = 0;
+ uint32_t row_len = 0;
+ uint32_t boff = 0;
+
+ rc_t rc = VCursorCellDataDirect(self, row_id, col_idx,
+ &elem_bits, base, &boff, &row_len);
+
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error during VCursorCellDataDirect($(name), $(spot))",
+ "name=%s,spot=%lu", name, col_idx));
+ }
+ else if (boff != 0 || elem_bits != elemBits) {
+ rc = RC(rcSRA, rcCursor, rcReading, rcData, rcUnexpected);
+ PLOGERR(klogInt, (klogInt, rc,
+ "Bad VCursorCellDataDirect($(name), $(spot)) result: "
+ "boff=$(boff), elem_bits=$(elem_bits)",
+ "name=%s,spot=%lu,boff=%u,elem_bits=%u",
+ name, col_idx, boff, elem_bits));
+ }
+ else if (row_len != nreads) {
+ rc = RC(rcSRA, rcCursor, rcReading, rcData, rcUnexpected);
+ PLOGERR(klogInt, (klogInt, rc,
+ "Bad VCursorCellDataDirect($(name), $(spot)) result: "
+ "row_len=$(row_len)",
+ "name=%s,spot=%lu,row_len=%u", name, col_idx, row_len));
+ }
+
+ return rc;
+}
+
+typedef struct {
+ const VCursor *curs;
+ uint32_t colREAD_LEN;
+ uint32_t colREAD_TYPE;
+ uint64_t techBasesPerSpot;
+ bool techBasesPerSpotEquals;
+ uint64_t bioBasesCnt;
+} ApprCnt;
+static rc_t _ApprCntChunk(ApprCnt *self,
+ uint64_t chunk, uint64_t l, uint64_t nspots, uint32_t nreads)
+{
+ rc_t rc = 0;
+ uint64_t start = nspots / 10 * chunk + 1;
+ uint64_t spot = 0;
+ uint64_t end = start + l;
+ assert(self);
+ if (end - 1 > nspots) {
+ end = nspots + 1;
+ }
+ for (spot = start; spot < end; ++spot) {
+ uint64_t techBases = 0;
+ uint64_t bioBases = 0;
+ uint32_t read = 0;
+ const uint32_t *readLen = NULL;
+ const INSDC_read_type *readType = NULL;
+ const void *base = NULL;
+ rc = _VCursorCellDataDirect(self->curs, spot, self->colREAD_LEN,
+ 32, &base, nreads, "READ_LEN");
+ if (rc != 0) {
+ return rc;
+ }
+ readLen = base;
+ rc = _VCursorCellDataDirect(self->curs, spot, self->colREAD_TYPE,
+ 8, &base, nreads, "READ_TYPE");
+ if (rc != 0) {
+ return rc;
+ }
+ readType = base;
+ for (read = 0; read < nreads; ++read) {
+ INSDC_read_type type = readType[read] & 1;
+ if (type == READ_TYPE_BIOLOGICAL) {
+ bioBases += readLen[read];
+ }
+ else {
+ techBases += readLen[read];
+ }
+ }
+ if (self->techBasesPerSpotEquals) {
+ if (self->techBasesPerSpot != techBases) {
+ if (self->techBasesPerSpot == ~0) {
+ self->techBasesPerSpot = techBases;
+ }
+ else {
+ self->techBasesPerSpotEquals = false;
+ }
+ }
+ }
+ self->bioBasesCnt += bioBases;
+ }
+ return rc;
+}
+static
+rc_t _ApprCntInit(ApprCnt *self,
+ const VTable *tbl)
+{
+ rc_t rc = 0;
+
+ assert(self);
+
+ memset(self, 0, sizeof *self);
+
+ self->techBasesPerSpotEquals = true;
+ self->techBasesPerSpot = ~0;
+
+ if (rc == 0) {
+ rc = VTableCreateCursorRead(tbl, &self->curs);
+ if (rc != 0) {
+ LOGERR(klogInt, rc, "Error during VTableCreateCursorRead");
+ }
+ }
+
+ if (rc == 0) {
+ const char name[] = "READ_LEN";
+ rc = VCursorAddColumn(self->curs, &self->colREAD_LEN, name);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error during VCursorAddColumn($(name))", "name=%s", name));
+ }
+ }
+
+ if (rc == 0) {
+ const char name[] = "READ_TYPE";
+ rc = VCursorAddColumn(self->curs, &self->colREAD_TYPE, name);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error during VCursorAddColumn($(name))", "name=%s", name));
+ }
+ }
+
+ if (rc == 0) {
+ rc = VCursorOpen(self->curs);
+ if (rc != 0) {
+ LOGERR(klogInt, rc, "Error during VCursorOpen");
+ }
+ }
+
+ return rc;
+}
+static
+rc_t _ApprCntFini(ApprCnt *self)
+{
+ rc_t rc = 0;
+ assert(self);
+ RELEASE(VCursor, self->curs);
+ memset(self, 0, sizeof *self);
+ return rc;
+}
+static uint64_t BIG = 10000 /*11*/;
+static
+rc_t _VTableBioBaseCntApprox(const VTable *self,
+ uint64_t nspots, uint32_t nreads, uint64_t *bio_base_count)
+{
+ rc_t rc = 0;
+ uint64_t c = nspots;
+ uint64_t d = 1;
+ ApprCnt ac;
+ rc = _ApprCntInit(&ac, self);
+ assert(bio_base_count);
+ if (rc == 0) {
+ if (nspots < BIG) {
+ STSMSG(2,
+ ("VdbBlastRunSetGetTotalLengthApprox: counting all reads\n"));
+ rc = _ApprCntChunk(&ac, 0, nspots, nspots, nreads);
+ }
+ else {
+ uint64_t i = 0;
+ uint64_t l = 0;
+ uint64_t n = 10 /* 3 */;
+ while (c > BIG) {
+ c /= 2;
+ d *= 2;
+ }
+ l = c / n;
+ if (l == 0) {
+ l = 1;
+ }
+ for (i = 1; i < n - 1 && rc == 0; ++i) {
+ rc = _ApprCntChunk(&ac, i, l, nspots, nreads);
+ }
+ }
+ }
+ if (rc == 0) {
+ uint32_t status = eVdbBlastNoErr;
+ if (nspots < BIG) {
+ *bio_base_count = ac.bioBasesCnt;
+ }
+ else {
+ if (ac.techBasesPerSpotEquals && ac.techBasesPerSpot == ~0) {
+ ac.techBasesPerSpotEquals = false;
+ }
+ if (ac.techBasesPerSpotEquals ) {
+ uint64_t baseCount = 0;
+ status = _VTableReadFirstRow(
+ self, "BASE_COUNT", &baseCount, sizeof baseCount, NULL);
+ if (status == eVdbBlastNoErr) {
+ STSMSG(2, ("VdbBlastRunSetGetTotalLengthApprox: "
+ "fixed technical reads length\n"));
+ *bio_base_count = baseCount - nspots * ac.techBasesPerSpot;
+ }
+ else {
+ STSMSG(1, ("VdbBlastRunSetGetTotalLengthApprox: "
+ "cannot read BASE_COUNT\n"));
+ }
+ }
+ if (!ac.techBasesPerSpotEquals || status != eVdbBlastNoErr) {
+/* double dd = nspots / c; */
+ STSMSG(2, ("VdbBlastRunSetGetTotalLengthApprox: "
+ "extrapolating variable read length\n"));
+ *bio_base_count = ac.bioBasesCnt * d;
+ }
+ }
+ }
+ _ApprCntFini(&ac);
+ return rc;
+}
+static
+uint64_t _VdbBlastRunCountBioBaseCount(VdbBlastRun *self,
+ uint32_t *status)
+{
+ uint64_t bio_base_count = 0;
+ rc_t rc = _VTableBioBaseCntApprox(self->tbl,
+ self->rd.spotCount, self->rd.nReads, &bio_base_count);
+#if 0
+ const VCursor *curs = NULL;
+/* uint32_t colREAD_FILTER = 0; */
+ uint32_t colREAD_LEN = 0;
+ uint32_t colREAD_TYPE = 0;
+ uint64_t spot = 0;
+ assert(self && status);
+ if (rc == 0) {
+ rc = VTableCreateCursorRead(self->tbl, &curs);
+ if (rc != 0) {
+ LOGERR(klogInt, rc, "Error during VTableCreateCursorRead");
+ }
+ }
+/* if (rc == 0) {
+ const char name[] = "READ_FILTER";
+ rc = VCursorAddColumn(curs, &colREAD_FILTER, name);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error during VCursorAddColumn($(name))", "name=%s", name));
+ }
+ }*/
+ if (rc == 0) {
+ const char name[] = "READ_LEN";
+ rc = VCursorAddColumn(curs, &colREAD_LEN, name);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error during VCursorAddColumn($(name))", "name=%s", name));
+ }
+ }
+ if (rc == 0) {
+ const char name[] = "READ_TYPE";
+ rc = VCursorAddColumn(curs, &colREAD_TYPE, name);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error during VCursorAddColumn($(name))", "name=%s", name));
+ }
+ }
+ if (rc == 0) {
+ rc = VCursorOpen(curs);
+ if (rc != 0) {
+ LOGERR(klogInt, rc, "Error during VCursorOpen");
+ }
+ }
+ for (spot = 1; spot <= self->rd.spotCount && rc == 0; ++spot) {
+ const void *base = NULL;
+ uint32_t elem_bits = 0;
+/* uint8_t *readFilter = NULL; */
+ const uint32_t *readLen = NULL;
+ const INSDC_read_type *readType = NULL;
+ uint32_t boff = 0;
+ uint32_t row_len = 0;
+ uint32_t nreads = 0;
+ if (rc == 0) {
+ rc = VCursorCellDataDirect(curs, spot, colREAD_LEN,
+ &elem_bits, &base, &boff, &row_len);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error during VCursorCellDataDirect(READ_LEN, $(spot))",
+ "spot=%lu", spot));
+ }
+ else if (boff != 0 || elem_bits != 32) {
+ rc = RC(rcSRA, rcCursor, rcReading, rcData, rcUnexpected);
+ PLOGERR(klogInt, (klogInt, rc,
+ "Bad VCursorCellDataDirect(READ_LEN, $(spot)) result: "
+ "boff=$(boff), elem_bits=$(elem_bits)",
+ "spot=%lu, boff=%u, elem_bits=%u", spot, boff, elem_bits));
+ }
+ else {
+ readLen = base;
+ nreads = row_len;
+ }
+ }
+ /*if (rc == 0) {
+ rc = VCursorCellDataDirect(curs, spot, colREAD_FILTER,
+ &elem_bits, &base, &boff, &row_len);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error during VCursorCellDataDirect(READ_FILTER, $(spot))",
+ "spot=%lu", spot));
+ }
+ else if (boff != 0 || elem_bits != 8) {
+ rc = RC(rcSRA, rcCursor, rcReading, rcData, rcUnexpected);
+ PLOGERR(klogInt, (klogInt, rc,
+ "Bad VCursorCellDataDirect(READ_FILTER, $(spot)) result: "
+ "boff=$(boff), row_len=$(row_len)",
+ "spot=%lu, boff=%u, row_len=%u", spot, boff, row_len));
+ }
+ else if (row_len != nreads) {
+ rc = RC(rcSRA, rcCursor, rcReading, rcData, rcUnexpected);
+ PLOGERR(klogInt, (klogInt, rc,
+ "spot $(spot): READ_LEN[$(len)], FILTER[$(type)]",
+ "spot=%lu, len=%u, type=%u", spot, nreads, row_len));
+ }
+ else {
+ readFilter = base;
+ }
+ }*/
+ if (rc == 0) {
+ rc = VCursorCellDataDirect(curs, spot, colREAD_TYPE,
+ &elem_bits, &base, &boff, &row_len);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error during VCursorCellDataDirect(READ_TYPE, $(spot))",
+ "spot=%lu", spot));
+ }
+ else if (boff != 0 || elem_bits != 8) {
+ rc = RC(rcSRA, rcCursor, rcReading, rcData, rcUnexpected);
+ PLOGERR(klogInt, (klogInt, rc,
+ "Bad VCursorCellDataDirect(READ_TYPE, $(spot)) result: "
+ "boff=$(boff), row_len=$(row_len)",
+ "spot=%lu, boff=%u, row_len=%u", spot, boff, row_len));
+ }
+ else if (row_len != nreads) {
+ rc = RC(rcSRA, rcCursor, rcReading, rcData, rcUnexpected);
+ PLOGERR(klogInt, (klogInt, rc,
+ "spot $(spot): READ_LEN[$(len)], READ_TYPE[$(type)]",
+ "spot=%lu, len=%u, type=%u", spot, nreads, row_len));
+ }
+ else {
+ readType = base;
+ }
+ }
+ if (rc == 0) {
+ uint32_t i = 0;
+ for (i = 0; i < nreads; ++i) {
+ INSDC_read_type type = readType[i];
+ type &= 1;
+ if (type == READ_TYPE_BIOLOGICAL) {
+/* if (readFilter[i] == READ_FILTER_PASS) */
+ bio_base_count += readLen[i];
+ }
+ }
+ }
+ }
+ RELEASE(VCursor, curs);
+#endif
+ if (rc != 0) {
+ *status = eVdbBlastErr;
+ }
+ return bio_base_count;
+}
+
+static
+uint64_t _VdbBlastSraRunGetLengthApprox(VdbBlastRun *self,
+ uint32_t *status)
+{
+ assert(self && status);
+
+ *status = eVdbBlastNoErr;
+
+ if (self->bioBasesApprox == ~0) {
+ RunDesc *rd = NULL;
+ *status = _VdbBlastRunFillRunDesc(self);
+ if (*status != eVdbBlastNoErr) {
+ S
+ return 0;
+ }
+
+ rd = &self->rd;
+ if (rd->nReads == 0) {
+ S
+ self->bioBasesApprox = 0;
+ }
+ else if (rd->varReadLen) {
+ S
+ self->bioBasesApprox = _VdbBlastRunCountBioBaseCount(self, status);
+ }
+ else {
+ if (self->type == btpREFSEQ) {
+ if (rd->bioBaseCount == ~0) {
+ S
+ *status = eVdbBlastErr;
+ }
+ else {
+ self->bioBasesApprox = rd->bioBaseCount;
+ }
+ }
+ else {
+ uint8_t read = 0;
+ S
+ for (read = 0, self->bioBasesApprox = 0;
+ read < rd->nReads; ++read)
+ {
+ if (rd->readType[read] & SRA_READ_TYPE_BIOLOGICAL) {
+ self->bioBasesApprox += rd->readLen[read];
+ }
+ }
+ self->bioBasesApprox *= rd->spotCount;
+ }
+ }
+ }
+
+ return self->bioBasesApprox;
+}
+
+static uint64_t _VdbBlastRunGetLengthApprox(VdbBlastRun *self, uint32_t *status)
+{
+ if (self->cSra) {
+ return _VdbBlastRunGetLength(self, status);
+ }
+ else {
+ return _VdbBlastSraRunGetLengthApprox(self, status);
+ }
+}
+
+static
+uint64_t _VdbBlastRunGetNumSequencesApprox(VdbBlastRun *self,
+ uint32_t *status)
+{
+
+ assert(self && status);
+
+ *status = eVdbBlastNoErr;
+
+ if (self->bioReadsApprox == ~0) {
+ RunDesc *rd = NULL;
+
+ if (self->bioReads != ~0 && ! self->bioReadsTooExpensive) {
+ self->bioReadsApprox = self->bioReads;
+ }
+ else if (self->type == btpREFSEQ) {
+ S
+ self->bioReadsApprox = 1;
+ }
+ else if (self->cSra) {
+/* Number of Bio Reads for cSra == number of CMP reads
+ = Number of all bio reads * CMP_BASE_COUNT / BIO_BASE_COUNT
+ Number of all bio reads = nSpots * n of bio reads per spot */
+ double r = 0;
+ uint64_t n = 0;
+
+ *status = _VdbBlastRunFillRunDesc(self);
+ if (*status != eVdbBlastNoErr) {
+ S
+ return 0;
+ }
+
+ rd = &self->rd;
+
+ n = _VdbBlastSraRunGetLengthApprox(self, status);
+ if (*status != eVdbBlastNoErr) {
+ S
+ return 0;
+ }
+ r = rd->cmpBaseCount * rd->spotCount * rd->nBioReads;
+ r /= n;
+ self->bioReadsApprox = r;
+ }
+ else {
+ *status = _VdbBlastRunFillRunDesc(self);
+ if (*status != eVdbBlastNoErr) {
+ S
+ return 0;
+ }
+
+ rd = &self->rd;
+
+ self->bioReadsApprox = rd->spotCount * rd->nBioReads;
+ S
+ }
+ }
+ else
+ { S }
+
+ return self->bioReadsApprox;
+}
+
+static
+uint32_t _VdbBlastRunGetWgsAccession(VdbBlastRun *self,
+ int64_t spot,
+ char *name_buffer,
+ size_t bsize,
+ size_t *num_required)
+{
+ rc_t rc = 0;
+ uint32_t row_len = 0;
+
+ assert(num_required);
+
+ if (self == NULL || spot <= 0 || name_buffer == NULL || bsize == 0) {
+ STSMSG(0, ("Error: some of %s parameters is NULL or 0", __func__));
+ return eVdbBlastErr;
+ }
+ if (self->tbl == NULL) {
+ STSMSG(0, ("Error: %s: VTable is NULL in VdbBlastRun", __func__));
+ return eVdbBlastErr;
+ }
+
+ if (self->cursACCESSION == NULL) {
+ rc = _VTableMakeCursor(self->tbl,
+ &self->cursACCESSION, &self->col_ACCESSION, "ACCESSION");
+ if (rc != 0) {
+ VCursorRelease(self->cursACCESSION);
+ self->cursACCESSION = NULL;
+ return eVdbBlastErr;
+ }
+ }
+
+ assert(self->cursACCESSION && rc == 0);
+
+ rc = VCursorReadDirect(self->cursACCESSION, spot,
+ self->col_ACCESSION, 8, name_buffer, bsize, &row_len);
+ *num_required = row_len;
+ if (row_len > 0) /* include ending '\0' */
+ { ++(*num_required); }
+ if (rc == 0) {
+ if (bsize > row_len)
+ { name_buffer[row_len] = '\0'; }
+ return eVdbBlastNoErr;
+ }
+ else if (rc == SILENT_RC
+ (rcVDB, rcCursor, rcReading, rcBuffer, rcInsufficient))
+ { return eVdbBlastNoErr; }
+ else {
+ assert(self->path);
+ PLOGERR(klogInt, (klogInt, rc, "Error in VCursorReadDirect"
+ "$(path), ACCESSION, spot=$(spot))",
+ "path=%s,spot=%ld", self->path, spot));
+ return eVdbBlastErr;
+ }
+}
+
+/******************************************************************************/
+typedef struct ReadDesc {
+ const VdbBlastRun *prev;
+
+ VdbBlastRun *run;
+ uint64_t spot; /* 1-based */
+ uint32_t read; /* 1-based */
+
+ uint64_t read_id; /* BioReadId in RunSet */
+} ReadDesc;
+static
+bool _ReadDescNextRead(ReadDesc *self)
+{
+ uint32_t read = 0;
+ int i = 0;
+ const RunDesc *rd = NULL;
+
+ assert(self && self->run);
+
+ rd = &self->run->rd;
+
+ if (rd->nBioReads == 0) {
+ S
+ return false;
+ }
+
+ for (i = self->read + 1; i <= rd->nReads; ++i) {
+ if (rd->readType[i - 1] & SRA_READ_TYPE_BIOLOGICAL) {
+ S
+ read = i;
+ break;
+ }
+ }
+
+ if (read == 0) {
+ if (++self->spot > rd->spotCount) {
+ S
+ return false;
+ }
+
+ for (i = 1; i <= rd->nReads; ++i) {
+ if (rd->readType[i - 1] & SRA_READ_TYPE_BIOLOGICAL) {
+ S
+ read = i;
+ break;
+ }
+ }
+ }
+
+ if (read) {
+ S
+ self->read = read;
+ ++self->read_id;
+ }
+ else
+ { S }
+
+ return read;
+}
+
+static
+bool _ReadDescSameRun(const ReadDesc *self)
+{
+ assert(self);
+
+ if (self->prev == NULL && self->run == NULL) {
+ S
+ return false;
+ }
+
+ S
+ return self->prev == self->run;
+}
+
+#ifdef TEST_VdbBlastRunFillReadDesc
+LIB_EXPORT
+#else
+static
+#endif
+uint32_t _VdbBlastRunFillReadDesc(VdbBlastRun *self,
+ uint64_t read_id,
+ ReadDesc *desc)
+{
+ const VdbBlastRun *prev = NULL;
+ const RunDesc *rd = NULL;
+
+ int bioIdx = 0;
+
+ if (self == NULL || desc == NULL) {
+ S
+ return eVdbBlastErr;
+ }
+
+ prev = desc->run;
+ memset(desc, 0, sizeof *desc);
+ desc->prev = prev;
+ desc->run = self;
+
+ rd = &self->rd;
+
+ if (rd->nReads == 0 || rd->readType == NULL) {
+ uint32_t status = _VdbBlastRunFillRunDesc(self);
+ if (status != eVdbBlastNoErr)
+ { return status; }
+ assert(rd->nReads && rd->readType);
+ }
+
+ desc->spot = read_id / rd->nBioReads + 1;
+ if (desc->spot <= rd->spotCount) {
+ int idInSpot = read_id - (desc->spot - 1) * rd->nBioReads; /* 0-based */
+
+ int i = 0;
+ for (i = 0; i < rd->nReads; ++i) {
+ if (rd->readType[i] & SRA_READ_TYPE_BIOLOGICAL) {
+ if (bioIdx++ == idInSpot) {
+ S
+ desc->read = i + 1;
+ return eVdbBlastNoErr;
+ }
+ }
+ }
+ S
+ }
+ else { S }
+
+ memset(desc, 0, sizeof *desc);
+ return eVdbBlastErr;
+}
+
+static
+uint32_t _VdbBlastRunGetReadId(VdbBlastRun *self,
+ const char *acc,
+ uint64_t spot, /* 1-based */
+ uint32_t read, /* 1-based */
+ uint64_t *read_id)
+{
+ uint64_t id = ~0;
+ uint32_t status = eVdbBlastErr;
+ size_t size;
+
+ assert(self && acc && read_id && self->acc);
+ assert(memcmp(self->acc, acc, string_measure(self->acc, &size)) == 0);
+
+ if ((spot <= 0 && read > 0) || (spot > 0 && read <= 0)) {
+ S
+ return eVdbBlastErr;
+ }
+
+ if (spot > 0) {
+ if (self->type != btpSRA) {
+ return eVdbBlastErr;
+ }
+
+ for (id = (spot - 1) * self->rd.nBioReads; ; ++id) {
+ ReadDesc desc;
+ status = _VdbBlastRunFillReadDesc(self, id, &desc);
+ if (status != eVdbBlastNoErr)
+ { return status; }
+ if (desc.spot < spot) {
+ S
+ return eVdbBlastErr;
+ }
+ if (desc.spot > spot) {
+ S
+ return eVdbBlastErr;
+ }
+ if (desc.read == read) {
+ *read_id = id;
+ return eVdbBlastNoErr;
+ }
+ }
+ S
+ return eVdbBlastErr;
+ }
+ else {
+ uint64_t n = ~0;
+ uint64_t i = ~0;
+ if (self->type == btpSRA)
+ { return eVdbBlastErr; }
+ else if (self->type == btpREFSEQ) {
+ *read_id = 0;
+ return eVdbBlastNoErr;
+ }
+ else if (self->type == btpWGS) {
+ n = _VdbBlastRunGetNumSequences(self, &status);
+ if (status != eVdbBlastNoErr && status != eVdbBlastTooExpensive) {
+ return status;
+ }
+ /* TODO optimize: avoid full run scan */
+ for (i = 0; i < n ; ++i) {
+ size_t need = ~0;
+#define SZ 4096
+ char name_buffer[SZ + 1];
+ if (string_measure(acc, &size) > SZ) {
+ S
+ return eVdbBlastErr;
+ }
+#undef SZ
+ status = _VdbBlastRunGetWgsAccession(
+ self, i + 1, name_buffer, sizeof name_buffer, &need);
+ if (need > sizeof name_buffer) {
+ S
+ return eVdbBlastErr;
+ }
+ if (strcmp(name_buffer, acc) == 0) {
+ *read_id = i;
+ return eVdbBlastNoErr;
+ }
+ }
+ }
+ else { assert(0); }
+ return eVdbBlastErr;
+ }
+}
+
+/*
+static
+rc_t _VTableStatic(const VTable *self,
+ const char *col_name, bool *isStatic)
+{
+ rc_t rc = 0;
+ const VCursor *curs = NULL;
+ uint32_t idx = 0;
+ rc = _VTableMakeCursor(self, &curs, &idx, col_name);
+ if (rc == 0) {
+ rc = VCursorIsStaticColumn(curs, idx, isStatic);
+ }
+ RELEASE(VCursor, curs);
+ return rc;
+}
+static
+uint32_t _VdbBlastRunFillBioInfo(VdbBlastRun *self) {
+ rc_t rc = 0;
+ bool isStatic = true;
+ bool aStatic = false;
+
+ assert(self);
+
+ if (self->bioReads == ~0 || self->bioReadsApprox == ~0) {
+ return eVdbBlastTooExpensive;
+ }
+ if (self->bioReads != 0 || self->bioReadsApprox != 0) {
+ return eVdbBlastNoErr;
+ }
+ rc = _VTableStatic(self->tbl, "READ_LEN");
+ return eVdbBlastNoErr;
+}*/
+
+typedef struct Data2na {
+ uint32_t irun;
+ const VBlob *blob;
+} Data2na;
+/******************************************************************************/
+typedef struct Reader2na {
+ bool eor;
+ ReadDesc desc;
+ uint32_t col_READ;
+ const VCursor *curs;
+ size_t starting_base; /* 0-based, in current read */
+ ReaderCols cols;
+} Reader2na;
+static
+uint64_t _Reader2naFini(Reader2na *self)
+{
+ uint64_t read_id = 0;
+
+ assert(self);
+
+ read_id = self->desc.read_id;
+
+ VCursorRelease(self->curs);
+
+ ReaderColsFini(&self->cols);
+
+ memset(self, 0, sizeof *self);
+
+ return read_id;
+}
+
+static
+bool _Reader2naEor(const Reader2na *self)
+{
+ assert(self);
+ S
+ return self->eor;
+}
+
+static
+uint32_t _Reader2naReadCols(Reader2na *self)
+{
+ assert(self && self->desc.run);
+ return _VCursorReadCols
+ (self->curs, self->desc.spot, &self->cols, self->desc.run->rd.nReads);
+}
+
+static
+uint32_t _Reader2naGetBlob(Reader2na *self,
+ const VBlob **blob,
+ const ReadDesc *desc,
+ int64_t *first,
+ uint64_t *count)
+{
+ bool fresh = false;
+
+ assert(self && blob && desc && first && count
+ && desc->run && desc->run->path);
+
+ for (fresh = false; ;) {
+ rc_t rc = 0;
+
+ if (*blob == NULL) {
+ rc = VCursorGetBlobDirect
+ (self->curs, blob, desc->spot, self->col_READ);
+ if (rc) {
+ PLOGERR(klogInt, (klogInt, rc, "Error in VCursorGetBlobDirect"
+ "($(path), READ, spot=$(spot))",
+ "path=%s,spot=%ld", desc->run->path, desc->spot));
+ return eVdbBlastErr;
+ }
+
+ fresh = true;
+ }
+
+ rc = VBlobIdRange(*blob, first, count);
+ if (rc) {
+ PLOGERR(klogInt, (klogInt, rc, "Error in VBlobIdRange($(path))",
+ "path=%s", desc->run->path));
+ return eVdbBlastErr;
+ }
+
+ if (desc->spot >= *first && desc->spot < *first + *count) {
+ S
+ return eVdbBlastNoErr;
+ }
+
+ if (fresh) {
+ S
+ return eVdbBlastErr;
+ }
+
+ rc = VBlobRelease(*blob);
+ *blob = NULL;
+ if (rc) {
+ PLOGERR(klogInt, (klogInt, rc, "Error in VBlobRelease($(path))",
+ "path=%s", desc->run->path));
+ return eVdbBlastErr;
+ }
+ }
+
+ S
+ return eVdbBlastErr;
+}
+
+static
+uint32_t _Reader2naCalcReadParams(const ReadDesc *desc,
+ const ReaderCols *cols,
+ uint32_t *start,
+ uint32_t min_read_length)
+{
+ int i = ~0;
+ uint32_t to_read = 0;
+ assert(desc && cols && start);
+ assert(desc->run && desc->run->path);
+
+ *start = 0;
+
+ assert(cols->read_len && cols->read_filter);
+ for (i = 1; i < desc->read; ++i) {
+ assert(i <= desc->run->rd.nReads);
+
+ /* do not count CMP_READ-s where primary_alignment_id != 0
+ as are not stored in CMP_READ) */
+ if (!ReaderColsIsReadCompressed(cols, i - 1)) {
+ *start += cols->read_len[i - 1];
+ }
+ }
+ S
+
+ if (cols->read_len[desc->read - 1] == 0) {
+ S
+ DBGMSG(DBG_BLAST, DBG_FLAG(DBG_BLAST_BLAST),
+ ("%s: %s:%d:%d(%d): READ_LEN=0\n",
+ __func__, desc->run->path, desc->spot, desc->read, desc->read_id));
+ return 0;
+ }
+ else if (cols->read_filter[desc->read - 1] != READ_FILTER_PASS) {
+ S
+ DBGMSG(DBG_BLAST, DBG_FLAG(DBG_BLAST_BLAST),
+ ("%s: %s:%d:%d(%d): READ_FILTER != READ_FILTER_PASS\n",
+ __func__, desc->run->path, desc->spot, desc->read, desc->read_id));
+ return 0;
+ }
+ else if (cols->TRIM_LEN > 0
+ && *start >= cols->TRIM_START + cols->TRIM_LEN)
+ {
+ return 0;
+ }
+ else {
+ uint32_t end = 0;
+
+ /* do not count CMP_READ-s where primary_alignment_id != 0
+ as are not stored in CMP_READ) */
+ if (ReaderColsIsReadCompressed(cols, desc->read - 1)) {
+ to_read = 0;
+ S
+ DBGMSG(DBG_BLAST, DBG_FLAG(DBG_BLAST_BLAST),
+ ("%s: %s:%d:%d(%d): PRIMARY_ALIGNMENT_ID != 0\n", __func__,
+ desc->run->path, desc->spot, desc->read, desc->read_id));
+ }
+ else {
+ to_read = cols->read_len[desc->read - 1];
+ end = *start + to_read;
+ if (cols->TRIM_LEN > 0 && cols->TRIM_START > *start) {
+ uint32_t delta = cols->TRIM_START - *start;
+ if (to_read > delta) {
+ *start = cols->TRIM_START;
+ to_read -= delta;
+ assert(*start + to_read == end);
+ }
+ else {
+ to_read = 0;
+ }
+ }
+ }
+ if (to_read > 0) {
+ if (cols->TRIM_LEN > 0 &&
+ end > (cols->TRIM_START + cols->TRIM_LEN))
+ {
+ uint32_t delta = end - (cols->TRIM_START + cols->TRIM_LEN);
+ assert(delta < to_read);
+ to_read -= delta;
+ }
+ if (to_read < min_read_length) {
+ S
+ DBGMSG(DBG_BLAST, DBG_FLAG(DBG_BLAST_BLAST),
+ ("%s: %s:%d:%d(%d): READ_LEN=%d: TOO SHORT (<%d)\n",
+ __func__, desc->run->path, desc->spot, desc->read,
+ desc->read_id, cols->read_len[desc->read - 1],
+ min_read_length));
+ return 0;
+ }
+ else {
+ DBGMSG(DBG_BLAST, DBG_FLAG(DBG_BLAST_BLAST),
+ ("%s: %s:%d:%d(%d): READ_LEN=%d\n", __func__,
+ desc->run->path, desc->spot, desc->read,
+ desc->read_id, cols->read_len[desc->read - 1]));
+ }
+ }
+ }
+
+ return to_read;
+}
+
+static
+bool _Reader2naNextData(Reader2na *self,
+ const VBlob *blob,
+ uint32_t *status,
+ Packed2naRead *out,
+ uint32_t min_read_length)
+{
+ uint32_t start = 0;
+ uint32_t to_read = 0;
+ const ReadDesc *desc = NULL;
+ assert(self && status && out && self->curs);
+ desc = &self->desc;
+ memset(out, 0, sizeof *out);
+
+ *status = _Reader2naReadCols(self);
+ if (*status != eVdbBlastNoErr) {
+ S
+ return false;
+ }
+ if (!self->curs || !desc->run) {
+ S
+ *status = eVdbBlastErr;
+ return false;
+ }
+
+ assert(self->cols.read_len && self->cols.read_filter);
+ assert(desc->read <= desc->run->rd.nReads);
+
+ to_read = _Reader2naCalcReadParams(&self->desc, &self->cols,
+ &start, min_read_length);
+ if (to_read == 0) {
+ return true;
+ }
+ else {
+ uint32_t elem_bits = 0;
+ rc_t rc = 0;
+
+ S
+ DBGMSG(DBG_BLAST, DBG_FLAG(DBG_BLAST_BLAST),
+ ("%s: %s:%d:%d(%d): READ_LEN=%d\n", __func__,
+ self->desc.run->path, self->desc.spot, self->desc.read,
+ self->desc.read_id, self->cols.read_len[desc->read - 1]));
+
+ rc = VBlobCellData(blob, desc->spot, &elem_bits,
+ (const void **)&out->starting_byte, &out->offset_to_first_bit,
+ &out->length_in_bases);
+ if (rc != 0) {
+ S
+ DBGMSG(DBG_BLAST, DBG_FLAG(DBG_BLAST_BLAST),
+ ("%s: %s:%d:%d(%d): READ_LEN=%d: "
+ "ERROR WHILE READING: SKIPPED FOR NOW\n", __func__,
+ self->desc.run->path, self->desc.spot, self->desc.read,
+ self->desc.read_id, self->cols.read_len[desc->read - 1]));
+ /* special case */
+ *status = eVdbBlastErr;
+ return true;
+ }
+
+ if (elem_bits != 2) {
+ S
+ *status = eVdbBlastErr;
+ return false;
+ }
+
+ if (out->length_in_bases < start) {
+ S
+ *status = eVdbBlastErr;
+ return false;
+ }
+
+ out->offset_to_first_bit += start * 2;
+ S
+
+ out->length_in_bases = to_read;
+ while (out->offset_to_first_bit >= 8) {
+ out->starting_byte = ((uint8_t*)out->starting_byte) + 1;
+ out->offset_to_first_bit -= 8;
+ }
+ out->read_id = desc->read_id;
+ S
+ return true;
+ }
+}
+
+static
+uint32_t _Reader2naData(Reader2na *self,
+ Data2na *data,
+ uint32_t *status,
+ Packed2naRead *buffer,
+ uint32_t buffer_length,
+ uint32_t min_read_length)
+{
+ ReadDesc *desc = NULL;
+ uint32_t n = 0;
+ int64_t first = 0;
+ uint64_t count = 0;
+ uint32_t dummy = eVdbBlastNoErr;
+ if (status == NULL)
+ { status = &dummy; }
+ *status = eVdbBlastErr;
+ if (buffer_length && buffer == NULL) {
+ S
+ return 0;
+ }
+
+ assert(self && self->curs && data);
+ desc = &self->desc;
+ *status = _Reader2naGetBlob(self, &data->blob, desc, &first, &count);
+ if (*status == eVdbBlastErr) {
+ S
+ return 0;
+ }
+
+ for (n = 0; n < buffer_length; ) {
+ Packed2naRead *p = buffer + n;
+ bool ignorable
+ = _Reader2naNextData(self, data->blob, status, p, min_read_length);
+ if (*status == eVdbBlastErr) {
+ if (ignorable) {
+ /* special case */
+ if (n > 0) { /* let's retry during next call */
+ S
+ *status = eVdbBlastNoErr;
+ }
+ else
+ { S }
+ return n;
+ }
+ S
+ return 0;
+ }
+ if (p->length_in_bases > 0)
+ { ++n; }
+ if (!_ReadDescNextRead(desc)) {
+ S
+ self->eor = true;
+ break;
+ }
+ if (desc->spot >= first + count) {
+ S
+ break;
+ }
+ }
+
+ *status = eVdbBlastNoErr;
+ return n;
+}
+/* struct Packed2naRead {
+ uint64_t read_id;
+ void *starting_byte;
+ uint32_t offset_to_first_bit;
+ uint32_t length_in_bases; }; */
+
+static
+uint64_t _Reader2naRead(Reader2na *self,
+ uint32_t *status,
+ uint64_t *read_id,
+ size_t *starting_base,
+ uint8_t *buffer,
+ size_t buffer_size,
+ uint32_t min_read_length)
+{
+ uint32_t num_read = 0;
+ uint32_t to_read = 0;
+ ReadDesc *desc = NULL;
+ uint32_t start = 0;
+ uint32_t remaining = 0;
+ rc_t rc = 0;
+ assert(self && status && read_id && starting_base);
+ desc = &self->desc;
+ *read_id = desc->read_id;
+ *starting_base = self->starting_base;
+
+ if (_Reader2naEor(self)) {
+ S
+ *status = eVdbBlastNoErr;
+ return 0;
+ }
+
+ *status = _Reader2naReadCols(self);
+ if (*status != eVdbBlastNoErr) {
+ S
+ return 0;
+ }
+
+ *status = eVdbBlastErr;
+ if (!self->curs || !desc->run) {
+ S
+ return 0;
+ }
+
+ assert(desc->run->path);
+
+ *status = eVdbBlastNoErr;
+ if (desc->run->rd.nBioReads == 0) {
+ S
+ return 0;
+ }
+
+ *status = eVdbBlastNoErr;
+
+ to_read = _Reader2naCalcReadParams(&self->desc, &self->cols,
+ &start, min_read_length);
+ if (to_read <= self->starting_base) {
+ S
+ DBGMSG(DBG_BLAST, DBG_FLAG(DBG_BLAST_BLAST), (
+ "%s: %s:%d:%d(%d): READ_LEN=%d: TOO SHORT (starting_base=%d)\n",
+ __func__, desc->run->path, desc->spot, desc->read,
+ desc->read_id, self->cols.read_len[desc->read - 1],
+ self->starting_base));
+ to_read = 0;
+ }
+ else {
+ to_read -= self->starting_base;
+ start += self->starting_base;
+ }
+ if (to_read > 0) {
+ S
+ rc = VCursorReadBitsDirect(self->curs, desc->spot, self->col_READ, 2,
+ start, buffer, 0, buffer_size * 4, &num_read, &remaining);
+ if (rc) {
+ if (rc == SILENT_RC
+ (rcVDB, rcCursor, rcReading, rcBuffer, rcInsufficient))
+ {
+ S
+ rc = 0;
+ num_read = buffer_size * 4;
+ }
+ else {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VCursorReadBitsDirect"
+ "($(path), READ, spot=$(spot))", "path=%s,spot=%ld",
+ desc->run->path, desc->spot));
+ *status = eVdbBlastErr;
+ return 0;
+ }
+ }
+ *status
+ = (num_read == 0 && remaining == 0) ? eVdbBlastErr : eVdbBlastNoErr;
+ S
+ }
+
+ if (num_read >= to_read) {
+ self->starting_base = 0;
+ num_read = to_read;
+ if (!_ReadDescNextRead(desc))
+ { self->eor = true; }
+ S
+ }
+ else {
+ self->starting_base += num_read;
+ S
+ }
+
+ return num_read;
+}
+
+static VdbBlastStatus _VdbBlastRunMakeCursor(const VdbBlastRun *self,
+ const VCursor **curs, uint32_t *read_col_idx, bool INSDC2na,
+ ReaderCols *cols)
+{
+ rc_t rc = 0;
+ const char *read_col_name = INSDC2na ? "(INSDC:2na:packed)READ"
+ : "(INSDC:4na:bin)READ";
+ assert(self);
+ if (self->cSra) {
+ read_col_name = INSDC2na ? "(INSDC:2na:packed)CMP_READ"
+ : "(INSDC:4na:bin)CMP_READ";
+ }
+ rc = _VTableMakeCursor(self->tbl, curs, read_col_idx, read_col_name);
+ if (rc == 0) {
+ assert(*curs);
+ VdbBlastStatus status = _VCursorAddCols(*curs, cols, self->cSra);
+ return status;
+ }
+ return eVdbBlastErr;
+}
+
+static
+VdbBlastStatus _Reader2naOpenCursor(Reader2na *self)
+{
+ const ReadDesc *desc = NULL;
+ const VdbBlastRun *run = NULL;
+
+ assert(self);
+
+ desc = &self->desc;
+ run = desc->run;
+
+ assert(run && self->curs == NULL);
+
+ return _VdbBlastRunMakeCursor(run,
+ &self->curs, &self->col_READ, true, &self->cols);
+}
+
+/******************************************************************************/
+typedef struct RunSet {
+ VdbBlastRun *run;
+ uint32_t krun; /* number of run-s */
+ uint32_t nrun; /* sizeof of run-s */
+} RunSet;
+static
+void _RunSetFini(RunSet *self)
+{
+ assert(self);
+ if (self->run) {
+ uint32_t i = 0;
+ for (i = 0; i < self->krun; ++i)
+ { _VdbBlastRunFini(&self->run[i]); }
+ free(self->run);
+ }
+ memset(self, 0, sizeof *self);
+}
+
+static
+uint32_t _RunSetAllocTbl(RunSet *self)
+{
+ size_t nmemb = 16;
+
+ if (self == NULL)
+ { return eVdbBlastErr; }
+
+ if (self->run && self->krun < self->nrun) {
+ return eVdbBlastNoErr;
+ }
+
+ if (self->run == NULL) {
+ self->run = calloc(nmemb, sizeof *self->run);
+ if (self->run == NULL)
+ { return eVdbBlastMemErr; }
+ S
+ }
+ else {
+ void *p = NULL;
+ nmemb += self->nrun;
+ p = realloc(self->run, nmemb * sizeof *self->run);
+ if (p == NULL)
+ { return eVdbBlastMemErr; }
+ self->run = p;
+ S
+ }
+
+ self->nrun = nmemb;
+ return eVdbBlastNoErr;
+}
+
+static
+uint32_t _RunSetAddTbl(RunSet *self,
+ const VTable *tbl,
+ const char *rundesc,
+ BTableType type,
+ const KDirectory *dir,
+ char *fullpath,
+ uint32_t min_read_length)
+{
+
+ VdbBlastRun* run = NULL;
+ uint32_t status = _RunSetAllocTbl(self);
+ if (status) {
+ return status;
+ }
+
+ if (tbl == NULL) {
+ return eVdbBlastNoErr;
+ }
+
+ assert(self && self->run);
+ run = &self->run[self->krun++];
+ status = _VdbBlastRunInit(run,
+ tbl, rundesc, type, dir, fullpath, min_read_length);
+ return status;
+}
+
+static
+uint64_t _RunSetGetNumSequencesApprox(const RunSet *self,
+ uint32_t *status)
+{
+ uint64_t num = 0;
+ uint32_t i = 0;
+ assert(self && status);
+ *status = eVdbBlastNoErr;
+ for (i = 0; i < self->krun; ++i) {
+ VdbBlastRun *run = NULL;
+ assert(self->run);
+ run = &self->run[i];
+ num += _VdbBlastRunGetNumSequencesApprox(run, status);
+ if (*status != eVdbBlastNoErr) {
+ assert(run->path);
+ STSMSG(1, (
+ "Error: failed to GetNumSequencesApprox(on run %s)",
+ run->path));
+ return 0;
+ }
+ }
+
+ STSMSG(1, ("_RunSetGetNumSequencesApprox = %ld", num));
+
+ return num;
+}
+
+static
+uint64_t _RunSetGetNumSequences(const RunSet *self,
+ VdbBlastStatus *aStatus)
+{
+ uint64_t num = 0;
+ uint32_t i = 0;
+ assert(self && aStatus);
+ *aStatus = eVdbBlastNoErr;
+ for (i = 0; i < self->krun; ++i) {
+ VdbBlastStatus status = eVdbBlastNoErr;
+ VdbBlastRun *run = NULL;
+ assert(self->run);
+ run = &self->run[i];
+ num += _VdbBlastRunGetNumSequences(run, &status);
+ if (status != eVdbBlastNoErr) {
+ assert(run->path);
+ if (*aStatus == eVdbBlastNoErr) {
+ *aStatus = status;
+ }
+ if (status != eVdbBlastTooExpensive) {
+ STSMSG(1, (
+ "Error: failed to GetNumSequences(on run %s)", run->path));
+ return 0;
+ }
+ assert(*aStatus == eVdbBlastTooExpensive);
+ }
+ }
+
+ STSMSG(1, ("_RunSetGetNumSequences = %ld", num));
+
+ return num;
+}
+
+static
+uint64_t _RunSetGetTotalLength(const RunSet *self,
+ uint32_t *status)
+{
+ uint64_t num = 0;
+ uint32_t i = 0;
+ assert(self && status);
+
+ if (self->krun)
+ { assert(self->run); }
+
+ for (i = 0; i < self->krun; ++i) {
+ VdbBlastRun *run = &self->run[i];
+ assert(run && run->path);
+ num += _VdbBlastRunGetLength(run, status);
+ if (*status != eVdbBlastNoErr) {
+ STSMSG(1, (
+ "Error: failed to _RunSetGetTotalLength(on run %s)",
+ run->path));
+ return 0;
+ }
+ }
+
+ STSMSG(1, ("_RunSetGetTotalLength = %ld", num));
+
+ return num;
+}
+
+static
+uint64_t _RunSetGetTotalLengthApprox(const RunSet *self,
+ uint32_t *status)
+{
+ uint64_t num = 0;
+ uint32_t i = 0;
+
+ assert(self && status);
+
+ for (num = 0, i = 0; i < self->krun; ++i) {
+ VdbBlastRun *run = NULL;
+ assert(self->run);
+ run = &self->run[i];
+ num += _VdbBlastRunGetLengthApprox(run, status);
+ if (*status != eVdbBlastNoErr) {
+ STSMSG(1, ("Error: failed "
+ "to _VdbBlastRunGetLengthApprox(on run %s)", run->path));
+ return 0;
+ }
+ }
+
+ STSMSG(1, ("VdbBlastRunSetGetTotalLengthApprox = %ld", num));
+ return num;
+}
+
+static
+size_t _RunSetGetName(const RunSet *self,
+ uint32_t *status,
+ char *name_buffer,
+ size_t bsize)
+{
+ size_t need = 0, idx = 0;
+ int i = 0;
+ size_t size;
+
+ assert(self && status);
+ for (i = 0; i < self->krun; ++i) {
+ VdbBlastRun *run = &self->run[i];
+ if (run && run->acc) {
+ if (i)
+ { ++need; }
+ need += string_measure(run->acc, &size);
+ }
+ else {
+ S
+ return 0;
+ }
+ }
+
+ if (name_buffer == NULL || bsize == 0) {
+ S
+ return need;
+ }
+
+ for (i = 0; i < self->krun; ++i) {
+ VdbBlastRun *run = &self->run[i];
+ if (run && run->acc) {
+ if (i)
+ { name_buffer[idx++] = '|'; }
+ if (idx >= bsize) {
+ S
+ return need;
+ }
+ string_copy(name_buffer + idx, bsize - idx,
+ run->acc, string_size(run->acc));
+ idx += string_measure(run->acc, &size);
+ if (idx >= bsize) {
+ S
+ return need;
+ }
+ }
+ }
+ name_buffer[idx++] = '\0';
+ *status = eVdbBlastNoErr;
+
+ S
+ return need;
+}
+
+static
+uint32_t _RunSetFindReadDesc(const RunSet *self,
+ uint64_t read_id,
+ ReadDesc *desc)
+{
+ uint64_t i = 0;
+ uint64_t prev = 0;
+ uint64_t crnt = 0;
+
+ if (self == NULL || desc == NULL) {
+ S
+ return eVdbBlastErr;
+ }
+
+ for (i = 0, prev = 0; i < self->krun; ++i) {
+ uint32_t status = eVdbBlastNoErr;
+ VdbBlastRun *run = NULL;
+ uint64_t l = 0;
+
+ if (prev > 0 && i < prev) {
+ S
+ return eVdbBlastErr;
+ }
+
+ run = &self->run[i];
+ if (run == NULL) {
+ S
+ return eVdbBlastErr;
+ }
+
+ l = _VdbBlastRunGetNumSequences(run, &status);
+ if (status != eVdbBlastNoErr && status != eVdbBlastTooExpensive) {
+ S
+ return status;
+ }
+
+ if (crnt + l <= read_id) {
+ crnt += l;
+ }
+ else {
+ status = _VdbBlastRunFillReadDesc(run, read_id - crnt, desc);
+ if (status == eVdbBlastNoErr) {
+ S
+ desc->read_id = read_id;
+ }
+ else
+ { S }
+
+ return status;
+ }
+
+ prev = i;
+ }
+
+ S
+ return eVdbBlastErr;
+}
+
+/******************************************************************************/
+typedef struct Core2na {
+ uint32_t min_read_length;
+ bool hasReader;
+ KLock *mutex;
+ uint64_t initial_read_id;
+ uint32_t irun; /* index in RunSet */
+ bool eos;
+ Reader2na reader;
+} Core2na;
+static void _Core2naFini(Core2na *self)
+{
+ assert(self);
+ _Reader2naFini(&self->reader);
+ KLockRelease(self->mutex);
+ memset(self, 0, sizeof *self);
+}
+
+static
+uint32_t _Core2naOpen1stRead(Core2na *self,
+ const RunSet *runs,
+ uint64_t initial_read_id)
+{
+ Reader2na *reader = NULL;
+ uint32_t status = eVdbBlastNoErr;
+
+ assert(self && runs);
+
+ reader = &self->reader;
+
+ if (reader->curs)
+ { return eVdbBlastNoErr; }
+
+ if (runs->run && runs->krun) {
+ self->initial_read_id = initial_read_id;
+ status = _RunSetFindReadDesc
+ (runs, initial_read_id, &reader->desc);
+ if (status == eVdbBlastNoErr) {
+ status = _Reader2naOpenCursor(reader);
+ if (status != eVdbBlastNoErr) {
+ S
+ _Reader2naFini(reader);
+ }
+ }
+ else
+ { S }
+ }
+ else {
+ S
+ self->eos = true;
+ }
+
+ return status;
+}
+
+static
+uint32_t _Core2naOpenNextRead(Core2na *core,
+ const RunSet *runs)
+{
+ uint64_t read_id = 0;
+ ReadDesc *desc = NULL;
+ Reader2na *reader = NULL;
+
+ assert(core && runs);
+
+ reader = &core->reader;
+ desc = &reader->desc;
+
+ assert(desc->run);
+
+ read_id = _Reader2naFini(reader) + 1;
+
+ if (core->irun >= runs->krun - 1) { /* No more runs to read */
+ S
+ core->eos = true;
+ return eVdbBlastNoErr;
+ }
+
+ while (++core->irun < runs->krun) {
+ uint32_t status = eVdbBlastNoErr;
+
+ VdbBlastRun *run = &runs->run[core->irun];
+ if (run == NULL) {
+ S
+ return eVdbBlastErr;
+ }
+
+ status = _VdbBlastRunFillReadDesc(run, 0, desc);
+ if (status != eVdbBlastNoErr) {
+ S
+ return status;
+ }
+
+ desc->read_id = read_id;
+ status = _Reader2naOpenCursor(reader);
+ if (status == eVdbBlastNoErr)
+ { S }
+ else { S }
+
+ return status;
+ }
+
+ S
+ return eVdbBlastNoErr;
+}
+
+static
+uint32_t _Core2naData(Core2na *self,
+ Data2na *data,
+ const RunSet *runs,
+ uint32_t *status,
+ Packed2naRead *buffer,
+ uint32_t buffer_length)
+{
+ uint32_t num_read = 0;
+
+ assert(self && data && status && runs);
+
+ *status = eVdbBlastNoErr;
+
+ while (*status == eVdbBlastNoErr && num_read == 0) {
+ if (_Reader2naEor(&self->reader) || data->irun != self->irun) {
+ S
+ VBlobRelease(data->blob);
+ data->blob = NULL;
+ }
+ if (_Reader2naEor(&self->reader)) {
+ S
+ *status = _Core2naOpenNextRead(self, runs);
+ if (*status != eVdbBlastNoErr) {
+ STSMSG(1, ("Error: "
+ "failed to VdbBlast2naReaderData: cannot open next read"));
+ return 0;
+ }
+ }
+ if (data->irun != self->irun)
+ { data->irun = self->irun; }
+
+ if (self->eos) {
+ STSMSG(1, ("VdbBlast2naReaderData: End Of Set"));
+ return 0;
+ }
+
+ num_read = _Reader2naData(&self->reader, data, status,
+ buffer, buffer_length, self->min_read_length);
+ }
+
+ if (*status == eVdbBlastNoErr) {
+ STSMSG(3, ("VdbBlast2naReaderData = %ld", num_read));
+ }
+ else {
+ STSMSG(1, ("Error: failed to VdbBlast2naReaderData"));
+ }
+
+ return num_read;
+}
+
+static
+uint64_t _Core2naRead(Core2na *self,
+ const RunSet *runs,
+ uint32_t *status,
+ uint64_t *read_id,
+ size_t *starting_base,
+ uint8_t *buffer,
+ size_t buffer_size)
+{
+ uint64_t num_read = 0;
+
+ assert(self && status && runs);
+
+ if (buffer_size == 0) {
+ S
+ *status = eVdbBlastErr;
+ return 0;
+ }
+
+ *status = eVdbBlastNoErr;
+
+ while (*status == eVdbBlastNoErr && num_read == 0) {
+ if (_Reader2naEor(&self->reader)) {
+ S
+ *status = _Core2naOpenNextRead(self, runs);
+ if (*status != eVdbBlastNoErr) {
+ S
+ return 0;
+ }
+ }
+
+ if (self->eos) {
+ S
+ return 0;
+ }
+
+ num_read = _Reader2naRead(&self->reader, status,
+ read_id, starting_base, buffer, buffer_size, self->min_read_length);
+ S
+ }
+
+ return num_read;
+}
+
+typedef struct Core4na {
+ uint32_t min_read_length;
+ KLock *mutex;
+ ReadDesc desc;
+ const VCursor *curs;
+ const VBlob *blob; /* TODO */
+ ReaderCols cols;
+ uint32_t col_READ;
+} Core4na;
+
+static
+void _Core4naFini(Core4na *self)
+{
+ assert(self);
+
+ VCursorRelease(self->curs);
+ VBlobRelease(self->blob);
+ KLockRelease(self->mutex);
+
+ ReaderColsFini(&self->cols);
+
+ memset(self, 0, sizeof *self);
+}
+
+static
+size_t _Core4naRead(Core4na *self,
+ const RunSet *runs,
+ uint32_t *status,
+ uint64_t read_id,
+ size_t starting_base,
+ uint8_t *buffer,
+ size_t buffer_length)
+{
+ uint32_t num_read = 0;
+ ReadDesc *desc = NULL;
+ assert(self && runs && status);
+ desc = &((Core4na*)self)->desc;
+
+ *status = _RunSetFindReadDesc(runs, read_id, desc);
+ if (*status != eVdbBlastNoErr)
+ { S }
+ else {
+ rc_t rc = 0;
+ if (!_ReadDescSameRun(desc)) {
+ S
+ ReaderColsReset(&self->cols);
+ VCursorRelease(self->curs);
+ ((Core4na*)self)->curs = NULL;
+ *status = _VdbBlastRunMakeCursor(desc->run,
+ &((Core4na*)self)->curs,
+ &((Core4na*)self)->col_READ, false,
+ &(((Core4na*)self)->cols));
+ S
+ }
+
+ if (*status == eVdbBlastNoErr && rc == 0) {
+ uint32_t remaining = 0;
+ uint32_t start = 0;
+ uint32_t to_read = 0;
+ assert(desc->run && desc->read <= desc->run->rd.nReads
+ && desc->run->path);
+ *status = _VCursorReadCols(self->curs,
+ desc->spot, &((Core4na*)self)->cols, desc->run->rd.nReads);
+ if (*status == eVdbBlastNoErr) {
+ assert(self->cols.read_len && self->cols.read_filter);
+ to_read = _Reader2naCalcReadParams(&self->desc,
+ &self->cols, &start, self->min_read_length);
+ if (to_read == 0) {
+ /* When _Reader2naCalcReadParams returns 0
+ then this read is skipped by 2na reader (usually filtered)
+ and should not be accessed by 4na reader */
+ *status = eVdbBlastInvalidId;
+ S
+ }
+ else {
+ if (to_read >= starting_base) {
+ to_read -= starting_base;
+ start += starting_base;
+ if (buffer_length < to_read) {
+ to_read = buffer_length;
+ }
+ S
+ rc = VCursorReadBitsDirect(self->curs,
+ desc->spot, self->col_READ, 8,
+ start, buffer, 0, to_read, &num_read, &remaining);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VCursorReadBitsDirect"
+ "($(path), READ, spot=$(spot))",
+ "path=%s,spot=%ld",
+ desc->run->path, desc->spot));
+ }
+ }
+ else {
+ S
+ *status = eVdbBlastErr;
+ }
+ }
+ }
+ }
+
+ if (*status == eVdbBlastNoErr)
+ { *status = rc ? eVdbBlastErr : eVdbBlastNoErr; }
+ }
+
+ S
+ return num_read;
+}
+
+static
+const uint8_t* _Core4naData(Core4na *self,
+ const RunSet *runs,
+ uint32_t *status,
+ uint64_t read_id,
+ size_t *length)
+{
+ ReadDesc *desc = NULL;
+ assert(self && runs && status && length);
+ desc = &self->desc;
+
+ *length = 0;
+
+ *status = _RunSetFindReadDesc(runs, read_id, desc);
+ if (*status != eVdbBlastNoErr)
+ { S }
+ else {
+ rc_t rc = 0;
+ const uint8_t *base = NULL;
+ if (!_ReadDescSameRun(desc)) {
+ S
+ ReaderColsReset(&self->cols);
+ VCursorRelease(self->curs);
+ self->curs = NULL;
+ *status = _VdbBlastRunMakeCursor(desc->run,
+ &self->curs, &self->col_READ, false,
+ &self->cols);
+ S
+ }
+
+ if (*status == eVdbBlastNoErr) {
+ *status = _VCursorReadCols(self->curs, desc->spot,
+ &self->cols, desc->run->rd.nReads);
+ S
+ }
+
+ if (rc == 0 && *status == eVdbBlastNoErr) {
+ assert(self->cols.read_len && self->cols.read_filter
+ && desc->run->path);
+
+ if (self->cols.read_filter[desc->read - 1]
+ != READ_FILTER_PASS)
+ { /* FILTERed reads are not returned by 2na reader:
+ 4na readed should not ask for them */
+ *status = eVdbBlastInvalidId;
+ S
+ }
+ else if (ReaderColsIsReadCompressed(&self->cols, desc->read - 1)) {
+ /* Compressed CMP_READs are not returned by 2na reader:
+ 4na readed should not ask for them */
+ *status = eVdbBlastInvalidId; /* */
+ S
+ }
+ else {
+ if (self->blob) {
+ VBlobRelease(self->blob);
+ self->blob = NULL;
+ }
+
+ if (rc == 0 && *status == eVdbBlastNoErr) {
+ rc = VCursorGetBlobDirect
+ (self->curs, &self->blob, desc->spot, self->col_READ);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc,
+ "Error in VCursorGetBlobDirect"
+ "($(path), READ, spot=$(spot))",
+ "path=%s,spot=%ld", desc->run->path, desc->spot));
+ }
+ }
+
+ if (rc == 0 && *status == eVdbBlastNoErr) {
+ uint32_t boff = 0;
+ uint32_t elem_bits = 0;
+ uint32_t row_len = 0;
+
+ rc = VBlobCellData(self->blob, desc->spot,
+ &elem_bits, (const void**)&base, &boff, &row_len);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc, "Error in VBlobCellData"
+ "$(path), READ, spot=$(spot))",
+ "path=%s,spot=%ld", desc->run->path, desc->spot));
+ }
+ else {
+ if (elem_bits != 8) {
+ S
+ *status = eVdbBlastErr;
+ base = NULL;
+ }
+ else {
+ size_t to_read
+ = self->cols.read_len[desc->read - 1];
+
+ if (to_read < self->min_read_length) {
+ S
+ /* NOP */
+ }
+ else {
+ uint32_t start = 0;
+ to_read = _Reader2naCalcReadParams(&self->desc,
+ &self->cols, &start, self->min_read_length);
+/*
+ uint32_t offset = 0;
+ int i = 0;
+ assert(desc->run
+ && desc->read <= desc->run->rd.nReads);
+ for (i = 1; i < desc->read; ++i)
+ { offset += self->cols.read_len[i - 1]; }
+ base += boff + offset;
+ */
+ base += boff + start;
+ if (row_len >= start) {
+ row_len -= start;
+ if (to_read > row_len) {
+ S
+ *status = eVdbBlastErr;
+ }
+ else {
+ S
+ *length = to_read;
+ *status = eVdbBlastNoErr;
+ }
+ }
+ else {
+ S
+ *status = eVdbBlastErr;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+
+ if (*status == eVdbBlastNoErr) {
+ if (rc != 0)
+ { *status = eVdbBlastErr; }
+ }
+
+ return base;
+ }
+
+ return NULL;
+}
+
+/******************************************************************************/
+static const char VDB_BLAST_RUN_SET[] = "VdbBlastRunSet";
+
+struct VdbBlastRunSet {
+ KRefcount refcount;
+ bool protein;
+ VdbBlastMgr *mgr;
+
+ RunSet runs;
+
+ bool beingRead;
+ Core2na core2na;
+ Core4na core4na;
+
+ uint64_t minSeqLen;
+ uint64_t avgSeqLen;
+ uint64_t maxSeqLen;
+};
+
+static
+void _VdbBlastRunSetWhack(VdbBlastRunSet *self)
+{
+ assert(self);
+
+ STSMSG(1, ("Deleting VdbBlastRunSet(min_read_length=%d, protein=%s)",
+ self->core2na.min_read_length, self->protein ? "true" : "false"));
+
+ VdbBlastMgrRelease(self->mgr);
+
+ _RunSetFini(&self->runs);
+ _Core2naFini(&self->core2na);
+ _Core4naFini(&self->core4na);
+
+ memset(self, 0, sizeof *self);
+ free(self);
+}
+
+VdbBlastRunSet *VdbBlastMgrMakeRunSet(const VdbBlastMgr *cself,
+ uint32_t *status,
+ uint32_t min_read_length,
+ bool protein)
+{
+ rc_t rc = 0;
+ VdbBlastRunSet *obj = NULL;
+ VdbBlastMgr *self = (VdbBlastMgr*)cself;
+
+ uint32_t dummy = eVdbBlastNoErr;
+ if (status == NULL)
+ { status = &dummy; }
+
+ *status = eVdbBlastNoErr;
+
+ obj = calloc(1, sizeof *obj);
+ if (obj == NULL) {
+ *status = eVdbBlastMemErr;
+ return obj;
+ }
+
+ obj->protein = protein;
+ obj->core2na.min_read_length = min_read_length;
+ obj->core4na.min_read_length = min_read_length;
+
+ obj->minSeqLen = ~0;
+ obj->avgSeqLen = ~0;
+ obj->maxSeqLen = ~0;
+
+ if (rc == 0) {
+ rc = KLockMake(&obj->core2na.mutex);
+ if (rc != 0)
+ { LOGERR(klogInt, rc, "Error in KLockMake"); }
+ }
+ if (rc == 0) {
+ rc = KLockMake(&obj->core4na.mutex);
+ if (rc != 0)
+ { LOGERR(klogInt, rc, "Error in KLockMake"); }
+ }
+ if (rc == 0) {
+ obj->mgr = VdbBlastMgrAddRef(self);
+ if (obj->mgr) {
+ KRefcountInit(&obj->refcount,
+ 1, VDB_BLAST_RUN_SET, __func__, "set");
+ STSMSG(1, ("Created VdbBlastRunSet(min_read_length=%d, protein=%s)",
+ min_read_length, protein ? "true" : "false"));
+ return obj;
+ }
+ }
+
+ STSMSG(1, ("Error: failed to create VdbBlastRunSet"));
+ _VdbBlastRunSetWhack(obj);
+
+ *status = eVdbBlastErr;
+
+ return NULL;
+}
+
+LIB_EXPORT
+VdbBlastRunSet* CC VdbBlastRunSetAddRef(VdbBlastRunSet *self)
+{
+ if (self == NULL) {
+ STSMSG(1, ("VdbBlastRunSetAddRef(NULL)"));
+ return self;
+ }
+
+ if (KRefcountAdd(&self->refcount, VDB_BLAST_RUN_SET) == krefOkay) {
+ STSMSG(1, ("VdbBlastRunSetAddRef"));
+ return self;
+ }
+
+ STSMSG(1, ("Error: failed to VdbBlastRunSetAddRef"));
+ return NULL;
+}
+
+LIB_EXPORT
+void CC VdbBlastRunSetRelease(VdbBlastRunSet *self)
+{
+ if (self == NULL)
+ { return; }
+
+ STSMSG(1, ("VdbBlastRunSetRelease"));
+ if (KRefcountDrop(&self->refcount, VDB_BLAST_RUN_SET) != krefWhack)
+ { return; }
+
+ _VdbBlastRunSetWhack(self);
+}
+
+LIB_EXPORT
+uint32_t CC VdbBlastRunSetAddRun(VdbBlastRunSet *self,
+ const char *rundesc)
+{
+ uint32_t status = eVdbBlastNoErr;
+ const VTable *tbl = NULL;
+ BTableType type = btpUndefined;
+
+ /* allocated in _VdbBlastMgrFindNOpenTable()
+ in _RunSetAddTbl() is assigned to VdbBlastRun::path
+ freed during VdbBlastRun release */
+ char *fullpath = NULL;
+
+ if (self == NULL || self->mgr == NULL || self->beingRead) {
+ S
+ return eVdbBlastErr;
+ }
+
+ status =
+ _VdbBlastMgrFindNOpenTable(self->mgr, rundesc, &tbl, &type, &fullpath);
+ if (status) {
+ S
+ PLOGMSG(klogInfo,
+ (klogInfo, "failed to open $(rundesc)", "rundesc=%s", rundesc));
+ }
+ else {
+ S
+ PLOGMSG(klogInfo,
+ (klogInfo, "opened $(rundesc)", "rundesc=%s", rundesc));
+ status = _RunSetAddTbl(&self->runs, tbl, rundesc, type,
+ self->mgr->dir, fullpath, self->core2na.min_read_length);
+ S
+ }
+
+ return status;
+}
+
+static
+void _VdbBlastRunSetBeingRead(const VdbBlastRunSet *self)
+{
+ if (self == NULL)
+ { return; }
+ ((VdbBlastRunSet *)self)->beingRead = true;
+}
+
+LIB_EXPORT
+uint64_t CC VdbBlastRunSetGetNumSequences(const VdbBlastRunSet *self,
+ uint32_t *status)
+{
+ uint32_t dummy = eVdbBlastNoErr;
+ if (status == NULL)
+ { status = &dummy; }
+
+ if (self == NULL) {
+ *status = eVdbBlastErr;
+ return 0;
+ }
+
+ _VdbBlastRunSetBeingRead(self);
+
+ return _RunSetGetNumSequences(&self->runs, status);
+}
+
+LIB_EXPORT
+uint64_t CC VdbBlastRunSetGetNumSequencesApprox(
+ const VdbBlastRunSet *self)
+{
+ uint64_t num = 0;
+ uint32_t status = eVdbBlastNoErr;
+
+ _VdbBlastRunSetBeingRead(self);
+
+ num = _RunSetGetNumSequencesApprox(&self->runs, &status);
+
+ STSMSG(1, ("VdbBlastRunSetGetNumSequencesApprox=%lu", num));
+
+ return num;
+}
+
+LIB_EXPORT
+uint64_t CC VdbBlastRunSetGetTotalLength(const VdbBlastRunSet *self,
+ uint32_t *status)
+{
+ uint32_t dummy = eVdbBlastNoErr;
+ if (status == NULL)
+ { status = &dummy; }
+
+ if (self == NULL) {
+ *status = eVdbBlastErr;
+ return 0;
+ }
+
+ _VdbBlastRunSetBeingRead(self);
+
+ return _RunSetGetTotalLength(&self->runs, status);
+}
+
+LIB_EXPORT
+uint64_t CC VdbBlastRunSetGetTotalLengthApprox(
+ const VdbBlastRunSet *self)
+{
+ uint32_t status = eVdbBlastNoErr;
+
+ if (self == NULL) {
+ STSMSG(1, ("VdbBlastRunSetGetTotalLengthApprox(self=NULL)"));
+ return 0;
+ }
+
+ _VdbBlastRunSetBeingRead(self);
+
+ return _RunSetGetTotalLengthApprox(&self->runs, &status);
+}
+
+LIB_EXPORT
+uint64_t CC VdbBlastRunSetGetAvgSeqLen(const VdbBlastRunSet *self)
+{
+ uint64_t num = 0;
+
+ if (self == NULL) {
+ STSMSG(1, ("VdbBlastRunSetGetAvgSeqLen(self=NULL)"));
+ return 0;
+ }
+
+ if (self->avgSeqLen == ~0) {
+ uint64_t n = 0;
+ _VdbBlastRunSetBeingRead(self);
+
+ n = VdbBlastRunSetGetNumSequencesApprox(self);
+ if (n != 0) {
+ num = VdbBlastRunSetGetTotalLengthApprox(self) / n;
+ }
+ else {
+ num = n;
+ }
+ ((VdbBlastRunSet*)self)->avgSeqLen = num;
+ }
+
+ STSMSG(1, ("VdbBlastRunSetGetAvgSeqLen = %ld", num));
+ return self->avgSeqLen;
+}
+
+LIB_EXPORT
+size_t CC VdbBlastRunSetGetName(const VdbBlastRunSet *self,
+ uint32_t *status,
+ char *name_buffer,
+ size_t bsize)
+{
+ size_t sz = 0;
+
+ uint32_t dummy = eVdbBlastNoErr;
+ if (status == NULL)
+ { status = &dummy; }
+
+ *status = eVdbBlastErr;
+
+ if (self == NULL)
+ { return 0; }
+
+ _VdbBlastRunSetBeingRead(self);
+
+ sz = _RunSetGetName(&self->runs, status, name_buffer, bsize);
+
+ STSMSG(1, ("VdbBlastRunSetGetName = '%.*s'", bsize, name_buffer));
+
+ return sz;
+}
+
+LIB_EXPORT
+bool CC VdbBlastRunSetIsProtein(const VdbBlastRunSet *self)
+{
+ if (self == NULL) {
+ STSMSG(1, ("VdbBlastRunSetIsProtein(self=NULL)"));
+ return false;
+ }
+ STSMSG(1, (
+ "VdbBlastRunSetIsProtein = %s", self->protein ? "true" : "false"));
+ return self->protein;
+}
+
+LIB_EXPORT
+time_t CC VdbBlastRunSetLastUpdatedDate(const VdbBlastRunSet *self)
+{
+ _VdbBlastRunSetBeingRead(self);
+ return _NotImplemented(__func__);
+}
+
+LIB_EXPORT
+size_t CC VdbBlastRunSetGetReadName(const VdbBlastRunSet *self,
+ uint64_t read_id, /* 0-based in RunSet */
+ char *name_buffer,
+ size_t bsize)
+{
+ rc_t rc = 0;
+ uint32_t status = eVdbBlastNoErr;
+ size_t need = 0;
+ size_t num_writ = 0;
+
+ ReadDesc desc;
+ memset(&desc, 0, sizeof desc);
+
+ if (name_buffer && bsize)
+ { name_buffer[0] = '\0'; }
+
+ if (self == NULL) {
+ STSMSG(1, ("VdbBlastRunSetGetReadName(self=NULL)"));
+ return 0;
+ }
+
+ _VdbBlastRunSetBeingRead(self);
+
+ status = _RunSetFindReadDesc(&self->runs, read_id, &desc);
+ if (status != eVdbBlastNoErr) {
+ STSMSG(1, ("Error: failed to VdbBlastRunSetGetReadName: "
+ "cannot find RunSet ReadDesc"));
+ return 0;
+ }
+
+ assert(desc.run && desc.run->path && desc.run->acc && desc.spot
+ && desc.read);
+
+ if (desc.run->type == btpUndefined) {
+ desc.run->type
+ = _VdbBlastMgrBTableTypeFromPath(self->mgr, desc.run->path);
+ assert(desc.run->type != btpUndefined);
+ }
+ if (desc.run->type == btpWGS) {
+ if (desc.read != 1) {
+ STSMSG(1, ("Error: failed to VdbBlastRunSetGetReadName: "
+ "Unexpected read='%u' for run '%s', spot='%lu'",
+ desc.read, desc.run->path, desc.spot));
+ return 0;
+ }
+ status = _VdbBlastRunGetWgsAccession(
+ desc.run, desc.spot, name_buffer, bsize, &need);
+ if (status != eVdbBlastNoErr)
+ { need = 0; }
+ return need;
+ }
+ else if (desc.run->type == btpREFSEQ) {
+ rc = string_printf(name_buffer, bsize, &num_writ, "%s", desc.run->acc);
+ if (rc == 0) {
+ S
+ need = num_writ;
+ }
+ else if (GetRCObject(rc) == (enum RCObject)rcBuffer
+ && GetRCState(rc) == rcInsufficient)
+ {
+ size_t size;
+ S
+ need = string_measure(desc.run->acc, &size) + 1;
+ }
+ }
+ else {
+ rc = string_printf(name_buffer, bsize, &num_writ,
+ "%s.%lu.%u", desc.run->acc, desc.spot, desc.read);
+ if (rc == 0) {
+ S
+ need = num_writ;
+ }
+ else if (GetRCObject(rc) == (enum RCObject)rcBuffer
+ && GetRCState(rc) == rcInsufficient)
+ {
+ int i = 0;
+ size_t size;
+ S
+ need = string_measure(desc.run->acc, &size) + 2;
+ i = desc.spot;
+ while (i > 0) {
+ ++need;
+ i /= 10;
+ }
+ i = desc.read;
+ while (i > 0) {
+ ++need;
+ i /= 10;
+ }
+ }
+ else
+ { LOGERR(klogInt, rc, "Unexpecter error in string_printf"); }
+ }
+
+ STSMSG(1, ("VdbBlastRunSetGetName = '%.*s'", bsize, name_buffer));
+ return need;
+}
+
+LIB_EXPORT
+uint32_t CC VdbBlastRunSetGetReadId(const VdbBlastRunSet *self,
+ const char *name_buffer,
+ size_t bsize,
+ uint64_t *read_id)
+{
+ uint32_t status = eVdbBlastNoErr;
+ bool found = false;
+
+ uint64_t result = 0;
+ char *acc = NULL;
+ uint64_t spot = 0;
+ uint32_t read = 0;
+ uint32_t i = ~0;
+ if (self == NULL || name_buffer == NULL || name_buffer[0] == '\0' ||
+ bsize == 0 || read_id == 0)
+ { return eVdbBlastErr; }
+
+ {
+ size_t n = bsize;
+ const char *end = name_buffer + bsize;
+ char *dot2 = NULL;
+ char *dot1 = memchr(name_buffer, '.', bsize);
+ if (dot1 != NULL) {
+ if (dot1 == name_buffer)
+ { return eVdbBlastErr; }
+ if (dot1 - name_buffer + 1 >= bsize)
+ { return eVdbBlastErr; }
+ n -= (dot1 - name_buffer + 1);
+ dot2 = memchr(dot1 + 1, '.', n);
+ if (dot2 != NULL) {
+ if (dot2 - name_buffer + 1 >= bsize)
+ { return eVdbBlastErr; }
+ acc = string_dup(name_buffer, dot1 - name_buffer + 1);
+ if (acc == NULL)
+ { return eVdbBlastMemErr; }
+ acc[dot1 - name_buffer] = '\0';
+ while (++dot1 < dot2) {
+ char c = *dot1;
+ if (c < '0' || c > '9') {
+ S
+ status = eVdbBlastErr;
+ break;
+ }
+ spot = spot * 10 + c - '0';
+ }
+ while (status == eVdbBlastNoErr && ++dot2 < end) {
+ char c = *dot2;
+ if (c < '0' || c > '9') {
+ S
+ status = eVdbBlastErr;
+ break;
+ }
+ read = read * 10 + c - '0';
+ }
+ }
+ else {
+ acc = malloc(bsize + 1);
+ if (acc == NULL)
+ { return eVdbBlastMemErr; }
+ string_copy(acc, bsize + 1, name_buffer, bsize);
+ acc[bsize] = '\0';
+ }
+ }
+ else {
+ acc = malloc(bsize + 1);
+ if (acc == NULL)
+ { return eVdbBlastMemErr; }
+ string_copy(acc, bsize + 1, name_buffer, bsize);
+ acc[bsize] = '\0';
+ }
+ }
+
+ for (i = 0; i < self->runs.krun && status == eVdbBlastNoErr; ++i) {
+ uint64_t id = ~0;
+ VdbBlastRun *run = self->runs.run + i;
+ size_t size;
+ assert(run && run->acc);
+ if (string_measure(run->acc, &size) == string_measure(acc, &size)) {
+ if (strcmp(run->acc, acc) == 0) {
+ status = _VdbBlastRunGetReadId(run, acc, spot, read, &id);
+ if (status == eVdbBlastNoErr) {
+ *read_id = result + id;
+ found = true;
+ }
+ break;
+ }
+ }
+ else if ((string_measure(run->acc, &size) < string_measure(acc, &size))
+ && (run->type == btpWGS)
+ && (memcmp(run->acc, acc, string_measure(run->acc, &size)) == 0))
+ {
+ status = _VdbBlastRunGetReadId(run, acc, spot, read, &id);
+ if (status == eVdbBlastNoErr) {
+ *read_id = result + id;
+ found = true;
+ }
+ break;
+ }
+ result += _VdbBlastRunGetNumSequences(run, &status);
+ if (status != eVdbBlastNoErr) {
+ if (status == eVdbBlastTooExpensive) {
+ status = eVdbBlastNoErr;
+ }
+ else {
+ break;
+ }
+ }
+ }
+
+ if (status == eVdbBlastNoErr && !found) {
+ S
+ status = eVdbBlastErr;
+ }
+
+ free (acc);
+ acc = NULL;
+
+ return status;
+}
+
+/* TODO: make sure
+ ReadLength is correct when there are multiple reads in the same spot */
+LIB_EXPORT
+uint64_t CC VdbBlastRunSetGetReadLength(const VdbBlastRunSet *self,
+ uint64_t read_id)
+{
+ rc_t rc = 0;
+ const VCursor *curs = NULL;
+ uint32_t col_idx = 0;
+ char buffer[84] = "";
+ uint32_t row_len = 0;
+ ReadDesc desc;
+ uint32_t status = eVdbBlastErr;
+
+ if (self == NULL) {
+ STSMSG(1, ("VdbBlastRunSetGetReadLength(self=NULL)"));
+ return 0;
+ }
+
+ status = _RunSetFindReadDesc(&self->runs, read_id, &desc);
+ if (status != eVdbBlastNoErr) {
+ STSMSG(1, ("Error: failed to VdbBlastRunSetGetReadLength: "
+ "cannot find RunSet ReadDesc"));
+ return 0;
+ }
+ assert(desc.run && desc.spot && desc.run->path);
+
+ _VdbBlastRunSetBeingRead(self);
+
+ if (rc == 0) {
+ rc = _VTableMakeCursor(desc.run->tbl, &curs, &col_idx, "READ");
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc, "Error in _VTableMakeCursor"
+ "$(path), READ)", "path=%s", desc.run->path));
+ }
+ }
+ if (rc == 0) {
+ rc = VCursorReadDirect
+ (curs, desc.spot, col_idx, 8, buffer, sizeof buffer, &row_len);
+ if (rc != 0) {
+ PLOGERR(klogInt, (klogInt, rc, "Error in VCursorReadDirect"
+ "$(path), READ, spot=$(spot))",
+ "path=%s,spot=%ld", desc.run->path, desc.spot));
+ }
+ }
+ VCursorRelease(curs);
+ curs = NULL;
+ if (rc == 0) {
+ STSMSG(1, ("VdbBlastRunSetGetReadLength = %ld", row_len));
+ return row_len;
+ }
+ else {
+ STSMSG(1, ("Error: failed to VdbBlastRunSetGetReadLength"));
+ return 0;
+ }
+}
+
+static
+uint64_t _VdbBlastRunSet2naRead(const VdbBlastRunSet *self,
+ uint32_t *status,
+ uint64_t *read_id,
+ size_t *starting_base,
+ uint8_t *buffer,
+ size_t buffer_size)
+{
+ uint64_t n = 0;
+ rc_t rc = 0;
+ assert(self && status);
+ rc = KLockAcquire(self->core2na.mutex);
+ if (rc != 0) {
+ LOGERR(klogInt, rc, "Error in KLockAcquire");
+ }
+ else {
+ n = _Core2naRead((Core2na*)&self->core2na, &self->runs,
+ status, read_id, starting_base, buffer, buffer_size);
+ if (n == 0 && self->core2na.eos) {
+ *read_id = ~0;
+ }
+ rc = KLockUnlock(self->core2na.mutex);
+ if (rc != 0) {
+ LOGERR(klogInt, rc, "Error in KLockUnlock");
+ }
+ }
+ if (rc) {
+ *status = eVdbBlastErr;
+ }
+ if (*status == eVdbBlastNoErr) {
+ if (read_id != NULL && starting_base != NULL) {
+ STSMSG(3, (
+ "VdbBlast2naReaderRead(read_id=%ld, starting_base=%ld) = %ld",
+ *read_id, *starting_base, n));
+ }
+ else {
+ STSMSG(2, ("VdbBlast2naReaderRead = %ld", n));
+ }
+ }
+ else {
+ if (read_id != NULL && starting_base != NULL) {
+ STSMSG(1, ("Error: failed to "
+ "VdbBlast2naReaderRead(read_id=%ld, starting_base=%ld)", n));
+ }
+ else {
+ STSMSG(1, ("Error: failed to VdbBlast2naReaderRead"));
+ }
+ }
+ return n;
+}
+
+/******************************************************************************/
+static const char VDB_BLAST_2NA_READER[] = "VdbBlast2naReader";
+
+struct VdbBlast2naReader {
+ KRefcount refcount;
+ VdbBlastRunSet *set;
+ Data2na data;
+};
+
+static
+VdbBlast2naReader *_VdbBlastRunSetMake2naReader(VdbBlastRunSet *self,
+ uint32_t *status,
+ uint64_t initial_read_id,
+ Core2na *core2na)
+{
+ VdbBlast2naReader *obj = NULL;
+ assert(self && status);
+ if (core2na == NULL) {
+ core2na = &self->core2na;
+ }
+ else {
+ core2na->initial_read_id = initial_read_id;
+ }
+ if (!core2na->hasReader) {
+ *status = _Core2naOpen1stRead(core2na, &self->runs, initial_read_id);
+ if (*status != eVdbBlastNoErr) {
+ STSMSG(1, ("Error: failed to create VdbBlast2naReader: "
+ "cannot open the first read"));
+ return NULL;
+ }
+ _VdbBlastRunSetBeingRead(self);
+ core2na->initial_read_id = initial_read_id;
+ core2na->hasReader = true;
+ }
+ else if (core2na->initial_read_id != initial_read_id) {
+ STSMSG(1, ("Error: failed to create VdbBlast2naReader"
+ "(initial_read_id=%ld): allowed initial_read_id=%ld",
+ initial_read_id, core2na->initial_read_id));
+ *status = eVdbBlastErr;
+ return NULL;
+ }
+ obj = calloc(1, sizeof *obj);
+ if (obj == NULL) {
+ *status = eVdbBlastMemErr;
+ return NULL;
+ }
+
+ obj->set = VdbBlastRunSetAddRef((VdbBlastRunSet*)self);
+
+ KRefcountInit(&obj->refcount, 1,
+ VDB_BLAST_2NA_READER, __func__, "2naReader");
+
+ *status = eVdbBlastNoErr;
+
+ return obj;
+}
+
+LIB_EXPORT
+VdbBlast2naReader* CC VdbBlastRunSetMake2naReader(const VdbBlastRunSet *self,
+ uint32_t *status,
+ uint64_t initial_read_id)
+{
+ VdbBlast2naReader *obj = NULL;
+
+ uint32_t dummy = eVdbBlastNoErr;
+ if (status == NULL)
+ { status = &dummy; }
+
+ if (self) {
+ rc_t rc = KLockAcquire(self->core2na.mutex);
+ if (rc != 0)
+ { LOGERR(klogInt, rc, "Error in KLockAcquire"); }
+ else {
+ obj = _VdbBlastRunSetMake2naReader
+ ((VdbBlastRunSet*)self, status, initial_read_id, NULL);
+ rc = KLockUnlock(self->core2na.mutex);
+ if (rc != 0) {
+ LOGERR(klogInt, rc, "Error in KLockUnlock");
+ VdbBlast2naReaderRelease(obj);
+ obj = NULL;
+ }
+ }
+ if (rc != 0) {
+ *status = eVdbBlastErr;
+ }
+ }
+ else {
+ *status = eVdbBlastErr;
+ }
+
+ if (obj != NULL) {
+ STSMSG(1, (
+ "Created VdbBlast2naReader(initial_read_id=%ld)", initial_read_id));
+ }
+ else {
+ STSMSG(1, ("Error: failed to create "
+ "VdbBlast2naReader(initial_read_id=%ld)", initial_read_id));
+ }
+
+ return obj;
+}
+
+LIB_EXPORT
+VdbBlast2naReader* CC VdbBlast2naReaderAddRef(VdbBlast2naReader *self)
+{
+ if (self == NULL) {
+ STSMSG(1, ("VdbBlast2naReaderAddRef(NULL)"));
+ return self;
+ }
+
+ if (KRefcountAdd(&self->refcount, VDB_BLAST_2NA_READER)
+ == krefOkay)
+ {
+ STSMSG(1, ("VdbBlast2naReaderAddRef"));
+ return self;
+ }
+
+ STSMSG(1, ("Error: failed to VdbBlast2naReaderAddRef"));
+ return NULL;
+}
+
+static
+void _VdbBlast2naReaderWhack(VdbBlast2naReader *self)
+{
+ if (self == NULL)
+ { return; }
+
+ if (self->set != NULL) {
+ STSMSG(1, ("Deleting VdbBlast2naReader(initial_read_id=%ld)",
+ self->set->core2na.initial_read_id));
+ }
+ else {
+ STSMSG(1, ("Deleting VdbBlast2naReader(self->set=NULL)",
+ self->set->core2na.initial_read_id));
+ }
+
+ VBlobRelease(self->data.blob);
+ VdbBlastRunSetRelease(self->set);
+
+ memset(self, 0, sizeof *self);
+
+ free(self);
+}
+
+LIB_EXPORT
+void CC VdbBlast2naReaderRelease(VdbBlast2naReader *self)
+{
+ if (self == NULL)
+ { return; }
+
+ STSMSG(1, ("VdbBlast2naReaderRelease"));
+ if (KRefcountDrop(&self->refcount, VDB_BLAST_2NA_READER) != krefWhack)
+ { return; }
+
+ _VdbBlast2naReaderWhack(self);
+}
+
+LIB_EXPORT
+uint64_t CC _VdbBlast2naReaderRead(const VdbBlast2naReader *self,
+ uint32_t *status,
+ uint64_t *read_id,
+ size_t *starting_base,
+ uint8_t *buffer,
+ size_t buffer_size)
+{
+ uint32_t dummy = eVdbBlastNoErr;
+ if (status == NULL)
+ { status = &dummy; }
+
+ if (self == NULL) {
+ *status = eVdbBlastErr;
+ return 0;
+ }
+
+ return _VdbBlastRunSet2naRead(self->set,
+ status, read_id, starting_base, buffer, buffer_size);
+}
+
+LIB_EXPORT
+uint64_t CC VdbBlast2naReaderRead(const VdbBlast2naReader *self,
+ uint32_t *status,
+ uint64_t *read_id,
+ uint8_t *buffer,
+ size_t buffer_size)
+{
+ size_t starting_base = 0;
+
+ return _VdbBlast2naReaderRead(self,
+ status, read_id, &starting_base, buffer, buffer_size);
+}
+
+LIB_EXPORT
+uint32_t CC VdbBlast2naReaderData(VdbBlast2naReader *self,
+ uint32_t *status,
+ Packed2naRead *buffer,
+ uint32_t buffer_length)
+{
+ bool verbose = false;
+ uint32_t n = 0;
+ rc_t rc = 0;
+
+ uint32_t dummy = eVdbBlastNoErr;
+ if (status == NULL)
+ { status = &dummy; }
+
+ *status = eVdbBlastErr;
+
+ if (self == NULL)
+ { return 0; }
+
+ if ((buffer_length != 0 && buffer == NULL) || (buffer_length == 0))
+ { return 0; }
+
+ *status = eVdbBlastNoErr;
+
+ assert(self->set);
+
+ rc = KLockAcquire(self->set->core2na.mutex);
+ if (rc != 0)
+ { LOGERR(klogInt, rc, "Error in KLockAcquire"); }
+ if (0 && verbose) {
+ char b[256];
+ string_printf(b, sizeof b, NULL, "KLockAcquire(%p)\n",
+ self->set->core2na.mutex);
+ assert(!rc);
+ fprintf(stderr, "%s", b);
+ fflush(stderr);
+ }
+ if (rc == 0) {
+ n = _Core2naData((Core2na*)&self->set->core2na, &self->data,
+ &self->set->runs, status, buffer, buffer_length);
+ S
+ if (n > 0 && verbose)
+ { _Packed2naReadPrint(buffer, self->data.blob); }
+ if (0 && verbose) {
+ char b[256];
+ string_printf(b, sizeof b, NULL, "KLockUnlock(%p)\n",
+ self->set->core2na.mutex);
+ assert(!rc);
+ fprintf(stderr, "%s", b);
+ fflush(stderr);
+ }
+ rc = KLockUnlock(self->set->core2na.mutex);
+ if (rc != 0)
+ { LOGERR(klogInt, rc, "Error in KLockUnlock"); }
+ }
+ if (rc)
+ { *status = eVdbBlastErr; }
+
+ S
+ return n;
+}
+
+static uint64_t _VdbBlastRunScan(const VdbBlastRun *self,
+ uint64_t (*cmp)
+ (uint64_t cand, uint64_t champ, int64_t minRead, bool *done),
+ uint64_t minRead, uint64_t start, uint32_t *status)
+{
+ uint64_t res = start;
+ uint64_t bad = start;
+ uint64_t spot = 0;
+ bool done = false;
+ rc_t rc = 0;
+ const VCursor *curs = NULL;
+ uint32_t idx = 0;
+ assert(self && status &&
+ (self->rd.spotCount || self->rd.readType ||
+ self->rd.nReads || self->rd.nBioReads));
+ rc = _VTableMakeCursor(self->tbl, &curs, &idx, "READ_LEN");
+ if (rc != 0) {
+ return bad;
+ }
+ for (spot = 1;
+ spot <= self->rd.spotCount && *status == eVdbBlastNoErr && !done;
+ ++spot)
+ {
+ uint32_t elem_bits, elem_off, elem_cnt;
+ const void *base = NULL;
+ rc = VCursorCellDataDirect(curs, spot, idx,
+ &elem_bits, &base, &elem_off, &elem_cnt);
+ if (rc != 0) {
+ *status = eVdbBlastErr;
+ PLOGMSG(klogInfo, (klogInfo,
+ "$(f): Cannot '$(name)' CellDataDirect",
+ "f=%s,name=%s", __func__, "READ_LEN"));
+ res = bad;
+ break;
+ }
+ else if (elem_off != 0 || elem_bits != 32) {
+ *status = eVdbBlastErr;
+ PLOGERR(klogInt, (klogInt, rc,
+ "Bad VCursorCellDataDirect(READ_LEN) result: "
+ "boff=$(elem_off), elem_bits=$(elem_bits)",
+ "elem_off=%u,elem_bits=%u", elem_off, elem_bits));
+ res = bad;
+ break;
+ }
+ else {
+ uint8_t read = 0;
+ const uint32_t *readLen = base;
+ assert(self->rd.readType && self->rd.readLen);
+ assert(self->rd.nReads == elem_cnt);
+ for (read = 0; read < self->rd.nReads; ++read) {
+ if (self->rd.readType[read] & SRA_READ_TYPE_BIOLOGICAL) {
+ res = cmp(readLen[read], res, minRead, &done);
+ }
+ }
+ }
+ }
+ RELEASE(VCursor, curs);
+ return res;
+}
+
+/*static
+uint64_t CC _VdbBlastRunSetGetSomeSeqLen2(const VdbBlastRunSet *self, bool max)
+{
+ uint64_t num = max ? 0 : ~0;
+ bool done = false;
+ Packed2naRead buffer[1024];
+ uint32_t status = eVdbBlastNoErr;
+ VdbBlast2naReader* r = NULL;
+
+ Core2na core2na;
+ memset(&core2na, 0, sizeof core2na);
+
+ _VdbBlastRunSetBeingRead(self);
+
+ r = _VdbBlastRunSetMake2naReader(
+ (VdbBlastRunSet*)self, &status, 0, &core2na);
+ while (status == eVdbBlastNoErr) {
+ uint32_t i = 0;
+ uint32_t n = _Core2naData(&core2na, &r->data,
+ &self->runs, &status, buffer, sizeof buffer / sizeof buffer[0]);
+ if (status != eVdbBlastNoErr) {
+ num = max ? 0 : ~0;
+ break;
+ }
+ if (n == 0) {
+ break;
+ }
+ for (i = 0; i < n; ++i) {
+ if (max) {
+ if (num < buffer[i].length_in_bases) {
+ num = buffer[i].length_in_bases;
+ }
+ }
+ else {
+ if (num > buffer[i].length_in_bases) {
+ num = buffer[i].length_in_bases;
+ if (num > 0 && num - 1 == r->set->core2na.min_read_length) {
+ done = true;
+ break;
+ }
+ }
+ }
+ }
+ if (done) {
+ break;
+ }
+ }
+ _Core2naFini(&core2na);
+ VdbBlast2naReaderRelease(r);
+ return num;
+}*/
+
+static
+uint64_t CC Min(uint64_t cand,
+ uint64_t champ, int64_t minRead, bool *done)
+{
+ assert(done);
+ if (minRead >= 0) {
+ if (cand < minRead) {
+ return champ;
+ }
+ else if (cand == minRead) {
+ *done = true;
+ return minRead;
+ }
+ }
+ return cand < champ ? cand : champ;
+}
+
+static
+uint64_t CC Max(uint64_t cand,
+ uint64_t champ, int64_t minRead, bool *done)
+{
+ return cand > champ ? cand : champ;
+}
+
+/*static
+uint64_t CC Sum(uint64_t cand, uint64_t champ, int64_t minRead, bool *done)
+{
+ return cand + champ;
+}*/
+
+LIB_EXPORT
+uint64_t CC VdbBlastRunSetGetMinSeqLen(const VdbBlastRunSet *self)
+{
+ if (self->minSeqLen == ~0) {
+ bool empty = true;
+ uint32_t status = eVdbBlastNoErr;
+ uint64_t res = ~0;
+ uint32_t i = 0;
+ _VdbBlastRunSetBeingRead(self);
+ for (i = 0; i < self->runs.krun; ++i) {
+ VdbBlastRun *run = &self->runs.run[i];
+ assert(run);
+ if (run->type == btpREFSEQ) {
+ uint64_t cand = _VdbBlastRunGetLengthApprox(run, &status);
+ if (status != eVdbBlastNoErr) {
+ S
+ return ~0;
+ }
+ if (cand < res && cand >= self->core2na.min_read_length) {
+ res = cand;
+ }
+ }
+ else {
+ status = _VdbBlastRunFillRunDesc(run);
+ if (status != eVdbBlastNoErr) {
+ S
+ return ~0;
+ }
+ if (!run->rd.varReadLen) {
+ uint8_t read = 0;
+ assert(run->rd.readType && run->rd.readLen);
+ for (read = 0; read < run->rd.nReads; ++read) {
+ if (run->rd.readType[i] & SRA_READ_TYPE_BIOLOGICAL) {
+ if (run->rd.readLen[i]
+ == self->core2na.min_read_length)
+ {
+ ((VdbBlastRunSet*)self)->minSeqLen
+ = self->core2na.min_read_length;
+ return self->minSeqLen;
+ }
+ else if (run->rd.readLen[i]
+ > self->core2na.min_read_length
+ && run->rd.readLen[i] < res)
+ {
+ res = run->rd.readLen[i];
+ empty = false;
+ }
+ }
+ }
+ }
+ else {
+ res = _VdbBlastRunScan(
+ run, Min, self->core2na.min_read_length, res, &status);
+ if (status != eVdbBlastNoErr) {
+ S
+ return ~0;
+ }
+ }
+ }
+ }
+ if (empty && res == ~0) {
+ res = 0;
+ }
+ ((VdbBlastRunSet*)self)->minSeqLen = res;
+ }
+ return self->minSeqLen;
+}
+LIB_EXPORT
+uint64_t CC VdbBlastRunSetGetMaxSeqLen(const VdbBlastRunSet *self)
+{
+ if (self->maxSeqLen == ~0) {
+ uint32_t status = eVdbBlastNoErr;
+ uint64_t res = 0;
+ uint32_t i = 0;
+ _VdbBlastRunSetBeingRead(self);
+ for (i = 0; i < self->runs.krun; ++i) {
+ VdbBlastRun *run = &self->runs.run[i];
+ assert(run);
+ if (run->type == btpREFSEQ) {
+ uint64_t cand = _VdbBlastRunGetLengthApprox(run, &status);
+ if (status != eVdbBlastNoErr) {
+ S
+ return ~0;
+ }
+ if (cand > res) {
+ res = cand;
+ }
+ }
+ else {
+ status = _VdbBlastRunFillRunDesc(run);
+ if (status != eVdbBlastNoErr) {
+ S
+ return ~0;
+ }
+ if (!run->rd.varReadLen) {
+ uint8_t read = 0;
+ assert(run->rd.readType && run->rd.readLen);
+ for (read = 0; read < run->rd.nReads; ++read) {
+ if (run->rd.readType[i] & SRA_READ_TYPE_BIOLOGICAL) {
+ if (run->rd.readLen[i] > res) {
+ res = run->rd.readLen[i];
+ }
+ }
+ }
+ }
+ else {
+ res = _VdbBlastRunScan(
+ run, Max, -1, res, &status);
+ if (status != eVdbBlastNoErr) {
+ S
+ return ~0;
+ }
+ }
+ }
+ }
+ ((VdbBlastRunSet*)self)->maxSeqLen = res;
+ }
+ return self->maxSeqLen;
+}
+
+/******************************************************************************/
+static const char VDB_BLAST_4NA_READER[] = "VdbBlast4naReader";
+
+struct VdbBlast4naReader {
+ KRefcount refcount;
+ VdbBlastRunSet *set;
+};
+
+LIB_EXPORT
+VdbBlast4naReader* CC VdbBlastRunSetMake4naReader(const VdbBlastRunSet *self,
+ uint32_t *status)
+{
+ uint32_t dummy = eVdbBlastNoErr;
+ if (status == NULL) {
+ status = &dummy;
+ }
+
+ if (self) {
+ VdbBlast4naReader *obj = calloc(1, sizeof *obj);
+ if (obj == NULL) {
+ *status = eVdbBlastMemErr;
+ return NULL;
+ }
+
+ obj->set = VdbBlastRunSetAddRef((VdbBlastRunSet*)self);
+
+ KRefcountInit(&obj->refcount, 1,
+ VDB_BLAST_4NA_READER, __func__, "4naReader");
+
+ _VdbBlastRunSetBeingRead(self);
+
+ *status = eVdbBlastNoErr;
+
+ STSMSG(1, ("Created VdbBlast4naReader"));
+
+ return obj;
+ }
+ else {
+ *status = eVdbBlastErr;
+
+ STSMSG(1, ("VdbBlastRunSetMake4naReader(self=NULL)"));
+
+ return NULL;
+ }
+}
+
+LIB_EXPORT
+VdbBlast4naReader* CC VdbBlast4naReaderAddRef(VdbBlast4naReader *self)
+{
+ if (self == NULL) {
+ STSMSG(1, ("VdbBlast4naReaderAddRef(NULL)"));
+ return self;
+ }
+
+ if (KRefcountAdd(&self->refcount, VDB_BLAST_4NA_READER)
+ == krefOkay)
+ {
+ STSMSG(1, ("VdbBlast4naReaderAddRef"));
+ return self;
+ }
+
+ STSMSG(1, ("Error: failed to VdbBlast4naReaderAddRef"));
+ return NULL;
+}
+
+LIB_EXPORT
+void CC VdbBlast4naReaderRelease(VdbBlast4naReader *self)
+{
+ if (self == NULL)
+ { return; }
+
+ STSMSG(1, ("VdbBlast4naReaderRelease"));
+ if (KRefcountDrop(&self->refcount, VDB_BLAST_4NA_READER) != krefWhack)
+ { return; }
+
+ STSMSG(1, ("Deleting VdbBlast4naReader"));
+
+ VdbBlastRunSetRelease(self->set);
+
+ memset(self, 0, sizeof *self);
+ free(self);
+}
+
+LIB_EXPORT
+size_t CC VdbBlast4naReaderRead(const VdbBlast4naReader *self,
+ uint32_t *status,
+ uint64_t read_id,
+ size_t starting_base,
+ uint8_t *buffer,
+ size_t buffer_length)
+{
+ size_t n = 0;
+ rc_t rc = 0;
+
+ uint32_t dummy = eVdbBlastNoErr;
+ if (status == NULL)
+ { status = &dummy; }
+
+ if (self == NULL) {
+ S
+ *status = eVdbBlastErr;
+ return 0;
+ }
+
+ assert(self->set);
+
+ rc = KLockAcquire(self->set->core4na.mutex);
+ if (rc != 0)
+ { LOGERR(klogInt, rc, "Error in KLockAcquire"); }
+ else {
+ n = _Core4naRead(&self->set->core4na, &self->set->runs,
+ status, read_id, starting_base, buffer, buffer_length);
+ rc = KLockUnlock(self->set->core4na.mutex);
+ if (rc != 0)
+ { LOGERR(klogInt, rc, "Error in KLockUnlock"); }
+ }
+ if (rc != 0)
+ { *status = eVdbBlastErr; }
+
+ if (*status == eVdbBlastNoErr) {
+ STSMSG(3, (
+ "VdbBlast4naReaderRead(read_id=%ld, starting_base=%ld) = %ld",
+ read_id, starting_base, n));
+ }
+ else {
+ STSMSG(2, ("Error: failed to "
+ "VdbBlast4naReaderRead(read_id=%ld, starting_base=%ld)",
+ read_id, starting_base));
+ }
+
+ return n;
+}
+
+LIB_EXPORT
+const uint8_t* CC VdbBlast4naReaderData(const VdbBlast4naReader *self,
+ uint32_t *status,
+ uint64_t read_id,
+ size_t *length)
+{
+ const uint8_t *d = NULL;
+ rc_t rc = 0;
+
+ uint32_t dummy = eVdbBlastNoErr;
+ if (status == NULL)
+ { status = &dummy; }
+
+ if (self == NULL || length == NULL) {
+ if (self == NULL)
+ { STSMSG(1, ("VdbBlast4naReaderData(self=NULL)")); }
+ if (length == NULL)
+ { STSMSG(1, ("VdbBlast4naReaderData(length=NULL)")); }
+ *status = eVdbBlastErr;
+ return 0;
+ }
+
+ assert(self->set);
+
+ rc = KLockAcquire(self->set->core4na.mutex);
+ if (rc != 0)
+ { LOGERR(klogInt, rc, "Error in KLockAcquire"); }
+ else {
+ d = _Core4naData(( Core4na*)&self->set->core4na,
+ &self->set->runs, status, read_id, length);
+ rc = KLockUnlock(self->set->core4na.mutex);
+ if (rc != 0)
+ { LOGERR(klogInt, rc, "Error in KLockUnlock"); }
+ }
+ if (rc)
+ { *status = eVdbBlastErr; }
+
+ if (*status == eVdbBlastNoErr) {
+ STSMSG(3, ("VdbBlast4naReaderData(read_id=%ld, length=%ld)",
+ read_id, *length));
+ }
+ else {
+ STSMSG(1, ("Error: failed to VdbBlast4naReaderData(read_id=%ld)",
+ read_id));
+ }
+
+ return d;
+}
+
+/******************************************************************************/
+static const char VDB_BLAST_AA_READER[] = "VdbBlastStdaaReader";
+
+struct VdbBlastStdaaReader {
+ KRefcount refcount;
+};
+
+LIB_EXPORT
+VdbBlastStdaaReader* CC VdbBlastRunSetMakeStdaaReader(
+ const VdbBlastRunSet *self,
+ uint32_t *status)
+{
+ VdbBlastStdaaReader *obj = NULL;
+
+ uint32_t dummy = eVdbBlastNoErr;
+ if (status == NULL)
+ { status = &dummy; }
+
+ obj = calloc(1, sizeof *obj);
+ if (obj == NULL) {
+ *status = eVdbBlastMemErr;
+ STSMSG(1, ("Error: failed to create VdbBlastStdaaReader"));
+ return NULL;
+ }
+
+ KRefcountInit(&obj->refcount, 1, VDB_BLAST_AA_READER, __func__, "aaReader");
+
+ _VdbBlastRunSetBeingRead(self);
+
+ *status = eVdbBlastNoErr;
+
+ STSMSG(1, ("Created VdbBlastStdaaReader"));
+
+ return obj;
+}
+
+LIB_EXPORT
+VdbBlastStdaaReader* CC VdbBlastStdaaReaderAddRef(
+ VdbBlastStdaaReader *self)
+{
+ if (self == NULL) {
+ STSMSG(1, ("VdbBlastStdaaReaderAddRef(NULL)"));
+ return self;
+ }
+
+ if (KRefcountAdd(&self->refcount, VDB_BLAST_AA_READER) == krefOkay) {
+ STSMSG(1, ("VdbBlastStdaaReaderAddRef"));
+ return self;
+ }
+
+ STSMSG(1, ("Error: failed to VdbBlastStdaaReaderAddRef"));
+ return NULL;
+}
+
+LIB_EXPORT
+void CC VdbBlastStdaaReaderRelease(VdbBlastStdaaReader *self)
+{
+ if (self == NULL)
+ { return; }
+
+ STSMSG(1, ("VdbBlastStdaaReaderRelease"));
+ if (KRefcountDrop(&self->refcount, VDB_BLAST_AA_READER) != krefWhack)
+ { return; }
+
+ STSMSG(1, ("Deleting VdbBlastStdaaReader"));
+ free(self);
+ memset(self, 0, sizeof *self);
+}
+
+LIB_EXPORT
+size_t CC VdbBlastStdaaReaderRead(const VdbBlastStdaaReader *self,
+ uint32_t *status,
+ uint64_t pig,
+ uint8_t *buffer,
+ size_t buffer_length)
+{ return _NotImplemented(__func__); }
+
+LIB_EXPORT
+const uint8_t* CC VdbBlastStdaaReaderData(const VdbBlastStdaaReader *self,
+ uint32_t *status,
+ uint64_t pig,
+ size_t *length)
+{ return _NotImplementedP(__func__); }
+
+/* EOF */
diff --git a/libs/kapp/args_debug.h b/libs/kapp/args_debug.h
index 3221434..ea4c509 100644
--- a/libs/kapp/args_debug.h
+++ b/libs/kapp/args_debug.h
@@ -44,4 +44,4 @@
#endif
-#endif
\ No newline at end of file
+#endif
diff --git a/libs/kdb/dbmgr-cmn.c b/libs/kdb/dbmgr-cmn.c
index 3a5daeb..fd95b66 100644
--- a/libs/kdb/dbmgr-cmn.c
+++ b/libs/kdb/dbmgr-cmn.c
@@ -39,6 +39,7 @@
#include <klib/symbol.h>
#include <klib/checksum.h>
#include <klib/rc.h>
+#include <kproc/lock.h>
#include <sysalloc.h>
#include <limits.h>
@@ -66,6 +67,8 @@ rc_t KDBManagerWhack ( KDBManager *self )
/* everything should be closed */
assert ( self -> open_objs . root == NULL );
+ rc = KRWLockRelease ( self -> open_objs_lock );
+
rc = VFSManagerRelease ( self -> vfsmgr );
rc = KDirectoryRelease ( self -> wd );
@@ -186,15 +189,24 @@ rc_t KDBManagerMake ( KDBManager **mgrp, const KDirectory *wd, const char *op,
if ( rc == 0 )
{
- CRC32Init ();
-
- BSTreeInit ( & mgr -> open_objs );
-
- KRefcountInit ( & mgr -> refcount, 1, "KDBManager", op, "kmgr" );
+ rc = KRWLockMake ( & mgr -> open_objs_lock );
+
+ if ( rc == 0 )
+ {
+ CRC32Init ();
+
+ BSTreeInit ( & mgr -> open_objs );
+
+ KRefcountInit ( & mgr -> refcount, 1, "KDBManager", op, "kmgr" );
+
+ * mgrp = mgr;
+ return 0;
+ }
- * mgrp = mgr;
- return 0;
+ VFSManagerRelease ( mgr -> vfsmgr );
}
+
+ KDirectoryRelease ( mgr -> wd );
}
free ( mgr );
@@ -338,7 +350,14 @@ rc_t KDBManagerCheckOpen ( const KDBManager * self, const char *path )
static
KSymbol *KDBManagerOpenObjectFindInt ( const KDBManager * self, String *s )
{
- return ( KSymbol* ) BSTreeFind ( & self -> open_objs, s, KSymbolCmp );
+ KSymbol *sym = NULL;
+ rc_t rc = KRWLockAcquireShared ( self -> open_objs_lock );
+ if ( rc == 0 )
+ {
+ sym = ( KSymbol* ) BSTreeFind ( & self -> open_objs, s, KSymbolCmp );
+ KRWLockUnlock ( self -> open_objs_lock );
+ }
+ return sym;
}
KSymbol *KDBManagerOpenObjectFind ( const KDBManager * self, const char * path )
@@ -364,28 +383,40 @@ bool KDBManagerOpenObjectBusy ( const KDBManager *self, const char *path )
rc_t KDBManagerOpenObjectAdd ( KDBManager *self, KSymbol *obj )
{
KSymbol *exists;
- rc_t rc = BSTreeInsertUnique ( & self -> open_objs,
- & obj -> n, ( BSTNode** ) & exists, KSymbolSort );
-
+ rc_t rc = KRWLockAcquireExcl ( self -> open_objs_lock );
if ( rc == 0 )
- return 0;
-
- switch ( exists -> type )
{
- case kptDatabase:
- return RC ( rcDB, rcMgr, rcInserting, rcDatabase, rcBusy );
- case kptTable:
- case kptPrereleaseTbl:
- return RC ( rcDB, rcMgr, rcInserting, rcTable, rcBusy );
- case kptColumn:
- return RC ( rcDB, rcMgr, rcInserting, rcColumn, rcBusy );
- case kptIndex:
- return RC ( rcDB, rcMgr, rcInserting, rcIndex, rcBusy );
- case kptMetadata:
- return RC ( rcDB, rcMgr, rcInserting, rcMetadata, rcBusy );
- }
+ rc = BSTreeInsertUnique ( & self -> open_objs,
+ & obj -> n, ( BSTNode** ) & exists, KSymbolSort );
- return RC ( rcDB, rcMgr, rcInserting, rcUnknown, rcBusy );
+ KRWLockUnlock ( self -> open_objs_lock );
+
+ if ( rc != 0 )
+ {
+ switch ( exists -> type )
+ {
+ case kptDatabase:
+ rc = RC ( rcDB, rcMgr, rcInserting, rcDatabase, rcBusy );
+ break;
+ case kptTable:
+ case kptPrereleaseTbl:
+ rc = RC ( rcDB, rcMgr, rcInserting, rcTable, rcBusy );
+ break;
+ case kptColumn:
+ rc = RC ( rcDB, rcMgr, rcInserting, rcColumn, rcBusy );
+ break;
+ case kptIndex:
+ rc = RC ( rcDB, rcMgr, rcInserting, rcIndex, rcBusy );
+ break;
+ case kptMetadata:
+ rc = RC ( rcDB, rcMgr, rcInserting, rcMetadata, rcBusy );
+ break;
+ default:
+ rc = RC ( rcDB, rcMgr, rcInserting, rcUnknown, rcBusy );
+ }
+ }
+ }
+ return rc;
}
@@ -394,20 +425,27 @@ rc_t KDBManagerOpenObjectAdd ( KDBManager *self, KSymbol *obj )
*/
rc_t KDBManagerOpenObjectDelete ( KDBManager *self, KSymbol *obj )
{
+ rc_t rc = 0;
if ( obj != NULL )
{
- /* we can expect that the only valid reason for
- "obj" not being unlinked is that it was not in
- the tree. other reasons would be that "obj" was
- corrupt, but in any event, it's not in the tree */
- if ( ! BSTreeUnlink ( & self -> open_objs, & obj -> n ) )
-
- /* to be truly weird, we could tell what kind of node
- it was that we didn't find */
- return RC ( rcDB, rcMgr, rcRemoving, rcNode, rcNotFound );
+ rc = KRWLockAcquireExcl ( self -> open_objs_lock );
+ if ( rc == 0 )
+ {
+ /* we can expect that the only valid reason for
+ "obj" not being unlinked is that it was not in
+ the tree. other reasons would be that "obj" was
+ corrupt, but in any event, it's not in the tree */
+ if ( ! BSTreeUnlink ( & self -> open_objs, & obj -> n ) )
+
+ /* to be truly weird, we could tell what kind of node
+ it was that we didn't find */
+ rc = RC ( rcDB, rcMgr, rcRemoving, rcNode, rcNotFound );
+
+ KRWLockUnlock ( self -> open_objs_lock );
+ }
}
- return 0;
+ return rc;
}
diff --git a/libs/kdb/dbmgr-priv.h b/libs/kdb/dbmgr-priv.h
index 3ef8617..37c526b 100644
--- a/libs/kdb/dbmgr-priv.h
+++ b/libs/kdb/dbmgr-priv.h
@@ -51,6 +51,7 @@ extern "C" {
/*--------------------------------------------------------------------------
* forwards
*/
+struct KRWLock;
struct KSymbol;
struct KDirectory;
struct VFSManager;
@@ -65,6 +66,7 @@ struct KDBManager
struct KDirectory KONST *wd;
/* open objects */
+ struct KRWLock *open_objs_lock;
BSTree open_objs;
/* open references */
diff --git a/libs/kdb/wmeta.c b/libs/kdb/wmeta.c
index 890bf73..dd094c4 100644
--- a/libs/kdb/wmeta.c
+++ b/libs/kdb/wmeta.c
@@ -534,10 +534,10 @@ bool CC KMDataNodeInflate ( PBSTNode *n, void *data )
b -> vsize = n -> data . size - size - 1;
BSTreeInit ( & b -> attr );
BSTreeInit ( & b -> child );
- KRefcountInit ( & b -> refcount, 0, "KMDataNode", "inflate", b -> name );
- b -> read_only = 0;
memcpy ( b -> name, name, size );
b -> name [ size ] = 0;
+ KRefcountInit ( & b -> refcount, 0, "KMDataNode", "inflate", b -> name );
+ b -> read_only = 0;
pb -> rc = ( bits & 1 ) != 0 ? KMDataNodeInflateAttr ( b, pb -> byteswap ) : 0;
if ( pb -> rc == 0 )
@@ -709,9 +709,9 @@ rc_t KMDataNodeMake ( KMDataNode *self, KMDataNode **np, char *name )
n -> vsize = 0;
BSTreeInit ( & n -> attr );
BSTreeInit ( & n -> child );
+ strcpy ( n -> name, name );
KRefcountInit ( & n -> refcount, 0, "KMDataNode", "make", n -> name );
n -> read_only = 0;
- strcpy ( n -> name, name );
/* insert */
rc = BSTreeInsertUnique ( & self -> child,
diff --git a/libs/kfg/config-lex.c b/libs/kfg/config-lex.c
index 299650f..38daf51 100644
--- a/libs/kfg/config-lex.c
+++ b/libs/kfg/config-lex.c
@@ -151,7 +151,7 @@ typedef void* yyscan_t;
#define YY_STATE_EOF(state) (YY_END_OF_BUFFER + state + 1)
/* Special action meaning "start processing a new file". */
-#define YY_NEW_FILE yyrestart(yyin ,yyscanner )
+#define YY_NEW_FILE vdb_kfg_yyrestart(yyin ,yyscanner )
#define YY_END_OF_BUFFER_CHAR 0
@@ -175,7 +175,7 @@ typedef struct yy_buffer_state *YY_BUFFER_STATE;
/* Note: We specifically omit the test for yy_rule_can_match_eol because it requires
* access to the local variable yy_act. Since yyless() is a macro, it would break
- * existing scanners that call yyless() from OUTSIDE yylex.
+ * existing scanners that call yyless() from OUTSIDE vdb_kfg_yylex.
* One obvious solution it to make yy_act a global. I tried that, and saw
* a 5% performance hit in a non-yylineno scanner, because yy_act is
* normally declared as a register variable-- so it is not worth it.
@@ -266,7 +266,7 @@ struct yy_buffer_state
* possible backing-up.
*
* When we actually see the EOF, we change the status to "new"
- * (via yyrestart()), so that the user can continue scanning by
+ * (via vdb_kfg_yyrestart()), so that the user can continue scanning by
* just pointing yyin at a new input file.
*/
#define YY_BUFFER_EOF_PENDING 2
@@ -289,36 +289,36 @@ struct yy_buffer_state
*/
#define YY_CURRENT_BUFFER_LVALUE yyg->yy_buffer_stack[yyg->yy_buffer_stack_top]
-void yyrestart (FILE *input_file ,yyscan_t yyscanner );
-void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner );
-YY_BUFFER_STATE yy_create_buffer (FILE *file,int size ,yyscan_t yyscanner );
-void yy_delete_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner );
-void yy_flush_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner );
-void yypush_buffer_state (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner );
-void yypop_buffer_state (yyscan_t yyscanner );
+void vdb_kfg_yyrestart (FILE *input_file ,yyscan_t yyscanner );
+void vdb_kfg_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner );
+YY_BUFFER_STATE vdb_kfg_yy_create_buffer (FILE *file,int size ,yyscan_t yyscanner );
+void vdb_kfg_yy_delete_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner );
+void vdb_kfg_yy_flush_buffer (YY_BUFFER_STATE b ,yyscan_t yyscanner );
+void vdb_kfg_yypush_buffer_state (YY_BUFFER_STATE new_buffer ,yyscan_t yyscanner );
+void vdb_kfg_yypop_buffer_state (yyscan_t yyscanner );
-static void yyensure_buffer_stack (yyscan_t yyscanner );
-static void yy_load_buffer_state (yyscan_t yyscanner );
-static void yy_init_buffer (YY_BUFFER_STATE b,FILE *file ,yyscan_t yyscanner );
+static void vdb_kfg_yyensure_buffer_stack (yyscan_t yyscanner );
+static void vdb_kfg_yy_load_buffer_state (yyscan_t yyscanner );
+static void vdb_kfg_yy_init_buffer (YY_BUFFER_STATE b,FILE *file ,yyscan_t yyscanner );
-#define YY_FLUSH_BUFFER yy_flush_buffer(YY_CURRENT_BUFFER ,yyscanner)
+#define YY_FLUSH_BUFFER vdb_kfg_yy_flush_buffer(YY_CURRENT_BUFFER ,yyscanner)
-YY_BUFFER_STATE yy_scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner );
-YY_BUFFER_STATE yy_scan_string (yyconst char *yy_str ,yyscan_t yyscanner );
-YY_BUFFER_STATE yy_scan_bytes (yyconst char *bytes,int len ,yyscan_t yyscanner );
+YY_BUFFER_STATE vdb_kfg_yy_scan_buffer (char *base,yy_size_t size ,yyscan_t yyscanner );
+YY_BUFFER_STATE vdb_kfg_yy_scan_string (yyconst char *yy_str ,yyscan_t yyscanner );
+YY_BUFFER_STATE vdb_kfg_yy_scan_bytes (yyconst char *bytes,int len ,yyscan_t yyscanner );
-void *yyalloc (yy_size_t ,yyscan_t yyscanner );
-void *yyrealloc (void *,yy_size_t ,yyscan_t yyscanner );
-void yyfree (void * ,yyscan_t yyscanner );
+void *vdb_kfg_yyalloc (yy_size_t ,yyscan_t yyscanner );
+void *vdb_kfg_yyrealloc (void *,yy_size_t ,yyscan_t yyscanner );
+void vdb_kfg_yyfree (void * ,yyscan_t yyscanner );
-#define yy_new_buffer yy_create_buffer
+#define yy_new_buffer vdb_kfg_yy_create_buffer
#define yy_set_interactive(is_interactive) \
{ \
if ( ! YY_CURRENT_BUFFER ){ \
- yyensure_buffer_stack (yyscanner); \
+ vdb_kfg_yyensure_buffer_stack (yyscanner); \
YY_CURRENT_BUFFER_LVALUE = \
- yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
+ vdb_kfg_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
} \
YY_CURRENT_BUFFER_LVALUE->yy_is_interactive = is_interactive; \
}
@@ -326,9 +326,9 @@ void yyfree (void * ,yyscan_t yyscanner );
#define yy_set_bol(at_bol) \
{ \
if ( ! YY_CURRENT_BUFFER ){\
- yyensure_buffer_stack (yyscanner); \
+ vdb_kfg_yyensure_buffer_stack (yyscanner); \
YY_CURRENT_BUFFER_LVALUE = \
- yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
+ vdb_kfg_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner); \
} \
YY_CURRENT_BUFFER_LVALUE->yy_at_bol = at_bol; \
}
@@ -337,7 +337,7 @@ void yyfree (void * ,yyscan_t yyscanner );
/* Begin user sect3 */
-#define yywrap(n) 1
+#define vdb_kfg_yywrap(n) 1
#define YY_SKIP_YYWRAP
typedef unsigned char YY_CHAR;
@@ -762,42 +762,42 @@ static int yy_init_globals (yyscan_t yyscanner );
* from bison output in section 1.*/
# define yylval yyg->yylval_r
-int yylex_init (yyscan_t* scanner);
+int vdb_kfg_yylex_init (yyscan_t* scanner);
-int yylex_init_extra (YY_EXTRA_TYPE user_defined,yyscan_t* scanner);
+int vdb_kfg_yylex_init_extra (YY_EXTRA_TYPE user_defined,yyscan_t* scanner);
/* Accessor methods to globals.
These are made visible to non-reentrant scanners for convenience. */
-int yylex_destroy (yyscan_t yyscanner );
+int vdb_kfg_yylex_destroy (yyscan_t yyscanner );
-int yyget_debug (yyscan_t yyscanner );
+int vdb_kfg_yyget_debug (yyscan_t yyscanner );
-void yyset_debug (int debug_flag ,yyscan_t yyscanner );
+void vdb_kfg_yyset_debug (int debug_flag ,yyscan_t yyscanner );
-YY_EXTRA_TYPE yyget_extra (yyscan_t yyscanner );
+YY_EXTRA_TYPE vdb_kfg_yyget_extra (yyscan_t yyscanner );
-void yyset_extra (YY_EXTRA_TYPE user_defined ,yyscan_t yyscanner );
+void vdb_kfg_yyset_extra (YY_EXTRA_TYPE user_defined ,yyscan_t yyscanner );
-FILE *yyget_in (yyscan_t yyscanner );
+FILE *vdb_kfg_yyget_in (yyscan_t yyscanner );
-void yyset_in (FILE * in_str ,yyscan_t yyscanner );
+void vdb_kfg_yyset_in (FILE * in_str ,yyscan_t yyscanner );
-FILE *yyget_out (yyscan_t yyscanner );
+FILE *vdb_kfg_yyget_out (yyscan_t yyscanner );
-void yyset_out (FILE * out_str ,yyscan_t yyscanner );
+void vdb_kfg_yyset_out (FILE * out_str ,yyscan_t yyscanner );
-int yyget_leng (yyscan_t yyscanner );
+int vdb_kfg_yyget_leng (yyscan_t yyscanner );
-char *yyget_text (yyscan_t yyscanner );
+char *vdb_kfg_yyget_text (yyscan_t yyscanner );
-int yyget_lineno (yyscan_t yyscanner );
+int vdb_kfg_yyget_lineno (yyscan_t yyscanner );
-void yyset_lineno (int line_number ,yyscan_t yyscanner );
+void vdb_kfg_yyset_lineno (int line_number ,yyscan_t yyscanner );
-YYSTYPE * yyget_lval (yyscan_t yyscanner );
+YYSTYPE * vdb_kfg_yyget_lval (yyscan_t yyscanner );
-void yyset_lval (YYSTYPE * yylval_param ,yyscan_t yyscanner );
+void vdb_kfg_yyset_lval (YYSTYPE * yylval_param ,yyscan_t yyscanner );
/* Macros after this point can all be overridden by user definitions in
* section 1.
@@ -805,9 +805,9 @@ void yyset_lval (YYSTYPE * yylval_param ,yyscan_t yyscanner );
#ifndef YY_SKIP_YYWRAP
#ifdef __cplusplus
-extern "C" int yywrap (yyscan_t yyscanner );
+extern "C" int vdb_kfg_yywrap (yyscan_t yyscanner );
#else
-extern int yywrap (yyscan_t yyscanner );
+extern int vdb_kfg_yywrap (yyscan_t yyscanner );
#endif
#endif
@@ -912,10 +912,10 @@ static int input (yyscan_t yyscanner );
#ifndef YY_DECL
#define YY_DECL_IS_OURS 1
-extern int yylex \
+extern int vdb_kfg_yylex \
(YYSTYPE * yylval_param ,yyscan_t yyscanner);
-#define YY_DECL int yylex \
+#define YY_DECL int vdb_kfg_yylex \
(YYSTYPE * yylval_param , yyscan_t yyscanner)
#endif /* !YY_DECL */
@@ -965,12 +965,12 @@ YY_DECL
yyout = stdout;
if ( ! YY_CURRENT_BUFFER ) {
- yyensure_buffer_stack (yyscanner);
+ vdb_kfg_yyensure_buffer_stack (yyscanner);
YY_CURRENT_BUFFER_LVALUE =
- yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner);
+ vdb_kfg_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner);
}
- yy_load_buffer_state(yyscanner );
+ vdb_kfg_yy_load_buffer_state(yyscanner );
}
while ( 1 ) /* loops until end-of-file is reached */
@@ -1247,7 +1247,7 @@ case YY_STATE_EOF(IN_SNG_STRING):
/* We're scanning a new file or input source. It's
* possible that this happened because the user
* just pointed yyin at a new source and called
- * yylex(). If so, then we have to assure
+ * vdb_kfg_yylex(). If so, then we have to assure
* consistency between YY_CURRENT_BUFFER and our
* globals. Here is the right place to do so, because
* this is the first action (other than possibly a
@@ -1308,7 +1308,7 @@ case YY_STATE_EOF(IN_SNG_STRING):
{
yyg->yy_did_buffer_switch_on_eof = 0;
- if ( yywrap(yyscanner ) )
+ if ( vdb_kfg_yywrap(yyscanner ) )
{
/* Note: because we've taken care in
* yy_get_next_buffer() to have set up
@@ -1361,7 +1361,7 @@ case YY_STATE_EOF(IN_SNG_STRING):
"fatal flex scanner internal error--no action found" );
} /* end of action switch */
} /* end of scanning one token */
-} /* end of yylex */
+} /* end of vdb_kfg_yylex */
/* yy_get_next_buffer - try to read in a new buffer
*
@@ -1440,7 +1440,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
b->yy_ch_buf = (char *)
/* Include room in for 2 EOB chars. */
- yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ,yyscanner );
+ vdb_kfg_yyrealloc((void *) b->yy_ch_buf,b->yy_buf_size + 2 ,yyscanner );
}
else
/* Can't grow it, we don't own it. */
@@ -1472,7 +1472,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
if ( number_to_move == YY_MORE_ADJ )
{
ret_val = EOB_ACT_END_OF_FILE;
- yyrestart(yyin ,yyscanner);
+ vdb_kfg_yyrestart(yyin ,yyscanner);
}
else
@@ -1489,7 +1489,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
if ((yy_size_t) (yyg->yy_n_chars + number_to_move) > YY_CURRENT_BUFFER_LVALUE->yy_buf_size) {
/* Extend the array by 50%, plus the number we really need. */
yy_size_t new_size = yyg->yy_n_chars + number_to_move + (yyg->yy_n_chars >> 1);
- YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ,yyscanner );
+ YY_CURRENT_BUFFER_LVALUE->yy_ch_buf = (char *) vdb_kfg_yyrealloc((void *) YY_CURRENT_BUFFER_LVALUE->yy_ch_buf,new_size ,yyscanner );
if ( ! YY_CURRENT_BUFFER_LVALUE->yy_ch_buf )
YY_FATAL_ERROR( "out of dynamic memory in yy_get_next_buffer()" );
}
@@ -1646,13 +1646,13 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
*/
/* Reset buffer status. */
- yyrestart(yyin ,yyscanner);
+ vdb_kfg_yyrestart(yyin ,yyscanner);
/*FALLTHROUGH*/
case EOB_ACT_END_OF_FILE:
{
- if ( yywrap(yyscanner ) )
+ if ( vdb_kfg_yywrap(yyscanner ) )
return EOF;
if ( ! yyg->yy_did_buffer_switch_on_eof )
@@ -1691,34 +1691,34 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
* @param yyscanner The scanner object.
* @note This function does not reset the start condition to @c INITIAL .
*/
- void yyrestart (FILE * input_file , yyscan_t yyscanner)
+ void vdb_kfg_yyrestart (FILE * input_file , yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
if ( ! YY_CURRENT_BUFFER ){
- yyensure_buffer_stack (yyscanner);
+ vdb_kfg_yyensure_buffer_stack (yyscanner);
YY_CURRENT_BUFFER_LVALUE =
- yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner);
+ vdb_kfg_yy_create_buffer(yyin,YY_BUF_SIZE ,yyscanner);
}
- yy_init_buffer(YY_CURRENT_BUFFER,input_file ,yyscanner);
- yy_load_buffer_state(yyscanner );
+ vdb_kfg_yy_init_buffer(YY_CURRENT_BUFFER,input_file ,yyscanner);
+ vdb_kfg_yy_load_buffer_state(yyscanner );
}
/** Switch to a different input buffer.
* @param new_buffer The new input buffer.
* @param yyscanner The scanner object.
*/
- void yy_switch_to_buffer (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
+ void vdb_kfg_yy_switch_to_buffer (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
/* TODO. We should be able to replace this entire function body
* with
- * yypop_buffer_state();
- * yypush_buffer_state(new_buffer);
+ * vdb_kfg_yypop_buffer_state();
+ * vdb_kfg_yypush_buffer_state(new_buffer);
*/
- yyensure_buffer_stack (yyscanner);
+ vdb_kfg_yyensure_buffer_stack (yyscanner);
if ( YY_CURRENT_BUFFER == new_buffer )
return;
@@ -1731,17 +1731,17 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
}
YY_CURRENT_BUFFER_LVALUE = new_buffer;
- yy_load_buffer_state(yyscanner );
+ vdb_kfg_yy_load_buffer_state(yyscanner );
/* We don't actually know whether we did this switch during
- * EOF (yywrap()) processing, but the only time this flag
- * is looked at is after yywrap() is called, so it's safe
+ * EOF (vdb_kfg_yywrap()) processing, but the only time this flag
+ * is looked at is after vdb_kfg_yywrap() is called, so it's safe
* to go ahead and always set it.
*/
yyg->yy_did_buffer_switch_on_eof = 1;
}
-static void yy_load_buffer_state (yyscan_t yyscanner)
+static void vdb_kfg_yy_load_buffer_state (yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
yyg->yy_n_chars = YY_CURRENT_BUFFER_LVALUE->yy_n_chars;
@@ -1756,35 +1756,35 @@ static void yy_load_buffer_state (yyscan_t yyscanner)
* @param yyscanner The scanner object.
* @return the allocated buffer state.
*/
- YY_BUFFER_STATE yy_create_buffer (FILE * file, int size , yyscan_t yyscanner)
+ YY_BUFFER_STATE vdb_kfg_yy_create_buffer (FILE * file, int size , yyscan_t yyscanner)
{
YY_BUFFER_STATE b;
- b = (YY_BUFFER_STATE) yyalloc(sizeof( struct yy_buffer_state ) ,yyscanner );
+ b = (YY_BUFFER_STATE) vdb_kfg_yyalloc(sizeof( struct yy_buffer_state ) ,yyscanner );
if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
+ YY_FATAL_ERROR( "out of dynamic memory in vdb_kfg_yy_create_buffer()" );
b->yy_buf_size = size;
/* yy_ch_buf has to be 2 characters longer than the size given because
* we need to put in 2 end-of-buffer characters.
*/
- b->yy_ch_buf = (char *) yyalloc(b->yy_buf_size + 2 ,yyscanner );
+ b->yy_ch_buf = (char *) vdb_kfg_yyalloc(b->yy_buf_size + 2 ,yyscanner );
if ( ! b->yy_ch_buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_create_buffer()" );
+ YY_FATAL_ERROR( "out of dynamic memory in vdb_kfg_yy_create_buffer()" );
b->yy_is_our_buffer = 1;
- yy_init_buffer(b,file ,yyscanner);
+ vdb_kfg_yy_init_buffer(b,file ,yyscanner);
return b;
}
/** Destroy the buffer.
- * @param b a buffer created with yy_create_buffer()
+ * @param b a buffer created with vdb_kfg_yy_create_buffer()
* @param yyscanner The scanner object.
*/
- void yy_delete_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
+ void vdb_kfg_yy_delete_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
@@ -1795,28 +1795,28 @@ static void yy_load_buffer_state (yyscan_t yyscanner)
YY_CURRENT_BUFFER_LVALUE = (YY_BUFFER_STATE) 0;
if ( b->yy_is_our_buffer )
- yyfree((void *) b->yy_ch_buf ,yyscanner );
+ vdb_kfg_yyfree((void *) b->yy_ch_buf ,yyscanner );
- yyfree((void *) b ,yyscanner );
+ vdb_kfg_yyfree((void *) b ,yyscanner );
}
/* Initializes or reinitializes a buffer.
* This function is sometimes called more than once on the same buffer,
- * such as during a yyrestart() or at EOF.
+ * such as during a vdb_kfg_yyrestart() or at EOF.
*/
- static void yy_init_buffer (YY_BUFFER_STATE b, FILE * file , yyscan_t yyscanner)
+ static void vdb_kfg_yy_init_buffer (YY_BUFFER_STATE b, FILE * file , yyscan_t yyscanner)
{
int oerrno = errno;
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
- yy_flush_buffer(b ,yyscanner);
+ vdb_kfg_yy_flush_buffer(b ,yyscanner);
b->yy_input_file = file;
b->yy_fill_buffer = 1;
- /* If b is the current buffer, then yy_init_buffer was _probably_
- * called from yyrestart() or through yy_get_next_buffer.
+ /* If b is the current buffer, then vdb_kfg_yy_init_buffer was _probably_
+ * called from vdb_kfg_yyrestart() or through yy_get_next_buffer.
* In that case, we don't want to reset the lineno or column.
*/
if (b != YY_CURRENT_BUFFER){
@@ -1833,7 +1833,7 @@ static void yy_load_buffer_state (yyscan_t yyscanner)
* @param b the buffer state to be flushed, usually @c YY_CURRENT_BUFFER.
* @param yyscanner The scanner object.
*/
- void yy_flush_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
+ void vdb_kfg_yy_flush_buffer (YY_BUFFER_STATE b , yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
if ( ! b )
@@ -1854,7 +1854,7 @@ static void yy_load_buffer_state (yyscan_t yyscanner)
b->yy_buffer_status = YY_BUFFER_NEW;
if ( b == YY_CURRENT_BUFFER )
- yy_load_buffer_state(yyscanner );
+ vdb_kfg_yy_load_buffer_state(yyscanner );
}
/** Pushes the new state onto the stack. The new state becomes
@@ -1863,15 +1863,15 @@ static void yy_load_buffer_state (yyscan_t yyscanner)
* @param new_buffer The new state.
* @param yyscanner The scanner object.
*/
-void yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
+void vdb_kfg_yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
if (new_buffer == NULL)
return;
- yyensure_buffer_stack(yyscanner);
+ vdb_kfg_yyensure_buffer_stack(yyscanner);
- /* This block is copied from yy_switch_to_buffer. */
+ /* This block is copied from vdb_kfg_yy_switch_to_buffer. */
if ( YY_CURRENT_BUFFER )
{
/* Flush out information for old buffer. */
@@ -1885,8 +1885,8 @@ void yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
yyg->yy_buffer_stack_top++;
YY_CURRENT_BUFFER_LVALUE = new_buffer;
- /* copied from yy_switch_to_buffer. */
- yy_load_buffer_state(yyscanner );
+ /* copied from vdb_kfg_yy_switch_to_buffer. */
+ vdb_kfg_yy_load_buffer_state(yyscanner );
yyg->yy_did_buffer_switch_on_eof = 1;
}
@@ -1894,19 +1894,19 @@ void yypush_buffer_state (YY_BUFFER_STATE new_buffer , yyscan_t yyscanner)
* The next element becomes the new top.
* @param yyscanner The scanner object.
*/
-void yypop_buffer_state (yyscan_t yyscanner)
+void vdb_kfg_yypop_buffer_state (yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
if (!YY_CURRENT_BUFFER)
return;
- yy_delete_buffer(YY_CURRENT_BUFFER ,yyscanner);
+ vdb_kfg_yy_delete_buffer(YY_CURRENT_BUFFER ,yyscanner);
YY_CURRENT_BUFFER_LVALUE = NULL;
if (yyg->yy_buffer_stack_top > 0)
--yyg->yy_buffer_stack_top;
if (YY_CURRENT_BUFFER) {
- yy_load_buffer_state(yyscanner );
+ vdb_kfg_yy_load_buffer_state(yyscanner );
yyg->yy_did_buffer_switch_on_eof = 1;
}
}
@@ -1914,7 +1914,7 @@ void yypop_buffer_state (yyscan_t yyscanner)
/* Allocates the stack if it does not exist.
* Guarantees space for at least one push.
*/
-static void yyensure_buffer_stack (yyscan_t yyscanner)
+static void vdb_kfg_yyensure_buffer_stack (yyscan_t yyscanner)
{
int num_to_alloc;
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
@@ -1926,11 +1926,11 @@ static void yyensure_buffer_stack (yyscan_t yyscanner)
* immediate realloc on the next call.
*/
num_to_alloc = 1;
- yyg->yy_buffer_stack = (struct yy_buffer_state**)yyalloc
+ yyg->yy_buffer_stack = (struct yy_buffer_state**)vdb_kfg_yyalloc
(num_to_alloc * sizeof(struct yy_buffer_state*)
, yyscanner);
if ( ! yyg->yy_buffer_stack )
- YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
+ YY_FATAL_ERROR( "out of dynamic memory in vdb_kfg_yyensure_buffer_stack()" );
memset(yyg->yy_buffer_stack, 0, num_to_alloc * sizeof(struct yy_buffer_state*));
@@ -1945,12 +1945,12 @@ static void yyensure_buffer_stack (yyscan_t yyscanner)
int grow_size = 8 /* arbitrary grow size */;
num_to_alloc = yyg->yy_buffer_stack_max + grow_size;
- yyg->yy_buffer_stack = (struct yy_buffer_state**)yyrealloc
+ yyg->yy_buffer_stack = (struct yy_buffer_state**)vdb_kfg_yyrealloc
(yyg->yy_buffer_stack,
num_to_alloc * sizeof(struct yy_buffer_state*)
, yyscanner);
if ( ! yyg->yy_buffer_stack )
- YY_FATAL_ERROR( "out of dynamic memory in yyensure_buffer_stack()" );
+ YY_FATAL_ERROR( "out of dynamic memory in vdb_kfg_yyensure_buffer_stack()" );
/* zero only the new slots.*/
memset(yyg->yy_buffer_stack + yyg->yy_buffer_stack_max, 0, grow_size * sizeof(struct yy_buffer_state*));
@@ -1964,7 +1964,7 @@ static void yyensure_buffer_stack (yyscan_t yyscanner)
* @param yyscanner The scanner object.
* @return the newly allocated buffer state object.
*/
-YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size , yyscan_t yyscanner)
+YY_BUFFER_STATE vdb_kfg_yy_scan_buffer (char * base, yy_size_t size , yyscan_t yyscanner)
{
YY_BUFFER_STATE b;
@@ -1974,9 +1974,9 @@ YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size , yyscan_t yyscann
/* They forgot to leave room for the EOB's. */
return 0;
- b = (YY_BUFFER_STATE) yyalloc(sizeof( struct yy_buffer_state ) ,yyscanner );
+ b = (YY_BUFFER_STATE) vdb_kfg_yyalloc(sizeof( struct yy_buffer_state ) ,yyscanner );
if ( ! b )
- YY_FATAL_ERROR( "out of dynamic memory in yy_scan_buffer()" );
+ YY_FATAL_ERROR( "out of dynamic memory in vdb_kfg_yy_scan_buffer()" );
b->yy_buf_size = size - 2; /* "- 2" to take care of EOB's */
b->yy_buf_pos = b->yy_ch_buf = base;
@@ -1988,33 +1988,33 @@ YY_BUFFER_STATE yy_scan_buffer (char * base, yy_size_t size , yyscan_t yyscann
b->yy_fill_buffer = 0;
b->yy_buffer_status = YY_BUFFER_NEW;
- yy_switch_to_buffer(b ,yyscanner );
+ vdb_kfg_yy_switch_to_buffer(b ,yyscanner );
return b;
}
-/** Setup the input buffer state to scan a string. The next call to yylex() will
+/** Setup the input buffer state to scan a string. The next call to vdb_kfg_yylex() will
* scan from a @e copy of @a str.
* @param yystr a NUL-terminated string to scan
* @param yyscanner The scanner object.
* @return the newly allocated buffer state object.
* @note If you want to scan bytes that may contain NUL values, then use
- * yy_scan_bytes() instead.
+ * vdb_kfg_yy_scan_bytes() instead.
*/
-YY_BUFFER_STATE yy_scan_string (yyconst char * yystr , yyscan_t yyscanner)
+YY_BUFFER_STATE vdb_kfg_yy_scan_string (yyconst char * yystr , yyscan_t yyscanner)
{
- return yy_scan_bytes(yystr,strlen(yystr) ,yyscanner);
+ return vdb_kfg_yy_scan_bytes(yystr,strlen(yystr) ,yyscanner);
}
-/** Setup the input buffer state to scan the given bytes. The next call to yylex() will
+/** Setup the input buffer state to scan the given bytes. The next call to vdb_kfg_yylex() will
* scan from a @e copy of @a bytes.
* @param bytes the byte buffer to scan
* @param len the number of bytes in the buffer pointed to by @a bytes.
* @param yyscanner The scanner object.
* @return the newly allocated buffer state object.
*/
-YY_BUFFER_STATE yy_scan_bytes (yyconst char * yybytes, int _yybytes_len , yyscan_t yyscanner)
+YY_BUFFER_STATE vdb_kfg_yy_scan_bytes (yyconst char * yybytes, int _yybytes_len , yyscan_t yyscanner)
{
YY_BUFFER_STATE b;
char *buf;
@@ -2023,18 +2023,18 @@ YY_BUFFER_STATE yy_scan_bytes (yyconst char * yybytes, int _yybytes_len , yysc
/* Get memory for full buffer, including space for trailing EOB's. */
n = _yybytes_len + 2;
- buf = (char *) yyalloc(n ,yyscanner );
+ buf = (char *) vdb_kfg_yyalloc(n ,yyscanner );
if ( ! buf )
- YY_FATAL_ERROR( "out of dynamic memory in yy_scan_bytes()" );
+ YY_FATAL_ERROR( "out of dynamic memory in vdb_kfg_yy_scan_bytes()" );
for ( i = 0; i < _yybytes_len; ++i )
buf[i] = yybytes[i];
buf[_yybytes_len] = buf[_yybytes_len+1] = YY_END_OF_BUFFER_CHAR;
- b = yy_scan_buffer(buf,n ,yyscanner);
+ b = vdb_kfg_yy_scan_buffer(buf,n ,yyscanner);
if ( ! b )
- YY_FATAL_ERROR( "bad buffer in yy_scan_bytes()" );
+ YY_FATAL_ERROR( "bad buffer in vdb_kfg_yy_scan_bytes()" );
/* It's okay to grow etc. this buffer, and we should throw it
* away when we're done.
@@ -2055,10 +2055,10 @@ YY_BUFFER_STATE yy_scan_bytes (yyconst char * yybytes, int _yybytes_len , yysc
new_size = yyg->yy_start_stack_depth * sizeof( int );
if ( ! yyg->yy_start_stack )
- yyg->yy_start_stack = (int *) yyalloc(new_size ,yyscanner );
+ yyg->yy_start_stack = (int *) vdb_kfg_yyalloc(new_size ,yyscanner );
else
- yyg->yy_start_stack = (int *) yyrealloc((void *) yyg->yy_start_stack,new_size ,yyscanner );
+ yyg->yy_start_stack = (int *) vdb_kfg_yyrealloc((void *) yyg->yy_start_stack,new_size ,yyscanner );
if ( ! yyg->yy_start_stack )
YY_FATAL_ERROR( "out of memory expanding start-condition stack" );
@@ -2116,7 +2116,7 @@ static void yy_fatal_error (yyconst char* msg , yyscan_t yyscanner)
/** Get the user-defined data for this scanner.
* @param yyscanner The scanner object.
*/
-YY_EXTRA_TYPE yyget_extra (yyscan_t yyscanner)
+YY_EXTRA_TYPE vdb_kfg_yyget_extra (yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
return yyextra;
@@ -2125,7 +2125,7 @@ YY_EXTRA_TYPE yyget_extra (yyscan_t yyscanner)
/** Get the current line number.
* @param yyscanner The scanner object.
*/
-int yyget_lineno (yyscan_t yyscanner)
+int vdb_kfg_yyget_lineno (yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
@@ -2138,7 +2138,7 @@ int yyget_lineno (yyscan_t yyscanner)
/** Get the current column number.
* @param yyscanner The scanner object.
*/
-int yyget_column (yyscan_t yyscanner)
+int vdb_kfg_yyget_column (yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
@@ -2151,7 +2151,7 @@ int yyget_column (yyscan_t yyscanner)
/** Get the input stream.
* @param yyscanner The scanner object.
*/
-FILE *yyget_in (yyscan_t yyscanner)
+FILE *vdb_kfg_yyget_in (yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
return yyin;
@@ -2160,7 +2160,7 @@ FILE *yyget_in (yyscan_t yyscanner)
/** Get the output stream.
* @param yyscanner The scanner object.
*/
-FILE *yyget_out (yyscan_t yyscanner)
+FILE *vdb_kfg_yyget_out (yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
return yyout;
@@ -2169,7 +2169,7 @@ FILE *yyget_out (yyscan_t yyscanner)
/** Get the length of the current token.
* @param yyscanner The scanner object.
*/
-int yyget_leng (yyscan_t yyscanner)
+int vdb_kfg_yyget_leng (yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
return yyleng;
@@ -2179,7 +2179,7 @@ int yyget_leng (yyscan_t yyscanner)
* @param yyscanner The scanner object.
*/
-char *yyget_text (yyscan_t yyscanner)
+char *vdb_kfg_yyget_text (yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
return yytext;
@@ -2189,7 +2189,7 @@ char *yyget_text (yyscan_t yyscanner)
* @param user_defined The data to be associated with this scanner.
* @param yyscanner The scanner object.
*/
-void yyset_extra (YY_EXTRA_TYPE user_defined , yyscan_t yyscanner)
+void vdb_kfg_yyset_extra (YY_EXTRA_TYPE user_defined , yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
yyextra = user_defined ;
@@ -2199,13 +2199,13 @@ void yyset_extra (YY_EXTRA_TYPE user_defined , yyscan_t yyscanner)
* @param line_number
* @param yyscanner The scanner object.
*/
-void yyset_lineno (int line_number , yyscan_t yyscanner)
+void vdb_kfg_yyset_lineno (int line_number , yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
/* lineno is only valid if an input buffer exists. */
if (! YY_CURRENT_BUFFER )
- yy_fatal_error( "yyset_lineno called with no buffer" , yyscanner);
+ yy_fatal_error( "vdb_kfg_yyset_lineno called with no buffer" , yyscanner);
yylineno = line_number;
}
@@ -2214,13 +2214,13 @@ void yyset_lineno (int line_number , yyscan_t yyscanner)
* @param line_number
* @param yyscanner The scanner object.
*/
-void yyset_column (int column_no , yyscan_t yyscanner)
+void vdb_kfg_yyset_column (int column_no , yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
/* column is only valid if an input buffer exists. */
if (! YY_CURRENT_BUFFER )
- yy_fatal_error( "yyset_column called with no buffer" , yyscanner);
+ yy_fatal_error( "vdb_kfg_yyset_column called with no buffer" , yyscanner);
yycolumn = column_no;
}
@@ -2229,27 +2229,27 @@ void yyset_column (int column_no , yyscan_t yyscanner)
* input buffer.
* @param in_str A readable stream.
* @param yyscanner The scanner object.
- * @see yy_switch_to_buffer
+ * @see vdb_kfg_yy_switch_to_buffer
*/
-void yyset_in (FILE * in_str , yyscan_t yyscanner)
+void vdb_kfg_yyset_in (FILE * in_str , yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
yyin = in_str ;
}
-void yyset_out (FILE * out_str , yyscan_t yyscanner)
+void vdb_kfg_yyset_out (FILE * out_str , yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
yyout = out_str ;
}
-int yyget_debug (yyscan_t yyscanner)
+int vdb_kfg_yyget_debug (yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
return yy_flex_debug;
}
-void yyset_debug (int bdebug , yyscan_t yyscanner)
+void vdb_kfg_yyset_debug (int bdebug , yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
yy_flex_debug = bdebug ;
@@ -2257,13 +2257,13 @@ void yyset_debug (int bdebug , yyscan_t yyscanner)
/* Accessor methods for yylval and yylloc */
-YYSTYPE * yyget_lval (yyscan_t yyscanner)
+YYSTYPE * vdb_kfg_yyget_lval (yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
return yylval;
}
-void yyset_lval (YYSTYPE * yylval_param , yyscan_t yyscanner)
+void vdb_kfg_yyset_lval (YYSTYPE * yylval_param , yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
yylval = yylval_param;
@@ -2271,12 +2271,12 @@ void yyset_lval (YYSTYPE * yylval_param , yyscan_t yyscanner)
/* User-visible API */
-/* yylex_init is special because it creates the scanner itself, so it is
+/* vdb_kfg_yylex_init is special because it creates the scanner itself, so it is
* the ONLY reentrant function that doesn't take the scanner as the last argument.
* That's why we explicitly handle the declaration, instead of using our macros.
*/
-int yylex_init(yyscan_t* ptr_yy_globals)
+int vdb_kfg_yylex_init(yyscan_t* ptr_yy_globals)
{
if (ptr_yy_globals == NULL){
@@ -2284,7 +2284,7 @@ int yylex_init(yyscan_t* ptr_yy_globals)
return 1;
}
- *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), NULL );
+ *ptr_yy_globals = (yyscan_t) vdb_kfg_yyalloc ( sizeof( struct yyguts_t ), NULL );
if (*ptr_yy_globals == NULL){
errno = ENOMEM;
@@ -2297,27 +2297,27 @@ int yylex_init(yyscan_t* ptr_yy_globals)
return yy_init_globals ( *ptr_yy_globals );
}
-/* yylex_init_extra has the same functionality as yylex_init, but follows the
+/* vdb_kfg_yylex_init_extra has the same functionality as vdb_kfg_yylex_init, but follows the
* convention of taking the scanner as the last argument. Note however, that
* this is a *pointer* to a scanner, as it will be allocated by this call (and
* is the reason, too, why this function also must handle its own declaration).
- * The user defined value in the first argument will be available to yyalloc in
+ * The user defined value in the first argument will be available to vdb_kfg_yyalloc in
* the yyextra field.
*/
-int yylex_init_extra(YY_EXTRA_TYPE yy_user_defined,yyscan_t* ptr_yy_globals )
+int vdb_kfg_yylex_init_extra(YY_EXTRA_TYPE yy_user_defined,yyscan_t* ptr_yy_globals )
{
struct yyguts_t dummy_yyguts;
- yyset_extra (yy_user_defined, &dummy_yyguts);
+ vdb_kfg_yyset_extra (yy_user_defined, &dummy_yyguts);
if (ptr_yy_globals == NULL){
errno = EINVAL;
return 1;
}
- *ptr_yy_globals = (yyscan_t) yyalloc ( sizeof( struct yyguts_t ), &dummy_yyguts );
+ *ptr_yy_globals = (yyscan_t) vdb_kfg_yyalloc ( sizeof( struct yyguts_t ), &dummy_yyguts );
if (*ptr_yy_globals == NULL){
errno = ENOMEM;
@@ -2328,7 +2328,7 @@ int yylex_init_extra(YY_EXTRA_TYPE yy_user_defined,yyscan_t* ptr_yy_globals )
yy_init_globals. Leave at 0x00 for releases. */
memset(*ptr_yy_globals,0x00,sizeof(struct yyguts_t));
- yyset_extra (yy_user_defined, *ptr_yy_globals);
+ vdb_kfg_yyset_extra (yy_user_defined, *ptr_yy_globals);
return yy_init_globals ( *ptr_yy_globals );
}
@@ -2337,7 +2337,7 @@ static int yy_init_globals (yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
/* Initialization is the same as for the non-reentrant scanner.
- * This function is called from yylex_destroy(), so don't allocate here.
+ * This function is called from vdb_kfg_yylex_destroy(), so don't allocate here.
*/
yyg->yy_buffer_stack = 0;
@@ -2361,37 +2361,37 @@ static int yy_init_globals (yyscan_t yyscanner)
#endif
/* For future reference: Set errno on error, since we are called by
- * yylex_init()
+ * vdb_kfg_yylex_init()
*/
return 0;
}
-/* yylex_destroy is for both reentrant and non-reentrant scanners. */
-int yylex_destroy (yyscan_t yyscanner)
+/* vdb_kfg_yylex_destroy is for both reentrant and non-reentrant scanners. */
+int vdb_kfg_yylex_destroy (yyscan_t yyscanner)
{
struct yyguts_t * yyg = (struct yyguts_t*)yyscanner;
/* Pop the buffer stack, destroying each element. */
while(YY_CURRENT_BUFFER){
- yy_delete_buffer(YY_CURRENT_BUFFER ,yyscanner );
+ vdb_kfg_yy_delete_buffer(YY_CURRENT_BUFFER ,yyscanner );
YY_CURRENT_BUFFER_LVALUE = NULL;
- yypop_buffer_state(yyscanner);
+ vdb_kfg_yypop_buffer_state(yyscanner);
}
/* Destroy the stack itself. */
- yyfree(yyg->yy_buffer_stack ,yyscanner);
+ vdb_kfg_yyfree(yyg->yy_buffer_stack ,yyscanner);
yyg->yy_buffer_stack = NULL;
/* Destroy the start condition stack. */
- yyfree(yyg->yy_start_stack ,yyscanner );
+ vdb_kfg_yyfree(yyg->yy_start_stack ,yyscanner );
yyg->yy_start_stack = NULL;
/* Reset the globals. This is important in a non-reentrant scanner so the next time
- * yylex() is called, initialization will occur. */
+ * vdb_kfg_yylex() is called, initialization will occur. */
yy_init_globals( yyscanner);
/* Destroy the main struct (reentrant only). */
- yyfree ( yyscanner , yyscanner );
+ vdb_kfg_yyfree ( yyscanner , yyscanner );
yyscanner = NULL;
return 0;
}
@@ -2420,12 +2420,12 @@ static int yy_flex_strlen (yyconst char * s , yyscan_t yyscanner)
}
#endif
-void *yyalloc (yy_size_t size , yyscan_t yyscanner)
+void *vdb_kfg_yyalloc (yy_size_t size , yyscan_t yyscanner)
{
return (void *) malloc( size );
}
-void *yyrealloc (void * ptr, yy_size_t size , yyscan_t yyscanner)
+void *vdb_kfg_yyrealloc (void * ptr, yy_size_t size , yyscan_t yyscanner)
{
/* The cast to (char *) in the following accommodates both
* implementations that use char* generic pointers, and those
@@ -2437,20 +2437,20 @@ void *yyrealloc (void * ptr, yy_size_t size , yyscan_t yyscanner)
return (void *) realloc( (char *) ptr, size );
}
-void yyfree (void * ptr , yyscan_t yyscanner)
+void vdb_kfg_yyfree (void * ptr , yyscan_t yyscanner)
{
- free( (char *) ptr ); /* see yyrealloc() for (char *) cast */
+ free( (char *) ptr ); /* see vdb_kfg_yyrealloc() for (char *) cast */
}
#define YYTABLES_NAME "yytables"
rc_t CC KFGScan_yylex_init(KFGScanBlock* sb, const char *str)
{
- if (yylex_init(&sb->scanner) != 0)
+ if (vdb_kfg_yylex_init(&sb->scanner) != 0)
{
return RC ( rcKFG, rcMgr, rcParsing, rcMemory, rcExhausted );
}
- sb->buffer=yy_scan_string((yyconst char*)str,sb->scanner);
+ sb->buffer=vdb_kfg_yy_scan_string((yyconst char*)str,sb->scanner);
{ /* initialize line/col counters */
/* yylineno and yycolumn are macros using variable yyg, so we have to prepare it for them */
@@ -2464,10 +2464,10 @@ rc_t CC KFGScan_yylex_init(KFGScanBlock* sb, const char *str)
void CC KFGScan_yylex_destroy(KFGScanBlock* sb)
{
- yy_delete_buffer(sb->buffer,sb->scanner);
+ vdb_kfg_yy_delete_buffer(sb->buffer,sb->scanner);
if (sb->scanner)
{
- yylex_destroy(sb->scanner);
+ vdb_kfg_yylex_destroy(sb->scanner);
}
sb->scanner=0;
sb->buffer=0;
@@ -2475,12 +2475,12 @@ void CC KFGScan_yylex_destroy(KFGScanBlock* sb)
void CC KFGScan_set_debug(bool on, KFGScanBlock* sb)
{
- yyset_debug(on ? 1 : 0,sb->scanner);
+ vdb_kfg_yyset_debug(on ? 1 : 0,sb->scanner);
}
int CC KFGScan_yylex(KFGSymbol* sym, KFGScanBlock* sb)
{
- sym->pb.tokenId=yylex(&sym->pb,sb->scanner);
+ sym->pb.tokenId=vdb_kfg_yylex(&sym->pb,sb->scanner);
sb->lastToken= &sym->pb;
switch (sym->pb.tokenId)
diff --git a/libs/kfg/config.c b/libs/kfg/config.c
index faf2380..29ebab9 100644
--- a/libs/kfg/config.c
+++ b/libs/kfg/config.c
@@ -3077,12 +3077,16 @@ rc_t open_file ( const KFile **f, const char *path )
return rc;
}
+/* KFS_EXTERN rc_t CC KFileMakeGzip2ForRead ( struct KFile const **gz, struct KFile const *src );
+#include <stdio.h> aprintf */
+static void aprintf(const char *a, int b) {}
static
rc_t decode_ncbi_gap ( KDataBuffer *mem, const KFile *orig )
{
char hdr [ 8 ];
size_t num_read;
rc_t rc = KFileReadAll ( orig, 0, hdr, sizeof hdr, & num_read );
+aprintf("decode_ncbi_gap %d\n", __LINE__);
if ( rc == 0 && num_read == sizeof hdr )
{
if (memcmp(hdr, "ncbi_gap", sizeof hdr) != 0) {
@@ -3090,19 +3094,29 @@ rc_t decode_ncbi_gap ( KDataBuffer *mem, const KFile *orig )
}
else {
uint64_t eof;
+aprintf("decode_ncbi_gap %d\n", __LINE__);
rc = KFileSize ( orig, & eof );
+aprintf("decode_ncbi_gap %d\n", __LINE__);
if ( rc == 0 )
{
const KFile *sub;
+aprintf("decode_ncbi_gap %d\n", __LINE__);
rc = KFileMakeSubRead ( & sub, orig, sizeof hdr,
eof - sizeof hdr );
+aprintf("decode_ncbi_gap %d\n", __LINE__);
if ( rc == 0 )
{
const KFile *gzip;
+aprintf("decode_ncbi_gap %d\n", __LINE__);
+
+/* aprintf rc = KFileMakeGzip2ForRead ( & gzip, sub ); */
rc = KFileMakeGzipForRead ( & gzip, sub );
+aprintf("decode_ncbi_gap %d\n", __LINE__);
if ( rc == 0 )
{
+aprintf("decode_ncbi_gap %d\n", __LINE__);
rc = KDataBufferMakeBytes ( mem, 0 );
+aprintf("decode_ncbi_gap %d\n", __LINE__);
if ( rc == 0 )
{
size_t total, to_read;
@@ -3112,16 +3126,21 @@ rc_t decode_ncbi_gap ( KDataBuffer *mem, const KFile *orig )
{
char *buff;
+aprintf("decode_ncbi_gap %d\n", __LINE__);
rc = KDataBufferResize ( mem,
total + 32 * 1024 );
+aprintf("decode_ncbi_gap %d\n", __LINE__);
if ( rc != 0 )
break;
buff = mem -> base;
+aprintf("decode_ncbi_gap %d\n", __LINE__);
to_read = ( size_t ) mem -> elem_count - total;
+aprintf("decode_ncbi_gap %d\n", __LINE__);
rc = KFileReadAll ( gzip, total,
& buff [ total ], to_read, & num_read );
+aprintf("decode_ncbi_gap %d\n", __LINE__);
if ( rc != 0 )
break;
@@ -3129,22 +3148,29 @@ rc_t decode_ncbi_gap ( KDataBuffer *mem, const KFile *orig )
if ( num_read < to_read )
{
+aprintf("decode_ncbi_gap %d\n", __LINE__);
buff [ total ] = 0;
+aprintf("decode_ncbi_gap %d\n", __LINE__);
mem -> elem_count = total;
break;
}
}
}
+aprintf("decode_ncbi_gap %d\n", __LINE__);
KFileRelease ( gzip );
+aprintf("decode_ncbi_gap %d\n", __LINE__);
}
+aprintf("decode_ncbi_gap %d\n", __LINE__);
KFileRelease ( sub );
+aprintf("decode_ncbi_gap %d\n", __LINE__);
}
}
}
}
+aprintf("decode_ncbi_gap %d\n", __LINE__);
return rc;
}
@@ -3513,6 +3539,7 @@ LIB_EXPORT rc_t CC KConfigImportNgc(KConfig *self,
else {
const KFile *orig = NULL;
rc_t rc = open_file ( & orig, ngcPath );
+/* DBGMSG(DBG_KFG, DBG_FLAG(DBG_KFG), ("KConfigImportNgc %d\n", __LINE__));*/
if (rc != 0) {
return rc;
}
@@ -3522,23 +3549,41 @@ LIB_EXPORT rc_t CC KConfigImportNgc(KConfig *self,
KDataBuffer mem;
memset ( & mem, 0, sizeof mem );
+/*DBGMSG(DBG_KFG, DBG_FLAG(DBG_KFG), ("KConfigImportNgc %d\n", __LINE__));
+aprintf("KConfigImportNgc %d\n", __LINE__); */
rc = decode_ncbi_gap ( & mem, orig );
+/*DBGMSG(DBG_KFG, DBG_FLAG(DBG_KFG), ("KConfigImportNgc %d\n", __LINE__));
+aprintf("KConfigImportNgc %d\n", __LINE__);*/
KFileRelease ( orig );
orig = NULL;
if (rc == 0) {
+/*DBGMSG(DBG_KFG, DBG_FLAG(DBG_KFG), ("KConfigImportNgc %d\n", __LINE__));
+aprintf("KConfigImportNgc %d\n", __LINE__);*/
rc = _KConfigNncToKGapConfig(self, mem.base, &kgc);
+/*DBGMSG(DBG_KFG, DBG_FLAG(DBG_KFG), ("KConfigImportNgc %d\n", __LINE__));
+aprintf("KConfigImportNgc %d\n", __LINE__);*/
}
if (rc == 0) {
+/*DBGMSG(DBG_KFG, DBG_FLAG(DBG_KFG), ("KConfigImportNgc %d\n", __LINE__));
+aprintf("KConfigImportNgc %d\n", __LINE__);*/
rc = _KConfigFixResolverCgiNode(self);
+/*DBGMSG(DBG_KFG, DBG_FLAG(DBG_KFG), ("KConfigImportNgc %d\n", __LINE__));
+aprintf("KConfigImportNgc %d\n", __LINE__);*/
}
if (rc == 0) {
+/*DBGMSG(DBG_KFG, DBG_FLAG(DBG_KFG), ("KConfigImportNgc %d\n", __LINE__));
+aprintf("KConfigImportNgc %d\n", __LINE__);*/
rc = _KConfigAddDBGapRepository(self, &kgc, repoParentPath,
newRepoParentPath);
+/*DBGMSG(DBG_KFG, DBG_FLAG(DBG_KFG), ("KConfigImportNgc %d\n", __LINE__));
+aprintf("KConfigImportNgc %d\n", __LINE__);*/
}
+/*DBGMSG(DBG_KFG, DBG_FLAG(DBG_KFG), ("KConfigImportNgc %d\n", __LINE__));
+aprintf("KConfigImportNgc %d\n", __LINE__);*/
KDataBufferWhack ( & mem );
}
diff --git a/libs/kfg/default.kfg b/libs/kfg/default.kfg
index 14f8ac9..aa5a7a7 100644
--- a/libs/kfg/default.kfg
+++ b/libs/kfg/default.kfg
@@ -29,6 +29,9 @@
/config/default = "true"
# The user's default public repository
+/repository/user/main/public/apps/file/volumes/flat = "files"
+/repository/user/main/public/apps/nakmer/volumes/nakmerFlat = "nannot"
+/repository/user/main/public/apps/nannot/volumes/nannotFlat = "nannot"
/repository/user/main/public/apps/refseq/volumes/refseq = "refseq"
/repository/user/main/public/apps/sra/volumes/sraFlat = "sra"
/repository/user/main/public/apps/wgs/volumes/wgsFlat = "wgs"
@@ -36,10 +39,18 @@
/repository/user/main/public/root = "$(HOME)/ncbi/public"
# Remote access to NCBI's public repository
-/repository/remote/main/NCBI/apps/refseq/volumes/refseq = "refseq"
-/repository/remote/main/NCBI/apps/sra/volumes/fuse1000 = "sra-instant/reads/ByRun/sra"
-/repository/remote/main/NCBI/apps/wgs/volumes/fuseWGS = "wgs"
-/repository/remote/main/NCBI/root = "http://ftp-trace.ncbi.nlm.nih.gov/sra"
+/repository/remote/main/CGI/resolver-cgi = "http://www.ncbi.nlm.nih.gov/Traces/names/names.cgi"
+/repository/remote/aux/NCBI/apps/nakmer/volumes/fuseNAKMER = "sadb"
+/repository/remote/aux/NCBI/apps/nannot/volumes/fuseNANNOT = "sadb"
+/repository/remote/aux/NCBI/apps/refseq/volumes/refseq = "refseq"
+/repository/remote/aux/NCBI/apps/sra/volumes/fuse1000 = "sra-instant/reads/ByRun/sra"
+/repository/remote/aux/NCBI/apps/wgs/volumes/fuseWGS = "wgs"
+/repository/remote/aux/NCBI/root = "http://ftp-trace.ncbi.nlm.nih.gov/sra"
# Remote access to NCBI's protected repository
/repository/remote/protected/CGI/resolver-cgi = "http://www.ncbi.nlm.nih.gov/Traces/names/names.cgi"
+
+/krypto/pwfile = "$(NCBI_HOME)/vdb-passwd"
+
+# Aspera configuration
+/tools/ascp/max_rate = "300m"
diff --git a/libs/kfs/Makefile b/libs/kfs/Makefile
index 12237b2..a50a95b 100644
--- a/libs/kfs/Makefile
+++ b/libs/kfs/Makefile
@@ -28,7 +28,8 @@ TOP ?= $(shell ../../build/abspath.sh ../..)
MODULE = libs/kfs
INT_LIBS = \
- libkfs
+ libkfs \
+ libkfs-nommap
ALL_LIBS = \
$(INT_LIBS)
@@ -62,6 +63,14 @@ clean: stdclean
.PHONY: clean
#-------------------------------------------------------------------------------
+# mmap.c
+# special rule to generate a disabled mmap
+#
+%.nommap.$(LOBX): %.c
+ $(CC) -o $@ -fPIC $(OPT) -DFORCE_MALLOC_MMAP -D_LIBRARY $<
+
+
+#-------------------------------------------------------------------------------
# kfs
#
$(ILIBDIR)/libkfs: $(addprefix $(ILIBDIR)/libkfs.,$(ILIBEXT))
@@ -104,16 +113,27 @@ KFS_CMN = \
report \
lockfile \
syslockfile \
- cacheteefile
+ cacheteefile \
+ from_to_namelist \
KFS_SRC = \
mmap \
$(KFS_CMN)
+ifeq (win,$(OS))
+ KFS_SRC += directory-path
+endif
+
+KFS_NOMMAP_SRC = \
+ mmap.nommap \
+ $(KFS_CMN)
KFS_OBJ = \
$(addsuffix .$(LOBX),$(KFS_SRC))
+KFS_NOMMAP_OBJ = \
+ $(addsuffix .$(LOBX),$(KFS_NOMMAP_SRC))
+
KFS_LIB = \
-dkproc \
-dklib \
@@ -124,6 +144,9 @@ KFS_LIB = \
$(ILIBDIR)/libkfs.$(LIBX): $(KFS_OBJ)
$(LD) --slib -o $@ $^ $(KFS_LIB)
+$(ILIBDIR)/libkfs-nommap.$(LIBX): $(KFS_NOMMAP_OBJ)
+ $(LD) --slib -o $@ $^ $(KFS_LIB)
+
#-------------------------------------------------------------------------------
# kff
diff --git a/libs/kfs/file.c b/libs/kfs/file.c
index b331a9a..22582db 100644
--- a/libs/kfs/file.c
+++ b/libs/kfs/file.c
@@ -27,8 +27,11 @@
#include <kfs/extern.h>
#include <kfs/impl.h>
#include <klib/rc.h>
+#include <kproc/timeout.h>
+#include <os-native.h>
#include <sysalloc.h>
+#include <assert.h>
/*--------------------------------------------------------------------------
* KFile
@@ -244,6 +247,38 @@ LIB_EXPORT rc_t CC KFileRead ( const KFile *self, uint64_t pos,
return RC ( rcFS, rcFile, rcReading, rcInterface, rcBadVersion );
}
+LIB_EXPORT rc_t CC KFileTimedRead ( const KFile *self, uint64_t pos,
+ void *buffer, size_t bsize, size_t *num_read, struct timeout_t *tm )
+{
+ if ( num_read == NULL )
+ return RC ( rcFS, rcFile, rcReading, rcParam, rcNull );
+
+ * num_read = 0;
+
+ if ( self == NULL )
+ return RC ( rcFS, rcFile, rcReading, rcSelf, rcNull );
+
+ if ( ! self -> read_enabled )
+ return RC ( rcFS, rcFile, rcReading, rcFile, rcNoPerm );
+
+ if ( buffer == NULL )
+ return RC ( rcFS, rcFile, rcReading, rcBuffer, rcNull );
+ if ( bsize == 0 )
+ return RC ( rcFS, rcFile, rcReading, rcBuffer, rcInsufficient );
+
+ switch ( self -> vt -> v1 . maj )
+ {
+ case 1:
+ if ( self -> vt -> v1 . min >= 2 )
+ return ( * self -> vt -> v1 . timed_read ) ( self, pos, buffer, bsize, num_read, tm );
+ if ( tm == NULL )
+ return ( * self -> vt -> v1 . read ) ( self, pos, buffer, bsize, num_read );
+ break;
+ }
+
+ return RC ( rcFS, rcFile, rcReading, rcInterface, rcBadVersion );
+}
+
/* ReadAll
* read from file until "bsize" bytes have been retrieved
* or until end-of-input
@@ -282,14 +317,39 @@ LIB_EXPORT rc_t CC KFileReadAll ( const KFile *self, uint64_t pos,
switch ( self -> vt -> v1 . maj )
{
case 1:
- for ( rc = 0, b = buffer, total = 0; total < bsize; total += count )
+ count = 0;
+ rc = ( * self -> vt -> v1 . read ) ( self, pos, buffer, bsize, & count );
+ total = count;
+
+ if ( rc == 0 && count != 0 && count < bsize )
{
- count = 0;
- rc = ( * self -> vt -> v1 . read ) ( self, pos + total, b + total, bsize - total, & count );
- if ( rc != 0 )
- break;
- if ( count == 0 )
- break;
+ if ( self -> vt -> v1 . min >= 2 )
+ {
+ timeout_t no_block;
+ TimeoutInit ( & no_block, 0 );
+
+ for ( b = buffer; total < bsize; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . timed_read ) ( self, pos + total, b + total, bsize - total, & count, & no_block );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ }
+ else
+ {
+ for ( b = buffer; total < bsize; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . read ) ( self, pos + total, b + total, bsize - total, & count );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ }
}
break;
default:
@@ -305,6 +365,218 @@ LIB_EXPORT rc_t CC KFileReadAll ( const KFile *self, uint64_t pos,
return rc;
}
+LIB_EXPORT rc_t CC KFileTimedReadAll ( const KFile *self, uint64_t pos,
+ void *buffer, size_t bsize, size_t *num_read, struct timeout_t *tm )
+{
+ rc_t rc;
+ uint8_t *b;
+ size_t total, count;
+
+ if ( num_read == NULL )
+ return RC ( rcFS, rcFile, rcReading, rcParam, rcNull );
+
+ * num_read = 0;
+
+ if ( self == NULL )
+ return RC ( rcFS, rcFile, rcReading, rcSelf, rcNull );
+
+ if ( ! self -> read_enabled )
+ return RC ( rcFS, rcFile, rcReading, rcFile, rcNoPerm );
+
+ if ( buffer == NULL )
+ return RC ( rcFS, rcFile, rcReading, rcBuffer, rcNull );
+ if ( bsize == 0 )
+ return RC ( rcFS, rcFile, rcReading, rcBuffer, rcInsufficient );
+
+ switch ( self -> vt -> v1 . maj )
+ {
+ case 1:
+ if ( self -> vt -> v1 . min >= 2 )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . timed_read ) ( self, pos, buffer, bsize, & count, tm );
+ total = count;
+
+ if ( rc == 0 && count != 0 && count < bsize )
+ {
+ timeout_t no_block;
+ TimeoutInit ( & no_block, 0 );
+
+ for ( b = buffer; total < bsize; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . timed_read ) ( self, pos + total, b + total, bsize - total, & count, & no_block );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ }
+ break;
+ }
+
+ if ( tm == NULL )
+ {
+ for ( rc = 0, b = buffer, total = 0; total < bsize; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . read ) ( self, pos + total, b + total, bsize - total, & count );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ break;
+ }
+
+ /* no break */
+ default:
+ return RC ( rcFS, rcFile, rcReading, rcInterface, rcBadVersion );
+ }
+
+ if ( total != 0 )
+ {
+ * num_read = total;
+ return 0;
+ }
+
+ return rc;
+}
+
+/* ReadExactly
+ * TimedReadExactly
+ * read from file until "bytes" have been retrieved
+ * or return incomplete transfer error
+ *
+ * "pos" [ IN ] - starting position within file
+ *
+ * "buffer" [ OUT ] and "bytes" [ IN ] - return buffer for read
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed reads. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
+ */
+LIB_EXPORT rc_t CC KFileReadExactly ( const KFile *self,
+ uint64_t pos, void *buffer, size_t bytes )
+{
+ rc_t rc;
+ uint8_t *b;
+ size_t total, count;
+
+ if ( self == NULL )
+ return RC ( rcFS, rcFile, rcReading, rcSelf, rcNull );
+
+ if ( ! self -> read_enabled )
+ return RC ( rcFS, rcFile, rcReading, rcFile, rcNoPerm );
+
+ if ( bytes == 0 )
+ return 0;
+ if ( buffer == NULL )
+ return RC ( rcFS, rcFile, rcReading, rcBuffer, rcNull );
+
+ switch ( self -> vt -> v1 . maj )
+ {
+ case 1:
+ assert ( bytes != 0 );
+ for ( b = buffer, total = 0; total < bytes; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . read ) ( self, pos + total, b + total, bytes - total, & count );
+ if ( rc != 0 )
+ {
+ if ( GetRCObject ( rc ) != rcTimeout || GetRCState ( rc ) != rcExhausted )
+ break;
+ }
+ else if ( count == 0 )
+ {
+ rc = RC ( rcFS, rcFile, rcReading, rcTransfer, rcIncomplete );
+ break;
+ }
+ }
+ break;
+ default:
+ rc = RC ( rcFS, rcFile, rcReading, rcInterface, rcBadVersion );
+ }
+
+ return rc;
+}
+
+LIB_EXPORT rc_t CC KFileTimedReadExactly ( const KFile *self,
+ uint64_t pos, void *buffer, size_t bytes, struct timeout_t *tm )
+{
+ rc_t rc;
+ uint8_t *b;
+ size_t total, count;
+
+ if ( self == NULL )
+ return RC ( rcFS, rcFile, rcReading, rcSelf, rcNull );
+
+ if ( ! self -> read_enabled )
+ return RC ( rcFS, rcFile, rcReading, rcFile, rcNoPerm );
+
+ if ( bytes == 0 )
+ return 0;
+ if ( buffer == NULL )
+ return RC ( rcFS, rcFile, rcReading, rcBuffer, rcNull );
+
+ switch ( self -> vt -> v1 . maj )
+ {
+ case 1:
+ if ( self -> vt -> v1 . min >= 2 )
+ {
+ assert ( bytes != 0 );
+ for ( b = buffer, total = 0; total < bytes; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . timed_read ) ( self, pos + total, b + total, bytes - total, & count, tm );
+ if ( rc != 0 )
+ {
+ if ( tm != NULL )
+ break;
+ if ( GetRCObject ( rc ) != rcTimeout || GetRCState ( rc ) != rcExhausted )
+ break;
+ }
+ else if ( count == 0 )
+ {
+ rc = RC ( rcFS, rcFile, rcReading, rcTransfer, rcIncomplete );
+ break;
+ }
+ }
+ break;
+ }
+
+ if ( tm == NULL )
+ {
+ assert ( bytes != 0 );
+ for ( b = buffer, total = 0; total < bytes; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . read ) ( self, pos + total, b + total, bytes - total, & count );
+ if ( rc != 0 )
+ {
+ if ( GetRCObject ( rc ) != rcTimeout || GetRCState ( rc ) != rcExhausted )
+ break;
+ }
+ else if ( count == 0 )
+ {
+ rc = RC ( rcFS, rcFile, rcReading, rcTransfer, rcIncomplete );
+ break;
+ }
+ }
+ break;
+ }
+
+ /* no break */
+ default:
+ return RC ( rcFS, rcFile, rcReading, rcInterface, rcBadVersion );
+ }
+
+ return rc;
+}
+
/* Write
* write file at known position
*
@@ -315,7 +587,7 @@ LIB_EXPORT rc_t CC KFileReadAll ( const KFile *self, uint64_t pos,
* "num_writ" [ OUT ] - number of bytes actually written
*/
LIB_EXPORT rc_t CC KFileWrite ( KFile *self, uint64_t pos,
- const void *buffer, size_t size, size_t *num_writ)
+ const void *buffer, size_t size, size_t *num_writ )
{
size_t ignore;
if ( num_writ == NULL )
@@ -343,6 +615,39 @@ LIB_EXPORT rc_t CC KFileWrite ( KFile *self, uint64_t pos,
return RC ( rcFS, rcFile, rcWriting, rcInterface, rcBadVersion );
}
+LIB_EXPORT rc_t CC KFileTimedWrite ( KFile *self, uint64_t pos,
+ const void *buffer, size_t size, size_t *num_writ, struct timeout_t *tm )
+{
+ size_t ignore;
+ if ( num_writ == NULL )
+ num_writ = & ignore;
+
+ * num_writ = 0;
+
+ if ( self == NULL )
+ return RC ( rcFS, rcFile, rcWriting, rcSelf, rcNull );
+
+ if ( ! self -> write_enabled )
+ return RC ( rcFS, rcFile, rcWriting, rcFile, rcNoPerm );
+
+ if ( size == 0 )
+ return 0;
+ if ( buffer == NULL )
+ return RC ( rcFS, rcFile, rcWriting, rcBuffer, rcNull );
+
+ switch ( self -> vt -> v1 . maj )
+ {
+ case 1:
+ if ( self -> vt -> v1 . min >= 2 )
+ return ( * self -> vt -> v1 . timed_write ) ( self, pos, buffer, size, num_writ, tm );
+ if ( tm == NULL )
+ return ( * self -> vt -> v1 . write ) ( self, pos, buffer, size, num_writ );
+ break;
+ }
+
+ return RC ( rcFS, rcFile, rcWriting, rcInterface, rcBadVersion );
+}
+
/* WriteAll
* write from file until "size" bytes have been transferred
* or until no further progress can be made
@@ -381,14 +686,39 @@ LIB_EXPORT rc_t CC KFileWriteAll ( KFile *self, uint64_t pos,
switch ( self -> vt -> v1 . maj )
{
case 1:
- for ( rc = 0, b = buffer, total = 0; total < size; total += count )
+ count = 0;
+ rc = ( * self -> vt -> v1 . write ) ( self, pos, buffer, size, & count );
+ total = count;
+
+ if ( rc == 0 && count != 0 && count < size )
{
- count = 0;
- rc = ( * self -> vt -> v1 . write ) ( self, pos + total, b + total, size - total, & count );
- if ( rc != 0 )
- break;
- if ( count == 0 )
- break;
+ if ( self -> vt -> v1 . min >= 2 )
+ {
+ timeout_t no_block;
+ TimeoutInit ( & no_block, 0 );
+
+ for ( b = buffer; total < size; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . timed_write ) ( self, pos + total, b + total, size - total, & count, & no_block );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ }
+ else
+ {
+ for ( b = buffer; total < size; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . write ) ( self, pos + total, b + total, size - total, & count );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ }
}
break;
default:
@@ -403,6 +733,75 @@ LIB_EXPORT rc_t CC KFileWriteAll ( KFile *self, uint64_t pos,
return rc;
}
+LIB_EXPORT rc_t CC KFileTimedWriteAll ( KFile *self, uint64_t pos,
+ const void *buffer, size_t size, size_t *num_writ, struct timeout_t *tm )
+{
+ rc_t rc;
+ const uint8_t *b;
+ size_t total, count;
+
+ size_t ignore;
+ if ( num_writ == NULL )
+ num_writ = & ignore;
+
+ * num_writ = 0;
+
+ if ( self == NULL )
+ return RC ( rcFS, rcFile, rcWriting, rcSelf, rcNull );
+
+ if ( ! self -> write_enabled )
+ return RC ( rcFS, rcFile, rcWriting, rcFile, rcNoPerm );
+
+ if ( size == 0 )
+ return 0;
+ if ( buffer == NULL )
+ return RC ( rcFS, rcFile, rcWriting, rcBuffer, rcNull );
+
+ switch ( self -> vt -> v1 . maj )
+ {
+ case 1:
+ if ( self -> vt -> v1 . min >= 2 )
+ {
+ for ( rc = 0, b = buffer, total = 0; total < size; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . timed_write ) ( self, pos + total, b + total, size - total, & count, tm );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ break;
+ }
+
+ if ( tm == NULL )
+ {
+ for ( rc = 0, b = buffer, total = 0; total < size; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . write ) ( self, pos + total, b + total, size - total, & count );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ break;
+ }
+
+ /* no break */
+
+ default:
+ return RC ( rcFS, rcFile, rcWriting, rcInterface, rcBadVersion );
+ }
+
+ * num_writ = total;
+ if ( total == size )
+ return 0;
+ if ( rc == 0 )
+ return RC ( rcFS, rcFile, rcWriting, rcTransfer, rcIncomplete );
+ return rc;
+}
+
/* Init
* initialize a newly allocated file object
*/
@@ -423,6 +822,12 @@ LIB_EXPORT rc_t CC KFileInit ( KFile *self, const KFile_vt *vt,
switch ( vt -> v1 . min )
{
/* ADD NEW MINOR VERSION CASES HERE */
+ case 2:
+#if _DEBUGGING
+ if ( vt -> v1 . timed_write == NULL ||
+ vt -> v1 . timed_read == NULL )
+ return RC ( rcFS, rcFile, rcConstructing, rcInterface, rcNull );
+#endif
case 1:
#if _DEBUGGING
if ( vt -> v1 . get_type == NULL )
diff --git a/libs/kfs/from_to_namelist.c b/libs/kfs/from_to_namelist.c
new file mode 100644
index 0000000..a3c8390
--- /dev/null
+++ b/libs/kfs/from_to_namelist.c
@@ -0,0 +1,307 @@
+/*===========================================================================
+ *
+ * PUBLIC DOMAIN NOTICE
+ * National Center for Biotechnology Information
+ *
+ * This software/database is a "United States Government Work" under the
+ * terms of the United States Copyright Act. It was written as part of
+ * the author's official duties as a United States Government employee and
+ * thus cannot be copyrighted. This software/database is freely available
+ * to the public for use. The National Library of Medicine and the U.S.
+ * Government have not placed any restriction on its use or reproduction.
+ *
+ * Although all reasonable efforts have been taken to ensure the accuracy
+ * and reliability of the software and data, the NLM and the U.S.
+ * Government do not and cannot warrant the performance or results that
+ * may be obtained by using this software or data. The NLM and the U.S.
+ * Government disclaim all warranties, express or implied, including
+ * warranties of performance, merchantability or fitness for any particular
+ * purpose.
+ *
+ * Please cite the author in any work or product based on this material.
+ *
+ * ===========================================================================
+ */
+
+#include <kfs/extern.h>
+
+#include <klib/rc.h>
+#include <klib/log.h>
+#include <klib/text.h>
+#include <klib/printf.h>
+#include <klib/namelist.h>
+
+#include <kfs/file.h>
+#include <kfs/directory.h>
+
+#include <sysalloc.h>
+#include <stdlib.h>
+#include <string.h>
+#include <assert.h>
+
+
+/* ****************************************************************************************** */
+
+
+#define STATE_ALPHA 0
+#define STATE_LF 1
+#define STATE_NL 2
+
+
+typedef struct buffer_range
+{
+ const char * start;
+ uint32_t processed, count, state;
+} buffer_range;
+
+
+static const char empty_str[ 2 ] = { ' ', 0 };
+
+
+static void LoadFromBuffer( VNamelist * nl, buffer_range * range )
+{
+ uint32_t idx;
+ const char * p = range->start;
+ String S;
+
+ S.addr = p;
+ S.len = S.size = range->processed;
+ for ( idx = range->processed; idx < range->count; ++idx )
+ {
+ switch( p[ idx ] )
+ {
+ case 0x0A : switch( range->state )
+ {
+ case STATE_ALPHA : /* ALPHA --> LF */
+ VNamelistAppendString ( nl, &S );
+ range->state = STATE_LF;
+ break;
+
+ case STATE_LF : /* LF --> LF */
+ VNamelistAppend ( nl, empty_str );
+ break;
+
+ case STATE_NL : /* NL --> LF */
+ VNamelistAppend ( nl, empty_str );
+ range->state = STATE_LF;
+ break;
+ }
+ break;
+
+ case 0x0D : switch( range->state )
+ {
+ case STATE_ALPHA : /* ALPHA --> NL */
+ VNamelistAppendString ( nl, &S );
+ range->state = STATE_NL;
+ break;
+
+ case STATE_LF : /* LF --> NL */
+ range->state = STATE_NL;
+ break;
+
+ case STATE_NL : /* NL --> NL */
+ VNamelistAppend ( nl, empty_str );
+ break;
+ }
+ break;
+
+ default : switch( range->state )
+ {
+ case STATE_ALPHA : /* ALPHA --> ALPHA */
+ S.len++; S.size++;
+ break;
+
+ case STATE_LF : /* LF --> ALPHA */
+ S.addr = &p[ idx ]; S.len = S.size = 1;
+ range->state = STATE_ALPHA;
+ break;
+
+ case STATE_NL : /* NL --> ALPHA */
+ S.addr = &p[ idx ]; S.len = S.size = 1;
+ range->state = STATE_ALPHA;
+ break;
+ }
+ break;
+ }
+ }
+ if ( range->state == STATE_ALPHA )
+ {
+ range->start = S.addr;
+ range->count = S.len;
+ }
+ else
+ range->count = 0;
+}
+
+
+static rc_t LoadFromFile( struct KFile const * f, VNamelist * nl )
+{
+ rc_t rc = 0;
+ uint64_t pos = 0;
+ char buffer[ 4096 ];
+ buffer_range range;
+ bool done = false;
+
+ range.start = buffer;
+ range.count = 0;
+ range.processed = 0;
+ range.state = STATE_ALPHA;
+
+ do
+ {
+ size_t num_read;
+ rc = KFileRead ( f, pos, ( char * )( range.start + range.processed ),
+ ( sizeof buffer ) - range.processed, &num_read );
+ if ( rc == 0 )
+ {
+ done = ( num_read == 0 );
+ if ( !done )
+ {
+ range.start = buffer;
+ range.count = range.processed + num_read;
+
+ LoadFromBuffer( nl, &range );
+ if ( range.count > 0 )
+ {
+ memmove ( buffer, range.start, range.count );
+ }
+ range.start = buffer;
+ range.processed = range.count;
+
+ pos += num_read;
+ }
+ else if ( range.state == STATE_ALPHA )
+ {
+ String S;
+ S.addr = range.start;
+ S.len = S.size = range.count;
+ VNamelistAppendString ( nl, &S );
+ }
+ }
+ } while ( rc == 0 && !done );
+
+ return rc;
+}
+
+
+/* -----
+
+ * loads the content of a KFile into a Namelist
+ *
+ */
+LIB_EXPORT rc_t CC LoadKFileToNameList( struct KFile const * self, VNamelist * namelist )
+{
+ rc_t rc;
+ if ( self == NULL )
+ rc = RC( rcFS, rcFile, rcValidating, rcSelf, rcNull );
+ else if ( namelist == NULL )
+ rc = RC( rcFS, rcFile, rcValidating, rcParam, rcNull );
+ else
+ rc = LoadFromFile( self, namelist );
+ return rc;
+}
+
+
+LIB_EXPORT rc_t CC LoadFileByNameToNameList( VNamelist * namelist, const char * filename )
+{
+ rc_t rc;
+ if ( namelist == NULL || filename == NULL )
+ rc = RC( rcFS, rcFile, rcValidating, rcParam, rcNull );
+ else
+ {
+ KDirectory * dir;
+ rc = KDirectoryNativeDir ( &dir );
+ if ( rc == 0 )
+ {
+ KFile const * f;
+ rc = KDirectoryOpenFileRead ( dir, &f, "%s", filename );
+ if ( rc == 0 )
+ {
+ if ( rc == 0 )
+ rc = LoadFromFile( f, namelist );
+ KFileRelease ( f );
+ }
+ KDirectoryRelease ( dir );
+ }
+ }
+ return rc;
+
+}
+
+
+static rc_t SaveToFile( struct KFile * f, const VNamelist * nl, const char * delim )
+{
+ uint32_t count;
+ rc_t rc = VNameListCount ( nl, &count );
+ if ( rc == 0 && count > 0 )
+ {
+ uint32_t idx;
+ uint64_t pos = 0;
+ for ( idx = 0; idx < count && rc == 0; ++idx )
+ {
+ const char * s;
+ rc = VNameListGet ( nl, idx, &s );
+ if ( rc == 0 && s != NULL )
+ {
+ size_t num_writ;
+ rc = KFileWriteAll ( f, pos, s, string_size ( s ), &num_writ );
+ if ( rc == 0 )
+ {
+ pos += num_writ;
+ rc = KFileWriteAll ( f, pos, delim, string_size ( delim ), &num_writ );
+ if ( rc == 0 )
+ pos += num_writ;
+ }
+ }
+ }
+ if ( rc == 0 )
+ rc = KFileSetSize ( f, pos );
+ }
+ return rc;
+}
+
+/* -----
+
+ * writes content of a Namelist into a KFile
+ *
+ */
+
+LIB_EXPORT rc_t CC WriteNameListToKFile( struct KFile * self, const VNamelist * namelist,
+ const char * delim )
+{
+ rc_t rc;
+ if ( self == NULL )
+ rc = RC( rcFS, rcFile, rcValidating, rcSelf, rcNull );
+ else if ( namelist == NULL )
+ rc = RC( rcFS, rcFile, rcValidating, rcParam, rcNull );
+ else
+ rc = SaveToFile( self, namelist, delim );
+ return rc;
+}
+
+
+LIB_EXPORT rc_t CC WriteNamelistToFileByName( const VNamelist * namelist, const char * filename,
+ const char * delim )
+{
+ rc_t rc;
+ if ( namelist == NULL || filename == NULL || delim == NULL )
+ rc = RC( rcFS, rcFile, rcValidating, rcParam, rcNull );
+ else
+ {
+ KDirectory * dir;
+ rc = KDirectoryNativeDir ( &dir );
+ if ( rc == 0 )
+ {
+ KFile * f;
+ rc = KDirectoryCreateFile ( dir, &f, true, 0664, kcmCreate, filename );
+ if ( rc == 0 )
+ {
+ if ( rc == 0 )
+ rc = SaveToFile( f, namelist, delim );
+ KFileRelease ( f );
+ }
+ KDirectoryRelease ( dir );
+ }
+ }
+ return rc;
+}
\ No newline at end of file
diff --git a/libs/kfs/gzip.c b/libs/kfs/gzip.c
index b8bd6bb..beb22fb 100644
--- a/libs/kfs/gzip.c
+++ b/libs/kfs/gzip.c
@@ -1,4 +1,4 @@
-/*=======================================================================================
+/*==============================================================================
*
* PUBLIC DOMAIN NOTICE
* National Center for Biotechnology Information
@@ -38,6 +38,7 @@ struct KGZipFile;
#include <zlib.h> /* z_stream */
#include <assert.h>
#include <stdlib.h> /* malloc */
+#include <string.h> /* memset */
#ifdef _DEBUGGING
#define GZIP_DEBUG(msg) DBGMSG(DBG_KFS,DBG_FLAG(DBG_KFS_GZIP), msg)
@@ -581,3 +582,65 @@ static int s_GzipAndWrite ( KGZipFile *self,
}
/* EOF */
+
+#include <stdio.h> /* printf */
+LIB_EXPORT rc_t CC KFileMakeGzip2ForRead( const struct KFile **result,
+ const struct KFile *file )
+{
+ rc_t rc;
+ z_stream* strm;
+ KGZipFile *obj;
+
+ if ( result == NULL || file == NULL )
+ return RC ( rcFS, rcFile, rcConstructing, rcParam, rcNull );
+
+ obj = (KGZipFile*) malloc(sizeof(KGZipFile));
+ if (!obj)
+ return RC ( rcFS, rcFile, rcConstructing, rcMemory, rcExhausted );
+
+printf("KFileMakeGzip2ForRead %d\n", __LINE__);
+ rc = KFileInit(&obj->dad, (const KFile_vt*) &s_vtKFile_InGz, "KGZipFile", "no-name", true, false);
+printf("KFileMakeGzip2ForRead %d\n", __LINE__);
+ if (rc != 0) {
+ free(obj);
+ return rc;
+ }
+
+ strm = &obj->strm;
+ memset(strm, 0, sizeof *strm);
+ strm->zalloc = Z_NULL;
+ strm->zfree = Z_NULL;
+ strm->opaque = Z_NULL;
+ strm->avail_in = 0;
+ strm->next_in = Z_NULL;
+
+ /* TBD - this should check gzlib error codes */
+printf("KFileMakeGzip2ForRead %d\n", __LINE__);
+ if (inflateInit2(strm, WINDOW_BITS) != Z_OK) {
+ free(obj);
+ return RC ( rcFS, rcFile, rcConstructing, rcNoObj, rcUnknown );
+ }
+
+printf("KFileMakeGzip2ForRead %d\n", __LINE__);
+ obj->myPosition = 0;
+ obj->filePosition = 0;
+
+printf("KFileMakeGzip2ForRead %d\n", __LINE__);
+ rc = KFileAddRef(file);
+ if ( rc != 0 )
+ {
+printf("KFileMakeGzip2ForRead %d\n", __LINE__);
+ obj->file = NULL;
+ KGZipFile_InDestroy ( obj );
+ }
+ else
+ {
+printf("KFileMakeGzip2ForRead %d\n", __LINE__);
+ obj->file = (KFile*) file;
+ obj->completed = true; /* we could have an empty file and this would be okay */
+ *result = &obj->dad;
+ }
+
+printf("KFileMakeGzip2ForRead %d\n", __LINE__);
+ return rc;
+}
diff --git a/libs/kfs/win/sysdir-priv.h b/libs/kfs/win/sysdir-priv.h
index 7bfe65a..1ae8cc7 100644
--- a/libs/kfs/win/sysdir-priv.h
+++ b/libs/kfs/win/sysdir-priv.h
@@ -78,6 +78,13 @@ rc_t KSysDirMakePath ( const KSysDir* self, enum RCContext ctx, bool canon,
#endif
+/* OSPath
+ * returns a real OS path
+ */
+rc_t KSysDirOSPath ( const KSysDir *self,
+ wchar_t *real, size_t bsize, const char *path, va_list args );
+
+
#ifdef __cplusplus
}
#endif
diff --git a/libs/kfs/win/sysdir.c b/libs/kfs/win/sysdir.c
index 159c54c..f3706ef 100644
--- a/libs/kfs/win/sysdir.c
+++ b/libs/kfs/win/sysdir.c
@@ -1656,12 +1656,15 @@ rc_t KSysDirRemoveEntry ( wchar_t *path, size_t path_max, bool force )
}
else
rc = RC ( rcFS, rcDirectory, rcRemoving, rcDirectory, rcUnauthorized );
+ break;
case ERROR_ACCESS_DENIED :
rc = RC ( rcFS, rcDirectory, rcRemoving, rcDirectory, rcUnauthorized );
+ break;
default :
rc = RC ( rcFS, rcDirectory, rcCreating, rcNoObj, rcUnknown );
+ break;
}
print_error_for( path, "RemoveDirectoryW", rcRemoving, klogInfo);
diff --git a/libs/klib/Makefile b/libs/klib/Makefile
index f2ba1ea..699815f 100644
--- a/libs/klib/Makefile
+++ b/libs/klib/Makefile
@@ -95,6 +95,7 @@ KLIB_SRC = \
ptpersist.nopt \
crc32 \
md5 \
+ misc \
SHA-32bit \
SHA-64bit \
qsort \
diff --git a/libs/klib/printf.c b/libs/klib/printf.c
index 44bba83..0edc914 100644
--- a/libs/klib/printf.c
+++ b/libs/klib/printf.c
@@ -2214,7 +2214,7 @@ static
rc_t flush_buffer ( KBufferedWrtHandler *out )
{
const KWrtHandler *flush = out -> handler;
- if ( out -> handler != NULL )
+ if ( flush != NULL && flush -> writer != NULL )
{
rc_t rc = 0;
size_t num_writ, flushed;
diff --git a/libs/klib/release-vers.h b/libs/klib/release-vers.h
index 04f64a3..6d1bcc8 100644
--- a/libs/klib/release-vers.h
+++ b/libs/klib/release-vers.h
@@ -27,7 +27,7 @@
/* THIS FILE IS NOT GENERATED AUTOMATICALLY! */
/* The Version of current SRA Toolkit Release */
-#define RELEASE_VERS 0x02030004
+#define RELEASE_VERS 0x02030005
/* The Revision of Version of current SRA Toolkit Release */
#define RELEASE_REVISION 2
diff --git a/libs/klib/report.c b/libs/klib/report.c
index c1207e6..5da2b46 100644
--- a/libs/klib/report.c
+++ b/libs/klib/report.c
@@ -30,15 +30,17 @@
#include <kfs/directory.h> /* KDirectoryNativeDir */
-#include <klib/report.h> /* ReportInit */
-#include <klib/namelist.h> /* KNamelistRelease */
-#include <klib/time.h> /* KTime */
-#include <klib/text.h> /* string_printf */
-#include <klib/printf.h> /* string_printf */
+#include <klib/klib-priv.h>
#include <klib/log.h> /* LOGERR */
+#include <klib/misc.h> /* is_iser_an_admin */
+#include <klib/namelist.h> /* KNamelistRelease */
#include <klib/out.h> /* OUTMSG */
+#include <klib/printf.h> /* string_printf */
#include <klib/rc.h>
-#include <klib/klib-priv.h>
+#include <klib/report.h> /* ReportInit */
+#include <klib/time.h> /* KTime */
+#include <klib/text.h> /* string_printf */
+
#include <atomic.h> /* atomic_test_and_set_ptr */
#include <stdarg.h> /* va_start */
@@ -486,6 +488,9 @@ static rc_t ReportRun(int indent, rc_t rc_in) {
report(indent + 1, "Result", 1, "rc", 'R', rc_in);
+ report(indent + 1, "User", 1,
+ "admin", 's', is_iser_an_admin() ? "true" : "false");
+
reportClose(indent, tag);
return rc;
diff --git a/libs/kns/unix/sysmgr.c b/libs/klib/unix/misc.c
similarity index 89%
copy from libs/kns/unix/sysmgr.c
copy to libs/klib/unix/misc.c
index 702675b..e42e332 100644
--- a/libs/kns/unix/sysmgr.c
+++ b/libs/klib/unix/misc.c
@@ -23,13 +23,11 @@
* ===========================================================================
*
*/
-#include "kns_mgr_priv.h"
-rc_t KNSManagerInit ( struct KNSManager *self )
-{
- return 0;
-}
+#include <klib/misc.h> /* is_iser_an_admin */
-void KNSManagerCleanup ( struct KNSManager *self )
-{
+#include <unistd.h> /* geteuid */
+
+LIB_EXPORT bool CC is_iser_an_admin(void) {
+ return geteuid() == 0;
}
diff --git a/libs/klib/unix/systime.c b/libs/klib/unix/systime.c
index 09b9b90..458abb9 100644
--- a/libs/klib/unix/systime.c
+++ b/libs/klib/unix/systime.c
@@ -106,3 +106,34 @@ LIB_EXPORT const KTime* CC KTimeGlobal ( KTime *kt, KTime_t ts )
}
return kt;
}
+
+
+/* MakeTime
+ * make a KTime_t from KTime
+ */
+LIB_EXPORT KTime_t CC KTimeMakeTime ( const KTime *self )
+{
+ KTime_t ts = 0;
+
+ if ( self != NULL )
+ {
+ struct tm t;
+
+ assert ( self -> year >= 1900 );
+ t . tm_year = self -> year - 1900;
+ t . tm_mon = self -> month;
+ t . tm_mday = self -> day + 1;
+ t . tm_wday = self -> weekday;
+#if !defined(__SunOS) && !defined(__sun__)
+ t . tm_gmtoff = self -> tzoff * 60;
+#endif
+ t . tm_hour = self -> hour;
+ t . tm_min = self -> minute;
+ t . tm_sec = self -> second;
+ t . tm_isdst = self -> dst;
+
+ ts = mktime ( &t );
+ }
+
+ return ts;
+}
diff --git a/libs/klib/vector_namelist.c b/libs/klib/vector_namelist.c
index 072e529..940ce57 100644
--- a/libs/klib/vector_namelist.c
+++ b/libs/klib/vector_namelist.c
@@ -259,12 +259,13 @@ LIB_EXPORT rc_t CC VNamelistIndexOf( VNamelist *self, const char* s, uint32_t *f
return rc;
}
-LIB_EXPORT rc_t CC VNamelistRemove( VNamelist *self, const char* s )
-{
- uint32_t idx;
- rc_t rc = VNamelistIndexOf( self, s, &idx );
- if ( rc == 0 )
+LIB_EXPORT rc_t CC VNamelistRemoveIdx( VNamelist *self, uint32_t idx )
+{
+ rc_t rc;
+ if ( self == NULL )
+ rc = RC ( rcCont, rcNamelist, rcSearching, rcSelf, rcNull );
+ else
{
char *removed;
rc = VectorRemove ( &(self->name_vector), idx, (void **)&removed );
@@ -275,6 +276,30 @@ LIB_EXPORT rc_t CC VNamelistRemove( VNamelist *self, const char* s )
}
+LIB_EXPORT rc_t CC VNamelistRemove( VNamelist *self, const char* s )
+{
+ uint32_t idx;
+
+ rc_t rc = VNamelistIndexOf( self, s, &idx );
+ if ( rc == 0 )
+ rc = VNamelistRemoveIdx( self, idx );
+ return rc;
+}
+
+
+LIB_EXPORT rc_t CC VNamelistRemoveAll( VNamelist *self )
+{
+ rc_t rc = 0;
+ uint32_t count = 1;
+ while ( count > 0 && rc == 0 )
+ {
+ rc = VNameListCount ( self, &count );
+ if ( rc == 0 && count > 0 )
+ rc = VNamelistRemoveIdx( self, count - 1 );
+ }
+ return rc;
+}
+
/* Reorder
* sort the names according to case sensitivity
@@ -329,3 +354,4 @@ LIB_EXPORT void CC VNamelistReorder ( VNamelist *self, bool case_insensitive )
VectorReorder ( & self -> name_vector, case_insensitive ? vect_string_cmp_case : vect_string_cmp, NULL );
}
}
+
diff --git a/libs/kns/unix/sysmgr.c b/libs/klib/win/misc.c
similarity index 88%
copy from libs/kns/unix/sysmgr.c
copy to libs/klib/win/misc.c
index 702675b..f204e34 100644
--- a/libs/kns/unix/sysmgr.c
+++ b/libs/klib/win/misc.c
@@ -23,13 +23,11 @@
* ===========================================================================
*
*/
-#include "kns_mgr_priv.h"
-rc_t KNSManagerInit ( struct KNSManager *self )
-{
- return 0;
-}
+#include <klib/misc.h> /* is_iser_an_admin */
-void KNSManagerCleanup ( struct KNSManager *self )
-{
+#include <Shlobj.h> /* IsUserAnAdmin */
+
+LIB_EXPORT bool CC is_iser_an_admin(void) {
+ return IsUserAnAdmin();
}
diff --git a/libs/kns/KCurlFile.c b/libs/kns/KCurlFile.c
deleted file mode 100644
index 243fd40..0000000
--- a/libs/kns/KCurlFile.c
+++ /dev/null
@@ -1,716 +0,0 @@
-/*===========================================================================
-*
-* PUBLIC DOMAIN NOTICE
-* National Center for Biotechnology Information
-*
-* This software/database is a "United States Government Work" under the
-* terms of the United States Copyright Act. It was written as part of
-* the author's official duties as a United States Government employee and
-* thus cannot be copyrighted. This software/database is freely available
-* to the public for use. The National Library of Medicine and the U.S.
-* Government have not placed any restriction on its use or reproduction.
-*
-* Although all reasonable efforts have been taken to ensure the accuracy
-* and reliability of the software and data, the NLM and the U.S.
-* Government do not and cannot warrant the performance or results that
-* may be obtained by using this software or data. The NLM and the U.S.
-* Government disclaim all warranties, express or implied, including
-* warranties of performance, merchantability or fitness for any particular
-* purpose.
-*
-* Please cite the author in any work or product based on this material.
-*
-* ===========================================================================
-*
-*/
-
-/* NOTE: uses VFS not KNS extern.h */
-#include <vfs/extern.h>
-
-struct KCurlFile;
-#define KFILE_IMPL struct KCurlFile
-#include <kfs/impl.h>
-
-#include <klib/rc.h>
-#include <klib/log.h>
-#include <klib/out.h>
-#include <klib/text.h>
-#include <klib/printf.h>
-#include <kns/manager.h>
-
-#include "kns_mgr_priv.h"
-
-#include <sysalloc.h>
-#include <stdlib.h>
-#include <string.h>
-
-#define HTTP_RESPONSE_CODE_0_VALID false
-
-/*--------------------------------------------------------------------------
- * KCurFile
- */
-
-typedef struct KCurlFile
-{
- KFile dad;
- uint64_t file_size;
- struct KNSManager *kns_mgr;
- CURL *curl_handle;
- bool file_size_valid;
- bool verbose;
- bool is_ftp;
- char url[ 1 ];
-} KCurlFile;
-
-
-typedef struct ReadContext
-{
- CURL *curl_handle;
- uint8_t * buffer;
- size_t buffer_size;
- size_t num_read;
- bool curl_handle_prepared;
-} ReadContext;
-
-static
-const char *curly_errstr ( CURLcode code )
-{
- switch ( ( int ) code )
- {
-#define CURL_CASE( c ) \
- case c: return # c
-#define CURL_CASE2( c, old ) \
- case old: return # c "(" #old ")"
-
- CURL_CASE ( CURLE_OK );
- CURL_CASE ( CURLE_UNSUPPORTED_PROTOCOL );
- CURL_CASE ( CURLE_FAILED_INIT );
- CURL_CASE ( CURLE_URL_MALFORMAT );
- CURL_CASE2 ( CURLE_OBSOLETE4, CURLE_URL_MALFORMAT_USER );
- CURL_CASE ( CURLE_COULDNT_RESOLVE_PROXY );
- CURL_CASE ( CURLE_COULDNT_RESOLVE_HOST );
- CURL_CASE ( CURLE_COULDNT_CONNECT );
- CURL_CASE ( CURLE_FTP_WEIRD_SERVER_REPLY );
- CURL_CASE2 ( CURLE_REMOTE_ACCESS_DENIED, CURLE_FTP_ACCESS_DENIED );
- CURL_CASE2 ( CURLE_OBSOLETE10, CURLE_FTP_USER_PASSWORD_INCORRECT );
- CURL_CASE ( CURLE_FTP_WEIRD_PASS_REPLY );
- CURL_CASE2 ( CURLE_OBSOLETE12, CURLE_FTP_WEIRD_USER_REPLY );
- CURL_CASE ( CURLE_FTP_WEIRD_PASV_REPLY );
- CURL_CASE ( CURLE_FTP_WEIRD_227_FORMAT );
- CURL_CASE ( CURLE_FTP_CANT_GET_HOST );
- CURL_CASE2 ( CURLE_OBSOLETE16, CURLE_FTP_CANT_RECONNECT );
- CURL_CASE2 ( CURLE_FTP_COULDNT_SET_TYPE, CURLE_FTP_COULDNT_SET_BINARY );
- CURL_CASE ( CURLE_PARTIAL_FILE );
- CURL_CASE ( CURLE_FTP_COULDNT_RETR_FILE );
- CURL_CASE2 ( CURLE_OBSOLETE20, CURLE_FTP_WRITE_ERROR );
- CURL_CASE2 ( CURLE_QUOTE_ERROR, CURLE_FTP_QUOTE_ERROR );
- CURL_CASE ( CURLE_HTTP_RETURNED_ERROR );
- CURL_CASE ( CURLE_WRITE_ERROR );
- CURL_CASE2 ( CURLE_OBSOLETE24, CURLE_MALFORMAT_USER );
- CURL_CASE2 ( CURLE_UPLOAD_FAILED, CURLE_FTP_COULDNT_STOR_FILE );
- CURL_CASE ( CURLE_READ_ERROR );
- CURL_CASE ( CURLE_OUT_OF_MEMORY );
- CURL_CASE ( CURLE_OPERATION_TIMEDOUT );
- CURL_CASE2 ( CURLE_OBSOLETE29, CURLE_FTP_COULDNT_SET_ASCII );
- CURL_CASE ( CURLE_FTP_PORT_FAILED );
- CURL_CASE ( CURLE_FTP_COULDNT_USE_REST );
- CURL_CASE2 ( CURLE_OBSOLETE32, CURLE_FTP_COULDNT_GET_SIZE );
- CURL_CASE2 ( CURLE_RANGE_ERROR, CURLE_HTTP_RANGE_ERROR );
- CURL_CASE ( CURLE_HTTP_POST_ERROR );
- CURL_CASE ( CURLE_SSL_CONNECT_ERROR );
- CURL_CASE ( CURLE_BAD_DOWNLOAD_RESUME );
- CURL_CASE ( CURLE_FILE_COULDNT_READ_FILE );
- CURL_CASE ( CURLE_LDAP_CANNOT_BIND );
- CURL_CASE ( CURLE_LDAP_SEARCH_FAILED );
- CURL_CASE2 ( CURLE_OBSOLETE40, CURLE_LIBRARY_NOT_FOUND );
- CURL_CASE ( CURLE_FUNCTION_NOT_FOUND );
- CURL_CASE ( CURLE_ABORTED_BY_CALLBACK );
- CURL_CASE ( CURLE_BAD_FUNCTION_ARGUMENT );
- CURL_CASE2 ( CURLE_OBSOLETE44, CURLE_BAD_CALLING_ORDER );
- CURL_CASE ( CURLE_INTERFACE_FAILED );
- CURL_CASE2 ( CURLE_OBSOLETE46, CURLE_BAD_PASSWORD_ENTERED );
- CURL_CASE ( CURLE_TOO_MANY_REDIRECTS );
- CURL_CASE ( CURLE_UNKNOWN_TELNET_OPTION );
- CURL_CASE ( CURLE_TELNET_OPTION_SYNTAX );
- CURL_CASE2 ( CURLE_OBSOLETE50, CURLE_OBSOLETE );
- CURL_CASE2 ( CURLE_PEER_FAILED_VERIFICATION, CURLE_SSL_PEER_CERTIFICATE );
- CURL_CASE ( CURLE_GOT_NOTHING );
- CURL_CASE ( CURLE_SSL_ENGINE_NOTFOUND );
- CURL_CASE ( CURLE_SSL_ENGINE_SETFAILED );
- CURL_CASE ( CURLE_SEND_ERROR );
- CURL_CASE ( CURLE_RECV_ERROR );
- CURL_CASE2 ( CURLE_OBSOLETE57, CURLE_SHARE_IN_USE );
- CURL_CASE ( CURLE_SSL_CERTPROBLEM );
- CURL_CASE ( CURLE_SSL_CIPHER );
- CURL_CASE ( CURLE_SSL_CACERT );
- CURL_CASE ( CURLE_BAD_CONTENT_ENCODING );
- CURL_CASE ( CURLE_LDAP_INVALID_URL );
- CURL_CASE ( CURLE_FILESIZE_EXCEEDED );
- CURL_CASE2 ( CURLE_USE_SSL_FAILED, CURLE_FTP_SSL_FAILED );
- CURL_CASE ( CURLE_SEND_FAIL_REWIND );
- CURL_CASE ( CURLE_SSL_ENGINE_INITFAILED );
- CURL_CASE ( CURLE_LOGIN_DENIED );
- CURL_CASE ( CURLE_TFTP_NOTFOUND );
- CURL_CASE ( CURLE_TFTP_PERM );
- CURL_CASE2 ( CURLE_REMOTE_DISK_FULL, CURLE_TFTP_DISKFULL );
- CURL_CASE ( CURLE_TFTP_ILLEGAL );
- CURL_CASE ( CURLE_TFTP_UNKNOWNID );
- CURL_CASE2 ( CURLE_REMOTE_FILE_EXISTS, CURLE_TFTP_EXISTS );
- CURL_CASE ( CURLE_TFTP_NOSUCHUSER );
- CURL_CASE ( CURLE_CONV_FAILED );
- CURL_CASE ( CURLE_CONV_REQD );
- CURL_CASE2 ( CURLE_SSL_CACERT_BADFILE, 77 );
- CURL_CASE2 ( CURLE_REMOTE_FILE_NOT_FOUND, 78 );
- CURL_CASE2 ( CURLE_SSH, 79 );
- CURL_CASE2 ( CURLE_SSL_SHUTDOWN_FAILED, 80 );
- CURL_CASE2 ( CURLE_AGAIN, 81 );
- CURL_CASE2 ( CURLE_SSL_CRL_BADFILE, 82 );
- CURL_CASE2 ( CURLE_SSL_ISSUER_ERROR, 83 );
- }
-
- return "<UNKNOWN>";
-}
-
-
-/* Destroy
- */
-static rc_t CC KCurlFileDestroy( KCurlFile *self )
-{
- self->kns_mgr->curl_easy_cleanup_fkt( self->curl_handle );
- KNSManagerRelease( self->kns_mgr );
- free ( self );
- return 0;
-}
-
-
-static struct KSysFile* KCurlFileGetSysFile( const KCurlFile *self, uint64_t *offset )
-{
- * offset = 0;
- return NULL;
-}
-
-
-static rc_t KCurlFileRandomAccess( const KCurlFile *self )
-{
- return 0;
-}
-
-
-static size_t CC dummy_callback( void *ptr, size_t size, size_t nmemb, void *data )
-{
- ( void )ptr;
- ( void )data;
- return (size_t)( size * nmemb );
-}
-
-
-static size_t CC KCurlFileCallback( void *ptr, size_t size, size_t nmemb, void *data )
-{
- size_t given_bytes = size * nmemb; /* calculate the size given in ptr */
- ReadContext *ctx = ( ReadContext * )data;
- if ( ctx != NULL && ctx->buffer != NULL && ctx->buffer_size > 0 )
- {
- if ( ( ctx->num_read + given_bytes ) > ctx->buffer_size )
- {
- /* the caller-provided buffer IS NOT enough... */
- size_t to_copy = ( ctx->buffer_size - ctx->num_read );
- if ( to_copy > 0 )
- {
- /* the caller-provided buffer can hold a part of it... */
- if ( ctx->buffer )
- {
- memcpy( &( ctx->buffer[ ctx->num_read ] ), ptr, to_copy );
- ctx->num_read += to_copy;
- }
- }
- }
- else
- {
- /* the caller-provided buffer IS enough... */
- if ( ctx->buffer )
- {
- memcpy( &( ctx->buffer[ ctx->num_read ] ), ptr, given_bytes );
- ctx->num_read += given_bytes;
- }
- }
- }
- return given_bytes;
-}
-
-
-/* helper to set a curl-option which is a long int */
-static rc_t set_curl_long_option( struct KNSManager *kns_mgr, CURL *curl,
- CURLoption option, long int value, const char *err_txt )
-{
- rc_t rc = 0;
- CURLcode rcc = kns_mgr->curl_easy_setopt_fkt( curl, option, value );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc, "curl_easy_setopt( $(t), $(v) ) failed with curl-error $(e)",
- "t=%s,v=%d,e=%d", err_txt, value, rcc ) );
- }
- return rc;
-}
-
-
-/* helper to set a curl-option which is a void pointert */
-static rc_t set_curl_void_ptr( struct KNSManager *kns_mgr, CURL *curl,
- CURLoption option, void * value, const char *err_txt )
-{
- rc_t rc = 0;
- CURLcode rcc = kns_mgr->curl_easy_setopt_fkt( curl, option, value );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc, "curl_easy_setopt( $(t) ... void * ptr ) failed with curl-error $(e)",
- "t=%s,e=%d", err_txt, rcc ) );
- }
- return rc;
-}
-
-
-static rc_t perform( struct KNSManager *kns_mgr, CURL *curl, const char * action, uint64_t pos, size_t len )
-{
- rc_t rc = 0;
- CURLcode rcc = kns_mgr->curl_easy_perform_fkt( curl );
- if ( rcc != CURLE_OK && rcc != CURLE_PARTIAL_FILE )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc,
- "curl_easy_perform( $(a), $(b).$(c) ) failed with curl-error '$(d)' ($(e))",
- "a=%s,b=%lu,c=%zu,d=%s,e=%d", action, pos, len, curly_errstr ( rcc ), rcc ) );
- }
- return rc;
-}
-
-
-static rc_t check_response_code( struct KNSManager *kns_mgr, CURL *curl, const char * action )
-{
- rc_t rc = 0;
- long response_code;
-
- CURLcode rcc = kns_mgr->curl_easy_getinfo_fkt( curl, CURLINFO_RESPONSE_CODE, &response_code );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcAccessing, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc,
- "curl_easy_getinfo( $(a) ) failed with curl-error $(c)",
- "a=%s,c=%d", action, rcc ) );
- }
- else
- {
- switch ( response_code )
- {
-
- case 0 : if ( !HTTP_RESPONSE_CODE_0_VALID ) /* no response code available */
- {
- rc = RC( rcFS, rcFile, rcAccessing, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc, "invalid response-code $(c)", "c=%d", response_code ) );
- }
- break;
-
- case 200 : /* OK */
- case 206 : /* Partial Content */
- case 416 : break; /* Requested Range Not Satisfiable */
-
- case 404 : rc = RC( rcFS, rcFile, rcAccessing, rcFileDesc, rcNotFound );
- break;
-
- default : rc = RC( rcFS, rcFile, rcAccessing, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc, "invalid response-code $(c)", "c=%d", response_code ) );
- }
- }
- return rc;
-}
-
-
-static rc_t prepare_curl( const KCurlFile *cself, ReadContext *ctx )
-{
- rc_t rc = 0;
-
- if ( !ctx->curl_handle_prepared )
- {
- ctx->curl_handle = cself->kns_mgr->curl_easy_init_fkt();
- if ( ctx->curl_handle == NULL )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcParam, rcNull );
- LOGERR( klogErr, rc, "cannot init curl" );
- }
- else
- ctx->curl_handle_prepared = true;
- }
-
- if ( rc == 0 && cself->verbose )
- rc = set_curl_long_option( cself->kns_mgr, ctx->curl_handle, CURLOPT_VERBOSE, 1, "CURLOPT_VERBOSE" );
-
- if ( rc == 0 )
- {
- CURLcode rcc = cself->kns_mgr->curl_easy_setopt_fkt( ctx->curl_handle, CURLOPT_WRITEFUNCTION, KCurlFileCallback );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc, "curl_easy_setopt( $(t) ... ptr ) failed", "t=%s", "CURLOPT_WRITEFUNCTION" ) );
- }
- }
-
- if ( rc == 0 )
- rc = set_curl_void_ptr( cself->kns_mgr, ctx->curl_handle, CURLOPT_URL, ( void * )cself->url, "CURLOPT_URL" );
-
- if ( rc == 0 )
- {
- ctx->buffer = NULL;
- ctx->buffer_size = 0;
- ctx->num_read = 0;
- }
- return rc;
-}
-
-
-static rc_t get_content_length( struct KNSManager *kns_mgr, CURL *curl, uint64_t *size )
-{
- rc_t rc = 0;
- double double_size;
- CURLcode rcc = kns_mgr->curl_easy_getinfo_fkt( curl, CURLINFO_CONTENT_LENGTH_DOWNLOAD, &double_size );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- LOGERR( klogErr, rc, "curl_easy_getinfo( CURLINFO_CONTENT_LENGTH_DOWNLOAD ) failed" );
- }
- else
- {
- *size = (uint64_t) double_size;
- }
- return rc;
-}
-
-
-static rc_t DiscoverFileSize_HTTP( const KCurlFile *cself, ReadContext *ctx, uint64_t *size )
-{
- rc_t rc = set_curl_long_option( cself->kns_mgr, ctx->curl_handle, CURLOPT_HEADER, 1, "CURLOPT_HEADER" );
-
- if ( rc == 0 )
- rc = set_curl_long_option( cself->kns_mgr, ctx->curl_handle, CURLOPT_NOBODY, 1, "CURLOPT_NOBODY" );
-
- if ( rc == 0 )
- rc = set_curl_void_ptr( cself->kns_mgr, ctx->curl_handle, CURLOPT_WRITEDATA, ctx, "CURLOPT_WRITEDATA" );
-
- if ( rc == 0 )
- rc = set_curl_long_option( cself->kns_mgr, ctx->curl_handle, CURLOPT_FOLLOWLOCATION, 1, "CURLOPT_FOLLOWLOCATION" );
-
- if ( rc == 0 )
- rc = perform( cself->kns_mgr, ctx->curl_handle, "filesize http", 0, 0 );
-
- if ( rc == 0 )
- rc = check_response_code( cself->kns_mgr, ctx->curl_handle, "filesize http" );
-
- if ( rc == 0 )
- rc = get_content_length( cself->kns_mgr, ctx->curl_handle, size );
-
- return rc;
-}
-
-static rc_t DiscoverFileSize_FTP( const KCurlFile *cself, ReadContext *ctx, uint64_t *size )
-{
- rc_t rc = set_curl_long_option( cself->kns_mgr, ctx->curl_handle, CURLOPT_NOBODY, 1, "CURLOPT_NOBODY" );
-
- if ( rc == 0 )
- rc = set_curl_long_option( cself->kns_mgr, ctx->curl_handle, CURLOPT_FILETIME, 1, "CURLOPT_FILETIME" );
-
- if ( rc == 0 )
- rc = set_curl_long_option( cself->kns_mgr, ctx->curl_handle, CURLOPT_FOLLOWLOCATION, 1, "CURLOPT_FOLLOWLOCATION" );
-
- if ( rc == 0 )
- {
- CURLcode rcc = cself->kns_mgr->curl_easy_setopt_fkt( ctx->curl_handle, CURLOPT_HEADERFUNCTION, dummy_callback );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc, "curl_easy_setopt( $(t) ... ptr ) failed", "t=%s", "CURLOPT_HEADERFUNCTION" ) );
- }
- }
-
- if ( rc == 0 )
- rc = set_curl_long_option( cself->kns_mgr, ctx->curl_handle, CURLOPT_HEADER, 0, "CURLOPT_HEADER" );
-
- if ( rc == 0 )
- rc = perform( cself->kns_mgr, ctx->curl_handle, "filesize ftp", 0, 0 );
-
- if ( rc == 0 )
- rc = get_content_length( cself->kns_mgr, ctx->curl_handle, size );
-
- return rc;
-}
-
-
-static rc_t KCurlFileDiscoverSize( const KCurlFile *cself, uint64_t *size )
-{
- ReadContext ctx;
- rc_t rc;
-
- memset( &ctx, 0, sizeof ctx );
- rc = prepare_curl( cself, &ctx );
- if ( rc == 0 )
- {
- if ( cself->is_ftp )
- rc = DiscoverFileSize_FTP( cself, &ctx, size );
- else
- rc = DiscoverFileSize_HTTP( cself, &ctx, size );
-
- if ( rc == 0 )
- {
- KCurlFile *self = ( KCurlFile * )cself;
-
- self->file_size = *size;
- self->file_size_valid = true;
- /* OUTMSG(( ">>>>>>>>>>>>>> and the file size is: %lu\n", self->file_size )); */
- }
-
- if ( ctx.curl_handle_prepared )
- cself->kns_mgr->curl_easy_cleanup_fkt( ctx.curl_handle );
- }
- return rc;
-}
-
-
-static rc_t KCurlFileSize( const KCurlFile *self, uint64_t *size )
-{
- rc_t rc = 0;
- if ( self->file_size_valid )
- *size = self->file_size;
- else
- rc = KCurlFileDiscoverSize( self, size );
- return rc;
-}
-
-
-static rc_t KCurlFileSetSize( KCurlFile *self, uint64_t size )
-{
- return RC ( rcFS, rcFile, rcUpdating, rcFile, rcReadonly );
-}
-
-
-static rc_t KCurlFileRead( const KCurlFile *cself, uint64_t pos,
- void *buffer, size_t bsize, size_t *num_read )
-{
- ReadContext ctx;
- rc_t rc;
-
- if ( cself->file_size_valid && cself->file_size > 0 )
- {
- /* we know the size of the remote file */
- if ( pos >= cself->file_size )
- {
- /* the caller requested to read beyond the end of the file */
- *num_read = 0;
- return 0;
- }
- else if ( pos + bsize > cself->file_size )
- {
- /* the caller requested to start reading inside the file, but bsize reaches beyond the end of the file */
- bsize = ( cself->file_size - pos );
- }
- }
-
- ctx.curl_handle = cself->curl_handle;
- ctx.curl_handle_prepared = true;
- rc = prepare_curl( cself, &ctx );
- if ( rc == 0 )
- {
- char s_range[ 64 ];
- size_t s_range_writ;
- uint64_t to = pos;
- to += bsize;
- to --;
-
- /* perform range-read... */
- rc = string_printf( s_range, sizeof s_range, &s_range_writ, "%lu-%lu", pos, to );
- if ( rc == 0 )
- {
- ReadContext ctx;
- CURLcode rcc;
-
- ctx.buffer = buffer;
- ctx.buffer_size = bsize;
- ctx.num_read = 0;
-
- rcc = cself->kns_mgr->curl_easy_setopt_fkt( cself->curl_handle, CURLOPT_WRITEDATA, (void *)&ctx );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcReading, rcFileDesc, rcInvalid );
- LOGERR( klogErr, rc, "curl_easy_setopt( CURLOPT_WRITEDATA ) failed" );
- }
-
- if ( rc == 0 )
- rc = set_curl_long_option( cself->kns_mgr, cself->curl_handle, CURLOPT_CONNECTTIMEOUT, 10, "CURLOPT_CONNECTTIMEOUT" );
- if ( rc == 0 )
- rc = set_curl_long_option( cself->kns_mgr, cself->curl_handle, CURLOPT_TIMEOUT, 10, "CURLOPT_TIMEOUT" );
- if ( rc == 0 )
- rc = set_curl_long_option( cself->kns_mgr, cself->curl_handle, CURLOPT_FOLLOWLOCATION, 1, "CURLOPT_FOLLOWLOCATION" );
-
- if ( rc == 0 )
- {
- rcc = cself->kns_mgr->curl_easy_setopt_fkt( cself->curl_handle, CURLOPT_RANGE, (void*)s_range );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcReading, rcFileDesc, rcInvalid );
- LOGERR( klogErr, rc, "curl_easy_setopt( CURLOPT_RANGE ) failed" );
- }
- }
-
- if ( rc == 0 )
- rc = perform( cself->kns_mgr, cself->curl_handle, "FileRead", pos, bsize );
-
- if ( rc == 0 )
- {
- long response_code;
- rcc = cself->kns_mgr->curl_easy_getinfo_fkt( cself->curl_handle, CURLINFO_RESPONSE_CODE, &response_code );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcReading, rcFileDesc, rcInvalid );
- LOGERR( klogErr, rc, "curl_easy_getinfo( RESPONSE_CODE ) failed" );
- }
- else
- {
- if ( cself->is_ftp )
- {
- switch ( response_code )
- {
- case 0 : if ( !HTTP_RESPONSE_CODE_0_VALID ) /* no response code available */
- {
- rc = RC( rcFS, rcFile, rcReading, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc, "invalid response-code $(c)", "c=%d", response_code ) );
- }
- break;
-
- case 226 :
- case 213 :
- case 450 : /* Transfer aborted */
- case 451 : break;
-
- default : rc = RC( rcFS, rcFile, rcReading, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc, "invalid response-code $(c)", "c=%d", response_code ) );
- }
- }
- else
- {
- switch ( response_code )
- {
- case 0 : if ( !HTTP_RESPONSE_CODE_0_VALID ) /* no response code available */
- {
- rc = RC( rcFS, rcFile, rcReading, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc, "invalid response-code $(c)", "c=%d", response_code ) );
- }
- break;
-
- case 416 : /* Requested Range Not Satisfiable */
- ctx.num_read = 0;
- case 200 : /* OK */
- case 206 : /* Partial Content */
- break;
-
- case 404 : rc = RC( rcFS, rcFile, rcReading, rcFileDesc, rcNotFound );
- break;
-
- default : rc = RC( rcFS, rcFile, rcReading, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc, "invalid response-code $(c)", "c=%d", response_code ) );
- }
- }
- }
- }
- if ( rc == 0 )
- *num_read = ctx.num_read;
- }
- }
- return rc;
-}
-
-
-static rc_t KCurlFileWrite( KCurlFile *self, uint64_t pos,
- const void *buffer, size_t size, size_t *num_writ )
-{
- return RC ( rcFS, rcFile, rcUpdating, rcInterface, rcUnsupported );
-}
-
-
-static KFile_vt_v1 vtKCurlFile =
-{
- /* version 1.0 */
- 1, 0,
-
- /* start minor version 0 methods */
- KCurlFileDestroy,
- KCurlFileGetSysFile,
- KCurlFileRandomAccess,
- KCurlFileSize,
- KCurlFileSetSize,
- KCurlFileRead,
- KCurlFileWrite
- /* end minor version 0 methods */
-};
-
-
-LIB_EXPORT rc_t CC KCurlFileMake( const KFile **fp, const char * url, bool verbose )
-{
- rc_t rc = 0;
- KCurlFile *f;
-
- if ( url == NULL || url[ 0 ] == 0 )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- PLOGERR( klogInt, ( klogInt, rc, "invalid url >$(URL)<", "URL=%s", url ) );
- }
- else
- {
- size_t url_len = string_size( url ) + 1;
- f = calloc ( ( sizeof *f ) + url_len, 1 );
- if ( f == NULL )
- {
- rc = RC ( rcFS, rcFile, rcConstructing, rcMemory, rcExhausted );
- LOGERR( klogErr, rc, "out of memory" );
- }
- else
- {
- rc = KNSManagerMake( &f->kns_mgr );
- if ( rc == 0 )
- {
- rc = KNSManagerAvail( f->kns_mgr );
- if ( rc == 0 )
- {
- rc = KFileInit( &f ->dad, (const union KFile_vt *)&vtKCurlFile, "KCurlFile", url, true, false );
- if ( rc == 0 )
- {
- ReadContext ctx;
- uint64_t file_size;
-
- memset( &ctx, 0, sizeof( ctx ) ); /* zero-out the content */
-
- string_copy( f->url, url_len, url, url_len );
- f->verbose = verbose;
- f->is_ftp = ( url_len >= 4 ) ? ( strcase_cmp ( f->url, url_len, "ftp:", 4, 4 ) == 0 ) : false;
-
- rc = KCurlFileDiscoverSize( f, &file_size );
-
- if ( rc == 0 )
- {
- rc = prepare_curl( f, &ctx );
- if ( rc == 0 )
- {
- f->curl_handle = ctx.curl_handle;
- *fp = & f -> dad;
- return rc;
- }
- else
- {
- KCurlFileDestroy( f );
- f = NULL;
- }
- }
- }
- }
- }
- free( f );
- }
- }
- return rc;
-}
diff --git a/libs/kns/KCurlRequest.c b/libs/kns/KCurlRequest.c
deleted file mode 100644
index f75d25c..0000000
--- a/libs/kns/KCurlRequest.c
+++ /dev/null
@@ -1,438 +0,0 @@
-/*===========================================================================
-*
-* PUBLIC DOMAIN NOTICE
-* National Center for Biotechnology Information
-*
-* This software/database is a "United States Government Work" under the
-* terms of the United States Copyright Act. It was written as part of
-* the author's official duties as a United States Government employee and
-* thus cannot be copyrighted. This software/database is freely available
-* to the public for use. The National Library of Medicine and the U.S.
-* Government have not placed any restriction on its use or reproduction.
-*
-* Although all reasonable efforts have been taken to ensure the accuracy
-* and reliability of the software and data, the NLM and the U.S.
-* Government do not and cannot warrant the performance or results that
-* may be obtained by using this software or data. The NLM and the U.S.
-* Government disclaim all warranties, express or implied, including
-* warranties of performance, merchantability or fitness for any particular
-* purpose.
-*
-* Please cite the author in any work or product based on this material.
-*
-* ===========================================================================
-*
-*/
-
-#include <kns/extern.h>
-
-#include <klib/refcount.h>
-#include <klib/rc.h>
-#include <klib/log.h>
-#include <klib/text.h>
-#include <klib/printf.h>
-#include <klib/data-buffer.h>
-#include <kns/manager.h>
-#include <kns/KCurlRequest.h>
-
-#include "kns_mgr_priv.h"
-
-#include <sysalloc.h>
-
-#include <stdlib.h>
-#include <string.h>
-#include <ctype.h>
-#include <assert.h>
-
-
-static const char kcurlrequest_classname [] = "KCurlRequest";
-
-
-typedef struct KCurlRequest
-{
- KRefcount refcount;
- const struct KNSManager * kns_mgr;
- CURL * curl_handle;
- KDataBuffer fields;
- uint64_t fields_chars;
-} KCurlRequest;
-
-
-static rc_t KCurlRequestSetUrl( struct KCurlRequest *self, const char * url )
-{
- rc_t rc = 0;
- CURLcode rcc = self->kns_mgr->curl_easy_setopt_fkt( self->curl_handle, CURLOPT_URL, (void *)url );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- LOGERR( klogErr, rc, "curl_easy_setopt( CURLOPT_URL ) failed" );
- }
- return rc;
-}
-
-
-static rc_t set_curl_long_option( struct KCurlRequest *self, CURLoption option, long int value, const char *err_txt )
-{
- rc_t rc = 0;
- CURLcode rcc = self->kns_mgr->curl_easy_setopt_fkt( self->curl_handle, option, value );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc, "curl_easy_setopt( $(t), $(v) ) failed with curl-error $(e)",
- "t=%s,v=%d,e=%d", err_txt, value, rcc ) );
- }
- return rc;
-}
-
-
-static rc_t set_verbose( struct KCurlRequest *self )
-{
- return set_curl_long_option( self, CURLOPT_VERBOSE, 1, "CURLOPT_VERBOSE" );
-}
-
-
-LIB_EXPORT rc_t CC KNSManagerMakeCurlRequest( const struct KNSManager *kns_mgr, struct KCurlRequest **self, const char * url, bool verbose )
-{
- rc_t rc = 0;
- struct KCurlRequest *tmp = calloc ( sizeof *tmp, 1 );
- if ( tmp == NULL )
- {
- rc = RC ( rcFS, rcFile, rcConstructing, rcMemory, rcExhausted );
- LOGERR( klogErr, rc, "out of memory" );
- }
- else
- {
- rc = KNSManagerAvail( kns_mgr );
- if ( rc == 0 )
- {
- tmp->kns_mgr = kns_mgr;
- rc = KNSManagerAddRef ( kns_mgr );
- if ( rc == 0 )
- {
- tmp->curl_handle = tmp->kns_mgr->curl_easy_init_fkt();
- if ( tmp->curl_handle == NULL )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcParam, rcNull );
- LOGERR( klogErr, rc, "cannot init curl" );
- }
- else
- {
- rc = KCurlRequestSetUrl( tmp, url );
- if ( rc == 0 )
- {
- if ( verbose )
- rc = set_verbose( tmp );
- memset( &tmp->fields, 0, sizeof tmp->fields );
- tmp->fields.elem_bits = 8;
- if ( rc == 0 )
- {
- KRefcountInit( &tmp->refcount, 1, "KNS", "make", kcurlrequest_classname );
- *self = tmp;
- return rc; /* !!!! */
- }
- }
- }
- KNSManagerRelease( kns_mgr );
- }
- }
- free( tmp );
- }
- return rc;
-}
-
-
-static rc_t KCurlRequestDestroy( struct KCurlRequest *self )
-{
- rc_t rc;
- self->kns_mgr->curl_easy_cleanup_fkt( self->curl_handle );
- rc = KNSManagerRelease( self->kns_mgr );
- KDataBufferWhack( &self->fields );
- free ( self );
- return rc;
-}
-
-
-LIB_EXPORT rc_t CC KCurlRequestAddRef ( const struct KCurlRequest *self )
-{
- if ( self != NULL )
- {
- switch ( KRefcountAdd( &self->refcount, kcurlrequest_classname ) )
- {
- case krefOkay:
- break;
- case krefZero:
- return RC( rcNS, rcFile, rcAttaching, rcRefcount, rcIncorrect);
- case krefLimit:
- return RC( rcNS, rcFile, rcAttaching, rcRefcount, rcExhausted);
- case krefNegative:
- return RC( rcNS, rcFile, rcAttaching, rcRefcount, rcInvalid);
- default:
- return RC( rcNS, rcFile, rcAttaching, rcRefcount, rcUnknown);
- }
- }
- return 0;
-}
-
-
-LIB_EXPORT rc_t CC KCurlRequestRelease( const struct KCurlRequest *self )
-{
- rc_t rc = 0;
- if ( self != NULL )
- {
- switch ( KRefcountDrop( &self->refcount, kcurlrequest_classname ) )
- {
- case krefOkay:
- case krefZero:
- break;
- case krefWhack:
- rc = KCurlRequestDestroy( ( struct KCurlRequest * )self );
- break;
- case krefNegative:
- return RC( rcNS, rcFile, rcAttaching, rcRefcount, rcInvalid );
- default:
- rc = RC( rcNS, rcFile, rcAttaching, rcRefcount, rcUnknown );
- break;
- }
- }
- return rc;
-}
-
-
-static rc_t perform( const struct KNSManager *kns_mgr, CURL *curl, const char * action )
-{
- rc_t rc = 0;
- CURLcode rcc = kns_mgr->curl_easy_perform_fkt( curl );
- if ( rcc != CURLE_OK && rcc != CURLE_PARTIAL_FILE )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc,
- "curl_easy_perform( $(a) ) failed with curl-error $(c)",
- "a=%s,b=%d", action, rcc ) );
- }
- return rc;
-}
-
-
-static rc_t check_response_code( const struct KNSManager *kns_mgr, CURL *curl, const char * action )
-{
- rc_t rc = 0;
- long response_code;
-
- CURLcode rcc = kns_mgr->curl_easy_getinfo_fkt( curl, CURLINFO_RESPONSE_CODE, &response_code );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc,
- "curl_easy_getinfo( $(a) ) failed with curl-error $(c)",
- "a=%s,c=%d", action, rcc ) );
- }
- else
- {
- switch ( response_code )
- {
- case 0 : /* no response code available */
- case 200 : break; /* OK */
-
- case 404 : rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcNotFound );
- break;
-
- default : rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- (void)PLOGERR( klogErr, ( klogErr, rc, "invalid response-code $(c)", "c=%d", response_code ) );
- }
- }
- return rc;
-}
-
-
-LIB_EXPORT rc_t CC KCurlRequestAddSFields( struct KCurlRequest *self, const String * fields )
-{
- rc_t rc = 0;
-
- if ( self == NULL )
- return RC( rcNS, rcFile, rcReading, rcSelf, rcNull );
- if ( fields == NULL || fields->size == 0 )
- return RC( rcNS, rcFile, rcReading, rcParam, rcNull );
-
- if ( self->fields_chars == 0 )
- {
- rc = KDataBufferResize ( &self->fields, fields->size + 1 );
- if ( rc == 0 )
- {
- memcpy( self->fields.base, fields->addr, fields->size );
- ( (uint8_t *)self->fields.base)[ fields->size ] = 0;
- self->fields_chars = fields->size;
- }
- }
- else
- {
- rc = KDataBufferResize ( &self->fields, self->fields_chars + fields->size + 1 );
- if ( rc == 0 )
- {
- ( (uint8_t *)self->fields.base)[ self->fields_chars ] = '&';
- memcpy( &( ( (uint8_t *)self->fields.base)[ self->fields_chars + 1 ] ), fields->addr, fields->size );
- self->fields_chars += ( fields->size + 1 );
- ( (uint8_t *)self->fields.base)[ self->fields_chars ] = 0;
- }
- }
- return rc;
-}
-
-
-LIB_EXPORT rc_t CC KCurlRequestAddFields( struct KCurlRequest *self, const char * fields )
-{
- String s;
-
- if ( self == NULL )
- return RC( rcNS, rcFile, rcReading, rcSelf, rcNull );
- if ( fields == NULL || fields[ 0 ] == 0 )
- return RC( rcNS, rcFile, rcReading, rcParam, rcNull );
-
- StringInitCString( &s, fields );
- return KCurlRequestAddSFields( self, &s );
-}
-
-
-LIB_EXPORT rc_t CC KCurlRequestAddSField( struct KCurlRequest *self, const String * name, const String * value )
-{
- rc_t rc = 0;
- size_t needed;
-
- if ( self == NULL )
- return RC( rcNS, rcFile, rcReading, rcSelf, rcNull );
- if ( name == NULL || name->size == 0 || value == NULL || value->size == 0 )
- return RC( rcNS, rcFile, rcReading, rcParam, rcNull );
-
- needed = ( self->fields_chars + name->size + value->size + 3 );
- rc = KDataBufferResize ( &self->fields, needed );
- if ( rc == 0 )
- {
- size_t num_writ;
- if ( self->fields_chars == 0 )
- {
- rc = string_printf ( ( char * )self->fields.base, needed, &num_writ,
- "%S=%S", name, value );
- }
- else
- {
- uint8_t * dst = ( uint8_t * )self->fields.base;
- rc = string_printf ( ( char * )( &dst[ self->fields_chars ] ), needed - self->fields_chars, &num_writ,
- "&%S=%S", name, value );
- }
- if ( rc == 0 )
- self->fields_chars += num_writ;
- }
- return rc;
-}
-
-
-LIB_EXPORT rc_t CC KCurlRequestAddField( struct KCurlRequest *self, const char * name, const char * value )
-{
- String s_name, s_value;
-
- if ( self == NULL )
- return RC( rcNS, rcFile, rcReading, rcSelf, rcNull );
- if ( name == NULL || name[ 0 ] == 0 || value == NULL || value[ 0 ] == 0 )
- return RC( rcNS, rcFile, rcReading, rcParam, rcNull );
-
- StringInitCString( &s_name, name );
- StringInitCString( &s_value, value );
- return KCurlRequestAddSField( self, &s_name, &s_value );
-}
-
-
-static rc_t KCurlRequestSetFields( struct KCurlRequest *self )
-{
- rc_t rc = 0;
- CURLcode rcc = self->kns_mgr->curl_easy_setopt_fkt( self->curl_handle, CURLOPT_POSTFIELDS, (void *)(self->fields.base) );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- LOGERR( klogErr, rc, "curl_easy_setopt( CURLOPT_POSTFIELDS ) failed" );
- }
- return rc;
-}
-
-
-typedef struct ReadContext
-{
- KDataBuffer * buffer;
- size_t num_read;
-} ReadContext;
-
-
-static size_t CC KCurlFileCallback( void *ptr, size_t size, size_t nmemb, void *data )
-{
- rc_t rc = 0;
- size_t given_bytes = size * nmemb; /* calculate the size given in ptr */
- ReadContext *ctx = ( ReadContext * )data;
- if ( ctx != NULL && ctx->buffer != NULL )
- {
- rc = KDataBufferResize ( ctx->buffer, ctx->num_read + given_bytes + 2 );
- if ( rc == 0 )
- {
- memcpy( &( ( (uint8_t *)ctx->buffer->base )[ ctx->num_read ] ), ptr, given_bytes );
- ctx->num_read += given_bytes;
- }
- }
- return given_bytes;
-}
-
-
-LIB_EXPORT rc_t CC KCurlRequestPerform( struct KCurlRequest *self, KDataBuffer * buffer )
-{
- CURLcode rcc;
- ReadContext ctx;
- rc_t rc = 0;
-
- if ( buffer == NULL )
- return RC( rcNS, rcFile, rcReading, rcParam, rcNull );
-
- memset ( buffer, 0, sizeof * buffer );
-
- if ( self == NULL )
- return RC( rcNS, rcFile, rcReading, rcSelf, rcNull );
-
- rc = KDataBufferMakeBytes ( buffer, 0 );
- if ( rc != 0 )
- return rc;
-
- ctx.buffer = buffer;
- ctx.num_read = 0;
-
- rcc = self->kns_mgr->curl_easy_setopt_fkt( self->curl_handle, CURLOPT_WRITEDATA, (void *)&ctx );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- LOGERR( klogErr, rc, "curl_easy_setopt( CURLOPT_WRITEDATA ) failed" );
- }
-
- if ( rc == 0 )
- {
- CURLcode rcc = self->kns_mgr->curl_easy_setopt_fkt( self->curl_handle, CURLOPT_WRITEFUNCTION, KCurlFileCallback );
- if ( rcc != CURLE_OK )
- {
- rc = RC( rcFS, rcFile, rcConstructing, rcFileDesc, rcInvalid );
- LOGERR( klogErr, rc, "curl_easy_setopt( CURLOPT_WRITEFUNCTION ) failed" );
- }
- }
-
- if ( rc == 0 )
- rc = set_curl_long_option( self, CURLOPT_FOLLOWLOCATION, 1, "CURLOPT_FOLLOWLOCATION" );
-
- if ( rc == 0 )
- rc = KCurlRequestSetFields( self );
-
- if ( rc == 0 )
- rc = perform( self->kns_mgr, self->curl_handle, "POST request" );
-
- if ( rc == 0 )
- rc = check_response_code( self->kns_mgr, self->curl_handle, "POST request" );
-
- if ( rc == 0 )
- {
- buffer->elem_count = ctx.num_read;
- ( ( uint8_t * )buffer->base )[ ctx.num_read ] = 0;
- }
-
- return rc;
-}
diff --git a/libs/kns/Makefile b/libs/kns/Makefile
index d8969b2..86869fe 100644
--- a/libs/kns/Makefile
+++ b/libs/kns/Makefile
@@ -28,8 +28,7 @@ TOP ?= $(shell ../../build/abspath.sh ../..)
MODULE = libs/kns
INT_LIBS = \
- libkns \
- libkurl
+ libkns
ALL_LIBS = \
$(INT_LIBS)
@@ -77,8 +76,8 @@ clean: stdclean
$(ILIBDIR)/libkns: $(addprefix $(ILIBDIR)/libkns.,$(ILIBEXT))
KNS_NO_HTTP_SRC = \
- kns_manager \
kns_manager-ext \
+ manager \
stream \
stream-from-files \
stream-from-streams \
@@ -86,11 +85,17 @@ KNS_NO_HTTP_SRC = \
sysendpoint \
syssock \
sysstream \
- sysmgr
+ sysmgr
+
+ifneq (win,$(OS))
+KNS_NO_HTTP_SRC += \
+ syspoll
+endif
KNS_SRC = \
$(KNS_NO_HTTP_SRC) \
- http
+ http \
+ undyinghttp
KNS_OBJ = \
$(addsuffix .$(LOBX),$(KNS_SRC))
@@ -104,25 +109,24 @@ $(ILIBDIR)/libkns.$(LIBX): $(KNS_OBJ)
#-------------------------------------------------------------------------------
-# kurl
+# white-box test
#
-$(ILIBDIR)/libkurl: $(addprefix $(ILIBDIR)/libkurl.,$(ILIBEXT))
-
-KURL_SRC = \
- KCurlFile \
- KCurlRequest \
- url-fetcher \
- url-fetcher-curl \
- entrez-fetcher
-
-KURL_OBJ = \
- $(addsuffix .$(LOBX),$(KURL_SRC))
-
-KURL_LIB = \
- -skns \
- -dkfs \
- -dklib \
- -dz
-
-$(ILIBDIR)/libkurl.$(LIBX): $(KURL_OBJ)
- $(LD) --slib -o $@ $^ $(KURL_LIB)
+
+TEST_SRC = \
+ http-test
+
+TEST_OBJ = \
+ $(addsuffix .$(OBJX),$(TEST_SRC))
+
+TEST_LIB = \
+ -skapp \
+ -skns \
+ -svfs \
+ -skrypto \
+ -skfg \
+ -skfs \
+ -skproc \
+ -sklib
+
+$(TEST_BINDIR)/test-http: $(TEST_OBJ)
+ $(LD) --exe -o $@ $^ $(TEST_LIB)
diff --git a/libs/kns/curlhdr/curl.h b/libs/kns/curlhdr/curl.h
deleted file mode 100644
index 1cfc7fa..0000000
--- a/libs/kns/curlhdr/curl.h
+++ /dev/null
@@ -1,1600 +0,0 @@
-#ifndef __CURL_CURL_H
-#define __CURL_CURL_H
-/***************************************************************************
- * _ _ ____ _
- * Project ___| | | | _ \| |
- * / __| | | | |_) | |
- * | (__| |_| | _ <| |___
- * \___|\___/|_| \_\_____|
- *
- * Copyright (C) 1998 - 2006, Daniel Stenberg, <daniel at haxx.se>, et al.
- *
- * This software is licensed as described in the file COPYING, which
- * you should have received as part of this distribution. The terms
- * are also available at http://curl.haxx.se/docs/copyright.html.
- *
- * You may opt to use, copy, modify, merge, publish, distribute and/or sell
- * copies of the Software, and permit persons to whom the Software is
- * furnished to do so, under the terms of the COPYING file.
- *
- * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
- * KIND, either express or implied.
- *
- * $Id: curl.h,v 1.1 2012/11/09 17:54:52 rodarmer Exp $
- ***************************************************************************/
-
-/* If you have problems, all libcurl docs and details are found here:
- http://curl.haxx.se/libcurl/
-*/
-
-#include "curlver.h" /* the libcurl version defines */
-
-#include <stdio.h>
-#include <limits.h>
-
-/* The include stuff here below is mainly for time_t! */
-#ifdef vms
-# include <types.h>
-# include <time.h>
-#else
-# include <sys/types.h>
-# include <time.h>
-#endif /* defined (vms) */
-
-typedef void CURL;
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/*
- * Decorate exportable functions for Win32 DLL linking.
- * This avoids using a .def file for building libcurl.dll.
- */
-#if (defined(WIN32) || defined(_WIN32)) && !defined(CURL_STATICLIB)
-#if defined(BUILDING_LIBCURL)
-#define CURL_EXTERN __declspec(dllexport)
-#else
-#define CURL_EXTERN __declspec(dllimport)
-#endif
-#else
-
-#ifdef CURL_HIDDEN_SYMBOLS
-/*
- * This definition is used to make external definitions visibile in the
- * shared library when symbols are hidden by default. It makes no
- * difference when compiling applications whether this is set or not,
- * only when compiling the library.
- */
-#define CURL_EXTERN CURL_EXTERN_SYMBOL
-#else
-#define CURL_EXTERN
-#endif
-#endif
-
-/*
- * We want the typedef curl_off_t setup for large file support on all
- * platforms. We also provide a CURL_FORMAT_OFF_T define to use in *printf
- * format strings when outputting a variable of type curl_off_t.
- *
- * Note: "pocc -Ze" is MSVC compatibily mode and this sets _MSC_VER!
- */
-
-#if (defined(_MSC_VER) && !defined(__POCC__)) || (defined(__LCC__) && defined(WIN32))
-/* MSVC */
-#ifdef _WIN32_WCE
- typedef long curl_off_t;
-#define CURL_FORMAT_OFF_T "%ld"
-#else
- typedef signed __int64 curl_off_t;
-#define CURL_FORMAT_OFF_T "%I64d"
-#endif
-#else /* (_MSC_VER && !__POCC__) || (__LCC__ && WIN32) */
-#if (defined(__GNUC__) && defined(WIN32)) || defined(__WATCOMC__)
-/* gcc on windows or Watcom */
- typedef long long curl_off_t;
-#define CURL_FORMAT_OFF_T "%I64d"
-#else /* GCC or Watcom on Windows */
-
-/* "normal" POSIX approach, do note that this does not necessarily mean that
- the type is >32 bits, see the SIZEOF_CURL_OFF_T define for that! */
- typedef off_t curl_off_t;
-
-/* Check a range of defines to detect large file support. On Linux it seems
- none of these are set by default, so if you don't explicitly switches on
- large file support, this define will be made for "small file" support. */
-#ifndef _FILE_OFFSET_BITS
-#define _FILE_OFFSET_BITS 0 /* to prevent warnings in the check below */
-#define UNDEF_FILE_OFFSET_BITS
-#endif
-#ifndef FILESIZEBITS
-#define FILESIZEBITS 0 /* to prevent warnings in the check below */
-#define UNDEF_FILESIZEBITS
-#endif
-
-#if defined(_LARGE_FILES) || (_FILE_OFFSET_BITS > 32) || (FILESIZEBITS > 32) \
- || defined(_LARGEFILE_SOURCE) || defined(_LARGEFILE64_SOURCE)
- /* For now, we assume at least one of these to be set for large files to
- work! */
-#define CURL_FORMAT_OFF_T "%lld"
-#else /* LARGE_FILE support */
-#define CURL_FORMAT_OFF_T "%ld"
-#endif
-#endif /* GCC or Watcom on Windows */
-#endif /* (_MSC_VER && !__POCC__) || (__LCC__ && WIN32) */
-
-#ifdef UNDEF_FILE_OFFSET_BITS
-/* this was defined above for our checks, undefine it again */
-#undef _FILE_OFFSET_BITS
-#endif
-
-#ifdef UNDEF_FILESIZEBITS
-/* this was defined above for our checks, undefine it again */
-#undef FILESIZEBITS
-#endif
-
-struct curl_httppost {
- struct curl_httppost *next; /* next entry in the list */
- char *name; /* pointer to allocated name */
- long namelength; /* length of name length */
- char *contents; /* pointer to allocated data contents */
- long contentslength; /* length of contents field */
- char *buffer; /* pointer to allocated buffer contents */
- long bufferlength; /* length of buffer field */
- char *contenttype; /* Content-Type */
- struct curl_slist* contentheader; /* list of extra headers for this form */
- struct curl_httppost *more; /* if one field name has more than one
- file, this link should link to following
- files */
- long flags; /* as defined below */
-#define HTTPPOST_FILENAME (1<<0) /* specified content is a file name */
-#define HTTPPOST_READFILE (1<<1) /* specified content is a file name */
-#define HTTPPOST_PTRNAME (1<<2) /* name is only stored pointer
- do not free in formfree */
-#define HTTPPOST_PTRCONTENTS (1<<3) /* contents is only stored pointer
- do not free in formfree */
-#define HTTPPOST_BUFFER (1<<4) /* upload file from buffer */
-#define HTTPPOST_PTRBUFFER (1<<5) /* upload file from pointer contents */
-
- char *showfilename; /* The file name to show. If not set, the
- actual file name will be used (if this
- is a file part) */
-};
-
-typedef int (*curl_progress_callback)(void *clientp,
- double dltotal,
- double dlnow,
- double ultotal,
- double ulnow);
-
- /* Tests have proven that 20K is a very bad buffer size for uploads on
- Windows, while 16K for some odd reason performed a lot better. */
-#define CURL_MAX_WRITE_SIZE 16384
-
-typedef size_t (*curl_write_callback)(char *buffer,
- size_t size,
- size_t nitems,
- void *outstream);
-
-/* This is a return code for the read callback that, when returned, will
- signal libcurl to immediately abort the current transfer. */
-#define CURL_READFUNC_ABORT 0x10000000
-typedef size_t (*curl_read_callback)(char *buffer,
- size_t size,
- size_t nitems,
- void *instream);
-
-
-#ifndef CURL_NO_OLDIES
- /* not used since 7.10.8, will be removed in a future release */
-typedef int (*curl_passwd_callback)(void *clientp,
- const char *prompt,
- char *buffer,
- int buflen);
-#endif
-
-typedef enum {
- CURLIOE_OK, /* I/O operation successful */
- CURLIOE_UNKNOWNCMD, /* command was unknown to callback */
- CURLIOE_FAILRESTART, /* failed to restart the read */
- CURLIOE_LAST /* never use */
-} curlioerr;
-
-typedef enum {
- CURLIOCMD_NOP, /* no operation */
- CURLIOCMD_RESTARTREAD, /* restart the read stream from start */
- CURLIOCMD_LAST /* never use */
-} curliocmd;
-
-typedef curlioerr (*curl_ioctl_callback)(CURL *handle,
- int cmd,
- void *clientp);
-
-/*
- * The following typedef's are signatures of malloc, free, realloc, strdup and
- * calloc respectively. Function pointers of these types can be passed to the
- * curl_global_init_mem() function to set user defined memory management
- * callback routines.
- */
-typedef void *(*curl_malloc_callback)(size_t size);
-typedef void (*curl_free_callback)(void *ptr);
-typedef void *(*curl_realloc_callback)(void *ptr, size_t size);
-typedef char *(*curl_strdup_callback)(const char *str);
-typedef void *(*curl_calloc_callback)(size_t nmemb, size_t size);
-
-/* the kind of data that is passed to information_callback*/
-typedef enum {
- CURLINFO_TEXT = 0,
- CURLINFO_HEADER_IN, /* 1 */
- CURLINFO_HEADER_OUT, /* 2 */
- CURLINFO_DATA_IN, /* 3 */
- CURLINFO_DATA_OUT, /* 4 */
- CURLINFO_SSL_DATA_IN, /* 5 */
- CURLINFO_SSL_DATA_OUT, /* 6 */
- CURLINFO_END
-} curl_infotype;
-
-typedef int (*curl_debug_callback)
- (CURL *handle, /* the handle/transfer this concerns */
- curl_infotype type, /* what kind of data */
- char *data, /* points to the data */
- size_t size, /* size of the data pointed to */
- void *userptr); /* whatever the user please */
-
-/* All possible error codes from all sorts of curl functions. Future versions
- may return other values, stay prepared.
-
- Always add new return codes last. Never *EVER* remove any. The return
- codes must remain the same!
- */
-
-typedef enum {
- CURLE_OK = 0,
- CURLE_UNSUPPORTED_PROTOCOL, /* 1 */
- CURLE_FAILED_INIT, /* 2 */
- CURLE_URL_MALFORMAT, /* 3 */
- CURLE_URL_MALFORMAT_USER, /* 4 - NOT USED */
- CURLE_COULDNT_RESOLVE_PROXY, /* 5 */
- CURLE_COULDNT_RESOLVE_HOST, /* 6 */
- CURLE_COULDNT_CONNECT, /* 7 */
- CURLE_FTP_WEIRD_SERVER_REPLY, /* 8 */
- CURLE_FTP_ACCESS_DENIED, /* 9 a service was denied by the FTP server
- due to lack of access - when login fails
- this is not returned. */
- CURLE_FTP_USER_PASSWORD_INCORRECT, /* 10 - NOT USED */
- CURLE_FTP_WEIRD_PASS_REPLY, /* 11 */
- CURLE_FTP_WEIRD_USER_REPLY, /* 12 */
- CURLE_FTP_WEIRD_PASV_REPLY, /* 13 */
- CURLE_FTP_WEIRD_227_FORMAT, /* 14 */
- CURLE_FTP_CANT_GET_HOST, /* 15 */
- CURLE_FTP_CANT_RECONNECT, /* 16 */
- CURLE_FTP_COULDNT_SET_BINARY, /* 17 */
- CURLE_PARTIAL_FILE, /* 18 */
- CURLE_FTP_COULDNT_RETR_FILE, /* 19 */
- CURLE_FTP_WRITE_ERROR, /* 20 */
- CURLE_FTP_QUOTE_ERROR, /* 21 */
- CURLE_HTTP_RETURNED_ERROR, /* 22 */
- CURLE_WRITE_ERROR, /* 23 */
- CURLE_MALFORMAT_USER, /* 24 - NOT USED */
- CURLE_FTP_COULDNT_STOR_FILE, /* 25 - failed FTP upload */
- CURLE_READ_ERROR, /* 26 - could open/read from file */
- CURLE_OUT_OF_MEMORY, /* 27 */
- /* Note: CURLE_OUT_OF_MEMORY may sometimes indicate a conversion error
- instead of a memory allocation error if CURL_DOES_CONVERSIONS
- is defined
- */
- CURLE_OPERATION_TIMEOUTED, /* 28 - the timeout time was reached */
- CURLE_FTP_COULDNT_SET_ASCII, /* 29 - TYPE A failed */
- CURLE_FTP_PORT_FAILED, /* 30 - FTP PORT operation failed */
- CURLE_FTP_COULDNT_USE_REST, /* 31 - the REST command failed */
- CURLE_FTP_COULDNT_GET_SIZE, /* 32 - the SIZE command failed */
- CURLE_HTTP_RANGE_ERROR, /* 33 - RANGE "command" didn't work */
- CURLE_HTTP_POST_ERROR, /* 34 */
- CURLE_SSL_CONNECT_ERROR, /* 35 - wrong when connecting with SSL */
- CURLE_BAD_DOWNLOAD_RESUME, /* 36 - couldn't resume download */
- CURLE_FILE_COULDNT_READ_FILE, /* 37 */
- CURLE_LDAP_CANNOT_BIND, /* 38 */
- CURLE_LDAP_SEARCH_FAILED, /* 39 */
- CURLE_LIBRARY_NOT_FOUND, /* 40 */
- CURLE_FUNCTION_NOT_FOUND, /* 41 */
- CURLE_ABORTED_BY_CALLBACK, /* 42 */
- CURLE_BAD_FUNCTION_ARGUMENT, /* 43 */
- CURLE_BAD_CALLING_ORDER, /* 44 - NOT USED */
- CURLE_INTERFACE_FAILED, /* 45 - CURLOPT_INTERFACE failed */
- CURLE_BAD_PASSWORD_ENTERED, /* 46 - NOT USED */
- CURLE_TOO_MANY_REDIRECTS , /* 47 - catch endless re-direct loops */
- CURLE_UNKNOWN_TELNET_OPTION, /* 48 - User specified an unknown option */
- CURLE_TELNET_OPTION_SYNTAX , /* 49 - Malformed telnet option */
- CURLE_OBSOLETE, /* 50 - NOT USED */
- CURLE_SSL_PEER_CERTIFICATE, /* 51 - peer's certificate wasn't ok */
- CURLE_GOT_NOTHING, /* 52 - when this is a specific error */
- CURLE_SSL_ENGINE_NOTFOUND, /* 53 - SSL crypto engine not found */
- CURLE_SSL_ENGINE_SETFAILED, /* 54 - can not set SSL crypto engine as
- default */
- CURLE_SEND_ERROR, /* 55 - failed sending network data */
- CURLE_RECV_ERROR, /* 56 - failure in receiving network data */
- CURLE_SHARE_IN_USE, /* 57 - share is in use */
- CURLE_SSL_CERTPROBLEM, /* 58 - problem with the local certificate */
- CURLE_SSL_CIPHER, /* 59 - couldn't use specified cipher */
- CURLE_SSL_CACERT, /* 60 - problem with the CA cert (path?) */
- CURLE_BAD_CONTENT_ENCODING, /* 61 - Unrecognized transfer encoding */
- CURLE_LDAP_INVALID_URL, /* 62 - Invalid LDAP URL */
- CURLE_FILESIZE_EXCEEDED, /* 63 - Maximum file size exceeded */
- CURLE_FTP_SSL_FAILED, /* 64 - Requested FTP SSL level failed */
- CURLE_SEND_FAIL_REWIND, /* 65 - Sending the data requires a rewind
- that failed */
- CURLE_SSL_ENGINE_INITFAILED, /* 66 - failed to initialise ENGINE */
- CURLE_LOGIN_DENIED, /* 67 - user, password or similar was not
- accepted and we failed to login */
- CURLE_TFTP_NOTFOUND, /* 68 - file not found on server */
- CURLE_TFTP_PERM, /* 69 - permission problem on server */
- CURLE_TFTP_DISKFULL, /* 70 - out of disk space on server */
- CURLE_TFTP_ILLEGAL, /* 71 - Illegal TFTP operation */
- CURLE_TFTP_UNKNOWNID, /* 72 - Unknown transfer ID */
- CURLE_TFTP_EXISTS, /* 73 - File already exists */
- CURLE_TFTP_NOSUCHUSER, /* 74 - No such user */
- CURLE_CONV_FAILED, /* 75 - conversion failed */
- CURLE_CONV_REQD, /* 76 - caller must register conversion
- callbacks using curl_easy_setopt options
- CURLOPT_CONV_FROM_NETWORK_FUNCTION,
- CURLOPT_CONV_TO_NETWORK_FUNCTION, and
- CURLOPT_CONV_FROM_UTF8_FUNCTION */
- CURLE_SSL_CRL_BADFILE = 82, /* 82 - could not load CRL file, missing or
- wrong format (Added in 7.19.0) */
- CURL_LAST /* never use! */
-} CURLcode;
-
-/* This prototype applies to all conversion callbacks */
-typedef CURLcode (*curl_conv_callback)(char *buffer, size_t length);
-
-typedef CURLcode (*curl_ssl_ctx_callback)(CURL *curl, /* easy handle */
- void *ssl_ctx, /* actually an
- OpenSSL SSL_CTX */
- void *userptr);
-
-/* Make a spelling correction for the operation timed-out define */
-#define CURLE_OPERATION_TIMEDOUT CURLE_OPERATION_TIMEOUTED
-
-#ifndef CURL_NO_OLDIES /* define this to test if your app builds with all
- the obsolete stuff removed! */
-/* backwards compatibility with older names */
-#define CURLE_HTTP_NOT_FOUND CURLE_HTTP_RETURNED_ERROR
-#define CURLE_HTTP_PORT_FAILED CURLE_INTERFACE_FAILED
-#endif
-
-typedef enum {
- CURLPROXY_HTTP = 0,
- CURLPROXY_SOCKS4 = 4,
- CURLPROXY_SOCKS5 = 5
-} curl_proxytype;
-
-#define CURLAUTH_NONE 0 /* nothing */
-#define CURLAUTH_BASIC (1<<0) /* Basic (default) */
-#define CURLAUTH_DIGEST (1<<1) /* Digest */
-#define CURLAUTH_GSSNEGOTIATE (1<<2) /* GSS-Negotiate */
-#define CURLAUTH_NTLM (1<<3) /* NTLM */
-#define CURLAUTH_ANY ~0 /* all types set */
-#define CURLAUTH_ANYSAFE (~CURLAUTH_BASIC)
-
-#ifndef CURL_NO_OLDIES /* define this to test if your app builds with all
- the obsolete stuff removed! */
-/* this was the error code 50 in 7.7.3 and a few earlier versions, this
- is no longer used by libcurl but is instead #defined here only to not
- make programs break */
-#define CURLE_ALREADY_COMPLETE 99999
-
-/* These are just to make older programs not break: */
-#define CURLE_FTP_PARTIAL_FILE CURLE_PARTIAL_FILE
-#define CURLE_FTP_BAD_DOWNLOAD_RESUME CURLE_BAD_DOWNLOAD_RESUME
-#endif
-
-#define CURLGSSAPI_DELEGATION_NONE 0 /* no delegation (default) */
-#define CURLGSSAPI_DELEGATION_POLICY_FLAG (1<<0) /* if permitted by policy */
-#define CURLGSSAPI_DELEGATION_FLAG (1<<1) /* delegate always */
-
-#define CURL_ERROR_SIZE 256
-
-/* parameter for the CURLOPT_FTP_SSL option */
-typedef enum {
- CURLFTPSSL_NONE, /* do not attempt to use SSL */
- CURLFTPSSL_TRY, /* try using SSL, proceed anyway otherwise */
- CURLFTPSSL_CONTROL, /* SSL for the control connection or fail */
- CURLFTPSSL_ALL, /* SSL for all communication or fail */
- CURLFTPSSL_LAST /* not an option, never use */
-} curl_ftpssl;
-
-/* parameter for the CURLOPT_FTPSSLAUTH option */
-typedef enum {
- CURLFTPAUTH_DEFAULT, /* let libcurl decide */
- CURLFTPAUTH_SSL, /* use "AUTH SSL" */
- CURLFTPAUTH_TLS, /* use "AUTH TLS" */
- CURLFTPAUTH_LAST /* not an option, never use */
-} curl_ftpauth;
-
-/* parameter for the CURLOPT_FTP_FILEMETHOD option */
-typedef enum {
- CURLFTPMETHOD_DEFAULT, /* let libcurl pick */
- CURLFTPMETHOD_MULTICWD, /* single CWD operation for each path part */
- CURLFTPMETHOD_NOCWD, /* no CWD at all */
- CURLFTPMETHOD_SINGLECWD, /* one CWD to full dir, then work on file */
- CURLFTPMETHOD_LAST /* not an option, never use */
-} curl_ftpmethod;
-
-/* CURLPROTO_ defines are for the CURLOPT_*PROTOCOLS options */
-#define CURLPROTO_HTTP (1<<0)
-#define CURLPROTO_HTTPS (1<<1)
-#define CURLPROTO_FTP (1<<2)
-#define CURLPROTO_FTPS (1<<3)
-#define CURLPROTO_TELNET (1<<6)
-#define CURLPROTO_LDAP (1<<7)
-#define CURLPROTO_LDAPS (1<<8)
-#define CURLPROTO_DICT (1<<9)
-#define CURLPROTO_FILE (1<<10)
-#define CURLPROTO_TFTP (1<<11)
-#define CURLPROTO_ALL (~0) /* enable everything */
-
-/* long may be 32 or 64 bits, but we should never depend on anything else
- but 32 */
-#define CURLOPTTYPE_LONG 0
-#define CURLOPTTYPE_OBJECTPOINT 10000
-#define CURLOPTTYPE_FUNCTIONPOINT 20000
-#define CURLOPTTYPE_OFF_T 30000
-
-/* name is uppercase CURLOPT_<name>,
- type is one of the defined CURLOPTTYPE_<type>
- number is unique identifier */
-#ifdef CINIT
-#undef CINIT
-#endif
-/*
- * Figure out if we can use the ## operator, which is supported by ISO/ANSI C
- * and C++. Some compilers support it without setting __STDC__ or __cplusplus
- * so we need to carefully check for them too. We don't use configure-checks
- * for these since we want these headers to remain generic and working for all
- * platforms.
- */
-#if defined(__STDC__) || defined(_MSC_VER) || defined(__cplusplus) || \
- defined(__HP_aCC) || defined(__BORLANDC__) || defined(__LCC__) || \
- defined(__POCC__) || defined(__SALFORDC__)
- /* This compiler is believed to have an ISO compatible preprocessor */
-#define CURL_ISOCPP
-#else
- /* This compiler is believed NOT to have an ISO compatible preprocessor */
-#undef CURL_ISOCPP
-#endif
-
-#ifdef CURL_ISOCPP
-#define CINIT(name,type,number) CURLOPT_ ## name = CURLOPTTYPE_ ## type + number
-#else
-/* The macro "##" is ISO C, we assume pre-ISO C doesn't support it. */
-#define LONG CURLOPTTYPE_LONG
-#define OBJECTPOINT CURLOPTTYPE_OBJECTPOINT
-#define FUNCTIONPOINT CURLOPTTYPE_FUNCTIONPOINT
-#define OFF_T CURLOPTTYPE_OFF_T
-#define CINIT(name,type,number) CURLOPT_/**/name = type + number
-#endif
-
-/*
- * This macro-mania below setups the CURLOPT_[what] enum, to be used with
- * curl_easy_setopt(). The first argument in the CINIT() macro is the [what]
- * word.
- */
-
-typedef enum {
- /* This is the FILE * or void * the regular output should be written to. */
- CINIT(FILE, OBJECTPOINT, 1),
-
- /* The full URL to get/put */
- CINIT(URL, OBJECTPOINT, 2),
-
- /* Port number to connect to, if other than default. */
- CINIT(PORT, LONG, 3),
-
- /* Name of proxy to use. */
- CINIT(PROXY, OBJECTPOINT, 4),
-
- /* "name:password" to use when fetching. */
- CINIT(USERPWD, OBJECTPOINT, 5),
-
- /* "name:password" to use with proxy. */
- CINIT(PROXYUSERPWD, OBJECTPOINT, 6),
-
- /* Range to get, specified as an ASCII string. */
- CINIT(RANGE, OBJECTPOINT, 7),
-
- /* not used */
-
- /* Specified file stream to upload from (use as input): */
- CINIT(INFILE, OBJECTPOINT, 9),
-
- /* Buffer to receive error messages in, must be at least CURL_ERROR_SIZE
- * bytes big. If this is not used, error messages go to stderr instead: */
- CINIT(ERRORBUFFER, OBJECTPOINT, 10),
-
- /* Function that will be called to store the output (instead of fwrite). The
- * parameters will use fwrite() syntax, make sure to follow them. */
- CINIT(WRITEFUNCTION, FUNCTIONPOINT, 11),
-
- /* Function that will be called to read the input (instead of fread). The
- * parameters will use fread() syntax, make sure to follow them. */
- CINIT(READFUNCTION, FUNCTIONPOINT, 12),
-
- /* Time-out the read operation after this amount of seconds */
- CINIT(TIMEOUT, LONG, 13),
-
- /* If the CURLOPT_INFILE is used, this can be used to inform libcurl about
- * how large the file being sent really is. That allows better error
- * checking and better verifies that the upload was succcessful. -1 means
- * unknown size.
- *
- * For large file support, there is also a _LARGE version of the key
- * which takes an off_t type, allowing platforms with larger off_t
- * sizes to handle larger files. See below for INFILESIZE_LARGE.
- */
- CINIT(INFILESIZE, LONG, 14),
-
- /* POST input fields. */
- CINIT(POSTFIELDS, OBJECTPOINT, 15),
-
- /* Set the referer page (needed by some CGIs) */
- CINIT(REFERER, OBJECTPOINT, 16),
-
- /* Set the FTP PORT string (interface name, named or numerical IP address)
- Use i.e '-' to use default address. */
- CINIT(FTPPORT, OBJECTPOINT, 17),
-
- /* Set the User-Agent string (examined by some CGIs) */
- CINIT(USERAGENT, OBJECTPOINT, 18),
-
- /* If the download receives less than "low speed limit" bytes/second
- * during "low speed time" seconds, the operations is aborted.
- * You could i.e if you have a pretty high speed connection, abort if
- * it is less than 2000 bytes/sec during 20 seconds.
- */
-
- /* Set the "low speed limit" */
- CINIT(LOW_SPEED_LIMIT, LONG , 19),
-
- /* Set the "low speed time" */
- CINIT(LOW_SPEED_TIME, LONG, 20),
-
- /* Set the continuation offset.
- *
- * Note there is also a _LARGE version of this key which uses
- * off_t types, allowing for large file offsets on platforms which
- * use larger-than-32-bit off_t's. Look below for RESUME_FROM_LARGE.
- */
- CINIT(RESUME_FROM, LONG, 21),
-
- /* Set cookie in request: */
- CINIT(COOKIE, OBJECTPOINT, 22),
-
- /* This points to a linked list of headers, struct curl_slist kind */
- CINIT(HTTPHEADER, OBJECTPOINT, 23),
-
- /* This points to a linked list of post entries, struct HttpPost */
- CINIT(HTTPPOST, OBJECTPOINT, 24),
-
- /* name of the file keeping your private SSL-certificate */
- CINIT(SSLCERT, OBJECTPOINT, 25),
-
- /* password for the SSL-private key, keep this for compatibility */
- CINIT(SSLCERTPASSWD, OBJECTPOINT, 26),
- /* password for the SSL private key */
- CINIT(SSLKEYPASSWD, OBJECTPOINT, 26),
-
- /* send TYPE parameter? */
- CINIT(CRLF, LONG, 27),
-
- /* send linked-list of QUOTE commands */
- CINIT(QUOTE, OBJECTPOINT, 28),
-
- /* send FILE * or void * to store headers to, if you use a callback it
- is simply passed to the callback unmodified */
- CINIT(WRITEHEADER, OBJECTPOINT, 29),
-
- /* point to a file to read the initial cookies from, also enables
- "cookie awareness" */
- CINIT(COOKIEFILE, OBJECTPOINT, 31),
-
- /* What version to specifly try to use.
- See CURL_SSLVERSION defines below. */
- CINIT(SSLVERSION, LONG, 32),
-
- /* What kind of HTTP time condition to use, see defines */
- CINIT(TIMECONDITION, LONG, 33),
-
- /* Time to use with the above condition. Specified in number of seconds
- since 1 Jan 1970 */
- CINIT(TIMEVALUE, LONG, 34),
-
- /* 35 = OBSOLETE */
-
- /* Custom request, for customizing the get command like
- HTTP: DELETE, TRACE and others
- FTP: to use a different list command
- */
- CINIT(CUSTOMREQUEST, OBJECTPOINT, 36),
-
- /* HTTP request, for odd commands like DELETE, TRACE and others */
- CINIT(STDERR, OBJECTPOINT, 37),
-
- /* 38 is not used */
-
- /* send linked-list of post-transfer QUOTE commands */
- CINIT(POSTQUOTE, OBJECTPOINT, 39),
-
- /* Pass a pointer to string of the output using full variable-replacement
- as described elsewhere. */
- CINIT(WRITEINFO, OBJECTPOINT, 40),
-
- CINIT(VERBOSE, LONG, 41), /* talk a lot */
- CINIT(HEADER, LONG, 42), /* throw the header out too */
- CINIT(NOPROGRESS, LONG, 43), /* shut off the progress meter */
- CINIT(NOBODY, LONG, 44), /* use HEAD to get http document */
- CINIT(FAILONERROR, LONG, 45), /* no output on http error codes >= 300 */
- CINIT(UPLOAD, LONG, 46), /* this is an upload */
- CINIT(POST, LONG, 47), /* HTTP POST method */
- CINIT(FTPLISTONLY, LONG, 48), /* Use NLST when listing ftp dir */
-
- CINIT(FTPAPPEND, LONG, 50), /* Append instead of overwrite on upload! */
-
- /* Specify whether to read the user+password from the .netrc or the URL.
- * This must be one of the CURL_NETRC_* enums below. */
- CINIT(NETRC, LONG, 51),
-
- CINIT(FOLLOWLOCATION, LONG, 52), /* use Location: Luke! */
-
- CINIT(TRANSFERTEXT, LONG, 53), /* transfer data in text/ASCII format */
- CINIT(PUT, LONG, 54), /* HTTP PUT */
-
- /* 55 = OBSOLETE */
-
- /* Function that will be called instead of the internal progress display
- * function. This function should be defined as the curl_progress_callback
- * prototype defines. */
- CINIT(PROGRESSFUNCTION, FUNCTIONPOINT, 56),
-
- /* Data passed to the progress callback */
- CINIT(PROGRESSDATA, OBJECTPOINT, 57),
-
- /* We want the referer field set automatically when following locations */
- CINIT(AUTOREFERER, LONG, 58),
-
- /* Port of the proxy, can be set in the proxy string as well with:
- "[host]:[port]" */
- CINIT(PROXYPORT, LONG, 59),
-
- /* size of the POST input data, if strlen() is not good to use */
- CINIT(POSTFIELDSIZE, LONG, 60),
-
- /* tunnel non-http operations through a HTTP proxy */
- CINIT(HTTPPROXYTUNNEL, LONG, 61),
-
- /* Set the interface string to use as outgoing network interface */
- CINIT(INTERFACE, OBJECTPOINT, 62),
-
- /* Set the krb4 security level, this also enables krb4 awareness. This is a
- * string, 'clear', 'safe', 'confidential' or 'private'. If the string is
- * set but doesn't match one of these, 'private' will be used. */
- CINIT(KRB4LEVEL, OBJECTPOINT, 63),
-
- /* Set if we should verify the peer in ssl handshake, set 1 to verify. */
- CINIT(SSL_VERIFYPEER, LONG, 64),
-
- /* The CApath or CAfile used to validate the peer certificate
- this option is used only if SSL_VERIFYPEER is true */
- CINIT(CAINFO, OBJECTPOINT, 65),
-
- /* 66 = OBSOLETE */
- /* 67 = OBSOLETE */
-
- /* Maximum number of http redirects to follow */
- CINIT(MAXREDIRS, LONG, 68),
-
- /* Pass a long set to 1 to get the date of the requested document (if
- possible)! Pass a zero to shut it off. */
- CINIT(FILETIME, LONG, 69),
-
- /* This points to a linked list of telnet options */
- CINIT(TELNETOPTIONS, OBJECTPOINT, 70),
-
- /* Max amount of cached alive connections */
- CINIT(MAXCONNECTS, LONG, 71),
-
- /* What policy to use when closing connections when the cache is filled
- up */
- CINIT(CLOSEPOLICY, LONG, 72),
-
- /* 73 = OBSOLETE */
-
- /* Set to explicitly use a new connection for the upcoming transfer.
- Do not use this unless you're absolutely sure of this, as it makes the
- operation slower and is less friendly for the network. */
- CINIT(FRESH_CONNECT, LONG, 74),
-
- /* Set to explicitly forbid the upcoming transfer's connection to be re-used
- when done. Do not use this unless you're absolutely sure of this, as it
- makes the operation slower and is less friendly for the network. */
- CINIT(FORBID_REUSE, LONG, 75),
-
- /* Set to a file name that contains random data for libcurl to use to
- seed the random engine when doing SSL connects. */
- CINIT(RANDOM_FILE, OBJECTPOINT, 76),
-
- /* Set to the Entropy Gathering Daemon socket pathname */
- CINIT(EGDSOCKET, OBJECTPOINT, 77),
-
- /* Time-out connect operations after this amount of seconds, if connects
- are OK within this time, then fine... This only aborts the connect
- phase. [Only works on unix-style/SIGALRM operating systems] */
- CINIT(CONNECTTIMEOUT, LONG, 78),
-
- /* Function that will be called to store headers (instead of fwrite). The
- * parameters will use fwrite() syntax, make sure to follow them. */
- CINIT(HEADERFUNCTION, FUNCTIONPOINT, 79),
-
- /* Set this to force the HTTP request to get back to GET. Only really usable
- if POST, PUT or a custom request have been used first.
- */
- CINIT(HTTPGET, LONG, 80),
-
- /* Set if we should verify the Common name from the peer certificate in ssl
- * handshake, set 1 to check existence, 2 to ensure that it matches the
- * provided hostname. */
- CINIT(SSL_VERIFYHOST, LONG, 81),
-
- /* Specify which file name to write all known cookies in after completed
- operation. Set file name to "-" (dash) to make it go to stdout. */
- CINIT(COOKIEJAR, OBJECTPOINT, 82),
-
- /* Specify which SSL ciphers to use */
- CINIT(SSL_CIPHER_LIST, OBJECTPOINT, 83),
-
- /* Specify which HTTP version to use! This must be set to one of the
- CURL_HTTP_VERSION* enums set below. */
- CINIT(HTTP_VERSION, LONG, 84),
-
- /* Specificly switch on or off the FTP engine's use of the EPSV command. By
- default, that one will always be attempted before the more traditional
- PASV command. */
- CINIT(FTP_USE_EPSV, LONG, 85),
-
- /* type of the file keeping your SSL-certificate ("DER", "PEM", "ENG") */
- CINIT(SSLCERTTYPE, OBJECTPOINT, 86),
-
- /* name of the file keeping your private SSL-key */
- CINIT(SSLKEY, OBJECTPOINT, 87),
-
- /* type of the file keeping your private SSL-key ("DER", "PEM", "ENG") */
- CINIT(SSLKEYTYPE, OBJECTPOINT, 88),
-
- /* crypto engine for the SSL-sub system */
- CINIT(SSLENGINE, OBJECTPOINT, 89),
-
- /* set the crypto engine for the SSL-sub system as default
- the param has no meaning...
- */
- CINIT(SSLENGINE_DEFAULT, LONG, 90),
-
- /* Non-zero value means to use the global dns cache */
- CINIT(DNS_USE_GLOBAL_CACHE, LONG, 91), /* To becomeO BSOLETE soon */
-
- /* DNS cache timeout */
- CINIT(DNS_CACHE_TIMEOUT, LONG, 92),
-
- /* send linked-list of pre-transfer QUOTE commands (Wesley Laxton)*/
- CINIT(PREQUOTE, OBJECTPOINT, 93),
-
- /* set the debug function */
- CINIT(DEBUGFUNCTION, FUNCTIONPOINT, 94),
-
- /* set the data for the debug function */
- CINIT(DEBUGDATA, OBJECTPOINT, 95),
-
- /* mark this as start of a cookie session */
- CINIT(COOKIESESSION, LONG, 96),
-
- /* The CApath directory used to validate the peer certificate
- this option is used only if SSL_VERIFYPEER is true */
- CINIT(CAPATH, OBJECTPOINT, 97),
-
- /* Instruct libcurl to use a smaller receive buffer */
- CINIT(BUFFERSIZE, LONG, 98),
-
- /* Instruct libcurl to not use any signal/alarm handlers, even when using
- timeouts. This option is useful for multi-threaded applications.
- See libcurl-the-guide for more background information. */
- CINIT(NOSIGNAL, LONG, 99),
-
- /* Provide a CURLShare for mutexing non-ts data */
- CINIT(SHARE, OBJECTPOINT, 100),
-
- /* indicates type of proxy. accepted values are CURLPROXY_HTTP (default),
- CURLPROXY_SOCKS4 and CURLPROXY_SOCKS5. */
- CINIT(PROXYTYPE, LONG, 101),
-
- /* Set the Accept-Encoding string. Use this to tell a server you would like
- the response to be compressed. */
- CINIT(ENCODING, OBJECTPOINT, 102),
-
- /* Set pointer to private data */
- CINIT(PRIVATE, OBJECTPOINT, 103),
-
- /* Set aliases for HTTP 200 in the HTTP Response header */
- CINIT(HTTP200ALIASES, OBJECTPOINT, 104),
-
- /* Continue to send authentication (user+password) when following locations,
- even when hostname changed. This can potentionally send off the name
- and password to whatever host the server decides. */
- CINIT(UNRESTRICTED_AUTH, LONG, 105),
-
- /* Specificly switch on or off the FTP engine's use of the EPRT command ( it
- also disables the LPRT attempt). By default, those ones will always be
- attempted before the good old traditional PORT command. */
- CINIT(FTP_USE_EPRT, LONG, 106),
-
- /* Set this to a bitmask value to enable the particular authentications
- methods you like. Use this in combination with CURLOPT_USERPWD.
- Note that setting multiple bits may cause extra network round-trips. */
- CINIT(HTTPAUTH, LONG, 107),
-
- /* Set the ssl context callback function, currently only for OpenSSL ssl_ctx
- in second argument. The function must be matching the
- curl_ssl_ctx_callback proto. */
- CINIT(SSL_CTX_FUNCTION, FUNCTIONPOINT, 108),
-
- /* Set the userdata for the ssl context callback function's third
- argument */
- CINIT(SSL_CTX_DATA, OBJECTPOINT, 109),
-
- /* FTP Option that causes missing dirs to be created on the remote server */
- CINIT(FTP_CREATE_MISSING_DIRS, LONG, 110),
-
- /* Set this to a bitmask value to enable the particular authentications
- methods you like. Use this in combination with CURLOPT_PROXYUSERPWD.
- Note that setting multiple bits may cause extra network round-trips. */
- CINIT(PROXYAUTH, LONG, 111),
-
- /* FTP option that changes the timeout, in seconds, associated with
- getting a response. This is different from transfer timeout time and
- essentially places a demand on the FTP server to acknowledge commands
- in a timely manner. */
- CINIT(FTP_RESPONSE_TIMEOUT, LONG , 112),
-
- /* Set this option to one of the CURL_IPRESOLVE_* defines (see below) to
- tell libcurl to resolve names to those IP versions only. This only has
- affect on systems with support for more than one, i.e IPv4 _and_ IPv6. */
- CINIT(IPRESOLVE, LONG, 113),
-
- /* Set this option to limit the size of a file that will be downloaded from
- an HTTP or FTP server.
-
- Note there is also _LARGE version which adds large file support for
- platforms which have larger off_t sizes. See MAXFILESIZE_LARGE below. */
- CINIT(MAXFILESIZE, LONG, 114),
-
- /* See the comment for INFILESIZE above, but in short, specifies
- * the size of the file being uploaded. -1 means unknown.
- */
- CINIT(INFILESIZE_LARGE, OFF_T, 115),
-
- /* Sets the continuation offset. There is also a LONG version of this;
- * look above for RESUME_FROM.
- */
- CINIT(RESUME_FROM_LARGE, OFF_T, 116),
-
- /* Sets the maximum size of data that will be downloaded from
- * an HTTP or FTP server. See MAXFILESIZE above for the LONG version.
- */
- CINIT(MAXFILESIZE_LARGE, OFF_T, 117),
-
- /* Set this option to the file name of your .netrc file you want libcurl
- to parse (using the CURLOPT_NETRC option). If not set, libcurl will do
- a poor attempt to find the user's home directory and check for a .netrc
- file in there. */
- CINIT(NETRC_FILE, OBJECTPOINT, 118),
-
- /* Enable SSL/TLS for FTP, pick one of:
- CURLFTPSSL_TRY - try using SSL, proceed anyway otherwise
- CURLFTPSSL_CONTROL - SSL for the control connection or fail
- CURLFTPSSL_ALL - SSL for all communication or fail
- */
- CINIT(FTP_SSL, LONG, 119),
-
- /* The _LARGE version of the standard POSTFIELDSIZE option */
- CINIT(POSTFIELDSIZE_LARGE, OFF_T, 120),
-
- /* Enable/disable the TCP Nagle algorithm */
- CINIT(TCP_NODELAY, LONG, 121),
-
- /* 122 OBSOLETE, used in 7.12.3. Gone in 7.13.0 */
-
- /* When doing 3rd party transfer, set the source user and password with
- this */
- CINIT(SOURCE_USERPWD, OBJECTPOINT, 123),
-
- /* 124 OBSOLETE, used in 7.12.3. Gone in 7.13.0 */
- /* 125 OBSOLETE, used in 7.12.3. Gone in 7.13.0 */
- /* 126 OBSOLETE, used in 7.12.3. Gone in 7.13.0 */
-
- /* When doing 3rd party transfer, set the source pre-quote linked list
- of commands with this */
- CINIT(SOURCE_PREQUOTE, OBJECTPOINT, 127),
-
- /* When doing 3rd party transfer, set the source post-quote linked list
- of commands with this */
- CINIT(SOURCE_POSTQUOTE, OBJECTPOINT, 128),
-
- /* When FTP over SSL/TLS is selected (with CURLOPT_FTP_SSL), this option
- can be used to change libcurl's default action which is to first try
- "AUTH SSL" and then "AUTH TLS" in this order, and proceed when a OK
- response has been received.
-
- Available parameters are:
- CURLFTPAUTH_DEFAULT - let libcurl decide
- CURLFTPAUTH_SSL - try "AUTH SSL" first, then TLS
- CURLFTPAUTH_TLS - try "AUTH TLS" first, then SSL
- */
- CINIT(FTPSSLAUTH, LONG, 129),
-
- CINIT(IOCTLFUNCTION, FUNCTIONPOINT, 130),
- CINIT(IOCTLDATA, OBJECTPOINT, 131),
-
- /* To make a 3rd party transfer, set the source URL with this */
- CINIT(SOURCE_URL, OBJECTPOINT, 132),
-
- /* When doing 3rd party transfer, set the source quote linked list of
- commands with this */
- CINIT(SOURCE_QUOTE, OBJECTPOINT, 133),
-
- /* zero terminated string for pass on to the FTP server when asked for
- "account" info */
- CINIT(FTP_ACCOUNT, OBJECTPOINT, 134),
-
- /* feed cookies into cookie engine */
- CINIT(COOKIELIST, OBJECTPOINT, 135),
-
- /* ignore Content-Length */
- CINIT(IGNORE_CONTENT_LENGTH, LONG, 136),
-
- /* Set to non-zero to skip the IP address received in a 227 PASV FTP server
- response. Typically used for FTP-SSL purposes but is not restricted to
- that. libcurl will then instead use the same IP address it used for the
- control connection. */
- CINIT(FTP_SKIP_PASV_IP, LONG, 137),
-
- /* Select "file method" to use when doing FTP, see the curl_ftpmethod
- above. */
- CINIT(FTP_FILEMETHOD, LONG, 138),
-
- /* Local port number to bind the socket to */
- CINIT(LOCALPORT, LONG, 139),
-
- /* Number of ports to try, including the first one set with LOCALPORT.
- Thus, setting it to 1 will make no additional attempts but the first.
- */
- CINIT(LOCALPORTRANGE, LONG, 140),
-
- /* no transfer, set up connection and let application use the socket by
- extracting it with CURLINFO_LASTSOCKET */
- CINIT(CONNECT_ONLY, LONG, 141),
-
- /* Function that will be called to convert from the
- network encoding (instead of using the iconv calls in libcurl) */
- CINIT(CONV_FROM_NETWORK_FUNCTION, FUNCTIONPOINT, 142),
-
- /* Function that will be called to convert to the
- network encoding (instead of using the iconv calls in libcurl) */
- CINIT(CONV_TO_NETWORK_FUNCTION, FUNCTIONPOINT, 143),
-
- /* Function that will be called to convert from UTF8
- (instead of using the iconv calls in libcurl)
- Note that this is used only for SSL certificate processing */
- CINIT(CONV_FROM_UTF8_FUNCTION, FUNCTIONPOINT, 144),
-
- /* if the connection proceeds too quickly then need to slow it down */
- /* limit-rate: maximum number of bytes per second to send or receive */
- CINIT(MAX_SEND_SPEED_LARGE, OFF_T, 145),
- CINIT(MAX_RECV_SPEED_LARGE, OFF_T, 146),
-
- /* Pointer to command string to send if USER/PASS fails. */
- CINIT(FTP_ALTERNATIVE_TO_USER, OBJECTPOINT, 147),
-
- /* CRL file */
- CINIT(CRLFILE, OBJECTPOINT, 169),
-
- /* set the bitmask for the protocols that are allowed to be used for the
- transfer, which thus helps the app which takes URLs from users or other
- external inputs and want to restrict what protocol(s) to deal
- with. Defaults to CURLPROTO_ALL. */
- CINIT(PROTOCOLS, LONG, 181),
-
- /* set the bitmask for the protocols that libcurl is allowed to follow to,
- as a subset of the CURLOPT_PROTOCOLS ones. That means the protocol needs
- to be set in both bitmasks to be allowed to get redirected to. Defaults
- to CURLPROTO_ALL & ~CURLPROTO_FILE. */
- CINIT(REDIR_PROTOCOLS, LONG, 182),
-
- /* allow GSSAPI credential delegation */
- CINIT(GSSAPI_DELEGATION, LONG, 210),
-
- CURLOPT_LASTENTRY /* the last unused */
-} CURLoption;
-
- /* Below here follows defines for the CURLOPT_IPRESOLVE option. If a host
- name resolves addresses using more than one IP protocol version, this
- option might be handy to force libcurl to use a specific IP version. */
-#define CURL_IPRESOLVE_WHATEVER 0 /* default, resolves addresses to all IP
- versions that your system allows */
-#define CURL_IPRESOLVE_V4 1 /* resolve to ipv4 addresses */
-#define CURL_IPRESOLVE_V6 2 /* resolve to ipv6 addresses */
-
- /* three convenient "aliases" that follow the name scheme better */
-#define CURLOPT_WRITEDATA CURLOPT_FILE
-#define CURLOPT_READDATA CURLOPT_INFILE
-#define CURLOPT_HEADERDATA CURLOPT_WRITEHEADER
-
-#ifndef CURL_NO_OLDIES /* define this to test if your app builds with all
- the obsolete stuff removed! */
-#define CURLOPT_HTTPREQUEST -1
-#define CURLOPT_FTPASCII CURLOPT_TRANSFERTEXT
-#define CURLOPT_MUTE -2
-#define CURLOPT_PASSWDFUNCTION -3
-#define CURLOPT_PASSWDDATA -4
-#define CURLOPT_CLOSEFUNCTION -5
-
-#define CURLOPT_SOURCE_HOST -6
-#define CURLOPT_SOURCE_PATH -7
-#define CURLOPT_SOURCE_PORT -8
-#define CURLOPT_PASV_HOST -9
-
-#else
-/* This is set if CURL_NO_OLDIES is defined at compile-time */
-#undef CURLOPT_DNS_USE_GLOBAL_CACHE /* soon obsolete */
-#endif
-
-
- /* These enums are for use with the CURLOPT_HTTP_VERSION option. */
-enum {
- CURL_HTTP_VERSION_NONE, /* setting this means we don't care, and that we'd
- like the library to choose the best possible
- for us! */
- CURL_HTTP_VERSION_1_0, /* please use HTTP 1.0 in the request */
- CURL_HTTP_VERSION_1_1, /* please use HTTP 1.1 in the request */
-
- CURL_HTTP_VERSION_LAST /* *ILLEGAL* http version */
-};
-
- /* These enums are for use with the CURLOPT_NETRC option. */
-enum CURL_NETRC_OPTION {
- CURL_NETRC_IGNORED, /* The .netrc will never be read.
- * This is the default. */
- CURL_NETRC_OPTIONAL, /* A user:password in the URL will be preferred
- * to one in the .netrc. */
- CURL_NETRC_REQUIRED, /* A user:password in the URL will be ignored.
- * Unless one is set programmatically, the .netrc
- * will be queried. */
- CURL_NETRC_LAST
-};
-
-enum {
- CURL_SSLVERSION_DEFAULT,
- CURL_SSLVERSION_TLSv1,
- CURL_SSLVERSION_SSLv2,
- CURL_SSLVERSION_SSLv3,
-
- CURL_SSLVERSION_LAST /* never use, keep last */
-};
-
-
-typedef enum {
- CURL_TIMECOND_NONE,
-
- CURL_TIMECOND_IFMODSINCE,
- CURL_TIMECOND_IFUNMODSINCE,
- CURL_TIMECOND_LASTMOD,
-
- CURL_TIMECOND_LAST
-} curl_TimeCond;
-
-#ifdef __BEOS__
-#include <support/SupportDefs.h>
-#endif
-
-
-/* curl_strequal() and curl_strnequal() are subject for removal in a future
- libcurl, see lib/README.curlx for details */
-CURL_EXTERN int (curl_strequal)(const char *s1, const char *s2);
-CURL_EXTERN int (curl_strnequal)(const char *s1, const char *s2, size_t n);
-
-/* name is uppercase CURLFORM_<name> */
-#ifdef CFINIT
-#undef CFINIT
-#endif
-
-#ifdef CURL_ISOCPP
-#define CFINIT(name) CURLFORM_ ## name
-#else
-/* The macro "##" is ISO C, we assume pre-ISO C doesn't support it. */
-#define CFINIT(name) CURLFORM_/**/name
-#endif
-
-typedef enum {
- CFINIT(NOTHING), /********* the first one is unused ************/
-
- /* */
- CFINIT(COPYNAME),
- CFINIT(PTRNAME),
- CFINIT(NAMELENGTH),
- CFINIT(COPYCONTENTS),
- CFINIT(PTRCONTENTS),
- CFINIT(CONTENTSLENGTH),
- CFINIT(FILECONTENT),
- CFINIT(ARRAY),
- CFINIT(OBSOLETE),
- CFINIT(FILE),
-
- CFINIT(BUFFER),
- CFINIT(BUFFERPTR),
- CFINIT(BUFFERLENGTH),
-
- CFINIT(CONTENTTYPE),
- CFINIT(CONTENTHEADER),
- CFINIT(FILENAME),
- CFINIT(END),
- CFINIT(OBSOLETE2),
-
- CURLFORM_LASTENTRY /* the last unusued */
-} CURLformoption;
-
-#undef CFINIT /* done */
-
-/* structure to be used as parameter for CURLFORM_ARRAY */
-struct curl_forms {
- CURLformoption option;
- const char *value;
-};
-
-/* use this for multipart formpost building */
-/* Returns code for curl_formadd()
- *
- * Returns:
- * CURL_FORMADD_OK on success
- * CURL_FORMADD_MEMORY if the FormInfo allocation fails
- * CURL_FORMADD_OPTION_TWICE if one option is given twice for one Form
- * CURL_FORMADD_NULL if a null pointer was given for a char
- * CURL_FORMADD_MEMORY if the allocation of a FormInfo struct failed
- * CURL_FORMADD_UNKNOWN_OPTION if an unknown option was used
- * CURL_FORMADD_INCOMPLETE if the some FormInfo is not complete (or error)
- * CURL_FORMADD_MEMORY if a HttpPost struct cannot be allocated
- * CURL_FORMADD_MEMORY if some allocation for string copying failed.
- * CURL_FORMADD_ILLEGAL_ARRAY if an illegal option is used in an array
- *
- ***************************************************************************/
-typedef enum {
- CURL_FORMADD_OK, /* first, no error */
-
- CURL_FORMADD_MEMORY,
- CURL_FORMADD_OPTION_TWICE,
- CURL_FORMADD_NULL,
- CURL_FORMADD_UNKNOWN_OPTION,
- CURL_FORMADD_INCOMPLETE,
- CURL_FORMADD_ILLEGAL_ARRAY,
- CURL_FORMADD_DISABLED, /* libcurl was built with this disabled */
-
- CURL_FORMADD_LAST /* last */
-} CURLFORMcode;
-
-/*
- * NAME curl_formadd()
- *
- * DESCRIPTION
- *
- * Pretty advanved function for building multi-part formposts. Each invoke
- * adds one part that together construct a full post. Then use
- * CURLOPT_HTTPPOST to send it off to libcurl.
- */
-CURL_EXTERN CURLFORMcode curl_formadd(struct curl_httppost **httppost,
- struct curl_httppost **last_post,
- ...);
-
-/*
- * callback function for curl_formget()
- * The void *arg pointer will be the one passed as second argument to curl_formget().
- * The character buffer passed to it must not be freed.
- * Should return the buffer length passed to it as the argument "len" on success.
- */
-typedef size_t (*curl_formget_callback)(void *arg, const char *buf, size_t len);
-
-/*
- * NAME curl_formget()
- *
- * DESCRIPTION
- *
- * Serialize a curl_httppost struct built with curl_formadd().
- * Accepts a void pointer as second argument which will be passed to
- * the curl_formget_callback function.
- * Returns 0 on success.
- */
-CURL_EXTERN int curl_formget(struct curl_httppost *form, void *arg,
- curl_formget_callback append);
-/*
- * NAME curl_formfree()
- *
- * DESCRIPTION
- *
- * Free a multipart formpost previously built with curl_formadd().
- */
-CURL_EXTERN void curl_formfree(struct curl_httppost *form);
-
-/*
- * NAME curl_getenv()
- *
- * DESCRIPTION
- *
- * Returns a malloc()'ed string that MUST be curl_free()ed after usage is
- * complete. DEPRECATED - see lib/README.curlx
- */
-CURL_EXTERN char *curl_getenv(const char *variable);
-
-/*
- * NAME curl_version()
- *
- * DESCRIPTION
- *
- * Returns a static ascii string of the libcurl version.
- */
-CURL_EXTERN char *curl_version(void);
-
-/*
- * NAME curl_easy_escape()
- *
- * DESCRIPTION
- *
- * Escapes URL strings (converts all letters consider illegal in URLs to their
- * %XX versions). This function returns a new allocated string or NULL if an
- * error occurred.
- */
-CURL_EXTERN char *curl_easy_escape(CURL *handle,
- const char *string,
- int length);
-
-/* the previous version: */
-CURL_EXTERN char *curl_escape(const char *string,
- int length);
-
-
-/*
- * NAME curl_easy_unescape()
- *
- * DESCRIPTION
- *
- * Unescapes URL encoding in strings (converts all %XX codes to their 8bit
- * versions). This function returns a new allocated string or NULL if an error
- * occurred.
- * Conversion Note: On non-ASCII platforms the ASCII %XX codes are
- * converted into the host encoding.
- */
-CURL_EXTERN char *curl_easy_unescape(CURL *handle,
- const char *string,
- int length,
- int *outlength);
-
-/* the previous version */
-CURL_EXTERN char *curl_unescape(const char *string,
- int length);
-
-/*
- * NAME curl_free()
- *
- * DESCRIPTION
- *
- * Provided for de-allocation in the same translation unit that did the
- * allocation. Added in libcurl 7.10
- */
-CURL_EXTERN void curl_free(void *p);
-
-/*
- * NAME curl_global_init()
- *
- * DESCRIPTION
- *
- * curl_global_init() should be invoked exactly once for each application that
- * uses libcurl
- */
-CURL_EXTERN CURLcode curl_global_init(long flags);
-
-/*
- * NAME curl_global_init_mem()
- *
- * DESCRIPTION
- *
- * curl_global_init() or curl_global_init_mem() should be invoked exactly once
- * for each application that uses libcurl. This function can be used to
- * initialize libcurl and set user defined memory management callback
- * functions. Users can implement memory management routines to check for
- * memory leaks, check for mis-use of the curl library etc. User registered
- * callback routines with be invoked by this library instead of the system
- * memory management routines like malloc, free etc.
- */
-CURL_EXTERN CURLcode curl_global_init_mem(long flags,
- curl_malloc_callback m,
- curl_free_callback f,
- curl_realloc_callback r,
- curl_strdup_callback s,
- curl_calloc_callback c);
-
-/*
- * NAME curl_global_cleanup()
- *
- * DESCRIPTION
- *
- * curl_global_cleanup() should be invoked exactly once for each application
- * that uses libcurl
- */
-CURL_EXTERN void curl_global_cleanup(void);
-
-/* linked-list structure for the CURLOPT_QUOTE option (and other) */
-struct curl_slist {
- char *data;
- struct curl_slist *next;
-};
-
-/*
- * NAME curl_slist_append()
- *
- * DESCRIPTION
- *
- * Appends a string to a linked list. If no list exists, it will be created
- * first. Returns the new list, after appending.
- */
-CURL_EXTERN struct curl_slist *curl_slist_append(struct curl_slist *,
- const char *);
-
-/*
- * NAME curl_slist_free_all()
- *
- * DESCRIPTION
- *
- * free a previously built curl_slist.
- */
-CURL_EXTERN void curl_slist_free_all(struct curl_slist *);
-
-/*
- * NAME curl_getdate()
- *
- * DESCRIPTION
- *
- * Returns the time, in seconds since 1 Jan 1970 of the time string given in
- * the first argument. The time argument in the second parameter is unused
- * and should be set to NULL.
- */
-CURL_EXTERN time_t curl_getdate(const char *p, const time_t *unused);
-
-#define CURLINFO_STRING 0x100000
-#define CURLINFO_LONG 0x200000
-#define CURLINFO_DOUBLE 0x300000
-#define CURLINFO_SLIST 0x400000
-#define CURLINFO_MASK 0x0fffff
-#define CURLINFO_TYPEMASK 0xf00000
-
-typedef enum {
- CURLINFO_NONE, /* first, never use this */
- CURLINFO_EFFECTIVE_URL = CURLINFO_STRING + 1,
- CURLINFO_RESPONSE_CODE = CURLINFO_LONG + 2,
- CURLINFO_TOTAL_TIME = CURLINFO_DOUBLE + 3,
- CURLINFO_NAMELOOKUP_TIME = CURLINFO_DOUBLE + 4,
- CURLINFO_CONNECT_TIME = CURLINFO_DOUBLE + 5,
- CURLINFO_PRETRANSFER_TIME = CURLINFO_DOUBLE + 6,
- CURLINFO_SIZE_UPLOAD = CURLINFO_DOUBLE + 7,
- CURLINFO_SIZE_DOWNLOAD = CURLINFO_DOUBLE + 8,
- CURLINFO_SPEED_DOWNLOAD = CURLINFO_DOUBLE + 9,
- CURLINFO_SPEED_UPLOAD = CURLINFO_DOUBLE + 10,
- CURLINFO_HEADER_SIZE = CURLINFO_LONG + 11,
- CURLINFO_REQUEST_SIZE = CURLINFO_LONG + 12,
- CURLINFO_SSL_VERIFYRESULT = CURLINFO_LONG + 13,
- CURLINFO_FILETIME = CURLINFO_LONG + 14,
- CURLINFO_CONTENT_LENGTH_DOWNLOAD = CURLINFO_DOUBLE + 15,
- CURLINFO_CONTENT_LENGTH_UPLOAD = CURLINFO_DOUBLE + 16,
- CURLINFO_STARTTRANSFER_TIME = CURLINFO_DOUBLE + 17,
- CURLINFO_CONTENT_TYPE = CURLINFO_STRING + 18,
- CURLINFO_REDIRECT_TIME = CURLINFO_DOUBLE + 19,
- CURLINFO_REDIRECT_COUNT = CURLINFO_LONG + 20,
- CURLINFO_PRIVATE = CURLINFO_STRING + 21,
- CURLINFO_HTTP_CONNECTCODE = CURLINFO_LONG + 22,
- CURLINFO_HTTPAUTH_AVAIL = CURLINFO_LONG + 23,
- CURLINFO_PROXYAUTH_AVAIL = CURLINFO_LONG + 24,
- CURLINFO_OS_ERRNO = CURLINFO_LONG + 25,
- CURLINFO_NUM_CONNECTS = CURLINFO_LONG + 26,
- CURLINFO_SSL_ENGINES = CURLINFO_SLIST + 27,
- CURLINFO_COOKIELIST = CURLINFO_SLIST + 28,
- CURLINFO_LASTSOCKET = CURLINFO_LONG + 29,
- CURLINFO_FTP_ENTRY_PATH = CURLINFO_STRING + 30,
- /* Fill in new entries below here! */
-
- CURLINFO_LASTONE = 30
-} CURLINFO;
-
-/* CURLINFO_RESPONSE_CODE is the new name for the option previously known as
- CURLINFO_HTTP_CODE */
-#define CURLINFO_HTTP_CODE CURLINFO_RESPONSE_CODE
-
-typedef enum {
- CURLCLOSEPOLICY_NONE, /* first, never use this */
-
- CURLCLOSEPOLICY_OLDEST,
- CURLCLOSEPOLICY_LEAST_RECENTLY_USED,
- CURLCLOSEPOLICY_LEAST_TRAFFIC,
- CURLCLOSEPOLICY_SLOWEST,
- CURLCLOSEPOLICY_CALLBACK,
-
- CURLCLOSEPOLICY_LAST /* last, never use this */
-} curl_closepolicy;
-
-#define CURL_GLOBAL_SSL (1<<0)
-#define CURL_GLOBAL_WIN32 (1<<1)
-#define CURL_GLOBAL_ALL (CURL_GLOBAL_SSL|CURL_GLOBAL_WIN32)
-#define CURL_GLOBAL_NOTHING 0
-#define CURL_GLOBAL_DEFAULT CURL_GLOBAL_ALL
-
-
-/*****************************************************************************
- * Setup defines, protos etc for the sharing stuff.
- */
-
-/* Different data locks for a single share */
-typedef enum {
- CURL_LOCK_DATA_NONE = 0,
- /* CURL_LOCK_DATA_SHARE is used internaly to say that
- * the locking is just made to change the internal state of the share
- * itself.
- */
- CURL_LOCK_DATA_SHARE,
- CURL_LOCK_DATA_COOKIE,
- CURL_LOCK_DATA_DNS,
- CURL_LOCK_DATA_SSL_SESSION,
- CURL_LOCK_DATA_CONNECT,
- CURL_LOCK_DATA_LAST
-} curl_lock_data;
-
-/* Different lock access types */
-typedef enum {
- CURL_LOCK_ACCESS_NONE = 0, /* unspecified action */
- CURL_LOCK_ACCESS_SHARED = 1, /* for read perhaps */
- CURL_LOCK_ACCESS_SINGLE = 2, /* for write perhaps */
- CURL_LOCK_ACCESS_LAST /* never use */
-} curl_lock_access;
-
-typedef void (*curl_lock_function)(CURL *handle,
- curl_lock_data data,
- curl_lock_access locktype,
- void *userptr);
-typedef void (*curl_unlock_function)(CURL *handle,
- curl_lock_data data,
- void *userptr);
-
-typedef void CURLSH;
-
-typedef enum {
- CURLSHE_OK, /* all is fine */
- CURLSHE_BAD_OPTION, /* 1 */
- CURLSHE_IN_USE, /* 2 */
- CURLSHE_INVALID, /* 3 */
- CURLSHE_NOMEM, /* out of memory */
- CURLSHE_LAST /* never use */
-} CURLSHcode;
-
-typedef enum {
- CURLSHOPT_NONE, /* don't use */
- CURLSHOPT_SHARE, /* specify a data type to share */
- CURLSHOPT_UNSHARE, /* specify shich data type to stop sharing */
- CURLSHOPT_LOCKFUNC, /* pass in a 'curl_lock_function' pointer */
- CURLSHOPT_UNLOCKFUNC, /* pass in a 'curl_unlock_function' pointer */
- CURLSHOPT_USERDATA, /* pass in a user data pointer used in the lock/unlock
- callback functions */
- CURLSHOPT_LAST /* never use */
-} CURLSHoption;
-
-CURL_EXTERN CURLSH *curl_share_init(void);
-CURL_EXTERN CURLSHcode curl_share_setopt(CURLSH *, CURLSHoption option, ...);
-CURL_EXTERN CURLSHcode curl_share_cleanup(CURLSH *);
-
-/****************************************************************************
- * Structures for querying information about the curl library at runtime.
- */
-
-typedef enum {
- CURLVERSION_FIRST,
- CURLVERSION_SECOND,
- CURLVERSION_THIRD,
- CURLVERSION_LAST /* never actually use this */
-} CURLversion;
-
-/* The 'CURLVERSION_NOW' is the symbolic name meant to be used by
- basicly all programs ever, that want to get version information. It is
- meant to be a built-in version number for what kind of struct the caller
- expects. If the struct ever changes, we redefine the NOW to another enum
- from above. */
-#define CURLVERSION_NOW CURLVERSION_THIRD
-
-typedef struct {
- CURLversion age; /* age of the returned struct */
- const char *version; /* LIBCURL_VERSION */
- unsigned int version_num; /* LIBCURL_VERSION_NUM */
- const char *host; /* OS/host/cpu/machine when configured */
- int features; /* bitmask, see defines below */
- const char *ssl_version; /* human readable string */
- long ssl_version_num; /* not used anymore, always 0 */
- const char *libz_version; /* human readable string */
- /* protocols is terminated by an entry with a NULL protoname */
- const char * const *protocols;
-
- /* The fields below this were added in CURLVERSION_SECOND */
- const char *ares;
- int ares_num;
-
- /* This field was added in CURLVERSION_THIRD */
- const char *libidn;
-
- /* Same as '_libiconv_version' if built with HAVE_ICONV */
- int iconv_ver_num;
-} curl_version_info_data;
-
-#define CURL_VERSION_IPV6 (1<<0) /* IPv6-enabled */
-#define CURL_VERSION_KERBEROS4 (1<<1) /* kerberos auth is supported */
-#define CURL_VERSION_SSL (1<<2) /* SSL options are present */
-#define CURL_VERSION_LIBZ (1<<3) /* libz features are present */
-#define CURL_VERSION_NTLM (1<<4) /* NTLM auth is supported */
-#define CURL_VERSION_GSSNEGOTIATE (1<<5) /* Negotiate auth support */
-#define CURL_VERSION_DEBUG (1<<6) /* built with debug capabilities */
-#define CURL_VERSION_ASYNCHDNS (1<<7) /* asynchronous dns resolves */
-#define CURL_VERSION_SPNEGO (1<<8) /* SPNEGO auth */
-#define CURL_VERSION_LARGEFILE (1<<9) /* supports files bigger than 2GB */
-#define CURL_VERSION_IDN (1<<10) /* International Domain Names support */
-#define CURL_VERSION_SSPI (1<<11) /* SSPI is supported */
-#define CURL_VERSION_CONV (1<<12) /* character conversions are
- supported */
-
-/*
- * NAME curl_version_info()
- *
- * DESCRIPTION
- *
- * This function returns a pointer to a static copy of the version info
- * struct. See above.
- */
-CURL_EXTERN curl_version_info_data *curl_version_info(CURLversion);
-
-/*
- * NAME curl_easy_strerror()
- *
- * DESCRIPTION
- *
- * The curl_easy_strerror function may be used to turn a CURLcode value
- * into the equivalent human readable error string. This is useful
- * for printing meaningful error messages.
- */
-CURL_EXTERN const char *curl_easy_strerror(CURLcode);
-
-/*
- * NAME curl_share_strerror()
- *
- * DESCRIPTION
- *
- * The curl_share_strerror function may be used to turn a CURLSHcode value
- * into the equivalent human readable error string. This is useful
- * for printing meaningful error messages.
- */
-CURL_EXTERN const char *curl_share_strerror(CURLSHcode);
-
-#ifdef __cplusplus
-}
-#endif
-
-/* unfortunately, the easy.h and multi.h include files need options and info
- stuff before they can be included! */
-#include "easy.h" /* nothing in curl is fun without the easy stuff */
-#include "multi.h"
-
-#endif /* __CURL_CURL_H */
diff --git a/libs/kns/curlhdr/curlver.h b/libs/kns/curlhdr/curlver.h
deleted file mode 100644
index 46fc5d8..0000000
--- a/libs/kns/curlhdr/curlver.h
+++ /dev/null
@@ -1,56 +0,0 @@
-#ifndef __CURL_CURLVER_H
-#define __CURL_CURLVER_H
-/***************************************************************************
- * _ _ ____ _
- * Project ___| | | | _ \| |
- * / __| | | | |_) | |
- * | (__| |_| | _ <| |___
- * \___|\___/|_| \_\_____|
- *
- * Copyright (C) 1998 - 2006, Daniel Stenberg, <daniel at haxx.se>, et al.
- *
- * This software is licensed as described in the file COPYING, which
- * you should have received as part of this distribution. The terms
- * are also available at http://curl.haxx.se/docs/copyright.html.
- *
- * You may opt to use, copy, modify, merge, publish, distribute and/or sell
- * copies of the Software, and permit persons to whom the Software is
- * furnished to do so, under the terms of the COPYING file.
- *
- * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
- * KIND, either express or implied.
- *
- * $Id: curlver.h,v 1.1 2012/11/09 17:54:52 rodarmer Exp $
- ***************************************************************************/
-
-/* This header file contains nothing but libcurl version info, generated by
- a script at release-time. This was made its own header file in 7.11.2 */
-
-/* This is the version number of the libcurl package from which this header
- file origins: */
-#define LIBCURL_VERSION "7.15.5"
-
-/* The numeric version number is also available "in parts" by using these
- defines: */
-#define LIBCURL_VERSION_MAJOR 7
-#define LIBCURL_VERSION_MINOR 15
-#define LIBCURL_VERSION_PATCH 5
-
-/* This is the numeric version of the libcurl version number, meant for easier
- parsing and comparions by programs. The LIBCURL_VERSION_NUM define will
- always follow this syntax:
-
- 0xXXYYZZ
-
- Where XX, YY and ZZ are the main version, release and patch numbers in
- hexadecimal (using 8 bits each). All three numbers are always represented
- using two digits. 1.2 would appear as "0x010200" while version 9.11.7
- appears as "0x090b07".
-
- This 6-digit (24 bits) hexadecimal number does not show pre-release number,
- and it is always a greater number in a more recent release. It makes
- comparisons with greater than and less than work.
-*/
-#define LIBCURL_VERSION_NUM 0x070f05
-
-#endif /* __CURL_CURLVER_H */
diff --git a/libs/kns/curlhdr/easy.h b/libs/kns/curlhdr/easy.h
deleted file mode 100644
index 2f96c9a..0000000
--- a/libs/kns/curlhdr/easy.h
+++ /dev/null
@@ -1,81 +0,0 @@
-#ifndef __CURL_EASY_H
-#define __CURL_EASY_H
-/***************************************************************************
- * _ _ ____ _
- * Project ___| | | | _ \| |
- * / __| | | | |_) | |
- * | (__| |_| | _ <| |___
- * \___|\___/|_| \_\_____|
- *
- * Copyright (C) 1998 - 2004, Daniel Stenberg, <daniel at haxx.se>, et al.
- *
- * This software is licensed as described in the file COPYING, which
- * you should have received as part of this distribution. The terms
- * are also available at http://curl.haxx.se/docs/copyright.html.
- *
- * You may opt to use, copy, modify, merge, publish, distribute and/or sell
- * copies of the Software, and permit persons to whom the Software is
- * furnished to do so, under the terms of the COPYING file.
- *
- * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
- * KIND, either express or implied.
- *
- * $Id: easy.h,v 1.1 2012/11/09 17:54:52 rodarmer Exp $
- ***************************************************************************/
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-CURL_EXTERN CURL *curl_easy_init(void);
-CURL_EXTERN CURLcode curl_easy_setopt(CURL *curl, CURLoption option, ...);
-CURL_EXTERN CURLcode curl_easy_perform(CURL *curl);
-CURL_EXTERN void curl_easy_cleanup(CURL *curl);
-
-/*
- * NAME curl_easy_getinfo()
- *
- * DESCRIPTION
- *
- * Request internal information from the curl session with this function. The
- * third argument MUST be a pointer to a long, a pointer to a char * or a
- * pointer to a double (as the documentation describes elsewhere). The data
- * pointed to will be filled in accordingly and can be relied upon only if the
- * function returns CURLE_OK. This function is intended to get used *AFTER* a
- * performed transfer, all results from this function are undefined until the
- * transfer is completed.
- */
-CURL_EXTERN CURLcode curl_easy_getinfo(CURL *curl, CURLINFO info, ...);
-
-
-/*
- * NAME curl_easy_duphandle()
- *
- * DESCRIPTION
- *
- * Creates a new curl session handle with the same options set for the handle
- * passed in. Duplicating a handle could only be a matter of cloning data and
- * options, internal state info and things like persistant connections cannot
- * be transfered. It is useful in multithreaded applications when you can run
- * curl_easy_duphandle() for each new thread to avoid a series of identical
- * curl_easy_setopt() invokes in every thread.
- */
-CURL_EXTERN CURL* curl_easy_duphandle(CURL *curl);
-
-/*
- * NAME curl_easy_reset()
- *
- * DESCRIPTION
- *
- * Re-initializes a CURL handle to the default values. This puts back the
- * handle to the same state as it was in when it was just created.
- *
- * It does keep: live connections, the Session ID cache, the DNS cache and the
- * cookies.
- */
-CURL_EXTERN void curl_easy_reset(CURL *curl);
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
diff --git a/libs/kns/curlhdr/multi.h b/libs/kns/curlhdr/multi.h
deleted file mode 100644
index bbddc13..0000000
--- a/libs/kns/curlhdr/multi.h
+++ /dev/null
@@ -1,344 +0,0 @@
-#ifndef __CURL_MULTI_H
-#define __CURL_MULTI_H
-/***************************************************************************
- * _ _ ____ _
- * Project ___| | | | _ \| |
- * / __| | | | |_) | |
- * | (__| |_| | _ <| |___
- * \___|\___/|_| \_\_____|
- *
- * Copyright (C) 1998 - 2006, Daniel Stenberg, <daniel at haxx.se>, et al.
- *
- * This software is licensed as described in the file COPYING, which
- * you should have received as part of this distribution. The terms
- * are also available at http://curl.haxx.se/docs/copyright.html.
- *
- * You may opt to use, copy, modify, merge, publish, distribute and/or sell
- * copies of the Software, and permit persons to whom the Software is
- * furnished to do so, under the terms of the COPYING file.
- *
- * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
- * KIND, either express or implied.
- *
- * $Id: multi.h,v 1.1 2012/11/09 17:54:52 rodarmer Exp $
- ***************************************************************************/
-/*
- This is an "external" header file. Don't give away any internals here!
-
- GOALS
-
- o Enable a "pull" interface. The application that uses libcurl decides where
- and when to ask libcurl to get/send data.
-
- o Enable multiple simultaneous transfers in the same thread without making it
- complicated for the application.
-
- o Enable the application to select() on its own file descriptors and curl's
- file descriptors simultaneous easily.
-
-*/
-#if defined(_WIN32) && !defined(WIN32)
-/* Chris Lewis mentioned that he doesn't get WIN32 defined, only _WIN32 so we
- make this adjustment to catch this. */
-#define WIN32 1
-#endif
-
-#if defined(WIN32) && !defined(_WIN32_WCE) && !defined(__GNUC__) && \
- !defined(__CYGWIN__) || defined(__MINGW32__)
-#if !(defined(_WINSOCKAPI_) || defined(_WINSOCK_H))
-/* The check above prevents the winsock2 inclusion if winsock.h already was
- included, since they can't co-exist without problems */
-#include <winsock2.h>
-#endif
-#else
-
-/* HP-UX systems version 9, 10 and 11 lack sys/select.h and so does oldish
- libc5-based Linux systems. Only include it on system that are known to
- require it! */
-#if defined(_AIX) || defined(NETWARE) || defined(__NetBSD__) || defined(_MINIX)
-#include <sys/select.h>
-#endif
-
-#ifndef _WIN32_WCE
-#include <sys/socket.h>
-#endif
-#include <sys/time.h>
-#include <sys/types.h>
-#endif
-
-/*
- * This header file should not really need to include "curl.h" since curl.h
- * itself includes this file and we expect user applications to do #include
- * <curl/curl.h> without the need for especially including multi.h.
- *
- * For some reason we added this include here at one point, and rather than to
- * break existing (wrongly written) libcurl applications, we leave it as-is
- * but with this warning attached.
- */
-#include "curl.h"
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-typedef void CURLM;
-
-#ifndef curl_socket_typedef
-/* Public socket typedef */
-#ifdef WIN32
-typedef SOCKET curl_socket_t;
-#define CURL_SOCKET_BAD INVALID_SOCKET
-#else
-typedef int curl_socket_t;
-#define CURL_SOCKET_BAD -1
-#endif
-#define curl_socket_typedef
-#endif /* curl_socket_typedef */
-
-typedef enum {
- CURLM_CALL_MULTI_PERFORM = -1, /* please call curl_multi_perform() or
- curl_multi_socket*() soon */
- CURLM_OK,
- CURLM_BAD_HANDLE, /* the passed-in handle is not a valid CURLM handle */
- CURLM_BAD_EASY_HANDLE, /* an easy handle was not good/valid */
- CURLM_OUT_OF_MEMORY, /* if you ever get this, you're in deep sh*t */
- CURLM_INTERNAL_ERROR, /* this is a libcurl bug */
- CURLM_BAD_SOCKET, /* the passed in socket argument did not match */
- CURLM_UNKNOWN_OPTION, /* curl_multi_setopt() with unsupported option */
- CURLM_LAST
-} CURLMcode;
-
-/* just to make code nicer when using curl_multi_socket() you can now check
- for CURLM_CALL_MULTI_SOCKET too in the same style it works for
- curl_multi_perform() and CURLM_CALL_MULTI_PERFORM */
-#define CURLM_CALL_MULTI_SOCKET CURLM_CALL_MULTI_PERFORM
-
-typedef enum {
- CURLMSG_NONE, /* first, not used */
- CURLMSG_DONE, /* This easy handle has completed. 'result' contains
- the CURLcode of the transfer */
- CURLMSG_LAST /* last, not used */
-} CURLMSG;
-
-struct CURLMsg {
- CURLMSG msg; /* what this message means */
- CURL *easy_handle; /* the handle it concerns */
- union {
- void *whatever; /* message-specific data */
- CURLcode result; /* return code for transfer */
- } data;
-};
-typedef struct CURLMsg CURLMsg;
-
-/*
- * Name: curl_multi_init()
- *
- * Desc: inititalize multi-style curl usage
- *
- * Returns: a new CURLM handle to use in all 'curl_multi' functions.
- */
-CURL_EXTERN CURLM *curl_multi_init(void);
-
-/*
- * Name: curl_multi_add_handle()
- *
- * Desc: add a standard curl handle to the multi stack
- *
- * Returns: CURLMcode type, general multi error code.
- */
-CURL_EXTERN CURLMcode curl_multi_add_handle(CURLM *multi_handle,
- CURL *curl_handle);
-
- /*
- * Name: curl_multi_remove_handle()
- *
- * Desc: removes a curl handle from the multi stack again
- *
- * Returns: CURLMcode type, general multi error code.
- */
-CURL_EXTERN CURLMcode curl_multi_remove_handle(CURLM *multi_handle,
- CURL *curl_handle);
-
- /*
- * Name: curl_multi_fdset()
- *
- * Desc: Ask curl for its fd_set sets. The app can use these to select() or
- * poll() on. We want curl_multi_perform() called as soon as one of
- * them are ready.
- *
- * Returns: CURLMcode type, general multi error code.
- */
-CURL_EXTERN CURLMcode curl_multi_fdset(CURLM *multi_handle,
- fd_set *read_fd_set,
- fd_set *write_fd_set,
- fd_set *exc_fd_set,
- int *max_fd);
-
- /*
- * Name: curl_multi_perform()
- *
- * Desc: When the app thinks there's data available for curl it calls this
- * function to read/write whatever there is right now. This returns
- * as soon as the reads and writes are done. This function does not
- * require that there actually is data available for reading or that
- * data can be written, it can be called just in case. It returns
- * the number of handles that still transfer data in the second
- * argument's integer-pointer.
- *
- * Returns: CURLMcode type, general multi error code. *NOTE* that this only
- * returns errors etc regarding the whole multi stack. There might
- * still have occurred problems on invidual transfers even when this
- * returns OK.
- */
-CURL_EXTERN CURLMcode curl_multi_perform(CURLM *multi_handle,
- int *running_handles);
-
- /*
- * Name: curl_multi_cleanup()
- *
- * Desc: Cleans up and removes a whole multi stack. It does not free or
- * touch any individual easy handles in any way. We need to define
- * in what state those handles will be if this function is called
- * in the middle of a transfer.
- *
- * Returns: CURLMcode type, general multi error code.
- */
-CURL_EXTERN CURLMcode curl_multi_cleanup(CURLM *multi_handle);
-
-/*
- * Name: curl_multi_info_read()
- *
- * Desc: Ask the multi handle if there's any messages/informationals from
- * the individual transfers. Messages include informationals such as
- * error code from the transfer or just the fact that a transfer is
- * completed. More details on these should be written down as well.
- *
- * Repeated calls to this function will return a new struct each
- * time, until a special "end of msgs" struct is returned as a signal
- * that there is no more to get at this point.
- *
- * The data the returned pointer points to will not survive calling
- * curl_multi_cleanup().
- *
- * The 'CURLMsg' struct is meant to be very simple and only contain
- * very basic informations. If more involved information is wanted,
- * we will provide the particular "transfer handle" in that struct
- * and that should/could/would be used in subsequent
- * curl_easy_getinfo() calls (or similar). The point being that we
- * must never expose complex structs to applications, as then we'll
- * undoubtably get backwards compatibility problems in the future.
- *
- * Returns: A pointer to a filled-in struct, or NULL if it failed or ran out
- * of structs. It also writes the number of messages left in the
- * queue (after this read) in the integer the second argument points
- * to.
- */
-CURL_EXTERN CURLMsg *curl_multi_info_read(CURLM *multi_handle,
- int *msgs_in_queue);
-
-/*
- * Name: curl_multi_strerror()
- *
- * Desc: The curl_multi_strerror function may be used to turn a CURLMcode
- * value into the equivalent human readable error string. This is
- * useful for printing meaningful error messages.
- *
- * Returns: A pointer to a zero-terminated error message.
- */
-CURL_EXTERN const char *curl_multi_strerror(CURLMcode);
-
-/*
- * Name: curl_multi_socket() and
- * curl_multi_socket_all()
- *
- * Desc: An alternative version of curl_multi_perform() that allows the
- * application to pass in one of the file descriptors that have been
- * detected to have "action" on them and let libcurl perform.
- * See man page for details.
- */
-#define CURL_POLL_NONE 0
-#define CURL_POLL_IN 1
-#define CURL_POLL_OUT 2
-#define CURL_POLL_INOUT 3
-#define CURL_POLL_REMOVE 4
-
-#define CURL_SOCKET_TIMEOUT CURL_SOCKET_BAD
-
-typedef int (*curl_socket_callback)(CURL *easy, /* easy handle */
- curl_socket_t s, /* socket */
- int what, /* see above */
- void *userp, /* private callback
- pointer */
- void *socketp); /* private socket
- pointer */
-
-CURL_EXTERN CURLMcode curl_multi_socket(CURLM *multi_handle, curl_socket_t s,
- int *running_handles);
-
-CURL_EXTERN CURLMcode curl_multi_socket_all(CURLM *multi_handle,
- int *running_handles);
-
-/*
- * Name: curl_multi_timeout()
- *
- * Desc: Returns the maximum number of milliseconds the app is allowed to
- * wait before curl_multi_socket() or curl_multi_perform() must be
- * called (to allow libcurl's timed events to take place).
- *
- * Returns: CURLM error code.
- */
-CURL_EXTERN CURLMcode curl_multi_timeout(CURLM *multi_handle,
- long *milliseconds);
-
-#undef CINIT /* re-using the same name as in curl.h */
-
-#ifdef CURL_ISOCPP
-#define CINIT(name,type,number) CURLMOPT_ ## name = CURLOPTTYPE_ ## type + number
-#else
-/* The macro "##" is ISO C, we assume pre-ISO C doesn't support it. */
-#define LONG CURLOPTTYPE_LONG
-#define OBJECTPOINT CURLOPTTYPE_OBJECTPOINT
-#define FUNCTIONPOINT CURLOPTTYPE_FUNCTIONPOINT
-#define OFF_T CURLOPTTYPE_OFF_T
-#define CINIT(name,type,number) CURLMOPT_/**/name = type + number
-#endif
-
-typedef enum {
- /* This is the socket callback function pointer */
- CINIT(SOCKETFUNCTION, FUNCTIONPOINT, 1),
-
- /* This is the argument passed to the socket callback */
- CINIT(SOCKETDATA, OBJECTPOINT, 2),
-
- CURLMOPT_LASTENTRY /* the last unused */
-} CURLMoption;
-
-
-/*
- * Name: curl_multi_setopt()
- *
- * Desc: Sets options for the multi handle.
- *
- * Returns: CURLM error code.
- */
-CURL_EXTERN CURLMcode curl_multi_setopt(CURLM *multi_handle,
- CURLMoption option, ...);
-
-
-/*
- * Name: curl_multi_assign()
- *
- * Desc: This function sets an association in the multi handle between the
- * given socket and a private pointer of the application. This is
- * (only) useful for curl_multi_socket uses.
- *
- * Returns: CURLM error code.
- */
-CURL_EXTERN CURLMcode curl_multi_assign(CURLM *multi_handle,
- curl_socket_t sockfd, void *sockp);
-
-#ifdef __cplusplus
-} /* end of extern "C" */
-#endif
-
-#endif
diff --git a/libs/kns/curlhdr/types.h b/libs/kns/curlhdr/types.h
deleted file mode 100644
index d37d6ae..0000000
--- a/libs/kns/curlhdr/types.h
+++ /dev/null
@@ -1 +0,0 @@
-/* not used */
diff --git a/libs/kns/entrez-fetcher.c b/libs/kns/entrez-fetcher.c
deleted file mode 100644
index 0108ccd..0000000
--- a/libs/kns/entrez-fetcher.c
+++ /dev/null
@@ -1,221 +0,0 @@
-/*===========================================================================
-*
-* PUBLIC DOMAIN NOTICE
-* National Center for Biotechnology Information
-*
-* This software/database is a "United States Government Work" under the
-* terms of the United States Copyright Act. It was written as part of
-* the author's official duties as a United States Government employee and
-* thus cannot be copyrighted. This software/database is freely available
-* to the public for use. The National Library of Medicine and the U.S.
-* Government have not placed any restriction on its use or reproduction.
-*
-* Although all reasonable efforts have been taken to ensure the accuracy
-* and reliability of the software and data, the NLM and the U.S.
-* Government do not and cannot warrant the performance or results that
-* may be obtained by using this software or data. The NLM and the U.S.
-* Government disclaim all warranties, express or implied, including
-* warranties of performance, merchantability or fitness for any particular
-* purpose.
-*
-* Please cite the author in any work or product based on this material.
-*
-* ===========================================================================
-*
-*/
-
-#include <klib/rc.h>
-#include <klib/text.h>
-#include <klib/printf.h>
-#include <klib/refcount.h>
-#include <kns/entrez-fetcher.h>
-#include <kns/url-fetcher.h>
-#include <sysalloc.h>
-
-#include <stdlib.h>
-#include <string.h>
-
-#define URI_PARAM_LEN 70
-#define ENTREZ_FIRST_LINE_LEN 120
-#define ENTREZ_NEWLINE_DIV 80
-
-struct KEntrezFetcher
-{
- KRefcount refcount;
-
- KUrlFetcher * url_fetcher;
- char * uri;
-};
-
-static const char classname[] = "KSraFetcher";
-
-rc_t KEntrezFetcherAddRef ( const KEntrezFetcher *self )
-{
- if ( self != NULL )
- {
- switch ( KRefcountAdd ( & self -> refcount, classname ) )
- {
- case krefLimit:
- return RC ( rcApp, rcFunction, rcAttaching, rcRange, rcExcessive );
- }
- }
- return 0;
-}
-
-
-rc_t KEntrezFetcherRelease ( const KEntrezFetcher *cself )
-{
- KEntrezFetcher *self = ( KEntrezFetcher* ) cself;
- if ( cself != NULL )
- {
- switch ( KRefcountDrop ( & self -> refcount, classname ) )
- {
- case krefWhack:
- {
- KUrlFetcherRelease ( self -> url_fetcher );
- if ( self -> uri ) free( self -> uri );
- free( self );
- return 0;
- }
- case krefNegative:
- return RC ( rcApp, rcFunction, rcReleasing, rcRange, rcExcessive );
- }
- }
- return 0;
-}
-
-
-rc_t KEntrezFetcherSetupUri ( KEntrezFetcher *self, const char * uri )
-{
- if ( uri == NULL || uri[0] == 0 )
- return RC ( rcApp, rcFunction, rcAccessing, rcParam, rcNull );
- if ( self == NULL )
- return RC ( rcApp, rcFunction, rcAccessing, rcSelf, rcNull );
-
- if ( self -> uri ) free( self -> uri );
- self -> uri = string_dup_measure ( uri, NULL );
- return 0;
-}
-
-
-/* composes the internal uri from the parameters and returns an estimated buffersize */
-rc_t KEntrezFetcherSetup ( KEntrezFetcher *self,
- const char * server, const char * seq_id,
- const size_t max_seq_len, const uint64_t row_id, const size_t row_count,
- size_t * buffsize )
-{
- rc_t rc;
- size_t uri_len;
-
- if ( server == NULL || seq_id == NULL || buffsize == NULL )
- return RC ( rcApp, rcFunction, rcAccessing, rcParam, rcNull );
- if ( self == NULL )
- return RC ( rcApp, rcFunction, rcAccessing, rcSelf, rcNull );
-
- if ( self -> uri ) free( self -> uri );
- uri_len = string_size( server ) + string_size( seq_id ) + URI_PARAM_LEN;
- self -> uri = malloc( uri_len );
- if ( self -> uri != NULL )
- {
- size_t num_written;
- uint64_t seq_start, seq_stop;
-
- seq_start = max_seq_len * ( row_id - 1 ) + 1;
- seq_stop = max_seq_len * ( row_id + row_count - 1 );
-
- if ( seq_stop <= seq_start )
- return RC ( rcApp, rcFunction, rcAccessing, rcSelf, rcNull );
-
- *buffsize = ( seq_stop - seq_start );
- *buffsize += ( *buffsize / ENTREZ_NEWLINE_DIV );
- *buffsize += ENTREZ_FIRST_LINE_LEN;
-
- rc = string_printf ( self->uri, uri_len, &num_written,
- "%s?db=nucleotide&id=%s&rettype=fasta&seq_start=%lu&seq_stop=%lu",
- server, seq_id, seq_start, seq_stop );
- }
- else
- rc = RC( rcExe, rcString, rcAllocating, rcMemory, rcExhausted );
-
- return rc;
-}
-
-
-/* remove the first line, including it's line-feed */
-static void remove_first_line( char * s, size_t * len )
-{
- char * p = string_chr ( s, *len, '\n' );
- if ( p )
- {
- *len -= ( p - s ) + 1;
- memmove( s, p + 1, *len );
- }
-}
-
-
-/* filters out all char's c by using a filtered temp-buffer... */
-static void filter_char( char * s, size_t * len, const char c )
-{
- size_t src, dst;
-
- if ( s == NULL || len == NULL || *len == 0 )
- return;
-
- dst = 0;
- for ( src = 0; src < *len; ++src )
- {
- char ch = s[ src ];
- if ( ch != c )
- {
- if ( src != dst )
- s[ dst ] = ch;
- ++dst;
- }
- }
- *len = dst;
-}
-
-
-rc_t KEntrezFetcherRead ( KEntrezFetcher *self,
- void *dst, size_t dst_size, size_t *num_read )
-{
- rc_t rc;
-
- if ( dst == NULL || dst_size == 0 || num_read == NULL )
- return RC ( rcApp, rcFunction, rcAccessing, rcParam, rcNull );
- if ( self == NULL )
- return RC ( rcApp, rcFunction, rcAccessing, rcSelf, rcNull );
- if ( self -> url_fetcher == NULL || self -> uri == NULL )
- return RC ( rcApp, rcFunction, rcAccessing, rcParam, rcNull );
-
- rc = KUrlFetcherRead( self -> url_fetcher, self -> uri, dst, dst_size, num_read );
- if ( rc == 0 )
- {
- remove_first_line( dst, num_read );
- filter_char( dst, num_read, '\n' );
- }
- return rc;
-}
-
-
-rc_t KEntrezFetcherMake ( KEntrezFetcher **fetcher, KUrlFetcher * url_fetcher )
-{
- rc_t rc;
-
- if ( fetcher == NULL || url_fetcher == NULL )
- rc = RC ( rcApp, rcFunction, rcConstructing, rcParam, rcNull );
- else
- {
- *fetcher = malloc( sizeof( *fetcher ) );
- if ( *fetcher != NULL )
- {
- (*fetcher) -> url_fetcher = url_fetcher;
- KUrlFetcherAddRef ( url_fetcher );
- (*fetcher) -> uri = NULL;
- rc = 0;
- }
- else
- rc = RC( rcApp, rcFunction, rcListing, rcParam, rcNull );
- }
- return rc;
-}
diff --git a/libs/kns/http-priv.h b/libs/kns/http-priv.h
index bf5a218..0808e52 100644
--- a/libs/kns/http-priv.h
+++ b/libs/kns/http-priv.h
@@ -39,12 +39,27 @@
#include <klib/data-buffer.h>
#endif
+#ifndef _h_klib_container
+#include <klib/container.h>
+#endif
+
+#ifndef MAX_HTTP_READ_LIMIT
+#define MAX_HTTP_READ_LIMIT ( 30 * 1000 )
+#endif
+
+#ifndef MAX_HTTP_WRITE_LIMIT
+#define MAX_HTTP_WRITE_LIMIT ( 15 * 1000 )
+#endif
+
#ifdef __cplusplus
extern "C" {
#endif
struct KFile;
struct KHttp;
+struct KNSManager;
+struct KStream;
+struct timeout_t;
/*--------------------------------------------------------------------------
* URLBlock
@@ -78,16 +93,20 @@ struct KHttpHeader
};
extern void KHttpHeaderWhack ( BSTNode *n, void *ignore );
-extern rc_t KHttpGetHeaderLine ( struct KHttp *self, BSTree *hdrs, bool *blank, bool *close_connection );
-extern rc_t KHttpGetStatusLine ( struct KHttp *self, String *msg, uint32_t *status, ver_t *version );
+extern rc_t KHttpGetHeaderLine ( struct KHttp *self, struct timeout_t *tm, BSTree *hdrs, bool *blank, bool *close_connection );
+extern rc_t KHttpGetStatusLine ( struct KHttp *self, struct timeout_t *tm, String *msg, uint32_t *status, ver_t *version );
/* exported private functions
*/
-extern rc_t HttpTest ( const struct KFile *input );
+extern rc_t HttpTest ( struct KFile const *input );
extern void URLBlockInitTest ( void );
extern rc_t ParseUrlTest ( void );
extern rc_t MakeRequestTest ( void );
+/* tmp fix */
+rc_t SecretKNSManagerMakeHttpFile(const struct KNSManager *self,
+ const struct KFile **file, struct KStream *conn, ver_t vers, const char *url, ...);
+
#ifdef __cplusplus
}
#endif
diff --git a/libs/kns/http-test.c b/libs/kns/http-test.c
index 87539a5..3f0de53 100644
--- a/libs/kns/http-test.c
+++ b/libs/kns/http-test.c
@@ -215,7 +215,7 @@ rc_t HttpTest ( const KFile *input )
ver_t version;
uint32_t status;
- rc = KHttpGetStatusLine ( http, &msg, &status, &version );
+ rc = KHttpGetStatusLine ( http, NULL, &msg, &status, &version );
if ( rc != 0 )
OUTMSG (( "%s: KHttpGetStatusLine failed with rc=%R\n", __func__, rc ));
else
@@ -228,7 +228,7 @@ rc_t HttpTest ( const KFile *input )
BSTreeInit ( & hdrs );
for ( blank = close_connection = false; ! blank && rc == 0; )
- rc = KHttpGetHeaderLine ( http, & hdrs, & blank, & close_connection );
+ rc = KHttpGetHeaderLine ( http, NULL, & hdrs, & blank, & close_connection );
if ( rc != 0 )
OUTMSG (( "%s: KHttpGetHeaderLine failed with rc=%R\n", __func__, rc ));
diff --git a/libs/kns/http.c b/libs/kns/http.c
index cb963d8..44d5965 100644
--- a/libs/kns/http.c
+++ b/libs/kns/http.c
@@ -51,10 +51,13 @@ typedef struct KHttpFile KHttpFile;
#include <klib/rc.h>
#include <klib/printf.h>
#include <klib/vector.h>
+#include <kproc/timeout.h>
+#include <os-native.h>
#include <strtol.h>
#include <va_copy.h>
+#include "mgr-priv.h"
#include "stream-priv.h"
#include <sysalloc.h>
@@ -65,7 +68,6 @@ typedef struct KHttpFile KHttpFile;
#include "http-priv.h"
-
static
void KDataBufferClear ( KDataBuffer *buf )
{
@@ -81,88 +83,10 @@ bool KDataBufferContainsString ( const KDataBuffer *buf, const String *str )
}
/*--------------------------------------------------------------------------
- * KDataBufferVPrintf
- * Populate a KDataBuffer
- * If buffer is empty - resize it to 4k
- * Else determine the correct multiple of 4k and add/append data
- */
-
-#if 0
-/* TBD - add to the printf file permanently */
-static
-rc_t KDataBufferVPrintf ( KDataBuffer * buf, const char * fmt, va_list args )
-{
- rc_t rc;
- size_t bsize;
- char *buffer;
- size_t content;
- size_t num_writ;
-
- /* the C library ruins a va_list upon use
- in case we ever need to use it a second time,
- make a copy first */
- va_list args_copy;
- va_copy ( args_copy, args );
-
- /* begin to calculate content and bsize */
- content = ( size_t ) buf -> elem_count;
-
- /* check for an empty buffer */
- if ( content == 0 )
- {
- rc = KDataBufferResize ( buf, bsize = 4096 );
- if ( rc != 0 )
- return rc;
- }
- else
- {
- /* generate even multiple of 4K */
- bsize = ( content + 4095 ) & ~ ( size_t ) 4095;
-
- /* discount NUL byte */
- content -= 1;
- }
-
- /* convert the 2-part url into a flat string */
- buffer = buf -> base;
- rc = string_vprintf ( &buffer [ content ], bsize - content, & num_writ, fmt, args );
- /* Make sure there is enough room to store data including NUL */
- if ( rc != 0 || ( content + num_writ ) == bsize )
- {
- bsize = ( content + num_writ + 4095 + 1 ) & ~ ( size_t ) 4095;
- rc = KDataBufferResize ( buf, bsize );
- if ( rc == 0 )
- {
- /* try again with the newly sized buffer */
- rc = string_vprintf ( &buffer [ content ], bsize - content, & num_writ, fmt, args_copy );
- }
- }
- va_end ( args_copy );
-
- /* size down to bsize + NULL */
- if ( rc == 0 )
- KDataBufferResize ( buf, content + num_writ + 1 );
-
- return rc;
-}
-
-/* forward to KDataBufferVPrintf */
-static
-rc_t KDataBufferPrintf ( KDataBuffer * buf, const char * url, ... )
-{
- rc_t rc;
-
- va_list args;
- va_start ( args, url );
- rc = KDataBufferVPrintf ( buf, url, args );
- va_end ( args );
-
- return rc;
-}
-#endif
-/*--------------------------------------------------------------------------
* URLBlock
* RFC 3986
+ *
+ * TBD - replace with VPath
*/
/* Init
@@ -361,7 +285,7 @@ rc_t ParseUrl ( URLBlock * b, const char * url, size_t url_size )
if ( b -> port == 0 || ( const char* ) term != end )
{
rc = RC ( rcNS, rcUrl, rcParsing, rcNoObj, rcIncorrect );
- PLOGERR ( klogErr ,( klogErr, rc, "Port is '$(port)'", "port=%d", b -> port ) );
+ PLOGERR ( klogErr ,( klogErr, rc, "Port is '$(port)'", "port=%u", b -> port ) );
return rc;
}
@@ -415,10 +339,11 @@ struct KHttp
/* buffer for accumulating response data from "sock" */
KDataBuffer block_buffer;
- size_t block_valid; /* number of valid response bytes in buffer */
- size_t block_read; /* number of bytes read out by line reader or stream */
+ size_t block_valid; /* number of valid response bytes in buffer */
+ size_t block_read; /* number of bytes read out by line reader or stream */
+ size_t body_start; /* offset to first byte in body */
- KDataBuffer line_buffer; /* data accumulates for reading headers and chunk size */
+ KDataBuffer line_buffer; /* data accumulates for reading headers and chunk size */
size_t line_valid;
KDataBuffer hostname_buffer;
@@ -429,6 +354,9 @@ struct KHttp
KRefcount refcount;
+ int32_t read_timeout;
+ int32_t write_timeout;
+
KEndPoint ep;
bool ep_valid;
};
@@ -494,7 +422,8 @@ rc_t KHttpOpen ( KHttp * self, const String * hostname, uint32_t port )
self -> ep_valid = true;
}
- rc = KNSManagerMakeConnection ( self -> mgr, & self -> sock, NULL, & self -> ep );
+ /* TBD - retries? default for now */
+ rc = KNSManagerMakeTimedConnection ( self -> mgr, & self -> sock, self -> read_timeout, self -> write_timeout, NULL, & self -> ep );
if ( rc == 0 )
{
self -> port = port;
@@ -515,16 +444,17 @@ rc_t KHttpInit ( KHttp * http, const KDataBuffer *hostname_buffer, KStream * con
port = 80;
/* we accept a NULL connection ( from ) */
- if ( conn != NULL )
- rc = KStreamAddRef ( conn );
+ if ( conn == NULL )
+ rc = KHttpOpen ( http, _host, port );
else
{
- rc = KHttpOpen ( http, _host, port );
+ rc = KStreamAddRef ( conn );
+ if ( rc == 0 )
+ http -> sock = conn;
}
if ( rc == 0 )
{
- http -> sock = conn;
http -> port = port;
http -> vers = _vers & 0xFFFF0000; /* safety measure - limit to major.minor */
@@ -551,7 +481,7 @@ rc_t KHttpInit ( KHttp * http, const KDataBuffer *hostname_buffer, KStream * con
*
* "http" [ OUT ] - return parameter for HTTP object
*
- * "conn" [ IN ] - previously opened stream for communications.
+ * "opt_conn" [ IN ] - previously opened stream for communications.
*
* "vers" [ IN ] - http version
* the only legal types are 1.0 ( 0x01000000 ) and 1.1 ( 0x01010000 )
@@ -563,7 +493,9 @@ rc_t KHttpInit ( KHttp * http, const KDataBuffer *hostname_buffer, KStream * con
*/
static
rc_t KNSManagerMakeHttpInt ( const KNSManager *self, KHttp **_http,
- const KDataBuffer *hostname_buffer, KStream *conn, ver_t vers, const String *host, uint32_t port )
+ const KDataBuffer *hostname_buffer, KStream *opt_conn,
+ ver_t vers, int32_t readMillis, int32_t writeMillis,
+ const String *host, uint32_t port )
{
rc_t rc;
@@ -578,7 +510,8 @@ rc_t KNSManagerMakeHttpInt ( const KNSManager *self, KHttp **_http,
char save, *text;
http -> mgr = self;
-
+ http -> read_timeout = readMillis;
+ http -> write_timeout = writeMillis;
/* Dont use MakeBytes because we dont need to allocate memory
and we only need to know that the elem size is 8 bits */
@@ -600,7 +533,7 @@ rc_t KNSManagerMakeHttpInt ( const KNSManager *self, KHttp **_http,
text [ host -> size ] = save;
/* init the KHttp object */
- rc = KHttpInit ( http, hostname_buffer, conn, vers, host, port );
+ rc = KHttpInit ( http, hostname_buffer, opt_conn, vers, host, port );
if ( rc == 0 )
{
/* assign to OUT http param */
@@ -617,27 +550,28 @@ rc_t KNSManagerMakeHttpInt ( const KNSManager *self, KHttp **_http,
return rc;
}
-LIB_EXPORT rc_t CC KNSManagerMakeHttp ( const KNSManager *self,
- KHttp **_http, KStream *conn, ver_t vers, const String *host, uint32_t port )
+LIB_EXPORT rc_t CC KNSManagerMakeTimedHttp ( const KNSManager *self,
+ KHttp **_http, KStream *opt_conn, ver_t vers, int32_t readMillis, int32_t writeMillis,
+ const String *host, uint32_t port )
{
rc_t rc;
/* check return parameters */
if ( _http == NULL )
- rc = RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcNull );
+ rc = RC ( rcNS, rcMgr, rcConstructing, rcParam, rcNull );
else
{
/* check input parameters */
if ( self == NULL )
- rc = RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcNull );
+ rc = RC ( rcNS, rcMgr, rcConstructing, rcSelf, rcNull );
/* make sure we have one of the two versions supported - 1.0, 1.1 */
else if ( vers < 0x01000000 || vers > 0x01010000 )
- rc = RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcIncorrect );
+ rc = RC ( rcNS, rcMgr, rcConstructing, rcParam, rcBadVersion );
else if ( host == NULL )
- rc = RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcNull );
+ rc = RC ( rcNS, rcMgr, rcConstructing, rcPath, rcNull );
/* make sure there is data in the host name */
else if ( host -> size == 0 )
- rc = RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcInsufficient );
+ rc = RC ( rcNS, rcMgr, rcConstructing, rcPath, rcEmpty );
else
{
KDataBuffer hostname_buffer;
@@ -655,8 +589,19 @@ LIB_EXPORT rc_t CC KNSManagerMakeHttp ( const KNSManager *self,
/* create copy of host that points into new buffer */
StringInit ( &_host, hostname_buffer . base, host -> size, host -> len );
+ /* limit timeouts */
+ if ( readMillis < 0 )
+ readMillis = -1;
+ else if ( readMillis > MAX_HTTP_READ_LIMIT )
+ readMillis = MAX_HTTP_READ_LIMIT;
+ if ( writeMillis < 0 )
+ writeMillis = -1;
+ else if ( writeMillis > MAX_HTTP_WRITE_LIMIT )
+ writeMillis = MAX_HTTP_WRITE_LIMIT;
+
/* initialize http object - will create a new reference to hostname buffer */
- rc = KNSManagerMakeHttpInt ( self, _http, & hostname_buffer, conn, vers, &_host, port );
+ rc = KNSManagerMakeHttpInt ( self, _http, & hostname_buffer,
+ opt_conn, vers, readMillis, writeMillis, &_host, port );
/* release our reference to buffer */
KDataBufferWhack ( & hostname_buffer );
@@ -672,6 +617,23 @@ LIB_EXPORT rc_t CC KNSManagerMakeHttp ( const KNSManager *self,
return rc;
}
+LIB_EXPORT rc_t CC KNSManagerMakeHttp ( const KNSManager *self,
+ KHttp **http, KStream *opt_conn, ver_t vers, const String *host, uint32_t port )
+{
+ if ( self == NULL )
+ {
+ if ( http == NULL )
+ return RC ( rcNS, rcMgr, rcValidating, rcParam, rcNull );
+
+ * http = NULL;
+
+ return RC ( rcNS, rcMgr, rcValidating, rcSelf, rcNull );
+ }
+
+ return KNSManagerMakeTimedHttp ( self, http, opt_conn, vers,
+ self -> http_read_timeout, self -> http_write_timeout, host, port );
+}
+
/* AddRef
* Release
@@ -717,7 +679,7 @@ LIB_EXPORT rc_t CC KHttpRelease ( const KHttp *self )
* Read in the http response and return 1 char at a time
*/
static
-rc_t KHttpGetCharFromResponse ( KHttp *self, char *ch )
+rc_t KHttpGetCharFromResponse ( KHttp *self, char *ch, struct timeout_t *tm )
{
rc_t rc;
char * buffer = self -> block_buffer . base;
@@ -748,7 +710,7 @@ rc_t KHttpGetCharFromResponse ( KHttp *self, char *ch )
/* NB - do NOT use KStreamReadAll or it will block with http 1.1
because http/1.1 uses keep alive and the read will block until the server
drops the connection */
- rc = KStreamRead ( self -> sock, buffer, bsize, & self -> block_valid );
+ rc = KStreamTimedRead ( self -> sock, buffer, bsize, & self -> block_valid, tm );
if ( rc != 0 )
return rc;
@@ -768,7 +730,7 @@ rc_t KHttpGetCharFromResponse ( KHttp *self, char *ch )
/* Read and return entire lines ( until \r\n ) */
static
-rc_t KHttpGetLine ( KHttp *self )
+rc_t KHttpGetLine ( KHttp *self, struct timeout_t *tm )
{
rc_t rc;
@@ -782,7 +744,7 @@ rc_t KHttpGetLine ( KHttp *self )
char ch;
/* get char */
- rc = KHttpGetCharFromResponse ( self, &ch );
+ rc = KHttpGetCharFromResponse ( self, &ch, tm );
if ( rc != 0 )
break;
@@ -823,8 +785,19 @@ rc_t KHttpGetLine ( KHttp *self )
if ( ch == 0 )
{
#if _DEBUGGING
- if ( KNSManagerIsVerbose ( self->mgr ) )
- KOutMsg( "RX:%s\n", buffer );
+ if ( KNSManagerIsVerbose ( self -> mgr ) ) {
+ size_t i = 0;
+ KOutMsg ( "RX:" );
+ for (i = 0; i <= self->line_valid; ++i) {
+ if (isprint(buffer[i])) {
+ KOutMsg("%c", buffer[i]);
+ }
+ else {
+ KOutMsg("\\%02X", buffer[i]);
+ }
+ }
+ KOutMsg ( "\n" );
+ }
#endif
break;
}
@@ -964,10 +937,10 @@ rc_t KHttpAddHeader ( BSTree *hdrs, const char *name, const char *val, ... )
}
/* Capture each header line to add to BSTree */
-rc_t KHttpGetHeaderLine ( KHttp *self, BSTree *hdrs, bool *blank, bool *close_connection )
+rc_t KHttpGetHeaderLine ( KHttp *self, timeout_t *tm, BSTree *hdrs, bool *blank, bool *close_connection )
{
/* Starting from the second line of the response */
- rc_t rc = KHttpGetLine ( self );
+ rc_t rc = KHttpGetLine ( self, tm );
if ( rc == 0 )
{
/* blank = empty line_buffer = separation between headers and body of response */
@@ -1066,10 +1039,18 @@ rc_t KHttpFindHeader ( const BSTree *hdrs, const char *_name, char *buffer, size
return rc;
}
-rc_t KHttpGetStatusLine ( KHttp *self, String *msg, uint32_t *status, ver_t *version )
+rc_t KHttpGetStatusLine ( KHttp *self, timeout_t *tm, String *msg, uint32_t *status, ver_t *version )
{
/* First time reading the response */
- rc_t rc = KHttpGetLine ( self );
+ rc_t rc = KHttpGetLine ( self, tm );
+
+ if (rc == 0 && self->line_valid == 0) {
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@2 %s empty HttpStatusLine @@@@@@@@@@@@@@@@"
+ "\n", __FILE__));
+ rc = RC(rcNS, rcNoTarg, rcReading, rcNoObj, rcIncomplete);
+ }
+
if ( rc == 0 )
{
char * sep;
@@ -1105,7 +1086,7 @@ rc_t KHttpGetStatusLine ( KHttp *self, String *msg, uint32_t *status, ver_t *ver
rc = RC ( rcNS, rcNoTarg, rcParsing, rcNoObj, rcUnsupported );
else
{
- /* which one? */
+ /* which version was returned? */
* version = string_cmp ( "1.0", 3, buffer, sep - buffer, -1 ) == 0 ? 0x01000000 : 0x01010000;
/* move up to status code */
@@ -1172,8 +1153,8 @@ rc_t CC KHttpStreamWhack ( KHttpStream *self )
/* Read from stream - not chunked or within a chunk */
static
-rc_t CC KHttpStreamRead ( const KHttpStream *cself,
- void *buffer, size_t bsize, size_t *num_read )
+rc_t CC KHttpStreamTimedRead ( const KHttpStream *cself,
+ void *buffer, size_t bsize, size_t *num_read, struct timeout_t *tm )
{
rc_t rc;
KHttpStream *self = ( KHttpStream * ) cself;
@@ -1198,7 +1179,7 @@ rc_t CC KHttpStreamRead ( const KHttpStream *cself,
if ( KHttpBlockBufferIsEmpty ( http ) )
{
/* ReadAll blocks for 1.1. Server will drop the connection */
- rc = KStreamRead ( http -> sock, buffer, num_to_read, num_read );
+ rc = KStreamTimedRead ( http -> sock, buffer, num_to_read, num_read, tm );
if ( rc != 0 )
{
/* TBD - handle dropped connection - may want to reestablish */
@@ -1248,11 +1229,18 @@ rc_t CC KHttpStreamRead ( const KHttpStream *cself,
return rc;
}
-/* Uses a state machine*/
static
-rc_t CC KHttpStreamReadChunked ( const KHttpStream *cself,
+rc_t CC KHttpStreamRead ( const KHttpStream *self,
void *buffer, size_t bsize, size_t *num_read )
{
+ return KHttpStreamTimedRead ( self, buffer, bsize, num_read, NULL );
+}
+
+/* Uses a state machine*/
+static
+rc_t CC KHttpStreamTimedReadChunked ( const KHttpStream *cself,
+ void *buffer, size_t bsize, size_t *num_read, timeout_t *tm )
+{
rc_t rc;
char * sep;
KHttpStream *self = ( KHttpStream * ) cself;
@@ -1263,7 +1251,7 @@ rc_t CC KHttpStreamReadChunked ( const KHttpStream *cself,
switch ( self -> state )
{
case end_chunk:
- rc = KHttpGetLine ( http );
+ rc = KHttpGetLine ( http, tm );
/* this should be the CRLF following chunk */
if ( rc != 0 || http -> line_valid != 0 )
{
@@ -1280,7 +1268,7 @@ rc_t CC KHttpStreamReadChunked ( const KHttpStream *cself,
case new_chunk:
/* Get chunk size */
- rc = KHttpGetLine ( http );
+ rc = KHttpGetLine ( http, tm );
if ( rc != 0 )
{
self -> state = error_state;
@@ -1346,28 +1334,46 @@ rc_t CC KHttpStreamReadChunked ( const KHttpStream *cself,
return rc;
}
+static
+rc_t CC KHttpStreamReadChunked ( const KHttpStream *self,
+ void *buffer, size_t bsize, size_t *num_read )
+{
+ return KHttpStreamTimedReadChunked ( self, buffer, bsize, num_read, NULL );
+}
+
/* cannot write - for now */
static
+rc_t CC KHttpStreamTimedWrite ( KHttpStream *self,
+ const void *buffer, size_t size, size_t *num_writ, struct timeout_t *tm )
+{
+ return RC ( rcNS, rcNoTarg, rcWriting, rcFunction, rcUnsupported );
+}
+
+static
rc_t CC KHttpStreamWrite ( KHttpStream *self,
const void *buffer, size_t size, size_t *num_writ )
{
- return RC ( rcNS, rcNoTarg, rcWriting, rcNoObj, rcError );
+ return RC ( rcNS, rcNoTarg, rcWriting, rcFunction, rcUnsupported );
}
static KStream_vt_v1 vtKHttpStream =
{
- 1, 0,
+ 1, 1,
KHttpStreamWhack,
KHttpStreamRead,
- KHttpStreamWrite
+ KHttpStreamWrite,
+ KHttpStreamTimedRead,
+ KHttpStreamTimedWrite
};
static KStream_vt_v1 vtKHttpStreamChunked =
{
- 1, 0,
+ 1, 1,
KHttpStreamWhack,
KHttpStreamReadChunked,
- KHttpStreamWrite
+ KHttpStreamWrite,
+ KHttpStreamTimedReadChunked,
+ KHttpStreamTimedWrite
};
/* Make a KHttpStream object */
@@ -1476,14 +1482,15 @@ rc_t KHttpSendReceiveMsg ( KHttp *self, KHttpResult **rslt,
const char *buffer, size_t len, const KDataBuffer *body, const char *url )
{
rc_t rc = 0;
-
size_t sent;
+ timeout_t tm;
/* TBD - may want to assert that there is an empty line in "buffer" */
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_HTTP), ("TX:%.*s", len, buffer));
#if _DEBUGGING
- if ( KNSManagerIsVerbose ( self->mgr ) )
- KOutMsg( "TX:%.*s", len, buffer );
+ if ( KNSManagerIsVerbose ( self -> mgr ) )
+ KOutMsg ( "TX:%.*s", len, buffer );
#endif
/* reopen connection if NULL */
@@ -1492,7 +1499,10 @@ rc_t KHttpSendReceiveMsg ( KHttp *self, KHttpResult **rslt,
/* ALWAYS want to use write all when sending */
if ( rc == 0 )
- rc = KStreamWriteAll ( self -> sock, buffer, len, & sent );
+ {
+ TimeoutInit ( & tm, self -> write_timeout );
+ rc = KStreamTimedWriteAll ( self -> sock, buffer, len, & sent, & tm );
+ }
/* check the data was completely sent */
if ( rc == 0 && sent != len )
@@ -1501,7 +1511,7 @@ rc_t KHttpSendReceiveMsg ( KHttp *self, KHttpResult **rslt,
{
/* "body" contains bytes plus trailing NUL */
size_t to_send = ( size_t ) body -> elem_count - 1;
- rc = KStreamWriteAll ( self -> sock, body -> base, to_send, & sent );
+ rc = KStreamTimedWriteAll ( self -> sock, body -> base, to_send, & sent, & tm );
if ( rc == 0 && sent != to_send )
rc = RC ( rcNS, rcNoTarg, rcWriting, rcTransfer, rcIncomplete );
}
@@ -1511,9 +1521,12 @@ rc_t KHttpSendReceiveMsg ( KHttp *self, KHttpResult **rslt,
ver_t version;
uint32_t status;
+ /* reinitialize the timeout for reading */
+ TimeoutInit ( & tm, self -> read_timeout );
+
/* we have now received a response
start reading the header lines */
- rc = KHttpGetStatusLine ( self, & msg, & status, & version );
+ rc = KHttpGetStatusLine ( self, & tm, & msg, & status, & version );
if ( rc == 0 )
{
/* create a result object with enough space for msg string + nul */
@@ -1552,7 +1565,7 @@ rc_t KHttpSendReceiveMsg ( KHttp *self, KHttpResult **rslt,
/* receive and parse all header lines
blank = end of headers */
for ( blank = false; ! blank && rc == 0; )
- rc = KHttpGetHeaderLine ( self, & result -> hdrs, & blank, & result -> close_connection );
+ rc = KHttpGetHeaderLine ( self, & tm, & result -> hdrs, & blank, & result -> close_connection );
if ( rc == 0 )
{
@@ -2033,11 +2046,12 @@ LIB_EXPORT rc_t CC KHttpResultGetInputStream ( KHttpResult *self, KStream ** s )
if ( KHttpResultSize ( self, & content_length ) )
return KHttpStreamMake ( self -> http, s, "KHttpStream", content_length, false );
- /* detect pre-HTTP/1.1 dynamic content */
- if ( self -> version < 0x01010000 )
+ /* detect connection: close or pre-HTTP/1.1 dynamic content */
+ if ( self -> close_connection || self -> version < 0x01010000 )
return KHttpStreamMake ( self -> http, s, "KHttpStream", 0, true );
#if _DEBUGGING
+ KOutMsg ( "HTTP/%.2V %03u %S\n", self -> version, self -> status, & self -> msg );
BSTreeForEach ( & self -> hdrs, false, PrintHeaders, NULL );
#endif
@@ -2276,7 +2290,8 @@ LIB_EXPORT rc_t CC KNSManagerMakeRequest ( const KNSManager *self,
{
KHttp * http;
- rc = KNSManagerMakeHttpInt ( self, & http, & buf, conn, vers, & block . host, block . port );
+ rc = KNSManagerMakeHttpInt ( self, & http, & buf, conn, vers,
+ self -> http_read_timeout, self -> http_write_timeout, & block . host, block . port );
if ( rc == 0 )
{
rc = KHttpMakeRequestInt ( http, req, & block, & buf );
@@ -2388,7 +2403,7 @@ LIB_EXPORT rc_t CC KHttpRequestByteRange ( KHttpRequest *self, uint64_t pos, siz
String name, value;
CONST_STRING ( & name, "Range" );
- rc = string_printf ( range, sizeof range, & num_writ, "bytes=%u-%u"
+ rc = string_printf ( range, sizeof range, & num_writ, "bytes=%lu-%lu"
, pos
, pos + bytes - 1);
if ( rc == 0 )
@@ -2847,7 +2862,7 @@ struct KHttpFile
};
static
-rc_t KHttpFileDestroy ( KHttpFile *self )
+rc_t CC KHttpFileDestroy ( KHttpFile *self )
{
KHttpRelease ( self -> http );
KDataBufferWhack ( & self -> url_buffer );
@@ -2857,36 +2872,38 @@ rc_t KHttpFileDestroy ( KHttpFile *self )
}
static
-struct KSysFile* KHttpFileGetSysFile ( const KHttpFile *self, uint64_t *offset )
+struct KSysFile* CC KHttpFileGetSysFile ( const KHttpFile *self, uint64_t *offset )
{
*offset = 0;
return NULL;
}
static
-rc_t KHttpFileRandomAccess ( const KHttpFile *self )
+rc_t CC KHttpFileRandomAccess ( const KHttpFile *self )
{
+ /* TBD - not all HTTP servers will support this
+ detect if the server does not, and alter the vTable */
return 0;
}
/* KHttpFile must have a file size to be created
impossible for this funciton to fail */
static
-rc_t KHttpFileSize ( const KHttpFile *self, uint64_t *size )
+rc_t CC KHttpFileSize ( const KHttpFile *self, uint64_t *size )
{
*size = self -> file_size;
return 0;
}
static
-rc_t KHttpFileSetSize ( KHttpFile *self, uint64_t size )
+rc_t CC KHttpFileSetSize ( KHttpFile *self, uint64_t size )
{
return RC ( rcNS, rcFile, rcUpdating, rcFile, rcReadonly );
}
static
-rc_t KHttpFileRead ( const KHttpFile *cself, uint64_t pos,
- void *buffer, size_t bsize, size_t *num_read )
+rc_t CC KHttpFileTimedRead ( const KHttpFile *cself, uint64_t pos,
+ void *buffer, size_t bsize, size_t *num_read, struct timeout_t *tm )
{
rc_t rc;
KHttpFile *self = ( KHttpFile * ) cself;
@@ -2898,17 +2915,26 @@ rc_t KHttpFileRead ( const KHttpFile *cself, uint64_t pos,
*num_read = 0;
return 0;
}
+#if 0
+ /* position is within http header buffer */
+ else if ( KHttpBlockBufferContainsPos ( http, pos ) )
+ {
+
+ }
+#endif
/* starting position was within file but the range fell beyond EOF */
else
{
KHttpRequest *req;
+ /* limit request to file size */
if ( pos + bsize > self -> file_size )
bsize = self -> file_size - pos;
rc = KHttpMakeRequest ( http, &req, self -> url_buffer . base );
if ( rc == 0 )
{
+ /* request min ( bsize, file_size ) bytes */
rc = KHttpRequestByteRange ( req, pos, bsize );
if ( rc == 0 )
{
@@ -2930,6 +2956,7 @@ rc_t KHttpFileRead ( const KHttpFile *cself, uint64_t pos,
uint64_t start_pos;
size_t result_size;
+ /* extract actual amount being returned by server */
rc = KHttpResultRange ( rslt, &start_pos, &result_size );
if ( rc == 0 &&
start_pos == pos &&
@@ -2940,10 +2967,15 @@ rc_t KHttpFileRead ( const KHttpFile *cself, uint64_t pos,
rc = KHttpResultGetInputStream ( rslt, &response );
if ( rc == 0 )
{
- rc = KStreamReadAll ( response, buffer, bsize, num_read );
- if ( rc != 0 || num_read == 0 )
- return rc;
-
+ rc = KStreamTimedReadExactly ( response, buffer, result_size, tm );
+ if ( rc != 0 )
+ {
+ KHttpClose ( http );
+ return ResetRCContext ( rc, rcNS, rcFile, rcReading );
+ }
+
+ * num_read = result_size;
+
KStreamRelease ( response );
}
}
@@ -2965,15 +2997,41 @@ rc_t KHttpFileRead ( const KHttpFile *cself, uint64_t pos,
}
static
-rc_t KHttpFileWrite ( KHttpFile *self, uint64_t pos,
- const void *buffer, size_t size, size_t *num_writ )
+rc_t CC KHttpFileRead ( const KHttpFile *self, uint64_t pos,
+ void *buffer, size_t bsize, size_t *num_read )
+{
+ return KHttpFileTimedRead ( self, pos, buffer, bsize, num_read, NULL );
+}
+
+static
+rc_t CC KHttpFileWrite ( KHttpFile *self, uint64_t pos,
+ const void *buffer, size_t size, size_t *num_writ )
+{
+ return RC ( rcNS, rcFile, rcUpdating, rcInterface, rcUnsupported );
+}
+
+static
+rc_t CC KHttpFileTimedWrite ( KHttpFile *self, uint64_t pos,
+ const void *buffer, size_t size, size_t *num_writ, struct timeout_t *tm )
{
return RC ( rcNS, rcFile, rcUpdating, rcInterface, rcUnsupported );
}
+static
+uint32_t CC KHttpFileGetType ( const KHttpFile *self )
+{
+ assert ( self != NULL );
+
+ /* the HTTP file behaves like a read-only file
+ returning kfdSocket would be imply absence of
+ random access: the HTTP protocol adds that. */
+
+ return kfdFile;
+}
+
static KFile_vt_v1 vtKHttpFile =
{
- 1, 0,
+ 1, 2,
KHttpFileDestroy,
KHttpFileGetSysFile,
@@ -2981,10 +3039,14 @@ static KFile_vt_v1 vtKHttpFile =
KHttpFileSize,
KHttpFileSetSize,
KHttpFileRead,
- KHttpFileWrite
+ KHttpFileWrite,
+ KHttpFileGetType,
+ KHttpFileTimedRead,
+ KHttpFileTimedWrite
};
-LIB_EXPORT rc_t CC KNSManagerVMakeHttpFile ( const KNSManager *self,
+/* LIB_EXPORT */
+rc_t SecretKNSManagerVMakeHttpFile ( const KNSManager *self,
const KFile **file, KStream *conn, ver_t vers, const char *url, va_list args )
{
rc_t rc;
@@ -3022,7 +3084,8 @@ LIB_EXPORT rc_t CC KNSManagerVMakeHttpFile ( const KNSManager *self,
{
KHttp *http;
- rc = KNSManagerMakeHttpInt ( self, &http, buf, conn, vers, &block . host, block . port );
+ rc = KNSManagerMakeHttpInt ( self, & http, buf, conn, vers,
+ self -> http_read_timeout, self -> http_write_timeout, &block . host, block . port );
if ( rc == 0 )
{
KHttpRequest *req;
@@ -3072,16 +3135,24 @@ LIB_EXPORT rc_t CC KNSManagerVMakeHttpFile ( const KNSManager *self,
return rc;
}
-LIB_EXPORT rc_t CC KNSManagerMakeHttpFile ( const KNSManager *self,
- const KFile **file, KStream *conn, ver_t vers, const char *url, ... )
+LIB_EXPORT rc_t CC KNSManagerMakeHttpFile(const KNSManager *self,
+ const KFile **file, struct KStream *conn, ver_t vers, const char *url, ...)
{
- rc_t rc;
-
+ rc_t rc = 0;
va_list args;
- va_start ( args, url );
- rc = KNSManagerVMakeHttpFile ( self, file, conn, vers, url, args );
- va_end ( args );
-
+ va_start(args, url);
+ rc = KNSManagerVMakeHttpFile(self, file, conn, vers, url, args);
+ va_end(args);
return rc;
}
+rc_t SecretKNSManagerMakeHttpFile(const KNSManager *self,
+ const KFile **file, struct KStream *conn, ver_t vers, const char *url, ...)
+{
+ rc_t rc = 0;
+ va_list args;
+ va_start(args, url);
+ rc = SecretKNSManagerVMakeHttpFile(self, file, conn, vers, url, args);
+ va_end(args);
+ return rc;
+}
diff --git a/libs/kns/kns_manager-ext.c b/libs/kns/kns_manager-ext.c
index cba8cb8..83ac39c 100644
--- a/libs/kns/kns_manager-ext.c
+++ b/libs/kns/kns_manager-ext.c
@@ -46,7 +46,7 @@
#define RELEASE(type, obj) do { rc_t rc2 = type##Release(obj); \
if (rc2 != 0 && rc == 0) { rc = rc2; } obj = NULL; } while (false)
-LIB_EXPORT rc_t CC KNSManagerNewReleaseVersion(const struct KNSManager *self,
+static rc_t CC KNSManagerNewReleaseVersionImpl(const struct KNSManager *self,
SraReleaseVersion *newVersion)
{
rc_t rc = 0;
@@ -62,7 +62,7 @@ LIB_EXPORT rc_t CC KNSManagerNewReleaseVersion(const struct KNSManager *self,
}
memset(&result, 0, sizeof result);
if (rc == 0) {
- rc = KNSManagerMakeRequest(self, &req, 0x01000000, NULL,
+ rc = KNSManagerMakeRequest(self, &req, 0x01010000, NULL,
"http://ftp-trace.ncbi.nlm.nih.gov/sra/sdk/current/sratoolkit.current.version"
);
}
@@ -138,3 +138,20 @@ LIB_EXPORT rc_t CC KNSManagerNewReleaseVersion(const struct KNSManager *self,
return rc;
}
+
+LIB_EXPORT rc_t CC KNSManagerNewReleaseVersion(const struct KNSManager *self,
+ SraReleaseVersion *newVersion)
+{
+ rc_t rc = 0;
+ int i = 0, retryOnFailure = 2;
+ for (i = 0; i < retryOnFailure; ++i) {
+ rc = KNSManagerNewReleaseVersionImpl(self, newVersion);
+ if (rc == 0) {
+ break;
+ }
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+ "@@@@@@@@2: KNSManagerNewReleaseVersion %d/%d = %R"
+ "\n", i + 1, retryOnFailure, rc));
+ }
+ return rc;
+}
diff --git a/libs/kns/kns_manager.c b/libs/kns/kns_manager.c
index 31ce2f0..944a85c 100644
--- a/libs/kns/kns_manager.c
+++ b/libs/kns/kns_manager.c
@@ -226,6 +226,7 @@ LIB_EXPORT rc_t CC KNSManagerMake( struct KNSManager **self )
*self = kns_mgr_singleton;
if ( kns_mgr_singleton != NULL )
{
+/* fprintf(stderr, "%p KNSManagerMake(KNSManagerAddRef)\n", *self); */
rc = KNSManagerAddRef( kns_mgr_singleton );
if ( rc != 0 )
*self = NULL;
@@ -248,6 +249,8 @@ LIB_EXPORT rc_t CC KNSManagerMake( struct KNSManager **self )
{
tmp->create_rc = KNSManagerLoadLib( tmp );
KRefcountInit( &tmp->refcount, 1, "KNS", "make", knsmanager_classname );
+/* fprintf(stderr,
+ "%p KNSManagerLoadLib = %d\n", tmp, tmp->create_rc); */
}
}
*self = tmp;
@@ -300,6 +303,8 @@ static rc_t KNSManagerDestroy( struct KNSManager *self )
if ( self == NULL )
return RC( rcNS, rcFile, rcDestroying, rcSelf, rcNull );
+/* fprintf(stderr, "%p KNSManagerDestroy\n", self); */
+
KDylibRelease ( lib_curl_handle );
lib_curl_handle = NULL;
@@ -307,6 +312,7 @@ static rc_t KNSManagerDestroy( struct KNSManager *self )
KRefcountWhack( &self->refcount, knsmanager_classname );
+ memset(self, 0, sizeof *self);
free( self );
kns_mgr_singleton = NULL;
@@ -323,6 +329,7 @@ LIB_EXPORT rc_t CC KNSManagerRelease( const struct KNSManager *self )
{
case krefOkay:
case krefZero:
+/* fprintf(stderr, "%p KNSManagerRelease(!KNSManagerDestroy)\n", self);*/
break;
case krefWhack:
rc = KNSManagerDestroy( ( struct KNSManager * )self );
diff --git a/libs/kns/kns_mgr_priv.h b/libs/kns/kns_mgr_priv.h
deleted file mode 100644
index 4d4adc2..0000000
--- a/libs/kns/kns_mgr_priv.h
+++ /dev/null
@@ -1,71 +0,0 @@
-/*===========================================================================
-*
-* PUBLIC DOMAIN NOTICE
-* National Center for Biotechnology Information
-*
-* This software/database is a "United States Government Work" under the
-* terms of the United States Copyright Act. It was written as part of
-* the author's official duties as a United States Government employee and
-* thus cannot be copyrighted. This software/database is freely available
-* to the public for use. The National Library of Medicine and the U.S.
-* Government have not placed any restriction on its use or reproduction.
-*
-* Although all reasonable efforts have been taken to ensure the accuracy
-* and reliability of the software and data, the NLM and the U.S.
-* Government do not and cannot warrant the performance or results that
-* may be obtained by using this software or data. The NLM and the U.S.
-* Government disclaim all warranties, express or implied, including
-* warranties of performance, merchantability or fitness for any particular
-* purpose.
-*
-* Please cite the author in any work or product based on this material.
-*
-* ===========================================================================
-*
-*/
-#ifndef _h_kns_mgr_priv_
-#define _h_kns_mgr_priv_
-
-#ifndef _h_klib_refcount_
-#include <klib/refcount.h>
-#endif
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include <klib/rc.h>
-
-#include "curlhdr/curl.h"
-#include "curlhdr/easy.h"
-
-/* this is the hidden manager-struct: a refcount with some function-pointer's */
-struct KNSManager
-{
- KRefcount refcount;
-
- rc_t create_rc;
-
- /* curl-easy-function-pointers... */
- CURL* ( CC * curl_easy_init_fkt ) ( void );
- void ( CC * curl_easy_cleanup_fkt ) ( CURL * handle );
- CURLcode ( CC * curl_easy_setopt_fkt ) ( CURL *handle, CURLoption option, ... );
- CURLcode ( CC * curl_easy_perform_fkt ) ( CURL * handle );
- CURLcode ( CC * curl_easy_getinfo_fkt ) ( CURL *curl, CURLINFO info, ... );
- char * ( CC * curl_version_fkt ) ( void );
- struct curl_slist* ( CC * curl_slist_append_fkt ) ( struct curl_slist * list, const char * string );
- void ( CC * curl_slist_free_all_fkt ) ( struct curl_slist * list );
-
- bool verbose;
-};
-
-
-rc_t KNSManagerInit ( struct KNSManager *self ); /* in kns/unix/sysmgr.c or kns/win/sysmgr.c */
-void KNSManagerCleanup ( struct KNSManager *self );
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
diff --git a/libs/kns/unix/sysendpoint.c b/libs/kns/linux/sysendpoint.c
similarity index 85%
copy from libs/kns/unix/sysendpoint.c
copy to libs/kns/linux/sysendpoint.c
index 456f336..c1daba0 100644
--- a/libs/kns/unix/sysendpoint.c
+++ b/libs/kns/linux/sysendpoint.c
@@ -38,6 +38,8 @@
#include <arpa/inet.h>
#include <assert.h>
+#include <errno.h> /* ERANGE definition */
+
#include <sysalloc.h>
extern int h_errno;
@@ -95,15 +97,28 @@ rc_t CC KNSManagerInitDNSEndpoint ( struct KNSManager const *self,
if ( rc == 0 )
{
- struct hostent *remote = gethostbyname ( hostname );
- if ( remote != NULL )
+ char BB [ 1024 ];
+ struct hostent ret;
+ struct hostent * remote = NULL;
+ int h_errnop = 0;
+ int ghbnr = 0;
+
+ ghbnr = gethostbyname_r (
+ hostname,
+ & ret,
+ BB,
+ sizeof ( BB ),
+ & remote,
+ & h_errnop
+ );
+ if ( ghbnr == 0 && remote != NULL )
{
ep -> type = epIPV4;
memcpy ( & ep -> u . ipv4 . addr, remote -> h_addr_list [ 0 ], sizeof ep -> u . ipv4 . addr );
ep -> u . ipv4 . addr = htonl ( ep -> u . ipv4 . addr );
ep -> u . ipv4 . port = ( uint16_t ) port;
}
- else switch ( h_errno )
+ else switch ( h_errnop )
{
case HOST_NOT_FOUND: /* The specified host is unknown */
rc = RC ( rcNS, rcNoTarg, rcValidating, rcConnection, rcNotFound );
@@ -122,6 +137,9 @@ rc_t CC KNSManagerInitDNSEndpoint ( struct KNSManager const *self,
case TRY_AGAIN: /* A temporary error occured on an authoritative name server. Try again later */
rc = RC ( rcNS, rcNoTarg, rcValidating, rcConnection, rcBusy );
break;
+ case ERANGE:
+ rc = RC ( rcNS, rcNoTarg, rcValidating, rcConnection, rcExhausted );
+ break;
default :
rc = RC ( rcNS, rcNoTarg, rcValidating, rcConnection, rcError );
}
diff --git a/libs/kns/linux/syspoll.c b/libs/kns/linux/syspoll.c
new file mode 100644
index 0000000..6e3014f
--- /dev/null
+++ b/libs/kns/linux/syspoll.c
@@ -0,0 +1,107 @@
+/*===========================================================================
+*
+* PUBLIC DOMAIN NOTICE
+* National Center for Biotechnology Information
+*
+* This software/database is a "United States Government Work" under the
+* terms of the United States Copyright Act. It was written as part of
+* the author's official duties as a United States Government employee and
+* thus cannot be copyrighted. This software/database is freely available
+* to the public for use. The National Library of Medicine and the U.S.
+* Government have not placed any restriction on its use or reproduction.
+*
+* Although all reasonable efforts have been taken to ensure the accuracy
+* and reliability of the software and data, the NLM and the U.S.
+* Government do not and cannot warrant the performance or results that
+* may be obtained by using this software or data. The NLM and the U.S.
+* Government disclaim all warranties, express or implied, including
+* warranties of performance, merchantability or fitness for any particular
+* purpose.
+*
+* Please cite the author in any work or product based on this material.
+*
+* ===========================================================================
+*
+*/
+
+
+#include <kns/extern.h>
+#include <klib/log.h>
+#include <klib/out.h>
+#include <kproc/timeout.h>
+#include <os-native.h>
+
+#include "poll-priv.h"
+
+#include <stdlib.h>
+#include <assert.h>
+#include <string.h>
+
+#include <os-native.h>
+
+#include <poll.h>
+#include <unistd.h>
+#include <errno.h>
+
+
+/* socket_wait
+ * wait for an event or a timeout
+ */
+int socket_wait ( int fd, int events, timeout_t *tm )
+{
+ int i, status;
+ struct pollfd fds [ 1 ];
+
+ /* poll for data with no delay */
+ for ( i = 0; i < 2; ++ i )
+ {
+ fds [ 0 ] . fd = fd;
+ fds [ 0 ] . events = events;
+ fds [ 0 ] . revents = 0;
+
+ status = poll ( fds, sizeof fds / sizeof fds [ 0 ], 0 );
+ if ( status > 0 )
+ return fds [ 0 ] . revents;
+ if ( status < 0 )
+ return -1;
+ }
+
+ /* test for infinite timeout */
+ while ( tm == NULL )
+ {
+ status = poll ( fds, sizeof fds / sizeof fds [ 0 ], 1000 );
+ if ( status > 0 )
+ return fds [ 0 ] . revents;
+ if ( status < 0 )
+ return -1;
+
+ /* TBD - check for quitting event
+ this may want to be a callback on the manager
+ or on the socket */
+ }
+
+ /* no blocking */
+ if ( tm -> mS == 0 )
+ return 0;
+
+#if PPOLL_USED_A_PROPER_TIMEOUT_INSTEAD_OF_BEING_CLOWNS
+
+ /* convert to absolute time */
+ if ( ! tm -> prepared )
+ TimeoutPrepare ( tm );
+
+ /* wait until final guy */
+ status = ppoll ( fds, sizeof fds / sizeof fds [ 0 ], & tm -> ts, NULL );
+
+#elif WHY_BOTHER_WITH_PPOLL_WHEN_POLL_TAKES_A_RELATIVE_TIMEOUT_ALREADY || 1
+
+ /* wait until final guy */
+ status = poll ( fds, sizeof fds / sizeof fds [ 0 ], tm -> mS );
+
+#endif
+
+ if ( status > 0 )
+ return fds [ 0 ] . revents;
+
+ return status;
+}
diff --git a/libs/kns/unix/sysendpoint.c b/libs/kns/mac/sysendpoint.c
similarity index 100%
rename from libs/kns/unix/sysendpoint.c
rename to libs/kns/mac/sysendpoint.c
diff --git a/libs/kns/mac/syspoll.c b/libs/kns/mac/syspoll.c
new file mode 100644
index 0000000..4c41f48
--- /dev/null
+++ b/libs/kns/mac/syspoll.c
@@ -0,0 +1,96 @@
+/*===========================================================================
+*
+* PUBLIC DOMAIN NOTICE
+* National Center for Biotechnology Information
+*
+* This software/database is a "United States Government Work" under the
+* terms of the United States Copyright Act. It was written as part of
+* the author's official duties as a United States Government employee and
+* thus cannot be copyrighted. This software/database is freely available
+* to the public for use. The National Library of Medicine and the U.S.
+* Government have not placed any restriction on its use or reproduction.
+*
+* Although all reasonable efforts have been taken to ensure the accuracy
+* and reliability of the software and data, the NLM and the U.S.
+* Government do not and cannot warrant the performance or results that
+* may be obtained by using this software or data. The NLM and the U.S.
+* Government disclaim all warranties, express or implied, including
+* warranties of performance, merchantability or fitness for any particular
+* purpose.
+*
+* Please cite the author in any work or product based on this material.
+*
+* ===========================================================================
+*
+*/
+
+
+#include <kns/extern.h>
+#include <klib/log.h>
+#include <klib/out.h>
+#include <kproc/timeout.h>
+
+#include "poll-priv.h"
+
+#include <stdlib.h>
+#include <assert.h>
+#include <string.h>
+
+#include <os-native.h>
+
+#include <poll.h>
+#include <unistd.h>
+#include <errno.h>
+
+
+/* socket_wait
+ * wait for an event or a timeout
+ */
+int socket_wait ( int fd, int events, timeout_t *tm )
+{
+ int i, status;
+ struct pollfd fds [ 1 ];
+
+ /* poll for data with no delay */
+ for ( i = 0; i < 2; ++ i )
+ {
+ fds [ 0 ] . fd = fd;
+ fds [ 0 ] . events = events;
+ fds [ 0 ] . revents = 0;
+
+ status = poll ( fds, sizeof fds / sizeof fds [ 0 ], 0 );
+ if ( status > 0 )
+ return fds [ 0 ] . revents;
+ if ( status < 0 )
+ return -1;
+ }
+
+ /* test for infinite timeout */
+ while ( tm == NULL )
+ {
+ status = poll ( fds, sizeof fds / sizeof fds [ 0 ], 1000 );
+ if ( status > 0 )
+ return fds [ 0 ] . revents;
+ if ( status < 0 )
+ return -1;
+
+ /* TBD - check for quitting event
+ this may want to be a callback on the manager
+ or on the socket */
+ }
+
+ /* no blocking */
+ if ( tm -> mS == 0 )
+ return 0;
+
+ /* Darwin doesn't appear to support ppoll,
+ so we just wait for the specified mS,
+ regardless of how long we may have waited before */
+
+ /* wait until final guy */
+ status = poll ( fds, sizeof fds / sizeof fds [ 0 ], tm -> mS );
+ if ( status > 0 )
+ return fds [ 0 ] . revents;
+
+ return status;
+}
diff --git a/libs/kns/manager.c b/libs/kns/manager.c
new file mode 100644
index 0000000..821ee61
--- /dev/null
+++ b/libs/kns/manager.c
@@ -0,0 +1,307 @@
+/*===========================================================================
+*
+* PUBLIC DOMAIN NOTICE
+* National Center for Biotechnology Information
+*
+* This software/database is a "United States Government Work" under the
+* terms of the United States Copyright Act. It was written as part of
+* the author's official duties as a United States Government employee and
+* thus cannot be copyrighted. This software/database is freely available
+* to the public for use. The National Library of Medicine and the U.S.
+* Government have not placed any restriction on its use or reproduction.
+*
+* Although all reasonable efforts have been taken to ensure the accuracy
+* and reliability of the software and data, the NLM and the U.S.
+* Government do not and cannot warrant the performance or results that
+* may be obtained by using this software or data. The NLM and the U.S.
+* Government disclaim all warranties, express or implied, including
+* warranties of performance, merchantability or fitness for any particular
+* purpose.
+*
+* Please cite the author in any work or product based on this material.
+*
+* ===========================================================================
+*
+*/
+
+#include <kns/extern.h>
+
+#include <kns/manager.h>
+#include <kns/socket.h>
+#include <klib/refcount.h>
+#include <klib/rc.h>
+
+#include "mgr-priv.h"
+#include "http-priv.h"
+#include "stream-priv.h"
+#include "sysmgr.h"
+
+#include <stdlib.h>
+#include <string.h>
+#include <assert.h>
+
+#include <sysalloc.h>
+
+#ifndef MAX_CONN_LIMIT
+#define MAX_CONN_LIMIT ( 10 * 60 )
+#endif
+
+#ifndef MAX_CONN_READ_LIMIT
+#define MAX_CONN_READ_LIMIT ( 10 * 60 * 1000 )
+#endif
+
+#ifndef MAX_CONN_WRITE_LIMIT
+#define MAX_CONN_WRITE_LIMIT ( 10 * 60 * 1000 )
+#endif
+
+static
+rc_t KNSManagerWhack ( KNSManager * self )
+{
+ free ( self );
+ KNSManagerCleanup ();
+ return 0;
+}
+
+LIB_EXPORT rc_t CC KNSManagerAddRef ( const KNSManager *self )
+{
+ if ( self != NULL )
+ {
+ switch ( KRefcountAdd( &self->refcount, "KNSManager" ) )
+ {
+ case krefLimit:
+ return RC ( rcNS, rcMgr, rcAttaching, rcRefcount, rcExcessive );
+ case krefNegative:
+ return RC ( rcNS, rcMgr, rcAttaching, rcRefcount, rcInvalid );
+ }
+ }
+ return 0;
+}
+
+
+LIB_EXPORT rc_t CC KNSManagerRelease ( const KNSManager *self )
+{
+ if ( self != NULL )
+ {
+ switch ( KRefcountDrop ( & self -> refcount, "KNSManager" ) )
+ {
+ case krefWhack:
+ return KNSManagerWhack ( ( KNSManager * ) self );
+ case krefNegative:
+ return RC ( rcNS, rcMgr, rcAttaching, rcRefcount, rcInvalid );
+ }
+ }
+ return 0;
+}
+
+
+LIB_EXPORT rc_t CC KNSManagerMake ( KNSManager **mgrp )
+{
+ rc_t rc;
+
+ if ( mgrp == NULL )
+ rc = RC ( rcNS, rcMgr, rcAllocating, rcParam, rcNull );
+ else
+ {
+ KNSManager * mgr = calloc ( 1, sizeof * mgr );
+ if ( mgr == NULL )
+ rc = RC ( rcNS, rcMgr, rcAllocating, rcMemory, rcExhausted );
+ else
+ {
+ KRefcountInit ( & mgr -> refcount, 1, "KNSManager", "init", "kns" );
+ mgr -> conn_timeout = MAX_CONN_LIMIT;
+ mgr -> conn_read_timeout = MAX_CONN_READ_LIMIT;
+ mgr -> conn_write_timeout = MAX_CONN_WRITE_LIMIT;
+ mgr -> http_read_timeout = MAX_HTTP_READ_LIMIT;
+ mgr -> http_write_timeout = MAX_HTTP_WRITE_LIMIT;
+ mgr -> verbose = false;
+
+ rc = KNSManagerInit ();
+ if ( rc == 0 )
+ {
+ * mgrp = mgr;
+ return 0;
+ }
+
+ free ( mgr );
+ }
+
+ * mgrp = NULL;
+ }
+
+ return rc;
+}
+
+
+LIB_EXPORT void KNSManagerSetVerbose ( KNSManager *self, bool verbosity )
+{
+ if ( self != NULL )
+ self -> verbose = verbosity;
+}
+
+
+LIB_EXPORT bool KNSManagerIsVerbose ( const KNSManager *self )
+{
+ return ( self != NULL ) ? self -> verbose : false;
+}
+
+
+/* MakeConnection
+ * create a connection-oriented stream
+ *
+ * "conn" [ OUT ] - a stream for communication with the server
+ *
+ * "from" [ IN ] - client endpoint
+ *
+ * "to" [ IN ] - server endpoint
+ *
+ * both endpoints have to be of type epIP; creates a TCP connection
+ */
+LIB_EXPORT rc_t CC KNSManagerMakeConnection ( const KNSManager * self,
+ struct KStream **conn, struct KEndPoint const *from, struct KEndPoint const *to )
+{
+ if ( self == NULL )
+ {
+ if ( conn == NULL )
+ return RC ( rcNS, rcStream, rcConstructing, rcParam, rcNull );
+
+ * conn = NULL;
+
+ return RC ( rcNS, rcStream, rcConstructing, rcSelf, rcNull );
+ }
+
+ return KNSManagerMakeRetryTimedConnection ( self, conn,
+ self -> conn_timeout, self -> conn_read_timeout, self -> conn_write_timeout, from, to );
+}
+/* MakeTimedConnection
+ * create a connection-oriented stream
+ *
+ * "conn" [ OUT ] - a stream for communication with the server
+ *
+ * "retryTimeout" [ IN ] - if connection is refused, retry with 1ms intervals: when negative, retry infinitely,
+ * when 0, do not retry, positive gives maximum wait time in seconds
+ *
+ * "readMillis" [ IN ] and "writeMillis" - when negative, infinite timeout
+ * when 0, return immediately, positive gives maximum wait time in mS
+ * for reads and writes respectively.
+ *
+ * "from" [ IN ] - client endpoint
+ *
+ * "to" [ IN ] - server endpoint
+ *
+ * both endpoints have to be of type epIP; creates a TCP connection
+ */
+KNS_EXTERN rc_t CC KNSManagerMakeTimedConnection ( struct KNSManager const * self,
+ struct KStream **conn, int32_t readMillis, int32_t writeMillis,
+ struct KEndPoint const *from, struct KEndPoint const *to )
+{
+ if ( self == NULL )
+ {
+ if ( conn == NULL )
+ return RC ( rcNS, rcStream, rcConstructing, rcParam, rcNull );
+
+ * conn = NULL;
+
+ return RC ( rcNS, rcStream, rcConstructing, rcSelf, rcNull );
+ }
+
+ return KNSManagerMakeRetryTimedConnection ( self, conn,
+ self -> conn_timeout, readMillis, writeMillis, from, to );
+}
+
+/* MakeRetryConnection
+ * create a connection-oriented stream
+ *
+ * "conn" [ OUT ] - a stream for communication with the server
+ *
+ * "retryTimeout" [ IN ] - if connection is refused, retry with 1ms intervals: when negative, retry infinitely,
+ * when 0, do not retry, positive gives maximum wait time in seconds
+ *
+ * "from" [ IN ] - client endpoint
+ *
+ * "to" [ IN ] - server endpoint
+ *
+ * both endpoints have to be of type epIP; creates a TCP connection
+ */
+KNS_EXTERN rc_t CC KNSManagerMakeRetryConnection ( struct KNSManager const * self,
+ struct KStream **conn, int32_t retryTimeout, struct KEndPoint const *from, struct KEndPoint const *to )
+{
+ if ( self == NULL )
+ {
+ if ( conn == NULL )
+ return RC ( rcNS, rcStream, rcConstructing, rcParam, rcNull );
+
+ * conn = NULL;
+
+ return RC ( rcNS, rcStream, rcConstructing, rcSelf, rcNull );
+ }
+
+ return KNSManagerMakeRetryTimedConnection ( self, conn,
+ retryTimeout, self -> conn_read_timeout, self -> conn_write_timeout, from, to );
+}
+
+/* SetConnectionTimeouts
+ * sets default connect/read/write timeouts to supply to sockets
+ *
+ * "connectMillis", "readMillis", "writeMillis" [ IN ] - when negative, infinite timeout
+ * when 0, return immediately, positive gives maximum wait time in sec/mS
+ * for connects, reads and writes respectively.
+ */
+LIB_EXPORT rc_t CC KNSManagerSetConnectionTimeouts ( KNSManager *self,
+ int32_t connectSecs, int32_t readMillis, int32_t writeMillis )
+{
+ if ( self == NULL )
+ return RC ( rcNS, rcMgr, rcUpdating, rcSelf, rcNull );
+
+ /* limit values */
+ if ( connectSecs < 0 )
+ connectSecs = -1;
+ else if ( connectSecs > MAX_CONN_LIMIT )
+ connectSecs = MAX_CONN_LIMIT;
+
+ if ( readMillis < 0 )
+ readMillis = -1;
+ else if ( readMillis > MAX_CONN_READ_LIMIT )
+ readMillis = MAX_CONN_READ_LIMIT;
+
+ if ( writeMillis < 0 )
+ writeMillis = -1;
+ else if ( writeMillis > MAX_CONN_WRITE_LIMIT )
+ writeMillis = MAX_CONN_WRITE_LIMIT;
+
+ self -> conn_timeout = connectSecs;
+ self -> conn_read_timeout = readMillis;
+ self -> conn_write_timeout = writeMillis;
+
+ return 0;
+}
+
+
+/* SetHTTPTimeouts
+ * sets default read/write timeouts to supply to HTTP connections
+ *
+ * "readMillis" [ IN ] and "writeMillis" - when negative, infinite timeout
+ * when 0, return immediately, positive gives maximum wait time in mS
+ * for reads and writes respectively.
+ */
+LIB_EXPORT rc_t CC KNSManagerSetHTTPTimeouts ( KNSManager *self,
+ int32_t readMillis, int32_t writeMillis )
+{
+ if ( self == NULL )
+ return RC ( rcNS, rcMgr, rcUpdating, rcSelf, rcNull );
+
+ /* limit values */
+ if ( readMillis < 0 )
+ readMillis = -1;
+ else if ( readMillis > MAX_HTTP_READ_LIMIT )
+ readMillis = MAX_HTTP_READ_LIMIT;
+
+ if ( writeMillis < 0 )
+ writeMillis = -1;
+ else if ( writeMillis > MAX_HTTP_WRITE_LIMIT )
+ writeMillis = MAX_HTTP_WRITE_LIMIT;
+
+ self -> http_read_timeout = readMillis;
+ self -> http_write_timeout = writeMillis;
+
+ return 0;
+}
diff --git a/libs/kproc/win/syslock-priv.h b/libs/kns/mgr-priv.h
similarity index 81%
copy from libs/kproc/win/syslock-priv.h
copy to libs/kns/mgr-priv.h
index ea751af..627bbb1 100644
--- a/libs/kproc/win/syslock-priv.h
+++ b/libs/kns/mgr-priv.h
@@ -24,11 +24,11 @@
*
*/
-#ifndef _h_syslock_priv_
-#define _h_syslock_priv_
+#ifndef _h_kns_mgr_priv_
+#define _h_kns_mgr_priv_
-#ifndef _h_os_native_
-#include <os-native.h>
+#ifndef _h_kns_extern_
+#include <kns/extern.h>
#endif
#ifndef _h_klib_refcount_
@@ -39,18 +39,19 @@
extern "C" {
#endif
-/*--------------------------------------------------------------------------
- * KLock
- * a POSIX-style mutual exclusion lock
- */
-struct KLock
+struct KNSManager
{
- HANDLE mutex;
KRefcount refcount;
+ int32_t conn_timeout;
+ int32_t conn_read_timeout;
+ int32_t conn_write_timeout;
+ int32_t http_read_timeout;
+ int32_t http_write_timeout;
+ bool verbose;
};
#ifdef __cplusplus
}
#endif
-#endif /* _h_syslock_priv_ */
+#endif /* _h_kns_mgr_priv_ */
diff --git a/interfaces/kns/curl-file.h b/libs/kns/poll-priv.h
similarity index 83%
rename from interfaces/kns/curl-file.h
rename to libs/kns/poll-priv.h
index 77aabe4..b0cbbe2 100644
--- a/interfaces/kns/curl-file.h
+++ b/libs/kns/poll-priv.h
@@ -23,12 +23,9 @@
* ===========================================================================
*
*/
-#ifndef _h_curl_file_
-#define _h_curl_file_
-#ifndef _h_kns_extern_
-#include <kns/extern.h>
-#endif
+#ifndef _h_poll_priv_
+#define _h_poll_priv_
#ifdef __cplusplus
extern "C" {
@@ -36,14 +33,19 @@ extern "C" {
/*--------------------------------------------------------------------------
- * KCurlFile
- * a remote file, fetched (in parts) via http using libcurl
+ * forwards
*/
-KNS_EXTERN rc_t CC KCurlFileMake ( struct KFile const **self, const char * url, bool verbose );
+struct timeout_t;
+
+
+/* socket_wait
+ * wait for an event or a timeout
+ */
+int socket_wait ( int fd, int events, struct timeout_t *tm );
#ifdef __cplusplus
}
#endif
-#endif
+#endif /* _h_poll_priv_ */
diff --git a/libs/kns/stream-priv.h b/libs/kns/stream-priv.h
index 6919869..12575f8 100644
--- a/libs/kns/stream-priv.h
+++ b/libs/kns/stream-priv.h
@@ -31,6 +31,10 @@
#define rcStream rcFile
#endif
+#ifndef rcSocket
+#define rcSocket rcFile
+#endif
+
#ifndef rcUrl
#define rcUrl rcPath
#endif
diff --git a/libs/kns/stream.c b/libs/kns/stream.c
index b63e267..4b25d71 100644
--- a/libs/kns/stream.c
+++ b/libs/kns/stream.c
@@ -27,10 +27,13 @@
#include <kns/extern.h>
#include <kns/impl.h>
#include <klib/rc.h>
+#include <kproc/timeout.h>
+#include <os-native.h>
#include <sysalloc.h>
#include "stream-priv.h"
+#include <assert.h>
/*--------------------------------------------------------------------------
* KStream
@@ -99,6 +102,7 @@ LIB_EXPORT rc_t CC KStreamRelease ( const KStream *self )
}
/* Read
+ * TimedRead
* read data from stream
*
* "buffer" [ OUT ] and "bsize" [ IN ] - return buffer for read
@@ -106,6 +110,13 @@ LIB_EXPORT rc_t CC KStreamRelease ( const KStream *self )
* "num_read" [ OUT ] - return parameter giving number of bytes
* actually read. when returned value is zero and return code is
* also zero, interpreted as end of stream.
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed reads. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
*/
LIB_EXPORT rc_t CC KStreamRead ( const KStream *self,
void *buffer, size_t bsize, size_t *num_read )
@@ -135,7 +146,42 @@ LIB_EXPORT rc_t CC KStreamRead ( const KStream *self,
return RC ( rcNS, rcStream, rcReading, rcInterface, rcBadVersion );
}
+LIB_EXPORT rc_t CC KStreamTimedRead ( const KStream *self,
+ void *buffer, size_t bsize, size_t *num_read, struct timeout_t *tm )
+{
+ if ( num_read == NULL )
+ return RC ( rcNS, rcStream, rcReading, rcParam, rcNull );
+
+ * num_read = 0;
+
+ if ( self == NULL )
+ return RC ( rcNS, rcStream, rcReading, rcSelf, rcNull );
+
+ if ( ! self -> read_enabled )
+ return RC ( rcNS, rcStream, rcReading, rcStream, rcNoPerm );
+
+ if ( buffer == NULL )
+ return RC ( rcNS, rcStream, rcReading, rcBuffer, rcNull );
+ if ( bsize == 0 )
+ return RC ( rcNS, rcStream, rcReading, rcBuffer, rcInsufficient );
+
+ switch ( self -> vt -> v1 . maj )
+ {
+ case 1:
+ if ( self -> vt -> v1 . min >= 1 )
+ return ( * self -> vt -> v1 . timed_read ) ( self, buffer, bsize, num_read, tm );
+ if ( tm == NULL )
+ return ( * self -> vt -> v1 . read ) ( self, buffer, bsize, num_read );
+ break;
+ }
+
+
+ return RC ( rcNS, rcStream, rcReading, rcInterface, rcBadVersion );
+}
+
+
/* ReadAll
+ * TimedReadAll
* read from stream until "bsize" bytes have been retrieved
* or until end-of-input
*
@@ -144,6 +190,13 @@ LIB_EXPORT rc_t CC KStreamRead ( const KStream *self,
* "num_read" [ OUT ] - return parameter giving number of bytes
* actually read. when returned value is zero and return code is
* also zero, interpreted as end of stream.
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed reads. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
*/
LIB_EXPORT rc_t CC KStreamReadAll ( const KStream *self,
void *buffer, size_t bsize, size_t *num_read )
@@ -171,16 +224,42 @@ LIB_EXPORT rc_t CC KStreamReadAll ( const KStream *self,
switch ( self -> vt -> v1 . maj )
{
case 1:
- for ( rc = 0, b = buffer, total = 0; total < bsize; total += count )
+ count = 0;
+ rc = ( * self -> vt -> v1 . read ) ( self, buffer, bsize, & count );
+ total = count;
+
+ if ( rc == 0 && count != 0 && count < bsize )
{
- count = 0;
- rc = ( * self -> vt -> v1 . read ) ( self, b + total, bsize - total, & count );
- if ( rc != 0 )
- break;
- if ( count == 0 )
- break;
+ if ( self -> vt -> v1 . min >= 1 )
+ {
+ timeout_t no_block;
+ TimeoutInit ( & no_block, 0 );
+
+ for ( rc = 0, b = buffer; total < bsize; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . timed_read ) ( self, b + total, bsize - total, & count, & no_block );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ }
+ else
+ {
+ for ( rc = 0, b = buffer; total < bsize; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . read ) ( self, b + total, bsize - total, & count );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ }
}
break;
+
default:
return RC ( rcNS, rcStream, rcReading, rcInterface, rcBadVersion );
}
@@ -194,16 +273,239 @@ LIB_EXPORT rc_t CC KStreamReadAll ( const KStream *self,
return rc;
}
+LIB_EXPORT rc_t CC KStreamTimedReadAll ( const KStream *self,
+ void *buffer, size_t bsize, size_t *num_read, struct timeout_t *tm )
+{
+ rc_t rc;
+ uint8_t *b;
+ size_t total, count;
+
+ if ( num_read == NULL )
+ return RC ( rcNS, rcStream, rcReading, rcParam, rcNull );
+
+ * num_read = 0;
+
+ if ( self == NULL )
+ return RC ( rcNS, rcStream, rcReading, rcSelf, rcNull );
+
+ if ( ! self -> read_enabled )
+ return RC ( rcNS, rcStream, rcReading, rcStream, rcNoPerm );
+
+ if ( buffer == NULL )
+ return RC ( rcNS, rcStream, rcReading, rcBuffer, rcNull );
+ if ( bsize == 0 )
+ return RC ( rcNS, rcStream, rcReading, rcBuffer, rcInsufficient );
+
+ switch ( self -> vt -> v1 . maj )
+ {
+ case 1:
+ if ( self -> vt -> v1 . min >= 1 )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . timed_read ) ( self, buffer, bsize, & count, tm );
+ total = count;
+
+ if ( rc == 0 && count != 0 && count < bsize )
+ {
+ timeout_t no_block;
+ TimeoutInit ( & no_block, 0 );
+
+ for ( b = buffer; total < bsize; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . timed_read ) ( self, b + total, bsize - total, & count, & no_block );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ }
+ break;
+ }
+
+ if ( tm == NULL )
+ {
+ for ( rc = 0, b = buffer, total = 0; total < bsize; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . read ) ( self, b + total, bsize - total, & count );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ break;
+ }
+
+ /* no break */
+
+ default:
+ return RC ( rcNS, rcStream, rcReading, rcInterface, rcBadVersion );
+ }
+
+ if ( total != 0 )
+ {
+ * num_read = total;
+ return 0;
+ }
+
+ return rc;
+}
+
+
+/* ReadExactly
+ * TimedReadExactly
+ * read from stream until "bytes" have been retrieved
+ * or return incomplete transfer
+ *
+ * "buffer" [ OUT ] and "bytes" [ IN ] - return buffer for read
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed reads. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
+ */
+LIB_EXPORT rc_t CC KStreamReadExactly ( const KStream *self,
+ void *buffer, size_t bytes )
+{
+ rc_t rc;
+ uint8_t *b;
+ size_t total, count;
+
+ if ( self == NULL )
+ return RC ( rcNS, rcStream, rcReading, rcSelf, rcNull );
+
+ if ( ! self -> read_enabled )
+ return RC ( rcNS, rcStream, rcReading, rcStream, rcNoPerm );
+
+ if ( bytes == 0 )
+ return 0;
+ if ( buffer == NULL )
+ return RC ( rcNS, rcStream, rcReading, rcBuffer, rcNull );
+
+ switch ( self -> vt -> v1 . maj )
+ {
+ case 1:
+ assert ( bytes != 0 );
+ for ( b = buffer, total = 0; total < bytes; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . read ) ( self, b + total, bytes - total, & count );
+ if ( rc != 0 )
+ {
+ if ( GetRCObject ( rc ) != rcTimeout || GetRCState ( rc ) != rcExhausted )
+ break;
+ }
+ else if ( count == 0 )
+ {
+ rc = RC ( rcNS, rcStream, rcReading, rcTransfer, rcIncomplete );
+ break;
+ }
+ }
+ break;
+
+ default:
+ return RC ( rcNS, rcStream, rcReading, rcInterface, rcBadVersion );
+ }
+
+ return rc;
+}
+
+LIB_EXPORT rc_t CC KStreamTimedReadExactly ( const KStream *self,
+ void *buffer, size_t bytes, struct timeout_t *tm )
+{
+ rc_t rc;
+ uint8_t *b;
+ size_t total, count;
+
+ if ( self == NULL )
+ return RC ( rcNS, rcStream, rcReading, rcSelf, rcNull );
+
+ if ( ! self -> read_enabled )
+ return RC ( rcNS, rcStream, rcReading, rcStream, rcNoPerm );
+
+ if ( bytes == 0 )
+ return RC ( rcNS, rcStream, rcReading, rcBuffer, rcInsufficient );
+ if ( buffer == NULL )
+ return RC ( rcNS, rcStream, rcReading, rcBuffer, rcNull );
+
+ switch ( self -> vt -> v1 . maj )
+ {
+ case 1:
+ if ( self -> vt -> v1 . min >= 1 )
+ {
+ assert ( bytes != 0 );
+ for ( b = buffer, total = 0; total < bytes; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . timed_read ) ( self, b + total, bytes - total, & count, tm );
+ if ( rc != 0 )
+ {
+ if ( tm != NULL )
+ break;
+ if ( GetRCObject ( rc ) != rcTimeout || GetRCState ( rc ) != rcExhausted )
+ break;
+ }
+ else if ( count == 0 )
+ {
+ rc = RC ( rcNS, rcStream, rcReading, rcTransfer, rcIncomplete );
+ break;
+ }
+ }
+
+ break;
+ }
+
+ if ( tm == NULL )
+ {
+ assert ( bytes != 0 );
+ for ( b = buffer, total = 0; total < bytes; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . read ) ( self, b + total, bytes - total, & count );
+ if ( rc != 0 )
+ {
+ if ( GetRCObject ( rc ) != rcTimeout || GetRCState ( rc ) != rcExhausted )
+ break;
+ }
+ else if ( count == 0 )
+ {
+ rc = RC ( rcNS, rcStream, rcReading, rcTransfer, rcIncomplete );
+ break;
+ }
+ }
+ break;
+ }
+
+ /* no break */
+
+ default:
+ return RC ( rcNS, rcStream, rcReading, rcInterface, rcBadVersion );
+ }
+
+ return rc;
+}
+
/* Write
+ * TimedWrite
* send data to stream
*
* "buffer" [ IN ] and "size" [ IN ] - data to be written
*
* "num_writ" [ OUT, NULL OKAY ] - optional return parameter
* giving number of bytes actually written
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed writes. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
*/
LIB_EXPORT rc_t CC KStreamWrite ( KStream *self,
- const void *buffer, size_t size, size_t *num_writ)
+ const void *buffer, size_t size, size_t *num_writ )
{
size_t ignore;
if ( num_writ == NULL )
@@ -231,7 +533,41 @@ LIB_EXPORT rc_t CC KStreamWrite ( KStream *self,
return RC ( rcNS, rcStream, rcWriting, rcInterface, rcBadVersion );
}
+LIB_EXPORT rc_t CC KStreamTimedWrite ( KStream *self,
+ const void *buffer, size_t size, size_t *num_writ, struct timeout_t *tm )
+{
+ size_t ignore;
+ if ( num_writ == NULL )
+ num_writ = & ignore;
+
+ * num_writ = 0;
+
+ if ( self == NULL )
+ return RC ( rcNS, rcStream, rcWriting, rcSelf, rcNull );
+
+ if ( ! self -> write_enabled )
+ return RC ( rcNS, rcStream, rcWriting, rcStream, rcNoPerm );
+
+ if ( size == 0 )
+ return 0;
+ if ( buffer == NULL )
+ return RC ( rcNS, rcStream, rcWriting, rcBuffer, rcNull );
+
+ switch ( self -> vt -> v1 . maj )
+ {
+ case 1:
+ if ( self -> vt -> v1 . min >= 1 )
+ return ( * self -> vt -> v1 . timed_write ) ( self, buffer, size, num_writ, tm );
+ if ( tm == NULL )
+ return ( * self -> vt -> v1 . write ) ( self, buffer, size, num_writ );
+ break;
+ }
+
+ return RC ( rcNS, rcStream, rcWriting, rcInterface, rcBadVersion );
+}
+
/* WriteAll
+ * TimedWriteAll
* write to stream until "size" bytes have been transferred
* or until no further progress can be made
*
@@ -239,6 +575,13 @@ LIB_EXPORT rc_t CC KStreamWrite ( KStream *self,
*
* "num_writ" [ OUT, NULL OKAY ] - optional return parameter
* giving number of bytes actually written
+ *
+ * "tm" [ IN/OUT, NULL OKAY ] - an optional indicator of
+ * blocking behavior. not all implementations will support
+ * timed writes. a NULL timeout will block indefinitely,
+ * a value of "tm->mS == 0" will have non-blocking behavior
+ * if supported by implementation, and "tm->mS > 0" will indicate
+ * a maximum wait timeout.
*/
LIB_EXPORT rc_t CC KStreamWriteAll ( KStream *self,
const void *buffer, size_t size, size_t *num_writ )
@@ -267,16 +610,111 @@ LIB_EXPORT rc_t CC KStreamWriteAll ( KStream *self,
switch ( self -> vt -> v1 . maj )
{
case 1:
- for ( rc = 0, b = buffer, total = 0; total < size; total += count )
+ count = 0;
+ rc = ( * self -> vt -> v1 . write ) ( self, buffer, size, & count );
+ total = count;
+
+ if ( rc == 0 && count != 0 && count < size )
{
- count = 0;
- rc = ( * self -> vt -> v1 . write ) ( self, b + total, size - total, & count );
- if ( rc != 0 )
- break;
- if ( count == 0 )
- break;
+ if ( self -> vt -> v1 . min >= 1 )
+ {
+ timeout_t no_block;
+ TimeoutInit ( & no_block, 0 );
+
+ for ( b = buffer; total < size; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . timed_write ) ( self, b + total, size - total, & count, & no_block );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ }
+ else
+ {
+ for ( b = buffer; total < size; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . write ) ( self, b + total, size - total, & count );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ }
}
break;
+
+ default:
+ return RC ( rcNS, rcStream, rcWriting, rcInterface, rcBadVersion );
+ }
+
+ * num_writ = total;
+ if ( total == size )
+ return 0;
+ if ( rc == 0 )
+ return RC ( rcNS, rcStream, rcWriting, rcTransfer, rcIncomplete );
+ return rc;
+}
+
+LIB_EXPORT rc_t CC KStreamTimedWriteAll ( KStream *self,
+ const void *buffer, size_t size, size_t *num_writ, struct timeout_t *tm )
+{
+ rc_t rc;
+ const uint8_t *b;
+ size_t total, count;
+
+ size_t ignore;
+ if ( num_writ == NULL )
+ num_writ = & ignore;
+
+ * num_writ = 0;
+
+ if ( self == NULL )
+ return RC ( rcNS, rcStream, rcWriting, rcSelf, rcNull );
+
+ if ( ! self -> write_enabled )
+ return RC ( rcNS, rcStream, rcWriting, rcStream, rcNoPerm );
+
+ if ( size == 0 )
+ return 0;
+ if ( buffer == NULL )
+ return RC ( rcNS, rcStream, rcWriting, rcBuffer, rcNull );
+
+ switch ( self -> vt -> v1 . maj )
+ {
+ case 1:
+ if ( self -> vt -> v1 . min >= 1 )
+ {
+ for ( rc = 0, b = buffer, total = 0; total < size; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . timed_write ) ( self, b + total, size - total, & count, tm );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ break;
+ }
+
+ if ( tm == NULL )
+ {
+ for ( rc = 0, b = buffer, total = 0; total < size; total += count )
+ {
+ count = 0;
+ rc = ( * self -> vt -> v1 . write ) ( self, b + total, size - total, & count );
+ if ( rc != 0 )
+ break;
+ if ( count == 0 )
+ break;
+ }
+ break;
+ }
+
+ /* no break */
+
default:
return RC ( rcNS, rcStream, rcWriting, rcInterface, rcBadVersion );
}
@@ -310,6 +748,12 @@ LIB_EXPORT rc_t CC KStreamInit ( KStream *self, const KStream_vt *vt,
switch ( vt -> v1 . min )
{
/* ADD NEW MINOR VERSION CASES HERE */
+ case 1:
+#if _DEBUGGING
+ if ( vt -> v1 . timed_write == NULL ||
+ vt -> v1 . timed_read == NULL )
+ return RC ( rcNS, rcStream, rcConstructing, rcInterface, rcNull );
+#endif
case 0:
#if _DEBUGGING
if ( vt -> v1 . write == NULL ||
diff --git a/libs/kns/unix/sysmgr.c b/libs/kns/sysmgr.h
similarity index 88%
copy from libs/kns/unix/sysmgr.c
copy to libs/kns/sysmgr.h
index 702675b..03928c4 100644
--- a/libs/kns/unix/sysmgr.c
+++ b/libs/kns/sysmgr.h
@@ -23,13 +23,19 @@
* ===========================================================================
*
*/
-#include "kns_mgr_priv.h"
-rc_t KNSManagerInit ( struct KNSManager *self )
-{
- return 0;
-}
+#ifndef _h_sysmgr_
+#define _h_sysmgr_
-void KNSManagerCleanup ( struct KNSManager *self )
-{
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+rc_t KNSManagerInit();
+void KNSManagerCleanup();
+
+#ifdef __cplusplus
}
+#endif
+
+#endif
\ No newline at end of file
diff --git a/libs/kns/undyinghttp.c b/libs/kns/undyinghttp.c
new file mode 100644
index 0000000..228c163
--- /dev/null
+++ b/libs/kns/undyinghttp.c
@@ -0,0 +1,362 @@
+/*===========================================================================
+*
+* PUBLIC DOMAIN NOTICE
+* National Center for Biotechnology Information
+*
+* This software/database is a "United States Government Work" under the
+* terms of the United States Copyright Act. It was written as part of
+* the author's official duties as a United States Government employee and
+* thus cannot be copyrighted. This software/database is freely available
+* to the public for use. The National Library of Medicine and the U.S.
+* Government have not placed any restriction on its use or reproduction.
+*
+* Although all reasonable efforts have been taken to ensure the accuracy
+* and reliability of the software and data, the NLM and the U.S.
+* Government do not and cannot warrant the performance or results that
+* may be obtained by using this software or data. The NLM and the U.S.
+* Government disclaim all warranties, express or implied, including
+* warranties of performance, merchantability or fitness for any particular
+* purpose.
+*
+* Please cite the author in any work or product based on this material.
+*
+* ==============================================================================
+*
+*/
+
+#include <kns/extern.h>
+
+#define KSTREAM_IMPL KHttpStream
+typedef struct KHttpStream KHttpStream;
+
+#define KFILE_IMPL KHttpUndyingFile
+typedef struct KHttpUndyingFile KHttpUndyingFile;
+
+#include <kfs/impl.h>
+
+#include "http-priv.h"
+
+#include <kns/http.h> /* KNSManagerMakeHttpFile */
+#include <kns/manager.h> /* KNSManager */
+
+#include <klib/debug.h> /* DBGMSG */
+#include <klib/printf.h> /* string_vprintf */
+#include <klib/rc.h>
+
+#include <sysalloc.h> /* for malloc/calloc */
+
+#include <assert.h>
+#include <string.h> /* memset */
+
+#include <limits.h> /* PATH_MAX */
+#ifndef PATH_MAX
+#define PATH_MAX 4096
+#endif
+
+/*******************************************************************************
+ * KHttpUndyingFile
+ */
+
+struct KHttpUndyingFile
+{
+ KFile dad;
+
+ uint64_t size; /* file's size */
+
+ const KFile *file; /* this struct is a wrapper around this file */
+
+ const KNSManager *mgr; /* mgr to construct the file */
+ const char *url; /* url to construct the file */
+ ver_t vers; /* vers to construct the file */
+};
+
+static rc_t CC KHttpUndyingFileDestroy(KHttpUndyingFile *self) {
+ rc_t rc = 0;
+
+ if (self == NULL) {
+ return 0;
+ }
+
+ free((void*)self->url);
+
+ rc = KFileRelease(self->file);
+
+ {
+ rc_t rc2 = KNSManagerRelease(self->mgr);
+ if (rc == 0) {
+ rc = rc2;
+ }
+ }
+
+ memset(self, 0, sizeof *self);
+
+ free(self);
+
+ return rc;
+}
+
+static KFile* GetUnderlyingFile(const KHttpUndyingFile *self) {
+ if (self == NULL) {
+ return NULL;
+ }
+ else {
+ return (KFile*)self->file;
+ }
+}
+
+static struct KSysFile* CC KHttpUndyingFileGetSysFile(
+ const KHttpUndyingFile *self, uint64_t *offset)
+{
+ return KFileGetSysFile(GetUnderlyingFile(self), offset);
+}
+
+static
+rc_t CC KHttpUndyingFileRandomAccess(const KHttpUndyingFile *self)
+{
+ return KFileRandomAccess(GetUnderlyingFile(self));
+}
+
+static rc_t CC KHttpUndyingFileSize(const KHttpUndyingFile *self,
+ uint64_t *size)
+{
+ return KFileSize(GetUnderlyingFile(self), size);
+}
+
+static
+rc_t CC KHttpUndyingFileSetSize(KHttpUndyingFile *self, uint64_t size)
+{
+ return KFileSetSize(GetUnderlyingFile(self), size);
+}
+
+static rc_t Revive(const KHttpUndyingFile *cself) {
+ KHttpUndyingFile *self = (KHttpUndyingFile*)cself;
+
+ rc_t rc = 0;
+
+ assert(self);
+
+ rc = KFileRelease(self->file);
+ self->file = NULL;
+
+ if (rc == 0) {
+ rc = SecretKNSManagerMakeHttpFile(self->mgr,
+ &self->file, NULL, self->vers, self->url);
+ }
+
+ return rc;
+}
+
+#define RETRY_REVIVE 2
+#define RETRY_READ 2
+static rc_t CC KHttpUndyingFileRead(const KHttpUndyingFile *self,
+ uint64_t pos, void *buffer, size_t bsize, size_t *num_read)
+{
+ if (self == NULL || self->file == NULL) {
+ return KFileRead(NULL, pos, buffer, bsize, num_read);
+ }
+ else {
+ rc_t rc = 0, prev_rc = 0;
+ int i = 0;
+ for (i = 0; i < RETRY_REVIVE; ++i) {
+ int r = 0;
+ for (r = 0; r < RETRY_READ; ++r) {
+ rc = KFileRead(self->file, pos, buffer, bsize, num_read);
+ if (rc == 0) {
+ return rc;
+ }
+ else {
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@3 %s KFileRead(%s, %d)(%d/%d) = %R @@@@@@@"
+ "\n", __FUNCTION__,
+ self->url, pos, r + 1, RETRY_READ, rc));
+ if (prev_rc == 0) {
+ prev_rc = rc;
+ }
+ else if (rc == prev_rc) {
+ break;
+ }
+ }
+ }
+
+ if (i < RETRY_REVIVE - 1) {
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@5 %s %d/%d KFileRead: Reviving... @@@@@@@@"
+ "\n", __FUNCTION__, i + 1, RETRY_REVIVE));
+ rc = Revive(self);
+ if (rc != 0) {
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@5 %s KFileRead(%s, %d): Revive = %R @@@@@@"
+ "\n", __FUNCTION__, self->url, pos, rc));
+ return rc;
+ }
+ }
+ else {
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@5 %s %d/%d KFileRead: Not Reviving @@@@@@@@"
+ "\n", __FUNCTION__, i + 1, RETRY_REVIVE));
+ }
+ }
+
+ return rc;
+ }
+}
+
+static rc_t CC KHttpUndyingFileWrite ( KHttpUndyingFile *self, uint64_t pos,
+ const void *buffer, size_t size, size_t *num_writ )
+{
+ return KFileWrite(GetUnderlyingFile(self), pos, buffer, size, num_writ);
+}
+
+static
+uint32_t CC KHttpUndyingFileGetType(const KHttpUndyingFile *self)
+{
+ return KFileType(GetUnderlyingFile(self));
+}
+
+static rc_t CC KHttpUndyingFileTimedRead(const KHttpUndyingFile *self,
+ uint64_t pos, void *buffer, size_t bsize, size_t *num_read,
+ struct timeout_t *tm)
+{
+ if (self == NULL || self->file == NULL) {
+ return KFileTimedRead(NULL, pos, buffer, bsize, num_read, tm);
+ }
+ else {
+ rc_t rc = 0, prev_rc = 0;
+ int i = 0;
+ for (i = 0; i < RETRY_REVIVE; ++i) {
+ int r = 0;
+ for (r = 0; r < RETRY_READ; ++r) {
+ rc = KFileTimedRead(self->file, pos, buffer, bsize, num_read,
+ tm);
+ if (rc == 0) {
+ return rc;
+ }
+ else {
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@3 %s KFileTimedRead(%s, %d)(%d/%d) = %R @@"
+ "\n", __FUNCTION__,
+ self->url, pos, r + 1, RETRY_READ, rc));
+ if (prev_rc == 0) {
+ prev_rc = rc;
+ }
+ else if (rc == prev_rc) {
+ break;
+ }
+ }
+ }
+
+ if (i < RETRY_REVIVE - 1) {
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@5 %s %d/%d KFileTimedRead: Reviving... @@@"
+ "\n", __FUNCTION__, i + 1, RETRY_REVIVE));
+ rc = Revive(self);
+ if (rc != 0) {
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@5 %s KFileTimedRead(%s, %d): Revive = %R @"
+ "\n", __FUNCTION__, self->url, pos, rc));
+ return rc;
+ }
+ }
+ else {
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@5 %s %d/%d KFileTimedRead: Not Reviving @@"
+ "\n", __FUNCTION__, i + 1, RETRY_REVIVE));
+ }
+ }
+ return rc;
+ }
+}
+
+static rc_t CC KHttpUndyingFileTimedWrite(KHttpUndyingFile *self, uint64_t pos,
+ const void *buffer, size_t size, size_t *num_writ,
+ struct timeout_t *tm)
+{
+ return KFileTimedWrite(GetUnderlyingFile(self),
+ pos, buffer, size, num_writ, tm);
+}
+
+static KFile_vt_v1 vtKHttpFile = {
+ 1, 2,
+
+ KHttpUndyingFileDestroy,
+ KHttpUndyingFileGetSysFile,
+ KHttpUndyingFileRandomAccess,
+ KHttpUndyingFileSize,
+ KHttpUndyingFileSetSize,
+ KHttpUndyingFileRead,
+ KHttpUndyingFileWrite,
+ KHttpUndyingFileGetType,
+ KHttpUndyingFileTimedRead,
+ KHttpUndyingFileTimedWrite
+};
+
+static rc_t KNSManagerVMakeUndyingHttpFile(const KNSManager *self, const KFile **file,
+ struct KStream *conn, ver_t vers, const char *url, va_list args)
+{
+ char buffer[PATH_MAX] = "";
+ size_t num_writ = 0;
+ rc_t rc = 0;
+ KHttpUndyingFile *f = NULL;
+ if (file == NULL) {
+ return RC(rcNS, rcFile, rcConstructing, rcParam, rcNull);
+ }
+ *file = NULL;
+ f = calloc(1, sizeof *f);
+ if (f == NULL) {
+ return RC(rcNS, rcFile, rcConstructing, rcMemory, rcExhausted);
+ }
+ rc = string_vprintf(buffer, sizeof buffer, &num_writ, url, args);
+ if (rc == 0) {
+ f->url = string_dup_measure(url, NULL);
+ }
+ if (f->url == NULL) {
+ rc = RC(rcNS, rcFile, rcConstructing, rcMemory, rcExhausted);
+ }
+ f->vers = vers;
+ if (rc == 0) {
+ rc = KNSManagerAddRef(self);
+ if (rc == 0) {
+ f->mgr = self;
+ }
+ }
+ if (rc == 0) {
+ assert(conn == NULL);
+ rc = Revive(f);
+ }
+ if (rc == 0) {
+ KHttpUndyingFileSize(f, &f->size);
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_MGR), (
+"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@4 %s KNSManagerMakeUndyingHttpFile: size = %ld"
+ "\n", __FUNCTION__, f->size));
+ }
+ if (rc == 0) {
+ rc = KFileInit(&f->dad, (const KFile_vt*)&vtKHttpFile,
+ "KHttpUndyingFile", url, true, false);
+ }
+ if (rc == 0) {
+ *file = &f->dad;
+ }
+ else {
+ KHttpUndyingFileDestroy(f);
+ }
+
+ return rc;
+}
+
+/*LIB_EXPORT rc_t CC KNSManagerMakeUndyingHttpFile(const KNSManager *self,
+ const KFile **file, struct KStream *conn, ver_t vers, const char *url, ...)
+{
+ rc_t rc = 0;
+ va_list args;
+ va_start(args, url);
+ rc = KNSManagerVMakeHttpFile(self, file, conn, vers, url, args);
+ va_end(args);
+ return rc;
+}*/
+
+LIB_EXPORT rc_t CC KNSManagerVMakeHttpFile(const KNSManager *self,
+ const KFile **file, struct KStream *conn, ver_t vers, const char *url,
+ va_list args)
+{
+ return KNSManagerVMakeUndyingHttpFile(self, file, conn, vers, url, args);
+}
diff --git a/libs/kns/unix/sysmgr.c b/libs/kns/unix/sysmgr.c
index 702675b..ac031a9 100644
--- a/libs/kns/unix/sysmgr.c
+++ b/libs/kns/unix/sysmgr.c
@@ -23,13 +23,15 @@
* ===========================================================================
*
*/
-#include "kns_mgr_priv.h"
-rc_t KNSManagerInit ( struct KNSManager *self )
+#include <klib/rc.h>
+#include "sysmgr.h"
+
+rc_t KNSManagerInit ( void )
{
return 0;
}
-void KNSManagerCleanup ( struct KNSManager *self )
+void KNSManagerCleanup ( void )
{
}
diff --git a/libs/kns/unix/syssock.c b/libs/kns/unix/syssock.c
index 037a8e6..5139c9a 100644
--- a/libs/kns/unix/syssock.c
+++ b/libs/kns/unix/syssock.c
@@ -35,19 +35,28 @@
#include <kns/socket.h>
#include <kns/impl.h>
#include <kns/endpoint.h>
-#include <klib/rc.h>
+
+#include <klib/debug.h> /* DBGMSG */
#include <klib/log.h>
-#include <klib/text.h>
-#include <klib/printf.h>
#include <klib/out.h>
+#include <klib/printf.h>
+#include <klib/rc.h>
+#include <klib/text.h>
+
+#include <kproc/timeout.h>
+#include "mgr-priv.h"
#include "stream-priv.h"
+#include "poll-priv.h"
#include <sysalloc.h>
+
#include <stdlib.h>
#include <assert.h>
#include <string.h>
+#include <os-native.h>
+
#include <arpa/inet.h>
#include <sys/types.h>
#include <sys/socket.h>
@@ -59,6 +68,11 @@
#include <errno.h>
#include <pwd.h>
+#ifndef POLLRDHUP
+#define POLLRDHUP 0
+#endif
+
+
/*--------------------------------------------------------------------------
* KSocket
* a socket IS a stream
@@ -75,24 +89,26 @@
struct KSocket
{
KStream dad;
+ const char * path;
+ uint32_t type;
+ int32_t read_timeout;
+ int32_t write_timeout;
int fd;
- char* path;
};
LIB_EXPORT rc_t CC KSocketAddRef( struct KSocket *self )
{
- return KStreamAddRef(&self->dad);
+ return KStreamAddRef ( & self -> dad );
}
-LIB_EXPORT rc_t CC KSocketRelease( struct KSocket *self )
+LIB_EXPORT rc_t CC KSocketRelease ( struct KSocket *self )
{
- return KStreamRelease(&self->dad);
+ return KStreamRelease ( & self -> dad );
}
-LIB_EXPORT
+static
rc_t CC KSocketWhack ( KSocket *self )
{
-
assert ( self != NULL );
shutdown ( self -> fd, SHUT_WR );
@@ -104,14 +120,15 @@ rc_t CC KSocketWhack ( KSocket *self )
if ( result <= 0 )
break;
}
- shutdown ( self ->fd, SHUT_RD );
+
+ shutdown ( self -> fd, SHUT_RD );
close ( self -> fd );
- if (self->path)
+ if ( self -> path != NULL )
{
- unlink(self->path);
- free(self->path);
+ unlink ( self -> path );
+ free ( ( void* ) self -> path );
}
free ( self );
@@ -120,7 +137,7 @@ rc_t CC KSocketWhack ( KSocket *self )
}
static
-rc_t HandleErrno ( const char *func_name, int lineno )
+rc_t HandleErrno ( const char *func_name, unsigned int lineno )
{
int lerrno;
rc_t rc = 0;
@@ -245,404 +262,614 @@ rc_t HandleErrno ( const char *func_name, int lineno )
}
static
-int socket_wait ( int fd, int events, int timeout )
+rc_t CC KSocketTimedRead ( const KSocket *self,
+ void *buffer, size_t bsize, size_t *num_read, timeout_t *tm )
{
- int i;
- struct pollfd fds [ 1 ];
-
- /* poll for data with no delay */
- for ( i = 0; i < 2; ++ i )
+ int revents;
+
+ assert ( self != NULL );
+ assert ( num_read != NULL );
+
+ pLogLibMsg(klogInfo, "$(b): KSocketTimedRead($(s), $(t))...", "b=%p,s=%d,t=%d", self, bsize, tm == NULL ? -1 : tm -> mS);
+
+ /* wait for socket to become readable */
+ revents = socket_wait ( self -> fd
+ , POLLIN
+ | POLLRDNORM
+ | POLLRDBAND
+ | POLLPRI
+ | POLLRDHUP
+ , tm );
+
+ /* check for error */
+ if ( revents < 0 || ( revents & ( POLLERR | POLLNVAL ) ) != 0 )
{
- fds [ 0 ] . fd = fd;
- fds [ 0 ] . events = events;
- fds [ 0 ] . revents = 0;
-
- if ( poll ( fds, sizeof fds / sizeof fds [ 0 ], 0 ) != 0 )
- return fds [ 0 ] . revents;
+ if ( errno != 0 )
+ {
+ rc_t rc = HandleErrno ( __func__, __LINE__ );
+ pLogLibMsg(klogInfo, "$(b): KSocketTimedRead socket_wait "
+ "returned errno $(e)", "b=%p,e=%d", self, errno);
+ return rc;
+ }
+
+ if ((revents & POLLERR) != 0) {
+ int optval = 0;
+ socklen_t optlen = sizeof optval;
+ if ((getsockopt(self->fd, SOL_SOCKET, SO_ERROR, &optval, &optlen)
+ == 0)
+ && optval > 0)
+ {
+ errno = optval;
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+"@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@1 %s getsockopt = %s @@@@@@@@@@@@@@@@"
+ "\n", __FILE__, strerror(optval)));
+ rc_t rc = HandleErrno(__func__, __LINE__);
+ pLogLibMsg(klogInfo, "$(b): KSocketTimedRead "
+ "socket_wait/getsockopt returned errno $(e)",
+ "b=%p,e=%d", self, errno);
+ return rc;
+ }
+ }
+
+ pLogLibMsg(klogInfo, "$(b): KSocketTimedRead socket_wait "
+ "returned POLLERR | POLLNVAL", "b=%p", self);
+ return RC ( rcNS, rcStream, rcReading, rcNoObj, rcUnknown );
}
-
- /* poll for data */
- if ( timeout != 0 )
+
+ /* check for read availability */
+ if ( ( revents & ( POLLRDNORM | POLLRDBAND ) ) != 0 )
{
- fds [ 0 ] . fd = fd;
- fds [ 0 ] . events = events;
- fds [ 0 ] . revents = 0;
-
- if ( poll ( fds, sizeof fds / sizeof fds [ 0 ], timeout ) != 0 )
+ ssize_t count = recv ( self -> fd, buffer, bsize, 0 );
+ if ( count >= 0 )
{
- /* experiment - try another poll with no timeout */
- fds [ 0 ] . fd = fd;
- fds [ 0 ] . events = events;
- fds [ 0 ] . revents = 0;
- poll ( fds, sizeof fds / sizeof fds [ 0 ], 0 );
-
- return fds [ 0 ] . revents;
+ * num_read = count;
+ return 0;
}
+ rc_t rc = HandleErrno ( __func__, __LINE__ );
+ pLogLibMsg(klogInfo, "$(b): KSocketTimedRead recv returned count $(c)", "b=%p,c=%d", self, count);
+ return rc;
}
-
- return 0;
+
+ /* check for broken connection */
+ if ( ( revents & ( POLLHUP | POLLRDHUP ) ) != 0 )
+ {
+ pLogLibMsg(klogInfo, "$(b): KSocketTimedRead broken connection", "b=%p", self);
+ * num_read = 0;
+ return 0;
+ }
+
+ /* anything else in revents is an error */
+ if ( ( revents & ~ POLLIN ) != 0 && errno != 0 )
+ {
+ rc_t rc = HandleErrno ( __func__, __LINE__ );
+ pLogLibMsg(klogInfo, "$(b): KSocketTimedRead error=$(e)", "b=%p,e=%e", self, errno);
+ return rc;
+ }
+
+ /* finally, call this a timeout */
+ pLogLibMsg(klogInfo, "$(b): KSocketTimedRead timeout", "b=%p", self);
+ return RC ( rcNS, rcStream, rcReading, rcTimeout, rcExhausted );
}
static
rc_t CC KSocketRead ( const KSocket *self,
void *buffer, size_t bsize, size_t *num_read )
{
- rc_t rc = 0;
- int timeout = 1000;
-
- size_t total = 0;
- char *b = buffer;
-
+ timeout_t tm;
assert ( self != NULL );
- while ( 1 )
- {
- ssize_t count = 0;
-
- /* wait for socket to become readable */
- int revents = socket_wait ( self -> fd, POLLIN | POLLPRI | POLLRDNORM | POLLRDBAND, timeout );
- if ( revents != 0 )
- count = recv ( self -> fd, & b [ total ], bsize - total, 0 );
- if ( count <= 0 )
- {
- if ( total != 0 || count == 0 )
- {
- assert ( num_read != NULL );
- * num_read = total;
- return 0;
- }
-
- if ( errno != EAGAIN )
- {
- rc = HandleErrno ( __func__, __LINE__ );
- if ( rc != 0 )
- break;
- }
- }
- else
- {
- total += count;
- timeout = 0;
- }
- }
-
- return rc;
+ if ( self -> read_timeout < 0 )
+ return KSocketTimedRead ( self, buffer, bsize, num_read, NULL );
+
+ TimeoutInit ( & tm, self -> read_timeout );
+ return KSocketTimedRead ( self, buffer, bsize, num_read, & tm );
}
static
-rc_t CC KSocketWrite ( KSocket *self,
- const void *buffer, size_t bsize, size_t *num_writ )
+rc_t CC KSocketTimedWrite ( KSocket *self,
+ const void *buffer, size_t bsize, size_t *num_writ, timeout_t *tm )
{
- rc_t rc = 0;
+ int revents;
+ ssize_t count;
+
assert ( self != NULL );
+ assert ( num_writ != NULL );
+
+ pLogLibMsg(klogInfo, "$(b): KSocketTimedWrite($(s), $(t))...", "b=%p,s=%d,t=%d", self, bsize, tm == NULL ? -1 : tm -> mS);
- while ( rc == 0 )
+ /* wait for socket to become writable */
+ revents = socket_wait ( self -> fd
+ , POLLOUT
+ | POLLWRNORM
+ | POLLWRBAND
+ , tm );
+
+ /* check for error */
+ if ( revents < 0 || ( revents & ( POLLERR | POLLNVAL ) ) != 0 )
{
- ssize_t count;
-
- /* wait for socket to become writable */
- socket_wait ( self -> fd, POLLOUT | POLLWRNORM | POLLWRBAND, 1000 );
+ if ( errno != 0 )
+ {
+ rc_t rc = HandleErrno ( __func__, __LINE__ );
+ pLogLibMsg(klogInfo, "$(b): KSocketTimedWrite socket_wait returned errno $(e)", "b=%p,e=%d", self, errno);
+ return rc;
+ }
+ pLogLibMsg(klogInfo, "$(b): KSocketTimedWrite socket_wait returned POLLERR | POLLNVAL", "b=%p", self);
+ return RC ( rcNS, rcStream, rcWriting, rcNoObj, rcUnknown );
+ }
+
+ /* check for broken connection */
+ if ( ( revents & POLLHUP ) != 0 )
+ {
+ pLogLibMsg(klogInfo, "$(b): POLLHUP received", "b=%p", self);
+ * num_writ = 0;
+ return 0;
+ }
+ /* check for ability to send */
+ if ( ( revents & ( POLLWRNORM | POLLWRBAND ) ) != 0 )
+ {
+ rc_t rc = 0;
count = send ( self -> fd, buffer, bsize, 0 );
if ( count >= 0 )
{
- assert ( num_writ != NULL );
+ pLogLibMsg(klogInfo, "$(b): $(s) bytes written", "b=%p,s=%d", self, count);
* num_writ = count;
return 0;
}
-
+
rc = HandleErrno ( __func__, __LINE__ );
+ pLogLibMsg(klogInfo, "$(b): KSocketTimedWrite recv returned count $(c)", "b=%p,c=%d", self, count);
+ return rc;
}
- return rc;
+ /* anything else in revents is an error */
+ if ( ( revents & ~ POLLOUT ) != 0 && errno != 0 )
+ {
+ rc_t rc = HandleErrno ( __func__, __LINE__ );
+ pLogLibMsg(klogInfo, "$(b): KSocketTimedWrite error=$(e)", "b=%p,e=%e", self, errno);
+ return rc;
+ }
+
+ /* finally, call this a timeout */
+ pLogLibMsg(klogInfo, "$(b): KSocketTimedWrite timeout", "b=%p", self);
+ return RC ( rcNS, rcStream, rcWriting, rcTimeout, rcExhausted );
+}
+
+static
+rc_t CC KSocketWrite ( KSocket *self,
+ const void *buffer, size_t bsize, size_t *num_writ )
+{
+ timeout_t tm;
+ assert ( self != NULL );
+
+ if ( self -> write_timeout < 0 )
+ return KSocketTimedWrite ( self, buffer, bsize, num_writ, NULL );
+
+ TimeoutInit ( & tm, self -> write_timeout );
+ return KSocketTimedWrite ( self, buffer, bsize, num_writ, & tm );
}
static KStream_vt_v1 vtKSocket =
{
- 1, 0,
+ 1, 1,
KSocketWhack,
KSocketRead,
- KSocketWrite
+ KSocketWrite,
+ KSocketTimedRead,
+ KSocketTimedWrite
};
static
-rc_t MakeSocketPath(const char* name, char* buf, size_t buf_size)
+rc_t KSocketMakePath ( const char * name, char * buf, size_t buf_size )
{
size_t num_writ;
- /*struct passwd* pwd;
- pwd = getpwuid(geteuid());
- if (pwd == NULL)
- return HandleErrno();
- return string_printf(buf, buf_size, &num_writ, "%s/.ncbi/%s", pwd->pw_dir, name);*/
- return string_printf(buf, buf_size, &num_writ, "%s/.ncbi/%s", getenv("HOME"), name);
+#if 0
+ struct passwd* pwd;
+ pwd = getpwuid ( geteuid () );
+ if ( pwd == NULL )
+ return HandleErrno ( __func__, __LINE__ );
+
+ return string_printf ( buf, buf_size, & num_writ, "%s/.ncbi/%s", pwd -> pw_dir, name );
+#else
+ const char *HOME = getenv ( "HOME" );
+ if ( HOME == NULL )
+ return RC ( rcNS, rcProcess, rcAccessing, rcPath, rcNotFound );
+
+ return string_printf ( buf, buf_size, & num_writ, "%s/.ncbi/%s", HOME, name );
+#endif
}
-LIB_EXPORT
-rc_t CC KNSManagerMakeConnection ( struct KNSManager const * self,KStream **out, const KEndPoint *from, const KEndPoint *to )
+static
+rc_t KSocketConnectIPv4 ( KSocket *self, int32_t retryTimeout, const KEndPoint *from, const KEndPoint *to )
{
- rc_t rc;
- int fd;
+ rc_t rc = 0;
+ uint32_t retry_count = 0;
+ struct sockaddr_in ss_from, ss_to;
- if ( self == NULL )
- return RC ( rcNS, rcStream, rcConstructing, rcSelf, rcNull );
-
- if ( out == NULL )
- return RC ( rcNS, rcStream, rcConstructing, rcParam, rcNull );
+ memset ( & ss_from, 0, sizeof ss_from );
+ if ( from != NULL )
+ {
+ ss_from . sin_family = AF_INET;
+ ss_from . sin_addr . s_addr = htonl ( from -> u . ipv4 . addr );
+ ss_from . sin_port = htons ( from -> u . ipv4 . port );
+ }
- * out = NULL;
+ memset ( & ss_to, 0, sizeof ss_to );
+ ss_to . sin_family = AF_INET;
+ ss_to . sin_addr . s_addr = htonl ( to -> u . ipv4 . addr );
+ ss_to . sin_port = htons ( to -> u . ipv4 . port );
+
+ do
+ {
+ /* create the OS socket */
+ self -> fd = socket ( AF_INET, SOCK_STREAM, 0 );
+ if ( self -> fd < 0 )
+ rc = HandleErrno ( __func__, __LINE__ );
+ else
+ {
+ /* disable nagle algorithm */
+ int flag = 1;
+ setsockopt ( self -> fd, IPPROTO_TCP, TCP_NODELAY, ( char* ) & flag, sizeof flag );
- if ( to == NULL )
- return RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcNull);
+ /* bind */
+ if ( from != NULL && bind ( self -> fd, ( struct sockaddr* ) & ss_from, sizeof ss_from ) != 0 )
+ rc = HandleErrno ( __func__, __LINE__ );
+
+ if ( rc == 0 )
+ {
+ /* connect */
+ if ( connect ( self -> fd, ( struct sockaddr* ) & ss_to, sizeof ss_to ) == 0 )
+ {
+ /* set non-blocking mode */
+ flag = fcntl ( self -> fd, F_GETFL );
+ fcntl ( self -> fd, F_SETFL, flag | O_NONBLOCK );
+ return 0;
+ }
+ rc = HandleErrno ( __func__, __LINE__ );
+ }
- if ( (from != NULL && from->type != epIPV4) || to->type != epIPV4 )
- return RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcInvalid);
+ /* dump socket */
+ close ( self -> fd );
+ self -> fd = -1;
+ }
- /* create the OS socket */
- fd = socket ( AF_INET, SOCK_STREAM, 0 );
- if ( fd != -1 )
+ /* rc != 0 */
+ if (retryTimeout < 0 || retry_count < retryTimeout)
+ { /* retry */
+ sleep ( 1 );
+ ++retry_count;
+ rc = 0;
+ }
+ }
+ while (rc == 0);
+
+ pLogLibMsg(klogInfo, "$(b): KSocketConnectIPv4 timed out", "b=%p", self);
+
+ return rc;
+}
+
+static
+rc_t KSocketConnectIPC ( KSocket *self, int32_t retryTimeout, const KEndPoint *to )
+{
+ rc_t rc = 0;
+ uint32_t retry_count = 0;
+ struct sockaddr_un ss_to;
+
+ memset ( & ss_to, 0, sizeof ss_to );
+ ss_to . sun_family = AF_UNIX;
+ rc = KSocketMakePath ( to -> u . ipc_name, ss_to . sun_path, sizeof ss_to . sun_path );
+
+ do
{
- int flag;
- struct sockaddr_in ss;
- memset ( &ss, 0, sizeof ss );
- ss . sin_family = AF_INET;
- if ( from != NULL )
+ /* create the OS socket */
+ self -> fd = socket ( AF_UNIX, SOCK_STREAM, 0 );
+ if ( self -> fd < 0 )
+ rc = HandleErrno ( __func__, __LINE__ );
+ else
{
- ss . sin_port = htons ( from -> u . ipv4 . port );
- ss . sin_addr . s_addr = htonl ( from -> u . ipv4 . addr );
+ /* connect */
+ if ( connect ( self -> fd, ( struct sockaddr* ) & ss_to, sizeof ss_to ) == 0 )
+ {
+ return 0;
+ }
+ rc = HandleErrno ( __func__, __LINE__ );
+
+ /* dump socket */
+ close ( self -> fd );
+ self -> fd = -1;
}
- /* disable nagle algorithm */
- flag = 1;
- setsockopt ( fd, IPPROTO_TCP, TCP_NODELAY, ( char* ) & flag, sizeof flag );
-
-
- if ( from == NULL || bind ( fd, ( struct sockaddr *) & ss, sizeof ss ) == 0)
+ /* rc != 0 */
+ if (retryTimeout < 0 || retry_count < retryTimeout)
+ { /* retry */
+ sleep ( 1 );
+ ++retry_count;
+ rc = 0;
+ }
+ }
+ while (rc == 0);
+
+ pLogLibMsg(klogInfo, "$(b): KSocketConnectIPC timed out", "b=%p", self);
+
+ return rc;
+ }
+
+KNS_EXTERN rc_t CC KNSManagerMakeRetryTimedConnection ( struct KNSManager const * self,
+ struct KStream **out, int32_t retryTimeout, int32_t readMillis, int32_t writeMillis,
+ struct KEndPoint const *from, struct KEndPoint const *to )
+{
+ rc_t rc;
+
+ if ( out == NULL )
+ rc = RC ( rcNS, rcStream, rcConstructing, rcParam, rcNull );
+ else
+ {
+ if ( self == NULL )
+ rc = RC ( rcNS, rcStream, rcConstructing, rcSelf, rcNull );
+ else if ( to == NULL )
+ rc = RC ( rcNS, rcStream, rcConstructing, rcParam, rcNull );
+ else if ( from != NULL && from -> type != to -> type )
+ rc = RC ( rcNS, rcStream, rcConstructing, rcParam, rcIncorrect );
+ else
{
- memset ( & ss, 0, sizeof ss );
- ss . sin_family = AF_INET;
- ss . sin_port = htons ( to -> u . ipv4 . port );
- ss . sin_addr . s_addr = htonl ( to -> u . ipv4 . addr );
- if ( connect ( fd, (struct sockaddr *)&ss, sizeof ss ) == 0 )
+ KSocket *conn = calloc ( 1, sizeof * conn );
+ if ( conn == NULL )
+ rc = RC ( rcNS, rcStream, rcConstructing, rcMemory, rcExhausted );
+ else
{
- /* create the KSocket */
- KSocket *ksock = calloc ( sizeof *ksock, 1 );
- if ( ksock == NULL )
- rc = RC ( rcNS, rcNoTarg, rcAllocating, rcNoObj, rcNull );
- else
+ conn -> fd = -1;
+ conn -> read_timeout = readMillis;
+ conn -> write_timeout = writeMillis;
+
+ rc = KStreamInit ( & conn -> dad, ( const KStream_vt* ) & vtKSocket,
+ "KSocket", "", true, true );
+ if ( rc == 0 )
{
- /* initialize the KSocket */
- rc = KStreamInit ( & ksock -> dad, ( const KStream_vt* ) & vtKSocket,
- "KSocket", "tcp", true, true );
+ switch ( to -> type )
+ {
+ case epIPV4:
+ rc = KSocketConnectIPv4 ( conn, retryTimeout, from, to );
+ break;
+ case epIPC:
+ rc = KSocketConnectIPC ( conn, retryTimeout, to );
+ break;
+ default:
+ rc = RC ( rcNS, rcStream, rcConstructing, rcParam, rcIncorrect );
+ }
+
if ( rc == 0 )
{
- /* set non-blocking mode */
- flag = fcntl ( fd, F_GETFL );
- fcntl ( fd, F_SETFL, flag | O_NONBLOCK );
-
- ksock -> fd = fd;
- *out = & ksock -> dad;
+ * out = & conn -> dad;
return 0;
}
- /* free the KSocket */
- free ( ksock );
}
+
+ free ( conn );
}
- else /* connect() failed */
- rc = HandleErrno( __func__, __LINE__ );
}
- else /* bind() failed */
- rc = HandleErrno( __func__, __LINE__ );
- close(fd);
+
+ * out = NULL;
}
- else /* socket() failed */
- rc = HandleErrno( __func__, __LINE__ );
+
return rc;
}
-LIB_EXPORT
-rc_t CC KNSManagerMakeIPCConnection ( struct KNSManager const *self, KStream **out, const KEndPoint *to, uint32_t max_retries )
+static
+rc_t KNSManagerMakeIPv4Listener ( KSocket *listener, const KEndPoint * ep )
{
rc_t rc;
- uint32_t retry_count = 0;
- struct sockaddr_un ss;
- if ( self == NULL )
- return RC ( rcNS, rcStream, rcConstructing, rcSelf, rcNull );
-
- if ( out == NULL )
- return RC ( rcNS, rcStream, rcConstructing, rcParam, rcNull );
+ listener -> fd = socket ( AF_INET, SOCK_STREAM, 0 );
+ if ( listener -> fd < 0 )
+ rc = HandleErrno ( __func__, __LINE__ );
+ else
+ {
+ struct sockaddr_in ss;
+
+ int on = 1;
+ setsockopt ( listener -> fd, SOL_SOCKET, SO_REUSEADDR, ( char* ) & on, sizeof on );
- * out = NULL;
+ memset ( & ss, 0, sizeof ss );
+ ss . sin_family = AF_INET;
+ ss . sin_addr . s_addr = htonl ( ep -> u . ipv4 . addr );
+ ss . sin_port = htons ( ep -> u . ipv4 . port );
+
+ if ( bind ( listener -> fd, ( struct sockaddr* ) & ss, sizeof ss ) == 0 )
+ return 0;
+ rc = HandleErrno ( __func__, __LINE__ );
+
+ close ( listener -> fd );
+ listener -> fd = -1;
+ }
- if ( to == NULL )
- return RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcNull);
+ return rc;
+}
- if ( to->type != epIPC )
- return RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcInvalid);
+static
+rc_t KNSManagerMakeIPCListener ( KSocket *listener, const KEndPoint * ep )
+{
+ rc_t rc;
- memset ( & ss, 0, sizeof ss );
- ss.sun_family = AF_UNIX;
- rc = MakeSocketPath(to->u.ipc_name, ss.sun_path, sizeof(ss.sun_path));
- /* create the OS socket */
- while (rc == 0)
+ listener -> fd = socket ( AF_UNIX, SOCK_STREAM, 0 );
+ if ( listener -> fd < 0 )
+ rc = HandleErrno ( __func__, __LINE__ );
+ else
{
- int fd = socket ( AF_UNIX, SOCK_STREAM, 0 );
- if ( fd != -1 )
+ struct sockaddr_un ss;
+ memset ( & ss, 0, sizeof ss );
+ ss.sun_family = AF_UNIX;
+ rc = KSocketMakePath ( ep -> u. ipc_name, ss . sun_path, sizeof ss . sun_path );
+ if ( rc == 0 )
{
- if ( connect ( fd, (struct sockaddr *)&ss, sizeof(ss) ) == 0 )
- { /* create the KSocket */
- KSocket *ksock = calloc ( sizeof *ksock, 1 );
- if ( ksock == NULL )
- rc = RC ( rcNS, rcNoTarg, rcAllocating, rcNoObj, rcNull );
- else
- { /* initialize the KSocket */
- rc = KStreamInit ( & ksock -> dad, ( const KStream_vt* ) & vtKSocket,
- "KSocket", "tcp", true, true );
- if ( rc == 0 )
- {
- ksock -> fd = fd;
- *out = & ksock -> dad;
- return 0;
- }
- free(ksock);
- }
- }
+ char * path = string_dup ( ss . sun_path, string_measure ( ss . sun_path, NULL ) );
+ if ( path == NULL )
+ rc = RC ( rcNS, rcSocket, rcConstructing, rcMemory, rcExhausted );
else
{
- rc = HandleErrno( __func__, __LINE__ );
- close(fd);
-
- if ( retry_count < max_retries &&
- (GetRCState(rc) == rcCanceled || GetRCState(rc) == rcNotFound) )
- {
- sleep(1);
- ++retry_count;
- rc = 0;
- continue;
+ unlink ( ss . sun_path );
+ if ( bind ( listener -> fd, ( struct sockaddr* ) & ss, sizeof ss ) != 0 )
+ rc = HandleErrno ( __func__, __LINE__ );
+ else
+ {
+ listener -> path = path;
+ return 0;
}
+
+ free ( path );
}
}
- else /* socket() failed */
- rc = HandleErrno( __func__, __LINE__ );
- break;
+
+ close ( listener -> fd );
+ listener -> fd = -1;
}
+
return rc;
}
-LIB_EXPORT
-rc_t CC KNSManagerMakeListener( struct KNSManager const *self, struct KSocket** out, struct KEndPoint const * ep )
+LIB_EXPORT rc_t CC KNSManagerMakeListener ( const KNSManager *self,
+ KSocket ** out, const KEndPoint * ep )
{
- int fd;
rc_t rc;
- if ( self == NULL )
- return RC ( rcNS, rcStream, rcConstructing, rcSelf, rcNull );
-
if ( out == NULL )
- return RC ( rcNS, rcStream, rcConstructing, rcParam, rcNull );
-
- * out = NULL;
-
- if ( ep == NULL )
- return RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcNull);
-
- if ( ep->type != epIPC )
- return RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcInvalid);
-
- /* create the OS socket */
- fd = socket ( AF_UNIX, SOCK_STREAM, 0 );
- if ( fd >= 0 )
+ rc = RC ( rcNS, rcSocket, rcConstructing, rcParam, rcNull );
+ else
{
- struct sockaddr_un ss;
- memset ( & ss, 0, sizeof ss );
- ss.sun_family = AF_UNIX;
- rc = MakeSocketPath(ep->u.ipc_name, ss.sun_path, sizeof(ss.sun_path));
- if (rc == 0)
+ if ( self == NULL )
+ rc = RC ( rcNS, rcSocket, rcConstructing, rcSelf, rcNull );
+ else if ( ep == NULL )
+ rc = RC ( rcNS, rcSocket, rcConstructing, rcParam, rcNull );
+ else
{
- unlink(ss.sun_path);
- if ( bind( fd,(struct sockaddr *)&ss, sizeof(ss) ) == 0 )
- { /* create the KSocket */
- KSocket *ksock = calloc ( sizeof *ksock, 1 );
- if ( ksock == NULL )
- rc = RC ( rcNS, rcNoTarg, rcAllocating, rcMemory, rcExhausted );
- else
+ KSocket *listener = calloc ( 1, sizeof * listener );
+ if ( listener == NULL )
+ rc = RC ( rcNS, rcSocket, rcConstructing, rcMemory, rcExhausted );
+ else
+ {
+ listener -> fd = -1;
+
+ /* pass these along to accepted sockets */
+ listener -> read_timeout = self -> conn_read_timeout;
+ listener -> write_timeout = self -> conn_write_timeout;
+
+ rc = KStreamInit ( & listener -> dad, ( const KStream_vt* ) & vtKSocket,
+ "KSocket", "", true, true );
+ if ( rc == 0 )
{
- char* path = string_dup(ss.sun_path, string_measure(ss.sun_path, NULL));
- if (path == NULL)
- rc = RC ( rcNS, rcNoTarg, rcAllocating, rcMemory, rcExhausted );
- else
- { /* initialize the KSocket */
- rc = KStreamInit ( & ksock -> dad, ( const KStream_vt* ) & vtKSocket,
- "KSocket", "tcp", true, true );
- if ( rc == 0 )
+ switch ( ep -> type )
+ {
+ case epIPV4:
+ rc = KNSManagerMakeIPv4Listener ( listener, ep );
+ break;
+ case epIPC:
+ rc = KNSManagerMakeIPCListener ( listener, ep );
+ break;
+ default:
+ rc = RC ( rcNS, rcSocket, rcConstructing, rcParam, rcIncorrect );
+ }
+
+ if ( rc == 0 )
+ {
+ /* the classic 5 connection queue... ? */
+ if ( listen ( listener -> fd, 5 ) == 0 )
{
- ksock -> fd = fd;
- ksock -> path = path;
- *out = ksock;
+ * out = listener;
return 0;
}
- free(path);
+
+ rc = HandleErrno ( __func__, __LINE__ );
+
+ if ( listener -> path != NULL )
+ free ( ( void* ) listener -> path );
}
- free(ksock);
- return rc;
}
+
+ free ( listener );
}
- else /* bind() failed */
- rc = HandleErrno( __func__, __LINE__ );
}
- close(fd);
+
+ * out = NULL;
}
- else /* socket() failed */
- rc = HandleErrno( __func__, __LINE__ );
-
+
return rc;
}
-LIB_EXPORT
-rc_t CC KSocketListen ( struct KSocket *listener, struct KStream **out )
+static
+rc_t KSocketAcceptIPv4 ( KSocket *self, KSocket *conn )
{
- rc_t rc;
-
- if ( listener == NULL )
- return RC ( rcNS, rcNoTarg, rcValidating, rcSelf, rcNull);
+ struct sockaddr_in remote;
+ socklen_t len = sizeof remote;
+ conn -> fd = accept ( self -> fd, ( struct sockaddr* ) & remote, & len );
+ if ( conn -> fd < 0 )
+ return HandleErrno ( __func__, __LINE__ );
+ if ( len > sizeof remote )
+ return RC ( rcNS, rcConnection, rcWaiting, rcBuffer, rcInsufficient );
+ return 0;
+}
- if ( out == NULL )
- return RC ( rcNS, rcStream, rcConstructing, rcParam, rcNull );
+static
+rc_t KSocketAcceptIPC ( KSocket *self, KSocket *conn )
+{
+ struct sockaddr_un remote;
+ socklen_t len = sizeof remote;
+ conn -> fd = accept ( self -> fd, ( struct sockaddr* ) & remote, & len );
+ if ( conn -> fd < 0 )
+ return HandleErrno ( __func__, __LINE__ );
+ if ( len > sizeof remote )
+ return RC ( rcNS, rcConnection, rcWaiting, rcBuffer, rcInsufficient );
+ return 0;
+}
- * out = NULL;
+LIB_EXPORT rc_t CC KSocketAccept ( KSocket *self, struct KStream **out )
+{
+ rc_t rc;
- if ( listen(listener->fd, 5) == 0)
+ if ( out == NULL )
+ rc = RC ( rcNS, rcConnection, rcWaiting, rcParam, rcNull );
+ else
{
- struct sockaddr_un remote;
- socklen_t t = sizeof(remote);
- int fd = accept(listener->fd, (struct sockaddr *)&remote, &t);
-
- if ( fd != -1)
+ if ( self == NULL )
+ rc = RC ( rcNS, rcConnection, rcWaiting, rcSelf, rcNull);
+ else
{
- KSocket *ksock = calloc ( sizeof *ksock, 1 );
- if ( ksock == NULL )
- rc = RC ( rcNS, rcNoTarg, rcAllocating, rcNoObj, rcNull );
+ KSocket * conn = calloc ( 1, sizeof * conn );
+ if ( conn == NULL )
+ rc = RC ( rcNS, rcConnection, rcWaiting, rcMemory, rcExhausted );
else
{
- rc = KStreamInit ( & ksock -> dad, ( const KStream_vt* ) & vtKSocket,
- "KSocket", "tcp", true, true );
+ conn -> fd = -1;
+ conn -> read_timeout = self -> read_timeout;
+ conn -> write_timeout = self -> write_timeout;
+
+ rc = KStreamInit ( & conn -> dad, ( const KStream_vt* ) & vtKSocket,
+ "KSocket", "", true, true );
if ( rc == 0 )
{
- ksock -> fd = fd;
- *out = &ksock->dad;
- return 0;
+ switch ( self -> type )
+ {
+ case epIPV4:
+ rc = KSocketAcceptIPv4 ( self, conn );
+ break;
+ case epIPC:
+ rc = KSocketAcceptIPC ( self, conn );
+ break;
+ default:
+ rc = RC ( rcNS, rcSocket, rcConstructing, rcSelf, rcCorrupt );
+ }
+
+ if ( rc == 0 )
+ {
+ * out = & conn -> dad;
+ return 0;
+ }
+
+ free ( conn );
}
- free(ksock);
}
- close(fd);
}
- else /* accept() failed */
- rc = HandleErrno( __func__, __LINE__ );
+
+ * out = NULL;
}
- else /* listen() failed */
- rc = HandleErrno( __func__, __LINE__ );
+
return rc;
-}
-
-
-
+}
diff --git a/libs/kns/win/sysmgr.c b/libs/kns/win/sysmgr.c
index 7d73945..67c59a4 100644
--- a/libs/kns/win/sysmgr.c
+++ b/libs/kns/win/sysmgr.c
@@ -23,35 +23,43 @@
* ===========================================================================
*
*/
-#include "kns_mgr_priv.h"
#include <klib/rc.h>
+#include <atomic32.h>
+
+#include "sysmgr.h"
#include <WINDOWS.H>
-rc_t KNSManagerInit ( struct KNSManager *self )
-{
- rc_t rc = 0;
- WSADATA wsaData;
+static atomic32_t mgr_count;
- if ( WSAStartup ( MAKEWORD ( 2, 2 ), &wsaData ) != 0 )
+rc_t KNSManagerInit ( void )
+{
+ if ( atomic32_test_and_inc ( & mgr_count ) )
{
- int lerrno;
- switch ( lerrno = WSAGetLastError () )
+ WSADATA wsaData;
+ if ( WSAStartup ( MAKEWORD ( 2, 2 ), & wsaData ) != 0 )
{
- case WSASYSNOTREADY:
- case WSAVERNOTSUPPORTED:
- case WSAEINPROGRESS:
- case WSAEPROCLIM:
- case WSAEFAULT:
- default:
- rc = RC ( rcNS, rcNoTarg, rcInitializing, rcNoObj, rcError );
+ int lerrno = WSAGetLastError ();
+ switch ( lerrno )
+ {
+ case WSASYSNOTREADY:
+ case WSAVERNOTSUPPORTED:
+ case WSAEINPROGRESS:
+ case WSAEPROCLIM:
+ case WSAEFAULT:
+ default:
+ atomic32_dec ( & mgr_count );
+ return RC ( rcNS, rcMgr, rcInitializing, rcLibrary, rcNotAvailable );
+ }
}
}
- return rc;
+
+ return 0;
}
-void KNSManagerCleanup ( struct KNSManager *self )
+void KNSManagerCleanup ( void )
{
- WSACleanup ();
+ if ( atomic32_dec_and_test ( & mgr_count ) )
+ WSACleanup ();
}
diff --git a/libs/kns/win/syssock.c b/libs/kns/win/syssock.c
index cc59a6d..d5ea566 100644
--- a/libs/kns/win/syssock.c
+++ b/libs/kns/win/syssock.c
@@ -41,31 +41,28 @@ typedef struct KSocket KSocket;
#include <klib/printf.h>
#include <klib/text.h>
#include <sysalloc.h>
+#include <kproc/timeout.h>
#include "../stream-priv.h"
+#include <sysalloc.h>
+
#include <stdlib.h>
#include <assert.h>
#include <string.h>
-#if 0
-#define _WINSOCKAPI_
-#define WIN32_LEAN_AND_MEAN
-
-#include <winsock2.h>
-#include <ws2tcpip.h>
-#endif
+#include <os-native.h>
#include <WINDOWS.H>
-#include <sysalloc.h>
-
+#define LOG
#define SHUT_RD 0
#define SHUT_WR 1
-typedef int ssize_t;
-
+typedef SSIZE_T ssize_t;
+static rc_t HandleErrnoEx ( const char *func, unsigned int lineno );
+#define HandleErrno() HandleErrnoEx ( __func__, __LINE__ )
/*--------------------------------------------------------------------------
* KSocket
@@ -80,67 +77,360 @@ typedef int ssize_t;
* target observed from a movable window. This means that a STREAM cannot be
* addressed randomly, whereas a FILE or OBJECT can.
*/
+
+ /*
+ * On Windows, we have 2 different mechanisms to implement KSockets,
+ * WinSock based for Ipv4 connections and named pipes based for IPC
+ */
+
struct KSocket
-{
+{ /* the "base type" for KIpv4Socket and PKIPCSocket */
KStream dad;
- union {
- SOCKET fd;
- wchar_t pipename[256];
- HANDLE pipe;
- } u;
- enum {isSocket, isIpcListener, isIpcPipeServer, isIpcPipeClient} type;
- HANDLE listenerPipe;
-};
-static rc_t HandleErrno();
+ int32_t read_timeout;
+ int32_t write_timeout;
+};
LIB_EXPORT rc_t CC KSocketAddRef( struct KSocket *self )
-{
+{ /* this will handle all derived types */
return KStreamAddRef(&self->dad);
}
LIB_EXPORT rc_t CC KSocketRelease( struct KSocket *self )
-{
+{ /* this will handle all derived types */
return KStreamRelease(&self->dad);
}
+/*
+ KIpv4Socket
+*/
+struct KIpv4Socket
+{
+ KSocket dad;
+ SOCKET fd;
+};
+typedef struct KIpv4Socket KIpv4Socket;
+
static
-rc_t CC KSocketWhack ( KSocket *self )
+rc_t CC KIpv4SocketWhack ( KSocket *base )
{
+ KIpv4Socket* self = (KIpv4Socket*)base;
rc_t rc = 0;
+
assert ( self != NULL );
- switch (self->type)
+ if (shutdown ( self -> fd, SHUT_WR ) != -1)
{
- case isSocket:
+ while ( 1 )
{
- if (shutdown ( self -> u . fd, SHUT_WR ) != -1)
+ char buffer [ 1024 ];
+ ssize_t result = recv ( self -> fd, buffer, sizeof buffer, 0 );
+ if ( result <= 0 )
+ break;
+ }
+ if (shutdown ( self -> fd, SHUT_RD ) != -1)
+ {
+ if ( closesocket ( self -> fd ) == SOCKET_ERROR )
+ rc = RC ( rcNS, rcNoTarg, rcClosing, rcNoObj, rcError );
+ /* maybe report */
+ }
+ else
+ rc = HandleErrno();
+ }
+ else
+ rc = HandleErrno();
+
+ free ( self );
+
+ return rc;
+}
+
+static
+rc_t CC KIpv4SocketTimedRead ( const KSocket *base,
+ void *buffer, size_t bsize, size_t *num_read, timeout_t *tm )
+{
+ rc_t rc = 0;
+
+ struct timeval ts;
+ fd_set readFds;
+ int selectRes;
+
+ KIpv4Socket* self = (KIpv4Socket*)base;
+ assert ( self != NULL );
+
+ /* convert timeout (relative time) */
+ if (tm != NULL)
+ {
+ ts.tv_sec = tm -> mS / 1000;
+ ts.tv_usec = (tm -> mS % 1000) * 1000;
+ }
+
+ /* wait for socket to become readable */
+ FD_ZERO(&readFds);
+ FD_SET(self -> fd, &readFds);
+ selectRes = select(0, &readFds, NULL, NULL, tm == NULL ? NULL : &ts);
+
+ /* check for error */
+ if (selectRes == -1)
+ {
+ rc = HandleErrno();
+ }
+ else if (selectRes == 0)
+ { /* timeout */
+ rc = RC ( rcNS, rcStream, rcWriting, rcTimeout, rcExhausted );
+ }
+ else if (FD_ISSET(self -> fd, &readFds))
+ {
+ while ( rc == 0 )
+ {
+ ssize_t count = recv ( self -> fd, buffer, (int)bsize, 0 );
+
+ if ( count >= 0 )
{
- while ( 1 )
- {
- char buffer [ 1024 ];
- ssize_t result = recv ( self -> u . fd, buffer, sizeof buffer, 0 );
- if ( result <= 0 )
- break;
- }
- if (shutdown ( self -> u . fd, SHUT_RD ) != -1)
- {
- if ( closesocket ( self -> u . fd ) == SOCKET_ERROR )
- rc = RC ( rcNS, rcNoTarg, rcClosing, rcNoObj, rcError );
- /* maybe report */
- }
- else
- rc = HandleErrno();
+ assert ( num_read != NULL );
+ * num_read = ( size_t ) count;
+ return 0;
}
- else
+ if (WSAGetLastError() != WSAEINTR)
rc = HandleErrno();
+ break;
}
- break;
+ }
+ else
+ {
+ rc = HandleErrno();
+ }
+
+ return rc;
+}
+
+static
+rc_t CC KIpv4SocketRead ( const KSocket *self,
+ void *buffer, size_t bsize, size_t *num_read )
+{
+ timeout_t tm;
+ assert ( self != NULL );
+
+ if ( self -> read_timeout < 0 )
+ return KIpv4SocketTimedRead ( self, buffer, bsize, num_read, NULL );
+
+ TimeoutInit ( & tm, self -> read_timeout );
+ return KIpv4SocketTimedRead ( self, buffer, bsize, num_read, & tm );
+}
+
+static
+rc_t CC KIpv4SocketTimedWrite ( KSocket *base,
+ const void *buffer, size_t bsize, size_t *num_writ, timeout_t *tm )
+{
+ rc_t rc = 0;
+
+ struct timeval ts;
+ fd_set writeFds;
+ int selectRes;
+
+ KIpv4Socket* self = (KIpv4Socket*)base;
+ assert ( self != NULL );
+
+ /* convert timeout (relative time) */
+ if (tm != NULL)
+ {
+ ts.tv_sec = tm -> mS / 1000;
+ ts.tv_usec = (tm -> mS % 1000) * 1000;
+ }
+
+ /* wait for socket to become writable */
+ FD_ZERO(&writeFds);
+ FD_SET(self -> fd, &writeFds);
+ selectRes = select(0, NULL, &writeFds, NULL, tm == NULL ? NULL : &ts);
+
+ /* check for error */
+ if (selectRes == -1)
+ {
+ rc = HandleErrno();
+ }
+ else if (selectRes == 0)
+ { /* timeout */
+ rc = RC ( rcNS, rcStream, rcWriting, rcTimeout, rcExhausted );
+ }
+ else if (FD_ISSET(self -> fd, &writeFds))
+ {
+ while ( rc == 0 )
+ {
+ ssize_t count = send ( self -> fd , buffer, (int)bsize, 0 );
+ if ( count >= 0 )
+ {
+ assert ( num_writ != NULL );
+ * num_writ = count;
+ return 0;
+ }
+ if (WSAGetLastError() != WSAEINTR)
+ rc = HandleErrno();
+
+ break;
+ }
+ }
+ else
+ {
+ rc = HandleErrno();
+ }
+
+ return rc;
+}
+
+static
+rc_t CC KIpv4SocketWrite ( KSocket *self,
+ const void *buffer, size_t bsize, size_t *num_writ )
+{
+ timeout_t tm;
+ assert ( self != NULL );
+
+ if ( self -> write_timeout < 0 )
+ return KIpv4SocketTimedWrite ( self, buffer, bsize, num_writ, NULL );
+
+ TimeoutInit ( & tm, self -> write_timeout );
+ return KIpv4SocketTimedWrite ( self, buffer, bsize, num_writ, & tm );
+}
+
+static KStream_vt_v1 vtKIpv4Socket =
+{
+ 1, 1,
+ KIpv4SocketWhack,
+ KIpv4SocketRead,
+ KIpv4SocketWrite,
+ KIpv4SocketTimedRead,
+ KIpv4SocketTimedWrite
+};
+
+static
+rc_t KNSManagerMakeIPv4Connection ( struct KNSManager const *self,
+ KStream **out,
+ const KEndPoint *from,
+ const KEndPoint *to,
+ int32_t retryTimeout,
+ int32_t readMillis,
+ int32_t writeMillis )
+{
+ rc_t rc = 0;
+ uint32_t retry_count = 0;
+ SOCKET fd;
+
+ assert ( self != NULL );
+ assert ( out != NULL );
+
+ * out = NULL;
+
+ assert ( to != NULL );
+ assert ( to -> type == epIPV4 );
+ assert ( ( from == NULL || from -> type == to -> type ) );
+
+ do
+ {
+ fd = socket ( AF_INET, SOCK_STREAM, IPPROTO_TCP );
+ if ( fd == INVALID_SOCKET )
+ rc = HandleErrno();
+ else
+ {
+ struct sockaddr_in ss;
+ memset ( & ss, 0, sizeof ss );
+ ss . sin_family = AF_INET;
+ if ( from != NULL )
+ {
+ ss . sin_port = htons ( from -> u. ipv4 . port );
+ ss . sin_addr . s_addr = htonl ( from -> u . ipv4 . addr );
+ }
+ if ( bind ( fd, (const struct sockaddr*)&ss, sizeof ss ) == SOCKET_ERROR )
+ rc = HandleErrno();
+
+ if (rc == 0)
+ {
+ ss . sin_port = htons ( to -> u . ipv4 . port );
+ ss . sin_addr . s_addr = htonl ( to -> u . ipv4 . addr );
+
+ if ( connect ( fd, (const struct sockaddr*)&ss, sizeof ss ) != SOCKET_ERROR )
+ { /* create the KSocket */
+ KIpv4Socket *ksock = calloc ( sizeof *ksock, 1 );
+ if ( ksock == NULL )
+ rc = RC ( rcNS, rcNoTarg, rcAllocating, rcNoObj, rcNull );
+ else
+ { /* initialize the KSocket */
+ rc = KStreamInit ( & ksock -> dad . dad, ( const KStream_vt* ) & vtKIpv4Socket,
+ "KSocket", "tcp", true, true );
+ if ( rc == 0 )
+ {
+ ksock -> dad . read_timeout = readMillis;
+ ksock -> dad . write_timeout = writeMillis;
+ ksock -> fd = fd;
+ *out = & ksock -> dad . dad;
+ return 0;
+ }
+ free(ksock);
+ }
+ /* we connected but then then ran out of memory or something bad like that, so no need to retry
+ - simply close fd and return RC */
+ closesocket(fd);
+ return rc;
+ }
+ else /* connect () failed */
+ rc = HandleErrno();
+ }
+
+ /* dump socket */
+ closesocket(fd);
+ }
+
+ /* rc != 0 */
+ if (retryTimeout < 0 || (int32_t)retry_count < retryTimeout)
+ { /* retry */
+ Sleep ( 1000 ); /*ms*/
+ ++retry_count;
+ rc = 0;
+ }
+ }
+ while (rc == 0);
+
+ return rc;
+}
+
+static rc_t KNSManagerMakeIPv4Listener ( const KNSManager *self, KSocket **out, const KEndPoint * ep )
+{ /* this is for server side which we do not support for IPv4 */
+ * out = NULL;
+ return RC ( rcNS, rcNoTarg, rcValidating, rcFunction, rcUnsupported);
+}
+
+/*
+ * KIPCSocket
+ */
+enum { isIpcListener, isIpcPipeServer, isIpcPipeClient };
+
+struct KIPCSocket
+{
+ KSocket dad;
+
+ HANDLE pipe;
+ wchar_t pipename [ 256 ];
+
+ uint8_t type;
+ HANDLE listenerPipe; /* only used iftype == isIpcListener */
+};
+typedef struct KIPCSocket KIPCSocket;
+
+static
+rc_t CC KIPCSocketWhack ( KSocket *base )
+{
+ rc_t rc = 0;
+
+ KIPCSocket* self = (KIPCSocket*)base;
+ assert ( self != NULL );
+ pLogLibMsg(klogInfo, "$(b): KIPCSocketWhack()...", "b=%p", base);
+
+ switch (self->type)
+ {
case isIpcListener: /* an unconnected server-side pipe */
+ pLogLibMsg(klogInfo, "$(b): isIpcListener", "b=%p", base);
if (self->listenerPipe != INVALID_HANDLE_VALUE)
{ /* !!! In case there is an active call to ConnectNamedPipe() on some thread, "wake" the synchronous named pipe,
otherwise DisconnectNamedPipe/CloseHandle will block forever */
- HANDLE hPipe = CreateFileW(self->u.pipename,
+ HANDLE hPipe = CreateFileW(self->pipename,
GENERIC_READ,
FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE,
NULL,
@@ -152,24 +442,46 @@ rc_t CC KSocketWhack ( KSocket *self )
/* now, Disconnect/Close the original pipe */
if (!DisconnectNamedPipe(self->listenerPipe) && rc == 0)
+ {
rc = HandleErrno();
+ pLogLibMsg(klogInfo, "$(b): DisconnectNamedPipe failed", "b=%p", base);
+ }
+
if (!CloseHandle(self->listenerPipe) && rc == 0)
+ {
rc = HandleErrno();
+ pLogLibMsg(klogInfo, "$(b): CloseHandle failed", "b=%p", base);
+ }
}
break;
case isIpcPipeServer:
+ pLogLibMsg(klogInfo, "$(b): isIpcPipeServer", "b=%p", base);
+ if (!FlushFileBuffers(self->pipe))
{
- if (!FlushFileBuffers(self->u.pipe))
- rc = HandleErrno();
- if (!DisconnectNamedPipe(self->u.pipe) && rc == 0)
- rc = HandleErrno();
- if (!CloseHandle(self->u.pipe) && rc == 0)
+ if (GetLastError() != ERROR_BROKEN_PIPE)
+ {
rc = HandleErrno();
+ pLogLibMsg(klogInfo, "$(b): FlushFileBuffers failed, err=$(e)", "b=%p,e=%d", base, GetLastError());
+ }
+ }
+ if (!DisconnectNamedPipe(self->pipe) && rc == 0)
+ {
+ rc = HandleErrno();
+ pLogLibMsg(klogInfo, "$(b): DisconnectNamedPipe failed", "b=%p", base);
+ }
+ if (!CloseHandle(self->pipe) && rc == 0)
+ {
+ rc = HandleErrno();
+ pLogLibMsg(klogInfo, "$(b): CloseHandle failed", "b=%p", base);
}
break;
case isIpcPipeClient:
- if (!CloseHandle(self->u.pipe))
+ pLogLibMsg(klogInfo, "$(b): isIpcPipeClient", "b=%p", base);
+ if (!CloseHandle(self->pipe))
+ {
rc = HandleErrno();
+ pLogLibMsg(klogInfo, "$(b): CloseHandle failed", "b=%p", base);
+ }
break;
}
@@ -179,309 +491,340 @@ rc_t CC KSocketWhack ( KSocket *self )
}
static
-rc_t HandleErrno()
-{
- int lerrno;
- rc_t rc;
-
- switch ( lerrno = WSAGetLastError() )
- {
- case ERROR_FILE_NOT_FOUND:
- rc = RC ( rcNS, rcNoTarg, rcReading, rcFile, rcNotFound);
- break;
- case ERROR_INVALID_HANDLE:
- rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcInvalid);
- break;
- case ERROR_INVALID_PARAMETER:
- rc = RC ( rcNS, rcNoTarg, rcReading, rcParam, rcInvalid);
- break;
- case ERROR_PIPE_BUSY:
- rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcCanceled );
- break;
- case WSAEACCES: /* write permission denied */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcMemory, rcUnauthorized );
- break;
- case WSAEADDRINUSE:/* address is already in use */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcMemory, rcExists );
- break;
- case WSAEADDRNOTAVAIL: /* requested address was not local */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcMemory, rcNotFound );
- break;
- case WSAEAFNOSUPPORT: /* address didnt have correct address family in ss_family field */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcName, rcError );
- break;
- case WSAEALREADY: /* socket is non blocking and a previous connection has not yet completed */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcUndefined );
- break;
- case WSAECONNABORTED: /* virtual circuit terminated. Application should close socket */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcInterrupted );
- break;
- case WSAECONNREFUSED: /* remote host refused to allow network connection */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcCanceled );
- break;
- case WSAECONNRESET: /* connection reset by peer */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcCanceled );
- break;
- case WSAEFAULT: /* name paremeter is not valid part of addr space */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcMemory, rcOutofrange );
- break;
- case WSAEHOSTUNREACH: /* remote hoste cannot be reached at this time */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcNotAvailable );
- break;
- case WSAEINPROGRESS: /* call is in progress */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcUndefined );
- break;
- case WSAEINVAL: /* invalid argument */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcParam, rcInvalid );
- break;
- case WSAEISCONN: /* connected already */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcExists );
- break;
- case WSAEMSGSIZE: /* msg size too big */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcMessage, rcExcessive );
- break;
- case WSAENETDOWN:/* network subsystem failed */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcNoObj, rcFailed );
- break;
- case WSAENETRESET: /* connection broken due to keep-alive activity that
- detected a failure while in progress */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcCanceled );
- break;
- case WSAENETUNREACH: /* network is unreachable */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcNotAvailable );
- break;
- case WSAENOBUFS: /* output queue for a network connection was full.
- ( wont typically happen in linux. Packets are just silently dropped */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcInterrupted );
- break;
- case ERROR_PIPE_NOT_CONNECTED:
- case WSAENOTCONN: /* socket is not connected */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcInvalid );
- break;
- case WSANOTINITIALISED: /* Must have WSAStartup call */
- rc = RC ( rcNS, rcNoTarg, rcInitializing, rcEnvironment, rcUndefined );
- break;
- case WSAENOTSOCK: /* sock fd is not a socket */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcInvalid );
- break;
- case WSAEOPNOTSUPP: /* socket is not stream-style such as SOCK_STREAM */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcUnsupported );
- break;
- case WSAEPROTONOSUPPORT: /* specified protocol is not supported */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcNoObj, rcError );
- break;
- case WSAEPROTOTYPE: /* wrong type of protol for this socket */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcUnsupported );
- break;
- case WSAEPROVIDERFAILEDINIT: /* service provider failed to initialize */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcNoObj, rcError );
- break;
- case WSAESHUTDOWN: /* socket had been shutdown */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcUnsupported );
- break;
- case WSAESOCKTNOSUPPORT: /* specifified socket type is not supported */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcUnsupported );
- break;
- case WSAETIMEDOUT: /* connection dropped because of network failure */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcCanceled );
- break;
- case WSAEWOULDBLOCK: /* socket is marked as non-blocking but the recv operation
- would block */
- rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcError );
- break;
-
- case WSAEINTR: /* call was canceled */
- case WSAEMFILE: /* no more socket fd available */
- default:
- rc = RC ( rcNS, rcNoTarg, rcReading, rcNoObj, rcError );
- PLOGERR (klogErr,
- (klogErr, rc, "unknown system error '$(S)($(E))'",
- "S=%!,E=%d", lerrno, lerrno));
- }
- return rc;
-}
-
-static
-rc_t CC KSocketRead ( const KSocket *self,
- void *buffer, size_t bsize, size_t *num_read )
-{
- rc_t rc = 0;
- assert ( self != NULL );
-
- while ( rc == 0 )
+rc_t
+WaitForData(const KIPCSocket* base, void* buffer, size_t bsize, size_t* num_read, uint32_t* tmMs, OVERLAPPED* overlap)
+{ /* received a ERROR_NO_DATA trying to read from a pipe; wait for the data to arrive or a time out to expire */
+ /* on success, will leave tmMs set to the remaining portion of timeout, if specified */
+ uint32_t tm_decrement = 100;
+ pLogLibMsg(klogInfo, "$(b): no data on the pipe - going into a wait loop, tm=$(t)", "b=%p,t=%d", base, tmMs == 0 ? -1 : *tmMs);
+ while (true)
{
- ssize_t count;
- if ( self -> type == isSocket)
- count = recv ( self -> u . fd, buffer, (int)bsize, 0 );
- else if (!ReadFile( self->u.pipe, buffer, (DWORD)bsize, &count, NULL))
- count = -1;
-
- if ( count >= 0 )
+ rc_t rc = 0;
+ BOOL ret;
+ DWORD count;
+
+ if (tmMs != NULL)
{
+ if (*tmMs <= tm_decrement)
+ {
+ CloseHandle(overlap->hEvent);
+ return RC ( rcNS, rcFile, rcReading, rcTimeout, rcExhausted );
+ }
+ *tmMs -= tm_decrement;
+ }
+ ret = ReadFile( base->pipe, buffer, (DWORD)bsize, &count, overlap ); /* *usually* returns FALSE in asynch mode */
+ if (ret)
+ {
+ pLogLibMsg(klogInfo, "$(b): (wait loop) ReadFile completed synchronously, count=$(c)", "b=%p,c=%d", base, count);
assert ( num_read != NULL );
* num_read = ( size_t ) count;
+ CloseHandle(overlap->hEvent);
return 0;
}
- if (WSAGetLastError() != WSAEINTR)
- rc = HandleErrno();
- break;
- }
+
+ switch (GetLastError())
+ {
+ case ERROR_IO_PENDING:
+ return 0; /* the caller will wait for completion */
- return rc;
+ case ERROR_NO_DATA:
+ pLogLibMsg(klogInfo, "$(b): (wait loop) Sleep($(t))", "b=%p,t=%d", base, tm_decrement);
+ Sleep(tm_decrement);
+ break;
+
+ case ERROR_SUCCESS: /* not expected in asynch mode */
+ return RC ( rcNS, rcFile, rcReading, rcError, rcUnexpected);
+
+ default:
+ return HandleErrno();
+ }
+ }
+ return 0;
}
static
-rc_t CC KSocketWrite ( KSocket *self,
- const void *buffer, size_t bsize, size_t *num_writ )
+rc_t CC KIPCSocketTimedRead ( const KSocket *base,
+ void *buffer, size_t bsize, size_t *num_read, timeout_t *tm )
{
rc_t rc = 0;
+ OVERLAPPED overlap;
+
+ KIPCSocket* self = (KIPCSocket*)base;
assert ( self != NULL );
+ assert ( num_read != NULL );
+
+ pLogLibMsg(klogInfo, "$(b): KIPCSocketTimedRead($(t), $(buf), $(s))... ", "b=%p,t=%d,buf=%p,s=%d", base, tm == NULL ? -1 : tm -> mS, buffer, bsize);
- while ( rc == 0 )
+ /*TODO: wait for pipe to become readable? */
+ memset(&overlap, 0, sizeof(overlap));
+ overlap.hEvent = CreateEvent(
+ NULL, /* default security attribute */
+ TRUE, /* manual reset event */
+ FALSE, /* initial state = nonsignalled */
+ NULL);
+ if (overlap.hEvent != NULL)
{
- ssize_t count;
- if ( self -> type == isSocket)
- count = send ( self -> u . fd, buffer, (int)bsize, 0 );
- else if (!WriteFile( self->u.pipe, buffer, (DWORD)bsize, &count, NULL))
- count = -1;
-
- if ( count >= 0 )
+ DWORD count;
+ BOOL ret = ReadFile( self->pipe, buffer, (DWORD)bsize, &count, &overlap ); /* *usually* returns FALSE in asynch mode */
+ if (ret) /* done: must be synch mode */
{
- assert ( num_writ != NULL );
- * num_writ = count;
+ pLogLibMsg(klogInfo, "$(b): ReadFile completed synchronously, count=$(c)", "b=%p,c=%d", base, count);
+ * num_read = ( size_t ) count;
+ CloseHandle(overlap.hEvent);
return 0;
}
- if (WSAGetLastError() != WSAEINTR)
- rc = HandleErrno();
+
+ *num_read = 0;
+ /* asynch mode - wait for the operation to complete */
+ if (GetLastError() == ERROR_NO_DATA) /* 232 */
+ {
+ pLogLibMsg(klogInfo, "$(b): ReadFile($(h)) returned FALSE, GetLastError() = ERROR_NO_DATA", "b=%p,h=%x", base, self->pipe);
+ rc = WaitForData(self, buffer, bsize, num_read, tm == NULL ? NULL : &tm -> mS, &overlap);
+ if (*num_read != 0) /* read completed*/
+ {
+ CloseHandle(overlap.hEvent);
+ return 0;
+ }
+ if (rc != 0)
+ {
+ CloseHandle(overlap.hEvent);
+ return rc;
+ }
+ }
- break;
+ if (GetLastError() == ERROR_IO_PENDING) /* 997 */
+ {
+ pLogLibMsg(klogInfo, "$(b): ReadFile($(h)) returned FALSE, GetLastError() = ERROR_IO_PENDING", "b=%p,h=%x", base, self->pipe);
+ if (tm == NULL)
+ pLogLibMsg(klogInfo, "$(b): waiting forever", "b=%p", base);
+ else
+ pLogLibMsg(klogInfo, "$(b): waiting for $(t) ms", "b=%p,t=%d", base, tm -> mS);
+
+ switch (WaitForSingleObject(overlap.hEvent, tm == NULL ? INFINITE : tm -> mS ))
+ {
+ case WAIT_TIMEOUT:
+ pLogLibMsg(klogInfo, "$(b): timed out", "b=%p", base);
+ rc = RC ( rcNS, rcFile, rcReading, rcTimeout, rcExhausted );
+ break;
+
+ case WAIT_OBJECT_0:
+ {
+ DWORD count;
+ pLogLibMsg(klogInfo, "$(b): successful", "b=%p", base);
+ if (GetOverlappedResult(self->pipe, &overlap, &count, TRUE)) /* wait to complete if necessary */
+ {
+ pLogLibMsg(klogInfo, "$(b): $(c) bytes read", "b=%p,c=%d", base, count);
+ * num_read = ( size_t ) count;
+ rc = 0;
+ }
+ else
+ {
+ rc = HandleErrno();
+ pLogLibMsg(klogInfo, "$(b): GetOverlappedResult() failed", "b=%p", base);
+ }
+ break;
+ }
+
+ default:
+ rc = HandleErrno();
+ pLogLibMsg(klogInfo, "$(b): WaitForSingleObject() failed", "b=%p", base);
+ break;
+ }
+ }
+ else if (GetLastError() == ERROR_SUCCESS)
+ {
+ pLogLibMsg(klogInfo, "$(b): ReadFile($(h)) returned FALSE, GetLastError() = ERROR_SUCCESS", "b=%p,h=%x", base, self->pipe);
+ rc = RC ( rcNS, rcFile, rcReading, rcError, rcUnexpected);
+ }
+ else
+ {
+ rc = HandleErrno();
+ }
+ CloseHandle(overlap.hEvent);
}
-
+ else
+ rc = HandleErrno();
+
return rc;
}
-static KStream_vt_v1 vtKSocket =
-{
- 1, 0,
- KSocketWhack,
- KSocketRead,
- KSocketWrite
-};
-
static
-rc_t KSocketBind ( KSocket *self, const struct sockaddr *ss, size_t addrlen )
+rc_t CC KIPCSocketRead ( const KSocket *self,
+ void *buffer, size_t bsize, size_t *num_read )
{
- rc_t rc = 0;
-
- if ( bind ( self -> u.fd, ss, (int)addrlen ) == SOCKET_ERROR )
- rc = HandleErrno();
+ timeout_t tm;
+ assert ( self != NULL );
- return rc;
-}
+ if ( self -> read_timeout < 0 )
+ return KIPCSocketTimedRead ( self, buffer, bsize, num_read, NULL );
+ TimeoutInit ( & tm, self -> read_timeout );
+ return KIPCSocketTimedRead ( self, buffer, bsize, num_read, & tm );
+}
static
-rc_t KSocketConnect ( KSocket *self, struct sockaddr *ss, size_t addrlen )
+rc_t CC KIPCSocketTimedWrite ( KSocket *base,
+ const void *buffer, size_t bsize, size_t *num_writ, timeout_t *tm )
{
rc_t rc = 0;
+ OVERLAPPED overlap;
- if ( connect ( self -> u . fd, ss, (int)addrlen ) == SOCKET_ERROR )
- rc = HandleErrno();
-
- return rc;
-}
-
-LIB_EXPORT
-rc_t CC KNSManagerMakeConnection ( struct KNSManager const *self, KStream **out, const KEndPoint *from, const KEndPoint *to )
-{
- rc_t rc;
- SOCKET fd;
-
- if ( self == NULL )
- return RC ( rcNS, rcStream, rcConstructing, rcSelf, rcNull );
-
- if ( out == NULL )
- return RC ( rcNS, rcStream, rcConstructing, rcParam, rcNull );
-
- * out = NULL;
-
- if ( to == NULL )
- return RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcNull);
-
- if ( (from != NULL && from->type != epIPV4) || to->type != epIPV4 )
- return RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcInvalid);
+ KIPCSocket* self = (KIPCSocket*)base;
+ assert ( self != NULL );
+
+ pLogLibMsg(klogInfo, "$(b): KIPCSocketTimedWrite($(s), $(t))...", "b=%p,s=%d,t=%d", base, bsize, tm == NULL ? -1 : tm -> mS);
- fd = socket ( AF_INET, SOCK_STREAM, IPPROTO_TCP );
- if ( fd != INVALID_SOCKET )
+ memset(&overlap, 0, sizeof(overlap));
+ overlap.hEvent = CreateEvent(
+ NULL, /* default security attribute */
+ TRUE, /* manual reset event */
+ FALSE, /* initial state = nonsignalled */
+ NULL);
+ if (overlap.hEvent != NULL)
{
- struct sockaddr_in ss;
- memset ( & ss, 0, sizeof ss );
- ss . sin_family = AF_INET;
- if ( from != NULL )
- {
- ss . sin_port = htons ( from -> u. ipv4 . port );
- ss . sin_addr . s_addr = htonl ( from -> u . ipv4 . addr );
- }
- if ( bind ( fd, (const struct sockaddr*)&ss, sizeof ss ) != SOCKET_ERROR )
- {
- ss . sin_port = htons ( to -> u . ipv4 . port );
- ss . sin_addr . s_addr = htonl ( to -> u . ipv4 . addr );
-
- if ( connect ( fd, (const struct sockaddr*)&ss, sizeof ss ) != SOCKET_ERROR )
- { /* create the KSocket */
- KSocket *ksock = calloc ( sizeof *ksock, 1 );
- if ( ksock == NULL )
- rc = RC ( rcNS, rcNoTarg, rcAllocating, rcNoObj, rcNull );
- else
+ DWORD count;
+ BOOL ret = WriteFile( self->pipe, buffer, (DWORD)bsize, &count, &overlap ); /* returns FALSE in asynch mode */
+ int err = GetLastError();
+ /*pLogLibMsg(klogInfo, "$(b): WriteFile returned $(r), GetError() = $(e)", "b=%p,r=%s,e=%d", base, ret ? "TRUE" : "FALSE", err); */
+ if (ret) /* completed synchronously; either message is so short that is went out immediately, or the pipe is full */
+ {
+ if (count > 0)
+ {
+ pLogLibMsg(klogInfo, "$(b): $(c) bytes written", "b=%p,c=%d", base, count);
+ assert ( num_writ != NULL );
+ * num_writ = ( size_t ) count;
+ CloseHandle(overlap.hEvent);
+ return 0;
+ }
+ else
+ { /* pipe is full - go into a wait loop */
+ uint32_t tm_left = tm == NULL ? 0 : tm -> mS;
+ uint32_t tm_decrement = 100;
+ pLogLibMsg(klogInfo, "$(b): pipe full - going into a wait loop for $(t) ms", "b=%p,t=%d", base, tm == NULL ? -1 : tm->mS);
+ while (count == 0)
{
- /* initialize the KSocket */
- rc = KStreamInit ( & ksock -> dad, ( const KStream_vt* ) & vtKSocket,
- "KSocket", "tcp", true, true );
- if ( rc == 0 )
+ if (tm != NULL)
{
- ksock -> type = isSocket;
- ksock -> u . fd = fd;
- *out = & ksock -> dad;
- return 0;
+ if (tm_left <= tm_decrement)
+ {
+ CloseHandle(overlap.hEvent);
+ return RC ( rcNS, rcFile, rcWriting, rcTimeout, rcExhausted );
+ }
+ tm_left -= tm_decrement;
}
- free(ksock);
+
+ Sleep(1);/*ms*/
+
+ pLogLibMsg(klogInfo, "$(b): write wait loop: attempting to WriteFile", "b=%p", base);
+ ret = WriteFile( self->pipe, buffer, (DWORD)bsize, &count, &overlap ); /* returns FALSE in asynch mode */
+ err = GetLastError();
+ /*pLogLibMsg(klogInfo, "$(b): WriteFile returned $(r), GetError() = $(e)", "b=%p,r=%s,e=%d", base, ret ? "TRUE" : "FALSE", err); */
+ if (!ret)
+ break; /* and proceed to handling the asynch mode*/
}
- return rc;
}
- else /* connect () failed */
+ }
+
+ /* asynch mode - wait for the operation to complete */
+ switch (err) /* set by the last call to WriteFile */
+ {
+ case NO_ERROR:
+ case ERROR_IO_PENDING:
+ {
+ switch (WaitForSingleObject(overlap.hEvent, tm == NULL ? INFINITE : tm -> mS ))
+ {
+ case WAIT_TIMEOUT:
+ pLogLibMsg(klogInfo, "$(b): timed out ", "b=%p", base);
+ CloseHandle(overlap.hEvent);
+ return RC ( rcNS, rcStream, rcWriting, rcTimeout, rcExhausted );
+
+ case WAIT_OBJECT_0:
+ {
+ pLogLibMsg(klogInfo, "$(b): successful", "b=%p", base);
+ if (GetOverlappedResult(self->pipe, &overlap, &count, TRUE)) /* wait to complete if necessary */
+ {
+ pLogLibMsg(klogInfo, "$(b): $(c) bytes written", "b=%p,c=%d", base, count);
+ assert ( num_writ != NULL );
+ * num_writ = count;
+ CloseHandle(overlap.hEvent);
+ return 0;
+ }
rc = HandleErrno();
+ pLogLibMsg(klogInfo, "$(b): GetOverlappedResult() failed", "b=%p", base);
+ break;
+ }
+
+ default:
+ rc = HandleErrno();
+ pLogLibMsg(klogInfo, "$(b): WaitForSingleObject() failed", "b=%p", base);
+ break;
+ }
}
- else /* bind() failed */
+ case ERROR_NO_DATA:
+ /* the secret MS lore says when WriteFile to a pipe returns ERROR_NO_DATA, it's
+ "Pipe was closed (normal exit path)." - see http://support.microsoft.com/kb/190351 */
+ CloseHandle(overlap.hEvent);
+ return 0;
+
+ default:
rc = HandleErrno();
- closesocket(fd);
+ pLogLibMsg(klogInfo, "$(b): WriteFile() failed", "b=%p", base);
+ break;
+ }
+
+ CloseHandle(overlap.hEvent);
}
- else /* socket() failed */
+ else
rc = HandleErrno();
+
return rc;
}
-LIB_EXPORT
-rc_t CC KNSManagerMakeIPCConnection ( struct KNSManager const *self, KStream **out, const KEndPoint *to, uint8_t max_retries )
+static
+rc_t CC KIPCSocketWrite ( KSocket *self,
+ const void *buffer, size_t bsize, size_t *num_writ )
+{
+ timeout_t tm;
+ assert ( self != NULL );
+
+ if ( self -> write_timeout < 0 )
+ return KIPCSocketTimedWrite ( self, buffer, bsize, num_writ, NULL );
+
+ TimeoutInit ( & tm, self -> write_timeout );
+ return KIPCSocketTimedWrite ( self, buffer, bsize, num_writ, & tm );
+}
+
+static KStream_vt_v1 vtKIPCSocket =
+{
+ 1, 1,
+ KIPCSocketWhack,
+ KIPCSocketRead,
+ KIPCSocketWrite,
+ KIPCSocketTimedRead,
+ KIPCSocketTimedWrite
+};
+
+static
+rc_t KNSManagerMakeIPCConnection ( struct KNSManager const *self,
+ KStream **out,
+ const KEndPoint *to,
+ int32_t retryTimeout,
+ int32_t readMillis,
+ int32_t writeMillis)
{
uint8_t retry_count = 0;
- rc_t rc;
+ rc_t rc = 0;
char pipename[256];
wchar_t pipenameW[256];
size_t num_writ;
- if ( self == NULL )
- return RC ( rcNS, rcStream, rcConstructing, rcSelf, rcNull );
-
- if ( out == NULL )
- return RC ( rcNS, rcStream, rcConstructing, rcParam, rcNull );
+ assert ( self != NULL );
+ assert ( out != NULL );
* out = NULL;
- if ( to == NULL )
- return RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcNull);
-
- if ( to->type != epIPC )
- return RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcInvalid);
+ assert ( to != NULL );
+ assert ( to->type == epIPC );
/* use named pipes to implement unix domain socket - like behavior */
rc = string_printf(pipename, sizeof(pipename), &num_writ, "\\\\.\\pipe\\%s", to->u.ipc_name);
@@ -496,31 +839,36 @@ rc_t CC KNSManagerMakeIPCConnection ( struct KNSManager const *self, KStream **o
0, /* no sharing */
NULL, /* default security attributes */
OPEN_EXISTING, /* opens existing pipe */
- 0, /* default attributes */
+ FILE_FLAG_OVERLAPPED, /* using overlapped IO */
NULL); /* no template file */
if ( h != INVALID_HANDLE_VALUE )
{ /* create the KSocket */
- KSocket* ksock;
-
- DWORD dwMode = PIPE_READMODE_MESSAGE;
+ DWORD dwMode = PIPE_READMODE_MESSAGE | PIPE_NOWAIT; /* need NOWAIT if pipe is created in asynch mode */
if (SetNamedPipeHandleState(
h, /* pipe handle */
&dwMode, /* new pipe mode */
NULL, /* don't set maximum bytes */
NULL)) /* don't set maximum time */
{
- ksock = calloc ( sizeof *ksock, 1 );
+ KIPCSocket* ksock = calloc ( sizeof *ksock, 1 );
+
if ( ksock == NULL )
rc = RC ( rcNS, rcNoTarg, rcAllocating, rcNoObj, rcNull );
else
- { /* initialize the KSocket */
- rc = KStreamInit ( & ksock -> dad, ( const KStream_vt* ) & vtKSocket,
+ {
+
+ /* initialize the KSocket */
+ rc = KStreamInit ( & ksock -> dad . dad, ( const KStream_vt* ) & vtKIPCSocket,
"KSocket", "tcp", true, true );
if ( rc == 0 )
{
+ pLogLibMsg(klogInfo, "$(b): KNSManagerMakeIPCConnection($(e),'$(n)')", "b=%p,e=%p,n=%s", ksock, to, pipename);
+
+ ksock -> dad . read_timeout = readMillis;
+ ksock -> dad . write_timeout = writeMillis;
ksock -> type = isIpcPipeClient;
- ksock -> u.pipe = h;
- *out = & ksock -> dad;
+ ksock -> pipe = h;
+ *out = & ksock -> dad . dad;
return 0;
}
free ( ksock );
@@ -529,32 +877,48 @@ rc_t CC KNSManagerMakeIPCConnection ( struct KNSManager const *self, KStream **o
else
rc = HandleErrno();
}
- else if (GetLastError() == ERROR_PIPE_BUSY)
+ else /* CreateFileW failed */
{
- if (!WaitNamedPipeW(pipenameW, NMPWAIT_USE_DEFAULT_WAIT))
- { // timeout, try again
- if ( retry_count < max_retries )
+ switch (GetLastError())
+ {
+ case ERROR_PIPE_BUSY:
+ LogLibMsg(klogInfo, "KNSManagerMakeIPCConnection: pipe busy, retrying");
+ {
+ BOOL pipeAvailable = WaitNamedPipeW(pipenameW, NMPWAIT_USE_DEFAULT_WAIT);
+ if (pipeAvailable)
+ {
+ LogLibMsg(klogInfo, "KNSManagerMakeIPCConnection: WaitNamedPipeW returned TRUE");
+ continue;
+ }
+ /* time-out, try again */
+ rc = HandleErrno();
+ LogLibMsg(klogInfo, "KNSManagerMakeIPCConnection: WaitNamedPipeW returned FALSE(timeout)");
+ if ( retryTimeout < 0 || retry_count < retryTimeout )
+ {
+ Sleep(1000); /*ms*/
+ ++retry_count;
+ rc = 0;
+ continue;
+ }
+ }
+ break;
+
+ case (ERROR_FILE_NOT_FOUND):
+ if ( retryTimeout < 0 || retry_count < retryTimeout )
{
- Sleep(1000);/*ms*/
+ LogLibMsg(klogInfo, "KNSManagerMakeIPCConnection: pipe not found, retrying");
+ Sleep(1000); /*ms*/
++retry_count;
- continue;
+ rc = 0;
+ continue;
}
+ else
+ rc = HandleErrno();
+ break;
+
+ default:
rc = HandleErrno();
- }
- else
- continue;
- }
- else /* CreateFile() failed */
- {
- rc = HandleErrno();
-
- if ( retry_count < max_retries &&
- (GetRCState(rc) == rcCanceled || GetRCState(rc) == rcNotFound) )
- {
- Sleep(1000);/*ms*/
- ++retry_count;
- rc = 0;
- continue;
+ break;
}
}
break;
@@ -562,25 +926,19 @@ rc_t CC KNSManagerMakeIPCConnection ( struct KNSManager const *self, KStream **o
return rc;
}
-LIB_EXPORT
-rc_t CC KNSManagerMakeListener( struct KNSManager const *self, struct KSocket** out, struct KEndPoint const * ep )
+static
+rc_t KNSManagerMakeIPCListener( struct KNSManager const *self, struct KSocket** out, struct KEndPoint const * ep )
{
rc_t rc = 0;
- KSocket* ksock;
+ KIPCSocket* ksock;
- if ( self == NULL )
- return RC ( rcNS, rcStream, rcConstructing, rcSelf, rcNull );
-
- if ( out == NULL )
- return RC ( rcNS, rcStream, rcConstructing, rcParam, rcNull );
+ assert ( self != NULL );
+ assert ( out != NULL );
* out = NULL;
- if ( ep == NULL )
- return RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcNull);
-
- if (ep->type != epIPC)
- return RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcInvalid);
+ assert ( ep != NULL );
+ assert (ep->type == epIPC);
/* use named pipes to implement unix domain socket - like behavior */
ksock = calloc ( sizeof *ksock, 1 );
@@ -588,7 +946,7 @@ rc_t CC KNSManagerMakeListener( struct KNSManager const *self, struct KSocket**
rc = RC ( rcNS, rcNoTarg, rcAllocating, rcNoObj, rcNull );
else
{
- rc = KStreamInit ( & ksock -> dad, ( const KStream_vt* ) & vtKSocket,
+ rc = KStreamInit ( & ksock -> dad . dad, ( const KStream_vt* ) & vtKIPCSocket,
"KSocket", "tcp", true, true );
if ( rc == 0 )
{
@@ -596,28 +954,35 @@ rc_t CC KNSManagerMakeListener( struct KNSManager const *self, struct KSocket**
char pipename[256];
rc = string_printf(pipename, sizeof(pipename), &num_writ, "\\\\.\\pipe\\%s", ep->u.ipc_name);
if (rc == 0)
- string_cvt_wchar_copy(ksock->u.pipename, sizeof(ksock->u.pipename), pipename, num_writ);
-
- if (rc == 0)
{
+ string_cvt_wchar_copy(ksock->pipename, sizeof(ksock->pipename), pipename, num_writ);
+
ksock -> type = isIpcListener;
ksock -> listenerPipe = INVALID_HANDLE_VALUE;
- *out = ksock;
+ *out = & ksock -> dad;
+
+ pLogLibMsg(klogInfo, "$(b): KNSManagerMakeIPCListener($(e),'$(n)')", "b=%p,e=%p,n=%s", ksock, ep, pipename);
return 0;
}
- KSocketWhack(ksock);
+ KIPCSocketWhack( & ksock -> dad );
}
else
free ( ksock );
}
+ pLogLibMsg(klogInfo, "$(b): KNSManagerMakeIPCListener failed", "b=%p", ksock);
return rc;
}
+/*
+ * Entry points
+*/
LIB_EXPORT
-rc_t CC KSocketListen ( struct KSocket *listener, struct KStream **out )
+rc_t CC KSocketAccept ( struct KSocket *listenerBase, struct KStream **out )
{
rc_t rc = 0;
+ KIPCSocket* listener = (KIPCSocket*)listenerBase;
+ pLogLibMsg(klogInfo, "$(b): KSocketAccept", "b=%p", listener);
if ( listener == NULL )
return RC ( rcNS, rcNoTarg, rcValidating, rcSelf, rcNull);
@@ -627,56 +992,305 @@ rc_t CC KSocketListen ( struct KSocket *listener, struct KStream **out )
* out = NULL;
- if (listener->type != isIpcListener)
+ /* make sure listener points to a KIPCSocket */
+ if (listener -> dad . dad . vt -> v1 . destroy != KIPCSocketWhack)
return RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcInvalid);
+ if (listener->type != isIpcListener)
+ return RC ( rcNS, rcNoTarg, rcValidating, rcParam, rcInvalid);
+
+ listener->listenerPipe = CreateNamedPipeW(listener->pipename, /* pipe name */
+ FILE_FLAG_OVERLAPPED | /* using overlapped IO */
+ PIPE_ACCESS_DUPLEX, /* read/write access */
+ PIPE_TYPE_MESSAGE | /* message type pipe */
+ PIPE_READMODE_MESSAGE | /* message-read mode */
+ PIPE_WAIT, /* blocking mode */
+ PIPE_UNLIMITED_INSTANCES,/* max. instances */
+ 1024, /* output buffer size */
+ 1024, /* input buffer size */
+ 0, /* client time-out */
+ NULL); /* default security attribute */
+ if ( listener->listenerPipe != INVALID_HANDLE_VALUE )
{
- listener->listenerPipe = CreateNamedPipeW(listener->u.pipename, /* pipe name */
- PIPE_ACCESS_DUPLEX, /* read/write access */
- PIPE_TYPE_MESSAGE | /* message type pipe */
- PIPE_READMODE_MESSAGE | /* message-read mode */
- PIPE_WAIT, /* blocking mode */
- PIPE_UNLIMITED_INSTANCES,/* max. instances */
- 1024, /* output buffer size */
- 1024, /* input buffer size */
- 0, /* client time-out */
- NULL); /* default security attribute */
- if ( listener->listenerPipe != INVALID_HANDLE_VALUE )
+ OVERLAPPED overlap;
+ LogLibMsg(klogInfo, "KSocketAccept: calling CreateEvent");
+ overlap.hEvent = CreateEvent(
+ NULL, /* default security attribute */
+ TRUE, /* manual reset event */
+ FALSE, /* initial state = nonsignalled */
+ NULL);
+ if (overlap.hEvent != NULL)
{
- while (1)
- {
- if ( ConnectNamedPipe(listener->listenerPipe, NULL) ||
- GetLastError() == ERROR_PIPE_CONNECTED) /* = a client happened to connect between CreateNamePipe and ConnectNamedPipe, we are good */
+ BOOL connected = ConnectNamedPipe(listener->listenerPipe, &overlap);
+ /*LogLibMsg(klogInfo, "KSocketAccept: calling ConnectNamedPipe");*/
+ if ( !connected ) /* normal for asynch mode */
+ {
+ switch (GetLastError())
{
- KSocket *ksock = calloc ( sizeof *ksock, 1 );
- if ( ksock == NULL )
- rc = RC ( rcNS, rcNoTarg, rcAllocating, rcNoObj, rcNull );
- else
+ case ERROR_PIPE_CONNECTED: /* client connected since the call to CreateNamedPipeW */
+ break;
+
+ case ERROR_IO_PENDING:
+ LogLibMsg(klogInfo, "KSocketAccept: calling WaitForSingleObject");
+ if (WaitForSingleObject(overlap.hEvent, INFINITE) != WAIT_OBJECT_0)
{
- rc = KStreamInit ( & ksock -> dad, ( const KStream_vt* ) & vtKSocket,
- "KSocket", "tcp", true, true );
- if ( rc == 0 )
- {
- ksock -> type = isIpcPipeServer;
- ksock -> u.pipe = listener->listenerPipe;
- listener->listenerPipe = INVALID_HANDLE_VALUE; /* this is only to be used while ConnectNamedPipe() is in progress */
- *out = & ksock -> dad;
- return 0;
- }
- free ( ksock );
+ rc = HandleErrno();
+ CloseHandle(overlap.hEvent);
+ LogLibMsg(klogInfo, "KSocketAccept: WaitForSingleObject failed");
+ return rc;
}
+ break;
+
+ default:
+ rc = HandleErrno();
+ CloseHandle(overlap.hEvent);
+ LogLibMsg(klogInfo, "KSocketAccept: ConnectNamedPipe failed");
+ return rc;
}
- else if (GetLastError() == ERROR_NO_DATA) /* no client */
- { /* keep on listening */
- Sleep(10); /*ms*/
+ }
+ /* we are connected, create the socket stream */
+ {
+ KIPCSocket *ksock = calloc ( sizeof *ksock, 1 );
+ pLogLibMsg(klogInfo, "$(b): KSocketAccept", "b=%p", ksock);
+
+ if ( ksock == NULL )
+ {
+ rc = RC ( rcNS, rcNoTarg, rcAllocating, rcNoObj, rcNull );
+ LogLibMsg(klogInfo, "KSocketAccept: calloc failed");
}
else
- break;
+ {
+ rc = KStreamInit ( & ksock -> dad . dad, ( const KStream_vt* ) & vtKIPCSocket,
+ "KSocket", "tcp", true, true );
+ if ( rc == 0 )
+ {
+ ksock -> type = isIpcPipeServer;
+ ksock -> pipe = listener->listenerPipe;
+ listener->listenerPipe = INVALID_HANDLE_VALUE; /* this is only to be used while ConnectNamedPipe() is in progress */
+ *out = & ksock -> dad . dad;
+ CloseHandle(overlap.hEvent);
+ return 0;
+ }
+ free ( ksock );
+ LogLibMsg(klogInfo, "KSocketAccept: KStreamInit failed");
+ }
+ CloseHandle(overlap.hEvent);
+ return rc;
}
}
}
- return HandleErrno();
+ else
+ {
+ rc = HandleErrno();
+ LogLibMsg(klogInfo, "KSocketAccept: CreateNamedPipeW failed");
+ }
+ return rc;
}
-
-
-
+
+LIB_EXPORT rc_t CC KNSManagerMakeRetryTimedConnection ( const KNSManager * self,
+ KStream **out, int32_t retryTimeout, int32_t readMillis, int32_t writeMillis,
+ const KEndPoint *from, const KEndPoint *to )
+{
+ rc_t rc;
+
+ if ( out == NULL )
+ rc = RC ( rcNS, rcStream, rcConstructing, rcParam, rcNull );
+ else
+ {
+ if ( self == NULL )
+ rc = RC ( rcNS, rcStream, rcConstructing, rcSelf, rcNull );
+ else if ( to == NULL )
+ rc = RC ( rcNS, rcStream, rcConstructing, rcParam, rcNull );
+ else if ( from != NULL && from -> type != to -> type )
+ rc = RC ( rcNS, rcStream, rcConstructing, rcParam, rcIncorrect );
+ else
+ {
+ switch ( to -> type )
+ {
+ case epIPV4:
+ rc = KNSManagerMakeIPv4Connection ( self, out, from, to, retryTimeout, readMillis, writeMillis );
+ break;
+ case epIPC:
+ rc = KNSManagerMakeIPCConnection ( self, out, to, retryTimeout, readMillis, writeMillis );
+ break;
+ default:
+ rc = RC ( rcNS, rcStream, rcConstructing, rcParam, rcIncorrect );
+ }
+
+ if ( rc == 0 )
+ return 0;
+ }
+
+ * out = NULL;
+ }
+
+ return rc;
+}
+
+LIB_EXPORT
+rc_t CC KNSManagerMakeListener( struct KNSManager const *self, struct KSocket** out, struct KEndPoint const * ep )
+{
+ rc_t rc;
+
+ if ( out == NULL )
+ rc = RC ( rcNS, rcSocket, rcConstructing, rcParam, rcNull );
+ else
+ {
+ if ( self == NULL )
+ rc = RC ( rcNS, rcSocket, rcConstructing, rcSelf, rcNull );
+ else if ( ep == NULL )
+ rc = RC ( rcNS, rcSocket, rcConstructing, rcParam, rcNull );
+ else
+ {
+ switch ( ep -> type )
+ {
+ case epIPV4:
+ rc = KNSManagerMakeIPv4Listener ( self, out, ep );
+ break;
+ case epIPC:
+ rc = KNSManagerMakeIPCListener ( self, out, ep );
+ break;
+ default:
+ rc = RC ( rcNS, rcSocket, rcConstructing, rcParam, rcIncorrect );
+ }
+
+ if ( rc == 0 )
+ return 0;
+ }
+
+ * out = NULL;
+ }
+
+ return rc;
+}
+
+/*
+ * Local helpers
+*/
+static
+rc_t HandleErrnoEx ( const char *func_name, unsigned int lineno )
+{
+ rc_t rc;
+ int lerrno = WSAGetLastError();
+
+ switch ( lerrno )
+ {
+ case ERROR_FILE_NOT_FOUND:
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcFile, rcNotFound);
+ break;
+ case ERROR_INVALID_HANDLE:
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcInvalid);
+ break;
+ case ERROR_INVALID_PARAMETER:
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcParam, rcInvalid);
+ break;
+ case ERROR_PIPE_BUSY:
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcCanceled );
+ break;
+ case ERROR_SEM_TIMEOUT:
+ rc = RC ( rcNS, rcStream, rcReading, rcTimeout, rcExhausted );
+ break;
+ case WSAEACCES: /* write permission denied */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcMemory, rcUnauthorized );
+ break;
+ case WSAEADDRINUSE:/* address is already in use */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcMemory, rcExists );
+ break;
+ case WSAEADDRNOTAVAIL: /* requested address was not local */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcMemory, rcNotFound );
+ break;
+ case WSAEAFNOSUPPORT: /* address didnt have correct address family in ss_family field */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcName, rcError );
+ break;
+ case WSAEALREADY: /* socket is non blocking and a previous connection has not yet completed */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcUndefined );
+ break;
+ case WSAECONNABORTED: /* virtual circuit terminated. Application should close socket */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcInterrupted );
+ break;
+ case WSAECONNREFUSED: /* remote host refused to allow network connection */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcCanceled );
+ break;
+ case WSAECONNRESET: /* connection reset by peer */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcCanceled );
+ break;
+ case WSAEFAULT: /* name paremeter is not valid part of addr space */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcMemory, rcOutofrange );
+ break;
+ case WSAEHOSTUNREACH: /* remote hoste cannot be reached at this time */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcNotAvailable );
+ break;
+ case WSAEINPROGRESS: /* call is in progress */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcUndefined );
+ break;
+ case WSAEINVAL: /* invalid argument */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcParam, rcInvalid );
+ break;
+ case WSAEISCONN: /* connected already */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcExists );
+ break;
+ case WSAEMSGSIZE: /* msg size too big */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcMessage, rcExcessive );
+ break;
+ case WSAENETDOWN:/* network subsystem failed */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcNoObj, rcFailed );
+ break;
+ case WSAENETRESET: /* connection broken due to keep-alive activity that
+ detected a failure while in progress */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcCanceled );
+ break;
+ case WSAENETUNREACH: /* network is unreachable */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcNotAvailable );
+ break;
+ case WSAENOBUFS: /* output queue for a network connection was full.
+ ( wont typically happen in linux. Packets are just silently dropped */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcInterrupted );
+ break;
+ case ERROR_PIPE_NOT_CONNECTED:
+ case WSAENOTCONN: /* socket is not connected */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcInvalid );
+ break;
+ case WSANOTINITIALISED: /* Must have WSAStartup call */
+ rc = RC ( rcNS, rcNoTarg, rcInitializing, rcEnvironment, rcUndefined );
+ break;
+ case WSAENOTSOCK: /* sock fd is not a socket */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcInvalid );
+ break;
+ case WSAEOPNOTSUPP: /* socket is not stream-style such as SOCK_STREAM */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcUnsupported );
+ break;
+ case WSAEPROTONOSUPPORT: /* specified protocol is not supported */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcNoObj, rcError );
+ break;
+ case WSAEPROTOTYPE: /* wrong type of protocol for this socket */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcUnsupported );
+ break;
+ case WSAEPROVIDERFAILEDINIT: /* service provider failed to initialize */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcNoObj, rcError );
+ break;
+ case ERROR_BROKEN_PIPE:
+ case WSAESHUTDOWN: /* socket had been shutdown */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcUnsupported );
+ break;
+ case WSAESOCKTNOSUPPORT: /* specified socket type is not supported */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcUnsupported );
+ break;
+ case WSAETIMEDOUT: /* connection dropped because of network failure */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcConnection, rcCanceled );
+ break;
+ case WSAEWOULDBLOCK: /* socket is marked as non-blocking but the recv operation
+ would block */
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcId, rcError );
+ break;
+
+ case WSAEINTR: /* call was cancelled */
+ case WSAEMFILE: /* no more socket fd available */
+ default:
+ rc = RC ( rcNS, rcNoTarg, rcReading, rcNoObj, rcError );
+ PLOGERR (klogErr,
+ (klogErr, rc, "unknown system error '$(S)($(E))', line=$(L)",
+ "S=%!,E=%d,L=%d", lerrno, lerrno, lineno));
+ }
+ return rc;
+}
+
diff --git a/libs/kproc/bsd/syslock-priv.h b/libs/kproc/bsd/syslock-priv.h
index e7542e5..438888f 100644
--- a/libs/kproc/bsd/syslock-priv.h
+++ b/libs/kproc/bsd/syslock-priv.h
@@ -44,11 +44,21 @@ extern "C" {
/*--------------------------------------------------------------------------
* KLock
* a POSIX-style mutual exclusion lock
- * with some facilities for timed operations
*/
struct KLock
{
pthread_mutex_t mutex;
+ atomic32_t refcount;
+};
+
+/*--------------------------------------------------------------------------
+ * KTimedLock
+ * a POSIX-style mutual exclusion lock
+ * with some facilities for timed operations
+ */
+struct KTimedLock
+{
+ pthread_mutex_t mutex;
pthread_mutex_t cond_lock;
pthread_cond_t cond;
uint32_t waiters;
diff --git a/libs/kproc/bsd/syslock.c b/libs/kproc/bsd/syslock.c
index 5cfada0..c28c81e 100644
--- a/libs/kproc/bsd/syslock.c
+++ b/libs/kproc/bsd/syslock.c
@@ -38,7 +38,6 @@
#include <stdlib.h>
#include <errno.h>
-
/*--------------------------------------------------------------------------
* pthread_mutex
*/
@@ -63,7 +62,10 @@ rc_t pthread_mutex_whack ( pthread_mutex_t *mutex )
static
rc_t pthread_mutex_acquire ( pthread_mutex_t *mutex )
{
+/* pthread_t t = pthread_self();
+ fprintf(stdout, "pthread_mutex_lock(%p), thread=%x\n", mutex, t);*/
int status = pthread_mutex_lock ( mutex );
+/*fprintf(stdout, "pthread_mutex_lock, thread=%x, status = %d\n", t, status);*/
switch ( status )
{
case 0:
@@ -79,9 +81,22 @@ rc_t pthread_mutex_acquire ( pthread_mutex_t *mutex )
}
static
+int pthread_mutex_tryacquire ( pthread_mutex_t *mutex )
+{
+/* pthread_t t = pthread_self();
+fprintf(stdout, "pthread_mutex_trylock(%p), thread=%x\n", mutex, t);*/
+ int status = pthread_mutex_trylock ( mutex );
+/*fprintf(stdout, "pthread_mutex_trylock, thread=%x, status = %d\n", t, status);*/
+ return status;
+}
+
+static
rc_t pthread_mutex_release ( pthread_mutex_t *mutex )
{
+/* pthread_t t = pthread_self();
+fprintf(stdout, "pthread_mutex_unlock(%p), thread=%x\n", mutex, t);*/
int status = pthread_mutex_unlock ( mutex );
+/*fprintf(stdout, "pthread_mutex_unlock, thread=%x, status = %d\n", t, status);*/
switch ( status )
{
case 0:
@@ -96,12 +111,34 @@ rc_t pthread_mutex_release ( pthread_mutex_t *mutex )
return 0;
}
-
/*--------------------------------------------------------------------------
- * pthread_cond
+ * pthread_condition
*/
static
-rc_t pthread_cond_whack ( pthread_cond_t *cond )
+rc_t pthread_condition_init ( pthread_cond_t *cond )
+ {
+ int status = pthread_cond_init ( cond, NULL );
+ switch ( status )
+ {
+ case 0:
+ break;
+ case EAGAIN:
+ return RC ( rcPS, rcCondition, rcConstructing, rcCondition, rcExhausted );
+ case ENOMEM:
+ return RC ( rcPS, rcCondition, rcConstructing, rcMemory, rcExhausted );
+ case EBUSY:
+ return RC ( rcPS, rcCondition, rcConstructing, rcCondition, rcBusy );
+ case EINVAL:
+ return RC ( rcPS, rcCondition, rcConstructing, rcCondition, rcInvalid );
+ default:
+ return RC ( rcPS, rcCondition, rcConstructing, rcNoObj, rcUnknown );
+ }
+
+ return 0;
+}
+
+static
+rc_t pthread_condition_whack ( pthread_cond_t *cond )
{
int status = pthread_cond_destroy ( cond );
switch ( status )
@@ -119,9 +156,13 @@ rc_t pthread_cond_whack ( pthread_cond_t *cond )
}
static
-rc_t pthread_cond_ping ( pthread_cond_t *cond )
+rc_t pthread_condition_wait ( pthread_cond_t *cond, pthread_mutex_t *mutex )
{
- int status = pthread_cond_signal ( cond );
+/* pthread_t t = pthread_self();
+fprintf(stdout, "pthread_cond_wait(%p, %p), thread=%x\n", cond, mutex, t);*/
+ int status = pthread_cond_wait( cond, mutex );
+/*fprintf(stdout, "pthread_cond_wait, thread=%x, status = %d\n", t, status);*/
+
switch ( status )
{
case 0:
@@ -132,6 +173,54 @@ rc_t pthread_cond_ping ( pthread_cond_t *cond )
return 0;
}
+static
+rc_t pthread_condition_timedwait ( pthread_cond_t *cond, pthread_mutex_t *mutex, struct timespec *ts )
+{
+ int status = pthread_cond_timedwait ( cond, mutex, ts );
+ switch ( status )
+ {
+ case 0:
+ break;
+ case ETIMEDOUT:
+ return RC ( rcPS, rcCondition, rcWaiting, rcTimeout, rcExhausted );
+ case EINTR:
+ return RC ( rcPS, rcCondition, rcWaiting, rcThread, rcInterrupted );
+ default:
+ return RC ( rcPS, rcCondition, rcWaiting, rcNoObj, rcUnknown );
+ }
+
+ return 0;
+}
+
+static
+rc_t pthread_condition_signal( pthread_cond_t *cond )
+{
+ int status = pthread_cond_signal ( cond );
+ switch ( status )
+ {
+ case 0:
+ break;
+ default:
+ return RC ( rcPS, rcCondition, rcSignaling, rcNoObj, rcUnknown );
+ }
+
+ return 0;
+}
+
+static
+rc_t pthread_condition_broadcast ( pthread_cond_t *cond )
+{
+ int status = pthread_cond_broadcast ( cond );
+ switch ( status )
+ {
+ case 0:
+ break;
+ default:
+ return RC ( rcPS, rcCondition, rcSignaling, rcNoObj, rcUnknown );
+ }
+
+ return 0;
+}
/*--------------------------------------------------------------------------
* KLock
@@ -143,11 +232,145 @@ rc_t pthread_cond_ping ( pthread_cond_t *cond )
static
rc_t KLockDestroy ( KLock *self )
{
+ return pthread_mutex_whack ( & self -> mutex );
+}
+
+/* Whack
+ */
+static
+rc_t KLockWhack ( KLock *self )
+{
+ rc_t rc = KLockDestroy ( self );
+ if ( rc == 0 )
+ free ( self );
+ return rc;
+}
+
+/* Init
+ */
+static
+rc_t KLockInit ( KLock *self )
+{
+ int status = pthread_mutex_init ( & self -> mutex, NULL );
+ switch ( status )
+ {
+ case 0:
+ atomic32_set ( & self -> refcount, 1 );
+ return 0;
+ case EAGAIN:
+ return RC ( rcPS, rcLock, rcConstructing, rcResources, rcInsufficient );
+ case ENOMEM:
+ return RC ( rcPS, rcLock, rcConstructing, rcMemory, rcInsufficient );
+ }
+
+ return RC ( rcPS, rcLock, rcConstructing, rcNoObj, rcUnknown );
+ }
+
+
+/* Make
+ * make a simple mutex
+ */
+LIB_EXPORT rc_t CC KLockMake ( KLock **lockp )
+{
+ rc_t rc;
+ if ( lockp == NULL )
+ rc = RC ( rcPS, rcLock, rcConstructing, rcParam, rcNull );
+ else
+ {
+ KLock *lock = malloc ( sizeof * lock );
+ if ( lock == NULL )
+ rc = RC ( rcPS, rcLock, rcConstructing, rcMemory, rcExhausted );
+ else
+ {
+ rc = KLockInit ( lock );
+ if ( rc == 0 )
+ {
+ * lockp = lock;
+ return 0;
+ }
+
+ free ( lock );
+ }
+
+ * lockp = NULL;
+ }
+ return rc;
+}
+
+
+/* AddRef
+ * Release
+ */
+LIB_EXPORT rc_t CC KLockAddRef ( const KLock *cself )
+{
+ if ( cself != NULL )
+ atomic32_inc ( & ( ( KLock* ) cself ) -> refcount );
+ return 0;
+}
+
+LIB_EXPORT rc_t CC KLockRelease ( const KLock *cself )
+{
+ KLock *self = ( KLock* ) cself;
+ if ( cself != NULL )
+ {
+ if ( atomic32_dec_and_test ( & self -> refcount ) )
+ {
+ atomic32_set ( & self -> refcount, 1 );
+ return KLockWhack ( self );
+ }
+ }
+ return 0;
+}
+
+
+/* Acquire
+ * acquires lock
+ */
+LIB_EXPORT rc_t CC KLockAcquire ( KLock *self )
+{
+ rc_t rc;
+
+ if ( self == NULL )
+ rc = RC ( rcPS, rcLock, rcLocking, rcSelf, rcNull );
+ else
+ {
+ rc = pthread_mutex_acquire ( & self -> mutex );
+ }
+
+ return rc;
+}
+
+/* Unlock
+ * releases lock
+ */
+LIB_EXPORT rc_t CC KLockUnlock ( KLock *self )
+{
+ rc_t rc;
+
+ if ( self == NULL )
+ return RC ( rcPS, rcLock, rcUnlocking, rcSelf, rcNull );
+
+ /* release the guy */
+ rc = pthread_mutex_release ( & self -> mutex );
+
+ return rc;
+}
+
+/*--------------------------------------------------------------------------
+ * KTimedLock
+ * a POSIX-style mutual exclusion lock with support for timed acquire
+ */
+
+/* Destroy
+ */
+static
+rc_t KTimedLockDestroy ( KTimedLock *self )
+{
rc_t rc = pthread_mutex_whack ( & self -> mutex );
if ( rc == 0 )
{
pthread_mutex_whack ( & self -> cond_lock );
- pthread_cond_whack ( & self -> cond );
+ pthread_condition_whack ( & self -> cond );
}
return rc;
}
@@ -155,9 +378,9 @@ rc_t KLockDestroy ( KLock *self )
/* Whack
*/
static
-rc_t KLockWhack ( KLock *self )
+rc_t KTimedLockWhack ( KTimedLock *self )
{
- rc_t rc = KLockDestroy ( self );
+ rc_t rc = KTimedLockDestroy ( self );
if ( rc == 0 )
free ( self );
return rc;
@@ -166,7 +389,7 @@ rc_t KLockWhack ( KLock *self )
/* Init
*/
static
-rc_t KLockInit ( KLock *self )
+rc_t KTimedLockInit ( KTimedLock *self )
{
int status = pthread_mutex_init ( & self -> mutex, NULL );
if ( status == 0 )
@@ -203,19 +426,19 @@ rc_t KLockInit ( KLock *self )
/* Make
* make a simple mutex
*/
-LIB_EXPORT rc_t CC KLockMake ( KLock **lockp )
+LIB_EXPORT rc_t CC KTimedLockMake ( KTimedLock **lockp )
{
rc_t rc;
if ( lockp == NULL )
rc = RC ( rcPS, rcLock, rcConstructing, rcParam, rcNull );
else
{
- KLock *lock = malloc ( sizeof * lock );
+ KTimedLock *lock = malloc ( sizeof * lock );
if ( lock == NULL )
rc = RC ( rcPS, rcLock, rcConstructing, rcMemory, rcExhausted );
else
{
- rc = KLockInit ( lock );
+ rc = KTimedLockInit ( lock );
if ( rc == 0 )
{
* lockp = lock;
@@ -234,22 +457,22 @@ LIB_EXPORT rc_t CC KLockMake ( KLock **lockp )
/* AddRef
* Release
*/
-LIB_EXPORT rc_t CC KLockAddRef ( const KLock *cself )
+LIB_EXPORT rc_t CC KTimedLockAddRef ( const KTimedLock *cself )
{
if ( cself != NULL )
- atomic32_inc ( & ( ( KLock* ) cself ) -> refcount );
+ atomic32_inc ( & ( ( KTimedLock* ) cself ) -> refcount );
return 0;
}
-LIB_EXPORT rc_t CC KLockRelease ( const KLock *cself )
+LIB_EXPORT rc_t CC KTimedLockRelease ( const KTimedLock *cself )
{
- KLock *self = ( KLock* ) cself;
+ KTimedLock *self = ( KTimedLock* ) cself;
if ( cself != NULL )
{
if ( atomic32_dec_and_test ( & self -> refcount ) )
{
atomic32_set ( & self -> refcount, 1 );
- return KLockWhack ( self );
+ return KTimedLockWhack ( self );
}
}
return 0;
@@ -259,113 +482,88 @@ LIB_EXPORT rc_t CC KLockRelease ( const KLock *cself )
/* Acquire
* acquires lock
*/
-LIB_EXPORT rc_t CC KLockAcquire ( KLock *self )
-{
- if ( self == NULL )
- return RC ( rcPS, rcLock, rcLocking, rcSelf, rcNull );
-
- return pthread_mutex_acquire ( & self -> mutex );
-}
-
-LIB_EXPORT rc_t CC KLockTimedAcquire ( KLock *self, timeout_t *tm )
+LIB_EXPORT rc_t CC KTimedLockAcquire ( KTimedLock *self, timeout_t *tm )
{
rc_t rc;
- int status;
if ( self == NULL )
return RC ( rcPS, rcLock, rcLocking, rcSelf, rcNull );
- status = pthread_mutex_trylock ( & self -> mutex );
- switch ( status )
- {
- case 0:
- return 0;
- case EBUSY:
- if ( tm != NULL )
- break;
- return RC ( rcPS, rcLock, rcLocking, rcLock, rcBusy );
- case EINVAL:
- return RC ( rcPS, rcLock, rcLocking, rcLock, rcInvalid );
- default:
- return RC ( rcPS, rcLock, rcLocking, rcNoObj, rcUnknown );
- }
+ if ( tm == NULL )
+ return pthread_mutex_acquire ( & self -> mutex );
+ /* this is ugly, but don't want to prepare inside lock */
if ( ! tm -> prepared )
TimeoutPrepare ( tm );
rc = pthread_mutex_acquire ( & self -> cond_lock );
- if ( rc != 0 )
- return rc;
-
- ++ self -> waiters;
-
- while ( 1 )
+ if ( rc == 0 )
{
- status = pthread_cond_timedwait ( & self -> cond, & self -> cond_lock, & tm -> ts );
- if ( status != 0 )
+ int status = pthread_mutex_tryacquire ( & self -> mutex );
+ if ( status == EBUSY )
{
- switch ( status )
+ while ( 1 )
{
- case ETIMEDOUT:
- rc = RC ( rcPS, rcLock, rcLocking, rcTimeout, rcExhausted );
- break;
- case EINTR:
- rc = RC ( rcPS, rcLock, rcLocking, rcThread, rcInterrupted );
- break;
- default:
- rc = RC ( rcPS, rcLock, rcLocking, rcNoObj, rcUnknown );
+ ++ self -> waiters;
+ status = pthread_cond_timedwait ( & self -> cond, & self -> cond_lock, & tm -> ts );
+ -- self -> waiters;
+
+ if ( status == EINTR )
+ continue;
+ if ( status != 0 )
+ break;
+ status = pthread_mutex_tryacquire ( & self -> mutex );
+ if ( status != EBUSY )
+ break;
}
- break;
}
- status = pthread_mutex_trylock ( & self -> mutex );
- if ( status != EBUSY )
+ pthread_mutex_release ( & self -> cond_lock );
+
+ switch ( status )
{
- switch ( status )
- {
- case 0:
- break;
- case EINVAL:
- rc = RC ( rcPS, rcLock, rcLocking, rcLock, rcInvalid );
- break;
- default:
- rc = RC ( rcPS, rcLock, rcLocking, rcNoObj, rcUnknown );
- }
+ case 0:
+ break;
+ case ETIMEDOUT:
+ rc = RC ( rcPS, rcLock, rcLocking, rcTimeout, rcExhausted );
+ break;
+ case EBUSY:
+ rc = RC ( rcPS, rcLock, rcLocking, rcLock, rcBusy );
break;
+ case EINVAL:
+ rc = RC ( rcPS, rcLock, rcLocking, rcLock, rcInvalid );
+ break;
+ default:
+ rc = RC ( rcPS, rcLock, rcLocking, rcNoObj, rcUnknown );
}
}
- -- self -> waiters;
- pthread_mutex_release ( & self -> cond_lock );
-
return rc;
}
/* Unlock
* releases lock
*/
-LIB_EXPORT rc_t CC KLockUnlock ( KLock *self )
+LIB_EXPORT rc_t CC KTimedLockUnlock ( KTimedLock *self )
{
rc_t rc;
if ( self == NULL )
return RC ( rcPS, rcLock, rcUnlocking, rcSelf, rcNull );
- /* release the guy */
- rc = pthread_mutex_release ( & self -> mutex );
- if ( rc != 0 )
- return rc;
-
- /* check for and signal any waiters */
rc = pthread_mutex_acquire ( & self -> cond_lock );
if ( rc == 0 )
{
+ /* release the guy */
+ rc = pthread_mutex_release ( & self -> mutex );
+
if ( self -> waiters != 0 )
- pthread_cond_ping ( & self -> cond );
+ pthread_condition_signal ( & self -> cond );
+
pthread_mutex_release ( & self -> cond_lock );
}
- return 0;
+ return rc;
}
@@ -376,12 +574,17 @@ LIB_EXPORT rc_t CC KLockUnlock ( KLock *self )
struct KRWLock
{
KLock lock;
- KCondition rcond;
- KCondition wcond;
+ pthread_cond_t rcond;
+ pthread_cond_t wcond;
uint32_t rwait;
uint32_t wwait;
int32_t count;
atomic32_t refcount;
+
+ /* used in KRWLockTimedAcquire */
+ pthread_mutex_t timed_lock;
+ pthread_cond_t timed_cond;
+ uint32_t timed_waiters;
};
@@ -391,15 +594,18 @@ static
rc_t KRWLockWhack ( KRWLock *self )
{
rc_t rc;
-
if ( self -> count || self -> rwait || self -> wwait )
return RC ( rcPS, rcRWLock, rcDestroying, rcRWLock, rcBusy );
rc = KLockDestroy ( & self -> lock );
if ( rc == 0 )
{
- KConditionDestroy ( & self -> rcond );
- KConditionDestroy ( & self -> wcond );
+ pthread_cond_destroy ( & self -> rcond );
+ pthread_cond_destroy ( & self -> wcond );
+
+ pthread_cond_destroy ( & self -> timed_cond );
+ pthread_mutex_whack ( & self -> timed_lock );
+
free ( self );
}
@@ -426,20 +632,32 @@ LIB_EXPORT rc_t CC KRWLockMake ( KRWLock **lockp )
rc = KLockInit ( & lock -> lock );
if ( rc == 0 )
{
- rc = KConditionInit ( & lock -> rcond );
+ rc = pthread_condition_init ( & lock -> rcond );
if ( rc == 0 )
{
- rc = KConditionInit ( & lock -> wcond );
+ rc = pthread_condition_init ( & lock -> wcond );
if ( rc == 0 )
{
- lock -> rwait = lock -> wwait = 0;
- lock -> count = 0;
- atomic32_set ( & lock -> refcount, 1 );
- * lockp = lock;
- return 0;
+ rc = pthread_condition_init ( & lock -> timed_cond );
+ if ( rc == 0 )
+ {
+ int status = pthread_mutex_init ( & lock -> timed_lock, NULL );
+ if ( status == 0 )
+ {
+
+ lock -> rwait = lock -> wwait = 0;
+ lock -> count = 0;
+ atomic32_set ( & lock -> refcount, 1 );
+ lock -> timed_waiters = 0;
+ * lockp = lock;
+ return 0;
+ }
+ pthread_cond_destroy ( & lock -> timed_cond );
+ }
+ pthread_cond_destroy ( & lock -> wcond );
}
- KConditionDestroy ( & lock -> rcond );
+ pthread_cond_destroy ( & lock -> rcond );
}
KLockDestroy ( & lock -> lock );
@@ -454,7 +672,6 @@ LIB_EXPORT rc_t CC KRWLockMake ( KRWLock **lockp )
return rc;
}
-
/* AddRef
* Release
*/
@@ -496,14 +713,16 @@ LIB_EXPORT rc_t CC KRWLockAcquireShared ( KRWLock *self )
++ self -> rwait;
while ( self -> count < 0 || self -> wwait != 0 )
{
- rc = KConditionWait ( & self -> rcond, & self -> lock );
+ rc = pthread_condition_wait ( & self -> rcond, & self -> lock . mutex );
if ( rc != 0 )
break;
}
-- self -> rwait;
if ( rc == 0 )
+ {
++ self -> count;
+ }
KLockUnlock ( & self -> lock );
}
@@ -511,6 +730,66 @@ LIB_EXPORT rc_t CC KRWLockAcquireShared ( KRWLock *self )
return rc;
}
+static
+rc_t KRWLockTimedAcquire( KRWLock *self, timeout_t *tm )
+{
+ rc_t rc;
+
+ if ( self == NULL )
+ return RC ( rcPS, rcLock, rcLocking, rcSelf, rcNull );
+
+ if ( tm == NULL )
+ return pthread_mutex_acquire ( & self -> lock . mutex );
+
+ /* this is ugly, but don't want to prepare inside lock */
+ if ( ! tm -> prepared )
+ TimeoutPrepare ( tm );
+
+ rc = pthread_mutex_acquire ( & self -> timed_lock );
+ if ( rc == 0 )
+ {
+ int status = pthread_mutex_tryacquire ( & self -> lock . mutex );
+ if ( status == EBUSY )
+ {
+ while ( 1 )
+ {
+ ++ self -> timed_waiters;
+ status = pthread_cond_timedwait ( & self -> timed_cond, & self -> timed_lock, & tm -> ts );
+ -- self -> timed_waiters;
+
+ if ( status == EINTR )
+ continue;
+ if ( status != 0 )
+ break;
+ status = pthread_mutex_tryacquire ( & self -> lock . mutex );
+ if ( status != EBUSY )
+ break;
+ }
+ }
+
+ pthread_mutex_release ( & self -> timed_lock );
+
+ switch ( status )
+ {
+ case 0:
+ break;
+ case ETIMEDOUT:
+ rc = RC ( rcPS, rcLock, rcLocking, rcTimeout, rcExhausted );
+ break;
+ case EBUSY:
+ rc = RC ( rcPS, rcLock, rcLocking, rcLock, rcBusy );
+ break;
+ case EINVAL:
+ rc = RC ( rcPS, rcLock, rcLocking, rcLock, rcInvalid );
+ break;
+ default:
+ rc = RC ( rcPS, rcLock, rcLocking, rcNoObj, rcUnknown );
+ }
+ }
+
+ return rc;
+}
+
LIB_EXPORT rc_t CC KRWLockTimedAcquireShared ( KRWLock *self, timeout_t *tm )
{
rc_t rc;
@@ -518,20 +797,26 @@ LIB_EXPORT rc_t CC KRWLockTimedAcquireShared ( KRWLock *self, timeout_t *tm )
if ( self == NULL )
return RC ( rcPS, rcRWLock, rcLocking, rcSelf, rcNull );
- rc = KLockTimedAcquire ( & self -> lock, tm );
+ rc = KRWLockTimedAcquire ( self, tm );
if ( rc == 0 )
{
++ self -> rwait;
while ( self -> count < 0 || self -> wwait != 0 )
{
- rc = KConditionTimedWait ( & self -> rcond, & self -> lock, tm );
+ rc = pthread_condition_timedwait ( & self -> rcond, & self -> lock . mutex, & tm -> ts );
if ( rc != 0 )
+ {
+ if ( GetRCState ( rc ) == rcExhausted && GetRCObject ( rc ) == rcTimeout )
+ rc = ResetRCContext ( rc, rcPS, rcRWLock, rcLocking );
break;
+ }
}
-- self -> rwait;
if ( rc == 0 )
+ {
++ self -> count;
+ }
KLockUnlock ( & self -> lock );
}
@@ -539,7 +824,6 @@ LIB_EXPORT rc_t CC KRWLockTimedAcquireShared ( KRWLock *self, timeout_t *tm )
return rc;
}
-
/* AcquireExcl
* acquires write ( exclusive ) lock
*/
@@ -556,14 +840,16 @@ LIB_EXPORT rc_t CC KRWLockAcquireExcl ( KRWLock *self )
++ self -> wwait;
while ( self -> count != 0 )
{
- rc = KConditionWait ( & self -> wcond, & self -> lock );
+ rc = pthread_condition_wait ( & self -> wcond, & self -> lock . mutex );
if ( rc != 0 )
break;
}
-- self -> wwait;
if ( rc == 0 )
+ {
self -> count = -1;
+ }
KLockUnlock ( & self -> lock );
}
@@ -578,20 +864,26 @@ LIB_EXPORT rc_t CC KRWLockTimedAcquireExcl ( KRWLock *self, timeout_t *tm )
if ( self == NULL )
return RC ( rcPS, rcRWLock, rcLocking, rcSelf, rcNull );
- rc = KLockTimedAcquire ( & self -> lock, tm );
+ rc = KRWLockTimedAcquire ( self, tm );
if ( rc == 0 )
{
++ self -> wwait;
while ( self -> count != 0 )
{
- rc = KConditionTimedWait ( & self -> wcond, & self -> lock, tm );
+ rc = pthread_condition_timedwait ( & self -> wcond, & self -> lock . mutex, & tm -> ts );
if ( rc != 0 )
+ {
+ if ( GetRCState ( rc ) == rcExhausted && GetRCObject ( rc ) == rcTimeout )
+ rc = ResetRCContext ( rc, rcPS, rcRWLock, rcLocking );
break;
+ }
}
-- self -> wwait;
if ( rc == 0 )
+ {
self -> count = -1;
+ }
KLockUnlock ( & self -> lock );
}
@@ -599,7 +891,6 @@ LIB_EXPORT rc_t CC KRWLockTimedAcquireExcl ( KRWLock *self, timeout_t *tm )
return rc;
}
-
/* Unlock
* releases lock
*/
@@ -624,14 +915,14 @@ LIB_EXPORT rc_t CC KRWLockUnlock ( KRWLock *self )
{
/* don't bother unless the lock is free */
if ( self -> count == 0 )
- KConditionSignal ( & self -> wcond );
+ pthread_condition_signal ( & self -> wcond );
}
/* if there are readers waiting */
else if ( self -> rwait != 0 )
{
/* any number of readers can come through now */
- KConditionBroadcast ( & self -> rcond );
+ pthread_condition_broadcast ( & self -> rcond );
}
KLockUnlock ( & self -> lock );
diff --git a/libs/kproc/linux/syslock-priv.h b/libs/kproc/linux/syslock-priv.h
index e47d508..1b2adff 100644
--- a/libs/kproc/linux/syslock-priv.h
+++ b/libs/kproc/linux/syslock-priv.h
@@ -55,6 +55,12 @@ struct KLock
atomic32_t refcount;
};
+struct KTimedLock
+{
+ pthread_mutex_t mutex;
+ atomic32_t refcount;
+};
+
#ifdef __cplusplus
}
#endif
diff --git a/libs/kproc/linux/syslock.c b/libs/kproc/linux/syslock.c
index aa86628..dffd05f 100644
--- a/libs/kproc/linux/syslock.c
+++ b/libs/kproc/linux/syslock.c
@@ -35,7 +35,6 @@
#include <stdlib.h>
#include <errno.h>
-
/*--------------------------------------------------------------------------
* KLock
* a POSIX-style mutual exclusion lock
@@ -63,7 +62,6 @@ rc_t KLockWhack ( KLock *self )
return 0;
}
-
/* Make
* make a simple mutex
*/
@@ -150,7 +148,123 @@ LIB_EXPORT rc_t CC KLockAcquire ( KLock *self )
return 0;
}
-LIB_EXPORT rc_t CC KLockTimedAcquire ( KLock *self, timeout_t *tm )
+/* Unlock
+ * releases lock
+ */
+LIB_EXPORT rc_t CC KLockUnlock ( KLock *self )
+{
+ int status;
+
+ if ( self == NULL )
+ return RC ( rcPS, rcLock, rcUnlocking, rcSelf, rcNull );
+
+ status = pthread_mutex_unlock ( & self -> mutex );
+ switch ( status )
+ {
+ case 0:
+ break;
+ case EPERM:
+ return RC ( rcPS, rcLock, rcUnlocking, rcThread, rcIncorrect );
+ case EINVAL:
+ return RC ( rcPS, rcLock, rcUnlocking, rcLock, rcInvalid );
+ default:
+ return RC ( rcPS, rcLock, rcUnlocking, rcNoObj, rcUnknown );
+ }
+
+ return 0;
+}
+
+/*--------------------------------------------------------------------------
+ * KTimedLock
+ * a POSIX-style mutual exclusion lock with support for timed Acquire
+ */
+
+ /* Whack
+ */
+static
+rc_t KTimedLockWhack ( KTimedLock *self )
+{
+ int status = pthread_mutex_destroy ( & self -> mutex );
+ switch ( status )
+ {
+ case 0:
+ break;
+ case EBUSY:
+ return RC ( rcPS, rcLock, rcDestroying, rcLock, rcBusy );
+ case EINVAL:
+ return RC ( rcPS, rcLock, rcDestroying, rcLock, rcInvalid );
+ default:
+ return RC ( rcPS, rcLock, rcDestroying, rcNoObj, rcUnknown );
+ }
+
+ free ( self );
+ return 0;
+}
+
+/* Make
+ * make a simple mutex
+ */
+LIB_EXPORT rc_t CC KTimedLockMake ( KTimedLock **lockp )
+{
+ rc_t rc;
+ if ( lockp == NULL )
+ rc = RC ( rcPS, rcLock, rcConstructing, rcParam, rcNull );
+ else
+ {
+ KTimedLock *lock = malloc ( sizeof * lock );
+ if ( lock == NULL )
+ rc = RC ( rcPS, rcLock, rcConstructing, rcMemory, rcExhausted );
+ else
+ {
+ int status = pthread_mutex_init ( & lock -> mutex, NULL );
+ if ( status == 0 )
+ {
+ atomic32_set ( & lock -> refcount, 1 );
+ * lockp = lock;
+ return 0;
+ }
+
+ /* pthread_mutex_init is documented as always returning 0 */
+ rc = RC ( rcPS, rcLock, rcConstructing, rcNoObj, rcUnknown );
+
+ free ( lock );
+ }
+
+ * lockp = NULL;
+ }
+ return rc;
+}
+
+
+/* AddRef
+ * Release
+ */
+LIB_EXPORT rc_t CC KTimedLockAddRef ( const KTimedLock *cself )
+{
+ if ( cself != NULL )
+ atomic32_inc ( & ( ( KLock* ) cself ) -> refcount );
+ return 0;
+}
+
+LIB_EXPORT rc_t CC KTimedLockRelease ( const KTimedLock *cself )
+{
+ KTimedLock *self = ( KTimedLock* ) cself;
+ if ( cself != NULL )
+ {
+ if ( atomic32_dec_and_test ( & self -> refcount ) )
+ {
+ atomic32_set ( & self -> refcount, 1 );
+ return KTimedLockWhack ( self );
+ }
+ }
+ return 0;
+}
+
+
+/* Acquire
+ * acquires lock with a timeout
+ */
+LIB_EXPORT rc_t CC KTimedLockAcquire ( KTimedLock *self, timeout_t *tm )
{
int status;
@@ -194,7 +308,7 @@ LIB_EXPORT rc_t CC KLockTimedAcquire ( KLock *self, timeout_t *tm )
/* Unlock
* releases lock
*/
-LIB_EXPORT rc_t CC KLockUnlock ( KLock *self )
+LIB_EXPORT rc_t CC KTimedLockUnlock ( KTimedLock *self )
{
int status;
@@ -218,6 +332,7 @@ LIB_EXPORT rc_t CC KLockUnlock ( KLock *self )
}
+
/*--------------------------------------------------------------------------
* KRWLock
* a POSIX-style read/write lock
diff --git a/libs/kproc/win/syslock-priv.h b/libs/kproc/win/syslock-priv.h
index ea751af..412cdf0 100644
--- a/libs/kproc/win/syslock-priv.h
+++ b/libs/kproc/win/syslock-priv.h
@@ -49,6 +49,17 @@ struct KLock
KRefcount refcount;
};
+/*--------------------------------------------------------------------------
+ * KTimedLock
+ * a POSIX-style mutual exclusion lock with wupport for timed Acquire
+ */
+struct KTimedLock
+{
+ HANDLE mutex;
+ KRefcount refcount;
+};
+
+
#ifdef __cplusplus
}
#endif
diff --git a/libs/kproc/win/syslock.c b/libs/kproc/win/syslock.c
index 5159eef..4aefc1c 100644
--- a/libs/kproc/win/syslock.c
+++ b/libs/kproc/win/syslock.c
@@ -36,7 +36,6 @@
#include <errno.h>
#include <assert.h>
-
/*--------------------------------------------------------------------------
* KLock
* a mutual exclusion lock
@@ -153,8 +152,121 @@ LIB_EXPORT rc_t CC KLockAcquire ( KLock *self )
return RC ( rcPS, rcLock, rcLocking, rcNoObj, rcUnknown );
}
+/* Unlock
+ * releases lock
+ */
+LIB_EXPORT rc_t CC KLockUnlock ( KLock *self )
+{
+ if ( self == NULL )
+ return RC ( rcPS, rcLock, rcUnlocking, rcSelf, rcNull );
+
+ if ( ReleaseMutex ( self -> mutex ) )
+ return 0;
-LIB_EXPORT rc_t CC KLockTimedAcquire ( KLock *self, timeout_t *tm )
+ switch ( GetLastError () )
+ {
+ case ERROR_INVALID_HANDLE:
+ return RC ( rcPS, rcLock, rcUnlocking, rcLock, rcInvalid );
+ }
+
+ return RC ( rcPS, rcLock, rcUnlocking, rcNoObj, rcUnknown );
+}
+
+
+/*--------------------------------------------------------------------------
+ * KTimedLock
+ * a mutual exclusion lock with support for timed Acquire
+ */
+
+/* Whack
+ */
+static
+rc_t KTimedLockWhack ( KTimedLock *self )
+{
+ if ( CloseHandle ( self -> mutex ) )
+ {
+ free ( self );
+ return 0;
+ }
+
+ switch ( GetLastError () )
+ {
+ case ERROR_INVALID_HANDLE:
+ return RC ( rcPS, rcLock, rcDestroying, rcLock, rcInvalid );
+ }
+
+ return RC ( rcPS, rcLock, rcDestroying, rcNoObj, rcUnknown );
+}
+
+
+/* Make
+ * make a simple mutex
+ */
+LIB_EXPORT rc_t CC KTimedLockMake ( KTimedLock **lockp )
+{
+ rc_t rc;
+ if ( lockp == NULL )
+ rc = RC ( rcPS, rcLock, rcConstructing, rcParam, rcNull );
+ else
+ {
+ KTimedLock *lock = malloc ( sizeof * lock );
+ if ( lock == NULL )
+ rc = RC ( rcPS, rcLock, rcConstructing, rcMemory, rcExhausted );
+ else
+ {
+ lock -> mutex = CreateMutex ( NULL, false, NULL );
+ if ( lock -> mutex != NULL )
+ {
+ atomic32_set ( & lock -> refcount, 1 );
+ * lockp = lock;
+ return 0;
+ }
+
+ switch ( GetLastError () )
+ {
+ default:
+ rc = RC ( rcPS, rcLock, rcConstructing, rcNoObj, rcUnknown );
+ }
+
+ free ( lock );
+ }
+
+ * lockp = NULL;
+ }
+ return rc;
+}
+
+
+/* AddRef
+ * Release
+ */
+LIB_EXPORT rc_t CC KTimedLockAddRef ( const KTimedLock *cself )
+{
+ if ( cself != NULL )
+ atomic32_inc ( & ( ( KTimedLock* ) cself ) -> refcount );
+ return 0;
+}
+
+
+LIB_EXPORT rc_t CC KTimedLockRelease ( const KTimedLock *cself )
+{
+ KTimedLock *self = ( KTimedLock* ) cself;
+ if ( cself != NULL )
+ {
+ if ( atomic32_dec_and_test ( & self -> refcount ) )
+ {
+ atomic32_set ( & self -> refcount, 1 );
+ return KTimedLockWhack ( self );
+ }
+ }
+ return 0;
+}
+
+
+/* Acquire
+ * acquires lock
+ */
+LIB_EXPORT rc_t CC KTimedLockAcquire ( KTimedLock *self, timeout_t *tm )
{
if ( self == NULL )
return RC ( rcPS, rcLock, rcLocking, rcSelf, rcNull );
@@ -183,7 +295,7 @@ LIB_EXPORT rc_t CC KLockTimedAcquire ( KLock *self, timeout_t *tm )
/* Unlock
* releases lock
*/
-LIB_EXPORT rc_t CC KLockUnlock ( KLock *self )
+LIB_EXPORT rc_t CC KTimedLockUnlock ( KTimedLock *self )
{
if ( self == NULL )
return RC ( rcPS, rcLock, rcUnlocking, rcSelf, rcNull );
@@ -413,7 +525,7 @@ rc_t KRWLockAcquireSharedInt ( KRWLock *self, DWORD mS )
/* drop count and go */
-- self -> rwait;
ReleaseMutex ( self -> mutex );
- return RC ( rcPS, rcRWLock, rcLocking, rcRWLock, rcExhausted );
+ return RC ( rcPS, rcRWLock, rcLocking, rcTimeout, rcExhausted );
case WAIT_FAILED:
switch ( GetLastError () )
@@ -517,7 +629,7 @@ rc_t KRWLockAcquireExclInt ( KRWLock *self, DWORD mS )
/* drop count and go */
-- self -> wwait;
ReleaseMutex ( self -> mutex );
- return RC ( rcPS, rcRWLock, rcLocking, rcRWLock, rcExhausted );
+ return RC ( rcPS, rcRWLock, rcLocking, rcTimeout, rcExhausted );
case WAIT_FAILED:
switch ( GetLastError () )
diff --git a/libs/krypto/Makefile b/libs/krypto/Makefile
index d7586c8..4fd6fe0 100644
--- a/libs/krypto/Makefile
+++ b/libs/krypto/Makefile
@@ -49,7 +49,7 @@ endif
# VEC_SUPPORTED, VECREG_SUPPORTED and AESNI_SUPPORTED
# The successive symbols are additive
# In order they are the compiler supports the vector 'container' type,
-# the preocessor has supported vector registers
+# the processor has supported vector registers
# the processor supports the Intel AES-NI instruction set
#
# The prerequisite call to make compiler-test will have tried to compile objects
diff --git a/libs/ktst/testenv.cpp b/libs/ktst/testenv.cpp
index b9a2301..d76b93e 100644
--- a/libs/ktst/testenv.cpp
+++ b/libs/ktst/testenv.cpp
@@ -57,7 +57,10 @@ TestEnv::TestEnv(int argc, char* argv[], ArgsHandler* argsHandler)
, argc2(0)
, argv2(NULL)
{
- process_args(argc, argv, argsHandler);
+ rc_t rc = process_args(argc, argv, argsHandler);
+ if (rc != 0) {
+ throw rc;
+ }
}
TestEnv::~TestEnv ()
@@ -503,3 +506,9 @@ rc_t CC TestEnv::Usage(const char *progname)
return 0;
}
#endif
+
+bool TestEnv::Sleep(unsigned int seconds)
+{
+ return TestEnv::SleepMs(seconds*1000);
+}
+
diff --git a/libs/ktst/unix/runprocesstestcase.cpp b/libs/ktst/unix/runprocesstestcase.cpp
index 60c608d..192a750 100644
--- a/libs/ktst/unix/runprocesstestcase.cpp
+++ b/libs/ktst/unix/runprocesstestcase.cpp
@@ -26,17 +26,22 @@
#include <ktst/unit_test_suite.hpp>
-#include <signal.h> // sigaction, not necessarily in csignal :-/
+#include <sstream>
+
+#include <csignal> // sigaction, not necessarily in csignal :-/
#include <cstdlib>
#include <cstring>
-#include <sstream>
+
+#include <time.h>
+#include <unistd.h> /* fork */
+
#include <sys/wait.h>
#include <sys/types.h>
-#include <unistd.h>
using namespace std;
using namespace ncbi::NK;
+#undef REPORT_ERROR
#define REPORT_ERROR(msg) _REPORT_CRITICAL_ERROR_("TestEnv::" msg, __FILE__, __LINE__, true);
static void alarmHandler(int)
@@ -100,9 +105,10 @@ int TestEnv::RunProcessTestCase(TestCase& obj, void(TestCase::*meth)(), int time
return WEXITSTATUS(status); /* exit status of the child process */
}
-unsigned int TestEnv::Sleep(unsigned int seconds)
+bool TestEnv::SleepMs(unsigned int milliseconds)
{
- return sleep(seconds);
+ struct timespec time = { milliseconds / 1000, (milliseconds % 1000) * 1000 * 1000 };
+ return nanosleep(&time, NULL) == 0;
}
void TestEnv::set_handlers(void)
diff --git a/libs/ktst/win/runprocesstestcase.cpp b/libs/ktst/win/runprocesstestcase.cpp
index ca621de..0ff1651 100644
--- a/libs/ktst/win/runprocesstestcase.cpp
+++ b/libs/ktst/win/runprocesstestcase.cpp
@@ -34,6 +34,9 @@
using namespace std;
using namespace ncbi::NK;
+#undef REPORT_ERROR
+#define REPORT_ERROR(msg) _REPORT_CRITICAL_ERROR_(string("TestEnv::") + msg, __FILE__, __LINE__, true)
+
/* signal handlers for a single-test case thread */
void CC SigSubHandler(int sig)
{
@@ -84,13 +87,10 @@ int TestEnv::RunProcessTestCase(TestCase& obj, void(TestCase::*meth)(), int time
HANDLE thread = (HANDLE)_beginthread( ThreadProc, 0, &call );
if (thread == NULL)
{
- _REPORT_CRITICAL_ERROR_("TestEnv::RunProcessTestCase: failed to start a test case thread", __FILE__, __LINE__, true);
+ REPORT_ERROR("TestEnv::RunProcessTestCase: failed to start a test case thread");
}
- // make sure to restore main process's signal handlers before throwing an exception
-#define CALL_FAILED(call)\
- _REPORT_CRITICAL_ERROR_("TestEnv::RunProcessTestCase: " call " failed", __FILE__, __LINE__, true);
-
+ // make sure to restore main process's signal handlers before re-throwing an exception
DWORD rc=0;
DWORD result=WaitForSingleObject( (HANDLE)thread, timeout == 0 ? INFINITE : timeout*1000);
try
@@ -99,24 +99,33 @@ int TestEnv::RunProcessTestCase(TestCase& obj, void(TestCase::*meth)(), int time
{
case WAIT_OBJECT_0:
if (GetExitCodeThread(thread, &rc) == 0)
- {
- CALL_FAILED("GetExitCodeThread");
- }
+ REPORT_ERROR("RunProcessTestCase failed");
break;
case WAIT_TIMEOUT:
if (!CloseHandle(thread))
- {
- CALL_FAILED("GetExitCodeThread");
- }
+ REPORT_ERROR("CloseHandle failed");
+ cerr << "child process timed out" << endl;
rc=TEST_CASE_TIMED_OUT;
break;
default:
- CALL_FAILED("WaitForSingleObject");
+ REPORT_ERROR("WaitForSingleObject failed");
break;
}
}
- catch(...)
+ catch (const exception& ex)
+ {
+ REPORT_ERROR(obj.GetName() + " threw " + ex.what());
+ rc=TEST_CASE_FAILED;
+ }
+ catch (const ncbi::NK::execution_aborted&)
+ {
+ REPORT_ERROR(obj.GetName() + " aborted ");
+ rc=TEST_CASE_FAILED;
+ }
+ catch (...)
{
+ REPORT_ERROR(obj.GetName() + " threw something ");
+ rc=TEST_CASE_FAILED;
set_handlers();
throw;
}
@@ -126,10 +135,10 @@ int TestEnv::RunProcessTestCase(TestCase& obj, void(TestCase::*meth)(), int time
return (int)rc;
}
-unsigned int TestEnv::Sleep(unsigned int seconds)
+bool TestEnv::SleepMs(unsigned int milliseconds)
{
- ::Sleep(seconds*1000);
- return 0;
+ ::Sleep((DWORD)milliseconds);
+ return true;
}
void TestEnv::set_handlers(void)
diff --git a/libs/loader/common-writer.c b/libs/loader/common-writer.c
index 59f4c1c..2c0f5e0 100644
--- a/libs/loader/common-writer.c
+++ b/libs/loader/common-writer.c
@@ -170,6 +170,7 @@ rc_t GetKeyIDOld(const CommonWriterSettings* settings, SpotAssembler* const ctx,
return rc;
}
+#if _DEBUGGING
static char const *Print_ctx_value_t(ctx_value_t const *const self)
{
static char buffer[4096];
@@ -188,6 +189,7 @@ static char const *Print_ctx_value_t(ctx_value_t const *const self)
return 0;
return buffer;
}
+#endif
static unsigned HashKey(void const *const key, size_t const keylen)
{
@@ -1071,7 +1073,11 @@ rc_t ArchiveFile(const struct ReaderFile *const reader,
const CGData* cg = NULL;
rc = ReaderFileGetRecord(reader, &record);
- if (rc || record == 0)
+ if (GetRCObject(rc) == rcRow && (GetRCState(rc) == rcInvalid || GetRCState(rc) == rcEmpty)) {
+ (void)PLOGERR(klogWarn, (klogWarn, rc, "ArchiveFile: '$(file)' - row $(row)", "file=%s,row=%lu", ReaderFileGetPathname(reader), reccount + 1));
+ rc = CheckLimitAndLogError(G);
+ }
+ else if (rc || record == 0)
break;
{
@@ -1538,7 +1544,22 @@ rc_t ArchiveFile(const struct ReaderFile *const reader,
if (aligned) {
if (G->editAlignedQual ) EditAlignedQualities (G, qual, AR_HAS_MISMATCH(data), readlen);
if (G->keepMismatchQual) EditUnalignedQualities(qual, AR_HAS_MISMATCH(data), readlen);
- AR_NUM_MISMATCH_QUAL(data) = (AR_MISMATCH_QUAL(data) == NULL) ? (size_t)0 : ReferenceMgr_CompressHelper(AR_MISMATCH_QUAL(data), &data.data, qual);
+
+ if (AR_MISMATCH_QUAL(data) == NULL) {
+ AR_NUM_MISMATCH_QUAL(data) = 0;
+ }
+ else {
+ size_t i;
+ size_t n;
+ bool const *const has_mismatch = AR_HAS_MISMATCH(data);
+ uint8_t *const mismatch = AR_MISMATCH_QUAL(data);
+
+ for (n = i = 0; i < readlen; ++i) {
+ if (has_mismatch[i])
+ mismatch[n++] = qual[i];
+ }
+ AR_NUM_MISMATCH_QUAL(data) = n;
+ }
}
else if (isPrimary) {
switch (AR_READNO(data)) {
diff --git a/libs/ncbi-vdb/Makefile b/libs/ncbi-vdb/Makefile
index f8acf19..8821403 100644
--- a/libs/ncbi-vdb/Makefile
+++ b/libs/ncbi-vdb/Makefile
@@ -96,7 +96,7 @@ VDB_LIB_CMN = \
krypto \
ksrch \
$(LIBKXML) \
- kurl \
+ kns \
vfs \
z
diff --git a/libs/ncbi-vdb/libncbi-vdb.vers b/libs/ncbi-vdb/libncbi-vdb.vers
index 3f684d2..cc6c9a4 100644
--- a/libs/ncbi-vdb/libncbi-vdb.vers
+++ b/libs/ncbi-vdb/libncbi-vdb.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/libs/ncbi-vdb/libncbi-wvdb.vers b/libs/ncbi-vdb/libncbi-wvdb.vers
index 3f684d2..cc6c9a4 100644
--- a/libs/ncbi-vdb/libncbi-wvdb.vers
+++ b/libs/ncbi-vdb/libncbi-wvdb.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/libs/search/agrep-dp.c b/libs/search/agrep-dp.c
index 85df7bf..45a188e 100644
--- a/libs/search/agrep-dp.c
+++ b/libs/search/agrep-dp.c
@@ -746,7 +746,7 @@ LIB_EXPORT uint32_t CC has_right_approx_match( char *pattern, uint32_t errors,
int32_t *tmp;
int32_t i, j;
int32_t allowable;
- char *subpattern;
+ char *subpattern, chBackup;
char *subpattern_r;
int32_t dist;
@@ -760,16 +760,22 @@ LIB_EXPORT uint32_t CC has_right_approx_match( char *pattern, uint32_t errors,
bound = buflen;
}
- for (i=bound; i>=8; i--) {
+ subpattern = malloc(plen + 1);
+ subpattern_r = malloc(plen + 1);
+ strncpy(subpattern, pattern, plen);
+
+ for (i=bound; i>=8; i--, subpattern[i] = chBackup) {
/* See if the first i chars of the pattern match the last i
chars of the text with (errors) errors.
We match in reverse, so the initial penalty of skipping
the "first part" of the pattern means skipping the end
*/
- /* Some leaks here! */
- subpattern = substring(pattern, i);
- subpattern_r = malloc(i + 1);
+ /* making prefix of length i out of pattern
+ (subpattern contains full copy of pattern)*/
+ chBackup = subpattern[i];
+ subpattern[i] = '\0';
+
reverse_string(subpattern, i, subpattern_r);
init_col(subpattern_r, i, nxt);
@@ -797,6 +803,8 @@ LIB_EXPORT uint32_t CC has_right_approx_match( char *pattern, uint32_t errors,
}
}
DONE:
+ free(subpattern);
+ free(subpattern_r);
free(prev);
free(nxt);
if (found) {
diff --git a/libs/search/agrep-myers.c b/libs/search/agrep-myers.c
index 8d84bc8..de22993 100644
--- a/libs/search/agrep-myers.c
+++ b/libs/search/agrep-myers.c
@@ -28,6 +28,7 @@
#include <compiler.h>
#include <os-native.h>
#include <sysalloc.h>
+#include <assert.h>
#include "search-priv.h"
#include "debug.h"
@@ -136,6 +137,7 @@ rc_t AgrepMyersMake( MyersSearch **self, AgrepFlags mode, const char *pattern )
This finds the first match forward in the string less than or equal
the threshold. If nonzero, this will be a prefix of any exact match.
*/
+
uint32_t MyersFindFirst( MyersSearch *self, int32_t threshold,
const char* text, size_t n,
AgrepMatch *match )
@@ -333,15 +335,26 @@ LIB_EXPORT int32_t CC MyersFindBest ( MyersSearch *self, const char* text,
This finds the first match forward in the string less than or equal
the threshold. If nonzero, this will be a prefix of any exact match.
*/
-void MyersFindAll ( const AgrepCallArgs *args )
+
+/*
+ MyersFindAllOld is the old implementation of MyersFindAll.
+ It uses inline copy-pasted Myers core algorithm steps therefore
+ it might be faster than the new MyersFindAll (if compiler doesn't optimize it enough)
+ Also for some reason it uses unoptimized dp algorithm to find starting point of the match.
+
+ Leaving it in CVS for a while just in case (with fixed bug in "const void *cbinfo = args->cbinfo;"
+ and some minor improvements like marking data being used for read only as explicitly const)
+*/
+#ifdef COMMENT_OUT_MYERS_FIND_ALL_OLD_AND_HOPE_NOBODY_IS_USING_THIS_NAME_FOR_DEFINE
+void MyersFindAllOld ( const AgrepCallArgs *args )
{
- AgrepFlags mode = args->self->mode;
- MyersSearch *self = args->self->myers;
- int32_t threshold = args->threshold;
+ AgrepFlags const mode = args->self->mode;
+ MyersSearch const* self = args->self->myers;
+ int32_t const threshold = args->threshold;
const unsigned char *utext = (const unsigned char *)args->buf;
- int32_t n = args->buflen;
+ int32_t const n = args->buflen;
AgrepMatchCallback cb = dp_end_callback;
- const void *cbinfo = args;
+ const void *cbinfo = args->cbinfo;
AgrepMatch match;
AgrepContinueFlag cont;
@@ -349,7 +362,7 @@ void MyersFindAll ( const AgrepCallArgs *args )
UBITTYPE Pv;
UBITTYPE Mv;
- int32_t m = self->m;
+ int32_t const m = self->m;
int32_t Score;
int32_t BestScore;
@@ -365,7 +378,8 @@ void MyersFindAll ( const AgrepCallArgs *args )
Pv = (UBITTYPE)-1;
Mv = (UBITTYPE)0;
- for(j = 0; j < n; j++) {
+ for (j = 0; j < n; j++)
+ {
Eq = self->PEq[utext[j]];
Xv = Eq | Mv;
Xh = (((Eq & Pv) + Pv) ^ Pv) | Eq;
@@ -450,3 +464,123 @@ void MyersFindAll ( const AgrepCallArgs *args )
(*cb)(cbinfo, &match, &cont);
}
}
+#endif
+
+
+/* The core of the Myers algorithm - calculation of j-th score
+ Now using for new MyersFindAll only but can be used by all other Myers-find
+ functons if there is no issues with performance because of function call with
+ so many parameters and locals
+*/
+static void MyersCoreStep(unsigned char const* utext, int32_t const j, int32_t const m
+ ,UBITTYPE const* PEq, UBITTYPE* Mv, UBITTYPE* Pv, int32_t *Score
+)
+{
+ UBITTYPE Eq, Xv, Xh, Ph, Mh;
+
+ Eq = PEq[utext[j]];
+ Xv = Eq | *Mv;
+ Xh = (((Eq & *Pv) + *Pv) ^ *Pv) | Eq;
+ Ph = *Mv | ~ (Xh | *Pv);
+ Mh = *Pv & Xh;
+ if (Ph & ((UBITTYPE)1 << (m - 1)))
+ ++(*Score);
+ else if (Mh & ((UBITTYPE)1 << (m - 1)))
+ --(*Score);
+
+ Ph <<= 1;
+ Mh <<= 1;
+ *Pv = Mh | ~(Xv | Ph);
+ *Mv = Ph & Xv;
+}
+
+/* Return start position of the match given its end position and score */
+static int32_t MyersGetMatchStartingPosition(AgrepCallArgs const* args
+ ,int32_t const indexEnd, int32_t const TargetScore
+)
+{
+ MyersSearch const* self = args->self->myers;
+ unsigned char const* utext = (unsigned char const*)args->buf;
+ int32_t const m = self->m;
+
+ UBITTYPE Pv;
+ UBITTYPE Mv;
+
+ int32_t Score, ScorePrev;
+
+ int32_t j;
+
+ Score = m;
+ ScorePrev = m;
+ Pv = (UBITTYPE)-1;
+ Mv = (UBITTYPE)0;
+
+ /*
+ Here we're guaranteed that score will be decreasing down to:
+ 1) TargetScore in the case when indexEnd points to the
+ string with deletions/modifications from the pattern
+ 2) 0 in the case when indexEnd points to the string with
+ insertions to the end of the pattern
+ So we need to search backwards until Score is non-increasing
+ */
+ for (j = indexEnd; j >= 0; --j, ScorePrev = Score)
+ {
+ MyersCoreStep(utext, j, m, self->PEq_R, &Mv, &Pv, &Score);
+ SEARCH_DBG("Rvs: %3d. '%c' score %d", j, utext[j], Score);
+ if (Score > ScorePrev && ScorePrev <= TargetScore)
+ {
+ ++j;
+ break;
+ }
+ if (j == 0 && Score <= TargetScore)
+ break;
+ }
+ assert(j >= 0);
+ return j;
+}
+
+void MyersFindAll(AgrepCallArgs const *args )
+{
+ MyersSearch const* self = args->self->myers;
+ int32_t const threshold = args->threshold;
+ const unsigned char *utext = (const unsigned char *)args->buf;
+ int32_t const n = args->buflen;
+ const void *cbinfo = args->cbinfo;
+
+ AgrepMatch match;
+ AgrepContinueFlag cont;
+
+ UBITTYPE Pv;
+ UBITTYPE Mv;
+
+ int32_t const m = self->m;
+ int32_t Score;
+ int32_t BestScore;
+
+ int32_t j, indexStart;
+
+ BestScore = m;
+ Score = m;
+ Pv = (UBITTYPE)-1;
+ Mv = (UBITTYPE)0;
+
+ for (j = 0; j < n; ++j)
+ {
+ MyersCoreStep(utext, j, m, self->PEq, &Mv, &Pv, &Score);
+ if (Score <= threshold)
+ {
+ indexStart = MyersGetMatchStartingPosition(args, j, Score);
+
+ /* found starting point indexStart for current match ending at j with Score */
+ match.score = Score;
+ match.position = indexStart;
+ match.length = j - indexStart + 1;
+ cont = AGREP_CONTINUE;
+ (*args->cb)(cbinfo, &match, &cont);
+ if (cont != AGREP_CONTINUE)
+ return;
+ }
+ }
+}
+
+
diff --git a/libs/search/fgrep-aho.c b/libs/search/fgrep-aho.c
index b3001b4..f0be9ca 100644
--- a/libs/search/fgrep-aho.c
+++ b/libs/search/fgrep-aho.c
@@ -141,7 +141,7 @@ void trie_enter(struct trie *self, int32_t whichpattern, const char *s, int32_t
newone = (struct trie *)malloc(sizeof(struct trie));
newone->fail = NULL;
newone->outs = NULL;
- newone->debugs = substring(s, i+1);
+ newone->debugs = create_substring(s, i+1);
newone->depth = i+1;
newone->hasmatch = 1;
memset( newone->next, 0, sizeof( *newone->next ) );
diff --git a/libs/search/fgrep-boyermoore.c b/libs/search/fgrep-boyermoore.c
index 375bd27..8029ca3 100644
--- a/libs/search/fgrep-boyermoore.c
+++ b/libs/search/fgrep-boyermoore.c
@@ -151,7 +151,7 @@ void trie_enter(struct trie *self, int32_t whichpattern, char *s, int32_t minlen
newone = (struct trie *)malloc(sizeof(struct trie));
newone->s = NULL;
#ifdef DEBUG
- newone->debugs = substring(s, i+1);
+ newone->debugs = create_substring(s, i+1);
#endif
newone->depth = i+1;
newone->hasmatch = 1;
@@ -189,7 +189,7 @@ void trie_enter_suffixes(struct trie *self, char *s, int32_t minlen)
newone = (struct trie *)malloc(sizeof(struct trie));
newone->s = NULL;
#ifdef DEBUG
- newone->debugs = substring(s+suf, i+1);
+ newone->debugs = create_substring(s+suf, i+1);
#endif
newone->depth = i+1;
newone->hasmatch = 0;
diff --git a/libs/search/fgrep-dumb.c b/libs/search/fgrep-dumb.c
index d34f09c..b0abfe2 100644
--- a/libs/search/fgrep-dumb.c
+++ b/libs/search/fgrep-dumb.c
@@ -119,7 +119,7 @@ void trie_enter(struct trie *self, const char *s, int32_t minlen)
newone = (struct trie *)malloc(sizeof(struct trie));
newone->s = NULL;
#ifdef DEBUG
- newone->debugs = substring(s, i+1);
+ newone->debugs = create_substring(s, i+1);
#endif
newone->depth = i+1;
newone->hasmatch = 1;
diff --git a/libs/search/search-priv.h b/libs/search/search-priv.h
index ff8a376..b1a7dc8 100644
--- a/libs/search/search-priv.h
+++ b/libs/search/search-priv.h
@@ -122,9 +122,9 @@ rc_t na4_set_bits(const AgrepFlags mode, uint64_t* arr, const unsigned char c, c
rc_t CC dp_end_callback( const void *cbinfo, const AgrepMatch *match, AgrepContinueFlag *flag );
static __inline__
-char *substring ( const char *src, uint32_t sz )
+char *create_substring ( const char *src, uint32_t sz )
{
- char *ret = malloc ( sz + 1 );
+ char *ret = (char*)malloc( sz + 1 );
strncpy ( ret, src, sz );
ret [ sz ] = 0;
return ret;
diff --git a/libs/sra/Makefile b/libs/sra/Makefile
index 26a5081..0dee0e4 100644
--- a/libs/sra/Makefile
+++ b/libs/sra/Makefile
@@ -85,7 +85,7 @@ SRA_DFLT_SCHEMA_LIBS = \
-salign-reader \
-skdb \
-svfs \
- -skurl \
+ -skns \
-sksrch \
-skrypto \
-skfg \
diff --git a/libs/sra/reader-abi.c b/libs/sra/reader-abi.c
index c48f541..6482e2b 100644
--- a/libs/sra/reader-abi.c
+++ b/libs/sra/reader-abi.c
@@ -173,23 +173,27 @@ LIB_EXPORT rc_t CC AbsolidReaderSpotName(const AbsolidReader* self,
} else {
int k = 0;
size_t psz = spotname_sz;
- while( psz > 0 && k < 4 ) {
+ while( psz > 0 && k < 3 ) {
/* take out PLATE_X_Y and optional label _(F|R)3 */
- while( psz > 0 && isdigit(*(spotname + psz)) ) {
+ while( psz > 0 && isdigit( *(spotname + psz - 1)) ) {
psz--;
}
- if(*(spotname + psz) == 'F' || *(spotname + psz) == 'R') {
- if( --psz > 0 && !isdigit(*(spotname + psz)) ) {
+
+ if( *(spotname + psz - 1) == 'F' || *(spotname + psz - 1) == 'R') {
+ /* Discard F|R and preceding underscore */
+ if( --psz > 0 && !isdigit(*(spotname + psz - 1)) ) {
psz--;
}
continue;
} else if( psz > 0 ) {
+ /* Discard underscore */
psz--;
k++;
}
}
if( psz > 0 ) {
- me->prefix_sz = psz + 2;
+ /* Add one to restore underscore at end of prefix */
+ me->prefix_sz = psz + 1;
string_copy(me->prefix_buf, sizeof(me->prefix_buf), spotname, me->prefix_sz);
} else {
me->prefix_sz = 0;
diff --git a/libs/sra/reader-fastq.c b/libs/sra/reader-fastq.c
index 11bd156..6a59a6b 100644
--- a/libs/sra/reader-fastq.c
+++ b/libs/sra/reader-fastq.c
@@ -44,7 +44,8 @@ typedef enum FastqReaderOptions_enum {
ePrintLabel = 0x10,
ePrintReadId = 0x20,
eClipQual = 0x40,
- eUseQual = 0x80
+ eUseQual = 0x80,
+ eSuppressQualForCSKey = 0x100 /* added Jan 15th 2014 ( a new fastq-variation! ) */
} FastqReaderOptions;
/* column order is important here: see Init function below!!! */
@@ -81,7 +82,7 @@ struct FastqReader {
static
rc_t FastqReaderInit(const FastqReader* self,
bool colorSpace, bool origFormat, bool fasta, bool printLabel, bool printReadId,
- bool noClip, uint32_t minReadLen, int offset, char csKey)
+ bool noClip, bool SuppressQualForCSKey, uint32_t minReadLen, int offset, char csKey)
{
rc_t rc = 0;
int options = colorSpace ? eColorSpace : eBaseSpace;
@@ -93,6 +94,8 @@ rc_t FastqReaderInit(const FastqReader* self,
options |= printReadId ? ePrintReadId : 0;
options |= noClip ? 0 : eClipQual;
options |= fasta ? 0 : eUseQual;
+ options |= SuppressQualForCSKey ? eSuppressQualForCSKey : 0; /* added Jan 15th 2014 ( a new fastq-variation! ) */
+
me->minReadLen = minReadLen;
me->offset = offset > 0 ? offset : 33;
me->csKey = csKey;
@@ -118,14 +121,14 @@ rc_t FastqReaderInit(const FastqReader* self,
LIB_EXPORT rc_t CC FastqReaderMake(const FastqReader** self, const SRATable* table, const char* accession,
bool colorSpace, bool origFormat, bool fasta, bool printLabel, bool printReadId,
- bool noClip, uint32_t minReadLen, char offset, char csKey,
+ bool noClip, bool SuppressQualForCSKey, uint32_t minReadLen, char offset, char csKey,
spotid_t minSpotId, spotid_t maxSpotId)
{
rc_t rc = SRAReaderMake((const SRAReader**)self, sizeof **self, table, accession, minSpotId, maxSpotId);
if( rc == 0 ) {
rc = FastqReaderInit(*self, colorSpace, origFormat, fasta,
- printLabel, printReadId, noClip, minReadLen, offset, csKey);
+ printLabel, printReadId, noClip, SuppressQualForCSKey, minReadLen, offset, csKey);
}
if( rc != 0 ) {
FastqReaderWhack(*self);
@@ -421,6 +424,7 @@ LIB_EXPORT rc_t CC FastqReaderQuality(const FastqReader* self, uint32_t readId,
rc_t rc = 0;
INSDC_coord_zero read_start = 0;
INSDC_coord_len read_len = 0;
+ bool print_quality_for_cskey = false; /* added Jan 15th 2014 ( a new fastq-variation! )*/
CHECK_SELF(FastqReader);
CHECK_SPOT(self->dad);
@@ -436,10 +440,13 @@ LIB_EXPORT rc_t CC FastqReaderQuality(const FastqReader* self, uint32_t readId,
return rc;
}
+ /* added Jan 15th 2014 ( a new fastq-variation! )*/
+ print_quality_for_cskey = ( ( me->dad.options & eColorSpace )&&( ( me->dad.options & eSuppressQualForCSKey ) == 0 ) );
+
if( read_len < self->minReadLen ) {
read_len = 0;
}
- if( me->dad.options & eColorSpace ) {
+ if( print_quality_for_cskey ) { /* changed Jan 15th 2014 ( a new fastq-variation! ) */
read_len++;
}
if( written != NULL ) {
@@ -452,7 +459,8 @@ LIB_EXPORT rc_t CC FastqReaderQuality(const FastqReader* self, uint32_t readId,
char* d = data;
INSDC_coord_len i, j;
- if( me->dad.options & eColorSpace ) {
+ if ( print_quality_for_cskey ) /* changed Jan 15th 2014 ( a new fastq-variation! ) */
+ {
*d++ = me->offset;
--read_len;
}
diff --git a/libs/sra/sra-schema.c b/libs/sra/sra-schema.c
index 8087365..8833cdd 100644
--- a/libs/sra/sra-schema.c
+++ b/libs/sra/sra-schema.c
@@ -297,1689 +297,1546 @@ const char sra_schema_text[] = {
'M', 'N', 'P', 'Q', 'R', 'S', 'T', 'V', 'W', 'X', 'Y', 'Z', 'U', '*', 'a', 'b', 'c',
'd', 'e', 'f', 'g', 'h', 'i', 'k', 'l', 'm', 'n', 'p', 'q', 'r', 's', 't', 'v', 'w',
'x', 'y', 'z', 'u', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D',
- 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r',
- ' ', 'S', 'R', 'A', '_', 'R', 'E', 'A', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', '_',
- 'P', 'A', 'S', 'S', '=', '0', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D',
- 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r',
- ' ', 'S', 'R', 'A', '_', 'R', 'E', 'A', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', '_',
- 'R', 'E', 'J', 'E', 'C', 'T', '=', '1', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N',
- 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't',
- 'e', 'r', ' ', 'S', 'R', 'A', '_', 'R', 'E', 'A', 'D', '_', 'F', 'I', 'L', 'T', 'E',
- 'R', '_', 'C', 'R', 'I', 'T', 'E', 'R', 'I', 'A', '=', '2', ';', 'c', 'o', 'n', 's',
- 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_',
- 'f', 'i', 'l', 't', 'e', 'r', ' ', 'S', 'R', 'A', '_', 'R', 'E', 'A', 'D', '_', 'F',
- 'I', 'L', 'T', 'E', 'R', '_', 'R', 'E', 'D', 'A', 'C', 'T', 'E', 'D', '=', '3', ';',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'I', 'N', 'S', 'D', 'C',
+ ':', 'c', 'o', 'o', 'r', 'd', ':', 'm', 'i', 'n', ':', 'o', 'n', 'e', '=', '2', '1',
+ '4', '7', '4', '8', '3', '6', '4', '9', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N',
+ 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'I', 'N', 'S',
+ 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'm', 'a', 'x', ':', 'o', 'n', 'e', '=',
+ '1', '0', '7', '3', '7', '4', '1', '8', '2', '3', ';', 'c', 'o', 'n', 's', 't', ' ',
+ 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ',
+ 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'm', 'i', 'n', ':', 'z',
+ 'e', 'r', 'o', '=', '2', '1', '4', '7', '4', '8', '3', '6', '4', '8', ';', 'c', 'o',
+ 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z',
+ 'e', 'r', 'o', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'm',
+ 'a', 'x', ':', 'z', 'e', 'r', 'o', '=', '1', '0', '7', '3', '7', '4', '1', '8', '2',
+ '2', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A',
+ ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', ' ', 'S', 'R', 'A', '_',
+ 'R', 'E', 'A', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', '_', 'P', 'A', 'S', 'S', '=',
+ '0', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A',
+ ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', ' ', 'S', 'R', 'A', '_',
+ 'R', 'E', 'A', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', '_', 'R', 'E', 'J', 'E', 'C',
+ 'T', '=', '1', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S',
+ 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', ' ', 'S', 'R',
+ 'A', '_', 'R', 'E', 'A', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', '_', 'C', 'R', 'I',
+ 'T', 'E', 'R', 'I', 'A', '=', '2', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S',
+ 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e',
+ 'r', ' ', 'S', 'R', 'A', '_', 'R', 'E', 'A', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R',
+ '_', 'R', 'E', 'D', 'A', 'C', 'T', 'E', 'D', '=', '3', ';', 'c', 'o', 'n', 's', 't',
+ ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd', '_',
+ 't', 'y', 'p', 'e', ' ', 'S', 'R', 'A', '_', 'R', 'E', 'A', 'D', '_', 'T', 'Y', 'P',
+ 'E', '_', 'T', 'E', 'C', 'H', 'N', 'I', 'C', 'A', 'L', '=', '0', ';', 'c', 'o', 'n',
+ 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a',
+ 'd', '_', 't', 'y', 'p', 'e', ' ', 'S', 'R', 'A', '_', 'R', 'E', 'A', 'D', '_', 'T',
+ 'Y', 'P', 'E', '_', 'B', 'I', 'O', 'L', 'O', 'G', 'I', 'C', 'A', 'L', '=', '1', ';',
+ 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x',
+ 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'S', 'R', 'A', '_', 'R', 'E', 'A',
+ 'D', '_', 'T', 'Y', 'P', 'E', '_', 'F', 'O', 'R', 'W', 'A', 'R', 'D', '=', '2', ';',
'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x',
'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'S', 'R', 'A', '_', 'R', 'E', 'A',
- 'D', '_', 'T', 'Y', 'P', 'E', '_', 'T', 'E', 'C', 'H', 'N', 'I', 'C', 'A', 'L', '=',
+ 'D', '_', 'T', 'Y', 'P', 'E', '_', 'R', 'E', 'V', 'E', 'R', 'S', 'E', '=', '4', ';',
+ 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p',
+ 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S', 'R', 'A', '_', 'P', 'L',
+ 'A', 'T', 'F', 'O', 'R', 'M', '_', 'U', 'N', 'D', 'E', 'F', 'I', 'N', 'E', 'D', '=',
'0', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A',
- ':', 'x', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'S', 'R', 'A', '_', 'R',
- 'E', 'A', 'D', '_', 'T', 'Y', 'P', 'E', '_', 'B', 'I', 'O', 'L', 'O', 'G', 'I', 'C',
- 'A', 'L', '=', '1', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':',
- 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'S', 'R',
- 'A', '_', 'R', 'E', 'A', 'D', '_', 'T', 'Y', 'P', 'E', '_', 'F', 'O', 'R', 'W', 'A',
- 'R', 'D', '=', '2', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':',
- 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'S', 'R',
- 'A', '_', 'R', 'E', 'A', 'D', '_', 'T', 'Y', 'P', 'E', '_', 'R', 'E', 'V', 'E', 'R',
- 'S', 'E', '=', '4', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':',
- 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S',
- 'R', 'A', '_', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '_', 'U', 'N', 'D', 'E', 'F',
- 'I', 'N', 'E', 'D', '=', '0', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D',
- 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd',
- ' ', 'S', 'R', 'A', '_', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '_', '4', '5', '4',
- '=', '1', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R',
- 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S', 'R', 'A',
- '_', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '_', 'I', 'L', 'L', 'U', 'M', 'I', 'N',
- 'A', '=', '2', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S',
- 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S', 'R',
- 'A', '_', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '_', 'A', 'B', 'S', 'O', 'L', 'I',
- 'D', '=', '3', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S',
- 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S', 'R',
- 'A', '_', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '_', 'C', 'O', 'M', 'P', 'L', 'E',
- 'T', 'E', '_', 'G', 'E', 'N', 'O', 'M', 'I', 'C', 'S', '=', '4', ';', 'c', 'o', 'n',
- 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't',
- 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S', 'R', 'A', '_', 'P', 'L', 'A', 'T', 'F',
- 'O', 'R', 'M', '_', 'H', 'E', 'L', 'I', 'C', 'O', 'S', '=', '5', ';', 'c', 'o', 'n',
- 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't',
- 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S', 'R', 'A', '_', 'P', 'L', 'A', 'T', 'F',
- 'O', 'R', 'M', '_', 'P', 'A', 'C', 'B', 'I', 'O', '_', 'S', 'M', 'R', 'T', '=', '6',
- ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':',
- 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S', 'R', 'A', '_', 'P',
- 'L', 'A', 'T', 'F', 'O', 'R', 'M', '_', 'I', 'O', 'N', '_', 'T', 'O', 'R', 'R', 'E',
- 'N', 'T', '=', '7', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':',
- 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S',
- 'R', 'A', '_', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '_', 'S', 'A', 'N', 'G', 'E',
- 'R', '=', '8', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'q',
- 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'N',
- 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'f', 'r', 'o', 'm', ':',
- 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '=', '[', '-', '6', ',', '-', '5', ',', '-',
- '4', ',', '-', '3', ',', '-', '2', ',', '-', '1', ',', '0', ',', '1', ',', '2', ',',
- '3', ',', '4', ',', '5', ',', '6', ',', '7', ',', '8', ',', '9', ',', '1', '0', ',',
- '1', '1', ',', '1', '2', ',', '1', '3', ',', '1', '4', ',', '1', '5', ',', '1', '6',
- ',', '1', '7', ',', '1', '8', ',', '1', '9', ',', '2', '0', ',', '2', '1', ',', '2',
- '2', ',', '2', '3', ',', '2', '4', ',', '2', '5', ',', '2', '6', ',', '2', '7', ',',
- '2', '8', ',', '2', '9', ',', '3', '0', ',', '3', '1', ',', '3', '2', ',', '3', '3',
- ',', '3', '4', ',', '3', '5', ',', '3', '6', ',', '3', '7', ',', '3', '8', ',', '3',
- '9', ',', '4', '0', ']', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C',
- ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'N', 'C',
- 'B', 'I', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 't', 'o', ':', 'p', 'h', 'r',
- 'e', 'd', '=', '[', '0', ',', '1', ',', '1', ',', '2', ',', '2', ',', '3', ',', '3',
- ',', '4', ',', '4', ',', '5', ',', '5', ',', '6', ',', '7', ',', '8', ',', '9', ',',
- '1', '0', ',', '1', '0', ',', '1', '1', ',', '1', '2', ',', '1', '3', ',', '1', '4',
- ',', '1', '5', ',', '1', '6', ',', '1', '7', ',', '1', '8', ',', '1', '9', ',', '2',
- '0', ',', '2', '1', ',', '2', '2', ',', '2', '3', ',', '2', '4', ',', '2', '5', ',',
- '2', '6', ',', '2', '7', ',', '2', '8', ',', '2', '9', ',', '3', '0', ',', '3', '1',
- ',', '3', '2', ',', '3', '3', ',', '3', '4', ',', '3', '5', ',', '3', '6', ',', '3',
- '7', ',', '3', '8', ',', '3', '9', ',', '4', '0', ']', ';', 'c', 'o', 'n', 's', 't',
- ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm',
- 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'u', 'n', 'r', 'e', 'c', 'o', 'g', 'n', 'i',
- 'z', 'e', 'd', '=', '1', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e',
- 'n', ':', 'r', 'e', 'c', 'o', 'g', 'n', 'i', 'z', 'e', 'd', '=', '2', ';', 'c', 'o',
- 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'Q', '=', '3', ';', 'c', 'o',
- 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'X', '=', '4', ';', 'c', 'o',
- 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'Y', '=', '5', ';', 'c', 'o',
- 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'T', '=', '6', ';', 'c', 'o',
- 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'L', '=', '7', ';', 'c', 'o',
+ ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S', 'R', 'A', '_',
+ 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '_', '4', '5', '4', '=', '1', ';', 'c', 'o',
+ 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a',
+ 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S', 'R', 'A', '_', 'P', 'L', 'A', 'T',
+ 'F', 'O', 'R', 'M', '_', 'I', 'L', 'L', 'U', 'M', 'I', 'N', 'A', '=', '2', ';', 'c',
+ 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l',
+ 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S', 'R', 'A', '_', 'P', 'L', 'A',
+ 'T', 'F', 'O', 'R', 'M', '_', 'A', 'B', 'S', 'O', 'L', 'I', 'D', '=', '3', ';', 'c',
+ 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l',
+ 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S', 'R', 'A', '_', 'P', 'L', 'A',
+ 'T', 'F', 'O', 'R', 'M', '_', 'C', 'O', 'M', 'P', 'L', 'E', 'T', 'E', '_', 'G', 'E',
+ 'N', 'O', 'M', 'I', 'C', 'S', '=', '4', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N',
+ 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_',
+ 'i', 'd', ' ', 'S', 'R', 'A', '_', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '_', 'H',
+ 'E', 'L', 'I', 'C', 'O', 'S', '=', '5', ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N',
+ 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_',
+ 'i', 'd', ' ', 'S', 'R', 'A', '_', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '_', 'P',
+ 'A', 'C', 'B', 'I', 'O', '_', 'S', 'M', 'R', 'T', '=', '6', ';', 'c', 'o', 'n', 's',
+ 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f',
+ 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S', 'R', 'A', '_', 'P', 'L', 'A', 'T', 'F', 'O',
+ 'R', 'M', '_', 'I', 'O', 'N', '_', 'T', 'O', 'R', 'R', 'E', 'N', 'T', '=', '7', ';',
+ 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p',
+ 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'S', 'R', 'A', '_', 'P', 'L',
+ 'A', 'T', 'F', 'O', 'R', 'M', '_', 'S', 'A', 'N', 'G', 'E', 'R', '=', '8', ';', 'c',
+ 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't',
+ 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'N', 'C', 'B', 'I', ':', 'q',
+ 'u', 'a', 'l', 'i', 't', 'y', ':', 'f', 'r', 'o', 'm', ':', 'l', 'o', 'g', '_', 'o',
+ 'd', 'd', 's', '=', '[', '-', '6', ',', '-', '5', ',', '-', '4', ',', '-', '3', ',',
+ '-', '2', ',', '-', '1', ',', '0', ',', '1', ',', '2', ',', '3', ',', '4', ',', '5',
+ ',', '6', ',', '7', ',', '8', ',', '9', ',', '1', '0', ',', '1', '1', ',', '1', '2',
+ ',', '1', '3', ',', '1', '4', ',', '1', '5', ',', '1', '6', ',', '1', '7', ',', '1',
+ '8', ',', '1', '9', ',', '2', '0', ',', '2', '1', ',', '2', '2', ',', '2', '3', ',',
+ '2', '4', ',', '2', '5', ',', '2', '6', ',', '2', '7', ',', '2', '8', ',', '2', '9',
+ ',', '3', '0', ',', '3', '1', ',', '3', '2', ',', '3', '3', ',', '3', '4', ',', '3',
+ '5', ',', '3', '6', ',', '3', '7', ',', '3', '8', ',', '3', '9', ',', '4', '0', ']',
+ ';', 'c', 'o', 'n', 's', 't', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l',
+ 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'q', 'u',
+ 'a', 'l', 'i', 't', 'y', ':', 't', 'o', ':', 'p', 'h', 'r', 'e', 'd', '=', '[', '0',
+ ',', '1', ',', '1', ',', '2', ',', '2', ',', '3', ',', '3', ',', '4', ',', '4', ',',
+ '5', ',', '5', ',', '6', ',', '7', ',', '8', ',', '9', ',', '1', '0', ',', '1', '0',
+ ',', '1', '1', ',', '1', '2', ',', '1', '3', ',', '1', '4', ',', '1', '5', ',', '1',
+ '6', ',', '1', '7', ',', '1', '8', ',', '1', '9', ',', '2', '0', ',', '2', '1', ',',
+ '2', '2', ',', '2', '3', ',', '2', '4', ',', '2', '5', ',', '2', '6', ',', '2', '7',
+ ',', '2', '8', ',', '2', '9', ',', '3', '0', ',', '3', '1', ',', '3', '2', ',', '3',
+ '3', ',', '3', '4', ',', '3', '5', ',', '3', '6', ',', '3', '7', ',', '3', '8', ',',
+ '3', '9', ',', '4', '0', ']', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k',
+ 'e', 'n', ':', 'u', 'n', 'r', 'e', 'c', 'o', 'g', 'n', 'i', 'z', 'e', 'd', '=', '1',
+ ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'r', 'e', 'c',
+ 'o', 'g', 'n', 'i', 'z', 'e', 'd', '=', '2', ';', 'c', 'o', 'n', 's', 't', ' ', 'U',
+ '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_',
+ 't', 'o', 'k', 'e', 'n', ':', 'Q', '=', '3', ';', 'c', 'o', 'n', 's', 't', ' ', 'U',
+ '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_',
+ 't', 'o', 'k', 'e', 'n', ':', 'X', '=', '4', ';', 'c', 'o', 'n', 's', 't', ' ', 'U',
+ '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_',
+ 't', 'o', 'k', 'e', 'n', ':', 'Y', '=', '5', ';', 'c', 'o', 'n', 's', 't', ' ', 'U',
+ '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_',
+ 't', 'o', 'k', 'e', 'n', ':', 'T', '=', '6', ';', 'c', 'o', 'n', 's', 't', ' ', 'U',
+ '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_',
+ 't', 'o', 'k', 'e', 'n', ':', 'L', '=', '7', ';', 'c', 'o', 'n', 's', 't', ' ', 'U',
+ '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_',
+ 't', 'o', 'k', 'e', 'n', ':', 's', 'i', 'g', 'n', 'e', 'd', ':', 'X', '=', '8', ';',
+ 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 's', 'i', 'g', 'n',
+ 'e', 'd', ':', 'Y', '=', '9', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k',
+ 'e', 'n', ':', 's', 'i', 'g', 'n', 'e', 'd', ':', 'T', '=', '1', '0', ';', 'c', 'o',
'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 's', 'i', 'g', 'n', 'e', 'd',
- ':', 'X', '=', '8', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n',
- ':', 's', 'i', 'g', 'n', 'e', 'd', ':', 'Y', '=', '9', ';', 'c', 'o', 'n', 's', 't',
- ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm',
- 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 's', 'i', 'g', 'n', 'e', 'd', ':', 'T', '=',
- '1', '0', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 's',
- 'i', 'g', 'n', 'e', 'd', ':', 'L', '=', '1', '1', ';', 'c', 'o', 'n', 's', 't', ' ',
+ ':', 'L', '=', '1', '1', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e',
+ 'n', ':', 'o', 'c', 't', 'a', 'l', ':', 'X', '=', '1', '2', ';', 'c', 'o', 'n', 's',
+ 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a',
+ 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'o', 'c', 't', 'a', 'l', ':', 'Y', '=',
+ '1', '3', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I',
+ ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'o',
+ 'c', 't', 'a', 'l', ':', 'T', '=', '1', '4', ';', 'c', 'o', 'n', 's', 't', ' ', 'U',
+ '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_',
+ 't', 'o', 'k', 'e', 'n', ':', 'o', 'c', 't', 'a', 'l', ':', 'L', '=', '1', '5', ';',
+ 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'h', 'e', 'x', ':',
+ 'u', 'p', 'p', 'e', 'r', ':', 'X', '=', '1', '6', ';', 'c', 'o', 'n', 's', 't', ' ',
'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e',
- '_', 't', 'o', 'k', 'e', 'n', ':', 'o', 'c', 't', 'a', 'l', ':', 'X', '=', '1', '2',
- ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'o', 'c', 't',
- 'a', 'l', ':', 'Y', '=', '1', '3', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6',
- ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o',
- 'k', 'e', 'n', ':', 'o', 'c', 't', 'a', 'l', ':', 'T', '=', '1', '4', ';', 'c', 'o',
- 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'o', 'c', 't', 'a', 'l', ':',
- 'L', '=', '1', '5', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C',
+ '_', 't', 'o', 'k', 'e', 'n', ':', 'h', 'e', 'x', ':', 'u', 'p', 'p', 'e', 'r', ':',
+ 'Y', '=', '1', '7', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C',
'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n',
- ':', 'h', 'e', 'x', ':', 'u', 'p', 'p', 'e', 'r', ':', 'X', '=', '1', '6', ';', 'c',
+ ':', 'h', 'e', 'x', ':', 'u', 'p', 'p', 'e', 'r', ':', 'T', '=', '1', '8', ';', 'c',
'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'h', 'e', 'x', ':', 'u',
- 'p', 'p', 'e', 'r', ':', 'Y', '=', '1', '7', ';', 'c', 'o', 'n', 's', 't', ' ', 'U',
+ 'p', 'p', 'e', 'r', ':', 'L', '=', '1', '9', ';', 'c', 'o', 'n', 's', 't', ' ', 'U',
'1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_',
- 't', 'o', 'k', 'e', 'n', ':', 'h', 'e', 'x', ':', 'u', 'p', 'p', 'e', 'r', ':', 'T',
- '=', '1', '8', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B',
+ 't', 'o', 'k', 'e', 'n', ':', 'h', 'e', 'x', ':', 'l', 'o', 'w', 'e', 'r', ':', 'X',
+ '=', '2', '0', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B',
'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':',
- 'h', 'e', 'x', ':', 'u', 'p', 'p', 'e', 'r', ':', 'L', '=', '1', '9', ';', 'c', 'o',
+ 'h', 'e', 'x', ':', 'l', 'o', 'w', 'e', 'r', ':', 'Y', '=', '2', '1', ';', 'c', 'o',
'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'h', 'e', 'x', ':', 'l', 'o',
- 'w', 'e', 'r', ':', 'X', '=', '2', '0', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1',
+ 'w', 'e', 'r', ':', 'T', '=', '2', '2', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1',
'6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 't',
- 'o', 'k', 'e', 'n', ':', 'h', 'e', 'x', ':', 'l', 'o', 'w', 'e', 'r', ':', 'Y', '=',
- '2', '1', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'h',
- 'e', 'x', ':', 'l', 'o', 'w', 'e', 'r', ':', 'T', '=', '2', '2', ';', 'c', 'o', 'n',
- 's', 't', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n',
- 'a', 'm', 'e', '_', 't', 'o', 'k', 'e', 'n', ':', 'h', 'e', 'x', ':', 'l', 'o', 'w',
- 'e', 'r', ':', 'L', '=', '2', '3', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c',
- 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_',
- 's', 'y', 'm', 'b', 'o', 'l', ':', 'Q', '=', '\'', '$', 'Q', '\'', ';', 'c', 'o',
- 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'X', '=', '\'',
- '$', 'X', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i', ' ',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y', 'm',
- 'b', 'o', 'l', ':', 'Y', '=', '\'', '$', 'Y', '\'', ';', 'c', 'o', 'n', 's', 't',
- ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n',
- 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'T', '=', '\'', '$', 'T',
- '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C',
+ 'o', 'k', 'e', 'n', ':', 'h', 'e', 'x', ':', 'l', 'o', 'w', 'e', 'r', ':', 'L', '=',
+ '2', '3', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C',
'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o',
- 'l', ':', 'L', '=', '\'', '$', 'L', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a',
+ 'l', ':', 'Q', '=', '\'', '$', 'Q', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a',
+ 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm',
+ 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'X', '=', '\'', '$', 'X', '\'', ';',
+ 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':',
+ 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'Y',
+ '=', '\'', '$', 'Y', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i',
+ 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's',
+ 'y', 'm', 'b', 'o', 'l', ':', 'T', '=', '\'', '$', 'T', '\'', ';', 'c', 'o', 'n',
+ 's', 't', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', 'n', 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'L', '=', '\'',
+ '$', 'L', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i', ' ',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y', 'm',
+ 'b', 'o', 'l', ':', 'o', 'c', 't', 'a', 'l', ':', 'X', '=', '\'', '$', 'a', '\'',
+ ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I',
+ ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':',
+ 'o', 'c', 't', 'a', 'l', ':', 'Y', '=', '\'', '$', 'b', '\'', ';', 'c', 'o', 'n',
+ 's', 't', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', 'n', 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'o', 'c', 't', 'a',
+ 'l', ':', 'T', '=', '\'', '$', 'c', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a',
's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm',
- 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'o', 'c', 't', 'a', 'l', ':', 'X', '=',
- '\'', '$', 'a', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i',
+ 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'o', 'c', 't', 'a', 'l', ':', 'L', '=',
+ '\'', '$', 'd', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i',
' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y',
- 'm', 'b', 'o', 'l', ':', 'o', 'c', 't', 'a', 'l', ':', 'Y', '=', '\'', '$', 'b',
- '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o',
- 'l', ':', 'o', 'c', 't', 'a', 'l', ':', 'T', '=', '\'', '$', 'c', '\'', ';', 'c',
- 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'o', 'c',
- 't', 'a', 'l', ':', 'L', '=', '\'', '$', 'd', '\'', ';', 'c', 'o', 'n', 's', 't',
- ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n',
- 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'u', 'p',
- 'p', 'e', 'r', ':', 'X', '=', '\'', '$', 'e', '\'', ';', 'c', 'o', 'n', 's', 't',
- ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n',
- 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'u', 'p',
- 'p', 'e', 'r', ':', 'Y', '=', '\'', '$', 'f', '\'', ';', 'c', 'o', 'n', 's', 't',
- ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n',
- 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'u', 'p',
- 'p', 'e', 'r', ':', 'T', '=', '\'', '$', 'g', '\'', ';', 'c', 'o', 'n', 's', 't',
- ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n',
- 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'u', 'p',
- 'p', 'e', 'r', ':', 'L', '=', '\'', '$', 'h', '\'', ';', 'c', 'o', 'n', 's', 't',
- ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n',
- 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'l', 'o',
- 'w', 'e', 'r', ':', 'X', '=', '\'', '$', 'x', '\'', ';', 'c', 'o', 'n', 's', 't',
- ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n',
- 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'l', 'o',
- 'w', 'e', 'r', ':', 'Y', '=', '\'', '$', 'y', '\'', ';', 'c', 'o', 'n', 's', 't',
- ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n',
- 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'l', 'o',
- 'w', 'e', 'r', ':', 'T', '=', '\'', '$', 't', '\'', ';', 'c', 'o', 'n', 's', 't',
- ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n',
- 'a', 'm', 'e', '_', 's', 'y', 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'l', 'o',
- 'w', 'e', 'r', ':', 'L', '=', '\'', '$', 'l', '\'', ';', 'c', 'o', 'n', 's', 't',
- ' ', 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5',
- '4', '_', ':', 'd', 'y', 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '=',
- '0', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'd', 'y', 'n', '_', 'r', 'e', 'a',
- 'd', '_', 's', 't', 'a', 'r', 't', '=', '1', ';', 'c', 'o', 'n', 's', 't', ' ', 'U',
- '3', '2', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_',
- ':', 'd', 'y', 'n', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', '=', '2', ';', 'c',
- 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', 'r', 'e', 'a', 'd', 'n', ':', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '=',
- '0', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', 'n', ':', 'r', 'e', 'a', 'd', '_', 's', 't',
- 'a', 'r', 't', '=', '1', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', 'n', ':', 'r', 'e', 'a',
- 'd', '_', 'l', 'e', 'n', '=', '2', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '3', '2',
- ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', 'n', ':', 'l',
- 'a', 'b', 'e', 'l', '_', 's', 't', 'a', 'r', 't', '=', '3', ';', 'c', 'o', 'n', 's',
+ 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'u', 'p', 'p', 'e', 'r', ':', 'X', '=',
+ '\'', '$', 'e', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y',
+ 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'u', 'p', 'p', 'e', 'r', ':', 'Y', '=',
+ '\'', '$', 'f', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y',
+ 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'u', 'p', 'p', 'e', 'r', ':', 'T', '=',
+ '\'', '$', 'g', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y',
+ 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'u', 'p', 'p', 'e', 'r', ':', 'L', '=',
+ '\'', '$', 'h', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y',
+ 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'l', 'o', 'w', 'e', 'r', ':', 'X', '=',
+ '\'', '$', 'x', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y',
+ 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'l', 'o', 'w', 'e', 'r', ':', 'Y', '=',
+ '\'', '$', 'y', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y',
+ 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'l', 'o', 'w', 'e', 'r', ':', 'T', '=',
+ '\'', '$', 't', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'a', 's', 'c', 'i', 'i',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'a', 'm', 'e', '_', 's', 'y',
+ 'm', 'b', 'o', 'l', ':', 'h', 'e', 'x', ':', 'l', 'o', 'w', 'e', 'r', ':', 'L', '=',
+ '\'', '$', 'l', '\'', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'd', 'y', 'n',
+ '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '=', '0', ';', 'c', 'o', 'n', 's',
+ 't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4',
+ '5', '4', '_', ':', 'd', 'y', 'n', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r',
+ 't', '=', '1', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'd', 'y', 'n', '_', 'r',
+ 'e', 'a', 'd', '_', 'l', 'e', 'n', '=', '2', ';', 'c', 'o', 'n', 's', 't', ' ', 'U',
+ '3', '2', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', 'n',
+ ':', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '=', '0', ';', 'c', 'o', 'n', 's',
't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'e',
- 'a', 'd', 'n', ':', 'l', 'a', 'b', 'e', 'l', '_', 'l', 'e', 'n', '=', '4', ';', 'c',
- 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'y', '=', '0', ';', 'c', 'o', 'n', 's', 't', ' ',
- 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'c', 'o', 'o', 'r',
- 'd', ':', 'x', '=', '1', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'c', 'o', 'o', 'r', 'd', ':', 't', 'i', 'l',
- 'e', '=', '2', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'a', 'n', 'e', '=',
- '3', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'c', 'o', 'o', 'r', 'd', ':', 'r', 'e', 'g', 'i', 'o', 'n', '=',
+ 'a', 'd', 'n', ':', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', '=', '1', ';',
+ 'c', 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'r', 'e', 'a', 'd', 'n', ':', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', '=',
'2', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'c', 'o', 'o', 'r', 'd', ':', 'p', 'a', 'n', 'e', 'l', '=', '2',
- ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
- 'a', 'n', 'y', ' ', 'c', 'a', 's', 't', '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n',
- ')', '=', 'v', 'd', 'b', ':', 'c', 'a', 's', 't', ';', 'e', 'x', 't', 'e', 'r', 'n',
- ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T',
- '>', 'T', ' ', 'b', 'i', 't', '_', 'o', 'r', '#', '1', '<', 'U', '8', ' ', 'a', 'l',
- 'i', 'g', 'n', '>', '(', 'T', ' ', 'A', ',', 'T', ' ', 'B', ')', '=', 'v', 'd', 'b',
- ':', 'b', 'i', 't', '_', 'o', 'r', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u',
- 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ',
- 't', 'r', 'i', 'm', '#', '1', '<', 'U', '8', ' ', 'a', 'l', 'i', 'g', 'n', ',', 'T',
- ' ', 'v', 'a', 'l', '>', '(', 'T', ' ', 'A', ')', '=', 'v', 'd', 'b', ':', 't', 'r',
- 'i', 'm', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
- 'n', ' ', 'a', 'n', 'y', ' ', 'r', 'e', 'd', 'i', 'm', 'e', 'n', 's', 'i', 'o', 'n',
- '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'r', 'e',
- 'd', 'i', 'm', 'e', 'n', 's', 'i', 'o', 'n', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
- 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'I', '6', '4', ' ', 'r', 'o', 'w', '_',
- 'i', 'd', '#', '1', '(', ')', '=', 'v', 'd', 'b', ':', 'r', 'o', 'w', '_', 'i', 'd',
- ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
- 'U', '3', '2', ' ', 'r', 'o', 'w', '_', 'l', 'e', 'n', '#', '1', '(', 'a', 'n', 'y',
- ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'r', 'o', 'w', '_', 'l', 'e', 'n', ';',
- 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'U',
- '3', '2', ' ', 'f', 'i', 'x', 'e', 'd', '_', 'r', 'o', 'w', '_', 'l', 'e', 'n', '#',
- '1', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'f', 'i', 'x',
- 'e', 'd', '_', 'r', 'o', 'w', '_', 'l', 'e', 'n', ';', 'v', 'a', 'l', 'i', 'd', 'a',
- 't', 'e', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e',
- ' ', 'T', '>', 'v', 'o', 'i', 'd', ' ', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1',
- '<', '*', 'U', '3', '2', ' ', 's', 'i', 'g', '_', 'b', 'i', 't', 's', '>', '(', 'T',
- ' ', 's', 'r', 'c', ',', 'T', ' ', 'c', 'm', 'p', ')', '=', 'v', 'd', 'b', ':', 'c',
- 'o', 'm', 'p', 'a', 'r', 'e', ';', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', ' ', 'f',
- 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'v',
- 'o', 'i', 'd', ' ', 'n', 'o', '_', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1', '(',
- 'T', ' ', 's', 'r', 'c', ',', 'T', ' ', 'c', 'm', 'p', ')', '=', 'v', 'd', 'b', ':',
- 'n', 'o', '_', 'c', 'o', 'm', 'p', 'a', 'r', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n',
- ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T',
- '>', 'T', ' ', 'r', 'a', 'n', 'g', 'e', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e',
- '#', '1', '<', 'T', ' ', 'l', 'o', 'w', 'e', 'r', ',', 'T', ' ', 'u', 'p', 'p', 'e',
- 'r', '>', '(', 'T', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'r', 'a', 'n', 'g',
- 'e', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n',
+ 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', 'n', ':', 'l', 'a', 'b', 'e', 'l', '_', 's',
+ 't', 'a', 'r', 't', '=', '3', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', 'n', ':', 'l', 'a',
+ 'b', 'e', 'l', '_', 'l', 'e', 'n', '=', '4', ';', 'c', 'o', 'n', 's', 't', ' ', 'U',
+ '3', '2', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'y', '=', '0', ';', 'c', 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 'c', 'o', 'o', 'r', 'd', ':', 'x', '=', '1', ';',
+ 'c', 'o', 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'c', 'o', 'o', 'r', 'd', ':', 't', 'i', 'l', 'e', '=', '2', ';', 'c', 'o',
+ 'n', 's', 't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 'c', 'o', 'o', 'r', 'd', ':', 'l', 'a', 'n', 'e', '=', '3', ';', 'c', 'o', 'n', 's',
+ 't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'c', 'o',
+ 'o', 'r', 'd', ':', 'r', 'e', 'g', 'i', 'o', 'n', '=', '2', ';', 'c', 'o', 'n', 's',
+ 't', ' ', 'U', '3', '2', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'c', 'o',
+ 'o', 'r', 'd', ':', 'p', 'a', 'n', 'e', 'l', '=', '2', ';', 'e', 'x', 't', 'e', 'r',
+ 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'c', 'a',
+ 's', 't', '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':',
+ 'c', 'a', 's', 't', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
+ 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'b', 'i', 't',
+ '_', 'o', 'r', '#', '1', '<', 'U', '8', ' ', 'a', 'l', 'i', 'g', 'n', '>', '(', 'T',
+ ' ', 'A', ',', 'T', ' ', 'B', ')', '=', 'v', 'd', 'b', ':', 'b', 'i', 't', '_', 'o',
+ 'r', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
+ ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 't', 'r', 'i', 'm', '#', '1',
+ '<', 'U', '8', ' ', 'a', 'l', 'i', 'g', 'n', ',', 'T', ' ', 'v', 'a', 'l', '>', '(',
+ 'T', ' ', 'A', ')', '=', 'v', 'd', 'b', ':', 't', 'r', 'i', 'm', ';', 'e', 'x', 't',
+ 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ',
+ 'r', 'e', 'd', 'i', 'm', 'e', 'n', 's', 'i', 'o', 'n', '#', '1', '(', 'a', 'n', 'y',
+ ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'r', 'e', 'd', 'i', 'm', 'e', 'n', 's',
+ 'i', 'o', 'n', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i',
+ 'o', 'n', ' ', 'I', '6', '4', ' ', 'r', 'o', 'w', '_', 'i', 'd', '#', '1', '(', ')',
+ '=', 'v', 'd', 'b', ':', 'r', 'o', 'w', '_', 'i', 'd', ';', 'e', 'x', 't', 'e', 'r',
+ 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'U', '3', '2', ' ', 'r', 'o',
+ 'w', '_', 'l', 'e', 'n', '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '=', 'v',
+ 'd', 'b', ':', 'r', 'o', 'w', '_', 'l', 'e', 'n', ';', 'e', 'x', 't', 'e', 'r', 'n',
+ ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'U', '3', '2', ' ', 'f', 'i', 'x',
+ 'e', 'd', '_', 'r', 'o', 'w', '_', 'l', 'e', 'n', '#', '1', '(', 'a', 'n', 'y', ' ',
+ 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'f', 'i', 'x', 'e', 'd', '_', 'r', 'o', 'w',
+ '_', 'l', 'e', 'n', ';', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', ' ', 'f', 'u', 'n',
+ 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'v', 'o', 'i',
+ 'd', ' ', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1', '<', '*', 'U', '3', '2', ' ',
+ 's', 'i', 'g', '_', 'b', 'i', 't', 's', '>', '(', 'T', ' ', 's', 'r', 'c', ',', 'T',
+ ' ', 'c', 'm', 'p', ')', '=', 'v', 'd', 'b', ':', 'c', 'o', 'm', 'p', 'a', 'r', 'e',
+ ';', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
+ 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'v', 'o', 'i', 'd', ' ', 'n', 'o',
+ '_', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1', '(', 'T', ' ', 's', 'r', 'c', ',',
+ 'T', ' ', 'c', 'm', 'p', ')', '=', 'v', 'd', 'b', ':', 'n', 'o', '_', 'c', 'o', 'm',
+ 'p', 'a', 'r', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
+ 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'r', 'a', 'n',
+ 'g', 'e', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '#', '1', '<', 'T', ' ', 'l',
+ 'o', 'w', 'e', 'r', ',', 'T', ' ', 'u', 'p', 'p', 'e', 'r', '>', '(', 'T', ' ', 'i',
+ 'n', ')', '=', 'v', 'd', 'b', ':', 'r', 'a', 'n', 'g', 'e', '_', 'v', 'a', 'l', 'i',
+ 'd', 'a', 't', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
+ 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 's', 'e', 'l',
+ 'e', 'c', 't', '#', '1', '(', 'T', ' ', 'f', 'i', 'r', 's', 't', ',', 'T', ' ', 's',
+ 'e', 'c', 'o', 'n', 'd', ',', '.', '.', '.', ')', '=', 'v', 'd', 'b', ':', 's', 'e',
+ 'l', 'e', 'c', 't', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
+ 'i', 'o', 'n', ' ', 't', 'r', 'a', 'n', 's', 'p', 'o', 's', 'e', 'd', '_', 'f', 'm',
+ 't', ' ', 't', 'r', 'a', 'n', 's', 'p', 'o', 's', 'e', '#', '1', '(', 't', 'r', 'a',
+ 'n', 's', 'p', 'o', 's', 'e', '_', 's', 'e', 't', ' ', 'i', 'n', ')', '=', 'v', 'd',
+ 'b', ':', 't', 'r', 'a', 'n', 's', 'p', 'o', 's', 'e', ';', 'e', 'x', 't', 'e', 'r',
+ 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'r', 'a', 'n', 's', 'p',
+ 'o', 's', 'e', '_', 's', 'e', 't', ' ', 'd', 'e', 't', 'r', 'a', 'n', 's', 'p', 'o',
+ 's', 'e', '#', '1', '(', 't', 'r', 'a', 'n', 's', 'p', 'o', 's', 'e', 'd', '_', 'f',
+ 'm', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'd', 'e', 't', 'r', 'a', 'n',
+ 's', 'p', 'o', 's', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c',
+ 't', 'i', 'o', 'n', ' ', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v', 'e', 'r', 'a', 'g',
+ 'e', 'd', '_', 'f', 'm', 't', ' ', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v', 'e', 'r',
+ 'a', 'g', 'e', '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b',
+ ':', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v', 'e', 'r', 'a', 'g', 'e', ';', 'e', 'x',
+ 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y',
+ ' ', 'u', 'n', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v', 'e', 'r', 'a', 'g', 'e', '#',
+ '1', '(', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v', 'e', 'r', 'a', 'g', 'e', 'd', '_',
+ 'f', 'm', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'u', 'n', 'd', 'e', 'l',
+ 't', 'a', '_', 'a', 'v', 'e', 'r', 'a', 'g', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n',
+ ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'm', 'e', 'r', 'g', 'e', 'd', '_',
+ 'f', 'm', 't', ' ', 'm', 'e', 'r', 'g', 'e', '#', '1', '(', 'a', 'n', 'y', ' ', 'i',
+ 'n', ',', '.', '.', '.', ')', '=', 'v', 'd', 'b', ':', 'm', 'e', 'r', 'g', 'e', ';',
+ 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a',
+ 'n', 'y', ' ', 's', 'p', 'l', 'i', 't', '#', '1', '<', 'U', '3', '2', ' ', 'i', 'd',
+ 'x', '>', '(', 'm', 'e', 'r', 'g', 'e', 'd', '_', 'f', 'm', 't', ' ', 'i', 'n', ')',
+ '=', 'v', 'd', 'b', ':', 's', 'p', 'l', 'i', 't', ';', 'e', 'x', 't', 'e', 'r', 'n',
' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T',
- '>', 'T', ' ', 's', 'e', 'l', 'e', 'c', 't', '#', '1', '(', 'T', ' ', 'f', 'i', 'r',
- 's', 't', ',', 'T', ' ', 's', 'e', 'c', 'o', 'n', 'd', ',', '.', '.', '.', ')', '=',
- 'v', 'd', 'b', ':', 's', 'e', 'l', 'e', 'c', 't', ';', 'e', 'x', 't', 'e', 'r', 'n',
- ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'r', 'a', 'n', 's', 'p', 'o',
- 's', 'e', 'd', '_', 'f', 'm', 't', ' ', 't', 'r', 'a', 'n', 's', 'p', 'o', 's', 'e',
- '#', '1', '(', 't', 'r', 'a', 'n', 's', 'p', 'o', 's', 'e', '_', 's', 'e', 't', ' ',
- 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 't', 'r', 'a', 'n', 's', 'p', 'o', 's', 'e',
- ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
- 't', 'r', 'a', 'n', 's', 'p', 'o', 's', 'e', '_', 's', 'e', 't', ' ', 'd', 'e', 't',
- 'r', 'a', 'n', 's', 'p', 'o', 's', 'e', '#', '1', '(', 't', 'r', 'a', 'n', 's', 'p',
- 'o', 's', 'e', 'd', '_', 'f', 'm', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':',
- 'd', 'e', 't', 'r', 'a', 'n', 's', 'p', 'o', 's', 'e', ';', 'e', 'x', 't', 'e', 'r',
- 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'd', 'e', 'l', 't', 'a', '_',
- 'a', 'v', 'e', 'r', 'a', 'g', 'e', 'd', '_', 'f', 'm', 't', ' ', 'd', 'e', 'l', 't',
- 'a', '_', 'a', 'v', 'e', 'r', 'a', 'g', 'e', '#', '1', '(', 'a', 'n', 'y', ' ', 'i',
- 'n', ')', '=', 'v', 'd', 'b', ':', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v', 'e', 'r',
- 'a', 'g', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i',
- 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'u', 'n', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v',
- 'e', 'r', 'a', 'g', 'e', '#', '1', '(', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v', 'e',
- 'r', 'a', 'g', 'e', 'd', '_', 'f', 'm', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b',
- ':', 'u', 'n', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v', 'e', 'r', 'a', 'g', 'e', ';',
- 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'm',
- 'e', 'r', 'g', 'e', 'd', '_', 'f', 'm', 't', ' ', 'm', 'e', 'r', 'g', 'e', '#', '1',
- '(', 'a', 'n', 'y', ' ', 'i', 'n', ',', '.', '.', '.', ')', '=', 'v', 'd', 'b', ':',
- 'm', 'e', 'r', 'g', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c',
- 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 's', 'p', 'l', 'i', 't', '#', '1', '<',
- 'U', '3', '2', ' ', 'i', 'd', 'x', '>', '(', 'm', 'e', 'r', 'g', 'e', 'd', '_', 'f',
- 'm', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 's', 'p', 'l', 'i', 't', ';',
- 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<',
- 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'm', 'e', 't', 'a', ':', 'r', 'e', 'a',
- 'd', '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'o', 'd', 'e', '*', 'b', 'o',
- 'o', 'l', ' ', 'd', 'e', 't', 'e', 'r', 'm', 'i', 'n', 'i', 's', 't', 'i', 'c', '>',
- '(', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
- 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'm', 'e', 't', 'a', ':',
- 'v', 'a', 'l', 'u', 'e', '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'o', 'd',
- 'e', '*', 'b', 'o', 'o', 'l', ' ', 'd', 'e', 't', 'e', 'r', 'm', 'i', 'n', 'i', 's',
- 't', 'i', 'c', '>', '(', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
- 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'm',
- 'e', 't', 'a', ':', 'w', 'r', 'i', 't', 'e', '#', '1', '<', 'a', 's', 'c', 'i', 'i',
- ' ', 'n', 'o', 'd', 'e', '>', '(', 'T', ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e',
- 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 's', 'c', 'i', 'i',
- ' ', 'm', 'e', 't', 'a', ':', 'a', 't', 't', 'r', ':', 'r', 'e', 'a', 'd', '#', '1',
- '<', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'o', 'd', 'e', ',', 'a', 's', 'c', 'i', 'i',
- ' ', 'a', 't', 't', 'r', '*', 'b', 'o', 'o', 'l', ' ', 'd', 'e', 't', 'e', 'r', 'm',
- 'i', 'n', 'i', 's', 't', 'i', 'c', '>', '(', ')', ';', 'e', 'x', 't', 'e', 'r', 'n',
- ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'm',
- 'e', 't', 'a', ':', 'a', 't', 't', 'r', ':', 'w', 'r', 'i', 't', 'e', '#', '1', '<',
- 'a', 's', 'c', 'i', 'i', ' ', 'n', 'o', 'd', 'e', ',', 'a', 's', 'c', 'i', 'i', ' ',
- 'a', 't', 't', 'r', '>', '(', 'a', 's', 'c', 'i', 'i', ' ', 'i', 'n', ')', ';', 'e',
- 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'e',
- 'x', 't', '8', '_', 's', 'e', 't', ' ', 'p', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r',
- ':', 'r', 'e', 'a', 'd', '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm',
- 'e', '*', 'b', 'o', 'o', 'l', ' ', 'd', 'e', 't', 'e', 'r', 'm', 'i', 'n', 'i', 's',
- 't', 'i', 'c', '>', '(', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
- 'c', 't', 'i', 'o', 'n', ' ', 't', 'e', 'x', 't', '8', '_', 's', 'e', 't', ' ', 'e',
- 'n', 'v', 'i', 'r', 'o', 'n', 'm', 'e', 'n', 't', ':', 'r', 'e', 'a', 'd', '#', '1',
- '<', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e', '>', '(', ')', ';', 'e', 'x',
- 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'e', 'x',
- 't', '8', '_', 's', 'e', 't', ' ', 'i', 'd', 'x', ':', 't', 'e', 'x', 't', ':', 'p',
- 'r', 'o', 'j', 'e', 'c', 't', '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'i', 'n',
- 'd', 'e', 'x', '_', 'n', 'a', 'm', 'e', '>', '(', '*', 't', 'e', 'x', 't', '8', '_',
- 's', 'e', 't', ' ', 's', 'u', 'b', 's', 't', 'i', 't', 'u', 't', 'e', ')', ';', 'e',
- 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'e',
- 'x', 't', '8', '_', 's', 'e', 't', ' ', 'i', 'd', 'x', ':', 't', 'e', 'x', 't', ':',
- 'i', 'n', 's', 'e', 'r', 't', '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'i', 'n',
- 'd', 'e', 'x', '_', 'n', 'a', 'm', 'e', '>', '(', 't', 'e', 'x', 't', '8', '_', 's',
- 'e', 't', ' ', 'k', 'e', 'y', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u',
- 'n', 'c', 't', 'i', 'o', 'n', ' ', 'v', 'd', 'b', ':', 'r', 'o', 'w', '_', 'i', 'd',
- '_', 'r', 'a', 'n', 'g', 'e', ' ', 'i', 'd', 'x', ':', 't', 'e', 'x', 't', ':', 'l',
- 'o', 'o', 'k', 'u', 'p', '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'i', 'n', 'd',
- 'e', 'x', '_', 'n', 'a', 'm', 'e', ',', 'a', 's', 'c', 'i', 'i', ' ', 'q', 'u', 'e',
- 'r', 'y', '_', 'b', 'y', '_', 'n', 'a', 'm', 'e', '>', '(', ')', ';', 'e', 'x', 't',
+ '>', 'T', ' ', 'm', 'e', 't', 'a', ':', 'r', 'e', 'a', 'd', '#', '1', '<', 'a', 's',
+ 'c', 'i', 'i', ' ', 'n', 'o', 'd', 'e', '*', 'b', 'o', 'o', 'l', ' ', 'd', 'e', 't',
+ 'e', 'r', 'm', 'i', 'n', 'i', 's', 't', 'i', 'c', '>', '(', ')', ';', 'e', 'x', 't',
'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p',
- 'e', ' ', 'T', '>', 'T', ' ', 'e', 'c', 'h', 'o', '#', '1', '<', 'T', ' ', 'v', 'a',
- 'l', '>', '(', '*', 'a', 'n', 'y', ' ', 'r', 'o', 'w', '_', 'l', 'e', 'n', ')', '=',
- 'v', 'd', 'b', ':', 'e', 'c', 'h', 'o', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f',
- 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T',
- ' ', 'e', 'x', 'i', 's', 't', 's', '#', '1', '<', '*', 'T', ' ', 'c', 'v', 'a', 'l',
- '>', '(', 'a', 'n', 'y', ' ', 'p', 'r', 'e', 'd', 'i', 'c', 'a', 't', 'e', '*', 'T',
- ' ', 'd', 'v', 'a', 'l', ')', '=', 'v', 'd', 'b', ':', 'e', 'x', 'i', 's', 't', 's',
+ 'e', ' ', 'T', '>', 'T', ' ', 'm', 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#',
+ '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'o', 'd', 'e', '*', 'b', 'o', 'o', 'l',
+ ' ', 'd', 'e', 't', 'e', 'r', 'm', 'i', 'n', 'i', 's', 't', 'i', 'c', '>', '(', ')',
';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
- '<', 't', 'y', 'p', 'e', ' ', 'A', ',', 't', 'y', 'p', 'e', ' ', 'B', '>', 'B', ' ',
- 'm', 'a', 'p', '#', '1', '<', 'A', ' ', 'f', 'r', 'o', 'm', ',', 'B', ' ', 't', 'o',
- '>', '(', 'A', ' ', 'i', 'n', '*', 'B', ' ', 's', 'r', 'c', ')', '=', 'v', 'd', 'b',
- ':', 'm', 'a', 'p', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
- 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'c', 'l', 'i',
- 'p', '#', '1', '<', 'T', ' ', 'l', 'o', 'w', 'e', 'r', ',', 'T', ' ', 'u', 'p', 'p',
- 'e', 'r', '>', '(', 'T', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'c', 'l', 'i',
- 'p', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
- ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', ',', 'U', '3', '2', ' ', 'd', 'i', 'm', '>',
- 'T', '[', 'd', 'i', 'm', ']', ' ', 'v', 'c', 'l', 'i', 'p', '#', '1', '<', 'T', ' ',
- 'l', 'o', 'w', 'e', 'r', ',', 'T', ' ', 'u', 'p', 'p', 'e', 'r', '>', '(', 'T', '[',
- 'd', 'i', 'm', ']', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'c', 'l', 'i', 'p',
+ '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'm', 'e', 't', 'a', ':', 'w', 'r',
+ 'i', 't', 'e', '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'o', 'd', 'e', '>',
+ '(', 'T', ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
+ 'c', 't', 'i', 'o', 'n', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'm', 'e', 't', 'a', ':',
+ 'a', 't', 't', 'r', ':', 'r', 'e', 'a', 'd', '#', '1', '<', 'a', 's', 'c', 'i', 'i',
+ ' ', 'n', 'o', 'd', 'e', ',', 'a', 's', 'c', 'i', 'i', ' ', 'a', 't', 't', 'r', '*',
+ 'b', 'o', 'o', 'l', ' ', 'd', 'e', 't', 'e', 'r', 'm', 'i', 'n', 'i', 's', 't', 'i',
+ 'c', '>', '(', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
+ 'i', 'o', 'n', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'm', 'e', 't', 'a', ':', 'a', 't',
+ 't', 'r', ':', 'w', 'r', 'i', 't', 'e', '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ',
+ 'n', 'o', 'd', 'e', ',', 'a', 's', 'c', 'i', 'i', ' ', 'a', 't', 't', 'r', '>', '(',
+ 'a', 's', 'c', 'i', 'i', ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
+ 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'e', 'x', 't', '8', '_', 's', 'e',
+ 't', ' ', 'p', 'a', 'r', 'a', 'm', 'e', 't', 'e', 'r', ':', 'r', 'e', 'a', 'd', '#',
+ '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e', '*', 'b', 'o', 'o', 'l',
+ ' ', 'd', 'e', 't', 'e', 'r', 'm', 'i', 'n', 'i', 's', 't', 'i', 'c', '>', '(', ')',
';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
- 'n', 'u', 'm', 'e', 'r', 'i', 'c', '_', 's', 'e', 't', ' ', 'c', 'e', 'i', 'l', '#',
- '1', '(', 'f', 'l', 'o', 'a', 't', '_', 's', 'e', 't', ' ', 'i', 'n', ')', '=', 'v',
- 'd', 'b', ':', 'c', 'e', 'i', 'l', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u',
- 'n', 'c', 't', 'i', 'o', 'n', ' ', 'n', 'u', 'm', 'e', 'r', 'i', 'c', '_', 's', 'e',
- 't', ' ', 'f', 'l', 'o', 'o', 'r', '#', '1', '(', 'f', 'l', 'o', 'a', 't', '_', 's',
- 'e', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'f', 'l', 'o', 'o', 'r', ';',
- 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'n',
- 'u', 'm', 'e', 'r', 'i', 'c', '_', 's', 'e', 't', ' ', 'r', 'o', 'u', 'n', 'd', '#',
- '1', '(', 'f', 'l', 'o', 'a', 't', '_', 's', 'e', 't', ' ', 'i', 'n', ')', '=', 'v',
- 'd', 'b', ':', 'r', 'o', 'u', 'n', 'd', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f',
- 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'n', 'u', 'm', 'e', 'r', 'i', 'c', '_', 's',
- 'e', 't', ' ', 't', 'r', 'u', 'n', 'c', '#', '1', '(', 'f', 'l', 'o', 'a', 't', '_',
- 's', 'e', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 't', 'r', 'u', 'n', 'c',
- ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
- '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'm', 'i', 'n', '#', '1', '(', 'T',
- ' ', 'a', ',', 'T', ' ', 'b', ')', '=', 'v', 'd', 'b', ':', 'm', 'i', 'n', ';', 'e',
+ 't', 'e', 'x', 't', '8', '_', 's', 'e', 't', ' ', 'e', 'n', 'v', 'i', 'r', 'o', 'n',
+ 'm', 'e', 'n', 't', ':', 'r', 'e', 'a', 'd', '#', '1', '<', 'a', 's', 'c', 'i', 'i',
+ ' ', 'n', 'a', 'm', 'e', '>', '(', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f',
+ 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'e', 'x', 't', '8', '_', 's', 'e', 't',
+ ' ', 'i', 'd', 'x', ':', 't', 'e', 'x', 't', ':', 'p', 'r', 'o', 'j', 'e', 'c', 't',
+ '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'i', 'n', 'd', 'e', 'x', '_', 'n', 'a',
+ 'm', 'e', '>', '(', '*', 't', 'e', 'x', 't', '8', '_', 's', 'e', 't', ' ', 's', 'u',
+ 'b', 's', 't', 'i', 't', 'u', 't', 'e', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
+ 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'e', 'x', 't', '8', '_', 's', 'e',
+ 't', ' ', 'i', 'd', 'x', ':', 't', 'e', 'x', 't', ':', 'i', 'n', 's', 'e', 'r', 't',
+ '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'i', 'n', 'd', 'e', 'x', '_', 'n', 'a',
+ 'm', 'e', '>', '(', 't', 'e', 'x', 't', '8', '_', 's', 'e', 't', ' ', 'k', 'e', 'y',
+ ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
+ ' ', 'v', 'd', 'b', ':', 'r', 'o', 'w', '_', 'i', 'd', '_', 'r', 'a', 'n', 'g', 'e',
+ ' ', 'i', 'd', 'x', ':', 't', 'e', 'x', 't', ':', 'l', 'o', 'o', 'k', 'u', 'p', '#',
+ '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'i', 'n', 'd', 'e', 'x', '_', 'n', 'a', 'm',
+ 'e', ',', 'a', 's', 'c', 'i', 'i', ' ', 'q', 'u', 'e', 'r', 'y', '_', 'b', 'y', '_',
+ 'n', 'a', 'm', 'e', '>', '(', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u',
+ 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ',
+ 'e', 'c', 'h', 'o', '#', '1', '<', 'T', ' ', 'v', 'a', 'l', '>', '(', '*', 'a', 'n',
+ 'y', ' ', 'r', 'o', 'w', '_', 'l', 'e', 'n', ')', '=', 'v', 'd', 'b', ':', 'e', 'c',
+ 'h', 'o', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
+ 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'e', 'x', 'i', 's', 't',
+ 's', '#', '1', '<', '*', 'T', ' ', 'c', 'v', 'a', 'l', '>', '(', 'a', 'n', 'y', ' ',
+ 'p', 'r', 'e', 'd', 'i', 'c', 'a', 't', 'e', '*', 'T', ' ', 'd', 'v', 'a', 'l', ')',
+ '=', 'v', 'd', 'b', ':', 'e', 'x', 'i', 's', 't', 's', ';', 'e', 'x', 't', 'e', 'r',
+ 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ',
+ 'A', ',', 't', 'y', 'p', 'e', ' ', 'B', '>', 'B', ' ', 'm', 'a', 'p', '#', '1', '<',
+ 'A', ' ', 'f', 'r', 'o', 'm', ',', 'B', ' ', 't', 'o', '>', '(', 'A', ' ', 'i', 'n',
+ '*', 'B', ' ', 's', 'r', 'c', ')', '=', 'v', 'd', 'b', ':', 'm', 'a', 'p', ';', 'e',
'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't',
- 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'm', 'a', 'x', '#', '1', '(', 'T', ' ', 'a',
- ',', 'T', ' ', 'b', ')', '=', 'v', 'd', 'b', ':', 'm', 'a', 'x', ';', 'e', 'x', 't',
- 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p',
- 'e', ' ', 'T', '>', 'T', ' ', 's', 'u', 'm', '#', '1', '<', '*', 'T', ' ', 'k', '>',
- '(', 'T', ' ', 'a', ',', '.', '.', '.', ')', '=', 'v', 'd', 'b', ':', 's', 'u', 'm',
+ 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'c', 'l', 'i', 'p', '#', '1', '<', 'T', ' ',
+ 'l', 'o', 'w', 'e', 'r', ',', 'T', ' ', 'u', 'p', 'p', 'e', 'r', '>', '(', 'T', ' ',
+ 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'c', 'l', 'i', 'p', ';', 'e', 'x', 't', 'e',
+ 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e',
+ ' ', 'T', ',', 'U', '3', '2', ' ', 'd', 'i', 'm', '>', 'T', '[', 'd', 'i', 'm', ']',
+ ' ', 'v', 'c', 'l', 'i', 'p', '#', '1', '<', 'T', ' ', 'l', 'o', 'w', 'e', 'r', ',',
+ 'T', ' ', 'u', 'p', 'p', 'e', 'r', '>', '(', 'T', '[', 'd', 'i', 'm', ']', ' ', 'i',
+ 'n', ')', '=', 'v', 'd', 'b', ':', 'c', 'l', 'i', 'p', ';', 'e', 'x', 't', 'e', 'r',
+ 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'n', 'u', 'm', 'e', 'r', 'i',
+ 'c', '_', 's', 'e', 't', ' ', 'c', 'e', 'i', 'l', '#', '1', '(', 'f', 'l', 'o', 'a',
+ 't', '_', 's', 'e', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'c', 'e', 'i',
+ 'l', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
+ ' ', 'n', 'u', 'm', 'e', 'r', 'i', 'c', '_', 's', 'e', 't', ' ', 'f', 'l', 'o', 'o',
+ 'r', '#', '1', '(', 'f', 'l', 'o', 'a', 't', '_', 's', 'e', 't', ' ', 'i', 'n', ')',
+ '=', 'v', 'd', 'b', ':', 'f', 'l', 'o', 'o', 'r', ';', 'e', 'x', 't', 'e', 'r', 'n',
+ ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'n', 'u', 'm', 'e', 'r', 'i', 'c',
+ '_', 's', 'e', 't', ' ', 'r', 'o', 'u', 'n', 'd', '#', '1', '(', 'f', 'l', 'o', 'a',
+ 't', '_', 's', 'e', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'r', 'o', 'u',
+ 'n', 'd', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
+ 'n', ' ', 'n', 'u', 'm', 'e', 'r', 'i', 'c', '_', 's', 'e', 't', ' ', 't', 'r', 'u',
+ 'n', 'c', '#', '1', '(', 'f', 'l', 'o', 'a', 't', '_', 's', 'e', 't', ' ', 'i', 'n',
+ ')', '=', 'v', 'd', 'b', ':', 't', 'r', 'u', 'n', 'c', ';', 'e', 'x', 't', 'e', 'r',
+ 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ',
+ 'T', '>', 'T', ' ', 'm', 'i', 'n', '#', '1', '(', 'T', ' ', 'a', ',', 'T', ' ', 'b',
+ ')', '=', 'v', 'd', 'b', ':', 'm', 'i', 'n', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
+ 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>',
+ 'T', ' ', 'm', 'a', 'x', '#', '1', '(', 'T', ' ', 'a', ',', 'T', ' ', 'b', ')', '=',
+ 'v', 'd', 'b', ':', 'm', 'a', 'x', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u',
+ 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ',
+ 's', 'u', 'm', '#', '1', '<', '*', 'T', ' ', 'k', '>', '(', 'T', ' ', 'a', ',', '.',
+ '.', '.', ')', '=', 'v', 'd', 'b', ':', 's', 'u', 'm', ';', 'e', 'x', 't', 'e', 'r',
+ 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ',
+ 'T', '>', 'T', ' ', 'd', 'i', 'f', 'f', '#', '1', '<', '*', 'T', ' ', 'k', '>', '(',
+ 'T', ' ', 'a', '*', 'T', ' ', 'b', ')', '=', 'v', 'd', 'b', ':', 'd', 'i', 'f', 'f',
';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
- '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'd', 'i', 'f', 'f', '#', '1', '<',
- '*', 'T', ' ', 'k', '>', '(', 'T', ' ', 'a', '*', 'T', ' ', 'b', ')', '=', 'v', 'd',
- 'b', ':', 'd', 'i', 'f', 'f', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
- 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'd',
- 'e', 'r', 'i', 'v', '#', '1', '(', 'T', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':',
- 'd', 'e', 'r', 'i', 'v', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c',
- 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'i', 'n',
- 't', 'e', 'g', 'r', 'a', 'l', '#', '1', '(', 'T', ' ', 'i', 'n', ')', '=', 'v', 'd',
- 'b', ':', 'i', 'n', 't', 'e', 'g', 'r', 'a', 'l', ';', 'e', 'x', 't', 'e', 'r', 'n',
- ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T',
- '>', 'T', ' ', 'i', 'n', 't', 'e', 'g', 'r', 'a', 'l', '_', '0', '#', '1', '(', 'T',
- ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'i', 'n', 't', 'e', 'g', 'r', 'a', 'l',
- '_', '0', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
- 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'd', 'e', 'l', 't', 'a',
- '#', '1', '(', 'T', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'd', 'e', 'l', 't',
- 'a', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
- ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'u', 'n', 'd', 'e', 'l', 't',
- 'a', '#', '1', '(', 'T', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'u', 'n', 'd',
- 'e', 'l', 't', 'a', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
- 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'o', 'u', 't',
- 'l', 'i', 'e', 'r', '_', 'e', 'n', 'c', 'o', 'd', 'e', '#', '1', '<', 'T', ' ', 'o',
- 'u', 't', 'l', 'i', 'e', 'r', '>', '(', 'T', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b',
- ':', 'o', 'u', 't', 'l', 'i', 'e', 'r', '_', 'e', 'n', 'c', 'o', 'd', 'e', ';', 'e',
+ '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'd', 'e', 'r', 'i', 'v', '#', '1',
+ '(', 'T', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'd', 'e', 'r', 'i', 'v', ';',
+ 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<',
+ 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'i', 'n', 't', 'e', 'g', 'r', 'a', 'l',
+ '#', '1', '(', 'T', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'i', 'n', 't', 'e',
+ 'g', 'r', 'a', 'l', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
+ 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'i', 'n', 't',
+ 'e', 'g', 'r', 'a', 'l', '_', '0', '#', '1', '(', 'T', ' ', 'i', 'n', ')', '=', 'v',
+ 'd', 'b', ':', 'i', 'n', 't', 'e', 'g', 'r', 'a', 'l', '_', '0', ';', 'e', 'x', 't',
+ 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p',
+ 'e', ' ', 'T', '>', 'T', ' ', 'd', 'e', 'l', 't', 'a', '#', '1', '(', 'T', ' ', 'i',
+ 'n', ')', '=', 'v', 'd', 'b', ':', 'd', 'e', 'l', 't', 'a', ';', 'e', 'x', 't', 'e',
+ 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e',
+ ' ', 'T', '>', 'T', ' ', 'u', 'n', 'd', 'e', 'l', 't', 'a', '#', '1', '(', 'T', ' ',
+ 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'u', 'n', 'd', 'e', 'l', 't', 'a', ';', 'e',
'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't',
- 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'o', 'u', 't', 'l', 'i', 'e', 'r', '_', 'd',
- 'e', 'c', 'o', 'd', 'e', '#', '1', '<', 'T', ' ', 'o', 'u', 't', 'l', 'i', 'e', 'r',
+ 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'o', 'u', 't', 'l', 'i', 'e', 'r', '_', 'e',
+ 'n', 'c', 'o', 'd', 'e', '#', '1', '<', 'T', ' ', 'o', 'u', 't', 'l', 'i', 'e', 'r',
'>', '(', 'T', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'o', 'u', 't', 'l', 'i',
- 'e', 'r', '_', 'd', 'e', 'c', 'o', 'd', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
+ 'e', 'r', '_', 'e', 'n', 'c', 'o', 'd', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>',
- 'T', ' ', 'a', 'd', 'd', '_', 'r', 'o', 'w', '_', 'i', 'd', '#', '1', '(', 'T', ' ',
- 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'a', 'd', 'd', '_', 'r', 'o', 'w', '_', 'i',
- 'd', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
- ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 's', 'u', 'b', '_', 'r', 'o',
- 'w', '_', 'i', 'd', '#', '1', '(', 'T', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':',
- 's', 'u', 'b', '_', 'r', 'o', 'w', '_', 'i', 'd', ';', 'e', 'x', 't', 'e', 'r', 'n',
+ 'T', ' ', 'o', 'u', 't', 'l', 'i', 'e', 'r', '_', 'd', 'e', 'c', 'o', 'd', 'e', '#',
+ '1', '<', 'T', ' ', 'o', 'u', 't', 'l', 'i', 'e', 'r', '>', '(', 'T', ' ', 'i', 'n',
+ ')', '=', 'v', 'd', 'b', ':', 'o', 'u', 't', 'l', 'i', 'e', 'r', '_', 'd', 'e', 'c',
+ 'o', 'd', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i',
+ 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'a', 'd', 'd', '_',
+ 'r', 'o', 'w', '_', 'i', 'd', '#', '1', '(', 'T', ' ', 'i', 'n', ')', '=', 'v', 'd',
+ 'b', ':', 'a', 'd', 'd', '_', 'r', 'o', 'w', '_', 'i', 'd', ';', 'e', 'x', 't', 'e',
+ 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e',
+ ' ', 'T', '>', 'T', ' ', 's', 'u', 'b', '_', 'r', 'o', 'w', '_', 'i', 'd', '#', '1',
+ '(', 'T', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 's', 'u', 'b', '_', 'r', 'o',
+ 'w', '_', 'i', 'd', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
+ 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', '[', '*', ']', ' ',
+ 'c', 'u', 't', '#', '1', '<', 'U', '3', '2', ' ', 'i', 'd', 'x', ',', '.', '.', '.',
+ '>', '(', 'T', '[', '*', ']', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'c', 'u',
+ 't', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
+ ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', '[', '*', ']', ' ', 'p', 'a', 's',
+ 't', 'e', '#', '1', '(', 'T', '[', '*', ']', ' ', 'i', 'n', ',', '.', '.', '.', ')',
+ '=', 'v', 'd', 'b', ':', 'p', 'a', 's', 't', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n',
' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T',
- '>', 'T', '[', '*', ']', ' ', 'c', 'u', 't', '#', '1', '<', 'U', '3', '2', ' ', 'i',
- 'd', 'x', ',', '.', '.', '.', '>', '(', 'T', '[', '*', ']', ' ', 'i', 'n', ')', '=',
- 'v', 'd', 'b', ':', 'c', 'u', 't', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u',
- 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', '[',
- '*', ']', ' ', 'p', 'a', 's', 't', 'e', '#', '1', '(', 'T', '[', '*', ']', ' ', 'i',
- 'n', ',', '.', '.', '.', ')', '=', 'v', 'd', 'b', ':', 'p', 'a', 's', 't', 'e', ';',
+ '>', 'T', ' ', 'v', 'e', 'c', '_', 's', 'u', 'm', '#', '1', '(', 'T', '[', '*', ']',
+ ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'v', 'e', 'c', '_', 's', 'u', 'm', ';',
'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<',
- 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'v', 'e', 'c', '_', 's', 'u', 'm', '#',
- '1', '(', 'T', '[', '*', ']', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'v', 'e',
- 'c', '_', 's', 'u', 'm', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c',
- 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'f', 'i',
- 'x', 'e', 'd', '_', 'v', 'e', 'c', '_', 's', 'u', 'm', '#', '1', '(', 'T', '[', '*',
- ']', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'f', 'i', 'x', 'e', 'd', '_', 'v',
- 'e', 'c', '_', 's', 'u', 'm', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
- 'c', 't', 'i', 'o', 'n', ' ', 'b', 'o', 'o', 'l', ' ', 'c', 'h', 'e', 'c', 'k', 's',
- 'u', 'm', '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'o', 'd', 'e', ',', 'a',
- 's', 'c', 'i', 'i', ' ', 'a', 'l', 'g', 'o', 'r', 'i', 't', 'h', 'm', '>', '(', 'B',
- '8', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'c', 'h', 'e', 'c', 'k', 's', 'u',
- 'm', ';', 's', 'c', 'h', 'e', 'm', 'a', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
- ' ', 'b', 'o', 'o', 'l', ' ', 'm', 'd', '5', 's', 'u', 'm', '#', '1', '<', 'a', 's',
- 'c', 'i', 'i', ' ', 'n', 'o', 'd', 'e', '>', '(', 'B', '8', ' ', 'i', 'n', ')', '{',
- 'r', 'e', 't', 'u', 'r', 'n', ' ', 'c', 'h', 'e', 'c', 'k', 's', 'u', 'm', '#', '1',
- '<', 'n', 'o', 'd', 'e', ',', '\'', 'm', 'd', '5', '\'', '>', '(', 'i', 'n', ')',
- ';', '}', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
- ' ', 'B', '1', '[', '*', ']', ' ', 'p', 'a', 'c', 'k', '#', '1', '(', 'p', 'a', 'c',
- 'k', '_', 's', 'e', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'p', 'a', 'c',
- 'k', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
- ' ', 'p', 'a', 'c', 'k', '_', 's', 'e', 't', ' ', 'u', 'n', 'p', 'a', 'c', 'k', '#',
- '1', '(', 'B', '1', '[', '*', ']', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'u',
- 'n', 'p', 'a', 'c', 'k', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c',
- 't', 'i', 'o', 'n', ' ', 'i', 'z', 'i', 'p', '_', 'f', 'm', 't', ' ', 'i', 'z', 'i',
- 'p', '#', '2', '.', '1', '(', 'i', 'z', 'i', 'p', '_', 's', 'e', 't', ' ', 'i', 'n',
- ')', '=', 'v', 'd', 'b', ':', 'i', 'z', 'i', 'p', ';', 'e', 'x', 't', 'e', 'r', 'n',
- ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'i', 'z', 'i', 'p', '_', 's', 'e',
- 't', ' ', 'i', 'u', 'n', 'z', 'i', 'p', '#', '2', '.', '1', '(', 'i', 'z', 'i', 'p',
- '_', 'f', 'm', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'i', 'u', 'n', 'z',
- 'i', 'p', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
- 'n', ' ', 'f', 'z', 'i', 'p', '_', 'f', 'm', 't', ' ', 'f', 'z', 'i', 'p', '#', '1',
- '<', 'U', '3', '2', ' ', 'm', 'a', 'n', 't', 'i', 's', 's', 'a', '>', '(', 'f', 'z',
- 'i', 'p', '_', 's', 'e', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'f', 'z',
- 'i', 'p', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
- 'n', ' ', 'f', 'z', 'i', 'p', '_', 's', 'e', 't', ' ', 'f', 'u', 'n', 'z', 'i', 'p',
- '#', '1', '(', 'f', 'z', 'i', 'p', '_', 'f', 'm', 't', ' ', 'i', 'n', ')', '=', 'v',
- 'd', 'b', ':', 'f', 'u', 'n', 'z', 'i', 'p', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
- 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'r', 'l', 'e', '_', 'f', 'm', 't', ' ',
- 'r', 'l', 'e', 'n', 'c', 'o', 'd', 'e', '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n',
- ')', '=', 'v', 'd', 'b', ':', 'r', 'l', 'e', 'n', 'c', 'o', 'd', 'e', ';', 'e', 'x',
- 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y',
- ' ', 'r', 'l', 'd', 'e', 'c', 'o', 'd', 'e', '#', '1', '(', 'r', 'l', 'e', '_', 'f',
- 'm', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'r', 'l', 'd', 'e', 'c', 'o',
- 'd', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
- 'n', ' ', 'z', 'l', 'i', 'b', '_', 'f', 'm', 't', ' ', 'z', 'i', 'p', '#', '1', '<',
- '*', 'I', '3', '2', ' ', 's', 't', 'r', 'a', 't', 'e', 'g', 'y', ',', 'I', '3', '2',
- ' ', 'l', 'e', 'v', 'e', 'l', '>', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '=', 'v',
- 'd', 'b', ':', 'z', 'i', 'p', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
- 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'u', 'n', 'z', 'i', 'p', '#', '1',
- '(', 'z', 'l', 'i', 'b', '_', 'f', 'm', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b',
- ':', 'u', 'n', 'z', 'i', 'p', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
- 'c', 't', 'i', 'o', 'n', ' ', 'b', 'z', 'i', 'p', '2', '_', 'f', 'm', 't', ' ', 'b',
- 'z', 'i', 'p', '#', '1', '<', '*', 'U', '3', '2', ' ', 'b', 'l', 'o', 'c', 'k', 'S',
- 'i', 'z', 'e', '1', '0', '0', 'k', ',', 'U', '3', '2', ' ', 'w', 'o', 'r', 'k', 'F',
- 'a', 'c', 't', 'o', 'r', '>', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '=', 'v', 'd',
- 'b', ':', 'b', 'z', 'i', 'p', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
- 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'b', 'u', 'n', 'z', 'i', 'p', '#',
- '1', '(', 'b', 'z', 'i', 'p', '2', '_', 'f', 'm', 't', ' ', 'i', 'n', ')', '=', 'v',
- 'd', 'b', ':', 'b', 'u', 'n', 'z', 'i', 'p', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
- 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>',
- 'T', ' ', 's', 'i', 'm', 'p', 'l', 'e', '_', 's', 'u', 'b', '_', 's', 'e', 'l', 'e',
- 'c', 't', '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 't', 'b', 'l', ',', 'a', 's',
- 'c', 'i', 'i', ' ', 'c', 'o', 'l', '>', '(', 'I', '6', '4', ' ', 'r', 'o', 'w', '*',
- 'I', '3', '2', ' ', 'i', 'd', 'x', ')', '=', 'v', 'd', 'b', ':', 's', 'i', 'm', 'p',
- 'l', 'e', '_', 's', 'u', 'b', '_', 's', 'e', 'l', 'e', 'c', 't', '_', '1', ';', 'e',
- 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'e',
- 'x', 't', '_', 's', 'e', 't', ' ', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 't', 'o',
- 'k', 'e', 'n', '#', '1', '<', 'U', '3', '2', ' ', 'i', 'd', 'x', '>', '(', 't', 'e',
- 'x', 't', '_', 's', 'e', 't', ' ', 's', 't', 'r', ',', 't', 'e', 'x', 't', ':', 't',
- 'o', 'k', 'e', 'n', ' ', 't', 'o', 'k', ')', '=', 'v', 'd', 'b', ':', 'e', 'x', 't',
- 'r', 'a', 'c', 't', '_', 't', 'o', 'k', 'e', 'n', ';', 'e', 'x', 't', 'e', 'r', 'n',
- ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'n', 'u', 'm', 'e', 'r', 'i', 'c',
- '_', 's', 'e', 't', ' ', 's', 't', 'r', 't', 'o', 'n', 'u', 'm', '#', '1', '<', '*',
- 'U', '3', '2', ' ', 'r', 'a', 'd', 'i', 'x', '>', '(', 't', 'e', 'x', 't', '_', 's',
- 'e', 't', ' ', 's', 't', 'r', ')', '=', 'v', 'd', 'b', ':', 's', 't', 'r', 't', 'o',
- 'n', 'u', 'm', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i',
- 'o', 'n', ' ', 't', 'e', 'x', 't', '_', 's', 'e', 't', ' ', 's', 'p', 'r', 'i', 'n',
- 't', 'f', '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'f', 'm', 't', '>', '(', 'a',
- 'n', 'y', ' ', 'p', '1', ',', '.', '.', '.', ')', '=', 'v', 'd', 'b', ':', 's', 'p',
- 'r', 'i', 'n', 't', 'f', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c',
- 't', 'i', 'o', 'n', ' ', 'm', 'e', 'r', 'g', 'e', 'd', '_', 't', ' ', 'N', 'C', 'B',
- 'I', ':', 'm', 'e', 'r', 'g', 'e', '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n', ',',
- '.', '.', '.', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
- 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':', 's', 'p', 'l', 'i',
- 't', '#', '1', '<', 'U', '3', '2', ' ', 'i', 'd', 'x', '>', '(', 'm', 'e', 'r', 'g',
- 'e', 'd', '_', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 's', 'p', 'l', 'i',
- 't', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
- ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':', 'c', 'u', 't', '#', '1', '<', 'U',
- '3', '2', ' ', 'i', 'd', 'x', ',', '.', '.', '.', '>', '(', 'a', 'n', 'y', ' ', 'i',
- 'n', ')', '=', 'v', 'd', 'b', ':', 'c', 'u', 't', ';', 'e', 'x', 't', 'e', 'r', 'n',
- ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B',
- 'I', ':', 'p', 'a', 's', 't', 'e', '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n', ',',
- '.', '.', '.', ')', '=', 'v', 'd', 'b', ':', 'p', 'a', 's', 't', 'e', ';', 'e', 'x',
- 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y',
- ' ', 'N', 'C', 'B', 'I', ':', 'p', 'a', 'c', 'k', '#', '1', '<', 'U', '3', '2', ' ',
- 'f', 'r', 'o', 'm', ',', 'U', '3', '2', ' ', 't', 'o', '>', '(', 'a', 'n', 'y', ' ',
- 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i',
- 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':', 'u', 'n', 'p', 'a', 'c',
- 'k', '#', '1', '<', 'U', '3', '2', ' ', 'f', 'r', 'o', 'm', ',', 'U', '3', '2', ' ',
- 't', 'o', '>', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r',
- 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C',
- 'B', 'I', ':', 'f', 'p', '_', 'd', 'e', 'c', 'o', 'd', 'e', '#', '1', '(', 'f', 'p',
- '_', 'e', 'n', 'c', 'o', 'd', 'e', 'd', '_', 't', ' ', 'i', 'n', ')', ';', 'e', 'x',
+ 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'f', 'i', 'x', 'e', 'd', '_', 'v', 'e',
+ 'c', '_', 's', 'u', 'm', '#', '1', '(', 'T', '[', '*', ']', ' ', 'i', 'n', ')', '=',
+ 'v', 'd', 'b', ':', 'f', 'i', 'x', 'e', 'd', '_', 'v', 'e', 'c', '_', 's', 'u', 'm',
+ ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
+ 'b', 'o', 'o', 'l', ' ', 'c', 'h', 'e', 'c', 'k', 's', 'u', 'm', '#', '1', '<', 'a',
+ 's', 'c', 'i', 'i', ' ', 'n', 'o', 'd', 'e', ',', 'a', 's', 'c', 'i', 'i', ' ', 'a',
+ 'l', 'g', 'o', 'r', 'i', 't', 'h', 'm', '>', '(', 'B', '8', ' ', 'i', 'n', ')', '=',
+ 'v', 'd', 'b', ':', 'c', 'h', 'e', 'c', 'k', 's', 'u', 'm', ';', 's', 'c', 'h', 'e',
+ 'm', 'a', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'b', 'o', 'o', 'l', ' ',
+ 'm', 'd', '5', 's', 'u', 'm', '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'o',
+ 'd', 'e', '>', '(', 'B', '8', ' ', 'i', 'n', ')', '{', 'r', 'e', 't', 'u', 'r', 'n',
+ ' ', 'c', 'h', 'e', 'c', 'k', 's', 'u', 'm', '#', '1', '<', 'n', 'o', 'd', 'e', ',',
+ '\'', 'm', 'd', '5', '\'', '>', '(', 'i', 'n', ')', ';', '}', 'e', 'x', 't', 'e',
+ 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'B', '1', '[', '*', ']',
+ ' ', 'p', 'a', 'c', 'k', '#', '1', '(', 'p', 'a', 'c', 'k', '_', 's', 'e', 't', ' ',
+ 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'p', 'a', 'c', 'k', ';', 'e', 'x', 't', 'e',
+ 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'p', 'a', 'c', 'k', '_',
+ 's', 'e', 't', ' ', 'u', 'n', 'p', 'a', 'c', 'k', '#', '1', '(', 'B', '1', '[', '*',
+ ']', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'u', 'n', 'p', 'a', 'c', 'k', ';',
+ 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'i',
+ 'z', 'i', 'p', '_', 'f', 'm', 't', ' ', 'i', 'z', 'i', 'p', '#', '2', '.', '1', '(',
+ 'i', 'z', 'i', 'p', '_', 's', 'e', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':',
+ 'i', 'z', 'i', 'p', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
+ 'i', 'o', 'n', ' ', 'i', 'z', 'i', 'p', '_', 's', 'e', 't', ' ', 'i', 'u', 'n', 'z',
+ 'i', 'p', '#', '2', '.', '1', '(', 'i', 'z', 'i', 'p', '_', 'f', 'm', 't', ' ', 'i',
+ 'n', ')', '=', 'v', 'd', 'b', ':', 'i', 'u', 'n', 'z', 'i', 'p', ';', 'e', 'x', 't',
+ 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'f', 'z', 'i', 'p',
+ '_', 'f', 'm', 't', ' ', 'f', 'z', 'i', 'p', '#', '1', '<', 'U', '3', '2', ' ', 'm',
+ 'a', 'n', 't', 'i', 's', 's', 'a', '>', '(', 'f', 'z', 'i', 'p', '_', 's', 'e', 't',
+ ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'f', 'z', 'i', 'p', ';', 'e', 'x', 't',
+ 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'f', 'z', 'i', 'p',
+ '_', 's', 'e', 't', ' ', 'f', 'u', 'n', 'z', 'i', 'p', '#', '1', '(', 'f', 'z', 'i',
+ 'p', '_', 'f', 'm', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'f', 'u', 'n',
+ 'z', 'i', 'p', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i',
+ 'o', 'n', ' ', 'r', 'l', 'e', '_', 'f', 'm', 't', ' ', 'r', 'l', 'e', 'n', 'c', 'o',
+ 'd', 'e', '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':',
+ 'r', 'l', 'e', 'n', 'c', 'o', 'd', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f',
+ 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'r', 'l', 'd', 'e', 'c',
+ 'o', 'd', 'e', '#', '1', '(', 'r', 'l', 'e', '_', 'f', 'm', 't', ' ', 'i', 'n', ')',
+ '=', 'v', 'd', 'b', ':', 'r', 'l', 'd', 'e', 'c', 'o', 'd', 'e', ';', 'e', 'x', 't',
+ 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'z', 'l', 'i', 'b',
+ '_', 'f', 'm', 't', ' ', 'z', 'i', 'p', '#', '1', '<', '*', 'I', '3', '2', ' ', 's',
+ 't', 'r', 'a', 't', 'e', 'g', 'y', ',', 'I', '3', '2', ' ', 'l', 'e', 'v', 'e', 'l',
+ '>', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'z', 'i', 'p',
+ ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
+ 'a', 'n', 'y', ' ', 'u', 'n', 'z', 'i', 'p', '#', '1', '(', 'z', 'l', 'i', 'b', '_',
+ 'f', 'm', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'u', 'n', 'z', 'i', 'p',
+ ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
+ 'b', 'z', 'i', 'p', '2', '_', 'f', 'm', 't', ' ', 'b', 'z', 'i', 'p', '#', '1', '<',
+ '*', 'U', '3', '2', ' ', 'b', 'l', 'o', 'c', 'k', 'S', 'i', 'z', 'e', '1', '0', '0',
+ 'k', ',', 'U', '3', '2', ' ', 'w', 'o', 'r', 'k', 'F', 'a', 'c', 't', 'o', 'r', '>',
+ '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'b', 'z', 'i', 'p',
+ ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
+ 'a', 'n', 'y', ' ', 'b', 'u', 'n', 'z', 'i', 'p', '#', '1', '(', 'b', 'z', 'i', 'p',
+ '2', '_', 'f', 'm', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'b', 'u', 'n',
+ 'z', 'i', 'p', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i',
+ 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 's', 'i', 'm', 'p',
+ 'l', 'e', '_', 's', 'u', 'b', '_', 's', 'e', 'l', 'e', 'c', 't', '#', '1', '<', 'a',
+ 's', 'c', 'i', 'i', ' ', 't', 'b', 'l', ',', 'a', 's', 'c', 'i', 'i', ' ', 'c', 'o',
+ 'l', '>', '(', 'I', '6', '4', ' ', 'r', 'o', 'w', '*', 'I', '3', '2', ' ', 'i', 'd',
+ 'x', ')', '=', 'v', 'd', 'b', ':', 's', 'i', 'm', 'p', 'l', 'e', '_', 's', 'u', 'b',
+ '_', 's', 'e', 'l', 'e', 'c', 't', '_', '1', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
+ 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'e', 'x', 't', '_', 's', 'e', 't',
+ ' ', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 't', 'o', 'k', 'e', 'n', '#', '1', '<',
+ 'U', '3', '2', ' ', 'i', 'd', 'x', '>', '(', 't', 'e', 'x', 't', '_', 's', 'e', 't',
+ ' ', 's', 't', 'r', ',', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 't',
+ 'o', 'k', ')', '=', 'v', 'd', 'b', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 't',
+ 'o', 'k', 'e', 'n', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
+ 'i', 'o', 'n', ' ', 'n', 'u', 'm', 'e', 'r', 'i', 'c', '_', 's', 'e', 't', ' ', 's',
+ 't', 'r', 't', 'o', 'n', 'u', 'm', '#', '1', '<', '*', 'U', '3', '2', ' ', 'r', 'a',
+ 'd', 'i', 'x', '>', '(', 't', 'e', 'x', 't', '_', 's', 'e', 't', ' ', 's', 't', 'r',
+ ')', '=', 'v', 'd', 'b', ':', 's', 't', 'r', 't', 'o', 'n', 'u', 'm', ';', 'e', 'x',
+ 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'e', 'x',
+ 't', '_', 's', 'e', 't', ' ', 's', 'p', 'r', 'i', 'n', 't', 'f', '#', '1', '<', 'a',
+ 's', 'c', 'i', 'i', ' ', 'f', 'm', 't', '>', '(', 'a', 'n', 'y', ' ', 'p', '1', ',',
+ '.', '.', '.', ')', '=', 'v', 'd', 'b', ':', 's', 'p', 'r', 'i', 'n', 't', 'f', ';',
+ 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'm',
+ 'e', 'r', 'g', 'e', 'd', '_', 't', ' ', 'N', 'C', 'B', 'I', ':', 'm', 'e', 'r', 'g',
+ 'e', '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n', ',', '.', '.', '.', ')', ';', 'e',
+ 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n',
+ 'y', ' ', 'N', 'C', 'B', 'I', ':', 's', 'p', 'l', 'i', 't', '#', '1', '<', 'U', '3',
+ '2', ' ', 'i', 'd', 'x', '>', '(', 'm', 'e', 'r', 'g', 'e', 'd', '_', 't', ' ', 'i',
+ 'n', ')', '=', 'v', 'd', 'b', ':', 's', 'p', 'l', 'i', 't', ';', 'e', 'x', 't', 'e',
+ 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N',
+ 'C', 'B', 'I', ':', 'c', 'u', 't', '#', '1', '<', 'U', '3', '2', ' ', 'i', 'd', 'x',
+ ',', '.', '.', '.', '>', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b',
+ ':', 'c', 'u', 't', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
+ 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':', 'p', 'a', 's', 't',
+ 'e', '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n', ',', '.', '.', '.', ')', '=', 'v',
+ 'd', 'b', ':', 'p', 'a', 's', 't', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f',
+ 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':',
+ 'p', 'a', 'c', 'k', '#', '1', '<', 'U', '3', '2', ' ', 'f', 'r', 'o', 'm', ',', 'U',
+ '3', '2', ' ', 't', 'o', '>', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', ';', 'e', 'x',
't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y',
- ' ', 'N', 'C', 'B', 'I', ':', 'f', 'p', '_', 'e', 'x', 't', 'e', 'n', 'd', '#', '1',
- '<', 'U', '3', '2', ' ', 'b', 'i', 't', 's', '>', '(', 'N', 'C', 'B', 'I', ':', 'f',
- 'p', '_', 'e', 'n', 'c', 'o', 'd', 'e', 'd', '_', 't', ' ', 'i', 'n', ')', ';', 'e',
- 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'r', 'l',
- '_', 'e', 'n', 'c', 'o', 'd', 'e', 'd', '_', 't', ' ', 'N', 'C', 'B', 'I', ':', 'r',
- 'u', 'n', '_', 'l', 'e', 'n', 'g', 't', 'h', '_', 'e', 'n', 'c', 'o', 'd', 'e', '#',
- '1', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'r', 'l', 'e',
- 'n', 'c', 'o', 'd', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c',
- 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':', 'r', 'u', 'n',
- '_', 'l', 'e', 'n', 'g', 't', 'h', '_', 'd', 'e', 'c', 'o', 'd', 'e', '#', '1', '(',
- 'r', 'l', '_', 'e', 'n', 'c', 'o', 'd', 'e', 'd', '_', 't', ' ', 'i', 'n', ')', '=',
- 'v', 'd', 'b', ':', 'r', 'l', 'd', 'e', 'c', 'o', 'd', 'e', ';', 'e', 'x', 't', 'e',
- 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':',
- 'z', 'l', 'i', 'b', '_', 'e', 'n', 'c', 'o', 'd', 'e', 'd', '_', 't', ' ', 'N', 'C',
- 'B', 'I', ':', 'z', 'l', 'i', 'b', '#', '1', '<', '*', 'I', '3', '2', ' ', 's', 't',
- 'r', 'a', 't', 'e', 'g', 'y', ',', 'I', '3', '2', ' ', 'l', 'e', 'v', 'e', 'l', '>',
- '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'z', 'i', 'p', ';',
- 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a',
- 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':', 'u', 'n', 'z', 'i', 'p', '#', '1', '(', 'N',
- 'C', 'B', 'I', ':', 'z', 'l', 'i', 'b', '_', 'e', 'n', 'c', 'o', 'd', 'e', 'd', '_',
- 't', ' ', 'i', 'n', ')', ';', 'a', 'l', 'i', 'a', 's', ' ', 'N', 'C', 'B', 'I', ':',
- 'u', 'n', 'z', 'i', 'p', ' ', 'N', 'C', 'B', 'I', ':', 'z', 'l', 'i', 'b', '_', 'd',
- 'e', 'c', 'o', 'm', 'p', 'r', 'e', 's', 's', ';', 's', 'c', 'h', 'e', 'm', 'a', ' ',
- 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'z', 'l', 'i',
- 'b', '_', 'e', 'n', 'c', 'o', 'd', 'e', 'd', '_', 't', ' ', 'N', 'C', 'B', 'I', ':',
- 'z', 'l', 'i', 'b', '_', 'h', 'u', 'f', 'f', 'm', 'a', 'n', '_', 'c', 'o', 'm', 'p',
- 'r', 'e', 's', 's', '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '{', 'r', 'e',
- 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'z', 'l', 'i', 'b', '#', '1', '<',
- '3', '>', '(', 'i', 'n', ')', ';', '}', 's', 'c', 'h', 'e', 'm', 'a', ' ', 'f', 'u',
- 'n', 'c', 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'z', 'l', 'i', 'b', '_',
- 'e', 'n', 'c', 'o', 'd', 'e', 'd', '_', 't', ' ', 'N', 'C', 'B', 'I', ':', 'z', 'l',
- 'i', 'b', '_', 'c', 'o', 'm', 'p', 'r', 'e', 's', 's', '#', '1', '(', 'a', 'n', 'y',
- ' ', 'i', 'n', ')', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':',
- 'z', 'l', 'i', 'b', '#', '1', '<', '0', '>', '(', 'i', 'n', ')', ';', '}', 'e', 'x',
- 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'I', 'N', 'S',
- 'D', 'C', ':', '2', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':',
- 'S', 'E', 'Q', ':', 'r', 'a', 'n', 'd', '_', '4', 'n', 'a', '_', '2', 'n', 'a', '#',
- '1', '(', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'r',
- 'd', '_', 'b', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
- 'c', 't', 'i', 'o', 'n', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'I', 'N', 'S', 'D', 'C',
- ':', 'S', 'R', 'A', ':', 'f', 'o', 'r', 'm', 'a', 't', '_', 's', 'p', 'o', 't', '_',
- 'n', 'a', 'm', 'e', '#', '1', '(', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e',
- '_', 'f', 'm', 't', ',', 'I', '3', '2', ' ', 'X', ',', 'I', '3', '2', ' ', 'Y', '*',
- 'a', 's', 'c', 'i', 'i', ' ', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', ')', ';',
+ ' ', 'N', 'C', 'B', 'I', ':', 'u', 'n', 'p', 'a', 'c', 'k', '#', '1', '<', 'U', '3',
+ '2', ' ', 'f', 'r', 'o', 'm', ',', 'U', '3', '2', ' ', 't', 'o', '>', '(', 'a', 'n',
+ 'y', ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c',
+ 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':', 'f', 'p', '_',
+ 'd', 'e', 'c', 'o', 'd', 'e', '#', '1', '(', 'f', 'p', '_', 'e', 'n', 'c', 'o', 'd',
+ 'e', 'd', '_', 't', ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f',
+ 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':',
+ 'f', 'p', '_', 'e', 'x', 't', 'e', 'n', 'd', '#', '1', '<', 'U', '3', '2', ' ', 'b',
+ 'i', 't', 's', '>', '(', 'N', 'C', 'B', 'I', ':', 'f', 'p', '_', 'e', 'n', 'c', 'o',
+ 'd', 'e', 'd', '_', 't', ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
+ 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'r', 'l', '_', 'e', 'n', 'c', 'o', 'd',
+ 'e', 'd', '_', 't', ' ', 'N', 'C', 'B', 'I', ':', 'r', 'u', 'n', '_', 'l', 'e', 'n',
+ 'g', 't', 'h', '_', 'e', 'n', 'c', 'o', 'd', 'e', '#', '1', '(', 'a', 'n', 'y', ' ',
+ 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'r', 'l', 'e', 'n', 'c', 'o', 'd', 'e', ';',
'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a',
- 's', 'c', 'i', 'i', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'f', 'o',
- 'r', 'm', 'a', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 'n', 'o',
- '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '(', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a',
- 'm', 'e', '_', 'f', 'm', 't', '*', 'a', 's', 'c', 'i', 'i', ' ', 's', 'p', 'o', 't',
- '_', 'n', 'a', 'm', 'e', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
- 'c', 't', 'i', 'o', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':',
- 'b', 'i', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'c', 'o', 'l', 'o', 'r', '_', 'f', 'r',
- 'o', 'm', '_', 'd', 'n', 'a', '#', '1', '(', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2',
- 'n', 'a', ':', 'b', 'i', 'n', ' ', 'b', 'i', 'n', '_', 'x', '2', 'n', 'a', ',', 'I',
- 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'r',
- 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n',
- ',', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'c',
- 's', '_', 'k', 'e', 'y', ',', 'U', '8', ' ', 'c', 'o', 'l', 'o', 'r', '_', 'm', 'a',
- 't', 'r', 'i', 'x', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c',
- 't', 'i', 'o', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b',
- 'i', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'd', 'n', 'a', '_', 'f', 'r', 'o', 'm', '_',
- 'c', 'o', 'l', 'o', 'r', '#', '1', '(', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c',
- 's', ':', 'b', 'i', 'n', ' ', 'c', 'o', 'l', 'o', 'r', '_', 'b', 'i', 'n', ',', 'I',
- 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'r',
- 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n',
- ',', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'c',
- 's', '_', 'k', 'e', 'y', ',', 'U', '8', ' ', 'c', 'o', 'l', 'o', 'r', '_', 'm', 'a',
- 't', 'r', 'i', 'x', ')', ';', 's', 'c', 'h', 'e', 'm', 'a', ' ', 'f', 'u', 'n', 'c',
- 't', 'i', 'o', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't',
- 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'l', 'o', 'g', '_',
- 'o', 'd', 'd', 's', '_', 't', 'o', '_', 'p', 'h', 'r', 'e', 'd', '#', '1', '(', 'I',
- 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_',
- 'o', 'd', 'd', 's', ' ', 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd',
- 's', ')', '{', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':',
- 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's',
- '_', 'c', 'l', 'i', 'p', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l',
- 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '>', 'c', 'l', 'i', 'p',
- '#', '1', '<', '-', '6', ',', '4', '0', '>', '(', 'q', 'u', 'a', 'l', '_', 'l', 'o',
- 'g', '_', 'o', 'd', 'd', 's', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', '<', 'I',
- 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_',
- 'o', 'd', 'd', 's', ',', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't',
- 'y', ':', 'p', 'h', 'r', 'e', 'd', '>', 'm', 'a', 'p', '#', '1', '<', '[', '-', '6',
- ',', '-', '5', ',', '-', '4', ',', '-', '3', ',', '-', '2', ',', '-', '1', ',', '0',
- ',', '1', ',', '2', ',', '3', ',', '4', ',', '5', ',', '6', ',', '7', ',', '8', ',',
- '9', ',', '1', '0', ',', '1', '1', ',', '1', '2', ',', '1', '3', ',', '1', '4', ',',
- '1', '5', ',', '1', '6', ',', '1', '7', ',', '1', '8', ',', '1', '9', ',', '2', '0',
- ',', '2', '1', ',', '2', '2', ',', '2', '3', ',', '2', '4', ',', '2', '5', ',', '2',
- '6', ',', '2', '7', ',', '2', '8', ',', '2', '9', ',', '3', '0', ',', '3', '1', ',',
- '3', '2', ',', '3', '3', ',', '3', '4', ',', '3', '5', ',', '3', '6', ',', '3', '7',
- ',', '3', '8', ',', '3', '9', ',', '4', '0', ']', ',', '[', '0', ',', '1', ',', '1',
- ',', '2', ',', '2', ',', '3', ',', '3', ',', '4', ',', '4', ',', '5', ',', '5', ',',
- '6', ',', '7', ',', '8', ',', '9', ',', '1', '0', ',', '1', '0', ',', '1', '1', ',',
- '1', '2', ',', '1', '3', ',', '1', '4', ',', '1', '5', ',', '1', '6', ',', '1', '7',
- ',', '1', '8', ',', '1', '9', ',', '2', '0', ',', '2', '1', ',', '2', '2', ',', '2',
- '3', ',', '2', '4', ',', '2', '5', ',', '2', '6', ',', '2', '7', ',', '2', '8', ',',
- '2', '9', ',', '3', '0', ',', '3', '1', ',', '3', '2', ',', '3', '3', ',', '3', '4',
- ',', '3', '5', ',', '3', '6', ',', '3', '7', ',', '3', '8', ',', '3', '9', ',', '4',
- '0', ']', '>', '(', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 'c', 'l', 'i', 'p',
- ')', ';', '}', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
- 'n', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e',
- '#', '1', '(', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e', ',', 't', 'e', 'x',
- 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 't', 'o', 'k', ')', ';', 'e', 'x', 't', 'e',
- 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 's', 'c', 'i', 'i',
- ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't',
- '_', 'n', 'a', 'm', 'e', '_', 'f', 'm', 't', '#', '1', '<', 'a', 's', 'c', 'i', 'i',
- ' ', 'i', 'd', 'x', '>', '(', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e', ',',
- 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 't', 'o', 'k', ')', ';', 'e',
- 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n', 'a', 'm',
- 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', 'U', '1', '6', ' ', 'c', 'o', 'o',
- 'r', 'd', '>', '(', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e', ',', 't', 'e',
- 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 't', 'o', 'k', ')', ';', 'e', 'x', 't',
- 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'I', 'N', 'S', 'D',
- 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o',
- 'u', 'n', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'l', 'o', 'o', 'k',
- 'u', 'p', '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'i', 'n', 'd', 'e', 'x', '_',
- 'n', 'a', 'm', 'e', ',', 'a', 's', 'c', 'i', 'i', ' ', 'q', 'u', 'e', 'r', 'y', '_',
- 'b', 'y', '_', 'n', 'a', 'm', 'e', ',', 'U', '8', ' ', 'n', 'a', 'm', 'e', '_', 'f',
- 'm', 't', '_', 'v', 'e', 'r', 's', 'i', 'o', 'n', '>', '(', '*', 'a', 's', 'c', 'i',
- 'i', ' ', 'n', 'a', 'm', 'e', '_', 'p', 'r', 'e', 'f', 'i', 'x', ')', ';', 'e', 'x',
- 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'U', '8', ' ',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 't', 'a', 't', 's', '_', 't', 'r',
- 'i', 'g', 'g', 'e', 'r', '#', '1', '(', 'U', '8', ' ', 'r', 'e', 'a', 'd', '_', 'b',
- 'i', 'n', ',', 'U', '3', '2', ' ', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',', 'I',
- 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd', '_', 't', 'y',
- 'p', 'e', ' ', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '*', 'a', 's', 'c', 'i',
- 'i', ' ', 's', 'p', 'o', 't', '_', 'g', 'r', 'o', 'u', 'p', ')', ';', 'e', 'x', 't',
- 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'U', '8', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'c', 'm', 'p', '_', 's', 't', 'a', 't', 's',
- '_', 't', 'r', 'i', 'g', 'g', 'e', 'r', '#', '1', '(', 'B', '8', ' ', 'c', 'm', 'p',
- '_', 'r', 'e', 'a', 'd', '_', 'b', 'i', 'n', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 's', 't', 'a', 't', 's', ':', 'q', 'u', 'a', 'l', '_', 't', 'y', 'p', 'e',
- ' ', 'q', 'u', 'a', 'l', '_', 'b', 'i', 'n', ',', 'U', '3', '2', ' ', 'r', 'e', 'a',
- 'd', '_', 'l', 'e', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x',
- 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'r', 'e', 'a', 'd', '_', 't', 'y',
- 'p', 'e', '*', 'a', 's', 'c', 'i', 'i', ' ', 's', 'p', 'o', 't', '_', 'g', 'r', 'o',
- 'u', 'p', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i',
- 'o', 'n', ' ', 'U', '8', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'c', 'm',
- 'p', 'f', '_', 's', 't', 'a', 't', 's', '_', 't', 'r', 'i', 'g', 'g', 'e', 'r', '#',
- '1', '(', 'B', '8', ' ', 'c', 'm', 'p', '_', 'r', 'e', 'a', 'd', '_', 'b', 'i', 'n',
- ',', 'U', '3', '2', ' ', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ',', 'U', '3', '2',
+ 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':', 'r', 'u', 'n', '_', 'l', 'e', 'n', 'g', 't',
+ 'h', '_', 'd', 'e', 'c', 'o', 'd', 'e', '#', '1', '(', 'r', 'l', '_', 'e', 'n', 'c',
+ 'o', 'd', 'e', 'd', '_', 't', ' ', 'i', 'n', ')', '=', 'v', 'd', 'b', ':', 'r', 'l',
+ 'd', 'e', 'c', 'o', 'd', 'e', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
+ 'c', 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'z', 'l', 'i', 'b', '_', 'e',
+ 'n', 'c', 'o', 'd', 'e', 'd', '_', 't', ' ', 'N', 'C', 'B', 'I', ':', 'z', 'l', 'i',
+ 'b', '#', '1', '<', '*', 'I', '3', '2', ' ', 's', 't', 'r', 'a', 't', 'e', 'g', 'y',
+ ',', 'I', '3', '2', ' ', 'l', 'e', 'v', 'e', 'l', '>', '(', 'a', 'n', 'y', ' ', 'i',
+ 'n', ')', '=', 'v', 'd', 'b', ':', 'z', 'i', 'p', ';', 'e', 'x', 't', 'e', 'r', 'n',
+ ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B',
+ 'I', ':', 'u', 'n', 'z', 'i', 'p', '#', '1', '(', 'N', 'C', 'B', 'I', ':', 'z', 'l',
+ 'i', 'b', '_', 'e', 'n', 'c', 'o', 'd', 'e', 'd', '_', 't', ' ', 'i', 'n', ')', ';',
+ 'a', 'l', 'i', 'a', 's', ' ', 'N', 'C', 'B', 'I', ':', 'u', 'n', 'z', 'i', 'p', ' ',
+ 'N', 'C', 'B', 'I', ':', 'z', 'l', 'i', 'b', '_', 'd', 'e', 'c', 'o', 'm', 'p', 'r',
+ 'e', 's', 's', ';', 's', 'c', 'h', 'e', 'm', 'a', ' ', 'f', 'u', 'n', 'c', 't', 'i',
+ 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'z', 'l', 'i', 'b', '_', 'e', 'n', 'c', 'o',
+ 'd', 'e', 'd', '_', 't', ' ', 'N', 'C', 'B', 'I', ':', 'z', 'l', 'i', 'b', '_', 'h',
+ 'u', 'f', 'f', 'm', 'a', 'n', '_', 'c', 'o', 'm', 'p', 'r', 'e', 's', 's', '#', '1',
+ '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N',
+ 'C', 'B', 'I', ':', 'z', 'l', 'i', 'b', '#', '1', '<', '3', '>', '(', 'i', 'n', ')',
+ ';', '}', 's', 'c', 'h', 'e', 'm', 'a', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
+ ' ', 'N', 'C', 'B', 'I', ':', 'z', 'l', 'i', 'b', '_', 'e', 'n', 'c', 'o', 'd', 'e',
+ 'd', '_', 't', ' ', 'N', 'C', 'B', 'I', ':', 'z', 'l', 'i', 'b', '_', 'c', 'o', 'm',
+ 'p', 'r', 'e', 's', 's', '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', '{', 'r',
+ 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'z', 'l', 'i', 'b', '#', '1',
+ '<', '0', '>', '(', 'i', 'n', ')', ';', '}', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f',
+ 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a',
+ ':', 'b', 'i', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'E', 'Q', ':', 'r', 'a',
+ 'n', 'd', '_', '4', 'n', 'a', '_', '2', 'n', 'a', '#', '1', '(', 'I', 'N', 'S', 'D',
+ 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'r', 'd', '_', 'b', 'i', 'n', ')',
+ ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
+ 'a', 's', 'c', 'i', 'i', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'f',
+ 'o', 'r', 'm', 'a', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1',
+ '(', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e', '_', 'f', 'm', 't', ',', 'I',
+ '3', '2', ' ', 'X', ',', 'I', '3', '2', ' ', 'Y', '*', 'a', 's', 'c', 'i', 'i', ' ',
+ 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', ')', ';', 'e', 'x', 't', 'e', 'r', 'n',
+ ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'I',
+ 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'f', 'o', 'r', 'm', 'a', 't', '_', 's',
+ 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 'n', 'o', '_', 'c', 'o', 'o', 'r', 'd',
+ '#', '1', '(', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e', '_', 'f', 'm', 't',
+ '*', 'a', 's', 'c', 'i', 'i', ' ', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', ')',
+ ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
+ 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ' ', 'N', 'C',
+ 'B', 'I', ':', 'c', 'o', 'l', 'o', 'r', '_', 'f', 'r', 'o', 'm', '_', 'd', 'n', 'a',
+ '#', '1', '(', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n',
+ ' ', 'b', 'i', 'n', '_', 'x', '2', 'n', 'a', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c',
+ 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'r', 'e', 'a', 'd', '_', 's', 't',
+ 'a', 'r', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l',
+ 'e', 'n', ' ', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',', 'I', 'N', 'S', 'D', 'C',
+ ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'c', 's', '_', 'k', 'e', 'y', ',',
+ 'U', '8', ' ', 'c', 'o', 'l', 'o', 'r', '_', 'm', 'a', 't', 'r', 'i', 'x', ')', ';',
+ 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'I',
+ 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'N', 'C', 'B',
+ 'I', ':', 'd', 'n', 'a', '_', 'f', 'r', 'o', 'm', '_', 'c', 'o', 'l', 'o', 'r', '#',
+ '1', '(', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ' ',
+ 'c', 'o', 'l', 'o', 'r', '_', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c',
+ 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'r', 'e', 'a', 'd', '_', 's', 't',
+ 'a', 'r', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l',
+ 'e', 'n', ' ', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',', 'I', 'N', 'S', 'D', 'C',
+ ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'c', 's', '_', 'k', 'e', 'y', ',',
+ 'U', '8', ' ', 'c', 'o', 'l', 'o', 'r', '_', 'm', 'a', 't', 'r', 'i', 'x', ')', ';',
+ 's', 'c', 'h', 'e', 'm', 'a', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'I',
+ 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e',
+ 'd', ' ', 'N', 'C', 'B', 'I', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 't',
+ 'o', '_', 'p', 'h', 'r', 'e', 'd', '#', '1', '(', 'I', 'N', 'S', 'D', 'C', ':', 'q',
+ 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'q',
+ 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ')', '{', 'I', 'N', 'S',
+ 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd',
+ 'd', 's', ' ', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 'c', 'l', 'i', 'p', '=',
+ '<', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o',
+ 'g', '_', 'o', 'd', 'd', 's', '>', 'c', 'l', 'i', 'p', '#', '1', '<', '-', '6', ',',
+ '4', '0', '>', '(', 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's',
+ ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'q',
+ 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ',', 'I',
+ 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e',
+ 'd', '>', 'm', 'a', 'p', '#', '1', '<', '[', '-', '6', ',', '-', '5', ',', '-', '4',
+ ',', '-', '3', ',', '-', '2', ',', '-', '1', ',', '0', ',', '1', ',', '2', ',', '3',
+ ',', '4', ',', '5', ',', '6', ',', '7', ',', '8', ',', '9', ',', '1', '0', ',', '1',
+ '1', ',', '1', '2', ',', '1', '3', ',', '1', '4', ',', '1', '5', ',', '1', '6', ',',
+ '1', '7', ',', '1', '8', ',', '1', '9', ',', '2', '0', ',', '2', '1', ',', '2', '2',
+ ',', '2', '3', ',', '2', '4', ',', '2', '5', ',', '2', '6', ',', '2', '7', ',', '2',
+ '8', ',', '2', '9', ',', '3', '0', ',', '3', '1', ',', '3', '2', ',', '3', '3', ',',
+ '3', '4', ',', '3', '5', ',', '3', '6', ',', '3', '7', ',', '3', '8', ',', '3', '9',
+ ',', '4', '0', ']', ',', '[', '0', ',', '1', ',', '1', ',', '2', ',', '2', ',', '3',
+ ',', '3', ',', '4', ',', '4', ',', '5', ',', '5', ',', '6', ',', '7', ',', '8', ',',
+ '9', ',', '1', '0', ',', '1', '0', ',', '1', '1', ',', '1', '2', ',', '1', '3', ',',
+ '1', '4', ',', '1', '5', ',', '1', '6', ',', '1', '7', ',', '1', '8', ',', '1', '9',
+ ',', '2', '0', ',', '2', '1', ',', '2', '2', ',', '2', '3', ',', '2', '4', ',', '2',
+ '5', ',', '2', '6', ',', '2', '7', ',', '2', '8', ',', '2', '9', ',', '3', '0', ',',
+ '3', '1', ',', '3', '2', ',', '3', '3', ',', '3', '4', ',', '3', '5', ',', '3', '6',
+ ',', '3', '7', ',', '3', '8', ',', '3', '9', ',', '4', '0', ']', '>', '(', 'l', 'o',
+ 'g', '_', 'o', 'd', 'd', 's', '_', 'c', 'l', 'i', 'p', ')', ';', '}', 'e', 'x', 't',
+ 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 's', 'c', 'i',
+ 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c',
+ 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', 'a', 's', 'c',
+ 'i', 'i', ' ', 'n', 'a', 'm', 'e', ',', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e',
+ 'n', ' ', 't', 'o', 'k', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
+ 'c', 't', 'i', 'o', 'n', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':',
+ 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n', 'a', 'm', 'e', '_',
+ 'f', 'm', 't', '#', '1', '<', 'a', 's', 'c', 'i', 'i', ' ', 'i', 'd', 'x', '>', '(',
+ 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e', ',', 't', 'e', 'x', 't', ':', 't',
+ 'o', 'k', 'e', 'n', ' ', 't', 'o', 'k', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
+ 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
+ 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n', 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r',
+ 'd', '#', '1', '<', 'U', '1', '6', ' ', 'c', 'o', 'o', 'r', 'd', '>', '(', 'a', 's',
+ 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e', ',', 't', 'e', 'x', 't', ':', 't', 'o', 'k',
+ 'e', 'n', ' ', 't', 'o', 'k', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u',
+ 'n', 'c', 't', 'i', 'o', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':',
+ 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', ' ', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 'l', 'o', 'o', 'k', 'u', 'p', '#', '1', '<', 'a',
+ 's', 'c', 'i', 'i', ' ', 'i', 'n', 'd', 'e', 'x', '_', 'n', 'a', 'm', 'e', ',', 'a',
+ 's', 'c', 'i', 'i', ' ', 'q', 'u', 'e', 'r', 'y', '_', 'b', 'y', '_', 'n', 'a', 'm',
+ 'e', ',', 'U', '8', ' ', 'n', 'a', 'm', 'e', '_', 'f', 'm', 't', '_', 'v', 'e', 'r',
+ 's', 'i', 'o', 'n', '>', '(', '*', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e',
+ '_', 'p', 'r', 'e', 'f', 'i', 'x', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f',
+ 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'U', '8', ' ', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 's', 't', 'a', 't', 's', '_', 't', 'r', 'i', 'g', 'g', 'e', 'r', '#',
+ '1', '(', 'U', '8', ' ', 'r', 'e', 'a', 'd', '_', 'b', 'i', 'n', ',', 'U', '3', '2',
' ', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'S',
'R', 'A', ':', 'x', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'r', 'e', 'a',
'd', '_', 't', 'y', 'p', 'e', '*', 'a', 's', 'c', 'i', 'i', ' ', 's', 'p', 'o', 't',
'_', 'g', 'r', 'o', 'u', 'p', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u',
'n', 'c', 't', 'i', 'o', 'n', ' ', 'U', '8', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 'p', 'h', 'r', 'e', 'd', '_', 's', 't', 'a', 't', 's', '_', 't', 'r', 'i',
- 'g', 'g', 'e', 'r', '#', '1', '(', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l',
- 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'q', 'u', 'a', 'l', '_', 'b', 'i',
- 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
- 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r',
- 'o', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'b', 'i', 'o', '_', 's', 't',
- 'a', 'r', 't', '#', '1', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
- ':', 'z', 'e', 'r', 'o', ' ', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', ',',
- 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd', '_', 't',
- 'y', 'p', 'e', ' ', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ')', ';', 'e', 'x',
- 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'I', 'N', 'S',
- 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', '[', '2', ']', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'f', 'i', 'x', '_', 'r', 'e', 'a', 'd', '_',
- 's', 'e', 'g', '#', '1', '(', 'U', '1', '6', '[', '2', ']', ' ', 'r', 'd', '_', 's',
- 'e', 'g', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e',
- 'n', ' ', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ')', ';', 'e', 'x', 't', 'e', 'r',
- 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 'S', 'p', 'o', 't', 'D', 'e', 's', 'c', ' ', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'm', 'a', 'k', 'e', '_', 's', 'p', 'o', 't', '_', 'd', 'e', 's',
- 'c', '#', '1', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l',
- 'e', 'n', ' ', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ',', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'f', 'i', 'x', 'e', 'd', '_',
- 'l', 'e', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l',
- 'e', 'n', ' ', 's', 'i', 'g', '_', 'l', 'e', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 't', 'r', 'i', 'm', '_', 's',
- 't', 'a', 'r', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
- 'l', 'e', 'n', ' ', 't', 'r', 'i', 'm', '_', 'l', 'e', 'n', ',', 'U', '8', ' ', 'n',
- 'u', 'm', '_', 'r', 'e', 'a', 'd', 's', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
- 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', 'R', 'e', 'a', 'd', 'D', 'e', 's', 'c', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 'm', 'a', 'k', 'e', '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', '#',
- '1', '(', 'U', '8', ' ', 'n', 'u', 'm', '_', 'r', 'e', 'a', 'd', 's', ',', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'r', 'e',
- 'a', 'd', '_', 's', 't', 'a', 'r', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',',
+ 'A', ':', 'c', 'm', 'p', '_', 's', 't', 'a', 't', 's', '_', 't', 'r', 'i', 'g', 'g',
+ 'e', 'r', '#', '1', '(', 'B', '8', ' ', 'c', 'm', 'p', '_', 'r', 'e', 'a', 'd', '_',
+ 'b', 'i', 'n', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 't', 'a', 't',
+ 's', ':', 'q', 'u', 'a', 'l', '_', 't', 'y', 'p', 'e', ' ', 'q', 'u', 'a', 'l', '_',
+ 'b', 'i', 'n', ',', 'U', '3', '2', ' ', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',',
'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd', '_', 't',
- 'y', 'p', 'e', ' ', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ',', 'I', 'N', 'S',
- 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e',
- 'r', ' ', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', ',', 'I', 'N', 'S', 'D', 'C',
- ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'c', 's', '_', 'k', 'e', 'y', ',',
+ 'y', 'p', 'e', ' ', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '*', 'a', 's', 'c',
+ 'i', 'i', ' ', 's', 'p', 'o', 't', '_', 'g', 'r', 'o', 'u', 'p', ')', ';', 'e', 'x',
+ 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'U', '8', ' ',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'c', 'm', 'p', 'f', '_', 's', 't', 'a',
+ 't', 's', '_', 't', 'r', 'i', 'g', 'g', 'e', 'r', '#', '1', '(', 'B', '8', ' ', 'c',
+ 'm', 'p', '_', 'r', 'e', 'a', 'd', '_', 'b', 'i', 'n', ',', 'U', '3', '2', ' ', 's',
+ 'p', 'o', 't', '_', 'l', 'e', 'n', ',', 'U', '3', '2', ' ', 'r', 'e', 'a', 'd', '_',
+ 'l', 'e', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x', 'r', 'e',
+ 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e',
+ '*', 'a', 's', 'c', 'i', 'i', ' ', 's', 'p', 'o', 't', '_', 'g', 'r', 'o', 'u', 'p',
+ ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
+ ' ', 'U', '8', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'p', 'h', 'r', 'e',
+ 'd', '_', 's', 't', 'a', 't', 's', '_', 't', 'r', 'i', 'g', 'g', 'e', 'r', '#', '1',
+ '(', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h',
+ 'r', 'e', 'd', ' ', 'q', 'u', 'a', 'l', '_', 'b', 'i', 'n', ')', ';', 'e', 'x', 't',
+ 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'N', 'C', 'B', 'I',
+ ':', 'S', 'R', 'A', ':', 'b', 'i', 'o', '_', 's', 't', 'a', 'r', 't', '#', '1', '(',
'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ',
- 'l', 'a', 'b', 'e', 'l', '_', 's', 't', 'a', 'r', 't', ',', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'l', 'a', 'b', 'e', 'l', '_',
- 'l', 'e', 'n', ',', 'a', 's', 'c', 'i', 'i', ' ', 'l', 'a', 'b', 'e', 'l', ')', ';',
- 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<',
- 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', 'r', 'o', 't', 'a', 't', 'e', '#', '1', '<', 'b', 'o', 'o', 'l', ' ', 'e', 'n',
- 'c', 'o', 'd', 'i', 'n', 'g', '>', '(', 'T', ' ', 'i', 'n', ',', 'U', '8', ' ', 'c',
- 'a', 'l', 'l', 'e', 'd', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
- 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(', 'T', ' ',
- 'i', 'n', ',', 'U', '8', ' ', 'c', 'a', 'l', 'l', 'e', 'd', ')', ';', 'e', 'x', 't',
+ 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', ',', 'I', 'N', 'S', 'D', 'C', ':',
+ 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'r', 'e',
+ 'a', 'd', '_', 't', 'y', 'p', 'e', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f',
+ 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
+ 'r', 'd', ':', 'l', 'e', 'n', '[', '2', ']', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'f', 'i', 'x', '_', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '#', '1', '(',
+ 'U', '1', '6', '[', '2', ']', ' ', 'r', 'd', '_', 's', 'e', 'g', ',', 'I', 'N', 'S',
+ 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 's', 'p', 'o', 't',
+ '_', 'l', 'e', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c',
+ 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'S', 'p', 'o',
+ 't', 'D', 'e', 's', 'c', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'm', 'a',
+ 'k', 'e', '_', 's', 'p', 'o', 't', '_', 'd', 'e', 's', 'c', '#', '1', '(', 'I', 'N',
+ 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 's', 'p', 'o',
+ 't', '_', 'l', 'e', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'l', 'e', 'n', ' ', 'f', 'i', 'x', 'e', 'd', '_', 'l', 'e', 'n', ',', 'I', 'N',
+ 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 's', 'i', 'g',
+ '_', 'l', 'e', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
+ 'z', 'e', 'r', 'o', ' ', 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't', ',', 'I',
+ 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 't', 'r',
+ 'i', 'm', '_', 'l', 'e', 'n', ',', 'U', '8', ' ', 'n', 'u', 'm', '_', 'r', 'e', 'a',
+ 'd', 's', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i',
+ 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'R', 'e', 'a', 'd', 'D',
+ 'e', 's', 'c', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'm', 'a', 'k', 'e',
+ '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', '#', '1', '(', 'U', '8', ' ', 'n',
+ 'u', 'm', '_', 'r', 'e', 'a', 'd', 's', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
+ 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'r', 'e', 'a', 'd', '_', 's', 't', 'a',
+ 'r', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e',
+ 'n', ' ', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':',
+ 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'r', 'e',
+ 'a', 'd', '_', 't', 'y', 'p', 'e', ',', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A',
+ ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', ' ', 'r', 'e', 'a', 'd',
+ '_', 'f', 'i', 'l', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't',
+ 'e', 'x', 't', ' ', 'c', 's', '_', 'k', 'e', 'y', ',', 'I', 'N', 'S', 'D', 'C', ':',
+ 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'l', 'a', 'b', 'e', 'l', '_',
+ 's', 't', 'a', 'r', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'l', 'e', 'n', ' ', 'l', 'a', 'b', 'e', 'l', '_', 'l', 'e', 'n', ',', 'a', 's',
+ 'c', 'i', 'i', ' ', 'l', 'a', 'b', 'e', 'l', ')', ';', 'e', 'x', 't', 'e', 'r', 'n',
+ ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T',
+ '>', 'T', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'o', 't', 'a', 't',
+ 'e', '#', '1', '<', 'b', 'o', 'o', 'l', ' ', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g',
+ '>', '(', 'T', ' ', 'i', 'n', ',', 'U', '8', ' ', 'c', 'a', 'l', 'l', 'e', 'd', ')',
+ ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
+ '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(', 'T', ' ', 'i', 'n', ',', 'U', '8', ' ',
+ 'c', 'a', 'l', 'l', 'e', 'd', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u',
+ 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'o', 'r', 'm', 'a', 'l', 'i', 'z',
+ 'e', '#', '1', '(', 'T', ' ', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ',', 'U',
+ '8', ' ', 'c', 'a', 'l', 'l', 'e', 'd', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
+ 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>',
+ 'T', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'n', 'o', 'r', 'm',
+ 'a', 'l', 'i', 'z', 'e', '#', '1', '(', 'T', ' ', 'i', 'n', 't', 'e', 'n', 's', 'i',
+ 't', 'y', ',', 'U', '8', ' ', 'c', 'a', 'l', 'l', 'e', 'd', ')', ';', 'e', 'x', 't',
'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't', 'y', 'p',
- 'e', ' ', 'T', '>', 'T', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'o',
- 'r', 'm', 'a', 'l', 'i', 'z', 'e', '#', '1', '(', 'T', ' ', 'i', 'n', 't', 'e', 'n',
- 's', 'i', 't', 'y', ',', 'U', '8', ' ', 'c', 'a', 'l', 'l', 'e', 'd', ')', ';', 'e',
- 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '<', 't',
- 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'd', 'e', 'n', 'o', 'r', 'm', 'a', 'l', 'i', 'z', 'e', '#', '1', '(', 'T', ' ', 'i',
- 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ',', 'U', '8', ' ', 'c', 'a', 'l', 'l', 'e',
- 'd', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
- 'n', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'm', 'a', 'k', 'e', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n',
- '#', '1', '<', 'T', ' ', 's', 't', 'a', 'r', 't', '>', '(', 'a', 'n', 'y', ' ', 'b',
- 'a', 's', 'e', 's', ')', ';', 's', 'c', 'h', 'e', 'm', 'a', ' ', 'f', 'u', 'n', 'c',
- 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a',
- 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ' ', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'f', 's', 'a', 'm', 'p', '4', ':', 'd', 'e', 'c', 'o', 'd', 'e',
- '#', '2', '(', 'm', 'e', 'r', 'g', 'e', 'd', '_', 'f', 'm', 't', ' ', 'i', 'n', ')',
- '{', 'f', 'z', 'i', 'p', '_', 'f', 'm', 't', ' ', 'c', 'm', 'p', '0', '=', 's', 'p',
- 'l', 'i', 't', '#', '1', '<', '0', '>', '(', 'i', 'n', ')', ';', 'f', 'z', 'i', 'p',
- '_', 'f', 'm', 't', ' ', 'c', 'm', 'p', '1', '2', '3', '=', 's', 'p', 'l', 'i', 't',
- '#', '1', '<', '1', '>', '(', 'i', 'n', ')', ';', 'F', '3', '2', ' ', 'c', 'h', '0',
- '=', 'f', 'u', 'n', 'z', 'i', 'p', '#', '1', '(', 'c', 'm', 'p', '0', ')', ';', 'F',
- '3', '2', ' ', 'c', 'h', '1', '2', '3', 'a', '=', 'f', 'u', 'n', 'z', 'i', 'p', '#',
- '1', '(', 'c', 'm', 'p', '1', '2', '3', ')', ';', 'F', '3', '2', '[', '3', ']', ' ',
- 'c', 'h', '1', '2', '3', '=', 'r', 'e', 'd', 'i', 'm', 'e', 'n', 's', 'i', 'o', 'n',
- '#', '1', '(', 'c', 'h', '1', '2', '3', 'a', ')', ';', 'r', 'e', 't', 'u', 'r', 'n',
- ' ', '(', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e',
- 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'F', '3', '2', '>', 'p', 'a', 's',
- 't', 'e', '#', '1', '(', 'c', 'h', '0', ',', 'c', 'h', '1', '2', '3', ')', ';', '}',
- 's', 'c', 'h', 'e', 'm', 'a', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'm',
- 'e', 'r', 'g', 'e', 'd', '_', 'f', 'm', 't', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 'f', 's', 'a', 'm', 'p', '4', ':', 'e', 'n', 'c', 'o', 'd', 'e', '#', '2',
- '<', 'U', '3', '2', ' ', 'c', 'a', 'l', 'l', 'e', 'd', ',', 'U', '3', '2', ' ', 'a',
- 'l', 't', '>', '(', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p',
- 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ' ', 'i', 'n', ')', '{', 'F', '3',
- '2', ' ', 'c', 'h', '0', '=', '<', 'F', '3', '2', '>', 'c', 'u', 't', '#', '1', '<',
- '0', '>', '(', 'i', 'n', ')', ';', 'F', '3', '2', '[', '3', ']', ' ', 'c', 'h', '1',
- '2', '3', '=', '<', 'F', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '1', ',', '2',
- ',', '3', '>', '(', 'i', 'n', ')', ';', 'f', 'z', 'i', 'p', '_', 'f', 'm', 't', ' ',
- 'c', 'm', 'p', '0', '=', 'f', 'z', 'i', 'p', '#', '1', '<', 'c', 'a', 'l', 'l', 'e',
- 'd', '>', '(', 'c', 'h', '0', ')', ';', 'F', '3', '2', ' ', 'c', 'h', '1', '2', '3',
- 'a', '=', 'r', 'e', 'd', 'i', 'm', 'e', 'n', 's', 'i', 'o', 'n', '#', '1', '(', 'c',
- 'h', '1', '2', '3', ')', ';', 'f', 'z', 'i', 'p', '_', 'f', 'm', 't', ' ', 'c', 'm',
- 'p', '1', '2', '3', '=', 'f', 'z', 'i', 'p', '#', '1', '<', 'a', 'l', 't', '>', '(',
- 'c', 'h', '1', '2', '3', 'a', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'm', 'e',
- 'r', 'g', 'e', '#', '1', '(', 'c', 'm', 'p', '0', ',', 'c', 'm', 'p', '1', '2', '3',
- ')', ';', '}', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
- 'n', ' ', 'U', '3', '2', '[', '3', ']', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', '_', '4', '5', '4', '_', ':', 'd', 'y', 'n', 'a', 'm', 'i', 'c', '_', 'r', 'e',
- 'a', 'd', '_', 'd', 'e', 's', 'c', '#', '1', '<', '*', 'U', '3', '2', ' ', 'e', 'd',
- 'i', 't', '_', 'd', 'i', 's', 't', 'a', 'n', 'c', 'e', '>', '(', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'd', 'r', 'd', 'p', 'a', 'r',
- 'a', 'm', '_', 's', 'e', 't', ' ', 's', 'p', 'o', 't', ',', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'd', 'r', 'd', 'p', 'a', 'r', 'a',
- 'm', '_', 's', 'e', 't', ' ', 'k', 'e', 'y', '*', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', '_', '4', '5', '4', '_', ':', 'd', 'r', 'd', 'p', 'a', 'r', 'a', 'm', '_',
- 's', 'e', 't', ' ', 'l', 'i', 'n', 'k', 'e', 'r', ')', ';', 'e', 'x', 't', 'e', 'r',
- 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'e', 'x', 't', ':', 't',
- 'o', 'k', 'e', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5',
- '4', '_', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_',
- 'n', 'a', 'm', 'e', '#', '1', '(', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e',
- ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
- ' ', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'o', 'k', 'e',
- 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(',
- 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e', ')', ';', 'e', 'x', 't', 'e', 'r',
- 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4', ' ',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'q', 'u', 'a', 'l', '4', '_', 'd', 'e',
- 'c', 'o', 'd', 'e', '#', '1', '(', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e',
- 'n', 'c', 'o', 'd', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4', ' ', 'i', 'n', ')', ';',
- 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'n', 'c', 'o', 'd', 'e', 'd', '_', 'q',
- 'u', 'a', 'l', '4', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'q', 'u', 'a',
- 'l', '4', '_', 'e', 'n', 'c', 'o', 'd', 'e', '#', '1', '(', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4',
- ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
- 'i', 'o', 'n', ' ', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 't', 'o', 'k', 'e', 'n', 'i',
- 'z', 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', 'a', 's',
- 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
- 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'e', 'x', 't', ':', 't', 'o', 'k',
- 'e', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'H', 'e', 'l', 'i', 'c',
- 'o', 's', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_',
- 'n', 'a', 'm', 'e', '#', '1', '(', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e',
- ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
- ' ', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'I', 'o', 'n', 'T', 'o', 'r', 'r', 'e', 'n', 't', ':', 't', 'o',
- 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#',
- '1', '(', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e', ')', ';', 'e', 'x', 't',
+ 'e', ' ', 'T', '>', 'T', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'm', 'a',
+ 'k', 'e', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '#', '1', '<', 'T', ' ', 's',
+ 't', 'a', 'r', 't', '>', '(', 'a', 'n', 'y', ' ', 'b', 'a', 's', 'e', 's', ')', ';',
+ 's', 'c', 'h', 'e', 'm', 'a', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f',
+ 's', 'a', 'm', 'p', '4', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'f', 's',
+ 'a', 'm', 'p', '4', ':', 'd', 'e', 'c', 'o', 'd', 'e', '#', '2', '(', 'm', 'e', 'r',
+ 'g', 'e', 'd', '_', 'f', 'm', 't', ' ', 'i', 'n', ')', '{', 'f', 'z', 'i', 'p', '_',
+ 'f', 'm', 't', ' ', 'c', 'm', 'p', '0', '=', 's', 'p', 'l', 'i', 't', '#', '1', '<',
+ '0', '>', '(', 'i', 'n', ')', ';', 'f', 'z', 'i', 'p', '_', 'f', 'm', 't', ' ', 'c',
+ 'm', 'p', '1', '2', '3', '=', 's', 'p', 'l', 'i', 't', '#', '1', '<', '1', '>', '(',
+ 'i', 'n', ')', ';', 'F', '3', '2', ' ', 'c', 'h', '0', '=', 'f', 'u', 'n', 'z', 'i',
+ 'p', '#', '1', '(', 'c', 'm', 'p', '0', ')', ';', 'F', '3', '2', ' ', 'c', 'h', '1',
+ '2', '3', 'a', '=', 'f', 'u', 'n', 'z', 'i', 'p', '#', '1', '(', 'c', 'm', 'p', '1',
+ '2', '3', ')', ';', 'F', '3', '2', '[', '3', ']', ' ', 'c', 'h', '1', '2', '3', '=',
+ 'r', 'e', 'd', 'i', 'm', 'e', 'n', 's', 'i', 'o', 'n', '#', '1', '(', 'c', 'h', '1',
+ '2', '3', 'a', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', '(', 'N', 'C', 'B', 'I',
+ ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm',
+ 'p', '4', ')', '<', 'F', '3', '2', '>', 'p', 'a', 's', 't', 'e', '#', '1', '(', 'c',
+ 'h', '0', ',', 'c', 'h', '1', '2', '3', ')', ';', '}', 's', 'c', 'h', 'e', 'm', 'a',
+ ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'm', 'e', 'r', 'g', 'e', 'd', '_',
+ 'f', 'm', 't', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'f', 's', 'a', 'm',
+ 'p', '4', ':', 'e', 'n', 'c', 'o', 'd', 'e', '#', '2', '<', 'U', '3', '2', ' ', 'c',
+ 'a', 'l', 'l', 'e', 'd', ',', 'U', '3', '2', ' ', 'a', 'l', 't', '>', '(', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's',
+ 'a', 'm', 'p', '4', ' ', 'i', 'n', ')', '{', 'F', '3', '2', ' ', 'c', 'h', '0', '=',
+ '<', 'F', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '0', '>', '(', 'i', 'n', ')',
+ ';', 'F', '3', '2', '[', '3', ']', ' ', 'c', 'h', '1', '2', '3', '=', '<', 'F', '3',
+ '2', '>', 'c', 'u', 't', '#', '1', '<', '1', ',', '2', ',', '3', '>', '(', 'i', 'n',
+ ')', ';', 'f', 'z', 'i', 'p', '_', 'f', 'm', 't', ' ', 'c', 'm', 'p', '0', '=', 'f',
+ 'z', 'i', 'p', '#', '1', '<', 'c', 'a', 'l', 'l', 'e', 'd', '>', '(', 'c', 'h', '0',
+ ')', ';', 'F', '3', '2', ' ', 'c', 'h', '1', '2', '3', 'a', '=', 'r', 'e', 'd', 'i',
+ 'm', 'e', 'n', 's', 'i', 'o', 'n', '#', '1', '(', 'c', 'h', '1', '2', '3', ')', ';',
+ 'f', 'z', 'i', 'p', '_', 'f', 'm', 't', ' ', 'c', 'm', 'p', '1', '2', '3', '=', 'f',
+ 'z', 'i', 'p', '#', '1', '<', 'a', 'l', 't', '>', '(', 'c', 'h', '1', '2', '3', 'a',
+ ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'm', 'e', 'r', 'g', 'e', '#', '1', '(',
+ 'c', 'm', 'p', '0', ',', 'c', 'm', 'p', '1', '2', '3', ')', ';', '}', 'e', 'x', 't',
'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'U', '3', '2', '[',
- '5', ']', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_',
- 's', 'e', 'g', '_', 'f', 'r', 'o', 'm', '_', 'r', 'e', 'a', 'd', 'n', '#', '1', '(',
- 'U', '8', ' ', 'n', 'r', 'e', 'a', 'd', 's', ',', 'U', '3', '2', ' ', 's', 'p', 'o',
- 't', '_', 'l', 'e', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
- 'c', 't', 'i', 'o', 'n', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'r', 'e', 'w', 'r', 'i', 't', 'e', '_', 's', 'p', 'o', 't', '_',
- 'n', 'a', 'm', 'e', '#', '1', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':',
- 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'p', 'l', 'a', 't', 'f',
- 'o', 'r', 'm', '>', '(', 'a', 's', 'c', 'i', 'i', ' ', 's', 'k', 'e', 'y', '*', 'a',
- 's', 'c', 'i', 'i', ' ', 'p', 'r', 'e', 'f', 'i', 'x', ')', ';', 'e', 'x', 't', 'e',
- 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', '[', '*', ']', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'c', 'o', 'o',
- 'r', 'd', 'i', 'n', 'a', 't', 'e', 's', '#', '1', '<', 'I', 'N', 'S', 'D', 'C', ':',
- 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'p',
- 'l', 'a', 't', 'f', 'o', 'r', 'm', '>', '(', 'a', 's', 'c', 'i', 'i', ' ', 's', 'k',
- 'e', 'y', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i',
- 'o', 'n', ' ', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', ' ', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'u', 'n', 't', 'y', 'p', 'e',
- 'd', '_', '0', '(', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c',
- 't', 'i', 'o', 'n', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'C', 'L', 'I', 'P', '#', '1', '(', 'o', 'p',
- 'a', 'q', 'u', 'e', ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f',
- 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'p', 'o', 's', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e',
- 'c', 'o', 'd', 'e', ':', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', '#', '1', '(', 'o',
- 'p', 'a', 'q', 'u', 'e', ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ',
- 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n',
- 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'R', 'E', 'A', 'D', '#', '1', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_',
- 'i', 'd', ' ', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '>', '(', 'o', 'p', 'a', 'q',
- 'u', 'e', ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
- 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '#',
- '1', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f',
- 'o', 'r', 'm', '_', 'i', 'd', ' ', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '>', '(',
- 'o', 'p', 'a', 'q', 'u', 'e', ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n',
- ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'S', 'I', 'G', 'N',
- 'A', 'L', '#', '1', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l',
+ '3', ']', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_',
+ ':', 'd', 'y', 'n', 'a', 'm', 'i', 'c', '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's',
+ 'c', '#', '1', '<', '*', 'U', '3', '2', ' ', 'e', 'd', 'i', 't', '_', 'd', 'i', 's',
+ 't', 'a', 'n', 'c', 'e', '>', '(', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_',
+ '4', '5', '4', '_', ':', 'd', 'r', 'd', 'p', 'a', 'r', 'a', 'm', '_', 's', 'e', 't',
+ ' ', 's', 'p', 'o', 't', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4',
+ '5', '4', '_', ':', 'd', 'r', 'd', 'p', 'a', 'r', 'a', 'm', '_', 's', 'e', 't', ' ',
+ 'k', 'e', 'y', '*', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4',
+ '_', ':', 'd', 'r', 'd', 'p', 'a', 'r', 'a', 'm', '_', 's', 'e', 't', ' ', 'l', 'i',
+ 'n', 'k', 'e', 'r', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c',
+ 't', 'i', 'o', 'n', ' ', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 't', 'o', 'k',
+ 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1',
+ '(', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e', ')', ';', 'e', 'x', 't', 'e',
+ 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'e', 'x', 't', ':',
+ 't', 'o', 'k', 'e', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l',
+ 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's',
+ 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', 'a', 's', 'c', 'i', 'i', ' ',
+ 'n', 'a', 'm', 'e', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c',
+ 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a',
+ 'p', 'p', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4', ' ', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 'q', 'u', 'a', 'l', '4', '_', 'd', 'e', 'c', 'o', 'd', 'e', '#', '1',
+ '(', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'n', 'c', 'o', 'd', 'e', 'd',
+ '_', 'q', 'u', 'a', 'l', '4', ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n',
+ ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'e', 'n', 'c', 'o', 'd', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4', ' ', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'q', 'u', 'a', 'l', '4', '_', 'e', 'n', 'c',
+ 'o', 'd', 'e', '#', '1', '(', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w',
+ 'a', 'p', 'p', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4', ' ', 'i', 'n', ')', ';', 'e',
+ 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'e',
+ 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', 'A', 'B', 'I', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o',
+ 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a',
+ 'm', 'e', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i',
+ 'o', 'n', ' ', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', 'H', 'e', 'l', 'i', 'c', 'o', 's', ':', 't', 'o', 'k',
+ 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1',
+ '(', 'a', 's', 'c', 'i', 'i', ' ', 'n', 'a', 'm', 'e', ')', ';', 'e', 'x', 't', 'e',
+ 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 't', 'e', 'x', 't', ':',
+ 't', 'o', 'k', 'e', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'o',
+ 'n', 'T', 'o', 'r', 'r', 'e', 'n', 't', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e',
+ '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', 'a', 's', 'c', 'i',
+ 'i', ' ', 'n', 'a', 'm', 'e', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u',
+ 'n', 'c', 't', 'i', 'o', 'n', ' ', 'U', '3', '2', '[', '5', ']', ' ', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '_', 'f', 'r',
+ 'o', 'm', '_', 'r', 'e', 'a', 'd', 'n', '#', '1', '(', 'U', '8', ' ', 'n', 'r', 'e',
+ 'a', 'd', 's', ',', 'U', '3', '2', ' ', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ')',
+ ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
+ 'a', 's', 'c', 'i', 'i', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'e',
+ 'w', 'r', 'i', 't', 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1',
+ '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o',
+ 'r', 'm', '_', 'i', 'd', ' ', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '>', '(', 'a',
+ 's', 'c', 'i', 'i', ' ', 's', 'k', 'e', 'y', '*', 'a', 's', 'c', 'i', 'i', ' ', 'p',
+ 'r', 'e', 'f', 'i', 'x', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
+ 'c', 't', 'i', 'o', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'v', 'a', 'l', '[', '*', ']', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'c', 'o', 'o', 'r', 'd', 'i', 'n', 'a', 't',
+ 'e', 's', '#', '1', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l',
'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'p', 'l', 'a', 't', 'f', 'o', 'r',
- 'm', '>', '(', 'o', 'p', 'a', 'q', 'u', 'e', ' ', 'i', 'n', ')', ';', 'e', 'x', 't',
- 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 'p', 'o', 's', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'p', 'r', 'o', 'c', 'e', 's', 's', '_',
- 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '#', '1', '(', 'U', '1', '6', ' ', 'p', 'o',
- 's', 'i', 't', 'i', 'o', 'n', '*', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':',
- 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', ' ', 'r', 'd', '_', 'f', 'i',
- 'l', 't', ',', 'N', 'C', 'B', 'I', ':', 'i', 's', 'a', 'm', 'p', '1', ' ', 's', 'i',
- 'g', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
- 'n', ' ', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd',
- '_', '1', '_', '2', 'a', '(', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u',
- 'n', 'c', 't', 'i', 'o', 'n', ' ', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', ' ',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'u', 'n',
- 't', 'y', 'p', 'e', 'd', '_', '1', '_', '2', 'b', '(', ')', ';', 'e', 'x', 't', 'e',
- 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'I', 'N',
- 'T', 'E', 'N', 'S', 'I', 'T', 'Y', '#', '1', '(', 'o', 'p', 'a', 'q', 'u', 'e', ' ',
+ 'm', '>', '(', 'a', 's', 'c', 'i', 'i', ' ', 's', 'k', 'e', 'y', ')', ';', 'e', 'x',
+ 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '_', '_', 'u',
+ 'n', 't', 'y', 'p', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_',
+ '4', '5', '4', '_', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '0', '(', ')', ';',
+ 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'U',
+ '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd',
+ 'e', ':', 'C', 'L', 'I', 'P', '#', '1', '(', 'o', 'p', 'a', 'q', 'u', 'e', ' ', 'i',
+ 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
+ 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'p', 'o', 's', '1', '6', ' ',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'P',
+ 'O', 'S', 'I', 'T', 'I', 'O', 'N', '#', '1', '(', 'o', 'p', 'a', 'q', 'u', 'e', ' ',
'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i',
- 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd',
- 'e', 'c', 'o', 'd', 'e', ':', 'N', 'O', 'I', 'S', 'E', '#', '1', '(', 'o', 'p', 'a',
+ 'o', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k',
+ 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd',
+ 'e', ':', 'R', 'E', 'A', 'D', '#', '1', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R',
+ 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'p', 'l', 'a',
+ 't', 'f', 'o', 'r', 'm', '>', '(', 'o', 'p', 'a', 'q', 'u', 'e', ' ', 'i', 'n', ')',
+ ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ',
+ 'a', 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o',
+ 'd', 'e', ':', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '#', '1', '<', 'I', 'N', 'S', 'D',
+ 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd',
+ ' ', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '>', '(', 'o', 'p', 'a', 'q', 'u', 'e',
+ ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't',
+ 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 'd', 'e', 'c', 'o', 'd', 'e', ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '1', '<', 'I',
+ 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm',
+ '_', 'i', 'd', ' ', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '>', '(', 'o', 'p', 'a',
'q', 'u', 'e', ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u',
+ 'n', 'c', 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'p',
+ 'o', 's', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5',
+ '4', '_', ':', 'p', 'r', 'o', 'c', 'e', 's', 's', '_', 'p', 'o', 's', 'i', 't', 'i',
+ 'o', 'n', '#', '1', '(', 'U', '1', '6', ' ', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n',
+ '*', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f',
+ 'i', 'l', 't', 'e', 'r', ' ', 'r', 'd', '_', 'f', 'i', 'l', 't', ',', 'N', 'C', 'B',
+ 'I', ':', 'i', 's', 'a', 'm', 'p', '1', ' ', 's', 'i', 'g', ')', ';', 'e', 'x', 't',
+ 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '_', '_', 'u', 'n',
+ 't', 'y', 'p', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4',
+ '5', '4', '_', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '1', '_', '2', 'a', '(',
+ ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
+ ' ', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_',
+ '1', '_', '2', 'b', '(', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n',
+ 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T',
+ 'Y', '#', '1', '(', 'o', 'p', 'a', 'q', 'u', 'e', ' ', 'i', 'n', ')', ';', 'e', 'x',
+ 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'a', 'n', 'y',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':',
+ 'N', 'O', 'I', 'S', 'E', '#', '1', '(', 'o', 'p', 'a', 'q', 'u', 'e', ' ', 'i', 'n',
+ ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
+ ' ', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'u', 'n', 't', 'y', 'p',
+ 'e', 'd', '_', '0', 'a', '(', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u',
'n', 'c', 't', 'i', 'o', 'n', ' ', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', ' ',
'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a',
- ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '0', 'a', '(', ')', ';', 'e', 'x', 't',
+ ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '0', 'b', '(', ')', ';', 'e', 'x', 't',
'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '_', '_', 'u', 'n',
't', 'y', 'p', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l',
- 'l', 'u', 'm', 'i', 'n', 'a', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '0', 'b',
+ 'l', 'u', 'm', 'i', 'n', 'a', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '1', 'a',
'(', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o',
- 'n', ' ', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'u', 'n', 't', 'y',
- 'p', 'e', 'd', '_', '1', 'a', '(', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f',
- 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'q', 'u', 'a', 'l', '4', '_', 'd', 'e', 'c', 'o', 'm',
- 'p', 'r', 'e', 's', 's', '_', 'v', '1', '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n',
+ 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e',
+ 'd', '_', 'q', 'u', 'a', 'l', '4', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 'q', 'u', 'a', 'l', '4', '_', 'd', 'e', 'c', 'o', 'm', 'p', 'r', 'e', 's', 's', '_',
+ 'v', '1', '#', '1', '(', 'a', 'n', 'y', ' ', 'i', 'n', ')', ';', 'e', 'x', 't', 'e',
+ 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n', ' ', '_', '_', 'u', 'n', 't',
+ 'y', 'p', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l',
+ 'u', 'm', 'i', 'n', 'a', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '1', 'b', '(',
')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u', 'n', 'c', 't', 'i', 'o', 'n',
' ', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'u', 'n', 't', 'y', 'p',
- 'e', 'd', '_', '1', 'b', '(', ')', ';', 'e', 'x', 't', 'e', 'r', 'n', ' ', 'f', 'u',
- 'n', 'c', 't', 'i', 'o', 'n', ' ', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', ' ',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 'u', 'n', 't', 'y',
- 'p', 'e', 'd', '_', '1', '(', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
- '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'i', 'z', 'i', 'p', '_', 'e', 'n',
- 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'r',
- 'e', 't', 'u', 'r', 'n', ' ', 'i', 'z', 'i', 'p', '#', '2', '.', '1', '(', '@', ')',
- ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', '(',
- 'T', ')', 'i', 'u', 'n', 'z', 'i', 'p', '#', '2', '.', '1', '(', '@', ')', ';', '}',
- '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T',
- '>', 'T', ' ', 'f', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#',
- '1', '<', 'U', '3', '2', ' ', 'm', 'a', 'n', 't', 'i', 's', 's', 'a', '>', '{', 'e',
- 'n', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'f', 'z', 'i', 'p',
- '#', '1', '<', 'm', 'a', 'n', 't', 'i', 's', 's', 'a', '>', '(', '@', ')', ';', '}',
- 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'f', 'u', 'n',
- 'z', 'i', 'p', '#', '1', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c',
- 'a', 'l', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'z', 'i', 'p', '_',
- 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '<', '*', 'I', '3', '2', ' ', 's',
- 't', 'r', 'a', 't', 'e', 'g', 'y', ',', 'I', '3', '2', ' ', 'l', 'e', 'v', 'e', 'l',
- '>', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'z',
- 'i', 'p', '#', '1', '<', 's', 't', 'r', 'a', 't', 'e', 'g', 'y', ',', 'l', 'e', 'v',
- 'e', 'l', '>', '(', '@', ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e',
- 't', 'u', 'r', 'n', ' ', 'u', 'n', 'z', 'i', 'p', '#', '1', '(', '@', ')', ';', '}',
- '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'b', 'o', 'o', 'l', ' ', 'b', 'o',
- 'o', 'l', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '{', 'e', 'n', 'c',
- 'o', 'd', 'e', '{', 'U', '8', ' ', 'l', 'i', 'm', '=', '<', 'U', '8', '>', 'c', 'l',
- 'i', 'p', '#', '1', '<', '0', ',', '1', '>', '(', '@', ')', ';', 'B', '1', ' ', 'b',
- 'i', 't', '=', 'p', 'a', 'c', 'k', '#', '1', '(', 'l', 'i', 'm', ')', ';', 'r', 'e',
- 't', 'u', 'r', 'n', ' ', 'z', 'i', 'p', '#', '1', '<', '3', ',', '1', '>', '(', 'b',
- 'i', 't', ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'B', '1', ' ', 'b', 'i',
- 't', '=', 'u', 'n', 'z', 'i', 'p', '#', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u',
- 'r', 'n', ' ', '(', 'b', 'o', 'o', 'l', ')', 'u', 'n', 'p', 'a', 'c', 'k', '#', '1',
- '(', 'b', 'i', 't', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
- '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'd', 'e', 'l', 't', 'a', '_', 'i',
- 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '{', 'e', 'n',
- 'c', 'o', 'd', 'e', '{', 'T', ' ', 'd', 'l', 't', '=', '<', 'T', '>', 'd', 'e', 'l',
- 't', 'a', '#', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'i', 'z',
- 'i', 'p', '#', '2', '.', '1', '(', 'd', 'l', 't', ')', ';', '}', 'd', 'e', 'c', 'o',
- 'd', 'e', '{', 'T', ' ', 'd', 'l', 't', '=', 'i', 'u', 'n', 'z', 'i', 'p', '#', '2',
- '.', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', '<', 'T', '>', 'u',
+ 'R', 'A', ':', 'A', 'B', 'I', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '1', '(',
+ ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '<', 't', 'y', 'p', 'e', ' ',
+ 'T', '>', 'T', ' ', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g',
+ '#', '1', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ',
+ 'i', 'z', 'i', 'p', '#', '2', '.', '1', '(', '@', ')', ';', '}', 'd', 'e', 'c', 'o',
+ 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', '(', 'T', ')', 'i', 'u', 'n', 'z',
+ 'i', 'p', '#', '2', '.', '1', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i',
+ 'c', 'a', 'l', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'f', 'z', 'i',
+ 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '<', 'U', '3', '2', ' ',
+ 'm', 'a', 'n', 't', 'i', 's', 's', 'a', '>', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{',
+ 'r', 'e', 't', 'u', 'r', 'n', ' ', 'f', 'z', 'i', 'p', '#', '1', '<', 'm', 'a', 'n',
+ 't', 'i', 's', 's', 'a', '>', '(', '@', ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e',
+ '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'f', 'u', 'n', 'z', 'i', 'p', '#', '1', '(',
+ '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '<', 't', 'y',
+ 'p', 'e', ' ', 'T', '>', 'T', ' ', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i',
+ 'n', 'g', '#', '1', '<', '*', 'I', '3', '2', ' ', 's', 't', 'r', 'a', 't', 'e', 'g',
+ 'y', ',', 'I', '3', '2', ' ', 'l', 'e', 'v', 'e', 'l', '>', '{', 'e', 'n', 'c', 'o',
+ 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'z', 'i', 'p', '#', '1', '<', 's',
+ 't', 'r', 'a', 't', 'e', 'g', 'y', ',', 'l', 'e', 'v', 'e', 'l', '>', '(', '@', ')',
+ ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'u',
+ 'n', 'z', 'i', 'p', '#', '1', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i',
+ 'c', 'a', 'l', ' ', 'b', 'o', 'o', 'l', ' ', 'b', 'o', 'o', 'l', '_', 'e', 'n', 'c',
+ 'o', 'd', 'i', 'n', 'g', '#', '1', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'U', '8',
+ ' ', 'l', 'i', 'm', '=', '<', 'U', '8', '>', 'c', 'l', 'i', 'p', '#', '1', '<', '0',
+ ',', '1', '>', '(', '@', ')', ';', 'B', '1', ' ', 'b', 'i', 't', '=', 'p', 'a', 'c',
+ 'k', '#', '1', '(', 'l', 'i', 'm', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'z',
+ 'i', 'p', '#', '1', '<', '3', ',', '1', '>', '(', 'b', 'i', 't', ')', ';', '}', 'd',
+ 'e', 'c', 'o', 'd', 'e', '{', 'B', '1', ' ', 'b', 'i', 't', '=', 'u', 'n', 'z', 'i',
+ 'p', '#', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', '(', 'b', 'o',
+ 'o', 'l', ')', 'u', 'n', 'p', 'a', 'c', 'k', '#', '1', '(', 'b', 'i', 't', ')', ';',
+ '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '<', 't', 'y', 'p', 'e', ' ',
+ 'T', '>', 'T', ' ', 'd', 'e', 'l', 't', 'a', '_', 'i', 'z', 'i', 'p', '_', 'e', 'n',
+ 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'T',
+ ' ', 'd', 'l', 't', '=', '<', 'T', '>', 'd', 'e', 'l', 't', 'a', '#', '1', '(', '@',
+ ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'i', 'z', 'i', 'p', '#', '2', '.', '1',
+ '(', 'd', 'l', 't', ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'T', ' ', 'd',
+ 'l', 't', '=', 'i', 'u', 'n', 'z', 'i', 'p', '#', '2', '.', '1', '(', '@', ')', ';',
+ 'r', 'e', 't', 'u', 'r', 'n', ' ', '<', 'T', '>', 'u', 'n', 'd', 'e', 'l', 't', 'a',
+ '#', '1', '(', 'd', 'l', 't', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a',
+ 'l', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ', 'd', 'e', 'l', 't', 'a',
+ '_', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '{', 'e',
+ 'n', 'c', 'o', 'd', 'e', '{', 'T', ' ', 'd', 'l', 't', '=', '<', 'T', '>', 'd', 'e',
+ 'l', 't', 'a', '#', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'z',
+ 'i', 'p', '#', '1', '<', '3', ',', '1', '>', '(', 'd', 'l', 't', ')', ';', '}', 'd',
+ 'e', 'c', 'o', 'd', 'e', '{', 'T', ' ', 'd', 'l', 't', '=', 'u', 'n', 'z', 'i', 'p',
+ '#', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', '<', 'T', '>', 'u',
'n', 'd', 'e', 'l', 't', 'a', '#', '1', '(', 'd', 'l', 't', ')', ';', '}', '}', 'p',
'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T',
- ' ', 'd', 'e', 'l', 't', 'a', '_', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i',
- 'n', 'g', '#', '1', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'T', ' ', 'd', 'l', 't',
- '=', '<', 'T', '>', 'd', 'e', 'l', 't', 'a', '#', '1', '(', '@', ')', ';', 'r', 'e',
- 't', 'u', 'r', 'n', ' ', 'z', 'i', 'p', '#', '1', '<', '3', ',', '1', '>', '(', 'd',
- 'l', 't', ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'T', ' ', 'd', 'l', 't',
- '=', 'u', 'n', 'z', 'i', 'p', '#', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r',
- 'n', ' ', '<', 'T', '>', 'u', 'n', 'd', 'e', 'l', 't', 'a', '#', '1', '(', 'd', 'l',
- 't', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '<', 't', 'y',
- 'p', 'e', ' ', 'T', '>', 'T', ' ', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v', 'e', 'r',
- 'a', 'g', 'e', '_', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#',
- '1', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v',
- 'e', 'r', 'a', 'g', 'e', 'd', '_', 'f', 'm', 't', ' ', 't', '=', 'd', 'e', 'l', 't',
- 'a', '_', 'a', 'v', 'e', 'r', 'a', 'g', 'e', '#', '1', '(', '@', ')', ';', 'r', 'e',
- 't', 'u', 'r', 'n', ' ', 'z', 'i', 'p', '#', '1', '<', '3', ',', '1', '>', '(', 't',
- ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'd', 'e', 'l', 't', 'a', '_', 'a',
- 'v', 'e', 'r', 'a', 'g', 'e', 'd', '_', 'f', 'm', 't', ' ', 't', '=', 'u', 'n', 'z',
- 'i', 'p', '#', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'u', 'n',
- 'd', 'e', 'l', 't', 'a', '_', 'a', 'v', 'e', 'r', 'a', 'g', 'e', '#', '1', '(', 't',
- ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '<', 't', 'y', 'p',
- 'e', ' ', 'T', '>', 'T', ' ', 'b', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i',
- 'n', 'g', '#', '1', '<', '*', 'U', '3', '2', ' ', 'b', 'l', 'o', 'c', 'k', 'S', 'i',
- 'z', 'e', '1', '0', '0', 'k', ',', 'U', '3', '2', ' ', 'w', 'o', 'r', 'k', 'F', 'a',
- 'c', 't', 'o', 'r', '>', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u',
- 'r', 'n', ' ', 'b', 'z', 'i', 'p', '#', '1', '<', 'b', 'l', 'o', 'c', 'k', 'S', 'i',
- 'z', 'e', '1', '0', '0', 'k', ',', 'w', 'o', 'r', 'k', 'F', 'a', 'c', 't', 'o', 'r',
- '>', '(', '@', ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u',
- 'r', 'n', ' ', 'b', 'u', 'n', 'z', 'i', 'p', '#', '1', '(', '@', ')', ';', '}', '}',
- 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C', 'L',
- 'I', 'P', '#', '2', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r',
- 'n', ' ', 'i', 'z', 'i', 'p', '#', '2', '.', '1', '(', '@', ')', ';', '}', 'd', 'e',
- 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', '(', 'I', 'N', 'S', 'D',
- 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ')', 'i', 'u', 'n', 'z', 'i',
- 'p', '#', '2', '.', '1', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c',
- 'a', 'l', ' ', 'N', 'C', 'B', 'I', ':', 'i', 's', 'a', 'm', 'p', '1', ' ', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o',
- 'd', 'i', 'n', 'g', ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '2', '{', 'e', 'n', 'c',
- 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'i', 'z', 'i', 'p', '#', '2',
- '.', '1', '(', '@', ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't',
- 'u', 'r', 'n', ' ', '(', 'N', 'C', 'B', 'I', ':', 'i', 's', 'a', 'm', 'p', '1', ')',
- 'i', 'u', 'n', 'z', 'i', 'p', '#', '2', '.', '1', '(', '@', ')', ';', '}', '}', 'p',
- 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's',
- 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':',
- 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', '#', '2', '{', 'e', 'n', 'c', 'o', 'd', 'e',
- '{', 'I', '3', '2', ' ', 'p', 'o', 's', '_', '1', 's', 't', '_', 'd', 'e', 'r', 'i',
- 'v', '=', '<', 'I', '3', '2', '>', 'd', 'e', 'r', 'i', 'v', '#', '1', '(', '@', ')',
- ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'i', 'z', 'i', 'p', '#', '2', '.', '1', '(',
- 'p', 'o', 's', '_', '1', 's', 't', '_', 'd', 'e', 'r', 'i', 'v', ')', ';', '}', 'd',
- 'e', 'c', 'o', 'd', 'e', '{', 'I', '3', '2', ' ', 'p', 'o', 's', '_', '1', 's', 't',
- '_', 'd', 'e', 'r', 'i', 'v', '=', 'i', 'u', 'n', 'z', 'i', 'p', '#', '2', '.', '1',
- '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', '(', 'I', 'N', 'S', 'D', 'C',
- ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', ')', '<', 'I', '3',
- '2', '>', 'i', 'n', 't', 'e', 'g', 'r', 'a', 'l', '#', '1', '(', 'p', 'o', 's', '_',
- '1', 's', 't', '_', 'd', 'e', 'r', 'i', 'v', ')', ';', '}', '}', 'p', 'h', 'y', 's',
- 'i', 'c', 'a', 'l', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a',
- 'p', 'p', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4', ' ', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 'q', 'u', 'a', 'l', '4', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g',
- '#', '1', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 'e', 'n', 'c', 'o', 'd', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4', ' ', 'e',
- 'n', 'c', 'o', 'd', 'e', 'd', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'q',
- 'u', 'a', 'l', '4', '_', 'e', 'n', 'c', 'o', 'd', 'e', '#', '1', '(', '@', ')', ';',
- 'r', 'e', 't', 'u', 'r', 'n', ' ', 'z', 'i', 'p', '#', '1', '<', '3', ',', '1', '>',
- '(', 'e', 'n', 'c', 'o', 'd', 'e', 'd', ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e',
- '{', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'n', 'c', 'o', 'd', 'e', 'd',
- '_', 'q', 'u', 'a', 'l', '4', ' ', 'u', 'n', 'z', 'i', 'p', 'p', 'e', 'd', '=', 'u',
- 'n', 'z', 'i', 'p', '#', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'q', 'u', 'a', 'l', '4', '_', 'd', 'e',
- 'c', 'o', 'd', 'e', '#', '1', '(', 'u', 'n', 'z', 'i', 'p', 'p', 'e', 'd', ')', ';',
- '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4',
- ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n',
- 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'S', 'I', 'G', 'N', 'A', 'L',
- '#', '2', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'f', 's', 'a', 'm', 'p', '4', ':', 'e',
- 'n', 'c', 'o', 'd', 'e', '#', '2', '<', '1', '4', ',', '1', '0', '>', '(', '@', ')',
- ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'f', 's', 'a', 'm', 'p', '4', ':', 'd', 'e',
- 'c', 'o', 'd', 'e', '#', '2', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i',
- 'c', 'a', 'l', ' ', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':',
- 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'N', 'O', 'I', 'S', 'E', '#', '2', '{',
- 'e', 'n', 'c', 'o', 'd', 'e', '{', 'F', '3', '2', ' ', 'n', 'c', 'm', 'p', '=', 'r',
- 'e', 'd', 'i', 'm', 'e', 'n', 's', 'i', 'o', 'n', '#', '1', '(', '@', ')', ';', 'r',
- 'e', 't', 'u', 'r', 'n', ' ', 'f', 'z', 'i', 'p', '#', '1', '<', '1', '0', '>', '(',
- 'n', 'c', 'm', 'p', ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'F', '3', '2',
- ' ', 'd', 'c', 'm', 'p', '=', 'f', 'u', 'n', 'z', 'i', 'p', '#', '1', '(', '@', ')',
- ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'r', 'e', 'd', 'i', 'm', 'e', 'n', 's', 'i',
- 'o', 'n', '#', '1', '(', 'd', 'c', 'm', 'p', ')', ';', '}', '}', 'p', 'h', 'y', 's',
+ ' ', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v', 'e', 'r', 'a', 'g', 'e', '_', 'z', 'i',
+ 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '{', 'e', 'n', 'c', 'o',
+ 'd', 'e', '{', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v', 'e', 'r', 'a', 'g', 'e', 'd',
+ '_', 'f', 'm', 't', ' ', 't', '=', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v', 'e', 'r',
+ 'a', 'g', 'e', '#', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'z',
+ 'i', 'p', '#', '1', '<', '3', ',', '1', '>', '(', 't', ')', ';', '}', 'd', 'e', 'c',
+ 'o', 'd', 'e', '{', 'd', 'e', 'l', 't', 'a', '_', 'a', 'v', 'e', 'r', 'a', 'g', 'e',
+ 'd', '_', 'f', 'm', 't', ' ', 't', '=', 'u', 'n', 'z', 'i', 'p', '#', '1', '(', '@',
+ ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'u', 'n', 'd', 'e', 'l', 't', 'a', '_',
+ 'a', 'v', 'e', 'r', 'a', 'g', 'e', '#', '1', '(', 't', ')', ';', '}', '}', 'p', 'h',
+ 'y', 's', 'i', 'c', 'a', 'l', ' ', '<', 't', 'y', 'p', 'e', ' ', 'T', '>', 'T', ' ',
+ 'b', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '<', '*',
+ 'U', '3', '2', ' ', 'b', 'l', 'o', 'c', 'k', 'S', 'i', 'z', 'e', '1', '0', '0', 'k',
+ ',', 'U', '3', '2', ' ', 'w', 'o', 'r', 'k', 'F', 'a', 'c', 't', 'o', 'r', '>', '{',
+ 'e', 'n', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'b', 'z', 'i',
+ 'p', '#', '1', '<', 'b', 'l', 'o', 'c', 'k', 'S', 'i', 'z', 'e', '1', '0', '0', 'k',
+ ',', 'w', 'o', 'r', 'k', 'F', 'a', 'c', 't', 'o', 'r', '>', '(', '@', ')', ';', '}',
+ 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'b', 'u', 'n',
+ 'z', 'i', 'p', '#', '1', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c',
+ 'a', 'l', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n',
+ 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':',
+ 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C', 'L', 'I', 'P', '#', '2', '{', 'e',
+ 'n', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'i', 'z', 'i', 'p',
+ '#', '2', '.', '1', '(', '@', ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r',
+ 'e', 't', 'u', 'r', 'n', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'o', 'n', 'e', ')', 'i', 'u', 'n', 'z', 'i', 'p', '#', '2', '.', '1', '(',
+ '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'N', 'C', 'B',
+ 'I', ':', 'i', 's', 'a', 'm', 'p', '1', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'S',
+ 'I', 'G', 'N', 'A', 'L', '#', '2', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'r', 'e',
+ 't', 'u', 'r', 'n', ' ', 'i', 'z', 'i', 'p', '#', '2', '.', '1', '(', '@', ')', ';',
+ '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', '(', 'N',
+ 'C', 'B', 'I', ':', 'i', 's', 'a', 'm', 'p', '1', ')', 'i', 'u', 'n', 'z', 'i', 'p',
+ '#', '2', '.', '1', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a',
+ 'l', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':',
+ 'o', 'n', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4',
+ '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'P', 'O', 'S', 'I', 'T', 'I',
+ 'O', 'N', '#', '2', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'I', '3', '2', ' ', 'p',
+ 'o', 's', '_', '1', 's', 't', '_', 'd', 'e', 'r', 'i', 'v', '=', '<', 'I', '3', '2',
+ '>', 'd', 'e', 'r', 'i', 'v', '#', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r',
+ 'n', ' ', 'i', 'z', 'i', 'p', '#', '2', '.', '1', '(', 'p', 'o', 's', '_', '1', 's',
+ 't', '_', 'd', 'e', 'r', 'i', 'v', ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{',
+ 'I', '3', '2', ' ', 'p', 'o', 's', '_', '1', 's', 't', '_', 'd', 'e', 'r', 'i', 'v',
+ '=', 'i', 'u', 'n', 'z', 'i', 'p', '#', '2', '.', '1', '(', '@', ')', ';', 'r', 'e',
+ 't', 'u', 'r', 'n', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't',
+ 'i', 'o', 'n', ':', 'o', 'n', 'e', ')', '<', 'I', '3', '2', '>', 'i', 'n', 't', 'e',
+ 'g', 'r', 'a', 'l', '#', '1', '(', 'p', 'o', 's', '_', '1', 's', 't', '_', 'd', 'e',
+ 'r', 'i', 'v', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'q',
+ 'u', 'a', 'l', '4', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'q', 'u', 'a',
+ 'l', '4', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '{', 'e', 'n', 'c',
+ 'o', 'd', 'e', '{', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'n', 'c', 'o',
+ 'd', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4', ' ', 'e', 'n', 'c', 'o', 'd', 'e', 'd',
+ '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'q', 'u', 'a', 'l', '4', '_', 'e',
+ 'n', 'c', 'o', 'd', 'e', '#', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r', 'n',
+ ' ', 'z', 'i', 'p', '#', '1', '<', '3', ',', '1', '>', '(', 'e', 'n', 'c', 'o', 'd',
+ 'e', 'd', ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'N', 'C', 'B', 'I', ':',
+ 'S', 'R', 'A', ':', 'e', 'n', 'c', 'o', 'd', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4',
+ ' ', 'u', 'n', 'z', 'i', 'p', 'p', 'e', 'd', '=', 'u', 'n', 'z', 'i', 'p', '#', '1',
+ '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 'q', 'u', 'a', 'l', '4', '_', 'd', 'e', 'c', 'o', 'd', 'e', '#', '1',
+ '(', 'u', 'n', 'z', 'i', 'p', 'p', 'e', 'd', ')', ';', '}', '}', 'p', 'h', 'y', 's',
'i', 'c', 'a', 'l', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a',
'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ' ', 'N', 'C', 'B', 'I', ':',
'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o',
- 'd', 'i', 'n', 'g', ':', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', '#', '2', '{',
- 'e', 'n', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'f', 's', 'a', 'm', 'p', '4', ':', 'e', 'n', 'c', 'o',
- 'd', 'e', '#', '2', '<', '1', '4', ',', '1', '0', '>', '(', '@', ')', ';', '}', 'd',
- 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 'f', 's', 'a', 'm', 'p', '4', ':', 'd', 'e', 'c', 'o', 'd',
- 'e', '#', '2', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l',
- ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd',
- '_', 'f', 's', 'a', 'm', 'p', '4', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'A', 'B', 'I', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'S', 'I', 'G', 'N',
- 'A', 'L', '#', '2', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r',
- 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'f', 's', 'a', 'm', 'p', '4',
- ':', 'e', 'n', 'c', 'o', 'd', 'e', '#', '2', '<', '1', '4', ',', '1', '0', '>', '(',
- '@', ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n',
- ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'f', 's', 'a', 'm', 'p', '4', ':',
- 'd', 'e', 'c', 'o', 'd', 'e', '#', '2', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y',
- 's', 'i', 'c', 'a', 'l', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't',
- 'i', 'o', 'n', ':', 'o', 'n', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'I', 'o', 'n', 'T', 'o', 'r', 'r', 'e', 'n', 't', ':', 'e', 'n', 'c', 'o', 'd', 'i',
- 'n', 'g', ':', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', '#', '1', '{', 'e', 'n', 'c',
- 'o', 'd', 'e', '{', 'I', '3', '2', ' ', 'p', 'o', 's', '_', '1', 's', 't', '_', 'd',
- 'e', 'r', 'i', 'v', '=', '<', 'I', '3', '2', '>', 'd', 'e', 'r', 'i', 'v', '#', '1',
- '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'i', 'z', 'i', 'p', '#', '2',
- '.', '1', '(', 'p', 'o', 's', '_', '1', 's', 't', '_', 'd', 'e', 'r', 'i', 'v', ')',
- ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'I', '3', '2', ' ', 'p', 'o', 's', '_',
- '1', 's', 't', '_', 'd', 'e', 'r', 'i', 'v', '=', 'i', 'u', 'n', 'z', 'i', 'p', '#',
- '2', '.', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', '(', 'I', 'N',
- 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', ')',
- '<', 'I', '3', '2', '>', 'i', 'n', 't', 'e', 'g', 'r', 'a', 'l', '#', '1', '(', 'p',
- 'o', 's', '_', '1', 's', 't', '_', 'd', 'e', 'r', 'i', 'v', ')', ';', '}', '}', 'p',
+ 'd', 'i', 'n', 'g', ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '2', '{', 'e', 'n', 'c',
+ 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 'f', 's', 'a', 'm', 'p', '4', ':', 'e', 'n', 'c', 'o', 'd', 'e', '#',
+ '2', '<', '1', '4', ',', '1', '0', '>', '(', '@', ')', ';', '}', 'd', 'e', 'c', 'o',
+ 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'f', 's', 'a', 'm', 'p', '4', ':', 'd', 'e', 'c', 'o', 'd', 'e', '#', '2',
+ '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'N', 'C',
+ 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i',
+ 'n', 'g', ':', 'N', 'O', 'I', 'S', 'E', '#', '2', '{', 'e', 'n', 'c', 'o', 'd', 'e',
+ '{', 'F', '3', '2', ' ', 'n', 'c', 'm', 'p', '=', 'r', 'e', 'd', 'i', 'm', 'e', 'n',
+ 's', 'i', 'o', 'n', '#', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r', 'n', ' ',
+ 'f', 'z', 'i', 'p', '#', '1', '<', '1', '0', '>', '(', 'n', 'c', 'm', 'p', ')', ';',
+ '}', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'F', '3', '2', ' ', 'd', 'c', 'm', 'p', '=',
+ 'f', 'u', 'n', 'z', 'i', 'p', '#', '1', '(', '@', ')', ';', 'r', 'e', 't', 'u', 'r',
+ 'n', ' ', 'r', 'e', 'd', 'i', 'm', 'e', 'n', 's', 'i', 'o', 'n', '#', '1', '(', 'd',
+ 'c', 'm', 'p', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f',
+ 's', 'a', 'm', 'p', '4', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l',
+ 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'I',
+ 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', '#', '2', '{', 'e', 'n', 'c', 'o', 'd', 'e',
+ '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 'f', 's', 'a', 'm', 'p', '4', ':', 'e', 'n', 'c', 'o', 'd', 'e', '#', '2', '<', '1',
+ '4', ',', '1', '0', '>', '(', '@', ')', ';', '}', 'd', 'e', 'c', 'o', 'd', 'e', '{',
+ 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'f',
+ 's', 'a', 'm', 'p', '4', ':', 'd', 'e', 'c', 'o', 'd', 'e', '#', '2', '(', '@', ')',
+ ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'N', 'C', 'B', 'I', ':',
+ 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p',
+ '4', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 'e', 'n',
+ 'c', 'o', 'd', 'i', 'n', 'g', ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '2', '{', 'e',
+ 'n', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I',
+ ':', 'S', 'R', 'A', ':', 'f', 's', 'a', 'm', 'p', '4', ':', 'e', 'n', 'c', 'o', 'd',
+ 'e', '#', '2', '<', '1', '4', ',', '1', '0', '>', '(', '@', ')', ';', '}', 'd', 'e',
+ 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':',
+ 'S', 'R', 'A', ':', 'f', 's', 'a', 'm', 'p', '4', ':', 'd', 'e', 'c', 'o', 'd', 'e',
+ '#', '2', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
+ 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n',
+ 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'o', 'n', 'T', 'o', 'r',
+ 'r', 'e', 'n', 't', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'P', 'O', 'S',
+ 'I', 'T', 'I', 'O', 'N', '#', '1', '{', 'e', 'n', 'c', 'o', 'd', 'e', '{', 'I', '3',
+ '2', ' ', 'p', 'o', 's', '_', '1', 's', 't', '_', 'd', 'e', 'r', 'i', 'v', '=', '<',
+ 'I', '3', '2', '>', 'd', 'e', 'r', 'i', 'v', '#', '1', '(', '@', ')', ';', 'r', 'e',
+ 't', 'u', 'r', 'n', ' ', 'i', 'z', 'i', 'p', '#', '2', '.', '1', '(', 'p', 'o', 's',
+ '_', '1', 's', 't', '_', 'd', 'e', 'r', 'i', 'v', ')', ';', '}', 'd', 'e', 'c', 'o',
+ 'd', 'e', '{', 'I', '3', '2', ' ', 'p', 'o', 's', '_', '1', 's', 't', '_', 'd', 'e',
+ 'r', 'i', 'v', '=', 'i', 'u', 'n', 'z', 'i', 'p', '#', '2', '.', '1', '(', '@', ')',
+ ';', 'r', 'e', 't', 'u', 'r', 'n', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o',
+ 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', ')', '<', 'I', '3', '2', '>', 'i',
+ 'n', 't', 'e', 'g', 'r', 'a', 'l', '#', '1', '(', 'p', 'o', 's', '_', '1', 's', 't',
+ '_', 'd', 'e', 'r', 'i', 'v', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a',
+ 'l', ' ', '_', '_', 'n', 'o', '_', 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'U', '1', '6',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'e',
+ 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C', 'L', 'I', 'P', '#', '1', '{', 'd', 'e',
+ 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':',
+ 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'C', 'L', 'I', 'P', '#', '1',
+ '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '_', '_',
+ 'n', 'o', '_', 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'p', 'o', 's', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'P', 'O',
+ 'S', 'I', 'T', 'I', 'O', 'N', '#', '1', '{', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r',
+ 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e',
+ 'c', 'o', 'd', 'e', ':', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', '#', '1', '(', '@',
+ ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '_', '_', 'n', 'o',
+ '_', 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a',
+ ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'R', 'E',
+ 'A', 'D', '#', '1', '{', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r',
+ 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e',
+ ':', 'R', 'E', 'A', 'D', '#', '1', '<', '1', '>', '(', '@', ')', ';', '}', '}', 'p',
'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '_', '_', 'n', 'o', '_', 'h', 'e', 'a', 'd',
- 'e', 'r', ' ', 'U', '1', '6', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_',
- '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C', 'L', 'I',
- 'P', '#', '1', '{', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n',
- ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':',
- 'C', 'L', 'I', 'P', '#', '1', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i',
- 'c', 'a', 'l', ' ', '_', '_', 'n', 'o', '_', 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'p', 'o', 's', '1', '6', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd',
- 'i', 'n', 'g', ':', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', '#', '1', '{', 'd', 'e',
+ 'e', 'r', ' ', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'n',
+ '_', 'e', 'n', 'c', 'o', 'd', 'e', 'd', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o',
+ 'd', 'i', 'n', 'g', ':', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '#', '1', '{', 'd', 'e',
'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'P', 'O', 'S', 'I', 'T', 'I',
- 'O', 'N', '#', '1', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a',
- 'l', ' ', '_', '_', 'n', 'o', '_', 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'I', 'N', 'S',
- 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd',
- 'i', 'n', 'g', ':', 'R', 'E', 'A', 'D', '#', '1', '{', 'd', 'e', 'c', 'o', 'd', 'e',
- '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'd', 'e', 'c', 'o', 'd', 'e', ':', 'R', 'E', 'A', 'D', '#', '1', '<', '1', '>', '(',
- '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '_', '_', 'n',
- 'o', '_', 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a',
- 'l', 'i', 't', 'y', ':', 'n', '_', 'e', 'n', 'c', 'o', 'd', 'e', 'd', ':', 'p', 'h',
- 'r', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4',
- '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'Q', 'U', 'A', 'L', 'I', 'T',
- 'Y', '#', '1', '{', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n',
- ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':',
- 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '#', '1', '<', '1', '>', '(', '@', ')', ';', '}',
- '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '_', '_', 'n', 'o', '_', 'h', 'e',
- 'a', 'd', 'e', 'r', ' ', 'N', 'C', 'B', 'I', ':', 'i', 's', 'a', 'm', 'p', '1', ' ',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'e', 'n',
- 'c', 'o', 'd', 'i', 'n', 'g', ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '1', '{', 'd',
- 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'S', 'I', 'G', 'N', 'A',
- 'L', '#', '1', '<', '1', '>', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i',
- 'c', 'a', 'l', ' ', '_', '_', 'n', 'o', '_', 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'I',
- 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':',
- 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'R', 'E', 'A', 'D', '#', '1', '{', 'd',
- 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'R', 'E', 'A', 'D', '#',
- '1', '<', '2', '>', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a',
- 'l', ' ', '_', '_', 'n', 'o', '_', 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'r', 'o', 't', 'a', 't', 'e', 'd', '_', 'q', 'u', 'a',
- 'l', '4', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm',
- 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'Q', 'U', 'A', 'L',
- 'I', 'T', 'Y', '#', '1', '{', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u',
- 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd',
- 'e', ':', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '#', '1', '<', '2', '>', '(', '@', ')',
- ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '_', '_', 'n', 'o', '_',
- 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l',
- 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'Q', 'U', 'A', 'L', 'I', 'T',
+ 'Y', '#', '1', '<', '1', '>', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i',
+ 'c', 'a', 'l', ' ', '_', '_', 'n', 'o', '_', 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'N',
+ 'C', 'B', 'I', ':', 'i', 's', 'a', 'm', 'p', '1', ' ', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g',
+ ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '1', '{', 'd', 'e', 'c', 'o', 'd', 'e', '{',
+ 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd',
+ 'e', 'c', 'o', 'd', 'e', ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '1', '<', '1', '>',
+ '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '_', '_',
+ 'n', 'o', '_', 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'I', 'N', 'S', 'D', 'C', ':', '2',
+ 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i',
- 'n', 'g', ':', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '2', '#', '1', '{', 'd', 'e', 'c',
- 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y',
- '#', '1', '<', '2', '>', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c',
- 'a', 'l', ' ', '_', '_', 'n', 'o', '_', 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'o', 't', 'a', 't', 'e', 'd', '_', 'f', 's',
- 'a', 'm', 'p', '4', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l',
- 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'S', 'I',
- 'G', 'N', 'A', 'L', '#', '1', '{', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't',
- 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o',
- 'd', 'e', ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '1', '<', '2', '>', '(', '@', ')',
- ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '_', '_', 'n', 'o', '_',
- 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r',
- 'o', 't', 'a', 't', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n',
- 'c', 'o', 'd', 'i', 'n', 'g', ':', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', '#',
- '1', '{', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'I', 'N',
- 'T', 'E', 'N', 'S', 'I', 'T', 'Y', '#', '1', '(', '@', ')', ';', '}', '}', 'p', 'h',
- 'y', 's', 'i', 'c', 'a', 'l', ' ', '_', '_', 'n', 'o', '_', 'h', 'e', 'a', 'd', 'e',
- 'r', ' ', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'N', 'C', 'B',
+ 'n', 'g', ':', 'R', 'E', 'A', 'D', '#', '1', '{', 'd', 'e', 'c', 'o', 'd', 'e', '{',
+ 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd',
+ 'e', 'c', 'o', 'd', 'e', ':', 'R', 'E', 'A', 'D', '#', '1', '<', '2', '>', '(', '@',
+ ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '_', '_', 'n', 'o',
+ '_', 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 'r', 'o', 't', 'a', 't', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4', ' ', 'N', 'C', 'B',
'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n',
- 'c', 'o', 'd', 'i', 'n', 'g', ':', 'N', 'O', 'I', 'S', 'E', '#', '1', '{', 'd', 'e',
- 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'N', 'O', 'I', 'S', 'E', '#',
- '1', '(', '@', ')', ';', '}', '}', 't', 'a', 'b', 'l', 'e', ' ', 'I', 'N', 'S', 'D',
- 'C', ':', 't', 'b', 'l', ':', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.',
- '0', '.', '1', '{', 'd', 'e', 'f', 'a', 'u', 'l', 't', ' ', 'c', 'o', 'l', 'u', 'm',
- 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ',
- 'R', 'E', 'A', 'D', '{', 'r', 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 'd', 'n', 'a',
- '_', 't', 'e', 'x', 't', ';', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '=', '<', 'I',
- 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'c', 'o', 'm',
- 'p', 'a', 'r', 'e', '#', '1', '(', 'i', 'n', '_', 'd', 'n', 'a', '_', 't', 'e', 'x',
- 't', ',', 'o', 'u', 't', '_', 'd', 'n', 'a', '_', 't', 'e', 'x', 't', ')', ';', '}',
+ 'c', 'o', 'd', 'i', 'n', 'g', ':', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '#', '1', '{',
+ 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'Q', 'U', 'A', 'L',
+ 'I', 'T', 'Y', '#', '1', '<', '2', '>', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y',
+ 's', 'i', 'c', 'a', 'l', ' ', '_', '_', 'n', 'o', '_', 'h', 'e', 'a', 'd', 'e', 'r',
+ ' ', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h',
+ 'r', 'e', 'd', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u',
+ 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'Q', 'U', 'A',
+ 'L', 'I', 'T', 'Y', '2', '#', '1', '{', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e',
+ 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c',
+ 'o', 'd', 'e', ':', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '#', '1', '<', '2', '>', '(',
+ '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', '_', '_', 'n',
+ 'o', '_', 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', 'r', 'o', 't', 'a', 't', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ' ', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':',
+ 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '1',
+ '{', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'S', 'I', 'G',
+ 'N', 'A', 'L', '#', '1', '<', '2', '>', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y',
+ 's', 'i', 'c', 'a', 'l', ' ', '_', '_', 'n', 'o', '_', 'h', 'e', 'a', 'd', 'e', 'r',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'o', 't', 'a', 't', 'e', 'd',
+ '_', 'f', 's', 'a', 'm', 'p', '4', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g',
+ ':', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', '#', '1', '{', 'd', 'e', 'c', 'o',
+ 'd', 'e', '{', 'r', 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'd', 'e', 'c', 'o', 'd', 'e', ':', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T',
+ 'Y', '#', '1', '(', '@', ')', ';', '}', '}', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l',
+ ' ', '_', '_', 'n', 'o', '_', 'h', 'e', 'a', 'd', 'e', 'r', ' ', 'N', 'C', 'B', 'I',
+ ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g',
+ ':', 'N', 'O', 'I', 'S', 'E', '#', '1', '{', 'd', 'e', 'c', 'o', 'd', 'e', '{', 'r',
+ 'e', 't', 'u', 'r', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e',
+ 'c', 'o', 'd', 'e', ':', 'N', 'O', 'I', 'S', 'E', '#', '1', '(', '@', ')', ';', '}',
+ '}', 't', 'a', 'b', 'l', 'e', ' ', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l', ':',
+ 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0', '.', '1', '{', 'd', 'e',
+ 'f', 'a', 'u', 'l', 't', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D',
+ 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'R', 'E', 'A', 'D', '{', 'r',
+ 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 'd', 'n', 'a', '_', 't', 'e', 'x', 't', ';',
+ 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd',
+ 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1',
+ '(', 'i', 'n', '_', 'd', 'n', 'a', '_', 't', 'e', 'x', 't', ',', 'o', 'u', 't', '_',
+ 'd', 'n', 'a', '_', 't', 'e', 'x', 't', ')', ';', '}', 'c', 'o', 'l', 'u', 'm', 'n',
+ ' ', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'R', 'E',
+ 'A', 'D', ' ', '=', ' ', 'o', 'u', 't', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', ';',
'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':',
- 'b', 'i', 'n', ' ', 'R', 'E', 'A', 'D', ' ', '=', ' ', 'o', 'u', 't', '_', '4', 'n',
- 'a', '_', 'b', 'i', 'n', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D',
- 'C', ':', '4', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'R', 'E', 'A', 'D',
- ' ', '=', ' ', 'o', 'u', 't', '_', '4', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd',
- ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n',
- 'a', ':', 'b', 'i', 'n', ' ', 'R', 'E', 'A', 'D', ' ', '=', ' ', 'o', 'u', 't', '_',
- 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I',
- 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'R', 'E', 'A', 'D',
- ' ', '=', ' ', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ';', 'c', 'o',
- 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a',
- 'c', 'k', 'e', 'd', ' ', 'R', 'E', 'A', 'D', ' ', '=', ' ', 'o', 'u', 't', '_', '2',
- 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', ';', 'd', 'e', 'f', 'a', 'u', 'l', 't',
- ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'l',
- 'o', 'r', ':', 't', 'e', 'x', 't', ' ', 'C', 'S', 'R', 'E', 'A', 'D', '{', 'r', 'e',
- 'a', 'd', '=', 'o', 'u', 't', '_', 'c', 'o', 'l', 'o', 'r', '_', 't', 'e', 'x', 't',
- ';', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '=', '<', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'l', 'o', 'r', ':', 't', 'e', 'x', 't', '>', 'c', 'o', 'm', 'p', 'a', 'r',
- 'e', '#', '1', '(', 'i', 'n', '_', 'c', 'o', 'l', 'o', 'r', '_', 't', 'e', 'x', 't',
- ',', 'o', 'u', 't', '_', 'c', 'o', 'l', 'o', 'r', '_', 't', 'e', 'x', 't', ')', ';',
- '}', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c',
- 's', ':', 'b', 'i', 'n', ' ', 'C', 'S', 'R', 'E', 'A', 'D', ' ', '=', ' ', 'o', 'u',
- 't', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', ';', 'c', 'o', 'l', 'u', 'm', 'n',
- ' ', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'b', 'i', 'n', ' ', 'C', 'S',
- 'R', 'E', 'A', 'D', ' ', '=', ' ', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'b', 'i',
- 'n', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c',
- 's', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'C', 'S', 'R', 'E', 'A', 'D', ' ', '=',
- ' ', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', ';', 'r',
- 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'b', 'o',
- 'o', 'l', ' ', 'C', 'S', '_', 'N', 'A', 'T', 'I', 'V', 'E', ' ', '=', ' ', 'c', 's',
- '_', 'n', 'a', 't', 'i', 'v', 'e', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N',
- 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'C', 'S', '_', 'K',
- 'E', 'Y', '{', 'r', 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 'c', 's', '_', 'k', 'e',
- 'y', ';', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '=', '<', 'I', 'N', 'S', 'D', 'C',
- ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'c', 'o', 'm', 'p', 'a', 'r', 'e',
- '#', '1', '(', 'i', 'n', '_', 'c', 's', '_', 'k', 'e', 'y', ',', 'o', 'u', 't', '_',
- 'c', 's', '_', 'k', 'e', 'y', ')', ';', '}', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U',
- '8', ' ', 'C', 'O', 'L', 'O', 'R', '_', 'M', 'A', 'T', 'R', 'I', 'X', ' ', '=', ' ',
- 'o', 'u', 't', '_', 'c', 'o', 'l', 'o', 'r', '_', 'm', 'a', 't', 'r', 'i', 'x', ';',
- 'd', 'e', 'f', 'a', 'u', 'l', 't', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N',
- 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd',
- ' ', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ' ', '=', ' ', 'o', 'u', 't', '_', 'q', 'u',
- 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I',
- 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 't', 'e', 'x', 't',
- ':', 'p', 'h', 'r', 'e', 'd', '_', '3', '3', ' ', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y',
- ' ', '=', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 't', 'e', 'x', 't', '_',
- 'p', 'h', 'r', 'e', 'd', '_', '3', '3', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'q',
+ 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'R', 'E', 'A', 'D', ' ', '=', ' ', 'o', 'u', 't',
+ '_', '4', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', ';', 'c', 'o', 'l', 'u', 'm',
+ 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ' ',
+ 'R', 'E', 'A', 'D', ' ', '=', ' ', 'o', 'u', 't', '_', 'x', '2', 'n', 'a', '_', 'b',
+ 'i', 'n', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', '2',
+ 'n', 'a', ':', 'b', 'i', 'n', ' ', 'R', 'E', 'A', 'D', ' ', '=', ' ', 'o', 'u', 't',
+ '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I',
+ 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'R',
+ 'E', 'A', 'D', ' ', '=', ' ', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c',
+ 'k', 'e', 'd', ';', 'd', 'e', 'f', 'a', 'u', 'l', 't', ' ', 'c', 'o', 'l', 'u', 'm',
+ 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'l', 'o', 'r', ':', 't', 'e', 'x',
+ 't', ' ', 'C', 'S', 'R', 'E', 'A', 'D', '{', 'r', 'e', 'a', 'd', '=', 'o', 'u', 't',
+ '_', 'c', 'o', 'l', 'o', 'r', '_', 't', 'e', 'x', 't', ';', 'v', 'a', 'l', 'i', 'd',
+ 'a', 't', 'e', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'l', 'o', 'r', ':',
+ 't', 'e', 'x', 't', '>', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1', '(', 'i', 'n',
+ '_', 'c', 'o', 'l', 'o', 'r', '_', 't', 'e', 'x', 't', ',', 'o', 'u', 't', '_', 'c',
+ 'o', 'l', 'o', 'r', '_', 't', 'e', 'x', 't', ')', ';', '}', 'c', 'o', 'l', 'u', 'm',
+ 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ' ',
+ 'C', 'S', 'R', 'E', 'A', 'D', ' ', '=', ' ', 'o', 'u', 't', '_', 'x', '2', 'c', 's',
+ '_', 'b', 'i', 'n', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C',
+ ':', '2', 'c', 's', ':', 'b', 'i', 'n', ' ', 'C', 'S', 'R', 'E', 'A', 'D', ' ', '=',
+ ' ', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'b', 'i', 'n', ';', 'c', 'o', 'l', 'u',
+ 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'p', 'a', 'c', 'k',
+ 'e', 'd', ' ', 'C', 'S', 'R', 'E', 'A', 'D', ' ', '=', ' ', 'o', 'u', 't', '_', '2',
+ 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l',
+ 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'b', 'o', 'o', 'l', ' ', 'C', 'S', '_',
+ 'N', 'A', 'T', 'I', 'V', 'E', ' ', '=', ' ', 'c', 's', '_', 'n', 'a', 't', 'i', 'v',
+ 'e', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n',
+ 'a', ':', 't', 'e', 'x', 't', ' ', 'C', 'S', '_', 'K', 'E', 'Y', '{', 'r', 'e', 'a',
+ 'd', '=', 'o', 'u', 't', '_', 'c', 's', '_', 'k', 'e', 'y', ';', 'v', 'a', 'l', 'i',
+ 'd', 'a', 't', 'e', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't',
+ 'e', 'x', 't', '>', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1', '(', 'i', 'n', '_',
+ 'c', 's', '_', 'k', 'e', 'y', ',', 'o', 'u', 't', '_', 'c', 's', '_', 'k', 'e', 'y',
+ ')', ';', '}', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '8', ' ', 'C', 'O', 'L', 'O',
+ 'R', '_', 'M', 'A', 'T', 'R', 'I', 'X', ' ', '=', ' ', 'o', 'u', 't', '_', 'c', 'o',
+ 'l', 'o', 'r', '_', 'm', 'a', 't', 'r', 'i', 'x', ';', 'd', 'e', 'f', 'a', 'u', 'l',
+ 't', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u',
+ 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'Q', 'U', 'A', 'L', 'I',
+ 'T', 'Y', ' ', '=', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r',
+ 'e', 'd', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'q',
'u', 'a', 'l', 'i', 't', 'y', ':', 't', 'e', 'x', 't', ':', 'p', 'h', 'r', 'e', 'd',
- '_', '3', '3', ')', '<', 'B', '8', '>', 's', 'u', 'm', '#', '1', '<', '3', '3', '>',
- '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', ')', ';',
- 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l',
- 'i', 't', 'y', ':', 't', 'e', 'x', 't', ':', 'p', 'h', 'r', 'e', 'd', '_', '6', '4',
- ' ', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ' ', '=', ' ', 'o', 'u', 't', '_', 'q', 'u',
- 'a', 'l', '_', 't', 'e', 'x', 't', '_', 'p', 'h', 'r', 'e', 'd', '_', '6', '4', '|',
- '(', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 't', 'e',
- 'x', 't', ':', 'p', 'h', 'r', 'e', 'd', '_', '6', '4', ')', '<', 'B', '8', '>', 's',
- 'u', 'm', '#', '1', '<', '6', '4', '>', '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l',
- '_', 'p', 'h', 'r', 'e', 'd', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
- 'r', 'd', ':', 'l', 'e', 'n', ' ', 's', 'i', 'g', 'n', 'a', 'l', '_', 'l', 'e', 'n',
- '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n',
- ')', 'r', 'o', 'w', '_', 'l', 'e', 'n', '#', '1', '(', 'o', 'u', 't', '_', 's', 'i',
- 'g', 'n', 'a', 'l', ')', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
- 'd', ':', 'l', 'e', 'n', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '0', '>', '(', ')',
- ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l',
- ':', 'p', 'r', 'o', 't', 'e', 'i', 'n', '#', '1', '{', 'd', 'e', 'f', 'a', 'u', 'l',
- 't', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'r',
- 'o', 't', 'e', 'i', 'n', ':', 't', 'e', 'x', 't', ' ', 'P', 'R', 'O', 'T', 'E', 'I',
- 'N', '{', 'r', 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 'p', 'r', 'o', 't', 'e', 'i',
- 'n', '_', 't', 'e', 'x', 't', ';', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '=', '<',
- 'I', 'N', 'S', 'D', 'C', ':', 'p', 'r', 'o', 't', 'e', 'i', 'n', ':', 't', 'e', 'x',
- 't', '>', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1', '(', 'i', 'n', '_', 'p', 'r',
- 'o', 't', 'e', 'i', 'n', '_', 't', 'e', 'x', 't', ',', 'o', 'u', 't', '_', 'p', 'r',
- 'o', 't', 'e', 'i', 'n', '_', 't', 'e', 'x', 't', ')', ';', '}', 'c', 'o', 'l', 'u',
- 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'a', 'a', ':', 'b', 'i', 'n', ' ', 'P',
- 'R', 'O', 'T', 'E', 'I', 'N', ' ', '=', ' ', 'o', 'u', 't', '_', 'a', 'a', '_', 'b',
- 'i', 'n', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S',
- 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'c', 'o', 'o', 'r', 'd', '#',
- '1', '{', 'd', 'e', 'f', 'a', 'u', 'l', 't', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'X',
- ' ', '=', ' ', 'o', 'u', 't', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', ';', 'd', 'e',
- 'f', 'a', 'u', 'l', 't', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D',
- 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'Y', ' ', '=', ' ', 'o',
- 'u', 't', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', ';', 'r', 'e', 'a', 'd', 'o', 'n',
- 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '1', '6', ' ', 'X', ' ', '=',
- ' ', 'c', 'a', 's', 't', '#', '1', '(', 'x', '_', 'c', 'l', 'i', 'p', '_', 'U', '1',
- '6', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm',
- 'n', ' ', 'U', '1', '6', ' ', 'Y', ' ', '=', ' ', 'c', 'a', 's', 't', '#', '1', '(',
- 'y', '_', 'c', 'l', 'i', 'p', '_', 'U', '1', '6', ')', ';', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'x', '_', 'c', 'l', 'i', 'p',
- '_', 'U', '1', '6', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
- ':', 'v', 'a', 'l', '>', 'c', 'l', 'i', 'p', '#', '1', '<', '0', ',', '6', '5', '5',
- '3', '5', '>', '(', 'o', 'u', 't', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', ')', ';',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'y',
- '_', 'c', 'l', 'i', 'p', '_', 'U', '1', '6', '=', '<', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', '>', 'c', 'l', 'i', 'p', '#', '1', '<',
- '0', ',', '6', '5', '5', '3', '5', '>', '(', 'o', 'u', 't', '_', 'y', '_', 'c', 'o',
- 'o', 'r', 'd', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'I', 'N', 'S', 'D', 'C',
- ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'n', 'a', 'm', 'e',
- '#', '1', '.', '0', '.', '1', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':',
- 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'c', 'o', 'o', 'r', 'd', '#', '1', '{', 'c',
- 'o', 'l', 'u', 'm', 'n', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'N', 'A', 'M', 'E', ' ',
- '=', ' ', '_', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', ';', 'r', 'e', 'a', 'd', 'o',
- 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':',
- 'S', 'R', 'A', ':', 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n',
- 'd', ' ', 'S', 'P', 'O', 'T', '_', 'I', 'D', 'S', '_', 'F', 'O', 'U', 'N', 'D', ' ',
- '=', ' ', 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', ';',
- 'a', 's', 'c', 'i', 'i', ' ', '_', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', '=', 'I',
- 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'f', 'o', 'r', 'm', 'a', 't', '_', 's',
- 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', 'o', 'u', 't', '_', 'n', 'a',
- 'm', 'e', '_', 'f', 'm', 't', ',', 'o', 'u', 't', '_', 'x', '_', 'c', 'o', 'o', 'r',
- 'd', ',', 'o', 'u', 't', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', ',', 'o', 'u', 't',
- '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', ')', '|', 'I', 'N', 'S', 'D', 'C',
- ':', 'S', 'R', 'A', ':', 'f', 'o', 'r', 'm', 'a', 't', '_', 's', 'p', 'o', 't', '_',
- 'n', 'a', 'm', 'e', '#', '1', '(', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', '_', 'f',
- 'm', 't', ',', 'o', 'u', 't', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', ',', 'o', 'u',
- 't', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', ')', '|', 'I', 'N', 'S', 'D', 'C', ':',
- 'S', 'R', 'A', ':', 'f', 'o', 'r', 'm', 'a', 't', '_', 's', 'p', 'o', 't', '_', 'n',
- 'a', 'm', 'e', '_', 'n', 'o', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '(', 'o', 'u',
- 't', '_', 'n', 'a', 'm', 'e', '_', 'f', 'm', 't', ')', '|', 'o', 'u', 't', '_', 's',
- 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'I',
- 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't',
- 'd', 'e', 's', 'c', '#', '1', '.', '0', '.', '2', '=', 'I', 'N', 'S', 'D', 'C', ':',
- 't', 'b', 'l', ':', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0', '.',
- '1', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '8', ' ', 'N', 'R', 'E', 'A', 'D',
- 'S', ' ', '=', ' ', 'o', 'u', 't', '_', 'n', 'r', 'e', 'a', 'd', 's', ';', 'r', 'e',
- 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S',
- 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'S', 'P', 'O', 'T',
- '_', 'L', 'E', 'N', ' ', '=', ' ', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ';', 'r',
- 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'F', 'I', 'X',
- 'E', 'D', '_', 'S', 'P', 'O', 'T', '_', 'L', 'E', 'N', ' ', '=', ' ', 'f', 'i', 'x',
- 'e', 'd', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ';', 'r', 'e', 'a', 'd', 'o',
- 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'T', 'R', 'I', 'M', '_', 'S',
- 'T', 'A', 'R', 'T', ' ', '=', ' ', 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't',
- '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r',
- 'o', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '0', '>', '(', ')', ';', 'r', 'e', 'a',
- 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D',
- 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'T', 'R', 'I', 'M', '_',
- 'S', 'T', 'A', 'R', 'T', ' ', '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'o', 'n', 'e', ')', '<', 'I', '3', '2', '>', 's', 'u', 'm', '#',
- '1', '<', '1', '>', '(', 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't', ')', '|',
- '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>',
- 'e', 'c', 'h', 'o', '#', '1', '<', '1', '>', '(', ')', ';', 'r', 'e', 'a', 'd', 'o',
- 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'T', 'R', 'I', 'M', '_', 'L', 'E',
- 'N', ' ', '=', ' ', 't', 'r', 'i', 'm', '_', 'l', 'e', 'n', '|', 's', 'p', 'o', 't',
- '_', 'l', 'e', 'n', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'a', 's', 'c', 'i', 'i',
- ' ', 'L', 'A', 'B', 'E', 'L', ' ', '=', ' ', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e',
- 'l', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'L', 'A', 'B', 'E', 'L', '_', 'S', 'T',
- 'A', 'R', 'T', ' ', '=', ' ', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's',
- 't', 'a', 'r', 't', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'L', 'A', 'B', 'E', 'L', '_',
- 'L', 'E', 'N', ' ', '=', ' ', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 'l',
- 'e', 'n', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm',
- 'n', ' ', 'U', '1', '6', ' ', 'L', 'A', 'B', 'E', 'L', '_', 'S', 'T', 'A', 'R', 'T',
- ' ', '=', ' ', 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u', 't', '_', 'l', 'a', 'b',
- 'e', 'l', '_', 's', 't', 'a', 'r', 't', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l',
- 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '1', '6', ' ', 'L', 'A', 'B', 'E',
- 'L', '_', 'L', 'E', 'N', ' ', '=', ' ', 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u',
- 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 'l', 'e', 'n', ')', ';', 'd', 'e', 'f', 'a',
+ '_', '3', '3', ' ', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ' ', '=', ' ', 'o', 'u', 't',
+ '_', 'q', 'u', 'a', 'l', '_', 't', 'e', 'x', 't', '_', 'p', 'h', 'r', 'e', 'd', '_',
+ '3', '3', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y',
+ ':', 't', 'e', 'x', 't', ':', 'p', 'h', 'r', 'e', 'd', '_', '3', '3', ')', '<', 'B',
+ '8', '>', 's', 'u', 'm', '#', '1', '<', '3', '3', '>', '(', 'o', 'u', 't', '_', 'q',
+ 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', ')', ';', 'c', 'o', 'l', 'u', 'm', 'n',
+ ' ', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 't', 'e',
+ 'x', 't', ':', 'p', 'h', 'r', 'e', 'd', '_', '6', '4', ' ', 'Q', 'U', 'A', 'L', 'I',
+ 'T', 'Y', ' ', '=', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 't', 'e', 'x',
+ 't', '_', 'p', 'h', 'r', 'e', 'd', '_', '6', '4', '|', '(', 'I', 'N', 'S', 'D', 'C',
+ ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 't', 'e', 'x', 't', ':', 'p', 'h', 'r',
+ 'e', 'd', '_', '6', '4', ')', '<', 'B', '8', '>', 's', 'u', 'm', '#', '1', '<', '6',
+ '4', '>', '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd',
+ ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n',
+ ' ', 's', 'i', 'g', 'n', 'a', 'l', '_', 'l', 'e', 'n', '=', '(', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ')', 'r', 'o', 'w', '_', 'l',
+ 'e', 'n', '#', '1', '(', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', ')', '|',
+ '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', '>',
+ 'e', 'c', 'h', 'o', '#', '1', '<', '0', '>', '(', ')', ';', '}', 't', 'a', 'b', 'l',
+ 'e', ' ', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l', ':', 'p', 'r', 'o', 't', 'e',
+ 'i', 'n', '#', '1', '{', 'd', 'e', 'f', 'a', 'u', 'l', 't', ' ', 'c', 'o', 'l', 'u',
+ 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'r', 'o', 't', 'e', 'i', 'n', ':',
+ 't', 'e', 'x', 't', ' ', 'P', 'R', 'O', 'T', 'E', 'I', 'N', '{', 'r', 'e', 'a', 'd',
+ '=', 'o', 'u', 't', '_', 'p', 'r', 'o', 't', 'e', 'i', 'n', '_', 't', 'e', 'x', 't',
+ ';', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '=', '<', 'I', 'N', 'S', 'D', 'C', ':',
+ 'p', 'r', 'o', 't', 'e', 'i', 'n', ':', 't', 'e', 'x', 't', '>', 'c', 'o', 'm', 'p',
+ 'a', 'r', 'e', '#', '1', '(', 'i', 'n', '_', 'p', 'r', 'o', 't', 'e', 'i', 'n', '_',
+ 't', 'e', 'x', 't', ',', 'o', 'u', 't', '_', 'p', 'r', 'o', 't', 'e', 'i', 'n', '_',
+ 't', 'e', 'x', 't', ')', ';', '}', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S',
+ 'D', 'C', ':', 'a', 'a', ':', 'b', 'i', 'n', ' ', 'P', 'R', 'O', 'T', 'E', 'I', 'N',
+ ' ', '=', ' ', 'o', 'u', 't', '_', 'a', 'a', '_', 'b', 'i', 'n', ';', '}', 't', 'a',
+ 'b', 'l', 'e', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l',
+ ':', 's', 'p', 'o', 't', 'c', 'o', 'o', 'r', 'd', '#', '1', '{', 'd', 'e', 'f', 'a',
'u', 'l', 't', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':',
- 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'R', 'E',
- 'A', 'D', '_', 'T', 'Y', 'P', 'E', ' ', '=', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a',
- 'd', '_', 't', 'y', 'p', 'e', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c',
- 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r',
+ 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'X', ' ', '=', ' ', 'o', 'u', 't',
+ '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', ';', 'd', 'e', 'f', 'a', 'u', 'l', 't', ' ',
+ 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'v', 'a', 'l', ' ', 'Y', ' ', '=', ' ', 'o', 'u', 't', '_', 'y', '_', 'c',
+ 'o', 'o', 'r', 'd', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l',
+ 'u', 'm', 'n', ' ', 'U', '1', '6', ' ', 'X', ' ', '=', ' ', 'c', 'a', 's', 't', '#',
+ '1', '(', 'x', '_', 'c', 'l', 'i', 'p', '_', 'U', '1', '6', ')', ';', 'r', 'e', 'a',
+ 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '1', '6', ' ',
+ 'Y', ' ', '=', ' ', 'c', 'a', 's', 't', '#', '1', '(', 'y', '_', 'c', 'l', 'i', 'p',
+ '_', 'U', '1', '6', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'v', 'a', 'l', ' ', 'x', '_', 'c', 'l', 'i', 'p', '_', 'U', '1', '6', '=', '<',
+ 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', '>', 'c',
+ 'l', 'i', 'p', '#', '1', '<', '0', ',', '6', '5', '5', '3', '5', '>', '(', 'o', 'u',
+ 't', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', ')', ';', 'I', 'N', 'S', 'D', 'C', ':',
+ 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'y', '_', 'c', 'l', 'i', 'p', '_',
+ 'U', '1', '6', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
+ 'v', 'a', 'l', '>', 'c', 'l', 'i', 'p', '#', '1', '<', '0', ',', '6', '5', '5', '3',
+ '5', '>', '(', 'o', 'u', 't', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', ')', ';', '}',
+ 't', 'a', 'b', 'l', 'e', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't',
+ 'b', 'l', ':', 's', 'p', 'o', 't', 'n', 'a', 'm', 'e', '#', '1', '.', '0', '.', '1',
+ '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p',
+ 'o', 't', 'c', 'o', 'o', 'r', 'd', '#', '1', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
+ 'a', 's', 'c', 'i', 'i', ' ', 'N', 'A', 'M', 'E', ' ', '=', ' ', '_', 'o', 'u', 't',
+ '_', 'n', 'a', 'm', 'e', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p',
+ 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', ' ', 'S', 'P', 'O', 'T',
+ '_', 'I', 'D', 'S', '_', 'F', 'O', 'U', 'N', 'D', ' ', '=', ' ', 's', 'p', 'o', 't',
+ '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', ';', 'a', 's', 'c', 'i', 'i', ' ',
+ '_', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S',
+ 'R', 'A', ':', 'f', 'o', 'r', 'm', 'a', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a',
+ 'm', 'e', '#', '1', '(', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', '_', 'f', 'm', 't',
+ ',', 'o', 'u', 't', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', ',', 'o', 'u', 't', '_',
+ 'y', '_', 'c', 'o', 'o', 'r', 'd', ',', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_',
+ 'n', 'a', 'm', 'e', ')', '|', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'f',
+ 'o', 'r', 'm', 'a', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1',
+ '(', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', '_', 'f', 'm', 't', ',', 'o', 'u', 't',
+ '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', ',', 'o', 'u', 't', '_', 'y', '_', 'c', 'o',
+ 'o', 'r', 'd', ')', '|', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'f', 'o',
+ 'r', 'm', 'a', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 'n', 'o',
+ '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '(', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e',
+ '_', 'f', 'm', 't', ')', '|', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a',
+ 'm', 'e', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S',
+ 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '#', '1',
+ '.', '0', '.', '2', '=', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l', ':', 's', 'e',
+ 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0', '.', '1', '{', 'c', 'o', 'l', 'u',
+ 'm', 'n', ' ', 'U', '8', ' ', 'N', 'R', 'E', 'A', 'D', 'S', ' ', '=', ' ', 'o', 'u',
+ 't', '_', 'n', 'r', 'e', 'a', 'd', 's', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y',
+ ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
+ 'r', 'd', ':', 'l', 'e', 'n', ' ', 'S', 'P', 'O', 'T', '_', 'L', 'E', 'N', ' ', '=',
+ ' ', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l',
+ 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
+ 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'F', 'I', 'X', 'E', 'D', '_', 'S', 'P', 'O',
+ 'T', '_', 'L', 'E', 'N', ' ', '=', ' ', 'f', 'i', 'x', 'e', 'd', '_', 's', 'p', 'o',
+ 't', '_', 'l', 'e', 'n', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
+ 'z', 'e', 'r', 'o', ' ', 'T', 'R', 'I', 'M', '_', 'S', 'T', 'A', 'R', 'T', ' ', '=',
+ ' ', 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't', '|', '<', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', '>', 'e', 'c', 'h', 'o',
+ '#', '1', '<', '0', '>', '(', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ',
+ 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'o', 'n', 'e', ' ', 'T', 'R', 'I', 'M', '_', 'S', 'T', 'A', 'R', 'T', ' ',
+ '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n',
+ 'e', ')', '<', 'I', '3', '2', '>', 's', 'u', 'm', '#', '1', '<', '1', '>', '(', 't',
+ 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't', ')', '|', '<', 'I', 'N', 'S', 'D', 'C',
+ ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'e', 'c', 'h', 'o', '#', '1',
+ '<', '1', '>', '(', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
+ 'l', 'e', 'n', ' ', 'T', 'R', 'I', 'M', '_', 'L', 'E', 'N', ' ', '=', ' ', 't', 'r',
+ 'i', 'm', '_', 'l', 'e', 'n', '|', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ';', 'c',
+ 'o', 'l', 'u', 'm', 'n', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'L', 'A', 'B', 'E', 'L',
+ ' ', '=', ' ', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', ';', 'c', 'o', 'l', 'u',
+ 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e',
+ 'r', 'o', ' ', 'L', 'A', 'B', 'E', 'L', '_', 'S', 'T', 'A', 'R', 'T', ' ', '=', ' ',
+ 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 't', 'a', 'r', 't', ';', 'c',
+ 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'l', 'e', 'n', ' ', 'L', 'A', 'B', 'E', 'L', '_', 'L', 'E', 'N', ' ', '=', ' ',
+ 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 'l', 'e', 'n', ';', 'r', 'e', 'a',
+ 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '1', '6', ' ',
+ 'L', 'A', 'B', 'E', 'L', '_', 'S', 'T', 'A', 'R', 'T', ' ', '=', ' ', 'c', 'a', 's',
+ 't', '#', '1', '(', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 't', 'a',
+ 'r', 't', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u',
+ 'm', 'n', ' ', 'U', '1', '6', ' ', 'L', 'A', 'B', 'E', 'L', '_', 'L', 'E', 'N', ' ',
+ '=', ' ', 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e',
+ 'l', '_', 'l', 'e', 'n', ')', ';', 'd', 'e', 'f', 'a', 'u', 'l', 't', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x', 'r',
'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'R', 'E', 'A', 'D', '_', 'T', 'Y', 'P',
'E', ' ', '=', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e',
- '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd',
- '_', 't', 'y', 'p', 'e', ',', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r',
- 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0',
- ',', '1', ',', '2', ',', '3', ',', '4', ',', '5', ',', '6', ',', '7', ']', ',', '[',
- '0', ',', '1', ',', '0', ',', '1', ',', '0', ',', '1', ',', '0', ',', '1', ']', '>',
- '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ')', ';', 'd',
- 'e', 'f', 'a', 'u', 'l', 't', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S',
- 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'R', 'E', 'A',
- 'D', '_', 'S', 'T', 'A', 'R', 'T', ' ', '=', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a',
- 'd', '_', 's', 't', 'a', 'r', 't', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'R', 'E', 'A',
- 'D', '_', 'S', 'T', 'A', 'R', 'T', ' ', '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ')', '<', 'I', '3', '2', '>', 's', 'u',
- 'm', '#', '1', '<', '1', '>', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's',
- 't', 'a', 'r', 't', ')', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D',
- 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'R', 'E', 'A', 'D', '_',
- 'L', 'E', 'N', ' ', '=', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e',
- 'n', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n',
- ' ', 'U', '1', '6', ' ', 'R', 'E', 'A', 'D', '_', 'S', 'T', 'A', 'R', 'T', ' ', '=',
- ' ', 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_',
- 's', 't', 'a', 'r', 't', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c',
- 'o', 'l', 'u', 'm', 'n', ' ', 'U', '1', '6', ' ', 'R', 'E', 'A', 'D', '_', 'L', 'E',
- 'N', ' ', '=', ' ', 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u', 't', '_', 'r', 'e',
- 'a', 'd', '_', 'l', 'e', 'n', ')', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N',
- 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't',
- 'e', 'r', ' ', 'R', 'E', 'A', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', ' ', '=', ' ',
- 'o', 'u', 't', '_', 'r', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', '|', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't',
- 'e', 'r', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '0', '>', '(', 'o', 'u', 't', '_',
- 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', ')', ';', 'r', 'e', 'a', 'd', 'o',
- 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':',
- 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', ' ', 'R',
+ ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
+ 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 't', 'y',
+ 'p', 'e', ' ', 'R', 'E', 'A', 'D', '_', 'T', 'Y', 'P', 'E', ' ', '=', ' ', 'o', 'u',
+ 't', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '|', '<', 'I', 'N', 'S', 'D',
+ 'C', ':', 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ',',
+ 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 't', 'y',
+ 'p', 'e', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',', '3',
+ ',', '4', ',', '5', ',', '6', ',', '7', ']', ',', '[', '0', ',', '1', ',', '0', ',',
+ '1', ',', '0', ',', '1', ',', '0', ',', '1', ']', '>', '(', 'o', 'u', 't', '_', 'r',
+ 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ')', ';', 'd', 'e', 'f', 'a', 'u', 'l', 't',
+ ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
+ 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'R', 'E', 'A', 'D', '_', 'S', 'T', 'A', 'R',
+ 'T', ' ', '=', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r',
+ 't', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
+ 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'R', 'E', 'A', 'D', '_', 'S', 'T', 'A', 'R',
+ 'T', ' ', '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
+ 'o', 'n', 'e', ')', '<', 'I', '3', '2', '>', 's', 'u', 'm', '#', '1', '<', '1', '>',
+ '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', ')', ';',
+ 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'l', 'e', 'n', ' ', 'R', 'E', 'A', 'D', '_', 'L', 'E', 'N', ' ', '=', ' ',
+ 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ';', 'r', 'e', 'a', 'd',
+ 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '1', '6', ' ', 'R',
+ 'E', 'A', 'D', '_', 'S', 'T', 'A', 'R', 'T', ' ', '=', ' ', 'c', 'a', 's', 't', '#',
+ '1', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', ')',
+ ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
+ 'U', '1', '6', ' ', 'R', 'E', 'A', 'D', '_', 'L', 'E', 'N', ' ', '=', ' ', 'c', 'a',
+ 's', 't', '#', '1', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n',
+ ')', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R',
+ 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', ' ', 'R', 'E', 'A',
'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', ' ', '=', ' ', 'o', 'u', 't', '_', 'r', 'd',
- '_', 'f', 'i', 'l', 't', 'e', 'r', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A',
- ':', 'x', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'i', 'n', '_', 'r', 'e',
- 'a', 'd', '_', 't', 'y', 'p', 'e', '=', 'R', 'E', 'A', 'D', '_', 'T', 'Y', 'P', 'E',
- '|', '_', 'a', 'l', 't', '_', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p',
- 'e', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n',
- ' ', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', '=', 'R', 'E', 'A', 'D',
- '_', 'L', 'E', 'N', '|', '_', 'a', 'l', 't', '_', 'i', 'n', '_', 'r', 'e', 'a', 'd',
- '_', 'l', 'e', 'n', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
- 'l', 'e', 'n', ' ', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '=', 'b', 'a', 's', 'e',
- '_', 's', 'p', 'a', 'c', 'e', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '|', 'c',
- 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e', '_', 's', 'p', 'o', 't', '_', 'l',
- 'e', 'n', '|', 'a', 'l', 'i', 'g', 'n', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n',
- ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ',
- 'f', 'i', 'x', 'e', 'd', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '=', 's', 't',
- 'a', 't', 'i', 'c', '_', 'f', 'i', 'x', 'e', 'd', '_', 's', 'p', 'o', 't', '_', 'l',
- 'e', 'n', '|', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '_', 'f', 'i', 'x',
- 'e', 'd', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '|', 'c', 'o', 'l', 'o', 'r',
- '_', 's', 'p', 'a', 'c', 'e', '_', 'f', 'i', 'x', 'e', 'd', '_', 's', 'p', 'o', 't',
- '_', 'l', 'e', 'n', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'I', 'N', 'S', 'D', 'C',
- ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 't', 'a', 't', 's', '#', '1', '.',
- '1', '{', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n',
- ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', 'i', 'd',
- '_', 't', ' ', 'M', 'I', 'N', '_', 'S', 'P', 'O', 'T', '_', 'I', 'D', ' ', '=', ' ',
- 'm', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'i', 'd', '|', '<', 'I', 'N', 'S', 'D',
- 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', 'i', 'd', '_', 't', '>', 'e', 'c',
- 'h', 'o', '#', '1', '<', '1', '>', '(', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l',
- 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R',
- 'A', ':', 's', 'p', 'o', 't', 'i', 'd', '_', 't', ' ', 'M', 'A', 'X', '_', 'S', 'P',
- 'O', 'T', '_', 'I', 'D', ' ', '=', ' ', 'm', 'a', 'x', '_', 's', 'p', 'o', 't', '_',
- 'i', 'd', '|', 'c', 'a', 's', 't', '#', '1', '(', 's', 'p', 'o', 't', '_', 'c', 'o',
- 'u', 'n', 't', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l',
- 'u', 'm', 'n', ' ', 'U', '6', '4', ' ', 'S', 'P', 'O', 'T', '_', 'C', 'O', 'U', 'N',
- 'T', ' ', '=', ' ', 's', 'p', 'o', 't', '_', 'c', 'o', 'u', 'n', 't', ';', 'r', 'e',
- 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '6', '4',
- ' ', 'B', 'A', 'S', 'E', '_', 'C', 'O', 'U', 'N', 'T', ' ', '=', ' ', 'b', 'a', 's',
- 'e', '_', 'c', 'o', 'u', 'n', 't', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ',
- 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '6', '4', ' ', 'B', 'I', 'O', '_', 'B', 'A',
- 'S', 'E', '_', 'C', 'O', 'U', 'N', 'T', ' ', '=', ' ', 'b', 'i', 'o', '_', 'b', 'a',
- 's', 'e', '_', 'c', 'o', 'u', 'n', 't', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y',
- ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '6', '4', ' ', 'C', 'M', 'P', '_', 'B',
- 'A', 'S', 'E', '_', 'C', 'O', 'U', 'N', 'T', ' ', '=', ' ', 'c', 'm', 'p', '_', 'b',
- 'a', 's', 'e', '_', 'c', 'o', 'u', 'n', 't', '|', 'b', 'a', 's', 'e', '_', 'c', 'o',
- 'u', 'n', 't', ';', 'U', '8', ' ', 's', 't', 'a', 't', 's', '_', 'd', 'u', 'm', 'm',
- 'y', '=', 'i', 'n', '_', 's', 't', 'a', 't', 's', '_', 'b', 'i', 'n', ';', '}', 't',
- 'a', 'b', 'l', 'e', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b',
- 'l', ':', 's', 'r', 'a', '#', '1', '.', '0', '.', '3', '=', 'I', 'N', 'S', 'D', 'C',
- ':', 't', 'b', 'l', ':', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0',
- '.', '1', ',', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':',
- 's', 'p', 'o', 't', 'n', 'a', 'm', 'e', '#', '1', '.', '0', '.', '1', ',', 'I', 'N',
+ '_', 'f', 'i', 'l', 't', 'e', 'r', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R',
+ 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', '>', 'e', 'c', 'h',
+ 'o', '#', '1', '<', '0', '>', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's',
+ 't', 'a', 'r', 't', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e',
+ 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', ' ', 'R', 'D', '_', 'F', 'I', 'L', 'T',
+ 'E', 'R', ' ', '=', ' ', 'o', 'u', 't', '_', 'r', 'd', '_', 'f', 'i', 'l', 't', 'e',
+ 'r', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd',
+ '_', 't', 'y', 'p', 'e', ' ', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p',
+ 'e', '=', 'R', 'E', 'A', 'D', '_', 'T', 'Y', 'P', 'E', '|', '_', 'a', 'l', 't', '_',
+ 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ';', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'i', 'n', '_', 'r', 'e',
+ 'a', 'd', '_', 'l', 'e', 'n', '=', 'R', 'E', 'A', 'D', '_', 'L', 'E', 'N', '|', '_',
+ 'a', 'l', 't', '_', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ';', 'I',
+ 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 's', 'p',
+ 'o', 't', '_', 'l', 'e', 'n', '=', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e',
+ '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '|', 'c', 'o', 'l', 'o', 'r', '_', 's',
+ 'p', 'a', 'c', 'e', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '|', 'a', 'l', 'i',
+ 'g', 'n', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'f', 'i', 'x', 'e', 'd', '_',
+ 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '=', 's', 't', 'a', 't', 'i', 'c', '_', 'f',
+ 'i', 'x', 'e', 'd', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '|', 'b', 'a', 's',
+ 'e', '_', 's', 'p', 'a', 'c', 'e', '_', 'f', 'i', 'x', 'e', 'd', '_', 's', 'p', 'o',
+ 't', '_', 'l', 'e', 'n', '|', 'c', 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e',
+ '_', 'f', 'i', 'x', 'e', 'd', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ';', '}',
+ 't', 'a', 'b', 'l', 'e', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't',
+ 'b', 'l', ':', 's', 't', 'a', 't', 's', '#', '1', '.', '1', '{', 'r', 'e', 'a', 'd',
+ 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C',
+ ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', 'i', 'd', '_', 't', ' ', 'M', 'I', 'N',
+ '_', 'S', 'P', 'O', 'T', '_', 'I', 'D', ' ', '=', ' ', 'm', 'i', 'n', '_', 's', 'p',
+ 'o', 't', '_', 'i', 'd', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':',
+ 's', 'p', 'o', 't', 'i', 'd', '_', 't', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '1',
+ '>', '(', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u',
+ 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't',
+ 'i', 'd', '_', 't', ' ', 'M', 'A', 'X', '_', 'S', 'P', 'O', 'T', '_', 'I', 'D', ' ',
+ '=', ' ', 'm', 'a', 'x', '_', 's', 'p', 'o', 't', '_', 'i', 'd', '|', 'c', 'a', 's',
+ 't', '#', '1', '(', 's', 'p', 'o', 't', '_', 'c', 'o', 'u', 'n', 't', ')', ';', 'r',
+ 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '6',
+ '4', ' ', 'S', 'P', 'O', 'T', '_', 'C', 'O', 'U', 'N', 'T', ' ', '=', ' ', 's', 'p',
+ 'o', 't', '_', 'c', 'o', 'u', 'n', 't', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y',
+ ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '6', '4', ' ', 'B', 'A', 'S', 'E', '_',
+ 'C', 'O', 'U', 'N', 'T', ' ', '=', ' ', 'b', 'a', 's', 'e', '_', 'c', 'o', 'u', 'n',
+ 't', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n',
+ ' ', 'U', '6', '4', ' ', 'B', 'I', 'O', '_', 'B', 'A', 'S', 'E', '_', 'C', 'O', 'U',
+ 'N', 'T', ' ', '=', ' ', 'b', 'i', 'o', '_', 'b', 'a', 's', 'e', '_', 'c', 'o', 'u',
+ 'n', 't', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm',
+ 'n', ' ', 'U', '6', '4', ' ', 'C', 'M', 'P', '_', 'B', 'A', 'S', 'E', '_', 'C', 'O',
+ 'U', 'N', 'T', ' ', '=', ' ', 'c', 'm', 'p', '_', 'b', 'a', 's', 'e', '_', 'c', 'o',
+ 'u', 'n', 't', '|', 'b', 'a', 's', 'e', '_', 'c', 'o', 'u', 'n', 't', ';', 'U', '8',
+ ' ', 's', 't', 'a', 't', 's', '_', 'd', 'u', 'm', 'm', 'y', '=', 'i', 'n', '_', 's',
+ 't', 'a', 't', 's', '_', 'b', 'i', 'n', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'I',
+ 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#',
+ '1', '.', '0', '.', '3', '=', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l', ':', 's',
+ 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0', '.', '1', ',', 'I', 'N', 'S',
+ 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'n', 'a',
+ 'm', 'e', '#', '1', '.', '0', '.', '1', ',', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R',
+ 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '#', '1', '.',
+ '0', '.', '2', ',', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l',
+ ':', 's', 't', 'a', 't', 's', '#', '1', '.', '1', '{', 'c', 'o', 'l', 'u', 'm', 'n',
+ ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o',
+ 'r', 'm', '_', 'i', 'd', ' ', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', ' ', '=', ' ',
+ '.', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '|', 'o', 'u', 't', '_', 'p', 'l', 'a',
+ 't', 'f', 'o', 'r', 'm', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'P', 'L', 'A', 'T', 'F', 'O',
+ 'R', 'M', ' ', '=', ' ', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'n', 'a', 'm',
+ 'e', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R',
+ 'A', ':', 's', 'p', 'o', 't', 'i', 'd', '_', 't', ' ', 'S', 'P', 'O', 'T', '_', 'I',
+ 'D', ' ', '=', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p',
+ 'o', 't', 'i', 'd', '_', 't', '>', 'a', 'd', 'd', '_', 'r', 'o', 'w', '_', 'i', 'd',
+ '#', '1', '(', '.', 'S', 'P', 'O', 'T', '_', 'I', 'D', ')', '|', 'c', 'a', 's', 't',
+ '#', '1', '(', 'r', 'o', 'w', 'i', 'd', '_', '6', '4', ')', ';', 'c', 'o', 'l', 'u',
+ 'm', 'n', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'S', 'P', 'O', 'T', '_', 'G', 'R', 'O',
+ 'U', 'P', ' ', '=', ' ', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'g', 'r', 'o',
+ 'u', 'p', '|', '.', 'S', 'P', 'O', 'T', '_', 'G', 'R', 'O', 'U', 'P', '|', '<', 'a',
+ 's', 'c', 'i', 'i', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'', '\'', '>', '(',
+ ')', ';', 'I', '6', '4', ' ', 'r', 'o', 'w', 'i', 'd', '_', '6', '4', '=', 'r', 'o',
+ 'w', '_', 'i', 'd', '#', '1', '(', ')', ';', 'a', 's', 'c', 'i', 'i', ' ', 'i', 'n',
+ '_', 's', 'p', 'o', 't', '_', 'g', 'r', 'o', 'u', 'p', '=', 'S', 'P', 'O', 'T', '_',
+ 'G', 'R', 'O', 'U', 'P', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p',
+ 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', '>', 'z', 'i', 'p', '_', 'e', 'n',
+ 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'P', 'L', 'A', 'T', 'F', 'O', 'R',
+ 'M', '=', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', ';', 'p', 'h', 'y', 's', 'i', 'c',
+ 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':',
+ 'S', 'R', 'A', ':', 's', 'p', 'o', 't', 'i', 'd', '_', 't', '>', 'i', 'z', 'i', 'p',
+ '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'S', 'P', 'O', 'T',
+ '_', 'I', 'D', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p',
+ 'o', 't', 'i', 'd', '_', 't', '>', 's', 'u', 'b', '_', 'r', 'o', 'w', '_', 'i', 'd',
+ '#', '1', '(', 'S', 'P', 'O', 'T', '_', 'I', 'D', ')', ';', 'p', 'h', 'y', 's', 'i',
+ 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'a', 's', 'c', 'i', 'i',
+ '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '<', '0',
+ ',', '1', '>', ' ', '.', 'S', 'P', 'O', 'T', '_', 'G', 'R', 'O', 'U', 'P', '=', 'i',
+ 'n', '_', 's', 'p', 'o', 't', '_', 'g', 'r', 'o', 'u', 'p', ';', '}', 't', 'a', 'b',
+ 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'n', '_', 'e', 'n', 'c',
+ 'o', 'd', 'i', 'n', 'g', '#', '1', '{', 'U', '8', ' ', 'n', '_', 'e', 'n', 'c', 'o',
+ 'd', 'i', 'n', 'g', '_', 'd', 'u', 'm', 'm', 'y', '=', 'r', 'e', 'a', 'd', '_', 'u',
+ 'n', 'p', 'a', 'c', 'k', '|', 'r', 'e', 'a', 'd', '_', 'n', 'd', 'e', 'c', 'o', 'd',
+ 'e', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l',
+ ':', 's', 'e', 'q', 'l', 'o', 'c', '#', '1', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
+ '<', 'a', 's', 'c', 'i', 'i', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i',
+ 'n', 'g', '#', '1', ' ', 'S', 'E', 'Q', '_', 'I', 'D', ';', 'c', 'o', 'l', 'u', 'm',
+ 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n',
+ 'e', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1',
+ ' ', 'S', 'E', 'Q', '_', 'S', 'T', 'A', 'R', 'T', ';', 'r', 'e', 'a', 'd', 'o', 'n',
+ 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c',
+ 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'S', 'E', 'Q', '_', 'S', 'T', 'A',
+ 'R', 'T', ' ', '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'z', 'e', 'r', 'o', ')', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'o', 'n', 'e', '>', 'd', 'i', 'f', 'f', '#', '1', '<', '1', '>', '(', '.',
+ 'S', 'E', 'Q', '_', 'S', 'T', 'A', 'R', 'T', ')', ';', 'c', 'o', 'l', 'u', 'm', 'n',
+ ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n',
+ '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ',
+ 'S', 'E', 'Q', '_', 'L', 'E', 'N', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C',
+ 'B', 'I', ':', 't', 'b', 'l', ':', 'd', 'c', 'm', 'p', '_', 'b', 'a', 's', 'e', '_',
+ 's', 'p', 'a', 'c', 'e', '#', '1', '{', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a',
+ ':', 't', 'e', 'x', 't', ' ', 'd', 'c', 'm', 'p', '_', 'v', 'i', 'r', 't', 'u', 'a',
+ 'l', '_', 'p', 'r', 'o', 'd', 'u', 'c', 't', 'i', 'o', 'n', 's', '=', 'o', 'u', 't',
+ '_', 'd', 'c', 'm', 'p', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', '|', 'o', 'u', 't',
+ '_', 'd', 'c', 'm', 'p', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', '|', 'o', 'u',
+ 't', '_', 'd', 'c', 'm', 'p', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', '|', 'o', 'u',
+ 't', '_', 'd', 'c', 'm', 'p', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd',
+ ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':',
+ 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '_', 'c', 'o', 'm', 'm', 'o', 'n',
+ '#', '1', '.', '0', '.', '3', '=', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l', ':',
+ 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0', '.', '1', ',', 'I', 'N',
'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'd',
'e', 's', 'c', '#', '1', '.', '0', '.', '2', ',', 'I', 'N', 'S', 'D', 'C', ':', 'S',
- 'R', 'A', ':', 't', 'b', 'l', ':', 's', 't', 'a', 't', 's', '#', '1', '.', '1', '{',
- 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':',
- 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'P', 'L', 'A', 'T', 'F',
- 'O', 'R', 'M', ' ', '=', ' ', '.', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '|', 'o',
- 'u', 't', '_', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', ';', 'r', 'e', 'a', 'd', 'o',
- 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'a', 's', 'c', 'i', 'i', ' ',
- 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', ' ', '=', ' ', 'p', 'l', 'a', 't', 'f', 'o',
- 'r', 'm', '_', 'n', 'a', 'm', 'e', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N',
- 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', 'i', 'd', '_', 't', ' ',
- 'S', 'P', 'O', 'T', '_', 'I', 'D', ' ', '=', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':',
- 'S', 'R', 'A', ':', 's', 'p', 'o', 't', 'i', 'd', '_', 't', '>', 'a', 'd', 'd', '_',
- 'r', 'o', 'w', '_', 'i', 'd', '#', '1', '(', '.', 'S', 'P', 'O', 'T', '_', 'I', 'D',
- ')', '|', 'c', 'a', 's', 't', '#', '1', '(', 'r', 'o', 'w', 'i', 'd', '_', '6', '4',
- ')', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'a', 's', 'c', 'i', 'i', ' ', 'S', 'P',
- 'O', 'T', '_', 'G', 'R', 'O', 'U', 'P', ' ', '=', ' ', 'o', 'u', 't', '_', 's', 'p',
- 'o', 't', '_', 'g', 'r', 'o', 'u', 'p', '|', '.', 'S', 'P', 'O', 'T', '_', 'G', 'R',
- 'O', 'U', 'P', '|', '<', 'a', 's', 'c', 'i', 'i', '>', 'e', 'c', 'h', 'o', '#', '1',
- '<', '\'', '\'', '>', '(', ')', ';', 'I', '6', '4', ' ', 'r', 'o', 'w', 'i', 'd',
- '_', '6', '4', '=', 'r', 'o', 'w', '_', 'i', 'd', '#', '1', '(', ')', ';', 'a', 's',
- 'c', 'i', 'i', ' ', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'g', 'r', 'o', 'u', 'p',
- '=', 'S', 'P', 'O', 'T', '_', 'G', 'R', 'O', 'U', 'P', ';', 'p', 'h', 'y', 's', 'i',
- 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C',
- ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', '>',
- 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'P',
- 'L', 'A', 'T', 'F', 'O', 'R', 'M', '=', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', ';',
- 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<',
- 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', 'i', 'd', '_',
- 't', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1',
- ' ', '.', 'S', 'P', 'O', 'T', '_', 'I', 'D', '=', '<', 'I', 'N', 'S', 'D', 'C', ':',
- 'S', 'R', 'A', ':', 's', 'p', 'o', 't', 'i', 'd', '_', 't', '>', 's', 'u', 'b', '_',
- 'r', 'o', 'w', '_', 'i', 'd', '#', '1', '(', 'S', 'P', 'O', 'T', '_', 'I', 'D', ')',
- ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
- '<', 'a', 's', 'c', 'i', 'i', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i',
- 'n', 'g', '#', '1', '<', '0', ',', '1', '>', ' ', '.', 'S', 'P', 'O', 'T', '_', 'G',
- 'R', 'O', 'U', 'P', '=', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'g', 'r', 'o', 'u',
- 'p', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l',
- ':', 'n', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '{', 'U', '8', ' ',
- 'n', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '_', 'd', 'u', 'm', 'm', 'y', '=',
- 'r', 'e', 'a', 'd', '_', 'u', 'n', 'p', 'a', 'c', 'k', '|', 'r', 'e', 'a', 'd', '_',
- 'n', 'd', 'e', 'c', 'o', 'd', 'e', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C',
- 'B', 'I', ':', 't', 'b', 'l', ':', 's', 'e', 'q', 'l', 'o', 'c', '#', '1', '{', 'c',
- 'o', 'l', 'u', 'm', 'n', ' ', '<', 'a', 's', 'c', 'i', 'i', '>', 'z', 'i', 'p', '_',
- 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', 'S', 'E', 'Q', '_', 'I', 'D',
- ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o',
- 'd', 'i', 'n', 'g', '#', '1', ' ', 'S', 'E', 'Q', '_', 'S', 'T', 'A', 'R', 'T', ';',
- 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I',
- 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'S',
- 'E', 'Q', '_', 'S', 'T', 'A', 'R', 'T', ' ', '=', ' ', '(', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ')', '<', 'I', 'N', 'S', 'D',
- 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'd', 'i', 'f', 'f', '#',
- '1', '<', '1', '>', '(', '.', 'S', 'E', 'Q', '_', 'S', 'T', 'A', 'R', 'T', ')', ';',
- 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
- 'r', 'd', ':', 'l', 'e', 'n', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd',
- 'i', 'n', 'g', '#', '1', ' ', 'S', 'E', 'Q', '_', 'L', 'E', 'N', ';', '}', 't', 'a',
- 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'd', 'c', 'm', 'p',
- '_', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '#', '1', '{', 'I', 'N', 'S',
- 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'd', 'c', 'm', 'p', '_',
- 'v', 'i', 'r', 't', 'u', 'a', 'l', '_', 'p', 'r', 'o', 'd', 'u', 'c', 't', 'i', 'o',
- 'n', 's', '=', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_', '4', 'n', 'a', '_', 'b',
- 'i', 'n', '|', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_', 'x', '2', 'n', 'a', '_',
- 'b', 'i', 'n', '|', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_', '2', 'n', 'a', '_',
- 'b', 'i', 'n', '|', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_', '2', 'n', 'a', '_',
- 'p', 'a', 'c', 'k', 'e', 'd', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B',
- 'I', ':', 't', 'b', 'l', ':', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '_',
- 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.', '3', '=', 'I', 'N', 'S', 'D',
- 'C', ':', 't', 'b', 'l', ':', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.',
- '0', '.', '1', ',', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l',
- ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '#', '1', '.', '0', '.', '2', ',', 'I',
- 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 't', 'a', 't',
- 's', '#', '1', '.', '1', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'd', 'c',
- 'm', 'p', '_', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '#', '1', '{', 'b',
- 'o', 'o', 'l', ' ', 'c', 's', '_', 'n', 'a', 't', 'i', 'v', 'e', '=', '<', 'b', 'o',
- 'o', 'l', '>', 'e', 'c', 'h', 'o', '#', '1', '<', 'f', 'a', 'l', 's', 'e', '>', '(',
- ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ',
- 'o', 'u', 't', '_', 'c', 's', '_', 'k', 'e', 'y', '=', '.', 'C', 'S', '_', 'K', 'E',
- 'Y', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't',
- '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'', 'T', '\'', '>', '(', 'o', 'u', 't',
- '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ')', '|', '<', 'I', 'N', 'S', 'D',
- 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'e', 'c', 'h', 'o', '#', '1',
- '<', '\'', 'T', '\'', '>', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 'l',
- 'e', 'n', ')', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e',
- 'x', 't', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'', 'T', '\'', '>', '(', ')',
- ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'b', 'i', 'n', ' ', 'o', 'u',
- 't', '_', '2', 'c', 's', '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':',
- 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c',
- 's', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',',
- '2', ',', '3', ',', '4', ']', ',', '[', '0', ',', '1', ',', '2', ',', '3', ',', '0',
- ']', '>', '(', 'o', 'u', 't', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', ')', ';',
- 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't',
- '_', '2', 'n', 'a', '_', 'b', 'i', 'n', '=', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p',
- '_', '2', 'n', 'a', '_', 'b', 'i', 'n', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', '2',
- 'n', 'a', ':', 'b', 'i', 'n', ')', 'u', 'n', 'p', 'a', 'c', 'k', '#', '1', '(', 'o',
- 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', ')', ';', 'I', 'N',
- 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_',
- 'x', '2', 'c', 's', '_', 'b', 'i', 'n', '=', 'N', 'C', 'B', 'I', ':', 'c', 'o', 'l',
- 'o', 'r', '_', 'f', 'r', 'o', 'm', '_', 'd', 'n', 'a', '#', '1', '(', 'o', 'u', 't',
- '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ',', 'o', 'u', 't', '_', 'r', 'e', 'a',
- 'd', '_', 's', 't', 'a', 'r', 't', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_',
- 'l', 'e', 'n', ',', 'o', 'u', 't', '_', 'c', 's', '_', 'k', 'e', 'y', ',', 'o', 'u',
- 't', '_', 'c', 'o', 'l', 'o', 'r', '_', 'm', 'a', 't', 'r', 'i', 'x', ')', ';', 'I',
- 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o',
- 'u', 't', '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '(', 'I', 'N',
- 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'p', 'a', 'c', 'k', 'e', 'd', ')', 'p', 'a',
- 'c', 'k', '#', '1', '(', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'b', 'i', 'n', ')',
- ';', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd',
- ' ', 'o', 'u', 't', '_', '4', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '(',
- 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ')',
- 'p', 'a', 'c', 'k', '#', '1', '(', 'o', 'u', 't', '_', '4', 'n', 'a', '_', 'b', 'i',
- 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'l', 'o', 'r', ':', 't', 'e',
- 'x', 't', ' ', 'o', 'u', 't', '_', 'c', 'o', 'l', 'o', 'r', '_', 't', 'e', 'x', 't',
- '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ',',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'l', 'o', 'r', ':', 't', 'e', 'x', 't', '>',
+ 'R', 'A', ':', 't', 'b', 'l', ':', 's', 't', 'a', 't', 's', '#', '1', '.', '1', ',',
+ 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'd', 'c', 'm', 'p', '_', 'b', 'a', 's',
+ 'e', '_', 's', 'p', 'a', 'c', 'e', '#', '1', '{', 'b', 'o', 'o', 'l', ' ', 'c', 's',
+ '_', 'n', 'a', 't', 'i', 'v', 'e', '=', '<', 'b', 'o', 'o', 'l', '>', 'e', 'c', 'h',
+ 'o', '#', '1', '<', 'f', 'a', 'l', 's', 'e', '>', '(', ')', ';', 'I', 'N', 'S', 'D',
+ 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o', 'u', 't', '_', 'c', 's',
+ '_', 'k', 'e', 'y', '=', '.', 'C', 'S', '_', 'K', 'E', 'Y', '|', '<', 'I', 'N', 'S',
+ 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'e', 'c', 'h', 'o', '#',
+ '1', '<', '\'', 'T', '\'', '>', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_',
+ 't', 'y', 'p', 'e', ')', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':',
+ 't', 'e', 'x', 't', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'', 'T', '\'', '>',
+ '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ')', '|', '<', 'I',
+ 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'e', 'c', 'h',
+ 'o', '#', '1', '<', '\'', 'T', '\'', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', '2', 'c', 's', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', '2', 'c', 's', '_',
+ 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b',
+ 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'b', 'i', 'n', '>',
'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ']',
- ',', '\'', '0', '1', '2', '3', '.', '\'', '>', '(', 'o', 'u', 't', '_', 'x', '2',
- 'c', 's', '_', 'b', 'i', 'n', ')', ';', 'U', '8', ' ', 'o', 'u', 't', '_', 'c', 'o',
- 'l', 'o', 'r', '_', 'm', 'a', 't', 'r', 'i', 'x', '=', '<', 'U', '8', '>', 'e', 'c',
- 'h', 'o', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ',', '1',
- ',', '0', ',', '3', ',', '2', ',', '4', ',', '2', ',', '3', ',', '0', ',', '1', ',',
- '4', ',', '3', ',', '2', ',', '1', ',', '0', ',', '4', ',', '4', ',', '4', ',', '4',
- ',', '4', ',', '4', ']', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c',
- 'e', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '=', '(', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ')', 'r', 'o', 'w', '_', 'l', 'e',
- 'n', '#', '1', '(', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e',
- 'd', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e',
- 'n', ' ', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '_', 'f', 'i', 'x', 'e',
- 'd', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '=', '(', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ')', 'f', 'i', 'x', 'e', 'd', '_',
- 'r', 'o', 'w', '_', 'l', 'e', 'n', '#', '1', '(', 'o', 'u', 't', '_', '2', 'n', 'a',
- '_', 'p', 'a', 'c', 'k', 'e', 'd', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N',
- 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c',
- 'e', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '3', '=', 'N', 'C', 'B',
- 'I', ':', 't', 'b', 'l', ':', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '_',
- 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I',
- ':', 't', 'b', 'l', ':', 'n', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1',
- '{', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o',
- 'u', 't', '_', 'd', 'n', 'a', '_', 't', 'e', 'x', 't', '=', '<', 'I', 'N', 'S', 'D',
- 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':',
- 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0',
- ',', '1', ',', '2', ',', '3', ',', '4', ']', ',', '\'', 'A', 'C', 'G', 'T', 'N',
- '\'', '>', '(', 'o', 'u', 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')',
- ';', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'o', 'u',
- 't', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':',
- 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n',
- 'a', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',',
- '2', ',', '3', ',', '4', ']', ',', '[', '1', ',', '2', ',', '4', ',', '8', ',', '1',
- '5', ']', '>', '(', 'o', 'u', 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')',
- ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'o',
- 'u', 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', '=', '(', 'I', 'N', 'S', 'D',
- 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ')', 'r', 'e', 'a', 'd', '_', 'n',
- 'd', 'e', 'c', 'o', 'd', 'e', ';', 'U', '8', ' ', 'r', 'e', 'a', 'd', '_', 'u', 'n',
- 'p', 'a', 'c', 'k', '=', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ';',
- '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'b',
- 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '#', '1', '.', '0', '.', '3', '=', 'N',
- 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c',
- 'e', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '3', '{', 'I', 'N', 'S',
- 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u', 't',
- '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '.', 'R', 'E', 'A', 'D',
- ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':',
- 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '#', '2', '.', '0', '.', '3', '=',
- 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'b', 'a', 's', 'e', '_', 's', 'p', 'a',
- 'c', 'e', '_', 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.', '3', ',', 'N',
- 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'd', 'c', 'm', 'p', '_', 'b', 'a', 's', 'e',
- '_', 's', 'p', 'a', 'c', 'e', '#', '1', '{', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n',
- 'a', ':', 't', 'e', 'x', 't', ' ', 'i', 'n', '_', 'd', 'n', 'a', '_', 't', 'e', 'x',
- 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't',
- ',', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'm',
- 'a', 'p', '#', '1', '<', '\'', '.', 'a', 'c', 'm', 'g', 'r', 's', 'v', 't', 'w',
- 'y', 'h', 'k', 'd', 'b', 'n', '\'', ',', '\'', 'N', 'A', 'C', 'M', 'G', 'R', 'S',
- 'V', 'T', 'W', 'Y', 'H', 'K', 'D', 'B', 'N', '\'', '>', '(', 'R', 'E', 'A', 'D',
- ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'i',
- 'n', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':',
- '4', 'n', 'a', ':', 'b', 'i', 'n', '>', 'r', 'a', 'n', 'g', 'e', '_', 'v', 'a', 'l',
- 'i', 'd', 'a', 't', 'e', '#', '1', '<', '0', ',', '1', '5', '>', '(', 'R', 'E', 'A',
- 'D', ')', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n',
- ')', 'u', 'n', 'p', 'a', 'c', 'k', '#', '1', '(', 'i', 'n', '_', '4', 'n', 'a', '_',
- 'p', 'a', 'c', 'k', 'e', 'd', ')', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n',
- 'a', ':', 't', 'e', 'x', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':',
- 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1', '<', '\'', '.', 'A', 'C', 'M', 'G',
- 'R', 'S', 'V', 'T', 'W', 'Y', 'H', 'K', 'D', 'B', 'N', '\'', ',', '[', '0', ',',
- '1', ',', '2', ',', '3', ',', '4', ',', '5', ',', '6', ',', '7', ',', '8', ',', '9',
- ',', '1', '0', ',', '1', '1', ',', '1', '2', ',', '1', '3', ',', '1', '4', ',', '1',
- '5', ']', '>', '(', 'i', 'n', '_', 'd', 'n', 'a', '_', 't', 'e', 'x', 't', ')', '|',
- '<', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ',', 'I',
- 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#',
- '1', '<', '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ']', ',', '[', '1', ',',
- '2', ',', '4', ',', '8', ',', '1', '5', ']', '>', '(', 'i', 'n', '_', 'x', '2', 'n',
- 'a', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':',
- 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'i', 'n', '_', '4', 'n', 'a', '_', 'p', 'a', 'c',
- 'k', 'e', 'd', '=', 'R', 'E', 'A', 'D', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2',
- 'n', 'a', ':', 'b', 'i', 'n', ' ', 'i', 'n', '_', 'x', '2', 'n', 'a', '_', 'b', 'i',
- 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n',
- '>', 'r', 'a', 'n', 'g', 'e', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '#', '1',
- '<', '0', ',', '4', '>', '(', 'R', 'E', 'A', 'D', ')', '|', '<', 'I', 'N', 'S', 'D',
- 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'x',
- '2', 'n', 'a', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',',
- '1', ',', '2', ',', '3', ',', '4', ',', '5', ',', '6', ',', '7', ',', '8', ',', '9',
- ',', '1', '0', ',', '1', '1', ',', '1', '2', ',', '1', '3', ',', '1', '4', ',', '1',
- '5', ']', ',', '[', '4', ',', '0', ',', '1', ',', '4', ',', '2', ',', '4', ',', '4',
- ',', '4', ',', '3', ',', '4', ',', '4', ',', '4', ',', '4', ',', '4', ',', '4', ',',
- '4', ']', '>', '(', 'i', 'n', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'I',
- 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'i', 'n', '_', '2',
- 'n', 'a', '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a',
- ':', 'b', 'i', 'n', '>', 'r', 'a', 'n', 'g', 'e', '_', 'v', 'a', 'l', 'i', 'd', 'a',
- 't', 'e', '#', '1', '<', '0', ',', '3', '>', '(', 'R', 'E', 'A', 'D', ')', '|', '(',
- 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'b', 'i', 'n', ')', 'u', 'n', 'p',
- 'a', 'c', 'k', '#', '1', '(', 'i', 'n', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k',
- 'e', 'd', ')', '|', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'E', 'Q', ':', 'r', 'a', 'n',
- 'd', '_', '4', 'n', 'a', '_', '2', 'n', 'a', '#', '1', '(', 'i', 'n', '_', '4', 'n',
- 'a', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':',
- 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'i', 'n', '_', '2', 'n', 'a', '_', 'p', 'a', 'c',
- 'k', 'e', 'd', '=', 'R', 'E', 'A', 'D', ';', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n',
- 'a', ':', 'b', 'i', 'n', ' ', 'i', 'n', '_', 'a', 'l', 't', '_', '4', 'n', 'a', '_',
- 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i',
- 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', '>', 'm',
- 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ',', '5',
- ',', '6', ',', '7', ',', '8', ',', '9', ',', '1', '0', ',', '1', '1', ',', '1', '2',
- ',', '1', '3', ',', '1', '4', ',', '1', '5', ']', ',', '[', '1', '5', ',', '0', ',',
- '0', ',', '3', ',', '0', ',', '5', ',', '6', ',', '7', ',', '0', ',', '9', ',', '1',
- '0', ',', '1', '1', ',', '1', '2', ',', '1', '3', ',', '1', '4', ',', '1', '5', ']',
- '>', '(', 'i', 'n', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'U', '8', ' ',
- 'i', 'n', '_', 's', 't', 'a', 't', 's', '_', 'b', 'i', 'n', '=', 'i', 'n', '_', '2',
- 'n', 'a', '_', 'b', 'i', 'n', ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':',
- 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a',
- 'c', 'k', 'e', 'd', '=', '.', 'R', 'E', 'A', 'D', '|', 'o', 'u', 't', '_', 'd', 'c',
- 'm', 'p', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', ';', 'I', 'N', 'S',
- 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', 'x',
- '2', 'n', 'a', '_', 'b', 'i', 'n', '=', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_',
- 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', '4',
- 'n', 'a', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a',
- ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2',
- ',', '3', ',', '4', ',', '5', ',', '6', ',', '7', ',', '8', ',', '9', ',', '1', '0',
- ',', '1', '1', ',', '1', '2', ',', '1', '3', ',', '1', '4', ',', '1', '5', ']', ',',
- '[', '4', ',', '0', ',', '1', ',', '4', ',', '2', ',', '4', ',', '4', ',', '4', ',',
- '3', ',', '4', ',', '4', ',', '4', ',', '4', ',', '4', ',', '4', ',', '4', ']', '>',
+ ',', '[', '0', ',', '1', ',', '2', ',', '3', ',', '0', ']', '>', '(', 'o', 'u', 't',
+ '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':',
+ '2', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'b',
+ 'i', 'n', '=', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_', '2', 'n', 'a', '_', 'b',
+ 'i', 'n', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'b', 'i', 'n',
+ ')', 'u', 'n', 'p', 'a', 'c', 'k', '#', '1', '(', 'o', 'u', 't', '_', '2', 'n', 'a',
+ '_', 'p', 'a', 'c', 'k', 'e', 'd', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2',
+ 'c', 's', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', 'x', '2', 'c', 's', '_', 'b',
+ 'i', 'n', '=', 'N', 'C', 'B', 'I', ':', 'c', 'o', 'l', 'o', 'r', '_', 'f', 'r', 'o',
+ 'm', '_', 'd', 'n', 'a', '#', '1', '(', 'o', 'u', 't', '_', 'x', '2', 'n', 'a', '_',
+ 'b', 'i', 'n', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r',
+ 't', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',', 'o', 'u',
+ 't', '_', 'c', 's', '_', 'k', 'e', 'y', ',', 'o', 'u', 't', '_', 'c', 'o', 'l', 'o',
+ 'r', '_', 'm', 'a', 't', 'r', 'i', 'x', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '2',
+ 'c', 's', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u', 't', '_', '2', 'c', 's',
+ '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c',
+ 's', ':', 'p', 'a', 'c', 'k', 'e', 'd', ')', 'p', 'a', 'c', 'k', '#', '1', '(', 'o',
+ 'u', 't', '_', '2', 'c', 's', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', '4', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u', 't', '_', '4',
+ 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':',
+ '4', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ')', 'p', 'a', 'c', 'k', '#', '1',
'(', 'o', 'u', 't', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S',
- 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', '2', 'n',
- 'a', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':',
- '2', 'n', 'a', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a',
- ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2',
- ',', '3', ']', ',', '[', '1', ',', '2', ',', '4', ',', '8', ']', '>', '(', 'o', 'u',
- 't', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':',
- '4', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', '4', 'n', 'a', '_', 'b',
- 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n',
- '>', 'b', 'i', 't', '_', 'o', 'r', '#', '1', '<', '1', '>', '(', 'o', 'u', 't', '_',
- '2', 'n', 'a', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', ',', '.', 'A', 'L', 'T', 'R',
- 'E', 'A', 'D', ')', '|', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_', '4', 'n', 'a',
- '_', 'b', 'i', 'n', '|', 'o', 'u', 't', '_', '2', 'n', 'a', '_', '4', 'n', 'a', '_',
- 'b', 'i', 'n', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x',
- 't', ' ', 'o', 'u', 't', '_', 'd', 'n', 'a', '_', 't', 'e', 'x', 't', '=', '<', 'I',
- 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D',
- 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<',
- '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ',', '5', ',', '6', ',', '7', ',',
- '8', ',', '9', ',', '1', '0', ',', '1', '1', ',', '1', '2', ',', '1', '3', ',', '1',
- '4', ',', '1', '5', ']', ',', '\'', '.', 'A', 'C', 'M', 'G', 'R', 'S', 'V', 'T',
- 'W', 'Y', 'H', 'K', 'D', 'B', 'N', '\'', '>', '(', 'o', 'u', 't', '_', '4', 'n',
- 'a', '_', 'b', 'i', 'n', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c',
- 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p',
- 'a', 'c', 'k', 'e', 'd', ' ', '.', 'R', 'E', 'A', 'D', '=', 'i', 'n', '_', '2', 'n',
- 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', '2',
- 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ')', 'p', 'a', 'c', 'k', '#', '1', '(',
- 'i', 'n', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'p', 'h', 'y', 's', 'i',
- 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C',
- ':', '4', 'n', 'a', ':', 'b', 'i', 'n', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o',
- 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'A', 'L', 'T', 'R', 'E', 'A', 'D', '=', '<',
- 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', '>', 't', 'r', 'i',
- 'm', '#', '1', '<', '0', ',', '0', '>', '(', 'i', 'n', '_', 'a', 'l', 't', '_', '4',
- 'n', 'a', '_', 'b', 'i', 'n', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C',
- 'B', 'I', ':', 't', 'b', 'l', ':', 'd', 'c', 'm', 'p', '_', 'c', 'o', 'l', 'o', 'r',
- '_', 's', 'p', 'a', 'c', 'e', '#', '1', '{', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n',
- 'a', ':', 't', 'e', 'x', 't', ' ', 'd', 'c', 'm', 'p', '_', 'v', 'i', 'r', 't', 'u',
- 'a', 'l', '_', 'p', 'r', 'o', 'd', 'u', 'c', 't', 'i', 'o', 'n', 's', '=', 'o', 'u',
- 't', '_', 'd', 'c', 'm', 'p', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', '|', 'o',
- 'u', 't', '_', 'd', 'c', 'm', 'p', '_', '2', 'c', 's', '_', 'b', 'i', 'n', '|', 'o',
- 'u', 't', '_', 'd', 'c', 'm', 'p', '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e',
- 'd', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l',
- ':', 'c', 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e', '_', 'c', 'o', 'm', 'm',
- 'o', 'n', '#', '1', '.', '0', '.', '3', '=', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b',
- 'l', ':', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0', '.', '1', ',',
- 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o',
- 't', 'd', 'e', 's', 'c', '#', '1', '.', '0', '.', '2', ',', 'I', 'N', 'S', 'D', 'C',
- ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 't', 'a', 't', 's', '#', '1', '.',
- '1', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'd', 'c', 'm', 'p', '_', 'c',
- 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e', '#', '1', '{', 'b', 'o', 'o', 'l',
- ' ', 'c', 's', '_', 'n', 'a', 't', 'i', 'v', 'e', '=', '<', 'b', 'o', 'o', 'l', '>',
- 'e', 'c', 'h', 'o', '#', '1', '<', 't', 'r', 'u', 'e', '>', '(', ')', ';', 'I', 'N',
- 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', '2',
- 'c', 's', '_', 'b', 'i', 'n', '=', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_', '2',
- 'c', 's', '_', 'b', 'i', 'n', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's',
- ':', 'b', 'i', 'n', ')', 'u', 'n', 'p', 'a', 'c', 'k', '#', '1', '(', 'o', 'u', 't',
- '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', ')', ';', 'I', 'N', 'S', 'D',
- 'C', ':', '2', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', '2', 'n', 'a',
- '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':',
- 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'b', 'i', 'n',
- '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',', '3', ',', '4',
- ']', ',', '[', '0', ',', '1', ',', '2', ',', '3', ',', '0', ']', '>', '(', 'o', 'u',
+ 'D', 'C', ':', 'c', 'o', 'l', 'o', 'r', ':', 't', 'e', 'x', 't', ' ', 'o', 'u', 't',
+ '_', 'c', 'o', 'l', 'o', 'r', '_', 't', 'e', 'x', 't', '=', '<', 'I', 'N', 'S', 'D',
+ 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':',
+ 'c', 'o', 'l', 'o', 'r', ':', 't', 'e', 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<',
+ '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ']', ',', '\'', '0', '1', '2',
+ '3', '.', '\'', '>', '(', 'o', 'u', 't', '_', 'x', '2', 'c', 's', '_', 'b', 'i',
+ 'n', ')', ';', 'U', '8', ' ', 'o', 'u', 't', '_', 'c', 'o', 'l', 'o', 'r', '_', 'm',
+ 'a', 't', 'r', 'i', 'x', '=', '<', 'U', '8', '>', 'e', 'c', 'h', 'o', '#', '1', '<',
+ '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ',', '1', ',', '0', ',', '3', ',',
+ '2', ',', '4', ',', '2', ',', '3', ',', '0', ',', '1', ',', '4', ',', '3', ',', '2',
+ ',', '1', ',', '0', ',', '4', ',', '4', ',', '4', ',', '4', ',', '4', ',', '4', ']',
+ '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l',
+ 'e', 'n', ' ', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '_', 's', 'p', 'o',
+ 't', '_', 'l', 'e', 'n', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'l', 'e', 'n', ')', 'r', 'o', 'w', '_', 'l', 'e', 'n', '#', '1', '(', 'o',
+ 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', ')', ';', 'I', 'N',
+ 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'b', 'a', 's',
+ 'e', '_', 's', 'p', 'a', 'c', 'e', '_', 'f', 'i', 'x', 'e', 'd', '_', 's', 'p', 'o',
+ 't', '_', 'l', 'e', 'n', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'l', 'e', 'n', ')', 'f', 'i', 'x', 'e', 'd', '_', 'r', 'o', 'w', '_', 'l',
+ 'e', 'n', '#', '1', '(', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k',
+ 'e', 'd', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't',
+ 'b', 'l', ':', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '_', 'n', 'o', 'c',
+ 'o', 'l', '#', '1', '.', '0', '.', '3', '=', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l',
+ ':', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '_', 'c', 'o', 'm', 'm', 'o',
+ 'n', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':',
+ 'n', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '{', 'I', 'N', 'S', 'D',
+ 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o', 'u', 't', '_', 'd', 'n',
+ 'a', '_', 't', 'e', 'x', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n',
+ 'a', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't',
+ 'e', 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',',
+ '3', ',', '4', ']', ',', '\'', 'A', 'C', 'G', 'T', 'N', '\'', '>', '(', 'o', 'u',
't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C',
':', '4', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', '4', 'n', 'a', '_',
'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b',
@@ -1987,1025 +1844,1181 @@ const char sra_schema_text[] = {
'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ']',
',', '[', '1', ',', '2', ',', '4', ',', '8', ',', '1', '5', ']', '>', '(', 'o', 'u',
't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C',
- ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o', 'u', 't', '_', 'd', 'n', 'a',
- '_', 't', 'e', 'x', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a',
- ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e',
- 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',', '3',
- ',', '4', ']', ',', '\'', 'A', 'C', 'G', 'T', 'N', '\'', '>', '(', 'o', 'u', 't',
- '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':',
- 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', 'x', '2', 'n', 'a',
- '_', 'b', 'i', 'n', '=', 'N', 'C', 'B', 'I', ':', 'd', 'n', 'a', '_', 'f', 'r', 'o',
- 'm', '_', 'c', 'o', 'l', 'o', 'r', '#', '1', '(', 'o', 'u', 't', '_', 'x', '2', 'c',
- 's', '_', 'b', 'i', 'n', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't',
- 'a', 'r', 't', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',',
- 'o', 'u', 't', '_', 'c', 's', '_', 'k', 'e', 'y', ',', 'o', 'u', 't', '_', 'c', 'o',
- 'l', 'o', 'r', '_', 'm', 'a', 't', 'r', 'i', 'x', ')', ';', 'I', 'N', 'S', 'D', 'C',
- ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u', 't', '_', '2',
- 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':',
- '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ')', 'p', 'a', 'c', 'k', '#', '1',
- '(', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S',
- 'D', 'C', ':', '4', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u', 't',
- '_', '4', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '(', 'I', 'N', 'S', 'D',
- 'C', ':', '4', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ')', 'p', 'a', 'c', 'k',
- '#', '1', '(', 'o', 'u', 't', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'I',
- 'N', 'S', 'D', 'C', ':', 'c', 'o', 'l', 'o', 'r', ':', 't', 'e', 'x', 't', ' ', 'o',
- 'u', 't', '_', 'c', 'o', 'l', 'o', 'r', '_', 't', 'e', 'x', 't', '=', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D',
- 'C', ':', 'c', 'o', 'l', 'o', 'r', ':', 't', 'e', 'x', 't', '>', 'm', 'a', 'p', '#',
- '1', '<', '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ']', ',', '\'', '0',
- '1', '2', '3', '.', '\'', '>', '(', 'o', 'u', 't', '_', 'x', '2', 'c', 's', '_',
- 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
- 'l', 'e', 'n', ' ', 'c', 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e', '_', 's',
- 'p', 'o', 't', '_', 'l', 'e', 'n', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'l', 'e', 'n', ')', 'r', 'o', 'w', '_', 'l', 'e', 'n', '#', '1',
- '(', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', ')', ';',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'c',
- 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e', '_', 'f', 'i', 'x', 'e', 'd', '_',
- 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ')', 'f', 'i', 'x', 'e', 'd', '_', 'r', 'o',
- 'w', '_', 'l', 'e', 'n', '#', '1', '(', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'p',
- 'a', 'c', 'k', 'e', 'd', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B',
- 'I', ':', 't', 'b', 'l', ':', 'c', 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e',
- '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '3', '=', 'N', 'C', 'B', 'I',
- ':', 't', 'b', 'l', ':', 'c', 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e', '_',
- 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I',
- ':', 't', 'b', 'l', ':', 'n', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1',
- '{', 'U', '8', ' ', 'o', 'u', 't', '_', 'c', 'o', 'l', 'o', 'r', '_', 'm', 'a', 't',
- 'r', 'i', 'x', '=', '<', 'U', '8', '>', 'm', 'e', 't', 'a', ':', 'r', 'e', 'a', 'd',
- '#', '1', '<', '\'', 'C', 'O', 'L', 'O', 'R', '_', 'M', 'A', 'T', 'R', 'I', 'X',
- '\'', '>', '(', ')', '|', '<', 'U', '8', '>', 'e', 'c', 'h', 'o', '#', '1', '<',
- '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ',', '1', ',', '0', ',', '3', ',',
- '2', ',', '4', ',', '2', ',', '3', ',', '0', ',', '1', ',', '4', ',', '3', ',', '2',
- ',', '1', ',', '0', ',', '4', ',', '4', ',', '4', ',', '4', ',', '4', ',', '4', ']',
- '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i',
- 'n', ' ', 'o', 'u', 't', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', '=', '(', 'I',
- 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ')', 'r', 'e', 'a',
- 'd', '_', 'n', 'd', 'e', 'c', 'o', 'd', 'e', ';', 'U', '8', ' ', 'r', 'e', 'a', 'd',
- '_', 'u', 'n', 'p', 'a', 'c', 'k', '=', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'b',
- 'i', 'n', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b',
- 'l', ':', 'c', 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e', '#', '1', '.', '0',
- '.', '3', '=', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'c', 'o', 'l', 'o', 'r',
- '_', 's', 'p', 'a', 'c', 'e', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.',
- '3', '{', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ',
- 'o', 'u', 't', '_', 'c', 's', '_', 'k', 'e', 'y', '=', '.', 'C', 'S', '_', 'K', 'E',
- 'Y', ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'p', 'a', 'c', 'k', 'e',
- 'd', ' ', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=',
- '.', 'C', 'S', 'R', 'E', 'A', 'D', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C',
- 'B', 'I', ':', 't', 'b', 'l', ':', 'c', 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c',
- 'e', '#', '2', '.', '1', '=', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'c', 'o',
- 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e', '_', 'c', 'o', 'm', 'm', 'o', 'n', '#',
- '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'd', 'c',
- 'm', 'p', '_', 'c', 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e', '#', '1', '{',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'l', 'o', 'r', ':', 't', 'e', 'x', 't', ' ',
- 'i', 'n', '_', 'c', 'o', 'l', 'o', 'r', '_', 't', 'e', 'x', 't', '=', 'C', 'S', 'R',
- 'E', 'A', 'D', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i',
- 'n', ' ', 'i', 'n', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', '=', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', '>', 'r', 'a', 'n', 'g',
- 'e', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '#', '1', '<', '0', ',', '4', '>',
- '(', 'C', 'S', 'R', 'E', 'A', 'D', ')', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'l', 'o', 'r', ':', 't', 'e', 'x', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'x',
- '2', 'c', 's', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1', '<', '\'', '0',
- '1', '2', '3', '.', '\'', ',', '[', '0', ',', '1', ',', '2', ',', '3', ',', '4',
- ']', '>', '(', 'i', 'n', '_', 'c', 'o', 'l', 'o', 'r', '_', 't', 'e', 'x', 't', ')',
- ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'b', 'i', 'n', ' ', 'i', 'n',
- '_', '2', 'c', 's', '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', '2',
- 'c', 's', ':', 'b', 'i', 'n', '>', 'r', 'a', 'n', 'g', 'e', '_', 'v', 'a', 'l', 'i',
- 'd', 'a', 't', 'e', '#', '1', '<', '0', ',', '3', '>', '(', 'C', 'S', 'R', 'E', 'A',
- 'D', ')', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'b', 'i', 'n',
- ')', 'u', 'n', 'p', 'a', 'c', 'k', '#', '1', '(', 'i', 'n', '_', '2', 'c', 's', '_',
- 'p', 'a', 'c', 'k', 'e', 'd', ')', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2',
- 'c', 's', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':',
- 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',',
- '3', ',', '4', ']', ',', '[', '0', ',', '1', ',', '2', ',', '3', ',', '0', ']', '>',
- '(', 'i', 'n', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S',
- 'D', 'C', ':', '2', 'c', 's', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'i', 'n', '_',
- '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', 'C', 'S', 'R', 'E', 'A', 'D',
- ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ' ', 'i',
- 'n', '_', 'a', 'l', 't', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', '=', '<', 'I',
- 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S',
- 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1',
- '<', '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ']', ',', '[', '0', ',', '0',
- ',', '0', ',', '0', ',', '4', ']', '>', '(', 'i', 'n', '_', 'x', '2', 'c', 's', '_',
- 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e',
- 'x', 't', ' ', 'i', 'n', '_', 'c', 's', '_', 'k', 'e', 'y', '=', '<', 'I', 'N', 'S',
+ ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', 'x', '2', 'n',
+ 'a', '_', 'b', 'i', 'n', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a',
+ ':', 'b', 'i', 'n', ')', 'r', 'e', 'a', 'd', '_', 'n', 'd', 'e', 'c', 'o', 'd', 'e',
+ ';', 'U', '8', ' ', 'r', 'e', 'a', 'd', '_', 'u', 'n', 'p', 'a', 'c', 'k', '=', 'o',
+ 'u', 't', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ';', '}', 't', 'a', 'b', 'l', 'e',
+ ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'b', 'a', 's', 'e', '_', 's', 'p',
+ 'a', 'c', 'e', '#', '1', '.', '0', '.', '3', '=', 'N', 'C', 'B', 'I', ':', 't', 'b',
+ 'l', ':', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '_', 'n', 'o', 'c', 'o',
+ 'l', '#', '1', '.', '0', '.', '3', '{', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a',
+ ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'p',
+ 'a', 'c', 'k', 'e', 'd', '=', '.', 'R', 'E', 'A', 'D', ';', '}', 't', 'a', 'b', 'l',
+ 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'b', 'a', 's', 'e', '_', 's',
+ 'p', 'a', 'c', 'e', '#', '2', '.', '0', '.', '3', '=', 'N', 'C', 'B', 'I', ':', 't',
+ 'b', 'l', ':', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '_', 'c', 'o', 'm',
+ 'm', 'o', 'n', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b',
+ 'l', ':', 'd', 'c', 'm', 'p', '_', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e',
+ '#', '1', '{', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't',
+ ' ', 'i', 'n', '_', 'd', 'n', 'a', '_', 't', 'e', 'x', 't', '=', '<', 'I', 'N', 'S',
'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ',', 'I', 'N', 'S', 'D', 'C',
':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<', '\'',
- 'a', 'c', 'g', 't', '\'', ',', '\'', 'A', 'C', 'G', 'T', '\'', '>', '(', 'C', 'S',
- '_', 'K', 'E', 'Y', ')', ';', 'U', '8', ' ', 'i', 'n', '_', 'c', 'o', 'l', 'o', 'r',
- '_', 'm', 'a', 't', 'r', 'i', 'x', '=', '<', 'U', '8', '>', 'r', 'a', 'n', 'g', 'e',
- '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '#', '1', '<', '0', ',', '4', '>', '(',
- 'C', 'O', 'L', 'O', 'R', '_', 'M', 'A', 'T', 'R', 'I', 'X', ')', ';', 'U', '8', ' ',
- 'i', 'n', '_', 's', 't', 'a', 't', 's', '_', 'b', 'i', 'n', '=', 'i', 'n', '_', '2',
- 'c', 's', '_', 'b', 'i', 'n', ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':',
- 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'p', 'a',
- 'c', 'k', 'e', 'd', '=', '.', 'C', 'S', 'R', 'E', 'A', 'D', '|', 'o', 'u', 't', '_',
- 'd', 'c', 'm', 'p', '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', ';', 'I',
- 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't',
- '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', '=', '(', 'I', 'N', 'S', 'D', 'C', ':',
- 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ')', '<', 'U', '8', '>', 'b', 'i', 't', '_',
- 'o', 'r', '#', '1', '<', '1', '>', '(', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'b',
- 'i', 'n', ',', '.', 'A', 'L', 'T', 'C', 'S', 'R', 'E', 'A', 'D', ')', '|', 'o', 'u',
- 't', '_', 'd', 'c', 'm', 'p', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', '|', '(',
- 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ')', 'o', 'u',
- 't', '_', '2', 'c', 's', '_', 'b', 'i', 'n', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd',
+ '.', 'a', 'c', 'm', 'g', 'r', 's', 'v', 't', 'w', 'y', 'h', 'k', 'd', 'b', 'n', '\'',
+ ',', '\'', 'N', 'A', 'C', 'M', 'G', 'R', 'S', 'V', 'T', 'W', 'Y', 'H', 'K', 'D',
+ 'B', 'N', '\'', '>', '(', 'R', 'E', 'A', 'D', ')', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', '4', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'i', 'n', '_', '4', 'n', 'a', '_', 'b',
+ 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n',
+ '>', 'r', 'a', 'n', 'g', 'e', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '#', '1',
+ '<', '0', ',', '1', '5', '>', '(', 'R', 'E', 'A', 'D', ')', '|', '(', 'I', 'N', 'S',
+ 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', ')', 'u', 'n', 'p', 'a', 'c', 'k',
+ '#', '1', '(', 'i', 'n', '_', '4', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', ')',
+ '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ',',
+ 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p',
+ '#', '1', '<', '\'', '.', 'A', 'C', 'M', 'G', 'R', 'S', 'V', 'T', 'W', 'Y', 'H',
+ 'K', 'D', 'B', 'N', '\'', ',', '[', '0', ',', '1', ',', '2', ',', '3', ',', '4',
+ ',', '5', ',', '6', ',', '7', ',', '8', ',', '9', ',', '1', '0', ',', '1', '1', ',',
+ '1', '2', ',', '1', '3', ',', '1', '4', ',', '1', '5', ']', '>', '(', 'i', 'n', '_',
+ 'd', 'n', 'a', '_', 't', 'e', 'x', 't', ')', '|', '<', 'I', 'N', 'S', 'D', 'C', ':',
+ 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n',
+ 'a', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',',
+ '2', ',', '3', ',', '4', ']', ',', '[', '1', ',', '2', ',', '4', ',', '8', ',', '1',
+ '5', ']', '>', '(', 'i', 'n', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';',
+ 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ',
+ 'i', 'n', '_', '4', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', 'R', 'E', 'A',
+ 'D', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ' ',
+ 'i', 'n', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D',
+ 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', '>', 'r', 'a', 'n', 'g', 'e', '_',
+ 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '#', '1', '<', '0', ',', '4', '>', '(', 'R',
+ 'E', 'A', 'D', ')', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b',
+ 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n',
+ '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',', '3', ',', '4',
+ ',', '5', ',', '6', ',', '7', ',', '8', ',', '9', ',', '1', '0', ',', '1', '1', ',',
+ '1', '2', ',', '1', '3', ',', '1', '4', ',', '1', '5', ']', ',', '[', '4', ',', '0',
+ ',', '1', ',', '4', ',', '2', ',', '4', ',', '4', ',', '4', ',', '3', ',', '4', ',',
+ '4', ',', '4', ',', '4', ',', '4', ',', '4', ',', '4', ']', '>', '(', 'i', 'n', '_',
+ '4', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n',
+ 'a', ':', 'b', 'i', 'n', ' ', 'i', 'n', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', '=',
+ '<', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'b', 'i', 'n', '>', 'r', 'a',
+ 'n', 'g', 'e', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '#', '1', '<', '0', ',',
+ '3', '>', '(', 'R', 'E', 'A', 'D', ')', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', '2',
+ 'n', 'a', ':', 'b', 'i', 'n', ')', 'u', 'n', 'p', 'a', 'c', 'k', '#', '1', '(', 'i',
+ 'n', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', ')', '|', 'I', 'N', 'S',
+ 'D', 'C', ':', 'S', 'E', 'Q', ':', 'r', 'a', 'n', 'd', '_', '4', 'n', 'a', '_', '2',
+ 'n', 'a', '#', '1', '(', 'i', 'n', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', ')', ';',
+ 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ',
+ 'i', 'n', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', 'R', 'E', 'A',
+ 'D', ';', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', ' ', 'i',
+ 'n', '_', 'a', 'l', 't', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', '=', '<', 'I', 'N',
+ 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C',
+ ':', '4', 'n', 'a', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0',
+ ',', '1', ',', '2', ',', '3', ',', '4', ',', '5', ',', '6', ',', '7', ',', '8', ',',
+ '9', ',', '1', '0', ',', '1', '1', ',', '1', '2', ',', '1', '3', ',', '1', '4', ',',
+ '1', '5', ']', ',', '[', '1', '5', ',', '0', ',', '0', ',', '3', ',', '0', ',', '5',
+ ',', '6', ',', '7', ',', '0', ',', '9', ',', '1', '0', ',', '1', '1', ',', '1', '2',
+ ',', '1', '3', ',', '1', '4', ',', '1', '5', ']', '>', '(', 'i', 'n', '_', '4', 'n',
+ 'a', '_', 'b', 'i', 'n', ')', ';', 'U', '8', ' ', 'i', 'n', '_', 's', 't', 'a', 't',
+ 's', '_', 'b', 'i', 'n', '=', 'i', 'n', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ';',
+ 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ',
+ 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '.', 'R',
+ 'E', 'A', 'D', '|', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_', '2', 'n', 'a', '_',
+ 'p', 'a', 'c', 'k', 'e', 'd', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a',
+ ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n',
+ '=', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_', 'x', '2', 'n', 'a', '_', 'b', 'i',
+ 'n', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', ',',
+ 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', '>', 'm', 'a',
+ 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ',', '5', ',',
+ '6', ',', '7', ',', '8', ',', '9', ',', '1', '0', ',', '1', '1', ',', '1', '2', ',',
+ '1', '3', ',', '1', '4', ',', '1', '5', ']', ',', '[', '4', ',', '0', ',', '1', ',',
+ '4', ',', '2', ',', '4', ',', '4', ',', '4', ',', '3', ',', '4', ',', '4', ',', '4',
+ ',', '4', ',', '4', ',', '4', ',', '4', ']', '>', '(', 'o', 'u', 't', '_', '4', 'n',
+ 'a', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':',
+ 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', '2', 'n', 'a', '_', '4', 'n', 'a', '_', 'b',
+ 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'b', 'i', 'n',
+ ',', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', '>', 'm', 'a',
+ 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',', '3', ']', ',', '[', '1', ',',
+ '2', ',', '4', ',', '8', ']', '>', '(', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'b',
+ 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n',
+ ' ', 'o', 'u', 't', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S',
+ 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', '>', 'b', 'i', 't', '_', 'o', 'r',
+ '#', '1', '<', '1', '>', '(', 'o', 'u', 't', '_', '2', 'n', 'a', '_', '4', 'n', 'a',
+ '_', 'b', 'i', 'n', ',', '.', 'A', 'L', 'T', 'R', 'E', 'A', 'D', ')', '|', 'o', 'u',
+ 't', '_', 'd', 'c', 'm', 'p', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', '|', 'o', 'u',
+ 't', '_', '2', 'n', 'a', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', ';', 'I', 'N', 'S',
+ 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o', 'u', 't', '_', 'd',
+ 'n', 'a', '_', 't', 'e', 'x', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n',
+ 'a', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't',
+ 'e', 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',',
+ '3', ',', '4', ',', '5', ',', '6', ',', '7', ',', '8', ',', '9', ',', '1', '0', ',',
+ '1', '1', ',', '1', '2', ',', '1', '3', ',', '1', '4', ',', '1', '5', ']', ',', '\'',
+ '.', 'A', 'C', 'M', 'G', 'R', 'S', 'V', 'T', 'W', 'Y', 'H', 'K', 'D', 'B', 'N', '\'',
+ '>', '(', 'o', 'u', 't', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'p', 'h',
+ 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S',
+ 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', '.', 'R', 'E',
+ 'A', 'D', '=', 'i', 'n', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '|',
+ '(', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd',
+ ')', 'p', 'a', 'c', 'k', '#', '1', '(', 'i', 'n', '_', '2', 'n', 'a', '_', 'b', 'i',
+ 'n', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm',
+ 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', '>',
+ 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'A',
+ 'L', 'T', 'R', 'E', 'A', 'D', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a',
+ ':', 'b', 'i', 'n', '>', 't', 'r', 'i', 'm', '#', '1', '<', '0', ',', '0', '>', '(',
+ 'i', 'n', '_', 'a', 'l', 't', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', '}',
+ 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'd', 'c',
+ 'm', 'p', '_', 'c', 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e', '#', '1', '{',
+ 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'd', 'c',
+ 'm', 'p', '_', 'v', 'i', 'r', 't', 'u', 'a', 'l', '_', 'p', 'r', 'o', 'd', 'u', 'c',
+ 't', 'i', 'o', 'n', 's', '=', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_', 'x', '2',
+ 'c', 's', '_', 'b', 'i', 'n', '|', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_', '2',
+ 'c', 's', '_', 'b', 'i', 'n', '|', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_', '2',
+ 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', ';', '}', 't', 'a', 'b', 'l', 'e', ' ',
+ 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'c', 'o', 'l', 'o', 'r', '_', 's', 'p',
+ 'a', 'c', 'e', '_', 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.', '3', '=',
+ 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l', ':', 's', 'e', 'q', 'u', 'e', 'n', 'c',
+ 'e', '#', '1', '.', '0', '.', '1', ',', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A',
+ ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '#', '1', '.', '0',
+ '.', '2', ',', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':',
+ 's', 't', 'a', 't', 's', '#', '1', '.', '1', ',', 'N', 'C', 'B', 'I', ':', 't', 'b',
+ 'l', ':', 'd', 'c', 'm', 'p', '_', 'c', 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c',
+ 'e', '#', '1', '{', 'b', 'o', 'o', 'l', ' ', 'c', 's', '_', 'n', 'a', 't', 'i', 'v',
+ 'e', '=', '<', 'b', 'o', 'o', 'l', '>', 'e', 'c', 'h', 'o', '#', '1', '<', 't', 'r',
+ 'u', 'e', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'b',
+ 'i', 'n', ' ', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'b', 'i', 'n', '=', 'o', 'u',
+ 't', '_', 'd', 'c', 'm', 'p', '_', '2', 'c', 's', '_', 'b', 'i', 'n', '|', '(', 'I',
+ 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'b', 'i', 'n', ')', 'u', 'n', 'p', 'a',
+ 'c', 'k', '#', '1', '(', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k',
+ 'e', 'd', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'b', 'i', 'n',
+ ' ', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S',
+ 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C',
+ ':', '2', 'n', 'a', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0',
+ ',', '1', ',', '2', ',', '3', ',', '4', ']', ',', '[', '0', ',', '1', ',', '2', ',',
+ '3', ',', '0', ']', '>', '(', 'o', 'u', 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i',
+ 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'b', 'i', 'n', ' ',
+ 'o', 'u', 't', '_', '4', 'n', 'a', '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D',
+ 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':',
+ '4', 'n', 'a', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',',
+ '1', ',', '2', ',', '3', ',', '4', ']', ',', '[', '1', ',', '2', ',', '4', ',', '8',
+ ',', '1', '5', ']', '>', '(', 'o', 'u', 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i',
+ 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't',
+ ' ', 'o', 'u', 't', '_', 'd', 'n', 'a', '_', 't', 'e', 'x', 't', '=', '<', 'I', 'N',
+ 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D',
+ 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<',
+ '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ']', ',', '\'', 'A', 'C', 'G',
+ 'T', 'N', '\'', '>', '(', 'o', 'u', 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i',
+ 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n',
+ ' ', 'o', 'u', 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', '=', 'N', 'C', 'B',
+ 'I', ':', 'd', 'n', 'a', '_', 'f', 'r', 'o', 'm', '_', 'c', 'o', 'l', 'o', 'r', '#',
+ '1', '(', 'o', 'u', 't', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', ',', 'o', 'u',
+ 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', ',', 'o', 'u', 't', '_',
+ 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',', 'o', 'u', 't', '_', 'c', 's', '_', 'k',
+ 'e', 'y', ',', 'o', 'u', 't', '_', 'c', 'o', 'l', 'o', 'r', '_', 'm', 'a', 't', 'r',
+ 'i', 'x', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c',
+ 'k', 'e', 'd', ' ', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e',
+ 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k',
+ 'e', 'd', ')', 'p', 'a', 'c', 'k', '#', '1', '(', 'o', 'u', 't', '_', '2', 'n', 'a',
+ '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'p',
+ 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u', 't', '_', '4', 'n', 'a', '_', 'p', 'a', 'c',
+ 'k', 'e', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', '4', 'n', 'a', ':', 'p', 'a',
+ 'c', 'k', 'e', 'd', ')', 'p', 'a', 'c', 'k', '#', '1', '(', 'o', 'u', 't', '_', '4',
+ 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'l',
+ 'o', 'r', ':', 't', 'e', 'x', 't', ' ', 'o', 'u', 't', '_', 'c', 'o', 'l', 'o', 'r',
+ '_', 't', 'e', 'x', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's',
+ ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'l', 'o', 'r', ':',
+ 't', 'e', 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2',
+ ',', '3', ',', '4', ']', ',', '\'', '0', '1', '2', '3', '.', '\'', '>', '(', 'o',
+ 'u', 't', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'c', 'o', 'l', 'o', 'r',
+ '_', 's', 'p', 'a', 'c', 'e', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '=', '(',
+ 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ')', 'r',
+ 'o', 'w', '_', 'l', 'e', 'n', '#', '1', '(', 'o', 'u', 't', '_', '2', 'c', 's', '_',
+ 'p', 'a', 'c', 'k', 'e', 'd', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
+ 'r', 'd', ':', 'l', 'e', 'n', ' ', 'c', 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c',
+ 'e', '_', 'f', 'i', 'x', 'e', 'd', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '=',
+ '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ')',
+ 'f', 'i', 'x', 'e', 'd', '_', 'r', 'o', 'w', '_', 'l', 'e', 'n', '#', '1', '(', 'o',
+ 'u', 't', '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', ')', ';', '}', 't',
+ 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'c', 'o', 'l',
+ 'o', 'r', '_', 's', 'p', 'a', 'c', 'e', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.',
+ '0', '.', '3', '=', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'c', 'o', 'l', 'o',
+ 'r', '_', 's', 'p', 'a', 'c', 'e', '_', 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.',
+ '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'n', '_', 'e', 'n',
+ 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '{', 'U', '8', ' ', 'o', 'u', 't', '_', 'c',
+ 'o', 'l', 'o', 'r', '_', 'm', 'a', 't', 'r', 'i', 'x', '=', '<', 'U', '8', '>', 'm',
+ 'e', 't', 'a', ':', 'r', 'e', 'a', 'd', '#', '1', '<', '\'', 'C', 'O', 'L', 'O',
+ 'R', '_', 'M', 'A', 'T', 'R', 'I', 'X', '\'', '>', '(', ')', '|', '<', 'U', '8',
+ '>', 'e', 'c', 'h', 'o', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',', '3', ',',
+ '4', ',', '1', ',', '0', ',', '3', ',', '2', ',', '4', ',', '2', ',', '3', ',', '0',
+ ',', '1', ',', '4', ',', '3', ',', '2', ',', '1', ',', '0', ',', '4', ',', '4', ',',
+ '4', ',', '4', ',', '4', ',', '4', ']', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', 'x', '2', 'c',
+ 's', '_', 'b', 'i', 'n', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's',
+ ':', 'b', 'i', 'n', ')', 'r', 'e', 'a', 'd', '_', 'n', 'd', 'e', 'c', 'o', 'd', 'e',
+ ';', 'U', '8', ' ', 'r', 'e', 'a', 'd', '_', 'u', 'n', 'p', 'a', 'c', 'k', '=', 'o',
+ 'u', 't', '_', '2', 'c', 's', '_', 'b', 'i', 'n', ';', '}', 't', 'a', 'b', 'l', 'e',
+ ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'c', 'o', 'l', 'o', 'r', '_', 's',
+ 'p', 'a', 'c', 'e', '#', '1', '.', '0', '.', '3', '=', 'N', 'C', 'B', 'I', ':', 't',
+ 'b', 'l', ':', 'c', 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e', '_', 'n', 'o',
+ 'c', 'o', 'l', '#', '1', '.', '0', '.', '3', '{', 'I', 'N', 'S', 'D', 'C', ':', 'd',
'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o', 'u', 't', '_', 'c', 's', '_', 'k', 'e',
- 'y', '=', '.', 'C', 'S', '_', 'K', 'E', 'Y', ';', 'U', '8', ' ', 'o', 'u', 't', '_',
- 'c', 'o', 'l', 'o', 'r', '_', 'm', 'a', 't', 'r', 'i', 'x', '=', '.', 'C', 'O', 'L',
- 'O', 'R', '_', 'M', 'A', 'T', 'R', 'I', 'X', '|', '<', 'U', '8', '>', 'e', 'c', 'h',
- 'o', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ',', '1', ',',
- '0', ',', '3', ',', '2', ',', '4', ',', '2', ',', '3', ',', '0', ',', '1', ',', '4',
- ',', '3', ',', '2', ',', '1', ',', '0', ',', '4', ',', '4', ',', '4', ',', '4', ',',
- '4', ',', '4', ']', '>', '(', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
- 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':',
- 'p', 'a', 'c', 'k', 'e', 'd', ' ', '.', 'C', 'S', 'R', 'E', 'A', 'D', '=', 'i', 'n',
- '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', '|', '(', 'I', 'N', 'S', 'D',
- 'C', ':', '2', 'c', 's', ':', 'p', 'a', 'c', 'k', 'e', 'd', ')', 'p', 'a', 'c', 'k',
- '#', '1', '(', 'i', 'n', '_', '2', 'c', 's', '_', 'b', 'i', 'n', ')', ';', 'p', 'h',
- 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', '>', 'z', 'i', 'p', '_',
- 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'A', 'L', 'T', 'C', 'S',
- 'R', 'E', 'A', 'D', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':',
- 'b', 'i', 'n', '>', 't', 'r', 'i', 'm', '#', '1', '<', '0', ',', '0', '>', '(', 'i',
- 'n', '_', 'a', 'l', 't', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', ')', ';', 'p',
- 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I',
- 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'z', 'i', 'p',
- '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'C', 'S', '_', 'K',
- 'E', 'Y', '=', 'i', 'n', '_', 'c', 's', '_', 'k', 'e', 'y', ';', 'p', 'h', 'y', 's',
- 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'U', '8', '>', 'z',
- 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'C', 'O',
- 'L', 'O', 'R', '_', 'M', 'A', 'T', 'R', 'I', 'X', '=', 'i', 'n', '_', 'c', 'o', 'l',
- 'o', 'r', '_', 'm', 'a', 't', 'r', 'i', 'x', ';', '}', 't', 'a', 'b', 'l', 'e', ' ',
- 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'p', 'r', 'o', 't', 'e', 'i', 'n', '#',
- '1', '=', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l', ':', 'p', 'r', 'o', 't', 'e',
- 'i', 'n', '#', '1', '{', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'r', 'o', 't', 'e', 'i',
- 'n', ':', 't', 'e', 'x', 't', ' ', 'i', 'n', '_', 'p', 'r', 'o', 't', 'e', 'i', 'n',
- '_', 't', 'e', 'x', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'r', 'o', 't',
- 'e', 'i', 'n', ':', 't', 'e', 'x', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'r',
- 'o', 't', 'e', 'i', 'n', ':', 't', 'e', 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<',
- '\'', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'k', 'l', 'm', 'n', 'p', 'q',
- 'r', 's', 't', 'v', 'w', 'x', 'y', 'z', 'u', '\'', ',', '\'', 'A', 'B', 'C', 'D',
- 'E', 'F', 'G', 'H', 'I', 'K', 'L', 'M', 'N', 'P', 'Q', 'R', 'S', 'T', 'V', 'W', 'X',
- 'Y', 'Z', 'U', '\'', '>', '(', 'P', 'R', 'O', 'T', 'E', 'I', 'N', ')', ';', 'I',
- 'N', 'S', 'D', 'C', ':', 'a', 'a', ':', 'b', 'i', 'n', ' ', 'i', 'n', '_', 'a', 'a',
- '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'a', 'a', ':', 'b', 'i',
- 'n', '>', 'r', 'a', 'n', 'g', 'e', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '#',
- '1', '<', '1', ',', '2', '5', '>', '(', 'P', 'R', 'O', 'T', 'E', 'I', 'N', ')', '|',
- '<', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'r', 'o', 't', 'e', 'i', 'n', ':', 't', 'e',
- 'x', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'a', 'a', ':', 'b', 'i', 'n', '>', 'm',
- 'a', 'p', '#', '1', '<', '\'', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'K',
- 'L', 'M', 'N', 'P', 'Q', 'R', 'S', 'T', 'V', 'W', 'X', 'Y', 'Z', 'U', '*', '\'',
- ',', '[', '1', ',', '2', ',', '3', ',', '4', ',', '5', ',', '6', ',', '7', ',', '8',
- ',', '9', ',', '1', '0', ',', '1', '1', ',', '1', '2', ',', '1', '3', ',', '1', '4',
- ',', '1', '5', ',', '1', '6', ',', '1', '7', ',', '1', '8', ',', '1', '9', ',', '2',
- '0', ',', '2', '1', ',', '2', '2', ',', '2', '3', ',', '2', '4', ',', '2', '5', ']',
- '>', '(', 'i', 'n', '_', 'p', 'r', 'o', 't', 'e', 'i', 'n', '_', 't', 'e', 'x', 't',
- ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'a', 'a', ':', 'b', 'i', 'n', ' ', 'o', 'u',
- 't', '_', 'a', 'a', '_', 'b', 'i', 'n', '=', '.', 'P', 'R', 'O', 'T', 'E', 'I', 'N',
- ';', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'r', 'o', 't', 'e', 'i', 'n', ':', 't', 'e',
- 'x', 't', ' ', 'o', 'u', 't', '_', 'p', 'r', 'o', 't', 'e', 'i', 'n', '_', 't', 'e',
- 'x', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'a', 'a', ':', 'b', 'i', 'n', ',',
+ 'y', '=', '.', 'C', 'S', '_', 'K', 'E', 'Y', ';', 'I', 'N', 'S', 'D', 'C', ':', '2',
+ 'c', 's', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u', 't', '_', '2', 'c', 's',
+ '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '.', 'C', 'S', 'R', 'E', 'A', 'D', ';', '}',
+ 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'c', 'o',
+ 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e', '#', '2', '.', '1', '=', 'N', 'C', 'B',
+ 'I', ':', 't', 'b', 'l', ':', 'c', 'o', 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e',
+ '_', 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B',
+ 'I', ':', 't', 'b', 'l', ':', 'd', 'c', 'm', 'p', '_', 'c', 'o', 'l', 'o', 'r', '_',
+ 's', 'p', 'a', 'c', 'e', '#', '1', '{', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'l',
+ 'o', 'r', ':', 't', 'e', 'x', 't', ' ', 'i', 'n', '_', 'c', 'o', 'l', 'o', 'r', '_',
+ 't', 'e', 'x', 't', '=', 'C', 'S', 'R', 'E', 'A', 'D', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ' ', 'i', 'n', '_', 'x', '2', 'c', 's',
+ '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':',
+ 'b', 'i', 'n', '>', 'r', 'a', 'n', 'g', 'e', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't',
+ 'e', '#', '1', '<', '0', ',', '4', '>', '(', 'C', 'S', 'R', 'E', 'A', 'D', ')', '|',
+ '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'l', 'o', 'r', ':', 't', 'e', 'x', 't',
+ ',', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', '>', 'm',
+ 'a', 'p', '#', '1', '<', '\'', '0', '1', '2', '3', '.', '\'', ',', '[', '0', ',',
+ '1', ',', '2', ',', '3', ',', '4', ']', '>', '(', 'i', 'n', '_', 'c', 'o', 'l', 'o',
+ 'r', '_', 't', 'e', 'x', 't', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's',
+ ':', 'b', 'i', 'n', ' ', 'i', 'n', '_', '2', 'c', 's', '_', 'b', 'i', 'n', '=', '<',
+ 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'b', 'i', 'n', '>', 'r', 'a', 'n',
+ 'g', 'e', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '#', '1', '<', '0', ',', '3',
+ '>', '(', 'C', 'S', 'R', 'E', 'A', 'D', ')', '|', '(', 'I', 'N', 'S', 'D', 'C', ':',
+ '2', 'c', 's', ':', 'b', 'i', 'n', ')', 'u', 'n', 'p', 'a', 'c', 'k', '#', '1', '(',
+ 'i', 'n', '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', ')', '|', '<', 'I',
+ 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S',
+ 'D', 'C', ':', '2', 'c', 's', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1', '<',
+ '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ']', ',', '[', '0', ',', '1', ',',
+ '2', ',', '3', ',', '0', ']', '>', '(', 'i', 'n', '_', 'x', '2', 'c', 's', '_', 'b',
+ 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'p', 'a', 'c',
+ 'k', 'e', 'd', ' ', 'i', 'n', '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd',
+ '=', 'C', 'S', 'R', 'E', 'A', 'D', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c',
+ 's', ':', 'b', 'i', 'n', ' ', 'i', 'n', '_', 'a', 'l', 't', '_', 'x', '2', 'c', 's',
+ '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':',
+ 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i',
+ 'n', '>', 'm', 'a', 'p', '#', '1', '<', '[', '0', ',', '1', ',', '2', ',', '3', ',',
+ '4', ']', ',', '[', '0', ',', '0', ',', '0', ',', '0', ',', '4', ']', '>', '(', 'i',
+ 'n', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'i', 'n', '_', 'c', 's', '_', 'k',
+ 'e', 'y', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x',
+ 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>',
+ 'm', 'a', 'p', '#', '1', '<', '\'', 'a', 'c', 'g', 't', '\'', ',', '\'', 'A', 'C',
+ 'G', 'T', '\'', '>', '(', 'C', 'S', '_', 'K', 'E', 'Y', ')', ';', 'U', '8', ' ',
+ 'i', 'n', '_', 'c', 'o', 'l', 'o', 'r', '_', 'm', 'a', 't', 'r', 'i', 'x', '=', '<',
+ 'U', '8', '>', 'r', 'a', 'n', 'g', 'e', '_', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e',
+ '#', '1', '<', '0', ',', '4', '>', '(', 'C', 'O', 'L', 'O', 'R', '_', 'M', 'A', 'T',
+ 'R', 'I', 'X', ')', ';', 'U', '8', ' ', 'i', 'n', '_', 's', 't', 'a', 't', 's', '_',
+ 'b', 'i', 'n', '=', 'i', 'n', '_', '2', 'c', 's', '_', 'b', 'i', 'n', ';', 'I', 'N',
+ 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u',
+ 't', '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '.', 'C', 'S', 'R',
+ 'E', 'A', 'D', '|', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_', '2', 'c', 's', '_',
+ 'p', 'a', 'c', 'k', 'e', 'd', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's',
+ ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n',
+ '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', ')',
+ '<', 'U', '8', '>', 'b', 'i', 't', '_', 'o', 'r', '#', '1', '<', '1', '>', '(', 'o',
+ 'u', 't', '_', '2', 'c', 's', '_', 'b', 'i', 'n', ',', '.', 'A', 'L', 'T', 'C', 'S',
+ 'R', 'E', 'A', 'D', ')', '|', 'o', 'u', 't', '_', 'd', 'c', 'm', 'p', '_', 'x', '2',
+ 'c', 's', '_', 'b', 'i', 'n', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c',
+ 's', ':', 'b', 'i', 'n', ')', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'b', 'i', 'n',
+ ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o',
+ 'u', 't', '_', 'c', 's', '_', 'k', 'e', 'y', '=', '.', 'C', 'S', '_', 'K', 'E', 'Y',
+ ';', 'U', '8', ' ', 'o', 'u', 't', '_', 'c', 'o', 'l', 'o', 'r', '_', 'm', 'a', 't',
+ 'r', 'i', 'x', '=', '.', 'C', 'O', 'L', 'O', 'R', '_', 'M', 'A', 'T', 'R', 'I', 'X',
+ '|', '<', 'U', '8', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '[', '0', ',', '1', ',',
+ '2', ',', '3', ',', '4', ',', '1', ',', '0', ',', '3', ',', '2', ',', '4', ',', '2',
+ ',', '3', ',', '0', ',', '1', ',', '4', ',', '3', ',', '2', ',', '1', ',', '0', ',',
+ '4', ',', '4', ',', '4', ',', '4', ',', '4', ',', '4', ']', '>', '(', ')', ';', 'p',
+ 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N',
+ 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', '.', 'C',
+ 'S', 'R', 'E', 'A', 'D', '=', 'i', 'n', '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k',
+ 'e', 'd', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', '2', 'c', 's', ':', 'p', 'a', 'c',
+ 'k', 'e', 'd', ')', 'p', 'a', 'c', 'k', '#', '1', '(', 'i', 'n', '_', '2', 'c', 's',
+ '_', 'b', 'i', 'n', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'c', 's', ':',
+ 'b', 'i', 'n', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#',
+ '1', ' ', '.', 'A', 'L', 'T', 'C', 'S', 'R', 'E', 'A', 'D', '=', '<', 'I', 'N', 'S',
+ 'D', 'C', ':', 'x', '2', 'c', 's', ':', 'b', 'i', 'n', '>', 't', 'r', 'i', 'm', '#',
+ '1', '<', '0', ',', '0', '>', '(', 'i', 'n', '_', 'a', 'l', 't', '_', 'x', '2', 'c',
+ 's', '_', 'b', 'i', 'n', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c',
+ 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':',
+ 't', 'e', 'x', 't', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g',
+ '#', '1', ' ', '.', 'C', 'S', '_', 'K', 'E', 'Y', '=', 'i', 'n', '_', 'c', 's', '_',
+ 'k', 'e', 'y', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u',
+ 'm', 'n', ' ', '<', 'U', '8', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i',
+ 'n', 'g', '#', '1', ' ', '.', 'C', 'O', 'L', 'O', 'R', '_', 'M', 'A', 'T', 'R', 'I',
+ 'X', '=', 'i', 'n', '_', 'c', 'o', 'l', 'o', 'r', '_', 'm', 'a', 't', 'r', 'i', 'x',
+ ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':',
+ 'p', 'r', 'o', 't', 'e', 'i', 'n', '#', '1', '=', 'I', 'N', 'S', 'D', 'C', ':', 't',
+ 'b', 'l', ':', 'p', 'r', 'o', 't', 'e', 'i', 'n', '#', '1', '{', 'I', 'N', 'S', 'D',
+ 'C', ':', 'p', 'r', 'o', 't', 'e', 'i', 'n', ':', 't', 'e', 'x', 't', ' ', 'i', 'n',
+ '_', 'p', 'r', 'o', 't', 'e', 'i', 'n', '_', 't', 'e', 'x', 't', '=', '<', 'I', 'N',
+ 'S', 'D', 'C', ':', 'p', 'r', 'o', 't', 'e', 'i', 'n', ':', 't', 'e', 'x', 't', ',',
'I', 'N', 'S', 'D', 'C', ':', 'p', 'r', 'o', 't', 'e', 'i', 'n', ':', 't', 'e', 'x',
- 't', '>', 'm', 'a', 'p', '#', '1', '<', '[', '1', ',', '2', ',', '3', ',', '4', ',',
- '5', ',', '6', ',', '7', ',', '8', ',', '9', ',', '1', '0', ',', '1', '1', ',', '1',
- '2', ',', '1', '3', ',', '1', '4', ',', '1', '5', ',', '1', '6', ',', '1', '7', ',',
- '1', '8', ',', '1', '9', ',', '2', '0', ',', '2', '1', ',', '2', '2', ',', '2', '3',
- ',', '2', '4', ',', '2', '5', ']', ',', '\'', 'A', 'B', 'C', 'D', 'E', 'F', 'G',
- 'H', 'I', 'K', 'L', 'M', 'N', 'P', 'Q', 'R', 'S', 'T', 'V', 'W', 'X', 'Y', 'Z', 'U',
- '*', '\'', '>', '(', 'o', 'u', 't', '_', 'a', 'a', '_', 'b', 'i', 'n', ')', ';',
- 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<',
- 'I', 'N', 'S', 'D', 'C', ':', 'a', 'a', ':', 'b', 'i', 'n', '>', 'z', 'i', 'p', '_',
- 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'P', 'R', 'O', 'T', 'E',
- 'I', 'N', '=', 'i', 'n', '_', 'a', 'a', '_', 'b', 'i', 'n', ';', '}', 't', 'a', 'b',
- 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'p', 'h', 'r', 'e', 'd',
+ 't', '>', 'm', 'a', 'p', '#', '1', '<', '\'', 'a', 'b', 'c', 'd', 'e', 'f', 'g',
+ 'h', 'i', 'k', 'l', 'm', 'n', 'p', 'q', 'r', 's', 't', 'v', 'w', 'x', 'y', 'z', 'u',
+ '\'', ',', '\'', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'K', 'L', 'M', 'N',
+ 'P', 'Q', 'R', 'S', 'T', 'V', 'W', 'X', 'Y', 'Z', 'U', '\'', '>', '(', 'P', 'R',
+ 'O', 'T', 'E', 'I', 'N', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'a', 'a', ':', 'b',
+ 'i', 'n', ' ', 'i', 'n', '_', 'a', 'a', '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S',
+ 'D', 'C', ':', 'a', 'a', ':', 'b', 'i', 'n', '>', 'r', 'a', 'n', 'g', 'e', '_', 'v',
+ 'a', 'l', 'i', 'd', 'a', 't', 'e', '#', '1', '<', '1', ',', '2', '5', '>', '(', 'P',
+ 'R', 'O', 'T', 'E', 'I', 'N', ')', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'r',
+ 'o', 't', 'e', 'i', 'n', ':', 't', 'e', 'x', 't', ',', 'I', 'N', 'S', 'D', 'C', ':',
+ 'a', 'a', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1', '<', '\'', 'A', 'B',
+ 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'K', 'L', 'M', 'N', 'P', 'Q', 'R', 'S', 'T', 'V',
+ 'W', 'X', 'Y', 'Z', 'U', '*', '\'', ',', '[', '1', ',', '2', ',', '3', ',', '4',
+ ',', '5', ',', '6', ',', '7', ',', '8', ',', '9', ',', '1', '0', ',', '1', '1', ',',
+ '1', '2', ',', '1', '3', ',', '1', '4', ',', '1', '5', ',', '1', '6', ',', '1', '7',
+ ',', '1', '8', ',', '1', '9', ',', '2', '0', ',', '2', '1', ',', '2', '2', ',', '2',
+ '3', ',', '2', '4', ',', '2', '5', ']', '>', '(', 'i', 'n', '_', 'p', 'r', 'o', 't',
+ 'e', 'i', 'n', '_', 't', 'e', 'x', 't', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'a',
+ 'a', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', 'a', 'a', '_', 'b', 'i', 'n', '=',
+ '.', 'P', 'R', 'O', 'T', 'E', 'I', 'N', ';', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'r',
+ 'o', 't', 'e', 'i', 'n', ':', 't', 'e', 'x', 't', ' ', 'o', 'u', 't', '_', 'p', 'r',
+ 'o', 't', 'e', 'i', 'n', '_', 't', 'e', 'x', 't', '=', '<', 'I', 'N', 'S', 'D', 'C',
+ ':', 'a', 'a', ':', 'b', 'i', 'n', ',', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'r', 'o',
+ 't', 'e', 'i', 'n', ':', 't', 'e', 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<', '[',
+ '1', ',', '2', ',', '3', ',', '4', ',', '5', ',', '6', ',', '7', ',', '8', ',', '9',
+ ',', '1', '0', ',', '1', '1', ',', '1', '2', ',', '1', '3', ',', '1', '4', ',', '1',
+ '5', ',', '1', '6', ',', '1', '7', ',', '1', '8', ',', '1', '9', ',', '2', '0', ',',
+ '2', '1', ',', '2', '2', ',', '2', '3', ',', '2', '4', ',', '2', '5', ']', ',', '\'',
+ 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'K', 'L', 'M', 'N', 'P', 'Q', 'R', 'S',
+ 'T', 'V', 'W', 'X', 'Y', 'Z', 'U', '*', '\'', '>', '(', 'o', 'u', 't', '_', 'a',
+ 'a', '_', 'b', 'i', 'n', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c',
+ 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'a', 'a', ':', 'b',
+ 'i', 'n', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1',
+ ' ', '.', 'P', 'R', 'O', 'T', 'E', 'I', 'N', '=', 'i', 'n', '_', 'a', 'a', '_', 'b',
+ 'i', 'n', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b',
+ 'l', ':', 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_', 'n',
+ 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '1', '=', 'I', 'N', 'S', 'D', 'C', ':',
+ 't', 'b', 'l', ':', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0', '.',
+ '1', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'n', '_', 'e', 'n', 'c', 'o',
+ 'd', 'i', 'n', 'g', '#', '1', '{', 'U', '8', ' ', 'r', 'e', 'a', 'd', '_', 'n', 'd',
+ 'e', 'c', 'o', 'd', 'e', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l',
+ 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ',', 'U', '8', '>', 'm', 'a', 'p', '#',
+ '1', '<', '0', ',', '4', '>', '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p',
+ 'h', 'r', 'e', 'd', ',', 'r', 'e', 'a', 'd', '_', 'u', 'n', 'p', 'a', 'c', 'k', ')',
+ ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':',
+ 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '#', '1', '.', '0',
+ '.', '1', '=', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'p', 'h', 'r', 'e', 'd',
'_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.',
- '0', '.', '1', '=', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l', ':', 's', 'e', 'q',
- 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0', '.', '1', ',', 'N', 'C', 'B', 'I', ':',
- 't', 'b', 'l', ':', 'n', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '{',
- 'U', '8', ' ', 'r', 'e', 'a', 'd', '_', 'n', 'd', 'e', 'c', 'o', 'd', 'e', '=', '<',
- 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r',
- 'e', 'd', ',', 'U', '8', '>', 'm', 'a', 'p', '#', '1', '<', '0', ',', '4', '>', '(',
- 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', ',', 'r', 'e',
- 'a', 'd', '_', 'u', 'n', 'p', 'a', 'c', 'k', ')', ';', '}', 't', 'a', 'b', 'l', 'e',
- ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'p', 'h', 'r', 'e', 'd', '_', 'q',
- 'u', 'a', 'l', 'i', 't', 'y', '#', '1', '.', '0', '.', '1', '=', 'N', 'C', 'B', 'I',
+ '0', '.', '1', '{', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':',
+ 'n', '_', 'e', 'n', 'c', 'o', 'd', 'e', 'd', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'o',
+ 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', '=', '.', 'Q', 'U',
+ 'A', 'L', 'I', 'T', 'Y', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I',
':', 't', 'b', 'l', ':', 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't',
- 'y', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '1', '{', 'N', 'C', 'B',
- 'I', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'n', '_', 'e', 'n', 'c', 'o', 'd',
- 'e', 'd', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l',
- '_', 'p', 'h', 'r', 'e', 'd', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', '}',
- 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'p', 'h',
- 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '#', '2', '.', '0', '.', '4',
- '=', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l', ':', 's', 'e', 'q', 'u', 'e', 'n',
- 'c', 'e', '#', '1', '.', '0', '.', '1', '{', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u',
- 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'o', 'u', 't', '_', 'q',
- 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T',
- 'Y', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 't',
- 'e', 'x', 't', ':', 'p', 'h', 'r', 'e', 'd', '_', '3', '3', ' ', 'i', 'n', '_', 'q',
- 'u', 'a', 'l', '_', 't', 'e', 'x', 't', '_', 'p', 'h', 'r', 'e', 'd', '_', '3', '3',
- '=', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u',
- 'a', 'l', 'i', 't', 'y', ':', 't', 'e', 'x', 't', ':', 'p', 'h', 'r', 'e', 'd', '_',
- '6', '4', ' ', 'i', 'n', '_', 'q', 'u', 'a', 'l', '_', 't', 'e', 'x', 't', '_', 'p',
- 'h', 'r', 'e', 'd', '_', '6', '4', '=', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'I',
- 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e',
- 'd', ' ', 'i', 'n', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', '=', 'Q',
- 'U', 'A', 'L', 'I', 'T', 'Y', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a',
- 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ')', '<', 'B', '8', '>', 'd', 'i',
- 'f', 'f', '#', '1', '<', '3', '3', '>', '(', 'i', 'n', '_', 'q', 'u', 'a', 'l', '_',
- 't', 'e', 'x', 't', '_', 'p', 'h', 'r', 'e', 'd', '_', '3', '3', ')', '|', '(', 'I',
+ 'y', '#', '2', '.', '0', '.', '4', '=', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l',
+ ':', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0', '.', '1', '{', 'I',
'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e',
- 'd', ')', '<', 'B', '8', '>', 'd', 'i', 'f', 'f', '#', '1', '<', '6', '4', '>', '(',
- 'i', 'n', '_', 'q', 'u', 'a', 'l', '_', 't', 'e', 'x', 't', '_', 'p', 'h', 'r', 'e',
- 'd', '_', '6', '4', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i',
- 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'i', 'n', '_', 's', 't', 'a', 't', 's',
- '_', 'q', 'u', 'a', 'l', '=', 'i', 'n', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r',
- 'e', 'd', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm',
- 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':',
- 'p', 'h', 'r', 'e', 'd', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n',
- 'g', '#', '1', ' ', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '=', 'i', 'n', '_', 'q',
- 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', ';', '}', 't', 'a', 'b', 'l', 'e', ' ',
- 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's',
- '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.',
- '0', '.', '1', '=', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l', ':', 's', 'e', 'q',
- 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0', '.', '1', ',', 'N', 'C', 'B', 'I', ':',
- 't', 'b', 'l', ':', 'n', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', '{',
- 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l',
- 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'Q', 'U', 'A', 'L',
- 'I', 'T', 'Y', ' ', '=', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'l', 'o',
- 'g', '_', 'o', 'd', 'd', 's', ';', 'U', '8', ' ', 'r', 'e', 'a', 'd', '_', 'n', 'd',
- 'e', 'c', 'o', 'd', 'e', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l',
- 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ',', 'U', '8', '>', 'm',
- 'a', 'p', '#', '1', '<', '-', '6', ',', '4', '>', '(', 'o', 'u', 't', '_', 'q', 'u',
- 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ',', 'r', 'e', 'a', 'd', '_',
- 'u', 'n', 'p', 'a', 'c', 'k', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a',
- 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'o', 'u', 't', '_', 'q', 'u',
- 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', '=', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l',
- '2', '_', 'p', 'h', 'r', 'e', 'd', '|', 'N', 'C', 'B', 'I', ':', 'l', 'o', 'g', '_',
- 'o', 'd', 'd', 's', '_', 't', 'o', '_', 'p', 'h', 'r', 'e', 'd', '#', '1', '(', 'o',
- 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ')',
- ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':',
- 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '#',
- '1', '.', '0', '.', '1', '=', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'l', 'o',
- 'g', '_', 'o', 'd', 'd', 's', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_', 'n', 'o',
- 'c', 'o', 'l', '#', '1', '.', '0', '.', '1', '{', 'N', 'C', 'B', 'I', ':', 'q', 'u',
- 'a', 'l', 'i', 't', 'y', ':', 'n', '_', 'e', 'n', 'c', 'o', 'd', 'e', 'd', ':', 'l',
- 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_',
- 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y',
- ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':',
- 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_',
- 'n', 'o', 'c', 'o', 'l', '#', '2', '.', '0', '.', '1', '=', 'I', 'N', 'S', 'D', 'C',
- ':', 't', 'b', 'l', ':', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0',
+ 'd', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', '=',
+ '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u',
+ 'a', 'l', 'i', 't', 'y', ':', 't', 'e', 'x', 't', ':', 'p', 'h', 'r', 'e', 'd', '_',
+ '3', '3', ' ', 'i', 'n', '_', 'q', 'u', 'a', 'l', '_', 't', 'e', 'x', 't', '_', 'p',
+ 'h', 'r', 'e', 'd', '_', '3', '3', '=', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'I',
+ 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 't', 'e', 'x', 't',
+ ':', 'p', 'h', 'r', 'e', 'd', '_', '6', '4', ' ', 'i', 'n', '_', 'q', 'u', 'a', 'l',
+ '_', 't', 'e', 'x', 't', '_', 'p', 'h', 'r', 'e', 'd', '_', '6', '4', '=', 'Q', 'U',
+ 'A', 'L', 'I', 'T', 'Y', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i',
+ 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'i', 'n', '_', 'q', 'u', 'a', 'l', '_',
+ 'p', 'h', 'r', 'e', 'd', '=', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '|', '(', 'I', 'N',
+ 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd',
+ ')', '<', 'B', '8', '>', 'd', 'i', 'f', 'f', '#', '1', '<', '3', '3', '>', '(', 'i',
+ 'n', '_', 'q', 'u', 'a', 'l', '_', 't', 'e', 'x', 't', '_', 'p', 'h', 'r', 'e', 'd',
+ '_', '3', '3', ')', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i',
+ 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ')', '<', 'B', '8', '>', 'd', 'i', 'f', 'f',
+ '#', '1', '<', '6', '4', '>', '(', 'i', 'n', '_', 'q', 'u', 'a', 'l', '_', 't', 'e',
+ 'x', 't', '_', 'p', 'h', 'r', 'e', 'd', '_', '6', '4', ')', ';', 'I', 'N', 'S', 'D',
+ 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'i',
+ 'n', '_', 's', 't', 'a', 't', 's', '_', 'q', 'u', 'a', 'l', '=', 'i', 'n', '_', 'q',
+ 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a',
+ 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'q',
+ 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', '>', 'z', 'i', 'p', '_',
+ 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'Q', 'U', 'A', 'L', 'I',
+ 'T', 'Y', '=', 'i', 'n', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', ';',
+ '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'l',
+ 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_', 'n',
+ 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '1', '=', 'I', 'N', 'S', 'D', 'C', ':',
+ 't', 'b', 'l', ':', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0', '.',
+ '1', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'n', '_', 'e', 'n', 'c', 'o',
+ 'd', 'i', 'n', 'g', '#', '1', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S',
+ 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd',
+ 'd', 's', ' ', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ' ', '=', ' ', 'o', 'u', 't', '_',
+ 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ';', 'U', '8', ' ',
+ 'r', 'e', 'a', 'd', '_', 'n', 'd', 'e', 'c', 'o', 'd', 'e', '=', '<', 'I', 'N', 'S',
+ 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd',
+ 'd', 's', ',', 'U', '8', '>', 'm', 'a', 'p', '#', '1', '<', '-', '6', ',', '4', '>',
+ '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd',
+ 's', ',', 'r', 'e', 'a', 'd', '_', 'u', 'n', 'p', 'a', 'c', 'k', ')', ';', 'I', 'N',
+ 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd',
+ ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', '=', 'o',
+ 'u', 't', '_', 'q', 'u', 'a', 'l', '2', '_', 'p', 'h', 'r', 'e', 'd', '|', 'N', 'C',
+ 'B', 'I', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 't', 'o', '_', 'p', 'h',
+ 'r', 'e', 'd', '#', '1', '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'l', 'o',
+ 'g', '_', 'o', 'd', 'd', 's', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C',
+ 'B', 'I', ':', 't', 'b', 'l', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 'q',
+ 'u', 'a', 'l', 'i', 't', 'y', '#', '1', '.', '0', '.', '1', '=', 'N', 'C', 'B', 'I',
+ ':', 't', 'b', 'l', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 'q', 'u', 'a',
+ 'l', 'i', 't', 'y', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '1', '{',
+ 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'n', '_', 'e', 'n',
+ 'c', 'o', 'd', 'e', 'd', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'o', 'u',
+ 't', '_', 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '=', '.',
+ 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C',
+ 'B', 'I', ':', 't', 'b', 'l', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 'q',
+ 'u', 'a', 'l', 'i', 't', 'y', '_', 'n', 'o', 'c', 'o', 'l', '#', '2', '.', '0', '.',
+ '1', '=', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l', ':', 's', 'e', 'q', 'u', 'e',
+ 'n', 'c', 'e', '#', '1', '.', '0', '.', '1', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
+ 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g',
+ '_', 'o', 'd', 'd', 's', ' ', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ' ', '=', ' ', 'o',
+ 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ';',
+ 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r',
+ 'e', 'd', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd',
+ '=', 'N', 'C', 'B', 'I', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 't', 'o',
+ '_', 'p', 'h', 'r', 'e', 'd', '#', '1', '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l',
+ '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ')', ';', '}', 't', 'a', 'b', 'l', 'e',
+ ' ', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd',
+ 's', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '#', '2', '.', '0', '.', '4', '=', 'N',
+ 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_',
+ 'q', 'u', 'a', 'l', 'i', 't', 'y', '_', 'n', 'o', 'c', 'o', 'l', '#', '2', '.', '0',
'.', '1', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'q',
- 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'Q',
- 'U', 'A', 'L', 'I', 'T', 'Y', ' ', '=', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l',
- '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q',
- 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'o', 'u', 't', '_',
- 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', '=', 'N', 'C', 'B', 'I', ':', 'l',
- 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 't', 'o', '_', 'p', 'h', 'r', 'e', 'd', '#',
- '1', '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd',
- 'd', 's', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 't',
- 'b', 'l', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 'q', 'u', 'a', 'l', 'i',
- 't', 'y', '#', '2', '.', '0', '.', '4', '=', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l',
- ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y',
- '_', 'n', 'o', 'c', 'o', 'l', '#', '2', '.', '0', '.', '1', '{', 'c', 'o', 'l', 'u',
- 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':',
- 't', 'e', 'x', 't', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', '6', '4', ' ',
- 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ' ', '=', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a',
- 'l', '_', 't', 'e', 'x', 't', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', '6',
- '4', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':',
- 't', 'e', 'x', 't', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', '6', '4', ')',
- '<', 'B', '8', '>', 's', 'u', 'm', '#', '1', '<', '6', '4', '>', '(', 'o', 'u', 't',
- '_', 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ')', ';', 'I',
+ 'u', 'a', 'l', 'i', 't', 'y', ':', 't', 'e', 'x', 't', ':', 'l', 'o', 'g', '_', 'o',
+ 'd', 'd', 's', '_', '6', '4', ' ', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ' ', '=', ' ',
+ 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 't', 'e', 'x', 't', '_', 'l', 'o', 'g',
+ '_', 'o', 'd', 'd', 's', '_', '6', '4', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'q',
+ 'u', 'a', 'l', 'i', 't', 'y', ':', 't', 'e', 'x', 't', ':', 'l', 'o', 'g', '_', 'o',
+ 'd', 'd', 's', '_', '6', '4', ')', '<', 'B', '8', '>', 's', 'u', 'm', '#', '1', '<',
+ '6', '4', '>', '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g', '_',
+ 'o', 'd', 'd', 's', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i',
+ 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'o', 'u', 't', '_', 'q',
+ 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '=', '.', 'Q', 'U', 'A',
+ 'L', 'I', 'T', 'Y', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't',
+ 'y', ':', 't', 'e', 'x', 't', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', '6',
+ '4', ' ', 'i', 'n', '_', 'q', 'u', 'a', 'l', '_', 't', 'e', 'x', 't', '_', 'l', 'o',
+ 'g', '_', 'o', 'd', 'd', 's', '_', '6', '4', '=', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y',
+ ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o',
+ 'g', '_', 'o', 'd', 'd', 's', ' ', 'i', 'n', '_', 'q', 'u', 'a', 'l', '_', 'l', 'o',
+ 'g', '_', 'o', 'd', 'd', 's', '=', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '|', '(', 'I',
'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_',
- 'o', 'd', 'd', 's', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g',
- '_', 'o', 'd', 'd', 's', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'I', 'N',
- 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 't', 'e', 'x', 't', ':',
- 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', '6', '4', ' ', 'i', 'n', '_', 'q', 'u',
- 'a', 'l', '_', 't', 'e', 'x', 't', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_',
- '6', '4', '=', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'I', 'N', 'S', 'D', 'C', ':',
- 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ',
- 'i', 'n', '_', 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '=',
- 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u',
- 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ')', '<', 'B',
- '8', '>', 'd', 'i', 'f', 'f', '#', '1', '<', '6', '4', '>', '(', 'i', 'n', '_', 'q',
- 'u', 'a', 'l', '_', 't', 'e', 'x', 't', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's',
- '_', '6', '4', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't',
- 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'i', 'n', '_', 's', 't', 'a',
- 't', 's', '_', 'q', 'u', 'a', 'l', '=', 'i', 'n', '_', 'q', 'u', 'a', 'l', '_', 'l',
- 'o', 'g', '_', 'o', 'd', 'd', 's', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
- 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a',
- 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '>', 'z', 'i', 'p',
- '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'Q', 'U', 'A', 'L',
- 'I', 'T', 'Y', '=', 'i', 'n', '_', 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o',
- 'd', 'd', 's', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'c', 'o', 'o', 'r', 'd', '#',
- '1', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's',
- 'p', 'o', 't', 'c', 'o', 'o', 'r', 'd', '#', '1', '{', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'x', '_', 'c',
- 'o', 'o', 'r', 'd', '=', '.', 'X', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
- 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'y', '_', 'c', 'o', 'o', 'r',
- 'd', '=', '.', 'Y', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
- 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 't', '_', 'c', 'o', 'o', 'r', 'd', '=', '.',
- 'T', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l',
- ' ', 'o', 'u', 't', '_', 'l', '_', 'c', 'o', 'o', 'r', 'd', '=', '.', 'L', ';', 'p',
- 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I',
- 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', '>', 'i', 'z',
- 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'X', '=',
- 'i', 'n', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', '|', 'i', 'n', '_', 'n', 'a', 'm',
- 'e', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a',
- 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c',
- 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'Y', '=', 'i', 'n', '_', 'y', '_', 'c',
- 'o', 'o', 'r', 'd', '|', 'i', 'n', '_', 'n', 'a', 'm', 'e', '_', 'y', '_', 'c', 'o',
- 'o', 'r', 'd', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u',
- 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v',
- 'a', 'l', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#',
- '1', ' ', '.', 'T', '=', 'i', 'n', '_', 't', '_', 'c', 'o', 'o', 'r', 'd', '|', 'i',
- 'n', '_', 'n', 'a', 'm', 'e', '_', 't', '_', 'c', 'o', 'o', 'r', 'd', ';', 'p', 'h',
+ 'o', 'd', 'd', 's', ')', '<', 'B', '8', '>', 'd', 'i', 'f', 'f', '#', '1', '<', '6',
+ '4', '>', '(', 'i', 'n', '_', 'q', 'u', 'a', 'l', '_', 't', 'e', 'x', 't', '_', 'l',
+ 'o', 'g', '_', 'o', 'd', 'd', 's', '_', '6', '4', ')', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's',
+ ' ', 'i', 'n', '_', 's', 't', 'a', 't', 's', '_', 'q', 'u', 'a', 'l', '=', 'i', 'n',
+ '_', 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ';', 'p', 'h',
'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', '>', 'i', 'z', 'i',
- 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'L', '=', 'i',
- 'n', '_', 'l', '_', 'c', 'o', 'o', 'r', 'd', '|', 'i', 'n', '_', 'n', 'a', 'm', 'e',
- '_', 'l', '_', 'c', 'o', 'o', 'r', 'd', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'k', 'e', 'y', 'n',
- 'a', 'm', 'e', '#', '1', '.', '0', '.', '1', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S',
- 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'n', 'a', 'm', 'e', '#', '1',
- '.', '0', '.', '1', '{', 'a', 's', 'c', 'i', 'i', ' ', 'o', 'u', 't', '_', 's', 'k',
- 'e', 'y', '=', '(', 'a', 's', 'c', 'i', 'i', ')', 'i', 'd', 'x', ':', 't', 'e', 'x',
- 't', ':', 'p', 'r', 'o', 'j', 'e', 'c', 't', '#', '1', '<', '\'', 's', 'k', 'e',
- 'y', '\'', '>', '(', ')', ';', 'a', 's', 'c', 'i', 'i', ' ', 'o', 'u', 't', '_',
- 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '=', 'r', 'e', 'w', 'r', 'i', 't', 't',
- 'e', 'n', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '|', 'o', 'u', 't', '_',
- 's', 'k', 'e', 'y', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p',
- 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', ' ', 's', 'p', 'o', 't',
- '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C',
- ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u',
- 'n', 'd', ')', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'l', 'o', 'o', 'k', 'u',
- 'p', '#', '1', '<', '\'', 's', 'k', 'e', 'y', '\'', ',', '\'', 'Q', 'U', 'E', 'R',
- 'Y', '_', 'B', 'Y', '_', 'N', 'A', 'M', 'E', '\'', ',', '1', '>', '(', 'o', 'u',
- 't', '_', 's', 'l', 'x', '_', 'p', 'r', 'e', 'f', 'i', 'x', ')', '|', '(', 'I', 'N',
- 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_',
- 'f', 'o', 'u', 'n', 'd', ')', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'l', 'o',
- 'o', 'k', 'u', 'p', '#', '1', '<', '\'', 's', 'k', 'e', 'y', '\'', ',', '\'', 'Q',
- 'U', 'E', 'R', 'Y', '_', 'B', 'Y', '_', 'N', 'A', 'M', 'E', '\'', ',', '0', '>',
- '(', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 't', 'b', 'l', ':', 's', 'k', 'e', 'y', 'n', 'a', 'm', 'e', '_', 'n', 'o',
- 'c', 'o', 'l', '#', '2', '.', '0', '.', '1', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S',
- 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'n', 'a', 'm', 'e', '#', '1',
- '.', '0', '.', '1', '{', 'a', 's', 'c', 'i', 'i', ' ', 'o', 'u', 't', '_', 'n', 'a',
- 'm', 'e', '_', 'f', 'm', 't', '=', '(', 'a', 's', 'c', 'i', 'i', ')', 'i', 'd', 'x',
- ':', 't', 'e', 'x', 't', ':', 'p', 'r', 'o', 'j', 'e', 'c', 't', '#', '1', '<', '\'',
- 's', 'k', 'e', 'y', '\'', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S',
- 'R', 'A', ':', 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd',
- ' ', 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', '=', '(',
+ 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o',
+ 'd', 'd', 's', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#',
+ '1', ' ', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '=', 'i', 'n', '_', 'q', 'u', 'a',
+ 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ';', '}', 't', 'a', 'b', 'l', 'e',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o',
+ 't', 'c', 'o', 'o', 'r', 'd', '#', '1', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R',
+ 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'c', 'o', 'o', 'r', 'd', '#', '1',
+ '{', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ',
+ 'o', 'u', 't', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', '=', '.', 'X', ';', 'I', 'N',
+ 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't',
+ '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', '=', '.', 'Y', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 't', '_',
+ 'c', 'o', 'o', 'r', 'd', '=', '.', 'T', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
+ 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'l', '_', 'c', 'o', 'o',
+ 'r', 'd', '=', '.', 'L', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'v', 'a', 'l', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n',
+ 'g', '#', '1', ' ', '.', 'X', '=', 'i', 'n', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd',
+ '|', 'i', 'n', '_', 'n', 'a', 'm', 'e', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', ';',
+ 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<',
+ 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', '>', 'i',
+ 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'Y',
+ '=', 'i', 'n', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', '|', 'i', 'n', '_', 'n', 'a',
+ 'm', 'e', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', ';', 'p', 'h', 'y', 's', 'i', 'c',
+ 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':',
+ 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n',
+ 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'T', '=', 'i', 'n', '_', 't', '_',
+ 'c', 'o', 'o', 'r', 'd', '|', 'i', 'n', '_', 'n', 'a', 'm', 'e', '_', 't', '_', 'c',
+ 'o', 'o', 'r', 'd', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l',
+ 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
+ 'v', 'a', 'l', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g',
+ '#', '1', ' ', '.', 'L', '=', 'i', 'n', '_', 'l', '_', 'c', 'o', 'o', 'r', 'd', '|',
+ 'i', 'n', '_', 'n', 'a', 'm', 'e', '_', 'l', '_', 'c', 'o', 'o', 'r', 'd', ';', '}',
+ 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b',
+ 'l', ':', 's', 'k', 'e', 'y', 'n', 'a', 'm', 'e', '#', '1', '.', '0', '.', '1', '=',
+ 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o',
+ 't', 'n', 'a', 'm', 'e', '#', '1', '.', '0', '.', '1', '{', 'a', 's', 'c', 'i', 'i',
+ ' ', 'o', 'u', 't', '_', 's', 'k', 'e', 'y', '=', '(', 'a', 's', 'c', 'i', 'i', ')',
+ 'i', 'd', 'x', ':', 't', 'e', 'x', 't', ':', 'p', 'r', 'o', 'j', 'e', 'c', 't', '#',
+ '1', '<', '\'', 's', 'k', 'e', 'y', '\'', '>', '(', ')', ';', 'a', 's', 'c', 'i',
+ 'i', ' ', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '=', 'r',
+ 'e', 'w', 'r', 'i', 't', 't', 'e', 'n', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm',
+ 'e', '|', 'o', 'u', 't', '_', 's', 'k', 'e', 'y', ';', 'I', 'N', 'S', 'D', 'C', ':',
+ 'S', 'R', 'A', ':', 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n',
+ 'd', ' ', 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', '=',
+ '(', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', '_', 'i',
+ 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', ')', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', 'l', 'o', 'o', 'k', 'u', 'p', '#', '1', '<', '\'', 's', 'k', 'e', 'y', '\'',
+ ',', '\'', 'Q', 'U', 'E', 'R', 'Y', '_', 'B', 'Y', '_', 'N', 'A', 'M', 'E', '\'',
+ ',', '1', '>', '(', 'o', 'u', 't', '_', 's', 'l', 'x', '_', 'p', 'r', 'e', 'f', 'i',
+ 'x', ')', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o',
+ 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', ')', 'N', 'C', 'B', 'I', ':',
+ 'S', 'R', 'A', ':', 'l', 'o', 'o', 'k', 'u', 'p', '#', '1', '<', '\'', 's', 'k',
+ 'e', 'y', '\'', ',', '\'', 'Q', 'U', 'E', 'R', 'Y', '_', 'B', 'Y', '_', 'N', 'A',
+ 'M', 'E', '\'', ',', '0', '>', '(', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'k', 'e', 'y',
+ 'n', 'a', 'm', 'e', '_', 'n', 'o', 'c', 'o', 'l', '#', '2', '.', '0', '.', '1', '=',
+ 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o',
+ 't', 'n', 'a', 'm', 'e', '#', '1', '.', '0', '.', '1', '{', 'a', 's', 'c', 'i', 'i',
+ ' ', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', '_', 'f', 'm', 't', '=', '(', 'a', 's',
+ 'c', 'i', 'i', ')', 'i', 'd', 'x', ':', 't', 'e', 'x', 't', ':', 'p', 'r', 'o', 'j',
+ 'e', 'c', 't', '#', '1', '<', '\'', 's', 'k', 'e', 'y', '\'', '>', '(', ')', ';',
'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', '_', 'i', 'd',
- 's', '_', 'f', 'o', 'u', 'n', 'd', ')', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'l', 'o', 'o', 'k', 'u', 'p', '#', '1', '<', '\'', 's', 'k', 'e', 'y', '\'', ',',
- '\'', 'Q', 'U', 'E', 'R', 'Y', '_', 'B', 'Y', '_', 'N', 'A', 'M', 'E', '\'', ',',
- '2', '>', '(', 'o', 'u', 't', '_', 's', 'l', 'x', '_', 'p', 'r', 'e', 'f', 'i', 'x',
- ')', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't',
- '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', ')', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 'l', 'o', 'o', 'k', 'u', 'p', '#', '1', '<', '\'', 's', 'k', 'e',
- 'y', '\'', ',', '\'', 'Q', 'U', 'E', 'R', 'Y', '_', 'B', 'Y', '_', 'N', 'A', 'M',
- 'E', '\'', ',', '2', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'x', '_', 'c', 'o', 'o',
- 'r', 'd', '=', 'c', 'a', 's', 't', '#', '1', '(', '.', 'X', ')', ';', 'I', 'N', 'S',
- 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_',
- 'y', '_', 'c', 'o', 'o', 'r', 'd', '=', 'c', 'a', 's', 't', '#', '1', '(', '.', 'Y',
- ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', 't', 'b', 'l', ':', 's', 'k', 'e', 'y', 'n', 'a', 'm', 'e', '#', '2', '.', '0',
- '.', '1', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's',
- 'k', 'e', 'y', 'n', 'a', 'm', 'e', '_', 'n', 'o', 'c', 'o', 'l', '#', '2', '.', '0',
- '.', '1', '{', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm',
- 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a',
- 'l', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1',
- ' ', '.', 'X', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r',
- 'a', 'c', 't', '_', 'n', 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<',
- '4', '>', '(', 'N', 'A', 'M', 'E', ',', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'n',
- 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l',
+ 's', '_', 'f', 'o', 'u', 'n', 'd', ' ', 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_',
+ 'f', 'o', 'u', 'n', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':',
+ 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', ')', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 'l', 'o', 'o', 'k', 'u', 'p', '#', '1', '<', '\'',
+ 's', 'k', 'e', 'y', '\'', ',', '\'', 'Q', 'U', 'E', 'R', 'Y', '_', 'B', 'Y', '_',
+ 'N', 'A', 'M', 'E', '\'', ',', '2', '>', '(', 'o', 'u', 't', '_', 's', 'l', 'x',
+ '_', 'p', 'r', 'e', 'f', 'i', 'x', ')', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'S',
+ 'R', 'A', ':', 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd',
+ ')', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'l', 'o', 'o', 'k', 'u', 'p', '#',
+ '1', '<', '\'', 's', 'k', 'e', 'y', '\'', ',', '\'', 'Q', 'U', 'E', 'R', 'Y', '_',
+ 'B', 'Y', '_', 'N', 'A', 'M', 'E', '\'', ',', '2', '>', '(', ')', ';', 'I', 'N',
+ 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't',
+ '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', '=', 'c', 'a', 's', 't', '#', '1', '(', '.',
+ 'X', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a',
+ 'l', ' ', 'o', 'u', 't', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', '=', 'c', 'a', 's',
+ 't', '#', '1', '(', '.', 'Y', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'k', 'e', 'y', 'n', 'a',
+ 'm', 'e', '#', '2', '.', '0', '.', '1', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', 't', 'b', 'l', ':', 's', 'k', 'e', 'y', 'n', 'a', 'm', 'e', '_', 'n', 'o', 'c',
+ 'o', 'l', '#', '2', '.', '0', '.', '1', '{', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l',
' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
'o', 'r', 'd', ':', 'v', 'a', 'l', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o',
- 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'Y', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'X', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R',
'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n', 'a', 'm', 'e', '_', 'c', 'o',
- 'o', 'r', 'd', '#', '1', '<', '5', '>', '(', 'N', 'A', 'M', 'E', ',', 'i', 'n', '_',
- 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', '}', 't',
- 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l',
- ':', 's', 'k', 'e', 'y', 'n', 'a', 'm', 'e', '#', '3', '.', '0', '.', '1', '=', 'I',
- 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't',
- 'n', 'a', 'm', 'e', '#', '1', '.', '0', '.', '1', ',', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'c', 'o', 'o', 'r', 'd', '#',
- '1', '{', 'a', 's', 'c', 'i', 'i', ' ', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_',
- 'n', 'a', 'm', 'e', '=', '.', 'S', 'P', 'O', 'T', '_', 'N', 'A', 'M', 'E', ';', 'a',
- 's', 'c', 'i', 'i', ' ', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', '_', 'f', 'm', 't',
- '=', '(', 'a', 's', 'c', 'i', 'i', ')', 'i', 'd', 'x', ':', 't', 'e', 'x', 't', ':',
- 'p', 'r', 'o', 'j', 'e', 'c', 't', '#', '1', '<', '\'', 's', 'k', 'e', 'y', '\'',
- '>', '(', '.', 'N', 'A', 'M', 'E', '_', 'F', 'M', 'T', ')', ';', 'I', 'N', 'S', 'D',
- 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o',
- 'u', 'n', 'd', ' ', 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n',
- 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't',
- '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', ')', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 'l', 'o', 'o', 'k', 'u', 'p', '#', '1', '<', '\'', 's', 'k', 'e',
- 'y', '\'', ',', '\'', 'Q', 'U', 'E', 'R', 'Y', '_', 'B', 'Y', '_', 'N', 'A', 'M',
- 'E', '\'', ',', '2', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'i', 'n', '_', 'n', 'a', 'm', 'e', '_', 'x',
- '_', 'c', 'o', 'o', 'r', 'd', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e',
- 'x', 't', 'r', 'a', 'c', 't', '_', 'n', 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd',
- '#', '1', '<', '4', '>', '(', 'N', 'A', 'M', 'E', ',', 'i', 'n', '_', 's', 'p', 'o',
- 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'i', 'n', '_', 'n', 'a', 'm',
- 'e', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n', 'a', 'm', 'e', '_', 'c', 'o',
- 'o', 'r', 'd', '#', '1', '<', '5', '>', '(', 'N', 'A', 'M', 'E', ',', 'i', 'n', '_',
- 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'i', 'n', '_',
- 'n', 'a', 'm', 'e', '_', 't', '_', 'c', 'o', 'o', 'r', 'd', '=', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n', 'a', 'm', 'e',
- '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '6', '>', '(', 'N', 'A', 'M', 'E', ',',
- 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')',
- ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ',
- 'i', 'n', '_', 'n', 'a', 'm', 'e', '_', 'l', '_', 'c', 'o', 'o', 'r', 'd', '=', 'N',
+ 'o', 'r', 'd', '#', '1', '<', '4', '>', '(', 'N', 'A', 'M', 'E', ',', 'i', 'n', '_',
+ 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', 'p', 'h',
+ 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N',
+ 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', '>', 'i', 'z', 'i',
+ 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'Y', '=', 'N',
'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n',
- 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '7', '>', '(', 'N', 'A',
+ 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '5', '>', '(', 'N', 'A',
'M', 'E', ',', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't',
- 'o', 'k', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u',
- 'm', 'n', ' ', '<', 'a', 's', 'c', 'i', 'i', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c',
- 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'S', 'P', 'O', 'T', '_', 'N', 'A', 'M',
- 'E', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c',
- 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', 'N', 'A', 'M',
+ 'o', 'k', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'k', 'e', 'y', 'n', 'a', 'm', 'e', '#', '3',
+ '.', '0', '.', '1', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b',
+ 'l', ':', 's', 'p', 'o', 't', 'n', 'a', 'm', 'e', '#', '1', '.', '0', '.', '1', ',',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't',
+ 'c', 'o', 'o', 'r', 'd', '#', '1', '{', 'a', 's', 'c', 'i', 'i', ' ', 'o', 'u', 't',
+ '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '=', '.', 'S', 'P', 'O', 'T', '_',
+ 'N', 'A', 'M', 'E', ';', 'a', 's', 'c', 'i', 'i', ' ', 'o', 'u', 't', '_', 'n', 'a',
+ 'm', 'e', '_', 'f', 'm', 't', '=', '(', 'a', 's', 'c', 'i', 'i', ')', 'i', 'd', 'x',
+ ':', 't', 'e', 'x', 't', ':', 'p', 'r', 'o', 'j', 'e', 'c', 't', '#', '1', '<', '\'',
+ 's', 'k', 'e', 'y', '\'', '>', '(', '.', 'N', 'A', 'M', 'E', '_', 'F', 'M', 'T',
+ ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', '_',
+ 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', ' ', 's', 'p', 'o', 't', '_', 'i', 'd',
+ 's', '_', 'f', 'o', 'u', 'n', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R',
+ 'A', ':', 's', 'p', 'o', 't', '_', 'i', 'd', 's', '_', 'f', 'o', 'u', 'n', 'd', ')',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'l', 'o', 'o', 'k', 'u', 'p', '#', '1',
+ '<', '\'', 's', 'k', 'e', 'y', '\'', ',', '\'', 'Q', 'U', 'E', 'R', 'Y', '_', 'B',
+ 'Y', '_', 'N', 'A', 'M', 'E', '\'', ',', '2', '>', '(', ')', ';', 'I', 'N', 'S',
+ 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'i', 'n', '_', 'n',
+ 'a', 'm', 'e', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', '=', 'N', 'C', 'B', 'I', ':',
+ 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n', 'a', 'm', 'e', '_',
+ 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '4', '>', '(', 'N', 'A', 'M', 'E', ',', 'i',
+ 'n', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';',
+ 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'i',
+ 'n', '_', 'n', 'a', 'm', 'e', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', '=', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n', 'a',
+ 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '5', '>', '(', 'N', 'A', 'M',
'E', ',', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o',
- 'k', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm',
- 'n', ' ', '<', 'a', 's', 'c', 'i', 'i', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o',
- 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'N', 'A', 'M', 'E', '_', 'F', 'M', 'T', '=',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_',
- 'n', 'a', 'm', 'e', '_', 'f', 'm', 't', '#', '1', '<', '\'', 's', 'k', 'e', 'y',
- '\'', '>', '(', 'N', 'A', 'M', 'E', ',', 'i', 'n', '_', 's', 'p', 'o', 't', '_',
- 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 't', 'a', 't',
- 's', '#', '1', '.', '2', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't',
- 'b', 'l', ':', 's', 't', 'a', 't', 's', '#', '1', '.', '1', ',', 'I', 'N', 'S', 'D',
- 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#', '1', '.', '0',
- '.', '3', '{', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't',
- 'i', 'd', '_', 't', ' ', 'm', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'i', 'd', '=',
- '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', 'i', 'd',
- '_', 't', '>', 'm', 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<', '\'',
- 'S', 'T', 'A', 'T', 'S', '/', 'T', 'A', 'B', 'L', 'E', '/', 'S', 'P', 'O', 'T', '_',
- 'M', 'I', 'N', '\'', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R',
- 'A', ':', 's', 'p', 'o', 't', 'i', 'd', '_', 't', ' ', 'm', 'a', 'x', '_', 's', 'p',
- 'o', 't', '_', 'i', 'd', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':',
- 's', 'p', 'o', 't', 'i', 'd', '_', 't', '>', 'm', 'e', 't', 'a', ':', 'v', 'a', 'l',
- 'u', 'e', '#', '1', '<', '\'', 'S', 'T', 'A', 'T', 'S', '/', 'T', 'A', 'B', 'L',
- 'E', '/', 'S', 'P', 'O', 'T', '_', 'M', 'A', 'X', '\'', '>', '(', ')', ';', 'U',
- '6', '4', ' ', 's', 'p', 'o', 't', '_', 'c', 'o', 'u', 'n', 't', '=', '<', 'U', '6',
- '4', '>', 'm', 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<', '\'',
- 'S', 'T', 'A', 'T', 'S', '/', 'T', 'A', 'B', 'L', 'E', '/', 'S', 'P', 'O', 'T', '_',
- 'C', 'O', 'U', 'N', 'T', '\'', '>', '(', ')', ';', 'U', '6', '4', ' ', 'b', 'a',
- 's', 'e', '_', 'c', 'o', 'u', 'n', 't', '=', '<', 'U', '6', '4', '>', 'm', 'e', 't',
+ 'k', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a',
+ 'l', ' ', 'i', 'n', '_', 'n', 'a', 'm', 'e', '_', 't', '_', 'c', 'o', 'o', 'r', 'd',
+ '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't',
+ '_', 'n', 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '6', '>', '(',
+ 'N', 'A', 'M', 'E', ',', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e',
+ '_', 't', 'o', 'k', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'v', 'a', 'l', ' ', 'i', 'n', '_', 'n', 'a', 'm', 'e', '_', 'l', '_', 'c', 'o',
+ 'o', 'r', 'd', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r',
+ 'a', 'c', 't', '_', 'n', 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<',
+ '7', '>', '(', 'N', 'A', 'M', 'E', ',', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'n',
+ 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l',
+ ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'a', 's', 'c', 'i', 'i', '>', 'z', 'i',
+ 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'S', 'P', 'O',
+ 'T', '_', 'N', 'A', 'M', 'E', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e',
+ 'x', 't', 'r', 'a', 'c', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#',
+ '1', '(', 'N', 'A', 'M', 'E', ',', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'n', 'a',
+ 'm', 'e', '_', 't', 'o', 'k', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
+ 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'a', 's', 'c', 'i', 'i', '>', 'z', 'i', 'p',
+ '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'N', 'A', 'M', 'E',
+ '_', 'F', 'M', 'T', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't',
+ 'r', 'a', 'c', 't', '_', 'n', 'a', 'm', 'e', '_', 'f', 'm', 't', '#', '1', '<', '\'',
+ 's', 'k', 'e', 'y', '\'', '>', '(', 'N', 'A', 'M', 'E', ',', 'i', 'n', '_', 's',
+ 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', '}', 't', 'a',
+ 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':',
+ 's', 't', 'a', 't', 's', '#', '1', '.', '2', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S',
+ 'R', 'A', ':', 't', 'b', 'l', ':', 's', 't', 'a', 't', 's', '#', '1', '.', '1', ',',
+ 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a',
+ '#', '1', '.', '0', '.', '3', '{', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':',
+ 's', 'p', 'o', 't', 'i', 'd', '_', 't', ' ', 'm', 'i', 'n', '_', 's', 'p', 'o', 't',
+ '_', 'i', 'd', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p',
+ 'o', 't', 'i', 'd', '_', 't', '>', 'm', 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e',
+ '#', '1', '<', '\'', 'S', 'T', 'A', 'T', 'S', '/', 'T', 'A', 'B', 'L', 'E', '/',
+ 'S', 'P', 'O', 'T', '_', 'M', 'I', 'N', '\'', '>', '(', ')', ';', 'I', 'N', 'S',
+ 'D', 'C', ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', 'i', 'd', '_', 't', ' ', 'm',
+ 'a', 'x', '_', 's', 'p', 'o', 't', '_', 'i', 'd', '=', '<', 'I', 'N', 'S', 'D', 'C',
+ ':', 'S', 'R', 'A', ':', 's', 'p', 'o', 't', 'i', 'd', '_', 't', '>', 'm', 'e', 't',
'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<', '\'', 'S', 'T', 'A', 'T', 'S',
- '/', 'T', 'A', 'B', 'L', 'E', '/', 'B', 'A', 'S', 'E', '_', 'C', 'O', 'U', 'N', 'T',
- '\'', '>', '(', ')', ';', 'U', '6', '4', ' ', 'b', 'i', 'o', '_', 'b', 'a', 's',
- 'e', '_', 'c', 'o', 'u', 'n', 't', '=', '<', 'U', '6', '4', '>', 'm', 'e', 't', 'a',
- ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<', '\'', 'S', 'T', 'A', 'T', 'S', '/',
- 'T', 'A', 'B', 'L', 'E', '/', 'B', 'I', 'O', '_', 'B', 'A', 'S', 'E', '_', 'C', 'O',
- 'U', 'N', 'T', '\'', '>', '(', ')', ';', 'U', '6', '4', ' ', 'c', 'm', 'p', '_',
- 'b', 'a', 's', 'e', '_', 'c', 'o', 'u', 'n', 't', '=', '<', 'U', '6', '4', '>', 'm',
- 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<', '\'', 'S', 'T', 'A',
- 'T', 'S', '/', 'T', 'A', 'B', 'L', 'E', '/', 'C', 'M', 'P', '_', 'B', 'A', 'S', 'E',
- '_', 'C', 'O', 'U', 'N', 'T', '\'', '>', '(', ')', '|', 'b', 'a', 's', 'e', '_',
- 'c', 'o', 'u', 'n', 't', ';', 't', 'r', 'i', 'g', 'g', 'e', 'r', ' ', 'm', 'e', 't',
- 'a', '_', 's', 't', 'a', 't', 's', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 's', 't', 'a', 't', 's', '_', 't', 'r', 'i', 'g', 'g', 'e', 'r', '#', '1', '(', 'i',
- 'n', '_', 's', 't', 'a', 't', 's', '_', 'b', 'i', 'n', ',', 'i', 'n', '_', 'r', 'e',
- 'a', 'd', '_', 'l', 'e', 'n', ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y',
- 'p', 'e', ',', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'g', 'r', 'o', 'u', 'p', ')',
- '|', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 't', 'a', 't', 's', '_', 't',
- 'r', 'i', 'g', 'g', 'e', 'r', '#', '1', '(', 'i', 'n', '_', 's', 't', 'a', 't', 's',
- '_', 'b', 'i', 'n', ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',',
- 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ')', '|', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'c', 'm', 'p', '_', 's', 't', 'a', 't', 's', '_', 't',
- 'r', 'i', 'g', 'g', 'e', 'r', '#', '1', '(', 'i', 'n', '_', 'c', 'm', 'p', '_', 's',
- 't', 'a', 't', 's', '_', 'b', 'i', 'n', ',', 'i', 'n', '_', 's', 't', 'a', 't', 's',
- '_', 'q', 'u', 'a', 'l', ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n',
- ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ',', 'i', 'n', '_',
- 's', 'p', 'o', 't', '_', 'g', 'r', 'o', 'u', 'p', ')', '|', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'c', 'm', 'p', '_', 's', 't', 'a', 't', 's', '_', 't', 'r', 'i',
- 'g', 'g', 'e', 'r', '#', '1', '(', 'i', 'n', '_', 'c', 'm', 'p', '_', 's', 't', 'a',
- 't', 's', '_', 'b', 'i', 'n', ',', 'i', 'n', '_', 's', 't', 'a', 't', 's', '_', 'q',
- 'u', 'a', 'l', ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',', 'i',
- 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ')', '|', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 'c', 'm', 'p', 'f', '_', 's', 't', 'a', 't', 's', '_', 't',
- 'r', 'i', 'g', 'g', 'e', 'r', '#', '1', '(', 'i', 'n', '_', 'c', 'm', 'p', '_', 's',
- 't', 'a', 't', 's', '_', 'b', 'i', 'n', ',', 'i', 'n', '_', 's', 'p', 'o', 't', '_',
- 'l', 'e', 'n', ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',', 'i',
- 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ',', 'i', 'n', '_', 's', 'p',
- 'o', 't', '_', 'g', 'r', 'o', 'u', 'p', ')', '|', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 'c', 'm', 'p', 'f', '_', 's', 't', 'a', 't', 's', '_', 't', 'r', 'i', 'g',
- 'g', 'e', 'r', '#', '1', '(', 'i', 'n', '_', 'c', 'm', 'p', '_', 's', 't', 'a', 't',
- 's', '_', 'b', 'i', 'n', ',', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n',
- ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',', 'i', 'n', '_', 'r',
- 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ')', ';', 't', 'r', 'i', 'g', 'g', 'e', 'r',
- ' ', 'q', 'u', 'a', 'l', '_', 's', 't', 'a', 't', 's', '=', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'p', 'h', 'r', 'e', 'd', '_', 's', 't', 'a', 't', 's', '_', 't',
- 'r', 'i', 'g', 'g', 'e', 'r', '#', '1', '(', 'i', 'n', '_', 'q', 'u', 'a', 'l', '_',
- 'p', 'h', 'r', 'e', 'd', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'd', 'e', 's',
- 'c', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '2', '=', 'I', 'N', 'S',
- 'D', 'C', ':', 't', 'b', 'l', ':', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1',
- '.', '0', '.', '1', ',', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b',
- 'l', ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '#', '1', '.', '0', '.', '2', '{',
- 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'S', 'e', 'g', 'm', 'e', 'n', 't', ' ', 'L',
- 'A', 'B', 'E', 'L', '_', 'S', 'E', 'G', ' ', '=', ' ', 'o', 'u', 't', '_', 'l', 'a',
- 'b', 'e', 'l', '_', 's', 'e', 'g', '|', 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u',
- 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 'e', 'g', '3', '2', ')', '|', 'c', 'a',
- 's', 't', '#', '1', '(', '_', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's',
- 'e', 'g', '3', '2', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o',
- 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'S', 'e', 'g',
- 'm', 'e', 'n', 't', ' ', 'R', 'E', 'A', 'D', '_', 'S', 'E', 'G', ' ', '=', ' ', 'o',
- 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '|', 'c', 'a', 's', 't', '#',
- '1', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '3', '2', ')',
- '|', 'c', 'a', 's', 't', '#', '1', '(', '_', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd',
- '_', 's', 'e', 'g', '3', '2', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ',
- 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'R',
- 'e', 'a', 'd', 'D', 'e', 's', 'c', ' ', 'R', 'E', 'A', 'D', '_', 'D', 'E', 'S', 'C',
- ' ', '=', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'm', 'a', 'k', 'e', '_',
- 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', '#', '1', '(', 'o', 'u', 't', '_', 'n',
- 'r', 'e', 'a', 'd', 's', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't',
- 'a', 'r', 't', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',',
- 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ',', '_', 'o', 'u',
- 't', '_', 'r', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', ',', 'o', 'u', 't', '_', 'c',
- 's', '_', 'k', 'e', 'y', ',', '_', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_',
- 's', 't', 'a', 'r', 't', ',', '_', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_',
- 'l', 'e', 'n', ',', '_', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', ')', ';', 'r',
- 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', 'S', 'p', 'o', 't', 'D', 'e', 's', 'c', ' ', 'S',
- 'P', 'O', 'T', '_', 'D', 'E', 'S', 'C', ' ', '=', ' ', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 'm', 'a', 'k', 'e', '_', 's', 'p', 'o', 't', '_', 'd', 'e', 's', 'c',
- '#', '1', '(', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ',', 'f', 'i', 'x', 'e', 'd',
- '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ',', 's', 'i', 'g', 'n', 'a', 'l', '_',
- 'l', 'e', 'n', ',', 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't', ',', 't', 'r',
- 'i', 'm', '_', 'l', 'e', 'n', ',', 'o', 'u', 't', '_', 'n', 'r', 'e', 'a', 'd', 's',
- ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n',
- ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ',
- 'S', 'I', 'G', 'N', 'A', 'L', '_', 'L', 'E', 'N', ' ', '=', ' ', 's', 'i', 'g', 'n',
- 'a', 'l', '_', 'l', 'e', 'n', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c',
- 'o', 'l', 'u', 'm', 'n', ' ', 'U', '1', '6', ' ', 'S', 'I', 'G', 'N', 'A', 'L', '_',
- 'L', 'E', 'N', ' ', '=', ' ', 'c', 'a', 's', 't', '#', '1', '(', 's', 'i', 'g', 'n',
- 'a', 'l', '_', 'l', 'e', 'n', ')', ';', 'U', '3', '2', ' ', '_', 'o', 'u', 't', '_',
- 'l', 'a', 'b', 'e', 'l', '_', 's', 't', 'a', 'r', 't', 'U', '3', '2', '=', '(', 'U',
- '3', '2', ')', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 't', 'a', 'r',
- 't', ';', 'U', '3', '2', '[', '2', ']', ' ', '_', 'o', 'u', 't', '_', 'l', 'a', 'b',
- 'e', 'l', '_', 's', 'e', 'g', '3', '2', '=', '<', 'U', '3', '2', '>', 'p', 'a', 's',
- 't', 'e', '#', '1', '(', '_', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's',
- 't', 'a', 'r', 't', 'U', '3', '2', ',', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l',
- '_', 'l', 'e', 'n', ')', ';', 'U', '3', '2', ' ', '_', 'o', 'u', 't', '_', 'r', 'e',
- 'a', 'd', '_', 's', 't', 'a', 'r', 't', 'U', '3', '2', '=', '(', 'U', '3', '2', ')',
- 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', ';', 'U', '3',
- '2', '[', '2', ']', ' ', '_', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 'e',
- 'g', '3', '2', '=', '<', 'U', '3', '2', '>', 'p', 'a', 's', 't', 'e', '#', '1', '(',
- '_', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', 'U', '3',
- '2', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ')', ';', 'I',
- 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l',
- 't', 'e', 'r', ' ', '_', 'o', 'u', 't', '_', 'r', 'd', '_', 'f', 'i', 'l', 't', 'e',
- 'r', '=', 'o', 'u', 't', '_', 'r', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', '|', '<',
- 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i',
- 'l', 't', 'e', 'r', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '0', '>', '(', 'o', 'u',
- 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', ')', ';', 'a', 's', 'c',
- 'i', 'i', ' ', '_', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '=', 'o', 'u', 't',
- '_', 'l', 'a', 'b', 'e', 'l', '|', '<', 'a', 's', 'c', 'i', 'i', '>', 'e', 'c', 'h',
- 'o', '#', '1', '<', '\'', '\'', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', '_', 'o', 'u', 't', '_', 'l',
- 'a', 'b', 'e', 'l', '_', 's', 't', 'a', 'r', 't', '=', 'o', 'u', 't', '_', 'l', 'a',
- 'b', 'e', 'l', '_', 's', 't', 'a', 'r', 't', '|', '<', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', '>', 'e', 'c', 'h', 'o', '#', '1',
- '<', '0', '>', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r',
- 't', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e',
- 'n', ' ', '_', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 'l', 'e', 'n', '=',
- 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 'l', 'e', 'n', '|', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', '>', 'e', 'c', 'h',
- 'o', '#', '1', '<', '0', '>', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's',
- 't', 'a', 'r', 't', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c',
- '_', 'n', 'o', 'p', 'h', 'y', 's', '#', '1', '.', '0', '.', '2', '=', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'd', 'e', 's',
- 'c', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '2', '{', 'U', '8', ' ',
- 'o', 'u', 't', '_', 'n', 'r', 'e', 'a', 'd', 's', '=', '.', 'N', 'R', 'E', 'A', 'D',
- 'S', ';', 'a', 's', 'c', 'i', 'i', ' ', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l',
- '=', '.', 'L', 'A', 'B', 'E', 'L', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A',
- ':', 'x', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'o', 'u', 't', '_', 'r',
- 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '=', '.', 'R', 'E', 'A', 'D', '_', 'T', 'Y',
- 'P', 'E', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd',
- '_', 'f', 'i', 'l', 't', 'e', 'r', ' ', 'o', 'u', 't', '_', 'r', 'd', '_', 'f', 'i',
- 'l', 't', 'e', 'r', '=', '.', 'R', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', ';', 'I',
- 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'o',
- 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 't', 'a', 'r', 't', '=', '.', 'L',
- 'A', 'B', 'E', 'L', '_', 'S', 'T', 'A', 'R', 'T', '|', '(', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ')', '<', 'U', '3', '2', '>',
- 'c', 'u', 't', '#', '1', '<', '0', '>', '(', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e',
- 'l', '_', 's', 'e', 'g', '3', '2', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l',
- '_', 'l', 'e', 'n', '=', '.', 'L', 'A', 'B', 'E', 'L', '_', 'L', 'E', 'N', '|', '(',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ')', '<',
- 'U', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '1', '>', '(', 'o', 'u', 't', '_',
- 'l', 'a', 'b', 'e', 'l', '_', 's', 'e', 'g', '3', '2', ')', ';', 'U', '3', '2', '[',
- '2', ']', ' ', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 'e', 'g', '3',
- '2', '=', 'c', 'a', 's', 't', '#', '1', '(', '.', 'L', 'A', 'B', 'E', 'L', '_', 'S',
- 'E', 'G', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z',
- 'e', 'r', 'o', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r',
- 't', '=', '.', 'R', 'E', 'A', 'D', '_', 'S', 'T', 'A', 'R', 'T', '|', '(', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ')', '<', 'U',
- '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '0', '>', '(', 'o', 'u', 't', '_', 'r',
- 'e', 'a', 'd', '_', 's', 'e', 'g', '3', '2', ')', ';', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a',
- 'd', '_', 'l', 'e', 'n', '=', '.', 'R', 'E', 'A', 'D', '_', 'L', 'E', 'N', '|', '(',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ')', '<',
- 'U', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '1', '>', '(', 'o', 'u', 't', '_',
- 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '3', '2', ')', ';', 'U', '3', '2', '[', '2',
- ']', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '3', '2', '=',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'f', 'i', 'x', '_', 'r', 'e', 'a', 'd',
- '_', 's', 'e', 'g', '#', '1', '(', '.', 'R', 'E', 'A', 'D', '_', 'S', 'E', 'G', ',',
- 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't',
- 'd', 'e', 's', 'c', '#', '1', '.', '0', '.', '2', '=', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '_', 'n',
- 'o', 'p', 'h', 'y', 's', '#', '1', '.', '0', '.', '2', '{', 'p', 'h', 'y', 's', 'i',
- 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'U', '8', '>', 'z', 'i',
- 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'N', 'R', 'E',
- 'A', 'D', 'S', '=', 'N', 'R', 'E', 'A', 'D', 'S', ';', 'p', 'h', 'y', 's', 'i', 'c',
- 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'a', 's', 'c', 'i', 'i', '>',
+ '/', 'T', 'A', 'B', 'L', 'E', '/', 'S', 'P', 'O', 'T', '_', 'M', 'A', 'X', '\'',
+ '>', '(', ')', ';', 'U', '6', '4', ' ', 's', 'p', 'o', 't', '_', 'c', 'o', 'u', 'n',
+ 't', '=', '<', 'U', '6', '4', '>', 'm', 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e',
+ '#', '1', '<', '\'', 'S', 'T', 'A', 'T', 'S', '/', 'T', 'A', 'B', 'L', 'E', '/',
+ 'S', 'P', 'O', 'T', '_', 'C', 'O', 'U', 'N', 'T', '\'', '>', '(', ')', ';', 'U',
+ '6', '4', ' ', 'b', 'a', 's', 'e', '_', 'c', 'o', 'u', 'n', 't', '=', '<', 'U', '6',
+ '4', '>', 'm', 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<', '\'',
+ 'S', 'T', 'A', 'T', 'S', '/', 'T', 'A', 'B', 'L', 'E', '/', 'B', 'A', 'S', 'E', '_',
+ 'C', 'O', 'U', 'N', 'T', '\'', '>', '(', ')', ';', 'U', '6', '4', ' ', 'b', 'i',
+ 'o', '_', 'b', 'a', 's', 'e', '_', 'c', 'o', 'u', 'n', 't', '=', '<', 'U', '6', '4',
+ '>', 'm', 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<', '\'', 'S',
+ 'T', 'A', 'T', 'S', '/', 'T', 'A', 'B', 'L', 'E', '/', 'B', 'I', 'O', '_', 'B', 'A',
+ 'S', 'E', '_', 'C', 'O', 'U', 'N', 'T', '\'', '>', '(', ')', ';', 'U', '6', '4',
+ ' ', 'c', 'm', 'p', '_', 'b', 'a', 's', 'e', '_', 'c', 'o', 'u', 'n', 't', '=', '<',
+ 'U', '6', '4', '>', 'm', 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<',
+ '\'', 'S', 'T', 'A', 'T', 'S', '/', 'T', 'A', 'B', 'L', 'E', '/', 'C', 'M', 'P',
+ '_', 'B', 'A', 'S', 'E', '_', 'C', 'O', 'U', 'N', 'T', '\'', '>', '(', ')', '|',
+ 'b', 'a', 's', 'e', '_', 'c', 'o', 'u', 'n', 't', ';', 't', 'r', 'i', 'g', 'g', 'e',
+ 'r', ' ', 'm', 'e', 't', 'a', '_', 's', 't', 'a', 't', 's', '=', 'N', 'C', 'B', 'I',
+ ':', 'S', 'R', 'A', ':', 's', 't', 'a', 't', 's', '_', 't', 'r', 'i', 'g', 'g', 'e',
+ 'r', '#', '1', '(', 'i', 'n', '_', 's', 't', 'a', 't', 's', '_', 'b', 'i', 'n', ',',
+ 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ',', 'i', 'n', '_', 'r', 'e',
+ 'a', 'd', '_', 't', 'y', 'p', 'e', ',', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'g',
+ 'r', 'o', 'u', 'p', ')', '|', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 't',
+ 'a', 't', 's', '_', 't', 'r', 'i', 'g', 'g', 'e', 'r', '#', '1', '(', 'i', 'n', '_',
+ 's', 't', 'a', 't', 's', '_', 'b', 'i', 'n', ',', 'i', 'n', '_', 'r', 'e', 'a', 'd',
+ '_', 'l', 'e', 'n', ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e',
+ ')', '|', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'c', 'm', 'p', '_', 's', 't',
+ 'a', 't', 's', '_', 't', 'r', 'i', 'g', 'g', 'e', 'r', '#', '1', '(', 'i', 'n', '_',
+ 'c', 'm', 'p', '_', 's', 't', 'a', 't', 's', '_', 'b', 'i', 'n', ',', 'i', 'n', '_',
+ 's', 't', 'a', 't', 's', '_', 'q', 'u', 'a', 'l', ',', 'i', 'n', '_', 'r', 'e', 'a',
+ 'd', '_', 'l', 'e', 'n', ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p',
+ 'e', ',', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'g', 'r', 'o', 'u', 'p', ')', '|',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'c', 'm', 'p', '_', 's', 't', 'a', 't',
+ 's', '_', 't', 'r', 'i', 'g', 'g', 'e', 'r', '#', '1', '(', 'i', 'n', '_', 'c', 'm',
+ 'p', '_', 's', 't', 'a', 't', 's', '_', 'b', 'i', 'n', ',', 'i', 'n', '_', 's', 't',
+ 'a', 't', 's', '_', 'q', 'u', 'a', 'l', ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_',
+ 'l', 'e', 'n', ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ')',
+ '|', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'c', 'm', 'p', 'f', '_', 's', 't',
+ 'a', 't', 's', '_', 't', 'r', 'i', 'g', 'g', 'e', 'r', '#', '1', '(', 'i', 'n', '_',
+ 'c', 'm', 'p', '_', 's', 't', 'a', 't', 's', '_', 'b', 'i', 'n', ',', 'i', 'n', '_',
+ 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_',
+ 'l', 'e', 'n', ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ',',
+ 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'g', 'r', 'o', 'u', 'p', ')', '|', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 'c', 'm', 'p', 'f', '_', 's', 't', 'a', 't', 's',
+ '_', 't', 'r', 'i', 'g', 'g', 'e', 'r', '#', '1', '(', 'i', 'n', '_', 'c', 'm', 'p',
+ '_', 's', 't', 'a', 't', 's', '_', 'b', 'i', 'n', ',', 'i', 'n', '_', 's', 'p', 'o',
+ 't', '_', 'l', 'e', 'n', ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n',
+ ',', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ')', ';', 't', 'r',
+ 'i', 'g', 'g', 'e', 'r', ' ', 'q', 'u', 'a', 'l', '_', 's', 't', 'a', 't', 's', '=',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'p', 'h', 'r', 'e', 'd', '_', 's', 't',
+ 'a', 't', 's', '_', 't', 'r', 'i', 'g', 'g', 'e', 'r', '#', '1', '(', 'i', 'n', '_',
+ 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', ')', ';', '}', 't', 'a', 'b', 'l',
+ 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p',
+ 'o', 't', 'd', 'e', 's', 'c', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.',
+ '2', '=', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l', ':', 's', 'e', 'q', 'u', 'e',
+ 'n', 'c', 'e', '#', '1', '.', '0', '.', '1', ',', 'I', 'N', 'S', 'D', 'C', ':', 'S',
+ 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '#', '1',
+ '.', '0', '.', '2', '{', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l',
+ 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'S', 'e', 'g', 'm',
+ 'e', 'n', 't', ' ', 'L', 'A', 'B', 'E', 'L', '_', 'S', 'E', 'G', ' ', '=', ' ', 'o',
+ 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 'e', 'g', '|', 'c', 'a', 's', 't',
+ '#', '1', '(', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 'e', 'g', '3',
+ '2', ')', '|', 'c', 'a', 's', 't', '#', '1', '(', '_', 'o', 'u', 't', '_', 'l', 'a',
+ 'b', 'e', 'l', '_', 's', 'e', 'g', '3', '2', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n',
+ 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'S', 'e', 'g', 'm', 'e', 'n', 't', ' ', 'R', 'E', 'A', 'D', '_', 'S', 'E',
+ 'G', ' ', '=', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '|',
+ 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's',
+ 'e', 'g', '3', '2', ')', '|', 'c', 'a', 's', 't', '#', '1', '(', '_', 'o', 'u', 't',
+ '_', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '3', '2', ')', ';', 'r', 'e', 'a', 'd',
+ 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':',
+ 'S', 'R', 'A', ':', 'R', 'e', 'a', 'd', 'D', 'e', 's', 'c', ' ', 'R', 'E', 'A', 'D',
+ '_', 'D', 'E', 'S', 'C', ' ', '=', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 'm', 'a', 'k', 'e', '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', '#', '1', '(',
+ 'o', 'u', 't', '_', 'n', 'r', 'e', 'a', 'd', 's', ',', 'o', 'u', 't', '_', 'r', 'e',
+ 'a', 'd', '_', 's', 't', 'a', 'r', 't', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd',
+ '_', 'l', 'e', 'n', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p',
+ 'e', ',', '_', 'o', 'u', 't', '_', 'r', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', ',',
+ 'o', 'u', 't', '_', 'c', 's', '_', 'k', 'e', 'y', ',', '_', 'o', 'u', 't', '_', 'l',
+ 'a', 'b', 'e', 'l', '_', 's', 't', 'a', 'r', 't', ',', '_', 'o', 'u', 't', '_', 'l',
+ 'a', 'b', 'e', 'l', '_', 'l', 'e', 'n', ',', '_', 'o', 'u', 't', '_', 'l', 'a', 'b',
+ 'e', 'l', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u',
+ 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'S', 'p', 'o', 't', 'D',
+ 'e', 's', 'c', ' ', 'S', 'P', 'O', 'T', '_', 'D', 'E', 'S', 'C', ' ', '=', ' ', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'm', 'a', 'k', 'e', '_', 's', 'p', 'o', 't',
+ '_', 'd', 'e', 's', 'c', '#', '1', '(', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ',',
+ 'f', 'i', 'x', 'e', 'd', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ',', 's', 'i',
+ 'g', 'n', 'a', 'l', '_', 'l', 'e', 'n', ',', 't', 'r', 'i', 'm', '_', 's', 't', 'a',
+ 'r', 't', ',', 't', 'r', 'i', 'm', '_', 'l', 'e', 'n', ',', 'o', 'u', 't', '_', 'n',
+ 'r', 'e', 'a', 'd', 's', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c',
+ 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'l', 'e', 'n', ' ', 'S', 'I', 'G', 'N', 'A', 'L', '_', 'L', 'E', 'N', ' ', '=',
+ ' ', 's', 'i', 'g', 'n', 'a', 'l', '_', 'l', 'e', 'n', ';', 'r', 'e', 'a', 'd', 'o',
+ 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '1', '6', ' ', 'S', 'I',
+ 'G', 'N', 'A', 'L', '_', 'L', 'E', 'N', ' ', '=', ' ', 'c', 'a', 's', 't', '#', '1',
+ '(', 's', 'i', 'g', 'n', 'a', 'l', '_', 'l', 'e', 'n', ')', ';', 'U', '3', '2', ' ',
+ '_', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 't', 'a', 'r', 't', 'U',
+ '3', '2', '=', '(', 'U', '3', '2', ')', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l',
+ '_', 's', 't', 'a', 'r', 't', ';', 'U', '3', '2', '[', '2', ']', ' ', '_', 'o', 'u',
+ 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 'e', 'g', '3', '2', '=', '<', 'U', '3',
+ '2', '>', 'p', 'a', 's', 't', 'e', '#', '1', '(', '_', 'o', 'u', 't', '_', 'l', 'a',
+ 'b', 'e', 'l', '_', 's', 't', 'a', 'r', 't', 'U', '3', '2', ',', 'o', 'u', 't', '_',
+ 'l', 'a', 'b', 'e', 'l', '_', 'l', 'e', 'n', ')', ';', 'U', '3', '2', ' ', '_', 'o',
+ 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', 'U', '3', '2', '=',
+ '(', 'U', '3', '2', ')', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a',
+ 'r', 't', ';', 'U', '3', '2', '[', '2', ']', ' ', '_', 'o', 'u', 't', '_', 'r', 'e',
+ 'a', 'd', '_', 's', 'e', 'g', '3', '2', '=', '<', 'U', '3', '2', '>', 'p', 'a', 's',
+ 't', 'e', '#', '1', '(', '_', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't',
+ 'a', 'r', 't', 'U', '3', '2', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 'l',
+ 'e', 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a',
+ 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', ' ', '_', 'o', 'u', 't', '_', 'r', 'd', '_',
+ 'f', 'i', 'l', 't', 'e', 'r', '=', 'o', 'u', 't', '_', 'r', 'd', '_', 'f', 'i', 'l',
+ 't', 'e', 'r', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e',
+ 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', '>', 'e', 'c', 'h', 'o', '#', '1', '<',
+ '0', '>', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't',
+ ')', ';', 'a', 's', 'c', 'i', 'i', ' ', '_', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e',
+ 'l', '=', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '|', '<', 'a', 's', 'c', 'i',
+ 'i', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'', '\'', '>', '(', ')', ';', 'I',
+ 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', '_',
+ 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 't', 'a', 'r', 't', '=', 'o',
+ 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 't', 'a', 'r', 't', '|', '<', 'I',
+ 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', '>', 'e',
+ 'c', 'h', 'o', '#', '1', '<', '0', '>', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd',
+ '_', 's', 't', 'a', 'r', 't', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
+ 'r', 'd', ':', 'l', 'e', 'n', ' ', '_', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l',
+ '_', 'l', 'e', 'n', '=', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 'l', 'e',
+ 'n', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e',
+ 'n', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '0', '>', '(', 'o', 'u', 't', '_', 'r',
+ 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', ')', ';', '}', 't', 'a', 'b', 'l', 'e',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o',
+ 't', 'd', 'e', 's', 'c', '_', 'n', 'o', 'p', 'h', 'y', 's', '#', '1', '.', '0', '.',
+ '2', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p',
+ 'o', 't', 'd', 'e', 's', 'c', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.',
+ '2', '{', 'U', '8', ' ', 'o', 'u', 't', '_', 'n', 'r', 'e', 'a', 'd', 's', '=', '.',
+ 'N', 'R', 'E', 'A', 'D', 'S', ';', 'a', 's', 'c', 'i', 'i', ' ', 'o', 'u', 't', '_',
+ 'l', 'a', 'b', 'e', 'l', '=', '.', 'L', 'A', 'B', 'E', 'L', ';', 'I', 'N', 'S', 'D',
+ 'C', ':', 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ',
+ 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '=', '.', 'R', 'E',
+ 'A', 'D', '_', 'T', 'Y', 'P', 'E', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A',
+ ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', ' ', 'o', 'u', 't', '_',
+ 'r', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', '=', '.', 'R', 'D', '_', 'F', 'I', 'L',
+ 'T', 'E', 'R', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z',
+ 'e', 'r', 'o', ' ', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 't', 'a',
+ 'r', 't', '=', '.', 'L', 'A', 'B', 'E', 'L', '_', 'S', 'T', 'A', 'R', 'T', '|', '(',
+ 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ')',
+ '<', 'U', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '0', '>', '(', 'o', 'u', 't',
+ '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 'e', 'g', '3', '2', ')', ';', 'I', 'N', 'S',
+ 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'o', 'u', 't', '_',
+ 'l', 'a', 'b', 'e', 'l', '_', 'l', 'e', 'n', '=', '.', 'L', 'A', 'B', 'E', 'L', '_',
+ 'L', 'E', 'N', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
+ 'l', 'e', 'n', ')', '<', 'U', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '1', '>',
+ '(', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 's', 'e', 'g', '3', '2', ')',
+ ';', 'U', '3', '2', '[', '2', ']', ' ', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l',
+ '_', 's', 'e', 'g', '3', '2', '=', 'c', 'a', 's', 't', '#', '1', '(', '.', 'L', 'A',
+ 'B', 'E', 'L', '_', 'S', 'E', 'G', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
+ 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd',
+ '_', 's', 't', 'a', 'r', 't', '=', '.', 'R', 'E', 'A', 'D', '_', 'S', 'T', 'A', 'R',
+ 'T', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e',
+ 'r', 'o', ')', '<', 'U', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '0', '>', '(',
+ 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '3', '2', ')', ';', 'I',
+ 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'o', 'u',
+ 't', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', '=', '.', 'R', 'E', 'A', 'D', '_',
+ 'L', 'E', 'N', '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
+ 'l', 'e', 'n', ')', '<', 'U', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '1', '>',
+ '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '3', '2', ')', ';',
+ 'U', '3', '2', '[', '2', ']', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's',
+ 'e', 'g', '3', '2', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'f', 'i', 'x',
+ '_', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '#', '1', '(', '.', 'R', 'E', 'A', 'D',
+ '_', 'S', 'E', 'G', ',', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ')', ';', '}', 't',
+ 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l',
+ ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '#', '1', '.', '0', '.', '2', '=', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'd',
+ 'e', 's', 'c', '_', 'n', 'o', 'p', 'h', 'y', 's', '#', '1', '.', '0', '.', '2', '{',
+ 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<',
+ 'U', '8', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1',
+ ' ', '.', 'N', 'R', 'E', 'A', 'D', 'S', '=', 'N', 'R', 'E', 'A', 'D', 'S', ';', 'p',
+ 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'a',
+ 's', 'c', 'i', 'i', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g',
+ '#', '1', ' ', '.', 'L', 'A', 'B', 'E', 'L', '=', 'L', 'A', 'B', 'E', 'L', ';', 'p',
+ 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I',
+ 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', '>', 'i',
'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'L',
- 'A', 'B', 'E', 'L', '=', 'L', 'A', 'B', 'E', 'L', ';', 'p', 'h', 'y', 's', 'i', 'c',
- 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', '>', 'i', 'z', 'i', 'p', '_', 'e',
- 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'L', 'A', 'B', 'E', 'L', '_',
- 'S', 'T', 'A', 'R', 'T', '=', 'L', 'A', 'B', 'E', 'L', '_', 'S', 'T', 'A', 'R', 'T',
- ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
- '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', '>',
- 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.',
- 'L', 'A', 'B', 'E', 'L', '_', 'L', 'E', 'N', '=', 'L', 'A', 'B', 'E', 'L', '_', 'L',
- 'E', 'N', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm',
- 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e',
- 'r', 'o', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#',
- '1', ' ', '.', 'R', 'E', 'A', 'D', '_', 'S', 'T', 'A', 'R', 'T', '=', 'R', 'E', 'A',
- 'D', '_', 'S', 'T', 'A', 'R', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
+ 'A', 'B', 'E', 'L', '_', 'S', 'T', 'A', 'R', 'T', '=', 'L', 'A', 'B', 'E', 'L', '_',
+ 'S', 'T', 'A', 'R', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'l', 'e', 'n', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n',
+ 'g', '#', '1', ' ', '.', 'L', 'A', 'B', 'E', 'L', '_', 'L', 'E', 'N', '=', 'L', 'A',
+ 'B', 'E', 'L', '_', 'L', 'E', 'N', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
- 'r', 'd', ':', 'l', 'e', 'n', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd',
- 'i', 'n', 'g', '#', '1', ' ', '.', 'R', 'E', 'A', 'D', '_', 'L', 'E', 'N', '=', 'i',
- 'n', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ';', 'p', 'h', 'y', 's', 'i', 'c',
- 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':',
- 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '>', 'z', 'i',
- 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'R', 'E', 'A',
- 'D', '_', 'T', 'Y', 'P', 'E', '=', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 't', 'y',
- 'p', 'e', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm',
- 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd',
- '_', 'f', 'i', 'l', 't', 'e', 'r', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd',
- 'i', 'n', 'g', '#', '1', ' ', '.', 'R', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', '=',
- 'R', 'E', 'A', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', ';', '}', 't', 'a', 'b', 'l',
- 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 'p', 'o',
- 's', '#', '1', '.', '0', '.', '1', '=', 'I', 'N', 'S', 'D', 'C', ':', 't', 'b', 'l',
- ':', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0', '.', '1', '{', 'I',
+ 'r', 'd', ':', 'z', 'e', 'r', 'o', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o',
+ 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'R', 'E', 'A', 'D', '_', 'S', 'T', 'A', 'R',
+ 'T', '=', 'R', 'E', 'A', 'D', '_', 'S', 'T', 'A', 'R', 'T', ';', 'p', 'h', 'y', 's',
+ 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', '>', 'i', 'z', 'i', 'p', '_',
+ 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'R', 'E', 'A', 'D', '_',
+ 'L', 'E', 'N', '=', 'i', 'n', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', ';', 'p',
+ 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I',
+ 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x', 'r', 'e', 'a', 'd', '_', 't', 'y',
+ 'p', 'e', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1',
+ ' ', '.', 'R', 'E', 'A', 'D', '_', 'T', 'Y', 'P', 'E', '=', 'i', 'n', '_', 'r', 'e',
+ 'a', 'd', '_', 't', 'y', 'p', 'e', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
+ 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A',
+ ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', '>', 'z', 'i', 'p', '_',
+ 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'R', 'D', '_', 'F', 'I',
+ 'L', 'T', 'E', 'R', '=', 'R', 'E', 'A', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', ';',
+ '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't',
+ 'b', 'l', ':', 'p', 'o', 's', '#', '1', '.', '0', '.', '1', '=', 'I', 'N', 'S', 'D',
+ 'C', ':', 't', 'b', 'l', ':', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.',
+ '0', '.', '1', '{', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o',
+ 'n', ':', 'o', 'n', 'e', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o',
+ 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n',
+ ':', 'o', 'n', 'e', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'm', 'a', 'k',
+ 'e', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '#', '1', '<', '1', '>', '(', 'o',
+ 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', ')', '|', '<', 'I',
'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e',
- ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '=', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', '>',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'm', 'a', 'k', 'e', '_', 'p', 'o', 's',
- 'i', 't', 'i', 'o', 'n', '#', '1', '<', '1', '>', '(', 'o', 'u', 't', '_', '2', 'n',
- 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', ')', '|', '<', 'I', 'N', 'S', 'D', 'C', ':',
- 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', '>', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 'm', 'a', 'k', 'e', '_', 'p', 'o', 's', 'i', 't', 'i', 'o',
- 'n', '#', '1', '<', '1', '>', '(', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'p', 'a',
- 'c', 'k', 'e', 'd', ')', ';', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'p', 'o',
- 's', '1', '6', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '1',
- '6', '=', '<', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'p', 'o', 's', '1', '6',
'>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'm', 'a', 'k', 'e', '_', 'p', 'o',
's', 'i', 't', 'i', 'o', 'n', '#', '1', '<', '1', '>', '(', 'o', 'u', 't', '_', '2',
- 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', ')', '|', '<', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'p', 'o', 's', '1', '6', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 'm', 'a', 'k', 'e', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '#', '1',
- '<', '1', '>', '(', 'o', 'u', 't', '_', '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e',
- 'd', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '_', 'n', 'o', 'p', 'o', 's', '#', '1',
- '.', '0', '.', '3', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b',
- 'l', ':', 's', 'r', 'a', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '_',
- 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '2', '{', 'c', 'o', 'l', 'u', 'm',
- 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':',
- 'o', 'n', 'e', ' ', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ' ', '=', ' ', 'o', 'u',
- 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ';', 'r', 'e', 'a', 'd', 'o', 'n',
- 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 'p', 'o', 's', '1', '6', ' ', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ' ',
- '=', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '1', '6', ';',
- 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I',
- 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'z', 'e', 'r',
- 'o', ' ', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ' ', '=', ' ', '(', 'I', 'N', 'S',
- 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'z', 'e', 'r', 'o', ')',
- '<', 'I', '3', '2', '>', 'd', 'i', 'f', 'f', '#', '1', '<', '1', '>', '(', 'o', 'u',
- 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ')', ';', 'U', '6', '4', ' ', 'b',
- 'a', 's', 'e', '_', 'c', 'o', 'u', 'n', 't', '=', '<', 'U', '6', '4', '>', 'm', 'e',
- 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<', '\'', 'B', 'A', 'S', 'E',
- '_', 'C', 'O', 'U', 'N', 'T', '\'', '>', '(', ')', ';', 'U', '6', '4', ' ', 's',
- 'p', 'o', 't', '_', 'c', 'o', 'u', 'n', 't', '=', '<', 'U', '6', '4', '>', 'm', 'e',
- 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<', '\'', '.', 's', 'e', 'q',
- '/', 's', 'p', 'o', 't', '\'', '>', '(', ')', '|', '<', 'U', '6', '4', '>', 'm',
- 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<', '\'', '.', 's', 'e',
- 'q', '\'', '>', '(', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#', '1', '.', '0',
- '.', '3', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's',
- 'r', 'a', '_', 'n', 'o', 'p', 'o', 's', '#', '1', '.', '0', '.', '3', ',', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 'p', 'o', 's', '#', '1', '.',
- '0', '.', '1', '{', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '_', 'n', 'o', 'p', 'o', 's', '#',
- '2', '.', '1', '.', '3', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't',
- 'b', 'l', ':', 's', 'r', 'a', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'k', 'e', 'y', 'n', 'a', 'm', 'e',
- '#', '3', '.', '0', '.', '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't',
- 'b', 'l', ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '#', '1', '.', '0', '.', '2',
- ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 't', 'a',
- 't', 's', '#', '1', '.', '2', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S',
- 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', ' ', 'P',
- 'O', 'S', 'I', 'T', 'I', 'O', 'N', ' ', '=', ' ', 'o', 'u', 't', '_', 'p', 'o', 's',
- 'i', 't', 'i', 'o', 'n', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o',
- 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'p', 'o', 's',
- '1', '6', ' ', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ' ', '=', ' ', 'c', 'a', 's',
- 't', '#', '1', '(', '_', 'c', 'l', 'i', 'p', '_', 'p', 'o', 's', 'i', 't', 'i', 'o',
- 'n', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm',
- 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':',
- 'z', 'e', 'r', 'o', ' ', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ' ', '=', ' ', '(',
- 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'z', 'e',
- 'r', 'o', ')', '<', 'I', '3', '2', '>', 'd', 'i', 'f', 'f', '#', '1', '<', '1', '>',
- '(', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ')', ';', 'I', 'N',
- 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_',
- 'i', 'd', ' ', 'o', 'u', 't', '_', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '=', '.',
- 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', ';', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o',
- 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', ' ', '_', 'c', 'l', 'i', 'p', '_',
- 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'p',
- 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', '>', 'c', 'l', 'i', 'p', '#',
- '1', '<', '0', ',', '6', '5', '5', '3', '5', '>', '(', 'o', 'u', 't', '_', 'p', 'o',
- 's', 'i', 't', 'i', 'o', 'n', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#', '2', '.',
- '1', '.', '3', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l',
- ':', 's', 'r', 'a', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'k', 'e', 'y', 'n', 'a', 'm', 'e', '#', '3',
- '.', '0', '.', '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l',
- ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '#', '1', '.', '0', '.', '2', ',', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 't', 'a', 't', 's',
- '#', '1', '.', '2', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l',
- ':', 'p', 'o', 's', '#', '1', '.', '0', '.', '1', '{', 'r', 'e', 'a', 'd', 'o', 'n',
- 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'p',
- 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', ' ', 'P', 'O', 'S', 'I', 'T',
- 'I', 'O', 'N', ' ', '=', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o',
- 'n', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n',
- ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'p', 'o', 's', '1', '6', ' ', 'P',
- 'O', 'S', 'I', 'T', 'I', 'O', 'N', ' ', '=', ' ', 'o', 'u', 't', '_', 'p', 'o', 's',
- 'i', 't', 'i', 'o', 'n', '1', '6', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ',
+ 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', ')', ';', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 'p', 'o', 's', '1', '6', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i',
+ 't', 'i', 'o', 'n', '1', '6', '=', '<', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 'p', 'o', 's', '1', '6', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'm', 'a',
+ 'k', 'e', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '#', '1', '<', '1', '>', '(',
+ 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', ')', '|', '<',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'p', 'o', 's', '1', '6', '>', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 'm', 'a', 'k', 'e', '_', 'p', 'o', 's', 'i', 't',
+ 'i', 'o', 'n', '#', '1', '<', '1', '>', '(', 'o', 'u', 't', '_', '2', 'c', 's', '_',
+ 'p', 'a', 'c', 'k', 'e', 'd', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '_', 'n', 'o',
+ 'p', 'o', 's', '#', '1', '.', '0', '.', '3', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S',
+ 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#', '1', '.', '0', '.', '3', ',',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't',
+ 'd', 'e', 's', 'c', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '2', '{',
'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i',
- 't', 'i', 'o', 'n', ':', 'z', 'e', 'r', 'o', ' ', 'P', 'O', 'S', 'I', 'T', 'I', 'O',
- 'N', ' ', '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i',
- 'o', 'n', ':', 'z', 'e', 'r', 'o', ')', '<', 'I', '3', '2', '>', 'd', 'i', 'f', 'f',
- '#', '1', '<', '1', '>', '(', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o',
- 'n', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 't', 'b', 'l', ':', 'c', 'l', 'i', 'p', '#', '1', '.', '0', '.', '2', '=',
- 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o',
- 't', 'd', 'e', 's', 'c', '#', '1', '.', '0', '.', '2', '{', 'c', 'o', 'l', 'u', 'm',
- 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e',
- ' ', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'L', 'E', 'F',
- 'T', ' ', '=', ' ', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p',
- 't', '_', 'l', 'e', 'f', 't', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S',
- 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'C', 'L', 'I', 'P',
- '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'R', 'I', 'G', 'H', 'T', ' ', '=', ' ',
- 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'r', 'i',
- 'g', 'h', 't', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'C', 'L', 'I', 'P', '_', 'Q', 'U',
- 'A', 'L', 'I', 'T', 'Y', '_', 'L', 'E', 'F', 'T', ' ', '=', ' ', 'o', 'u', 't', '_',
- 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'l', 'e', 'f', 't', ';', 'c', 'o',
+ 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', ' ', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N',
+ ' ', '=', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ';', 'r',
+ 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 'p', 'o', 's', '1', '6', ' ', 'P', 'O', 'S', 'I',
+ 'T', 'I', 'O', 'N', ' ', '=', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i',
+ 'o', 'n', '1', '6', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l',
+ 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o',
+ 'n', ':', 'z', 'e', 'r', 'o', ' ', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ' ', '=',
+ ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':',
+ 'z', 'e', 'r', 'o', ')', '<', 'I', '3', '2', '>', 'd', 'i', 'f', 'f', '#', '1', '<',
+ '1', '>', '(', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ')', ';',
+ 'U', '6', '4', ' ', 'b', 'a', 's', 'e', '_', 'c', 'o', 'u', 'n', 't', '=', '<', 'U',
+ '6', '4', '>', 'm', 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<', '\'',
+ 'B', 'A', 'S', 'E', '_', 'C', 'O', 'U', 'N', 'T', '\'', '>', '(', ')', ';', 'U',
+ '6', '4', ' ', 's', 'p', 'o', 't', '_', 'c', 'o', 'u', 'n', 't', '=', '<', 'U', '6',
+ '4', '>', 'm', 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<', '\'',
+ '.', 's', 'e', 'q', '/', 's', 'p', 'o', 't', '\'', '>', '(', ')', '|', '<', 'U',
+ '6', '4', '>', 'm', 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<', '\'',
+ '.', 's', 'e', 'q', '\'', '>', '(', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#',
+ '1', '.', '0', '.', '3', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b',
+ 'l', ':', 's', 'r', 'a', '_', 'n', 'o', 'p', 'o', 's', '#', '1', '.', '0', '.', '3',
+ ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 'p', 'o', 's',
+ '#', '1', '.', '0', '.', '1', '{', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '_', 'n', 'o', 'p',
+ 'o', 's', '#', '2', '.', '1', '.', '3', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R',
+ 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#', '1', '.', '0', '.', '3', ',', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'k', 'e', 'y', 'n',
+ 'a', 'm', 'e', '#', '3', '.', '0', '.', '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '#', '1', '.',
+ '0', '.', '2', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':',
+ 's', 't', 'a', 't', 's', '#', '1', '.', '2', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
+ 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n',
+ 'e', ' ', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ' ', '=', ' ', 'o', 'u', 't', '_',
+ 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y',
+ ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 'p', 'o', 's', '1', '6', ' ', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ' ', '=', ' ',
+ 'c', 'a', 's', 't', '#', '1', '(', '_', 'c', 'l', 'i', 'p', '_', 'p', 'o', 's', 'i',
+ 't', 'i', 'o', 'n', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i',
+ 'o', 'n', ':', 'z', 'e', 'r', 'o', ' ', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ' ',
+ '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n',
+ ':', 'z', 'e', 'r', 'o', ')', '<', 'I', '3', '2', '>', 'd', 'i', 'f', 'f', '#', '1',
+ '<', '1', '>', '(', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ')',
+ ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o',
+ 'r', 'm', '_', 'i', 'd', ' ', 'o', 'u', 't', '_', 'p', 'l', 'a', 't', 'f', 'o', 'r',
+ 'm', '=', '.', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', ' ', '_', 'c', 'l',
+ 'i', 'p', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '=', '<', 'I', 'N', 'S', 'D',
+ 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', '>', 'c', 'l',
+ 'i', 'p', '#', '1', '<', '0', ',', '6', '5', '5', '3', '5', '>', '(', 'o', 'u', 't',
+ '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ')', ';', '}', 't', 'a', 'b', 'l', 'e',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a',
+ '#', '2', '.', '1', '.', '3', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':',
+ 't', 'b', 'l', ':', 's', 'r', 'a', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'k', 'e', 'y', 'n', 'a', 'm',
+ 'e', '#', '3', '.', '0', '.', '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 't', 'b', 'l', ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '#', '1', '.', '0', '.',
+ '2', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 't',
+ 'a', 't', 's', '#', '1', '.', '2', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 't', 'b', 'l', ':', 'p', 'o', 's', '#', '1', '.', '0', '.', '1', '{', 'r', 'e', 'a',
+ 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D',
+ 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', ' ', 'P', 'O',
+ 'S', 'I', 'T', 'I', 'O', 'N', ' ', '=', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i',
+ 't', 'i', 'o', 'n', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l',
+ 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'p', 'o', 's', '1',
+ '6', ' ', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ' ', '=', ' ', 'o', 'u', 't', '_',
+ 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '1', '6', ';', 'r', 'e', 'a', 'd', 'o', 'n',
+ 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'p',
+ 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'z', 'e', 'r', 'o', ' ', 'P', 'O', 'S', 'I',
+ 'T', 'I', 'O', 'N', ' ', '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's',
+ 'i', 't', 'i', 'o', 'n', ':', 'z', 'e', 'r', 'o', ')', '<', 'I', '3', '2', '>', 'd',
+ 'i', 'f', 'f', '#', '1', '<', '1', '>', '(', 'o', 'u', 't', '_', 'p', 'o', 's', 'i',
+ 't', 'i', 'o', 'n', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I',
+ ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 'c', 'l', 'i', 'p', '#', '1', '.', '0',
+ '.', '2', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':',
+ 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '#', '1', '.', '0', '.', '2', '{', 'c', 'o',
'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
- 'o', 'n', 'e', ' ', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_',
- 'R', 'I', 'G', 'H', 'T', ' ', '=', ' ', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_',
- 'q', 'u', 'a', 'l', '_', 'r', 'i', 'g', 'h', 't', ';', 'r', 'e', 'a', 'd', 'o', 'n',
- 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '1', '6', ' ', 'C', 'L', 'I',
- 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'L', 'E', 'F', 'T', ' ', '=', ' ',
- '.', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'L', 'E', 'F',
- 'T', '|', 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p',
- '_', 'a', 'd', 'a', 'p', 't', '_', 'l', 'e', 'f', 't', ')', ';', 'r', 'e', 'a', 'd',
- 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '1', '6', ' ', 'C',
+ 'o', 'n', 'e', ' ', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_',
+ 'L', 'E', 'F', 'T', ' ', '=', ' ', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'a',
+ 'd', 'a', 'p', 't', '_', 'l', 'e', 'f', 't', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
+ 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'C',
'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'R', 'I', 'G', 'H', 'T',
- ' ', '=', ' ', '.', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_',
- 'R', 'I', 'G', 'H', 'T', '|', 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u', 't', '_',
- 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'r', 'i', 'g', 'h', 't', ')',
- ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
- 'U', '1', '6', ' ', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_',
- 'L', 'E', 'F', 'T', ' ', '=', ' ', 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u', 't',
- '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'l', 'e', 'f', 't', ')', ';',
- 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U',
- '1', '6', ' ', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'R',
- 'I', 'G', 'H', 'T', ' ', '=', ' ', 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u', 't',
- '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'r', 'i', 'g', 'h', 't', ')',
- ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ',
+ ' ', '=', ' ', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't',
+ '_', 'r', 'i', 'g', 'h', 't', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S',
+ 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'C', 'L', 'I', 'P',
+ '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'L', 'E', 'F', 'T', ' ', '=', ' ', 'o',
+ 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'l', 'e', 'f', 't',
+ ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
+ 'r', 'd', ':', 'o', 'n', 'e', ' ', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I',
+ 'T', 'Y', '_', 'R', 'I', 'G', 'H', 'T', ' ', '=', ' ', 'o', 'u', 't', '_', 'c', 'l',
+ 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'r', 'i', 'g', 'h', 't', ';', 'r', 'e', 'a',
+ 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '1', '6', ' ',
'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'L', 'E', 'F', 'T',
- ' ', '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z',
- 'e', 'r', 'o', ')', '<', 'I', '3', '2', '>', 'd', 'i', 'f', 'f', '#', '1', '<', '1',
- '>', '(', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_',
- 'l', 'e', 'f', 't', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o',
- 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
- 'z', 'e', 'r', 'o', ' ', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R',
- '_', 'R', 'I', 'G', 'H', 'T', ' ', '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ')', '<', 'I', '3', '2', '>', 'd', 'i',
- 'f', 'f', '#', '1', '<', '1', '>', '(', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_',
- 'a', 'd', 'a', 'p', 't', '_', 'r', 'i', 'g', 'h', 't', ')', ';', 'r', 'e', 'a', 'd',
- 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'C', 'L', 'I', 'P', '_',
- 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'L', 'E', 'F', 'T', ' ', '=', ' ', '(', 'I',
- 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ')', '<',
- 'I', '3', '2', '>', 'd', 'i', 'f', 'f', '#', '1', '<', '1', '>', '(', 'l', 'i', 'm',
- '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'l', 'e', 'f', 't', ')', ';',
- 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I',
- 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'C',
- 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'R', 'I', 'G', 'H', 'T',
- ' ', '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z',
- 'e', 'r', 'o', ')', '<', 'I', '3', '2', '>', 'd', 'i', 'f', 'f', '#', '1', '<', '1',
- '>', '(', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'r',
- 'i', 'g', 'h', 't', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
- ':', 'o', 'n', 'e', ' ', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a',
- 'p', 't', '_', 'l', 'e', 'f', 't', '=', 'c', 'a', 's', 't', '#', '1', '(', '.', 'C',
- 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'L', 'E', 'F', 'T', ')',
+ ' ', '=', ' ', '.', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_',
+ 'L', 'E', 'F', 'T', '|', 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u', 't', '_', 'c',
+ 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'l', 'e', 'f', 't', ')', ';', 'r',
+ 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'U', '1',
+ '6', ' ', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'R', 'I',
+ 'G', 'H', 'T', ' ', '=', ' ', '.', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T',
+ 'E', 'R', '_', 'R', 'I', 'G', 'H', 'T', '|', 'c', 'a', 's', 't', '#', '1', '(', 'o',
+ 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'r', 'i', 'g',
+ 'h', 't', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u',
+ 'm', 'n', ' ', 'U', '1', '6', ' ', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I',
+ 'T', 'Y', '_', 'L', 'E', 'F', 'T', ' ', '=', ' ', 'c', 'a', 's', 't', '#', '1', '(',
+ 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'l', 'e', 'f',
+ 't', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm',
+ 'n', ' ', 'U', '1', '6', ' ', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T',
+ 'Y', '_', 'R', 'I', 'G', 'H', 'T', ' ', '=', ' ', 'c', 'a', 's', 't', '#', '1', '(',
+ 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'r', 'i', 'g',
+ 'h', 't', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u',
+ 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e',
+ 'r', 'o', ' ', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'L',
+ 'E', 'F', 'T', ' ', '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'z', 'e', 'r', 'o', ')', '<', 'I', '3', '2', '>', 'd', 'i', 'f', 'f', '#',
+ '1', '<', '1', '>', '(', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a',
+ 'p', 't', '_', 'l', 'e', 'f', 't', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y',
+ ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
+ 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P',
+ 'T', 'E', 'R', '_', 'R', 'I', 'G', 'H', 'T', ' ', '=', ' ', '(', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ')', '<', 'I', '3', '2',
+ '>', 'd', 'i', 'f', 'f', '#', '1', '<', '1', '>', '(', 'l', 'i', 'm', '_', 'c', 'l',
+ 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'r', 'i', 'g', 'h', 't', ')', ';', 'r',
+ 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N',
+ 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'C', 'L',
+ 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'L', 'E', 'F', 'T', ' ', '=',
+ ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r',
+ 'o', ')', '<', 'I', '3', '2', '>', 'd', 'i', 'f', 'f', '#', '1', '<', '1', '>', '(',
+ 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'l', 'e', 'f',
+ 't', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm',
+ 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r',
+ 'o', ' ', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'R', 'I',
+ 'G', 'H', 'T', ' ', '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'z', 'e', 'r', 'o', ')', '<', 'I', '3', '2', '>', 'd', 'i', 'f', 'f', '#',
+ '1', '<', '1', '>', '(', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a',
+ 'l', '_', 'r', 'i', 'g', 'h', 't', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
+ 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_',
+ 'a', 'd', 'a', 'p', 't', '_', 'l', 'e', 'f', 't', '=', 'c', 'a', 's', 't', '#', '1',
+ '(', '.', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'L', 'E',
+ 'F', 'T', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o',
+ 'n', 'e', ' ', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't',
+ '_', 'r', 'i', 'g', 'h', 't', '=', 'c', 'a', 's', 't', '#', '1', '(', '.', 'C', 'L',
+ 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'R', 'I', 'G', 'H', 'T', ')',
';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ',
- 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'r', 'i',
- 'g', 'h', 't', '=', 'c', 'a', 's', 't', '#', '1', '(', '.', 'C', 'L', 'I', 'P', '_',
- 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'R', 'I', 'G', 'H', 'T', ')', ';', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'o', 'u', 't',
- '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'l', 'e', 'f', 't', '=', 'c',
- 'a', 's', 't', '#', '1', '(', '.', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I',
- 'T', 'Y', '_', 'L', 'E', 'F', 'T', ')', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '1',
- '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o',
- 'n', 'e', ' ', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_',
- 'r', 'i', 'g', 'h', 't', '=', 'c', 'a', 's', 't', '#', '1', '(', '.', 'C', 'L', 'I',
- 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'R', 'I', 'G', 'H', 'T', ')', '|',
- 'c', 'a', 's', 't', '#', '1', '(', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ')', ';',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 's',
- 'p', 'o', 't', '_', 'r', 'i', 'g', 'h', 't', '=', '(', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ')', 's', 'p', 'o', 't', '_', 'l', 'e',
- 'n', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e',
- ' ', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'l',
- 'e', 'f', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
- 'o', 'n', 'e', '>', 'c', 'l', 'i', 'p', '#', '1', '<', '1', ',', '2', '1', '4', '7',
- '4', '8', '3', '6', '4', '7', '>', '(', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_',
- 'a', 'd', 'a', 'p', 't', '_', 'l', 'e', 'f', 't', ')', ';', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'm', 'a', 'x', '_', 'c', 'l',
- 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'r', 'i', 'g', 'h', 't', '=', '<', 'I',
- 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ',', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'm', 'a', 'p',
- '#', '1', '<', '0', ',', '2', '1', '4', '7', '4', '8', '3', '6', '4', '7', '>', '(',
- 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'r', 'i',
- 'g', 'h', 't', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
+ 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'l', 'e', 'f',
+ 't', '=', 'c', 'a', 's', 't', '#', '1', '(', '.', 'C', 'L', 'I', 'P', '_', 'Q', 'U',
+ 'A', 'L', 'I', 'T', 'Y', '_', 'L', 'E', 'F', 'T', ')', '|', '<', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'e', 'c', 'h', 'o', '#',
+ '1', '<', '1', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'o', 'n', 'e', ' ', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u',
+ 'a', 'l', '_', 'r', 'i', 'g', 'h', 't', '=', 'c', 'a', 's', 't', '#', '1', '(', '.',
+ 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'R', 'I', 'G', 'H',
+ 'T', ')', '|', 'c', 'a', 's', 't', '#', '1', '(', 's', 'p', 'o', 't', '_', 'l', 'e',
+ 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n',
+ 'e', ' ', 's', 'p', 'o', 't', '_', 'r', 'i', 'g', 'h', 't', '=', '(', 'I', 'N', 'S',
+ 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ')', 's', 'p', 'o', 't',
+ '_', 'l', 'e', 'n', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
'o', 'n', 'e', ' ', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p',
- 't', '_', 'r', 'i', 'g', 'h', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'm', 'i', 'n', '#', '1', '(', 's', 'p', 'o',
- 't', '_', 'r', 'i', 'g', 'h', 't', ',', 'm', 'a', 'x', '_', 'c', 'l', 'i', 'p', '_',
- 'a', 'd', 'a', 'p', 't', '_', 'r', 'i', 'g', 'h', 't', ')', ';', 'I', 'N', 'S', 'D',
- 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'l', 'i', 'm', '_', 'c',
- 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'l', 'e', 'f', 't', '=', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'c', 'l', 'i',
- 'p', '#', '1', '<', '1', ',', '2', '1', '4', '7', '4', '8', '3', '6', '4', '7', '>',
- '(', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'l', 'e',
- 'f', 't', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o',
- 'n', 'e', ' ', 'm', 'a', 'x', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_',
- 'r', 'i', 'g', 'h', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
- 'd', ':', 'o', 'n', 'e', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
- ':', 'o', 'n', 'e', '>', 'm', 'a', 'p', '#', '1', '<', '0', ',', '2', '1', '4', '7',
- '4', '8', '3', '6', '4', '7', '>', '(', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_',
- 'q', 'u', 'a', 'l', '_', 'r', 'i', 'g', 'h', 't', ')', ';', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'l', 'i', 'm', '_', 'c', 'l',
- 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'r', 'i', 'g', 'h', 't', '=', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'm', 'i', 'n',
- '#', '1', '(', 's', 'p', 'o', 't', '_', 'r', 'i', 'g', 'h', 't', ',', 'm', 'a', 'x',
- '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'r', 'i', 'g', 'h', 't', ')',
- ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ',
- 'm', 'a', 'x', '_', 'c', 'l', 'i', 'p', '_', 'l', 'e', 'f', 't', '=', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'm', 'a', 'x',
- '#', '1', '(', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't',
- '_', 'l', 'e', 'f', 't', ',', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u',
- 'a', 'l', '_', 'l', 'e', 'f', 't', ')', '|', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p',
- '_', 'a', 'd', 'a', 'p', 't', '_', 'l', 'e', 'f', 't', '|', 'l', 'i', 'm', '_', 'c',
- 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'l', 'e', 'f', 't', ';', 'I', 'N', 'S',
- 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'm', 'a', 'x',
- '_', 'z', 'c', 'l', 'i', 'p', '_', 'l', 'e', 'f', 't', '=', '(', 'I', 'N', 'S', 'D',
- 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ')', '<', 'I', '3', '2',
- '>', 'd', 'i', 'f', 'f', '#', '1', '<', '1', '>', '(', 'm', 'a', 'x', '_', 'c', 'l',
- 'i', 'p', '_', 'l', 'e', 'f', 't', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'm', 'i', 'n', '_', 'c', 'l', 'i', 'p', '_',
- 'r', 'i', 'g', 'h', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
- 'd', ':', 'o', 'n', 'e', '>', 'm', 'i', 'n', '#', '1', '(', 'l', 'i', 'm', '_', 'c',
- 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'r', 'i', 'g', 'h', 't', ',', 'l',
- 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'r', 'i', 'g', 'h',
- 't', ')', '|', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't',
- '_', 'r', 'i', 'g', 'h', 't', '|', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'q',
- 'u', 'a', 'l', '_', 'r', 'i', 'g', 'h', 't', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'b', 'i', 'o', '_', 's', 't', 'a',
- 'r', 't', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'b', 'i', 'o', '_', 's',
- 't', 'a', 'r', 't', '#', '1', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's',
- 't', 'a', 'r', 't', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p',
- 'e', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e',
- 'r', 'o', ' ', 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't', '=', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', '>', 'm', 'a',
- 'x', '#', '1', '(', 'b', 'i', 'o', '_', 's', 't', 'a', 'r', 't', ',', 'm', 'a', 'x',
- '_', 'z', 'c', 'l', 'i', 'p', '_', 'l', 'e', 'f', 't', ')', '|', 'b', 'i', 'o', '_',
- 's', 't', 'a', 'r', 't', ';', 'I', '3', '2', ' ', 't', 'r', 'i', 'm', '_', 's', 't',
- 'o', 'p', '=', '<', 'I', '3', '2', '>', 'm', 'a', 'x', '#', '1', '(', 'm', 'i', 'n',
- '_', 'c', 'l', 'i', 'p', '_', 'r', 'i', 'g', 'h', 't', ',', 't', 'r', 'i', 'm', '_',
- 's', 't', 'a', 'r', 't', ')', '|', 's', 'p', 'o', 't', '_', 'r', 'i', 'g', 'h', 't',
- ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ',
- 't', 'r', 'i', 'm', '_', 'l', 'e', 'n', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ')', '<', 'I', '3', '2', '>', 'd', 'i', 'f',
- 'f', '#', '1', '(', 't', 'r', 'i', 'm', '_', 's', 't', 'o', 'p', ',', 't', 'r', 'i',
- 'm', '_', 's', 't', 'a', 'r', 't', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'c', 'o', 'm',
- 'm', 'o', 'n', '#', '1', '.', '0', '.', '4', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S',
- 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#', '1', '.', '0', '.', '3', ',',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 'c', 'l', 'i', 'p',
- '#', '1', '.', '0', '.', '2', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S',
- 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'F', 'L', 'O', 'W', '_',
- 'C', 'H', 'A', 'R', 'S', ' ', '=', ' ', 'o', 'u', 't', '_', 'f', 'l', 'o', 'w', '_',
- 'c', 'h', 'a', 'r', 's', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D',
- 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'K', 'E', 'Y', '_', 'S', 'E',
- 'Q', 'U', 'E', 'N', 'C', 'E', ' ', '=', ' ', 'o', 'u', 't', '_', 'k', 'e', 'y', '_',
- 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I',
- 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'L', 'I', 'N',
- 'K', 'E', 'R', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ' ', '=', ' ', 'o', 'u',
- 't', '_', 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e',
- ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'i', 's', 'a', 'm',
- 'p', '1', ' ', 'S', 'I', 'G', 'N', 'A', 'L', ' ', '=', ' ', 'o', 'u', 't', '_', 's',
- 'i', 'g', 'n', 'a', 'l', ';', 'a', 's', 'c', 'i', 'i', ' ', 'p', 'l', 'a', 't', 'f',
- 'o', 'r', 'm', '_', 'n', 'a', 'm', 'e', '=', '<', 'a', 's', 'c', 'i', 'i', '>', 'e',
- 'c', 'h', 'o', '#', '1', '<', '\'', '4', '5', '4', '\'', '>', '(', ')', ';', 'I',
- 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'i', 'n', '_',
- 'f', 'l', 'o', 'w', '_', 'c', 'h', 'a', 'r', 's', '=', '<', 'I', 'N', 'S', 'D', 'C',
- ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'd',
- 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<', '\'', 'a',
- 'c', 'g', 't', 'n', '.', '\'', ',', '\'', 'A', 'C', 'G', 'T', 'N', 'N', '\'', '>',
- '(', 'F', 'L', 'O', 'W', '_', 'C', 'H', 'A', 'R', 'S', ')', ';', 'I', 'N', 'S', 'D',
- 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'i', 'n', '_', 'k', 'e', 'y',
- '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '=', '<', 'I', 'N', 'S', 'D', 'C', ':',
- 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n',
- 'a', ':', 't', 'e', 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<', '\'', 'a', 'c',
- 'g', 't', 'n', '.', '\'', ',', '\'', 'A', 'C', 'G', 'T', 'N', 'N', '\'', '>', '(',
- 'K', 'E', 'Y', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ')', ';', 'I', 'N', 'S',
- 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'i', 'n', '_', 'l', 'i',
- 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '=', '<', 'I', 'N',
+ 't', '_', 'l', 'e', 'f', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
+ 'r', 'd', ':', 'o', 'n', 'e', '>', 'c', 'l', 'i', 'p', '#', '1', '<', '1', ',', '2',
+ '1', '4', '7', '4', '8', '3', '6', '4', '7', '>', '(', 'o', 'u', 't', '_', 'c', 'l',
+ 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'l', 'e', 'f', 't', ')', ';', 'I', 'N',
+ 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'm', 'a', 'x',
+ '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'r', 'i', 'g', 'h', 't',
+ '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e',
+ ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>',
+ 'm', 'a', 'p', '#', '1', '<', '0', ',', '2', '1', '4', '7', '4', '8', '3', '6', '4',
+ '7', '>', '(', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't',
+ '_', 'r', 'i', 'g', 'h', 't', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
+ 'r', 'd', ':', 'o', 'n', 'e', ' ', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'a',
+ 'd', 'a', 'p', 't', '_', 'r', 'i', 'g', 'h', 't', '=', '<', 'I', 'N', 'S', 'D', 'C',
+ ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'm', 'i', 'n', '#', '1', '(',
+ 's', 'p', 'o', 't', '_', 'r', 'i', 'g', 'h', 't', ',', 'm', 'a', 'x', '_', 'c', 'l',
+ 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'r', 'i', 'g', 'h', 't', ')', ';', 'I',
+ 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'l', 'i',
+ 'm', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'l', 'e', 'f', 't', '=',
+ '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>',
+ 'c', 'l', 'i', 'p', '#', '1', '<', '1', ',', '2', '1', '4', '7', '4', '8', '3', '6',
+ '4', '7', '>', '(', 'o', 'u', 't', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l',
+ '_', 'l', 'e', 'f', 't', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'o', 'n', 'e', ' ', 'm', 'a', 'x', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u',
+ 'a', 'l', '_', 'r', 'i', 'g', 'h', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c',
+ 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ',', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
+ 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'm', 'a', 'p', '#', '1', '<', '0', ',', '2',
+ '1', '4', '7', '4', '8', '3', '6', '4', '7', '>', '(', 'o', 'u', 't', '_', 'c', 'l',
+ 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'r', 'i', 'g', 'h', 't', ')', ';', 'I', 'N',
+ 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'l', 'i', 'm',
+ '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'r', 'i', 'g', 'h', 't', '=',
+ '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>',
+ 'm', 'i', 'n', '#', '1', '(', 's', 'p', 'o', 't', '_', 'r', 'i', 'g', 'h', 't', ',',
+ 'm', 'a', 'x', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'r', 'i', 'g',
+ 'h', 't', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o',
+ 'n', 'e', ' ', 'm', 'a', 'x', '_', 'c', 'l', 'i', 'p', '_', 'l', 'e', 'f', 't', '=',
+ '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>',
+ 'm', 'a', 'x', '#', '1', '(', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd',
+ 'a', 'p', 't', '_', 'l', 'e', 'f', 't', ',', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p',
+ '_', 'q', 'u', 'a', 'l', '_', 'l', 'e', 'f', 't', ')', '|', 'l', 'i', 'm', '_', 'c',
+ 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'l', 'e', 'f', 't', '|', 'l', 'i',
+ 'm', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'l', 'e', 'f', 't', ';',
+ 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ',
+ 'm', 'a', 'x', '_', 'z', 'c', 'l', 'i', 'p', '_', 'l', 'e', 'f', 't', '=', '(', 'I',
+ 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ')', '<',
+ 'I', '3', '2', '>', 'd', 'i', 'f', 'f', '#', '1', '<', '1', '>', '(', 'm', 'a', 'x',
+ '_', 'c', 'l', 'i', 'p', '_', 'l', 'e', 'f', 't', ')', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', ' ', 'm', 'i', 'n', '_', 'c', 'l',
+ 'i', 'p', '_', 'r', 'i', 'g', 'h', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c',
+ 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'm', 'i', 'n', '#', '1', '(', 'l', 'i',
+ 'm', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd', 'a', 'p', 't', '_', 'r', 'i', 'g', 'h',
+ 't', ',', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'q', 'u', 'a', 'l', '_', 'r',
+ 'i', 'g', 'h', 't', ')', '|', 'l', 'i', 'm', '_', 'c', 'l', 'i', 'p', '_', 'a', 'd',
+ 'a', 'p', 't', '_', 'r', 'i', 'g', 'h', 't', '|', 'l', 'i', 'm', '_', 'c', 'l', 'i',
+ 'p', '_', 'q', 'u', 'a', 'l', '_', 'r', 'i', 'g', 'h', 't', ';', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'b', 'i', 'o', '_',
+ 's', 't', 'a', 'r', 't', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'b', 'i',
+ 'o', '_', 's', 't', 'a', 'r', 't', '#', '1', '(', 'o', 'u', 't', '_', 'r', 'e', 'a',
+ 'd', '_', 's', 't', 'a', 'r', 't', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_',
+ 't', 'y', 'p', 'e', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'z', 'e', 'r', 'o', ' ', 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't', '=',
+ '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o',
+ '>', 'm', 'a', 'x', '#', '1', '(', 'b', 'i', 'o', '_', 's', 't', 'a', 'r', 't', ',',
+ 'm', 'a', 'x', '_', 'z', 'c', 'l', 'i', 'p', '_', 'l', 'e', 'f', 't', ')', '|', 'b',
+ 'i', 'o', '_', 's', 't', 'a', 'r', 't', ';', 'I', '3', '2', ' ', 't', 'r', 'i', 'm',
+ '_', 's', 't', 'o', 'p', '=', '<', 'I', '3', '2', '>', 'm', 'a', 'x', '#', '1', '(',
+ 'm', 'i', 'n', '_', 'c', 'l', 'i', 'p', '_', 'r', 'i', 'g', 'h', 't', ',', 't', 'r',
+ 'i', 'm', '_', 's', 't', 'a', 'r', 't', ')', '|', 's', 'p', 'o', 't', '_', 'r', 'i',
+ 'g', 'h', 't', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l',
+ 'e', 'n', ' ', 't', 'r', 'i', 'm', '_', 'l', 'e', 'n', '=', '(', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ')', '<', 'I', '3', '2', '>',
+ 'd', 'i', 'f', 'f', '#', '1', '(', 't', 'r', 'i', 'm', '_', 's', 't', 'o', 'p', ',',
+ 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't', ')', ';', '}', 't', 'a', 'b', 'l',
+ 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':',
+ 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.', '4', '=', 'I', 'N', 'S', 'D',
+ 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#', '1', '.', '0',
+ '.', '3', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 'c',
+ 'l', 'i', 'p', '#', '1', '.', '0', '.', '2', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
+ 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'F', 'L',
+ 'O', 'W', '_', 'C', 'H', 'A', 'R', 'S', ' ', '=', ' ', 'o', 'u', 't', '_', 'f', 'l',
+ 'o', 'w', '_', 'c', 'h', 'a', 'r', 's', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I',
+ 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'K', 'E', 'Y',
+ '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ' ', '=', ' ', 'o', 'u', 't', '_', 'k',
+ 'e', 'y', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', ';', 'c', 'o', 'l', 'u', 'm',
+ 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ',
+ 'L', 'I', 'N', 'K', 'E', 'R', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ' ', '=',
+ ' ', 'o', 'u', 't', '_', 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e',
+ 'n', 'c', 'e', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'i',
+ 's', 'a', 'm', 'p', '1', ' ', 'S', 'I', 'G', 'N', 'A', 'L', ' ', '=', ' ', 'o', 'u',
+ 't', '_', 's', 'i', 'g', 'n', 'a', 'l', ';', 'a', 's', 'c', 'i', 'i', ' ', 'p', 'l',
+ 'a', 't', 'f', 'o', 'r', 'm', '_', 'n', 'a', 'm', 'e', '=', '<', 'a', 's', 'c', 'i',
+ 'i', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'', '4', '5', '4', '\'', '>', '(',
+ ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ',
+ 'i', 'n', '_', 'f', 'l', 'o', 'w', '_', 'c', 'h', 'a', 'r', 's', '=', '<', 'I', 'N',
'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ',', 'I', 'N', 'S', 'D',
'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<',
'\'', 'a', 'c', 'g', 't', 'n', '.', '\'', ',', '\'', 'A', 'C', 'G', 'T', 'N', 'N',
- '\'', '>', '(', 'L', 'I', 'N', 'K', 'E', 'R', '_', 'S', 'E', 'Q', 'U', 'E', 'N',
- 'C', 'E', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i',
- 'n', ' ', 'o', 'u', 't', '_', 'f', 'l', 'o', 'w', '_', 'b', 'i', 'n', '=', '<', 'I',
- 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ',', 'I', 'N', 'S',
- 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1',
- '<', '\'', 'A', 'C', 'G', 'T', 'N', '\'', ',', '[', '0', ',', '1', ',', '2', ',',
- '3', ',', '4', ']', '>', '(', 'o', 'u', 't', '_', 'f', 'l', 'o', 'w', '_', 'c', 'h',
- 'a', 'r', 's', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b',
- 'i', 'n', ' ', 'o', 'u', 't', '_', 'k', 'e', 'y', '_', 'b', 'i', 'n', '=', '<', 'I',
- 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ',', 'I', 'N', 'S',
- 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p', '#', '1',
- '<', '\'', 'A', 'C', 'G', 'T', 'N', '\'', ',', '[', '0', ',', '1', ',', '2', ',',
- '3', ',', '4', ']', '>', '(', 'o', 'u', 't', '_', 'k', 'e', 'y', '_', 's', 'e', 'q',
- 'u', 'e', 'n', 'c', 'e', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a',
- ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', 'l', 'i', 'n', 'k', 'e', 'r', '_', 'b',
- 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x',
- 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', '>',
- 'm', 'a', 'p', '#', '1', '<', '\'', 'A', 'C', 'G', 'T', 'N', '\'', ',', '[', '0',
- ',', '1', ',', '2', ',', '3', ',', '4', ']', '>', '(', 'o', 'u', 't', '_', 'l', 'i',
- 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', ')', ';', 'N', 'C',
- 'B', 'I', ':', 'i', 's', 'a', 'm', 'p', '1', ' ', 'o', 'u', 't', '_', 's', 'i', 'g',
- 'n', 'a', 'l', '=', '.', 'S', 'I', 'G', 'N', 'A', 'L', ';', '}', 't', 'a', 'b', 'l',
- 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':',
- 't', 'b', 'l', ':', 'v', '2', '#', '1', '.', '0', '.', '7', '=', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '_', 'n', 'o', 'p', 'o',
- 's', '#', '2', '.', '1', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':',
- 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '#', '2', '.', '0', '.', '3', ',',
- 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u',
- 'a', 'l', 'i', 't', 'y', '#', '2', '.', '0', '.', '4', ',', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'c', 'o', 'm', 'm', 'o', 'n', '#',
- '1', '.', '0', '.', '4', '{', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o',
- 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
- 'v', 'a', 'l', ' ', 'R', 'E', 'G', 'I', 'O', 'N', ' ', '=', ' ', '(', 'I', 'N', 'S',
- 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n', 'a', 'm', 'e',
- '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '6', '>', '(', '_', 'o', 'u', 't', '_',
- 'n', 'a', 'm', 'e', ',', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm',
- 'e', '_', 't', 'o', 'k', ')', ';', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n',
- ' ', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o',
- 'k', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':',
- 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm',
- 'e', '#', '1', '(', '_', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', ')', ';', 't', 'e',
- 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'i', 'n', '_', 's', 'p', 'o', 't', '_',
- 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', '_', '4', '5', '4', '_', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's',
- 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', 'N', 'A', 'M', 'E', ')', ';',
- 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o', 'u',
- 't', '_', 'f', 'l', 'o', 'w', '_', 'c', 'h', 'a', 'r', 's', '=', '.', 'F', 'L', 'O',
- 'W', '_', 'C', 'H', 'A', 'R', 'S', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n',
- 'a', ':', 't', 'e', 'x', 't', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'', 'T',
- 'A', 'C', 'G', '\'', '>', '(', '.', 'S', 'I', 'G', 'N', 'A', 'L', ')', '|', '<',
- 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'e', 'c',
- 'h', 'o', '#', '1', '<', '\'', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A',
+ '\'', '>', '(', 'F', 'L', 'O', 'W', '_', 'C', 'H', 'A', 'R', 'S', ')', ';', 'I',
+ 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'i', 'n', '_',
+ 'k', 'e', 'y', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '=', '<', 'I', 'N', 'S',
+ 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ',', 'I', 'N', 'S', 'D', 'C',
+ ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'm', 'a', 'p', '#', '1', '<', '\'',
+ 'a', 'c', 'g', 't', 'n', '.', '\'', ',', '\'', 'A', 'C', 'G', 'T', 'N', 'N', '\'',
+ '>', '(', 'K', 'E', 'Y', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ')', ';', 'I',
+ 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'i', 'n', '_',
+ 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '=', '<',
+ 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ',', 'I', 'N',
+ 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'm', 'a', 'p', '#',
+ '1', '<', '\'', 'a', 'c', 'g', 't', 'n', '.', '\'', ',', '\'', 'A', 'C', 'G', 'T',
+ 'N', 'N', '\'', '>', '(', 'L', 'I', 'N', 'K', 'E', 'R', '_', 'S', 'E', 'Q', 'U',
+ 'E', 'N', 'C', 'E', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':',
+ 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', 'f', 'l', 'o', 'w', '_', 'b', 'i', 'n', '=',
+ '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ',', 'I',
+ 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p',
+ '#', '1', '<', '\'', 'A', 'C', 'G', 'T', 'N', '\'', ',', '[', '0', ',', '1', ',',
+ '2', ',', '3', ',', '4', ']', '>', '(', 'o', 'u', 't', '_', 'f', 'l', 'o', 'w', '_',
+ 'c', 'h', 'a', 'r', 's', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a',
+ ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', 'k', 'e', 'y', '_', 'b', 'i', 'n', '=',
+ '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ',', 'I',
+ 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i', 'n', '>', 'm', 'a', 'p',
+ '#', '1', '<', '\'', 'A', 'C', 'G', 'T', 'N', '\'', ',', '[', '0', ',', '1', ',',
+ '2', ',', '3', ',', '4', ']', '>', '(', 'o', 'u', 't', '_', 'k', 'e', 'y', '_', 's',
+ 'e', 'q', 'u', 'e', 'n', 'c', 'e', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2',
+ 'n', 'a', ':', 'b', 'i', 'n', ' ', 'o', 'u', 't', '_', 'l', 'i', 'n', 'k', 'e', 'r',
+ '_', 'b', 'i', 'n', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't',
+ 'e', 'x', 't', ',', 'I', 'N', 'S', 'D', 'C', ':', 'x', '2', 'n', 'a', ':', 'b', 'i',
+ 'n', '>', 'm', 'a', 'p', '#', '1', '<', '\'', 'A', 'C', 'G', 'T', 'N', '\'', ',',
+ '[', '0', ',', '1', ',', '2', ',', '3', ',', '4', ']', '>', '(', 'o', 'u', 't', '_',
+ 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', ')', ';',
+ 'N', 'C', 'B', 'I', ':', 'i', 's', 'a', 'm', 'p', '1', ' ', 'o', 'u', 't', '_', 's',
+ 'i', 'g', 'n', 'a', 'l', '=', '.', 'S', 'I', 'G', 'N', 'A', 'L', ';', '}', 't', 'a',
+ 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4',
+ '_', ':', 't', 'b', 'l', ':', 'v', '2', '#', '1', '.', '0', '.', '7', '=', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '_', 'n', 'o',
+ 'p', 'o', 's', '#', '2', '.', '1', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b',
+ 'l', ':', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '#', '2', '.', '0', '.',
+ '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'p', 'h', 'r', 'e', 'd', '_',
+ 'q', 'u', 'a', 'l', 'i', 't', 'y', '#', '2', '.', '0', '.', '4', ',', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'c', 'o', 'm', 'm', 'o',
+ 'n', '#', '1', '.', '0', '.', '4', '{', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ',
+ 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'v', 'a', 'l', ' ', 'R', 'E', 'G', 'I', 'O', 'N', ' ', '=', ' ', '(', 'I',
+ 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n', 'a',
+ 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '6', '>', '(', '_', 'o', 'u',
+ 't', '_', 'n', 'a', 'm', 'e', ',', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n',
+ 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', 't', 'e', 'x', 't', ':', 't', 'o', 'k',
+ 'e', 'n', ' ', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_',
+ 't', 'o', 'k', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4',
+ '_', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_', 'n',
+ 'a', 'm', 'e', '#', '1', '(', '_', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', ')', ';',
+ 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'i', 'n', '_', 's', 'p', 'o',
+ 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', '=', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e',
+ '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', 'N', 'A', 'M', 'E',
+ ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ',
+ 'o', 'u', 't', '_', 'f', 'l', 'o', 'w', '_', 'c', 'h', 'a', 'r', 's', '=', '.', 'F',
+ 'L', 'O', 'W', '_', 'C', 'H', 'A', 'R', 'S', '|', '<', 'I', 'N', 'S', 'D', 'C', ':',
+ 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'',
+ 'T', 'A', 'C', 'G', '\'', '>', '(', '.', 'S', 'I', 'G', 'N', 'A', 'L', ')', '|',
+ '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'e',
+ 'c', 'h', 'o', '#', '1', '<', '\'', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T',
+ 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A',
'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C',
'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G',
'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T',
@@ -3028,1056 +3041,1055 @@ const char sra_schema_text[] = {
'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A',
'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C',
'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G',
- 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', 'T', 'A', 'C', 'G', '\'',
- '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x',
- 't', ' ', 'o', 'u', 't', '_', 'k', 'e', 'y', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c',
- 'e', '=', '.', 'K', 'E', 'Y', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', '|', '<',
- 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'e', 'c',
- 'h', 'o', '#', '1', '<', '\'', 'T', 'C', 'A', 'G', '\'', '>', '(', ')', ';', 'I',
- 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o', 'u', 't',
- '_', 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '=',
- '.', 'L', 'I', 'N', 'K', 'E', 'R', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ';',
- 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n',
- 'e', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '=', '.', 'P',
- 'O', 'S', 'I', 'T', 'I', 'O', 'N', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
- 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a',
- ':', 't', 'e', 'x', 't', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n',
- 'g', '#', '1', ' ', '.', 'F', 'L', 'O', 'W', '_', 'C', 'H', 'A', 'R', 'S', '=', 'i',
- 'n', '_', 'f', 'l', 'o', 'w', '_', 'c', 'h', 'a', 'r', 's', ';', 'p', 'h', 'y', 's',
- 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D',
- 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'z', 'i', 'p', '_', 'e', 'n',
- 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'K', 'E', 'Y', '_', 'S', 'E', 'Q',
- 'U', 'E', 'N', 'C', 'E', '=', 'i', 'n', '_', 'k', 'e', 'y', '_', 's', 'e', 'q', 'u',
+ '\'', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't',
+ 'e', 'x', 't', ' ', 'o', 'u', 't', '_', 'k', 'e', 'y', '_', 's', 'e', 'q', 'u', 'e',
+ 'n', 'c', 'e', '=', '.', 'K', 'E', 'Y', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E',
+ '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>',
+ 'e', 'c', 'h', 'o', '#', '1', '<', '\'', 'T', 'C', 'A', 'G', '\'', '>', '(', ')',
+ ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o',
+ 'u', 't', '_', 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c',
+ 'e', '=', '.', 'L', 'I', 'N', 'K', 'E', 'R', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C',
+ 'E', ';', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':',
+ 'o', 'n', 'e', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '=',
+ '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a',
+ 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd',
+ 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd',
+ 'i', 'n', 'g', '#', '1', ' ', '.', 'F', 'L', 'O', 'W', '_', 'C', 'H', 'A', 'R', 'S',
+ '=', 'i', 'n', '_', 'f', 'l', 'o', 'w', '_', 'c', 'h', 'a', 'r', 's', ';', 'p', 'h',
+ 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N',
+ 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'z', 'i', 'p', '_',
+ 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'K', 'E', 'Y', '_', 'S',
+ 'E', 'Q', 'U', 'E', 'N', 'C', 'E', '=', 'i', 'n', '_', 'k', 'e', 'y', '_', 's', 'e',
+ 'q', 'u', 'e', 'n', 'c', 'e', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c',
+ 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':',
+ 't', 'e', 'x', 't', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g',
+ '#', '1', ' ', '.', 'L', 'I', 'N', 'K', 'E', 'R', '_', 'S', 'E', 'Q', 'U', 'E', 'N',
+ 'C', 'E', '=', 'i', 'n', '_', 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u',
'e', 'n', 'c', 'e', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l',
- 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e',
- 'x', 't', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1',
- ' ', '.', 'L', 'I', 'N', 'K', 'E', 'R', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E',
- '=', 'i', 'n', '_', 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n',
- 'c', 'e', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm',
- 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':',
- 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N',
- '#', '2', ' ', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', '=', 'P', 'O', 'S', 'I',
- 'T', 'I', 'O', 'N', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l',
- 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4',
- '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C', 'L', 'I', 'P', '#', '2',
- ' ', '.', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'L', 'E',
- 'F', 'T', '=', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'L',
- 'E', 'F', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u',
- 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_',
- ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C', 'L', 'I', 'P', '#', '2', ' ',
- '.', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'R', 'I', 'G',
- 'H', 'T', '=', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'R',
- 'I', 'G', 'H', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l',
'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4',
- '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C', 'L', 'I', 'P', '#', '2',
- ' ', '.', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'L', 'E',
- 'F', 'T', '=', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'L',
- 'E', 'F', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u',
- 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_',
- ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C', 'L', 'I', 'P', '#', '2', ' ',
- '.', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'R', 'I', 'G',
- 'H', 'T', '=', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'R',
- 'I', 'G', 'H', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l',
- 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4',
- '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'S', 'I', 'G', 'N', 'A', 'L',
- '#', '2', ' ', '.', 'S', 'I', 'G', 'N', 'A', 'L', '=', 'S', 'I', 'G', 'N', 'A', 'L',
- ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'q', 'u', 'a', 'l', '4', '_', 'n', 'o',
- 'c', 'o', 'l', '#', '1', '.', '0', '.', '1', '=', 'I', 'N', 'S', 'D', 'C', ':', 't',
- 'b', 'l', ':', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0', '.', '1',
- ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd',
- 's', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_', 'n', 'o', 'c', 'o', 'l', '#', '1',
- '.', '0', '.', '1', '{', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l',
- 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', '4', ' ', 'Q', 'U',
- 'A', 'L', 'I', 'T', 'Y', ' ', '=', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4',
- ';', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', '4', ' ', 'o', 'u', 't', '_', 'q',
- 'u', 'a', 'l', '4', '=', '<', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', '4', '>',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(', 'o',
- 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 's', 'w', 'a', 'p', 'p', 'e', 'd', ',',
- 'r', 'e', 'a', 'd', '_', 'u', 'n', 'p', 'a', 'c', 'k', ')', '|', '<', 'N', 'C', 'B',
- 'I', ':', 'q', 'u', 'a', 'l', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'r', 'o', 't', 'a', 't', 'e', '#', '1', '<', 'f', 'a', 'l', 's', 'e', '>', '(', 'o',
- 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 'r', 'o', 't', 'a', 't', 'e', 'd', ',',
- 'r', 'e', 'a', 'd', '_', 'u', 'n', 'p', 'a', 'c', 'k', ')', ';', 'I', 'N', 'S', 'D',
- 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd',
- 's', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '1', '_', 'c', 'h', '0', '=', '<',
- 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g',
- '_', 'o', 'd', 'd', 's', '>', 'c', 'u', 't', '#', '1', '<', '0', '>', '(', 'o', 'u',
- 't', '_', 'q', 'u', 'a', 'l', '4', '_', 's', 'w', 'a', 'p', 'p', 'e', 'd', ')', '|',
- '<', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o',
- 'g', '_', 'o', 'd', 'd', 's', '>', 'c', 'u', 't', '#', '1', '<', '0', '>', '(', 'o',
- 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 'r', 'o', 't', 'a', 't', 'e', 'd', ')',
- ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o',
- 'g', '_', 'o', 'd', 'd', 's', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '1', '_',
- 'c', 'l', 'i', 'p', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i',
- 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '>', 'c', 'l', 'i', 'p', '#',
- '1', '<', '-', '5', ',', '1', '2', '7', '>', '(', 'o', 'u', 't', '_', 'q', 'u', 'a',
- 'l', '1', '_', 'c', 'h', '0', ')', ';', 'U', '3', '2', ' ', 'o', 'u', 't', '_', 'q',
- 'u', 'a', 'l', '4', '_', '3', '2', '=', 'r', 'e', 'd', 'i', 'm', 'e', 'n', 's', 'i',
- 'o', 'n', '#', '1', '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 's', 'w',
- 'a', 'p', 'p', 'e', 'd', ')', '|', 'r', 'e', 'd', 'i', 'm', 'e', 'n', 's', 'i', 'o',
- 'n', '#', '1', '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 'r', 'o', 't',
- 'a', 't', 'e', 'd', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i',
+ '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'P', 'O', 'S', 'I', 'T', 'I',
+ 'O', 'N', '#', '2', ' ', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', '=', 'P', 'O',
+ 'S', 'I', 'T', 'I', 'O', 'N', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c',
+ 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4',
+ '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C', 'L', 'I', 'P',
+ '#', '2', ' ', '.', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_',
+ 'L', 'E', 'F', 'T', '=', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R',
+ '_', 'L', 'E', 'F', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5',
+ '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C', 'L', 'I', 'P', '#',
+ '2', ' ', '.', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'R',
+ 'I', 'G', 'H', 'T', '=', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T', 'E', 'R',
+ '_', 'R', 'I', 'G', 'H', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c',
+ 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4',
+ '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C', 'L', 'I', 'P',
+ '#', '2', ' ', '.', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_',
+ 'L', 'E', 'F', 'T', '=', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y',
+ '_', 'L', 'E', 'F', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5',
+ '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C', 'L', 'I', 'P', '#',
+ '2', ' ', '.', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'R',
+ 'I', 'G', 'H', 'T', '=', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y',
+ '_', 'R', 'I', 'G', 'H', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c',
+ 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4',
+ '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'S', 'I', 'G', 'N',
+ 'A', 'L', '#', '2', ' ', '.', 'S', 'I', 'G', 'N', 'A', 'L', '=', 'S', 'I', 'G', 'N',
+ 'A', 'L', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'q', 'u', 'a', 'l', '4', '_',
+ 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '1', '=', 'I', 'N', 'S', 'D', 'C',
+ ':', 't', 'b', 'l', ':', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '#', '1', '.', '0',
+ '.', '1', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'l', 'o', 'g', '_', 'o',
+ 'd', 'd', 's', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_', 'n', 'o', 'c', 'o', 'l',
+ '#', '1', '.', '0', '.', '1', '{', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c',
+ 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', '4', ' ',
+ 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ' ', '=', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a',
+ 'l', '4', ';', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', '4', ' ', 'o', 'u', 't',
+ '_', 'q', 'u', 'a', 'l', '4', '=', '<', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l',
+ '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1',
+ '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 's', 'w', 'a', 'p', 'p', 'e',
+ 'd', ',', 'r', 'e', 'a', 'd', '_', 'u', 'n', 'p', 'a', 'c', 'k', ')', '|', '<', 'N',
+ 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'r', 'o', 't', 'a', 't', 'e', '#', '1', '<', 'f', 'a', 'l', 's', 'e', '>',
+ '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 'r', 'o', 't', 'a', 't', 'e',
+ 'd', ',', 'r', 'e', 'a', 'd', '_', 'u', 'n', 'p', 'a', 'c', 'k', ')', ';', 'I', 'N',
+ 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o',
+ 'd', 'd', 's', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '1', '_', 'c', 'h', '0',
+ '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l',
+ 'o', 'g', '_', 'o', 'd', 'd', 's', '>', 'c', 'u', 't', '#', '1', '<', '0', '>', '(',
+ 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 's', 'w', 'a', 'p', 'p', 'e', 'd',
+ ')', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':',
+ 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '>', 'c', 'u', 't', '#', '1', '<', '0', '>',
+ '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 'r', 'o', 't', 'a', 't', 'e',
+ 'd', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':',
+ 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l',
+ '1', '_', 'c', 'l', 'i', 'p', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a',
+ 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '>', 'c', 'l', 'i',
+ 'p', '#', '1', '<', '-', '5', ',', '1', '2', '7', '>', '(', 'o', 'u', 't', '_', 'q',
+ 'u', 'a', 'l', '1', '_', 'c', 'h', '0', ')', ';', 'U', '3', '2', ' ', 'o', 'u', 't',
+ '_', 'q', 'u', 'a', 'l', '4', '_', '3', '2', '=', 'r', 'e', 'd', 'i', 'm', 'e', 'n',
+ 's', 'i', 'o', 'n', '#', '1', '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_',
+ 's', 'w', 'a', 'p', 'p', 'e', 'd', ')', '|', 'r', 'e', 'd', 'i', 'm', 'e', 'n', 's',
+ 'i', 'o', 'n', '#', '1', '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 'r',
+ 'o', 't', 'a', 't', 'e', 'd', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a',
+ 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'o', 'u', 't',
+ '_', 'q', 'u', 'a', 'l', '1', '_', 'f', 'i', 'v', 'e', 's', '=', '<', 'U', '3', '2',
+ ',', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o',
+ 'g', '_', 'o', 'd', 'd', 's', '>', 'm', 'a', 'p', '#', '1', '<', '4', '2', '2', '7',
+ '5', '9', '5', '2', '5', '9', ',', '-', '6', '>', '(', 'o', 'u', 't', '_', 'q', 'u',
+ 'a', 'l', '4', '_', '3', '2', ',', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '1', '_',
+ 'c', 'l', 'i', 'p', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i',
't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'o', 'u', 't', '_', 'q',
- 'u', 'a', 'l', '1', '_', 'f', 'i', 'v', 'e', 's', '=', '<', 'U', '3', '2', ',', 'I',
- 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_',
- 'o', 'd', 'd', 's', '>', 'm', 'a', 'p', '#', '1', '<', '4', '2', '2', '7', '5', '9',
- '5', '2', '5', '9', ',', '-', '6', '>', '(', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l',
- '4', '_', '3', '2', ',', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '1', '_', 'c', 'l',
- 'i', 'p', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y',
- ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a',
- 'l', '1', '_', 'n', '=', '<', 'U', '8', ',', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u',
- 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '>', 'm', 'a',
- 'p', '#', '1', '<', '[', '1', ',', '2', ',', '3', ']', ',', '[', '0', ',', '0', ',',
- '0', ']', '>', '(', 'r', 'e', 'a', 'd', '_', 'u', 'n', 'p', 'a', 'c', 'k', ',', 'o',
- 'u', 't', '_', 'q', 'u', 'a', 'l', '1', '_', 'f', 'i', 'v', 'e', 's', ')', ';', 'I',
- 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_',
- 'o', 'd', 'd', 's', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g',
- '_', 'o', 'd', 'd', 's', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l',
- 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ',', 'I', 'N', 'S', 'D',
- 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd',
- 's', '>', 'm', 'a', 'p', '#', '1', '<', '-', '6', ',', '-', '6', '>', '(', 'o', 'u',
- 't', '_', 'q', 'u', 'a', 'l', '1', '_', 'n', ',', 'o', 'u', 't', '_', 'q', 'u', 'a',
- 'l', '1', '_', 'c', 'l', 'i', 'p', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':',
- 'q', 'u', 'a', 'l', '4', '#', '1', '.', '0', '.', '1', '=', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'q', 'u', 'a', 'l',
- '4', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '1', '{', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'q', 'u', 'a',
- 'l', '4', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 's', 'w', 'a', 'p',
- 'p', 'e', 'd', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', '}', 't', 'a', 'b',
- 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm',
- 'i', 'n', 'a', ':', 'q', 'u', 'a', 'l', '4', '#', '2', '.', '0', '.', '4', '=', 'N',
- 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c',
- 'e', '#', '2', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':',
- 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_',
- 'n', 'o', 'c', 'o', 'l', '#', '2', '.', '0', '.', '1', '{', 'c', 'o', 'l', 'u', 'm',
- 'n', ' ', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', '4', ' ', 'Q', 'U', 'A', 'L',
- 'I', 'T', 'Y', ' ', '=', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', ';', 'N',
+ 'u', 'a', 'l', '1', '_', 'n', '=', '<', 'U', '8', ',', 'I', 'N', 'S', 'D', 'C', ':',
+ 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '>',
+ 'm', 'a', 'p', '#', '1', '<', '[', '1', ',', '2', ',', '3', ']', ',', '[', '0', ',',
+ '0', ',', '0', ']', '>', '(', 'r', 'e', 'a', 'd', '_', 'u', 'n', 'p', 'a', 'c', 'k',
+ ',', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '1', '_', 'f', 'i', 'v', 'e', 's', ')',
+ ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o',
+ 'g', '_', 'o', 'd', 'd', 's', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'l',
+ 'o', 'g', '_', 'o', 'd', 'd', 's', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u',
+ 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ',', 'I', 'N',
+ 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o',
+ 'd', 'd', 's', '>', 'm', 'a', 'p', '#', '1', '<', '-', '6', ',', '-', '6', '>', '(',
+ 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '1', '_', 'n', ',', 'o', 'u', 't', '_', 'q',
+ 'u', 'a', 'l', '1', '_', 'c', 'l', 'i', 'p', ')', ';', '}', 't', 'a', 'b', 'l', 'e',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n',
+ 'a', ':', 'q', 'u', 'a', 'l', '4', '#', '1', '.', '0', '.', '1', '=', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'q', 'u',
+ 'a', 'l', '4', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '1', '{', 'N',
'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'q',
- 'u', 'a', 'l', '4', ' ', 'i', 'n', '_', 'q', 'u', 'a', 'l', '4', '=', '(', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'q', 'u',
- 'a', 'l', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', '4', '>', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(', 'Q', 'U',
- 'A', 'L', 'I', 'T', 'Y', ',', 'i', 'n', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n',
- ')', '|', '(', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p',
- 'e', 'd', '_', 'q', 'u', 'a', 'l', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'q', 'u',
- 'a', 'l', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p',
- '#', '1', '(', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ',', 'i', 'n', '_', '2', 'n', 'a',
- '_', 'b', 'i', 'n', ')', ';', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', '4', ' ',
- 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '=', '<', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4', '>',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(', '.',
- 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ',', 'o', 'u', 't', '_', 'x', '2', 'n', 'a', '_',
- 'b', 'i', 'n', ')', ';', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', '4', ' ', 'i',
- 'n', '_', 's', 't', 'a', 't', 's', '_', 'q', 'u', 'a', 'l', '=', 'i', 'n', '_', 'q',
- 'u', 'a', 'l', '4', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't',
- 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'o', 'u', 't', '_', 'q', 'u',
- 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '=', '<', 'I', 'N', 'S', 'D',
- 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd',
- 's', '>', 'c', 'u', 't', '#', '1', '<', '0', '>', '(', '.', 'Q', 'U', 'A', 'L', 'I',
- 'T', 'Y', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u',
- 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'q', 'u', 'a', 'l', '4',
- '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'Q', 'U', 'A', 'L',
- 'I', 'T', 'Y', '=', 'i', 'n', '_', 'q', 'u', 'a', 'l', '4', ';', '}', 't', 'a', 'b',
+ 'u', 'a', 'l', '4', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 's', 'w',
+ 'a', 'p', 'p', 'e', 'd', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', '}', 't',
+ 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l',
+ 'u', 'm', 'i', 'n', 'a', ':', 'q', 'u', 'a', 'l', '4', '#', '2', '.', '0', '.', '4',
+ '=', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'b', 'a', 's', 'e', '_', 's', 'p',
+ 'a', 'c', 'e', '#', '2', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b',
+ 'l', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '_', 'q', 'u', 'a', 'l', 'i', 't',
+ 'y', '_', 'n', 'o', 'c', 'o', 'l', '#', '2', '.', '0', '.', '1', '{', 'c', 'o', 'l',
+ 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', '4', ' ', 'Q', 'U',
+ 'A', 'L', 'I', 'T', 'Y', ' ', '=', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4',
+ ';', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd',
+ '_', 'q', 'u', 'a', 'l', '4', ' ', 'i', 'n', '_', 'q', 'u', 'a', 'l', '4', '=', '(',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_',
+ 'q', 'u', 'a', 'l', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', '4',
+ '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(',
+ 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ',', 'i', 'n', '_', 'x', '2', 'n', 'a', '_', 'b',
+ 'i', 'n', ')', '|', '(', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a',
+ 'p', 'p', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4', ')', '<', 'N', 'C', 'B', 'I', ':',
+ 'q', 'u', 'a', 'l', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w',
+ 'a', 'p', '#', '1', '(', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ',', 'i', 'n', '_', '2',
+ 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l',
+ '4', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '=', '<', 'N', 'C', 'B', 'I',
+ ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'q', 'u', 'a', 'l',
+ '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1',
+ '(', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ',', 'o', 'u', 't', '_', 'x', '2', 'n',
+ 'a', '_', 'b', 'i', 'n', ')', ';', 'N', 'C', 'B', 'I', ':', 'q', 'u', 'a', 'l', '4',
+ ' ', 'i', 'n', '_', 's', 't', 'a', 't', 's', '_', 'q', 'u', 'a', 'l', '=', 'i', 'n',
+ '_', 'q', 'u', 'a', 'l', '4', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l',
+ 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', ' ', 'o', 'u', 't', '_',
+ 'q', 'u', 'a', 'l', '_', 'l', 'o', 'g', '_', 'o', 'd', 'd', 's', '=', '<', 'I', 'N',
+ 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'l', 'o', 'g', '_', 'o',
+ 'd', 'd', 's', '>', 'c', 'u', 't', '#', '1', '<', '0', '>', '(', '.', 'Q', 'U', 'A',
+ 'L', 'I', 'T', 'Y', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'q', 'u', 'a',
+ 'l', '4', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'Q', 'U',
+ 'A', 'L', 'I', 'T', 'Y', '=', 'i', 'n', '_', 'q', 'u', 'a', 'l', '4', ';', '}', 't',
+ 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l',
+ 'u', 'm', 'i', 'n', 'a', ':', 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.',
+ '3', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's',
+ 'r', 'a', '#', '1', '.', '0', '.', '3', '{', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y',
+ ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
+ 'r', 'd', ':', 'v', 'a', 'l', ' ', 'L', 'A', 'N', 'E', ' ', '=', ' ', 'o', 'u', 't',
+ '_', 'l', 'a', 'n', 'e', '_', 'c', 'o', 'o', 'r', 'd', ';', 'r', 'e', 'a', 'd', 'o',
+ 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':',
+ 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'T', 'I', 'L', 'E', ' ', '=', ' ',
+ 'o', 'u', 't', '_', 't', 'i', 'l', 'e', '_', 'c', 'o', 'o', 'r', 'd', ';', 'a', 's',
+ 'c', 'i', 'i', ' ', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'n', 'a', 'm', 'e',
+ '=', '<', 'a', 's', 'c', 'i', 'i', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'',
+ 'I', 'L', 'L', 'U', 'M', 'I', 'N', 'A', '\'', '>', '(', ')', ';', 'I', 'N', 'S',
+ 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'b', 'i', 'o',
+ '_', 's', 't', 'a', 'r', 't', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'b',
+ 'i', 'o', '_', 's', 't', 'a', 'r', 't', '#', '1', '(', 'o', 'u', 't', '_', 'r', 'e',
+ 'a', 'd', '_', 's', 't', 'a', 'r', 't', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd',
+ '_', 't', 'y', 'p', 'e', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'z', 'e', 'r', 'o', ' ', 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't',
+ '=', 'b', 'i', 'o', '_', 's', 't', 'a', 'r', 't', ';', 'U', '3', '2', ' ', 't', 'r',
+ 'i', 'm', '_', 'l', 'e', 'f', 't', '=', '(', 'U', '3', '2', ')', 't', 'r', 'i', 'm',
+ '_', 's', 't', 'a', 'r', 't', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'l', 'e', 'n', ' ', 't', 'r', 'i', 'm', '_', 'l', 'e', 'n', '=', '(', 'I',
+ 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ')', '<', 'U',
+ '3', '2', '>', 'd', 'i', 'f', 'f', '#', '1', '(', 's', 'p', 'o', 't', '_', 'l', 'e',
+ 'n', ',', 't', 'r', 'i', 'm', '_', 'l', 'e', 'f', 't', ')', ';', '}', 't', 'a', 'b',
'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm',
- 'i', 'n', 'a', ':', 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.', '3', '=',
- 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a',
- '#', '1', '.', '0', '.', '3', '{', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ', 'c',
- 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
- ':', 'v', 'a', 'l', ' ', 'L', 'A', 'N', 'E', ' ', '=', ' ', 'o', 'u', 't', '_', 'l',
- 'a', 'n', 'e', '_', 'c', 'o', 'o', 'r', 'd', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l',
- 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'T', 'I', 'L', 'E', ' ', '=', ' ', 'o', 'u',
- 't', '_', 't', 'i', 'l', 'e', '_', 'c', 'o', 'o', 'r', 'd', ';', 'a', 's', 'c', 'i',
- 'i', ' ', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'n', 'a', 'm', 'e', '=', '<',
- 'a', 's', 'c', 'i', 'i', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'', 'I', 'L',
- 'L', 'U', 'M', 'I', 'N', 'A', '\'', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'b', 'i', 'o', '_', 's',
- 't', 'a', 'r', 't', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'b', 'i', 'o',
- '_', 's', 't', 'a', 'r', 't', '#', '1', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd',
- '_', 's', 't', 'a', 'r', 't', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 't',
- 'y', 'p', 'e', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
- 'z', 'e', 'r', 'o', ' ', 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't', '=', 'b',
- 'i', 'o', '_', 's', 't', 'a', 'r', 't', ';', 'U', '3', '2', ' ', 't', 'r', 'i', 'm',
- '_', 'l', 'e', 'f', 't', '=', '(', 'U', '3', '2', ')', 't', 'r', 'i', 'm', '_', 's',
- 't', 'a', 'r', 't', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
- 'l', 'e', 'n', ' ', 't', 'r', 'i', 'm', '_', 'l', 'e', 'n', '=', '(', 'I', 'N', 'S',
- 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ')', '<', 'U', '3', '2',
- '>', 'd', 'i', 'f', 'f', '#', '1', '(', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ',',
- 't', 'r', 'i', 'm', '_', 'l', 'e', 'f', 't', ')', ';', '}', 't', 'a', 'b', 'l', 'e',
- ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n',
- 'a', ':', 't', 'b', 'l', ':', 'v', '2', '#', '1', '.', '0', '.', '4', '=', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#', '2', '.',
- '1', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'b', 'a', 's', 'e',
- '_', 's', 'p', 'a', 'c', 'e', '#', '2', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'c', 'o', 'm',
- 'm', 'o', 'n', '#', '1', '.', '0', '.', '3', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
- 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'S', 'I', 'G', 'N', 'A',
- 'L', '{', 'r', 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l',
- ';', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '=', '<', 'N', 'C', 'B', 'I', ':', 'f',
- 's', 'a', 'm', 'p', '4', '>', 'n', 'o', '_', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#',
- '1', '(', 'i', 'n', '_', 's', 'i', 'g', 'n', 'a', 'l', ',', 'o', 'u', 't', '_', 's',
- 'i', 'g', 'n', 'a', 'l', ')', ';', '}', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C',
- 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'N', 'O', 'I', 'S', 'E', '{', 'r',
- 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 'n', 'o', 'i', 's', 'e', ';', 'v', 'a', 'l',
- 'i', 'd', 'a', 't', 'e', '=', '<', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p',
- '4', '>', 'n', 'o', '_', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1', '(', 'i', 'n',
- '_', 'n', 'o', 'i', 's', 'e', ',', 'o', 'u', 't', '_', 'n', 'o', 'i', 's', 'e', ')',
- ';', '}', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a',
- 'm', 'p', '4', ' ', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', '{', 'r', 'e', 'a',
- 'd', '=', 'o', 'u', 't', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ';', 'v',
+ 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '2', '#', '1', '.', '0', '.', '4', '=',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#',
+ '2', '.', '1', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'b', 'a',
+ 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '#', '2', '.', '0', '.', '3', ',', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'c',
+ 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.', '3', '{', 'c', 'o', 'l', 'u', 'm',
+ 'n', ' ', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'S', 'I', 'G',
+ 'N', 'A', 'L', '{', 'r', 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 's', 'i', 'g', 'n',
+ 'a', 'l', ';', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '=', '<', 'N', 'C', 'B', 'I',
+ ':', 'f', 's', 'a', 'm', 'p', '4', '>', 'n', 'o', '_', 'c', 'o', 'm', 'p', 'a', 'r',
+ 'e', '#', '1', '(', 'i', 'n', '_', 's', 'i', 'g', 'n', 'a', 'l', ',', 'o', 'u', 't',
+ '_', 's', 'i', 'g', 'n', 'a', 'l', ')', ';', '}', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
+ 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'N', 'O', 'I', 'S', 'E',
+ '{', 'r', 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 'n', 'o', 'i', 's', 'e', ';', 'v',
'a', 'l', 'i', 'd', 'a', 't', 'e', '=', '<', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a',
'm', 'p', '4', '>', 'n', 'o', '_', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1', '(',
- 'i', 'n', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ',', 'o', 'u', 't', '_',
- 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ')', ';', '}', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'l', 'a',
- 'n', 'e', '_', 'c', 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n', 'a', 'm', 'e', '_', 'c', 'o', 'o',
- 'r', 'd', '#', '1', '<', '7', '>', '(', '_', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e',
- ',', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o',
- 'k', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a',
- 'l', ' ', 'o', 'u', 't', '_', 't', 'i', 'l', 'e', '_', 'c', 'o', 'o', 'r', 'd', '=',
- '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_',
- 'n', 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '6', '>', '(', '_',
- 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', ',', 'o', 'u', 't', '_', 's', 'p', 'o', 't',
- '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', 't', 'e', 'x', 't', ':', 't',
- 'o', 'k', 'e', 'n', ' ', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm',
- 'e', '_', 't', 'o', 'k', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l',
- 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's',
- 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', '_', 'o', 'u', 't', '_', 'n',
- 'a', 'm', 'e', ')', ';', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'i',
- 'n', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', '=', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':',
- 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm',
- 'e', '#', '1', '(', 'N', 'A', 'M', 'E', ')', ';', 'N', 'C', 'B', 'I', ':', 'f', 's',
- 'a', 'm', 'p', '4', ' ', 'i', 'n', '_', 's', 'i', 'g', 'n', 'a', 'l', '=', 'S', 'I',
- 'G', 'N', 'A', 'L', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ',
- 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', '=', '<', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p',
- '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1',
- '(', '.', 'S', 'I', 'G', 'N', 'A', 'L', ',', 'o', 'u', 't', '_', 'x', '2', 'n', 'a',
- '_', 'b', 'i', 'n', ')', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4',
- ' ', 'i', 'n', '_', 'n', 'o', 'i', 's', 'e', '=', 'N', 'O', 'I', 'S', 'E', ';', 'N',
- 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u', 't', '_', 'n', 'o',
- 'i', 's', 'e', '=', '.', 'N', 'O', 'I', 'S', 'E', ';', 'N', 'C', 'B', 'I', ':', 'f',
- 's', 'a', 'm', 'p', '4', ' ', 'i', 'n', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't',
- 'y', '=', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', ';', 'N', 'C', 'B', 'I', ':',
- 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u', 't', '_', 'i', 'n', 't', 'e', 'n', 's',
- 'i', 't', 'y', '=', '<', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', '>',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'n', 'o', 'r', 'm', 'a', 'l',
- 'i', 'z', 'e', '#', '1', '(', 'o', 'u', 't', '_', 'n', 'o', 'r', 'm', '_', 'i', 'n',
- 't', 'e', 'n', 's', 'i', 't', 'y', ',', 'o', 'u', 't', '_', 'x', '2', 'n', 'a', '_',
- 'b', 'i', 'n', ')', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ',
- 'o', 'u', 't', '_', 'n', 'o', 'r', 'm', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't',
- 'y', '=', '(', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f',
- 's', 'a', 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w',
- 'a', 'p', '#', '1', '(', '.', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', ',', 'o',
- 'u', 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'N', 'C', 'B', 'I',
- ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'i', 'n', '_', 'n', 'o', 'r', 'm', '_', 'i',
- 'n', 't', 'e', 'n', 's', 'i', 't', 'y', '=', '<', 'N', 'C', 'B', 'I', ':', 'f', 's',
- 'a', 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'o', 'r',
- 'm', 'a', 'l', 'i', 'z', 'e', '#', '1', '(', 'i', 'n', '_', 'i', 'n', 't', 'e', 'n',
- 's', 'i', 't', 'y', ',', 'i', 'n', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')',
- '|', '<', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', '>', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'n', 'o', 'r', 'm', 'a', 'l', 'i', 'z', 'e', '#', '1',
- '(', 'i', 'n', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ',', 'i', 'n', '_',
- '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l',
- ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g',
- ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '2', ' ', '.', 'S', 'I', 'G', 'N', 'A', 'L',
- '=', '(', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e',
- 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'f', 's',
- 'a', 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a',
- 'p', '#', '1', '(', 'i', 'n', '_', 's', 'i', 'g', 'n', 'a', 'l', ',', 'i', 'n', '_',
- 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', '|', '(', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4',
- ')', '<', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', '>', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(', 'i', 'n', '_', 's',
- 'i', 'g', 'n', 'a', 'l', ',', 'i', 'n', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ')',
- ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a',
- ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'N', 'O', 'I', 'S', 'E', '#', '2',
- ' ', '.', 'N', 'O', 'I', 'S', 'E', '=', 'i', 'n', '_', 'n', 'o', 'i', 's', 'e', ';',
- 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':',
- 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T',
- 'Y', '#', '2', ' ', '.', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', '=', '(', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f',
- 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p',
- '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1',
- '(', 'i', 'n', '_', 'n', 'o', 'r', 'm', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't',
- 'y', ',', 'i', 'n', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', '|', '(', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f',
- 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p',
- '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1',
- '(', 'i', 'n', '_', 'n', 'o', 'r', 'm', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't',
- 'y', ',', 'i', 'n', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', '}', 't', 'a',
- 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u',
- 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'q', '4', ':', 'v', '2', '#', '1', '.',
- '0', '.', '4', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u',
- 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '2', '#', '1', '.', '0', '.', '4',
- ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n',
- 'a', ':', 'q', 'u', 'a', 'l', '4', '#', '2', '.', '0', '.', '4', '{', '}', 't', 'a',
- 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u',
- 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'q', '1', ':', 'v', '2', '#', '1', '.',
- '0', '.', '4', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u',
- 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '2', '#', '1', '.', '0', '.', '4',
- ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'l', 'o', 'g', '_', 'o', 'd', 'd',
- 's', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '#', '2', '.', '0', '.', '4', '{', '}',
+ 'i', 'n', '_', 'n', 'o', 'i', 's', 'e', ',', 'o', 'u', 't', '_', 'n', 'o', 'i', 's',
+ 'e', ')', ';', '}', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'f',
+ 's', 'a', 'm', 'p', '4', ' ', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', '{', 'r',
+ 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y',
+ ';', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '=', '<', 'N', 'C', 'B', 'I', ':', 'f',
+ 's', 'a', 'm', 'p', '4', '>', 'n', 'o', '_', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#',
+ '1', '(', 'i', 'n', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ',', 'o', 'u',
+ 't', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ')', ';', '}', 'I', 'N', 'S',
+ 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_',
+ 'l', 'a', 'n', 'e', '_', 'c', 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C',
+ ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n', 'a', 'm', 'e', '_', 'c',
+ 'o', 'o', 'r', 'd', '#', '1', '<', '7', '>', '(', '_', 'o', 'u', 't', '_', 'n', 'a',
+ 'm', 'e', ',', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_',
+ 't', 'o', 'k', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
+ 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 't', 'i', 'l', 'e', '_', 'c', 'o', 'o', 'r',
+ 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a',
+ 'l', ')', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c',
+ 't', '_', 'n', 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '6', '>',
+ '(', '_', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', ',', 'o', 'u', 't', '_', 's', 'p',
+ 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', 't', 'e', 'x', 't',
+ ':', 't', 'o', 'k', 'e', 'n', ' ', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n',
+ 'a', 'm', 'e', '_', 't', 'o', 'k', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e',
+ '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', '_', 'o', 'u', 't',
+ '_', 'n', 'a', 'm', 'e', ')', ';', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n',
+ ' ', 'i', 'n', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k',
+ '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n',
+ 'a', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_', 'n',
+ 'a', 'm', 'e', '#', '1', '(', 'N', 'A', 'M', 'E', ')', ';', 'N', 'C', 'B', 'I', ':',
+ 'f', 's', 'a', 'm', 'p', '4', ' ', 'i', 'n', '_', 's', 'i', 'g', 'n', 'a', 'l', '=',
+ 'S', 'I', 'G', 'N', 'A', 'L', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p',
+ '4', ' ', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', '=', '<', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a',
+ 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p',
+ '#', '1', '(', '.', 'S', 'I', 'G', 'N', 'A', 'L', ',', 'o', 'u', 't', '_', 'x', '2',
+ 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm',
+ 'p', '4', ' ', 'i', 'n', '_', 'n', 'o', 'i', 's', 'e', '=', 'N', 'O', 'I', 'S', 'E',
+ ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u', 't', '_',
+ 'n', 'o', 'i', 's', 'e', '=', '.', 'N', 'O', 'I', 'S', 'E', ';', 'N', 'C', 'B', 'I',
+ ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'i', 'n', '_', 'i', 'n', 't', 'e', 'n', 's',
+ 'i', 't', 'y', '=', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', ';', 'N', 'C', 'B',
+ 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u', 't', '_', 'i', 'n', 't', 'e',
+ 'n', 's', 'i', 't', 'y', '=', '<', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p',
+ '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'n', 'o', 'r', 'm',
+ 'a', 'l', 'i', 'z', 'e', '#', '1', '(', 'o', 'u', 't', '_', 'n', 'o', 'r', 'm', '_',
+ 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ',', 'o', 'u', 't', '_', 'x', '2', 'n',
+ 'a', '_', 'b', 'i', 'n', ')', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p',
+ '4', ' ', 'o', 'u', 't', '_', 'n', 'o', 'r', 'm', '_', 'i', 'n', 't', 'e', 'n', 's',
+ 'i', 't', 'y', '=', '(', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ')',
+ '<', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd',
+ '_', 'f', 's', 'a', 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 's', 'w', 'a', 'p', '#', '1', '(', '.', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y',
+ ',', 'o', 'u', 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'N', 'C',
+ 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'i', 'n', '_', 'n', 'o', 'r', 'm',
+ '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', '=', '<', 'N', 'C', 'B', 'I', ':',
+ 'f', 's', 'a', 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n',
+ 'o', 'r', 'm', 'a', 'l', 'i', 'z', 'e', '#', '1', '(', 'i', 'n', '_', 'i', 'n', 't',
+ 'e', 'n', 's', 'i', 't', 'y', ',', 'i', 'n', '_', 'x', '2', 'n', 'a', '_', 'b', 'i',
+ 'n', ')', '|', '<', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', '>', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'n', 'o', 'r', 'm', 'a', 'l', 'i', 'z', 'e',
+ '#', '1', '(', 'i', 'n', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ',', 'i',
+ 'n', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'p', 'h', 'y', 's', 'i', 'c',
+ 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i',
+ 'n', 'g', ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '2', ' ', '.', 'S', 'I', 'G', 'N',
+ 'A', 'L', '=', '(', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p',
+ 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':',
+ 'f', 's', 'a', 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's',
+ 'w', 'a', 'p', '#', '1', '(', 'i', 'n', '_', 's', 'i', 'g', 'n', 'a', 'l', ',', 'i',
+ 'n', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', '|', '(', 'N', 'C', 'B', 'I',
+ ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm',
+ 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', '>', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(', 'i', 'n',
+ '_', 's', 'i', 'g', 'n', 'a', 'l', ',', 'i', 'n', '_', '2', 'n', 'a', '_', 'b', 'i',
+ 'n', ')', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm',
+ 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i',
+ 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'N', 'O', 'I', 'S', 'E',
+ '#', '2', ' ', '.', 'N', 'O', 'I', 'S', 'E', '=', 'i', 'n', '_', 'n', 'o', 'i', 's',
+ 'e', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n',
+ ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n',
+ 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'I', 'N', 'T', 'E', 'N', 'S',
+ 'I', 'T', 'Y', '#', '2', ' ', '.', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', '=',
+ '(', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd',
+ '_', 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a',
+ 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p',
+ '#', '1', '(', 'i', 'n', '_', 'n', 'o', 'r', 'm', '_', 'i', 'n', 't', 'e', 'n', 's',
+ 'i', 't', 'y', ',', 'i', 'n', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', '|',
+ '(', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd',
+ '_', 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a',
+ 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p',
+ '#', '1', '(', 'i', 'n', '_', 'n', 'o', 'r', 'm', '_', 'i', 'n', 't', 'e', 'n', 's',
+ 'i', 't', 'y', ',', 'i', 'n', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', '}',
't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l',
- 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'p', 'h', 'r', 'e', 'd', ':',
- 'v', '2', '#', '1', '.', '0', '.', '4', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '2', '#',
- '1', '.', '0', '.', '4', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'p', 'h',
- 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '#', '2', '.', '0', '.', '4',
+ 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'q', '4', ':', 'v', '2', '#',
+ '1', '.', '0', '.', '4', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l',
+ 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '2', '#', '1', '.', '0',
+ '.', '4', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm',
+ 'i', 'n', 'a', ':', 'q', 'u', 'a', 'l', '4', '#', '2', '.', '0', '.', '4', '{', '}',
+ 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l',
+ 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'q', '1', ':', 'v', '2', '#',
+ '1', '.', '0', '.', '4', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l',
+ 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '2', '#', '1', '.', '0',
+ '.', '4', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'l', 'o', 'g', '_', 'o',
+ 'd', 'd', 's', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '#', '2', '.', '0', '.', '4',
'{', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'A', 'B', 'I', ':', 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.', '3', '=',
- 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a',
- '#', '1', '.', '0', '.', '3', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S',
- 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'P', 'A', 'N', 'E',
- 'L', ' ', '=', ' ', 'o', 'u', 't', '_', 'p', 'a', 'n', 'e', 'l', '_', 'c', 'o', 'o',
- 'r', 'd', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'f', 's',
- 'a', 'm', 'p', '4', ' ', 'S', 'I', 'G', 'N', 'A', 'L', ' ', '=', ' ', 'o', 'u', 't',
- '_', 's', 'i', 'g', 'n', 'a', 'l', ';', 'a', 's', 'c', 'i', 'i', ' ', 'p', 'l', 'a',
- 't', 'f', 'o', 'r', 'm', '_', 'n', 'a', 'm', 'e', '=', '<', 'a', 's', 'c', 'i', 'i',
- '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'', 'A', 'B', 'S', 'O', 'L', 'I', 'D',
- '\'', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
- ':', 'z', 'e', 'r', 'o', ' ', 'b', 'i', 'o', '_', 's', 't', 'a', 'r', 't', '=', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'b', 'i', 'o', '_', 's', 't', 'a', 'r', 't',
- '#', '1', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't',
- ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ')', ';', 'I',
- 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 't',
- 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't', '=', 'b', 'i', 'o', '_', 's', 't', 'a',
- 'r', 't', ';', 'U', '3', '2', ' ', 't', 'r', 'i', 'm', '_', 'l', 'e', 'f', 't', '=',
- '(', 'U', '3', '2', ')', 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't', ';', 'I',
- 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 't', 'r',
- 'i', 'm', '_', 'l', 'e', 'n', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
- 'r', 'd', ':', 'l', 'e', 'n', ')', '<', 'U', '3', '2', '>', 'd', 'i', 'f', 'f', '#',
- '1', '(', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ',', 't', 'r', 'i', 'm', '_', 'l',
- 'e', 'f', 't', ')', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ',
- 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', '=', '(', 'N', 'C', 'B', 'I', ':',
- 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', '>', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(', 'o', 'u', 't',
- '_', 's', 'i', 'g', 'n', 'a', 'l', '_', 's', 'w', 'a', 'p', 'p', 'e', 'd', ',', 'o',
- 'u', 't', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', ')', ';', '}', 't', 'a', 'b',
- 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 't',
- 'b', 'l', ':', 'v', '2', '#', '1', '.', '0', '.', '4', '=', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#', '2', '.', '1', '.', '3',
- ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'c', 'o', 'l', 'o', 'r', '_', 's',
- 'p', 'a', 'c', 'e', '#', '2', '.', '1', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l',
- ':', 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '#', '2', '.',
- '0', '.', '4', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':',
- 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.', '3', '{', 'c', 'o', 'l', 'u',
- 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'F', 'T',
- 'C', '{', 'r', 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 'f', 't', 'c', ';', 'v', 'a',
- 'l', 'i', 'd', 'a', 't', 'e', '=', '<', 'F', '3', '2', '>', 'n', 'o', '_', 'c', 'o',
- 'm', 'p', 'a', 'r', 'e', '#', '1', '(', 'i', 'n', '_', 'f', 't', 'c', ',', 'o', 'u',
- 't', '_', 'f', 't', 'c', ')', ';', '}', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C',
- 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'F', 'A', 'M', '{', 'r', 'e', 'a',
- 'd', '=', 'o', 'u', 't', '_', 'f', 'a', 'm', ';', 'v', 'a', 'l', 'i', 'd', 'a', 't',
- 'e', '=', '<', 'F', '3', '2', '>', 'n', 'o', '_', 'c', 'o', 'm', 'p', 'a', 'r', 'e',
- '#', '1', '(', 'i', 'n', '_', 'f', 'a', 'm', ',', 'o', 'u', 't', '_', 'f', 'a', 'm',
- ')', ';', '}', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'f', 's',
- 'a', 'm', 'p', '1', ' ', 'C', 'Y', '3', '{', 'r', 'e', 'a', 'd', '=', 'o', 'u', 't',
- '_', 'c', 'y', '3', ';', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '=', '<', 'F', '3',
- '2', '>', 'n', 'o', '_', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1', '(', 'i', 'n',
- '_', 'c', 'y', '3', ',', 'o', 'u', 't', '_', 'c', 'y', '3', ')', ';', '}', 'c', 'o',
+ 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'p', 'h', 'r', 'e',
+ 'd', ':', 'v', '2', '#', '1', '.', '0', '.', '4', '=', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v',
+ '2', '#', '1', '.', '0', '.', '4', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':',
+ 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '#', '2', '.', '0',
+ '.', '4', '{', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'A', 'B', 'I', ':', 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.',
+ '3', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's',
+ 'r', 'a', '#', '1', '.', '0', '.', '3', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I',
+ 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'P', 'A',
+ 'N', 'E', 'L', ' ', '=', ' ', 'o', 'u', 't', '_', 'p', 'a', 'n', 'e', 'l', '_', 'c',
+ 'o', 'o', 'r', 'd', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':',
+ 'f', 's', 'a', 'm', 'p', '4', ' ', 'S', 'I', 'G', 'N', 'A', 'L', ' ', '=', ' ', 'o',
+ 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', ';', 'a', 's', 'c', 'i', 'i', ' ', 'p',
+ 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'n', 'a', 'm', 'e', '=', '<', 'a', 's', 'c',
+ 'i', 'i', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'', 'A', 'B', 'S', 'O', 'L',
+ 'I', 'D', '\'', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
+ 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'b', 'i', 'o', '_', 's', 't', 'a', 'r', 't',
+ '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'b', 'i', 'o', '_', 's', 't', 'a',
+ 'r', 't', '#', '1', '(', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 's', 't', 'a',
+ 'r', 't', ',', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ')',
+ ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o',
+ ' ', 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't', '=', 'b', 'i', 'o', '_', 's',
+ 't', 'a', 'r', 't', ';', 'U', '3', '2', ' ', 't', 'r', 'i', 'm', '_', 'l', 'e', 'f',
+ 't', '=', '(', 'U', '3', '2', ')', 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't',
+ ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ',
+ 't', 'r', 'i', 'm', '_', 'l', 'e', 'n', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c',
+ 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ')', '<', 'U', '3', '2', '>', 'd', 'i', 'f',
+ 'f', '#', '1', '(', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ',', 't', 'r', 'i', 'm',
+ '_', 'l', 'e', 'f', 't', ')', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p',
+ '4', ' ', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', '=', '(', 'N', 'C', 'B',
+ 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', '>',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(', 'o',
+ 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', '_', 's', 'w', 'a', 'p', 'p', 'e', 'd',
+ ',', 'o', 'u', 't', '_', 'x', '2', 'c', 's', '_', 'b', 'i', 'n', ')', ';', '}', 't',
+ 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I',
+ ':', 't', 'b', 'l', ':', 'v', '2', '#', '1', '.', '0', '.', '4', '=', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#', '2', '.', '1',
+ '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'c', 'o', 'l', 'o', 'r',
+ '_', 's', 'p', 'a', 'c', 'e', '#', '2', '.', '1', ',', 'N', 'C', 'B', 'I', ':', 't',
+ 'b', 'l', ':', 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '#',
+ '2', '.', '0', '.', '4', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'A', 'B',
+ 'I', ':', 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.', '3', '{', 'c', 'o',
'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ',
- 'T', 'X', 'R', '{', 'r', 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 't', 'x', 'r', ';',
+ 'F', 'T', 'C', '{', 'r', 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 'f', 't', 'c', ';',
'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '=', '<', 'F', '3', '2', '>', 'n', 'o', '_',
- 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1', '(', 'i', 'n', '_', 't', 'x', 'r', ',',
- 'o', 'u', 't', '_', 't', 'x', 'r', ')', ';', '}', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
- 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'C', 'Y', '5', '{', 'r',
- 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 'c', 'y', '5', ';', 'v', 'a', 'l', 'i', 'd',
+ 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1', '(', 'i', 'n', '_', 'f', 't', 'c', ',',
+ 'o', 'u', 't', '_', 'f', 't', 'c', ')', ';', '}', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
+ 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'F', 'A', 'M', '{', 'r',
+ 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 'f', 'a', 'm', ';', 'v', 'a', 'l', 'i', 'd',
'a', 't', 'e', '=', '<', 'F', '3', '2', '>', 'n', 'o', '_', 'c', 'o', 'm', 'p', 'a',
- 'r', 'e', '#', '1', '(', 'i', 'n', '_', 'c', 'y', '5', ',', 'o', 'u', 't', '_', 'c',
- 'y', '5', ')', ';', '}', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
- 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'p', 'a', 'n', 'e', 'l', '_', 'c', 'o', 'o',
- 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v',
- 'a', 'l', ')', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a',
- 'c', 't', '_', 'n', 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '6',
- '>', '(', '_', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', ',', 'o', 'u', 't', '_', 's',
- 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', 't', 'e', 'x',
- 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_',
- 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', 'A', 'B', 'I', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o',
- 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', '_', 'o', 'u', 't', '_', 'n', 'a', 'm',
- 'e', ')', ';', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'i', 'n', '_',
- 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', '=', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z',
- 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', 'N', 'A', 'M',
- 'E', ')', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'i', 'n',
- '_', 'f', 't', 'c', '=', 'F', 'T', 'C', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a',
- 'm', 'p', '1', ' ', 'o', 'u', 't', '_', 'f', 't', 'c', '=', '(', 'N', 'C', 'B', 'I',
- ':', 'f', 's', 'a', 'm', 'p', '1', ')', '<', 'F', '3', '2', '>', 'c', 'u', 't', '#',
- '1', '<', '0', '>', '(', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', ')', ';',
- 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'i', 'n', '_', 'f', 'a',
- 'm', '=', 'F', 'A', 'M', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1',
- ' ', 'o', 'u', 't', '_', 'f', 'a', 'm', '=', '(', 'N', 'C', 'B', 'I', ':', 'f', 's',
- 'a', 'm', 'p', '1', ')', '<', 'F', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '0',
- '>', '(', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', ')', ';', 'N', 'C', 'B',
- 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'i', 'n', '_', 'c', 'y', '3', '=', 'C',
- 'Y', '3', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'o', 'u',
- 't', '_', 'c', 'y', '3', '=', '(', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p',
- '1', ')', '<', 'F', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '1', '>', '(', 'o',
- 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', ')', ';', 'N', 'C', 'B', 'I', ':', 'f',
- 's', 'a', 'm', 'p', '1', ' ', 'i', 'n', '_', 't', 'x', 'r', '=', 'T', 'X', 'R', ';',
- 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'o', 'u', 't', '_', 't',
- 'x', 'r', '=', '(', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ')', '<',
- 'F', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '2', '>', '(', 'o', 'u', 't', '_',
- 's', 'i', 'g', 'n', 'a', 'l', ')', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm',
- 'p', '1', ' ', 'i', 'n', '_', 'c', 'y', '5', '=', 'C', 'Y', '5', ';', 'N', 'C', 'B',
- 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'o', 'u', 't', '_', 'c', 'y', '5', '=',
- '(', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ')', '<', 'F', '3', '2',
- '>', 'c', 'u', 't', '#', '1', '<', '3', '>', '(', 'o', 'u', 't', '_', 's', 'i', 'g',
- 'n', 'a', 'l', ')', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ',
- 'i', 'n', '_', 's', 'i', 'g', 'n', 'a', 'l', '=', 'S', 'I', 'G', 'N', 'A', 'L', '|',
- '(', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'F', '3', '2',
- '>', 'p', 'a', 's', 't', 'e', '#', '1', '(', 'i', 'n', '_', 'f', 't', 'c', ',', 'i',
- 'n', '_', 'c', 'y', '3', ',', 'i', 'n', '_', 't', 'x', 'r', ',', 'i', 'n', '_', 'c',
- 'y', '5', ')', '|', '(', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ')',
- '<', 'F', '3', '2', '>', 'p', 'a', 's', 't', 'e', '#', '1', '(', 'i', 'n', '_', 'f',
- 'a', 'm', ',', 'i', 'n', '_', 'c', 'y', '3', ',', 'i', 'n', '_', 't', 'x', 'r', ',',
- 'i', 'n', '_', 'c', 'y', '5', ')', ';', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u',
- 't', '_', 's', 'i', 'g', 'n', 'a', 'l', '_', 's', 'w', 'a', 'p', 'p', 'e', 'd', '=',
- '.', 'S', 'I', 'G', 'N', 'A', 'L', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
- 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'A',
- 'B', 'I', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'S', 'I', 'G', 'N', 'A',
- 'L', '#', '2', ' ', '.', 'S', 'I', 'G', 'N', 'A', 'L', '=', '(', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm',
- 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', '>', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(', 'i', 'n',
- '_', 's', 'i', 'g', 'n', 'a', 'l', ',', 'i', 'n', '_', 'x', '2', 'c', 's', '_', 'b',
- 'i', 'n', ')', '|', '(', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a',
- 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I',
- ':', 'f', 's', 'a', 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 's', 'w', 'a', 'p', '#', '1', '(', 'i', 'n', '_', 's', 'i', 'g', 'n', 'a', 'l', ',',
- 'i', 'n', '_', '2', 'c', 's', '_', 'b', 'i', 'n', ')', ';', '}', 't', 'a', 'b', 'l',
- 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'H', 'e', 'l', 'i', 'c', 'o',
- 's', ':', 't', 'b', 'l', ':', 'v', '2', '#', '1', '.', '0', '.', '4', '=', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#', '2', '.',
- '1', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'b', 'a', 's', 'e',
- '_', 's', 'p', 'a', 'c', 'e', '#', '2', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I',
- ':', 't', 'b', 'l', ':', 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't',
- 'y', '#', '2', '.', '0', '.', '4', '{', 'r', 'e', 'a', 'd', 'o', 'n', 'l', 'y', ' ',
- 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
- 'd', ':', 'v', 'a', 'l', ' ', 'C', 'H', 'A', 'N', 'N', 'E', 'L', ' ', '=', ' ', '(',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n',
- 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '7', '>', '(', '_', 'o',
- 'u', 't', '_', 'n', 'a', 'm', 'e', ',', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_',
- 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l',
- 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'F', 'I', 'E', 'L', 'D', ' ', '=', ' ', '(',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'n',
- 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '6', '>', '(', '_', 'o',
- 'u', 't', '_', 'n', 'a', 'm', 'e', ',', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_',
- 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', 'r', 'e', 'a', 'd', 'o', 'n', 'l',
+ 'r', 'e', '#', '1', '(', 'i', 'n', '_', 'f', 'a', 'm', ',', 'o', 'u', 't', '_', 'f',
+ 'a', 'm', ')', ';', '}', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':',
+ 'f', 's', 'a', 'm', 'p', '1', ' ', 'C', 'Y', '3', '{', 'r', 'e', 'a', 'd', '=', 'o',
+ 'u', 't', '_', 'c', 'y', '3', ';', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '=', '<',
+ 'F', '3', '2', '>', 'n', 'o', '_', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1', '(',
+ 'i', 'n', '_', 'c', 'y', '3', ',', 'o', 'u', 't', '_', 'c', 'y', '3', ')', ';', '}',
+ 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p',
+ '1', ' ', 'T', 'X', 'R', '{', 'r', 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 't', 'x',
+ 'r', ';', 'v', 'a', 'l', 'i', 'd', 'a', 't', 'e', '=', '<', 'F', '3', '2', '>', 'n',
+ 'o', '_', 'c', 'o', 'm', 'p', 'a', 'r', 'e', '#', '1', '(', 'i', 'n', '_', 't', 'x',
+ 'r', ',', 'o', 'u', 't', '_', 't', 'x', 'r', ')', ';', '}', 'c', 'o', 'l', 'u', 'm',
+ 'n', ' ', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'C', 'Y', '5',
+ '{', 'r', 'e', 'a', 'd', '=', 'o', 'u', 't', '_', 'c', 'y', '5', ';', 'v', 'a', 'l',
+ 'i', 'd', 'a', 't', 'e', '=', '<', 'F', '3', '2', '>', 'n', 'o', '_', 'c', 'o', 'm',
+ 'p', 'a', 'r', 'e', '#', '1', '(', 'i', 'n', '_', 'c', 'y', '5', ',', 'o', 'u', 't',
+ '_', 'c', 'y', '5', ')', ';', '}', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'p', 'a', 'n', 'e', 'l', '_', 'c',
+ 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'v', 'a', 'l', ')', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't',
+ 'r', 'a', 'c', 't', '_', 'n', 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1',
+ '<', '6', '>', '(', '_', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', ',', 'o', 'u', 't',
+ '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', 't',
+ 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'o', 'u', 't', '_', 's', 'p', 'o',
+ 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', '=', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 'A', 'B', 'I', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's',
+ 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', '_', 'o', 'u', 't', '_', 'n',
+ 'a', 'm', 'e', ')', ';', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'i',
+ 'n', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', '=', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 't', 'o', 'k', 'e', 'n',
+ 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', 'N',
+ 'A', 'M', 'E', ')', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ',
+ 'i', 'n', '_', 'f', 't', 'c', '=', 'F', 'T', 'C', ';', 'N', 'C', 'B', 'I', ':', 'f',
+ 's', 'a', 'm', 'p', '1', ' ', 'o', 'u', 't', '_', 'f', 't', 'c', '=', '(', 'N', 'C',
+ 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ')', '<', 'F', '3', '2', '>', 'c', 'u',
+ 't', '#', '1', '<', '0', '>', '(', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l',
+ ')', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'i', 'n', '_',
+ 'f', 'a', 'm', '=', 'F', 'A', 'M', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm',
+ 'p', '1', ' ', 'o', 'u', 't', '_', 'f', 'a', 'm', '=', '(', 'N', 'C', 'B', 'I', ':',
+ 'f', 's', 'a', 'm', 'p', '1', ')', '<', 'F', '3', '2', '>', 'c', 'u', 't', '#', '1',
+ '<', '0', '>', '(', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', ')', ';', 'N',
+ 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'i', 'n', '_', 'c', 'y', '3',
+ '=', 'C', 'Y', '3', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ',
+ 'o', 'u', 't', '_', 'c', 'y', '3', '=', '(', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a',
+ 'm', 'p', '1', ')', '<', 'F', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '1', '>',
+ '(', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', ')', ';', 'N', 'C', 'B', 'I',
+ ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'i', 'n', '_', 't', 'x', 'r', '=', 'T', 'X',
+ 'R', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'o', 'u', 't',
+ '_', 't', 'x', 'r', '=', '(', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1',
+ ')', '<', 'F', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '2', '>', '(', 'o', 'u',
+ 't', '_', 's', 'i', 'g', 'n', 'a', 'l', ')', ';', 'N', 'C', 'B', 'I', ':', 'f', 's',
+ 'a', 'm', 'p', '1', ' ', 'i', 'n', '_', 'c', 'y', '5', '=', 'C', 'Y', '5', ';', 'N',
+ 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ' ', 'o', 'u', 't', '_', 'c', 'y',
+ '5', '=', '(', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '1', ')', '<', 'F',
+ '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '3', '>', '(', 'o', 'u', 't', '_', 's',
+ 'i', 'g', 'n', 'a', 'l', ')', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p',
+ '4', ' ', 'i', 'n', '_', 's', 'i', 'g', 'n', 'a', 'l', '=', 'S', 'I', 'G', 'N', 'A',
+ 'L', '|', '(', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'F',
+ '3', '2', '>', 'p', 'a', 's', 't', 'e', '#', '1', '(', 'i', 'n', '_', 'f', 't', 'c',
+ ',', 'i', 'n', '_', 'c', 'y', '3', ',', 'i', 'n', '_', 't', 'x', 'r', ',', 'i', 'n',
+ '_', 'c', 'y', '5', ')', '|', '(', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p',
+ '4', ')', '<', 'F', '3', '2', '>', 'p', 'a', 's', 't', 'e', '#', '1', '(', 'i', 'n',
+ '_', 'f', 'a', 'm', ',', 'i', 'n', '_', 'c', 'y', '3', ',', 'i', 'n', '_', 't', 'x',
+ 'r', ',', 'i', 'n', '_', 'c', 'y', '5', ')', ';', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ' ',
+ 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', '_', 's', 'w', 'a', 'p', 'p', 'e',
+ 'd', '=', '.', 'S', 'I', 'G', 'N', 'A', 'L', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a',
+ 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', 'A', 'B', 'I', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'S', 'I', 'G',
+ 'N', 'A', 'L', '#', '2', ' ', '.', 'S', 'I', 'G', 'N', 'A', 'L', '=', '(', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's',
+ 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4',
+ '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(',
+ 'i', 'n', '_', 's', 'i', 'g', 'n', 'a', 'l', ',', 'i', 'n', '_', 'x', '2', 'c', 's',
+ '_', 'b', 'i', 'n', ')', '|', '(', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's',
+ 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C',
+ 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(', 'i', 'n', '_', 's', 'i', 'g', 'n', 'a',
+ 'l', ',', 'i', 'n', '_', '2', 'c', 's', '_', 'b', 'i', 'n', ')', ';', '}', 't', 'a',
+ 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'H', 'e', 'l', 'i',
+ 'c', 'o', 's', ':', 't', 'b', 'l', ':', 'v', '2', '#', '1', '.', '0', '.', '4', '=',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '#',
+ '2', '.', '1', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'b', 'a',
+ 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '#', '2', '.', '0', '.', '3', ',', 'N', 'C',
+ 'B', 'I', ':', 't', 'b', 'l', ':', 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l',
+ 'i', 't', 'y', '#', '2', '.', '0', '.', '4', '{', 'r', 'e', 'a', 'd', 'o', 'n', 'l',
'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'C', 'A', 'M', 'E', 'R', 'A', ' ', '=', ' ',
- 'o', 'u', 't', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', ';', 'r', 'e', 'a', 'd', 'o',
+ 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'C', 'H', 'A', 'N', 'N', 'E', 'L', ' ', '=',
+ ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l',
+ ')', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't',
+ '_', 'n', 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '7', '>', '(',
+ '_', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', ',', 'o', 'u', 't', '_', 's', 'p', 'o',
+ 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', 'r', 'e', 'a', 'd', 'o',
'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'P', 'O', 'S', ' ', '=', ' ', 'o',
- 'u', 't', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', ';', 'a', 's', 'c', 'i', 'i', ' ',
- 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'n', 'a', 'm', 'e', '=', '<', 'a', 's',
- 'c', 'i', 'i', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'', 'H', 'E', 'L', 'I',
- 'C', 'O', 'S', '\'', '>', '(', ')', ';', 't', 'e', 'x', 't', ':', 't', 'o', 'k',
- 'e', 'n', ' ', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_',
- 't', 'o', 'k', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'H', 'e', 'l', 'i',
- 'c', 'o', 's', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't',
- '_', 'n', 'a', 'm', 'e', '#', '1', '(', '_', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e',
- ')', ';', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'i', 'n', '_', 's',
- 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', '=', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 'H', 'e', 'l', 'i', 'c', 'o', 's', ':', 't', 'o', 'k', 'e',
- 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(',
- 'N', 'A', 'M', 'E', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
- ':', 'z', 'e', 'r', 'o', ' ', 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r', 't', '=',
- '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o',
- '>', 'e', 'c', 'h', 'o', '#', '1', '<', '0', '>', '(', ')', ';', 'I', 'N', 'S', 'D',
- 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 't', 'r', 'i', 'm', '_',
- 'l', 'e', 'n', '=', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ';', '}', 't', 'a', 'b',
- 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'o', 'n', 'T', 'o',
- 'r', 'r', 'e', 'n', 't', ':', 't', 'b', 'l', ':', 'v', '2', '#', '1', '.', '0', '.',
- '3', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's',
- 'r', 'a', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', 't', 'b', 'l', ':', 's', 'r', 'a', '_', 'n', 'o', 'p', 'o', 's', '#', '2', '.',
- '1', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'b', 'a', 's', 'e',
- '_', 's', 'p', 'a', 'c', 'e', '#', '2', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I',
- ':', 't', 'b', 'l', ':', 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't',
- 'y', '#', '2', '.', '0', '.', '4', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 't', 'b', 'l', ':', 'c', 'l', 'i', 'p', '#', '1', '.', '0', '.', '2', '{', 'c', 'o',
+ 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'F', 'I', 'E', 'L', 'D', ' ', '=',
+ ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l',
+ ')', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't',
+ '_', 'n', 'a', 'm', 'e', '_', 'c', 'o', 'o', 'r', 'd', '#', '1', '<', '6', '>', '(',
+ '_', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', ',', 'o', 'u', 't', '_', 's', 'p', 'o',
+ 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', ')', ';', 'r', 'e', 'a', 'd', 'o',
+ 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':',
+ 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'C', 'A', 'M', 'E', 'R', 'A', ' ',
+ '=', ' ', 'o', 'u', 't', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', ';', 'r', 'e', 'a',
+ 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'P', 'O', 'S', ' ', '=',
+ ' ', 'o', 'u', 't', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', ';', 'a', 's', 'c', 'i',
+ 'i', ' ', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'n', 'a', 'm', 'e', '=', '<',
+ 'a', 's', 'c', 'i', 'i', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'', 'H', 'E',
+ 'L', 'I', 'C', 'O', 'S', '\'', '>', '(', ')', ';', 't', 'e', 'x', 't', ':', 't',
+ 'o', 'k', 'e', 'n', ' ', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm',
+ 'e', '_', 't', 'o', 'k', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'H', 'e',
+ 'l', 'i', 'c', 'o', 's', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p',
+ 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', '_', 'o', 'u', 't', '_', 'n', 'a',
+ 'm', 'e', ')', ';', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'i', 'n',
+ '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', '=', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 'H', 'e', 'l', 'i', 'c', 'o', 's', ':', 't', 'o',
+ 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#',
+ '1', '(', 'N', 'A', 'M', 'E', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
+ 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 't', 'r', 'i', 'm', '_', 's', 't', 'a', 'r',
+ 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e',
+ 'r', 'o', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '0', '>', '(', ')', ';', 'I', 'N',
+ 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 't', 'r', 'i',
+ 'm', '_', 'l', 'e', 'n', '=', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ';', '}', 't',
+ 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'o', 'n',
+ 'T', 'o', 'r', 'r', 'e', 'n', 't', ':', 't', 'b', 'l', ':', 'v', '2', '#', '1', '.',
+ '0', '.', '3', '=', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 't', 'b', 'l',
+ ':', 's', 'r', 'a', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '_', 'n', 'o', 'p', 'o', 's', '#',
+ '2', '.', '1', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'b', 'a',
+ 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '#', '2', '.', '0', '.', '3', ',', 'N', 'C',
+ 'B', 'I', ':', 't', 'b', 'l', ':', 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l',
+ 'i', 't', 'y', '#', '2', '.', '0', '.', '4', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 't', 'b', 'l', ':', 'c', 'l', 'i', 'p', '#', '1', '.', '0', '.', '2', '{',
+ 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a',
+ ':', 't', 'e', 'x', 't', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n',
+ 'g', '#', '1', ' ', 'F', 'L', 'O', 'W', '_', 'C', 'H', 'A', 'R', 'S', ';', 'c', 'o',
'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't',
'e', 'x', 't', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#',
- '1', ' ', 'F', 'L', 'O', 'W', '_', 'C', 'H', 'A', 'R', 'S', ';', 'c', 'o', 'l', 'u',
- 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x',
- 't', '>', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ',
- 'K', 'E', 'Y', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ';', 'c', 'o', 'l', 'u',
- 'm', 'n', ' ', '<', 'N', 'C', 'B', 'I', ':', 'i', 's', 'a', 'm', 'p', '1', '>', 'i',
- 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', 'S', 'I',
- 'G', 'N', 'A', 'L', ';', 'a', 's', 'c', 'i', 'i', ' ', 'p', 'l', 'a', 't', 'f', 'o',
- 'r', 'm', '_', 'n', 'a', 'm', 'e', '=', '<', 'a', 's', 'c', 'i', 'i', '>', 'e', 'c',
- 'h', 'o', '#', '1', '<', '\'', 'I', 'O', 'N', '_', 'T', 'O', 'R', 'R', 'E', 'N',
- 'T', '\'', '>', '(', ')', ';', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n',
- ' ', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o',
- 'k', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'o', 'n', 'T', 'o', 'r',
- 'r', 'e', 'n', 't', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o',
- 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', '_', 'o', 'u', 't', '_', 'n', 'a', 'm',
- 'e', ')', ';', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'i', 'n', '_',
- 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', '=', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'I', 'o', 'n', 'T', 'o', 'r', 'r', 'e', 'n', 't', ':',
- 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm',
- 'e', '#', '1', '(', 'N', 'A', 'M', 'E', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'p',
- 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', ' ', 'o', 'u', 't', '_', 'p',
- 'o', 's', 'i', 't', 'i', 'o', 'n', '=', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N',
- ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'o', 'n', 'T', 'o', 'r', 'r', 'e',
- 'n', 't', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'P', 'O', 'S', 'I', 'T',
- 'I', 'O', 'N', '#', '1', ' ', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', '=', 'P',
- 'O', 'S', 'I', 'T', 'I', 'O', 'N', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
- 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
- 'r', 'd', ':', 'o', 'n', 'e', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd',
- 'i', 'n', 'g', '#', '1', ' ', '.', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T',
- 'E', 'R', '_', 'L', 'E', 'F', 'T', '=', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P',
- 'T', 'E', 'R', '_', 'L', 'E', 'F', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l',
- ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o',
- 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P',
- 'T', 'E', 'R', '_', 'R', 'I', 'G', 'H', 'T', '=', 'C', 'L', 'I', 'P', '_', 'A', 'D',
- 'A', 'P', 'T', 'E', 'R', '_', 'R', 'I', 'G', 'H', 'T', ';', 'p', 'h', 'y', 's', 'i',
- 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'i', 'z', 'i', 'p', '_', 'e',
- 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'C', 'L', 'I', 'P', '_', 'Q',
- 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'L', 'E', 'F', 'T', '=', 'C', 'L', 'I', 'P', '_',
- 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'L', 'E', 'F', 'T', ';', 'p', 'h', 'y', 's',
- 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D',
- 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'i', 'z', 'i', 'p', '_',
- 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'C', 'L', 'I', 'P', '_',
- 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'R', 'I', 'G', 'H', 'T', '=', 'C', 'L', 'I',
- 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'R', 'I', 'G', 'H', 'T', ';', '}',
- 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4',
- '5', '4', '_', ':', 'l', 'e', 'g', 'a', 'c', 'y', '#', '1', '=', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '_', 'n', 'o', 'p', 'o',
- 's', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':',
- 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '_', 'n', 'o', 'c', 'o', 'l', '#',
- '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'p', 'h',
- 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_', 'n', 'o', 'c', 'o', 'l',
- '#', '1', '.', '0', '.', '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't',
- 'b', 'l', ':', 's', 'k', 'e', 'y', 'n', 'a', 'm', 'e', '#', '1', '.', '0', '.', '1',
- ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'c',
- 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.', '4', '{', 'r', 'e', 'a', 'd', 'o',
- 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'R', 'E', 'G', 'I', 'O', 'N', ' ',
- '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a',
- 'l', ')', '<', 'I', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '2', '>', '(', 'c',
- 'o', 'o', 'r', 'd', 's', '_', 'f', 'r', 'o', 'm', '_', 's', 'k', 'e', 'y', ')', ';',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o',
- 'u', 't', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', '<', 'I', '3', '2', '>', 'c',
- 'u', 't', '#', '1', '<', '0', '>', '(', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r',
- 'o', 'm', '_', 's', 'k', 'e', 'y', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'x', '_', 'c', 'o', 'o',
- 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v',
- 'a', 'l', ')', '<', 'I', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '1', '>', '(',
- 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r', 'o', 'm', '_', 's', 'k', 'e', 'y', ')',
- ';', 'I', '3', '2', '[', '3', ']', ' ', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r',
- 'o', 'm', '_', 's', 'k', 'e', 'y', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'c', 'o', 'o', 'r', 'd', 'i', 'n', 'a', 't',
- 'e', 's', '#', '1', '<', '1', '>', '(', 'o', 'u', 't', '_', 's', 'k', 'e', 'y', ')',
+ '1', ' ', 'K', 'E', 'Y', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ';', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', '<', 'N', 'C', 'B', 'I', ':', 'i', 's', 'a', 'm', 'p', '1',
+ '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ',
+ 'S', 'I', 'G', 'N', 'A', 'L', ';', 'a', 's', 'c', 'i', 'i', ' ', 'p', 'l', 'a', 't',
+ 'f', 'o', 'r', 'm', '_', 'n', 'a', 'm', 'e', '=', '<', 'a', 's', 'c', 'i', 'i', '>',
+ 'e', 'c', 'h', 'o', '#', '1', '<', '\'', 'I', 'O', 'N', '_', 'T', 'O', 'R', 'R',
+ 'E', 'N', 'T', '\'', '>', '(', ')', ';', 't', 'e', 'x', 't', ':', 't', 'o', 'k',
+ 'e', 'n', ' ', 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_',
+ 't', 'o', 'k', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'o', 'n', 'T',
+ 'o', 'r', 'r', 'e', 'n', 't', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's',
+ 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', '_', 'o', 'u', 't', '_', 'n',
+ 'a', 'm', 'e', ')', ';', 't', 'e', 'x', 't', ':', 't', 'o', 'k', 'e', 'n', ' ', 'i',
+ 'n', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '_', 't', 'o', 'k', '=', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'o', 'n', 'T', 'o', 'r', 'r', 'e', 'n',
+ 't', ':', 't', 'o', 'k', 'e', 'n', 'i', 'z', 'e', '_', 's', 'p', 'o', 't', '_', 'n',
+ 'a', 'm', 'e', '#', '1', '(', 'N', 'A', 'M', 'E', ')', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', ' ', 'o', 'u', 't',
+ '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '=', '.', 'P', 'O', 'S', 'I', 'T', 'I',
+ 'O', 'N', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm',
+ 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'o', 'n', 'T', 'o', 'r',
+ 'r', 'e', 'n', 't', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'P', 'O', 'S',
+ 'I', 'T', 'I', 'O', 'N', '#', '1', ' ', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N',
+ '=', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a',
+ 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c',
+ 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n', 'c',
+ 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A',
+ 'P', 'T', 'E', 'R', '_', 'L', 'E', 'F', 'T', '=', 'C', 'L', 'I', 'P', '_', 'A', 'D',
+ 'A', 'P', 'T', 'E', 'R', '_', 'L', 'E', 'F', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c',
+ 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S', 'D', 'C', ':',
+ 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'i', 'z', 'i', 'p', '_', 'e', 'n',
+ 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'C', 'L', 'I', 'P', '_', 'A', 'D',
+ 'A', 'P', 'T', 'E', 'R', '_', 'R', 'I', 'G', 'H', 'T', '=', 'C', 'L', 'I', 'P', '_',
+ 'A', 'D', 'A', 'P', 'T', 'E', 'R', '_', 'R', 'I', 'G', 'H', 'T', ';', 'p', 'h', 'y',
+ 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N', 'S',
+ 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'i', 'z', 'i', 'p',
+ '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'C', 'L', 'I', 'P',
+ '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'L', 'E', 'F', 'T', '=', 'C', 'L', 'I',
+ 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'L', 'E', 'F', 'T', ';', 'p', 'h',
+ 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', '<', 'I', 'N',
+ 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'o', 'n', 'e', '>', 'i', 'z', 'i',
+ 'p', '_', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', '#', '1', ' ', '.', 'C', 'L', 'I',
+ 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'R', 'I', 'G', 'H', 'T', '=', 'C',
+ 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_', 'R', 'I', 'G', 'H', 'T',
';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- '_', '4', '5', '4', '_', ':', 't', 'b', 'l', ':', 'v', '0', '#', '1', '=', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'l', 'e', 'g', 'a',
- 'c', 'y', '#', '1', '{', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', '=', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'u', 'n', 't', 'y',
- 'p', 'e', 'd', '_', '0', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A',
- ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'o', 'u', 't', '_',
- 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S',
- 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', '>', 'e', 'c',
- 'h', 'o', '#', '1', '<', '1', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '2',
- 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u', 't', '_', '2', 'n', 'a',
- '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '.', 'R', 'E', 'A', 'D', ';', 'I', 'N', 'S',
- 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ',
- 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', '=', '.', 'Q',
- 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'a', 's', 'c', 'i', 'i', ' ', 'o', 'u', 't', '_',
- 'l', 'a', 'b', 'e', 'l', '=', '<', 'a', 's', 'c', 'i', 'i', '>', 'e', 'x', 'i', 's',
- 't', 's', '#', '1', '<', '\'', 'A', 'd', 'a', 'p', 't', 'e', 'r', 'M', 'a', 't',
- 'e', '1', 'L', 'i', 'n', 'k', 'e', 'r', 'M', 'a', 't', 'e', '2', '\'', '>', '(',
+ '_', '4', '5', '4', '_', ':', 'l', 'e', 'g', 'a', 'c', 'y', '#', '1', '=', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'r', 'a', '_', 'n', 'o',
+ 'p', 'o', 's', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b',
+ 'l', ':', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '_', 'n', 'o', 'c', 'o',
+ 'l', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':',
+ 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_', 'n', 'o', 'c',
+ 'o', 'l', '#', '1', '.', '0', '.', '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', 't', 'b', 'l', ':', 's', 'k', 'e', 'y', 'n', 'a', 'm', 'e', '#', '1', '.', '0',
+ '.', '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_',
+ ':', 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.', '0', '.', '4', '{', 'r', 'e', 'a',
+ 'd', 'o', 'n', 'l', 'y', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'R', 'E', 'G', 'I', 'O',
+ 'N', ' ', '=', ' ', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
+ 'v', 'a', 'l', ')', '<', 'I', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '2', '>',
+ '(', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r', 'o', 'm', '_', 's', 'k', 'e', 'y',
+ ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l',
+ ' ', 'o', 'u', 't', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S',
+ 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', '<', 'I', '3', '2',
+ '>', 'c', 'u', 't', '#', '1', '<', '0', '>', '(', 'c', 'o', 'o', 'r', 'd', 's', '_',
+ 'f', 'r', 'o', 'm', '_', 's', 'k', 'e', 'y', ')', ';', 'I', 'N', 'S', 'D', 'C', ':',
+ 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'x', '_', 'c',
+ 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'v', 'a', 'l', ')', '<', 'I', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '1',
+ '>', '(', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r', 'o', 'm', '_', 's', 'k', 'e',
+ 'y', ')', ';', 'I', '3', '2', '[', '3', ']', ' ', 'c', 'o', 'o', 'r', 'd', 's', '_',
+ 'f', 'r', 'o', 'm', '_', 's', 'k', 'e', 'y', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'c', 'o', 'o', 'r', 'd', 'i', 'n',
+ 'a', 't', 'e', 's', '#', '1', '<', '1', '>', '(', 'o', 'u', 't', '_', 's', 'k', 'e',
+ 'y', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', '_', '4', '5', '4', '_', ':', 't', 'b', 'l', ':', 'v', '0', '#', '1', '=',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'l', 'e',
+ 'g', 'a', 'c', 'y', '#', '1', '{', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', '=',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'u', 'n',
+ 't', 'y', 'p', 'e', 'd', '_', '0', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S',
+ 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'o', 'u',
+ 't', '_', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '=', '<', 'I', 'N', 'S', 'D', 'C',
+ ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', '>',
+ 'e', 'c', 'h', 'o', '#', '1', '<', '1', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u', 't', '_', '2',
+ 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '.', 'R', 'E', 'A', 'D', ';', 'I',
+ 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e',
+ 'd', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', '=',
+ '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'a', 's', 'c', 'i', 'i', ' ', 'o', 'u',
+ 't', '_', 'l', 'a', 'b', 'e', 'l', '=', '<', 'a', 's', 'c', 'i', 'i', '>', 'e', 'x',
+ 'i', 's', 't', 's', '#', '1', '<', '\'', 'A', 'd', 'a', 'p', 't', 'e', 'r', 'M',
+ 'a', 't', 'e', '1', 'L', 'i', 'n', 'k', 'e', 'r', 'M', 'a', 't', 'e', '2', '\'',
+ '>', '(', 'o', 'u', 't', '_', 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u',
+ 'e', 'n', 'c', 'e', ')', '|', '<', 'a', 's', 'c', 'i', 'i', '>', 'e', 'c', 'h', 'o',
+ '#', '1', '<', '\'', 'A', 'd', 'a', 'p', 't', 'e', 'r', 'F', 'r', 'a', 'g', 'm',
+ 'e', 'n', 't', '\'', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
+ 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e',
+ 'l', '_', 's', 't', 'a', 'r', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
+ 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', '>', 'e', 'x', 'i', 's', 't', 's', '#', '1',
+ '<', '[', '0', ',', '7', ',', '1', '2', ',', '1', '8', ']', '>', '(', 'o', 'u', 't',
+ '_', 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', ')',
+ '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r',
+ 'o', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '[', '0', ',', '7', ']', '>', '(', ')',
+ ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ',
+ 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 'l', 'e', 'n', '=', '<', 'I', 'N',
+ 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', '>', 'e', 'x', 'i',
+ 's', 't', 's', '#', '1', '<', '[', '7', ',', '5', ',', '6', ',', '5', ']', '>', '(',
'o', 'u', 't', '_', 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n',
- 'c', 'e', ')', '|', '<', 'a', 's', 'c', 'i', 'i', '>', 'e', 'c', 'h', 'o', '#', '1',
- '<', '\'', 'A', 'd', 'a', 'p', 't', 'e', 'r', 'F', 'r', 'a', 'g', 'm', 'e', 'n',
- 't', '\'', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
- 'd', ':', 'z', 'e', 'r', 'o', ' ', 'o', 'u', 't', '_', 'l', 'a', 'b', 'e', 'l', '_',
- 's', 't', 'a', 'r', 't', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
- 'd', ':', 'z', 'e', 'r', 'o', '>', 'e', 'x', 'i', 's', 't', 's', '#', '1', '<', '[',
- '0', ',', '7', ',', '1', '2', ',', '1', '8', ']', '>', '(', 'o', 'u', 't', '_', 'l',
- 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', ')', '|', '<',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', '>',
- 'e', 'c', 'h', 'o', '#', '1', '<', '[', '0', ',', '7', ']', '>', '(', ')', ';', 'I',
- 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'o', 'u',
- 't', '_', 'l', 'a', 'b', 'e', 'l', '_', 'l', 'e', 'n', '=', '<', 'I', 'N', 'S', 'D',
- 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', '>', 'e', 'x', 'i', 's', 't',
- 's', '#', '1', '<', '[', '7', ',', '5', ',', '6', ',', '5', ']', '>', '(', 'o', 'u',
- 't', '_', 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e',
- ')', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e',
- 'n', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '[', '7', ',', '8', ']', '>', '(', ')',
+ 'c', 'e', ')', '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
+ 'l', 'e', 'n', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '[', '7', ',', '8', ']', '>',
+ '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't',
+ ' ', 'o', 'u', 't', '_', 'f', 'l', 'o', 'w', '_', 'c', 'h', 'a', 'r', 's', '=', '<',
+ 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'm', 'e',
+ 't', 'a', ':', 'r', 'e', 'a', 'd', '#', '1', '<', '\'', 'M', 'S', 'C', '4', '5',
+ '4', '_', 'F', 'L', 'O', 'W', '_', 'C', 'H', 'A', 'R', 'S', '\'', '>', '(', ')',
';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o',
- 'u', 't', '_', 'f', 'l', 'o', 'w', '_', 'c', 'h', 'a', 'r', 's', '=', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'm', 'e', 't', 'a',
- ':', 'r', 'e', 'a', 'd', '#', '1', '<', '\'', 'M', 'S', 'C', '4', '5', '4', '_',
- 'F', 'L', 'O', 'W', '_', 'C', 'H', 'A', 'R', 'S', '\'', '>', '(', ')', ';', 'I',
- 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o', 'u', 't',
- '_', 'k', 'e', 'y', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '=', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'm', 'e', 't', 'a',
- ':', 'r', 'e', 'a', 'd', '#', '1', '<', '\'', 'M', 'S', 'C', '4', '5', '4', '_',
- 'K', 'E', 'Y', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', '\'', '>', '(', ')',
- ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o',
- 'u', 't', '_', 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c',
- 'e', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't',
- '>', 'm', 'e', 't', 'a', ':', 'r', 'e', 'a', 'd', '#', '1', '<', '\'', 'M', 'S',
- 'C', '4', '5', '4', '_', 'L', 'I', 'N', 'K', 'E', 'R', '_', 'S', 'E', 'Q', 'U', 'E',
- 'N', 'C', 'E', '\'', '>', '(', ')', ';', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', 'p', 'o', 's', '1', '6', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i',
- 'o', 'n', '1', '6', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5',
- '4', '_', ':', 'p', 'r', 'o', 'c', 'e', 's', 's', '_', 'p', 'o', 's', 'i', 't', 'i',
- 'o', 'n', '#', '1', '(', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ',', '.', 'R',
- 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', ',', '.', 'S', 'I', 'G', 'N', 'A', 'L', ')',
- '|', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'p',
- 'r', 'o', 'c', 'e', 's', 's', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '#', '1',
- '(', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ',', '.', 'R', 'D', '_', 'F', 'I',
- 'L', 'T', 'E', 'R', ')', '|', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4',
- '5', '4', '_', ':', 'p', 'r', 'o', 'c', 'e', 's', 's', '_', 'p', 'o', 's', 'i', 't',
- 'i', 'o', 'n', '#', '1', '(', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ')', ';',
- 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':', 'o', 'n',
- 'e', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '=', 'c', 'a',
- 's', 't', '#', '1', '(', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n',
- '1', '6', ')', ';', 'U', '3', '2', '[', '3', ']', ' ', 'd', 'y', 'n', 'a', 'm', 'i',
- 'c', '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', '=', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'd', 'y', 'n', 'a', 'm', 'i', 'c',
- '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', '#', '1', '<', '4', '>', '(', 'o',
- 'u', 't', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ',', 'o', 'u', 't', '_', 'k', 'e',
- 'y', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', ',', 'o', 'u', 't', '_', 'l', 'i',
- 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', ')', '|', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'd', 'y', 'n', 'a',
- 'm', 'i', 'c', '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', '#', '1', '(', 'o',
- 'u', 't', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ',', 'o', 'u', 't', '_', 'k', 'e',
- 'y', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', ')', ';', 'U', '8', ' ', 'o', 'u',
- 't', '_', 'n', 'r', 'e', 'a', 'd', 's', '=', '<', 'U', '8', '>', 'e', 'x', 'i', 's',
- 't', 's', '#', '1', '<', '4', '>', '(', 'o', 'u', 't', '_', 'l', 'i', 'n', 'k', 'e',
- 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', ')', '|', '<', 'U', '8', '>', 'e',
- 'c', 'h', 'o', '#', '1', '<', '2', '>', '(', ')', ';', 'U', '3', '2', ' ', 'r', 'e',
- 'a', 'd', '_', 't', 'y', 'p', 'e', '3', '2', '=', '<', 'U', '3', '2', '>', 'c', 'u',
- 't', '#', '1', '<', '0', '>', '(', 'd', 'y', 'n', 'a', 'm', 'i', 'c', '_', 'r', 'e',
- 'a', 'd', '_', 'd', 'e', 's', 'c', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R',
- 'A', ':', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'o', 'u', 't', '_', 'r',
- 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '=', 'c', 'a', 's', 't', '#', '1', '(', 'r',
- 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '3', '2', ')', ';', 'U', '3', '2', ' ', 'u',
- 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', '=', '<', 'U', '3', '2', '>', 'c',
- 'u', 't', '#', '1', '<', '1', '>', '(', 'd', 'y', 'n', 'a', 'm', 'i', 'c', '_', 'r',
- 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a',
- 'd', '_', 's', 't', 'a', 'r', 't', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
- 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ')', 'u', 'r', 'e', 'a', 'd', '_', 's', 't',
- 'a', 'r', 't', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l',
- 'e', 'n', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n', '=', '(',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ')', '<',
- 'U', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '2', '>', '(', 'd', 'y', 'n', 'a',
- 'm', 'i', 'c', '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', ')', ';', 'I', 'N',
- 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't',
- 'e', 'r', ' ', 'o', 'u', 't', '_', 'r', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', '=',
- '.', 'R', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', '|', '<', 'I', 'N', 'S', 'D', 'C',
- ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e', 'r', '>',
- 'e', 'c', 'h', 'o', '#', '1', '<', '0', '>', '(', 'd', 'y', 'n', 'a', 'm', 'i', 'c',
- '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', ')', ';', 'p', 'h', 'y', 's', 'i',
+ 'u', 't', '_', 'k', 'e', 'y', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '=', '<',
+ 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', '>', 'm', 'e',
+ 't', 'a', ':', 'r', 'e', 'a', 'd', '#', '1', '<', '\'', 'M', 'S', 'C', '4', '5',
+ '4', '_', 'K', 'E', 'Y', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', '\'', '>',
+ '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't',
+ ' ', 'o', 'u', 't', '_', 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e',
+ 'n', 'c', 'e', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e',
+ 'x', 't', '>', 'm', 'e', 't', 'a', ':', 'r', 'e', 'a', 'd', '#', '1', '<', '\'',
+ 'M', 'S', 'C', '4', '5', '4', '_', 'L', 'I', 'N', 'K', 'E', 'R', '_', 'S', 'E', 'Q',
+ 'U', 'E', 'N', 'C', 'E', '\'', '>', '(', ')', ';', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 'p', 'o', 's', '1', '6', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i',
+ 't', 'i', 'o', 'n', '1', '6', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_',
+ '4', '5', '4', '_', ':', 'p', 'r', 'o', 'c', 'e', 's', 's', '_', 'p', 'o', 's', 'i',
+ 't', 'i', 'o', 'n', '#', '1', '(', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ',',
+ '.', 'R', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', ',', '.', 'S', 'I', 'G', 'N', 'A',
+ 'L', ')', '|', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_',
+ ':', 'p', 'r', 'o', 'c', 'e', 's', 's', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n',
+ '#', '1', '(', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ',', '.', 'R', 'D', '_',
+ 'F', 'I', 'L', 'T', 'E', 'R', ')', '|', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ '_', '4', '5', '4', '_', ':', 'p', 'r', 'o', 'c', 'e', 's', 's', '_', 'p', 'o', 's',
+ 'i', 't', 'i', 'o', 'n', '#', '1', '(', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N',
+ ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', ':',
+ 'o', 'n', 'e', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '=',
+ 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't', 'i',
+ 'o', 'n', '1', '6', ')', ';', 'U', '3', '2', '[', '3', ']', ' ', 'd', 'y', 'n', 'a',
+ 'm', 'i', 'c', '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', '=', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'd', 'y', 'n', 'a', 'm',
+ 'i', 'c', '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', '#', '1', '<', '4', '>',
+ '(', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ',', 'o', 'u', 't', '_',
+ 'k', 'e', 'y', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', ',', 'o', 'u', 't', '_',
+ 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', ')', '|',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'd', 'y',
+ 'n', 'a', 'm', 'i', 'c', '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', '#', '1',
+ '(', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'b', 'i', 'n', ',', 'o', 'u', 't', '_',
+ 'k', 'e', 'y', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', ')', ';', 'U', '8', ' ',
+ 'o', 'u', 't', '_', 'n', 'r', 'e', 'a', 'd', 's', '=', '<', 'U', '8', '>', 'e', 'x',
+ 'i', 's', 't', 's', '#', '1', '<', '4', '>', '(', 'o', 'u', 't', '_', 'l', 'i', 'n',
+ 'k', 'e', 'r', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', ')', '|', '<', 'U', '8',
+ '>', 'e', 'c', 'h', 'o', '#', '1', '<', '2', '>', '(', ')', ';', 'U', '3', '2', ' ',
+ 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '3', '2', '=', '<', 'U', '3', '2', '>',
+ 'c', 'u', 't', '#', '1', '<', '0', '>', '(', 'd', 'y', 'n', 'a', 'm', 'i', 'c', '_',
+ 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', ')', ';', 'I', 'N', 'S', 'D', 'C', ':',
+ 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', ' ', 'o', 'u', 't',
+ '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '=', 'c', 'a', 's', 't', '#', '1',
+ '(', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '3', '2', ')', ';', 'U', '3', '2',
+ ' ', 'u', 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', '=', '<', 'U', '3', '2',
+ '>', 'c', 'u', 't', '#', '1', '<', '1', '>', '(', 'd', 'y', 'n', 'a', 'm', 'i', 'c',
+ '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', ')', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'o', 'u', 't', '_', 'r',
+ 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', '=', '(', 'I', 'N', 'S', 'D', 'C', ':',
+ 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ')', 'u', 'r', 'e', 'a', 'd', '_',
+ 's', 't', 'a', 'r', 't', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
+ ':', 'l', 'e', 'n', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e', 'n',
+ '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n',
+ ')', '<', 'U', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '2', '>', '(', 'd', 'y',
+ 'n', 'a', 'm', 'i', 'c', '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', ')', ';',
+ 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i',
+ 'l', 't', 'e', 'r', ' ', 'o', 'u', 't', '_', 'r', 'd', '_', 'f', 'i', 'l', 't', 'e',
+ 'r', '=', '.', 'R', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', '|', '<', 'I', 'N', 'S',
+ 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 'f', 'i', 'l', 't', 'e',
+ 'r', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '0', '>', '(', 'd', 'y', 'n', 'a', 'm',
+ 'i', 'c', '_', 'r', 'e', 'a', 'd', '_', 'd', 'e', 's', 'c', ')', ';', 'p', 'h', 'y',
+ 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I',
+ ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i',
+ 'n', 'g', ':', 'C', 'L', 'I', 'P', '#', '1', ' ', '.', 'C', 'L', 'I', 'P', '_', 'A',
+ 'D', 'A', 'P', 'T', 'E', 'R', '_', 'L', 'E', 'F', 'T', ';', 'p', 'h', 'y', 's', 'i',
'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S',
'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g',
':', 'C', 'L', 'I', 'P', '#', '1', ' ', '.', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A',
- 'P', 'T', 'E', 'R', '_', 'L', 'E', 'F', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a',
- 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C',
- 'L', 'I', 'P', '#', '1', ' ', '.', 'C', 'L', 'I', 'P', '_', 'A', 'D', 'A', 'P', 'T',
- 'E', 'R', '_', 'R', 'I', 'G', 'H', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l',
+ 'P', 'T', 'E', 'R', '_', 'R', 'I', 'G', 'H', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c',
+ 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':',
+ 'C', 'L', 'I', 'P', '#', '1', ' ', '.', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L',
+ 'I', 'T', 'Y', '_', 'L', 'E', 'F', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l',
' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
'_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C', 'L',
'I', 'P', '#', '1', ' ', '.', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T',
- 'Y', '_', 'L', 'E', 'F', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c',
- 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4',
- '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'C', 'L', 'I', 'P',
- '#', '1', ' ', '.', 'C', 'L', 'I', 'P', '_', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '_',
- 'R', 'I', 'G', 'H', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o',
- 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5',
- '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'R', 'E', 'A', 'D', '#',
- '1', ' ', '.', 'R', 'E', 'A', 'D', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
+ 'Y', '_', 'R', 'I', 'G', 'H', 'T', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_',
- '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'Q', 'U', 'A',
- 'L', 'I', 'T', 'Y', '#', '1', ' ', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'p',
- 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o',
- 'd', 'i', 'n', 'g', ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '1', ' ', '.', 'S', 'I',
- 'G', 'N', 'A', 'L', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l',
- 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4',
- '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'P', 'O', 'S', 'I', 'T', 'I',
- 'O', 'N', '#', '1', ' ', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ';', '}', 't',
- 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5',
- '4', '_', ':', 't', 'b', 'l', ':', 'v', '1', '#', '1', '=', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'l', 'e', 'g', 'a', 'c', 'y', '#',
- '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p',
- 'o', 't', 'd', 'e', 's', 'c', '_', 'n', 'o', 'p', 'h', 'y', 's', '#', '1', '.', '0',
- '.', '2', '{', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't',
- 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'o', 'u', 't', '_', 'p', 'l', 'a', 't', 'f',
- 'o', 'r', 'm', '=', '.', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '|', '<', 'I', 'N',
- 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_',
- 'i', 'd', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '1', '>', '(', ')', ';', 'I', 'N',
- 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u',
- 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '.', 'R', 'E', 'A',
- 'D', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p',
- 'h', 'r', 'e', 'd', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r',
- 'e', 'd', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'I', 'N', 'S', 'D', 'C',
- ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o', 'u', 't', '_', 'f', 'l', 'o',
- 'w', '_', 'c', 'h', 'a', 'r', 's', '=', '.', 'F', 'L', 'O', 'W', '_', 'C', 'H', 'A',
- 'R', 'S', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't',
- ' ', 'o', 'u', 't', '_', 'k', 'e', 'y', '_', 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e',
- '=', '.', 'K', 'E', 'Y', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ';', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', 'p', 'o', 's', '1', '6', ' ', 'o', 'u', 't', '_',
- 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '1', '6', '=', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'p', 'r', 'o', 'c', 'e', 's', 's', '_',
- 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '#', '1', '(', '.', 'P', 'O', 'S', 'I', 'T',
- 'I', 'O', 'N', ',', '.', 'R', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', ',', '.', 'S',
- 'I', 'G', 'N', 'A', 'L', ')', '|', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_',
- '4', '5', '4', '_', ':', 'p', 'r', 'o', 'c', 'e', 's', 's', '_', 'p', 'o', 's', 'i',
- 't', 'i', 'o', 'n', '#', '1', '(', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ',',
- '.', 'R', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', ')', '|', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'p', 'r', 'o', 'c', 'e', 's', 's',
- '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '#', '1', '(', '.', 'P', 'O', 'S', 'I',
- 'T', 'I', 'O', 'N', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's', 'i', 't',
- 'i', 'o', 'n', ':', 'o', 'n', 'e', ' ', 'o', 'u', 't', '_', 'p', 'o', 's', 'i', 't',
- 'i', 'o', 'n', '=', 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u', 't', '_', 'p', 'o',
- 's', 'i', 't', 'i', 'o', 'n', '1', '6', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 't', 'b',
- 'l', ':', 'v', '1', '_', '2', 'a', '#', '1', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', '_', '4', '5', '4', '_', ':', 't', 'b', 'l', ':', 'v', '1', '#', '1', '{',
- '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', '_', '4', '5', '4', '_', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '1',
- '_', '2', 'a', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't',
- 'e', 'x', 't', ' ', 'o', 'u', 't', '_', 'l', 'i', 'n', 'k', 'e', 'r', '_', 's', 'e',
- 'q', 'u', 'e', 'n', 'c', 'e', '=', '.', 'L', 'I', 'N', 'K', 'E', 'R', '_', 'S', 'E',
- 'Q', 'U', 'E', 'N', 'C', 'E', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 't', 'b', 'l', ':', 'v',
- '1', '_', '2', 'b', '#', '1', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_',
- '4', '5', '4', '_', ':', 't', 'b', 'l', ':', 'v', '1', '#', '1', '{', '_', '_', 'u',
- 'n', 't', 'y', 'p', 'e', 'd', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_',
- '4', '5', '4', '_', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '1', '_', '2', 'b',
- '(', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'l', 'e', 'g', 'a', 'c', 'y',
- '#', '1', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's',
- 'r', 'a', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l',
- ':', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '_', 'n', 'o', 'c', 'o', 'l',
- '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I',
- 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.',
- '0', '.', '3', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'f',
- 's', 'a', 'm', 'p', '4', ' ', 'S', 'I', 'G', 'N', 'A', 'L', ' ', '=', ' ', '(', 'N',
- 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p',
- '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1',
- '(', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', ',', 'o', 'u', 't', '_', 'x',
+ '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'R', 'E', 'A',
+ 'D', '#', '1', ' ', '.', 'R', 'E', 'A', 'D', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a',
+ 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', '_', '4', '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'Q',
+ 'U', 'A', 'L', 'I', 'T', 'Y', '#', '1', ' ', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y',
+ ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'e', 'n',
+ 'c', 'o', 'd', 'i', 'n', 'g', ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '1', ' ', '.',
+ 'S', 'I', 'G', 'N', 'A', 'L', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c',
+ 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4',
+ '5', '4', '_', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'P', 'O', 'S', 'I',
+ 'T', 'I', 'O', 'N', '#', '1', ' ', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O', 'N', ';',
+ '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_',
+ '4', '5', '4', '_', ':', 't', 'b', 'l', ':', 'v', '1', '#', '1', '=', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'l', 'e', 'g', 'a', 'c',
+ 'y', '#', '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':',
+ 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '_', 'n', 'o', 'p', 'h', 'y', 's', '#', '1',
+ '.', '0', '.', '2', '{', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l',
+ 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'o', 'u', 't', '_', 'p', 'l', 'a',
+ 't', 'f', 'o', 'r', 'm', '=', '.', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '|', '<',
+ 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r',
+ 'm', '_', 'i', 'd', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '1', '>', '(', ')', ';',
+ 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ',
+ 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '.', 'R',
+ 'E', 'A', 'D', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y',
+ ':', 'p', 'h', 'r', 'e', 'd', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p',
+ 'h', 'r', 'e', 'd', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'I', 'N', 'S',
+ 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o', 'u', 't', '_', 'f',
+ 'l', 'o', 'w', '_', 'c', 'h', 'a', 'r', 's', '=', '.', 'F', 'L', 'O', 'W', '_', 'C',
+ 'H', 'A', 'R', 'S', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e',
+ 'x', 't', ' ', 'o', 'u', 't', '_', 'k', 'e', 'y', '_', 's', 'e', 'q', 'u', 'e', 'n',
+ 'c', 'e', '=', '.', 'K', 'E', 'Y', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ';',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'p', 'o', 's', '1', '6', ' ', 'o', 'u',
+ 't', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '1', '6', '=', 'N', 'C', 'B', 'I',
+ ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'p', 'r', 'o', 'c', 'e', 's',
+ 's', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '#', '1', '(', '.', 'P', 'O', 'S',
+ 'I', 'T', 'I', 'O', 'N', ',', '.', 'R', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', ',',
+ '.', 'S', 'I', 'G', 'N', 'A', 'L', ')', '|', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', '_', '4', '5', '4', '_', ':', 'p', 'r', 'o', 'c', 'e', 's', 's', '_', 'p', 'o',
+ 's', 'i', 't', 'i', 'o', 'n', '#', '1', '(', '.', 'P', 'O', 'S', 'I', 'T', 'I', 'O',
+ 'N', ',', '.', 'R', 'D', '_', 'F', 'I', 'L', 'T', 'E', 'R', ')', '|', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'p', 'r', 'o', 'c', 'e',
+ 's', 's', '_', 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '#', '1', '(', '.', 'P', 'O',
+ 'S', 'I', 'T', 'I', 'O', 'N', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'p', 'o', 's',
+ 'i', 't', 'i', 'o', 'n', ':', 'o', 'n', 'e', ' ', 'o', 'u', 't', '_', 'p', 'o', 's',
+ 'i', 't', 'i', 'o', 'n', '=', 'c', 'a', 's', 't', '#', '1', '(', 'o', 'u', 't', '_',
+ 'p', 'o', 's', 'i', 't', 'i', 'o', 'n', '1', '6', ')', ';', '}', 't', 'a', 'b', 'l',
+ 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':',
+ 't', 'b', 'l', ':', 'v', '1', '_', '2', 'a', '#', '1', '=', 'N', 'C', 'B', 'I', ':',
+ 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 't', 'b', 'l', ':', 'v', '1', '#',
+ '1', '{', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', '=', 'N', 'C', 'B', 'I', ':',
+ 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd',
+ '_', '1', '_', '2', 'a', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a',
+ ':', 't', 'e', 'x', 't', ' ', 'o', 'u', 't', '_', 'l', 'i', 'n', 'k', 'e', 'r', '_',
+ 's', 'e', 'q', 'u', 'e', 'n', 'c', 'e', '=', '.', 'L', 'I', 'N', 'K', 'E', 'R', '_',
+ 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', '_', '4', '5', '4', '_', ':', 't', 'b', 'l',
+ ':', 'v', '1', '_', '2', 'b', '#', '1', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', '_', '4', '5', '4', '_', ':', 't', 'b', 'l', ':', 'v', '1', '#', '1', '{', '_',
+ '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', '_', '4', '5', '4', '_', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '1', '_',
+ '2', 'b', '(', ')', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':',
+ 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'l', 'e', 'g', 'a',
+ 'c', 'y', '#', '1', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l',
+ ':', 's', 'r', 'a', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't',
+ 'b', 'l', ':', 'b', 'a', 's', 'e', '_', 's', 'p', 'a', 'c', 'e', '_', 'n', 'o', 'c',
+ 'o', 'l', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'c', 'o', 'm', 'm', 'o', 'n', '#',
+ '1', '.', '0', '.', '3', '{', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I',
+ ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'S', 'I', 'G', 'N', 'A', 'L', ' ', '=', ' ',
+ '(', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a',
+ 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p',
+ '#', '1', '(', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', ',', 'o', 'u', 't',
+ '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', '|', '(', 'N', 'C', 'B', 'I', ':',
+ 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 'r', 'o', 't', 'a', 't', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', '>', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'o', 't', 'a', 't', 'e', '#', '1', '<', 'f',
+ 'a', 'l', 's', 'e', '>', '(', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', ',',
+ 'o', 'u', 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'c', 'o', 'l',
+ 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'I',
+ 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', ' ', '=', ' ', '<', 'N', 'C', 'B', 'I', ':',
+ 'f', 's', 'a', 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd',
+ 'e', 'n', 'o', 'r', 'm', 'a', 'l', 'i', 'z', 'e', '#', '1', '(', 'o', 'u', 't', '_',
+ 'n', 'o', 'r', 'm', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ',', 'o', 'u',
+ 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'c', 'o', 'l', 'u', 'm',
+ 'n', ' ', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'N', 'O', 'I',
+ 'S', 'E', ' ', '=', ' ', 'o', 'u', 't', '_', 'n', 'o', 'i', 's', 'e', ';', 'N', 'C',
+ 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u', 't', '_', 'n', 'o', 'r',
+ 'm', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', '=', '(', 'N', 'C', 'B', 'I',
+ ':', 'f', 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', '>', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(', 'o', 'u',
+ 't', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ',', 'o', 'u', 't', '_', 'x',
'2', 'n', 'a', '_', 'b', 'i', 'n', ')', '|', '(', 'N', 'C', 'B', 'I', ':', 'f', 's',
'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'o',
't', 'a', 't', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', '>', 'N', 'C', 'B', 'I',
':', 'S', 'R', 'A', ':', 'r', 'o', 't', 'a', 't', 'e', '#', '1', '<', 'f', 'a', 'l',
- 's', 'e', '>', '(', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', ',', 'o', 'u',
- 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'c', 'o', 'l', 'u', 'm',
- 'n', ' ', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'I', 'N', 'T',
- 'E', 'N', 'S', 'I', 'T', 'Y', ' ', '=', ' ', '<', 'N', 'C', 'B', 'I', ':', 'f', 's',
- 'a', 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'd', 'e', 'n',
- 'o', 'r', 'm', 'a', 'l', 'i', 'z', 'e', '#', '1', '(', 'o', 'u', 't', '_', 'n', 'o',
- 'r', 'm', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ',', 'o', 'u', 't', '_',
- 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
- 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'N', 'O', 'I', 'S', 'E',
- ' ', '=', ' ', 'o', 'u', 't', '_', 'n', 'o', 'i', 's', 'e', ';', 'N', 'C', 'B', 'I',
- ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u', 't', '_', 'n', 'o', 'r', 'm', '_',
- 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', '=', '(', 'N', 'C', 'B', 'I', ':', 'f',
- 's', 'a', 'm', 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's',
- 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', '>', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', '#', '1', '(', 'o', 'u', 't', '_',
- 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ',', 'o', 'u', 't', '_', 'x', '2', 'n',
- 'a', '_', 'b', 'i', 'n', ')', '|', '(', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm',
- 'p', '4', ')', '<', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'o', 't', 'a',
- 't', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', '>', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 'r', 'o', 't', 'a', 't', 'e', '#', '1', '<', 'f', 'a', 'l', 's', 'e',
- '>', '(', 'o', 'u', 't', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', ',', 'o',
- 'u', 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', '}', 't', 'a', 'b',
- 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm',
- 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '0', '#', '1', '=', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'l', 'e', 'g',
- 'a', 'c', 'y', '#', '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b',
- 'l', ':', 's', 'k', 'e', 'y', 'n', 'a', 'm', 'e', '#', '1', '.', '0', '.', '1', '{',
- 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r',
- 'm', '_', 'i', 'd', ' ', 'o', 'u', 't', '_', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm',
- '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f',
- 'o', 'r', 'm', '_', 'i', 'd', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '2', '>', '(',
- ')', ';', 'a', 's', 'c', 'i', 'i', ' ', 'o', 'u', 't', '_', 's', 'l', 'x', '_', 'p',
- 'r', 'e', 'f', 'i', 'x', '=', '<', 'a', 's', 'c', 'i', 'i', '>', 'm', 'e', 't', 'a',
- ':', 'r', 'e', 'a', 'd', '#', '1', '<', '\'', 'S', 'L', 'X', '_', 'P', 'R', 'E',
- 'F', 'I', 'X', '\'', '>', '(', ')', '|', '<', 'a', 's', 'c', 'i', 'i', '>', 'e',
- 'c', 'h', 'o', '#', '1', '<', '\'', '\'', '>', '(', ')', ';', 'a', 's', 'c', 'i',
- 'i', ' ', 'r', 'e', 'w', 'r', 'i', 't', 't', 'e', 'n', '_', 's', 'p', 'o', 't', '_',
- 'n', 'a', 'm', 'e', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'e', 'w',
- 'r', 'i', 't', 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#', '1', '<',
- '2', '>', '(', 'o', 'u', 't', '_', 's', 'k', 'e', 'y', ',', 'o', 'u', 't', '_', 's',
- 'l', 'x', '_', 'p', 'r', 'e', 'f', 'i', 'x', ')', ';', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'y', '_', 'c',
- 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
- ':', 'v', 'a', 'l', ')', '<', 'I', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '0',
- '>', '(', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r', 'o', 'm', '_', 's', 'k', 'e',
- 'y', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a',
- 'l', ' ', 'o', 'u', 't', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', '=', '(', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', '<', 'I', '3',
- '2', '>', 'c', 'u', 't', '#', '1', '<', '1', '>', '(', 'c', 'o', 'o', 'r', 'd', 's',
- '_', 'f', 'r', 'o', 'm', '_', 's', 'k', 'e', 'y', ')', ';', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 't', 'i',
- 'l', 'e', '_', 'c', 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', '<', 'I', '3', '2', '>', 'c', 'u', 't',
- '#', '1', '<', '2', '>', '(', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r', 'o', 'm',
- '_', 's', 'k', 'e', 'y', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
- 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'l', 'a', 'n', 'e', '_', 'c', 'o',
- 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
- 'v', 'a', 'l', ')', '<', 'I', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '3', '>',
- '(', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r', 'o', 'm', '_', 's', 'k', 'e', 'y',
- ')', ';', 'I', '3', '2', '[', '4', ']', ' ', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f',
- 'r', 'o', 'm', '_', 's', 'k', 'e', 'y', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'c', 'o', 'o', 'r', 'd', 'i', 'n', 'a',
- 't', 'e', 's', '#', '1', '<', '2', '>', '(', 'o', 'u', 't', '_', 's', 'k', 'e', 'y',
- ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e',
- 'd', ' ', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=',
- '.', 'R', 'E', 'A', 'D', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd',
- ':', 'l', 'e', 'n', ' ', 's', 't', 'a', 't', 'i', 'c', '_', 'f', 'i', 'x', 'e', 'd',
- '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '=', 's', 'p', 'o', 't', '_', 'l', 'e',
- 'n', ';', 'U', '8', ' ', 'o', 'u', 't', '_', 'n', 'r', 'e', 'a', 'd', 's', '=', '<',
- 'U', '8', '>', 'm', 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1', '<', '\'',
- 'N', 'R', 'E', 'A', 'D', 'S', '\'', '>', '(', ')', '|', '<', 'U', '8', '>', 'e',
- 'c', 'h', 'o', '#', '1', '<', '1', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'o', 'u', 't', '_', 'r', 'e',
- 'a', 'd', '_', 's', 't', 'a', 'r', 't', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ')', '<', 'U', '3', '2', '>', 'c', 'u',
- 't', '#', '1', '<', '1', '>', '(', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '_', 'f',
- 'r', 'o', 'm', '_', 'r', 'e', 'a', 'd', 'n', ')', '|', '<', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', '>', 'e', 'c', 'h', 'o', '#',
- '1', '<', '0', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
- 'd', ':', 'l', 'e', 'n', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 'l', 'e',
- 'n', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e',
- 'n', ')', '<', 'U', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '2', '>', '(', 'r',
+ 's', 'e', '>', '(', 'o', 'u', 't', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y',
+ ',', 'o', 'u', 't', '_', 'x', '2', 'n', 'a', '_', 'b', 'i', 'n', ')', ';', '}', 't',
+ 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l',
+ 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '0', '#', '1', '=', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'l',
+ 'e', 'g', 'a', 'c', 'y', '#', '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 't', 'b', 'l', ':', 's', 'k', 'e', 'y', 'n', 'a', 'm', 'e', '#', '1', '.', '0', '.',
+ '1', '{', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f',
+ 'o', 'r', 'm', '_', 'i', 'd', ' ', 'o', 'u', 't', '_', 'p', 'l', 'a', 't', 'f', 'o',
+ 'r', 'm', '=', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a',
+ 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '2',
+ '>', '(', ')', ';', 'a', 's', 'c', 'i', 'i', ' ', 'o', 'u', 't', '_', 's', 'l', 'x',
+ '_', 'p', 'r', 'e', 'f', 'i', 'x', '=', '<', 'a', 's', 'c', 'i', 'i', '>', 'm', 'e',
+ 't', 'a', ':', 'r', 'e', 'a', 'd', '#', '1', '<', '\'', 'S', 'L', 'X', '_', 'P',
+ 'R', 'E', 'F', 'I', 'X', '\'', '>', '(', ')', '|', '<', 'a', 's', 'c', 'i', 'i',
+ '>', 'e', 'c', 'h', 'o', '#', '1', '<', '\'', '\'', '>', '(', ')', ';', 'a', 's',
+ 'c', 'i', 'i', ' ', 'r', 'e', 'w', 'r', 'i', 't', 't', 'e', 'n', '_', 's', 'p', 'o',
+ 't', '_', 'n', 'a', 'm', 'e', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r',
+ 'e', 'w', 'r', 'i', 't', 'e', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '#',
+ '1', '<', '2', '>', '(', 'o', 'u', 't', '_', 's', 'k', 'e', 'y', ',', 'o', 'u', 't',
+ '_', 's', 'l', 'x', '_', 'p', 'r', 'e', 'f', 'i', 'x', ')', ';', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'y',
+ '_', 'c', 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
+ 'r', 'd', ':', 'v', 'a', 'l', ')', '<', 'I', '3', '2', '>', 'c', 'u', 't', '#', '1',
+ '<', '0', '>', '(', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r', 'o', 'm', '_', 's',
+ 'k', 'e', 'y', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
+ 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', '=', '(',
+ 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', '<',
+ 'I', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '1', '>', '(', 'c', 'o', 'o', 'r',
+ 'd', 's', '_', 'f', 'r', 'o', 'm', '_', 's', 'k', 'e', 'y', ')', ';', 'I', 'N', 'S',
+ 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_',
+ 't', 'i', 'l', 'e', '_', 'c', 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C',
+ ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', '<', 'I', '3', '2', '>', 'c',
+ 'u', 't', '#', '1', '<', '2', '>', '(', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r',
+ 'o', 'm', '_', 's', 'k', 'e', 'y', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
+ 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'l', 'a', 'n', 'e', '_',
+ 'c', 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r',
+ 'd', ':', 'v', 'a', 'l', ')', '<', 'I', '3', '2', '>', 'c', 'u', 't', '#', '1', '<',
+ '3', '>', '(', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r', 'o', 'm', '_', 's', 'k',
+ 'e', 'y', ')', ';', 'I', '3', '2', '[', '4', ']', ' ', 'c', 'o', 'o', 'r', 'd', 's',
+ '_', 'f', 'r', 'o', 'm', '_', 's', 'k', 'e', 'y', '=', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'c', 'o', 'o', 'r', 'd', 'i',
+ 'n', 'a', 't', 'e', 's', '#', '1', '<', '2', '>', '(', 'o', 'u', 't', '_', 's', 'k',
+ 'e', 'y', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c',
+ 'k', 'e', 'd', ' ', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e',
+ 'd', '=', '.', 'R', 'E', 'A', 'D', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o',
+ 'r', 'd', ':', 'l', 'e', 'n', ' ', 's', 't', 'a', 't', 'i', 'c', '_', 'f', 'i', 'x',
+ 'e', 'd', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '=', 's', 'p', 'o', 't', '_',
+ 'l', 'e', 'n', ';', 'U', '8', ' ', 'o', 'u', 't', '_', 'n', 'r', 'e', 'a', 'd', 's',
+ '=', '<', 'U', '8', '>', 'm', 'e', 't', 'a', ':', 'v', 'a', 'l', 'u', 'e', '#', '1',
+ '<', '\'', 'N', 'R', 'E', 'A', 'D', 'S', '\'', '>', '(', ')', '|', '<', 'U', '8',
+ '>', 'e', 'c', 'h', 'o', '#', '1', '<', '1', '>', '(', ')', ';', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ' ', 'o', 'u', 't', '_',
+ 'r', 'e', 'a', 'd', '_', 's', 't', 'a', 'r', 't', '=', '(', 'I', 'N', 'S', 'D', 'C',
+ ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', ')', '<', 'U', '3', '2', '>',
+ 'c', 'u', 't', '#', '1', '<', '1', '>', '(', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g',
+ '_', 'f', 'r', 'o', 'm', '_', 'r', 'e', 'a', 'd', 'n', ')', '|', '<', 'I', 'N', 'S',
+ 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'z', 'e', 'r', 'o', '>', 'e', 'c', 'h',
+ 'o', '#', '1', '<', '0', '>', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o',
+ 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_',
+ 'l', 'e', 'n', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':',
+ 'l', 'e', 'n', ')', '<', 'U', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '2', '>',
+ '(', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '_', 'f', 'r', 'o', 'm', '_', 'r', 'e',
+ 'a', 'd', 'n', ')', '|', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ';', 'U', '3', '2',
+ '[', '5', ']', ' ', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '_', 'f', 'r', 'o', 'm',
+ '_', 'r', 'e', 'a', 'd', 'n', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r',
'e', 'a', 'd', '_', 's', 'e', 'g', '_', 'f', 'r', 'o', 'm', '_', 'r', 'e', 'a', 'd',
- 'n', ')', '|', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ';', 'U', '3', '2', '[', '5',
- ']', ' ', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '_', 'f', 'r', 'o', 'm', '_', 'r',
- 'e', 'a', 'd', 'n', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a',
- 'd', '_', 's', 'e', 'g', '_', 'f', 'r', 'o', 'm', '_', 'r', 'e', 'a', 'd', 'n', '#',
- '1', '(', 'o', 'u', 't', '_', 'n', 'r', 'e', 'a', 'd', 's', ',', 's', 'p', 'o', 't',
- '_', 'l', 'e', 'n', ')', ';', 'U', '3', '2', ' ', 'r', 'e', 'a', 'd', '_', 't', 'y',
- 'p', 'e', '_', 'f', 'r', 'o', 'm', '_', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', '=',
- '<', 'U', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '0', '>', '(', 'r', 'e', 'a',
- 'd', '_', 's', 'e', 'g', '_', 'f', 'r', 'o', 'm', '_', 'r', 'e', 'a', 'd', 'n', ')',
- ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 't',
- 'y', 'p', 'e', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e',
- '=', 'c', 'a', 's', 't', '#', '1', '(', 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e',
- '_', 'f', 'r', 'o', 'm', '_', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', ')', '|', '(',
- 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_', 't', 'y',
- 'p', 'e', ')', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x', 'r', 'e',
- 'a', 'd', '_', 't', 'y', 'p', 'e', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '1', '>',
- '(', ')', ';', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'o', 't', 'a', 't',
- 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u', 't', '_', 's', 'i', 'g',
- 'n', 'a', 'l', '=', '.', 'S', 'I', 'G', 'N', 'A', 'L', ';', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'r', 'o', 't', 'a', 't', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p',
- '4', ' ', 'o', 'u', 't', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y', '=', '.',
- 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', ';', 'N', 'C', 'B', 'I', ':', 'f', 's',
- 'a', 'm', 'p', '4', ' ', 'o', 'u', 't', '_', 'n', 'o', 'i', 's', 'e', '=', '.', 'N',
- 'O', 'I', 'S', 'E', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l',
- 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u',
- 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'R', 'E', 'A',
- 'D', '#', '1', ' ', '.', 'R', 'E', 'A', 'D', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a',
- 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
- ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n',
- 'g', ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '1', ' ', '.', 'S', 'I', 'G', 'N', 'A',
- 'L', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n',
- ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n',
- 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'I', 'N', 'T', 'E', 'N', 'S',
- 'I', 'T', 'Y', '#', '1', ' ', '.', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', ';',
- 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':',
- 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'N', 'O', 'I', 'S', 'E', '#', '1', ' ',
- '.', 'N', 'O', 'I', 'S', 'E', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b',
- 'l', ':', 'v', '0', 'a', '#', '1', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
- 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '0', '#', '1',
- ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n',
- 'a', ':', 'q', 'u', 'a', 'l', '4', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0',
- '.', '1', '{', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', '=', 'N', 'C', 'B', 'I',
- ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'u', 'n', 't',
- 'y', 'p', 'e', 'd', '_', '0', 'a', '(', ')', ';', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 'r', 'o', 't', 'a', 't', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4', ' ', 'o',
- 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 'r', 'o', 't', 'a', 't', 'e', 'd', '=',
- '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u',
- 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'o', 'u', 't', '_', 'q',
- 'u', 'a', 'l', '2', '_', 'p', 'h', 'r', 'e', 'd', '=', '.', 'Q', 'U', 'A', 'L', 'I',
- 'T', 'Y', '2', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u',
+ 'n', '#', '1', '(', 'o', 'u', 't', '_', 'n', 'r', 'e', 'a', 'd', 's', ',', 's', 'p',
+ 'o', 't', '_', 'l', 'e', 'n', ')', ';', 'U', '3', '2', ' ', 'r', 'e', 'a', 'd', '_',
+ 't', 'y', 'p', 'e', '_', 'f', 'r', 'o', 'm', '_', 'r', 'e', 'a', 'd', '_', 's', 'e',
+ 'g', '=', '<', 'U', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '0', '>', '(', 'r',
+ 'e', 'a', 'd', '_', 's', 'e', 'g', '_', 'f', 'r', 'o', 'm', '_', 'r', 'e', 'a', 'd',
+ 'n', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd',
+ '_', 't', 'y', 'p', 'e', ' ', 'o', 'u', 't', '_', 'r', 'e', 'a', 'd', '_', 't', 'y',
+ 'p', 'e', '=', 'c', 'a', 's', 't', '#', '1', '(', 'r', 'e', 'a', 'd', '_', 't', 'y',
+ 'p', 'e', '_', 'f', 'r', 'o', 'm', '_', 'r', 'e', 'a', 'd', '_', 's', 'e', 'g', ')',
+ '|', '(', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'r', 'e', 'a', 'd', '_',
+ 't', 'y', 'p', 'e', ')', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'x',
+ 'r', 'e', 'a', 'd', '_', 't', 'y', 'p', 'e', '>', 'e', 'c', 'h', 'o', '#', '1', '<',
+ '1', '>', '(', ')', ';', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'r', 'o', 't',
+ 'a', 't', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u', 't', '_', 's',
+ 'i', 'g', 'n', 'a', 'l', '=', '.', 'S', 'I', 'G', 'N', 'A', 'L', ';', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', 'r', 'o', 't', 'a', 't', 'e', 'd', '_', 'f', 's', 'a',
+ 'm', 'p', '4', ' ', 'o', 'u', 't', '_', 'i', 'n', 't', 'e', 'n', 's', 'i', 't', 'y',
+ '=', '.', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y', ';', 'N', 'C', 'B', 'I', ':',
+ 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u', 't', '_', 'n', 'o', 'i', 's', 'e', '=',
+ '.', 'N', 'O', 'I', 'S', 'E', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c',
+ 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l',
+ 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'R',
+ 'E', 'A', 'D', '#', '1', ' ', '.', 'R', 'E', 'A', 'D', ';', 'p', 'h', 'y', 's', 'i',
+ 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S',
+ 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd',
+ 'i', 'n', 'g', ':', 'S', 'I', 'G', 'N', 'A', 'L', '#', '1', ' ', '.', 'S', 'I', 'G',
+ 'N', 'A', 'L', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u',
'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm',
- 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'Q', 'U', 'A', 'L',
- 'I', 'T', 'Y', '#', '1', ' ', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'p', 'h',
- 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n',
- 'c', 'o', 'd', 'i', 'n', 'g', ':', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '2', '#', '1',
- ' ', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '2', ';', '}', 't', 'a', 'b', 'l', 'e',
+ 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'I', 'N', 'T', 'E',
+ 'N', 'S', 'I', 'T', 'Y', '#', '1', ' ', '.', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T',
+ 'Y', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n',
' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n',
- 'a', ':', 't', 'b', 'l', ':', 'v', '0', 'b', '#', '1', '=', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':',
- 'v', '0', '#', '1', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'p', 'h', 'r',
- 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_', 'n', 'o', 'c', 'o', 'l', '#',
- '1', '.', '0', '.', '1', '{', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', '=', 'N',
+ 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'N', 'O', 'I', 'S', 'E', '#',
+ '1', ' ', '.', 'N', 'O', 'I', 'S', 'E', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N',
'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':',
- 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '0', 'b', '(', ')', ';', 'I', 'N', 'S', 'D',
- 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'o',
- 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', '=', '.', 'Q', 'U',
- 'A', 'L', 'I', 'T', 'Y', '|', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '2', ';', 'p',
- 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C',
- 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e',
- 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '2', '#',
- '1', ' ', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'p', 'h', 'y', 's', 'i', 'c',
- 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R',
- 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i',
- 'n', 'g', ':', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '2', '#', '1', ' ', '.', 'Q', 'U',
- 'A', 'L', 'I', 'T', 'Y', '2', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b',
- 'l', ':', 'v', '1', '#', '1', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I',
- 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'l', 'e', 'g', 'a', 'c', 'y', '#', '1', ',',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p', 'o', 't',
- 'd', 'e', 's', 'c', '_', 'n', 'o', 'p', 'h', 'y', 's', '#', '1', '.', '0', '.', '2',
- ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'k', 'e',
- 'y', 'n', 'a', 'm', 'e', '_', 'n', 'o', 'c', 'o', 'l', '#', '2', '.', '0', '.', '1',
- '{', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o',
- 'r', 'm', '_', 'i', 'd', ' ', 'o', 'u', 't', '_', 'p', 'l', 'a', 't', 'f', 'o', 'r',
- 'm', '=', '.', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '|', '<', 'I', 'N', 'S', 'D',
- 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd',
- '>', 'e', 'c', 'h', 'o', '#', '1', '<', '2', '>', '(', ')', ';', 'I', 'N', 'S', 'D',
- 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 't',
- 'i', 'l', 'e', '_', 'c', 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':',
- 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', '<', 'I', '3', '2', '>', 'c', 'u',
- 't', '#', '1', '<', '2', '>', '(', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r', 'o',
- 'm', '_', 's', 'p', 'o', 't', 'n', 'a', 'm', 'e', ')', ';', 'I', 'N', 'S', 'D', 'C',
- ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_', 'l', 'a',
- 'n', 'e', '_', 'c', 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', '<', 'I', '3', '2', '>', 'c', 'u', 't',
- '#', '1', '<', '3', '>', '(', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r', 'o', 'm',
- '_', 's', 'p', 'o', 't', 'n', 'a', 'm', 'e', ')', ';', 'I', '3', '2', '[', '4', ']',
- ' ', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r', 'o', 'm', '_', 's', 'p', 'o', 't',
- 'n', 'a', 'm', 'e', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e', 'x', 't',
- 'r', 'a', 'c', 't', '_', 'c', 'o', 'o', 'r', 'd', 'i', 'n', 'a', 't', 'e', 's', '#',
- '1', '<', '2', '>', '(', '_', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', ')', ';', 'I',
- 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o',
- 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '.', 'R', 'E',
- 'A', 'D', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':',
- 'p', 'h', 'r', 'e', 'd', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '2', '_', 'p',
- 'h', 'r', 'e', 'd', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '2', ';', 'I', 'N',
- 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 's', 't', 'a',
- 't', 'i', 'c', '_', 'f', 'i', 'x', 'e', 'd', '_', 's', 'p', 'o', 't', '_', 'l', 'e',
- 'n', '=', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ';', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4',
- ' ', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', '=', '.', 'S', 'I', 'G', 'N',
- 'A', 'L', ';', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p',
- 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u', 't', '_', 'i', 'n', 't',
- 'e', 'n', 's', 'i', 't', 'y', '=', '.', 'I', 'N', 'T', 'E', 'N', 'S', 'I', 'T', 'Y',
- ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u', 't', '_',
- 'n', 'o', 'i', 's', 'e', '=', '.', 'N', 'O', 'I', 'S', 'E', ';', 'p', 'h', 'y', 's',
- 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C',
- ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', '.', 'F', 'L', 'O', 'W', '_', 'C',
- 'H', 'A', 'R', 'S', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l',
- 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x',
- 't', ' ', '.', 'K', 'E', 'Y', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ';', 'p',
- 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N',
- 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', '.', 'L', 'I', 'N',
- 'K', 'E', 'R', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ';', '}', 't', 'a', 'b',
+ 't', 'b', 'l', ':', 'v', '0', 'a', '#', '1', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R',
+ 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '0',
+ '#', '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm',
+ 'i', 'n', 'a', ':', 'q', 'u', 'a', 'l', '4', '_', 'n', 'o', 'c', 'o', 'l', '#', '1',
+ '.', '0', '.', '1', '{', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', '=', 'N', 'C',
+ 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'u',
+ 'n', 't', 'y', 'p', 'e', 'd', '_', '0', 'a', '(', ')', ';', 'N', 'C', 'B', 'I', ':',
+ 'S', 'R', 'A', ':', 'r', 'o', 't', 'a', 't', 'e', 'd', '_', 'q', 'u', 'a', 'l', '4',
+ ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 'r', 'o', 't', 'a', 't', 'e',
+ 'd', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'I', 'N', 'S', 'D', 'C', ':',
+ 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'o', 'u', 't',
+ '_', 'q', 'u', 'a', 'l', '2', '_', 'p', 'h', 'r', 'e', 'd', '=', '.', 'Q', 'U', 'A',
+ 'L', 'I', 'T', 'Y', '2', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o',
+ 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l',
+ 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'Q', 'U',
+ 'A', 'L', 'I', 'T', 'Y', '#', '1', ' ', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';',
+ 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':',
+ 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '2',
+ '#', '1', ' ', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '2', ';', '}', 't', 'a', 'b',
'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm',
- 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '1', 'a', '#', '1', '=', 'N', 'C', 'B',
+ 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '0', 'b', '#', '1', '=', 'N', 'C', 'B',
'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b',
- 'l', ':', 'v', '1', '#', '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I',
- 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'q', 'u', 'a', 'l', '4', '_', 'n', 'o', 'c',
- 'o', 'l', '#', '1', '.', '0', '.', '1', '{', '_', '_', 'u', 'n', 't', 'y', 'p', 'e',
- 'd', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i',
- 'n', 'a', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '1', 'a', '(', ')', ';', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'q',
- 'u', 'a', 'l', '4', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_', 's', 'w',
- 'a', 'p', 'p', 'e', 'd', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', '}', 't',
+ 'l', ':', 'v', '0', '#', '1', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'p',
+ 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_', 'n', 'o', 'c', 'o',
+ 'l', '#', '1', '.', '0', '.', '1', '{', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd',
+ '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n',
+ 'a', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '0', 'b', '(', ')', ';', 'I', 'N',
+ 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r', 'e', 'd',
+ ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd', '=', '.',
+ 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '|', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '2',
+ ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
+ 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a',
+ ':', 'e', 'n', 'c', 'o', 'd', 'i', 'n', 'g', ':', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y',
+ '2', '#', '1', ' ', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'p', 'h', 'y', 's',
+ 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'N', 'C', 'B', 'I', ':',
+ 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'e', 'n', 'c', 'o',
+ 'd', 'i', 'n', 'g', ':', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '2', '#', '1', ' ', '.',
+ 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '2', ';', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':',
+ 't', 'b', 'l', ':', 'v', '1', '#', '1', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'l', 'e', 'g', 'a', 'c', 'y', '#',
+ '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's', 'p',
+ 'o', 't', 'd', 'e', 's', 'c', '_', 'n', 'o', 'p', 'h', 'y', 's', '#', '1', '.', '0',
+ '.', '2', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's',
+ 'k', 'e', 'y', 'n', 'a', 'm', 'e', '_', 'n', 'o', 'c', 'o', 'l', '#', '2', '.', '0',
+ '.', '1', '{', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't',
+ 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'o', 'u', 't', '_', 'p', 'l', 'a', 't', 'f',
+ 'o', 'r', 'm', '=', '.', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '|', '<', 'I', 'N',
+ 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_',
+ 'i', 'd', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '2', '>', '(', ')', ';', 'I', 'N',
+ 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't',
+ '_', 't', 'i', 'l', 'e', '_', 'c', 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D',
+ 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', '<', 'I', '3', '2', '>',
+ 'c', 'u', 't', '#', '1', '<', '2', '>', '(', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f',
+ 'r', 'o', 'm', '_', 's', 'p', 'o', 't', 'n', 'a', 'm', 'e', ')', ';', 'I', 'N', 'S',
+ 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o', 'u', 't', '_',
+ 'l', 'a', 'n', 'e', '_', 'c', 'o', 'o', 'r', 'd', '=', '(', 'I', 'N', 'S', 'D', 'C',
+ ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', '<', 'I', '3', '2', '>', 'c',
+ 'u', 't', '#', '1', '<', '3', '>', '(', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r',
+ 'o', 'm', '_', 's', 'p', 'o', 't', 'n', 'a', 'm', 'e', ')', ';', 'I', '3', '2', '[',
+ '4', ']', ' ', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r', 'o', 'm', '_', 's', 'p',
+ 'o', 't', 'n', 'a', 'm', 'e', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'e',
+ 'x', 't', 'r', 'a', 'c', 't', '_', 'c', 'o', 'o', 'r', 'd', 'i', 'n', 'a', 't', 'e',
+ 's', '#', '1', '<', '2', '>', '(', '_', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', ')',
+ ';', 'I', 'N', 'S', 'D', 'C', ':', '2', 'n', 'a', ':', 'p', 'a', 'c', 'k', 'e', 'd',
+ ' ', 'o', 'u', 't', '_', '2', 'n', 'a', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '.',
+ 'R', 'E', 'A', 'D', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't',
+ 'y', ':', 'p', 'h', 'r', 'e', 'd', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '2',
+ '_', 'p', 'h', 'r', 'e', 'd', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', '2', ';',
+ 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 's',
+ 't', 'a', 't', 'i', 'c', '_', 'f', 'i', 'x', 'e', 'd', '_', 's', 'p', 'o', 't', '_',
+ 'l', 'e', 'n', '=', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', ';', 'N', 'C', 'B', 'I',
+ ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm',
+ 'p', '4', ' ', 'o', 'u', 't', '_', 's', 'i', 'g', 'n', 'a', 'l', '=', '.', 'S', 'I',
+ 'G', 'N', 'A', 'L', ';', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a',
+ 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u', 't', '_', 'i',
+ 'n', 't', 'e', 'n', 's', 'i', 't', 'y', '=', '.', 'I', 'N', 'T', 'E', 'N', 'S', 'I',
+ 'T', 'Y', ';', 'N', 'C', 'B', 'I', ':', 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u',
+ 't', '_', 'n', 'o', 'i', 's', 'e', '=', '.', 'N', 'O', 'I', 'S', 'E', ';', 'p', 'h',
+ 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S',
+ 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', '.', 'F', 'L', 'O', 'W',
+ '_', 'C', 'H', 'A', 'R', 'S', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c',
+ 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't',
+ 'e', 'x', 't', ' ', '.', 'K', 'E', 'Y', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E',
+ ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ',
+ 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', '.', 'L',
+ 'I', 'N', 'K', 'E', 'R', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ';', '}', 't',
'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l',
- 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '1', 'b', '#', '1', '=', 'N',
+ 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '1', 'a', '#', '1', '=', 'N',
'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':',
- 't', 'b', 'l', ':', 'v', '1', '#', '1', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l',
- ':', 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_', 'n', 'o',
- 'c', 'o', 'l', '#', '1', '.', '0', '.', '1', '{', '_', '_', 'u', 'n', 't', 'y', 'p',
- 'e', 'd', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm',
- 'i', 'n', 'a', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '1', 'b', '(', ')', ';',
- 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r',
- 'e', 'd', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd',
- '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', '}', 't', 'a', 'b', 'l', 'e', ' ',
- 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 'l', 'e', 'g', 'a',
- 'c', 'y', '#', '1', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l',
- ':', 's', 'r', 'a', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 't',
+ 't', 'b', 'l', ':', 'v', '1', '#', '1', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A',
+ ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 'q', 'u', 'a', 'l', '4', '_', 'n',
+ 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '1', '{', '_', '_', 'u', 'n', 't', 'y',
+ 'p', 'e', 'd', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u',
+ 'm', 'i', 'n', 'a', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '1', 'a', '(', ')',
+ ';', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w', 'a', 'p', 'p', 'e', 'd',
+ '_', 'q', 'u', 'a', 'l', '4', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '4', '_',
+ 's', 'w', 'a', 'p', 'p', 'e', 'd', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';',
+ '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I',
+ 'l', 'l', 'u', 'm', 'i', 'n', 'a', ':', 't', 'b', 'l', ':', 'v', '1', 'b', '#', '1',
+ '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l', 'u', 'm', 'i', 'n',
+ 'a', ':', 't', 'b', 'l', ':', 'v', '1', '#', '1', ',', 'N', 'C', 'B', 'I', ':', 't',
'b', 'l', ':', 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't', 'y', '_',
- 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '1', ',', 'N', 'C', 'B', 'I', ':',
- 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 'c', 'o', 'm', 'm', 'o', 'n', '#', '1', '.',
- '0', '.', '3', '{', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 'A', 'B', 'I', ':', 't', 'b', 'l', ':', 'v', '1', '#', '1', '=', 'N',
- 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 'l', 'e', 'g', 'a', 'c',
- 'y', '#', '1', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'c', 'o', 'l', 'o',
- 'r', '_', 's', 'p', 'a', 'c', 'e', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0',
- '.', '3', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':', 's',
- 'p', 'o', 't', 'd', 'e', 's', 'c', '_', 'n', 'o', 'p', 'h', 'y', 's', '#', '1', '.',
- '0', '.', '2', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l', ':',
- 's', 'k', 'e', 'y', 'n', 'a', 'm', 'e', '_', 'n', 'o', 'c', 'o', 'l', '#', '2', '.',
- '0', '.', '1', '{', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', '=', 'N', 'C', 'B',
- 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd',
- '_', '1', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l',
- 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'o', 'u', 't', '_', 'p', 'l', 'a',
- 't', 'f', 'o', 'r', 'm', '=', '.', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M', '|', '<',
- 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f', 'o', 'r',
- 'm', '_', 'i', 'd', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '3', '>', '(', ')', ';',
- 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ' ', 'o',
- 'u', 't', '_', 'p', 'a', 'n', 'e', 'l', '_', 'c', 'o', 'o', 'r', 'd', '=', '(', 'I',
- 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')', '<', 'I',
- '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '2', '>', '(', 'c', 'o', 'o', 'r', 'd',
- 's', '_', 'f', 'r', 'o', 'm', '_', 's', 'p', 'o', 't', 'n', 'a', 'm', 'e', ')', ';',
- 'I', '3', '2', '[', '4', ']', ' ', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f', 'r', 'o',
- 'm', '_', 's', 'p', 'o', 't', 'n', 'a', 'm', 'e', '=', 'N', 'C', 'B', 'I', ':', 'S',
- 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'c', 'o', 'o', 'r', 'd', 'i',
- 'n', 'a', 't', 'e', 's', '#', '1', '<', '3', '>', '(', 'o', 'u', 't', '_', 's', 'p',
- 'o', 't', '_', 'n', 'a', 'm', 'e', ')', ';', 'a', 's', 'c', 'i', 'i', ' ', 'o', 'u',
- 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '=', 'I', 'N', 'S', 'D', 'C',
- ':', 'S', 'R', 'A', ':', 'f', 'o', 'r', 'm', 'a', 't', '_', 's', 'p', 'o', 't', '_',
- 'n', 'a', 'm', 'e', '#', '1', '(', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e', '_', 'f',
- 'm', 't', ',', 'o', 'u', 't', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', ',', 'o', 'u',
- 't', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', ')', ';', 'I', 'N', 'S', 'D', 'C', ':',
- '2', 'c', 's', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u', 't', '_', '2', 'c',
- 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '.', 'C', 'S', 'R', 'E', 'A', 'D', ';',
- 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', 'o', 'u',
- 't', '_', 'c', 's', '_', 'k', 'e', 'y', '=', '.', 'C', 'S', '_', 'K', 'E', 'Y', ';',
- 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p', 'h', 'r',
- 'e', 'd', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r', 'e', 'd',
- '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c',
- 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 's', 't', 'a', 't', 'i', 'c', '_', 'f',
- 'i', 'x', 'e', 'd', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '=', 's', 'p', 'o',
- 't', '_', 'l', 'e', 'n', ';', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 's', 'w',
- 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u', 't', '_',
- 's', 'i', 'g', 'n', 'a', 'l', '_', 's', 'w', 'a', 'p', 'p', 'e', 'd', '=', '.', 'S',
- 'I', 'G', 'N', 'A', 'L', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o',
- 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e',
- 'x', 't', ' ', '.', 'F', 'L', 'O', 'W', '_', 'C', 'H', 'A', 'R', 'S', ';', 'p', 'h',
- 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S',
- 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', '.', 'K', 'E', 'Y', '_',
- 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l',
- ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a',
- ':', 't', 'e', 'x', 't', ' ', '.', 'L', 'I', 'N', 'K', 'E', 'R', '_', 'S', 'E', 'Q',
- 'U', 'E', 'N', 'C', 'E', ';', '}',
+ 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '1', '{', '_', '_', 'u', 'n', 't',
+ 'y', 'p', 'e', 'd', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'I', 'l', 'l',
+ 'u', 'm', 'i', 'n', 'a', ':', 'u', 'n', 't', 'y', 'p', 'e', 'd', '_', '1', 'b', '(',
+ ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p',
+ 'h', 'r', 'e', 'd', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r',
+ 'e', 'd', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', '}', 't', 'a', 'b', 'l',
+ 'e', ' ', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 'l', 'e',
+ 'g', 'a', 'c', 'y', '#', '1', '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't',
+ 'b', 'l', ':', 's', 'r', 'a', '#', '1', '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I',
+ ':', 't', 'b', 'l', ':', 'p', 'h', 'r', 'e', 'd', '_', 'q', 'u', 'a', 'l', 'i', 't',
+ 'y', '_', 'n', 'o', 'c', 'o', 'l', '#', '1', '.', '0', '.', '1', ',', 'N', 'C', 'B',
+ 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 'c', 'o', 'm', 'm', 'o', 'n', '#',
+ '1', '.', '0', '.', '3', '{', '}', 't', 'a', 'b', 'l', 'e', ' ', 'N', 'C', 'B', 'I',
+ ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 't', 'b', 'l', ':', 'v', '1', '#', '1',
+ '=', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 'l', 'e', 'g',
+ 'a', 'c', 'y', '#', '1', ',', 'N', 'C', 'B', 'I', ':', 't', 'b', 'l', ':', 'c', 'o',
+ 'l', 'o', 'r', '_', 's', 'p', 'a', 'c', 'e', '_', 'n', 'o', 'c', 'o', 'l', '#', '1',
+ '.', '0', '.', '3', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b', 'l',
+ ':', 's', 'p', 'o', 't', 'd', 'e', 's', 'c', '_', 'n', 'o', 'p', 'h', 'y', 's', '#',
+ '1', '.', '0', '.', '2', ',', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 't', 'b',
+ 'l', ':', 's', 'k', 'e', 'y', 'n', 'a', 'm', 'e', '_', 'n', 'o', 'c', 'o', 'l', '#',
+ '2', '.', '0', '.', '1', '{', '_', '_', 'u', 'n', 't', 'y', 'p', 'e', 'd', '=', 'N',
+ 'C', 'B', 'I', ':', 'S', 'R', 'A', ':', 'A', 'B', 'I', ':', 'u', 'n', 't', 'y', 'p',
+ 'e', 'd', '_', '1', '(', ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':',
+ 'p', 'l', 'a', 't', 'f', 'o', 'r', 'm', '_', 'i', 'd', ' ', 'o', 'u', 't', '_', 'p',
+ 'l', 'a', 't', 'f', 'o', 'r', 'm', '=', '.', 'P', 'L', 'A', 'T', 'F', 'O', 'R', 'M',
+ '|', '<', 'I', 'N', 'S', 'D', 'C', ':', 'S', 'R', 'A', ':', 'p', 'l', 'a', 't', 'f',
+ 'o', 'r', 'm', '_', 'i', 'd', '>', 'e', 'c', 'h', 'o', '#', '1', '<', '3', '>', '(',
+ ')', ';', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l',
+ ' ', 'o', 'u', 't', '_', 'p', 'a', 'n', 'e', 'l', '_', 'c', 'o', 'o', 'r', 'd', '=',
+ '(', 'I', 'N', 'S', 'D', 'C', ':', 'c', 'o', 'o', 'r', 'd', ':', 'v', 'a', 'l', ')',
+ '<', 'I', '3', '2', '>', 'c', 'u', 't', '#', '1', '<', '2', '>', '(', 'c', 'o', 'o',
+ 'r', 'd', 's', '_', 'f', 'r', 'o', 'm', '_', 's', 'p', 'o', 't', 'n', 'a', 'm', 'e',
+ ')', ';', 'I', '3', '2', '[', '4', ']', ' ', 'c', 'o', 'o', 'r', 'd', 's', '_', 'f',
+ 'r', 'o', 'm', '_', 's', 'p', 'o', 't', 'n', 'a', 'm', 'e', '=', 'N', 'C', 'B', 'I',
+ ':', 'S', 'R', 'A', ':', 'e', 'x', 't', 'r', 'a', 'c', 't', '_', 'c', 'o', 'o', 'r',
+ 'd', 'i', 'n', 'a', 't', 'e', 's', '#', '1', '<', '3', '>', '(', 'o', 'u', 't', '_',
+ 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', ')', ';', 'a', 's', 'c', 'i', 'i', ' ',
+ 'o', 'u', 't', '_', 's', 'p', 'o', 't', '_', 'n', 'a', 'm', 'e', '=', 'I', 'N', 'S',
+ 'D', 'C', ':', 'S', 'R', 'A', ':', 'f', 'o', 'r', 'm', 'a', 't', '_', 's', 'p', 'o',
+ 't', '_', 'n', 'a', 'm', 'e', '#', '1', '(', 'o', 'u', 't', '_', 'n', 'a', 'm', 'e',
+ '_', 'f', 'm', 't', ',', 'o', 'u', 't', '_', 'x', '_', 'c', 'o', 'o', 'r', 'd', ',',
+ 'o', 'u', 't', '_', 'y', '_', 'c', 'o', 'o', 'r', 'd', ')', ';', 'I', 'N', 'S', 'D',
+ 'C', ':', '2', 'c', 's', ':', 'p', 'a', 'c', 'k', 'e', 'd', ' ', 'o', 'u', 't', '_',
+ '2', 'c', 's', '_', 'p', 'a', 'c', 'k', 'e', 'd', '=', '.', 'C', 'S', 'R', 'E', 'A',
+ 'D', ';', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ',
+ 'o', 'u', 't', '_', 'c', 's', '_', 'k', 'e', 'y', '=', '.', 'C', 'S', '_', 'K', 'E',
+ 'Y', ';', 'I', 'N', 'S', 'D', 'C', ':', 'q', 'u', 'a', 'l', 'i', 't', 'y', ':', 'p',
+ 'h', 'r', 'e', 'd', ' ', 'o', 'u', 't', '_', 'q', 'u', 'a', 'l', '_', 'p', 'h', 'r',
+ 'e', 'd', '=', '.', 'Q', 'U', 'A', 'L', 'I', 'T', 'Y', ';', 'I', 'N', 'S', 'D', 'C',
+ ':', 'c', 'o', 'o', 'r', 'd', ':', 'l', 'e', 'n', ' ', 's', 't', 'a', 't', 'i', 'c',
+ '_', 'f', 'i', 'x', 'e', 'd', '_', 's', 'p', 'o', 't', '_', 'l', 'e', 'n', '=', 's',
+ 'p', 'o', 't', '_', 'l', 'e', 'n', ';', 'N', 'C', 'B', 'I', ':', 'S', 'R', 'A', ':',
+ 's', 'w', 'a', 'p', 'p', 'e', 'd', '_', 'f', 's', 'a', 'm', 'p', '4', ' ', 'o', 'u',
+ 't', '_', 's', 'i', 'g', 'n', 'a', 'l', '_', 's', 'w', 'a', 'p', 'p', 'e', 'd', '=',
+ '.', 'S', 'I', 'G', 'N', 'A', 'L', ';', 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ',
+ 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':',
+ 't', 'e', 'x', 't', ' ', '.', 'F', 'L', 'O', 'W', '_', 'C', 'H', 'A', 'R', 'S', ';',
+ 'p', 'h', 'y', 's', 'i', 'c', 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I',
+ 'N', 'S', 'D', 'C', ':', 'd', 'n', 'a', ':', 't', 'e', 'x', 't', ' ', '.', 'K', 'E',
+ 'Y', '_', 'S', 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ';', 'p', 'h', 'y', 's', 'i', 'c',
+ 'a', 'l', ' ', 'c', 'o', 'l', 'u', 'm', 'n', ' ', 'I', 'N', 'S', 'D', 'C', ':', 'd',
+ 'n', 'a', ':', 't', 'e', 'x', 't', ' ', '.', 'L', 'I', 'N', 'K', 'E', 'R', '_', 'S',
+ 'E', 'Q', 'U', 'E', 'N', 'C', 'E', ';', '}',
};
-const size_t sra_schema_size = 68751;
+const size_t sra_schema_size = 68967;
diff --git a/libs/vdb/blob.c b/libs/vdb/blob.c
index e728390..e8ffc4a 100644
--- a/libs/vdb/blob.c
+++ b/libs/vdb/blob.c
@@ -379,11 +379,8 @@ rc_t PageMapProcessRequestLock(PageMapProcessRequest *self)
{
rc_t rc=RC(rcVDB,rcPagemap, rcConstructing, rcSelf, rcNull);
if(self){
- struct timeout_t tm;
- TimeoutInit(&tm,0);
- TimeoutPrepare(&tm);
- /*** no plans to wait here the thread should be relased by now ****/
- rc = KLockTimedAcquire(self->lock,&tm);
+ /*** no plans to wait here the thread should be released by now ****/
+ rc = KLockAcquire(self->lock);
if(rc == 0){
if(self->state != ePMPR_STATE_NONE){ /*** thread is not released yet **/
assert(0); /** should not happen ***/
@@ -398,8 +395,8 @@ rc_t PageMapProcessRequestLock(PageMapProcessRequest *self)
static
void PageMapProcessRequestLaunch(PageMapProcessRequest *self)
{
- KLockUnlock(self -> lock);
KConditionSignal ( self -> cond );
+ KLockUnlock(self -> lock);
}
rc_t PageMapProcessGetPagemap(const PageMapProcessRequest *cself,struct PageMap **pm)
@@ -425,8 +422,8 @@ CHECK_AGAIN:
KDataBufferWhack(&self->data);
self->row_count = 0;
self->state = ePMPR_STATE_NONE;
- KLockUnlock(self -> lock);
KConditionSignal(self->cond);
+ KLockUnlock(self -> lock);
break;
case ePMPR_STATE_NONE: /* not requested */
KLockUnlock(self -> lock);
@@ -851,14 +848,13 @@ void VBlobPageMapOptimize ( VBlob **vblobp)
PageMapRelease(new_pm);
}
- KDataBufferWhack(&new_data);
} else {
/*printf("NO OPTIMIZATION: vocab:%d,rows:%d,data_recs:%d\n",vocab_cnt ,pm->row_count,pm->data_recs);*/
- KDataBufferWhack(&new_data);
}
if(data_offset) free(data_offset);
if(vocab_key2id) KBTreeRelease ( vocab_key2id );
}
+ KDataBufferWhack(&new_data);
}
}
diff --git a/libs/vdb/cursor-cmn.c b/libs/vdb/cursor-cmn.c
index 85e6bb8..0f8f331 100644
--- a/libs/vdb/cursor-cmn.c
+++ b/libs/vdb/cursor-cmn.c
@@ -76,7 +76,11 @@
#define PERMIT_POST_OPEN_ADD 1
+#if _ARCH_BITS == 32
+#define DISABLE_READ_CACHE 1
+#else
#define DISABLE_READ_CACHE 0
+#endif
/* normally false
can be set for certain applications using VDBManagerDisablePagemapThread
@@ -505,19 +509,6 @@ rc_t VCursorSupplementSchema ( const VCursor *self )
* "capacity" [ IN ] - the maximum bytes to cache on the cursor before
* dropping least recently used blobs
*/
-static rc_t VTableCreateCachedCursorReadImpl(const VTable *self, const VCursor **cursp, size_t capacity,bool create_pagemap_thread);
-LIB_EXPORT rc_t CC VTableCreateCachedCursorRead ( const VTable *self,
- const VCursor **cursp, size_t capacity )
-{
- return VTableCreateCachedCursorReadImpl(self,cursp,capacity,true);
-}
-/**
-*** VTableCreateCursorReadInternal is only visible in vdb and needed for schema resolutions
-****/
-rc_t VTableCreateCursorReadInternal(const VTable *self, const VCursor **cursp)
-{
- return VTableCreateCachedCursorReadImpl(self,cursp,0,false);
-}
static rc_t VTableCreateCachedCursorReadImpl ( const VTable *self,
const VCursor **cursp, size_t capacity, bool create_pagemap_thread )
{
@@ -570,6 +561,20 @@ static rc_t VTableCreateCachedCursorReadImpl ( const VTable *self,
return rc;
}
+LIB_EXPORT rc_t CC VTableCreateCachedCursorRead ( const VTable *self,
+ const VCursor **cursp, size_t capacity )
+{
+ return VTableCreateCachedCursorReadImpl(self,cursp,capacity,true);
+}
+
+/**
+*** VTableCreateCursorReadInternal is only visible in vdb and needed for schema resolutions
+****/
+rc_t VTableCreateCursorReadInternal(const VTable *self, const VCursor **cursp)
+{
+ return VTableCreateCachedCursorReadImpl(self,cursp,0,false);
+}
+
/* CreateCursor
* creates a cursor object onto table
* multiple read cursors are allowed
@@ -2350,15 +2355,15 @@ CHECK_AGAIN:
}
self->pmpr.state = ePMPR_STATE_DESERIALIZE_DONE;
/*fprintf(stderr,"Pagemap %p Done R:%6d|DR:%d|LR:%d\n",self->pmpr.lock, self->pmpr.pm->row_count,self->pmpr.pm->data_recs,self->pmpr.pm->leng_recs);*/
- KLockUnlock(self -> pmpr.lock);
KConditionSignal ( self -> pmpr.cond );
+ KLockUnlock(self -> pmpr.lock);
break;
case ePMPR_STATE_SERIALIZE_REQUESTED:
MTCURSOR_DBG (( "run_pagemap_thread: request to serialize\n" ));
self->pmpr.rc = PageMapSerialize(self->pmpr.pm,&self->pmpr.data,0,&self->pmpr.elem_count);
self->pmpr.state = ePMPR_STATE_SERIALIZE_DONE;
- KLockUnlock(self -> pmpr.lock);
KConditionSignal ( self -> pmpr.cond );
+ KLockUnlock(self -> pmpr.lock);
break;
default:
assert(0);
diff --git a/libs/vdb/database-depend.c b/libs/vdb/database-depend.c
index 1b010db..c8c9b9f 100644
--- a/libs/vdb/database-depend.c
+++ b/libs/vdb/database-depend.c
@@ -43,11 +43,12 @@
#include <kfg/config.h>
#include <klib/container.h>
-#include <klib/printf.h> /* string_printf */
-#include <klib/text.h>
+#include <klib/debug.h> /* DBG_VDB */
#include <klib/log.h>
#include <klib/out.h>
+#include <klib/printf.h> /* string_printf */
#include <klib/rc.h>
+#include <klib/text.h>
#include <sysalloc.h>
@@ -188,6 +189,10 @@ rc_t AddColumn(rc_t rc, const VCursor* curs, Column* col)
assert(curs && col);
rc = VCursorAddColumn(curs, &col->idx, col->name);
+ if (rc != 0) {
+ DBGMSG(DBG_VDB, DBG_FLAG(DBG_VDB),
+ ("Cannot Add Column %s", col->name));
+ }
}
return rc;
@@ -528,7 +533,7 @@ static rc_t FindRef(Ctx* ctx, const char* seqId, Resolved* resolved,
}
if (rc == 0) {
- rc = VResolverRemote(ctx->resolver, eProtocolHttp, acc, &remote, NULL);
+ rc = VResolverRemote(ctx->resolver, eProtocolHttp, acc, &remote);
if (rc == 0) {
rc = VPathMakeString(remote, &resolved->remote);
if (rc == 0) {
diff --git a/libs/vdb/dbmgr-cmn.c b/libs/vdb/dbmgr-cmn.c
index 2cb0bf6..41ac831 100644
--- a/libs/vdb/dbmgr-cmn.c
+++ b/libs/vdb/dbmgr-cmn.c
@@ -688,6 +688,84 @@ LIB_EXPORT rc_t CC VDBManagerGetObjVersion ( const VDBManager *self, ver_t * ver
return rc;
}
+/* VDBManagerGetObjModDate
+ * returns the load/modification timestamp of the given object
+ */
+LIB_EXPORT rc_t CC VDBManagerGetObjModDate ( const VDBManager *self, KTime_t *timestamp, const char *path )
+{
+ rc_t rc;
+
+ if ( timestamp == NULL )
+ rc = RC ( rcVDB, rcMgr, rcAccessing, rcParam, rcNull );
+ else
+ {
+ if ( self == NULL )
+ rc = RC ( rcVDB, rcMgr, rcAccessing, rcSelf, rcNull );
+ else if ( path == NULL )
+ rc = RC ( rcVDB, rcMgr, rcAccessing, rcPath, rcNull );
+ else if ( path [ 0 ] == 0 )
+ rc = RC ( rcVDB, rcMgr, rcAccessing, rcPath, rcEmpty );
+ else
+ {
+ const KTable *tbl;
+ const KDatabase *db;
+ const KMetadata *meta;
+
+ int path_type = KDBManagerPathType ( self -> kmgr, path ) & ~ kptAlias;
+ switch ( path_type )
+ {
+ case kptDatabase:
+ rc = KDBManagerOpenDBRead ( self -> kmgr, & db, path );
+ if ( rc == 0 )
+ {
+ rc = KDatabaseOpenMetadataRead ( db, & meta );
+ KDatabaseRelease ( db );
+ }
+ break;
+ case kptTable:
+ rc = KDBManagerOpenTableRead ( self -> kmgr, & tbl, path );
+ if ( rc == 0 )
+ {
+ rc = KTableOpenMetadataRead ( tbl, & meta );
+ KTableRelease ( tbl );
+ }
+ break;
+
+ case kptPrereleaseTbl:
+ * timestamp = 0;
+ meta = NULL;
+ break;
+
+ default:
+ rc = RC ( rcVDB, rcMgr, rcAccessing, rcPath, rcIncorrect );
+ }
+
+ if ( rc == 0 )
+ {
+ if ( meta != NULL )
+ {
+ const KMDataNode *node;
+ rc = KMetadataOpenNodeRead ( meta, & node, "LOAD/timestamp" );
+ KMetadataRelease ( meta );
+ if ( rc == 0 )
+ {
+ rc = KMDataNodeReadAsI64 ( node, timestamp );
+ KMDataNodeRelease ( node );
+ if ( rc == 0 )
+ return 0;
+ }
+ }
+
+ /* TBD - at this point our recourse is to check for
+ the object's timestamp in the filesystem */
+ }
+ }
+
+ * timestamp = 0;
+ }
+
+ return rc;
+}
/* ListExternalSchemaModules
*/
diff --git a/libs/vdb/prod-priv.h b/libs/vdb/prod-priv.h
index 72feaa7..d1601ea 100644
--- a/libs/vdb/prod-priv.h
+++ b/libs/vdb/prod-priv.h
@@ -47,6 +47,9 @@
#include "blob-priv.h"
#endif
+#ifndef _h_klib_debug_
+#include <klib/debug.h> /* DBG_VDB */
+#endif
#ifdef __cplusplus
extern "C" {
diff --git a/libs/vdb/report-vdb.c b/libs/vdb/report-vdb.c
index a231dd7..58a263c 100644
--- a/libs/vdb/report-vdb.c
+++ b/libs/vdb/report-vdb.c
@@ -202,7 +202,7 @@ static rc_t VDBDependenciesReportDepend1(const VDBDependencies *self,
rc_t rc = 0;
uint32_t i = ~0;
- assert(count && missing);
+ assert(missing);
*missing = 0;
diff --git a/libs/vdb/table-cmn.c b/libs/vdb/table-cmn.c
index 009d399..af5a849 100644
--- a/libs/vdb/table-cmn.c
+++ b/libs/vdb/table-cmn.c
@@ -985,7 +985,7 @@ rc_t CC flush_tbl_typespec ( void *data, const void *buffer, size_t size )
LIB_EXPORT rc_t CC VTableTypespec ( const VTable *self, char *ts_buff, size_t ts_size )
{
- rc_t rc;
+ rc_t rc = 0;
if ( ts_size == 0 )
rc = RC ( rcVDB, rcTable, rcAccessing, rcBuffer, rcInsufficient );
diff --git a/libs/vdb/wcursor.c b/libs/vdb/wcursor.c
index a9790b5..0455850 100644
--- a/libs/vdb/wcursor.c
+++ b/libs/vdb/wcursor.c
@@ -171,8 +171,6 @@ rc_t VTableCreateCursorWriteInt ( VTable *self, VCursor **cursp, KCreateMode mod
rc = KThreadMake ( & curs -> flush_thread, run_flush_thread, curs );
}
#endif
- if(rc == 0)
- rc = VCursorLaunchPagemapThread(curs);
if ( rc == 0 )
{
* cursp = curs;
diff --git a/libs/vfs/Makefile b/libs/vfs/Makefile
index a3507de..12c32af 100644
--- a/libs/vfs/Makefile
+++ b/libs/vfs/Makefile
@@ -77,8 +77,7 @@ $(ILIBDIR)/libvfs: $(addprefix $(ILIBDIR)/libvfs.,$(ILIBEXT))
VFS_SRC_CMN = \
syspath \
manager \
- resolver \
-
+ resolver
VFS_SRC = \
path \
@@ -89,7 +88,6 @@ VFS_OBJ = \
VFS_LIB = \
-lkns \
- -lkurl \
-lkns \
-lkrypto \
-lkfg \
@@ -98,3 +96,28 @@ VFS_LIB = \
$(ILIBDIR)/libvfs.$(LIBX): $(VFS_OBJ)
$(LD) --slib -o $@ $^ $(VFS_LIB)
+
+
+
+#-------------------------------------------------------------------------------
+# white-box test
+#
+
+TEST_SRC = \
+ path-test
+
+TEST_OBJ = \
+ $(addsuffix .$(OBJX),$(TEST_SRC)) \
+ $(addsuffix .$(LOBX),$(VFS_SRC_CMN))
+
+TEST_LIB = \
+ -skapp \
+ -skns \
+ -skrypto \
+ -skfg \
+ -skfs \
+ -skproc \
+ -sklib
+
+$(TEST_BINDIR)/path-test: $(TEST_OBJ)
+ $(LD) --exe -o $@ $^ $(TEST_LIB)
diff --git a/libs/vfs/keyring.h b/libs/vfs/keyring.h
index fa9ca01..b1140ee 100644
--- a/libs/vfs/keyring.h
+++ b/libs/vfs/keyring.h
@@ -50,9 +50,10 @@ typedef struct KKeyRing KKeyRing;
/* Make
* Open an IPC connection to a keyring server. Will start the server if none is running.
* KKeyRingMakeRead will reject Add/Delete operations
+ * dataDir [ IN, NULL OK ] = path to the directory with keyring database. NULL - use default location (~/.ncbi)
*/
-VFS_EXTERN rc_t CC KKeyRingMakeRead( const KKeyRing** self );
-VFS_EXTERN rc_t CC KKeyRingMakeUpdate( KKeyRing** self );
+VFS_EXTERN rc_t CC KKeyRingMakeRead( const KKeyRing** self, const char* dataDir );
+VFS_EXTERN rc_t CC KKeyRingMakeUpdate( KKeyRing** self, const char* dataDir );
/* AddRef
* Release
@@ -91,9 +92,9 @@ VFS_EXTERN rc_t CC KKeyRingDeleteObject(KKeyRing* self,
VFS_EXTERN rc_t CC KKeyRingReencrypt(KKeyRing** self, const char* new_passwd);
/* IsServerRunning
- *
+ * dataDir [ IN, NULL OK ] = path to the directory with keyring database. NULL - use default location (~/.ncbi)
*/
-VFS_EXTERN bool CC KKeyRingIsServerRunning();
+VFS_EXTERN bool CC KKeyRingIsServerRunning(const char* dataDir);
/*
* private API for libkrypto
diff --git a/libs/vfs/manager.c b/libs/vfs/manager.c
index 227bcab..a622a50 100644
--- a/libs/vfs/manager.c
+++ b/libs/vfs/manager.c
@@ -26,12 +26,15 @@
#include <vfs/extern.h>
+#include "path-priv.h"
+
+#include <sra/srapath.h>
+
#include <vfs/manager.h>
+#include <vfs/manager-priv.h> /* VFSManagerMakeFromKfg */
#include <vfs/path.h>
#include <vfs/path-priv.h>
-#include <vfs/manager-priv.h> /* VFSManagerMakeFromKfg */
-
-#include "path-priv.h"
+#include <vfs/resolver.h>
#include <krypto/key.h>
#include <krypto/encfile.h>
@@ -44,9 +47,6 @@
#include <kfg/keystore-priv.h>
#include <kfg/kfg-priv.h>
-#include <vfs/resolver.h>
-#include <sra/srapath.h>
-
#include <kfs/directory.h>
#include <kfs/file.h>
#include <kfs/sra.h>
@@ -59,12 +59,15 @@
#include <kfs/cacheteefile.h>
#include <kfs/lockfile.h>
-#include <kns/curl-file.h>
+#include <kns/manager.h>
+#include <kns/http.h>
#include <kxml/xml.h>
-#include <klib/refcount.h>
+
+#include <klib/debug.h> /* DBGMSG */
#include <klib/log.h>
-#include <klib/rc.h>
#include <klib/printf.h>
+#include <klib/rc.h>
+#include <klib/refcount.h>
#include <strtol.h>
@@ -95,8 +98,6 @@
* be fully fleshed out here */
struct VFSManager
{
- KRefcount refcount;
-
/* the current directory in the eyes of the O/S when created */
KDirectory * cwd;
@@ -109,11 +110,16 @@ struct VFSManager
/* SRAPath will be replaced with a VResolver */
struct VResolver * resolver;
+ /* network manager */
+ KNSManager * kns;
+
/* path to a global password file */
char *pw_env;
/* encryption key storage */
struct KKeyStore* keystore;
+
+ KRefcount refcount;
};
static const char kfsmanager_classname [] = "VFSManager";
@@ -129,24 +135,19 @@ static rc_t VFSManagerDestroy ( VFSManager *self )
{
if ( self == NULL )
return RC ( rcVFS, rcFile, rcDestroying, rcSelf, rcNull );
-
- KRefcountWhack (&self->refcount, kfsmanager_classname);
-
- KDirectoryRelease (self->cwd);
-
- KConfigRelease (self->cfg);
-
- KCipherManagerRelease (self->cipher);
-
- VResolverRelease ( self->resolver );
-
- free ( self -> pw_env );
- KKeyStoreRelease( self->keystore );
+ KKeyStoreRelease( self -> keystore );
+ free ( self -> pw_env );
+ VResolverRelease ( self -> resolver );
+ KNSManagerRelease ( self -> kns );
+ KCipherManagerRelease ( self -> cipher );
+ KConfigRelease ( self -> cfg );
+ KDirectoryRelease ( self -> cwd );
+ KRefcountWhack (&self->refcount, kfsmanager_classname);
free (self);
-
singleton = NULL;
+
return 0;
}
@@ -205,13 +206,13 @@ LIB_EXPORT rc_t CC VFSManagerRelease ( const VFSManager *self )
/*--------------------------------------------------------------------------
- * VFSManagerMakeCurlFile
+ * VFSManagerMakeHTTPFile
*/
static
-rc_t VFSManagerMakeCurlFile( const VFSManager * self, const KFile **cfp,
+rc_t VFSManagerMakeHTTPFile( const VFSManager * self, const KFile **cfp,
const char * url, const char * cache_location )
{
- rc_t rc = KCurlFileMake ( cfp, url, false );
+ rc_t rc = KNSManagerMakeHttpFile ( self -> kns, cfp, NULL, 0x01010000, url );
if ( rc == 0 )
{
const KFile *temp_file;
@@ -500,7 +501,7 @@ static rc_t VFSManagerResolvePathResolver (const VFSManager * self,
if (not_done && ((flags & vfsmgr_rflag_no_acc_remote) == 0))
{
rc = VResolverRemote (self->resolver, eProtocolHttp,
- in_path, (const VPath **)out_path, NULL);
+ in_path, (const VPath **)out_path);
}
}
return rc;
@@ -921,7 +922,7 @@ rc_t VFSManagerOpenFileReadRegularFile (char * pbuff, size_t z,
static
rc_t VFSManagerOpenFileReadSpecial (char * pbuff, size_t z, KFile const ** file)
{
- rc_t rc;
+ rc_t rc = 0;
static const char dev [] = "/dev/";
static const char dev_stdin [] = "/dev/stdin";
static const char dev_null [] = "/dev/null";
@@ -1094,13 +1095,13 @@ static rc_t VFSManagerOpenCurlFile ( const VFSManager *self,
rc = VResolverCache ( self->resolver, path, &local_cache, 0 );
if ( rc == 0 )
/* we did find a place for local cache --> use it! */
- rc = VFSManagerMakeCurlFile( self, f, uri->addr, local_cache->path.addr );
+ rc = VFSManagerMakeHTTPFile( self, f, uri->addr, local_cache->path.addr );
else
/* we did NOT find a place for local cache --> we are not caching! */
- rc = VFSManagerMakeCurlFile( self, f, uri->addr, NULL );
+ rc = VFSManagerMakeHTTPFile( self, f, uri->addr, NULL );
}
else
- rc = VFSManagerMakeCurlFile( self, f, uri->addr, NULL );
+ rc = VFSManagerMakeHTTPFile( self, f, uri->addr, NULL );
free( ( void * )uri );
}
return rc;
@@ -1384,7 +1385,7 @@ rc_t VFSManagerOpenDirectoryReadHttp (const VFSManager *self,
rc = VFSManagerOpenCurlFile ( self, &file, path );
if ( rc != 0 )
{
- PLOGERR ( klogErr, ( klogErr, rc, "error with curl open '$(U)'",
+ PLOGERR ( klogErr, ( klogErr, rc, "error with http open '$(U)'",
"U=%S:%S", & path -> scheme, & path -> path ) );
}
else
@@ -1397,7 +1398,7 @@ rc_t VFSManagerOpenDirectoryReadHttp (const VFSManager *self,
path->path.addr, path->path.size);
if (rc)
{
- PLOGERR (klogErr, (klogErr, rc, "error creating mount "
+ PLOGERR (klogInt, (klogErr, rc, "error creating mount "
"'$(M)' for '$(F)", "M=%s,F=%S",
mountpointpath, &path->path));
}
@@ -1646,11 +1647,13 @@ rc_t VFSManagerOpenDirectoryReadDirectoryRelativeInt (const VFSManager *self,
break;
}
+#if 0
if ((force_decrypt != false) && (force_decrypt != true))
{
rc = RC (rcVFS, rcDirectory, rcOpening, rcParam, rcInvalid);
break;
}
+#endif
rc = VPathAddRef (path_);
if ( rc )
@@ -2097,7 +2100,8 @@ LIB_EXPORT rc_t CC VFSManagerRemove ( const VFSManager *self, bool force,
/* Make
*/
-LIB_EXPORT rc_t CC VFSManagerMake ( VFSManager ** pmanager ) {
+LIB_EXPORT rc_t CC VFSManagerMake ( VFSManager ** pmanager )
+{
return VFSManagerMakeFromKfg(pmanager, NULL);
}
@@ -2112,7 +2116,7 @@ LIB_EXPORT rc_t CC VFSManagerMakeFromKfg ( struct VFSManager ** pmanager,
return RC (rcVFS, rcMgr, rcConstructing, rcParam, rcNull);
*pmanager = singleton;
- if (singleton != NULL)
+ if ( singleton != NULL )
{
rc = VFSManagerAddRef ( singleton );
if ( rc != 0 )
@@ -2127,45 +2131,51 @@ LIB_EXPORT rc_t CC VFSManagerMakeFromKfg ( struct VFSManager ** pmanager,
rc = RC (rcVFS, rcMgr, rcConstructing, rcMemory, rcExhausted);
else
{
- KRefcountInit (&obj->refcount, 1, kfsmanager_classname, "init",
- kfsmanager_classname);
+ KRefcountInit (& obj -> refcount, 1,
+ kfsmanager_classname, "init", "singleton" );
- rc = KDirectoryNativeDir (&obj->cwd);
- if (rc == 0)
+ rc = KDirectoryNativeDir ( & obj -> cwd );
+ if ( rc == 0 )
{
+ if (cfg == NULL)
+ rc = KConfigMake ( & obj -> cfg, NULL );
+ else
{
- if (cfg == NULL) {
- rc = KConfigMake (&obj->cfg, NULL);
- }
- else {
- rc = KConfigAddRef(cfg);
- if (rc == 0) {
- obj->cfg = cfg;
- }
- }
+ rc = KConfigAddRef ( cfg );
+ if (rc == 0)
+ obj -> cfg = cfg;
+ }
+ if ( rc == 0 )
+ {
+ rc = KCipherManagerMake ( & obj -> cipher );
if ( rc == 0 )
{
- rc = KCipherManagerMake (&obj->cipher);
+ rc = KKeyStoreMake ( & obj -> keystore, obj -> cfg );
if ( rc == 0 )
{
- rc = KKeyStoreMake ( &obj->keystore, obj->cfg );
- if ( rc == 0 )
+ rc = VFSManagerMakeResolver ( obj, & obj -> resolver, obj -> cfg );
+ if ( rc != 0 )
{
- rc = VFSManagerMakeResolver ( obj, &obj->resolver, obj->cfg );
- if ( rc != 0 )
- {
- LOGERR ( klogWarn, rc, "could not build vfs-resolver" );
- rc = 0;
- }
+ LOGERR ( klogWarn, rc, "could not build vfs-resolver" );
+ rc = 0;
+ }
- *pmanager = singleton = obj;
- return rc;
+ rc = KNSManagerMake ( & obj -> kns );
+ if ( rc != 0 )
+ {
+ LOGERR ( klogWarn, rc, "could not build network manager" );
+ rc = 0;
}
+
+ *pmanager = singleton = obj;
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_MGR), ("%s(%p)\n", __FUNCTION__, cfg));
+ return 0;
}
}
}
}
}
+
VFSManagerDestroy (obj);
}
return rc;
@@ -2176,42 +2186,80 @@ LIB_EXPORT rc_t CC VFSManagerGetCWD (const VFSManager * self, KDirectory ** cwd)
{
rc_t rc;
- if (cwd == NULL)
- return RC (rcVFS, rcMgr, rcAccessing, rcParam, rcNull);
-
- *cwd = NULL;
-
- if (self == NULL)
- return RC (rcVFS, rcMgr, rcAccessing, rcSelf, rcNull);
-
- rc = KDirectoryAddRef ( self->cwd );
- if (rc)
- return rc;
+ if ( cwd == NULL )
+ rc = RC (rcVFS, rcMgr, rcAccessing, rcParam, rcNull);
+ else
+ {
+ if ( self == NULL )
+ rc = RC (rcVFS, rcMgr, rcAccessing, rcSelf, rcNull);
+ else
+ {
+ rc = KDirectoryAddRef ( self -> cwd );
+ if ( rc == 0 )
+ {
+ * cwd = self -> cwd;
+ return 0;
+ }
+ }
- *cwd = self->cwd;
+ * cwd = NULL;
+ }
- return 0;
+ return rc;
}
LIB_EXPORT rc_t CC VFSManagerGetResolver ( const VFSManager * self, struct VResolver ** resolver )
{
+ rc_t rc;
+
if ( resolver == NULL )
- return RC ( rcVFS, rcMgr, rcAccessing, rcParam, rcNull );
+ rc = RC (rcVFS, rcMgr, rcAccessing, rcParam, rcNull);
+ else
+ {
+ if ( self == NULL )
+ rc = RC (rcVFS, rcMgr, rcAccessing, rcSelf, rcNull);
+ else
+ {
+ rc = VResolverAddRef ( self -> resolver );
+ if ( rc == 0 )
+ {
+ * resolver = self -> resolver;
+ return 0;
+ }
+ }
- *resolver = NULL;
+ * resolver = NULL;
+ }
- if ( self == NULL )
- return RC ( rcVFS, rcMgr, rcAccessing, rcSelf, rcNull );
+ return rc;
+}
+
+
+LIB_EXPORT rc_t CC VFSManagerGetKNSMgr ( const VFSManager * self, struct KNSManager ** kns )
+{
+ rc_t rc;
- if ( self->resolver )
+ if ( kns == NULL )
+ rc = RC (rcVFS, rcMgr, rcAccessing, rcParam, rcNull);
+ else
{
- rc_t rc = VResolverAddRef ( self->resolver );
- if ( rc != 0 )
- return rc;
+ if ( self == NULL )
+ rc = RC (rcVFS, rcMgr, rcAccessing, rcSelf, rcNull);
+ else
+ {
+ rc = KNSManagerAddRef ( self -> kns );
+ if ( rc == 0 )
+ {
+ * kns = self -> kns;
+ return 0;
+ }
+ }
+
+ * kns = NULL;
}
- *resolver = self->resolver;
- return 0;
+
+ return rc;
}
@@ -2810,7 +2858,7 @@ static rc_t VFSManagerResolveRemote( const VFSManager * self,
rc = VPathReadPath ( *source, full_url, sizeof full_url, &num_read );
if ( rc == 0 && num_read > 0 )
{
- rc = KCurlFileMake ( remote_file, full_url, false );
+ rc = KNSManagerMakeHttpFile ( self -> kns, remote_file, NULL, 0x01010000, full_url );
if ( rc == 0 )
{
uint64_t size_of_remote_file = 0;
diff --git a/libs/vfs/path.c b/libs/vfs/path.c
index 35bffcd..317af37 100644
--- a/libs/vfs/path.c
+++ b/libs/vfs/path.c
@@ -41,6 +41,7 @@
#include <sysalloc.h>
#define MAX_ACCESSION_LEN 20
+#define TREAT_URI_RESERVED_AS_FILENAME 0
/*--------------------------------------------------------------------------
@@ -579,13 +580,15 @@ rc_t VPathParse ( VPath * self, const char * uri, size_t uri_size )
state = vppFullOrUNCPath;
break;
+#if ! TREAT_URI_RESERVED_AS_FILENAME
case ':':
case '?':
case '#':
return RC ( rcVFS, rcPath, rcParsing, rcChar, rcUnexpected );
+#endif
default:
- state =vppNamePath;
+ state = vppNamePath;
}
break;
@@ -629,9 +632,11 @@ rc_t VPathParse ( VPath * self, const char * uri, size_t uri_size )
state = vppAccOidRelOrSlash;
break;
+#if ! TREAT_URI_RESERVED_AS_FILENAME
case '?':
case '#':
return RC ( rcVFS, rcPath, rcParsing, rcChar, rcUnexpected );
+#endif
default:
acc_alpha = 0;
@@ -660,10 +665,12 @@ rc_t VPathParse ( VPath * self, const char * uri, size_t uri_size )
state = vppRelPath;
break;
+#if ! TREAT_URI_RESERVED_AS_FILENAME
case ':':
case '?':
case '#':
return RC ( rcVFS, rcPath, rcParsing, rcChar, rcUnexpected );
+#endif
default:
acc_prefix = acc_alpha = 0;
@@ -708,9 +715,11 @@ rc_t VPathParse ( VPath * self, const char * uri, size_t uri_size )
state = vppAccOidRelOrSlash;
break;
+#if ! TREAT_URI_RESERVED_AS_FILENAME
case '?':
case '#':
return RC ( rcVFS, rcPath, rcParsing, rcChar, rcUnexpected );
+#endif
default:
acc_prefix = acc_alpha = acc_digit = 0;
@@ -738,10 +747,12 @@ rc_t VPathParse ( VPath * self, const char * uri, size_t uri_size )
state = vppAccDotNamePath;
break;
+#if ! TREAT_URI_RESERVED_AS_FILENAME
case ':':
case '?':
case '#':
return RC ( rcVFS, rcPath, rcParsing, rcChar, rcUnexpected );
+#endif
default:
acc_prefix = acc_alpha = acc_digit = 0;
@@ -786,9 +797,11 @@ rc_t VPathParse ( VPath * self, const char * uri, size_t uri_size )
state = vppAccOidRelOrSlash;
break;
+#if ! TREAT_URI_RESERVED_AS_FILENAME
case '?':
case '#':
return RC ( rcVFS, rcPath, rcParsing, rcChar, rcUnexpected );
+#endif
case '_':
if ( acc_prefix != 0 && acc_alpha == 0 && acc_digit == 9 )
@@ -825,10 +838,12 @@ rc_t VPathParse ( VPath * self, const char * uri, size_t uri_size )
state = vppAccDotNamePath;
break;
+#if ! TREAT_URI_RESERVED_AS_FILENAME
case ':':
case '?':
case '#':
return RC ( rcVFS, rcPath, rcParsing, rcChar, rcUnexpected );
+#endif
case '_':
if ( acc_prefix != 0 && acc_alpha == 0 && acc_digit == 9 && acc_ext == 1 )
@@ -861,10 +876,12 @@ rc_t VPathParse ( VPath * self, const char * uri, size_t uri_size )
state = vppRelPath;
break;
+#if ! TREAT_URI_RESERVED_AS_FILENAME
case ':':
case '?':
case '#':
return RC ( rcVFS, rcPath, rcParsing, rcChar, rcUnexpected );
+#endif
default:
acc_prefix = acc_alpha = acc_digit = acc_ext = acc_suffix = 0;
@@ -909,9 +926,11 @@ rc_t VPathParse ( VPath * self, const char * uri, size_t uri_size )
state = vppAccOidRelOrSlash;
break;
+#if ! TREAT_URI_RESERVED_AS_FILENAME
case '?':
case '#':
return RC ( rcVFS, rcPath, rcParsing, rcChar, rcUnexpected );
+#endif
default:
acc_prefix = acc_alpha = acc_digit = acc_ext = 0;
@@ -938,10 +957,12 @@ rc_t VPathParse ( VPath * self, const char * uri, size_t uri_size )
state = vppRelPath;
break;
+#if ! TREAT_URI_RESERVED_AS_FILENAME
case ':':
case '?':
case '#':
return RC ( rcVFS, rcPath, rcParsing, rcChar, rcUnexpected );
+#endif
default:
acc_prefix = acc_alpha = acc_digit = acc_ext = 0;
@@ -968,10 +989,12 @@ rc_t VPathParse ( VPath * self, const char * uri, size_t uri_size )
state = vppRelPath;
break;
+#if ! TREAT_URI_RESERVED_AS_FILENAME
case ':':
case '?':
case '#':
return RC ( rcVFS, rcPath, rcParsing, rcChar, rcUnexpected );
+#endif
default:
acc_prefix = acc_alpha = acc_digit = acc_ext = 0;
@@ -1001,9 +1024,11 @@ rc_t VPathParse ( VPath * self, const char * uri, size_t uri_size )
state = vppAccOidRelOrSlash;
break;
+#if ! TREAT_URI_RESERVED_AS_FILENAME
case '?':
case '#':
return RC ( rcVFS, rcPath, rcParsing, rcChar, rcUnexpected );
+#endif
default:
state = vppNamePath;
@@ -3068,7 +3093,7 @@ rc_t LegacyVPathResolveAccession ( VPath ** new_path, const VPath * path )
{
rc = VResolverLocal ( resolver, path, ( const VPath** ) new_path );
if ( GetRCState ( rc ) == rcNotFound )
- rc = VResolverRemote ( resolver, eProtocolHttp, path, ( const VPath** ) new_path, NULL );
+ rc = VResolverRemote ( resolver, eProtocolHttp, path, ( const VPath** ) new_path );
VResolverRelease ( resolver );
}
@@ -3314,7 +3339,7 @@ rc_t LegacyVPathMakeVFmt ( VPath ** new_path, const char * fmt, va_list args )
LIB_EXPORT rc_t CC LegacyVPathGetScheme_t ( const VPath * self, VPUri_t * uri_type )
{
- rc_t rc;
+ rc_t rc = 0;
if ( uri_type == NULL )
rc = RC ( rcVFS, rcPath, rcAccessing, rcParam, rcNull );
diff --git a/libs/vfs/resolver.c b/libs/vfs/resolver.c
index 9f5fb3a..c023670 100644
--- a/libs/vfs/resolver.c
+++ b/libs/vfs/resolver.c
@@ -20,7 +20,7 @@
*
* Please cite the author in any work or product based on this material.
*
- * ===========================================================================
+ * =============================================================================
*
*/
@@ -33,8 +33,6 @@
#include <kns/manager.h>
#include <kns/http.h>
#include <kns/stream.h>
-#include <kns/curl-file.h>
-#include <kns/KCurlRequest.h>
#include <kfs/file.h>
#include <kfs/directory.h>
#include <kfg/repository.h>
@@ -72,7 +70,7 @@
unless we are expecting them for refseq */
#define DISALLOW_FRAGMENT NO_LEGACY_WGS_REFSEQ_CGI
-#define USE_CURL 1
+#define USE_CURL 0
#define NAME_SERVICE_MAJ_VERS 1
#define NAME_SERVICE_MIN_VERS 1
@@ -930,9 +928,11 @@ rc_t VResolverAlgParseResolverCGIResponse_1_0 ( const char *start, size_t size,
* <accession>|obj-id|name|size|mod-date|md5|<download-ticket>|<url>|<result-code>|<message>
*/
static
-rc_t VResolverAlgParseResolverCGIResponse_1_1 ( const char *start, size_t size,
- const VPath ** path, const VPath ** mapping, const String *acc, const String *ticket )
+rc_t VResolverAlgParseResolverCGIResponse_1_1 ( const char *astart, size_t size,
+ const VPath ** path, const VPath ** mapping, const String *acc,
+ const String *ticket, bool *canRetry )
{
+ const char *start = astart;
rc_t rc;
KLogLevel lvl;
char *rslt_end;
@@ -1021,8 +1021,12 @@ rc_t VResolverAlgParseResolverCGIResponse_1_1 ( const char *start, size_t size,
StringInit ( & msg, start, sep - start, ( uint32_t ) ( sep - start ) );
/* compare acc to accession or obj_id */
- if ( ! StringEqual ( & accession, acc ) && ! StringEqual ( & obj_id, acc ) )
+ if ( ! StringEqual ( & accession, acc ) && ! StringEqual ( & obj_id, acc ) ) {
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+ "@@@@@@@@2 %%s:%s:%d: %s"
+ "\n", __FILE__, __FUNCTION__, __LINE__, astart));
return RC ( rcVFS, rcResolver, rcResolving, rcMessage, rcCorrupt );
+ }
/* compare ticket
currently this makes sense with 1 request from a known workspace */
@@ -1129,6 +1133,8 @@ rc_t VResolverAlgParseResolverCGIResponse_1_1 ( const char *start, size_t size,
rc = RC ( rcVFS, rcResolver, rcResolving, rcQuery, rcUnauthorized );
break;
case 404:
+ assert(canRetry);
+ *canRetry = false;
return RC ( rcVFS, rcResolver, rcResolving, rcName, rcNotFound );
case 410:
rc = RC ( rcVFS, rcResolver, rcResolving, rcName, rcNotFound );
@@ -1172,7 +1178,8 @@ rc_t VResolverAlgParseResolverCGIResponse_1_1 ( const char *start, size_t size,
*/
static
rc_t VResolverAlgParseResolverCGIResponse ( const KDataBuffer *result,
- const VPath ** path, const VPath ** mapping, const String *acc, const String *ticket )
+ const VPath ** path, const VPath ** mapping, const String *acc,
+ const String *ticket, bool * canRetry )
{
/* the textual response */
const char *start = ( const void* ) result -> base;
@@ -1230,7 +1237,8 @@ rc_t VResolverAlgParseResolverCGIResponse ( const KDataBuffer *result,
break;
/* parse 1.0 response table */
- return VResolverAlgParseResolverCGIResponse_1_1 ( & start [ i ], size - i, path, mapping, acc, ticket );
+ return VResolverAlgParseResolverCGIResponse_1_1 ( & start [ i ],
+ size - i, path, mapping, acc, ticket, canRetry );
}
while ( false );
}
@@ -1242,110 +1250,44 @@ rc_t VResolverAlgParseResolverCGIResponse ( const KDataBuffer *result,
* use NCBI CGI to resolve accession into URL
*/
static
-rc_t VResolverAlgRemoteProtectedResolve ( const VResolverAlg *self,
+rc_t VResolverAlgRemoteProtectedResolveImpl ( const VResolverAlg *self,
const KNSManager *kns, VRemoteProtocols protocols, const String *acc,
- const VPath ** path, const VPath ** mapping, bool legacy_wgs_refseq )
+ const VPath ** path, const VPath ** mapping, bool legacy_wgs_refseq,
+ bool *canRetry )
{
-#if USE_CURL
- struct KCurlRequest *req;
- rc_t rc = 0;
+ rc_t rc;
+ KHttpRequest *req;
+
+ assert(path && canRetry);
+ *canRetry = true;
+
DBGMSG(DBG_VFS, DBG_FLAG(DBG_VFS), ("names.cgi = %S\n", self -> root));
- rc = KNSManagerMakeCurlRequest ( kns, & req, self -> root -> addr, false );
+ rc = KNSManagerMakeRequest ( kns, & req, 0x01000000, NULL, self -> root -> addr );
if ( rc == 0 )
{
- String name, val;
-
/* build up POST information: */
- CONST_STRING ( & name, "version" );
-#if NAME_SERVICE_VERS == ONE_DOT_ONE
- CONST_STRING (& val, "1.1" );
-#else
- CONST_STRING (& val, "1.0" );
-#endif
- DBGMSG(DBG_VFS, DBG_FLAG(DBG_VFS), (" %S = %S\n", &name, &val));
- rc = KCurlRequestAddSField ( req, & name, & val );
+ DBGMSG(DBG_VFS, DBG_FLAG(DBG_VFS), (" version = %u.%u\n",
+ NAME_SERVICE_MAJ_VERS, NAME_SERVICE_MIN_VERS));
+ rc = KHttpRequestAddPostParam ( req, "version=%u.%u",
+ NAME_SERVICE_MAJ_VERS, NAME_SERVICE_MIN_VERS );
if ( rc == 0 )
{
- CONST_STRING ( & name, "acc" );
- DBGMSG(DBG_VFS, DBG_FLAG(DBG_VFS), (" %S = %S\n", &name, acc));
- rc = KCurlRequestAddSField ( req, & name, acc );
+ DBGMSG(DBG_VFS, DBG_FLAG(DBG_VFS), (" acc = %S\n", acc));
+ rc = KHttpRequestAddPostParam ( req, "acc=%S", acc );
}
if ( rc == 0 && legacy_wgs_refseq )
{
- CONST_STRING ( & name, "ctx" );
- CONST_STRING (& val, "refseq" );
- DBGMSG(DBG_VFS, DBG_FLAG(DBG_VFS), (" %S = %S\n", &name, &val));
- rc = KCurlRequestAddSField ( req, & name, & val );
+ DBGMSG(DBG_VFS, DBG_FLAG(DBG_VFS), (" ctx = refseq\n"));
+ rc = KHttpRequestAddPostParam ( req, "ctx=refseq" );
}
if ( rc == 0 && self -> ticket != NULL )
{
- CONST_STRING ( & name, "tic" );
- DBGMSG(DBG_VFS, DBG_FLAG(DBG_VFS),
- (" %S = %S\n", &name, self->ticket));
- rc = KCurlRequestAddSField ( req, & name, self -> ticket );
+ DBGMSG(DBG_VFS, DBG_FLAG(DBG_VFS), (" tic = %S\n", self -> ticket));
+ rc = KHttpRequestAddPostParam ( req, "tic=%S", self -> ticket );
}
#if NAME_SERVICE_VERS >= ONE_DOT_ONE /* SRA-1690 */
if ( rc == 0 )
{
- CONST_STRING ( & name, "accept-proto" );
- switch ( protocols )
- {
- case eProtocolHttp:
- CONST_STRING ( & val, "http" );
- break;
- case eProtocolFasp:
- CONST_STRING ( & val, "fasp" );
- break;
- case eProtocolFaspHttp:
- CONST_STRING ( & val, "fasp,http" );
- break;
- case eProtocolHttpFasp:
- CONST_STRING ( & val, "http,fasp" );
- break;
- default:
- rc = RC ( rcVFS, rcResolver, rcResolving, rcParam, rcInvalid );
- }
- if ( rc == 0 )
- {
- DBGMSG(DBG_VFS, DBG_FLAG ( DBG_VFS ), (" %S = %S\n", & name, & val ) );
- rc = KCurlRequestAddSField ( req, & name, & val );
- }
- }
-#endif
-
- /* execute post */
- if ( rc == 0 )
- {
- KDataBuffer result;
- memset ( & result, 0, sizeof result );
- rc = KCurlRequestPerform ( req, & result );
- if ( rc == 0 )
- {
- /* expect a table as a NUL-terminated string, but
- having close to the number of bytes in results */
- rc = VResolverAlgParseResolverCGIResponse ( & result, path, mapping, acc, self -> ticket );
- KDataBufferWhack ( & result );
- }
- }
-
- KCurlRequestRelease ( req );
- }
-#else
- KHttpRequest *req;
- rc_t rc = KNSManagerMakeRequest ( kns, &req, 0x01000000, NULL, self -> root -> addr );
- if ( rc == 0 )
- {
- /* build up POST information: */
- rc = KHttpRequestAddPostParam ( req, "version=%u.%u",
- NAME_SERVICE_MAJ_VERS, NAME_SERVICE_MIN_VERS );
- if ( rc == 0 )
- rc = KHttpRequestAddPostParam ( req, "acc=%S", acc );
- if ( rc == 0 && legacy_wgs_refseq )
- rc = KHttpRequestAddPostParam ( req, "ctx=refseq" );
- if ( rc == 0 && self -> ticket != NULL )
- rc = KHttpRequestAddPostParam ( req, "tic=%S", self -> ticket );
- if ( NAME_SERVICE_VERS >= ONE_DOT_ONE )
- {
const char *val;
switch ( protocols )
{
@@ -1367,8 +1309,12 @@ rc_t VResolverAlgRemoteProtectedResolve ( const VResolverAlg *self,
}
if ( rc == 0 )
+ {
+ DBGMSG(DBG_VFS, DBG_FLAG ( DBG_VFS ), (" accept-proto = %s\n", val ) );
rc = KHttpRequestAddPostParam ( req, "accept-proto=%s", val );
+ }
}
+#endif
if ( rc == 0 )
{
@@ -1379,6 +1325,8 @@ rc_t VResolverAlgRemoteProtectedResolve ( const VResolverAlg *self,
{
uint32_t code;
+ *canRetry = false;
+
rc = KHttpResultStatus ( rslt, &code, NULL, 0, NULL );
if ( code == 200 )
{
@@ -1387,11 +1335,11 @@ rc_t VResolverAlgRemoteProtectedResolve ( const VResolverAlg *self,
rc = KHttpResultGetInputStream ( rslt, &response );
if ( rc == 0 )
{
- KDataBuffer result;
size_t num_read;
size_t total = 0;
- memset ( &result, 0, sizeof result );
+ KDataBuffer result;
+ memset ( & result, 0, sizeof result );
KDataBufferMakeBytes ( & result, 4096 );
while ( 1 )
@@ -1406,7 +1354,7 @@ rc_t VResolverAlgRemoteProtectedResolve ( const VResolverAlg *self,
}
base = result . base;
- rc = KStreamRead ( response, & base [ total ], result . elem_count - total, &num_read );
+ rc = KStreamRead ( response, & base [ total ], result . elem_count - total, & num_read );
if ( rc != 0 )
{
/* TBD - look more closely at rc */
@@ -1415,8 +1363,10 @@ rc_t VResolverAlgRemoteProtectedResolve ( const VResolverAlg *self,
else
break;
}
+
if ( num_read == 0 )
break;
+
total += num_read;
}
@@ -1424,7 +1374,8 @@ rc_t VResolverAlgRemoteProtectedResolve ( const VResolverAlg *self,
{
result.elem_count = total;
- rc = VResolverAlgParseResolverCGIResponse ( & result, path, mapping, acc, self -> ticket );
+ rc = VResolverAlgParseResolverCGIResponse(&result,
+ path, mapping, acc, self->ticket, canRetry);
KDataBufferWhack ( &result );
}
@@ -1436,10 +1387,49 @@ rc_t VResolverAlgRemoteProtectedResolve ( const VResolverAlg *self,
}
KHttpRequestRelease ( req );
}
-#endif
- return rc == 0 ? 0 : RC ( rcVFS, rcResolver, rcResolving, rcName, rcNotFound );
+
+ assert(*path != NULL || rc != 0);
+
+ if (rc == 0 && *path == NULL) {
+ *canRetry = true;
+ rc = RC(rcVFS, rcResolver, rcResolving, rcName, rcNull);
+ }
+
+ return rc;
}
+static rc_t VResolverAlgRemoteProtectedResolve ( const VResolverAlg *self,
+ const KNSManager *kns, VRemoteProtocols protocols, const String *acc,
+ const VPath ** path, const VPath ** mapping, bool legacy_wgs_refseq )
+{
+ rc_t rc = 0;
+ int i = 0, retryOnFailure = 3;
+ for (i = 0; i < retryOnFailure; ++i) {
+ bool canRetry = false;
+ rc = VResolverAlgRemoteProtectedResolveImpl(self, kns, protocols,
+ acc, path, mapping, legacy_wgs_refseq, &canRetry);
+ if (rc == 0) {
+ break;
+ }
+ if (!canRetry) {
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+"@@@@@@@@2 %s: VResolverAlgRemoteProtectedResolveImpl %d/%d = cannot retry = %R"
+ "\n", __FUNCTION__, i + 1, retryOnFailure, rc));
+ break;
+ }
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+"@@@@@@@@2 %s: VResolverAlgRemoteProtectedResolveImpl %d/%d = can retry = %R"
+ "\n", __FUNCTION__, i + 1, retryOnFailure, rc));
+ }
+
+ if (rc != 0) {
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+ "@@@@@@@@2 %s: returning %R\n", __FUNCTION__, rc));
+ }
+
+ return rc == 0 ? 0 : RC(rcVFS, rcResolver, rcResolving, rcName, rcNotFound);
+}
+
/* RemoteResolve
* resolve an accession into a VPath or not found
*
@@ -1471,27 +1461,27 @@ rc_t VResolverAlgRemoteResolve ( const VResolverAlg *self,
{
rc = VResolverAlgRemoteProtectedResolve ( self,
kns, protocols, & tok -> acc, path, mapping, legacy_wgs_refseq );
+
if (rc == 0 && path != NULL && *path != NULL &&
opt_file_rtn != NULL && *opt_file_rtn == NULL &&
VPathGetUri_t ( * path ) != vpuri_fasp )
{
const String *s = NULL;
rc_t rc = VPathMakeString(*path, &s);
- if (rc != 0) {
+ if (rc != 0)
+ {
LOGERR(klogInt, rc,
"failed to make string from remote protected path");
}
- else {
-#if USE_CURL
- rc = KCurlFileMake(opt_file_rtn, s->addr, false);
-#else
+ else
+ {
rc = KNSManagerMakeHttpFile ( kns, opt_file_rtn, NULL, 0x01010000, "%S", s );
-#endif
- if (rc != 0) {
+ if (rc != 0)
+ {
PLOGERR(klogInt, (klogInt, rc,
"failed to open file for $(path)", "path=%s", s->addr));
}
- free((void*)s);
+ StringWhack ( s );
}
}
return rc;
@@ -2388,6 +2378,7 @@ rc_t VResolverRemoteResolve ( const VResolver *self,
* Accession must be an ncbi-acc scheme or a simple name with no
* directory paths.
*
+ * REMOVED 12/23/13
* "opt_file_rtn" [ OUT, NULL OKAY ] - optional return parameter for
* any KFile that may be opened as a result of resolution. This can
* happen if resolving an accession involves opening a URL to a
@@ -2396,14 +2387,17 @@ rc_t VResolverRemoteResolve ( const VResolver *self,
LIB_EXPORT
rc_t CC VResolverRemote ( const VResolver * self,
VRemoteProtocols protocols, const VPath * accession,
- const VPath ** path, const KFile ** opt_file_rtn )
+ const VPath ** path /*, const KFile ** opt_file_rtn */ )
{
rc_t rc;
+#if 0
if ( opt_file_rtn != NULL )
* opt_file_rtn = NULL;
+#endif
rc = VResolverQuery ( self, protocols, accession, NULL, path, NULL );
+#if 0
if ( rc == 0 && opt_file_rtn != NULL &&
VPathGetUri_t ( * path ) != vpuri_fasp )
{
@@ -2419,11 +2413,11 @@ rc_t CC VResolverRemote ( const VResolver * self,
}
#endif
}
+#endif
return rc;
}
-
/* ExtractAccessionApp
* examine a path for accession portion,
* and try to recognize what app it belongs to
diff --git a/libs/vfs/unix/syskeyring.c b/libs/vfs/unix/syskeyring.c
index 81c13b5..74e940c 100644
--- a/libs/vfs/unix/syskeyring.c
+++ b/libs/vfs/unix/syskeyring.c
@@ -24,12 +24,14 @@
*
*/
-#include "keyring-priv.h"
+#include <vfs/keyring-priv.h>
#include <kfg/config.h>
#include <klib/text.h>
#include <klib/rc.h>
+#include <klib/log.h>
+#include <klib/printf.h>
#include <kfs/file.h>
#include <kfs/directory.h>
@@ -41,105 +43,90 @@
#include <stdlib.h>
#include <sys/wait.h>
-static const char LockFileName[] = "/home/boshkina/.ncbi/keyring_lock";
-static const char KeyRingServerExeName[] = "keyring-srv";
+#include <stdio.h>
-LIB_EXPORT bool CC KKeyRingIsServerRunning()
+#ifndef MAX_PATH
+#define MAX_PATH 4096
+#endif
+
+const char* KeyRingDefaultDataDir = "~/.ncbi";
+
+/*TODO: move to ../keyring.c */
+LIB_EXPORT bool CC KKeyRingIsServerRunning(const char* dataDir)
{
KDirectory* wd;
rc_t rc = KDirectoryNativeDir (&wd);
if (rc == 0)
{
- KFile* lockedFile;
- rc = KDirectoryCreateExclusiveAccessFile(wd, &lockedFile, true, 0600, kcmOpen, LockFileName);
+ char lockFileName[MAX_PATH];
+ if (dataDir == NULL)
+ dataDir = KeyRingDefaultDataDir;
+ rc = string_printf(lockFileName, sizeof(lockFileName)-1, NULL, "%s/keyring_lock", dataDir);
+
if (rc == 0)
- KFileRelease(lockedFile);
+ {
+ KFile* lockedFile;
+ rc = KDirectoryCreateExclusiveAccessFile(wd, &lockedFile, true, 0600, kcmOpen, lockFileName);
+ if (rc == 0)
+ KFileRelease(lockedFile);
+ }
KDirectoryRelease(wd);
}
- return rc == 0;
+ return rc != 0;
}
-static
-int StartServer()
-{ /* create a child process that will become the server */
- char* const argv[] = {(char*)KeyRingServerExeName, NULL};
+rc_t StartKeyRing(const char* dataDir)
+{
+ rc_t rc = 0;
+
pid_t child = fork();
switch (child)
{
- case 0: /* child */
- if (execvp(KeyRingServerExeName, argv) == -1)
- { /* look around:
- - same dir as the current executable (kfg/APPPATH)
- - current dir
- */
- return -1;
- }
- /* no return if successful */
- return -1;
- case -1:
- return -1;
- default: /* parent */
- return 0;
- }
-}
+ case 0: /* child */
+ { /* become the server */
+
+/*TODO: calculate based on $(APPPATH) in kfg */
+const char* KeyRingServerExeName = "/home/boshkina/internal/asm-trace/centos/gcc/stat/x86_64/dbg/bin/keyring-srv";
-rc_t StartKeyRing(struct KStream** ipc)
-{
-/*
- 1. Lock the lock file
- 2. If failed, create the ipc object, connect to the server and exit (success)
- 3. If succeeded, fork
- In the child:
- - execvp(kr-server) (if not in PATH, try locate and execv in fixed places (kfg:$APPPATH, ./)
- In the parent:
- - wait for the server connection to come up (= keyring server ready).
- - close the lock file (do not unlock)
- - connect to the server and exit (success)
-*/
- KDirectory* wd;
- rc_t rc = KDirectoryNativeDir (&wd);
- if (rc == 0)
- {
- KFile* lockedFile;
- rc = KDirectoryCreateExclusiveAccessFile(wd, &lockedFile, true, 0600, kcmOpen, LockFileName);
- if (rc == 0)
- { /* start the server */
- pid_t child = fork();
- switch (child)
+ if (dataDir == NULL)
+ dataDir = "~/.ncbi";
+ LogMsg(klogInfo, "Keyring: execl...");
+
+ if (execl(KeyRingServerExeName, KeyRingServerExeName, dataDir, NULL) == -1)
+ { /* TODO: look around:
+ - same dir as the current executable (kfg/APPPATH)
+ - current dir
+ - etc.
+ */
+ }
+ pLogMsg(klogErr,
+ "Keyring: execl($(exe)) failed ($(errno)=$(perrno))",
+ "exe=%s,errno=%d,perrno=%!",
+ KeyRingServerExeName, errno, errno);
+ exit(1);
+ break;
+ }
+ case -1: /* error */
+ {
+ switch (errno)
{
- case 0: /* child */
- { /* fork a grandchild that will become the server */
- exit(StartServer());
- break;
- }
- case -1: /* error */
- {
- rc_t rc;
- switch (errno)
- {
- case EAGAIN:
- case ENOMEM:
- rc = RC (rcVFS, rcProcess, rcProcess, rcMemory, rcInsufficient);
- break;
- case ENOSYS:
- rc = RC (rcVFS, rcProcess, rcProcess, rcInterface, rcUnsupported);
- break;
- default:
- rc = RC (rcVFS, rcProcess, rcProcess, rcError, rcUnknown);
- break;
- }
- break;
- }
- default: /* parent */
- {
- waitpid(child, 0, 0);
- break;
- }
+ case EAGAIN:
+ case ENOMEM:
+ rc = RC (rcVFS, rcProcess, rcProcess, rcMemory, rcInsufficient);
+ break;
+ case ENOSYS:
+ rc = RC (rcVFS, rcProcess, rcProcess, rcInterface, rcUnsupported);
+ break;
+ default:
+ rc = RC (rcVFS, rcProcess, rcProcess, rcError, rcUnknown);
+ break;
}
- KFileRelease(lockedFile); /* if successfully started, the grandchild will hold the lock until its exit */
+ break;
}
- KDirectoryRelease(wd);
+ default: /* parent */
+ break;
}
+
return rc;
}
diff --git a/libs/vfs/win/syskeyring.c b/libs/vfs/win/syskeyring.c
index f747513..54ee745 100644
--- a/libs/vfs/win/syskeyring.c
+++ b/libs/vfs/win/syskeyring.c
@@ -24,12 +24,14 @@
*
*/
-#include "keyring-priv.h"
+#include <vfs/keyring-priv.h>
#include <kfg/config.h>
#include <klib/text.h>
-rc_t StartKeyRing(struct KStream** ipc)
+const char* KeyRingDefaultDataDir = "%USERPROFILE%\\.ncbi";
+
+rc_t StartKeyRing(const char* dataDir)
{
KConfig* kfg;
rc_t rc = KConfigMake(&kfg, NULL);
@@ -46,7 +48,7 @@ rc_t StartKeyRing(struct KStream** ipc)
rc = KConfigNodeRead(node, 0, buf, sizeof(buf), &num_read, NULL);
if (rc == 0)
{
-printf("apppath='%s'\n", buf);
+/*printf("apppath='%s'\n", buf); */
}
KConfigNodeRelease(node);
}
diff --git a/tools/align-info/align-info.c b/tools/align-info/align-info.c
index 0663401..afea6d6 100644
--- a/tools/align-info/align-info.c
+++ b/tools/align-info/align-info.c
@@ -68,6 +68,8 @@ typedef struct Params {
bool paramBamHeader;
bool paramQuality;
bool paramRef;
+
+ bool paramHeaders;
} Params;
#define ALIAS_ALL "a"
@@ -78,7 +80,7 @@ static const char* USAGE_ALL[] = { "print all information", NULL };
#define OPTION_BAM "bam"
static const char* USAGE_BAM[] = { "print bam header (if present)", NULL };
-#define ALIAS_QUA "q"
+#define ALIAS_QUA "Q"
#define OPTION_QUA "qual"
static const char* USAGE_QUA[]
= { "print quality statistics (if present)", NULL };
@@ -87,12 +89,17 @@ static const char* USAGE_QUA[]
#define OPTION_REF "ref"
static const char* USAGE_REF[] = { "print refseq information [default]", NULL };
+#define ALIAS_HEA "H"
+#define OPTION_HEA "headers"
+static const char* USAGE_HEA[] = { "print headers for output blocks", NULL };
+
OptDef Options[] =
{
{ OPTION_ALL, ALIAS_ALL, NULL, USAGE_ALL, 1, false, false }
, { OPTION_BAM, ALIAS_BAM, NULL, USAGE_BAM, 1, false, false }
, { OPTION_QUA, ALIAS_QUA, NULL, USAGE_QUA, 1, false, false }
, { OPTION_REF, ALIAS_REF, NULL, USAGE_REF, 1, false, false }
+ , { OPTION_HEA, ALIAS_HEA, NULL, USAGE_HEA, 1, false, false }
};
rc_t CC UsageSummary (const char * progname) {
@@ -130,6 +137,9 @@ rc_t CC Usage(const Args* args) {
HelpOptionLine (ALIAS_REF, OPTION_REF, NULL, USAGE_REF);
HelpOptionLine (ALIAS_BAM, OPTION_BAM, NULL, USAGE_BAM);
HelpOptionLine (ALIAS_QUA, OPTION_QUA, NULL, USAGE_QUA);
+ HelpOptionLine (ALIAS_HEA, OPTION_HEA, NULL, USAGE_HEA);
+
+ KOutMsg ("\n");
HelpOptionsStandard ();
@@ -275,9 +285,19 @@ static rc_t qual_stats(const Params* prm, const VDatabase* db) {
}
if (rc == 0 && count > 0)
{ ksort(quals, count, sizeof *quals, sort_callback, NULL); }
+
if (rc == 0) {
+ if (prm->paramHeaders) {
+ OUTMSG(("Quality statistics - rows per value\n"));
+ OUTMSG(("Quality values:"));
+ for (i = 0; i <= 40; ++i) {
+ OUTMSG(("\t%d", i));
+ }
+ OUTMSG(("\n"));
+ }
OUTMSG(("%s", prm->dbPath));
}
+
for (i = 0, nbr = 0; i < count && rc == 0; ++i, ++nbr) {
uint64_t u = 0;
char name[64];
@@ -364,6 +384,9 @@ static rc_t align_info(const Params* prm) {
const VDBDependencies* dep = NULL;
uint32_t count = 0;
int i = 0;
+ if (prm->paramHeaders) {
+ OUTMSG(("Alignments:\n"));
+ }
rc = VDatabaseListDependencies(db, &dep, false);
DISP_RC2(rc, prm->dbPath,
"while calling VDatabaseListDependencies");
@@ -427,6 +450,9 @@ static rc_t align_info(const Params* prm) {
OUTMSG(("\n"));
}
DESTRUCT(VDBDependencies, dep);
+ if (prm->paramHeaders) {
+ OUTMSG(("\n"));
+ }
}
if (prm->paramBamHeader) {
@@ -524,6 +550,15 @@ rc_t CC KMain(int argc, char* argv[]) {
if (!prm.paramBamHeader && !prm.paramQuality && !prm.paramRef)
{ prm.paramRef = true; }
+
+ rc = ArgsOptionCount (args, OPTION_HEA, &pcount);
+ if (rc) {
+ LOGERR(klogErr, rc, "Failure to get '" OPTION_HEA "' argument");
+ break;
+ }
+ if (pcount) {
+ prm.paramHeaders = true;
+ }
} while (false);
if (rc == 0)
diff --git a/tools/align-info/align-info.vers b/tools/align-info/align-info.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/align-info/align-info.vers
+++ b/tools/align-info/align-info.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/bam-loader/bam-load.vers b/tools/bam-loader/bam-load.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/bam-loader/bam-load.vers
+++ b/tools/bam-loader/bam-load.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/bam-loader/loader-imp.c b/tools/bam-loader/loader-imp.c
index 9f4d0de..0917b69 100644
--- a/tools/bam-loader/loader-imp.c
+++ b/tools/bam-loader/loader-imp.c
@@ -167,7 +167,7 @@ typedef struct context_t {
static char const *Print_ctx_value_t(ctx_value_t const *const self)
{
static char buffer[4096];
- rc_t rc = string_printf(buffer, sizeof(buffer), NULL, "pid: { %lu, %lu }, sid: %lu, fid: %u, alc: { %u, %u }, flg: %x", CTX_VALUE_GET_P_ID(*self, 0), CTX_VALUE_GET_P_ID(*self, 1), CTX_VALUE_GET_S_ID(*self), self->fragmentId, self->alignmentCount[0], self->alignmentCount[1], self->alignmentCount[2]);
+ rc_t rc = string_printf(buffer, sizeof(buffer), NULL, "pid: { %lu, %lu }, sid: %lu, fid: %u, alc: { %u, %u }, flg: %x", CTX_VALUE_GET_P_ID(*self, 0), CTX_VALUE_GET_P_ID(*self, 1), CTX_VALUE_GET_S_ID(*self), self->fragmentId, self->alignmentCount[0], self->alignmentCount[1], *(self->alignmentCount + sizeof(self->alignmentCount)/sizeof(self->alignmentCount[0])));
if (rc)
return 0;
@@ -1108,6 +1108,7 @@ static rc_t ProcessBAM(char const bamFile[], context_t *ctx, VDatabase *db,
AlignmentRecordInit(&data, buf.base, readlen | csSeqLen, &seqDNA);
qual = (uint8_t *)&seqDNA[readlen | csSeqLen];
}
+ BAMAlignmentGetReadName2(rec, &name, &namelen);/*BAM*/
BAMAlignmentGetSequence(rec, seqDNA);/*BAM*/
if (G.useQUAL) {
uint8_t const *squal;
@@ -1844,7 +1845,6 @@ static rc_t SequenceUpdateAlignInfo(context_t *ctx, Sequence *seq)
}
{{
int64_t primaryId[2];
- uint64_t const spotId = CTX_VALUE_GET_S_ID(*value);
primaryId[0] = CTX_VALUE_GET_P_ID(*value, 0);
primaryId[1] = CTX_VALUE_GET_P_ID(*value, 1);
@@ -2052,63 +2052,68 @@ rc_t run(char const progName[],
}
else {
bool has_alignments = false;
-
- if (G.onlyVerifyReferences) {
- rc = ArchiveBAM(mgr, NULL, bamFiles, bamFile, 0, NULL, &has_alignments);
- }
- else {
- VSchema *schema;
- rc = VDBManagerMakeSchema(mgr, &schema);
- if (rc) {
- (void)LOGERR (klogErr, rc, "failed to create schema");
+ rc = VDBManagerDisablePagemapThread(mgr);
+ if (rc == 0)
+ {
+
+ if (G.onlyVerifyReferences) {
+ rc = ArchiveBAM(mgr, NULL, bamFiles, bamFile, 0, NULL, &has_alignments);
}
else {
- (void)(rc = VSchemaAddIncludePath(schema, G.schemaIncludePath));
- rc = VSchemaParseFile(schema, G.schemaPath);
+ VSchema *schema;
+
+ rc = VDBManagerMakeSchema(mgr, &schema);
if (rc) {
- (void)PLOGERR(klogErr, (klogErr, rc, "failed to parse schema file $(file)", "file=%s", G.schemaPath));
+ (void)LOGERR (klogErr, rc, "failed to create schema");
}
else {
- VDatabase *db;
-
- rc = VDBManagerCreateDB(mgr, &db, schema, db_type,
- kcmInit + kcmMD5, G.outpath);
- rc2 = VSchemaRelease(schema);
- if (rc2)
- (void)LOGERR(klogWarn, rc2, "Failed to release schema");
- if (rc == 0)
- rc = rc2;
- if (rc == 0) {
- rc = ArchiveBAM(mgr, db, bamFiles, bamFile, seqFiles, seqFile, &has_alignments);
- if (rc == 0 && !has_alignments) {
- rc = ConvertDatabaseToUnmapped(db);
- }
+ (void)(rc = VSchemaAddIncludePath(schema, G.schemaIncludePath));
+ rc = VSchemaParseFile(schema, G.schemaPath);
+ if (rc) {
+ (void)PLOGERR(klogErr, (klogErr, rc, "failed to parse schema file $(file)", "file=%s", G.schemaPath));
+ }
+ else {
+ VDatabase *db;
- rc2 = VDatabaseRelease(db);
+ rc = VDBManagerCreateDB(mgr, &db, schema, db_type,
+ kcmInit + kcmMD5, G.outpath);
+ rc2 = VSchemaRelease(schema);
if (rc2)
- (void)LOGERR(klogWarn, rc2, "Failed to close database");
+ (void)LOGERR(klogWarn, rc2, "Failed to release schema");
if (rc == 0)
rc = rc2;
-
if (rc == 0) {
- KMetadata *meta;
- KDBManager *kmgr;
+ rc = ArchiveBAM(mgr, db, bamFiles, bamFile, seqFiles, seqFile, &has_alignments);
+ if (rc == 0 && !has_alignments) {
+ rc = ConvertDatabaseToUnmapped(db);
+ }
+
+ rc2 = VDatabaseRelease(db);
+ if (rc2)
+ (void)LOGERR(klogWarn, rc2, "Failed to close database");
+ if (rc == 0)
+ rc = rc2;
- rc = VDBManagerOpenKDBManagerUpdate(mgr, &kmgr);
if (rc == 0) {
- KDatabase *kdb;
+ KMetadata *meta;
+ KDBManager *kmgr;
- rc = KDBManagerOpenDBUpdate(kmgr, &kdb, G.outpath);
+ rc = VDBManagerOpenKDBManagerUpdate(mgr, &kmgr);
if (rc == 0) {
- rc = KDatabaseOpenMetadataUpdate(kdb, &meta);
- KDatabaseRelease(kdb);
+ KDatabase *kdb;
+
+ rc = KDBManagerOpenDBUpdate(kmgr, &kdb, G.outpath);
+ if (rc == 0) {
+ rc = KDatabaseOpenMetadataUpdate(kdb, &meta);
+ KDatabaseRelease(kdb);
+ }
+ KDBManagerRelease(kmgr);
+ }
+ if (rc == 0) {
+ rc = WriteLoaderSignature(meta, progName);
+ KMetadataRelease(meta);
}
- KDBManagerRelease(kmgr);
- }
- if (rc == 0) {
- rc = WriteLoaderSignature(meta, progName);
- KMetadataRelease(meta);
}
}
}
diff --git a/tools/cache-mgr/cache-mgr.vers b/tools/cache-mgr/cache-mgr.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/cache-mgr/cache-mgr.vers
+++ b/tools/cache-mgr/cache-mgr.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/cg-load/cg-load.vers b/tools/cg-load/cg-load.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/cg-load/cg-load.vers
+++ b/tools/cg-load/cg-load.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/fastq-loader/fastq-grammar.c b/tools/fastq-loader/fastq-grammar.c
index 66d32fd..6220df2 100644
--- a/tools/fastq-loader/fastq-grammar.c
+++ b/tools/fastq-loader/fastq-grammar.c
@@ -89,12 +89,15 @@
static void AddQuality(FASTQParseBlock* pb, const FASTQToken* token);
static void SetReadNumber(FASTQParseBlock* pb, const FASTQToken* token);
- static void GrowTagLine(FASTQParseBlock* pb, const FASTQToken* token);
+ static void StartSpotName(FASTQParseBlock* pb, size_t offset);
+ static void GrowSpotName(FASTQParseBlock* pb, const FASTQToken* token);
static void StopSpotName(FASTQParseBlock* pb);
static void SetSpotGroup(FASTQParseBlock* pb, const FASTQToken* token);
static void SetRead(FASTQParseBlock* pb, const FASTQToken* token);
#define UNLEX do { if (yychar != YYEMPTY && yychar != YYEOF) FASTQ_unlex(pb, & yylval); } while (0)
+
+ #define IS_PACBIO(pb) ((pb)->defaultReadNumber == -1)
@@ -132,7 +135,8 @@
fqCOLORSEQ = 263,
fqTOKEN = 264,
fqASCQUAL = 265,
- fqUNRECOGNIZED = 266
+ fqCOORDS = 266,
+ fqUNRECOGNIZED = 267
};
#endif
@@ -365,22 +369,22 @@ union yyalloc
#endif /* !YYCOPY_NEEDED */
/* YYFINAL -- State number of the termination state. */
-#define YYFINAL 24
+#define YYFINAL 21
/* YYLAST -- Last index in YYTABLE. */
-#define YYLAST 90
+#define YYLAST 111
/* YYNTOKENS -- Number of terminals. */
-#define YYNTOKENS 22
+#define YYNTOKENS 23
/* YYNNTS -- Number of nonterminals. */
-#define YYNNTS 52
+#define YYNNTS 53
/* YYNRULES -- Number of rules. */
-#define YYNRULES 89
+#define YYNRULES 96
/* YYNRULES -- Number of states. */
-#define YYNSTATES 131
+#define YYNSTATES 137
/* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */
#define YYUNDEFTOK 2
-#define YYMAXUTOK 266
+#define YYMAXUTOK 267
#define YYTRANSLATE(YYX) \
((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK)
@@ -391,13 +395,13 @@ static const yytype_uint8 yytranslate[] =
0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 18, 2, 2, 2, 2,
- 2, 2, 2, 21, 2, 16, 17, 19, 2, 2,
- 2, 2, 2, 2, 2, 2, 2, 2, 12, 2,
- 2, 20, 14, 2, 13, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 19, 2, 2, 2, 2,
+ 2, 2, 2, 22, 2, 18, 17, 20, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2, 13, 2,
+ 2, 21, 15, 2, 14, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
- 2, 2, 2, 2, 2, 15, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 16, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
@@ -414,67 +418,71 @@ static const yytype_uint8 yytranslate[] =
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
2, 2, 2, 2, 2, 2, 1, 2, 3, 4,
- 5, 6, 7, 8, 9, 10, 11
+ 5, 6, 7, 8, 9, 10, 11, 12
};
#if YYDEBUG
/* YYPRHS[YYN] -- Index of the first RHS symbol of rule number YYN in
YYRHS. */
-static const yytype_uint8 yyprhs[] =
+static const yytype_uint16 yyprhs[] =
{
0, 0, 3, 6, 8, 10, 11, 12, 13, 14,
- 15, 16, 17, 18, 19, 20, 21, 46, 50, 52,
- 54, 57, 59, 63, 68, 72, 75, 78, 80, 82,
- 83, 87, 88, 93, 94, 98, 99, 104, 106, 108,
- 110, 113, 114, 118, 120, 122, 125, 128, 131, 134,
- 137, 140, 141, 145, 146, 150, 151, 153, 154, 158,
- 159, 163, 164, 169, 170, 174, 175, 180, 181, 182,
- 183, 184, 185, 186, 200, 202, 204, 205, 207, 210,
- 213, 216, 219, 222, 226, 231, 233, 236, 239, 243
+ 25, 29, 31, 33, 36, 38, 42, 47, 51, 52,
+ 56, 57, 61, 63, 65, 66, 70, 71, 76, 77,
+ 81, 82, 87, 89, 91, 93, 96, 97, 101, 102,
+ 107, 108, 114, 115, 121, 122, 128, 129, 135, 136,
+ 143, 145, 147, 150, 153, 156, 159, 162, 165, 166,
+ 170, 171, 175, 176, 178, 179, 183, 184, 188, 189,
+ 194, 195, 199, 200, 205, 206, 207, 208, 209, 210,
+ 211, 225, 227, 229, 230, 232, 235, 238, 241, 244,
+ 247, 251, 256, 258, 261, 264, 268
};
/* YYRHS -- A `-1'-separated list of the rules' RHS. */
static const yytype_int8 yyrhs[] =
{
- 23, 0, -1, 37, 70, -1, 37, -1, 70, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 4, 24, 12, 25, 3, 26, 12, 27, 3,
- 28, 12, 29, 3, 30, 12, 31, 3, 32, 12,
- 33, 46, 12, 34, 72, -1, 4, 1, 36, -1,
- 35, -1, 0, -1, 36, 35, -1, 6, -1, 38,
- 36, 39, -1, 38, 36, 1, 36, -1, 1, 36,
- 39, -1, 13, 47, -1, 14, 47, -1, 40, -1,
- 43, -1, -1, 7, 41, 36, -1, -1, 40, 7,
- 42, 36, -1, -1, 8, 44, 36, -1, -1, 43,
- 8, 45, 36, -1, 7, -1, 8, -1, 48, -1,
- 48, 54, -1, -1, 50, 49, 51, -1, 4, -1,
- 3, -1, 50, 15, -1, 50, 16, -1, 50, 17,
- -1, 50, 12, -1, 50, 4, -1, 50, 3, -1,
- -1, 18, 52, 3, -1, -1, 18, 53, 4, -1,
- -1, 58, -1, -1, 5, 55, 61, -1, -1, 5,
- 56, 69, -1, -1, 54, 5, 57, 69, -1, -1,
- 19, 59, 3, -1, -1, 58, 19, 60, 4, -1,
- -1, -1, -1, -1, -1, -1, 3, 62, 12, 63,
- 4, 64, 12, 65, 3, 66, 12, 67, 68, -1,
- 4, -1, 3, -1, -1, 4, -1, 69, 3, -1,
- 69, 4, -1, 69, 15, -1, 69, 19, -1, 69,
- 20, -1, 71, 36, 72, -1, 71, 36, 1, 36,
- -1, 21, -1, 71, 9, -1, 73, 36, -1, 72,
- 73, 36, -1, 10, -1
+ 24, 0, -1, 31, 72, -1, 31, -1, 72, -1,
+ -1, -1, -1, -1, 52, 25, 11, 26, 13, 27,
+ 42, 13, 28, 74, -1, 4, 1, 30, -1, 29,
+ -1, 0, -1, 30, 29, -1, 6, -1, 32, 30,
+ 35, -1, 32, 30, 1, 30, -1, 1, 30, 35,
+ -1, -1, 14, 33, 43, -1, -1, 15, 34, 43,
+ -1, 36, -1, 39, -1, -1, 7, 37, 30, -1,
+ -1, 36, 7, 38, 30, -1, -1, 8, 40, 30,
+ -1, -1, 39, 8, 41, 30, -1, 7, -1, 8,
+ -1, 44, -1, 44, 56, -1, -1, 52, 45, 53,
+ -1, -1, 52, 11, 46, 53, -1, -1, 52, 11,
+ 16, 47, 63, -1, -1, 52, 11, 13, 48, 53,
+ -1, -1, 52, 11, 13, 49, 52, -1, -1, 52,
+ 11, 17, 50, 52, -1, -1, 52, 11, 13, 17,
+ 51, 52, -1, 4, -1, 3, -1, 52, 16, -1,
+ 52, 18, -1, 52, 17, -1, 52, 13, -1, 52,
+ 4, -1, 52, 3, -1, -1, 19, 54, 3, -1,
+ -1, 19, 55, 4, -1, -1, 60, -1, -1, 5,
+ 57, 63, -1, -1, 5, 58, 71, -1, -1, 56,
+ 5, 59, 71, -1, -1, 20, 61, 3, -1, -1,
+ 60, 20, 62, 52, -1, -1, -1, -1, -1, -1,
+ -1, 3, 64, 13, 65, 4, 66, 13, 67, 3,
+ 68, 13, 69, 70, -1, 4, -1, 3, -1, -1,
+ 4, -1, 71, 3, -1, 71, 4, -1, 71, 16,
+ -1, 71, 20, -1, 71, 21, -1, 73, 30, 74,
+ -1, 73, 30, 1, 30, -1, 22, -1, 73, 9,
+ -1, 75, 30, -1, 74, 75, 30, -1, 10, -1
};
/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
-static const yytype_uint8 yyrline[] =
+static const yytype_uint16 yyrline[] =
{
- 0, 71, 71, 73, 75, 77, 78, 79, 80, 81,
- 82, 83, 84, 85, 86, 88, 77, 91, 93, 97,
- 98, 102, 106, 107, 108, 112, 113, 117, 118, 122,
- 122, 124, 124, 129, 129, 131, 131, 136, 137, 142,
- 143, 147, 147, 152, 153, 154, 155, 156, 157, 158,
- 159, 163, 163, 165, 165, 167, 171, 172, 172, 174,
- 174, 176, 176, 181, 180, 192, 192, 197, 198, 199,
- 200, 201, 202, 197, 206, 207, 208, 212, 213, 214,
- 215, 216, 217, 223, 224, 228, 229, 233, 234, 237
+ 0, 75, 75, 77, 79, 81, 82, 83, 85, 81,
+ 88, 90, 94, 95, 99, 103, 104, 105, 109, 109,
+ 110, 110, 114, 115, 119, 119, 121, 121, 126, 126,
+ 128, 128, 133, 134, 139, 140, 144, 144, 146, 146,
+ 149, 148, 155, 155, 157, 157, 159, 159, 161, 161,
+ 166, 167, 168, 169, 170, 171, 172, 173, 177, 177,
+ 179, 179, 181, 185, 186, 186, 188, 188, 190, 190,
+ 195, 194, 207, 206, 218, 219, 220, 221, 222, 223,
+ 218, 228, 229, 230, 234, 235, 236, 237, 238, 239,
+ 245, 246, 250, 251, 255, 256, 259
};
#endif
@@ -485,15 +493,15 @@ static const char *const yytname[] =
{
"fqENDOFTEXT", "error", "$undefined", "fqNUMBER", "fqALPHANUM", "fqWS",
"fqENDLINE", "fqBASESEQ", "fqCOLORSEQ", "fqTOKEN", "fqASCQUAL",
- "fqUNRECOGNIZED", "':'", "'@'", "'>'", "'_'", "'-'", "'.'", "'#'", "'/'",
- "'='", "'+'", "$accept", "sequence", "$@1", "$@2", "$@3", "$@4", "$@5",
- "$@6", "$@7", "$@8", "$@9", "$@10", "$@11", "endfile", "endline",
- "readLines", "header", "read", "baseRead", "$@12", "$@13", "csRead",
- "$@14", "$@15", "inlineRead", "tagLine", "nameSpotGroup", "$@16", "name",
- "spotGroup", "$@17", "$@18", "readNumberOrTail", "$@19", "$@20", "$@21",
- "readNumber", "$@22", "$@23", "casava1_8", "$@24", "$@25", "$@26",
- "$@27", "$@28", "$@29", "indexSequence", "tail", "qualityLines",
- "qualityHeader", "quality", "qualityLine", 0
+ "fqCOORDS", "fqUNRECOGNIZED", "':'", "'@'", "'>'", "'_'", "'.'", "'-'",
+ "'#'", "'/'", "'='", "'+'", "$accept", "sequence", "$@1", "$@2", "$@3",
+ "$@4", "endfile", "endline", "readLines", "header", "$@5", "$@6", "read",
+ "baseRead", "$@7", "$@8", "csRead", "$@9", "$@10", "inlineRead",
+ "tagLine", "nameSpotGroup", "$@11", "$@12", "$@13", "$@14", "$@15",
+ "$@16", "$@17", "name", "spotGroup", "$@18", "$@19", "readNumberOrTail",
+ "$@20", "$@21", "$@22", "readNumber", "$@23", "$@24", "casava1_8",
+ "$@25", "$@26", "$@27", "$@28", "$@29", "$@30", "indexSequence", "tail",
+ "qualityLines", "qualityHeader", "quality", "qualityLine", 0
};
#endif
@@ -503,37 +511,39 @@ static const char *const yytname[] =
static const yytype_uint16 yytoknum[] =
{
0, 256, 257, 258, 259, 260, 261, 262, 263, 264,
- 265, 266, 58, 64, 62, 95, 45, 46, 35, 47,
- 61, 43
+ 265, 266, 267, 58, 64, 62, 95, 46, 45, 35,
+ 47, 61, 43
};
# endif
/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
static const yytype_uint8 yyr1[] =
{
- 0, 22, 23, 23, 23, 24, 25, 26, 27, 28,
- 29, 30, 31, 32, 33, 34, 23, 23, 23, 35,
- 35, 36, 37, 37, 37, 38, 38, 39, 39, 41,
- 40, 42, 40, 44, 43, 45, 43, 46, 46, 47,
- 47, 49, 48, 50, 50, 50, 50, 50, 50, 50,
- 50, 52, 51, 53, 51, 51, 54, 55, 54, 56,
- 54, 57, 54, 59, 58, 60, 58, 62, 63, 64,
- 65, 66, 67, 61, 68, 68, 68, 69, 69, 69,
- 69, 69, 69, 70, 70, 71, 71, 72, 72, 73
+ 0, 23, 24, 24, 24, 25, 26, 27, 28, 24,
+ 24, 24, 29, 29, 30, 31, 31, 31, 33, 32,
+ 34, 32, 35, 35, 37, 36, 38, 36, 40, 39,
+ 41, 39, 42, 42, 43, 43, 45, 44, 46, 44,
+ 47, 44, 48, 44, 49, 44, 50, 44, 51, 44,
+ 52, 52, 52, 52, 52, 52, 52, 52, 54, 53,
+ 55, 53, 53, 56, 57, 56, 58, 56, 59, 56,
+ 61, 60, 62, 60, 64, 65, 66, 67, 68, 69,
+ 63, 70, 70, 70, 71, 71, 71, 71, 71, 71,
+ 72, 72, 73, 73, 74, 74, 75
};
/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
static const yytype_uint8 yyr2[] =
{
- 0, 2, 2, 1, 1, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 24, 3, 1, 1,
- 2, 1, 3, 4, 3, 2, 2, 1, 1, 0,
- 3, 0, 4, 0, 3, 0, 4, 1, 1, 1,
- 2, 0, 3, 1, 1, 2, 2, 2, 2, 2,
- 2, 0, 3, 0, 3, 0, 1, 0, 3, 0,
- 3, 0, 4, 0, 3, 0, 4, 0, 0, 0,
- 0, 0, 0, 13, 1, 1, 0, 1, 2, 2,
- 2, 2, 2, 3, 4, 1, 2, 2, 3, 1
+ 0, 2, 2, 1, 1, 0, 0, 0, 0, 10,
+ 3, 1, 1, 2, 1, 3, 4, 3, 0, 3,
+ 0, 3, 1, 1, 0, 3, 0, 4, 0, 3,
+ 0, 4, 1, 1, 1, 2, 0, 3, 0, 4,
+ 0, 5, 0, 5, 0, 5, 0, 5, 0, 6,
+ 1, 1, 2, 2, 2, 2, 2, 2, 0, 3,
+ 0, 3, 0, 1, 0, 3, 0, 3, 0, 4,
+ 0, 3, 0, 4, 0, 0, 0, 0, 0, 0,
+ 13, 1, 1, 0, 1, 2, 2, 2, 2, 2,
+ 3, 4, 1, 2, 2, 3, 1
};
/* YYDEFACT[STATE-NAME] -- Default reduction number in state STATE-NUM.
@@ -541,121 +551,125 @@ static const yytype_uint8 yyr2[] =
means the default is an error. */
static const yytype_uint8 yydefact[] =
{
- 0, 19, 0, 0, 21, 0, 0, 85, 0, 18,
- 0, 3, 0, 4, 0, 0, 0, 0, 44, 43,
- 25, 39, 41, 26, 1, 20, 2, 0, 86, 0,
- 29, 33, 24, 27, 28, 17, 6, 57, 63, 40,
- 56, 50, 49, 48, 45, 46, 47, 55, 0, 22,
- 0, 89, 83, 0, 0, 0, 31, 35, 0, 0,
- 0, 0, 61, 65, 51, 42, 23, 84, 0, 87,
- 30, 34, 0, 0, 7, 67, 58, 77, 60, 64,
- 0, 0, 0, 0, 88, 32, 36, 0, 0, 78,
- 79, 80, 81, 82, 62, 66, 52, 54, 8, 68,
- 0, 0, 9, 69, 0, 0, 10, 70, 0, 0,
- 11, 71, 0, 0, 12, 72, 0, 76, 13, 75,
- 74, 73, 0, 14, 0, 37, 38, 0, 15, 0,
- 16
+ 0, 12, 0, 51, 0, 14, 18, 20, 92, 0,
+ 11, 0, 3, 0, 5, 4, 0, 0, 0, 0,
+ 0, 1, 13, 2, 0, 57, 56, 55, 52, 54,
+ 53, 0, 93, 0, 24, 28, 17, 22, 23, 10,
+ 50, 19, 34, 36, 21, 0, 15, 6, 0, 96,
+ 90, 0, 0, 0, 26, 30, 64, 70, 35, 63,
+ 38, 62, 16, 0, 91, 0, 94, 25, 29, 0,
+ 0, 0, 0, 0, 68, 72, 42, 40, 46, 62,
+ 58, 37, 7, 95, 27, 31, 74, 65, 84, 67,
+ 71, 0, 0, 48, 62, 0, 0, 0, 39, 0,
+ 0, 0, 0, 85, 86, 87, 88, 89, 69, 73,
+ 0, 43, 45, 41, 47, 59, 61, 32, 33, 0,
+ 75, 49, 8, 0, 0, 76, 9, 0, 77, 0,
+ 78, 0, 79, 83, 82, 81, 80
};
/* YYDEFGOTO[NTERM-NUM]. */
static const yytype_int16 yydefgoto[] =
{
- -1, 8, 17, 58, 87, 100, 104, 108, 112, 116,
- 122, 124, 129, 9, 10, 11, 12, 32, 33, 54,
- 72, 34, 55, 73, 127, 20, 21, 47, 22, 65,
- 82, 83, 39, 59, 60, 80, 40, 61, 81, 76,
- 88, 101, 105, 109, 113, 117, 121, 78, 13, 14,
- 52, 53
+ -1, 9, 31, 63, 101, 124, 10, 11, 12, 13,
+ 19, 20, 36, 37, 52, 69, 38, 53, 70, 119,
+ 41, 42, 61, 79, 96, 94, 95, 97, 110, 43,
+ 81, 99, 100, 58, 71, 72, 91, 59, 73, 92,
+ 87, 102, 123, 127, 129, 131, 133, 136, 89, 15,
+ 16, 50, 51
};
/* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing
STATE-NUM. */
-#define YYPACT_NINF -53
+#define YYPACT_NINF -69
static const yytype_int8 yypact[] =
{
- 3, -53, 6, 9, -53, 34, 34, -53, 23, -53,
- 2, 8, 6, -53, 16, 35, 6, 19, -53, -53,
- -53, 1, 24, -53, -53, -53, -53, 25, -53, 4,
- -53, -53, -53, 39, 40, -53, -53, 51, -53, 52,
- 37, -53, -53, -53, -53, -53, -53, 42, 6, -53,
- 6, -53, 48, 6, 6, 6, -53, -53, 56, 58,
- 59, 61, -53, -53, 62, -53, -53, -53, 6, -53,
- -53, -53, 6, 6, -53, -53, -53, -53, 15, -53,
- 59, 64, 66, 69, -53, -53, -53, 50, 53, -53,
- -53, -53, -53, -53, 15, -53, -53, -53, -53, -53,
- 67, 70, -53, -53, 63, 65, -53, -53, 73, 76,
- -53, -53, 68, 71, -53, -53, 78, 41, -53, -53,
- -53, -53, 72, -53, 43, -53, -53, 74, -53, 48,
- 48
+ 6, -69, -1, -69, 44, -69, -69, -69, -69, 16,
+ -69, 2, -4, -1, 71, -69, 23, 29, -1, 38,
+ 38, -69, -69, -69, 26, -69, -69, -69, -69, -69,
+ -69, 20, -69, 3, -69, -69, -69, 49, 50, -69,
+ -69, -69, 10, 65, -69, -1, -69, -69, -1, -69,
+ 53, -1, -1, -1, -69, -69, 55, -69, 59, 45,
+ 77, 48, -69, 60, -69, -1, -69, -69, -69, -1,
+ -1, 69, 75, 82, -69, -69, 21, -69, -69, 48,
+ 76, -69, -69, -69, -69, -69, -69, -69, -69, 19,
+ -69, 75, 38, -69, 48, 38, 69, 38, -69, 83,
+ 87, 36, 85, -69, -69, -69, -69, -69, 19, 71,
+ 38, -69, 71, -69, 71, -69, -69, -69, -69, 86,
+ -69, 71, -69, 92, 53, -69, 53, 88, -69, 97,
+ -69, 89, -69, 47, -69, -69, -69
};
/* YYPGOTO[NTERM-NUM]. */
static const yytype_int8 yypgoto[] =
{
- -53, -53, -53, -53, -53, -53, -53, -53, -53, -53,
- -53, -53, -53, 75, -1, -53, -53, 55, -53, -53,
- -53, -53, -53, -53, -53, 81, -53, -53, -53, -53,
- -53, -53, -53, -53, -53, -53, -53, -53, -53, -53,
- -53, -53, -53, -53, -53, -53, -53, 10, 77, -53,
- -40, -52
+ -69, -69, -69, -69, -69, -69, 93, 1, -69, -69,
+ -69, -69, 79, -69, -69, -69, -69, -69, -69, -69,
+ 91, -69, -69, -69, -69, -69, -69, -69, -69, 0,
+ -68, -69, -69, -69, -69, -69, -69, -69, -69, -69,
+ 9, -69, -69, -69, -69, -69, -69, -69, 15, 95,
+ -69, -16, -49
};
/* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If
positive, shift that token. If negative, reduce the rule which
number is the opposite. If YYTABLE_NINF, syntax error. */
-#define YYTABLE_NINF -60
+#define YYTABLE_NINF -67
static const yytype_int16 yytable[] =
{
- 68, 15, 1, 1, 2, 50, 37, 3, 4, 4,
- 16, 27, 4, 29, 51, 35, 5, 6, 89, 90,
- 38, -5, 4, 24, 7, 28, 48, 41, 42, 7,
- 91, 36, 30, 31, 92, 93, 43, 18, 19, 44,
- 45, 46, 30, 31, 119, 120, 56, 66, 57, 67,
- 125, 126, 69, 70, 71, -59, 63, 62, 51, 74,
- 64, 75, 98, 77, 79, 99, -53, 84, 95, 96,
- 102, 85, 86, 97, 103, 106, 110, 107, 68, 111,
- 114, 118, 49, 115, 123, 25, 128, 23, 26, 130,
- 94
+ 14, 65, 1, 17, 48, 5, 1, 2, 5, 3,
+ 4, 98, 5, 49, 24, 56, 21, 33, 8, 39,
+ 6, 7, 103, 104, -44, -44, 111, 45, 8, 5,
+ 57, 47, 32, 34, 35, 105, 34, 35, 93, 106,
+ 107, 3, 40, 117, 118, 18, 62, -50, -50, 64,
+ 134, 135, 66, 67, 68, -50, 54, -50, 55, -66,
+ -50, -50, -50, 49, 74, 75, 83, 80, 25, 26,
+ 84, 85, 86, 82, 25, 26, 60, 65, 27, 88,
+ -60, 28, 29, 30, 27, 90, 115, 28, 29, 30,
+ 76, 116, 109, 77, 78, 112, 125, 114, 120, 122,
+ 130, 128, 132, 46, 22, 113, 108, 23, 126, 0,
+ 121, 44
};
#define yypact_value_is_default(yystate) \
- ((yystate) == (-53))
+ ((yystate) == (-69))
#define yytable_value_is_error(yytable_value) \
YYID (0)
-static const yytype_uint8 yycheck[] =
+static const yytype_int8 yycheck[] =
{
- 52, 2, 0, 0, 1, 1, 5, 4, 6, 6,
- 1, 12, 6, 14, 10, 16, 13, 14, 3, 4,
- 19, 12, 6, 0, 21, 9, 1, 3, 4, 21,
- 15, 12, 7, 8, 19, 20, 12, 3, 4, 15,
- 16, 17, 7, 8, 3, 4, 7, 48, 8, 50,
- 7, 8, 53, 54, 55, 4, 19, 5, 10, 3,
- 18, 3, 12, 4, 3, 12, 4, 68, 4, 3,
- 3, 72, 73, 4, 4, 12, 3, 12, 130, 3,
- 12, 3, 27, 12, 12, 10, 12, 6, 11, 129,
- 80
+ 0, 50, 0, 2, 1, 6, 0, 1, 6, 3,
+ 4, 79, 6, 10, 13, 5, 0, 16, 22, 18,
+ 14, 15, 3, 4, 3, 4, 94, 1, 22, 6,
+ 20, 11, 9, 7, 8, 16, 7, 8, 17, 20,
+ 21, 3, 4, 7, 8, 1, 45, 3, 4, 48,
+ 3, 4, 51, 52, 53, 11, 7, 13, 8, 4,
+ 16, 17, 18, 10, 5, 20, 65, 19, 3, 4,
+ 69, 70, 3, 13, 3, 4, 11, 126, 13, 4,
+ 4, 16, 17, 18, 13, 3, 3, 16, 17, 18,
+ 13, 4, 92, 16, 17, 95, 4, 97, 13, 13,
+ 3, 13, 13, 24, 11, 96, 91, 12, 124, -1,
+ 110, 20
};
/* YYSTOS[STATE-NUM] -- The (internal number of the) accessing
symbol of state STATE-NUM. */
static const yytype_uint8 yystos[] =
{
- 0, 0, 1, 4, 6, 13, 14, 21, 23, 35,
- 36, 37, 38, 70, 71, 36, 1, 24, 3, 4,
- 47, 48, 50, 47, 0, 35, 70, 36, 9, 36,
- 7, 8, 39, 40, 43, 36, 12, 5, 19, 54,
- 58, 3, 4, 12, 15, 16, 17, 49, 1, 39,
- 1, 10, 72, 73, 41, 44, 7, 8, 25, 55,
- 56, 59, 5, 19, 18, 51, 36, 36, 73, 36,
- 36, 36, 42, 45, 3, 3, 61, 4, 69, 3,
- 57, 60, 52, 53, 36, 36, 36, 26, 62, 3,
- 4, 15, 19, 20, 69, 4, 3, 4, 12, 12,
- 27, 63, 3, 4, 28, 64, 12, 12, 29, 65,
- 3, 3, 30, 66, 12, 12, 31, 67, 3, 3,
- 4, 68, 32, 12, 33, 7, 8, 46, 12, 34,
- 72
+ 0, 0, 1, 3, 4, 6, 14, 15, 22, 24,
+ 29, 30, 31, 32, 52, 72, 73, 30, 1, 33,
+ 34, 0, 29, 72, 30, 3, 4, 13, 16, 17,
+ 18, 25, 9, 30, 7, 8, 35, 36, 39, 30,
+ 4, 43, 44, 52, 43, 1, 35, 11, 1, 10,
+ 74, 75, 37, 40, 7, 8, 5, 20, 56, 60,
+ 11, 45, 30, 26, 30, 75, 30, 30, 30, 38,
+ 41, 57, 58, 61, 5, 20, 13, 16, 17, 46,
+ 19, 53, 13, 30, 30, 30, 3, 63, 4, 71,
+ 3, 59, 62, 17, 48, 49, 47, 50, 53, 54,
+ 55, 27, 64, 3, 4, 16, 20, 21, 71, 52,
+ 51, 53, 52, 63, 52, 3, 4, 7, 8, 42,
+ 13, 52, 13, 65, 28, 4, 74, 66, 13, 67,
+ 3, 68, 13, 69, 3, 4, 70
};
#define yyerrok (yyerrstatus = 0)
@@ -1511,293 +1525,307 @@ yyreduce:
case 5:
- { GrowTagLine(pb, &(yyvsp[(1) - (1)])); }
+ { StartSpotName(pb, 0); }
break;
case 6:
- { GrowTagLine(pb, &(yyvsp[(3) - (3)])); }
+ { GrowSpotName(pb, &(yyvsp[(3) - (3)])); StopSpotName(pb); }
break;
case 7:
- { GrowTagLine(pb, &(yyvsp[(5) - (5)])); }
+ { FASTQScan_inline_sequence(pb); }
break;
case 8:
- { GrowTagLine(pb, &(yyvsp[(7) - (7)]));}
+ { FASTQScan_inline_quality(pb); }
break;
case 9:
- { GrowTagLine(pb, &(yyvsp[(9) - (9)])); }
+ { UNLEX; return 1; }
break;
case 10:
- { GrowTagLine(pb, &(yyvsp[(11) - (11)])); }
+ { UNLEX; return 1; }
break;
case 11:
- { GrowTagLine(pb, &(yyvsp[(13) - (13)])); }
- break;
-
- case 12:
-
- { GrowTagLine(pb, &(yyvsp[(15) - (15)])); }
- break;
-
- case 13:
-
- { GrowTagLine(pb, &(yyvsp[(17) - (17)])); }
- break;
-
- case 14:
-
- { FASTQScan_inline_sequence(pb); }
- break;
-
- case 15:
-
- { FASTQScan_inline_quality(pb); }
- break;
-
- case 16:
-
- { UNLEX; return 1; }
+ { return 0; }
break;
- case 17:
+ case 18:
- { UNLEX; return 1; }
+ { StartSpotName(pb, 1); }
break;
- case 18:
+ case 20:
- { return 0; }
+ { StartSpotName(pb, 1); }
break;
- case 27:
+ case 22:
{ pb->record->seq.is_colorspace = false; }
break;
- case 28:
+ case 23:
{ pb->record->seq.is_colorspace = true; }
break;
- case 29:
+ case 24:
{ SetRead(pb, & (yyvsp[(1) - (1)])); }
break;
- case 31:
+ case 26:
{ SetRead(pb, & (yyvsp[(2) - (2)])); }
break;
- case 33:
+ case 28:
{ SetRead(pb, & (yyvsp[(1) - (1)])); }
break;
- case 35:
+ case 30:
{ SetRead(pb, & (yyvsp[(2) - (2)])); }
break;
- case 37:
+ case 32:
{ SetRead(pb, & (yyvsp[(1) - (1)])); pb->record->seq.is_colorspace = false; }
break;
- case 38:
+ case 33:
{ SetRead(pb, & (yyvsp[(1) - (1)])); pb->record->seq.is_colorspace = true; }
break;
- case 41:
+ case 36:
{ StopSpotName(pb); }
break;
- case 43:
+ case 38:
- { GrowTagLine(pb, &(yyvsp[(1) - (1)])); }
+ { GrowSpotName(pb, &(yyvsp[(2) - (2)])); StopSpotName(pb); }
break;
- case 44:
+ case 40:
- { GrowTagLine(pb, &(yyvsp[(1) - (1)])); }
+ { /* another crazy variation by Illumina, this time "_" is used as " /" */
+ GrowSpotName(pb, &(yyvsp[(2) - (3)]));
+ StopSpotName(pb);
+ GrowSpotName(pb, &(yyvsp[(3) - (3)]));
+ }
break;
- case 45:
+ case 42:
- { GrowTagLine(pb, &(yyvsp[(2) - (2)])); }
+ { GrowSpotName(pb, &(yyvsp[(2) - (3)])); GrowSpotName(pb, &(yyvsp[(3) - (3)])); StopSpotName(pb); }
break;
- case 46:
+ case 44:
- { GrowTagLine(pb, &(yyvsp[(2) - (2)])); }
+ { GrowSpotName(pb, &(yyvsp[(2) - (3)])); GrowSpotName(pb, &(yyvsp[(3) - (3)]));}
break;
- case 47:
+ case 46:
- { GrowTagLine(pb, &(yyvsp[(2) - (2)])); }
+ { GrowSpotName(pb, &(yyvsp[(2) - (3)])); GrowSpotName(pb, &(yyvsp[(3) - (3)]));}
break;
case 48:
- { GrowTagLine(pb, &(yyvsp[(2) - (2)])); }
- break;
-
- case 49:
-
- { GrowTagLine(pb, &(yyvsp[(2) - (2)])); }
+ { GrowSpotName(pb, &(yyvsp[(2) - (4)])); GrowSpotName(pb, &(yyvsp[(3) - (4)])); GrowSpotName(pb, &(yyvsp[(3) - (4)]));}
break;
case 50:
- { GrowTagLine(pb, &(yyvsp[(2) - (2)])); }
+ { GrowSpotName(pb, &(yyvsp[(1) - (1)])); }
break;
case 51:
- { GrowTagLine(pb, &(yyvsp[(1) - (1)])); }
+ { GrowSpotName(pb, &(yyvsp[(1) - (1)])); }
break;
case 52:
- { SetSpotGroup(pb, &(yyvsp[(3) - (3)])); GrowTagLine(pb, &(yyvsp[(3) - (3)])); }
+ { GrowSpotName(pb, &(yyvsp[(2) - (2)])); }
break;
case 53:
- { GrowTagLine(pb, &(yyvsp[(1) - (1)])); }
+ { GrowSpotName(pb, &(yyvsp[(2) - (2)])); }
break;
case 54:
- { SetSpotGroup(pb, &(yyvsp[(3) - (3)])); GrowTagLine(pb, &(yyvsp[(3) - (3)])); }
+ { GrowSpotName(pb, &(yyvsp[(2) - (2)])); }
break;
- case 57:
+ case 55:
- { GrowTagLine(pb, &(yyvsp[(1) - (1)])); }
+ { GrowSpotName(pb, &(yyvsp[(2) - (2)])); }
break;
- case 59:
+ case 56:
- { GrowTagLine(pb, &(yyvsp[(1) - (1)])); }
+ { GrowSpotName(pb, &(yyvsp[(2) - (2)])); }
break;
- case 61:
+ case 57:
- { GrowTagLine(pb, &(yyvsp[(2) - (2)])); }
+ { GrowSpotName(pb, &(yyvsp[(2) - (2)])); }
break;
- case 63:
+ case 58:
- { /* in PACBIO fastq, the first '/' and the following digits are treated as a continuation of the spot name, not a read number */
- if (pb->defaultReadNumber == -1) pb->spotNameDone = false;
- GrowTagLine(pb, &(yyvsp[(1) - (1)]));
- }
+ { GrowSpotName(pb, &(yyvsp[(1) - (1)])); }
break;
- case 64:
+ case 59:
- {
- SetReadNumber(pb, &(yyvsp[(3) - (3)]));
- GrowTagLine(pb, &(yyvsp[(3) - (3)]));
- StopSpotName(pb);
- }
+ { SetSpotGroup(pb, &(yyvsp[(3) - (3)])); GrowSpotName(pb, &(yyvsp[(3) - (3)])); }
break;
- case 65:
+ case 60:
- { GrowTagLine(pb, &(yyvsp[(2) - (2)])); }
+ { GrowSpotName(pb, &(yyvsp[(1) - (1)])); }
break;
- case 66:
+ case 61:
- { GrowTagLine(pb, &(yyvsp[(4) - (4)])); }
+ { SetSpotGroup(pb, &(yyvsp[(3) - (3)])); GrowSpotName(pb, &(yyvsp[(3) - (3)])); }
break;
- case 67:
+ case 64:
- { SetReadNumber(pb, &(yyvsp[(1) - (1)])); GrowTagLine(pb, &(yyvsp[(1) - (1)])); }
+ { GrowSpotName(pb, &(yyvsp[(1) - (1)])); }
break;
- case 68:
+ case 66:
- { GrowTagLine(pb, &(yyvsp[(3) - (3)])); }
+ { GrowSpotName(pb, &(yyvsp[(1) - (1)])); }
break;
- case 69:
+ case 68:
- { GrowTagLine(pb, &(yyvsp[(5) - (5)])); if ((yyvsp[(5) - (5)]).tokenLength == 1 && (yyvsp[(5) - (5)]).tokenText[0] == 'Y') pb->record->seq.lowQuality = true; }
+ { GrowSpotName(pb, &(yyvsp[(2) - (2)])); }
break;
case 70:
- { GrowTagLine(pb, &(yyvsp[(7) - (7)])); }
+ { /* in PACBIO fastq, the first '/' and the following digits are treated as a continuation of the spot name, not a read number */
+ if (IS_PACBIO(pb)) pb->spotNameDone = false;
+ GrowSpotName(pb, &(yyvsp[(1) - (1)]));
+ }
break;
case 71:
- { GrowTagLine(pb, &(yyvsp[(9) - (9)])); }
+ {
+ if (!IS_PACBIO(pb)) SetReadNumber(pb, &(yyvsp[(3) - (3)]));
+ GrowSpotName(pb, &(yyvsp[(3) - (3)]));
+ StopSpotName(pb);
+ }
break;
case 72:
- { GrowTagLine(pb, &(yyvsp[(11) - (11)])); }
+ {
+ if (IS_PACBIO(pb)) pb->spotNameDone = false;
+ GrowSpotName(pb, &(yyvsp[(2) - (2)]));
+ }
+ break;
+
+ case 73:
+
+ {
+ if (IS_PACBIO(pb)) StopSpotName(pb);
+ }
break;
case 74:
- { SetSpotGroup(pb, &(yyvsp[(1) - (1)])); GrowTagLine(pb, &(yyvsp[(1) - (1)])); }
+ { SetReadNumber(pb, &(yyvsp[(1) - (1)])); GrowSpotName(pb, &(yyvsp[(1) - (1)])); StopSpotName(pb); }
break;
case 75:
- { SetSpotGroup(pb, &(yyvsp[(1) - (1)])); GrowTagLine(pb, &(yyvsp[(1) - (1)])); }
+ { GrowSpotName(pb, &(yyvsp[(3) - (3)])); }
+ break;
+
+ case 76:
+
+ { GrowSpotName(pb, &(yyvsp[(5) - (5)])); if ((yyvsp[(5) - (5)]).tokenLength == 1 && TokenTextPtr(pb, &(yyvsp[(5) - (5)]))[0] == 'Y') pb->record->seq.lowQuality = true; }
break;
case 77:
- { GrowTagLine(pb, &(yyvsp[(1) - (1)])); }
+ { GrowSpotName(pb, &(yyvsp[(7) - (7)])); }
break;
case 78:
- { GrowTagLine(pb, &(yyvsp[(2) - (2)])); }
+ { GrowSpotName(pb, &(yyvsp[(9) - (9)])); }
break;
case 79:
- { GrowTagLine(pb, &(yyvsp[(2) - (2)])); }
+ { GrowSpotName(pb, &(yyvsp[(11) - (11)])); }
break;
- case 80:
+ case 81:
- { GrowTagLine(pb, &(yyvsp[(2) - (2)])); }
+ { SetSpotGroup(pb, &(yyvsp[(1) - (1)])); GrowSpotName(pb, &(yyvsp[(1) - (1)])); }
break;
- case 81:
+ case 82:
- { GrowTagLine(pb, &(yyvsp[(2) - (2)])); }
+ { SetSpotGroup(pb, &(yyvsp[(1) - (1)])); GrowSpotName(pb, &(yyvsp[(1) - (1)])); }
break;
- case 82:
+ case 84:
+
+ { GrowSpotName(pb, &(yyvsp[(1) - (1)])); }
+ break;
+
+ case 85:
+
+ { GrowSpotName(pb, &(yyvsp[(2) - (2)])); }
+ break;
+
+ case 86:
+
+ { GrowSpotName(pb, &(yyvsp[(2) - (2)])); }
+ break;
+
+ case 87:
- { GrowTagLine(pb, &(yyvsp[(2) - (2)])); }
+ { GrowSpotName(pb, &(yyvsp[(2) - (2)])); }
+ break;
+
+ case 88:
+
+ { GrowSpotName(pb, &(yyvsp[(2) - (2)])); }
break;
case 89:
+ { GrowSpotName(pb, &(yyvsp[(2) - (2)])); }
+ break;
+
+ case 96:
+
{ AddQuality(pb, & (yyvsp[(1) - (1)])); }
break;
@@ -2034,14 +2062,6 @@ yyreturn:
-static
-void GrowByteBuffer(KDataBuffer* self, const char* buf, uint64_t length)
-{
- uint64_t oldSize = self->elem_count;
- KDataBufferResize( self, oldSize + length );
- memcpy( (char*)self->base + oldSize, buf, length );
-}
-
void AddQuality(FASTQParseBlock* pb, const FASTQToken* token)
{
if (pb->phredOffset != 0)
@@ -2052,10 +2072,13 @@ void AddQuality(FASTQParseBlock* pb, const FASTQToken* token)
for (i=0; i < token->tokenLength; ++i)
{
char buf[200];
- if (token->tokenText[i] < floor || token->tokenText[i] > ceiling)
+ char ch = TokenTextPtr(pb, token)[i];
+ if (ch < floor || ch > ceiling)
{
- sprintf(buf, "Invalid quality value (%d): for %s, valid range is from %d to %d.",
- token->tokenText[i],
+ sprintf(buf, "Invalid quality value ('%c'=%d, position %d): for %s, valid range is from %d to %d.",
+ ch,
+ ch,
+ i,
pb->phredOffset == 33 ? "Phred33": "Phred64",
floor,
ceiling);
@@ -2065,65 +2088,91 @@ void AddQuality(FASTQParseBlock* pb, const FASTQToken* token)
}
}
}
- GrowByteBuffer( & pb->quality, token->tokenText, token->tokenLength);
+ if (pb->qualityLength == 0)
+ {
+ pb->qualityOffset = token->tokenStart;
+ pb->qualityLength= token->tokenLength;
+ }
+ else
+ {
+ pb->qualityLength += token->tokenLength;
+ }
}
void SetReadNumber(FASTQParseBlock* pb, const FASTQToken* token)
-{
+{ /* token is known to be numeric */
if (pb->defaultReadNumber != -1)
- {
+ { /* we will only handle 1-digit read numbers for now*/
if (token->tokenLength == 1)
{
- switch (token->tokenText[0])
+ switch (TokenTextPtr(pb, token)[0])
{
- case '1': pb->record->seq.readnumber = 1; return;
- case '2': pb->record->seq.readnumber = 2; return;
+ case '1':
+ {
+ pb->record->seq.readnumber = 1;
+ break;
+ }
+ case '0':
+ {
+ pb->record->seq.readnumber = pb->defaultReadNumber;
+ break;
+ }
+ default:
+ { /* all secondary read numbers should be the same across an input file */
+ uint8_t readNum = TokenTextPtr(pb, token)[0] - '0';
+ if (pb->secondaryReadNumber == 0) /* this is the first secondary read observed */
+ {
+ pb->secondaryReadNumber = readNum;
+ }
+ else if (pb->secondaryReadNumber != readNum)
+ {
+ char buf[200];
+ sprintf(buf,
+ "Inconsistent secondary read number: previously used %d, now seen %d",
+ pb->secondaryReadNumber, readNum);
+ pb->fatalError = true;
+ yyerror(pb, buf);
+ return;
+ }
+ /* all secondary read numbers are internally represented as 2 */
+ pb->record->seq.readnumber = 2;
+
+ break;
+ }
}
}
- pb->record->seq.readnumber = pb->defaultReadNumber;
+ else
+ pb->record->seq.readnumber = pb->defaultReadNumber;
}
}
-void GrowTagLine(FASTQParseBlock* pb, const FASTQToken* token)
+void StartSpotName(FASTQParseBlock* pb, size_t offset)
+{
+ pb->spotNameOffset = offset;
+}
+void GrowSpotName(FASTQParseBlock* pb, const FASTQToken* token)
{
- /* TODO: move tagline to FileReader, move this function to fastq-reader.c */
-
- /* grow the buffer as necessary*/
- uint64_t oldSize = pb->tagLine.elem_count;
- KDataBufferResize( & pb->tagLine, oldSize + token->tokenLength);
- string_copy((char*)pb->tagLine.base + oldSize, pb->tagLine.elem_count - oldSize, token->tokenText, token->tokenLength);
-
if (!pb->spotNameDone)
- pb->spotNameLength = pb->tagLine.elem_count;
+ pb->spotNameLength += token->tokenLength;
}
void StopSpotName(FASTQParseBlock* pb)
-{ /* spot name is the current content of the tag line (there may be more tokens coming, they will not be a part of the spot name) */
+{ /* there may be more tokens coming, they will not be a part of the spot name */
pb->spotNameDone = true;
}
void SetSpotGroup(FASTQParseBlock* pb, const FASTQToken* token)
{
- if (token->tokenLength != 1 || token->tokenText[0] != '0') /* ignore spot group 0 */
+ if (token->tokenLength != 1 || TokenTextPtr(pb, token)[0] != '0') /* ignore spot group 0 */
{
- pb->spotGroupOffset = pb->tagLine.elem_count;
+ pb->spotGroupOffset = token->tokenStart;
pb->spotGroupLength = token->tokenLength;
}
}
void SetRead(FASTQParseBlock* pb, const FASTQToken* token)
{
- if (pb->record->seq.read)
- {
- pb->record->seq.read = (char*)realloc(pb->record->seq.read, strlen(pb->record->seq.read) + 1 + token->tokenLength + 1);
- strcat(pb->record->seq.read, token->tokenText);
- ++pb->expectedQualityLines;
- }
- else
- {
- pb->record->seq.read = (char*)malloc(token->tokenLength+1);
- strcpy(pb->record->seq.read, token->tokenText);
- pb->expectedQualityLines = 1;
- }
+ pb->readOffset = token->tokenStart;
+ pb->readLength = token->tokenLength;
}
diff --git a/tools/fastq-loader/fastq-lex.c b/tools/fastq-loader/fastq-lex.c
index e31d4bd..0152a84 100644
--- a/tools/fastq-loader/fastq-lex.c
+++ b/tools/fastq-loader/fastq-lex.c
@@ -361,8 +361,8 @@ static void yy_fatal_error (yyconst char msg[] ,yyscan_t yyscanner );
*yy_cp = '\0'; \
yyg->yy_c_buf_p = yy_cp;
-#define YY_NUM_RULES 27
-#define YY_END_OF_BUFFER 28
+#define YY_NUM_RULES 28
+#define YY_END_OF_BUFFER 29
/* This struct is not used in this scanner,
but its presence is necessary. */
struct yy_trans_info
@@ -370,44 +370,44 @@ struct yy_trans_info
flex_int32_t yy_verify;
flex_int32_t yy_nxt;
};
-static yyconst flex_int16_t yy_acclist[175] =
+static yyconst flex_int16_t yy_acclist[178] =
{ 0,
- 28, 9, 27, 6, 9, 27, 26, 27, 9, 26,
- 27, 5, 9, 27, 4, 5, 9, 27, 3, 9,
- 27, 9, 27,16391, 2, 9, 27, 1, 9, 27,
- 5, 9, 27,16391, 5, 9, 27,16391, 6, 9,
- 27, 10, 27, 9, 10, 27, 27, 27, 14, 27,
- 27,16397, 27,16395,16397, 27,16395,16397, 27, 18,
- 27, 18, 27, 22, 27, 19, 22, 27, 21, 27,
- 21, 22, 27, 22, 27,16404, 19, 22, 27,16404,
- 15, 27, 15, 27, 25, 27, 19, 25, 27, 24,
- 27, 24, 25, 27, 25, 27,16407, 19, 25, 27,
-
- 16407, 6, 26, 5, 4, 5, 8199, 8199,16391,16391,
- 16392, 5,16392, 5,16391, 6, 10, 10, 14, 8205,
- 14, 8205,16397, 8203, 8205, 14, 8203, 8205,16395,16397,
- 16395,16396,16397,16396,16397, 17, 17, 18, 19, 21,
- 8212, 8212,16404, 19,16404, 15, 15, 16, 16, 24,
- 8215, 8215,16407, 19,16407, 8199, 8200, 8199, 8200,16392,
- 8200, 8200, 8203, 8204, 8205, 14, 8203, 8204, 8205, 8204,
- 8205, 14, 8204, 8205
+ 29, 10, 28, 7, 10, 28, 27, 28, 10, 27,
+ 28, 6, 10, 28, 5, 6, 10, 28, 10, 28,
+ 3, 10, 28, 10, 28,16392, 2, 10, 28, 1,
+ 10, 28, 6, 10, 28,16392, 6, 10, 28,16392,
+ 7, 10, 28, 11, 28, 10, 11, 28, 28, 28,
+ 15, 28, 28,16398, 28,16396,16398, 28,16396,16398,
+ 28, 19, 28, 19, 28, 23, 28, 20, 23, 28,
+ 22, 28, 22, 23, 28, 23, 28,16405, 20, 23,
+ 28,16405, 16, 28, 16, 28, 26, 28, 20, 26,
+ 28, 25, 28, 25, 26, 28, 26, 28,16408, 20,
+
+ 26, 28,16408, 7, 27, 6, 5, 6, 8200, 8200,
+ 16392,16392,16393, 6,16393, 6,16392, 7, 11, 11,
+ 15, 8206, 15, 8206,16398, 8204, 8206, 15, 8204, 8206,
+ 16396,16398,16396,16397,16398,16397,16398, 18, 18, 19,
+ 20, 22, 8213, 8213,16405, 20,16405, 16, 16, 17,
+ 17, 25, 8216, 8216,16408, 20,16408, 8200, 8201, 8200,
+ 8201,16393, 8201, 8201, 8204, 8205, 8206, 15, 8204, 8205,
+ 8206, 8205, 8206, 15, 8205, 8206, 4
} ;
-static yyconst flex_int16_t yy_accept[113] =
+static yyconst flex_int16_t yy_accept[121] =
{ 0,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 2, 4, 7, 9, 12, 15, 19,
- 22, 25, 28, 31, 35, 39, 42, 44, 47, 48,
- 49, 51, 53, 56, 59, 60, 62, 64, 66, 69,
- 71, 74, 77, 81, 83, 85, 87, 90, 92, 95,
- 98, 102, 103, 104, 105, 107, 108, 109, 110, 112,
- 114, 116, 117, 118, 119, 119, 120, 122, 123, 124,
- 127, 129, 131, 134, 136, 136, 137, 139, 140, 141,
- 142, 143, 144, 146, 147, 149, 150, 151, 152, 153,
-
- 154, 156, 158, 160, 161, 162, 163, 167, 170, 173,
- 175, 175
+ 21, 24, 27, 30, 33, 37, 41, 44, 46, 49,
+ 50, 51, 53, 55, 58, 61, 62, 64, 66, 68,
+ 71, 73, 76, 79, 83, 85, 87, 89, 92, 94,
+ 97, 100, 104, 105, 106, 107, 109, 109, 110, 111,
+ 112, 114, 116, 118, 119, 120, 121, 121, 122, 124,
+ 125, 126, 129, 131, 133, 136, 138, 138, 139, 141,
+ 142, 143, 144, 145, 146, 148, 149, 151, 152, 153,
+
+ 154, 155, 156, 158, 158, 160, 162, 163, 164, 165,
+ 169, 172, 175, 177, 177, 177, 177, 177, 178, 178
} ;
static yyconst flex_int32_t yy_ec[256] =
@@ -417,14 +417,14 @@ static yyconst flex_int32_t yy_ec[256] =
5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
5, 6, 5, 5, 5, 5, 5, 5, 5, 5,
5, 5, 7, 5, 8, 9, 5, 10, 10, 10,
- 10, 11, 11, 11, 11, 11, 11, 5, 5, 5,
- 5, 12, 5, 13, 14, 8, 14, 8, 8, 8,
- 14, 8, 8, 8, 8, 8, 8, 15, 8, 8,
- 8, 8, 8, 14, 8, 8, 8, 8, 8, 8,
- 5, 5, 5, 5, 8, 5, 14, 8, 14, 8,
-
- 8, 8, 14, 8, 8, 8, 8, 8, 8, 15,
- 8, 8, 8, 8, 8, 14, 8, 8, 8, 8,
+ 10, 11, 11, 11, 11, 11, 11, 12, 5, 5,
+ 5, 13, 5, 14, 15, 8, 15, 8, 8, 8,
+ 15, 8, 8, 8, 8, 8, 8, 16, 8, 8,
+ 8, 8, 8, 15, 8, 8, 8, 8, 8, 8,
+ 5, 5, 5, 5, 5, 5, 15, 8, 15, 8,
+
+ 8, 8, 15, 8, 8, 8, 8, 8, 8, 16,
+ 8, 8, 8, 8, 8, 15, 8, 8, 8, 8,
8, 8, 5, 5, 5, 5, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
@@ -442,119 +442,133 @@ static yyconst flex_int32_t yy_ec[256] =
1, 1, 1, 1, 1
} ;
-static yyconst flex_int32_t yy_meta[16] =
+static yyconst flex_int32_t yy_meta[17] =
{ 0,
- 1, 1, 2, 2, 3, 3, 3, 4, 5, 4,
- 4, 3, 3, 6, 6
+ 1, 1, 2, 2, 3, 3, 3, 4, 5, 6,
+ 6, 7, 3, 3, 8, 8
} ;
-static yyconst flex_int16_t yy_base[125] =
+static yyconst flex_int16_t yy_base[136] =
{ 0,
- 0, 9, 23, 21, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 36, 16, 28, 50, 56, 54, 0,
- 69, 75, 172, 252, 59, 252, 168, 0, 23, 252,
- 63, 252, 252, 79, 75, 93, 252, 167, 252, 162,
- 252, 99, 103, 82, 161, 252, 160, 252, 107, 252,
- 159, 107, 117, 0, 105, 252, 120, 252, 150, 121,
- 125, 128, 252, 0, 0, 252, 149, 129, 132, 145,
- 0, 0, 252, 137, 113, 252, 252, 105, 155, 252,
- 95, 0, 157, 165, 83, 252, 252, 137, 252, 252,
- 77, 134, 0, 0, 0, 135, 252, 252, 71, 147,
-
- 0, 252, 61, 173, 252, 52, 252, 25, 252, 14,
- 252, 183, 189, 195, 201, 207, 210, 215, 221, 227,
- 233, 238, 240, 245
+ 0, 10, 25, 23, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 39, 17, 30, 54, 60, 58, 66,
+ 82, 88, 194, 297, 16, 297, 190, 0, 25, 58,
+ 297, 67, 297, 297, 92, 67, 107, 297, 189, 297,
+ 188, 297, 113, 117, 69, 183, 297, 182, 297, 91,
+ 297, 181, 95, 132, 0, 95, 297, 121, 297, 180,
+ 121, 137, 140, 297, 0, 0, 166, 297, 174, 125,
+ 144, 158, 0, 0, 297, 149, 141, 297, 297, 134,
+ 168, 297, 119, 0, 170, 178, 109, 297, 297, 143,
+ 297, 297, 103, 127, 0, 0, 0, 141, 297, 297,
+
+ 84, 152, 0, 147, 297, 77, 186, 297, 69, 297,
+ 62, 297, 56, 25, 153, 18, 155, 165, 297, 196,
+ 204, 212, 220, 228, 233, 240, 248, 256, 264, 271,
+ 275, 282, 285, 287, 289
} ;
-static yyconst flex_int16_t yy_def[125] =
+static yyconst flex_int16_t yy_def[136] =
{ 0,
- 111, 1, 1, 3, 112, 112, 112, 112, 112, 112,
- 112, 112, 112, 111, 113, 113, 114, 115, 112, 19,
- 116, 116, 111, 111, 111, 111, 111, 117, 117, 111,
- 118, 111, 111, 111, 34, 111, 111, 111, 111, 119,
- 111, 120, 120, 43, 121, 111, 121, 111, 111, 111,
- 111, 122, 122, 123, 123, 111, 111, 111, 111, 124,
- 124, 111, 111, 117, 29, 111, 111, 118, 111, 117,
- 35, 36, 111, 111, 119, 111, 111, 119, 120, 111,
- 119, 43, 43, 79, 121, 111, 111, 111, 111, 111,
- 111, 122, 53, 123, 55, 111, 111, 111, 111, 124,
-
- 61, 111, 111, 111, 111, 111, 111, 119, 111, 119,
- 0, 111, 111, 111, 111, 111, 111, 111, 111, 111,
- 111, 111, 111, 111
+ 119, 1, 1, 3, 120, 120, 120, 120, 120, 120,
+ 120, 120, 120, 119, 121, 121, 122, 123, 120, 120,
+ 124, 124, 119, 119, 119, 119, 119, 125, 125, 119,
+ 119, 126, 119, 119, 119, 35, 119, 119, 119, 119,
+ 127, 119, 128, 128, 44, 129, 119, 129, 119, 119,
+ 119, 119, 130, 130, 131, 131, 119, 119, 119, 119,
+ 132, 132, 119, 119, 125, 29, 133, 119, 119, 126,
+ 119, 125, 36, 37, 119, 119, 127, 119, 119, 127,
+ 128, 119, 127, 44, 44, 81, 129, 119, 119, 119,
+ 119, 119, 119, 130, 54, 131, 56, 119, 119, 119,
+
+ 119, 132, 62, 119, 119, 119, 119, 119, 119, 119,
+ 127, 119, 127, 134, 119, 135, 119, 119, 0, 119,
+ 119, 119, 119, 119, 119, 119, 119, 119, 119, 119,
+ 119, 119, 119, 119, 119
} ;
-static yyconst flex_int16_t yy_nxt[268] =
+static yyconst flex_int16_t yy_nxt[314] =
{ 0,
24, 25, 26, 27, 24, 25, 24, 28, 24, 29,
- 29, 24, 24, 28, 28, 30, 109, 31, 46, 47,
- 32, 33, 34, 35, 36, 37, 38, 107, 36, 31,
- 46, 47, 65, 65, 34, 35, 40, 40, 41, 40,
- 42, 42, 42, 42, 43, 42, 42, 42, 42, 44,
- 43, 49, 50, 51, 105, 49, 48, 49, 50, 51,
- 62, 53, 54, 102, 62, 66, 67, 55, 54, 56,
- 57, 58, 59, 98, 61, 56, 57, 58, 59, 90,
- 61, 66, 67, 68, 64, 86, 64, 69, 70, 64,
- 83, 84, 71, 71, 72, 73, 74, 80, 72, 75,
-
- 75, 77, 78, 75, 75, 80, 81, 77, 88, 90,
- 91, 82, 88, 95, 96, 76, 82, 82, 88, 90,
- 91, 88, 93, 98, 99, 88, 88, 98, 99, 62,
- 101, 66, 67, 62, 102, 103, 90, 91, 88, 73,
- 69, 104, 88, 96, 96, 68, 68, 105, 106, 98,
- 99, 66, 97, 104, 70, 75, 75, 77, 78, 107,
- 108, 89, 87, 86, 76, 83, 84, 109, 110, 73,
- 63, 111, 111, 84, 84, 105, 106, 111, 111, 111,
- 111, 104, 104, 39, 39, 39, 39, 39, 39, 45,
- 45, 45, 45, 45, 45, 48, 48, 48, 48, 48,
-
- 48, 52, 52, 52, 52, 52, 52, 60, 60, 60,
- 60, 60, 60, 64, 111, 64, 68, 111, 111, 68,
- 68, 75, 75, 75, 75, 75, 75, 79, 79, 79,
- 79, 79, 79, 85, 85, 85, 85, 85, 85, 92,
- 92, 92, 92, 92, 94, 94, 100, 100, 100, 100,
- 100, 23, 111, 111, 111, 111, 111, 111, 111, 111,
- 111, 111, 111, 111, 111, 111, 111
+ 29, 30, 24, 24, 28, 28, 31, 63, 32, 47,
+ 48, 63, 33, 34, 35, 36, 37, 38, 39, 117,
+ 37, 32, 47, 48, 66, 66, 115, 35, 36, 41,
+ 41, 42, 41, 43, 43, 43, 43, 44, 43, 43,
+ 43, 43, 43, 45, 44, 50, 51, 52, 112, 50,
+ 49, 50, 51, 52, 110, 54, 55, 67, 67, 68,
+ 69, 108, 56, 55, 55, 70, 65, 85, 86, 105,
+ 56, 55, 57, 58, 59, 60, 100, 62, 57, 58,
+ 59, 60, 90, 62, 68, 69, 90, 92, 93, 65,
+
+ 71, 72, 65, 97, 98, 92, 73, 73, 74, 75,
+ 76, 88, 74, 77, 77, 79, 80, 77, 77, 82,
+ 83, 82, 90, 100, 101, 84, 90, 68, 69, 92,
+ 93, 84, 84, 90, 92, 93, 79, 95, 90, 100,
+ 101, 63, 103, 78, 90, 63, 105, 106, 90, 98,
+ 98, 75, 71, 107, 100, 101, 114, 114, 70, 70,
+ 108, 109, 116, 116, 118, 118, 107, 72, 77, 77,
+ 79, 80, 110, 111, 118, 118, 68, 104, 85, 86,
+ 112, 113, 99, 91, 89, 88, 86, 86, 108, 109,
+ 78, 75, 64, 119, 107, 107, 40, 40, 40, 40,
+
+ 40, 40, 40, 40, 46, 46, 46, 46, 46, 46,
+ 46, 46, 49, 49, 49, 49, 49, 49, 49, 49,
+ 53, 53, 53, 53, 53, 53, 53, 53, 61, 61,
+ 61, 61, 61, 61, 61, 61, 65, 119, 65, 119,
+ 65, 70, 119, 119, 70, 119, 119, 70, 77, 77,
+ 77, 77, 77, 77, 77, 77, 81, 81, 81, 81,
+ 81, 81, 81, 81, 87, 87, 87, 87, 87, 87,
+ 87, 87, 94, 94, 94, 94, 94, 94, 94, 96,
+ 119, 119, 96, 102, 102, 102, 102, 102, 102, 102,
+ 67, 67, 114, 114, 116, 116, 23, 119, 119, 119,
+
+ 119, 119, 119, 119, 119, 119, 119, 119, 119, 119,
+ 119, 119, 119
} ;
-static yyconst flex_int16_t yy_chk[268] =
+static yyconst flex_int16_t yy_chk[314] =
{ 0,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 2, 110, 2, 15, 15,
- 2, 2, 2, 2, 3, 3, 3, 108, 3, 4,
- 16, 16, 29, 29, 4, 4, 14, 14, 14, 14,
+ 1, 1, 1, 1, 1, 1, 2, 25, 2, 15,
+ 15, 25, 2, 2, 2, 2, 3, 3, 3, 116,
+ 3, 4, 16, 16, 29, 29, 114, 4, 4, 14,
14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
- 14, 17, 17, 17, 106, 17, 18, 18, 18, 18,
- 25, 18, 19, 103, 25, 31, 31, 19, 19, 21,
- 21, 21, 21, 99, 21, 22, 22, 22, 22, 91,
- 22, 34, 34, 35, 35, 85, 34, 34, 34, 34,
- 44, 44, 34, 34, 36, 36, 36, 81, 36, 42,
-
- 42, 42, 42, 43, 43, 43, 43, 78, 49, 52,
- 52, 43, 49, 55, 55, 75, 43, 43, 53, 53,
- 53, 57, 53, 60, 60, 57, 61, 61, 61, 62,
- 61, 68, 68, 62, 69, 69, 92, 92, 88, 74,
- 69, 69, 88, 96, 96, 69, 69, 70, 70, 100,
- 100, 67, 59, 70, 70, 79, 79, 79, 79, 83,
- 83, 51, 47, 45, 40, 83, 83, 84, 84, 38,
- 27, 23, 0, 84, 84, 104, 104, 0, 0, 0,
- 0, 104, 104, 112, 112, 112, 112, 112, 112, 113,
- 113, 113, 113, 113, 113, 114, 114, 114, 114, 114,
-
- 114, 115, 115, 115, 115, 115, 115, 116, 116, 116,
- 116, 116, 116, 117, 0, 117, 118, 0, 0, 118,
- 118, 119, 119, 119, 119, 119, 119, 120, 120, 120,
- 120, 120, 120, 121, 121, 121, 121, 121, 121, 122,
- 122, 122, 122, 122, 123, 123, 124, 124, 124, 124,
- 124, 111, 111, 111, 111, 111, 111, 111, 111, 111,
- 111, 111, 111, 111, 111, 111, 111
+ 14, 14, 14, 14, 14, 17, 17, 17, 113, 17,
+ 18, 18, 18, 18, 111, 18, 19, 30, 30, 32,
+ 32, 109, 19, 19, 20, 36, 36, 45, 45, 106,
+ 20, 20, 21, 21, 21, 21, 101, 21, 22, 22,
+ 22, 22, 50, 22, 35, 35, 50, 53, 53, 35,
+
+ 35, 35, 35, 56, 56, 93, 35, 35, 37, 37,
+ 37, 87, 37, 43, 43, 43, 43, 44, 44, 44,
+ 44, 83, 58, 61, 61, 44, 58, 70, 70, 94,
+ 94, 44, 44, 54, 54, 54, 80, 54, 62, 62,
+ 62, 63, 62, 77, 90, 63, 71, 71, 90, 98,
+ 98, 76, 71, 71, 102, 102, 104, 104, 71, 71,
+ 72, 72, 115, 115, 117, 117, 72, 72, 81, 81,
+ 81, 81, 85, 85, 118, 118, 69, 67, 85, 85,
+ 86, 86, 60, 52, 48, 46, 86, 86, 107, 107,
+ 41, 39, 27, 23, 107, 107, 120, 120, 120, 120,
+
+ 120, 120, 120, 120, 121, 121, 121, 121, 121, 121,
+ 121, 121, 122, 122, 122, 122, 122, 122, 122, 122,
+ 123, 123, 123, 123, 123, 123, 123, 123, 124, 124,
+ 124, 124, 124, 124, 124, 124, 125, 0, 125, 0,
+ 125, 126, 0, 0, 126, 0, 0, 126, 127, 127,
+ 127, 127, 127, 127, 127, 127, 128, 128, 128, 128,
+ 128, 128, 128, 128, 129, 129, 129, 129, 129, 129,
+ 129, 129, 130, 130, 130, 130, 130, 130, 130, 131,
+ 0, 0, 131, 132, 132, 132, 132, 132, 132, 132,
+ 133, 133, 134, 134, 135, 135, 119, 119, 119, 119,
+
+ 119, 119, 119, 119, 119, 119, 119, 119, 119, 119,
+ 119, 119, 119
} ;
/* Table of booleans, true if rule could match eol. */
-static yyconst flex_int32_t yy_rule_can_match_eol[28] =
+static yyconst flex_int32_t yy_rule_can_match_eol[29] =
{ 0,
-0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0,
- 1, 1, 0, 1, 1, 0, 1, 0, };
+0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1,
+ 0, 1, 1, 0, 1, 1, 0, 1, 0, };
#define YY_TRAILING_MASK 0x2000
#define YY_TRAILING_HEAD_MASK 0x4000
@@ -609,15 +623,9 @@ goto find_rule; \
#define YYSTYPE FASTQToken
/* code to populate token with internal values */
- #define YY_USER_ACTION \
- yylval -> tokenText = yytext; \
- yylval -> tokenLength = yyleng; \
- yylval -> line_no = yylineno; \
- yylval -> column_no = yyextra -> column; \
- yyextra -> column += yyleng; \
- yyextra -> length += yyleng; \
- yyextra -> lastToken = yylval;
-
+ static void ConsumeToken(FASTQToken* token, FASTQParseBlock* pb);
+ #define YY_USER_ACTION ConsumeToken(yylval, yyextra);
+
#define ENDLINE \
yyextra -> column=1;\
return fqENDLINE;
@@ -953,14 +961,14 @@ yy_match:
while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
{
yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 112 )
+ if ( yy_current_state >= 120 )
yy_c = yy_meta[(unsigned int) yy_c];
}
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
*yyg->yy_state_ptr++ = yy_current_state;
++yy_cp;
}
- while ( yy_current_state != 111 );
+ while ( yy_current_state != 119 );
yy_find_action:
yy_current_state = *--yyg->yy_state_ptr;
@@ -1034,53 +1042,57 @@ YY_RULE_SETUP
case 4:
YY_RULE_SETUP
-{ return fqNUMBER; }
+{ return fqCOORDS; }
YY_BREAK
case 5:
YY_RULE_SETUP
-{ return fqALPHANUM; }
+{ return fqNUMBER; }
YY_BREAK
case 6:
YY_RULE_SETUP
-{ return fqWS; }
+{ return fqALPHANUM; }
YY_BREAK
case 7:
-/* rule 7 can match eol */
YY_RULE_SETUP
-{ return fqBASESEQ; }
+{ return fqWS; }
YY_BREAK
case 8:
/* rule 8 can match eol */
YY_RULE_SETUP
-{ return fqCOLORSEQ; }
+{ return fqBASESEQ; }
YY_BREAK
case 9:
+/* rule 9 can match eol */
YY_RULE_SETUP
-{ return yytext[0]; }
+{ return fqCOLORSEQ; }
YY_BREAK
-
case 10:
-/* rule 10 can match eol */
YY_RULE_SETUP
-{ BEGIN IN_SEQUENCE; ENDLINE; }
+{ return yytext[0]; }
YY_BREAK
case 11:
/* rule 11 can match eol */
YY_RULE_SETUP
-{ BEGIN 0; return fqBASESEQ; }
+{ BEGIN IN_SEQUENCE; ENDLINE; }
YY_BREAK
+
case 12:
/* rule 12 can match eol */
YY_RULE_SETUP
-{ BEGIN 0; return fqCOLORSEQ; }
+{ BEGIN 0; return fqBASESEQ; }
YY_BREAK
case 13:
/* rule 13 can match eol */
YY_RULE_SETUP
-{ BEGIN 0; return fqASCQUAL; }
+{ BEGIN 0; return fqCOLORSEQ; }
YY_BREAK
case 14:
+/* rule 14 can match eol */
+YY_RULE_SETUP
+{ BEGIN 0; return fqASCQUAL; }
+ YY_BREAK
+case 15:
*yy_cp = yyg->yy_hold_char; /* undo effects of setting up yytext */
yyg->yy_c_buf_p = yy_cp -= 1;
YY_DO_BEFORE_ACTION; /* set up yytext again */
@@ -1088,40 +1100,40 @@ YY_RULE_SETUP
{ BEGIN 0; return fqUNRECOGNIZED; }
YY_BREAK
-case 15:
+case 16:
YY_RULE_SETUP
{ BEGIN 0; return fqBASESEQ; }
YY_BREAK
-case 16:
+case 17:
YY_RULE_SETUP
{ BEGIN 0; return fqCOLORSEQ; }
YY_BREAK
-case 17:
+case 18:
*yy_cp = yyg->yy_hold_char; /* undo effects of setting up yytext */
yyg->yy_c_buf_p = yy_cp -= 1;
YY_DO_BEFORE_ACTION; /* set up yytext again */
YY_RULE_SETUP
{ return fqTOKEN; /* do not bother to parse the inside of the line */ }
YY_BREAK
-case 18:
-/* rule 18 can match eol */
+case 19:
+/* rule 19 can match eol */
YY_RULE_SETUP
{ BEGIN IN_QUALITY; ENDLINE }
YY_BREAK
-case 19:
+case 20:
YY_RULE_SETUP
{ }
YY_BREAK
-case 20:
-/* rule 20 can match eol */
+case 21:
+/* rule 21 can match eol */
YY_RULE_SETUP
{ return fqASCQUAL; }
YY_BREAK
-case 21:
-/* rule 21 can match eol */
+case 22:
+/* rule 22 can match eol */
YY_RULE_SETUP
{ /* if read was split across several lines, expect the same number of lines in quality */
if (yyextra->expectedQualityLines <= 1)
@@ -1131,32 +1143,32 @@ YY_RULE_SETUP
ENDLINE;
}
YY_BREAK
-case 22:
+case 23:
YY_RULE_SETUP
{ return yytext[0]; }
YY_BREAK
-case 23:
-/* rule 23 can match eol */
+case 24:
+/* rule 24 can match eol */
YY_RULE_SETUP
{ return fqASCQUAL; }
YY_BREAK
-case 24:
-/* rule 24 can match eol */
+case 25:
+/* rule 25 can match eol */
YY_RULE_SETUP
{ BEGIN 0; ENDLINE; }
YY_BREAK
-case 25:
+case 26:
YY_RULE_SETUP
{ return yytext[0]; }
YY_BREAK
-case 26:
-/* rule 26 can match eol */
+case 27:
+/* rule 27 can match eol */
YY_RULE_SETUP
{ ENDLINE; }
YY_BREAK
-case 27:
+case 28:
YY_RULE_SETUP
ECHO;
YY_BREAK
@@ -1433,7 +1445,7 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
{
yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 112 )
+ if ( yy_current_state >= 120 )
yy_c = yy_meta[(unsigned int) yy_c];
}
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
@@ -1457,11 +1469,11 @@ static int yy_get_next_buffer (yyscan_t yyscanner)
while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
{
yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 112 )
+ if ( yy_current_state >= 120 )
yy_c = yy_meta[(unsigned int) yy_c];
}
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
- yy_is_jam = (yy_current_state == 111);
+ yy_is_jam = (yy_current_state == 119);
if ( ! yy_is_jam )
*yyg->yy_state_ptr++ = yy_current_state;
@@ -2370,14 +2382,7 @@ rc_t CC FASTQScan_yylex_init(FASTQParseBlock* sb, bool debug)
sb->lastToken = NULL;
sb->record = NULL;
sb->column = 1;
- KDataBufferMakeBytes( &sb->tagLine, 1024);
-
- sb->spotNameLength = 0;
- sb->spotNameDone = false;
- sb->spotGroupOffset = 0;
- sb->spotGroupLength = 0;
-
- KDataBufferMakeBytes( &sb->quality, 1024);
+
sb->expectedQualityLines = 0;
FASTQ_set_debug(debug ? 1 : 0,sb->scanner);
@@ -2389,8 +2394,6 @@ rc_t CC FASTQScan_yylex_init(FASTQParseBlock* sb, bool debug)
void CC FASTQScan_yylex_destroy(FASTQParseBlock* sb)
{
- KDataBufferWhack( & sb->tagLine);
- KDataBufferWhack( & sb->quality);
if (sb->scanner)
{
FASTQ_lex_destroy(sb->scanner);
@@ -2416,10 +2419,11 @@ void CC FASTQ_unlex(FASTQParseBlock* pb, FASTQToken* token)
struct yyguts_t* yyg = (struct yyguts_t*)pb->scanner;
for (i = 0; i < token->tokenLength; ++i)
{
- yyunput(token->tokenText[token->tokenLength-1-i], yyg->yytext_r, pb->scanner);
+ yyunput(TokenTextPtr(pb, token)[token->tokenLength - 1 - i], yyg->yytext_r, pb->scanner);
}
yyextra -> column -= token->tokenLength;
yyextra -> length -= token->tokenLength;
+ KDataBufferResize( & pb->record->source, KDataBufferBytes( & pb->record->source ) - token->tokenLength );
}
void FASTQ_fatal_error(yyconst char* msg)
@@ -2431,3 +2435,20 @@ void FASTQ_fatal_error(yyconst char* msg)
LogErr(klogErr, rc, msg);
exit(rc);
}
+
+void ConsumeToken(FASTQToken* token, FASTQParseBlock* pb)
+{
+ struct yyguts_t* yyg = (struct yyguts_t*)pb->scanner;
+
+ token -> tokenStart = KDataBufferBytes( & pb->record->source );
+ token -> tokenLength = yyleng;
+ token -> line_no = yylineno;
+ token -> column_no = pb -> column;
+
+ KDataBufferResize( & pb->record->source, KDataBufferBytes( & pb->record->source ) + token->tokenLength );
+ strncpy((char*)TokenTextPtr(pb, token), yytext, token->tokenLength);
+
+ pb -> column += token->tokenLength;
+ pb -> length += token->tokenLength;
+ pb -> lastToken = token;
+}
diff --git a/tools/fastq-loader/fastq-loader.c b/tools/fastq-loader/fastq-loader.c
index 0cccd6d..45754b3 100644
--- a/tools/fastq-loader/fastq-loader.c
+++ b/tools/fastq-loader/fastq-loader.c
@@ -285,8 +285,8 @@ rc_t CC KMain (int argc, char * argv[])
char *files[256];
int8_t defaultReadNumbers[256];
char *name_buffer = NULL;
- unsigned next_name = 0;
- unsigned nbsz = 0;
+ size_t next_name = 0;
+ size_t nbsz = 0;
char const *value;
char *dummy;
const XMLLogger* xml_logger = NULL;
@@ -484,7 +484,7 @@ rc_t CC KMain (int argc, char * argv[])
break;
}
else {
- unsigned need = G.inpath ? (strlen(G.inpath) + 1) * pcount : 0;
+ size_t need = G.inpath ? (strlen(G.inpath) + 1) * pcount : 0;
unsigned i;
for (i = 0; i < pcount; ++i) {
diff --git a/tools/fastq-loader/fastq-parse.h b/tools/fastq-loader/fastq-parse.h
index bce7ee6..3ec93eb 100644
--- a/tools/fastq-loader/fastq-parse.h
+++ b/tools/fastq-loader/fastq-parse.h
@@ -38,7 +38,7 @@ extern "C" {
/* values used in validating quality lines */
#define MIN_PHRED_33 33
-#define MAX_PHRED_33 74
+#define MAX_PHRED_33 126
#define MIN_PHRED_64 64
#define MAX_PHRED_64 127
@@ -60,7 +60,9 @@ struct FastqSequence
int32_t coords[16];
#endif
- char* read;
+ /* read bases */
+ String read;
+
bool is_colorspace;
String quality;
@@ -80,12 +82,16 @@ struct FastqRecord
typedef struct FASTQToken
{
- const char* tokenText;
+ size_t tokenStart; /* offset into FASTQParseBlock.record->source */
size_t tokenLength;
size_t line_no;
size_t column_no;
} FASTQToken;
+/* obtain a pointer to the token's text */
+#define TokenTextPtr(pb, token) ((const char*)((pb)->record->source.base) + (token)->tokenStart)
+
+
typedef struct FASTQParseBlock
{
void* self;
@@ -99,40 +105,52 @@ typedef struct FASTQParseBlock
struct FastqRecord* record;
size_t column;
- /* temporaries for bison: */
- KDataBuffer tagLine;
-
- size_t spotNameLength;
+ /* temporaries for bison */
+ /* all offsets are into record->source */
+ size_t spotNameOffset;
+ size_t spotNameLength;
bool spotNameDone;
size_t spotGroupOffset;
size_t spotGroupLength;
+ size_t readOffset;
+ size_t readLength;
+ size_t qualityOffset;
+ size_t qualityLength;
- KDataBuffer quality;
size_t expectedQualityLines;
int8_t defaultReadNumber; /* -1: never assign read numbers */
+
+ /* Secondary (>1) read number observed previously (usually 2, sometimes 3).
+ Once one is seen, do not allow any other values in the same input file.
+ 0 = has not seen one yet in this input.
+ Always record as 2 */
+ uint8_t secondaryReadNumber;
bool fatalError;
} FASTQParseBlock;
-extern rc_t CC FASTQScan_yylex_init(FASTQParseBlock* context, bool debug);
-extern void CC FASTQScan_yylex_destroy(FASTQParseBlock* context);
+extern rc_t FASTQScan_yylex_init(FASTQParseBlock* context, bool debug);
+extern void FASTQScan_yylex_destroy(FASTQParseBlock* context);
/* explicit FLEX state control for bison*/
-extern void CC FASTQScan_inline_sequence(FASTQParseBlock* pb);
-extern void CC FASTQScan_inline_quality(FASTQParseBlock* pb);
+extern void FASTQScan_inline_sequence(FASTQParseBlock* pb);
+extern void FASTQScan_inline_quality(FASTQParseBlock* pb);
-extern void CC FASTQ_set_lineno (int line_number, void* scanner);
+extern void FASTQ_set_lineno (int line_number, void* scanner);
-extern int CC FASTQ_lex(FASTQToken* pb, void * scanner);
-extern void CC FASTQ_unlex(FASTQParseBlock* pb, FASTQToken* token);
-extern void CC FASTQ_qualityContext(FASTQParseBlock* pb);
+extern int FASTQ_lex(FASTQToken* pb, void * scanner);
+extern void FASTQ_unlex(FASTQParseBlock* pb, FASTQToken* token);
+extern void FASTQ_qualityContext(FASTQParseBlock* pb);
extern int FASTQ_debug; /* set to 1 to print Bison trace */
-extern int CC FASTQ_parse(FASTQParseBlock* pb); /* 0 = end of input, 1 = success, a new record is in context->record, 2 - syntax error */
+extern int FASTQ_parse(FASTQParseBlock* pb); /* 0 = end of input, 1 = success, a new record is in context->record, 2 - syntax error */
+
+/* call before parsing every record (FASTQ_parse does so internally; this is for testing the parser) */
+extern void FASTQ_ParseBlockInit(FASTQParseBlock* pb);
-extern void CC FASTQ_error(FASTQParseBlock* pb, const char* msg);
+extern void FASTQ_error(FASTQParseBlock* pb, const char* msg);
#ifdef __cplusplus
}
diff --git a/tools/fastq-loader/fastq-reader.c b/tools/fastq-loader/fastq-reader.c
index c64d389..6b5e0f2 100644
--- a/tools/fastq-loader/fastq-reader.c
+++ b/tools/fastq-loader/fastq-reader.c
@@ -83,8 +83,6 @@ static rc_t FastqRecordWhack( const FastqRecord* cself )
FastqRecord* self = (FastqRecord*)cself;
assert(self);
- free((void*)self->seq.read);
-
rc = KDataBufferWhack( & self->source );
if (rc)
@@ -221,8 +219,7 @@ FastqSequenceInit(FastqSequence* self)
StringInit(&self->spotname, 0, 0, 0);
StringInit(&self->spotgroup, 0, 0, 0);
self->readnumber = 0;
-
- self->read = 0;
+ StringInit(&self->read, 0, 0, 0);
self->is_colorspace = false;
StringInit(&self->quality, 0, 0, 0);
self->qualityOffset = 0;
@@ -270,13 +267,13 @@ static rc_t FastqSequenceRelease( const FastqSequence* self )
static rc_t FastqSequenceGetReadLength ( const FastqSequence *self, uint32_t *length )
{
assert(self);
- if ( self->read == NULL || self->is_colorspace )
+ if ( self->is_colorspace )
{
*length = 0;
}
else
{
- *length = string_measure(self->read, NULL);
+ *length = self->read.len;
}
return 0;
}
@@ -285,11 +282,8 @@ static rc_t FastqSequenceGetRead ( const FastqSequence *self, char *sequence )
{
assert(self);
assert(sequence);
- if ( self->read != NULL && !self->is_colorspace )
- {
- uint32_t length = string_measure(self->read, NULL);
- string_copy(sequence, length, self->read, length);
- }
+ if ( !self->is_colorspace )
+ string_copy(sequence, self->read.len, self->read.addr, self->read.len);
return 0;
}
@@ -297,18 +291,18 @@ static rc_t FastqSequenceGetRead2 ( const FastqSequence *self, char *sequence, u
{
assert(self);
assert(sequence);
- if ( self->read == NULL || self->is_colorspace )
+ if ( self->is_colorspace )
{
return RC( RC_MODULE, rcData, rcAccessing, rcItem, rcEmpty );
}
else
{
- uint32_t length = string_measure(self->read, NULL);
+ uint32_t length = self->read.len;
if (start >= length || stop >= length || start >= stop)
{
return RC( RC_MODULE, rcData, rcAccessing, rcRange, rcInvalid);
}
- string_copy(sequence, stop - start, self->read + start, stop - start);
+ string_copy(sequence, stop - start, self->read.addr + start, stop - start);
}
return 0;
}
@@ -322,7 +316,7 @@ static rc_t FastqSequenceGetQuality ( const FastqSequence *self, const int8_t **
*quality = NULL;
if ( self->quality.size != 0)
{
- uint32_t length = string_measure(self->read, NULL);
+ uint32_t length = self->read.len;
if (self->quality.size != length)
return RC(rcAlign, rcRow, rcReading, rcData, rcInconsistent);
@@ -366,21 +360,15 @@ static rc_t FastqSequenceGetCSKey ( const FastqSequence *self, char cskey[1] )
{
assert(self);
if (self->is_colorspace)
- cskey[0] = self->read[0];
+ cskey[0] = self->read.addr[0];
return 0;
}
static rc_t FastqSequenceGetCSReadLength ( const FastqSequence *self, uint32_t *length )
{
assert(self);
- if ( self->read == NULL )
- {
- *length = 0;
- }
- else if (self->is_colorspace)
- {
- *length = string_measure(self->read + 1, NULL);
- }
+ if (self->is_colorspace)
+ *length = self->read.len - 1;
return 0;
}
@@ -388,11 +376,8 @@ static rc_t FastqSequenceGetCSRead ( const FastqSequence *self, char *sequence )
{
assert(self);
assert(sequence);
- if ( self->read != NULL && self->is_colorspace )
- {
- uint32_t length = string_measure(self->read + 1, NULL);
- string_copy(sequence, length, self->read + 1, length);
- }
+ if ( self->is_colorspace )
+ string_copy(sequence, self->read.len - 1, self->read.addr + 1, self->read.len - 1);
return 0;
}
@@ -513,6 +498,20 @@ rc_t FastqReaderFileWhack( FastqReaderFile* f )
return 0;
}
+void FASTQ_ParseBlockInit ( FASTQParseBlock* pb )
+{
+ pb->length = 0;
+ pb->spotNameOffset = 0;
+ pb->spotNameLength = 0;
+ pb->spotNameDone = false;
+ pb->spotGroupOffset = 0;
+ pb->spotGroupLength = 0;
+ pb->readOffset = 0;
+ pb->readLength = 0;
+ pb->qualityOffset = 0;
+ pb->qualityLength = 0;
+}
+
rc_t FastqReaderFileGetRecord ( const FastqReaderFile *f, const Record** result )
{
rc_t rc;
@@ -531,18 +530,15 @@ rc_t FastqReaderFileGetRecord ( const FastqReaderFile *f, const Record** result
if (rc != 0)
return rc;
- self->pb.length = 0;
- KDataBufferResize( & self->pb.tagLine, 0 );
- KDataBufferResize( & self->pb.quality, 0 );
- self->pb.spotNameDone = false;
-
+ FASTQ_ParseBlockInit( & self->pb );
+
if ( FASTQ_parse( & self->pb ) == 0 && self->pb.record->rej == 0 )
{ /* normal end of input */
RecordRelease((const Record*)self->pb.record);
*result = 0;
return 0;
}
-
+
/*TODO: remove? compensate for an artificially inserted trailing \n */
if ( self->eolInserted )
{
@@ -552,7 +548,7 @@ rc_t FastqReaderFileGetRecord ( const FastqReaderFile *f, const Record** result
if (self->pb.record->rej != 0) /* had error(s) */
{ /* save the complete raw source in the Rejected object */
- StringInit(& self->pb.record->rej->source, string_dup(self->recordStart, self->pb.length), self->pb.length, self->pb.length);
+ StringInit(& self->pb.record->rej->source, string_dup(self->recordStart, self->pb.length), self->pb.length, (uint32_t)self->pb.length);
self->pb.record->rej->fatal = self->pb.fatalError;
}
@@ -567,9 +563,10 @@ rc_t FastqReaderFileGetRecord ( const FastqReaderFile *f, const Record** result
self->curPos -= self->pb.length;
}
- StringInit( & self->pb.record->seq.spotname, (const char*)self->pb.tagLine.base, self->pb.spotNameLength, self->pb.spotNameLength);
- StringInit( & self->pb.record->seq.spotgroup, (const char*)self->pb.tagLine.base + self->pb.spotGroupOffset, self->pb.spotGroupLength, self->pb.spotGroupLength);
- StringInit( & self->pb.record->seq.quality, (const char*)self->pb.quality.base, self->pb.quality.elem_count, self->pb.quality.elem_count);
+ StringInit( & self->pb.record->seq.spotname, (const char*)self->pb.record->source.base + self->pb.spotNameOffset, self->pb.spotNameLength, (uint32_t)self->pb.spotNameLength);
+ StringInit( & self->pb.record->seq.spotgroup, (const char*)self->pb.record->source.base + self->pb.spotGroupOffset, self->pb.spotGroupLength, (uint32_t)self->pb.spotGroupLength);
+ StringInit( & self->pb.record->seq.read, (const char*)self->pb.record->source.base + self->pb.readOffset, self->pb.readLength, (uint32_t)self->pb.readLength);
+ StringInit( & self->pb.record->seq.quality, (const char*)self->pb.record->source.base + self->pb.qualityOffset, self->pb.qualityLength, (uint32_t)self->pb.qualityLength);
self->pb.record->seq.qualityOffset = self->pb.phredOffset;
if (self->pb.record->seq.readnumber == 0)
@@ -624,8 +621,10 @@ size_t CC FASTQ_input(FASTQParseBlock* pb, char* buf, size_t max_size)
}
memcpy(buf, self->recordStart + self->curPos, length);
+
self->lastEol = ( buf[length-1] == '\n' );
self->curPos += length;
+
return length;
}
@@ -671,8 +670,9 @@ rc_t CC FastqReaderFileMake( const ReaderFile **reader, const KDirectory* dir, c
if a value below MIN_PHRED_64 seen, abort
*/
self->pb.defaultReadNumber = defaultReadNumber;
+ self->pb.secondaryReadNumber = 0;
- rc = FASTQScan_yylex_init(& self->pb, true);
+ rc = FASTQScan_yylex_init(& self->pb, false);
if (rc == 0)
{
*reader = (const ReaderFile *) self;
diff --git a/tools/fastq-loader/fastq-tokens.h b/tools/fastq-loader/fastq-tokens.h
index bcb059d..3b6ea48 100644
--- a/tools/fastq-loader/fastq-tokens.h
+++ b/tools/fastq-loader/fastq-tokens.h
@@ -46,7 +46,8 @@
fqCOLORSEQ = 263,
fqTOKEN = 264,
fqASCQUAL = 265,
- fqUNRECOGNIZED = 266
+ fqCOORDS = 266,
+ fqUNRECOGNIZED = 267
};
#endif
diff --git a/tools/fastq-loader/latf-load.vers b/tools/fastq-loader/latf-load.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/fastq-loader/latf-load.vers
+++ b/tools/fastq-loader/latf-load.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/kar/kar.vers b/tools/kar/kar.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/kar/kar.vers
+++ b/tools/kar/kar.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/kar/sra-kar.vers b/tools/kar/sra-kar.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/kar/sra-kar.vers
+++ b/tools/kar/sra-kar.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/nenctool/Makefile b/tools/nenctool/Makefile
index f6a51c8..0d9833a 100644
--- a/tools/nenctool/Makefile
+++ b/tools/nenctool/Makefile
@@ -88,7 +88,7 @@ NENCTOOL_OBJ = \
NENCTOOL_LIB = \
-lkapp \
-lvfs \
- -lkurl \
+ -lkns \
-lkrypto \
-lkfg \
-lkfs \
@@ -112,7 +112,7 @@ NENCTEST_OBJ = \
NENCTEST_LIB = \
-lkapp \
-lvfs \
- -lkurl \
+ -lkns \
-lkryptotest \
-lkfg \
-lkfs \
diff --git a/tools/nenctool/nenctest.vers b/tools/nenctool/nenctest.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/nenctool/nenctest.vers
+++ b/tools/nenctool/nenctest.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/nenctool/nenctool.vers b/tools/nenctool/nenctool.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/nenctool/nenctool.vers
+++ b/tools/nenctool/nenctool.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/nencvalid/Makefile b/tools/nencvalid/Makefile
index a64466d..f231dab 100644
--- a/tools/nencvalid/Makefile
+++ b/tools/nencvalid/Makefile
@@ -86,7 +86,7 @@ NENCVALID_OBJ = \
NENCVALID_LIB = \
-lkapp \
-lvfs \
- -lkurl \
+ -lkns \
-lkrypto \
-lkfg \
-lkfs \
diff --git a/tools/nencvalid/nencvalid.vers b/tools/nencvalid/nencvalid.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/nencvalid/nencvalid.vers
+++ b/tools/nencvalid/nencvalid.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/prefetch/prefetch.c b/tools/prefetch/prefetch.c
index eb30e1a..3537943 100644
--- a/tools/prefetch/prefetch.c
+++ b/tools/prefetch/prefetch.c
@@ -45,7 +45,8 @@
#include <vfs/resolver.h> /* VResolver */
#include <kns/ascp.h> /* ascp_locate */
-#include <kns/curl-file.h> /* KCurlFileMake */
+#include <kns/manager.h>
+#include <kns/http.h>
#include <kfs/file.h> /* KFile */
#include <kfs/gzip.h> /* KFileMakeGzipForRead */
@@ -87,7 +88,7 @@
#define STS_DBG 2
#define STS_FIN 3
-#define USE_CURL 1
+#define USE_CURL 0
#define rcResolver rcTree
static bool NotFoundByResolver(rc_t rc) {
@@ -171,6 +172,7 @@ typedef struct {
const KRepositoryMgr *repoMgr;
const VDBManager *mgr;
VFSManager *vfsMgr;
+ KNSManager *kns;
VResolver *resolver;
@@ -262,17 +264,15 @@ bool _StringIsFasp(const String *self, const char **withoutScheme)
}
/********** KFile extension **********/
-static rc_t _KFileOpenRemote(const KFile **self, const char *path) {
+static
+rc_t _KFileOpenRemote(const KFile **self, KNSManager *kns, const char *path)
+{
rc_t rc = 0;
assert(self);
if (*self != NULL) {
return 0;
}
-#if USE_CURL
- rc = KCurlFileMake(self, path, false);
-#else
- rc = KNSManagerMakeHttpFile(kns, &file, NULL, 0x01010000, "%S", s);
-#endif
+ rc = KNSManagerMakeHttpFile(kns, self, NULL, 0x01010000, path);
return rc;
}
@@ -538,7 +538,7 @@ static rc_t _VResolverRemote(VResolver *self, VRemoteProtocols protocols,
if (vcache == NULL) {
rc = RC(rcExe, rcResolver, rcResolving, rcPath, rcNotFound);
PLOGERR(klogInt, (klogInt, rc, "cannot get cache location "
- "for $(acc). Try to cd out of protected repository.",
+ "for $(acc).", /* Try to cd out of protected repository.", */
"acc=%s" , name));
}
if (rc == 0) {
@@ -934,10 +934,11 @@ static rc_t MainDownloadFile(Resolved *self,
{
rc_t rc = 0;
KFile *out = NULL;
- uint64_t pos = 0;
size_t num_read = 0;
uint64_t opos = 0;
size_t num_writ = 0;
+ uint64_t pos = 0;
+ uint64_t prevPos = 0;
assert(self && main);
@@ -951,7 +952,7 @@ static rc_t MainDownloadFile(Resolved *self,
assert(self->remote);
if (self->file == NULL) {
- rc = _KFileOpenRemote(&self->file, self->remote->addr);
+ rc = _KFileOpenRemote(&self->file, main->kns, self->remote->addr);
if (rc != 0) {
PLOGERR(klogInt, (klogInt, rc, "failed to open file for $(path)",
"path=%s", self->remote->addr));
@@ -960,21 +961,26 @@ static rc_t MainDownloadFile(Resolved *self,
STSMSG(STS_INFO, ("%s -> %s", self->remote->addr, to));
do {
+ bool print = pos - prevPos > 200000000;
rc = Quitting();
if (rc == 0) {
- STSMSG(STS_FIN,
- ("> Reading %lu bytes from pos. %lu", main->bsize, pos));
+ if (print) {
+ STSMSG(STS_FIN,
+ ("Reading %lu bytes from pos. %lu", main->bsize, pos));
+ }
rc = KFileRead(self->file,
pos, main->buffer, main->bsize, &num_read);
if (rc != 0) {
DISP_RC2(rc, "Cannot KFileRead", self->remote->addr);
}
else {
- STSMSG(STS_FIN,
- ("< Read %lu bytes from pos. %lu", num_read, pos));
pos += num_read;
}
+
+ if (print) {
+ prevPos = pos;
+ }
}
if (rc == 0 && num_read > 0) {
@@ -1315,7 +1321,7 @@ static rc_t _ItemSetResolverAndAssessionInResolved(Item *item,
/* resolve locations */
static rc_t _ItemResolveResolved(VResolver *resolver,
VRemoteProtocols protocols, Item *item, const KRepositoryMgr *repoMgr,
- const KConfig *cfg, const VFSManager *vfs, size_t minSize, size_t maxSize)
+ const KConfig *cfg, const VFSManager *vfs, KNSManager *kns, size_t minSize, size_t maxSize)
{
Resolved *resolved = NULL;
rc_t rc = 0;
@@ -1367,7 +1373,7 @@ static rc_t _ItemResolveResolved(VResolver *resolver,
rc_t rc3 = 0;
if (resolved->file == NULL) {
rc3 = _KFileOpenRemote(&resolved->file,
- resolved->remote->addr);
+ kns, resolved->remote->addr);
DISP_RC2(rc3,
"cannot open remote file", resolved->remote->addr);
}
@@ -1405,7 +1411,7 @@ static rc_t _ItemResolveResolved(VResolver *resolver,
assert(resolved->remote);
if (!_StringIsFasp(resolved->remote, NULL)) {
rc2 = _KFileOpenRemote(
- &resolved->file, resolved->remote->addr);
+ &resolved->file, kns, resolved->remote->addr);
}
}
if (rc2 == 0 && resolved->file != NULL && resolved->remoteSz == 0) {
@@ -1422,7 +1428,7 @@ static rc_t _ItemResolveResolved(VResolver *resolver,
/* Resolved: resolve locations */
static rc_t ItemInitResolved(Item *self, VResolver *resolver,
KDirectory *dir, bool ascp, const KRepositoryMgr *repoMgr,
- const KConfig *cfg, const VFSManager *vfs, size_t minSize, size_t maxSize)
+ const KConfig *cfg, const VFSManager *vfs, KNSManager *kns, size_t minSize, size_t maxSize)
{
Resolved *resolved = NULL;
rc_t rc = 0;
@@ -1463,7 +1469,7 @@ static rc_t ItemInitResolved(Item *self, VResolver *resolver,
}
rc = _ItemResolveResolved(resolver, protocols, self,
- repoMgr, cfg, vfs, minSize, maxSize);
+ repoMgr, cfg, vfs, kns, minSize, maxSize);
STSMSG(STS_DBG, ("Resolve(%s) = %R:", resolved->name, rc));
STSMSG(STS_DBG, ("local(%s)",
@@ -1523,7 +1529,7 @@ static rc_t ItemResolve(Item *item, int32_t row) {
rc = ItemInitResolved(item, item->main->resolver, item->main->dir, ascp,
item->main->repoMgr, item->main->cfg, item->main->vfsMgr,
- item->main->minSize, item->main->maxSize);
+ item->main->kns, item->main->minSize, item->main->maxSize);
return rc;
}
@@ -2457,6 +2463,7 @@ static rc_t MainFini(Main *self) {
RELEASE(VDBManager, self->mgr);
RELEASE(KDirectory, self->dir);
RELEASE(KRepositoryMgr, self->repoMgr);
+ RELEASE(KNSManager, self->kns);
RELEASE(VFSManager, self->vfsMgr);
RELEASE(Args, self->args);
@@ -2502,6 +2509,12 @@ static rc_t MainInit(int argc, char *argv[], Main *self) {
DISP_RC(rc, "VFSManagerMake");
}
+ if ( rc == 0 )
+ {
+ rc = VFSManagerGetKNSMgr (self->vfsMgr, & self->kns);
+ DISP_RC(rc, "VFSManagerGetKNSMgr");
+ }
+
if (rc == 0) {
VResolver *resolver = NULL;
rc = VFSManagerGetResolver(self->vfsMgr, &resolver);
diff --git a/tools/prefetch/prefetch.vers b/tools/prefetch/prefetch.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/prefetch/prefetch.vers
+++ b/tools/prefetch/prefetch.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-dbcc/sra-dbcc.vers b/tools/sra-dbcc/sra-dbcc.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-dbcc/sra-dbcc.vers
+++ b/tools/sra-dbcc/sra-dbcc.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-dump/abi-dump.vers b/tools/sra-dump/abi-dump.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-dump/abi-dump.vers
+++ b/tools/sra-dump/abi-dump.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-dump/abi.c b/tools/sra-dump/abi.c
index 3cdfdcc..39e2715 100644
--- a/tools/sra-dump/abi.c
+++ b/tools/sra-dump/abi.c
@@ -260,6 +260,7 @@ rc_t AbsolidLabelerFilterFactory_NewObj(const SRASplitterFactory* cself, const S
((AbsolidLabelerFilter*)(*splitter))->keys[4].key = "F5-RNA";
((AbsolidLabelerFilter*)(*splitter))->keys[5].key = "F5-DNA";
((AbsolidLabelerFilter*)(*splitter))->keys[6].key = "F3-DNA";
+ ((AbsolidLabelerFilter*)(*splitter))->keys[7].key = "BC";
((AbsolidLabelerFilter*)(*splitter))->key_sz[0] = 2;
((AbsolidLabelerFilter*)(*splitter))->key_sz[1] = 2;
((AbsolidLabelerFilter*)(*splitter))->key_sz[2] = 5;
@@ -267,6 +268,7 @@ rc_t AbsolidLabelerFilterFactory_NewObj(const SRASplitterFactory* cself, const S
((AbsolidLabelerFilter*)(*splitter))->key_sz[4] = 6;
((AbsolidLabelerFilter*)(*splitter))->key_sz[5] = 6;
((AbsolidLabelerFilter*)(*splitter))->key_sz[6] = 6;
+ ((AbsolidLabelerFilter*)(*splitter))->key_sz[7] = 2;
}
}
return rc;
diff --git a/tools/sra-dump/core.c b/tools/sra-dump/core.c
index 63a512a..a8dbde3 100644
--- a/tools/sra-dump/core.c
+++ b/tools/sra-dump/core.c
@@ -1535,11 +1535,19 @@ rc_t CC KMain ( int argc, char* argv[] )
/* platform constands in insdc/sra.h */
switch( *platform )
{
- case SRA_PLATFORM_454 : quality_N_limit = 30; break;
+ case SRA_PLATFORM_454 : quality_N_limit = 30; nreads_max = 8; break;
case SRA_PLATFORM_ION_TORRENT : ;
- case SRA_PLATFORM_ILLUMINA : quality_N_limit = 35; break;
- case SRA_PLATFORM_ABSOLID : quality_N_limit = 25; break;
- case SRA_PLATFORM_PACBIO_SMRT : nreads_max = 32; break;
+ case SRA_PLATFORM_ILLUMINA : quality_N_limit = 35; nreads_max = 8; break;
+ case SRA_PLATFORM_ABSOLID : quality_N_limit = 25; nreads_max = 8; break;
+
+ case SRA_PLATFORM_PACBIO_SMRT : if ( fmt.split_files )
+ {
+ /* only if we split into files we limit the number of reads */
+ nreads_max = 32;
+ }
+ break;
+
+ default : nreads_max = 8; break; /* for unknown platforms */
}
}
SRAColumnRelease( c );
diff --git a/tools/sra-dump/core.h b/tools/sra-dump/core.h
index 493b1ab..079884c 100644
--- a/tools/sra-dump/core.h
+++ b/tools/sra-dump/core.h
@@ -68,6 +68,7 @@ struct SRADumperFmt
const SRATable* table;
bool gzip;
bool bzip2;
+ bool split_files; /* tell the core that the implementation splits into files... */
};
#endif /* _h_tools_dump_core */
diff --git a/tools/sra-dump/factory.c b/tools/sra-dump/factory.c
index 63897c9..96e6b95 100644
--- a/tools/sra-dump/factory.c
+++ b/tools/sra-dump/factory.c
@@ -752,6 +752,7 @@ rc_t SRASplitter_AddSpot( const SRASplitter * cself, spotid_t spot, readmask_t *
}
}
/* leave reads only allowed by previous object in chain */
+#ifndef EUGNES_LOOP_FIX
for ( j = 0, k = 0; k < nreads_max; k++ )
{
local_readmask[ k ] &= readmask[ k ];
@@ -761,6 +762,7 @@ rc_t SRASplitter_AddSpot( const SRASplitter * cself, spotid_t spot, readmask_t *
}
}
if ( j > 0 )
+#endif
{
rc = SRASplitter_FindNextSplitter( self, keys[ i ].key );
if ( rc == 0 )
@@ -790,6 +792,7 @@ rc_t SRASplitter_AddSpot( const SRASplitter * cself, spotid_t spot, readmask_t *
{
int32_t j, k;
/* leave reads only allowed by previous object in chain */
+#ifndef EUGNES_LOOP_FIX
for( j = 0, k = 0; k < nreads_max; k++ )
{
readmask[ k ] &= new_readmask[ k ];
@@ -799,6 +802,7 @@ rc_t SRASplitter_AddSpot( const SRASplitter * cself, spotid_t spot, readmask_t *
}
}
if ( j > 0 )
+#endif
{
rc = SRASplitter_FindNextSplitter( self, key );
if ( rc == 0 )
diff --git a/tools/sra-dump/fastq-dump.vers b/tools/sra-dump/fastq-dump.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-dump/fastq-dump.vers
+++ b/tools/sra-dump/fastq-dump.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-dump/fastq.c b/tools/sra-dump/fastq.c
index f32202e..e4e55d7 100644
--- a/tools/sra-dump/fastq.c
+++ b/tools/sra-dump/fastq.c
@@ -79,6 +79,7 @@ struct FastqArgs_struct
bool dumpBase;
bool dumpCs;
bool readIds;
+ bool SuppressQualForCSKey; /* added Jan 15th 2014 ( a new fastq-variation! ) */
int offset;
bool qual_filter;
bool qual_filter1;
@@ -1309,7 +1310,7 @@ static rc_t FastqBioFilterFactory_Init( const SRASplitterFactory* cself )
rc = FastqReaderMake( &self->reader, self->table, self->accession,
/* preserve orig spot format to save on conversions */
FastqArgs.is_platform_cs_native, false, FastqArgs.fasta > 0, false,
- false, !FastqArgs.applyClip, 0,
+ false, !FastqArgs.applyClip, FastqArgs.SuppressQualForCSKey, 0,
FastqArgs.offset, '\0', 0, 0) ;
}
return rc;
@@ -1478,7 +1479,7 @@ static rc_t FastqRNumberFilterFactory_Init( const SRASplitterFactory* cself )
rc = FastqReaderMake( &self->reader, self->table, self->accession,
/* preserve orig spot format to save on conversions */
FastqArgs.is_platform_cs_native, false, FastqArgs.fasta > 0, false,
- false, !FastqArgs.applyClip, 0,
+ false, !FastqArgs.applyClip, FastqArgs.SuppressQualForCSKey, 0,
FastqArgs.offset, '\0', 0, 0 );
}
return rc;
@@ -1808,7 +1809,7 @@ static rc_t FastqQFilterFactory_Init( const SRASplitterFactory* cself )
rc = FastqReaderMake( &self->reader, self->table, self->accession,
/* preserve orig spot format to save on conversions */
FastqArgs.is_platform_cs_native, false, FastqArgs.fasta > 0, false,
- false, !FastqArgs.applyClip, 0,
+ false, !FastqArgs.applyClip, FastqArgs.SuppressQualForCSKey, 0,
FastqArgs.offset, '\0', 0, 0 );
}
}
@@ -2003,7 +2004,7 @@ static rc_t FastqReadLenFilterFactory_Init( const SRASplitterFactory* cself )
rc = FastqReaderMake( &self->reader, self->table, self->accession,
/* preserve orig spot format to save on conversions */
FastqArgs.is_platform_cs_native, false, FastqArgs.fasta > 0, false,
- false, !FastqArgs.applyClip, 0,
+ false, !FastqArgs.applyClip, FastqArgs.SuppressQualForCSKey, 0,
FastqArgs.offset, '\0', 0, 0 );
}
return rc;
@@ -2232,7 +2233,7 @@ static rc_t FastqReadSplitterFactory_Init( const SRASplitterFactory* cself )
rc = FastqReaderMake( &self->reader, self->table, self->accession,
/* preserve orig spot format to save on conversions */
FastqArgs.is_platform_cs_native, false, FastqArgs.fasta > 0, false,
- false, !FastqArgs.applyClip, 0,
+ false, !FastqArgs.applyClip, FastqArgs.SuppressQualForCSKey, 0,
FastqArgs.offset, '\0', 0, 0 );
}
return rc;
@@ -2445,7 +2446,7 @@ static rc_t Fastq3ReadSplitterFactory_Init( const SRASplitterFactory* cself )
rc = FastqReaderMake( &self->reader, self->table, self->accession,
/* preserve orig spot format to save on conversions */
FastqArgs.is_platform_cs_native, false, FastqArgs.fasta > 0, false,
- false, !FastqArgs.applyClip, 0,
+ false, !FastqArgs.applyClip, FastqArgs.SuppressQualForCSKey, 0,
FastqArgs.offset, '\0', 0, 0 );
}
return rc;
@@ -2846,7 +2847,7 @@ static rc_t FastqFormatterFactory_Init( const SRASplitterFactory* cself )
{
rc = FastqReaderMake( &self->reader, self->table, self->accession,
FastqArgs.dumpCs, FastqArgs.dumpOrigFmt, FastqArgs.fasta > 0, FastqArgs.dumpCs,
- FastqArgs.readIds, !FastqArgs.applyClip, 0,
+ FastqArgs.readIds, !FastqArgs.applyClip, FastqArgs.SuppressQualForCSKey, 0,
FastqArgs.offset, FastqArgs.desiredCsKey[ 0 ], 0, 0 );
if ( rc == 0 )
{
@@ -2971,6 +2972,7 @@ ver_t CC KAppVersion( void )
#define H_aligned_region 18
#define H_matepair_distance 19
#define H_qual_filter_1 20
+#define H_SuppressQualForCSKey 21
rc_t FastqDumper_Usage( const SRADumperFmt* fmt, const SRADumperFmt_Arg* core_args, int first )
{
@@ -3062,7 +3064,7 @@ rc_t FastqDumper_Usage( const SRADumperFmt* fmt, const SRADumperFmt_Arg* core_ar
OARG( &fmt->arg_desc[ 2 ], NULL );
OARG( core[ 6 ], NULL );
OARG( &fmt->arg_desc[ 3 ], NULL );
- OARG( &fmt->arg_desc[ 20 ], NULL );
+ OARG( &fmt->arg_desc[ H_qual_filter_1 ], NULL );
OUTMSG(( "\nFilters based on alignments Filters are active when alignment\n" ));
OUTMSG(( " data are present\n" ));
@@ -3099,6 +3101,7 @@ rc_t FastqDumper_Usage( const SRADumperFmt* fmt, const SRADumperFmt_Arg* core_ar
OUTMSG(( "\nQuality\n" ));
OARG( &fmt->arg_desc[ 9 ], NULL );
OARG( &fmt->arg_desc[ 10 ], NULL );
+ OARG( &fmt->arg_desc[ H_SuppressQualForCSKey ], NULL ); /* added Jan 15th 2014 ( a new fastq-variation! ) */
OUTMSG(( "\nDefline\n" ));
OARG( &fmt->arg_desc[ 11 ], NULL );
@@ -3161,6 +3164,10 @@ bool FastqDumper_AddArg( const SRADumperFmt* fmt, GetArg* f, int* i, int argc, c
{
FastqArgs.applyClip = true;
}
+ else if ( f( fmt, "SU", "suppress-qual-for-cskey", i, argc, argv, NULL ) )
+ {
+ FastqArgs.SuppressQualForCSKey = true;
+ }
else if ( f( fmt, "F", "origfmt", i, argc, argv, NULL ) )
{
FastqArgs.dumpOrigFmt = true;
@@ -3209,8 +3216,10 @@ bool FastqDumper_AddArg( const SRADumperFmt* fmt, GetArg* f, int* i, int argc, c
}
else if ( f( fmt, "SF", "split-files", i, argc, argv, NULL ) )
{
+ SRADumperFmt * nc_fmt = ( SRADumperFmt * )fmt;
FastqArgs.split_spot = true;
FastqArgs.split_files = true;
+ nc_fmt->split_files = true;
}
else if ( f( fmt, NULL, "split-3", i, argc, argv, NULL ) )
{
@@ -3744,6 +3753,8 @@ rc_t SRADumper_Init( SRADumperFmt* fmt )
{NULL, "qual-filter-1", NULL, {"Filter used in current 1000 Genomes data", NULL}}, /* H_qual_filter_1 = 20 */
+ {NULL, "suppress-qual-for-cskey", NULL, {"supress quality-value for cskey", NULL}}, /* H_SuppressQualForCSKey = 21 */
+
{NULL, NULL, NULL, {NULL}}
};
@@ -3758,6 +3769,7 @@ rc_t SRADumper_Init( SRADumperFmt* fmt )
FastqArgs.skipTechnical = false;
FastqArgs.minReadLen = 1;
FastqArgs.applyClip = false;
+ FastqArgs.SuppressQualForCSKey = false; /* added Jan 15th 2014 ( a new fastq-variation! ) */
FastqArgs.dumpOrigFmt = false;
FastqArgs.dumpBase = false;
FastqArgs.dumpCs = false;
@@ -3789,6 +3801,7 @@ rc_t SRADumper_Init( SRADumperFmt* fmt )
fmt->get_factory = FastqDumper_Factories;
fmt->gzip = true;
fmt->bzip2 = true;
+ fmt->split_files = false;
return 0;
}
diff --git a/tools/sra-dump/illumina-dump.vers b/tools/sra-dump/illumina-dump.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-dump/illumina-dump.vers
+++ b/tools/sra-dump/illumina-dump.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-dump/sff-dump.vers b/tools/sra-dump/sff-dump.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-dump/sff-dump.vers
+++ b/tools/sra-dump/sff-dump.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-dump/sra-dump.vers b/tools/sra-dump/sra-dump.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-dump/sra-dump.vers
+++ b/tools/sra-dump/sra-dump.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-load/abi-load.vers b/tools/sra-load/abi-load.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-load/abi-load.vers
+++ b/tools/sra-load/abi-load.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-load/fastq-load.vers b/tools/sra-load/fastq-load.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-load/fastq-load.vers
+++ b/tools/sra-load/fastq-load.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-load/helicos-load.vers b/tools/sra-load/helicos-load.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-load/helicos-load.vers
+++ b/tools/sra-load/helicos-load.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-load/illumina-load.vers b/tools/sra-load/illumina-load.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-load/illumina-load.vers
+++ b/tools/sra-load/illumina-load.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-load/pacbio-loadxml.vers b/tools/sra-load/pacbio-loadxml.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-load/pacbio-loadxml.vers
+++ b/tools/sra-load/pacbio-loadxml.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-load/sff-load.vers b/tools/sra-load/sff-load.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-load/sff-load.vers
+++ b/tools/sra-load/sff-load.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-load/srf-load.vers b/tools/sra-load/srf-load.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-load/srf-load.vers
+++ b/tools/sra-load/srf-load.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-load/writer-absolid.c b/tools/sra-load/writer-absolid.c
index faaaec4..17fa2ee 100644
--- a/tools/sra-load/writer-absolid.c
+++ b/tools/sra-load/writer-absolid.c
@@ -38,8 +38,8 @@
#include <ctype.h>
#include <assert.h>
-const int AbisolidReadType2ReadNumber [] = {0, 0, 0, 1, 1, 1, 1, 1, 1};
-const char *AbisolidReadType2ReadLabel [] = {"", "", "F3", "R3", "F5-P2", "F5-BC", "F5-RNA", "F5-DNA", "F3-DNA"};
+const int AbisolidReadType2ReadNumber [] = {0, 0, 0, 1, 1, 1, 1, 1, 1, 1};
+const char *AbisolidReadType2ReadLabel [] = {"", "", "F3", "R3", "F5-P2", "F5-BC", "F5-RNA", "F5-DNA", "F3-DNA", "BC"};
void AbsolidRead_Init(AbsolidRead* read)
{
@@ -81,6 +81,8 @@ EAbisolidReadType AbsolidRead_Suffix2ReadType(const char* s)
type = eAbisolidReadType_F5_DNA;
} else if( len > 5 && strcmp(&s[len - 6], "F3-DNA") == 0 ) {
type = eAbisolidReadType_F3_DNA;
+ } else if( len > 1 && strcmp(&s[len - 2], "BC") == 0 ) {
+ type = eAbisolidReadType_BC;
} else {
int i;
for(i = 0; i < len; i++) {
diff --git a/tools/sra-load/writer-absolid.h b/tools/sra-load/writer-absolid.h
index 220a990..2384977 100644
--- a/tools/sra-load/writer-absolid.h
+++ b/tools/sra-load/writer-absolid.h
@@ -49,7 +49,8 @@ typedef enum EAbisolidReadType_enum {
eAbisolidReadType_F5_BC = 5,
eAbisolidReadType_F5_RNA = 6,
eAbisolidReadType_F5_DNA = 7,
- eAbisolidReadType_F3_DNA = 8
+ eAbisolidReadType_F3_DNA = 8,
+ eAbisolidReadType_BC = 9
} EAbisolidReadType;
extern const int AbisolidReadType2ReadNumber [];
diff --git a/tools/sra-pileup/cg_tools.c b/tools/sra-pileup/cg_tools.c
index f2f18fa..9a2316b 100644
--- a/tools/sra-pileup/cg_tools.c
+++ b/tools/sra-pileup/cg_tools.c
@@ -954,10 +954,11 @@ rc_t discover_rna_splicing_candidates( uint32_t cigar_len, const char * cigar, u
}
-rc_t change_rna_splicing_cigar( uint32_t cigar_len, char * cigar, rna_splice_candidates * candidates )
+rc_t change_rna_splicing_cigar( uint32_t cigar_len, char * cigar, rna_splice_candidates * candidates, uint32_t * NM_adjustment )
{
rc_t rc = 0;
uint32_t cigops_len = cigar_len / 2;
+ uint32_t sum_of_n_lengths = 0;
CigOps * cigops = malloc( ( sizeof * cigops ) * cigops_len );
if ( cigops == NULL )
rc = RC( rcExe, rcNoTarg, rcConstructing, rcMemory, rcExhausted );
@@ -969,7 +970,10 @@ rc_t change_rna_splicing_cigar( uint32_t cigar_len, char * cigar, rna_splice_can
{
rna_splice_candidate * rsc = &candidates->candidates[ idx ];
if ( rsc->matched != 0 && cigops[ rsc->op_idx ].op == 'D' )
+ {
cigops[ rsc->op_idx ].op = 'N';
+ sum_of_n_lengths += cigops[ rsc->op_idx ].oplen;
+ }
}
for ( idx = 0, dst = 0; idx < ( n_cigops - 1 ) && rc == 0; ++idx )
@@ -980,5 +984,7 @@ rc_t change_rna_splicing_cigar( uint32_t cigar_len, char * cigar, rna_splice_can
}
free( cigops );
}
+ if ( NM_adjustment != NULL )
+ *NM_adjustment = sum_of_n_lengths;
return rc;
}
diff --git a/tools/sra-pileup/cg_tools.h b/tools/sra-pileup/cg_tools.h
index b60bdb3..5fac13a 100644
--- a/tools/sra-pileup/cg_tools.h
+++ b/tools/sra-pileup/cg_tools.h
@@ -119,6 +119,6 @@ typedef struct rna_splice_candidates
rc_t discover_rna_splicing_candidates( uint32_t cigar_len, const char * cigar, uint32_t min_len, rna_splice_candidates * candidates );
-rc_t change_rna_splicing_cigar( uint32_t cigar_len, char * cigar, rna_splice_candidates * candidates );
+rc_t change_rna_splicing_cigar( uint32_t cigar_len, char * cigar, rna_splice_candidates * candidates, uint32_t * NM_adjustment );
-#endif
\ No newline at end of file
+#endif
diff --git a/tools/sra-pileup/read_fkt.h b/tools/sra-pileup/read_fkt.h
index b4d2439..6ba6fa8 100644
--- a/tools/sra-pileup/read_fkt.h
+++ b/tools/sra-pileup/read_fkt.h
@@ -1,82 +1,82 @@
-/*===========================================================================
-*
-* PUBLIC DOMAIN NOTICE
-* National Center for Biotechnology Information
-*
-* This software/database is a "United States Government Work" under the
-* terms of the United States Copyright Act. It was written as part of
-* the author's official duties as a United States Government employee and
-* thus cannot be copyrighted. This software/database is freely available
-* to the public for use. The National Library of Medicine and the U.S.
-* Government have not placed any restriction on its use or reproduction.
-*
-* Although all reasonable efforts have been taken to ensure the accuracy
-* and reliability of the software and data, the NLM and the U.S.
-* Government do not and cannot warrant the performance or results that
-* may be obtained by using this software or data. The NLM and the U.S.
-* Government disclaim all warranties, express or implied, including
-* warranties of performance, merchantability or fitness for any particular
-* purpose.
-*
-* Please cite the author in any work or product based on this material.
-*
-* ===========================================================================
-*
-*/
-#ifndef _h_read_fkt_
-#define _h_read_fkt_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-#if 0
-}
-#endif
-
-#include <klib/vector.h>
-#include <klib/out.h>
-#include <klib/text.h>
-#include <klib/rc.h>
-#include <klib/log.h>
-
-#include <vdb/cursor.h>
-#include <insdc/sra.h>
-
-#define COL_NOT_AVAILABLE 0xFFFFFFFF
-#define INVALID_COLUMN 0xFFFFFFFF
-
-rc_t read_bool( int64_t row_id, const VCursor * cursor, uint32_t idx, bool *res, bool dflt, const char * hint );
-rc_t read_bool_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const bool **res, uint32_t *res_len, const char * hint );
-
-rc_t read_uint8( int64_t row_id, const VCursor * cursor, uint32_t idx, uint8_t *res, uint8_t dflt, const char * hint );
-rc_t read_uint8_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const uint8_t **res, uint32_t *len, const char * hint );
-
-rc_t read_uint32( int64_t row_id, const VCursor * cursor, uint32_t idx, uint32_t *res, uint32_t dflt, const char * hint );
-rc_t read_uint32_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const uint32_t **res, uint32_t *len, const char * hint );
-
-rc_t read_int32( int64_t row_id, const VCursor * cursor, uint32_t idx, int32_t *res, int32_t dflt, const char * hint );
-rc_t read_int32_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const int32_t **res, uint32_t *len, const char * hint );
-
-rc_t read_int64( int64_t row_id, const VCursor * cursor, uint32_t idx, int64_t *res, int64_t dflt, const char * hint );
-rc_t read_int64_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const int64_t **res, uint32_t *len, const char * hint );
-
-rc_t read_char_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const char **res, uint32_t *len, const char * hint );
-
-rc_t read_INSDC_coord_zero( int64_t row_id, const VCursor * cursor, uint32_t idx, INSDC_coord_zero *res, INSDC_coord_zero dflt, const char * hint );
-rc_t read_INSDC_coord_zero_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const INSDC_coord_zero **res, uint32_t *len, const char * hint );
-
-rc_t read_INSDC_coord_one( int64_t row_id, const VCursor * cursor, uint32_t idx, INSDC_coord_one *res, INSDC_coord_one dflt, const char * hint );
-rc_t read_INSDC_coord_one_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, INSDC_coord_one **res, uint32_t *len, const char * hint );
-
-rc_t read_INSDC_coord_len( int64_t row_id, const VCursor * cursor, uint32_t idx, INSDC_coord_len *res, INSDC_coord_len dflt, const char * hint );
-rc_t read_INSDC_coord_len_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const INSDC_coord_len **res, uint32_t *len, const char * hint );
-
-rc_t read_INSDC_read_type_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const INSDC_read_type **res, uint32_t *len, const char * hint );
-rc_t read_INSDC_read_filter_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const INSDC_read_filter **res, uint32_t *len, const char * hint );
-rc_t read_INSDC_dna_text_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const INSDC_dna_text **res, uint32_t *len, const char * hint );
-
-bool namelist_contains( const KNamelist * names, const char * a_name );
-rc_t add_column( const VCursor * cursor, const char *colname, uint32_t * idx );
-void add_opt_column( const VCursor * cursor, const KNamelist *names, const char *colname, uint32_t * idx );
-
-#endif
\ No newline at end of file
+/*===========================================================================
+*
+* PUBLIC DOMAIN NOTICE
+* National Center for Biotechnology Information
+*
+* This software/database is a "United States Government Work" under the
+* terms of the United States Copyright Act. It was written as part of
+* the author's official duties as a United States Government employee and
+* thus cannot be copyrighted. This software/database is freely available
+* to the public for use. The National Library of Medicine and the U.S.
+* Government have not placed any restriction on its use or reproduction.
+*
+* Although all reasonable efforts have been taken to ensure the accuracy
+* and reliability of the software and data, the NLM and the U.S.
+* Government do not and cannot warrant the performance or results that
+* may be obtained by using this software or data. The NLM and the U.S.
+* Government disclaim all warranties, express or implied, including
+* warranties of performance, merchantability or fitness for any particular
+* purpose.
+*
+* Please cite the author in any work or product based on this material.
+*
+* ===========================================================================
+*
+*/
+#ifndef _h_read_fkt_
+#define _h_read_fkt_
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+#if 0
+}
+#endif
+
+#include <klib/vector.h>
+#include <klib/out.h>
+#include <klib/text.h>
+#include <klib/rc.h>
+#include <klib/log.h>
+
+#include <vdb/cursor.h>
+#include <insdc/sra.h>
+
+#define COL_NOT_AVAILABLE 0xFFFFFFFF
+#define INVALID_COLUMN 0xFFFFFFFF
+
+rc_t read_bool( int64_t row_id, const VCursor * cursor, uint32_t idx, bool *res, bool dflt, const char * hint );
+rc_t read_bool_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const bool **res, uint32_t *res_len, const char * hint );
+
+rc_t read_uint8( int64_t row_id, const VCursor * cursor, uint32_t idx, uint8_t *res, uint8_t dflt, const char * hint );
+rc_t read_uint8_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const uint8_t **res, uint32_t *len, const char * hint );
+
+rc_t read_uint32( int64_t row_id, const VCursor * cursor, uint32_t idx, uint32_t *res, uint32_t dflt, const char * hint );
+rc_t read_uint32_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const uint32_t **res, uint32_t *len, const char * hint );
+
+rc_t read_int32( int64_t row_id, const VCursor * cursor, uint32_t idx, int32_t *res, int32_t dflt, const char * hint );
+rc_t read_int32_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const int32_t **res, uint32_t *len, const char * hint );
+
+rc_t read_int64( int64_t row_id, const VCursor * cursor, uint32_t idx, int64_t *res, int64_t dflt, const char * hint );
+rc_t read_int64_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const int64_t **res, uint32_t *len, const char * hint );
+
+rc_t read_char_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const char **res, uint32_t *len, const char * hint );
+
+rc_t read_INSDC_coord_zero( int64_t row_id, const VCursor * cursor, uint32_t idx, INSDC_coord_zero *res, INSDC_coord_zero dflt, const char * hint );
+rc_t read_INSDC_coord_zero_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const INSDC_coord_zero **res, uint32_t *len, const char * hint );
+
+rc_t read_INSDC_coord_one( int64_t row_id, const VCursor * cursor, uint32_t idx, INSDC_coord_one *res, INSDC_coord_one dflt, const char * hint );
+rc_t read_INSDC_coord_one_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, INSDC_coord_one **res, uint32_t *len, const char * hint );
+
+rc_t read_INSDC_coord_len( int64_t row_id, const VCursor * cursor, uint32_t idx, INSDC_coord_len *res, INSDC_coord_len dflt, const char * hint );
+rc_t read_INSDC_coord_len_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const INSDC_coord_len **res, uint32_t *len, const char * hint );
+
+rc_t read_INSDC_read_type_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const INSDC_read_type **res, uint32_t *len, const char * hint );
+rc_t read_INSDC_read_filter_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const INSDC_read_filter **res, uint32_t *len, const char * hint );
+rc_t read_INSDC_dna_text_ptr( int64_t row_id, const VCursor * cursor, uint32_t idx, const INSDC_dna_text **res, uint32_t *len, const char * hint );
+
+bool namelist_contains( const KNamelist * names, const char * a_name );
+rc_t add_column( const VCursor * cursor, const char *colname, uint32_t * idx );
+void add_opt_column( const VCursor * cursor, const KNamelist *names, const char *colname, uint32_t * idx );
+
+#endif
diff --git a/tools/sra-pileup/sam-aligned.c b/tools/sra-pileup/sam-aligned.c
index 92af47f..c1b878a 100644
--- a/tools/sra-pileup/sam-aligned.c
+++ b/tools/sra-pileup/sam-aligned.c
@@ -1345,7 +1345,7 @@ static rc_t print_alignment_sam_ps( const samdump_opts * const opts, const char
const PlacementRecord * const rec, const align_table_context * const atx,
uint64_t * const rows_so_far )
{
- uint32_t sam_flags = 0, seq_spot_id_len, mate_ref_pos_len = 0, mate_ref_name_len = string_size( ref_name );
+ uint32_t sam_flags = 0, NM_adjustments = 0, seq_spot_id_len, mate_ref_pos_len = 0, mate_ref_name_len = string_size( ref_name );
INSDC_coord_zero mate_ref_pos = 0;
INSDC_coord_len tlen = 0;
int64_t mate_align_id = 0, id = rec->id;
@@ -1539,7 +1539,7 @@ static rc_t print_alignment_sam_ps( const samdump_opts * const opts, const char
if ( temp_cigar != NULL )
{
memcpy( temp_cigar, cgc_output.p_cigar.ptr, cgc_output.p_cigar.len );
- rc = change_rna_splicing_cigar( cgc_output.p_cigar.len, temp_cigar, &candidates ); /* cg_tools.c */
+ rc = change_rna_splicing_cigar( cgc_output.p_cigar.len, temp_cigar, &candidates, &NM_adjustments ); /* cg_tools.c */
if ( rc == 0 )
cgc_output.p_cigar.ptr = temp_cigar;
}
@@ -1632,7 +1632,7 @@ static rc_t print_alignment_sam_ps( const samdump_opts * const opts, const char
/* OPT SAM-FIELD: NM SRA-column: EDIT_DISTANCE */
if ( rc == 0 )
- rc = KOutMsg( "\tNM:i:%u", cgc_output.edit_dist );
+ rc = KOutMsg( "\tNM:i:%u", ( cgc_output.edit_dist - NM_adjustments ) );
/* OPT SAM-FIELD: XS:A:+/- SRA-column: RNA-SPLICING detected via computation */
if ( rc == 0 && opts->rna_splicing && ( candidates.fwd_matched > 0 || candidates.rev_matched > 0 ) )
diff --git a/tools/sra-pileup/sam-aligned.h b/tools/sra-pileup/sam-aligned.h
index b8a4260..afccab4 100644
--- a/tools/sra-pileup/sam-aligned.h
+++ b/tools/sra-pileup/sam-aligned.h
@@ -1,45 +1,45 @@
-/*===========================================================================
-*
-* PUBLIC DOMAIN NOTICE
-* National Center for Biotechnology Information
-*
-* This software/database is a "United States Government Work" under the
-* terms of the United States Copyright Act. It was written as part of
-* the author's official duties as a United States Government employee and
-* thus cannot be copyrighted. This software/database is freely available
-* to the public for use. The National Library of Medicine and the U.S.
-* Government have not placed any restriction on its use or reproduction.
-*
-* Although all reasonable efforts have been taken to ensure the accuracy
-* and reliability of the software and data, the NLM and the U.S.
-* Government do not and cannot warrant the performance or results that
-* may be obtained by using this software or data. The NLM and the U.S.
-* Government disclaim all warranties, express or implied, including
-* warranties of performance, merchantability or fitness for any particular
-* purpose.
-*
-* Please cite the author in any work or product based on this material.
-*
-* ===========================================================================
-*
-*/
-#ifndef _h_sam_aligned_
-#define _h_sam_aligned_
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-#if 0
-}
-#endif
-
-#include "sam-dump-opts.h"
-#include "inputfiles.h"
-#include "matecache.h"
-
-#define COL_READ "(INSDC:dna:text)READ"
-
-rc_t print_aligned_spots( const samdump_opts * const opts, const input_files * const ifs,
- matecache * const mc, uint64_t * const rows_so_far );
-
-#endif
\ No newline at end of file
+/*===========================================================================
+*
+* PUBLIC DOMAIN NOTICE
+* National Center for Biotechnology Information
+*
+* This software/database is a "United States Government Work" under the
+* terms of the United States Copyright Act. It was written as part of
+* the author's official duties as a United States Government employee and
+* thus cannot be copyrighted. This software/database is freely available
+* to the public for use. The National Library of Medicine and the U.S.
+* Government have not placed any restriction on its use or reproduction.
+*
+* Although all reasonable efforts have been taken to ensure the accuracy
+* and reliability of the software and data, the NLM and the U.S.
+* Government do not and cannot warrant the performance or results that
+* may be obtained by using this software or data. The NLM and the U.S.
+* Government disclaim all warranties, express or implied, including
+* warranties of performance, merchantability or fitness for any particular
+* purpose.
+*
+* Please cite the author in any work or product based on this material.
+*
+* ===========================================================================
+*
+*/
+#ifndef _h_sam_aligned_
+#define _h_sam_aligned_
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+#if 0
+}
+#endif
+
+#include "sam-dump-opts.h"
+#include "inputfiles.h"
+#include "matecache.h"
+
+#define COL_READ "(INSDC:dna:text)READ"
+
+rc_t print_aligned_spots( const samdump_opts * const opts, const input_files * const ifs,
+ matecache * const mc, uint64_t * const rows_so_far );
+
+#endif
diff --git a/tools/sra-pileup/sam-dump-opts.c b/tools/sra-pileup/sam-dump-opts.c
index 073ad56..d0f0815 100644
--- a/tools/sra-pileup/sam-dump-opts.c
+++ b/tools/sra-pileup/sam-dump-opts.c
@@ -1062,6 +1062,19 @@ static rc_t gather_string_options( Args * args, samdump_opts * opts )
}
}
+ rc = get_str_option( args, OPT_HDR_FILE, &s );
+ if ( rc == 0 && s != NULL )
+ {
+ opts->header_file = string_dup_measure( s, NULL );
+ if ( opts->header_file == NULL )
+ {
+ rc = RC( rcExe, rcNoTarg, rcValidating, rcMemory, rcExhausted );
+ (void)LOGERR( klogErr, rc, "error storing HDR-FILE" );
+ }
+ else
+ opts->header_mode = hm_file;
+ }
+
return rc;
}
@@ -1163,6 +1176,7 @@ void report_options( const samdump_opts * opts )
case hm_none : KOutMsg( "header-mode : dont print\n" ); break;
case hm_recalc : KOutMsg( "header-mode : recalculate\n" ); break;
case hm_dump : KOutMsg( "header-mode : print meta-data\n" ); break;
+ case hm_file : KOutMsg( "header-mode : take from '%s'\n", opts->header_file ); break;
default : KOutMsg( "header-mode : unknown\n" ); break;
}
@@ -1289,6 +1303,8 @@ void release_options( samdump_opts * opts )
free( (void*)opts->qual_quant );
if( opts->outputfile != NULL )
free( (void*)opts->outputfile );
+ if( opts->header_file != NULL )
+ free( (void*)opts->header_file );
VNamelistRelease( opts->hdr_comments );
VNamelistRelease( opts->input_files );
VectorWhack ( &opts->mp_dist, release_range_wrapper, NULL );
diff --git a/tools/sra-pileup/sam-dump-opts.h b/tools/sra-pileup/sam-dump-opts.h
index 52a1aaa..71891d9 100644
--- a/tools/sra-pileup/sam-dump-opts.h
+++ b/tools/sra-pileup/sam-dump-opts.h
@@ -60,6 +60,7 @@ extern "C" {
#define OPT_CG_MAPP "CG-mappings"
#define OPT_REGION "aligned-region"
#define OPT_RECAL_HDR "header"
+#define OPT_HDR_FILE "header-file"
#define OPT_NO_HDR "no-header"
#define OPT_USE_SEQID "seqid"
#define OPT_HIDE_IDENT "hide-identical"
@@ -113,7 +114,8 @@ enum header_mode
{
hm_none = 0, /* do not dump the headers at all */
hm_recalc, /* recalculate the headers */
- hm_dump /* dump the header found in metadata */
+ hm_dump, /* dump the header found in metadata */
+ hm_file /* take the complete header part from a file */
};
enum output_format
@@ -169,6 +171,9 @@ typedef struct samdump_opts
/* optional outputfile */
const char * outputfile;
+ /* optional header-file */
+ const char * header_file;
+
/* cigar-test >>> not advertized! */
const char * cigar_test;
diff --git a/tools/sra-pileup/sam-dump.vers b/tools/sra-pileup/sam-dump.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-pileup/sam-dump.vers
+++ b/tools/sra-pileup/sam-dump.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-pileup/sam-dump3.c b/tools/sra-pileup/sam-dump3.c
index 6794065..8d51c9b 100644
--- a/tools/sra-pileup/sam-dump3.c
+++ b/tools/sra-pileup/sam-dump3.c
@@ -71,6 +71,9 @@ char const *sd_CG_mappings[] = { "Output CG sequences aligned to refere
char const *sd_header_usage[] = { "Always reconstruct header",
NULL };
+char const *sd_header_file_usage[] = { "take all headers from this file",
+ NULL };
+
char const *sd_noheader_usage[] = { "Do not output headers",
NULL };
@@ -160,6 +163,7 @@ OptDef SamDumpArgs[] =
{ OPT_CIGAR_LONG, "c", NULL, sd_cigartype_usage, 0, false, false }, /* use long cigar-string instead of short */
{ OPT_CIGAR_CG, NULL, NULL, sd_cigarCG_usage, 0, false, false }, /* transform cigar into cg-style ( has B/N ) */
{ OPT_RECAL_HDR, "r", NULL, sd_header_usage, 0, false, false }, /* recalculate header */
+ { OPT_HDR_FILE, NULL, NULL, sd_header_file_usage, 0, true, false }, /* take headers from file */
{ OPT_NO_HDR, "n", NULL, sd_noheader_usage, 0, false, false }, /* do not print header */
{ OPT_HDR_COMMENT, NULL, NULL, sd_comment_usage, 0, true, false }, /* insert this comment into header */
{ OPT_REGION, NULL, NULL, sd_region_usage, 0, true, false }, /* filter by region */
@@ -206,6 +210,7 @@ char const *sd_usage_params[] =
NULL, /* cigartype */
NULL, /* cigarCG */
NULL, /* recalc header */
+ "filename", /* take headers from file */
NULL, /* no-header */
"text", /* hdr-comment */
"name[:from-to]", /* region */
@@ -475,7 +480,7 @@ static rc_t samdump_main( Args * args, const samdump_opts * const opts )
{
if ( opts->input_file_count < 1 )
{
- rc = RC( rcExe, rcNoTarg, rcConstructing, rcParam, rcInvalid );
+ rc = RC( rcExe, rcArgv, rcParsing, rcParam, rcInvalid );
(void)LOGERR( klogErr, rc, "no inputfiles given at commandline" );
Usage( args );
}
diff --git a/tools/sra-pileup/sam-hdr.c b/tools/sra-pileup/sam-hdr.c
index 2173ad8..faad998 100644
--- a/tools/sra-pileup/sam-hdr.c
+++ b/tools/sra-pileup/sam-hdr.c
@@ -24,6 +24,7 @@
*
*/
+#include <kfs/file.h>
#include <kdb/meta.h>
#include <kdb/namelist.h>
#include <align/reference.h>
@@ -176,7 +177,7 @@ static rc_t add_seq_id_node( BSTree * tree, const char * seq_id, const char * na
}
-static rc_t print_seq_id_tree( BSTree * tree, input_files * ifs )
+static rc_t build_seq_id_tree( BSTree * tree, input_files * ifs )
{
rc_t rc = 0;
uint32_t i;
@@ -254,7 +255,230 @@ static void CC print_header_callback( BSTNode *n, void *data )
}
-static rc_t extract_spotgroups( VNamelist * spotgroups, input_files * ifs )
+static rc_t extract_spotgroups_from_stats( VNamelist * spotgroups, input_database * id, const KMetadata * meta )
+{
+ const KMDataNode * node;
+ rc_t rc = KMetadataOpenNodeRead( meta, &node, "STATS/SPOT_GROUP" );
+ if ( rc != 0 )
+ (void)PLOGERR( klogErr, ( klogErr, rc, "cannot open meta-node 'STATS/SPOT_GROUP' from '$(t)'", "t=%s", id->path ) );
+ else
+ {
+ KNamelist * node_childs;
+ rc = KMDataNodeListChildren( node, &node_childs );
+ if ( rc != 0 )
+ (void)PLOGERR( klogErr, ( klogErr, rc, "cannot list children of SPOT_GROUP-node in '$(t)'", "t=%s", id->path ) );
+ else
+ {
+ uint32_t n_count;
+ rc = KNamelistCount( node_childs, &n_count );
+ if ( rc == 0 && n_count > 0 )
+ {
+ uint32_t n_idx;
+ for ( n_idx = 0; n_idx < n_count && rc == 0; ++n_idx )
+ {
+ const char * spotgroup;
+ rc = KNamelistGet( node_childs, n_idx, &spotgroup );
+ if ( rc == 0 && spotgroup != NULL )
+ {
+ uint32_t found;
+ rc_t rc1 = VNamelistIndexOf( spotgroups, spotgroup, &found );
+ if ( GetRCState( rc1 ) == rcNotFound )
+ rc = VNamelistAppend( spotgroups, spotgroup );
+ }
+ }
+ }
+ KNamelistRelease( node_childs );
+ }
+ KMDataNodeRelease( node );
+ }
+ return rc;
+}
+
+
+#define STATE_ALPHA 0
+#define STATE_LF 1
+#define STATE_NL 2
+
+typedef struct buffer_range
+{
+ const char * start;
+ uint32_t processed, count, state;
+} buffer_range;
+
+
+static const char empty_str[ 2 ] = { ' ', 0 };
+
+
+static rc_t LoadFromBuffer( buffer_range * range,
+ rc_t ( CC * wr ) ( void * dst, const String * S ),
+ void * dst )
+{
+ rc_t rc = 0;
+ uint32_t idx;
+ const char * p = range->start;
+ String S, S_empty;
+
+ S.addr = p;
+ S.len = S.size = range->processed;
+ S_empty.addr = empty_str;
+ S_empty.len = S_empty.size = 1;
+ for ( idx = range->processed; idx < range->count && rc == 0; ++idx )
+ {
+ switch( p[ idx ] )
+ {
+ case 0x0A : switch( range->state )
+ {
+ case STATE_ALPHA : /* ALPHA --> LF */
+ rc = wr ( dst, &S );
+ range->state = STATE_LF;
+ break;
+
+ case STATE_LF : /* LF --> LF */
+ rc = wr ( dst, &S_empty );
+ break;
+
+ case STATE_NL : /* NL --> LF */
+ rc = wr ( dst, &S_empty );
+ range->state = STATE_LF;
+ break;
+ }
+ break;
+
+ case 0x0D : switch( range->state )
+ {
+ case STATE_ALPHA : /* ALPHA --> NL */
+ rc = wr( dst, &S_empty );
+ range->state = STATE_NL;
+ break;
+
+ case STATE_LF : /* LF --> NL */
+ range->state = STATE_NL;
+ break;
+
+ case STATE_NL : /* NL --> NL */
+ rc = wr ( dst, &S_empty );
+ break;
+ }
+ break;
+
+ default : switch( range->state )
+ {
+ case STATE_ALPHA : /* ALPHA --> ALPHA */
+ S.len++; S.size++;
+ break;
+
+ case STATE_LF : /* LF --> ALPHA */
+ S.addr = &p[ idx ]; S.len = S.size = 1;
+ range->state = STATE_ALPHA;
+ break;
+
+ case STATE_NL : /* NL --> ALPHA */
+ S.addr = &p[ idx ]; S.len = S.size = 1;
+ range->state = STATE_ALPHA;
+ break;
+ }
+ break;
+ }
+ }
+ if ( range->state == STATE_ALPHA )
+ {
+ range->start = S.addr;
+ range->count = S.len;
+ }
+ else
+ range->count = 0;
+ return rc;
+}
+
+
+static rc_t read_2_namelist( VNamelist * namelist, char * buffer, size_t bsize,
+ rc_t ( CC * rd ) ( const void * src, uint64_t pos, void * buffer, size_t bsize, size_t * num_read ),
+ rc_t ( CC * wr ) ( void * dst, const String * S ),
+ const void * src, void * dst )
+{
+ rc_t rc = 0;
+ uint64_t pos = 0;
+ buffer_range range;
+ bool done = false;
+
+ range.start = buffer;
+ range.count = 0;
+ range.processed = 0;
+ range.state = STATE_ALPHA;
+
+ do
+ {
+ size_t num_read;
+ rc = rd ( src, pos, ( char * )( range.start + range.processed ),
+ bsize - range.processed, &num_read );
+ if ( rc == 0 )
+ {
+ done = ( num_read == 0 );
+ if ( !done )
+ {
+ range.start = buffer;
+ range.count = range.processed + num_read;
+
+ LoadFromBuffer( &range, wr, dst );
+ if ( range.count > 0 )
+ {
+ memmove ( buffer, range.start, range.count );
+ }
+ range.start = buffer;
+ range.processed = range.count;
+
+ pos += num_read;
+ }
+ else if ( range.state == STATE_ALPHA )
+ {
+ String S;
+ S.addr = range.start;
+ S.len = S.size = range.count;
+ rc = wr ( dst, &S );
+ }
+ }
+ } while ( rc == 0 && !done );
+
+ return rc;
+}
+
+
+static rc_t CC write_to_namelist( void * dst, const String * S )
+{
+ rc_t rc = 0;
+ VNamelist * namelist = dst;
+ if ( S->len > 3 && S->addr[ 0 ] == '@' && S->addr[ 1 ] == 'R' && S->addr[ 2 ] == 'G' )
+ rc = VNamelistAppendString ( namelist, S );
+ return rc;
+}
+
+static rc_t CC read_from_metadata_node( const void * src, uint64_t pos, void * buffer, size_t bsize, size_t * num_read )
+{
+ const KMDataNode * node = src;
+ size_t remaining;
+ return KMDataNodeRead( node, pos, buffer, bsize, num_read, &remaining );
+}
+
+
+static rc_t extract_spotgroups_from_bam_hdr( VNamelist * spotgroups, input_database * id, const KMetadata * meta )
+{
+ const KMDataNode * node;
+ rc_t rc = KMetadataOpenNodeRead( meta, &node, "BAM_HEADER" );
+ /* do not report if the node cannot be found, because this would produce an error message when a database does
+ not have this node, which can is OK */
+ if ( rc == 0 )
+ {
+ char buffer[ 4096 ];
+ rc = read_2_namelist( spotgroups, buffer, sizeof buffer,
+ read_from_metadata_node, write_to_namelist,
+ node, spotgroups );
+ KMDataNodeRelease( node );
+ }
+ return rc;
+}
+
+
+static rc_t extract_spotgroups( VNamelist * spotgroups, input_files * ifs, bool from_stats )
{
rc_t rc = 0;
uint32_t i;
@@ -263,55 +487,39 @@ static rc_t extract_spotgroups( VNamelist * spotgroups, input_files * ifs )
input_database * id = VectorGet( &ifs->dbs, i );
if ( id != NULL )
{
- const VTable * tab;
- rc = VDatabaseOpenTableRead( id->db, &tab, "SEQUENCE" );
- if ( rc != 0 )
- (void)PLOGERR( klogErr, ( klogErr, rc, "cannot open table SEQUENCE in '$(t)'", "t=%s", id->path ) );
- else
+ if ( from_stats )
{
- const KMetadata * meta;
- rc = VTableOpenMetadataRead( tab, &meta );
+ const VTable * tab;
+ rc = VDatabaseOpenTableRead( id->db, &tab, "SEQUENCE" );
if ( rc != 0 )
- (void)PLOGERR( klogErr, ( klogErr, rc, "cannot open metadata from '$(t)'", "t=%s", id->path ) );
+ (void)PLOGERR( klogErr, ( klogErr, rc, "cannot open table SEQUENCE in '$(t)'", "t=%s", id->path ) );
else
{
- const KMDataNode * node;
- rc = KMetadataOpenNodeRead( meta, &node, "STATS/SPOT_GROUP" );
+ const KMetadata * meta;
+ rc = VTableOpenMetadataRead( tab, &meta );
if ( rc != 0 )
- (void)PLOGERR( klogErr, ( klogErr, rc, "cannot open meta-node 'STATS/SPOT_GROUP' from '$(t)'", "t=%s", id->path ) );
+ (void)PLOGERR( klogErr, ( klogErr, rc, "cannot open metadata from '$(t)'", "t=%s", id->path ) );
else
{
- KNamelist * node_childs;
- rc = KMDataNodeListChildren( node, &node_childs );
- if ( rc != 0 )
- (void)PLOGERR( klogErr, ( klogErr, rc, "cannot list children of SPOT_GROUP-node in '$(t)'", "t=%s", id->path ) );
- else
- {
- uint32_t n_count;
- rc = KNamelistCount( node_childs, &n_count );
- if ( rc == 0 && n_count > 0 )
- {
- uint32_t n_idx;
- for ( n_idx = 0; n_idx < n_count && rc == 0; ++n_idx )
- {
- const char * spotgroup;
- rc = KNamelistGet( node_childs, n_idx, &spotgroup );
- if ( rc == 0 && spotgroup != NULL )
- {
- uint32_t found;
- rc_t rc1 = VNamelistIndexOf( spotgroups, spotgroup, &found );
- if ( GetRCState( rc1 ) == rcNotFound )
- rc = VNamelistAppend( spotgroups, spotgroup );
- }
- }
- }
- KNamelistRelease( node_childs );
- }
- KMDataNodeRelease( node );
+ if ( from_stats )
+ rc = extract_spotgroups_from_stats( spotgroups, id, meta );
+ KMetadataRelease( meta );
}
+ VTableRelease( tab );
+ }
+ }
+ else
+ {
+ const KMetadata * meta;
+ rc = VDatabaseOpenMetadataRead( id->db, &meta );
+ /* do not report if metadata cannot be found, because this would produce an error message when a database has
+ no metadata at all */
+ if ( rc == 0 )
+ {
+ rc = extract_spotgroups_from_bam_hdr( spotgroups, id, meta );
KMetadataRelease( meta );
}
- VTableRelease( tab );
+
}
}
}
@@ -319,7 +527,7 @@ static rc_t extract_spotgroups( VNamelist * spotgroups, input_files * ifs )
}
-static rc_t print_spotgroups( VNamelist * spotgroups )
+static rc_t print_spotgroups( VNamelist * spotgroups, bool from_stats )
{
uint32_t count;
rc_t rc = VNameListCount( spotgroups, &count );
@@ -332,8 +540,15 @@ static rc_t print_spotgroups( VNamelist * spotgroups )
rc = VNameListGet( spotgroups, i, &s );
if ( rc == 0 && s != NULL )
{
- if ( cmp_pchar( s, "default" ) != 0 )
- rc = KOutMsg( "@RG\tID:%s\n", s );
+ if ( from_stats )
+ {
+ if ( cmp_pchar( s, "default" ) != 0 )
+ rc = KOutMsg( "@RG\tID:%s\n", s );
+ }
+ else
+ {
+ rc = KOutMsg( "%s\n", s );
+ }
}
}
}
@@ -343,13 +558,14 @@ static rc_t print_spotgroups( VNamelist * spotgroups )
static rc_t print_headers_by_recalculating( const samdump_opts * opts, input_files * ifs )
{
- BSTree tree;
rc_t rc = KOutMsg( "@HD\tVN:1.3\n" );
if ( rc == 0 )
{
+ BSTree tree;
+
/* collect sequenc-id's and names and their lengths, unique by sequence-id */
BSTreeInit( &tree );
- rc = print_seq_id_tree( &tree, ifs );
+ rc = build_seq_id_tree( &tree, ifs );
if ( rc == 0 )
{
hdr_print_ctx hctx;
@@ -368,9 +584,12 @@ static rc_t print_headers_by_recalculating( const samdump_opts * opts, input_fil
rc = VNamelistMake( &spotgroups, 10 );
if ( rc == 0 )
{
- rc = extract_spotgroups( spotgroups, ifs );
+ bool from_stats = false;
+ rc = extract_spotgroups( spotgroups, ifs, from_stats );
if ( rc == 0 )
- rc = print_spotgroups( spotgroups );
+ rc = print_spotgroups( spotgroups, from_stats );
+ else
+ rc = 0; /* otherwise the tool would be not able to handle something that has no headers */
VNamelistRelease( spotgroups );
}
}
@@ -379,29 +598,100 @@ static rc_t print_headers_by_recalculating( const samdump_opts * opts, input_fil
}
-rc_t print_headers( const samdump_opts * opts, input_files * ifs )
+static rc_t print_headers_from_file( const samdump_opts * opts )
{
- rc_t rc = 0;
- if ( ifs->database_count > 1 )
- rc = print_headers_by_recalculating( opts, ifs );
+ KDirectory * dir;
+ rc_t rc = KDirectoryNativeDir ( &dir );
+ if ( rc != 0 )
+ {
+ (void)PLOGERR( klogErr, ( klogErr, rc, "cant created native directory for file '$(t)'", "t=%s", opts->header_file ) );
+ }
else
{
- bool recalc = false;
- switch( opts->header_mode )
+ const struct KFile * f;
+ rc = KDirectoryOpenFileRead ( dir, &f, "%s", opts->header_file );
+ if ( rc != 0 )
+ {
+ (void)PLOGERR( klogErr, ( klogErr, rc, "cant open file '$(t)'", "t=%s", opts->header_file ) );
+ }
+ else
{
- case hm_dump : {
- input_database * id = VectorGet( &ifs->dbs, 0 );
- rc = print_headers_from_metadata( id->db, &recalc, id->path );
- if ( rc == 0 && recalc )
- rc = print_headers_by_recalculating( opts, ifs );
+ VNamelist * headers;
+ rc = VNamelistMake ( &headers, 25 );
+ if ( rc != 0 )
+ {
+ (void)PLOGERR( klogErr, ( klogErr, rc, "cant create container for file '$(t)'", "t=%s", opts->header_file ) );
+ }
+ else
+ {
+ rc = LoadKFileToNameList( f, headers );
+ if ( rc != 0 )
+ {
+ (void)PLOGERR( klogErr, ( klogErr, rc, "cant load file '$(t)' into container", "t=%s", opts->header_file ) );
+ }
+ else
+ {
+ uint32_t count;
+ rc = VNameListCount ( headers, &count );
+ if ( rc != 0 )
+ {
+ (void)PLOGERR( klogErr, ( klogErr, rc, "cant get count for container of '$(t)'", "t=%s", opts->header_file ) );
+ }
+ else
+ {
+ uint32_t i;
+ for ( i = 0; i < count && rc == 0; ++i )
+ {
+ const char * line;
+ rc = VNameListGet ( headers, i, &line );
+ if ( rc != 0 )
+ {
+ (void)PLOGERR( klogErr, ( klogErr, rc, "cant get line #$(t) from container", "t=%u", i ) );
+ }
+ else
+ {
+ rc = KOutMsg( "%s\n", line );
}
- break;
+ }
+ }
+ }
+ VNamelistRelease ( headers );
+ }
+ KFileRelease ( f );
+ }
+ KDirectoryRelease ( dir );
+ }
+ return rc;
+}
+
+
+static rc_t print_org_headers( const samdump_opts * opts, input_files * ifs )
+{
+ rc_t rc = 0;
+ bool recalc = ( ifs->database_count > 1 );
+ if ( !recalc )
+ {
+ input_database * id = VectorGet( &ifs->dbs, 0 );
+ rc = print_headers_from_metadata( id->db, &recalc, id->path );
+ }
+ if ( rc == 0 && recalc )
+ rc = print_headers_by_recalculating( opts, ifs );
+ return rc;
+}
+
+
+rc_t print_headers( const samdump_opts * opts, input_files * ifs )
+{
+ rc_t rc = 0;
+ switch( opts->header_mode )
+ {
+ case hm_dump : rc = print_org_headers( opts, ifs ); break;
- case hm_recalc : rc = print_headers_by_recalculating( opts, ifs );
- break;
+ case hm_recalc : rc = print_headers_by_recalculating( opts, ifs ); break;
+
+ case hm_file : rc = print_headers_from_file( opts ); break;
case hm_none : break; /* to not let the compiler complain about not handled enum */
- }
}
/* attach header comments from the commandline */
diff --git a/tools/sra-pileup/sam-unaligned.h b/tools/sra-pileup/sam-unaligned.h
index fe66f0d..47b8b3d 100644
--- a/tools/sra-pileup/sam-unaligned.h
+++ b/tools/sra-pileup/sam-unaligned.h
@@ -40,4 +40,4 @@ extern "C" {
rc_t print_unaligned_spots( const samdump_opts * const opts, const input_files * const ifs,
const matecache * const mc, uint64_t * const rows_so_far );
-#endif
\ No newline at end of file
+#endif
diff --git a/tools/sra-pileup/sra-pileup.vers b/tools/sra-pileup/sra-pileup.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-pileup/sra-pileup.vers
+++ b/tools/sra-pileup/sra-pileup.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-sort/sort-defs.h b/tools/sra-sort/sort-defs.h
index f4aff84..80157a5 100644
--- a/tools/sra-sort/sort-defs.h
+++ b/tools/sra-sort/sort-defs.h
@@ -27,6 +27,21 @@
#ifndef _h_sra_sort_defs_
#define _h_sra_sort_defs_
+#ifndef _h_kfc_callconv_
+#include <kfc/callconv.h>
+#endif
+
+#include <stdint.h>
+#include <stddef.h>
+#include <stdlib.h>
+#include <stdbool.h>
+#include <assert.h>
+
+/* prevent inclusion of <kfc/defs.h> */
+#define _h_kfc_defs_ 1
+
+typedef uint32_t rc_t, ver_t;
+
#ifndef _h_klib_defs_
#include <klib/defs.h>
#endif
diff --git a/tools/sra-sort/sra-sort.vers b/tools/sra-sort/sra-sort.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-sort/sra-sort.vers
+++ b/tools/sra-sort/sra-sort.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/sra-stat/sra-stat.vers b/tools/sra-stat/sra-stat.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/sra-stat/sra-stat.vers
+++ b/tools/sra-stat/sra-stat.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/srapath/srapath.vers b/tools/srapath/srapath.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/srapath/srapath.vers
+++ b/tools/srapath/srapath.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/util/kdbmeta.c b/tools/util/kdbmeta.c
index d9a9b53..da99020 100644
--- a/tools/util/kdbmeta.c
+++ b/tools/util/kdbmeta.c
@@ -99,6 +99,7 @@ static int indent_lvl;
static int tabsz = 2;
static const char *spaces = " ";
static bool as_unsigned = false;
+static bool as_valid_xml = true;
static const char *table_arg = NULL;
static bool read_only_arg = true;
@@ -178,6 +179,34 @@ void attr_select ( const char *name, const char *value )
OUTMSG (( " %s=\"%s\"", name, value ));
}
+static void value_print(char value) {
+ const char *replacement = NULL;
+
+ switch (value) {
+ case '\"':
+ replacement = """;
+ break;
+ case '&':
+ replacement = "&";
+ break;
+ case '<':
+ replacement = "<";
+ break;
+ case '>':
+ replacement = ">";
+ break;
+ default:
+ break;
+ }
+
+ if (replacement != NULL && as_valid_xml) {
+ OUTMSG(("%s", replacement));
+ }
+ else {
+ OUTMSG(("%c", value));
+ }
+}
+
static
void value_select ( const char *value, size_t vlen, uint32_t num_children, bool *close_indent )
{
@@ -276,7 +305,7 @@ void value_select ( const char *value, size_t vlen, uint32_t num_children, bool
tab_stop = 0;
break;
default:
- OUTMSG (( "%c", value [ i ] ));
+ value_print(value[i]);
}
}
OUTMSG (( "'" ));
@@ -659,7 +688,8 @@ bool CC md_select ( void *item, void *data )
if ( pb -> rc != 0 )
{
- PLOGERR ( klogErr, (klogErr, pb -> rc, "failed to open node '$(node) for '$(path)'",
+ PLOGERR ( klogErr, (klogErr, pb -> rc,
+ "failed to open node '$(node)' for '$(path)'",
"node=%s,path=%s", path, pb -> targ ));
}
else
@@ -680,7 +710,8 @@ bool CC md_select ( void *item, void *data )
if ( pb -> rc != 0 )
{
- PLOGERR ( klogErr, (klogErr, pb -> rc, "failed to open node '$(node) for '$(path)'",
+ PLOGERR ( klogErr, (klogErr, pb -> rc,
+ "failed to open node '$(node)' for '$(path)'",
"node=%s,path=%s", path, pb -> targ ));
}
else
@@ -977,8 +1008,6 @@ static const char *const q5 [] = { "<obj>=VALUE","a simple value assignment wher
"values use hex escape codes", NULL };
#endif
-/* static const char* o1[] = { "try to interpret binary values as unsigned ints", NULL }; */
-
#define ALIAS_READ_ONLY "r"
#define OPTION_READ_ONLY "read-only"
static const char* USAGE_READ_ONLY[] = { "operate in read-only mode", NULL };
@@ -992,12 +1021,18 @@ static const char* USAGE_TABLE[] = { "table-name", NULL };
static const char* USAGE_UNSIGNED[]
= { "print numeric values as unsigned", NULL };
+#define OPTION_OUT "output"
+#define ALIAS_OUT "X"
+static const char* USAGE_OUT[] = { "Output type: one of (xml text): ",
+ "whether to generate well-formed XML. Default: xml (well-formed)", NULL };
+
const OptDef opt[] = {
{ OPTION_TABLE , ALIAS_TABLE , NULL, USAGE_TABLE , 1, true , false }
,{ OPTION_UNSIGNED , ALIAS_UNSIGNED , NULL, USAGE_UNSIGNED , 1, false, false }
#if ALLOW_UPDATE
,{ OPTION_READ_ONLY, ALIAS_READ_ONLY, NULL, USAGE_READ_ONLY, 1, false, false }
#endif
+ ,{ OPTION_OUT , ALIAS_OUT , NULL, USAGE_OUT , 1, true , false }
};
static const char * const * target_usage [] = { t1, t2, t3, t4 };
@@ -1048,7 +1083,14 @@ rc_t CC Usage (const Args * args)
"Options:\n"));
for(idx = 0; idx < sizeof(opt) / sizeof(opt[0]); ++idx) {
- HelpOptionLine(opt[idx].aliases, opt[idx].name, NULL, opt[idx].help);
+ const char *param = NULL;
+ if (strcmp(opt[idx].aliases, ALIAS_TABLE) == 0) {
+ param = "table";
+ }
+ else if (strcmp(opt[idx].aliases, ALIAS_OUT) == 0) {
+ param = "value";
+ }
+ HelpOptionLine(opt[idx].aliases, opt[idx].name, param, opt[idx].help);
}
HelpOptionsStandard ();
@@ -1124,6 +1166,24 @@ rc_t CC KMain ( int argc, char *argv [] )
}
}
+ rc = ArgsOptionCount (args, OPTION_OUT, &pcount);
+ if (rc) {
+ LOGERR(klogErr, rc, "Failure to get '" OPTION_OUT "' argument");
+ break;
+ }
+ if (pcount) {
+ const char* dummy = NULL;
+ rc = ArgsOptionValue (args, OPTION_OUT, 0, &dummy);
+ if (rc) {
+ LOGERR(klogErr, rc,
+ "Failure to get '" OPTION_OUT "' argument");
+ break;
+ }
+ else if (strcmp(dummy, "t") == 0) {
+ as_valid_xml = false;
+ }
+ }
+
rc = ArgsParamCount (args, &pcount);
if (rc)
break;
@@ -1166,7 +1226,7 @@ rc_t CC KMain ( int argc, char *argv [] )
found = false;
#if ! WINDOWS /* TOOLS_USE_SRAPATH != 0 */
-#warning fix kdbmanagerVPathType to understand accessions
+/* done? warning fix kdbmanagerVPathType to understand accessions */
{
const VFSManager * vfs;
rc = KDBManagerGetVFSManager ( mgr, & vfs );
diff --git a/tools/util/kdbmeta.vers b/tools/util/kdbmeta.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/util/kdbmeta.vers
+++ b/tools/util/kdbmeta.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/util/mac/syspass.c b/tools/util/mac/syspass.c
index 2a2d9f1..550af53 100644
--- a/tools/util/mac/syspass.c
+++ b/tools/util/mac/syspass.c
@@ -45,4 +45,4 @@ rc_t get_pass(const char *prompt, char *buf, size_t bufsiz) {
}
return 0;
-}
\ No newline at end of file
+}
diff --git a/tools/util/md5cp.vers b/tools/util/md5cp.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/util/md5cp.vers
+++ b/tools/util/md5cp.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/util/rcexplain.vers b/tools/util/rcexplain.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/util/rcexplain.vers
+++ b/tools/util/rcexplain.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/util/rowwritetest.vers b/tools/util/rowwritetest.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/util/rowwritetest.vers
+++ b/tools/util/rowwritetest.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/util/schema-replace.vers b/tools/util/schema-replace.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/util/schema-replace.vers
+++ b/tools/util/schema-replace.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/util/test-sra.c b/tools/util/test-sra.c
index c27895c..4956951 100644
--- a/tools/util/test-sra.c
+++ b/tools/util/test-sra.c
@@ -46,22 +46,24 @@
#include <vdb/table.h> /* VDBManagerOpenTableRead */
#include <kns/ascp.h> /* ascp_locate */
-#include <kns/curl-file.h> /* KCurlFileMake */
-#include <kns/KCurlRequest.h> /* KCurlRequestRelease */
+#include <kns/http.h>
+#include <kns/manager.h>
#include <kns/manager-ext.h> /* KNSManagerNewReleaseVersion */
+#include <kns/stream.h>
#include <kdb/manager.h> /* kptDatabase */
#include <kfs/directory.h> /* KDirectory */
#include <kfs/file.h> /* KFile */
-#include <klib/sra-release-version.h>
#include <klib/data-buffer.h> /* KDataBuffer */
+#include <klib/debug.h> /* DBGMSG */
#include <klib/log.h> /* KLogHandlerSet */
#include <klib/out.h> /* KOutMsg */
#include <klib/printf.h> /* string_vprintf */
#include <klib/rc.h>
#include <klib/report.h> /* ReportForceFinalize */
+#include <klib/sra-release-version.h>
#include <klib/text.h> /* String */
#include <sysalloc.h>
@@ -87,7 +89,7 @@ typedef enum {
eResolve = 2,
eDependMissing = 4,
eDependAll = 8,
- eCurl = 16,
+/* eCurl = 16, */
eVersion = 32,
eNewVersion = 64,
eOpenTable = 128,
@@ -294,7 +296,9 @@ static TTest processTests(TTest testsOn, TTest testsOff) {
static void MainMakeQuick(Main *self) {
assert(self);
+#if 0
self->tests = eCurl;
+#endif
}
static void MainAddTest(Main *self, Type type) {
@@ -327,9 +331,11 @@ static void MainPrint(const Main *self) {
KOutMsg("eDependAll\n");
}
+#if 0
if (MainHasTest(self, eCurl)) {
KOutMsg("eCurl\n");
}
+#endif
if (MainHasTest(self, eVersion)) {
KOutMsg("eVersion\n");
@@ -383,10 +389,6 @@ static rc_t MainInitObjects(Main *self) {
}
if (rc == 0) {
- rc = KNSManagerMake(&self->knsMgr);
- }
-
- if (rc == 0) {
rc = KConfigMakeRepositoryMgrRead(self->cfg, &self->repoMgr);
}
@@ -399,6 +401,10 @@ static rc_t MainInitObjects(Main *self) {
}
if (rc == 0) {
+ rc = VFSManagerGetKNSMgr(self->vMgr, &self->knsMgr);
+ }
+
+ if (rc == 0) {
if (!self->allowCaching) {
self->cacheState = VResolverCacheEnable(resolver, vrAlwaysDisable);
}
@@ -464,12 +470,12 @@ static char** MainInit(Main *self, int argc, char *argv[], int *argi) {
return argv2;
}
-static rc_t MainCallCgi(const Main *self,
+static rc_t MainCallCgiImpl(const Main *self,
const KConfigNode *node, const char *acc)
{
rc_t rc = 0;
String *url = NULL;
- struct KCurlRequest *req = NULL;
+ KHttpRequest *req = NULL;
KDataBuffer result;
memset(&result, 0, sizeof result);
assert(self && node && acc);
@@ -480,18 +486,64 @@ static rc_t MainCallCgi(const Main *self,
}
}
if (rc == 0) {
- rc = KNSManagerMakeCurlRequest(self->knsMgr, &req, url->addr, false);
+ rc = KNSManagerMakeRequest(self->knsMgr,
+ &req, 0x01000000, NULL, url->addr);
}
if (rc == 0) {
- size_t s = string_size(acc);
- String name;
- String value;
- CONST_STRING(&name, "acc");
- StringInit(&value, acc, s, (uint32_t)s);
- rc = KCurlRequestAddSField(req, &name, &value);
+ rc = KHttpRequestAddPostParam ( req, "acc=%s", acc );
}
if (rc == 0) {
- rc = KCurlRequestPerform(req, &result);
+ KHttpResult *rslt;
+ rc = KHttpRequestPOST ( req, & rslt );
+ if ( rc == 0 )
+ {
+ uint32_t code;
+ size_t msg_size;
+ char msg_buff [ 256 ];
+ rc = KHttpResultStatus(rslt,
+ & code, msg_buff, sizeof msg_buff, & msg_size);
+ if ( rc == 0 && code == 200 )
+ {
+ KStream * response;
+ rc = KHttpResultGetInputStream ( rslt, & response );
+ if ( rc == 0 )
+ {
+ size_t num_read;
+ size_t total = 0;
+ KDataBufferMakeBytes ( & result, 4096 );
+ while ( 1 )
+ {
+ uint8_t *base;
+ uint64_t avail = result . elem_count - total;
+ if ( avail < 256 )
+ {
+ rc = KDataBufferResize ( & result, result . elem_count + 4096 );
+ if ( rc != 0 )
+ break;
+ }
+
+ base = result . base;
+ rc = KStreamRead ( response, & base [ total ], result . elem_count - total, & num_read );
+ if ( rc != 0 )
+ {
+ if ( num_read > 0 )
+ rc = 0;
+ else
+ break;
+ }
+
+ if ( num_read == 0 )
+ break;
+
+ total += num_read;
+ }
+
+ KStreamRelease ( response );
+ }
+ }
+
+ KHttpResultRelease ( rslt );
+ }
}
if (rc == 0) {
const char *start = (const void*)(result.base);
@@ -504,7 +556,7 @@ static rc_t MainCallCgi(const Main *self,
}
}
KDataBufferWhack(&result);
- RELEASE(KCurlRequest, req);
+ RELEASE(KHttpRequest, req);
free(url);
if (rc == 0) {
OUTMSG(("NCBI access: ok\n"));
@@ -515,6 +567,22 @@ static rc_t MainCallCgi(const Main *self,
return rc;
}
+static rc_t MainCallCgi(const Main *self,
+ const KConfigNode *node, const char *acc)
+{
+ rc_t rc = 0;
+ int i = 0, retryOnFailure = 2;
+ for (i = 0; i < retryOnFailure; ++i) {
+ rc = MainCallCgiImpl(self, node, acc);
+ if (rc == 0) {
+ break;
+ }
+ DBGMSG(DBG_KNS, DBG_FLAG(DBG_KNS_ERR), (
+ "@@@@@@@@2: MainCallCgi %d/%d = %R\n", i + 1, retryOnFailure, rc));
+ }
+ return rc;
+}
+
#define rcResolver rcTree
static rc_t MainQuickResolveQuery(const Main *self, const char *acc) {
rc_t rc = 0;
@@ -1064,14 +1132,40 @@ static rc_t MainResolveRemote(const Main *self, VResolver *resolver,
const KFile* f = NULL;
- assert(self && size);
+ assert(self && size && remote);
if (resolver == NULL) {
resolver = self->resolver;
}
rc = VResolverRemote(resolver,
- fasp ? eProtocolFaspHttp : eProtocolHttp, acc, remote, &f);
+ fasp ? eProtocolFaspHttp : eProtocolHttp, acc, remote);
+
+ if (rc == 0) {
+ rc_t rc = 0;
+ String str;
+ memset(&str, 0, sizeof str);
+ rc = VPathGetScheme(*remote, &str);
+ if (rc != 0) {
+ OUTMSG(("VPathGetScheme(%S) = %R\n", *remote, rc));
+ }
+ else {
+ String fasp;
+ CONST_STRING(&fasp, "fasp");
+ if (StringCompare(&str, &fasp) != 0) {
+ char path_str[8192];
+ rc = VPathReadUri(*remote, path_str, sizeof path_str, NULL);
+ if (rc != 0) {
+ OUTMSG(("VPathReadUri(%S) = %R\n", *remote, rc));
+ }
+ else {
+ rc = KNSManagerMakeHttpFile
+ (self->knsMgr, &f, NULL, 0x01010000, path_str);
+ }
+ }
+ }
+ }
+
rc = MainPathReport(self,
rc, *remote, ePathRemote, name, NULL, size, fasp, f);
RELEASE(KFile, f);
@@ -1092,8 +1186,6 @@ static rc_t MainResolveCache(const Main *self, const VResolver *resolver,
rc, cache, ePathCache, name, remote, NULL, fasp, NULL);
}
else {
- uint64_t file_size = 0;
-
if (resolver == NULL) {
resolver = self->resolver;
}
@@ -1101,7 +1193,8 @@ static rc_t MainResolveCache(const Main *self, const VResolver *resolver,
if (!self->allowCaching) {
VResolverCacheEnable(resolver, self->cacheState);
}
- rc = VResolverCache(resolver, remote, &cache, file_size);
+ rc = VResolverQuery(resolver, fasp ? eProtocolFasp : eProtocolHttp,
+ remote, NULL, NULL, &cache);
rc = MainPathReport(self,
rc, cache, ePathCache, name, remote, NULL, fasp, NULL);
@@ -1126,7 +1219,7 @@ static rc_t VResolverQueryByType(const Main *self, const VResolver *resolver,
const char *eol = "\n";
rc_t rc = 0;
- rc_t rc2 = 0;
+
const VPath *local = NULL;
const VPath *remote = NULL;
const VPath *cache = NULL;
@@ -1166,15 +1259,15 @@ static rc_t VResolverQueryByType(const Main *self, const VResolver *resolver,
pCache == NULL ? "=NULL" : "", rc, eol));
if (rc == 0) {
if (local != NULL) {
- rc2 = MainPathReport(self,
+/* rc2 =*/ MainPathReport(self,
rc, local, ePathLocal, name, NULL, NULL, false, NULL);
}
if (remote != NULL) {
- rc2 = MainPathReport(self,
+/* rc2 =*/ MainPathReport(self,
rc, remote, ePathRemote, name, NULL, NULL, fasp, NULL);
}
if (cache != NULL) {
- rc2 = MainPathReport(self,
+/* rc2 =*/ MainPathReport(self,
rc, cache, ePathCache, name, remote, NULL, fasp, NULL);
}
}
@@ -1508,9 +1601,9 @@ rc_t MainDepend(const Main *self, const char *name, bool missing)
OUTMSG(("%s\tpathRemote: %s ", eol, s));
if (!self->noRfs) {
const KFile *f = NULL;
- rc2 = KCurlFileMake(&f, s, false);
+ rc2 = KNSManagerMakeHttpFile ( self->knsMgr, & f, NULL, 0x01010000, s );
if (rc2 != 0) {
- OUTMSG(("KCurlFileMake=%R", rc2));
+ OUTMSG(("KNSManagerMakeHttpFile=%R", rc2));
if (rc == 0) {
rc = rc2;
}
@@ -1675,6 +1768,7 @@ static rc_t MainPrintAscp(const Main *self) {
return 0;
}
+#if 0
static rc_t PrintCurl(bool full, bool xml) {
const char *b = xml ? " <Curl>" : "";
const char *e = xml ? "</Curl>" : "";
@@ -1716,6 +1810,7 @@ static rc_t PrintCurl(bool full, bool xml) {
return rc;
}
+#endif
#define kptKartITEM (kptAlias - 1)
@@ -1932,13 +2027,18 @@ rc_t _SraReleaseVersionPrint(const SraReleaseVersion *self, rc_t rc, bool xml,
static rc_t MainPrintVersion(Main *self) {
const char root[] = "Version";
+
rc_t rc = 0;
+
SraReleaseVersion version;
SraReleaseVersion newVersion;
+
assert(self);
+
if (MainHasTest(self, eNewVersion)) {
MainAddTest(self, eVersion);
}
+
if (!MainHasTest(self, eVersion)) {
return 0;
}
@@ -1978,6 +2078,7 @@ static rc_t MainPrintVersion(Main *self) {
}
}
}
+
if (self->xml) {
OUTMSG(("</%s>\n", root));
}
@@ -2152,9 +2253,11 @@ rc_t CC KMain(int argc, char *argv[]) {
MainPrintAscp(&prms);
}
+#if 0
if (MainHasTest(&prms, eCurl)) {
PrintCurl(prms.full, prms.xml);
}
+#endif
if (!prms.full) {
rc_t rc2 = MainQuickCheck(&prms);
diff --git a/tools/util/test-sra.vers b/tools/util/test-sra.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/util/test-sra.vers
+++ b/tools/util/test-sra.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/util/testld.vers b/tools/util/testld.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/util/testld.vers
+++ b/tools/util/testld.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/util/txt2kdb.vers b/tools/util/txt2kdb.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/util/txt2kdb.vers
+++ b/tools/util/txt2kdb.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/util/vdb-lock.vers b/tools/util/vdb-lock.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/util/vdb-lock.vers
+++ b/tools/util/vdb-lock.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/util/vdb-passwd.vers b/tools/util/vdb-passwd.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/util/vdb-passwd.vers
+++ b/tools/util/vdb-passwd.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/util/vdb-unlock.vers b/tools/util/vdb-unlock.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/util/vdb-unlock.vers
+++ b/tools/util/vdb-unlock.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/vdb-config/vdb-config.c b/tools/vdb-config/vdb-config.c
index 5263c6d..c346d54 100644
--- a/tools/vdb-config/vdb-config.c
+++ b/tools/vdb-config/vdb-config.c
@@ -40,6 +40,7 @@
#include <kfs/kfs-priv.h> /* KSysDirOSPath */
#include <klib/log.h> /* LOGERR */
+#include <klib/misc.h> /* is_iser_an_admin */
#include <klib/namelist.h>
#include <klib/out.h> /* OUTMSG */
#include <klib/printf.h> /* string_printf */
@@ -54,7 +55,6 @@
#include <stdio.h> /* scanf */
#include <stdlib.h> /* getenv */
#include <string.h> /* memset */
-/* #include <unistd.h> access */
#include <limits.h> /* PATH_MAX */
@@ -106,6 +106,11 @@ static const char* USAGE_OUT[] = { "output type: one of (x n), "
#define OPTION_CFG "cfg"
static const char* USAGE_CFG[] = { "print current configuration", NULL };
+#define ALIAS_ROOT NULL
+#define OPTION_ROOT "root"
+static const char* USAGE_ROOT[] =
+ { "enforce configuration update while being run by superuser", NULL };
+
#define ALIAS_SET "s"
#define OPTION_SET "set"
static const char* USAGE_SET[] = { "set configuration node value", NULL };
@@ -122,6 +127,7 @@ OptDef Options[] =
, { OPTION_NEW, ALIAS_NEW, NULL, USAGE_NEW, 1, false, false }
, { OPTION_OUT, ALIAS_OUT, NULL, USAGE_OUT, 1, true , false }
, { OPTION_SET, ALIAS_SET, NULL, USAGE_SET, 1, true , false }
+ , { OPTION_ROOT,ALIAS_ROOT,NULL, USAGE_ROOT,1, false, false }
};
rc_t CC UsageSummary (const char * progname) {
@@ -151,7 +157,6 @@ rc_t CC Usage(const Args* args) {
HelpOptionLine (ALIAS_ALL, OPTION_ALL, NULL, USAGE_ALL);
HelpOptionLine (ALIAS_CFG, OPTION_CFG, NULL, USAGE_CFG);
-/* HelpOptionLine (ALIAS_NEW, OPTION_MOD, NULL, USAGE_NEW); */
HelpOptionLine (ALIAS_FIL, OPTION_FIL, NULL, USAGE_FIL);
HelpOptionLine (ALIAS_ENV, OPTION_ENV, NULL, USAGE_ENV);
HelpOptionLine (ALIAS_MOD, OPTION_MOD, NULL, USAGE_MOD);
@@ -161,6 +166,8 @@ rc_t CC Usage(const Args* args) {
HelpOptionLine (ALIAS_IMP, OPTION_IMP, "ngc-file", USAGE_IMP);
KOutMsg ("\n");
HelpOptionLine (ALIAS_OUT, OPTION_OUT, "x | n", USAGE_OUT);
+ KOutMsg ("\n");
+ HelpOptionLine (ALIAS_ROOT,OPTION_ROOT,NULL, USAGE_ROOT);
KOutMsg ("\n");
@@ -194,7 +201,7 @@ static rc_t KConfigNodeReadData(const KConfigNode* self,
return rc;
}
-static rc_t _printNodeData(const char *name, const char *data, uint32_t dlen) {
+static rc_t _printNodeData(const char *name, const char *data, size_t dlen) {
const char ticket[] = "download-ticket";
size_t l = sizeof ticket - 1;
if (string_cmp(name, string_measure(name, NULL),
@@ -207,7 +214,7 @@ static rc_t _printNodeData(const char *name, const char *data, uint32_t dlen) {
dlen = 70;
ellipsis = "...";
}
- return OUTMSG(("%.*s%s", dlen, replace, ellipsis));
+ return OUTMSG(("%.*s%s", (uint32_t)dlen, replace, ellipsis));
}
else {
return OUTMSG(("%.*s", dlen, data));
@@ -233,7 +240,7 @@ static rc_t KConfigNodePrintChildNames(bool xml, const KConfigNode* self,
{ rc = KConfigNodeOpenNodeRead(self, &node, name); }
if (rc == 0) {
rc = KConfigNodeReadData(node, buffer, sizeof buffer, &num_read);
- hasData = num_read;
+ hasData = num_read > 0;
if (hasData) {
/* VDB_CONGIG_OUTMSG(("\n%s = \"%.*s\"\n\n", aFullpath, num_read, buffer)); */
}
@@ -265,18 +272,20 @@ static rc_t KConfigNodePrintChildNames(bool xml, const KConfigNode* self,
{ VDB_CONGIG_OUTMSG(("\n"));}
if (hasChildren) {
- for (i = 0; i < count && rc == 0; ++i) {
+ for (i = 0; i < (int)count && rc == 0; ++i) {
char* fullpath = NULL;
const char* name = NULL;
rc = KNamelistGet(names, i, &name);
if (rc == 0) {
- fullpath = malloc(strlen(aFullpath) + 1 + strlen(name) + 1);
+ size_t bsize = strlen(aFullpath) + 1 + strlen(name);
+ fullpath = malloc(bsize + 1);
if (fullpath == NULL) {
rc = RC
(rcExe, rcStorage, rcAllocating, rcMemory, rcExhausted);
}
else {
- sprintf(fullpath, "%s/%s", aFullpath, name);
+ string_printf(fullpath, bsize, NULL,
+ "%s/%s", aFullpath, name);
}
}
if (rc == 0) {
@@ -315,6 +324,7 @@ typedef struct Params {
bool modeShowFiles;
bool modeShowLoadPath;
bool modeShowModules;
+ bool modeRoot;
bool showMultiple;
} Params;
@@ -444,8 +454,17 @@ static rc_t ParamsConstruct(int argc, char* argv[], Params* prm) {
++count;
}
+ rc = ArgsOptionCount(args, OPTION_ROOT, &pcount);
+ if (rc != 0) {
+ LOGERR(klogErr, rc, "Failure to get '" OPTION_ROOT "' argument");
+ break;
+ }
+ if (pcount) {
+ prm->modeRoot = true;
+ }
+
rc = ArgsOptionCount(args, OPTION_SET, &pcount);
- if (rc) {
+ if (rc != 0) {
LOGERR(klogErr, rc, "Failure to get '" OPTION_SET "' argument");
break;
}
@@ -577,8 +596,9 @@ static rc_t In(const char* prompt, const char* def, char** read) {
else
{ break; }
}
- if (buf[0] == '\0' && def)
- { strcpy(buf, def); }
+ if (buf[0] == '\0' && def != NULL) {
+ string_copy_measure(buf, sizeof buf, def);
+ }
if (buf[0]) {
*read = strdup(buf);
if (*read == NULL) {
@@ -601,7 +621,8 @@ static rc_t CC scan_config_dir(const KDirectory* dir,
case kptFile | kptAlias: {
size_t sz = strlen(name);
if (sz >= 5 && strcase_cmp(&name[sz - 4], 4, ".kfg", 4, 4) == 0) {
- strcpy(data, name);
+ string_copy_measure(data, PATH_MAX + 1, name);
+ /* from CreateConfig..KDirectoryVVisit call */
rc = RC(rcExe, rcDirectory, rcListing, rcFile, rcExists);
}
break;
@@ -802,6 +823,12 @@ static rc_t SetNode(KConfig* cfg, const Params* prm) {
assert(cfg && prm && prm->setValue);
+ if (is_iser_an_admin() && !prm->modeRoot) {
+ rc = RC(rcExe, rcNode, rcUpdating, rcCondition, rcViolated);
+ LOGERR(klogErr, rc, "Warning: "
+ "normally this application should not be run as root/superuser");
+ }
+
name = strdup(prm->setValue);
if (name == NULL)
{ return RC(rcExe, rcStorage, rcAllocating, rcMemory, rcExhausted); }
@@ -949,12 +976,13 @@ static rc_t ShowConfig(const KConfig* cfg, Params* prm) {
if (rc == 0) {
char* fullname = NULL;
if (strcmp(root, "/") == 0) {
- fullname = malloc(strlen(name) + 2);
+ size_t bsize = strlen(name) + 2;
+ fullname = malloc(bsize);
if (fullname == NULL) {
rc = RC(rcExe,
rcStorage, rcAllocating, rcMemory, rcExhausted);
}
- sprintf(fullname, "/%s", name);
+ string_printf(fullname, bsize, NULL, "/%s", name);
}
else {
size_t sz = strlen(root) + 2 + strlen(name);
diff --git a/tools/vdb-config/vdb-config.vers b/tools/vdb-config/vdb-config.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/vdb-config/vdb-config.vers
+++ b/tools/vdb-config/vdb-config.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/vdb-copy/vdb-copy.vers b/tools/vdb-copy/vdb-copy.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/vdb-copy/vdb-copy.vers
+++ b/tools/vdb-copy/vdb-copy.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/vdb-decrypt/vdb-decrypt.vers b/tools/vdb-decrypt/vdb-decrypt.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/vdb-decrypt/vdb-decrypt.vers
+++ b/tools/vdb-decrypt/vdb-decrypt.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/vdb-decrypt/vdb-encrypt.vers b/tools/vdb-decrypt/vdb-encrypt.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/vdb-decrypt/vdb-encrypt.vers
+++ b/tools/vdb-decrypt/vdb-encrypt.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/vdb-dump/vdb-dump-coldefs.c b/tools/vdb-dump/vdb-dump-coldefs.c
index fac3f38..2f15da6 100644
--- a/tools/vdb-dump/vdb-dump-coldefs.c
+++ b/tools/vdb-dump/vdb-dump-coldefs.c
@@ -356,9 +356,9 @@ static p_col_def vdcd_append_col( col_defs* defs, const char* name )
}
-bool vdcd_parse_string( col_defs* defs, const char* src, const VTable *my_table )
+uint32_t vdcd_parse_string( col_defs* defs, const char* src, const VTable *my_table )
{
- uint32_t count = 0;
+ uint32_t count, found = 0;
char colname[MAX_COL_NAME_LEN+1];
size_t i_dest = 0;
if ( defs == NULL ) return false;
@@ -385,7 +385,7 @@ bool vdcd_parse_string( col_defs* defs, const char* src, const VTable *my_table
colname[i_dest]=0;
vdcd_append_col( defs, colname );
}
- count = VectorLength( &(defs->cols) ) > 0;
+ count = VectorLength( &defs->cols );
if ( count > 0 && my_table != NULL )
{
const VCursor *my_cursor;
@@ -393,9 +393,8 @@ bool vdcd_parse_string( col_defs* defs, const char* src, const VTable *my_table
DISP_RC( rc, "VTableCreateCursorRead() failed" );
if ( rc == 0 )
{
- uint32_t found = 0;
uint32_t idx;
- for ( idx = 0; idx < count && rc == 0; ++idx )
+ for ( idx = 0; idx < count; ++idx )
{
col_def *col = ( col_def * )VectorGet( &(defs->cols), idx );
if ( col != NULL )
@@ -412,18 +411,17 @@ bool vdcd_parse_string( col_defs* defs, const char* src, const VTable *my_table
}
}
}
- count = found;
rc = VCursorRelease( my_cursor );
DISP_RC( rc, "VCursorRelease() failed" );
}
}
- return ( count > 0 );
+ return found;
}
-bool vdcd_extract_from_table( col_defs* defs, const VTable *my_table )
+uint32_t vdcd_extract_from_table( col_defs* defs, const VTable *my_table )
{
- bool col_defs_found = false;
+ uint32_t found = 0;
KNamelist *names;
rc_t rc = VTableListCol( my_table, &names );
DISP_RC( rc, "VTableListCol() failed" );
@@ -435,7 +433,6 @@ bool vdcd_extract_from_table( col_defs* defs, const VTable *my_table )
if ( rc == 0 )
{
uint32_t n;
- uint32_t found = 0;
rc = KNamelistCount( names, &n );
DISP_RC( rc, "KNamelistCount() failed" );
if ( rc == 0 )
@@ -463,7 +460,6 @@ bool vdcd_extract_from_table( col_defs* defs, const VTable *my_table )
}
}
}
- col_defs_found = ( found > 0 );
}
rc = VCursorRelease( my_cursor );
DISP_RC( rc, "VCursorRelease() failed" );
@@ -471,7 +467,7 @@ bool vdcd_extract_from_table( col_defs* defs, const VTable *my_table )
rc = KNamelistRelease( names );
DISP_RC( rc, "KNamelistRelease() failed" );
}
- return col_defs_found;
+ return found;
}
@@ -516,6 +512,7 @@ typedef struct add_2_cur_context
} add_2_cur_context;
typedef add_2_cur_context* p_add_2_cur_context;
+
static void CC vdcd_add_1_to_cursor( void *item, void *data )
{
rc_t rc;
@@ -544,15 +541,17 @@ static void CC vdcd_add_1_to_cursor( void *item, void *data )
}
}
-bool vdcd_add_to_cursor( col_defs* defs, const VCursor *my_cursor )
+
+uint32_t vdcd_add_to_cursor( col_defs* defs, const VCursor *my_cursor )
{
add_2_cur_context ctx;
ctx.count = 0;
ctx.my_cursor = my_cursor;
VectorForEach( &(defs->cols), false, vdcd_add_1_to_cursor, &ctx );
- return ( ctx.count > 0 );
+ return ctx.count;
}
+
static void CC vdcd_reset_1_content( void *item, void *data )
{
rc_t rc;
diff --git a/tools/vdb-dump/vdb-dump-coldefs.h b/tools/vdb-dump/vdb-dump-coldefs.h
index d45b66a..f884ac2 100644
--- a/tools/vdb-dump/vdb-dump-coldefs.h
+++ b/tools/vdb-dump/vdb-dump-coldefs.h
@@ -87,10 +87,10 @@ char *vdcd_make_domain_txt( const uint32_t domain );
bool vdcd_init( col_defs** defs, const size_t str_limit );
void vdcd_destroy( col_defs* defs );
-bool vdcd_parse_string( col_defs* defs, const char* src, const VTable *my_table );
-bool vdcd_extract_from_table( col_defs* defs, const VTable *my_table );
+uint32_t vdcd_parse_string( col_defs* defs, const char* src, const VTable *my_table );
+uint32_t vdcd_extract_from_table( col_defs* defs, const VTable *my_table );
bool vdcd_extract_from_phys_table( col_defs* defs, const VTable *my_table );
-bool vdcd_add_to_cursor( col_defs* defs, const VCursor *my_cursor );
+uint32_t vdcd_add_to_cursor( col_defs* defs, const VCursor *my_cursor );
void vdcd_reset_content( col_defs* defs );
void vdcd_ins_trans_fkt( col_defs* defs, const VSchema *my_schema );
void vdcd_exclude_these_columns( col_defs* defs, const char* column_names );
diff --git a/tools/vdb-dump/vdb-dump-context.c b/tools/vdb-dump/vdb-dump-context.c
index a4232e1..87e7520 100644
--- a/tools/vdb-dump/vdb-dump-context.c
+++ b/tools/vdb-dump/vdb-dump-context.c
@@ -106,8 +106,8 @@ static void vdco_init_values( p_dump_context ctx )
ctx->dont_check_accession = false;
ctx->print_num_elem = false;
ctx->objver_requested = false;
+ ctx->objts_requested = false;
ctx->objtype_requested = false;
- ctx->check_curl = false;
ctx->idx_enum_requested = false;
ctx->idx_range_requested = false;
ctx->disable_multithreading = false;
@@ -479,6 +479,7 @@ static void vdco_evaluate_options( const Args *my_args,
ctx->column_enum_short = vdco_get_bool_option( my_args, OPTION_COLUMN_SHORT, false );
ctx->print_dna_bases = vdco_get_bool_option( my_args, OPTION_DNA_BASES, false );
ctx->objver_requested = vdco_get_bool_option( my_args, OPTION_OBJVER, false );
+ ctx->objts_requested = vdco_get_bool_option( my_args, OPTION_OBJTS, false );
ctx->objtype_requested = vdco_get_bool_option( my_args, OPTION_OBJTYPE, false );
ctx->max_line_len = vdco_get_uint16_option( my_args, OPTION_MAX_LINE_LEN, 0 );
ctx->indented_line_len = vdco_get_uint16_option( my_args, OPTION_LINE_INDENT, 0 );
@@ -490,7 +491,6 @@ static void vdco_evaluate_options( const Args *my_args,
ctx->sum_num_elem = vdco_get_bool_option( my_args, OPTION_NUMELEMSUM, false );
ctx->show_blobbing = vdco_get_bool_option( my_args, OPTION_SHOW_BLOBBING, false );
ctx->enum_phys = vdco_get_bool_option( my_args, OPTION_ENUM_PHYS, false );
- ctx->check_curl = vdco_get_bool_option( my_args, OPTION_CHECK_CURL, false );
ctx->idx_enum_requested = vdco_get_bool_option( my_args, OPTION_IDX_ENUM, false );
ctx->disable_multithreading = vdco_get_bool_option( my_args, OPTION_NO_MULTITHREAD, false );
diff --git a/tools/vdb-dump/vdb-dump-context.h b/tools/vdb-dump/vdb-dump-context.h
index 3d96e02..0d976ca 100644
--- a/tools/vdb-dump/vdb-dump-context.h
+++ b/tools/vdb-dump/vdb-dump-context.h
@@ -62,12 +62,12 @@ extern "C" {
#define OPTION_EXCLUDED_COLUMNS "exclude"
#define OPTION_BOOLEAN "boolean"
#define OPTION_OBJVER "obj_version"
+#define OPTION_OBJTS "obj_timestamp"
#define OPTION_OBJTYPE "obj_type"
#define OPTION_NUMELEM "numelem"
#define OPTION_NUMELEMSUM "numelemsum"
#define OPTION_SHOW_BLOBBING "blobbing"
#define OPTION_ENUM_PHYS "phys"
-#define OPTION_CHECK_CURL "check-curl"
#define OPTION_IDX_ENUM "idx-report"
#define OPTION_IDX_RANGE "idx-range"
#define OPTION_CUR_CACHE "cur-cache"
@@ -159,12 +159,12 @@ typedef struct dump_context
bool without_sra_types;
bool dont_check_accession;
bool objver_requested;
+ bool objts_requested;
bool objtype_requested;
bool print_num_elem;
bool sum_num_elem;
bool show_blobbing;
bool enum_phys;
- bool check_curl;
bool idx_enum_requested;
bool idx_range_requested;
bool disable_multithreading;
diff --git a/tools/vdb-dump/vdb-dump-fastq.c b/tools/vdb-dump/vdb-dump-fastq.c
index c3c660b..8c1b7e7 100644
--- a/tools/vdb-dump/vdb-dump-fastq.c
+++ b/tools/vdb-dump/vdb-dump-fastq.c
@@ -31,6 +31,7 @@
#include <stdlib.h>
#include <kdb/manager.h>
+#include <vdb/vdb-priv.h>
#include <klib/log.h>
#include <klib/out.h>
@@ -256,6 +257,8 @@ static rc_t vdb_prepare_cursor( const p_dump_context ctx, const VTable * tbl, fa
if ( rc == 0 )
rc = VCursorAddColumn( fctx->cursor, &fctx->idx_name, "(ascii)NAME" );
if ( rc == 0 )
+ rc = VCursorPermitPostOpenAdd ( fctx->cursor );
+ if ( rc == 0 )
rc = VCursorOpen ( fctx->cursor );
if ( rc != 0 )
diff --git a/tools/vdb-dump/vdb-dump.c b/tools/vdb-dump/vdb-dump.c
index e09a771..85dc13d 100644
--- a/tools/vdb-dump/vdb-dump.c
+++ b/tools/vdb-dump/vdb-dump.c
@@ -55,6 +55,7 @@
#include <klib/printf.h>
#include <klib/rc.h>
#include <klib/namelist.h>
+#include <klib/time.h>
#include <os-native.h>
#include <sysalloc.h>
@@ -95,6 +96,7 @@ static const char * without_accession_usage[] = { "without accession-test", NULL
static const char * excluded_columns_usage[] = { "exclude these columns", NULL };
static const char * boolean_usage[] = { "defines how boolean's are printed (1,T)", NULL };
static const char * objver_usage[] = { "request vdb-version", NULL };
+static const char * objts_usage[] = { "request object modification date", NULL };
static const char * numelem_usage[] = { "print only element-count", NULL };
static const char * numelemsum_usage[] = { "sum element-count", NULL };
static const char * show_blobbing_usage[] = { "show blobbing", NULL };
@@ -138,8 +140,8 @@ OptDef DumpOptions[] =
{ OPTION_NUMELEMSUM, ALIAS_NUMELEMSUM, NULL, numelemsum_usage, 1, false, false },
{ OPTION_SHOW_BLOBBING, NULL, NULL, show_blobbing_usage, 1, false, false },
{ OPTION_ENUM_PHYS, NULL, NULL, enum_phys_usage, 1, false, false },
- { OPTION_CHECK_CURL, NULL, NULL, NULL, 1, false, false },
{ OPTION_OBJVER, ALIAS_OBJVER, NULL, objver_usage, 1, false, false },
+ { OPTION_OBJTS, NULL, NULL, objts_usage, 1, false, false },
{ OPTION_OBJTYPE, ALIAS_OBJTYPE, NULL, objtype_usage, 1, false, false },
{ OPTION_IDX_ENUM, NULL, NULL, idx_enum_usage, 1, false, false },
{ OPTION_IDX_RANGE, NULL, NULL, idx_range_usage, 1, true, false },
@@ -203,6 +205,7 @@ rc_t CC Usage ( const Args * args )
HelpOptionLine ( ALIAS_EXCLUDED_COLUMNS, OPTION_EXCLUDED_COLUMNS, NULL, excluded_columns_usage );
HelpOptionLine ( ALIAS_BOOLEAN, OPTION_BOOLEAN, NULL, boolean_usage );
HelpOptionLine ( ALIAS_OBJVER, OPTION_OBJVER, NULL, objver_usage );
+ HelpOptionLine ( NULL, OPTION_OBJTS, NULL, objts_usage );
HelpOptionLine ( ALIAS_OBJTYPE, OPTION_OBJTYPE, NULL, objtype_usage );
HelpOptionLine ( ALIAS_NUMELEM, OPTION_NUMELEM, NULL, numelem_usage );
HelpOptionLine ( ALIAS_NUMELEMSUM, OPTION_NUMELEMSUM, NULL, numelemsum_usage );
@@ -467,26 +470,26 @@ static rc_t vdm_dump_rows( p_row_context r_ctx )
}
-static bool vdm_extract_or_parse_columns( const p_dump_context ctx,
+static uint32_t vdm_extract_or_parse_columns( const p_dump_context ctx,
const VTable *my_table,
p_col_defs my_col_defs )
{
- bool res = false;
+ uint32_t count = 0;
if ( ctx != NULL && my_col_defs != NULL )
{
bool cols_unknown = ( ( ctx->columns == NULL ) || ( string_cmp( ctx->columns, 1, "*", 1, 1 ) == 0 ) );
if ( cols_unknown )
/* the user does not know the column-names or wants all of them */
- res = vdcd_extract_from_table( my_col_defs, my_table );
+ count = vdcd_extract_from_table( my_col_defs, my_table );
else
/* the user knows the names of the wanted columns... */
- res = vdcd_parse_string( my_col_defs, ctx->columns, my_table );
+ count = vdcd_parse_string( my_col_defs, ctx->columns, my_table );
if ( ctx->excluded_columns != NULL )
vdcd_exclude_these_columns( my_col_defs, ctx->excluded_columns );
}
- return res;
+ return count;
}
@@ -545,9 +548,11 @@ static rc_t vdm_dump_opened_table( const p_dump_context ctx, const VTable *my_ta
if ( rc == 0 )
{
- if ( vdm_extract_or_parse_columns( ctx, my_table, r_ctx.col_defs ) )
+ uint32_t n = vdm_extract_or_parse_columns( ctx, my_table, r_ctx.col_defs );
+ if ( n > 0 )
{
- if ( vdcd_add_to_cursor( r_ctx.col_defs, r_ctx.cursor ) )
+ n = vdcd_add_to_cursor( r_ctx.col_defs, r_ctx.cursor );
+ if ( n > 0 )
{
const VSchema *my_schema;
rc = VTableOpenSchema( my_table, &my_schema );
@@ -592,6 +597,14 @@ static rc_t vdm_dump_opened_table( const p_dump_context ctx, const VTable *my_ta
}
}
}
+ else
+ {
+ rc = RC( rcVDB, rcNoTarg, rcConstructing, rcParam, rcInvalid );
+ }
+ }
+ else
+ {
+ rc = RC( rcVDB, rcNoTarg, rcConstructing, rcParam, rcInvalid );
}
vdcd_destroy( r_ctx.col_defs );
}
@@ -1451,6 +1464,28 @@ static rc_t vdm_print_objver( const p_dump_context ctx, const VDBManager *mgr )
return rc;
}
+static rc_t vdm_print_objts ( const p_dump_context ctx, const VDBManager *mgr )
+{
+ KTime_t timestamp;
+ rc_t rc = VDBManagerGetObjModDate ( mgr, ×tamp, ctx-> path );
+ DISP_RC ( rc, "VDBManagerGetObjModDate () failed" );
+ if ( rc == 0 )
+ {
+ KTime kt;
+ KTimeGlobal ( & kt, timestamp );
+ rc = KOutMsg ( "%04u-%02u-%02uT"
+ "%02u:%02u:%02uZ"
+ "\n",
+ kt . year,
+ kt . month,
+ kt . day,
+ kt . hour,
+ kt . minute,
+ kt . second
+ );
+ }
+ return rc;
+}
static void vdm_print_objtype( const VDBManager *mgr, const char * acc_or_path )
{
@@ -1550,6 +1585,10 @@ static rc_t vdm_main_one_obj( const p_dump_context ctx,
{
rc = vdm_print_objver( ctx, mgr );
}
+ else if ( ctx->objts_requested )
+ {
+ rc = vdm_print_objts ( ctx, mgr );
+ }
else if ( ctx->objtype_requested )
{
vdm_print_objtype( mgr, acc_or_path );
@@ -1573,33 +1612,6 @@ static rc_t vdm_main_one_obj( const p_dump_context ctx,
}
-static rc_t vdm_check_curl( void )
-{
- struct KNSManager * knsmgr;
- rc_t rc = KNSManagerMake( &knsmgr );
- if ( rc == 0 )
- {
- rc = KNSManagerAvail( knsmgr );
- if ( rc == 0 )
- {
- const char *vers = NULL;
- rc = KNSManagerCurlVersion( knsmgr, &vers );
- if ( rc == 0 )
- KOutMsg( "libcurl-version = %s\n", vers );
- }
- else
- {
- rc = KOutMsg( "libcurl not available... %R\n", rc );
- }
- KNSManagerRelease( knsmgr );
- }
- else
- {
- rc = KOutMsg( "cannot create knsmgr... %R\n", rc );
- }
- return rc;
-}
-
/***************************************************************************
dump_main:
* called by "KMain()"
@@ -1643,10 +1655,6 @@ static rc_t vdm_main( const p_dump_context ctx, Args * args )
rc = vdh_show_manager_version( mgr );
DISP_RC( rc, "show_manager_version() failed" );
}
- else if ( ctx->check_curl )
- {
- rc = vdm_check_curl();
- }
else
{
uint32_t count;
diff --git a/tools/vdb-dump/vdb-dump.vers b/tools/vdb-dump/vdb-dump.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/vdb-dump/vdb-dump.vers
+++ b/tools/vdb-dump/vdb-dump.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
diff --git a/tools/vdb-validate/vdb-validate.c b/tools/vdb-validate/vdb-validate.c
index 5e8960d..5d8eda3 100644
--- a/tools/vdb-validate/vdb-validate.c
+++ b/tools/vdb-validate/vdb-validate.c
@@ -273,14 +273,14 @@ static rc_t visiting(CCReportInfoBlock const *what, cc_context_t *ctx)
unsigned const nn = ctx->nextNode++;
node_t *const nxt = &ctx->nodes[nn];
node_t *const cur = nxt - 1;
-
+
nxt->parent = nxt->prvSibl = nxt->nxtSibl = nxt->firstChild = -1;
nxt->depth = what->info.visit.depth;
nxt->objType = what->objType;
nxt->name = ctx->nextName;
ctx->nextName += strlen(what->objName) + 1;
strcpy(&ctx->names[nxt->name], what->objName);
-
+
if (nn) {
if (cur->depth == nxt->depth) {
nxt->parent = cur->parent;
@@ -293,7 +293,7 @@ static rc_t visiting(CCReportInfoBlock const *what, cc_context_t *ctx)
}
else {
unsigned sibling = cur->parent;
-
+
while (ctx->nodes[sibling].depth > nxt->depth)
sibling = ctx->nodes[sibling].parent;
nxt->parent = ctx->nodes[sibling].parent;
@@ -308,10 +308,10 @@ static rc_t CC report(CCReportInfoBlock const *what, void *Ctx)
{
cc_context_t *ctx = Ctx;
rc_t rc = Quitting();
-
+
if (rc)
return rc;
-
+
if (what->type == ccrpt_Visit)
return visiting(what, ctx);
@@ -364,7 +364,7 @@ rc_t kdbcc ( const KDBManager *mgr, char const name[], uint32_t mode,
if (*pathType == kptDatabase)
{
const KDatabase *db;
-
+
objtype = "database";
rc = KDBManagerOpenDBRead ( mgr, & db, name );
if ( rc == 0 )
@@ -465,9 +465,9 @@ static rc_t CC get_sizes_cb(const KDirectory *dir,
size_t size;
} *pb = data;
- ++pb->count;
+ ++pb->count;
pb->size += strlen(name) + 1;
-
+
return 0;
}
@@ -478,7 +478,7 @@ static rc_t get_sizes(KDirectory const *dir, unsigned *nobj, size_t *namesz)
unsigned count;
size_t size;
} pb;
-
+
memset(&pb, 0, sizeof(pb));
rc = KDirectoryVVisit(dir, true, get_sizes_cb, &pb, NULL, NULL);
if (rc)
@@ -686,10 +686,10 @@ static rc_t get_schema_info(KMetadata const *meta, char buffer[], size_t bsz,
{
KMDataNode const *node;
rc_t rc = KMetadataOpenNodeRead(meta, &node, "schema");
-
+
if (rc == 0) {
size_t sz;
-
+
rc = KMDataNodeReadAttr(node, "name", buffer, bsz, &sz);
if (rc == 0) {
buffer[sz] = '\0';
@@ -712,7 +712,7 @@ static rc_t get_tbl_schema_info(VTable const *tbl, char buffer[], size_t bsz,
{
KMetadata const *meta;
rc_t rc = VTableOpenMetadataRead(tbl, &meta);
-
+
*(*vers = &buffer[0]) = '\0';
if (rc == 0) rc = get_schema_info(meta, buffer, bsz, vers);
return 0;
@@ -723,7 +723,7 @@ static rc_t get_db_schema_info(VDatabase const *db, char buffer[], size_t bsz,
{
KMetadata const *meta;
rc_t rc = VDatabaseOpenMetadataRead(db, &meta);
-
+
*(*vers = &buffer[0]) = '\0';
if (rc == 0) rc = get_schema_info(meta, buffer, bsz, vers);
return rc;
@@ -740,10 +740,10 @@ static rc_t sra_dbcc_fastq(VTable const *tbl, char const name[])
static char const *const cn_FastQ[] = {
"READ", "QUALITY", "SPOT_LEN", "READ_START", "READ_LEN", "READ_TYPE"
};
-
+
VCursor const *curs;
rc_t rc = VTableCreateCursorRead(tbl, &curs);
-
+
if (rc == 0) {
unsigned const n = sizeof(cn_FastQ)/sizeof(cn_FastQ[0]);
ColumnInfo cols[sizeof(cn_FastQ)/sizeof(cn_FastQ[0])];
@@ -792,11 +792,11 @@ static rc_t VTable_get_platform(VTable const *tbl,
rc_t rc;
VCursor const *curs;
INSDC_SRA_platform_id platform = -1;
-
+
rc = VTableCreateCursorRead(tbl, &curs);
if (rc == 0) {
uint32_t cid;
-
+
rc = VCursorAddColumn(curs, &cid, "("sra_platform_id_t")PLATFORM");
if (rc == 0) {
rc = VCursorOpen(curs);
@@ -805,7 +805,7 @@ static rc_t VTable_get_platform(VTable const *tbl,
void const *data;
uint32_t boff;
uint32_t ecnt;
-
+
rc = VCursorCellDataDirect(curs, 1, cid,
&ebits, &data, &boff, &ecnt);
if (rc == 0) {
@@ -830,13 +830,13 @@ static rc_t verify_table(VTable const *tbl, char const name[])
char schemaName[1024];
char *schemaVers = NULL;
rc_t rc = 0;
-
+
get_tbl_schema_info(tbl, schemaName, sizeof(schemaName), &schemaVers);
-
+
if (schemaName[0] == '\0' || strncmp(schemaName, "NCBI:SRA:", 9) == 0) {
/* SRA or legacy SRA */
INSDC_SRA_platform_id platform;
-
+
rc = VTable_get_platform(tbl, &platform);
if (rc == 0) {
if (platform == (INSDC_SRA_platform_id)-1) {
@@ -861,7 +861,7 @@ static rc_t verify_mgr_table(VDBManager const *mgr, char const name[])
{
VTable const *tbl;
VSchema *sra_schema = NULL;
-
+
for ( ; ; ) {
rc_t rc = VDBManagerOpenTableRead(mgr, &tbl, sra_schema, name);
VSchemaRelease(sra_schema);
@@ -893,7 +893,7 @@ static rc_t verify_db_table(VDatabase const *db, char const name[])
{
VTable const *tbl;
rc_t rc = VDatabaseOpenTableRead(db, &tbl, name);
-
+
if (rc == 0) {
rc = verify_table(tbl, name);
VTableRelease(tbl);
@@ -909,7 +909,7 @@ static rc_t align_dbcc_primary_alignment(VTable const *tbl, char const name[])
{
VCursor const *curs;
rc_t rc = VTableCreateCursorRead(tbl, &curs);
-
+
if (rc == 0) {
static char const *const cn_SAM[] = {
"SEQ_NAME",
@@ -929,7 +929,7 @@ static rc_t align_dbcc_primary_alignment(VTable const *tbl, char const name[])
unsigned const n = sizeof(cn_SAM)/sizeof(cn_SAM[0]);
ColumnInfo cols[sizeof(cn_SAM)/sizeof(cn_SAM[0])];
unsigned i;
-
+
memset(cols, 0, sizeof(cols));
for (i = 0; i < n; ++i) {
cols[i].name = cn_SAM[i];
@@ -960,14 +960,23 @@ static rc_t align_dbcc_primary_alignment(VTable const *tbl, char const name[])
}
#endif
+static int CC id_cmp(void const *const A, void const *const B, void *const ignored)
+{
+ int64_t const *const a = A;
+ int64_t const *const b = B;
+
+ return *a < *b ? -1 : *a == *b ? 0 : 1;
+}
+
typedef struct id_pair_s {
int64_t first;
int64_t second;
} id_pair_t;
-static int CC id_pair_cmp(void const *A, void const *B, void *ignored)
+
+static int CC id_pair_cmp(void const *const A, void const *const B, void *const ignored)
{
- id_pair_t const *a = A;
- id_pair_t const *b = B;
+ id_pair_t const *const a = A;
+ id_pair_t const *const b = B;
return a->first < b->first
? -1
@@ -978,6 +987,154 @@ static int CC id_pair_cmp(void const *A, void const *B, void *ignored)
: 1;
}
+static size_t id_pair_span(size_t const first, size_t const N, id_pair_t const array[/* N */])
+{
+ int64_t const target = array[first].first;
+ size_t i;
+
+ for (i = first + 1; i < N; ++i) {
+ if (array[i].first != target)
+ break;
+ }
+ return i - first;
+}
+
+static size_t work_chunk(uint64_t const count)
+{
+ uint64_t const max = (2147483648ul) / (sizeof(id_pair_t)+sizeof(int64_t));
+ uint64_t chunk = count;
+
+ while (chunk > max)
+ chunk /= 2;
+
+ return (size_t)chunk;
+}
+
+static rc_t ric_align_generic(int64_t const startId,
+ uint64_t const count,
+ size_t const pairs,
+ id_pair_t pair[/* pairs */],
+ int64_t scratch[/* pairs */],
+ VCursor const *const acurs,
+ ColumnInfo *const aci,
+ VCursor const *const bcurs,
+ ColumnInfo *const bci
+ )
+{
+ rc_t rc = 0;
+ uint64_t current;
+
+ for (current = 0; current < count; current += pairs) {
+ uint64_t i;
+ uint64_t j;
+
+ for (i = current, j = 0; j < pairs && i < count; ++i) {
+ int64_t const row = startId + i;
+
+ rc = VCursorCellDataDirect(acurs, row, aci->idx,
+ &aci->elem_bits, &aci->value.vp, NULL, &aci->elem_count);
+ if (rc == 0) {
+ if (aci->elem_count != 1)
+ return RC(rcExe, rcDatabase, rcValidating, rcData,
+ rcUnexpected);
+ pair[j].second = row;
+ pair[j].first = aci->value.i64[0];
+ ++j;
+ }
+ else if (GetRCObject(rc) == rcRow && GetRCState(rc) == rcNotFound)
+ rc = 0;
+ else
+ return rc;
+ }
+ ksort(pair, j, sizeof(id_pair_t), id_pair_cmp, NULL);
+ for (i = 0; i < j; ) {
+ int64_t const row = pair[i].first;
+ size_t const span = id_pair_span(i, j, pair);
+ bool found = false;
+
+ rc = VCursorCellDataDirect(bcurs, row, bci->idx,
+ &bci->elem_bits, &bci->value.vp,
+ NULL, &bci->elem_count);
+ if (rc == 0) {
+ uint32_t const elem_count = bci->elem_count;
+
+ if (elem_count > pairs)
+ return RC(rcExe, rcDatabase, rcValidating, rcData, rcTooBig);
+
+ if (elem_count >= span) {
+ if (elem_count > 4) {
+ int64_t *const id = scratch;
+
+ memcpy(id, &bci->value.i64[0], elem_count * sizeof(bci->value.i64[0]));
+ ksort(id, span, sizeof(id[0]), id_cmp, NULL);
+
+ if (elem_count == span) {
+ size_t k;
+
+ found = true;
+ for (k = 0; k < span; ++k) {
+ if (id[k] != pair[i + k].second) {
+ found = false;
+ break;
+ }
+ }
+ }
+ else {
+ size_t k1, k2;
+
+ found = true;
+ for (k1 = k2 = 0; k1 < span && k2 < elem_count; ) {
+ int64_t const id1 = pair[i + k1].second;
+ int64_t const id2 = id[k2];
+
+ if (id2 == id1) {
+ ++k1;
+ ++k2;
+ }
+ else if (id2 < id1)
+ ++k2;
+ else {
+ found = false;
+ break;
+ }
+ }
+ if (found) found = k1 == span;
+ }
+ }
+ else {
+ size_t k1, k2;
+ int64_t const *const id = &bci->value.i64[0];
+
+ for (k1 = 0; k1 < span; ++k1) {
+ int64_t const id1 = pair[i + k1].second;
+
+ for (k2 = 0; k2 < elem_count; ++k2) {
+ int64_t const id2 = id[k2];
+
+ if (id1 == id2) {
+ found = true;
+ break;
+ }
+ }
+ if (!found)
+ break;
+ }
+ }
+ }
+ }
+ else if (GetRCObject(rc) != rcRow || GetRCState(rc) != rcNotFound)
+ return rc;
+
+ if (!found)
+ return RC(rcExe, rcDatabase, rcValidating, rcData,
+ rcInconsistent);
+
+ i += span;
+ }
+ }
+ return 0;
+}
+
static rc_t ric_align_ref_and_align(char const dbname[],
VTable const *ref,
VTable const *align,
@@ -988,136 +1145,69 @@ static rc_t ric_align_ref_and_align(char const dbname[],
: which == 2 ? "EVIDENCE_ALIGNMENT_IDS"
: NULL;
rc_t rc;
- VCursor const *curs = NULL;
- ColumnInfo ci;
+ VCursor const *acurs = NULL;
+ VCursor const *bcurs = NULL;
+ ColumnInfo aci;
+ ColumnInfo bci;
int64_t startId;
uint64_t count;
-
- rc = VTableCreateCursorRead(align, &curs);
+
+ rc = VTableCreateCursorRead(align, &acurs);
if (rc == 0) {
- rc = VCursorAddColumn(curs, &ci.idx, "REF_ID");
+ rc = VCursorAddColumn(acurs, &aci.idx, "REF_ID");
if (rc == 0)
- rc = VCursorOpen(curs);
+ rc = VCursorOpen(acurs);
if (rc == 0)
- rc = VCursorIdRange(curs, ci.idx, &startId, &count);
+ rc = VCursorIdRange(acurs, aci.idx, &startId, &count);
}
- if (rc) {
+ if (rc)
(void)PLOGERR(klogErr, (klogErr, rc, "Database '$(name)': "
"alignment table can not be read", "name=%s", dbname));
- }
else {
- id_pair_t *const id_pair = malloc(sizeof(id_pair_t) * count);
-
- if (id_pair) {
- uint64_t i;
- uint64_t j;
-
- for (j = i = 0; i < count && rc == 0; ++i) {
- int64_t const row = startId + i;
-
- rc = VCursorCellDataDirect(curs, row, ci.idx, &ci.elem_bits, &ci.value.vp, NULL, &ci.elem_count);
- if (rc == 0) {
- if (ci.elem_count != 1) {
- rc = RC(rcExe, rcDatabase, rcValidating, rcData, rcUnexpected);
- (void)PLOGERR(klogErr, (klogErr, rc,
- "Database '$(name)': failed referential integrity "
- "check", "name=%s", dbname));
- break;
- }
- else {
- id_pair[j].second = row;
- id_pair[j].first = ci.value.i64[0];
- ++j;
- }
- }
- else if (GetRCObject(rc) == rcRow
- && GetRCState(rc) == rcNotFound)
- { rc = 0; }
- }
- VCursorRelease(curs); curs = NULL;
- if (rc == 0) {
- bool ooo_warned = false;
- bool failed = false;
-
- ksort(id_pair, count, sizeof(id_pair_t), id_pair_cmp, NULL);
-
- rc = VTableCreateCursorRead(ref, &curs);
- if (rc == 0)
- rc = VCursorAddColumn(curs, &ci.idx, id_col_name);
- if (rc == 0)
- rc = VCursorOpen(curs);
- if (rc == 0)
- rc = VCursorIdRange(curs, ci.idx, &startId, &count);
- if (rc == 0) {
- for (i = j = 0; rc == 0 && i < count; ++i) {
- int64_t const row = startId + i;
-
- rc = VCursorCellDataDirect(curs, row, ci.idx,
- &ci.elem_bits, &ci.value.vp, NULL, &ci.elem_count);
- if (rc == 0) {
- unsigned k;
- int64_t prvId = ci.value.i64[0];
-
- for (k = 0; rc == 0 && k < ci.elem_count;
- ++k, ++j)
- {
- int64_t const alignId = ci.value.i64[k];
-
- if (!ooo_warned && prvId > alignId) {
- (void)PLOGMSG(klogWarn, (klogWarn,
- "Database '$(name)': "
- "column '$(idcol)' is not ordered",
- "name=%s,idcol=%s",
- dbname, id_col_name));
- ooo_warned = true;
- }
- if (id_pair[j].first != row) {
- if (!failed) {
- rc = RC(rcExe, rcDatabase, rcValidating,
- rcData, rcInconsistent);
- (void)PLOGERR(klogErr, (klogErr, rc,
+ rc = VTableCreateCursorRead(ref, &bcurs);
+ if (rc == 0)
+ rc = VCursorAddColumn(bcurs, &bci.idx, id_col_name);
+ if (rc == 0)
+ rc = VCursorOpen(bcurs);
+ if (rc)
+ (void)PLOGERR(klogErr, (klogErr, rc, "Database '$(name)': "
+ "reference table can not be read", "name=%s", dbname));
+ }
+ if (rc == 0) {
+ size_t const chunk = work_chunk(count);
+ id_pair_t *const pair = malloc((sizeof(id_pair_t)+sizeof(int64_t)) * chunk);
+ int64_t *const scratch = &pair[chunk].first;
+
+ if (pair) {
+ rc = ric_align_generic(startId, count, chunk, pair, scratch,
+ acurs, &aci, bcurs, &bci);
+ if (GetRCObject(rc) == rcData && GetRCState(rc) == rcUnexpected)
+ (void)PLOGERR(klogErr, (klogErr, rc,
+ "Database '$(name)': failed referential "
+ "integrity check", "name=%s", dbname));
+ else if (GetRCObject(rc) == rcData &&
+ GetRCState(rc) == rcInconsistent)
+ (void)PLOGERR(klogErr, (klogErr, rc,
"Database '$(name)': column '$(idcol)' failed referential integrity check",
"name=%s,idcol=%s", dbname, id_col_name));
- }
- failed = true;
- }
- else if (id_pair[j].second != alignId) {
- if (!ooo_warned) {
- (void)PLOGMSG(klogWarn, (klogWarn,
- "Database '$(name)': column '$(idcol)' might fail referential integrity check",
- "name=%s,idcol=%s", dbname, id_col_name));
- }
- }
- prvId = alignId;
- }
- }
- else if (GetRCObject(rc) == rcRow
- && GetRCState(rc) == rcNotFound)
- { rc = 0; }
- }
- if (!failed && i < count) {
- rc = RC(rcExe, rcDatabase, rcValidating,
- rcData, rcInconsistent);
- (void)PLOGERR(klogErr, (klogErr, rc,
- "Database '$(name)': column '$(idcol)' failed "
- "referential integrity check",
- "name=%s,idcol=%s", dbname, id_col_name));
- }
- }
- else
- (void)PLOGERR(klogErr, (klogErr, rc, "Database '$(name)': "
- "reference table can not be read", "name=%s", dbname));
- }
- free(id_pair);
- VCursorRelease(curs);
+ else if (GetRCObject(rc) == rcData &&
+ GetRCState(rc) == rcTooBig)
+ (void)PLOGERR(klogWarn, (klogWarn, rc = 0, "Database '$(name)':"
+ " referential integrity could not be checked, skipped",
+ "name=%s", dbname));
+ else if (rc)
+ (void)PLOGERR(klogErr, (klogErr, rc,
+"Database '$(name)': reference table can not be read", "name=%s", dbname));
+
+ free(pair);
}
- else {
- rc = RC(rcExe, rcDatabase, rcValidating, rcMemory, rcExhausted);
- (void)PLOGERR(klogErr, (klogErr, rc, "Database '$(name)': "
- "referential integrity could not be checked",
+ else
+ (void)PLOGERR(klogWarn, (klogWarn, rc = 0, "Database '$(name)':"
+ " referential integrity could not be checked, skipped",
"name=%s", dbname));
- }
}
+ VCursorRelease(acurs);
+ VCursorRelease(bcurs);
return rc;
}
@@ -1126,114 +1216,68 @@ static rc_t ric_align_seq_and_pri(char const dbname[],
VTable const *pri)
{
rc_t rc;
- VCursor const *curs = NULL;
- ColumnInfo ci;
+ VCursor const *acurs = NULL;
+ VCursor const *bcurs = NULL;
+ ColumnInfo aci;
+ ColumnInfo bci;
int64_t startId;
uint64_t count;
-
- rc = VTableCreateCursorRead(pri, &curs);
- if (rc == 0) {
- rc = VCursorAddColumn(curs, &ci.idx, "SEQ_SPOT_ID");
- if (rc == 0)
- rc = VCursorOpen(curs);
- if (rc == 0)
- rc = VCursorIdRange(curs, ci.idx, &startId, &count);
- }
- if (rc) {
+
+ rc = VTableCreateCursorRead(pri, &acurs);
+ if (rc == 0)
+ rc = VCursorAddColumn(acurs, &aci.idx, "SEQ_SPOT_ID");
+ if (rc == 0)
+ rc = VCursorOpen(acurs);
+ if (rc == 0)
+ rc = VCursorIdRange(acurs, aci.idx, &startId, &count);
+ if (rc)
(void)PLOGERR(klogErr, (klogErr, rc, "Database '$(name)': "
"alignment table can not be read", "name=%s", dbname));
- }
else {
- id_pair_t *const id_pair = malloc(sizeof(id_pair_t) * count);
-
- if (id_pair) {
- uint64_t i;
- uint64_t j;
-
- for (j = i = 0; i < count && rc == 0; ++i) {
- int64_t const row = startId + i;
-
- rc = VCursorCellDataDirect(curs, row, ci.idx,
- &ci.elem_bits, &ci.value.vp, NULL, &ci.elem_count);
- if (rc == 0) {
- if (ci.elem_count != 1) {
- rc = RC(rcExe, rcDatabase, rcValidating,
- rcData, rcUnexpected);
- (void)PLOGERR(klogErr, (klogErr, rc,
- "Database '$(name)': failed "
- "referential integrity check", "name=%s", dbname));
- break;
- }
- else {
- id_pair[j].second = row;
- id_pair[j].first = ci.value.i64[0];
- ++j;
- }
- }
- else if (GetRCObject(rc) == rcRow
- && GetRCState(rc) == rcNotFound)
- { rc = 0; }
- }
- VCursorRelease(curs); curs = NULL;
- if (rc == 0) {
- ksort(id_pair, count, sizeof(id_pair_t), id_pair_cmp, NULL);
-
- rc = VTableCreateCursorRead(seq, &curs);
- if (rc == 0)
- rc = VCursorAddColumn(curs, &ci.idx,
- "PRIMARY_ALIGNMENT_ID");
- if (rc == 0)
- rc = VCursorOpen(curs);
- if (rc == 0) {
- for (i = 0; rc == 0 && i < count; ++i) {
- int64_t const row = id_pair[i].first;
- int64_t const alignId = id_pair[i].second;
-
- rc = VCursorCellDataDirect(curs, row, ci.idx,
- &ci.elem_bits, &ci.value.vp, NULL, &ci.elem_count);
- if (rc == 0) {
- bool found = false;
-
- for (j = 0; j < ci.elem_count; ++j)
- found |= (alignId == ci.value.i64[j]);
-
- if (!found) {
- rc = RC(rcExe, rcDatabase, rcValidating,
- rcData, rcInconsistent);
- (void)PLOGERR(klogErr, (klogErr, rc,
- "Database '$(name)': column 'SEQ_SPOT_ID' failed referential integrity check",
- "name=%s", dbname));
- }
- }
- else if (GetRCObject(rc) == rcRow
- && GetRCState(rc) == rcNotFound)
- {
- rc = RC(rcExe, rcDatabase, rcValidating,
- rcData, rcInconsistent);
- (void)PLOGERR(klogErr, (klogErr, rc,
- "Database '$(name)': column 'SEQ_SPOT_ID' failed referential integrity check",
- "name=%s", dbname));
- }
- else {
- (void)PLOGERR(klogErr, (klogErr, rc,
- "Database '$(name)': sequence table can not be read", "name=%s", dbname));
- }
- }
- }
- else
- (void)PLOGERR(klogErr, (klogErr, rc, "Database '$(name)': "
- "sequence table can not be read", "name=%s", dbname));
- }
- free(id_pair);
- }
- else {
- rc = RC(rcExe, rcDatabase, rcValidating, rcMemory, rcExhausted);
+ rc = VTableCreateCursorRead(seq, &bcurs);
+ if (rc == 0)
+ rc = VCursorAddColumn(bcurs, &bci.idx, "PRIMARY_ALIGNMENT_ID");
+ if (rc == 0)
+ rc = VCursorOpen(bcurs);
+ if (rc)
(void)PLOGERR(klogErr, (klogErr, rc, "Database '$(name)': "
- "referential integrity could not be checked",
- "name=%s", dbname));
+ "sequence table can not be read", "name=%s", dbname));
+ }
+ if (rc == 0) {
+ size_t const chunk = work_chunk(count);
+ id_pair_t *const pair = malloc((sizeof(id_pair_t)+sizeof(int64_t)) * chunk);
+ int64_t *const scratch = &pair[chunk].first;
+
+ if (pair) {
+ rc = ric_align_generic(startId, count, chunk, pair, scratch,
+ acurs, &aci, bcurs, &bci);
+ if (GetRCObject(rc) == rcData && GetRCState(rc) == rcUnexpected)
+ (void)PLOGERR(klogErr, (klogErr, rc,
+ "Database '$(name)': failed referential "
+ "integrity check", "name=%s", dbname));
+ else if (GetRCObject(rc) == rcData &&
+ GetRCState(rc) == rcInconsistent)
+ (void)PLOGERR(klogErr, (klogErr, rc,
+"Database '$(name)': column 'SEQ_SPOT_ID' failed referential integrity check",
+"name=%s", dbname));
+ else if (GetRCObject(rc) == rcData &&
+ GetRCState(rc) == rcTooBig)
+ (void)PLOGERR(klogWarn, (klogWarn, rc = 0, "Database '$(name)':"
+ " referential integrity could not be checked, skipped",
+ "name=%s", dbname));
+ else if (rc)
+ (void)PLOGERR(klogErr, (klogErr, rc,
+"Database '$(name)': sequence table can not be read", "name=%s", dbname));
+
+ free(pair);
}
- VCursorRelease(curs);
+ else
+ (void)PLOGERR(klogWarn, (klogWarn, rc = 0, "Database '$(name)':"
+ " referential integrity could not be checked, skipped",
+ "name=%s", dbname));
}
+ VCursorRelease(acurs);
+ VCursorRelease(bcurs);
return rc;
}
@@ -1244,10 +1288,10 @@ static rc_t dbric_align(char const dbname[],
VTable const *ref)
{
rc_t rc = 0;
-
+
if ((rc == 0 || exhaustive) && (pri != NULL && seq != NULL)) {
rc_t rc2 = ric_align_seq_and_pri(dbname, seq, pri);
-
+
if (rc2 == 0) {
(void)PLOGMSG(klogInfo, (klogInfo, "Database '$(dbname)': "
"SEQUENCE.PRIMARY_ALIGNMENT_ID <-> PRIMARY_ALIGNMENT.SEQ_SPOT_ID"
@@ -1259,7 +1303,7 @@ static rc_t dbric_align(char const dbname[],
}
if ((rc == 0 || exhaustive) && (pri != NULL && ref != NULL)) {
rc_t rc2 = ric_align_ref_and_align(dbname, ref, pri, 0);
-
+
if (rc2 == 0) {
(void)PLOGMSG(klogInfo, (klogInfo, "Database '$(dbname)': "
"REFERENCE.PRIMARY_ALIGNMENT_IDS <-> PRIMARY_ALIGNMENT.REF_ID "
@@ -1287,12 +1331,12 @@ static rc_t verify_database_align(VDatabase const *db,
tbSequence = ( 1u << 4 ),
tbSecondaryAlignment = ( 1u << 5 )
};
-
+
if (nodes[0].firstChild) {
for ( ; ; ) {
char const *tname = &names[tbl->name];
unsigned this_table = 0;
-
+
if (tbl->objType == kptTable) {
switch (tname[0]) {
case 'E':
@@ -1363,7 +1407,7 @@ static rc_t verify_database_align(VDatabase const *db,
VTable const *pri = NULL;
VTable const *seq = NULL;
VTable const *ref = NULL;
-
+
if ((tables & tbPrimaryAlignment) != 0) {
rc = VDatabaseOpenTableRead(db, &pri, "PRIMARY_ALIGNMENT");
if (rc) break;
@@ -1379,7 +1423,7 @@ static rc_t verify_database_align(VDatabase const *db,
rc = dbric_align(name, pri, seq, ref);
break;
}
- return rc;
+ return rc;
}
static rc_t verify_database(VDatabase const *db,
@@ -1388,7 +1432,7 @@ static rc_t verify_database(VDatabase const *db,
char schemaName[1024];
char *schemaVers = NULL;
rc_t rc;
-
+
rc = get_db_schema_info(db, schemaName, sizeof(schemaName), &schemaVers);
if (rc) {
(void)PLOGERR(klogErr, (klogErr, rc,
@@ -1420,7 +1464,7 @@ static rc_t verify_mgr_database(VDBManager const *mgr,
{
VDatabase const *child;
rc_t rc = VDBManagerOpenDBRead(mgr, &child, NULL, name);
-
+
if (rc == 0) {
rc = verify_database(child, name, nodes, names);
VDatabaseRelease(child);
@@ -1438,7 +1482,7 @@ static rc_t sra_dbcc(const VDBManager *mgr,
rc = verify_mgr_database(mgr, name, nodes, names);
else
rc = verify_mgr_table(mgr, name);
-
+
return rc;
}
@@ -1833,7 +1877,7 @@ static rc_t vdb_validate(const vdb_validate_params *pb, const char *aPath) {
return rc;
}
-static char const* const defaultLogLevel =
+static char const* const defaultLogLevel =
#if _DEBUGGING
"debug5";
#else
@@ -1852,7 +1896,7 @@ rc_t CC UsageSummary(const char *prog_name)
, prog_name );
}
-/*static char const *help_text[] =
+/*static char const *help_text[] =
{
"Check components md5s if present, "
"fail unless other checks are requested (default: yes)", NULL,
@@ -1904,7 +1948,7 @@ static const char *USAGE_DRI[] =
static const char *USAGE_IND_ONLY[] =
{ "Check index-only with blobs CRC32 (default: no)", NULL };
-static OptDef options [] =
+static OptDef options [] =
{ /* needs_value, required */
/* { OPTION_MD5 , ALIAS_MD5 , NULL, USAGE_MD5 , 1, true , false }*/
{ OPTION_BLOB_CRC, ALIAS_BLOB_CRC, NULL, USAGE_BLOB_CRC, 1, true , false }
@@ -1947,9 +1991,9 @@ rc_t CC Usage ( const Args * args )
rc_t rc = ArgsProgram ( args, & fullpath, & progname );
if ( rc != 0 )
progname = fullpath = UsageDefaultName;
-
+
UsageSummary ( progname );
-
+
KOutMsg ( " Examine directories, files and VDB objects,\n"
" reporting any problems that can be detected.\n"
"\n"
@@ -1977,9 +2021,9 @@ rc_t CC Usage ( const Args * args )
}
*/
HelpOptionsStandard ();
-
+
HelpVersion ( fullpath, KAppVersion () );
-
+
return 0;
}
@@ -2160,6 +2204,9 @@ rc_t CC KMain ( int argc, char *argv [] )
else
{
uint32_t i;
+
+ md5_required = false;
+
STSMSG(2, ("exhaustive = %d", exhaustive));
STSMSG(2, ("ref_int_check = %d", ref_int_check));
STSMSG(2, ("md5_required = %d", md5_required));
diff --git a/tools/vdb-validate/vdb-validate.vers b/tools/vdb-validate/vdb-validate.vers
index 3f684d2..cc6c9a4 100644
--- a/tools/vdb-validate/vdb-validate.vers
+++ b/tools/vdb-validate/vdb-validate.vers
@@ -1 +1 @@
-2.3.4
+2.3.5
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-med/sra-sdk.git
More information about the debian-med-commit
mailing list