Skip to content

Commit

Permalink
Add common layers to Chisel (#4326)
Browse files Browse the repository at this point in the history
Add the common layers that all Chisel projects are expected to use.  These
layers will, in later commits, be used for in-tree Chisel generators to
put hardware in.  I.e., it is expected that asserts will not be put under
their corresponding layer.

Signed-off-by: Schuyler Eldridge <[email protected]>
  • Loading branch information
seldridge authored Aug 2, 2024
1 parent d80affa commit 074c075
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
16 changes: 16 additions & 0 deletions src/main/scala/chisel3/layers/Layers.scala
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
package chisel3.layers

import chisel3.layer.{Convention, Layer}

/** The root [[chisel3.layer.Layer]] for all shared verification collateral. */
object Verification extends Layer(Convention.Bind) {

/** The [[chisel3.layer.Layer]] where all assertions will be placed. */
object Assert extends Layer(Convention.Bind)

/** The [[chisel3.layer.Layer]] where all assumptions will be placed. */
object Assume extends Layer(Convention.Bind)

/** The [[chisel3.layer.Layer]] where all covers will be placed. */
object Cover extends Layer(Convention.Bind)
}
4 changes: 4 additions & 0 deletions src/main/scala/chisel3/layers/package.scala
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
package chisel3

/** This package contains common [[layer.Layer]]s used by Chisel generators. */
package object layers

0 comments on commit 074c075

Please sign in to comment.