Skip to content

Commit

Permalink
Reset states between partitions
Browse files Browse the repository at this point in the history
  • Loading branch information
paul-g committed Sep 4, 2015
1 parent 784c551 commit af82868
Showing 1 changed file with 9 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -93,11 +93,17 @@ void processRow() {
IF (rowsProcessed === nRows - 1) {
rowsProcessed.next <== 0;
vectorLoadCommands.next <== 0;
crtPos.next <== 0;
iLengthReady.next <== false;
mode.next <== Mode.VectorLoad;
partitionsProcessed.next <== partitionsProcessed + 1;
IF (paddingCycles !== 0) {
mode.next <== Mode.Padding;
paddedOutputs.next <== 0;
IF (partitionsProcessed === nPartitions - 1) {
IF (paddingCycles !== 0) {
mode.next <== Mode.Padding;
paddedOutputs.next <== 0;
} ELSE {
mode.next <== Mode.Done;
}
}
} ELSE {
mode.next <== Mode.ReadingLength;
Expand All @@ -118,12 +124,7 @@ protected void nextState() {
paddedOutputs.next <== paddedOutputs + 1;
makeOutput(fls(), fls(), zero(inputWidth), zero(), zeroI(), crtPos, fls());
IF (paddedOutputs === paddingCycles - 1) {
IF (partitionsProcessed === nPartitions) {
mode.next <== Mode.Done;
//outValid.next <== false;
} ELSE {
mode.next <== Mode.VectorLoad;
}
}
}
}
Expand Down

0 comments on commit af82868

Please sign in to comment.