May be it will usefull for you. I have such kind of a problem with NIOS v1. As I found this is trouble of SOPC Builder and Quartus. It allocates memory in wery strange mode. I want to have 24Kbyte of onchip ROM (ROM - M4Ks only) on Stratix 1s10 device. Such amount succesfully fits into device, but Quartus didn't fit it. My system in SOPC Builder was generated in verilog. I found next thing - in verilog file that describes memory (boot_rom.v for example) sopc builder writes
the_altsyncram.numwords_a = 8192 while correct ansver is
the_altsyncram.numwords_a = 6144.
The word width is 32 bit.
I correct it manually and all works well.
So you can try to find where memory is described in your project and check value and correct it manually if needed.
Also Quartus didn't fit for example 25Kbytes or 27Kbytes evein if there are free M4Ks in needed amount. It will fit it if only 32Kbytes are availible. I don't know why:(
It's wery bad bug cause in Stratix devices you can not use all M4Ks memory as single block.
All this (upper words) is correct for memory usage as a single block.