Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

enum logic[2:0] not generating enum in fst file #1426

Closed
veripoolbot opened this issue May 1, 2019 · 2 comments
Closed

enum logic[2:0] not generating enum in fst file #1426

veripoolbot opened this issue May 1, 2019 · 2 comments
Assignees
Labels
area: usability Issue involves general usability resolution: fixed Closed; fixed

Comments

@veripoolbot
Copy link
Contributor


Author Name: Danilo Ramos
Original Redmine Issue: 1426 from https://www.veripool.org

Original Assignee: Wilson Snyder (@wsnyder)


Hi Wilson.

When declaring an enum as:
typedef enum logic[1:0] { ZERO=0, ONE, TWO, THREE } enumed_t; // Not working

GTKwave does not recognize/loads an enumed_t variable as an enum.

However, when replacing logic[2:0] by int, it works.

typedef enum int { ZERO=0, ONE, TWO, THREE } enumed_t; // OK!

Platform: msys2 (Mingw-w64 64 bit), windows 10
Verilator: Verilator 4.012 2019-03-23 rev UNKNOWN_REV
GTKwave: v3.3.100

Example:

module example;
     typedef enum logic[1:0] { ZERO=0, ONE, TWO, THREE } enumed_t;
     enumed_t v_enumed;
     always_ff @(posedge aclk)
     begin: input_ctrl_p
         if (!aresetn) begin
             v_enumed           <= ZERO;
         end else begin
             case(v_enumed)
                 ZERO: begin
                     v_enumed    <= ONE;
                 end 
                 ONE: begin
                     v_enumed    <= TWO;
                 end
                 TWO: begin
                     v_enumed    <= THREE;
                 end
                 THREE: begin
                     THREE    <= ZERO;
                 end
             endcase
         end
     end
endmodule

@veripoolbot
Copy link
Contributor Author


Original Redmine Comment
Author Name: Wilson Snyder (@wsnyder)
Original Date: 2019-05-01T23:18:57Z


Thanks for the report, fixed in git towards 4.014.

@veripoolbot
Copy link
Contributor Author


Original Redmine Comment
Author Name: Wilson Snyder (@wsnyder)
Original Date: 2019-05-09T01:38:14Z


In 4.014.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: usability Issue involves general usability resolution: fixed Closed; fixed
Projects
None yet
Development

No branches or pull requests

2 participants