mirror of
https://github.com/YosysHQ/yosys
synced 2025-08-11 21:50:54 +00:00
docs: moving code examples
Code now resides in `docs/source/code_examples`. `CHAPTER_Prog` -> `stubnets` `APPNOTE_011_Design_Investigation` -> `selections` and `show` `resources/PRESENTATION_Intro` -> `intro` `resources/PRESENTATION_ExSyn` -> `synth_flow` `resources/PRESENTATION_ExAdv` -> `techmap`, `macc`, and `selections` `resources/PRESENTATION_ExOth` -> `scrambler` and `axis` Note that generated images are not yet configured to build from the new code locations.
This commit is contained in:
parent
3d70867809
commit
dbc38d72cf
119 changed files with 264 additions and 905 deletions
|
@ -1,19 +0,0 @@
|
|||
module memdemo(clk, d, y);
|
||||
|
||||
input clk;
|
||||
input [3:0] d;
|
||||
output reg [3:0] y;
|
||||
|
||||
integer i;
|
||||
reg [1:0] s1, s2;
|
||||
reg [3:0] mem [0:3];
|
||||
|
||||
always @(posedge clk) begin
|
||||
for (i = 0; i < 4; i = i+1)
|
||||
mem[i] <= mem[(i+1) % 4] + mem[(i+2) % 4];
|
||||
{ s2, s1 } = d ? { s1, s2 } ^ d : 4'b0;
|
||||
mem[s1] <= d;
|
||||
y <= mem[s2];
|
||||
end
|
||||
|
||||
endmodule
|
Loading…
Add table
Add a link
Reference in a new issue