Nios/memsize
From ASMBits
nios/memaddrPrevious
Nextnios/memtiling
Consider a memory array of with A address lines and D data lines. What is the capacity of this memory (in bits)?
Write a function that returns the memory capacity (in bits). The capacity will not overflow a 32-bit unsigned integer.
unsigned int memsize(unsigned int A, unsigned int D);
Expected solution length: Around 4 lines.
Sample Input
memsize(12, 8)
Sample Output
r2=32768
nios/memaddrPrevious
Nextnios/memtiling