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

Deprecate ChiselAnnotation #2819

Open
wants to merge 6 commits into
base: dev/seldridge/deprecate-enumannotations
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Deprecate ChiselAnnotation
Deprecate ChiselAnnotation as custom annotations will not be supported
as part of the migration to the MLIR-based FIRRTL Compiler.

Signed-off-by: Schuyler Eldridge <[email protected]>
seldridge committed Oct 31, 2022
commit 33e84d6d85a8d29a0753490c40b30f1817dad09e
8 changes: 7 additions & 1 deletion core/src/main/scala/chisel3/Annotation.scala
Original file line number Diff line number Diff line change
@@ -4,7 +4,7 @@ package chisel3.experimental

import scala.language.existentials
import chisel3.internal.{Builder, InstanceId, LegacyModule}
import chisel3.{CompileOptions, Data, RawModule}
import chisel3.{deprecatedMFCMessage, CompileOptions, Data, RawModule}
import firrtl.Transform
import firrtl.annotations._
import firrtl.options.Unserializable
@@ -14,6 +14,7 @@ import firrtl.transforms.{DontTouchAnnotation, NoDedupAnnotation}
*
* Defines a conversion to a corresponding FIRRTL Annotation
*/
@deprecated(deprecatedMFCMessage, "Chisel 3.6")
trait ChiselAnnotation {

/** Conversion to FIRRTL Annotation */
@@ -24,6 +25,7 @@ trait ChiselAnnotation {
*
* Defines a conversion to corresponding FIRRTL Annotation(s)
*/
@deprecated(deprecatedMFCMessage, "Chisel 3.6")
trait ChiselMultiAnnotation {
def toFirrtl: Seq[Annotation]
}
@@ -34,14 +36,18 @@ trait ChiselMultiAnnotation {
* Automatic Transform instantiation is *not* supported when the Circuit and Annotations are serialized before invoking
* FIRRTL.
*/
@deprecated(deprecatedMFCMessage, "Chisel 3.6")
trait RunFirrtlTransform extends ChiselAnnotation {
def transformClass: Class[_ <: Transform]
}

@deprecated(deprecatedMFCMessage, "Chisel 3.6")
object annotate {
@deprecated(deprecatedMFCMessage, "Chisel 3.6")
def apply(anno: ChiselAnnotation): Unit = {
Builder.annotations += anno
}
@deprecated(deprecatedMFCMessage, "Chisel 3.6")
def apply(annos: ChiselMultiAnnotation): Unit = {
Builder.newAnnotations += annos
}