Skip to content

Way to start register with "random" value? #562

Open
@RobertBaruch

Description

@RobertBaruch

I'm guessing the answer is just going to be, run SymbiYosys in prove mode. But just in case I'm missing something... I would love to do something like this:

x = Signal(16)
init_x = AnyConst(16)

m.d.comb += Assume(init_x > 0x1000)
with m.If(Initial()):
    m.d.comb += Assume(x == init_x)

m.d.sync += x.eq(x+1)

The goal here is to start BMC with x being any value above 0x1000. As it is now, this is UNSAT of course because the reset value of x, a synchronous signal, is zero, and the assumption that it isn't is a contradiction.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions