4.3.3.4 How Do I Stop the Compiler From Using Certain Memory Locations?

Concatenating an address attribute with the noload attribute can be used to block out sections of memory. For more on variable attributes and options, see the following sections in this user’s guide:

Variable Attributes

Options Specific to 32-bit MCU Devices

Also, you can use the option -mreserve. See the “MPLAB® XC32 Assembler, Linker and Utilities User’s Guide for PIC32A MCU” (DS-50003839) for details on linker scripts.