Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

[SOLVED] Can't synthesize with Synopsys Design Compiler when setting parameters in Verilog

Status
Not open for further replies.

Konze

Newbie level 1
Joined
Jul 14, 2008
Messages
1
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,293
Hello there,

I have the following Verilog modules which I would like to synthesize with the Synopsys Design Compiler:

PARENT
Code:
module PARENT();

    wire in;
    wire out;

    CHILD #(
        .negate(1)
    ) child (
        .in(in),
        .out(out)
    );

endmodule

CHILD
Code:
module CHILD(
    in,
    out
);

    parameter negate = 1;

    input in;
    wire in;

    output out;
    wire out;

    SUBCHILD #(
        .negate(negate)
    ) subchild (
        .in(in),
        .out(out)
    );

endmodule

SUBCHILD
Code:
module SUBCHILD(
    in,
    out
);

    parameter negate = 1;

    input in;
    wire in;

    output out;
    wire out;

    generate
        if(negate == 1) begin
            assign out = ~in;
        end
        else begin
            assign out = in;
        end
    endgenerate

endmodule

When I set negate in PARENT to 1 I'm able synthesize the PARENT module with CHILD and SUBCHILD without any problems with the Synopsys Design Compiler.
However, when I set negate in Parent to 0 I get the following error message during synthesis:
Code:
Processing 'PARENT'
Information: Building the design 'CHILD' instantiated from design 'PARENT' with
	the parameters "negate=0". (HDL-193)
Warning: Cannot find the design 'CHILD' in the library 'WORK'. (LBR-1)
Warning: Unable to resolve reference 'CHILD' in 'PARENT'. (LINK-5)

Why isn't it possible to change the parameter to a value other than the default for synthesis with the Synopsis Design Compiler?

Best regards

konze
 

Are you trying to pass down the parameter from the top-level? Please recheck as to how you are passing the parameter (I wouldn't do it the way you have shown for the .v codes for the modules CHILD and SUBCHILD).

Also be careful about the compile order of the files.
 

Unless I'm mistaken doing this Verilog 2001 sytle instantiation:
Code:
    CHILD #(
        .negate(1)
    ) child (
        .in(in),
        .out(out)
    );
with this type of antiquated module port declaration will cause errors.
Code:
module CHILD(
    in,
    out
);

    parameter negate = 1;

    input in;
    wire in;

    output out;
    wire out;

Haven't you heard of Verilog 2001 it's been around for 16 years.

Either change your module declaration to Verilog 2001 or go back to the antiquated (bad) practice of using defparam.
Code:
defparm child.negate = 1;
    CHILD child (
        .in(in),
        .out(out)
    );
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top