summaryrefslogtreecommitdiff
path: root/macros/src/main/scala/chisel3/internal
diff options
context:
space:
mode:
authormergify[bot]2022-02-01 20:55:35 +0000
committerGitHub2022-02-01 20:55:35 +0000
commitcb77b061e835044b4f3a2b718fb7ce3971b5d06e (patch)
tree673b14b358f8d5d19843cc1ea2341f233880726f /macros/src/main/scala/chisel3/internal
parentea1ced34b5c9e42412cc0ac3e7431cd3194ccbc3 (diff)
Optional clock param for memory ports (#2333) (#2382)
Warn if clock at memory instantiation differs from clock bound at port creation and port clock is not manually passed Co-authored-by: Jack Koenig <koenig@sifive.com> (cherry picked from commit 465805ec7b2696a985eaa12cf9c6868f11ac2931) Co-authored-by: Aditya Naik <91489422+adkian-sifive@users.noreply.github.com>
Diffstat (limited to 'macros/src/main/scala/chisel3/internal')
-rw-r--r--macros/src/main/scala/chisel3/internal/sourceinfo/SourceInfoTransform.scala4
1 files changed, 4 insertions, 0 deletions
diff --git a/macros/src/main/scala/chisel3/internal/sourceinfo/SourceInfoTransform.scala b/macros/src/main/scala/chisel3/internal/sourceinfo/SourceInfoTransform.scala
index 01e0acd6..3e310774 100644
--- a/macros/src/main/scala/chisel3/internal/sourceinfo/SourceInfoTransform.scala
+++ b/macros/src/main/scala/chisel3/internal/sourceinfo/SourceInfoTransform.scala
@@ -200,6 +200,10 @@ class SourceInfoTransform(val c: Context) extends AutoSourceTransform {
q"$thisObj.$doFuncTerm($x, $y)($implicitSourceInfo, $implicitCompileOptions)"
}
+ def xyzArg(idx: c.Tree, en: c.Tree, clock: c.Tree): c.Tree = {
+ q"$thisObj.$doFuncTerm($idx, $en, $clock)($implicitSourceInfo, $implicitCompileOptions)"
+ }
+
def xEnArg(x: c.Tree, en: c.Tree): c.Tree = {
q"$thisObj.$doFuncTerm($x, $en)($implicitSourceInfo, $implicitCompileOptions)"
}