Forum Discussion
Altera_Forum
Honored Contributor
12 years agoHow to read onchip dual port memory .?
Hi, I am doing this for a class project. I have implemented a processor on de4, where I have used onchip memory for data and instruction. I can initialise the memory using .mif files, but...
Altera_Forum
Honored Contributor
12 years agoIt is probably easiest to copy the data to a second memory area when it has all finished.
Qsys will replicate memory blocks in order to support 1 writer and multiple readers - but It probably isn't trivial to do that for TCM. Alternatively use separate memory blocks for the code and data, then the 2nd port of the data memory is free. In that case you don't really want any data accesses to the 'code' memory (link it up anyway without a data cache) so you'll need to ensure the linker script puts all the readonly data with the read-write data. The Altera build of gcc4 also embeds the jump tables for switch statements directly in the code segment - use gcc3.