anchor.diff:      MIMOConfiguration mimoCfg = defaultValue;
       MIMO#(1,4,4,Bit#(32)) completionMimo <- mkMIMO(mimoCfg);
      Reg#(TLPLength)             readBurstCount <- mkReg(0);
  +   Reg#(LUInt#(4))     completionMimoDeqCount <- mkReg(0);
      Reg#(Bool)      readBurstCountGreaterThan4 <- mkReg(False);
      Reg#(Bool)                  readInProgress <- mkReg(False);
      rule completionHeader if (!readInProgress && readDataFifo.notEmpty() && completionMimo.deqReadyN(1));
  
positive.code: 
        rbc = rbc - 1;
        readBurstCount <= rbc;
        readInProgress <= (rbc != 0);
        readBurstCountGreaterThan4 <= (rbc > 4);
        if (rbc == 0) begin
  
negative.code: 	  return 16'hffff;
      endfunction
  
     rule continuation if (readInProgress && completionMimo.deqReadyN(completionMimoDeqCount));
        let rbc = readBurstCount;
        TLPData#(16) tlp = defaultValue;
        Vector#(4, Bit#(32)) dvec = unpack(0);
        tlp.sof = False;
        dvec = completionMimo.first();
        completionMimo.deq(completionMimoDeqCount);
  
        if (readBurstCountGreaterThan4) begin
  	 rbc = rbc - 4;
  	 tlp.be = tlpBe(4);
  	 tlp.eof = False;
        end
        else begin
  	 tlp.be = tlpBe(rbc);
  	 //$display("tlp.data=%h tlp.be=%h", tlp.data, tlp.be);
  	 tlp.eof = True;
  	 rbc = 0;
        end
  
        readBurstCount <= rbc;
        completionMimoDeqCount <= truncate(min(4,unpack(rbc)));
        readBurstCountGreaterThan4 <= (rbc > 4);
        if (!readBurstCountGreaterThan4) begin
  	 readDataFifo.deq();
  	 readInProgress <= False;
        end
        for (Integer i = 0; i < 4; i = i + 1)
  	 tlp.data[(i+1)*32-1:i*32] = byteSwap(dvec[3-i]);
        tlpOutFifo.enq(tlp);
     endrule
  
      interface Client        tlp;
  