module fpunit(p,co,clk,a,b);
input [255:0] p;
input co;
input clk;
inout [255:0] a,b;
wire c1,c2,c3,c4;
wire [255:0] t1,t2,u,s1,s2,s3,s4,s5,s6;
wire [256:0] v1,w1,v2,w2
parallelreg a1(s1,256'b0,clk,1'b1);
parallelreg a2(s2,256'b0,clk,1'b1);
for(i=255;i>=0;i=i-1)
begin
muxb a3(u,s1,s2,b[i]);
flp a4(v1,u);
notb a5(s3,s2);
muxb a6(s4,s1,s3,co);
bitadd a7(v2,s1,s4,c0);
notg a8(c3,co);
notb a9(s5,p);
muxb a10(s6,p,s5,c3);
bitadd a12(w1,v1,s6,1'b1);
bitadd a11(w2,v2,s6,c3);
org a12(c1,w1[256],v1[256]);
org a13(c4,w2[256],v2[256]);
muxg a14(c2,v2[256],c4,c3);
muxb a15(t1,w1[255:0],v1[255:0],c1);
muxb a16(t2,w2[255:0],v2[255:0],c2);
muxb a17(a,t1,t2,b[i]);
muxb a18(b,t2,t1,b[i]);
parallelreg a19(s1,a,clk,1'b0);
parallelreg a20(s2,b,clk,1'b0);
end
endmodule
thanks. the other errors are cleared. but this error still exists "expecting 'endmodule', found 'for' "what to do??You forgot a semi-colon at the end of this line:
r.b.
module fpunit(p,co,clk,a,b);
input [255:0] p;
input co;
input clk;
inout [255:0] a,b;
integer i;
wire c1,c2,c3,c4;
wire [255:0] t1,t2,u,s1,s2,s3,s4,s5,s6;
wire [256:0] v1,w1,v2,w2;
parallelreg a1(s1,256'b0,clk,1'b1);
parallelreg a2(s2,256'b0,clk,1'b1);
for(i=255;i>=0;i=i-1)
begin
muxb a3(u,s1,s2,b[i]);
flp a4(v1,u);
notb a5(s3,s2);
muxb a6(s4,s1,s3,co);
bitadd a7(v2,s1,s4,co);
notg a8(c3,co);
notb a9(s5,p);
muxb a10(s6,p,s5,c3);
bitadd a12(w1,v1,s6,1'b1);
bitadd a11(w2,v2,s6,c3);
org a12(c1,w1[256],v1[256]);
org a13(c4,w2[256],v2[256]);
muxg a14(c2,v2[256],c4,c3);
muxb a15(t1,w1[255:0],v1[255:0],c1);
muxb a16(t2,w2[255:0],v2[255:0],c2);
muxb a17(a,t1,t2,b[i]);
muxb a18(b,t2,t1,b[i]);
parallelreg a19(s1,a,clk,1'b0);
parallelreg a20(s2,b,clk,1'b0);
end
endmodule
module fpunit(p,co,clk,a,b);
input [255:0] p;
input co;
input clk;
inout [255:0] a,b;
integer i;
wire c1,c2,c3,c4;
wire [255:0] t1,t2,u,s1,s2,s3,s4,s5,s6;
wire [256:0] v1,w1,v2,w2;
parallelreg a1(s1,256'b0,clk,1'b1);
parallelreg a2(s2,256'b0,clk,1'b1);
initial begin
for(i=255;i>=0;i=i-1)
begin
muxb a3(u,s1,s2,b[i]);
flp a4(v1,u);
notb a5(s3,s2);
muxb a6(s4,s1,s3,co);
bitadd a7(v2,s1,s4,co);
notg a8(c3,co);
notb a9(s5,p);
muxb a10(s6,p,s5,c3);
bitadd a12(w1,v1,s6,1'b1);
bitadd a11(w2,v2,s6,c3);
org a12(c1,w1[256],v1[256]);
org a13(c4,w2[256],v2[256]);
muxg a14(c2,v2[256],c4,c3);
muxb a15(t1,w1[255:0],v1[255:0],c1);
muxb a16(t2,w2[255:0],v2[255:0],c2);
muxb a17(a,t1,t2,b[i]);
muxb a18(b,t2,t1,b[i]);
parallelreg a19(s1,a,clk,1'b0);
parallelreg a20(s2,b,clk,1'b0);
end
end
endmodule
module fpunit(p,co,clk,a,b);
input [255:0] p;
input co;
input clk;
inout [255:0] a,b;
integer i;
wire c1,c2,c3,c4;
wire [255:0] t1,t2,u,s1,s2,s3,s4,s5,s6;
wire [256:0] v1,w1,v2,w2;
parallelreg a1(s1,256'b0,clk,1'b1);
parallelreg a2(s2,256'b0,clk,1'b1);
generate
for(i=255;i>=0;i=i-1)
begin
muxb a3(u,s1,s2,b[i]);
flp a4(v1,u);
notb a5(s3,s2);
muxb a6(s4,s1,s3,co);
bitadd a7(v2,s1,s4,co);
notg a8(c3,co);
notb a9(s5,p);
muxb a10(s6,p,s5,c3);
bitadd a12(w1,v1,s6,1'b1);
bitadd a13(w2,v2,s6,c3);
org a14(c1,w1[256],v1[256]);
org a15(c4,w2[256],v2[256]);
muxg a16(c2,v2[256],c4,c3);
muxb a17(t1,w1[255:0],v1[255:0],c1);
muxb a18(t2,w2[255:0],v2[255:0],c2);
muxb a19(a,t1,t2,b[i]);
muxb a20(b,t2,t1,b[i]);
parallelreg a21(s1,a,clk,1'b0);
parallelreg a22(s2,b,clk,1'b0);
end
endgenerate
endmodule
genvar i;
module fpunit(p,co,clk,a,b);
input [255:0] p;
input co;
input clk;
inout [255:0] a,b;
wire c1,c2,c3,c4;
wire [255:0] t1,t2,u,s1,s2,s3,s4,s5,s6;
wire [256:0] v1,w1,v2,w2;
parallelreg a1(s1,256'b0,clk,1'b1);
parallelreg a2(s2,256'b0,clk,1'b1);
flp a4(v1,u);
notb a5(s3,s2);
muxb a6(s4,s1,s3,co);
bitadd a7(v2,s1,s4,co);
notg a8(c3,co);
notb a9(s5,p);
muxb a10(s6,p,s5,c3);
bitadd a12(w1,v1,s6,1'b1);
bitadd a13(w2,v2,s6,c3);
org a14(c1,w1[256],v1[256]);
org a15(c4,w2[256],v2[256]);
muxg a16(c2,v2[256],c4,c3);
muxb a17(t1,w1[255:0],v1[255:0],c1);
muxb a18(t2,w2[255:0],v2[255:0],c2);
parallelreg a21(s1,a,clk,1'b0);
parallelreg a22(s2,b,clk,1'b0);
genvar i;
generate
for(i=255;i>=0;i=i-1)
begin: ABC
muxb a3(u,s1,s2,b[i]);
muxb a19(a,t1,t2,b[i]);
muxb a20(b,t2,t1,b[i]);
end
endgenerate
endmodule
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?