-
Notifications
You must be signed in to change notification settings - Fork 154
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
First active edge at least one clock period from start #2007
Conversation
06c0bfb
to
d5d10f7
Compare
4f7abd9
to
9a3a13f
Compare
For reviewers: with the change to the DDR test the Clash simulation and the HDL simulation now actually correspond. Before this change, it used to be that in the Clash simulation, outputverifier would trigger an assertion; where this assertion wasn't triggered in HDL simulation. Now neither the Clash simulation nor the HDL simulation trigger an assertion. |
@christiaanb I unchecked the copyright notice TODO, I can see non-updated notices in at least |
All the files that have a copyright notice were originally published in 2021, and the copyright header mentions 2021; so it's all good. I rechecked the copyright notice TODO |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why was there a difference in the resetGen
prims behaviour between synchronous and asynchrous domains?
And why is that not longer needed?
|
||
makeSystemVerilog :: IORef ClashOpts -> [FilePath] -> InputT GHCi () | ||
makeSystemVerilog = makeHDL' (Clash.Backend.initBackend :: Int -> HdlSyn -> Bool -> PreserveCase -> Maybe (Maybe Int) -> AggressiveXOptBB -> RenderEnums -> SystemVerilogState) | ||
makeSystemVerilog = makeHDL' (Clash.Backend.initBackend :: Int -> HdlSyn -> Bool -> PreserveCase -> Maybe (Maybe Int) -> AggressiveXOptBB -> RenderEnums -> DomainMap -> SystemVerilogState) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
makeSystemVerilog = makeHDL' (Clash.Backend.initBackend :: Int -> HdlSyn -> Bool -> PreserveCase -> Maybe (Maybe Int) -> AggressiveXOptBB -> RenderEnums -> DomainMap -> SystemVerilogState) | |
makeSystemVerilog = makeHDL' (Clash.Backend.initBackend @SystemVerilogState) |
Clash.hs
Outdated
|
||
genVerilog | ||
:: String | ||
-> IO () | ||
genVerilog = doHDL (initBackend WORD_SIZE_IN_BITS HDLSYN True PreserveCase Nothing (AggressiveXOptBB False) (RenderEnums True) :: VerilogState) | ||
genVerilog = doHDL (initBackend WORD_SIZE_IN_BITS HDLSYN True PreserveCase Nothing (AggressiveXOptBB False) (RenderEnums True) :: DomainMap -> VerilogState) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
genVerilog = doHDL (initBackend WORD_SIZE_IN_BITS HDLSYN True PreserveCase Nothing (AggressiveXOptBB False) (RenderEnums True) :: DomainMap -> VerilogState) | |
genVerilog = doHDL (initBackend @VerilogState WORD_SIZE_IN_BITS HDLSYN True PreserveCase Nothing (AggressiveXOptBB False) (RenderEnums True)) |
clash-ghc/src-bin-861/Clash/Main.hs
Outdated
|
||
makeSystemVerilog :: Ghc () -> IORef ClashOpts -> [(String, Maybe Phase)] -> Ghc () | ||
makeSystemVerilog = makeHDL' (Clash.Backend.initBackend :: Int -> HdlSyn -> Bool -> PreserveCase -> Maybe (Maybe Int) -> AggressiveXOptBB -> RenderEnums -> SystemVerilogState) | ||
makeSystemVerilog = makeHDL' (Clash.Backend.initBackend :: Int -> HdlSyn -> Bool -> PreserveCase -> Maybe (Maybe Int) -> AggressiveXOptBB -> RenderEnums -> DomainMap -> SystemVerilogState) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
makeSystemVerilog = makeHDL' (Clash.Backend.initBackend :: Int -> HdlSyn -> Bool -> PreserveCase -> Maybe (Maybe Int) -> AggressiveXOptBB -> RenderEnums -> DomainMap -> SystemVerilogState) | |
makeSystemVerilog = makeHDL' (Clash.Backend.initBackend @SystemVerilogState) |
The difference has always bogus, we used to have:
then in #428 we changed to:
so that the de-assertion always happened after 3000ps (which is the time all the clocks start (before this PR)). Then in #527 those definitions got merged:
By which time we should've already dropped the difference. Because both |
1c9a7ff
to
f7ddad7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
This isn't done automatically, sigh..
82cc493
to
a5c1ea5
Compare
Fixes #2001