There are a few ways to check your memory allocation:
-- The Memory Gauge in MPLAB under View will give you a grand total, however, you need to be able to compile it completely. Try using the 8722 as the target processor just for the purpose of getting a complete map.
-- The xxx.map file with a complete listing is your best resource. To generate it go to Project->Build Options->Project, then the "MPLINK linker" tab and click "Generate map file." It'll be created in your project folder.
Splitting out your data declarations can help, but it depends on how well you are heeding the chip limitations.
The linker will divide and reorganize your data locations to fit it into the various data blocks available. I wouldn't modify the linker script or use pragmas unless absolutely necessary and you don't have to ask these kinds of questions.
Remember too that the default code you may be using will have it's own data to allocate space for, so you won't have the full 2048 bytes of a PIC18F8520, you'll have more like 1340 bytes, unless you streamline the code. You also need to allow room for the stack and temporary variables.
Also, if your data fits on an 8722, then data block size probably isn't your problem. The data banks are the same size on both chips. The 8722 just has twice as many of them. 0xFF is all you get for a single block, but you have several of those blocks available to you. That size is a limit if you have an array that is greater than 256 of type char or 128 of type int.
Remember the limits before you combine data blocks:
- 256 bytes of global variables declared within any one MPLAB file (typical error message "udata..." or "idata...").
- 120 bytes of variables declared within a single routine (typical error message "stack frame too large").
but if you can compile for an 8722 then this isn't your problem.