Open suarezvictor opened 1 year ago
Good catch, thank you for the report. This is due to the termination state being a special case. It was not properly taken into account in state fastForward (which purpose is to skip such empty states). I pushed a fix in draft, please confirm whether this is ok.
Good. I think I have somewhere another case doing nested loops, if I'm able to spot it I'll report. Do you say that the draft branch is ready to be tested? Were you able to run my example?
Yes, this example and others, all looks good here. Here is how state 6 now jumps directly to 0.
6: begin
// __while__block_16
if (in_clock_counter-_q_t1<0) begin
// __block_17
// __block_19
_d_out_valid = 0;
// __block_20
_d__idx_fsm0 = 6;
end else begin
_d__idx_fsm0 = 0;
end
end
I am opening a different issue (#248) regarding state 8 being unused but left there, this should be fixed too.
Good! I'm impressed about how fast you made the fix. I'm eager to try it with other cores I have
Hi Sylvian/Victor,
I've updated to the latest devel branch, and can confirm that PAWSv2 RV64 builds and runs with no issues! Thanks as always for your hard work.
Rob.
On Sat, 11 Mar 2023 at 21:18, Victor Suarez Rovere @.***> wrote:
Good! I'm impressed about how fast you made the fix. I'm eager to try it with other cores I have
— Reply to this email directly, view it on GitHub https://github.com/sylefeb/Silice/issues/247#issuecomment-1465021547, or unsubscribe https://github.com/notifications/unsubscribe-auth/AN4SYT3CZ7QPM6LO7WIGUNLW3TTY7ANCNFSM6AAAAAAVXRQUOI . You are receiving this because you are subscribed to this thread.Message ID: @.***>
My example works too. Kudos to Sylvian! There's still room for optimization as I posted in the related issue https://github.com/sylefeb/Silice/issues/248. I'm not familiar with the code to send patches but this project is awesome and hopefully I can contribute more
Many thanks for the feedback, tests, and encouragements!! I'll try to address pending issues soon!
When I translate some code to Verilog, there are some "do nothing" states that consumes a clock cycle where that can be avoided. For example, the only thing that state 8 does is set next state to 0, so the code that set the next state to 8 (while in state 6) can just skip state 8 it and set next state to 0. Below is the example code in Silice, and the resulting Verilog code.
Silice code:
Resulting verilog code