CONTENTS

 

 

3.8

Build Task .....................................................................................................

36

 

3.8.1 Preparing a Build Task ..............................................................................

36

 

3.8.2 Building an Executable Object ..................................................................

36

 

3.8.3 Debugging ..................................................................................................

37

 

3.8.4 Executing Other Tools ................................................................................

38

3.9

Tool Option Settings .....................................................................................

40

 

3.9.1 Assembler Options .....................................................................................

40

 

3.9.2 Linker Options ...........................................................................................

41

 

3.9.3 Debugger Options ......................................................................................

43

 

3.9.4 HEX Converter Options .............................................................................

43

3.10

Work Bench Options .....................................................................................

44

3.11

Short-Cut Key List ........................................................................................

45

3.12

Error Messages ............................................................................................

45

3.13

Precautions ..................................................................................................

46

CHAPTER 4 ASSEMBLER ............................................................................................

47

4.1

Functions ......................................................................................................

47

4.2

Input/Output Files ........................................................................................

47

 

4.2.1 Input File ....................................................................................................

47

 

4.2.2 Output Files ................................................................................................

48

4.3

Starting Method ............................................................................................

49

4.4

Messages ......................................................................................................

50

4.5 Grammar of Assembly Source ......................................................................

51

 

4.5.1 Statements ..................................................................................................

51

 

4.5.2 Instructions (Mnemonics and Pseudo-instructions) ..................................

53

 

4.5.3 Symbols (Labels) ........................................................................................

54

 

4.5.4 Comments ...................................................................................................

56

 

4.5.5 Blank Lines ................................................................................................

56

 

4.5.6 Register Names ..........................................................................................

57

 

4.5.7 Numerical Notations ..................................................................................

57

 

4.5.8 Operators ...................................................................................................

58

 

4.5.9 Location Counter Symbol "$" ....................................................................

60

 

4.5.10 Optimization Branch Instructions for Old Preprocessor .........................

60

4.6

Section Management ....................................................................................

61

 

4.6.1 Definition of Sections .................................................................................

61

 

4.6.2 Absolute and Relocatable Sections ............................................................

61

 

4.6.3 Sample Definition of Sections ....................................................................

62

4.7

Assembler Pseudo-Instructions ....................................................................

63

 

4.7.1 Include Instruction (#include) ....................................................................

64

 

4.7.2 Define Instruction (#define) .......................................................................

65

 

4.7.3 Numeric Define Instruction (#defnum) ......................................................

67

 

4.7.4 Macro Instructions (#macro ... #endm) ......................................................

68

 

4.7.5 Conditional Assembly Instructions

 

 

(#ifdef ... #else ... #endif, #ifndef... #else ... #endif) ..................................

70

 

4.7.6 Section Defining Pseudo-Instructions (.code, .data, .bss) .........................

72

 

4.7.7 Location Defining Pseudo-Instructions (.org, .align) ................................

74

 

4.7.8 Absolute Assembling Pseudo-Instruction (.abs) ........................................

77

 

4.7.9 Symbol Defining Pseudo-Instruction (.set) ................................................

78

 

4.7.10 Data Defining Pseudo-Instructions (.codeword, .word) ..........................

79

 

4.7.11 Area Securing Pseudo-Instructions (.comm, .lcomm) ..............................

80

 

4.7.12 Global Declaration Pseudo-Instruction (.global) ....................................

81

 

4.7.13 List Control Pseudo-Instructions (.list, .nolist) ........................................

81

 

4.7.14 Source Debugging Information Pseudo-Instructions (.stabs, .stabn) ......

81

 

4.7.15 Comment Adding Function ......................................................................

82

 

4.7.16 Priority of Pseudo-Instructions ................................................................

82

iv

EPSON

S5U1C63000A MANUAL

 

 

(S1C63 FAMILY ASSEMBLER PACKAGE)