HDL code Linting first review test

HDL code Linting first review test

with what i need to start ? this is main question, let me put my opinion about it, means about linting. It is a process to find the potential error, like logical errors, syntax error. And if we know the errors, we try to correct it by our own to produce the quality RTL. And again I want to add into this> quality RTL does not mean desired functionality, in my view it is logically error free now not more than that. Who knows ! code desired functionality which is designed by you is really required[quality] functionality of module.

Anyway logical errors like [1 div by zero [2 width mismatch [3 constant conditions etc. can be find by such tools process, i mean linting process.

lets start with it, one more who need this tool ? beginners, freshers, and experiences designers peoples, i mean experiences people who has beginners, freshers as team members. i hope you got this. sorry to say [beginners, freshers]

It not means that experiences design people dont not need it, as these are experiences people so they have lot to do! there code size is large, not always possible to look forward to each and every things, then this tool process give a hand to these peoples, come on BRO !, i will take care of it, don't worry. this is what i think, may be others have there own way to think.

let start with it, on a start of tool[sypglass], you get the flash screen which is show at top of this article and then the screen comes as below.

No alt text provided for this image

I am referring the content from link https://mslab.hanyang.ac.kr/IDEC_VERILOG_day2.pdf for test the process. One more[it is spontaneous, it comes into mind i just add it ] i need to add as it is error finding tool so for that i need to add errors into the code to test it, which is very hard for me, because number of years i spends to write code which is error free. so i prefer to link document for the same which give some relief.

No alt text provided for this image

For better start i first go with error free code, which is just full adder, 2 half adder + or gate

The tool flow is very simple, go to file make new project, give name, location, after that a screen change, shows list of folders, by clicking the add design files, you are able to add source files that's it. it is similar to all other tools [ new project, add files] ok. After adding files. Click on design setup, it ask for synthesis netlist, etc. i just check mark that[ which will generate the schematic as well] and read the design and elaborate. after the process you will get the summary in the bottom of window which is show in above snap, all msgs are in green color means there is no severity error in reading and elaborating the source in first stage.After clicking the MS[and gate button] you will get the schematic window just like below.

No alt text provided for this image

>> here i took 4-5 ex with first code is bism1[badimplicitSM1] , obviously it has error

No alt text provided for this image

from the code it is clear also, when it comes to lint tool it gives error as Identifies the Un-synthesizable modelling style for sequential logic, where clock and reset cannot be inferred - Unsynthesizable - Severity level: Error

No alt text provided for this image

same error with zoom, with expand list of msg. To check the design there are numbers of goal rules. What i tell upto now it is for linting in basic way, but some tools like spyGlass also provide the linting for cdc, dft, power etc which is listed in bottom snap, which is very good to know. now it is not just logical error finding tool it is also a checker for following lists of items. [note there are lots more items in the list, cant fit in please ref the other doc for the same]

No alt text provided for this image

linting people called these are goal rules/linting rules/ methodology for the same.

No alt text provided for this image

>>Ex2 ,bism2 code has error

No alt text provided for this image

Identifies the implicit sequential logic in a non-synthesizable modeling style where states are not updated on the same clock phase - The synthesis tool can get confused about which edge to use for updating the register - RTL and gate-level simulation results may not match.- Severity level: Error

No alt text provided for this image

>> EX3 bism4 code, it has error as well as seen from code itself.

No alt text provided for this image

- Identifies the non-synthesizable implicit sequential logic where event control expressions have multiple edges - The synthesis tool can get confused about which edge to use for updating the register - RTL and gate-level simulation results may not match - Severity level: Error

No alt text provided for this image

>>Ex4 code bothedge.v also has error, i mean i put it for you.- Identifies the variable whose both the edges are used in an event control list - Synthesis tools do not allow both edges of the same variable in an event control list - Severity level: Error

No alt text provided for this image

>> Ex5 code mixedsense.v also seen error , and it detected as above. - Mixed conditions in sensitivity list may not be synthesizable - It flags mixed edge and non-edge conditions in the sensitivity list of an always construct. - Severity level: Error

Do comment for any more examples or any such tool explanations. i want to declare that its my own opinion[whatever seen above] about the lint process and the tool. Please do ref other resources for more detail as it is just a slice of lint process. that's it, Okay!

Akhilesh Goyal

Senior Software Engineer @Radisys Corporation|Ex-Lekha Wireless Solution|RTL Design|FPGA Design|Verilog|Synthesis

3 年

Thanks a lot sir for sharing this article it is quite helpful and eagerly waiting for the next part ...

回复

要查看或添加评论,请登录

Manish Meshram的更多文章

  • For design services Please contact us

    For design services Please contact us

    Please contact us for Designing or consulting for frontend vlsi and Electronics design.

  • Current limiting circuit

    Current limiting circuit

    It is current limiting circuit with opamp and mosfet, can be used with ac and dc supply .circuit diagram pcb layout has…

  • Pre-Post rtl simulation a case study

    Pre-Post rtl simulation a case study

    The point is that i am not good skill writer/editor, but still some one may find this article useful, please excuse if…

  • SpyGlass CDC review test 1

    SpyGlass CDC review test 1

    To have review for spyglass cdc, first we need code, here i attached 2 codes 1] cdc_test2.v is top 2] clk_rst_unit1.

  • LTP fsm HDL to RTL ,gate netlist,45ns

    LTP fsm HDL to RTL ,gate netlist,45ns

    This article is about the comparison of rtl from different tools for earlier design level to pulse converter. Please…

  • AXI stream m<>s interface RTL design

    AXI stream m<>s interface RTL design

    ?The AXI4 Stream I/F has a high grade of flexibility, it has some signals that are required and many that are optional.…

    6 条评论
  • NEORV32 RISC-V RTL compiled / sim

    NEORV32 RISC-V RTL compiled / sim

    First take a look of the simulated waveform, then i will tell, what i found interesting in it, obviously it not direct…

  • AXI GPIO RTL design

    AXI GPIO RTL design

    you can find the verilog code with test-bench at my GitHub space. https://github.

  • Calculator for fifo depth, code generation

    Calculator for fifo depth, code generation

    Code is build in matlab for calculations and code generation [is not completed yet], will soon completed with…

社区洞察

其他会员也浏览了