Main
Page
Page
About This Manual
Manual Features
Reference Techniques
How to read
Related Manuals
Page
Table of Contents
Chapter 1 Getting Started
Chapter 2 Program Development Flow
Chapter 3 Introduction to Operation
Chapter 4 Optimization
Chapter 7 Types of Source Statements
Chapter 8 Writing Source Statements
Chapter 9 Writing Machine Language Instruction Statements and Directive Statements
Chapter 10 Writing Assembler Control Statements
Chapter 11 Writing Macro Control Statements
Chapter 12 List of Machine Language Instructions
Chapter 13 Error Messages
Chapter 14 Readinig List Files
Chapter 15 Using Library Manager
Chapter 16 Notes on Operating Environment
Page
Page
Page
1.2 Operating Environment
1.3 File Organization
Page
1.5 Setup
Setting command path
Start-up files
Start-up file format
Page
Page
1.6 File Conversion Utility
General command format
Options
Rules of output file name
Example of specifying options
Page
Page
2.2 Program Development Flow
Main development flow
Assembler and compiler
Source code debugger
2.3 Programming with Assembler
Required knowledge
MAKE
Program format
Programming style
Optimization
Conditional assembly
Macros
Debugging
Page
Page
3.1 Purpose of This Chapter
3.2 Files Used by Assembler and Linker
Figure 3-1 shows the inter-relationships of the files used by the assembler and linker.
Page
3.3 Basic Operation of Assembler and Linker
Create source files
Assemble
Link
Generate final list files
The contents of the final list file program1.lst are as follows.
Page
3.4 Assembling and Linking Multiple Sections
Create source files
Assemble and generate list files
Page
Page
Link
Parameter file during linking
Generate final list files
Page
program locations after linking
3.5 Conditional Assembly and Linking
Create source file
Assemble and link
Select false condition, assemble, and link
Specify assembly conditions in the command
Page
Page
Page
4.1 Purpose of This Chapter
Page
4.3 Usage Example
Optimization Instructions
Page
Page
Optimization processing
Optimization processing of conditional branch instructions
Optimization of function calls
Optimization of branches
Optimization of data transfer, arithmetic, logical, bit manipulation and user-defined instructions
Page
Example: branch destination of conditional branch instruction within range
Example: branch destination of conditional branch instruction out of range
Example: unconditional branch instruction converted to relative branch
Example: subroutine call converted to a relative branch
Page
Page
5.2 Starting Assembler
Specifying options
Summary of options
Page
5.3.1 Output File Options
Page
Page
Page
Page
Page
5.3.2 Error Message Options
Page
Page
Page
Page
Page
5.3.3 Preprocessor Options
Page
5.3.4 Program Generation Options
Page
5.3.5 Other Options
5.4 Operation Examples
Program assembly
Generation of final list file with resolved program addresses
Page
6.1 Purpose of This Chapter
6.2 Starting Linker
Specifying options
Page
Summary of Options
6.3 Command Options
6.3.1 Output File Options
Page
6.3.2 Error Message Options
Page
Page
Page
Page
Page
6.3.3 Program Generation Options
Section layout rules
Page
Page
Page
Page
6.3.4 Library File Options
Page
6.3.5 Other Options
Operational example
Page
Page
6.4.1 Structure of IRAM Support Executable File
Structural Elements of an IRAM Support Executable
Chapter 6 Using Linker
Instruction RAM Support 109
External memory
Program 1 Program 2
Executable file created by linker
File layout and transfer operations for an instruction RAM executable file
6.4.2 IRAM Support Options
Page
Page
6.4.3 Operation Examples
Assigning to different addresses in instruction RAM
Assignment to the same address in instruction RAM
Specifying an address for the instruction RAM program management table
Page
Page
7.1 Purpose of This Chapter
7.2 Program Format
Page
7.3 Machine Language Instruction Statements and Directive Statements
Machine language instruction statements
Directive statements
7.4 Assembler Control Statements
7.5 Macro Control Statements
7.6 Comment Statements
Page
Page
Page
Page
8.2 Permitted Characters
8.3 Numbers
Radices and allowed digits
Extended C language format
Intel format
Matsushita format
8.4 Character Constants
Character constants
String constants
8.5 Address Constants
8.6 Location Counter
8.7 Expressions
8.7.1 Operators
Arithmetic operators
Shift operators
Logical operators
8.7.2 Expression Evaluation
8.7.3 Expression Syntax
*
8.7.4 Expression Attributes
Operation result attributes
For ~, +, (unary) operators
For + (addition) operator
For - (subtraction) operator
For *, /, %, <<, >>, &, ^ , | operators
8.8 Reserved Words
Page
9.1 Purpose of This Chapter
9.2 Instruction Statement Fields
9.2.1 Writing Label Field
Coding examples
9.2.2 Writing Operation Field
9.2.3 Writing Operand Field
9.2.4 Writing Comment Field
9.3 Writing Machine Language Instruction Statements
Coding examples
9.4 Writing Directive Statements
List of directives
9.4.1 section
Section linking rules
Directive coding rules
9.4.2 align
Page
9.4.3 end
9.4.4 listoff, liston
9.4.5 notation
Page
9.4.6 org
9.4.7 opt
9.4.8 page
9.4.9 radix
9.4.10 dc
9.4.11 ds
Page
9.4.12 dw
9.4.13 dd
9.4.14 equ
Page
9.4.15 global
Page
9.4.16 tit
9.4.17 xlistoff, xliston
9.4.18 funcinfo
Directive Specification Rules
Page
9.4.19 assign
Usage examples
Page
Page
10.1 Purpose of This Chapter
Common coding rules
Page
10.2.1 #include
Page
Page
10.3.1 #define
10.3.2 #undef
10.4 Conditional Assembly
Page
10.4.1 #ifdef, #ifndef
Page
10.4.2 #if, #ifn
Page
10.4.3 #ifeq, #ifneq
Page
Page
10.4.4 #iflt, #ifle
Page
10.4.5 #ifgt, #ifge
Page
10.4.6 #ifb, #ifnb
Page
Page
Page
11.1 Purpose of This Chapter
Common coding rules
11.2 Macro Definitions (macro, endm)
Page
11.3 Macro Calls and Expansion
Page
11.4 Macro Operators
Page
11.5 Local Symbol Declaration (local)
An example using the local directive is shown below.
11.6 Forced Termination of Macro Expansion (exitm)
The list file is shown below. The second macro call has been expanded after #endif.
11.7 Purging Macro Definitions (purge)
11.8 rept
Page
11.9 irp
Page
11.10 irpc
Page
Page
Page
Page
12.2 Addressing Modes
Register indirect addressing
228 Addressing Modes
Register relative indirect addressing
2. An address register, An, or the stack pointer register, SP, plus a 32-bit displacement.
+
Addressing Modes 229
+
Absolute addressing
Absolute addressing specifies the address to be accessed as a 16-bit or 32-bit displacement.
230 Addressing Modes
Index addressing
+
12.3 List of Machine Language Instructions
12.3.1 Data Move Instructions
MOVE source to destination
Page
Page
Page
Page
12.3.2 Arithmetic Instructions
ADD
SUBTRACT with BORROW
ADD with CARRY
SUBTRACT
MULTIPLY
DIVIDE
COMPARE source with destination
INC
12.3.3 Logical Instructions
ARITHMETIC SHIFT RIGHT
LOGICAL SHIFT RIGHT
ROTATE LEFT
ARITHMETIC SHIFT LEFT
ROTATE RIGHT
12.3.4 Bit Manipulation Instructions
Bit operations
Page
12.3.5 Branching Instructions
CALL Subroutine
Unconditional BRANCH
Conditional BRANCH
Conditional BRANCH for LOOP
12.3.6 User-Defined Instructions
User Defined FUNCTION
Page
Page
13.1 Purpose of This Chapter
Page
13.2.1 Warning Messages
Page
13.2.2 Error Messages
Page
Page
13.2.3 Fatal Error Messages
Page
13.3.1 Warning Messages
13.3.2 Error Messages
Page
13.3.3 Fatal Error Messages
Page
Page
Page
Page
Page
14.2.1 Output Format of Machine Language Code
Location (Loc)
Machine language code (Object)
Machine language code supplemental information
Line number (Line)
Supplemental information
Source statement (Source)
14.2.2 Symbol Table
Symbol Value
Supplemental Information
Symbol Type
Symbol Name
Page
15.1 Purpose of This Chapter
15.2 Starting Library Manager
15.3 Command Options
15.3.1 Error Message Options
Page
Page
Page
Page
Page
15.3.2 Program Generation Options
Page
15.3.3 Functional Options
Page
Page
Page
Page
Page
15.3.4 Other Options
Page
15.4 Error Messages
How to read
15.4.1 Warning Messages
15.4.2 Error Messages
Page
15.4.3 Fatal Error Messages
Page
Page
Page
Page
16.2.2 Files
Page
16.2.4 Environment Settings
CONFIG.SIS
AUTOEXEC BAT
Start-up files
16.2.5 Differences From Workstation Versions
Command line differences
16.2.6 Error Correction Using Tag Jumps
Generate error file
Tag jumps
Fix errors
Return to error file
Page
17.1 Numeric Restrictions
Page
17.2.1 List of Assembler Command Options
Assembler command general format
Output file options
Error message options
Preprocessor options
Program generation options
Page
17.2.2 List of Linker Command Options
Linker command general format
Error message options
Output file options
Program generation options
Library file options
Instruction RAM options
Page
17.3 List of Assembler Directives
Directives for program control
Directives for symbols
Directives for data area allocation
Directives for list control
Other directives
17.4 List of Assembler Control Statements
Page
Index
Symbols
A
B
C
J
L
M
N
O
Page
Page
Page
SALES OFFICES
NORTH AMERICA
LATIN AMERICA
EUROPE
ASIA