1
0

RegField: remove obsolete split method

This is now natively supported by the regmap(...) invocation.
This commit is contained in:
Wesley W. Terpstra 2016-09-22 20:00:49 -07:00
parent fc44151f10
commit c5706afc11

View File

@ -109,13 +109,6 @@ object RegField
bb.d := data
Bool(true)
}))
// Divide a long sequence of RegFields into a maximum sized registers
// Your input RegFields may not cross a beatBytes boundary!
def split(fields: Seq[RegField], base: Int, beatBytes: Int = 4): Seq[RegField.Map] = {
val offsets = fields.map(_.width).scanLeft(0)(_ + _).init
(offsets zip fields).groupBy(_._1 / (beatBytes*8)).toList.map(r => (r._1 + base, r._2.map(_._2)))
}
}
trait HasRegMap