ARM Compiler for µVision Getting Started Guide: ARM Compiler v5.06 for µVision Getting Started Guide

Keil, An ARM® Company ARM Compiler v5.06 for µVision Getting Started Guide

Non-Confidential PDF file icon PDF version ARM DUI0592F
ARM® Compiler v5.06 for µVision® Getting Started Guide Version 5
Home

ARM® Compiler v5.06 for µVision® Getting Started Guide

Version 5

Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved.

Proprietary notices

Table of Contents

Preface
About this book
Using this book
Glossary
Typographic conventions
Feedback
Other information
1 Overview of ARM® Compiler
1.1 About ARM® Compiler
1.1.1 Summary of ARM® Compiler tools
1.1.2 Host platform support for ARM® Compiler
1.1.3 Standards compliance in ARM® Compiler
1.1.4 Compliance with the ABI for the ARM Architecture (Base Standard)
1.1.5 Supporting software
1.1.6 Important limitations of ARM® Compiler
1.2 ARM architectures supported by the toolchain
1.3 ARM® Compiler support on 64-bit host platforms
1.4 About the toolchain documentation
1.5 Licensed features of ARM® Compiler
1.6 Toolchain environment variables
1.6.1 Environment variables used by the toolchain
1.6.2 TMP environment variable for temporary file directories
1.7 Portability of source files between hosts
1.8 About specifying Cygwin paths in compilation tools on Windows
1.9 Rogue Wave documentation
1.10 Further reading
2 Getting Started with the Compilation Tools
2.1 About the ARM compilation tools
2.2 About specifying command-line options
2.2.1 Methods of specifying command-line options
2.2.2 Special characters on the command line
2.2.3 Rules for specifying command-line options
2.2.4 Order of options on the command line
2.2.5 Precedence of command-line options when using them in a text file
2.2.6 Autocompletion of command-line options
2.3 The ARM compiler command
2.4 The ARM linker command
2.5 The ARM assembler command
2.6 Execute-only memory
2.7 Building applications for execute-only memory
2.8 The fromelf image converter command

List of Figures

1-1 Rogue Wave HTML documentation
2-1 A typical tool usage flow diagram

List of Tables

1-1 Environment variables used by the toolchain

Release Information

Document History
Issue | Date | Confidentiality | Change
A | June 2011 | Non-Confidential | Release for ARM Compiler v4.1 for µVision
B | July 2012 | Non-Confidential | Release for ARM Compiler v5.02 for µVision
C | 30 May 2014 | Non-Confidential | Release for ARM Compiler v5.04 for µVision
D | 12 December 2014 | Non-Confidential | Release for ARM Compiler v5.05 for µVision
E | 15 August 2015 | Non-Confidential | Release for ARM Compiler v5.06 for µVision
F | 17 June 2016 | Non-Confidential | Release for ARM Compiler v5.06 update 3 for µVision

Non-Confidential Proprietary Notice

This document is protected by copyright and other related rights and the practice or implementation of the information contained in this document may be protected by one or more patents or pending patent applications. No part of this document may be reproduced in any form by any means without the express prior written permission of ARM. No license, express or implied, by estoppel or otherwise to any intellectual property rights is granted by this document unless specifically stated.
Your access to the information in this document is conditional upon your acceptance that you will not use or permit others to use the information for the purposes of determining whether implementations infringe any third party patents.
THIS DOCUMENT IS PROVIDED “AS IS”. ARM PROVIDES NO REPRESENTATIONS AND NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTABILITY, SATISFACTORY QUALITY, NON-INFRINGEMENT OR FITNESS FOR A PARTICULAR PURPOSE WITH RESPECT TO THE DOCUMENT. For the avoidance of doubt, ARM makes no representation with respect to, and has undertaken no analysis to identify or understand the scope and content of, third party patents, copyrights, trade secrets, or other rights.
This document may include technical inaccuracies or typographical errors.
TO THE EXTENT NOT PROHIBITED BY LAW, IN NO EVENT WILL ARM BE LIABLE FOR ANY DAMAGES, INCLUDING WITHOUT LIMITATION ANY DIRECT, INDIRECT, SPECIAL, INCIDENTAL, PUNITIVE, OR CONSEQUENTIAL DAMAGES, HOWEVER CAUSED AND REGARDLESS OF THE THEORY OF LIABILITY, ARISING OUT OF ANY USE OF THIS DOCUMENT, EVEN IF ARM HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
This document consists solely of commercial items. You shall be responsible for ensuring that any use, duplication or disclosure of this document complies fully with any relevant export laws and regulations to assure that this document or any portion thereof is not exported, directly or indirectly, in violation of such export laws. Use of the word “partner” in reference to ARM’s customers is not intended to create or refer to any partnership relationship with any other company. ARM may make changes to this document at any time and without notice.
If any of the provisions contained in these terms conflict with any of the provisions of any signed written agreement covering this document with ARM, then the signed written agreement prevails over and supersedes the conflicting provisions of these terms. This document may be translated into other languages for convenience, and you agree that if there is any conflict between the English version of this document and any translation, the terms of the English version of the Agreement shall prevail.
Words and logos marked with ® or ™ are registered trademarks or trademarks of ARM Limited or its affiliates in the EU and/or elsewhere. All rights reserved. Other brands and names mentioned in this document may be the trademarks of their respective owners. Please follow ARM’s trademark usage guidelines at http://www.arm.com/about/trademark-usage-guidelines.php
Copyright © 2011, 2012, 2014-2016, ARM Limited or its affiliates. All rights reserved.
ARM Limited. Company 02557590 registered in England.
110 Fulbourn Road, Cambridge, England CB1 9NJ.
LES-PRE-20349

Confidentiality Status

This document is Non-Confidential. The right to use, copy and disclose this document may be subject to license restrictions in accordance with the terms of the agreement entered into by ARM and the party that ARM delivered this document to.
Unrestricted Access is an ARM internal classification.

Product Status

The information in this document is Final, that is for a developed product.

Web Address

http://www.arm.com
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home

Copyright © Keil, An ARM Company. All rights reserved.


ARM Compiler for µVision Getting Started Guide: Execute-only memory

Execute-only memory

Home > Getting Started with the Compilation Tools > Execute-only memory

2.6 Execute-only memory

Execute-only memory (XOM) allows only instruction fetches. Read and write accesses are not allowed.

Execute-only memory allows you to protect your intellectual property by preventing executable code being read by users. For example, you can place firmware in execute-only memory and load user code and drivers separately. Placing the firmware in execute-only memory prevents users from trivially reading the code.

Note

The ARM architecture does not directly support execute-only memory. Execute-only memory is supported at the memory device level.
Related tasks
2.7 Building applications for execute-only memory
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools > Execute-only memory


ARM Compiler for µVision Getting Started Guide: Building applications for execute-only memory

Building applications for execute-only memory

Home > Getting Started with the Compilation Tools > Building applications for execute-only memory

2.7 Building applications for execute-only memory

Placing code in execute-only memory prevents users from trivially reading that code.

Note

Execute-only memory is not supported for C++.
To build an application with code in execute-only memory:

Procedure

  1. Compile your C code or assemble your ARM assembly code using the --execute_only option
    armcc -c --execute_only test.c -o test.o
    The --execute_only option prevents the compiler from generating any data accesses to the code sections.
    To keep code and data in separate sections, the compiler disables the placement of literal pools inline with code.
    Compiled code sections have the EXECONLY attribute:
    AREA ||.text||, CODE, EXECONLY, ALIGN=1
    The assembler faults any attempts to define data in an EXECONLY code section.
  2. Specify the memory map to the linker using either of the following:
    • The +XO selector in a scatter file.
    • The armlink --xo-base option on the command-line.
    armlink --xo-base=0x8000 test.o -o test.axf
    The XO execution region is placed in a separate load region from the RO, RW, and ZI execution regions.

    Note

    If you do not specify --xo-base, then by default:
    • The XO execution region is placed immediately before the RO execution region, at address 0x8000.
    • All execution regions are in the same load region.
Related concepts
2.6 Execute-only memory
Related information
--execute_only compiler option
--execute_only assembler option
--xo_base=address linker option
AREA
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools > Building applications for execute-only memory


ARM Compiler for µVision Getting Started Guide: Preface

Preface

Home > Preface

Preface

This preface introduces the ARM® Compiler v5.06 for µVision® Getting Started Guide.

It contains the following:

  • About this book.

Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Preface


ARM Compiler for µVision Getting Started Guide: About this book

About this book

Home > Preface > About this book

About this book

ARM® Compiler for µVision® Getting Started Guide provides an overview of the µVision tools, standards supported, and compliance with the ARM Application Binary Interface (ABI).

Using this book

This book is organized into the following chapters:
Chapter 1 Overview of ARM® Compiler

Provides general information about ARM® Compiler.

Chapter 2 Getting Started with the Compilation Tools

Describes how to create an application using the tools provided by ARM® Compiler.

Glossary

The ARM Glossary is a list of terms used in ARM documentation, together with definitions for those terms. The ARM Glossary does not contain terms that are industry standard unless the ARM meaning differs from the generally accepted meaning.
See the ARM Glossary for more information.

Typographic conventions

italic
Introduces special terminology, denotes cross-references, and citations.
bold
Highlights interface elements, such as menu names. Denotes signal names. Also used for terms in descriptive lists, where appropriate.
monospace
Denotes text that you can enter at the keyboard, such as commands, file and program names, and source code.
monospace
Denotes a permitted abbreviation for a command or option. You can enter the underlined text instead of the full command or option name.
monospace italic
Denotes arguments to monospace text where the argument is to be replaced by a specific value.
monospace bold
Denotes language keywords when used outside example code.
<and>
Encloses replaceable terms for assembler syntax where they appear in code or code fragments. For example:
MRC p15, 0, <Rd>, <CRn>, <CRm>, <Opcode_2>
SMALL CAPITALS
Used in body text for a few terms that have specific technical meanings, that are defined in the ARM glossary. For example, IMPLEMENTATION DEFINED, IMPLEMENTATION SPECIFIC, UNKNOWN, and UNPREDICTABLE.

Feedback

Feedback on this product
If you have any comments or suggestions about this product, contact your supplier and give:
  • The product name.
  • The product revision or version.
  • An explanation with as much information as you can provide. Include symptoms and diagnostic procedures if appropriate.
Feedback on content
If you have comments on content then send an e-mail to errata@arm.com. Give:
  • The title ARM® Compiler v5.06 for µVision® Getting Started Guide.
  • The number ARM DUI0592F.
  • If applicable, the page number(s) to which your comments refer.
  • A concise explanation of your comments.
ARM also welcomes general suggestions for additions and improvements.

Note

ARM tests the PDF only in Adobe Acrobat and Acrobat Reader, and cannot guarantee the quality of the represented document when used with any other PDF reader.

Other information

  • ARM Information Center.
  • ARM Technical Support Knowledge Articles.
  • Support and Maintenance.
  • ARM Glossary.
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Preface > About this book


ARM Compiler for µVision Getting Started Guide: Overview of ARM Compiler

Overview of ARM Compiler

Home > Overview of ARM Compiler

Chapter 1 Overview of ARM® Compiler

Provides general information about ARM® Compiler.

It contains the following sections:

  • 1.1 About ARM® Compiler.

  • 1.2 ARM architectures supported by the toolchain.

  • 1.3 ARM® Compiler support on 64-bit host platforms.

  • 1.4 About the toolchain documentation.

  • 1.5 Licensed features of ARM® Compiler.

  • 1.6 Toolchain environment variables.

  • 1.7 Portability of source files between hosts.

  • 1.8 About specifying Cygwin paths in compilation tools on Windows.

  • 1.9 Rogue Wave documentation.

  • 1.10 Further reading.

Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler


ARM Compiler for µVision Getting Started Guide: About ARM Compiler

About ARM Compiler

Home > Overview of ARM Compiler > About ARM Compiler

1.1 About ARM® Compiler

ARM® Compiler enables you to build applications for the ARM family of processors from C, C++, or ARM assembly language source.

Note

Be aware of the following:
  • Generated code might be different between two ARM Compiler releases.
  • For a feature release, there might be significant code generation differences.

Note

The command-line option descriptions and related information in the individual ARM Compiler tools documents describe all the features that ARM Compiler supports. Any features not documented are not supported and are used at your own risk. You are responsible for making sure that any generated code using unsupported features is operating correctly.
This section contains the following subsections:

  • 1.1.1 Summary of ARM® Compiler tools.

  • 1.1.2 Host platform support for ARM® Compiler.

  • 1.1.3 Standards compliance in ARM® Compiler.

  • 1.1.4 Compliance with the ABI for the ARM Architecture (Base Standard).

  • 1.1.5 Supporting software.

  • 1.1.6 Important limitations of ARM® Compiler.

Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > About ARM Compiler


ARM Compiler for µVision Getting Started Guide: Host platform support for ARM Compiler

Host platform support for ARM Compiler

Home > Overview of ARM Compiler > About ARM Compiler > Host platform support for ARM Compiler

1.1.2 Host platform support for ARM® Compiler

ARM® Compiler supports various Windows platforms.

Except where stated, the ARM Compiler supports both 32-bit and 64-bit versions of the following OS platforms:
  • Windows 8.1, 64-bit only.
  • Windows 7 Enterprise SP1.
  • Windows 7 Professional SP1.
  • Windows Server 2012, 64-bit only.

Note

You can use ARM Compiler with Cygwin on the supported Windows platforms. However, Cygwin path translation enabled by CYGPATH is only supported on 32-bit Windows platforms.
Related concepts
1.8 About specifying Cygwin paths in compilation tools on Windows
1.1 About ARM® Compiler
Related information
Cygwin versions supported
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > About ARM Compiler > Host platform support for ARM Compiler


ARM Compiler for µVision Getting Started Guide: About the toolchain documentation

About the toolchain documentation

Home > Overview of ARM Compiler > About the toolchain documentation

1.4 About the toolchain documentation

ARM® Compiler contains a suite of documents that describe how to use the tools and provides information on migration from, and compatibility with, earlier toolchain versions.

The toolchain documentation comprises:
Getting Started Guide (ARM DUI 0592) - this document
This document gives an overview of the toolchain and features.
armcc User Guide (ARM DUI 0375)
This document describes how to use the various features of the compiler, armcc. It also provides a detailed description of each armcc command-line option.
See armcc User Guide.
ARM C and C++ Libraries and Floating-Point Support User Guide (ARM DUI 0378)
This document describes the features of the ARM C and C++ libraries and the ARM C microlib, and how to use them. It also describes the floating-point support of the libraries.
See ARM® C and C++ Libraries and Floating-Point Support User Guide.
armasm User Guide (ARM DUI 0379)
This document describes how to use the various features of the assembler, armasm. It also provides a detailed description of each armasm command-line option.
See armasm User Guide.
armlink User Guide (ARM DUI 0377)
This document describes how to use the various features of the linker, armlink. It also provides a detailed description of each armlink command-line option.
See armlink User Guide.
armar User Guide (ARM DUI 0590)
This document describes how to use the various features of the librarian, armar. It also provides a detailed description of each armar command-line option.
See armar User Guide.
fromelf User Guide (ARM DUI 0459)
This document describes how to use the various features of the ELF image converter, fromelf. It also provides a detailed description of each fromelf command-line option.
See fromelf User Guide.
Errors and Warning Reference Guide (ARM DUI 0591)
This document describes the errors and warnings that might be generated by each of the build tools in ARM Compiler.
See Errors and Warnings Reference Guide.
Migration and Compatibility Guide (ARM DUI 0593)
This document describes the differences you must be aware of in ARM Compiler, when migrating your software from earlier toolchain versions, such as ARM RVCT v4.0.
See Migration and Compatibility Guide.
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > About the toolchain documentation


ARM Compiler for µVision Getting Started Guide: Licensed features of ARM Compiler

Licensed features of ARM Compiler

Home > Overview of ARM Compiler > Licensed features of ARM Compiler

1.5 Licensed features of ARM® Compiler

ARM® Compiler requires a license.

If you purchased the toolchain with another ARM product, see the Getting Started document of that product for details of the licenses that are included.
Licensing of the ARM development tools is controlled by the FlexNet license management system.
To request a license, go to ARM Web Licensing and follow the online instructions.
Related information
ARM DS-5 License Management Guide
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > Licensed features of ARM Compiler


ARM Compiler for µVision Getting Started Guide: Standards compliance in ARM Compiler

Standards compliance in ARM Compiler

Home > Overview of ARM Compiler > About ARM Compiler > Standards compliance in ARM Compiler

1.1.3 Standards compliance in ARM® Compiler

ARM® Compiler conforms to the ISO C, ISO C++, ELF, DWARF 2, and DWARF 3 standards.

The level of compliance for each standard is:
ar
armar produces, and armlink consumes, UNIX-style object code archives. armar can list and extract most ar-format object code archives, and armlink can use an ar-format archive created by another archive utility providing it contains a symbol table member.
DWARF 3
DWARF 3 debug tables (DWARF Debugging Standard Version 3) are supported by the toolchain.
DWARF 2
DWARF 2 debug tables are supported by the toolchain, and by ELF DWARF 2 compatible debuggers from ARM.
ISO C
The compiler accepts ISO C 1990 and 1999 source as input.
ISO C++
The compiler accepts a subset of ISO C++11 source as input.
ELF
The toolchain produces relocatable and executable files in ELF format. The fromelf utility can translate ELF files into other formats.

Note

The DWARF 2 and DWARF 3 standards are ambiguous in some areas such as debug frame data. This means that there is no guarantee that third-party debuggers can consume the DWARF produced by ARM code generation tools or that an ARM debugger can consume the DWARF produced by third-party tools.
Related concepts
1.1.4 Compliance with the ABI for the ARM Architecture (Base Standard)
Related information
Source language modes of the compiler
The DWARF Debugging Standard
International Organization for Standardization
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > About ARM Compiler > Standards compliance in ARM Compiler


ARM Compiler for µVision Getting Started Guide: Compliance with the ABI for the ARM Architecture (Base Standard)

Compliance with the ABI for the ARM Architecture (Base Standard)

Non-Confidential PDF file icon PDF version ARM DUI0592F
ARM® Compiler v5.06 for µVision® Getting Started Guide Version 5
Home > Overview of ARM Compiler > About ARM Compiler > Compliance with the ABI for the ARM Architecture (Base Standard)

1.1.4 Compliance with the ABI for the ARM Architecture (Base Standard)

The ABI for the ARM Architecture (Base Standard) is a collection of standards. Some of these standards are open. Some are specific to the ARM architecture.

The Application Binary Interface (ABI) for the ARM Architecture (Base Standard) (BSABI) regulates the inter-operation of binary code and development tools in ARM architecture-based execution environments.
By conforming to this standard, objects produced by the toolchain can work together with object libraries from different producers.
The BSABI consists of a family of specifications including:
AADWARF
DWARF for the ARM Architecture. This ABI uses the DWARF 3 standard to govern the exchange of debugging data between object producers and debuggers.
AAELF
ELF for the ARM Architecture. Builds on the generic ELF standard to govern the exchange of linkable and executable files between producers and consumers.
AAPCS
Procedure Call Standard for the ARM Architecture. Governs the exchange of control and data between functions at runtime. There is a variant of the AAPCS for each of the major execution environment types supported by the toolchain.
BPABI
Base Platform ABI for the ARM Architecture. Governs the format and content of executable and shared object files generated by static linkers. Supports platform-specific executable files using post linking. Provides a base standard for deriving a platform ABI.
CLIBABI
C Library ABI for the ARM Architecture. Defines an ABI to the C library.
CPPABI
C++ ABI for the ARM Architecture. Builds on the generic C++ ABI (originally developed for IA-64) to govern interworking between independent C++ compilers.
DBGOVL
Support for Debugging Overlaid Programs. Defines an extension to the ABI for the ARM Architecture to support debugging overlaid programs.
EHABI
Exception Handling ABI for the ARM Architecture. Defines both the language-independent and C++-specific aspects of how exceptions are thrown and handled.
RTABI
Run-time ABI for the ARM Architecture. Governs what independently produced objects can assume of their execution environments by way of floating-point and compiler helper function support.
If you are upgrading from a previous toolchain release, ensure that you are using the most recent versions of the ARM specifications.
Related information
Application Binary Interface for the ARM Architecture Introduction and downloads
Addenda to, and Errata in, the ABI for the ARM Architecture
Differences between v1 and v2 of the ABI for the ARM Architecture
ABI for the ARM Architecture Advisory Note: SP must be 8-byte aligned on entry to AAPCS-conforming functions
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > About ARM Compiler > Compliance with the ABI for the ARM Architecture (Base Standard)


ARM Compiler for µVision Getting Started Guide: Toolchain environment variables

Toolchain environment variables

Home > Overview of ARM Compiler > Toolchain environment variables

1.6 Toolchain environment variables

Except for ARMLMD_LICENSE_FILE, ARM® Compiler does not require any other environment variables to be set. However, there are situations where you might want to set environment variables.

For example, if you want to specify additional command-line options for armcc, but you do not want to modify your build scripts, then you can specify the options using ARMCC5_CCOPT.
This section contains the following subsections:

  • 1.6.1 Environment variables used by the toolchain.

  • 1.6.2 TMP environment variable for temporary file directories.

Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > Toolchain environment variables


ARM Compiler for µVision Getting Started Guide: ARM architectures supported by the toolchain

ARM architectures supported by the toolchain

Home > Overview of ARM Compiler > ARM architectures supported by the toolchain

1.2 ARM architectures supported by the toolchain

ARM® Compiler includes support for all ARM architectures from ARMv4 to ARMv7 inclusive.

All architectures before ARMv4 are obsolete and are no longer supported.
You can specify a target processor or architecture to take advantage of extra features specific to the selected processor or architecture. To do this, use the following command-line options:
  • --cpu=name.
  • --fpu=name.
You can specify the startup instruction set, ARM or Thumb, with the --arm or --thumb command-line options.
You can force an ARM-only instruction set with the --arm_only option.
The compilation tools provide support for mixing ARM and Thumb code. This is known as interworking and enables branching between ARM code and Thumb code.
Related information
Selecting the target CPU at compile time
--arm compiler option
--arm_only compiler option
--cpu=name compiler option
--fpu=name compiler option
--thumb compiler option
--arm assembler option
--arm_only assembler option
--cpu=name assembler option
--fpu=name assembler option
--thumb assembler option
--arm_only linker option
--cpu=name linker option
--fpu=name linker option
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > ARM architectures supported by the toolchain


ARM Compiler for µVision Getting Started Guide: ARM Compiler support on 64-bit host platforms

ARM Compiler support on 64-bit host platforms

Home > Overview of ARM Compiler > ARM Compiler support on 64-bit host platforms

1.3 ARM® Compiler support on 64-bit host platforms

You can use ARM® Compiler on 32-bit and 64-bit platforms.

Although ARM Compiler is supported on certain 64-bit platforms, the tools are 32-bit applications. This limits the virtual address space and file size available to the tools. If these limits are exceeded, armlink reports an error message to indicate that there is not enough memory. This might cause confusion because sufficient physical memory is available but the application cannot access it.
Related reference
1.6 Toolchain environment variables
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > ARM Compiler support on 64-bit host platforms


ARM Compiler for µVision Getting Started Guide: Special characters on the command line

Special characters on the command line

Home > Getting Started with the Compilation Tools > About specifying command-line options > Special characters on the command line

2.2.2 Special characters on the command line

You can use special characters to select multiple symbolic names in some compilation tools command arguments.

If you are using a special character on Unix platforms, you must enclose the options in quotes to prevent the shell expanding the selection.
  • The wildcard character * matches any name.
  • The wildcard character ? matches any single character.
For example, enter '*,~*.*' instead of *,~*.*.

Note

The armar command-line options must be preceded by a -. This is different from some earlier versions of armar, and from some third-party archivers.

Examples

The following examples show the use of these characters:
  • armar --create mylib.a *.o, creates the archive mylib.a containing all object files in the current directory.
  • armar -t mylib.a s*.o, lists all object files beginning with s in the mylib.a.
  • armlink hello.o mylib.a(?.o) -o tst.axf, links hello.o with all object files in mylib.a that have a single letter filename.
  • fromelf --info=sizes,totals mylib.a(s*.o), lists the code and data sizes for all object files beginning with s in mylib.a.
Related information
Assembler command-line syntax
Compiler command-line syntax
Linker command-line syntax
armar command-line syntax
fromelf command-line syntax
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools > About specifying command-line options > Special characters on the command line


ARM Compiler for µVision Getting Started Guide: Rules for specifying command-line options

Rules for specifying command-line options

Home > Getting Started with the Compilation Tools > About specifying command-line options > Rules for specifying command-line options

2.2.3 Rules for specifying command-line options

There are certain rules you must follow when using command-line options. These rules depend on the type of option.

The following rules apply:
Single-letter options
All single-letter options, including single-letter options with arguments, are preceded by a single dash -. You can use a space between the option and the argument, or the argument can immediately follow the option. For example:
-J directory
-Jdirectory
Keyword options
All keyword options, including keyword options with arguments, are preceded by a double dash --. An = or space character is required between the option and the argument. For example:
--depend=file.d
--depend file.d
Compilation tools options that contain non-leading - or _ can use either of these characters. For example, --force_new_nothrow is the same as --force-new-nothrow.
To compile files with names starting with a dash, use the POSIX option -- to specify that all subsequent arguments are treated as filenames, not as command switches. For example, to compile a file named -ifile_1, use:
armcc -c -- -ifile_1
In some Unix shells, you might have to include quotes when using arguments to some command-line options, for example:
--keep='s.o(vect)'
Related information
Assembler command-line syntax
Compiler command-line syntax
Linker command-line syntax
fromelf command-line syntax
armar command-line syntax
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools > About specifying command-line options > Rules for specifying command-line options


ARM Compiler for µVision Getting Started Guide: Order of options on the command line

Order of options on the command line

Home > Getting Started with the Compilation Tools > About specifying command-line options > Order of options on the command line

2.2.4 Order of options on the command line

In general, command-line options can appear in any order. However, the effects of some options depend on how they are combined with other related options.

Where options override other options on the same command line, the options that appear closer to the end of the command line take precedence. Where an option does not follow this rule, this is noted in the description for that option.
Use the --show_cmdline option to see how the command line is processed. The commands are shown normalized.
Related information
--show_cmdline assembler option
--show_cmdline compiler option
--show_cmdline linker option
--show_cmdline fromelf option
--show_cmdline armar option
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools > About specifying command-line options > Order of options on the command line


ARM Compiler for µVision Getting Started Guide: Autocompletion of command-line options

Autocompletion of command-line options

Home > Getting Started with the Compilation Tools > About specifying command-line options > Autocompletion of command-line options

2.2.6 Autocompletion of command-line options

You can specify a shortened version of a command-line option with the autocompletion feature.

To use the autocompletion feature, insert a full stop (.) after the characters to be autocompleted.
The following rules apply to the autocompletion feature:
  • You must separate arguments from the full stop by an equals (=) character or a space character.
  • You cannot use autocompletion for the arguments to an option.
  • You must include sufficient characters to make the autocompleted option unique.
For example, use --diag_su.=223 to specify --diag_suppress=223 on the command line.
Specifying --diag.=223 is not valid, because --diag. does not identify a single unique command-line option.
Related information
Compiler command-line options listed by group
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools > About specifying command-line options > Autocompletion of command-line options


ARM Compiler for µVision Getting Started Guide: Precedence of command-line options when using them in a text file

Precedence of command-line options when using them in a text file

Non-Confidential PDF file icon PDF version ARM DUI0592F
ARM® Compiler v5.06 for µVision® Getting Started Guide Version 5
Home > Getting Started with the Compilation Tools > About specifying command-line options > Precedence of command-line options when using them in a text file

2.2.5 Precedence of command-line options when using them in a text file

The compilation tools read command-line options from a specified text file and combine them with any additional options you have specified for the tool. Some options might take precedence over other options.

The precedence given to a command-line option depends on:
  • The command-line option.
  • The position of the --via option on the command line.
To see a command line equivalent to the result of combining the options, specify the --show_cmdline option. For example, if armcc.txt contains the options --debug --cpu=ARM926EJ-S:
  • armcc -c --show_cmdline --cpu=ARM7TDMI --via=armcc.txt hello.c [armcc --show_cmdline --debug -c --cpu=ARM926EJ-S hello.c]
    In this case, --cpu=ARM7TDMI is not used because --cpu=ARM926EJ-S is the last instance of --cpu on the command-line.
  • armcc --via=armcc.via -c --show_cmdline --cpu=ARM7TDMI hello.c [armcc --show_cmdline --debug -c hello.c]
    In this case, --cpu=ARM926EJ-S is not used because --cpu=ARM7TDMI is the last instance of --cpu on the command line. In addition, --cpu=ARM7TDMI is not shown in the output, because this is the default option for --cpu.
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools > About specifying command-line options > Precedence of command-line options when using them in a text file


ARM Compiler for µVision Getting Started Guide: Portability of source files between hosts

Portability of source files between hosts

Home > Overview of ARM Compiler > Portability of source files between hosts

1.7 Portability of source files between hosts

You can make sure your source files are portable between hosts.

To do this:
  • Ensure that filenames do not contain spaces. If you have to use path names or filenames containing spaces, enclose the path and filename in double (") or single (') quotes.
  • Make embedded path names relative rather than absolute.
  • Use forward slashes (/) in embedded path names, not backslashes (\).
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > Portability of source files between hosts


ARM Compiler for µVision Getting Started Guide: Methods of specifying command-line options

Methods of specifying command-line options

Home > Getting Started with the Compilation Tools > About specifying command-line options > Methods of specifying command-line options

2.2.1 Methods of specifying command-line options

You can specify command-line options directly. Some operating systems restrict the length of the command line, so you can also specify command-line options in environment variables or in a text file.

You can:
  • Specify the commands directly on the command line. However, the number of options you can specify is limited by the command length supported by your operating system.
  • Specify the commands in a text file, called a via file. A separate via file is required for each tool. You can use a via file to overcome the command length limitation of your operating system.
  • Use tool-specific environment variables. These are:
    • ARMCC5_ASMOPT for the assembler.
    • ARMCC5_CCOPT for the compiler.
    • ARMCC5_FROMELFOPT for the fromelf image converter.
    • ARMCC5_LINKOPT for the linker.
    The syntax is identical to the command-line syntax. The compilation tool reads the value of the environment variable and inserts it at the front of the command string. This means that you can override options specified in the environment variable by arguments on the command line.
Related reference
1.6.1 Environment variables used by the toolchain
Related information
--via assembler option
--via compiler option
--via linker option
--via fromelf option
--via armar option
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools > About specifying command-line options > Methods of specifying command-line options


ARM Compiler for µVision Getting Started Guide: About specifying Cygwin paths in compilation tools on Windows

About specifying Cygwin paths in compilation tools on Windows

Non-Confidential PDF file icon PDF version ARM DUI0592F
ARM® Compiler v5.06 for µVision® Getting Started Guide Version 5
Home > Overview of ARM Compiler > About specifying Cygwin paths in compilation tools on Windows

1.8 About specifying Cygwin paths in compilation tools on Windows

You must use an environment variable to specify Cygwin paths for compilation tools on Windows.

By default on Windows, the compilation tools require path names to be in the Windows DOS format, for example, C:\myfiles. If you want to use Cygwin path names, then set the CYGPATH environment variable to the location of the cygpath.exe file on your system. For example:
set CYGPATH=C:/cygwin/bin/cygpath.exe
You can now specify file locations in the compilation tools command-line options using the Cygwin path format. The paths are translated by cygpath.exe. For example, to compile the file /cygdrive/h/main.c, enter the command:
armcc -c --debug /cygdrive/h/main.c
You can still specify paths that start with:
  • A drive letter, for example C:\ or C:/.
  • UNC, for example, \\computer.
The compilation tools do not translate these paths because the paths are already in a form that Windows understands.

Limitations of CYGPATH

Be aware of the following limitations with CYGPATH:
  • Cygwin path translation enabled by CYGPATH is only supported on 32-bit Windows platforms.
  • When using a Cygwin style path with spaces or other special terminal characters, the path must be double quoted:
    • The use of single quotes or escaping characters is not supported.
    • The use of literal doublequote characters in path names is not supported.
Related reference
1.6 Toolchain environment variables
Related information
Cygwin versions supported
Cygwin home page
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > About specifying Cygwin paths in compilation tools on Windows


ARM Compiler for µVision Getting Started Guide: Rogue Wave documentation

Rogue Wave documentation

Home > Overview of ARM Compiler > Rogue Wave documentation

1.9 Rogue Wave documentation

The documentation for the Rogue Wave Standard C++ Library used by ARM® Compiler is available from the ARM website. It is also installed with some ARM products.

The manuals for the Rogue Wave Standard C++ Library used by the compilation tools are:
  • Standard C++ Library Class Reference.
  • Standard C++ Library User’s Guide - OEM Edition.
These manuals might be installed with the documentation of your ARM product. If they are not installed, you can view them at Rogue Wave Standard C++ Library Documentation
Figure 1-1 Rogue Wave HTML documentation
Rogue Wave HTML documentation

Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > Rogue Wave documentation


ARM Compiler for µVision Getting Started Guide: Further reading

Further reading

Home > Overview of ARM Compiler > Further reading

1.10 Further reading

Additional information on developing code for the ARM family of processors is available from both ARM and third parties.

ARM publications

ARM periodically provides updates and corrections to its documentation. See ARM Infocenter for current errata sheets and addenda, and the ARM Frequently Asked Questions (FAQs).
For full information about the base standard, software interfaces, and standards supported by ARM, see Application Binary Interface (ABI) for the ARM Architecture.
In addition, see the following documentation for specific information relating to ARM products:
  • ARM Architecture Reference Manuals.
  • Cortex-R series processors.
  • Cortex-M series processors.
  • ARM9 processors.
  • ARM7 processors.

Other publications

This ARM Compiler tools documentation is not intended to be an introduction to the C or C++ programming languages. It does not try to teach programming in C or C++, and it is not a reference manual for the C or C++ standards. Other publications provide general information about programming.
The following publications describe the C++ language:
  • ISO/IEC 14882:2014, C++ Standard.
  • Stroustrup, B., The C++ Programming Language (4th edition, 2013). Addison-Wesley Publishing Company, Reading, Massachusetts. ISBN 978-0321563842.
The following publications provide general C++ programming information:
  • Stroustrup, B., The Design and Evolution of C++ (1994). Addison-Wesley Publishing Company, Reading, Massachusetts. ISBN 0-201-54330-3.
    This book explains how C++ evolved from its first design to the language in use today.
  • Vandevoorde, D and Josuttis, N.M. C++ Templates: The Complete Guide (2003). Addison-Wesley Publishing Company, Reading, Massachusetts. ISBN 0-201-73484-2.
  • Meyers, S., Effective C++ (3rd edition, 2005). Addison-Wesley Publishing Company, Reading, Massachusetts. ISBN 978-0321334879.
    This provides short, specific guidelines for effective C++ development.
  • Meyers, S., More Effective C++ (2nd edition, 1997). Addison-Wesley Publishing Company, Reading, Massachusetts. ISBN 0-201-92488-9.
The following publications provide general C programming information:
  • ISO/IEC 9899:2011, C Standard.
    The standard is available from national standards bodies (for example, AFNOR in France, ANSI in the USA).
  • Kernighan, B.W. and Ritchie, D.M., The C Programming Language (2nd edition, 1988). Prentice-Hall, Englewood Cliffs, NJ, USA. ISBN 0-13-110362-8.
    This book is co-authored by the original designer and implementer of the C language, and is updated to cover the essentials of ANSI C.
  • Harbison, S.P. and Steele, G.L., A C Reference Manual (5th edition, 2002). Prentice-Hall, Englewood Cliffs, NJ, USA. ISBN 0-13-089592-X.
    This is a very thorough reference guide to C, including useful information on ANSI C.
  • Plauger, P., The Standard C Library (1991). Prentice-Hall, Englewood Cliffs, NJ, USA. ISBN 0-13-131509-9.
    This is a comprehensive treatment of ANSI and ISO standards for the C Library.
  • Koenig, A., C Traps and Pitfalls, Addison-Wesley (1989), Reading, Mass. ISBN 0-201-17928-8.
    This explains how to avoid the most common traps in C programming. It provides informative reading at all levels of competence in C.
See The DWARF Debugging Standard web site for the latest information about the Debug With Arbitrary Record Format (DWARF) debug table standards and ELF specifications.
The following publications provide information about the European Telecommunications Standards Institute (ETSI) basic operations:
  • ETSI Recommendation G.191: Software tools for speech and audio coding standardization.
  • ITU-T Software Tool Library 2005 User's manual, included as part of ETSI Recommendation G.191.
  • ETSI Recommendation G723.1: Dual rate speech coder for multimedia communications transmitting at 5.3 and 6.3 kbit/s.
  • ETSI Recommendation G.729: Coding of speech at 8 kbit/s using conjugate-structure algebraic-code-excited linear prediction (CS-ACELP).
These publications are all available from the telecommunications bureau of the International Telecommunication Union (ITU) web site.
Publications providing information about Texas Instruments compiler intrinsics are available from Texas Instruments web site.
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > Further reading


ARM Compiler for µVision Getting Started Guide: Getting Started with the Compilation Tools

Getting Started with the Compilation Tools

Home > Getting Started with the Compilation Tools

Chapter 2 Getting Started with the Compilation Tools

Describes how to create an application using the tools provided by ARM® Compiler.

It contains the following sections:

  • 2.1 About the ARM compilation tools.

  • 2.2 About specifying command-line options.

  • 2.3 The ARM compiler command.

  • 2.4 The ARM linker command.

  • 2.5 The ARM assembler command.

  • 2.6 Execute-only memory.

  • 2.7 Building applications for execute-only memory.

  • 2.8 The fromelf image converter command.

Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools


ARM Compiler for µVision Getting Started Guide: About the ARM compilation tools

About the ARM compilation tools

Home > Getting Started with the Compilation Tools > About the ARM compilation tools

2.1 About the ARM compilation tools

The compilation tools allow you to build executable images, partially linked object files, and shared object files, and to convert images to different formats.

A typical application development might involve the following:
  • Compiling C/C++ source code for the main application (armcc).
  • Assembling ARM assembly source code for near-hardware components, such as interrupt service routines (armasm).
  • Linking all objects together to generate an image (armlink).
  • Converting an image to flash format in plain binary, Intel Hex, and Motorola-S formats (fromelf).
The following figure shows how the compilation tools are used for the development of a typical application.
Figure 2-1 A typical tool usage flow diagram
A typical tool usage flow diagram

Related concepts
2.3 The ARM compiler command
2.4 The ARM linker command
2.5 The ARM assembler command
2.8 The fromelf image converter command
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools > About the ARM compilation tools


ARM Compiler for µVision Getting Started Guide: The ARM compiler command

The ARM compiler command

Home > Getting Started with the Compilation Tools > The ARM compiler command

2.3 The ARM compiler command

The compiler, armcc, can compile C and C++ source code into ARM and Thumb code.

Typically, you invoke the compiler as follows:
armcc [options] file_1 … file_n
You can specify one or more input files. The compiler produces one object file for each source input file.

Building an example image from C++ source

To compile a C++ file called shapes.cpp:
  1. Compile the C++ file shapes.cpp with the following command:
    armcc -c --cpp --debug -O1 shapes.cpp -o shapes.o
  2. The following options are commonly used:
    -c
    Tells the compiler to compile only, and not link.
    --cpp
    Tells the compiler that the source is C++.
    --debug
    Tells the compiler to add debug tables for source-level debugging.
    -O1
    Tells the compiler to generate code with restricted optimizations applied to give a satisfactory debug view with good code density and performance.
    -o filename
    Tells the compiler to create an object file with the specified filename.

    Note

    Be aware that --arm is the default compiler option.
  3. Link the file:
    armlink shapes.o --info totals -o shapes.axf
  4. Use an ELF, DWARF 2, and DWARF 3 compatible debugger to load and run the image.

Command-line options for compiling ARM code

The following compiler options generate ARM code:
--arm
Tells the compiler to generate ARM code in preference to Thumb code. However, #pragma thumb overrides this option.
This is the default compiler option.
--arm_only
Forces the compiler to generate only ARM code. The compiler behaves as if Thumb is absent from the target architecture. Any #pragma thumb declarations are ignored.

Command-line options for compiling Thumb code

The following compiler option generates Thumb code:
--thumb
Tells the compiler to generate Thumb code in preference to ARM code. However, #pragma arm overrides this option.
Related concepts
2.4 The ARM linker command
1.1.3 Standards compliance in ARM® Compiler
Related information
Compiler Command-line Options
--arm compiler option
--arm_only compiler option
--thumb compiler option
#pragma arm
#pragma thumb
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools > The ARM compiler command


ARM Compiler for µVision Getting Started Guide: The ARM linker command

The ARM linker command

Home > Getting Started with the Compilation Tools > The ARM linker command

2.4 The ARM linker command

The linker combines the contents of one or more object files with selected parts of one or more object libraries to produce an image or object file.

Typically, you invoke the linker as follows:
armlink [options] file_1 … file_n

Linking an example object file

To link the object file shapes.o, enter:
armlink shapes.o --info totals -o shapes.axf
-o
Specifies the output file as shapes.axf.
--info totals
Tells the linker to display totals of the Code and Data sizes for input objects and libraries.
Related information
Linker Command-line Options
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools > The ARM linker command


ARM Compiler for µVision Getting Started Guide: The ARM assembler command

The ARM assembler command

Home > Getting Started with the Compilation Tools > The ARM assembler command

2.5 The ARM assembler command

The assembler, armasm, can assemble ARM assembly code into ARM and Thumb code.

Typically, you invoke the assembler as follows:
armasm [options] inputfile

Building an example from assembly source

To build the assembler program word.s:
  1. Assemble the source file:
    armasm --debug word.s
  2. Link the object file:
    armlink word.o -o word.axf
  3. Use an ELF, DWARF 2, and DWARF 3 compatible debugger to load and run the image.
    Step through the program and examine the registers to see how they change.
Related concepts
1.1.3 Standards compliance in ARM® Compiler
Related information
Assembler Command-line Options
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools > The ARM assembler command


ARM Compiler for µVision Getting Started Guide: The fromelf image converter command

The fromelf image converter command

Home > Getting Started with the Compilation Tools > The fromelf image converter command

2.8 The fromelf image converter command

fromelf allows you to convert ELF files into different formats and display information about them.

The features of the fromelf image converter include:
  • Converting an executable image in ELF executable format to other file formats.
  • Controlling debug information in output files.
  • Printing information about an ELF image or an ELF object file.

Examples

The following examples show how to use fromelf:
fromelf --text -c -s --output=outfile.lst infile.axf
Creates a plain text output file that contains the disassembled code and the symbol table of an ELF image.
fromelf --bin --16x2 --output=outfile.bin infile.axf
Creates two files in binary format (outfile0.bin and outfile1.bin) for a target system with a memory configuration of a 16-bit memory width in two banks.
The output files in the last example are suitable for writing directly to a 16-bit Flash device.
Related information
fromelf command-line syntax
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools > The fromelf image converter command


ARM Compiler for µVision Getting Started Guide: Summary of ARM Compiler tools

Summary of ARM Compiler tools

Home > Overview of ARM Compiler > About ARM Compiler > Summary of ARM Compiler tools

1.1.1 Summary of ARM® Compiler tools

ARM® Compiler includes the tools and libraries required to create executable images, dynamically linked libraries and shared objects from C, C++, and ARM assembly code.

The toolchain comprises:
armcc
The ARM and Thumb® compiler. This compiles your C and C++ code.
It supports inline and embedded assemblers.
armasm
The ARM and Thumb assembler. This assembles ARM and Thumb assembly language sources.
armlink
The linker. This combines the contents of one or more object files with selected parts of one or more object libraries to produce an executable program.
armar
The librarian. This enables sets of ELF object files to be collected together and maintained in archives or libraries. You can pass such a library or archive to the linker in place of several ELF files. You can also use the archive for distribution to a third party for further application development.
fromelf
The image conversion utility. This can also generate textual information about the input image, such as its disassembly and its code and data size.
ARM C++ libraries
The ARM C++ libraries provide:
  • Helper functions when compiling C++.
  • Additional C++ functions not supported by the Rogue Wave library.
ARM C libraries
The ARM C libraries provide:
  • An implementation of the library features as defined in the C and C++ standards.
  • Extensions specific to the compiler, such as _fisatty(), __heapstats(), and __heapvalid().
  • Common nonstandard extensions to many C libraries.
  • Some POSIX extended functionality.
  • Some functions standardized by POSIX.
ARM C microlib
The ARM C microlib provides a highly optimized set of functions. These functions are for use with deeply embedded applications that have to fit into extremely small amounts of memory.
Rogue Wave C++ library
The Rogue Wave C++ library provides an implementation of the C++ Standard Template Library (STL).

Note

ARM Compiler does not support systems with ECC or parity protection where the memory is not initialized.
Related concepts
1.3 ARM® Compiler support on 64-bit host platforms
1.5 Licensed features of ARM® Compiler
1.1.4 Compliance with the ABI for the ARM Architecture (Base Standard)
1.2 ARM architectures supported by the toolchain
1.9 Rogue Wave documentation
Related reference
1.10 Further reading
Related information
ARM website
Overview of the Compiler
Overview of the Assembler
Overview of the Linker
The ARM C and C++ Libraries
The ARM C Micro-Library
Overview of the ARM Librarian
Overview of the fromelf Image Converter
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > About ARM Compiler > Summary of ARM Compiler tools


ARM Compiler for µVision Getting Started Guide: Supporting software

Supporting software

Home > Overview of ARM Compiler > About ARM Compiler > Supporting software

1.1.5 Supporting software

You can debug the output from the toolchain with any ARM debugger. However, ARM cannot guarantee this with third-party debuggers, even when they are compatible with DWARF 2 and DWARF 3 standards.

Updates and patches to the toolchain are available from the ARM web site as they become available.
Related concepts
1.1.3 Standards compliance in ARM® Compiler
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > About ARM Compiler > Supporting software


ARM Compiler for µVision Getting Started Guide: Environment variables used by the toolchain

Environment variables used by the toolchain

Home > Overview of ARM Compiler > Toolchain environment variables > Environment variables used by the toolchain

1.6.1 Environment variables used by the toolchain

You can use environment variables to modify the ARM Compiler environment if required.

The environment variables are:

Table 1-1 Environment variables used by the toolchain

Environment variable Setting
ARMLMD_LICENSE_FILE
This environment variable must be set, and specifies the location of your ARM license file. See the ARM® DS-5 License Management Guide for information on this environment variable.

Note

On Windows, the length of ARMLMD_LICENSE_FILE must not exceed 260 characters.
ARMROOT
Your installation directory root, install_directory.
ARMCC5_ASMOPT
An optional environment variable to define additional assembler options that are to be used outside your regular makefile.
The options listed appear before any options specified for the armasm command in the makefile. Therefore, any options specified in the makefile might override the options listed in this environment variable.
ARMCC5_CCOPT
An optional environment variable to define additional compiler options that are to be used outside your regular makefile.
The options listed appear before any options specified for the armcc command in the makefile. Therefore, any options specified in the makefile might override the options listed in this environment variable.
ARMCC5_FROMELFOPT
An optional environment variable to define additional fromelf image converter options that are to be used outside your regular makefile.
The options listed appear before any options specified for the fromelf command in the makefile. Therefore, any options specified in the makefile might override the options listed in this environment variable.
ARMCC5_LINKOPT
An optional environment variable to define additional linker options that are to be used outside your regular makefile.
The options listed appear before any options specified for the armlink command in the makefile. Therefore, any options specified in the makefile might override the options listed in this environment variable.
ARMCC5INC
The default system include path. That is, the path used by the compiler to search for header filenames enclosed in angle-brackets. The compiler option -J overrides this environment variable.
The default location of the compiler include files is:
install_directory\include
ARMCC5LIB
The default location of the ARM standard C and C++ library files:
install_directory\lib
The compiler option --libpath overrides this environment variable.

Note

If you include a path separator at the end of the path, the linker searches that directory and the subdirectories. So for install_directory\lib\ the linker searches:
install_directory\lib
install_directory\lib\armlib
install_directory\lib\cpplib
ARMINC
Used only if you do not specify the compiler option -J and ARMCC5INC is either not set or is empty.
See the description of ARMCC5INC for more information.
ARMLIB
Used only if you do not specify the compiler option --libpath and ARMCC5LIB is either not set or is empty.
See the description of ARMCC5LIB for more information.
CYGPATH
The location of the cygpath.exe file on your system in Cygwin path format. For example:
C:/cygwin/bin/cygpath.exe
You must set this if you want to specify paths in Cygwin format for the compilation tools.

Note

Cygwin path translation enabled by CYGPATH is only supported on 32-bit Windows platforms, and is not supported on Windows Server 2012 and 64-bit Windows 8.1.
TMP
Used on Windows platforms to specify the directory to be used for temporary files. If TMP is not defined, or if it is set to the name of a directory that does not exist, temporary files are created in the current working directory.
Related concepts
1.8 About specifying Cygwin paths in compilation tools on Windows
Related reference
2.2 About specifying command-line options
Related information
ARM DS-5 License Management Guide
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > Toolchain environment variables > Environment variables used by the toolchain


ARM Compiler for µVision Getting Started Guide: Important limitations of ARM Compiler

Important limitations of ARM Compiler

Home > Overview of ARM Compiler > About ARM Compiler > Important limitations of ARM Compiler

1.1.6 Important limitations of ARM® Compiler

ARM® Compiler has some limitations that you must be aware of.

These limitations are:
  • ARM Compiler does not support systems with ECC or parity protection where the memory is not initialized..
  • Some floating-point arithmetic operations are not handled in hardware.
Related information
Limitations on hardware handling of floating-point arithmetic
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > About ARM Compiler > Important limitations of ARM Compiler


ARM Compiler for µVision Getting Started Guide: About specifying command-line options

About specifying command-line options

Home > Getting Started with the Compilation Tools > About specifying command-line options

2.2 About specifying command-line options

You can specify command-line options in different ways and use special wildcard characters. However, there are some rules you must follow and you must be aware that some options depend on the order they appear on the command-line.

This section contains the following subsections:

  • 2.2.1 Methods of specifying command-line options.

  • 2.2.2 Special characters on the command line.

  • 2.2.3 Rules for specifying command-line options.

  • 2.2.4 Order of options on the command line.

  • 2.2.5 Precedence of command-line options when using them in a text file.

  • 2.2.6 Autocompletion of command-line options.

Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Getting Started with the Compilation Tools > About specifying command-line options


ARM Compiler for µVision Getting Started Guide: TMP environment variable for temporary file directories

TMP environment variable for temporary file directories

Home > Overview of ARM Compiler > Toolchain environment variables > TMP environment variable for temporary file directories

1.6.2 TMP environment variable for temporary file directories

The compilation tools use a temporary directory when processing files.

Use the TMP environment variable name to refer to the temporary directory. If TMP is not defined, or if it is set to the name of a directory that does not exist, temporary files are created in the current working directory.
TMP is typically set up by a system administrator. However, it is permissible for you to change it.
Non-Confidential | PDF file icon PDF version | ARM DUI0592F
Copyright © 2011, 2012, 2014-2016 ARM. All rights reserved. |  |
Home > Overview of ARM Compiler > Toolchain environment variables > TMP environment variable for temporary file directories