11.07.2015 Views

PicC 9.50 dsPIC Manual.pdf

PicC 9.50 dsPIC Manual.pdf

PicC 9.50 dsPIC Manual.pdf

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Chapter 3C Language FeaturesHI-TECH <strong>dsPIC</strong>C supports a number of special features and extensions to the C language whichare designed to ease the task of producing ROM-based applications. This chapter documents thecompiler options and special language features which are specific to these devices.3.1 ANSI Standard Issues3.1.1 Implementation-defined behaviourCertain sections of the ANSI standard have implementation-defined behaviour. This means that theexact behaviour of some C code can vary from compiler to compiler. Throughout this manual aresections describing how the HI-TECH C compiler behaves in such situations.3.2 Processor-related FeaturesHI-TECH C has several features which relate directly to the <strong>dsPIC</strong> architecture and instruction set.These detailed in the following sections.3.2.1 StacksThe stack on <strong>dsPIC</strong> processors is configured by the runtime startup code to start at the end of userdata. The stack limit register SPLIM is set to the maximum address within XDATA. Although theprocessor has some support for frame pointers, the <strong>dsPIC</strong>C compiler does not use it. The compileris able to calculate all accesses to the stack by referencing directly from the stack pointer (W15). By23

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!