tilelink2: move general-purpose code out of tilelink2 package
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
package uncore
|
||||
|
||||
import Chisel._
|
||||
import chisel3.internal.sourceinfo.{SourceInfo, SourceLine, UnlocatableSourceInfo}
|
||||
import diplomacy._
|
||||
|
||||
package object tilelink2
|
||||
{
|
||||
@ -17,9 +17,4 @@ package object tilelink2
|
||||
if (s >= w) x else helper(s+s, x | (x << s)(w-1,0))
|
||||
helper(1, x)
|
||||
}
|
||||
|
||||
def sourceLine(sourceInfo: SourceInfo, prefix: String = " (", suffix: String = ")") = sourceInfo match {
|
||||
case SourceLine(filename, line, col) => s"$prefix$filename:$line:$col$suffix"
|
||||
case _ => ""
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user