1
0
mirror of https://github.com/aolofsson/oh.git synced 2025-01-17 20:02:53 +08:00

Tweaks to methodology

This commit is contained in:
Andreas Olofsson 2016-02-03 23:09:20 -05:00
parent 48e62c244c
commit f7ad4af2b7

View File

@ -24,6 +24,7 @@ CODING METHODOLOGY
* Keep parameter names short * Keep parameter names short
* Use common names: nreset, clk, din, dout, en, rd, wr, addr, etc * Use common names: nreset, clk, din, dout, en, rd, wr, addr, etc
* Make names as short as possible, but not shorter * Make names as short as possible, but not shorter
* Use _ in constants over 4 bits (eg: 8'h1100_1100)
## METHODLOGY ## METHODLOGY
* Use `include files for constants * Use `include files for constants
@ -48,8 +49,7 @@ CODING METHODOLOGY
* Use default statements in all case statements * Use default statements in all case statements
* Don't use proprietary EDA tool pragmas (use parameters) * Don't use proprietary EDA tool pragmas (use parameters)
* Only use synthesizable constructs * Only use synthesizable constructs
* Use $signed() for arithmetic operations on signed types
* Allowed keywords: assign, always, input, output, wire, reg, module, endmodule, if/else, case, casez, ~,|,&,^,==, >>, <<, >, <,?,posedge, negedge, generate, for(...), begin, end, $signed, * Allowed keywords: assign, always, input, output, wire, reg, module, endmodule, if/else, case, casez, ~,|,&,^,==, >>, <<, >, <,?,posedge, negedge, generate, for(...), begin, end, $signed,