FF's are inffered instead of distributed RAM

Mar 20, 2007 2 Replies

i have a byte array of size 10 and i need to shift values in the array to left by 5 positions in 5 clocks. here is the code im using.


reg [7:0] data[0:9];



// data shifting process reg ps_shift_start; reg ps_done;



reg [1:0] ps_state; parameter ps_s0 = 2'b00; parameter ps_s1 = 2'b01;



reg [12:0] ps_shift; integer ps_index;



always @ (posedge clk) begin if(reset == 1) begin ps_done


ps_index + 1) begin

Put the code that infers the RAM into its own process, and make sure you follow the template.

-a

Your code accesses multiple locations in the data array on the same clock cycle. RAMs cannot do that (dual port rams can access two addresses simultaneously).

Redesign your code/design to avoid accessing more than one location in the array.

Andy

ps_index + 1) begin

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required