35 Document Revision History

Revision A (August 2018)

  • Initial revision of the document.

Revision B (April 2020)

Revision C (May 2023)

  • Updated the stated size and information relating to the double type, which is now 64 bits wide.
  • Corrected examples of using the __pack specifier.
  • Updated information on the compiler option controls available in the MPLAB X IDE.
  • Provided dedicated sections on all compiler options in addition to a summary table.
  • Added new section on the compiler's code coverage feature.
  • Added a new section on the stack and the stack guidance feature.
  • Added -f[no-]common option description, which controls the placement of global variables defined without an initializer.
  • Added -Warray-bounds option description, which can warn on out-of-bounds array indices and pointer offsets.
  • Added -Wmultistatement-macros option description, which warns on unsafe macro expansion.
  • Added -Wsizeof-pointer-div option description, which warns on suspicious divisions involving pointers.
  • Indicated that the -foptimize-register-move option no longer has any effect.
  • Added information on the iar argument to the -mext option.
  • Added information on the used variable attribute.
  • Added information on the externally_visible function attribute and variable attribute.
  • Expanded information on the naked function attribute.
  • Updated and expanded the sections relating to variables in program memory, reflecting changes in the compiler.
  • Expanded information on fixed-point types and arithmetic.
  • Expanded information on interrupt context switching.
  • Updated information on the runtime startup code, including information on the data initialization template.
  • Added information on smart IO library features.
  • Expanded information on optimizations performed.
  • Added section on preprocessor arithmetic.
  • Added information on the default_function_attributes, default_variable_attributes, message, GCC optimize, pack, and weak pragmas.
  • Removed reference to the __PIC__ and __pic__ position independent code macros, which are no longer supported.
  • Indicated in the default linker script information that selecting an alternate DFP will affect the script used.
  • Added information on __builtin_mfc0 and __builtin_mtc0 built-in functions.
  • Corrected information relating to the return value for the __builtin_bcc0, __builtin_bsc0, and __builtin_bcsc0 built-in functions.

Revision D (September 2023)

  • Merged the MIPS-related library content in the 32-Bit Language Tools Libraries document into this guide.
  • Updated references to the C++ standard to reflect that the ISO/IEC 14882:2014 C++ program language is now supported.
  • Renamed references to the MPLAB XC16 compiler to be MPLAB XC-DSC to reflect the change in product name.
  • Defined the compiler's implementation-defined behavior for the C++14 standard in a new section.
  • Clarified information in the runtime startup section.
  • Updated Common C Interface chapter to reflect recent changes in MPLAB XC compilers.
  • Removed reference to MPLAB XC8 in the Embedded Compiler Compatibility Mode chapter, as this compiler no longer supports this mode.

Revision E (June 2024)

  • Added new How To explaining how the stack usage for each function in a module can be displayed
  • Updated compiler options used with the Linktime Optimizations setting in XC32 Global options tab of the MPLAB X IDE Project Properties
  • Added option present in the xc32-ar (Library Archive) tab of the MPLAB X IDE Project Properties
  • Added a diagram indicating the internal compiler applications
  • Updated information relating to runtime startup files
  • Added the following option descriptions to the guide:
    -mmalloc-variant-mips16e--version
    -mlibc-variant-std-Wformat-smart-io
    -dA-fdiagnostics-show-caret-fframe-base-loclist
    -mno-info-linker-ffat-lto-objects-finline-small-functions
    -flto-partition-fpeel-loops-ftracer
    -fuse-linker-plugin-T
  • Corrected typo in the name of what should have been the --dint-compression option and specified this with the -Wl, prefix, since it is a linker option
  • Updated the Dynamic Memory Allocation section to include the new allocation schemes
  • Updated several items in the Common C Interface section to improve readability and include the XC-DSC compiler
  • Expanded the description of the __builtin_disable_interrupts and __builtin_enable_interrupts Built-in Functions