SUD-DT-03-0257-E

CUSTOMER NOTIFICATION June 16, 2003 Koji Nishibayashi, Senior System Integrator Microcomputer Group 2nd Solutions Division

Solutions Operations Unit

NEC Electronics Corporation

CP(K), O

V850 Series C Compiler Package

CA850 V2.60

Operating Precautions

Be sure to read this document before using the product.

1 CONTENTS

1. USER’S MANUAL...... 5

2. SUPPORTED TOOLS...... 5

3. CHANGES FROM V2.50 TO V2.60...... 6 3.1 Changes in C Compiler ...... 6 3.1.1 Addition of external variable register assignment function...... 6 3.1.2 Addition of external variable sort function...... 7 3.1.3 Addition of packing function for unions...... 8 3.1.4 Addition Series shift support function...... 8 3.1.5 Modification of error message format ...... 10 3.1.6 Addition and modification of messages ...... 10 3.1.7 Addition of option to avoid CPU bug...... 11 3.1.8 Addition of security ID function ...... 11 3.1.9 Addition of option bytes function...... 12 3.1.10 Addition of -cn/-cnv850e option to compiler driver ...... 12 3.1.11 Addition of device file processing to compiler driver ...... 13 3.1.12 Modification of upper limit of compiler include path...... 13 3.1.13 Modification of message when some system registers are used by assembler ...... 13 3.1.14 Addition of default path handling by assembler...... 13 3.1.15 Change of device file handling by assembler...... 13 3.1.16 Modification of error/warning output in assembler...... 13 3.1.17 Addition of section sort function to linker...... 14 3.1.18 Support of interrupt vector in linker...... 14 3.1.19 Addition of hex converter startup option in PM plus ...... 15 3.1.20 Addition of [About CA850] dialog box...... 15 3.1.21 Improvement of performance of section file generator...... 15 3.1.22 Addition of error messages...... 15 3.2 Changes in PM plus ...... 17 3.2.1 Improvement of processing time ...... 17 3.2.2 Addition of active project selection box ...... 17 3.2.3 Addition of right-click menu in Output window...... 17 3.2.4 Addition of functions to Project window ...... 17 3.2.5 Addition and modification of functions to menu...... 17 3.2.6 Addition of functions related to workspace...... 18 3.2.7 Addition of functions related to build...... 18 3.2.8 Addition of function to set mark name in Mark Jump dialog box...... 18 3.2.9 Enhancement of macro function...... 18 3.2.10 Enhancement of drag & drop function...... 18 3.2.11 Modification of wizard ...... 19 3.2.12 Addition of function supporting real-time OS (RX) ...... 19 3.2.13 Modification of message...... 19 3.2.14 Addition of messages ...... 19 3.3 Changes in Stack Estimation Tools...... 20 3.3.1 Addition of compile option condition ...... 20 3.3.2 Addition of function pointer call display function...... 20

2 3.3.3 Addition of function specification option ...... 20 3.3.4 Addition of stack amount addition option...... 20

4. CAUTIONS...... 21 4.1 Cautions on Installation ...... 21 4.1.1 Caution on activating installer...... 21 4.1.2 Caution on restarting computer ...... 21 4.1.3 Caution on authority for installation ...... 21 4.1.4 Caution on installation directory ...... 21 4.1.5 Caution on re-installation...... 21 4.1.6 Caution on file created at installation...... 21 4.1.7 Caution on PM plus help...... 21 4.1.8 Caution on language used in Windows ...... 21 4.2 Cautions on C Compiler ...... 22 4.2.1 Caution on debug information output option (-g) specification...... 22 4.2.2 r1 register used by interrupt function ...... 22 4.2.3 User-defined function and interrupt disable/enable function ...... 22 4.2.4 Caution on debug information ...... 22 4.3 Cautions on PM plus ...... 22 4.3.1 Network environment...... 22 4.3.2 Installation folder...... 22 4.3.3 2-byte code ...... 23 4.3.4 Installation of language tools ...... 23 4.3.5 Activation of SF850...... 23 4.3.6 When opening project file to specify a device that is not installed yet ...... 23 4.3.7 Specification of startup file...... 23 4.3.8 Link directive file to be created ...... 23 4.3.9 Editing configuration file...... 24 4.3.10 Location of source file...... 24 4.3.11 Function name in Project window...... 24 4.3.12 Project window display ...... 24 4.3.13 Title of dialog box...... 24 4.3.14 Addition of source file ...... 24 4.3.15 Change of series name when creating a new workspace ...... 24 4.3.16 Smart lookup function...... 24 4.3.17 Smart lookup function and automatic prototype generation function ...... 25 4.3.18 Automatic generation of function list, smart lookup function, and prototype declaration ...... 25 4.3.19 Customization of keyboard ...... 25 4.3.20 Shortcut key display...... 25 4.3.21 Applying layer rules ...... 25 4.3.22 Font size of help ...... 25

5. CORRECTION AND ADDITION OF RESTRICTIONS ...... 26 5.1 Correction of CA850 Usage Restrictions...... 26 5.1.1 Restriction on numeric value following preprocessing instruction (No.9)...... 26 5.1.2 Restriction on illegal identifier following preprocessing instruction (No.10) ...... 26 5.1.3 Restriction on specifying type defined by union with struct (No.11)...... 26 5.1.4 Restriction on section file and global variable (No.19) ...... 26 5.1.5 Restriction on describing only ‘∼ (tilde)’ in macro (No.36) ...... 26 3 5.1.6 Restriction on ‘∼ (tilde)’ when macro is nested (No.37)...... 26 5.1.7 Restriction on initialization of variable (No.56) ...... 26 5.1.8 Restriction on optimization of union of integer and pointer (No.80) ...... 26 5.1.9 Restriction on packed structure argument (No.81)...... 27 5.1.10 Restriction on inline expansion of functions with structure as argument (No.83)...... 27 5.1.11 Restriction on function pointer (No.84) ...... 27 5.1.12 Restriction on embedded function __sasf() (No.85)...... 28 5.1.13 Restriction on conversion from float type to short/unsigned short type (No.86)...... 28 5.1.14 Restriction on interrupt function (No.87)...... 28 5.1.15 Restriction on multiple byte characters in a command file (No.61) ...... 29 5.2 Addition of Usage Restrictions in Other Package Tools ...... 29 5.2.1 Restriction on replacement using regular expression in PM plus (No.1) ...... 29 5.2.2 Restriction on square brackets in PM plus (No.2) ...... 29

6. LIST OF USAGE RESTRICTIONS IN CA850 ...... 30 6.1 List of Compiler Package Usage Restrictions ...... 30 6.2 Details of Compiler Package Usage Restrictions...... 30 6.3 List of Usage Restrictions in Other Package Tools...... 37

4 Thank you for purchasing Series C Compiler Package CA850 V2.60. This document explains the modifications from V850 Series C compiler package CA850 V2.50 to V2.60, cautions, and usage restrictions. Be sure to read this document before using CA850 V2.60.

1. USER’S MANUAL

The following user’s manuals are available for this version as a PDF file only. • CA850 C Compiler Package - C Language (document number: U16054E) Note 1 • CA850 C Compiler Package - Assembly Language (document number: U16042E) Note 1 • CA850 C Compiler Package - Operation (document number: U16053E) Note 1 • CA850 C Compiler Package - Coding Technique (document number: U16076E) Note 1 • PM plus (document number: U16569E) Note 2

Notes 1. This is a user’s manual (including online help) for CA850 V2.50. Refer to this document (SUD-DT-03-0257-E) for the functions added in V2.60. 2. Windows version only.

2. SUPPORTED TOOLS

Use the following version of PM plus when using CA850 V2.60. • PM plus V5.10

Note that the following version of the project manager is not supported. • PM plus V5.10 or earlier • All versions of PM

Use the following versions of the integrated debugger or system simulator when used in combination with CA850 V2.60 and PM plus. • Integrated debugger: ID850 V2.50 or later • Integrated debugger: ID850NW V2.50 or later • Integrated debugger: ID850NWC V2.50 or later • System simulator: SM850 V2.50 or later

5 3. CHANGES FROM V2.50 TO V2.60

This section explains the changes from V2.50 to V2.60 in terms of the C compiler, PM plus, and stack estimation tool.

3.1 Changes in C Compiler

This section explains the changes in the C compiler.

3.1.1 Addition of external variable register assignment function When the -r= option is specified, register r is assigned to the external variable . r is used to specify a register that is other than a mask register and that is not used by the compiler by specifying the register mode specification option (-reg). An error message is output and the processing terminates if a register that cannot be specified is specified. is the symbol name of an external variable (excluding '_' at the front). The following external variables cannot be specified. • volatile variable • Variable using address operator • Aggregate • Array • Variable with internal linkage • Peripheral I/O register Note that no error message is output for aggregates and arrays whose size is 4 or less. The definition (tentative definition) of the specified external variable and declaration has been deleted. When using the initial value of an external variable (when initialization is not performed at the beginning of program execution), assign the initial value to the register using the startup file. (Example) If -reg26 -r19=i is specified in a source in which “int i = 1;” is defined: mov 1, r19 -- set i jarl _main, lp -- call main function

Since the debug information of the specified external variable is also deleted, debug optimization also becomes impossible. (Use the .) With PM plus, this function is set on the External Register tab in the Compiler Options dialog box.

6

3.1.2 Addition of external variable sort function When the -Wo,-Op option is specified, external variables are aligned in order of size, starting from the largest. However, variables allocated in the const/sconst section are not aligned. When an intermediate language file is specified like -Wo,-Op= for this option, the following operations will be performed.

(1) The specified intermediate language file is loaded and an external variable list is created. If the specified file cannot be found, an empty list will be created and the operation will proceed to the next step. (2) If a definition or tentative definition of the external variable exists in the source file, the operation moves to the list created in (1). At this time, the tentative definition is changed to a definition. The definition of the source file (tentative definition) is changed to a declaration. If a variable definition with the same name exists in the list, it is overwritten by the definition in the source file. At this time, if there are only changes in the section, size, alignment, or initial value, a warning will be output. (3) The list of external variables is output to the intermediate language file . Finally all the compiled files and the file in which is compiled are linked.

[Caution] Note the following points when specifying file names. • If an option is specified for the file and the file is compiled, if all the definitions for a certain variable are tentative, and if a definition exists in a file for which no option is specified, the file can be linked normally if no option is specified, but an option overloading link error will be output if an option is specified. • If an option is specified for the file and a certain variable is overloaded, no link error will be output but the definition of the file compiled later will be valid.

7 • To delete variables in the intermediate language file, delete the intermediate language file itself and rebuild the file.

With PM plus, this function is set on the Detail of Optimization tab in the Compiler Options dialog box. Note the following points when specifying file names in PM plus. • The base name of the file name must be different from the source file. • Specify the intermediate language file extension ".ic" as the extension.

3.1.3 Addition of packing function for unions A union is now handled as a packing target in the same manner as structure (struct) packing.

3.1.4 Addition 78K Series shift support function The following #pragma and functions have been added to support shifting from the 78K Series compiler (CC78K0, CC78K0S, or CC78K4) to the CA850. The added #pragma, unlike the conventional #pragma, is not case sensitive. Specify the following option to use this function. -Wf,-Xdescription=78k

The meanings of the symbols used in [Format] are as follows. ∆: Space < >: Description specified by user [ ]: Description that can be omitted

(1) Assembler instruction description [Format] #asm #endasm 8 [Explanation] Handled as #pragma asm~#pragma endasm. A warning message will be output individually.

(2) Device type specification [Format] #pragma ∆ pc() [Explanation] Handled as #pragma cpu .

(3) Special function register specification [Format] #pragma ∆ sfr [Explanation] Handled as #pragma ioreg.

(4) Interrupt function specification [Format] #pragma ∆ interrupt ∆ ∆ [direct] __interrupt ∆ or #pragma ∆ vect ∆ __interrupt ∆ [Explanation] The same operation as #pragma interrupt [direct] is performed. Description after other than direct will be ignored. [Caution] An error will be output because __interrupt_brk is not supported.

(5) Interrupt disable control function [Format] #pragma ∆ DI DI(); #pragma ∆ EI EI(); [Explanation] Handled as __DI() and __EI(), respectively.

(6) CPU control instruction [Format] #pragma ∆ HALT HALT(); #pragma ∆ NOP NOP(); 9 [Explanation] Handled as __halt() and __nop(), respectively.

3.1.5 Modification of error message format The error message format of the compiler has been changed to standardize the error message format of cross tools (assembler, linker, archiver, hex converter, object dump, disassembler, ROMization , and section file generator). The error message formats of the compiler are as follows. • Message format including a file name and line number () ∆ : ∆ CA850 ∆ : ∆ • Message format including a file name ∆: ∆ CA850 ∆ : ∆ • Message format not including a file name and other information CA850 ∆ : ∆

The error message formats of cross tools are as follows. • Message format including a file name and line number : ∆ CA850 ∆ : ∆ • Message format not including a file name and other information : ∆ CA850 ∆ : ∆

has the following two types. • error Indicates an error. The processing will be stopped. This includes conventional fatal errors and compiler errors. • warning Indicates a warning. The processing will continue. is configured with one alphabetic character (F, E, or C for errors and W for warning) and a 4- digit numeric character (error number).

3.1.6 Addition and modification of messages Messages 6500 to 6999 have been added to the machine-dependant optimization module. The message number range for the code generation module has been changed to 6000 to 6499. Messages 3000 to 3999 have been added to the assembler. Messages 8000 to 8199 have been added to the section file generator. Messages 8200 to 8399 have been added to the archiver. Messages 8400 to 8599 have been added to the ROMization processor. Messages 8600 to 8799 have been added to the hex converter. Messages 8800 to 8999 have been added to the disassembler. Messages 9000 to 9199 have been added to the dump command.

10 3.1.7 Addition of option to avoid CPU bug The -Xv850patch=11 option, which is used to avoid a CPU bug in DMA, has been added to the compiler. When this option is specified, the output of the following instructions will be disabled. • set1/clr1/not1 • Misalign access of V850E core (when a structure is being packed) [Cautions] • The asm statement and assembler source files are not checked. • Access to a peripheral I/O must be described in word units (4 bytes). Consequently, consecutive peripheral I/O addresses are accessed and a warning will be output during assembly. Therefore, modify the description to byte/halfword units, instead of bit access. (Example) When P0.0 = 1 unsigned char dummy; dummy = P0; dummy |= 0x01; P0 = dummy;

3.1.8 Addition of security ID function A function to support the security ID of devices incorporating flash memory has been added. To use this function, implement any of the following procedures.

(1) Definition in assembler source Describe 10-byte data in the reserved section "SECURITY_ID" in the assembler source. (Example) Specify the security code “0xaa998877665544332211” .section "SECURITY_ID" .byte 0x11 -- Address 0x70 .byte 0x22 -- Address 0x71 .byte 0x33 -- Address 0x72 .byte 0x44 -- Address 0x73 .byte 0x55 -- Address 0x74 .byte 0x66 -- Address 0x75 .byte 0x77 -- Address 0x76 .byte 0x88 -- Address 0x77 .byte 0x99 -- Address 0x78 .byte 0xaa -- Address 0x79

(2) Specification by option Specify the new option –Xsid of the linker. [Format] -Xsid= [Explanation] is a hexadecimal number of 10 bytes or less (including 0x at the front) for which the vacancies in higher bits are filled with 0. An error is output when exceeds 10 bytes, and a warning is output and ignored when is specified for linking an object that does not 11 support the security ID function.

The -Xsid option can be specified in the ”Security ID” edit box on the Device tab in the Linker Options dialog box of PM plus. This box is dimmed when a device that does not support the security ID function is specified.

(Example) The option equivalent to the example in (1) above is as follows. -Xsid=0x112233445566778899aa

[Caution] If both (1) and (2) are specified, a warning is output and the option of (2) takes precedence. When (2) is implemented, the value is placed from the lower address in 1-byte units.

3.1.9 Addition of option bytes function An option bytes function for devices incorporating flash memory has been added. To use this function, specify option data using the reserved word “OPTION_BYTES” in the assembler source. (Example) .section " OPTION_BYTES " .byte 0b00000001 -- Address 0x7a .byte 0b00000000 -- Address 0x7b .byte 0b00000000 -- Address 0x7c .byte 0b00000000 -- Address 0x7d .byte 0b00000000 -- Address 0x7e .byte 0b00000000 -- Address 0x7f

3.1.10 Addition of -cn/-cnv850e option to compiler driver The -cn and -cnv850e options have been added to the compiler driver (ca850). The functions of these options are equivalent to the options with the same name in the assembler.

12 3.1.11 Addition of device file processing to compiler driver A function to read the device file when the -cpu option is specified by the compiler driver has been added. If the read fails, an error will be output and the processing will be abnormally terminated. When the device file is read successfully, the following processing will be performed. • Check when the V850E core is specified as the device and the -cn option is specified • Check when the V850 core is specified as the device and the -X256M option is specified • Check when a device not supporting programmable peripheral I/O is specified and the -Xbpc option is specified • Change of default startup file of the linker from crtN.o to crtE.o when the V850E core is specified as the device

3.1.12 Modification of upper limit of compiler include path The upper limit of the number of paths specified by the -I option of the compiler has been changed from 20 to 100.

3.1.13 Modification of message when some system registers are used by assembler Warning message output has been modified for when the V850E device is specified and some system registers are used by the assembler. • A warning is now output by stsr 18,r • A warning is now output by stsr 19,r • A warning is now not output by stsr 21,r • A warning is now not output by ldsr r,23

3.1.14 Addition of default path handling by assembler The processing of the following default path has been added to the assembler. (The directory is a relative path to the bin directory under the installation directory.) • ..\inc850 has been added to the directory for searching the include file. Search in this directory is performed after the search in the directory for which the -I option is specified is complete. • The ..\dev directory is now browsed when the -F option is specified and no device file could be found in the specified directory.

3.1.15 Change of device file handling by assembler Handling of the reserved words of the device file has been changed in the assembler.

3.1.16 Modification of error/warning output in assembler The following error/warning output has been changed in the assembler. • The following descriptions have been changed to cause error output. - divh 0, reg - dispose imm, regs..., [r0] • The r0 use warning output to the description tst reg, r0 is no longer output. • The internal error that is output when only a binary operator is described for the operand that can be specified by an expression has been changed to a syntax error. 13

3.1.17 Addition of section sort function to linker Segment directives described in a link directive file has been changed to sort in address order. Consequently, it is now not required to list the segments in address order in the link directive file. • Mapping directives are not subject to sorting. • Sorting is not performed when a relocatable object is generated (when the -r option is specified). • Segments for which no address is specified are sorted interlocking with the immediately preceding segment. • If an address is specified for the first mapping directive of a segment for which no address is specified, the address is regarded as the segment address and sorted. • If an address is specified for the second or later mapping directive of a segment for which no address is specified, it is regarded that no address is specified for the segment and sort is not performed. • A warning will be output when an address is specified for the mapping directive of a segment for which no address is specified.

The link directive of older versions can be interpreted by specifying the -Xolddir option. -Xolddir=V240: Equivalent to CA850 V2.40 (section-prioritized allocation is off, segment sort is off) -Xolddir=V250: Equivalent to CA850 V2.50 (segment sort is off) However, if a device such as the V850E/ME2, whose interrupts are not assigned in the vicinity of address 0x0, is specified, a warning will be output and sorting will be performed forcibly.

The check box “Use Old Link Directive” on the Option tab in Linker Options window of PM plus has been changed to the drop-down list “Compatibility of Link Directive”.

3.1.18 Support of interrupt vector in linker The link directive is now generated automatically for interrupts not assigned in the vicinity of address 0x0. If the V850E/ME2 is used and a directive for RESET is described at address 0x100000, delete the description because it may be regarded as an overloaded description.

14

3.1.19 Addition of hex converter startup option in PM plus The “Use This” check box, which is used to specify hex converter activation, has been added to the File tab in the Hex Converter Options dialog box of PM plus. The hex converter is not activated when this check box is cleared.

3.1.20 Addition of [About CA850] dialog box When [About CA850…] in the help menu of PM plus is selected, dialog boxes for the CA850 version and each module version can now be displayed.

3.1.21 Improvement of performance of section file generator The performance of the section file generator (sf850) has been improved.

3.1.22 Addition of error messages The following error messages have been added.

Error Number Message/Description F1107 Register 'r' is reserved for compiler system. An unspecifiable register r was specified using the external variable register assignment function. F1311 cannot find device file The device file cannot be loaded. F5601 cannot allocate register to '' An unspecifiable external variable was specified using the external variable register assignment function. W1126 -cn option must be used with V850 core, used -cnv850e option instead The device is the V850E core but the -cn option was specified. The processor changes it to the -cnv850e option and continues processing.

15

Error Number Message/Description W1127 '-X256M' option is not supported for V850 core. The device is the V850 core but the -X256M option was specified. The processor ignores the -X256M option and continues processing. W1128 cannot find programmable peripheral I/O registers, ignored The device does not support programmable peripheral I/O but the -Xbpc option was specified. The processor ignores the -Xbpc option and continues processing. W2166 recognized pragma directive '#pragma xxx' #asm or #endasm was described. The processor regards it as #pragma asm or #pragma endasm and continues processing. W4788 section address specification is illegal when address of segment "" is not specified. An address was specified for a mapping directive for which no address is specified. W4872 segment sort function is active, because new vector type exist in device file. A device in which the segment sort function cannot be disabled was specified. The processor ignores the -Xolddir option specified for disabling the segment sort function and executes segment sorting. W5501 The section of variable '' was changed from '' to '' The same variable definition already exists in the list for sorting external variables. The processor replaces it with the source file definition and replaces section with . W5502 The size of variable '' was changed from to . The same variable definition already exists in the list for sorting external variables. The processor replaces it with the source file definition and replaces size with size . W5503 The alignment of variable '' was changed from to . The same variable definition already exists in the list for sorting external variables. The processor replaces it with the source file definition and replaces alignment with alignment . W5504 The initial value of variable '' was changed. The same variable definition already exists in the list for sorting external variables. The processor replaces it with the source file definition and overwrites the initial value.

16 3.2 Changes in PM plus

This section explains the changes in PM plus.

3.2.1 Improvement of processing time The processing time in PM plus has been improved.

3.2.2 Addition of active project selection box An active project selection box has been added to the tool bar.

3.2.3 Addition of right-click menu in Output window The right-click menu in the Output window was the same as that in the Edit window. In the new version, the menu has been changed to one specific to the Output window, as follows. [Copy] [Clear] [Find…] [Find in Project] [Fix Window]

3.2.4 Addition of functions to Project window The following functions have been added or modified in the Project window.

• A function to sort the register file names and function names in ascending order has been added. • When the mouse cursor is moved on the register file name, the file name is displayed with the full path in the tool tip. When the mouse cursor is moved on the project group name or project title, the name of the used device is displayed. • When the return key is pressed while a file is selected, the file is now opened. • To more easily identify the active project, the name and project group of the active project are now highlighted.

3.2.5 Addition and modification of functions to menu • The following menus have been added to the [Project] menu. [Add Source Files…] [Add Project Related Files…] [Add Other Files…] • The commands shown below have been added so that the combo box on the toolbar (for search, build mode selection, and active project selection) can be easily accessed using a shortcut key. [Direct Search] under [Find] [Direct Select Build Mode] under [Build] [Direct Select Active Project] under [Project] • The menus shown below have been added to the menu that is displayed by right-clicking the mouse while the project group name or project title is selected in the Project window. 17 [Register order] [Ascending order] • A [Clear] command to clear the contents of the Output window has been added to the right-click menu in the Output window. • The menu access keys have been changed. [Add New Project] → [Add New Project] under [Project] [Tile Vertically] → [Tile Horizontally] under [Window] [Tile Horizontally] → [Tile Vertically] under [Window]

3.2.6 Addition of functions related to workspace • A progress bar is now displayed in project file unit on the status bar when opening a workspace. • If a registered source file or include file cannot be found when opening a workspace, the file that cannot be found is now displayed in the Output window. • A check box [Restore window position at each workspace] has been added to the workspace tab in the [PM plus Settings…] dialog box on the [Tool] menu. When this item is selected, the window display position is restored in workspace units.

3.2.7 Addition of functions related to build • An [Edit] button has been added to edit the registration contents on the “Pre Build ” and “After Build Process” tab in the Build Settings dialog box that is displayed by selecting [Build Settings…] on the [Build] menu. In line with this addition, an Edit Command dialog box has been added. • [Add] has been changed to [Add...] in the Build Mode dialog box. • If a file cannot be deleted by executing [Clean] on the [Build] menu in the previous version, an error message is output for each file. In V2.60, such files are displayed in the Output window together. • “Build Project” has been changed to “Build Project” in the Batch Build dialog box. • The project title to be added is now displayed in the “Add Source Files”, “Add Project Related Files”, and “Add Other Files” dialog boxes. • "Debug Target File" has been changed to "Debug Target File" in the Debugger Settings dialog box.

3.2.8 Addition of function to set mark name in Mark Jump dialog box The contents of the Mark Jump dialog box have been modified so that the mark name can be set. In addition, up to 20 marked data are memorized in the registry.

3.2.9 Enhancement of macro function • [Open Workspace…] and [Close Workspace] are now supported by the macro function. • “Title” has been changed to “Title” in the Add the Macro File dialog box.

3.2.10 Enhancement of drag & drop function • A workspace can now be opened by dropping a workspace file or a project file in the Main window. • A project can now be added by dropping a project file in the Project window.

18 3.2.11 Modification of wizard The design of the “New Workspace - Step 3/8 [Startup]” and “New Workspace - Set 5/8 [LinkDirectiveFile]” dialog boxes has been modified. “Copy and Use the Existing file” has been added.

3.2.12 Addition of function supporting real-time OS (RX) The following functions can be used when the corresponding RX package has been installed. • When the use of the RX is selected in the new project creation wizard or on the [Select OS] menu under [Tool], the necessary RX libraries and RX objects are automatically added as related files. • The system calls of the RX can be highlighted in the Edit window, and the smart lookup function is now supported. The highlighted display can be switched on/off on the Keyword page on the [Customize…] menu under [Tool].

3.2.13 Modification of message The device file name is now displayed in the E1405 message.

3.2.14 Addition of messages The following messages have been added.

Error Number Message F0130 Failed to copy the file. The original file cannot be opened or disk space may not be enough or the other process may by using the destination file. Copy from: %s Copy to: %s F0131 Failed to remove the file. Make sure that this file is read-only or the other process using this file. E1028 Please specify the same file extension of copy file. E1029 The file names of copy file and register file are identical. Please specify the different file name to register. E1030 %s Cannot register the file name with space character. Please register the file after rename it. Do you wish to continue to add source files?” E1031 A file name cannot contain any of the characters. \ /:*?\"<>| Do you wish to continue to add source files?” E1032 %s Cannot use the network path. E1033 %s Cannot use the network path. Do you wish to continue to add source files?” E1034 %s Cannot use the file path with space character. E1035 Two or more workspace files or project files cannot be dropped. E1036 A workspace is not opened during user program execution. Please open a workspace after stopping a program.

19 3.3 Changes in Stack Estimation Tools

This section explains the changes in the stack estimation tool (stack850).

3.3.1 Addition of compile option condition Specify “-Wi,-c” in the compiler when using the stack estimation tool. In PM plus, set “Any option” on the Others tab in the Compiler Options dialog box.

3.3.2 Addition of function pointer call display function “&” is now output when a function is called by a function pointer. func*&(N,M)

3.3.3 Addition of function specification option An -each-func option has been added. [Specification format] -each-func [ funcname …] The function is equal to that of the -func option. If this option is specified in combination with the -simple/-size option, however, information of the all specified functions is output.

3.3.4 Addition of stack amount addition option An -stk-callee option has been added. [Specification format] -stk-callee func:size The stack amount is calculated by adding the call of a function whose stack amount is size to func. Specify size using a decimal number.

20 4. CAUTIONS

Cautions on using V2.60 are described below.

4.1 Cautions on Installation

This section explains cautions on installing CA850 V2.60.

4.1.1 Caution on activating installer Insert the CD-ROM of CA850 V2.60 (Windows version) in the CD-ROM drive. The installer is started automatically. If it does not start automatically, execute “setup.exe” in the directory DISK1 under ca850 from Windows Explorer.

4.1.2 Caution on restarting computer Because it may be necessary to restart the computer after installation, terminate all other applications.

4.1.3 Caution on authority for installation Administrator right is required for installation of CA850 V2.60 in Windows NT, Windows 2000, or Windows XP.

4.1.4 Caution on installation directory Do not install CA850 V2.60 in a directory with a name containing a space; otherwise the development tools may not be correctly executed.

4.1.5 Caution on re-installation To re-install CA850 V2.60, uninstall the copy of CA850 V2.60 already installed. If this product is installed in a different directory without uninstalling the first copy of CA850 V2.60, the first copy of CA850 V2.60 already installed cannot be uninstalled.

4.1.6 Caution on file created at installation The following file will be created after CA850 V2.60 has been installed. This file is necessary for uninstalling CA850 V2.60 and must not be deleted (the installation destination is assumed to be C:\NECTools32). C: \NECTools32\SETUP\*.*

4.1.7 Caution on PM plus help The PM plus help is supplied in the HTML help format. If the help does not operate correctly, proceed as follows. • Install Microsoft Internet Explorer 5.0 or later (IE5.5 SP2 or later recommended)

4.1.8 Caution on language used in Windows CA850 V2.60 can be installed in the English Windows environment only.

21 If an attempt is made to install CA850 V2.60 in an environment other than English Windows, a message indicating a file transfer error is displayed and the installation is aborted. This situation also occurs if a language other than English is specified as the system language in the “Regional Settings Properties” tab.

4.2 Cautions on C Compiler

This section explains cautions on the C compiler.

4.2.1 Caution on debug information output option (-g) specification If a compiler option with an optimization level of -Og or higher is specified, the output codes differ depending on whether or not the debug information output option -g is specified. This is because the specification of -g suppresses the optimization processing for avoiding register hazards by making allowances for C source debugging.

4.2.2 r1 register used by interrupt function Since the assembler (as850) uses the r1 register as a temporary register when executing instruction expansion, the r1 register may be used during instruction expansion even if there is no description of the r1 register in the assembler source file. When describing an interrupt function in the assembler, therefore, first save/restore the r1 register.

4.2.3 User-defined function and interrupt disable/enable function The user cannot define a function whose name is already used by a function to disable/enable interrupts. If such a function is defined, the function called is the one provided by the compiler. In addition, no warning is output for such a function.

4.2.4 Caution on debug information If a function that starts or ends with #include is defined and the function is described in another source file, the correct debug information cannot be obtained. In addition, no debug information will be output for the code in a file specified by the .include or .binclude quasi directive, the code in a macro defined by the .macro quasi directive, and the section created using the .section quasi directive in the assembler source file.

4.3 Cautions on PM plus

This section explains cautions on PM plus.

4.3.1 Network environment PM plus does not support operation in a network environment. Do not use PM plus in a network environment.

4.3.2 Installation folder Be sure to install CA850 V2.60 in the folder in which other NEC Electronics tools are installed; 22 otherwise the tool may not be able to be activated.

4.3.3 2-byte code 2-byte codes cannot be used for the file or path name.

4.3.4 Installation of language tools If the compiler or assembler is not installed, the source file cannot be added in the [Source File] page opened from [Project Settings…] or in the [Step 6/8 [Setup Source Files]] dialog box opened by the [New WorkSpace…] or [Add New Project…] command.

4.3.5 Activation of SF850 When multiple source files are registered in a project (when the total number of characters of the source file names registered in the project exceeds 10,240 bytes), each output directory is specified, and the use of the section file generator is specified, data cannot be output to the make file correctly because the number of files to be output are too many, which disturbs execution of build.

4.3.6 When opening project file to specify a device that is not installed yet When a device name that is not installed in the host machine is specified in a project file and the project file is opened, if an attempt is made to find the device using the [Project Settings…] command in the [Project] menu, normally the device name is not displayed (blank). In the following cases, however, the device name at the top of the device list is displayed. • When [Project Settings…] in [Project] is selected after any device is registered using DFINST. • When any device is registered in the [Step 1/8 [Project Information]] dialog box opened from [Add New Project…] using DFINST In such cases, close the workspace first, install the device file used by the project, open the workspace (project) again, and execute the [Project Settings…] or [Add New Project…] command.

4.3.7 Specification of startup file If the item "Do Not specify now" is selected in the [Step 3/8 [Startup File]] dialog box opened by the [New WorkSpace…] or [Add New Project…] command, a source file is registered in [Step 6/8 [Setup Source Files]], the display is returned to [Step 3/8 [Startup File]] using the [Back] button, the file registered as the source file in Step 6/8 is specified as the startup file, and the [Finish] button is clicked in at the end of the settings, the following message is displayed, and the startup file is registered to both the source and project-related files. Linker Options ‘Startup file’ is illegal. In such a case, delete the startup file registered in the source file.

4.3.8 Link directive file to be created When a device with a 32 KB or more internal RAM is selected by the [Add New Project…] or [New WorkSpace…] command and “rx850” is selected in the [Step 2/8 [Select Real-Time OS]] dialog box, the item "Create and Use the sample file" is not supported in the [Step 5/8 [Link Directive File]] dialog box. Select an item other than "Create and Use the sample file"; otherwise an illegal link directive file will be created. 23

4.3.9 Editing configuration file In the [Step 2/8 [Select Real-Time OS]] dialog box opened by the [Add New Project…] or [New WorkSpace…] command, if the [RTOS Settings…] button and then the [Detail] button is clicked to open the [RX850 Settings] dialog box and if a configuration file is selected and the [Edit] button is clicked, the selected configuration file cannot be edited unless the previous three dialog boxes are closed (this means that the step to create a new workspace must be cancelled).

4.3.10 Location of source file The source file added by dragging on the project window is located at the end of the source file list, not next to the selected file. The order of the source files can be changed in the source file setting dialog box opened by the [Project Settings…] command in the [Project] menu.

4.3.11 Function name in Project window When a function name is edited in the Edit window and is updated in the Project window, if the change is cancelled using the [Undo]/[Redo] command, the function name is not updated even if the Project window is activated. The function name is updated by performing build or saving the file.

4.3.12 Project window display Up to 260 characters can be specified as a project group name or project title, but only the 259 characters can be displayed in the Project window.

4.3.13 Title of dialog box If there is no information required for PM plus in an opened project file, the project file must be updated. At this time, the dialog box with the title [Project Information] or [Source File], not [Project Settings], is displayed. This does not affect the actual operation, so made the project setting in this dialog box.

4.3.14 Addition of source file If "source file name + \" (e.g.: aaa.c\) is input to add a source file when CA850 V2.60 is used in Windows 98 or Windows Me, an error message is displayed but the file name in the message is not displayed correctly. Just close the error message to continue the operation.

4.3.15 Change of series name when creating a new workspace In the [Step 6/8 [Setup Source Files]] dialog box opened by the [Add New Project…] or [New WorkSpace…] command, if a source file is selected, Step 1/8 is returned to in order to change the series name, and the Step 6/8 is returned to again, a file that does not correspond to the new series (previously registered) remains in the source file list. Delete such a source file name from the source file list.

4.3.16 Smart lookup function When there is only one item in the list box displayed by the smart lookup function, the list box cannot be closed by pressing the up/down arrow key on the keyboard. Use the ESC key or Return key to close the list box.

24

4.3.17 Smart lookup function and automatic prototype generation function When a function name without a return value is described as shown below, a character on the previous line is recognized as the return value in the detailed display of the smart lookup function and in automatic prototype generation. In such a case, declare the function type. (Example) a.def main(){} The function is displayed as "def main();".

4.3.18 Automatic generation of function list, smart lookup function, and prototype declaration If a variable is declared between a function name and '{', it is not recognized as the function. Declare the argument type in the line in which the function is defined. (Example) int main( argc, argv[] ) int argc; char* argv[]; { } main is not regarded as a function.

4.3.19 Customization of keyboard The "Alt+A", "Alt+I", "Alt+Shift+A", "Alt+Shift+I" keys cannot be assigned in the keyboard page of customization.

4.3.20 Shortcut key display When a shortcut key is assigned to the [Object] menu, the assigned shortcut key is not displayed.

4.3.21 Applying layer rules When using the [Apply Layer Rule…] command in the [Layer] menu, the layer rule is not applied to the conditional compilation #elseif. Use #elif.

4.3.22 Font size of help The font size of the help menu is affected by the font settings in Internet Explorer. The display is too large in the default size (“Medium”) of Internet Explorer. Therefore, change the font size to “Smallest” in [Fonts] from the [View] menu and restart the help.

25 5. CORRECTION AND ADDITION OF RESTRICTIONS

5.1 Correction of CA850 Usage Restrictions

The following 14 restrictions have been corrected. Restriction No. 61 has been corrected partially.

5.1.1 Restriction on numeric value following preprocessing instruction (No.9) An error is not output for a numeric value described after a preprocessing instruction.

5.1.2 Restriction on illegal identifier following preprocessing instruction (No.10) An error is not output for an illegal identifier described after a preprocessing instruction.

5.1.3 Restriction on specifying type defined by union with struct (No.11) An error is not output even if a type defined by union is specified with struct.

5.1.4 Restriction on section file and global variable (No.19) A warning message may not be output even if a section mismatch occurs for a global variable in the section file and source file.

5.1.5 Restriction on describing only ‘∼ (tilde)’ in macro (No.36) The assembler is terminated abnormally if only ‘∼’ is described in a macro.

5.1.6 Restriction on ‘∼ (tilde)’ when macro is nested (No.37) ‘∼ (tilde)’ may cause an error when a macro is nested.

5.1.7 Restriction on initialization of variable (No.56) When any of the following conditions is satisfied, the following error message is output and compilation may be terminated. (1) There are many variable initializations (2) The program includes the debug information output option (-g) and variable initialization. A large amount of the following information is included • File name (including include file) • Function name • Variable name • Enumeration tag name and enumerator name • Structure tag name, union tag name, and member name • typedef name • Label name

5.1.8 Restriction on optimization of union of integer and pointer (No.80) When all the conditions shown below are satisfied, an error occurs in the optimization module and the optimization module is terminated without outputting an error message. This restriction is not applicable when the optimization module is terminated normally without causing an error. 26 (1) Optimization is specified. -Og, –O, -Os, or -Ot option (V2.50) -Os or -Ot option (V2.41 or earlier) (2) The union of a pointer and a 4-byte integer is included. (3) Optimization that propagates copying from the integer to the pointer in the basic block occurs for the union in (2). (4) The element propagated as a result of optimization in (3) is not an integer constant. (5) Indirect access by the pointer of the propagated address occurs or a structure transfer is performed.

5.1.9 Restriction on packed structure argument (No.81) An illegal stack frame is generated when all the conditions shown below are satisfied. The argument register area must be located at the top of the stack, but it is located in the middle of the stack. When a structure is specified as the return value, note that the argument in the following conditions is expressed in the format that the return value of the structure is inserted in the 1st argument, e.g., 1st argument = return value, 2nd argument = 1st argument of a function, 3rd argument = 2nd argument of a function. (1) The structure packing function is used. (The -Xpack option is used, or #pragma pack is described.) (2) Two or more packed structures with 5 or more bytes are specified for the argument of a function. (3) The function in (2) is not the variable argument function. (4) The packed structure specified for the 2nd or subsequent argument is located extending over the 16th and 17th byte boundary in the argument area of the stack frame.

Consequently, the structure of condition (4) is located at an illegal location and an illegal code will be output in response to the following accesses. • Access as the structure • Access of the structure member extending over the 16th and 17th byte boundary in the argument area of the stack frame.

5.1.10 Restriction on inline expansion of functions with structure as argument (No.83) The code corresponding to the argument is illegally deleted when all the following conditions are satisfied. (1) The function subject to inline expansion has a structure as an argument (2) The structure member of the argument used in the function in (1) satisfies the following conditions. <1> The member variable is either an array, structure, or union, and is defined as the second or later structure member <2> The member variable in <1> is used to access an array element. <3> The member variable does not use the object of the structure in <1> or other member variable. This bug does not occur even if all the conditions above are satisfied when structure packing is specified and the structure used as an argument is not aligned to 4 bytes.

5.1.11 Restriction on function pointer (No.84) An illegal value may be assigned to a function pointer when all the following conditions are satisfied. (1) A mask register is used (the -Xmask_reg option is specified.) 27 (2) 254 or more symbols of the function and variable are included in a single compilation (including extern symbols). • Function name • Variable name (3) A function pointer is used. (4) The address of a certain function is assigned to the function pointer in (3).

5.1.12 Restriction on embedded function __sasf() (No.85) An illegal code is output to __sasf() when all the following conditions are satisfied. (1) The V850E is specified as the device. (2) A mask register is used (the -Xmask_reg option is specified.) (3) The embedded function __sasf() is used. (4) The first argument of __sasf() is an unsigned short or unsigned char type variable allocated to tidata/tibss (5) The second argument of __sasf() is a conditional expression.

5.1.13 Restriction on conversion from float type to short/unsigned short type (No.86) An illegal code is output when all the conditions of (1) or (2) are satisfied. (1) <1> float type is converted into short/unsigned short type. <2> The value after the type conversion is referenced from multiple locations. <3> The first reference of <2> is assignment to memory. <4> The second or later reference of <2> is just assignment to a register.

(2) <1> float type is converted into short/unsigned short type. <2> The value after the type conversion is referenced from the multiple locations. <3> The first reference of <2> is assignment to memory. <4> The second or later reference of <2> is the operand of an expression <5> The debug information output option (-g) is specified.

5.1.14 Restriction on interrupt function (No.87) When all the following conditions are satisfied, the callt instruction to call run-time execution of a function prologue/epilogue is illegally output to an interrupt function, and the processing cannot be returned by reti. (1) The V850E is specified as the device. (2) Any of the following options is specified. <1> -Xpro_epi_runtime=on <2> Optimization option • -Os is specified (V2.41 or earlier) • Option other than -Ot is specified, or optimization is not specified (V2.50) (3) The interrupt function is used. (The function for which the __interrupt or __multi_interrupt qualifier is specified.) (4) The total size of the argument area, dynamic variable area, and register area for operation in a stack frame is smaller than 4 bytes or is 125 bytes or larger.

28 (The size can be confirmed by the value of ".R number" output at the end of the function in the assemble list.) (5) The compiler uses any of r25 to r29 or lp in the function and does not use r20 to r24.

Caution This bug does not occur when -Xpro_epi_runtime=off is specified.

5.1.15 Restriction on multiple byte characters in a command file (No.61) When a multiple byte character is used in the following command file, the CA850 fails to discriminate a descriptor in a character string, causing an error. (1) as850 Corrected in V2.60. (2) ar850 Corrected in V2.50. (3) dis850 (4) dump850 (5) hx850 Corrected in V2.50. (6) romp850 Corrected in V2.60.

5.2 Addition of Usage Restrictions in Other Package Tools

The following 2 restrictions have been added.

5.2.1 Restriction on replacement using regular expression in PM plus (No.1) With PM plus, if replacement processing of a character string is performed using the regular expression “^”, which indicates the line head, and “$”, which indicates the end of the line, the linefeed codes that exist before and after the relevant character string are included in the replacement target.

5.2.2 Restriction on square brackets in PM plus (No.2) With PM plus, if a square bracket (“[” or “]”) is used in the file name, path name, or project group name, the workspace cannot be loaded and individual options cannot be set.

29 6. LIST OF USAGE RESTRICTIONS IN CA850

This section explains restrictions applicable to V2.60 only. Since the numbers assigned to the restrictions have not been changed, the restriction numbers shown below are not consecutive.

6.1 List of Compiler Package Usage Restrictions

No. Bugs and Changes/Additions to Specifications

1 Restriction on file name including blank character 4 Restriction on precision during floating-point constant operation 6 Restriction on structure type conditional operator for argument of function 7 Restriction on indirect calling of function 8 Restriction on meaningless function definition 12 Restriction on extra ( ) in function declaration 13 Restriction on type definition of structure that includes extern 21 Restriction on section allocation 22 Restriction on section file with variable entity in assembly source 23 Restriction on section file with virtual definition of external variables of same name in multiple files 29 Restriction on specifying optimization option 30 Restriction on object size at optimization 31 Restriction on debugging at optimization 33 Restriction on address of structure member 34 Restriction on bit field 35 Restriction on .option nomacro quasi directive 40 Restriction on referencing specific symbol and reserved symbol in C source 47 Restriction on output file path specification option of cross- reference tool 48 Restriction on output file path specification option of memory layout visualization tool 59 Restriction on internal ROM check by ROMization processor 61 Restriction on multiple byte characters in a command file

6.2 Details of Compiler Package Usage Restrictions

No.1 Restriction on file name including blank character [Description] A file name or directory name including a blank character must not be used. [Workaround] Do not use a file name or directory name including a blank character. [Correction] Regard this as a restriction.

30 No.4 Restriction on precision during floating-point constant operation [Description] If a floating-point operation that may be inadvertently executed is described for compilation that involves casting to an integer, the precision drops very slightly, and the value may become illegal as a result of casting to an integer. No problem occurs if a floating point is handled as is. (Example) (long)(1.12 * 100); [Workaround] Change the above statement as follows. float f = 1.12; (long)(f * 100); Or, float f; (long)(f = 1.12 * 100); [Correction] Regard this as a restriction.

No.6 Restriction on structure type conditional operator for argument of function [Description] The correct branch code is not generated if a structure type conditional operator exists in an argument. (Example) typedef struct {int i;}S; S ss1, ss2; int j; void func(){ func_call( ( j > 10 ) ? ss1 : ss2 ); } [Workaround] Change the above statement as follows. if ( j > 10 ){ func_call( ss1 ); }else { func_call( ss2 ); } [Correction] Regard this as a restriction.

No.7 Restriction on indirect calling of function [Description] If an expression that indirectly calls a function requires an offset, an internal compiler error occurs. (Message) C2000: internal: gen_binary(): OP_CALL : left-child's operator is wrong (Example) struct S { int dummy; 31 int func_body[0x100]; } sobj; void f(){ ((void(*)())sobj.func_body)(); } [Workaround] Separate an offset calculation expression from a calling expression as follows. void f(){ void (*fp)() = (void(*)())&sobj.func_body; fp(); } [Correction] Regard this as a restriction.

No.8 Restriction on meaningless function definition [Description] An error is not output for a meaningless function definition. (Example) typedef int INTFN(); INTFN f { return (0); } [Workaround] Avoid the coding that corresponds to this restriction. [Correction] Regard this as a restriction.

No.12 Restriction on extra ( ) in function declaration [Description] A syntax error is output for an extra ( ) in a function declaration. (Example) typedef int Int; void f1((Int)); [Workaround] Modify the description as follows. typedef int Int; void f(Int); [Correction] Regard this as a restriction.

No.13 Restriction on type definition of structure that includes extern [Description] A syntax error is output for a type definition of a structure that includes extern. (Example) extern struct tag { int i; }; [Workaround] Remove extern. struct tag { int i;};

32 [Correction] Regard this as a restriction.

No.21 Restriction on section allocation [Description] In the tidata section allocation specification by the #pragma section directive or in “char type array of a structure” or “access to a char type member” specified by sf850 to be located in the tidata section, an error occurs in the linker if the displacement value of the sst instruction or sld instruction used to access the array or member is exceeded. [Workaround] Prevent the linker error in either of the following methods: 1) Do not use the char member or char array of a structure that causes the error in the linker. 2) Do not assign the char member or char array of a structure that causes the error in the linker to the tidata section. [Correction] Regard this as a restriction.

No.22 Restriction on section file with variable entity in assembly source [Description] In an application where the entity of a variable is in the assembly source and if that variable is referenced on the C source, an error occurs during linking if the section file is generated by sf850. [Workaround] Delete the variable in the assembly source from the section file. [Correction] Regard this as a restriction.

No.23 Restriction on section file with virtual definition of external variables of same name in multiple files [Description] If a section file is generated by sf850 when the virtual definition of external variables of the same name are in two or more files, symbols may be defined in duplicate during linking. (Message) ld850: fatal error: symbol “_xxxx” multiply defined. [Workaround] If two or more virtual definitions of external variables of the same name exist, be sure to declare extern in the file that references the external variables. [Correction] Regard this as a restriction.

No.29 Restriction on specifying optimization option [Description] If the optimization level of the optimization option specified during compilation is increased, the phases that are executed during compilation (such as the optimization function and compilation function)

33 increase. If the -Ot option is specified, the intermediate file created between these phases increases in size, causing a fatal error in some cases. [Workaround] Decrease the optimization level (by using -Os) and execute compilation. [Correction] Regard this as a restriction.

No.30 Restriction on object size at optimization [Description] When the optimization option is specified, the size of an object file including debug information may significantly increase. [Workaround] Either lower the optimization level or use the -g option, which outputs the debug information only to the file to be debugged. [Correction] Regard this as a restriction.

No.31 Restriction on debugging at optimization [Description] When the optimization option is specified for debugging the source, the following restrictions apply. a. When the value of a variable is referenced, a temporary value in the middle of calculation, not the correct value, may be obtained. b. If part of an array, element of a structure, or user-defined pointer variable is assigned to a register, variables may be illegally displayed or modified in the variable window of the debugger. c. If part of an array of an automatic variable or an element of structure is not used, the area may be deleted. In this case, variables may be illegally displayed or modified in the variable window of the debugger. The stack may be destroyed when a variable is modified. [Workaround] There is no workaround. [Correction] Regard this as a restriction.

No.33 Restriction on address of structure member [Description] The address of a structure member cannot be correctly obtained during structure packing. (Example) struct test { char c; /* offset 0 */ int i; /* offset 1-4 */ } test; int *ip, i; void func(){ i = *ip; }

34 void func2(){ ip = &(test.i); /* NG */ } [Workaround] There is no workaround. [Correction] Regard this as a restriction.

No.34 Restriction on bit field [Description] If the width of a bit field is less than the type of a member when the bit field is accessed during structure packing, the bit field is read by the type of the member. Consequently, an area outside the object (area where there is no data) is also accessed. This access is usually executed correctly but it may be illegal if I/Os are mapped. (Example) struct S { int x:21; } sobj; /* 3 bytes */ sobj.x = 1; [Workaround] There is no workaround. [Correction] Regard this as a restriction.

No.35 Restriction on .option nomacro quasi directive [Description] The mov instruction in the specified range of the .option nomacro quasi directive may result in a syntax error. (Example) .text .option nomacro mov 0x12345678, r10 [Workaround] Remove the corresponding mov instruction from the specified range of the .option nomacro quasi directive. [Correction] Regard this as a restriction.

No.40 Restriction on referencing specific symbol and reserved symbol in C source [Description] Target-specific symbols such as _gp_DATA and reserved symbols such as _stext cannot be referenced in the C source. [Workaround] Do not use a target-specific symbol and reserved symbol in the C source.

35 [Correction] Regard this as a restriction.

No.47 Restriction on output file path specification option of cross-reference tool [Description] Even if the folder to which the analysis result of a specified output file is to be output is specified by the path specification option (-o), the analysis result is not output to the specified folder but to the current folder (executed folder). If the -all option is specified, the -o option outputs the analysis result to the specified folder. [Workaround] Execute analysis in the folder to which the result is to be output. [Correction] Regard this as a restriction.

No.48 Restriction on output file path specification option of memory layout visualization tool [Description] Even if the folder to which the analysis result of a specified output file is to be output is specified by the path specification option (-o), the analysis result is not output to the specified folder but to the current folder (executed folder). If the -all option is specified, the -o option outputs the analysis result to the specified folder. [Workaround] Execute analysis in the folder to which the result is to be output. [Correction] Regard this as a restriction.

No.59 Restriction on internal ROM check by ROMization processor [Description] When using the ROMization processor (romp850), the following warning message is output when it should not be output, or not output when it should be output depending on the existence of a .text section or its allocated address. Note that the output object has no problem. (Message) Warning: rompsec section overflowed highest address of target machine. [Workaround] Refer to the map by using the -m option of the ROMization processor (romp850) and confirm that the rompsec section is not exceeding the internal ROM. If it is not exceeding the ROM, ignore the above warning message. [Correction] Regard this as a restriction.

No.61 Restriction on multiple byte characters in a command file [Description] When a multiple byte character is used in the following command file, the CA850 fails to discriminate a descriptor in a character string, causing an error. 36 (1) as850 Corrected in V2.60. (2) ar850 Corrected in V2.50. (3) dis850 (4) dump850 (5) hx850 Corrected in V2.50. (6) romp850 Corrected in V2.60. [Workaround] Do not use multiple byte characters in a command file. When using the project manager, do not use multiple byte characters for options, because they are specified by a command file. [Correction] Regard this as a restriction.

6.3 List of Usage Restrictions in Other Package Tools

No. Bugs and Changes/Additions to Specifications

1 Restriction on replacement using regular expression in PM plus 2 Restriction on square brackets in PM plus

No.1 Restriction on replacement using regular expression in PM plus [Description] With PM plus, if replacement processing of a character string is performed using the regular expression “^”, which indicates the line head, and “$”, which indicates the end of the line, the linefeed codes that exist before and after the relevant character string are included in the replacement target. [Workaround] Do not use a regular expression for replacement. [Correction] The command menu for replacement using a regular expression is dimmed and not selectable in V2.60.

No.2 Restriction on square brackets in PM plus [Description] With PM plus, if a square bracket (“[” or “]”) is used in the file name, path name, or project group name, the workspace cannot be loaded and individual options cannot be set. [Workaround] Do not use “[” or “]” for the file name, path name, or project group name. [Correction] Regard this as a restriction.

37