Forum Discussion
Altera_Forum
Honored Contributor
14 years agoTightly Coupled Memory
Would someone please explain "tightly coupled memory" and its use within the NiosII/Qsys context? The exercise manual section of the "Designing with the Nios II Processor and Qsys" Customer Tra...
Altera_Forum
Honored Contributor
14 years agoYou can use the gcc __attribute__((section("section_name"))) to mark a function (or data) as belonging to specific section instead of the default (eg .code). You can then use the linker script to assign different sections to different memeory areas. I think the the Altera build tools have some support for this - I don't use them at all.
If you have some code in SDRAM (or similar) then you could consider that code in tightly coupled memory is locked into the instruction cache. Since the access times are similar. Depending on the size of your target application, and the fpga you are using, you might fit all the code into internal memory. For small applications it is usually the inclusion of stdio (for diagnostic printf() to the jtag console) that consumes all the memory.