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

[STRUCT] random mechanism in struct does not work #12

Open
yyb0205 opened this issue Oct 13, 2023 · 0 comments
Open

[STRUCT] random mechanism in struct does not work #12

yyb0205 opened this issue Oct 13, 2023 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@yyb0205
Copy link

yyb0205 commented Oct 13, 2023

Test Program:

component pss_top {

    struct my_struct {
        int a = 1;
        rand int b;
        rand int c;
        constraint {
            b == 2;
        }
    }

    action root_a {
        my_struct s1;
        int x, y, z;

        constraint {
            s1.c == 3;
        }

        exec post_solve {
            x = s1.a;
            y = s1.b;
            z = s1.c;
        }
        exec body ASM = """x = {{x}}
y = {{y}}
z = {{z}}""";
    }
}

Error Message:

PSSRandom.limitRetry(), Ln47: randomize fail

Golden Result:

x = 1
y = 2
z = 3
@LeeKaiXuan LeeKaiXuan self-assigned this Oct 13, 2023
@LeeKaiXuan LeeKaiXuan added the bug Something isn't working label Oct 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants