SW006012 Microchip Technology, SW006012 Datasheet - Page 75

C COMPILER FOR DSPIC30F FAMILY

SW006012

Manufacturer Part Number
SW006012
Description
C COMPILER FOR DSPIC30F FAMILY
Manufacturer
Microchip Technology
Type
MPLAB® C30 Compilerr
Series
PIC24 & DsPICr
Datasheets

Specifications of SW006012

Supported Families
PIC24, DsPIC30F And DsPIC33F
Core Architecture
PIC, DsPIC
Kit Contents
Software And Docs
Mcu Supported Families
PIC24 MCUs And DsPIC DSCs
Tool Type
Compiler
Processor Series
PIC24, dsPIC
Lead Free Status / RoHS Status
Not applicable / Not applicable
For Use With/related Products
dsPIC30F
Lead Free Status / Rohs Status
Lead free / RoHS Compliant
4.7
© 2007 Microchip Technology Inc.
MEMORY MODELS
MPLAB C30 C Compiler Runtime Environment
The compiler supports several memory models. Command-line options are available
for selecting the optimum memory model for your application, based on the specific
dsPIC DSC device part that you are using and the type of memory usage.
TABLE 4-2:
The command-line options apply globally to the modules being compiled. Individual
variables and functions can be declared as near or far to better control the code
generation. For information on setting individual variable or function attributes, see
Section 2.3.1 “Specifying Attributes of Variables” and Section 2.3.2 “Specifying
Attributes of Functions”.
4.7.1
If variables are allocated in the near data section, the compiler is often able to generate
better (more compact) code than if the variables are not allocated in the near data
section. If all variables for an application can fit within the 8 KB of near data, then the
compiler can be requested to place them there by using the default -msmall-data
command line option when compiling each module. If the amount of data consumed
by scalar types (no arrays or structures) totals less than 8 KB, the default
-msmall-scalar may be used. This requests that the compiler arrange to have just
the scalars for an application allocated in the near data section.
If neither of these global options is suitable, then the following alternatives are
available.
-msmall-data
-msmall-scalar
-mlarge-data
-msmall-code
-mlarge-code
-mconst-in-data Constants located in data
-mconst-in-code Constants located in program
Option
Near and Far Data
MEMORY MODEL COMMAND LINE OPTIONS
Up to 8 KB of data memory.
This is the default.
Up to 8 KB of data memory.
This is the default.
Greater than 8 KB of data
memory.
Up to 32 Kwords of program
memory. This is the default.
Greater than 32 Kwords of
program memory.
memory.
memory. This is the default.
Memory Definition
Permits use of PIC18 like instructions
for accessing data memory.
Permits use of PIC18 like instructions
for accessing scalars in data memory.
Uses indirection for data references.
Function pointers will not go through a
jump table. Function calls use RCALL
instruction.
Function pointers might go through a
jump table. Function calls use CALL
instruction.
Values copied from program memory
by startup code.
Values are accessed via Program
Space Visibility (PSV) data window.
Description
DS51284F-page 69

Related parts for SW006012