scc

simple c99 compiler
git clone git://git.simple-cc.org/scc
Log | Files | Refs | Submodules | README | LICENSE

i286.s (3167B)


      1 # Look in http://www.mlsite.net/8086/
      2 # Look in http://www.srmuniv.ac.in/sites/default/files/2017/15CS205J-unitII.pdf
      3 # Look in http://www.c-jump.com/CIS77/reference/Instructions_by_Opcode.html
      4 # Look in http://www.c-jump.com/CIS77/CPU/x86/lecture.html#X77_0020_encoding_overview
      5 # Look in https://www.felixcloutier.com/x86/index.html
      6 
      7 	ADDB	AL,AL			# 00 C0
      8 	ADDB	CL,AL			# 00 C8
      9 	ADDB	DL,AL			# 00 D0
     10 	ADDB	BL,AL			# 00 D8
     11 	ADDB	AH,AL			# 00 E0
     12 	ADDB	CH,AL			# 00 E8
     13 	ADDB	DH,AL			# 00 F0
     14 	ADDB	BH,AL			# 00 F8
     15 
     16 	ADDW	AX,AX			# 01 C0
     17 	ADDW	CX,AX			# 01 C8
     18 	ADDW	DX,AX			# 01 D0
     19 	ADDW	BX,AX			# 01 D8
     20 	ADDW	SP,AX			# 01 E0
     21 	ADDW	BP,AX			# 01 E8
     22 	ADDW	SI,AX			# 01 F0
     23 	ADDW	DI,AX			# 01 F8
     24 
     25 	ADDB	AL,CL			# 00 C1
     26 	ADDB	CL,CL			# 00 C9
     27 	ADDB	DL,CL			# 00 D1
     28 	ADDB	BL,CL			# 00 D9
     29 	ADDB	AH,CL			# 00 E1
     30 	ADDB	CH,CL			# 00 E9
     31 	ADDB	DH,CL			# 00 F1
     32 	ADDB	BH,CL			# 00 F9
     33 
     34 	ADDW	AX,CX			# 01 C1
     35 	ADDW	CX,CX			# 01 C9
     36 	ADDW	DX,CX			# 01 D1
     37 	ADDW	BX,CX			# 01 D9
     38 	ADDW	SP,CX			# 01 E1
     39 	ADDW	BP,CX			# 01 E9
     40 	ADDW	SI,CX			# 01 F1
     41 	ADDW	DI,CX			# 01 F9
     42 
     43 	ADDB	AL,DL			# 00 C2
     44 	ADDB	CL,DL			# 00 CA
     45 	ADDB	DL,DL			# 00 D2
     46 	ADDB	BL,DL			# 00 DA
     47 	ADDB	AH,DL			# 00 E2
     48 	ADDB	CH,DL			# 00 EA
     49 	ADDB	DH,DL			# 00 F2
     50 	ADDB	BH,DL			# 00 FA
     51 
     52 	ADDW	AX,DX			# 01 C2
     53 	ADDW	CX,DX			# 01 CA
     54 	ADDW	DX,DX			# 01 D2
     55 	ADDW	BX,DX			# 01 DA
     56 	ADDW	SP,DX			# 01 E2
     57 	ADDW	BP,DX			# 01 EA
     58 	ADDW	SI,DX			# 01 F2
     59 	ADDW	DI,DX			# 01 FA
     60 
     61 	ADDB	AL,BL			# 00 C3
     62 	ADDB	CL,BL			# 00 CB
     63 	ADDB	DL,BL			# 00 D3
     64 	ADDB	BL,BL			# 00 DB
     65 	ADDB	AH,BL			# 00 E3
     66 	ADDB	CH,BL			# 00 EB
     67 	ADDB	DH,BL			# 00 F3
     68 	ADDB	BH,BL			# 00 FB
     69 
     70 	ADDW	AX,BX			# 01 C3
     71 	ADDW	CX,BX			# 01 CB
     72 	ADDW	DX,BX			# 01 D3
     73 	ADDW	BX,BX			# 01 DB
     74 	ADDW	SP,BX			# 01 E3
     75 	ADDW	BP,BX			# 01 EB
     76 	ADDW	SI,BX			# 01 F3
     77 	ADDW	DI,BX			# 01 FB
     78 
     79 	ADDB	AL,AH			# 00 C4
     80 	ADDB	CL,AH			# 00 CC
     81 	ADDB	DL,AH			# 00 D4
     82 	ADDB	BL,AH			# 00 DC
     83 	ADDB	AH,AH			# 00 E4
     84 	ADDB	CH,AH			# 00 EC
     85 	ADDB	DH,AH			# 00 F4
     86 	ADDB	BH,AH			# 00 FC
     87 
     88 	ADDW	AX,SP			# 01 C4
     89 	ADDW	CX,SP			# 01 CC
     90 	ADDW	DX,SP			# 01 D4
     91 	ADDW	BX,SP			# 01 DC
     92 	ADDW	SP,SP			# 01 E4
     93 	ADDW	BP,SP			# 01 EC
     94 	ADDW	SI,SP			# 01 F4
     95 	ADDW	DI,SP			# 01 FC
     96 
     97 	ADDB	AL,CH			# 00 C5
     98 	ADDB	CL,CH			# 00 CD
     99 	ADDB	DL,CH			# 00 D5
    100 	ADDB	BL,CH			# 00 DD
    101 	ADDB	AH,CH			# 00 E5
    102 	ADDB	CH,CH			# 00 ED
    103 	ADDB	DH,CH			# 00 F5
    104 	ADDB	BH,CH			# 00 FD
    105 
    106 	ADDW	AX,BP			# 01 C5
    107 	ADDW	CX,BP			# 01 CD
    108 	ADDW	DX,BP			# 01 D5
    109 	ADDW	BX,BP			# 01 DD
    110 	ADDW	SP,BP			# 01 E5
    111 	ADDW	BP,BP			# 01 ED
    112 	ADDW	SI,BP			# 01 F5
    113 	ADDW	DI,BP			# 01 FD
    114 
    115 	ADDB	AL,DH			# 00 C6
    116 	ADDB	CL,DH			# 00 CE
    117 	ADDB	DL,DH			# 00 D6
    118 	ADDB	BL,DH			# 00 DE
    119 	ADDB	AH,DH			# 00 E6
    120 	ADDB	CH,DH			# 00 EE
    121 	ADDB	DH,DH			# 00 F6
    122 	ADDB	BH,DH			# 00 FE
    123 
    124 	ADDW	AX,SI			# 01 C6
    125 	ADDW	CX,SI			# 01 CE
    126 	ADDW	DX,SI			# 01 D6
    127 	ADDW	BX,SI			# 01 DE
    128 	ADDW	SP,SI			# 01 E6
    129 	ADDW	BP,SI			# 01 EE
    130 	ADDW	SI,SI			# 01 F6
    131 	ADDW	DI,SI			# 01 FE
    132 
    133 	ADDB	AL,BH			# 00 C7
    134 	ADDB	CL,BH			# 00 CF
    135 	ADDB	DL,BH			# 00 D7
    136 	ADDB	BL,BH			# 00 DF
    137 	ADDB	AH,BH			# 00 E7
    138 	ADDB	CH,BH			# 00 EF
    139 	ADDB	DH,BH			# 00 F7
    140 	ADDB	BH,BH			# 00 FF
    141 
    142 	ADDW	AX,DI			# 01 C7
    143 	ADDW	CX,DI			# 01 CF
    144 	ADDW	DX,DI			# 01 D7
    145 	ADDW	BX,DI			# 01 DF
    146 	ADDW	SP,DI			# 01 E7
    147 	ADDW	BP,DI			# 01 EF
    148 	ADDW	SI,DI			# 01 F7
    149 	ADDW	DI,DI			# 01 FF