7.5.2. Using the Thumb-ARM interworking image project

This section describes how to use the Thumb-ARM interworking image project to start a new interworking project.

Adding files

Follow these steps to add files to the project:

  1. Select the appropriate partition before adding the file:

    • If the file is C or C++ source that should be compiled to Thumb code, select the Thumb-Sources partition and then select Add files to Thumb-Sources from the Project menu.

    • If the file is C or C++ source that is to be compiled to ARM code, select the ARM-Sources partition and then select Add files to ARM-Sources from the Project menu.

    • If the file is assembly language source, select the ASM-Sources partition and then select Add files to ASM-Sources from the Project menu.

    The Add Files to Project dialog is displayed.

  2. In the Add Files to Project dialog, find the directory containing the files to be added.

  3. Select the required file or files and click Open. The files are added to the selected partition.

After adding files you may have to expand branches of the tree to make them visible. Branches containing subtrees have a + button. If you added assembly language files to the ASM-Source partition that do not contain CODE32 directives perform the steps listed in Configuring the assembler to read ARM assembly source below.

Configuring the assembler to read ARM assembly source

By default, the interworking templates call the assembler with the -16 option to instruct the assembler to assemble Thumb code. The templates assume that assembly language source uses CODE16 and CODE32 directives to switch between Thumb and ARM assembly where required.

If you have ARM assembly language files that do not use CODE32 directives you can configure the assembler to avoid changing the assembly language source.

Follow these steps to change the assembler configuration for an individual source file:

  1. In the Project View, expand the ASM-Sources partition and select the ARM assembler source, for example, armer_kerl.s

  2. Choose Tool configuration for armer_kerl.s ? asm ? Set from the Project menu. The Compiler Configuration dialog is displayed.

  3. Click the Target tab and select the ARM radio button in the Initial state group.

  4. Select the Call Standard tab and ensure that the APCS3 radio button is selected in the APCS3 Qualifiers group.

  5. Click OK to save the configuration.

Copyright © 1997, 1998 ARM Limited. All rights reserved.ARM DUI 0040D
Non-Confidential