Forum Discussion

MamaSaru's avatar
MamaSaru
Icon for Occasional Contributor rankOccasional Contributor
3 years ago
Solved

eq output of lpm_counter does not see higher q bits in simulation.

I found the error in simulation library source file 220model.v.

#3866

assign eq = tmp_eq;

should be:

assign eq = (final_count < 16) ? tmp_eq : 0;

to confirm higher q bits are all zero.

My simulation environment is as below:

Questa - Intel FPGA Edition 2022.4 (Quartus Prime Pro 23.1)

Windows 10

  • Richard,
    No thanks, it was just feedback to Questa.
    Thank you for your effort.
    Regards,

6 Replies

  • FvM's avatar
    FvM
    Icon for Super Contributor rankSuper Contributor

    Hi,
    I suspect there are more faults. Do you understand the idea behind tmp_eq?

    B.T.W., there's apparently a longer tradition of incorrect lpm_counter models. Modelsim_AE was never using eq in 220model.v, simply zeroing it.

    assign eq = {16{1'b0}};

    No idea if the limitations are specified somewhere?

  • Do you observe any errors or unexpected functional behaviors during the simulation?


    If so, please help to share your design by archiving the project (Project > Archive Project) so that I can investigate it further.

    Please note that it's important to archive your project before upgrading your design in case of any unexpected issues.


    Best Regards,

    Richard Tan


  • MamaSaru's avatar
    MamaSaru
    Icon for Occasional Contributor rankOccasional Contributor

    Hi Richard,
    Thank you for the reply.
    I did not find any other problem for now.

    I already revise 220model.v file and compile it with other RTL files in my project.
    My design is the backend part of Arria 10 PCI Express avalon ST IP.
    I can't send whole my project but instead I will send one module that instantiate lpm_counter.
    You can simulete this module but you may not need to do.
    Please read lpm_counter module definition in 220model.v, you can see eq output never get all zeros.

    Regards,

  • Thank you for your constructive feedback.

    I have feedback this to the engineering team and we will decide whether the modified code can be implemented in the future or not.


    With that, do you need further help in regards to this case?


    Best Regards,

    Richard Tan


  • MamaSaru's avatar
    MamaSaru
    Icon for Occasional Contributor rankOccasional Contributor

    Richard,
    No thanks, it was just feedback to Questa.
    Thank you for your effort.
    Regards,

  • You're welcome. We're happy to help.

    With that, I will transition this thread to community support.

    If you have any further questions or concerns, please don't hesitate to reach out.

    Thank you and have a great day!


    Best Regards,

    Richard Tan