1006e1884SZihao Yupackage system 2006e1884SZihao Yu 3006e1884SZihao Yuimport noop.{NOOP, NOOPConfig} 4006e1884SZihao Yuimport bus.axi4.{AXI4, AXI4Lite} 58f36f779SZihao Yuimport bus.simplebus._ 6006e1884SZihao Yu 7006e1884SZihao Yuimport chisel3._ 8006e1884SZihao Yu 9006e1884SZihao Yuclass NOOPSoC(implicit val p: NOOPConfig) extends Module { 10006e1884SZihao Yu val io = IO(new Bundle{ 11cdd59e9fSZihao Yu val mem = new AXI4 12*ad255e6cSZihao Yu val mmio = (if (p.FPGAPlatform) { new AXI4Lite } else { new SimpleBusUC }) 13006e1884SZihao Yu }) 14006e1884SZihao Yu 15006e1884SZihao Yu val noop = Module(new NOOP) 16cdd59e9fSZihao Yu val cohMg = Module(new CoherenceInterconnect) 17cdd59e9fSZihao Yu cohMg.io.in(0) <> noop.io.imem 18cdd59e9fSZihao Yu cohMg.io.in(1) <> noop.io.dmem 19cdd59e9fSZihao Yu io.mem <> cohMg.io.out.toAXI4() 20006e1884SZihao Yu 21*ad255e6cSZihao Yu if (p.FPGAPlatform) io.mmio <> noop.io.mmio.toAXI4Lite() 22006e1884SZihao Yu else io.mmio <> noop.io.mmio 23006e1884SZihao Yu} 24