Skip to content
This repository has been archived by the owner on Dec 1, 2018. It is now read-only.

Load/Store on part of struct #212

Open
mattfel1 opened this issue Aug 22, 2017 · 1 comment
Open

Load/Store on part of struct #212

mattfel1 opened this issue Aug 22, 2017 · 1 comment

Comments

@mattfel1
Copy link
Member

This is just a thing that would be nice to have:

  @struct case class comp_acdc(index: UInt8,
                               dc: UInt8,
                               ac: UInt8
                              )
  ...
  val ac_dram = DRAM[UInt8](64)
  ...
  val sram = SRAM[comp_acdc](64)
   ...
   ac_dram store sram.ac
@dkoeplin
Copy link
Collaborator

The proposed syntax for this is a bit strange - sram doesn't have an ac field, only its individual elements do. We could potentially create a view of the SRAM using something like sram.map(_.ac).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants