Select

chisel3.aop.Select
object Select

Use to select Chisel components in a module, after that module has been constructed.

Attributes

Source
Select.scala
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Select.type

Members list

Type members

Classlikes

trait Predicate extends Serializeable

Used to indicates a when's predicate (or its otherwise predicate)

Used to indicates a when's predicate (or its otherwise predicate)

Attributes

Source
Select.scala
Supertypes
class Object
trait Matchable
class Any
Known subtypes
class When
class WhenNot
case class PredicatedConnect(preds: Seq[Predicate], loc: Data, exp: Data, isBulk: Boolean) extends Serializeable

Used to represent a connection or bulk connection

Used to represent a connection or bulk connection

Additionally contains the sequence of when predicates seen when the connection is declared

Attributes

Source
Select.scala
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
case class Printf(id: Printf, preds: Seq[Predicate], pable: Printable, clock: Clock) extends Serializeable

Used to represent a chisel3.printf

Used to represent a chisel3.printf

Attributes

Source
Select.scala
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Attributes

Source
Select.scala
Supertypes
class Object
trait Matchable
class Any
Known subtypes
trait Predicate
class When
class WhenNot
class Printf
class Stop
Show all
case class Stop(preds: Seq[Predicate], ret: Int, clock: Clock) extends Serializeable

Used to represent a chisel3.stop

Used to represent a chisel3.stop

Attributes

Source
Select.scala
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
case class When(bool: Bool) extends Predicate

Used to represent chisel3.when predicate

Used to represent chisel3.when predicate

Value parameters

bool

the when predicate

Attributes

Source
Select.scala
Supertypes
trait Serializable
trait Product
trait Equals
trait Predicate
class Object
trait Matchable
class Any
Show all
case class WhenNot(bool: Bool) extends Predicate

Used to represent the otherwise predicate of a chisel3.when

Used to represent the otherwise predicate of a chisel3.when

Value parameters

bool

the when predicate corresponding to this otherwise predicate

Attributes

Source
Select.scala
Supertypes
trait Serializable
trait Product
trait Equals
trait Predicate
class Object
trait Matchable
class Any
Show all
object unsafe

Select.unsafe exposes useful, but unsafe APIs.

Select.unsafe exposes useful, but unsafe APIs.

These APIs operate on directly Chisel's internal data structures, which may be mutated as more hardware is generated. They can only offer a point in time view of the current state. The tradeoff is they do not require the modules being selected on to have finished construction.

Attributes

Source
Select.scala
Supertypes
class Object
trait Matchable
class Any
Self type
unsafe.type

Value members

Concrete methods

def attachedTo(module: BaseModule)(signal: Data): Set[Data]

Selects all components who are attached to a given signal, within a module

Selects all components who are attached to a given signal, within a module

Attributes

Source
Select.scala
def collectDeep[T](module: BaseModule)(collector: PartialFunction[BaseModule, T]): Iterable[T]

Collects all components selected by collector within module and all children modules it instantiates directly or indirectly Accepts a collector partial function, rather than a collector function (see getDeep)

Collects all components selected by collector within module and all children modules it instantiates directly or indirectly Accepts a collector partial function, rather than a collector function (see getDeep)

Type parameters

T

Type of the component that will be collected

Value parameters

collector

Collector partial function to pick, given a module, which components to collect

module

Module to collect components, as well as all children module it directly and indirectly instantiates

tag

Required for generics to work, should ignore this

Attributes

Note

This API will not work with the new experimental hierarchy package. Instead, use allInstancesOf or allDefinitionsOf.

Source
Select.scala
def connectionsTo(module: BaseModule)(signal: Data): Seq[PredicatedConnect]

Selects all connections to a signal or its parent signal(s) (if the signal is an element of an aggregate signal) The when predicates surrounding each connection are included in the returned values

Selects all connections to a signal or its parent signal(s) (if the signal is an element of an aggregate signal) The when predicates surrounding each connection are included in the returned values

E.g. if signal = io.foo.bar, connectionsTo will return all connections to io, io.foo, and io.bar

Attributes

Source
Select.scala

Selects the Definitions of all instances/modules directly instantiated within given module

Selects the Definitions of all instances/modules directly instantiated within given module

Attributes

Source
Select.scala
def getDeep[T](module: BaseModule)(collector: BaseModule => Seq[T]): Seq[T]

Collects all components selected by collector within module and all children modules it instantiates directly or indirectly Accepts a collector function, rather than a collector partial function (see collectDeep)

Collects all components selected by collector within module and all children modules it instantiates directly or indirectly Accepts a collector function, rather than a collector partial function (see collectDeep)

Type parameters

T

Type of the component that will be collected

Value parameters

collector

Collector function to pick, given a module, which components to collect

module

Module to collect components, as well as all children module it directly and indirectly instantiates

tag

Required for generics to work, should ignore this

Attributes

Note

This API will not work with the new experimental hierarchy package. Instead, use allInstancesOf or allDefinitionsOf.

Source
Select.scala
def instances(module: BaseModule): Seq[BaseModule]

Selects all modules directly instantiated within given module

Selects all modules directly instantiated within given module

Attributes

Note

This API will not work with the new experimental hierarchy package. Instead, use instancesIn or definitionsIn.

Source
Select.scala

Selects all instances/modules directly instantiated within given definition

Selects all instances/modules directly instantiated within given definition

Attributes

Source
Select.scala
def invalids(module: BaseModule): Seq[Data]

Selects all components who have been set to be invalid, even if they are later connected to

Selects all components who have been set to be invalid, even if they are later connected to

Attributes

Source
Select.scala
def ios(module: BaseModule): Seq[Data]

Selects all Data ios on a given module

Selects all Data ios on a given module

Note that Property ios are not returned.

Attributes

Source
Select.scala
def ios[T <: BaseModule](parent: Hierarchy[T]): Seq[Data]

Selects all ios directly on a given Instance or Definition of a module

Selects all ios directly on a given Instance or Definition of a module

Value parameters

parent

the Definition or Instance to get the IOs of

Attributes

Source
Select.scala
def memPorts(module: BaseModule): Seq[(Data, MemPortDirection, MemBase[_])]

Selects all memory ports, including their direction and memory

Selects all memory ports, including their direction and memory

Attributes

Source
Select.scala
def memPorts(dir: MemPortDirection)(module: BaseModule): Seq[(Data, MemBase[_])]

Selects all memory ports of a given direction, including their memory

Selects all memory ports of a given direction, including their memory

Value parameters

dir

The direction of memory ports to select

Attributes

Source
Select.scala
def mems(module: BaseModule): Seq[Mem[_]]

Selects all Mems directly contained within given module

Selects all Mems directly contained within given module

Attributes

Source
Select.scala
def ops(module: BaseModule): Seq[(String, Data)]

Selects all arithmetic or logical operators directly instantiated within given module

Selects all arithmetic or logical operators directly instantiated within given module

Attributes

Source
Select.scala
def ops(opKind: String)(module: BaseModule): Seq[Data]

Selects a kind of arithmetic or logical operator directly instantiated within given module The kind of operators are contained in chisel3.internal.firrtl.PrimOp

Selects a kind of arithmetic or logical operator directly instantiated within given module The kind of operators are contained in chisel3.internal.firrtl.PrimOp

Value parameters

opKind

the kind of operator, e.g. "mux", "add", or "bits"

Attributes

Source
Select.scala
def printfs(module: BaseModule): Seq[Printf]

Selects all printf statements, and includes the predicates surrounding the printf statement

Selects all printf statements, and includes the predicates surrounding the printf statement

Attributes

Source
Select.scala
def registers(module: BaseModule): Seq[Data]

Selects all registers directly instantiated within given module

Selects all registers directly instantiated within given module

Attributes

Source
Select.scala
def stops(module: BaseModule): Seq[Stop]

Selects all stop statements, and includes the predicates surrounding the stop statement

Selects all stop statements, and includes the predicates surrounding the stop statement

Attributes

Source
Select.scala
def syncReadMems(module: BaseModule): Seq[SyncReadMem[_]]

Selects all SyncReadMems directly contained within given module

Selects all SyncReadMems directly contained within given module

Attributes

Source
Select.scala
def wires(module: BaseModule): Seq[Data]

Selects all wires in a module

Selects all wires in a module

Attributes

Source
Select.scala

Deprecated methods

Return all expanded components, including intermediate aggregate nodes

Return all expanded components, including intermediate aggregate nodes

Value parameters

d

Component to find leafs if aggregate typed. Intermediate fields/indicies ARE included

Attributes

Deprecated
Use DataMirror.collectAllMembers instead
Source
Select.scala
def getLeafs(d: Data): Seq[Data]

Return just leaf components of expanded node

Return just leaf components of expanded node

Value parameters

d

Component to find leafs if aggregate typed. Intermediate fields/indicies are not included

Attributes

Deprecated
Use DataMirror.collectLeafMembers instead
Source
Select.scala

Inherited methods

def allDefinitionsOf[T <: BaseModule : ClassTag](root: Hierarchy[BaseModule]): Seq[Definition[T]]

Selects all Definition's directly and indirectly instantiated within given root hierarchy, of provided type

Selects all Definition's directly and indirectly instantiated within given root hierarchy, of provided type

Value parameters

root

top of the hierarchy to search for definitions of given type

Attributes

Note

IMPORTANT: this function ignores type parameters. E.g. allDefinitionsOf[List[Int]] would return List[String].

Inherited from:
SelectIntf (hidden)
Source
SelectIntf.scala
def allInstancesOf[T <: BaseModule : ClassTag](root: Hierarchy[BaseModule]): Seq[Instance[T]]

Selects all Instances directly and indirectly instantiated within given root hierarchy, of provided type

Selects all Instances directly and indirectly instantiated within given root hierarchy, of provided type

Value parameters

root

top of the hierarchy to search for instances/modules of given type

Attributes

Note

IMPORTANT: this function ignores type parameters. E.g. allInstancesOf[List[Int]] would return List[String].

Inherited from:
SelectIntf (hidden)
Source
SelectIntf.scala
def definitionsOf[T <: BaseModule : ClassTag](parent: Hierarchy[BaseModule]): Seq[Definition[T]]

Selects all Definitions of instances/modules directly instantiated within given module, of provided type

Selects all Definitions of instances/modules directly instantiated within given module, of provided type

Value parameters

parent

hierarchy which instantiates the returned Definitions

Attributes

Note

IMPORTANT: this function ignores type parameters. E.g. definitionsOf[List[Int]] would return List[String].

Inherited from:
SelectIntf (hidden)
Source
SelectIntf.scala
def instancesOf[T <: BaseModule : ClassTag](parent: Hierarchy[BaseModule]): Seq[Instance[T]]

Selects all Instances of instances/modules directly instantiated within given module, of provided type

Selects all Instances of instances/modules directly instantiated within given module, of provided type

Value parameters

parent

hierarchy which instantiates the returned Definitions

Attributes

Note

IMPORTANT: this function ignores type parameters. E.g. instancesOf[List[Int]] would return List[String].

Inherited from:
SelectIntf (hidden)
Source
SelectIntf.scala