OpenCores
URL https://opencores.org/ocsvn/socgen/socgen/trunk

Subversion Repositories socgen

[/] [socgen/] [trunk/] [common/] [opencores.org/] [cde/] [ip/] [mult/] [sim/] [testbenches/] [verilog/] [top] - Blame information for rev 131

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

Line No. Rev Author Line
1 131 jt_eaton
 
2
 
3
 
4
reg [31:0]  a_in_R;
5
reg [31:0]  b_in_R;
6
reg [63:0]  mul_prod_exp_R;
7
reg   alu_op_mul_R;
8
reg   ex_freeze_R;
9
reg   mask_R;
10
 
11
 
12
 
13
assign a_in       = a_in_R;
14
assign b_in       = b_in_R;
15
assign alu_op_mul = alu_op_mul_R;
16
assign ex_freeze  = ex_freeze_R;
17
 
18
 
19
 
20
 
21
io_probe_in
22
 #(.MESG         ("multiply error"),
23
   .WIDTH        (32)
24
  )
25
rdata_tpb
26
  (
27
  .clk            (  clk        ),
28
  .expected_value (  mul_prod_exp_R[31:0]  ),
29
  .mask           (  {32{mask_R}} ),
30
  .signal         (  mul_prod_r[31:0]      )
31
  );
32
 
33
`ifndef SYNTHESYS
34
 
35
  task u_cmp;
36
    input  [31:0] a_in;
37
    input  [31:0] b_in;
38
    input  [31:0] exp;
39
 
40
     begin
41
      test.a_in_R <= a_in;
42
      test.b_in_R <= b_in;
43
      test.mul_prod_exp_R <= exp;
44
      test.alu_op_mul_R  <= 1'b1;
45
      test.ex_freeze_R    <= 1'b1;
46
      test.cg.next(1);
47
      while(mul_stall)        test.cg.next(1);
48
      test.mask_R  <= 1'b1;
49
      $display("%t %m   cycle %x %x %x",$realtime,a_in,b_in,exp );
50
      test.alu_op_mul_R  <= 1'b0;
51
      test.ex_freeze_R   <= 1'b0;
52
      test.cg.next(1);
53
      test.mask_R  <= 1'b0;
54
 
55
   end
56
  endtask
57
 
58
`endif
59
 
60
 
61
 
62
assign STOP = 1'b0;
63
assign BAD = 1'b0;

powered by: WebSVN 2.1.0

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