OpenCores
URL https://opencores.org/ocsvn/bluespec-h264/bluespec-h264/trunk

Subversion Repositories bluespec-h264

[/] [bluespec-h264/] [trunk/] [LumaChromaParallel/] [mkInterpolator.bsv] - Blame information for rev 91

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 90 jamey.hick
// The MIT License
2
 
3
// Copyright (c) 2006-2007 Massachusetts Institute of Technology
4
 
5
// Permission is hereby granted, free of charge, to any person obtaining a copy
6
// of this software and associated documentation files (the "Software"), to deal
7
// in the Software without restriction, including without limitation the rights
8
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
// copies of the Software, and to permit persons to whom the Software is
10
// furnished to do so, subject to the following conditions:
11
 
12
// The above copyright notice and this permission notice shall be included in
13
// all copies or substantial portions of the Software.
14
 
15
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
// THE SOFTWARE.
22
//**********************************************************************
23
// interpolator implementation
24
//----------------------------------------------------------------------
25
//
26
//
27
 
28
package mkInterpolator;
29
 
30
import H264Types::*;
31
import IInterpolator::*;
32
import FIFO::*;
33 91 jamey.hick
import FIFOF::*;
34 90 jamey.hick
import Vector::*;
35
 
36
import Connectable::*;
37
import GetPut::*;
38
import ClientServer::*;
39
 
40
 
41
//-----------------------------------------------------------
42
// Local Datatypes
43
//-----------------------------------------------------------
44
 
45
typedef union tagged
46
{
47
 struct { Bit#(2) xFracL; Bit#(2) yFracL; Bit#(2) offset; IPBlockType bt; } IPWLuma;
48
 struct { Bit#(3) xFracC; Bit#(3) yFracC; Bit#(2) offset; IPBlockType bt; } IPWChroma;
49
}
50
InterpolatorWT deriving(Eq,Bits);
51
 
52
 
53
//-----------------------------------------------------------
54
// Helper functions
55
 
56
function Bit#(8) clip1y10to8( Bit#(10) innum );
57
   if(innum[9] == 1)
58
      return 0;
59
   else if(innum[8] == 1)
60
      return 255;
61
   else
62
      return truncate(innum);
63
endfunction
64
 
65
function Bit#(15) interpolate8to15( Bit#(8) in0, Bit#(8) in1, Bit#(8) in2, Bit#(8) in3, Bit#(8) in4, Bit#(8) in5 );
66
   return zeroExtend(in0) - 5*zeroExtend(in1) + 20*zeroExtend(in2) + 20*zeroExtend(in3) - 5*zeroExtend(in4) + zeroExtend(in5);
67
endfunction
68
 
69
function Bit#(8) interpolate15to8( Bit#(15) in0, Bit#(15) in1, Bit#(15) in2, Bit#(15) in3, Bit#(15) in4, Bit#(15) in5 );
70
   Bit#(20) temp = signExtend(in0) - 5*signExtend(in1) + 20*signExtend(in2) + 20*signExtend(in3) - 5*signExtend(in4) + signExtend(in5) + 512;
71
   return clip1y10to8(truncate(temp>>10));
72
endfunction
73
 
74
 
75
 
76
//-----------------------------------------------------------
77
// Interpolation Module
78
//-----------------------------------------------------------
79
 
80
 
81
(* synthesize *)
82
module mkInterpolator( Interpolator );
83
 
84
   FIFO#(InterpolatorIT) reqfifoLoad <- mkSizedFIFO(interpolator_reqfifoLoad_size);
85
   FIFO#(InterpolatorWT) reqfifoWork1 <- mkSizedFIFO(interpolator_reqfifoWork_size);
86
   Reg#(Maybe#(InterpolatorWT)) reqregWork2 <- mkReg(Invalid);
87
   FIFO#(Vector#(4,Bit#(8))) outfifo <- mkFIFO;
88
   Reg#(Bool) endOfFrameFlag <- mkReg(False);
89
   FIFO#(InterpolatorLoadReq)  memReqQ  <- mkFIFO;
90
   FIFO#(InterpolatorLoadResp) memRespQ <- mkSizedFIFO(interpolator_memRespQ_size);
91
 
92
   Reg#(Bit#(PicWidthSz))  picWidth  <- mkReg(maxPicWidthInMB);
93
   Reg#(Bit#(PicHeightSz)) picHeight <- mkReg(0);
94
 
95
   RFile1#(Bit#(6),Vector#(4,Bit#(15))) workFile  <- mkRFile1Full();
96
   RFile1#(Bit#(6),Vector#(4,Bit#(8)))  storeFile <- mkRFile1Full();
97
   Reg#(Bit#(1)) workFileFlag <- mkReg(0);
98
   RFile1#(Bit#(4),Vector#(4,Bit#(8))) resultFile <- mkRFile1Full();
99
 
100
   Reg#(Bit#(1)) loadStage  <- mkReg(0);
101
   Reg#(Bit#(2)) loadHorNum <- mkReg(0);
102
   Reg#(Bit#(4)) loadVerNum <- mkReg(0);
103
 
104
   Reg#(Bit#(2)) work1MbPart    <- mkReg(0);//only for Chroma
105
   Reg#(Bit#(2)) work1SubMbPart <- mkReg(0);//only for Chroma
106
   Reg#(Bit#(1)) work1Stage     <- mkReg(0);
107
   Reg#(Bit#(2)) work1HorNum    <- mkReg(0);
108
   Reg#(Bit#(4)) work1VerNum    <- mkReg(0);
109
   Reg#(Vector#(20,Bit#(8))) work1Vector8 <- mkRegU;
110
   Reg#(Bool) work1Done <- mkReg(False);
111
 
112
   Reg#(Bit#(2)) work2SubMbPart <- mkReg(0);
113
   Reg#(Bit#(2)) work2HorNum    <- mkReg(0);
114
   Reg#(Bit#(4)) work2VerNum    <- mkReg(0);
115
   Reg#(Vector#(20,Bit#(8))) work2Vector8 <- mkRegU;
116
   Reg#(Vector#(20,Bit#(15))) work2Vector15 <- mkRegU;
117
   Reg#(Vector#(16,Bit#(1))) resultReady <- mkReg(replicate(0));
118
   Reg#(Bool) work2Done <- mkReg(False);
119
   Reg#(Bool) work8x8Done <- mkReg(False);
120
 
121
   Reg#(Bit#(2)) outBlockNum <- mkReg(0);
122
   Reg#(Bit#(2)) outPixelNum <- mkReg(0);
123
   Reg#(Bool) outDone <- mkReg(False);
124
 
125 91 jamey.hick
   Reg#(Bit#(64)) total_cycles <- mkReg(0);
126
 
127
 
128
   rule incr;
129
     total_cycles <= total_cycles + 1;
130
   endrule
131
 
132 90 jamey.hick
   rule sendEndOfFrameReq( endOfFrameFlag );
133
      endOfFrameFlag <= False;
134 91 jamey.hick
      $display("trace interpolator sending EndOfFrame");
135 90 jamey.hick
      memReqQ.enq(IPLoadEndFrame);
136
   endrule
137
 
138
 
139
   rule loadLuma( reqfifoLoad.first() matches tagged IPLuma .reqdata &&& !endOfFrameFlag );
140
      Bit#(2) xfracl = reqdata.mvhor[1:0];
141
      Bit#(2) yfracl = reqdata.mvver[1:0];
142
      Bit#(2) offset = reqdata.mvhor[3:2];
143
      Bool twoStage = (xfracl==1||xfracl==3) && (yfracl==1||yfracl==3);
144
      Bool horInter = (twoStage ? loadStage==1 : xfracl!=0);
145
      Bool verInter = (twoStage ? loadStage==0 : yfracl!=0);
146
      Bit#(2) offset2 = reqdata.mvhor[3:2] + ((twoStage&&verInter&&xfracl==3) ? 1 : 0);
147
      Bit#(1) horOut = 0;
148
      Bit#(TAdd#(PicWidthSz,2)) horAddr;
149
      Bit#(TAdd#(PicHeightSz,4)) verAddr;
150
      Bit#(TAdd#(PicWidthSz,12)) horTemp = zeroExtend({reqdata.hor,2'b00}) + zeroExtend({loadHorNum,2'b00}) + (xfracl==3&&(yfracl==1||yfracl==3)&&loadStage==0 ? 1 : 0);
151
      Bit#(TAdd#(PicHeightSz,10)) verTemp = zeroExtend(reqdata.ver) + zeroExtend(loadVerNum) + (yfracl==3&&(xfracl==1||xfracl==3)&&loadStage==1 ? 1 : 0);
152
      Bit#(13) mvhortemp = signExtend(reqdata.mvhor[13:2])-(horInter?2:0);
153
      Bit#(11) mvvertemp = signExtend(reqdata.mvver[11:2])-(verInter?2:0);
154
      if(mvhortemp[12]==1 && zeroExtend(0-mvhortemp)>horTemp)
155
         begin
156
            horAddr = 0;
157
            horOut = 1;
158
         end
159
      else
160
         begin
161
            horTemp = horTemp + signExtend(mvhortemp);
162
            if(horTemp>=zeroExtend({picWidth,4'b0000}))
163
               begin
164
                  horAddr = {picWidth-1,2'b11};
165
                  horOut = 1;
166
               end
167
            else
168
               horAddr = truncate(horTemp>>2);
169
         end
170
      if(mvvertemp[10]==1 && zeroExtend(0-mvvertemp)>verTemp)
171
         verAddr = 0;
172
      else
173
         begin
174
            verTemp = verTemp + signExtend(mvvertemp);
175
            if(verTemp>=zeroExtend({picHeight,4'b0000}))
176
               verAddr = {picHeight-1,4'b1111};
177
            else
178
               verAddr = truncate(verTemp);
179
         end
180 91 jamey.hick
      $display("PARDEBLOCK issuing Luma memory req");
181 90 jamey.hick
      memReqQ.enq(IPLoadLuma {refIdx:reqdata.refIdx,horOutOfBounds:horOut,hor:horAddr,ver:verAddr});
182
      Bool verFirst = twoStage || (yfracl==2&&(xfracl==1||xfracl==3));
183
      Bit#(2) loadHorNumMax = (reqdata.bt==IP8x8||reqdata.bt==IP8x4 ? 1 : 0) + (horInter ? 2 : (offset2==0 ? 0 : 1));
184
      Bit#(4) loadVerNumMax = (reqdata.bt==IP8x8||reqdata.bt==IP4x8 ? 7 : 3) + (verInter ? 5 : 0);
185
      if(verFirst)
186
         begin
187
            if(loadVerNum < loadVerNumMax)
188
               loadVerNum <= loadVerNum+1;
189
            else
190
               begin
191
                  loadVerNum <= 0;
192
                  if(loadHorNum < loadHorNumMax)
193
                     begin
194
                        if(loadStage == 1)
195
                           begin
196
                              offset = offset + (xfracl==3 ? 1 : 0);
197
                              if(!(offset==1 || (xfracl==3 && offset==2)))
198
                                 loadHorNum <= loadHorNumMax;
199
                              else
200
                                 begin
201
                                    loadHorNum <= 0;
202
                                    loadStage <= 0;
203
                                    reqfifoLoad.deq();
204
                                 end
205
                           end
206
                        else
207
                           loadHorNum <= loadHorNum+1;
208
                     end
209
                  else
210
                     begin
211
                        if(twoStage && loadStage==0)
212
                           begin
213
                              offset = offset + (xfracl==3 ? 1 : 0);
214
                              if((xfracl==3 ? offset<3 : offset<2))
215
                                 loadHorNum <= 0;
216
                              else
217
                                 loadHorNum <= loadHorNumMax+1;
218
                              loadStage <= 1;
219
                           end
220
                        else
221
                           begin
222
                              loadHorNum <= 0;
223
                              loadStage <= 0;
224
                              reqfifoLoad.deq();
225
                           end
226
                     end
227
               end
228
         end
229
      else
230
         begin
231
            if(loadHorNum < loadHorNumMax)
232
               loadHorNum <= loadHorNum+1;
233
            else
234
               begin
235
                  loadHorNum <= 0;
236
                  if(loadVerNum < loadVerNumMax)
237
                     loadVerNum <= loadVerNum+1;
238
                  else
239
                     begin
240
                        loadVerNum <= 0;
241
                        reqfifoLoad.deq();
242
                     end
243
               end
244
         end
245
      if(reqdata.bt==IP16x16 || reqdata.bt==IP16x8 || reqdata.bt==IP8x16)
246
         $display( "ERROR Interpolation: loadLuma block sizes > 8x8 not supported");
247 91 jamey.hick
      $display( "PARDEBLOCK Trace interpolator(%0d)): loadLuma %h %h %h %h %h %h %h", total_cycles,xfracl, yfracl, loadHorNum, loadVerNum, reqdata.refIdx, horAddr, verAddr);
248 90 jamey.hick
   endrule
249
 
250
 
251
   rule loadChroma( reqfifoLoad.first() matches tagged IPChroma .reqdata &&& !endOfFrameFlag );
252
      Bit#(3) xfracc = reqdata.mvhor[2:0];
253
      Bit#(3) yfracc = reqdata.mvver[2:0];
254
      Bit#(2) offset = reqdata.mvhor[4:3]+{reqdata.hor[0],1'b0};
255
      Bit#(1) horOut = 0;
256
      Bit#(TAdd#(PicWidthSz,1)) horAddr;
257
      Bit#(TAdd#(PicHeightSz,3)) verAddr;
258
      Bit#(TAdd#(PicWidthSz,11)) horTemp = zeroExtend({reqdata.hor,1'b0}) + zeroExtend({loadHorNum,2'b00});
259
      Bit#(TAdd#(PicHeightSz,9)) verTemp = zeroExtend(reqdata.ver) + zeroExtend(loadVerNum);
260
      if(reqdata.mvhor[13]==1 && zeroExtend(0-reqdata.mvhor[13:3])>horTemp)
261
         begin
262
            horAddr = 0;
263
            horOut = 1;
264
         end
265
      else
266
         begin
267
            horTemp = horTemp + signExtend(reqdata.mvhor[13:3]);
268
            if(horTemp>=zeroExtend({picWidth,3'b000}))
269
               begin
270
                  horAddr = {picWidth-1,1'b1};
271
                  horOut = 1;
272
               end
273
            else
274
               horAddr = truncate(horTemp>>2);
275
         end
276
      if(reqdata.mvver[11]==1 && zeroExtend(0-reqdata.mvver[11:3])>verTemp)
277
         verAddr = 0;
278
      else
279
         begin
280
            verTemp = verTemp + signExtend(reqdata.mvver[11:3]);
281
            if(verTemp>=zeroExtend({picHeight,3'b000}))
282
               verAddr = {picHeight-1,3'b111};
283
            else
284
               verAddr = truncate(verTemp);
285
         end
286 91 jamey.hick
      $display("PARDEBLOCK issuing Chroma memory req");
287 90 jamey.hick
      memReqQ.enq(IPLoadChroma {refIdx:reqdata.refIdx,uv:reqdata.uv,horOutOfBounds:horOut,hor:horAddr,ver:verAddr});
288
      Bit#(2) loadHorNumMax = (reqdata.bt==IP4x8||reqdata.bt==IP4x4 ? (offset[1]==0||(xfracc==0&&offset!=3) ? 0 : 1) : ((reqdata.bt==IP16x16||reqdata.bt==IP16x8 ? 1 : 0) + (xfracc==0&&offset==0 ? 0 : 1)));
289
      Bit#(4) loadVerNumMax = (reqdata.bt==IP16x16||reqdata.bt==IP8x16 ? 7 : (reqdata.bt==IP16x8||reqdata.bt==IP8x8||reqdata.bt==IP4x8 ? 3 : 1)) + (yfracc==0 ? 0 : 1);
290
      if(loadHorNum < loadHorNumMax)
291
         loadHorNum <= loadHorNum+1;
292
      else
293
         begin
294
            loadHorNum <= 0;
295
            if(loadVerNum < loadVerNumMax)
296
               loadVerNum <= loadVerNum+1;
297
            else
298
               begin
299
                  loadVerNum <= 0;
300
                  reqfifoLoad.deq();
301
               end
302
         end
303 91 jamey.hick
      $display( "PARDEB Trace interpolator(%0d): loadChroma %h %h %h %h %h %h %h", total_cycles, xfracc, yfracc, loadHorNum, loadVerNum, reqdata.refIdx, horAddr, verAddr);
304 90 jamey.hick
   endrule
305
 
306
 
307
   rule work1Luma ( reqfifoWork1.first() matches tagged IPWLuma .reqdata &&& !work1Done );
308
      let xfracl = reqdata.xFracL;
309
      let yfracl = reqdata.yFracL;
310
      let offset = reqdata.offset;
311
      let blockT = reqdata.bt;
312
      Bool twoStage = (xfracl==1||xfracl==3) && (yfracl==1||yfracl==3);
313
      Vector#(20,Bit#(8)) work1Vector8Next = work1Vector8;
314
      if(memRespQ.first() matches tagged IPLoadResp .tempreaddata)
315
         begin
316
            memRespQ.deq();
317
            Vector#(4,Bit#(8)) readdata = replicate(0);
318
            readdata[0] = tempreaddata[7:0];
319
            readdata[1] = tempreaddata[15:8];
320
            readdata[2] = tempreaddata[23:16];
321
            readdata[3] = tempreaddata[31:24];
322
            //$display( "Trace interpolator: workLuma stage 0 readdata %h %h %h %h %h %h", workHorNum, workVerNum, readdata[3], readdata[2], readdata[1], readdata[0] );
323
            Vector#(4,Bit#(8)) tempResult8 = replicate(0);
324
            Vector#(4,Bit#(15)) tempResult15 = replicate(0);
325
            if(xfracl==0 || yfracl==0 || xfracl==2)
326
               begin
327
                  if(xfracl==0)//reorder
328
                     begin
329
                        for(Integer ii=0; ii<4; ii=ii+1)
330
                           begin
331
                              Bit#(2) offsetplusii = offset+fromInteger(ii);
332
                              if(offset <= 3-fromInteger(ii) && offset!=0)
333
                                 tempResult8[ii] = work1Vector8[offsetplusii];
334
                              else
335
                                 tempResult8[ii] = readdata[offsetplusii];
336
                              work1Vector8Next[ii] = readdata[ii];
337
                           end
338
                        for(Integer ii=0; ii<4; ii=ii+1)
339
                           tempResult15[ii] = zeroExtend({tempResult8[ii],5'b00000});
340
                     end
341
                  else//horizontal interpolation
342
                     begin
343
                        offset = offset-2;
344
                        for(Integer ii=0; ii<8; ii=ii+1)
345
                           work1Vector8Next[ii] = work1Vector8[ii+4];
346
                        for(Integer ii=0; ii<4; ii=ii+1)
347
                           begin
348
                              Bit#(4) tempIndex = fromInteger(ii) + 8 - zeroExtend(offset);
349
                              work1Vector8Next[tempIndex] = readdata[ii];
350
                           end
351
                        for(Integer ii=0; ii<4; ii=ii+1)
352
                           begin
353
                              tempResult15[ii] = interpolate8to15(work1Vector8Next[ii],work1Vector8Next[ii+1],work1Vector8Next[ii+2],work1Vector8Next[ii+3],work1Vector8Next[ii+4],work1Vector8Next[ii+5]);
354
                              tempResult8[ii] = clip1y10to8(truncate((tempResult15[ii]+16)>>5));
355
                              if(xfracl == 1)
356
                                 tempResult8[ii] = truncate(({1'b0,tempResult8[ii]} + {1'b0,work1Vector8Next[ii+2]} + 1) >> 1);
357
                              else if(xfracl == 3)
358
                                 tempResult8[ii] = truncate(({1'b0,tempResult8[ii]} + {1'b0,work1Vector8Next[ii+3]} + 1) >> 1);
359
                           end
360
                     end
361
                  Bit#(2) workHorNumOffset = (xfracl!=0 ? 2 : (reqdata.offset==0 ? 0 : 1));
362
                  if(work1HorNum >= workHorNumOffset)
363
                     begin
364
                        Bit#(1) horAddr = truncate(work1HorNum-workHorNumOffset);
365
                        if(yfracl == 0)
366
                           begin
367
                              for(Integer ii=0; ii<4; ii=ii+1)
368
                                 tempResult15[ii] = zeroExtend({tempResult8[ii],5'b00000});
369
                           end
370
                        workFile.upd({workFileFlag,work1VerNum,horAddr},tempResult15);
371
                     end
372
                  Bit#(2) workHorNumMax = (blockT==IP8x8||blockT==IP8x4 ? 1 : 0) + workHorNumOffset;
373
                  Bit#(4) workVerNumMax = (blockT==IP8x8||blockT==IP4x8 ? 7 : 3) + (yfracl!=0 ? 5 : 0);
374
                  if(work1HorNum < workHorNumMax)
375
                     work1HorNum <= work1HorNum+1;
376
                  else
377
                     begin
378
                        work1HorNum <= 0;
379
                        if(work1VerNum < workVerNumMax)
380
                           work1VerNum <= work1VerNum+1;
381
                        else
382
                           begin
383
                              work1VerNum <= 0;
384
                              work1Done <= True;
385
                           end
386
                     end
387
               end
388
            else if(work1Stage == 0)//vertical interpolation
389
               begin
390
                  offset = offset + (xfracl==3&&(yfracl==1||yfracl==3) ? 1 : 0);
391
                  for(Integer ii=0; ii<4; ii=ii+1)
392
                     tempResult15[ii] = interpolate8to15(work1Vector8[ii],work1Vector8[ii+4],work1Vector8[ii+8],work1Vector8[ii+12],work1Vector8[ii+16],readdata[ii]);
393
                  for(Integer ii=0; ii<16; ii=ii+1)
394
                     work1Vector8Next[ii] = work1Vector8[ii+4];
395
                  for(Integer ii=0; ii<4; ii=ii+1)
396
                     work1Vector8Next[ii+16] = readdata[ii];
397
                  Bit#(2) workHorNumMax = (blockT==IP8x8||blockT==IP8x4 ? 1 : 0) + (yfracl==2 ? 2 : (offset==0 ? 0 : 1));
398
                  Bit#(4) workVerNumMax = (blockT==IP8x8||blockT==IP4x8 ? 7 : 3) + 5;
399
                  Bit#(2) horAddr = work1HorNum;
400
                  Bit#(3) verAddr = truncate(work1VerNum-5);
401
                  if(work1VerNum > 4)
402
                     begin
403
                        workFile.upd({workFileFlag,verAddr,horAddr},tempResult15);
404
                        //$display( "Trace interpolator: workLuma stage 0 result %h %h %h %h %h %h %h", workHorNum, workVerNum, {verAddr,horAddr}, tempResult15[3], tempResult15[2], tempResult15[1], tempResult15[0]);
405
                     end
406
                  if(twoStage)
407
                     begin
408
                        Bit#(2) storeHorAddr = work1HorNum;
409
                        Bit#(4) storeVerAddr = work1VerNum;
410
                        if((xfracl==3 ? offset<3 : offset<2))
411
                           storeHorAddr = storeHorAddr+1;
412
                        if(yfracl==3)
413
                           storeVerAddr = storeVerAddr-3;
414
                        else
415
                           storeVerAddr = storeVerAddr-2;
416
                        if(storeVerAddr < 8)
417
                           storeFile.upd({workFileFlag,storeVerAddr[2:0],storeHorAddr},readdata);
418
                     end
419
                  if(work1VerNum < workVerNumMax)
420
                     work1VerNum <= work1VerNum+1;
421
                  else
422
                     begin
423
                        work1VerNum <= 0;
424
                        if(work1HorNum < workHorNumMax)
425
                           work1HorNum <= work1HorNum+1;
426
                        else
427
                           begin
428
                              if(twoStage)
429
                                 begin
430
                                    work1Stage <= 1;
431
                                    if((xfracl==3 ? offset<3 : offset<2))
432
                                       work1HorNum <= 0;
433
                                    else
434
                                       work1HorNum <= workHorNumMax+1;
435
                                 end
436
                              else
437
                                 begin
438
                                    work1HorNum <= 0;
439
                                    work1Done <= True;
440
                                 end
441
                           end
442
                     end
443
               end
444
            else//second stage of twoStage
445
               begin
446
                  storeFile.upd({workFileFlag,work1VerNum[2:0],work1HorNum},readdata);
447
                  Bit#(2) workHorNumMax = (blockT==IP8x8||blockT==IP8x4 ? 1 : 0) + 2;
448
                  Bit#(4) workVerNumMax = (blockT==IP8x8||blockT==IP4x8 ? 7 : 3);
449
                  if(work1VerNum < workVerNumMax)
450
                     work1VerNum <= work1VerNum+1;
451
                  else
452
                     begin
453
                        work1VerNum <= 0;
454
                        offset = offset + (xfracl==3 ? 1 : 0);
455
                        if(work1HorNum
456
                           work1HorNum <= workHorNumMax;
457
                        else
458
                           begin
459
                              work1HorNum <= 0;
460
                              work1Stage <= 0;
461
                              work1Done <= True;
462
                           end
463
                     end
464
               end
465
         end
466
      work1Vector8 <= work1Vector8Next;
467 91 jamey.hick
      $display( "PARDEBLOCK Trace interpolator(%0d): work1Luma %h %h %h %h %h %h", total_cycles, xfracl, yfracl, work1HorNum, work1VerNum, offset, work1Stage);
468 90 jamey.hick
   endrule
469
 
470
 
471
   rule work2Luma ( reqregWork2 matches tagged Valid .vdata &&& vdata matches tagged IPWLuma .reqdata &&& !work2Done &&& !work8x8Done );
472
      let xfracl = reqdata.xFracL;
473
      let yfracl = reqdata.yFracL;
474
      let offset = reqdata.offset;
475
      let blockT = reqdata.bt;
476
      Vector#(20,Bit#(8)) work2Vector8Next = work2Vector8;
477
      Vector#(20,Bit#(15)) work2Vector15Next = work2Vector15;
478
      Vector#(16,Bit#(1)) resultReadyNext = resultReady;
479
      Vector#(4,Bit#(8)) tempResult8 = replicate(0);
480
      Vector#(4,Bit#(15)) readdata = replicate(0);
481
      if(yfracl==0)
482
         begin
483
            readdata = workFile.sub({(1-workFileFlag),1'b0,work2VerNum[1],work2HorNum,work2VerNum[0]});
484
            for(Integer ii=0; ii<4; ii=ii+1)
485
               tempResult8[ii] = (readdata[ii])[12:5];
486
            resultFile.upd({work2VerNum[1],work2HorNum,work2VerNum[0]},tempResult8);
487
            resultReadyNext[{work2VerNum[1],work2HorNum,work2VerNum[0]}] = 1;
488
            work2HorNum <= work2HorNum+1;
489
            if(work2HorNum == 3)
490
               begin
491
                  if(work2VerNum == 3)
492
                     begin
493
                        work2VerNum <= 0;
494
                        work2Done <= True;
495
                        if(((blockT==IP4x8 || blockT==IP8x4) && work2SubMbPart==0) || (blockT==IP4x4 && work2SubMbPart<3))
496
                           work2SubMbPart <= work2SubMbPart+1;
497
                        else
498
                           begin
499
                              work2SubMbPart <= 0;
500
                              work8x8Done <= True;
501
                           end
502
                     end
503
                  else
504
                     work2VerNum <= work2VerNum+1;
505
               end
506
         end
507
      else if(xfracl==0 || xfracl==2)//vertical interpolation
508
         begin
509
            readdata = workFile.sub({(1-workFileFlag),work2VerNum,work2HorNum[0]});
510
            for(Integer ii=0; ii<4; ii=ii+1)
511
               begin
512
                  tempResult8[ii] = interpolate15to8(work2Vector15[ii],work2Vector15[ii+4],work2Vector15[ii+8],work2Vector15[ii+12],work2Vector15[ii+16],readdata[ii]);
513
                  if(yfracl == 1)
514
                     tempResult8[ii] = truncate(({1'b0,tempResult8[ii]} + {1'b0,clip1y10to8(truncate((work2Vector15[ii+8]+16)>>5))} + 1) >> 1);
515
                  else if(yfracl == 3)
516
                     tempResult8[ii] = truncate(({1'b0,tempResult8[ii]} + {1'b0,clip1y10to8(truncate((work2Vector15[ii+12]+16)>>5))} + 1) >> 1);
517
               end
518
            for(Integer ii=0; ii<16; ii=ii+1)
519
               work2Vector15Next[ii] = work2Vector15[ii+4];
520
            for(Integer ii=0; ii<4; ii=ii+1)
521
               work2Vector15Next[ii+16] = readdata[ii];
522
            Bit#(2) workHorNumMax = 1;
523
            Bit#(4) workVerNumMax = (blockT==IP8x8||blockT==IP4x8 ? 7 : 3) + 5;
524
            if(work2VerNum > 4)
525
               begin
526
                  Bit#(1) horAddr = truncate(work2HorNum);
527
                  Bit#(3) verAddr = truncate(work2VerNum-5);
528
                  horAddr = horAddr + ((blockT==IP4x8&&work2SubMbPart==1)||(blockT==IP4x4&&work2SubMbPart[0]==1) ? 1 : 0);
529
                  verAddr = verAddr + ((blockT==IP8x4&&work2SubMbPart==1)||(blockT==IP4x4&&work2SubMbPart[1]==1) ? 4 : 0);
530
                  resultFile.upd({verAddr,horAddr},tempResult8);
531
                  resultReadyNext[{verAddr,horAddr}] = 1;
532
               end
533
            if(work2VerNum < workVerNumMax)
534
               work2VerNum <= work2VerNum+1;
535
            else
536
               begin
537
                  work2VerNum <= 0;
538
                  if(work2HorNum < workHorNumMax)
539
                     work2HorNum <= work2HorNum+1;
540
                  else
541
                     begin
542
                        work2HorNum <= 0;
543
                        work2Done <= True;
544
                        if(((blockT==IP4x8 || blockT==IP8x4) && work2SubMbPart==0) || (blockT==IP4x4 && work2SubMbPart<3))
545
                           work2SubMbPart <= work2SubMbPart+1;
546
                        else
547
                           begin
548
                              work2SubMbPart <= 0;
549
                              work8x8Done <= True;
550
                           end
551
                     end
552
               end
553
         end
554
      else//horizontal interpolation
555
         begin
556
            offset = offset-2;
557
            if(yfracl == 2)
558
               begin
559
                  readdata = workFile.sub({(1-workFileFlag),work2VerNum[2:0],work2HorNum});
560
                  for(Integer ii=0; ii<8; ii=ii+1)
561
                     work2Vector15Next[ii] = work2Vector15[ii+4];
562
                  for(Integer ii=0; ii<4; ii=ii+1)
563
                     begin
564
                        Bit#(4) tempIndex = fromInteger(ii) + 8 - zeroExtend(offset);
565
                        work2Vector15Next[tempIndex] = readdata[ii];
566
                     end
567
                  for(Integer ii=0; ii<4; ii=ii+1)
568
                     begin
569
                        tempResult8[ii] = interpolate15to8(work2Vector15Next[ii],work2Vector15Next[ii+1],work2Vector15Next[ii+2],work2Vector15Next[ii+3],work2Vector15Next[ii+4],work2Vector15Next[ii+5]);
570
                        if(xfracl == 1)
571
                           tempResult8[ii] = truncate(({1'b0,tempResult8[ii]} + {1'b0,clip1y10to8(truncate((work2Vector15Next[ii+2]+16)>>5))} + 1) >> 1);
572
                        else if(xfracl == 3)
573
                           tempResult8[ii] = truncate(({1'b0,tempResult8[ii]} + {1'b0,clip1y10to8(truncate((work2Vector15Next[ii+3]+16)>>5))} + 1) >> 1);
574
                     end
575
               end
576
            else
577
               begin
578
                  Vector#(4,Bit#(8)) readdata8 = storeFile.sub({(1-workFileFlag),work2VerNum[2:0],work2HorNum});
579
                  for(Integer ii=0; ii<8; ii=ii+1)
580
                     work2Vector8Next[ii] = work2Vector8[ii+4];
581
                  for(Integer ii=0; ii<4; ii=ii+1)
582
                     begin
583
                        Bit#(4) tempIndex = fromInteger(ii) + 8 - zeroExtend(offset);
584
                        work2Vector8Next[tempIndex] = readdata8[ii];
585
                     end
586
                  Vector#(4,Bit#(15)) tempResult15 = replicate(0);
587
                  for(Integer ii=0; ii<4; ii=ii+1)
588
                     begin
589
                        tempResult15[ii] = interpolate8to15(work2Vector8Next[ii],work2Vector8Next[ii+1],work2Vector8Next[ii+2],work2Vector8Next[ii+3],work2Vector8Next[ii+4],work2Vector8Next[ii+5]);
590
                        tempResult8[ii] = clip1y10to8(truncate((tempResult15[ii]+16)>>5));
591
                     end
592
                  Bit#(2) verOffset;
593
                  Vector#(4,Bit#(15)) verResult15 = replicate(0);
594
                  if(xfracl == 1)
595
                     verOffset = reqdata.offset;
596
                  else
597
                     verOffset = reqdata.offset+1;
598
                  readdata = workFile.sub({(1-workFileFlag),work2VerNum[2:0],(work2HorNum-2+(verOffset==0?0:1))});
599
                  for(Integer ii=0; ii<4; ii=ii+1)
600
                     begin
601
                        Bit#(2) offsetplusii = verOffset+fromInteger(ii);
602
                        if(verOffset <= 3-fromInteger(ii) && verOffset!=0)
603
                           verResult15[ii] = work2Vector15[offsetplusii];
604
                        else
605
                           verResult15[ii] = readdata[offsetplusii];
606
                        work2Vector15Next[ii] = readdata[ii];
607
                     end
608
                  for(Integer ii=0; ii<4; ii=ii+1)
609
                     begin
610
                        Bit#(9) tempVal = zeroExtend(clip1y10to8(truncate((verResult15[ii]+16)>>5)));
611
                        tempResult8[ii] = truncate((tempVal+zeroExtend(tempResult8[ii])+1)>>1);
612
                     end
613
               end
614
            if(work2HorNum >= 2)
615
               begin
616
                  Bit#(1) horAddr = truncate(work2HorNum-2);
617
                  Bit#(3) verAddr = truncate(work2VerNum);
618
                  horAddr = horAddr + ((blockT==IP4x8&&work2SubMbPart==1)||(blockT==IP4x4&&work2SubMbPart[0]==1) ? 1 : 0);
619
                  verAddr = verAddr + ((blockT==IP8x4&&work2SubMbPart==1)||(blockT==IP4x4&&work2SubMbPart[1]==1) ? 4 : 0);
620
                  resultFile.upd({verAddr,horAddr},tempResult8);
621
                  resultReadyNext[{verAddr,horAddr}] = 1;
622
                  //$display( "Trace interpolator: workLuma stage 1 result %h %h %h %h %h %h %h %h", workHorNum, workVerNum, {verAddr,horAddr}, tempResult8[3], tempResult8[2], tempResult8[1], tempResult8[0], pack(resultReadyNext));
623
               end
624
            Bit#(2) workHorNumMax = (blockT==IP8x8||blockT==IP8x4 ? 1 : 0) + 2;
625
            Bit#(4) workVerNumMax = (blockT==IP8x8||blockT==IP4x8 ? 7 : 3);
626
            if(work2HorNum < workHorNumMax)
627
               work2HorNum <= work2HorNum+1;
628
            else
629
               begin
630
                  work2HorNum <= 0;
631
                  if(work2VerNum < workVerNumMax)
632
                     work2VerNum <= work2VerNum+1;
633
                  else
634
                     begin
635
                        work2VerNum <= 0;
636
                        work2Done <= True;
637
                        if(((blockT==IP4x8 || blockT==IP8x4) && work2SubMbPart==0) || (blockT==IP4x4 && work2SubMbPart<3))
638
                           work2SubMbPart <= work2SubMbPart+1;
639
                        else
640
                           begin
641
                              work2SubMbPart <= 0;
642
                              work8x8Done <= True;
643
                           end
644
                     end
645
               end
646
         end
647
      work2Vector8 <= work2Vector8Next;
648
      work2Vector15 <= work2Vector15Next;
649
      resultReady <= resultReadyNext;
650 91 jamey.hick
      $display( "PARDEBLOCK Trace interpolator%(0d): work2Luma %h %h %h %h %h",total_cycles, xfracl, yfracl, work2HorNum, work2VerNum, offset);
651 90 jamey.hick
   endrule
652
 
653
 
654
   rule work1Chroma ( reqfifoWork1.first() matches tagged IPWChroma .reqdata &&& !work1Done );
655
      Bit#(4) xfracc = zeroExtend(reqdata.xFracC);
656
      Bit#(4) yfracc = zeroExtend(reqdata.yFracC);
657
      let offset = reqdata.offset;
658
      let blockT = reqdata.bt;
659
      Vector#(20,Bit#(8)) work1Vector8Next = work1Vector8;
660
      if(memRespQ.first() matches tagged IPLoadResp .tempreaddata)
661
         begin
662
            memRespQ.deq();
663
            Vector#(4,Bit#(8)) readdata = replicate(0);
664
            readdata[0] = tempreaddata[7:0];
665
            readdata[1] = tempreaddata[15:8];
666
            readdata[2] = tempreaddata[23:16];
667
            readdata[3] = tempreaddata[31:24];
668
            Vector#(5,Bit#(8)) tempWork8 = replicate(0);
669
            Vector#(5,Bit#(8)) tempPrev8 = replicate(0);
670
            Vector#(4,Bit#(8)) tempResult8 = replicate(0);
671
            Bool resultReadyFlag = False;
672
            for(Integer ii=0; ii<4; ii=ii+1)
673
               begin
674
                  Bit#(2) offsetplusii = offset+fromInteger(ii);
675
                  if(offset <= 3-fromInteger(ii) && !((blockT==IP4x8||blockT==IP4x4)&&(offset[1]==0||(xfracc==0&&offset!=3))) && !(xfracc==0&&offset==0))
676
                     tempWork8[ii] = work1Vector8[offsetplusii];
677
                  else
678
                     tempWork8[ii] = readdata[offsetplusii];
679
                  work1Vector8Next[ii] = readdata[ii];
680
               end
681
            tempWork8[4] = readdata[offset];
682
            if((blockT==IP16x8 || blockT==IP16x16) && work1HorNum==(xfracc==0&&offset==0 ? 1 : 2))
683
               begin
684
                  for(Integer ii=0; ii<5; ii=ii+1)
685
                     begin
686
                        tempPrev8[ii] = work1Vector8[ii+9];
687
                        work1Vector8Next[ii+9] = tempWork8[ii];
688
                     end
689
               end
690
            else
691
               begin
692
                  for(Integer ii=0; ii<5; ii=ii+1)
693
                     tempPrev8[ii] = work1Vector8[ii+4];
694
                  if(work1HorNum==(xfracc==0&&offset==0 ? 0 : 1) || ((blockT==IP4x8||blockT==IP4x4)&&(offset[1]==0||(xfracc==0&&offset!=3))))
695
                     begin
696
                        for(Integer ii=0; ii<5; ii=ii+1)
697
                           work1Vector8Next[ii+4] = tempWork8[ii];
698
                     end
699
               end
700
            if(yfracc==0)
701
               begin
702
                  for(Integer ii=0; ii<5; ii=ii+1)
703
                     tempPrev8[ii] = tempWork8[ii];
704
               end
705
            for(Integer ii=0; ii<4; ii=ii+1)
706
               begin
707
                  Bit#(14) tempVal = zeroExtend((8-xfracc))*zeroExtend((8-yfracc))*zeroExtend(tempPrev8[ii]);
708
                  tempVal = tempVal + zeroExtend(xfracc)*zeroExtend((8-yfracc))*zeroExtend(tempPrev8[ii+1]);
709
                  tempVal = tempVal + zeroExtend((8-xfracc))*zeroExtend(yfracc)*zeroExtend(tempWork8[ii]);
710
                  tempVal = tempVal + zeroExtend(xfracc)*zeroExtend(yfracc)*zeroExtend(tempWork8[ii+1]);
711
                  tempResult8[ii] = truncate((tempVal+32)>>6);
712
               end
713
            if(work1VerNum > 0 || yfracc==0)
714
               begin
715
                  if(blockT==IP4x8 || blockT==IP4x4)
716
                     begin
717
                        Bit#(5) tempIndex = 10 + zeroExtend(work1VerNum<<1);
718
                        work1Vector8Next[tempIndex] = tempResult8[0];
719
                        work1Vector8Next[tempIndex+1] = tempResult8[1];
720
                        tempResult8[2] = tempResult8[0];
721
                        tempResult8[3] = tempResult8[1];
722
                        tempResult8[0] = work1Vector8[tempIndex];
723
                        tempResult8[1] = work1Vector8[tempIndex+1];
724
                        if((work1HorNum>0 || offset[1]==0) && work1SubMbPart[0]==1)
725
                           resultReadyFlag = True;
726
                     end
727
                  else
728
                     begin
729
                        if(work1HorNum>0 || (xfracc==0 && offset==0))
730
                           resultReadyFlag = True;
731
                     end
732
               end
733
            if(resultReadyFlag)
734
               begin
735
                  Bit#(1) horAddr = ((blockT==IP4x8 || blockT==IP4x4) ? 0 : truncate(((xfracc==0 && offset==0) ? work1HorNum : work1HorNum-1)));
736
                  Bit#(3) verAddr = truncate((yfracc==0 ? work1VerNum : work1VerNum-1));
737
                  horAddr = horAddr + ((blockT==IP16x8||blockT==IP16x16) ? 0 : work1MbPart[0]);
738
                  verAddr = verAddr + ((blockT==IP8x16||blockT==IP16x16) ? 0 : ((blockT==IP16x8) ? {work1MbPart[0],2'b00} : {work1MbPart[1],2'b00}));
739
                  verAddr = verAddr + ((blockT==IP8x4&&work1SubMbPart==1)||(blockT==IP4x4&&work1SubMbPart[1]==1) ? 2 : 0);
740
                  storeFile.upd({workFileFlag,1'b0,verAddr,horAddr},tempResult8);
741
               end
742
            Bit#(2) workHorNumMax = (blockT==IP4x8||blockT==IP4x4 ? (offset[1]==0||(xfracc==0&&offset!=3) ? 0 : 1) : ((blockT==IP16x16||blockT==IP16x8 ? 1 : 0) + (xfracc==0&&offset==0 ? 0 : 1)));
743
            Bit#(4) workVerNumMax = (blockT==IP16x16||blockT==IP8x16 ? 7 : (blockT==IP16x8||blockT==IP8x8||blockT==IP4x8 ? 3 : 1)) + (yfracc==0 ? 0 : 1);
744
            if(work1HorNum < workHorNumMax)
745
               work1HorNum <= work1HorNum+1;
746
            else
747
               begin
748
                  work1HorNum <= 0;
749
                  if(work1VerNum < workVerNumMax)
750
                     work1VerNum <= work1VerNum+1;
751
                  else
752
                     begin
753
                        Bool allDone = False;
754
                        work1VerNum <= 0;
755
                        if(((blockT==IP4x8 || blockT==IP8x4) && work1SubMbPart==0) || (blockT==IP4x4 && work1SubMbPart<3))
756
                           work1SubMbPart <= work1SubMbPart+1;
757
                        else
758
                           begin
759
                              work1SubMbPart <= 0;
760
                              if(((blockT==IP16x8 || blockT==IP8x16) && work1MbPart==0) || (!(blockT==IP16x8 || blockT==IP8x16 || blockT==IP16x16) && work1MbPart<3))
761
                                 work1MbPart <= work1MbPart+1;
762
                              else
763
                                 begin
764
                                    work1MbPart <= 0;
765
                                    work1Done <= True;
766
                                    allDone = True;
767
                                 end
768
                           end
769
                        if(!allDone)
770
                           reqfifoWork1.deq();
771
                     end
772
               end
773
         end
774
      work1Vector8 <= work1Vector8Next;
775 91 jamey.hick
      $display( "PARDEBLOCK Trace interpolator(%0d): work1Chroma %h %h %h %h %h", total_cycles, xfracc, yfracc, work1HorNum, work1VerNum, offset);
776 90 jamey.hick
   endrule
777
 
778
 
779
   rule work2Chroma ( reqregWork2 matches tagged Valid .vdata &&& vdata matches tagged IPWChroma .reqdata &&& !work2Done &&& !work8x8Done );
780
      Vector#(16,Bit#(1)) resultReadyNext = resultReady;
781
      resultFile.upd({work2VerNum[1],work2HorNum,work2VerNum[0]},storeFile.sub({(1-workFileFlag),1'b0,work2VerNum[1],work2HorNum,work2VerNum[0]}));
782
      resultReadyNext[{work2VerNum[1],work2HorNum,work2VerNum[0]}] = 1;
783
      work2HorNum <= work2HorNum+1;
784
      if(work2HorNum == 3)
785
         begin
786
            if(work2VerNum == 3)
787
               begin
788
                  work2VerNum <= 0;
789
                  work2Done <= True;
790
                  work8x8Done <= True;
791
               end
792
            else
793
               work2VerNum <= work2VerNum+1;
794
         end
795
      resultReady <= resultReadyNext;
796 91 jamey.hick
      $display( "PARDEBLOCK Trace interpolator(%0d): work2Chroma %h %h", total_cycles, work2HorNum, work2VerNum);
797 90 jamey.hick
   endrule
798
 
799
 
800
  rule outputing( !outDone && resultReady[{outBlockNum[1],outPixelNum,outBlockNum[0]}]==1 );
801
      outfifo.enq(resultFile.sub({outBlockNum[1],outPixelNum,outBlockNum[0]}));
802
      outPixelNum <= outPixelNum+1;
803
      if(outPixelNum == 3)
804
         begin
805
            outBlockNum <= outBlockNum+1;
806
            if(outBlockNum == 3)
807
               outDone <= True;
808
         end
809 91 jamey.hick
      $display( "PARDEBLOCK Trace interpolator(%0d): outputing %h %h", total_cycles, outBlockNum, outPixelNum);
810 90 jamey.hick
   endrule
811
 
812
 
813
   rule switching( work1Done && (work2Done || reqregWork2==Invalid) && !work8x8Done);
814
      work1Done <= False;
815
      work2Done <= False;
816
      reqregWork2 <= (tagged Valid reqfifoWork1.first());
817
      workFileFlag <= 1-workFileFlag;
818
      reqfifoWork1.deq();
819
      $display( "Trace interpolator: switching %h %h", outBlockNum, outPixelNum);
820
   endrule
821
 
822
 
823
   rule switching8x8( work1Done && (work2Done || reqregWork2==Invalid) && work8x8Done && outDone);
824
      outDone <= False;
825
      work8x8Done <= False;
826
      resultReady <= replicate(0);
827
      work1Done <= False;
828
      work2Done <= False;
829
      reqregWork2 <= (tagged Valid reqfifoWork1.first());
830
      workFileFlag <= 1-workFileFlag;
831
      reqfifoWork1.deq();
832
      $display( "Trace interpolator: switching8x8 %h %h", outBlockNum, outPixelNum);
833
   endrule
834
 
835
 
836
 
837
   method Action   setPicWidth( Bit#(PicWidthSz) newPicWidth );
838
      picWidth <= newPicWidth;
839
   endmethod
840
 
841
   method Action   setPicHeight( Bit#(PicHeightSz) newPicHeight );
842
      picHeight <= newPicHeight;
843
   endmethod
844
 
845
   method Action request( InterpolatorIT inputdata );
846
      reqfifoLoad.enq(inputdata);
847
      if(inputdata matches tagged IPLuma .indata)
848
         reqfifoWork1.enq(IPWLuma {xFracL:indata.mvhor[1:0],yFracL:indata.mvver[1:0],offset:indata.mvhor[3:2],bt:indata.bt});
849
      else if(inputdata matches tagged IPChroma .indata)
850
         reqfifoWork1.enq(IPWChroma {xFracC:indata.mvhor[2:0],yFracC:indata.mvver[2:0],offset:indata.mvhor[4:3]+{indata.hor[0],1'b0},bt:indata.bt});
851
   endmethod
852
 
853
   method Vector#(4,Bit#(8)) first();
854
      return outfifo.first();
855
   endmethod
856
 
857
   method Action deq();
858
      outfifo.deq();
859
   endmethod
860 91 jamey.hick
 
861 90 jamey.hick
 
862
   method Action endOfFrame();
863
      endOfFrameFlag <= True;
864
   endmethod
865
 
866 91 jamey.hick
   method InterpolatorLoadReq mem_request_first();
867
     return memReqQ.first;
868
   endmethod
869 90 jamey.hick
 
870 91 jamey.hick
   method Action mem_request_deq();
871
     memReqQ.deq;
872
   endmethod
873
 
874
   interface mem_client_resp = fifoToPut(memRespQ);
875
 
876 90 jamey.hick
endmodule
877
 
878
 
879
endpackage

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.