



GENERATING EFFICIENT CODE WITH TMS320 DSPS: STYLE GUIDELINESThis report presents C-coding style guidelines to improve the efficiency of the Texas Instruments (TI(TM))TMS320 C2x/C2xx/C5x/C54x/C3x C-compilers, indicating what to avoid or what to promote when coding a TMS320 in C. For development time savings, apply these guidelines before deciding to re-write a time-critical portion in assembly.
To illustrate some of the guidelines a case study (vector dot product) is presented in Appendix E.
Note: TI code generation tools have been designed to achieve the best optimization possible for the entire application, not for specific kernels. Since the tools look at the entire code, not selected pieces, you may see inefficiencies in a certain kernel of code that reflect efficient code generation in another section of code.
This application note assumes that you are using the latest releases of the TMS320 compilers (C3x/4x version 5.0, C2xx/c5x version 6.65 Beta, C54x version 1.2). Any effect of future compiler releases on the guidelines presented here will be documented in future releases of this document, but such an effect is not foreseen.
View the complete PDF document: spra366.pdf (144 K Bytes) (Requires Acrobat Reader 3.x) Go to the Engineering Design Center to locate information on other TI Semiconductor devices.
![]() ![]() ![]() ![]() (c) Copyright 1998 Texas Instruments Incorporated. All rights reserved. Trademarks, Important Notice! |