anchor.diff:          // Write single char: '1' if counter-example found; '0' otherwise
           $fwrite(file, failureFound ? "1" : "0");
   
  +        // Write depth
  +        putHalfWord(file, depth[31:16]);
  +        putHalfWord(file, depth[15:0]);
  +
           // Initialise
  -        testDone <= False;
  +        loopDone <= False;
           iterCount <= 0;
         endaction
   
  -      while (!testDone)
  +      while (!loopDone)
           action
             let x <- shadows.get;
  -          putSeed(seedFile, x);
  +          putHalfWord(seedFile, x);
   
             // Increment loop counter
             iterCount <= iterCount+1;
  -          if (iterCount+1 == fromInteger(numLFSRs)) testDone <= True;
  +          if (iterCount+1 == fromInteger(numLFSRs)) loopDone <= True;
           endaction
   
         // Close file
  
positive.code: 
        // Each iteration will produce N test sequences of size 'depth'.
        // After each iteration, the depth is increased.
        currentDepth <= params.id.initialDepth;
        while (!failureFound && iterCount < params.numIterations)
          seq
            // Check that the depth is OK
  
negative.code:         // Ignore first character
          let _  <- $fgetc(file);
  
          // Read depth
          let d0 <- getHalfWord(file);
          let d1 <- getHalfWord(file);
          currentDepth <= {d0, d1};
          $display("d = ", {d0, d1});
  
          // Initialise
          loopDone <= False;
          iterCount <= 0;
        endaction
  
        while (!loopDone)
          action
            let x <- getHalfWord(seedFile);
            shadows.put(x);
  
            // Increment loop counter
            iterCount <= iterCount+1;
            if (iterCount+1 == fromInteger(numLFSRs)) loopDone <= True;
          endaction
  
        // Close file
  