If I have allocated correct memory size to accommodate my program size and I can check my program size in XPS by clicking "Get Program Size." However, if I have not allocated correct memory size (i.e., if the allocated memory is not enough for my program), I cannot use the tool to find out the program size. Is there any way to find the program size so that I can allocate the appropriate amount of memory?
Currently, this cannot be done. However a way to work around it would be to modify your linker script. If you are putting your program in OPB_BRAM, modify your linker script as follows, then compile your program:
opb_bram_if_cntlr_1 : ORIGIN = 0x00000050, LENGTH = 0x00007FAF
opb_bram_if_cntlr_1 : ORIGIN = 0x00000050, LENGTH = 0x10007FAF