on-internet
← Community

How to avoid scientific notation for large numbers? [closed]

Stack Overflow ·

In a case statement, the value of s is increased by the power of 2: input [127:0] s; output [127:0] y; case (s) 128'b1 : y = a1; 128'b2 : y = a2; // ... When it goes to 2^64, the number is so big and it will be represented automatically by scientific notation, for example: 128'b1.84467e19 : y = a64; This will give me a syntax error. Is there a way to avoid this? I don't want to define it as real since I want to synthesise this code.

Comments

Sign in or sign up to comment and upvote.

No comments yet.