Ralf Hildebrandt Posted February 17, 2023 Report Share Posted February 17, 2023 (edited) When defining a <memory map> one can define an <address block> with some range and a <usage> of e.g. <register> or <memory>. If a true memory (e.g. an SRAM) needs to be modeled, the <usage> is obviously <memory>. Now such a memory may store some data with some meaning: e.g. the memory may store an Ethernet frame and the first 6 bytes are the <dst> (the destination = the MAC address of the destination (receiver of the frame)). With IP-XACT such a meaning of the memory content could be modeled as a <register> inside the <address block>. The context-sensitive help of the <Kactus2> tool says: "Memory ... Registers and register files within will be considered virtual." My question is: Is it correct to model words / bytes inside some real memory as <register> / <field> using IP-XACT or should definitions as <register> / <field> limited to flip-flops (real registers)? Are there any better way to describe the meaning of memory words using IP-XACT? Many thanks in advance Ralf Edited February 17, 2023 by Ralf Hildebrandt a more precise title Quote Link to comment Share on other sites More sharing options...
kock Posted February 17, 2023 Report Share Posted February 17, 2023 Hello Ralf, In IEEE Std. 1685-2014 the concept of virtual registers was introduced: Quote virtual register: A collection of fields, overlaid on top of a memory, usually in an array. The semantics and layout of virtual registers come from an agreement between the software and hardware. Virtual registers are modeled in IP-XACT by creating register instances within addressBlocks with usage memory. The child elements of a virtual register are restricted to a subset of the overall register element. NOTE—See 6.11.2. virtual register file: A grouping of virtual registers. A virtual register file is modeled using the registerFile element in an addressBlock element with usage of memory. The children of virtual register files shall be virtual. NOTE—See 6.11.6. So if you set the usage attribute to memory, then you indicate that your registers are virtual. Does that address your question? Best regards, Erwin Quote Link to comment Share on other sites More sharing options...
Ralf Hildebrandt Posted February 17, 2023 Author Report Share Posted February 17, 2023 2 minutes ago, kock said: So if you set the usage attribute to memory, then you indicate that your registers are virtual. Does that address your question? Ok, understood and many thanks for this. But the main question was: Is this the correct way of modeling a meaning of data words inside some memory (by using virtual registers)? I am asking this, because I am a beginner to IP-XACT and am not sure if all tools will understand this, if I do model memories in that way. (I am a hardware designer, who needs to model an IP-XACT decription of some peripheral and want to make sure, that tools and users that will use this description will understand it.) Kind regards Ralf Quote Link to comment Share on other sites More sharing options...
kock Posted February 17, 2023 Report Share Posted February 17, 2023 Yes, this is the correct way. Not sure which tools you have in mind but if you are referring to tools that generate software header files, then these will typically generate a C/C++ structure from your IP-XACT descriptions. You have to make sure that such a structure makes sense in C/C++ so you want to have your registers byte/word aligned. Best regards, Erwin Ralf Hildebrandt 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.