c16b3edf4c88aed3d6cf1da68118fca1f8855593
markd
  Wed Feb 3 16:31:12 2021 -0800
add debug logging of index parameters

diff --git src/gfServer/gfServer.c src/gfServer/gfServer.c
index b7cf691..bd55595 100644
--- src/gfServer/gfServer.c
+++ src/gfServer/gfServer.c
@@ -203,30 +203,61 @@
 }
 
 void errSendString(int sd, char *s)
 // Send string. If not OK, remember we had an error, do not try to write anything more on this connection.
 {
 
 if (sendOk) sendOk = netSendString(sd, s);
 }
 
 void errSendLongString(int sd, char *s)
 // Send string unless we had an error already on the connection.
 {
 if (sendOk) sendOk = netSendLongString(sd, s);
 }
 
+void logGenoFind(struct genoFind *gf)
+/* debug log the genoFind parameters */
+{
+logDebug("gf->isMapped: %d", gf->isMapped);
+logDebug("gf->maxPat: %d", gf->maxPat);
+logDebug("gf->minMatch: %d", gf->minMatch);
+logDebug("gf->maxGap: %d", gf->maxGap);
+logDebug("gf->tileSize: %d", gf->tileSize);
+logDebug("gf->stepSize: %d", gf->stepSize);
+logDebug("gf->tileSpaceSize: %d", gf->tileSpaceSize);
+logDebug("gf->tileMask: %d", gf->tileMask);
+logDebug("gf->sourceCount: %d", gf->sourceCount);
+logDebug("gf->isPep: %d", gf->isPep);
+logDebug("gf->allowOneMismatch: %d", gf->allowOneMismatch);
+logDebug("gf->noSimpRepMask: %d", gf->noSimpRepMask);
+logDebug("gf->segSize: %d", gf->segSize);
+logDebug("gf->totalSeqSize: %d", gf->totalSeqSize);
+}
+
+void logGenoFindIndex(struct genoFindIndex *gfIdx)
+/* debug log the genoFind parameters in an genoFindIndex */
+{
+logDebug("gfIdx->isTrans: %d", gfIdx->isTrans);
+logDebug("gfIdx->noSimpRepMask: %d", gfIdx->noSimpRepMask);
+if (gfIdx->untransGf != NULL)
+    logGenoFind(gfIdx->untransGf);
+else
+    logGenoFind(gfIdx->transGf[0][0]);
+}
+
+
 void genoFindDirect(char *probeName, int fileCount, char *seqFiles[])
 /* Don't set up server - just directly look for matches. */
 {
 struct genoFind *gf = NULL;
 struct lineFile *lf = lineFileOpen(probeName, TRUE);
 struct dnaSeq seq;
 int hitCount = 0, clumpCount = 0, oneHit;
 ZeroVar(&seq);
 
 if (doTrans)
     errAbort("Don't support translated direct stuff currently, sorry");
 
 gf = gfIndexNibsAndTwoBits(fileCount, seqFiles, minMatch, maxGap, 
 	tileSize, repMatch, FALSE,
 	allowOneMismatch, stepSize, noSimpRepMask);
@@ -673,30 +704,31 @@
 time_t startIndexTime = clock1000();
 if (indexFile == NULL)
     {
     char *desc = doTrans ? "translated" : "untranslated";
     uglyf("starting %s server...\n", desc);
     logInfo("setting up %s index", desc);
     gfIdx = genoFindIndexBuild(fileCount, seqFiles, minMatch, maxGap, tileSize, repMatch, doTrans, NULL,
                                allowOneMismatch, doMask, stepSize, noSimpRepMask);
     logInfo("index building completed in %4.3f seconds", 0.001 * (clock1000() - startIndexTime));
     }
 else
     {
     gfIdx = genoFindIndexLoad(indexFile, doTrans);
     logInfo("index loading completed in %4.3f seconds", 0.001 * (clock1000() - startIndexTime));
     }
+logGenoFindIndex(gfIdx);
 
 /* Set up socket.  Get ready to listen to it. */
 socketHandle = netAcceptingSocket(port, 100);
 if (socketHandle < 0)
     errAbort("Fatal Error: Unable to open listening socket on port %d.", port);
 
 logInfo("Server ready for queries!");
 printf("Server ready for queries!\n");
 int connectFailCount = 0;
 for (;;)
     {
     ZeroVar(&fromAddr);
     fromLen = sizeof(fromAddr);
     connectionHandle = accept(socketHandle, (struct sockaddr*)&fromAddr, &fromLen);
     setSendOk();
@@ -1109,30 +1141,31 @@
     struct hash *perSeqMaxHash;   // max hits per sequence
     struct genoFindIndex *gfIdx;  // index
 };
 
 static struct genoFindIndex *loadGfIndex(char *gfIdxFile, boolean isTrans)
 /* load index and set globals from it */
 {
 struct genoFindIndex *gfIdx = genoFindIndexLoad(gfIdxFile, isTrans);
 struct genoFind *gf = isTrans ? gfIdx->transGf[0][0] : gfIdx->untransGf;
 minMatch = gf->minMatch;
 maxGap = gf->maxGap;
 tileSize = gf->tileSize;
 noSimpRepMask = gf->noSimpRepMask;
 allowOneMismatch = gf->allowOneMismatch;
 stepSize = gf->stepSize;
+logGenoFindIndex(gfIdx);
 return gfIdx;
 }
 
 static void dynWarnHandler(char *format, va_list args)
 /* log error warning and error message, along with printing */
 {
 logErrorVa(format, args);
 vfprintf(stderr, format, args);
 fputc('\n', stderr);
 }
 
 static void dynSessionInit(struct dynSession *dynSession, char *rootDir,
                            char *genome, char *genomeDataDir, boolean isTrans)
 /* Initialize or reinitialize a dynSession object */
 {