aasmcpu.pas 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675
  1. {
  2. Copyright (c) 1999-2009 by Mazen Neifer and David Zhang
  3. Contains the assembler object for the MIPSEL
  4. This program is free software; you can redistribute it and/or modify
  5. it under the terms of the GNU General Public License as published by
  6. the Free Software Foundation; either version 2 of the License, or
  7. (at your option) any later version.
  8. This program is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. GNU General Public License for more details.
  12. You should have received a copy of the GNU General Public License
  13. along with this program; if not, write to the Free Software
  14. Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  15. ****************************************************************************
  16. }
  17. unit aasmcpu;
  18. {$i fpcdefs.inc}
  19. interface
  20. uses
  21. cclasses,
  22. globtype, globals, verbose,
  23. aasmbase, aasmdata, aasmsym, aasmtai,
  24. cgbase, cgutils, cpubase, cpuinfo;
  25. const
  26. { "mov reg,reg" source operand number }
  27. O_MOV_SOURCE = 1;
  28. { "mov reg,reg" source operand number }
  29. O_MOV_DEST = 0;
  30. type
  31. { taicpu }
  32. taicpu = class(tai_cpu_abstract_sym)
  33. constructor op_none(op: tasmop);
  34. constructor op_reg(op: tasmop; _op1: tregister);
  35. constructor op_const(op: tasmop; _op1: longint);
  36. constructor op_ref(op: tasmop; const _op1: treference);
  37. constructor op_reg_reg(op: tasmop; _op1, _op2: tregister);
  38. constructor op_reg_ref(op: tasmop; _op1: tregister; const _op2: treference);
  39. constructor op_reg_const(op: tasmop; _op1: tregister; _op2: longint);
  40. constructor op_const_const(op: tasmop; _op1: aint; _op2: aint);
  41. constructor op_reg_reg_reg(op: tasmop; _op1, _op2, _op3: tregister);
  42. constructor op_reg_reg_ref(op: tasmop; _op1, _op2: tregister; const _op3: treference);
  43. constructor op_reg_reg_const(op: tasmop; _op1, _op2: tregister; _op3: aint);
  44. { INS and EXT }
  45. constructor op_reg_reg_const_const(op: tasmop; _op1,_op2: tregister; _op3,_op4: aint);
  46. constructor op_reg_const_reg(op: tasmop; _op1: tregister; _op2: aint; _op3: tregister);
  47. { this is for Jmp instructions }
  48. constructor op_sym(op: tasmop; _op1: tasmsymbol);
  49. constructor op_reg_reg_sym(op: tasmop; _op1, _op2: tregister; _op3: tasmsymbol);
  50. constructor op_reg_sym(op: tasmop; _op1: tregister; _op2: tasmsymbol);
  51. constructor op_sym_ofs(op: tasmop; _op1: tasmsymbol; _op1ofs: longint);
  52. { register allocation }
  53. function is_same_reg_move(regtype: Tregistertype): boolean; override;
  54. { register spilling code }
  55. function spilling_get_operation_type(opnr: longint): topertype; override;
  56. function is_macro: boolean;
  57. end;
  58. tai_align = class(tai_align_abstract)
  59. { nothing to add }
  60. end;
  61. procedure InitAsm;
  62. procedure DoneAsm;
  63. procedure fixup_jmps(list: TAsmList);
  64. function spilling_create_load(const ref: treference; r: tregister): taicpu;
  65. function spilling_create_store(r: tregister; const ref: treference): taicpu;
  66. implementation
  67. uses
  68. cutils;
  69. {*****************************************************************************
  70. taicpu Constructors
  71. *****************************************************************************}
  72. constructor taicpu.op_none(op: tasmop);
  73. begin
  74. inherited Create(op);
  75. end;
  76. constructor taicpu.op_reg(op: tasmop; _op1: tregister);
  77. begin
  78. inherited Create(op);
  79. ops := 1;
  80. loadreg(0, _op1);
  81. end;
  82. constructor taicpu.op_ref(op: tasmop; const _op1: treference);
  83. begin
  84. inherited Create(op);
  85. ops := 1;
  86. loadref(0, _op1);
  87. end;
  88. constructor taicpu.op_const(op: tasmop; _op1: longint);
  89. begin
  90. inherited Create(op);
  91. ops := 1;
  92. loadconst(0, _op1);
  93. end;
  94. constructor taicpu.op_reg_reg(op: tasmop; _op1, _op2: tregister);
  95. begin
  96. inherited Create(op);
  97. ops := 2;
  98. loadreg(0, _op1);
  99. loadreg(1, _op2);
  100. end;
  101. constructor taicpu.op_reg_const(op: tasmop; _op1: tregister; _op2: longint);
  102. begin
  103. inherited Create(op);
  104. ops := 2;
  105. loadreg(0, _op1);
  106. loadconst(1, _op2);
  107. end;
  108. constructor taicpu.op_const_const(op: tasmop; _op1: aint; _op2: aint);
  109. begin
  110. inherited Create(op);
  111. ops := 2;
  112. loadconst(0, _op1);
  113. loadconst(1, _op2);
  114. end;
  115. constructor taicpu.op_reg_ref(op: tasmop; _op1: tregister; const _op2: treference);
  116. begin
  117. inherited Create(op);
  118. ops := 2;
  119. loadreg(0, _op1);
  120. loadref(1, _op2);
  121. end;
  122. constructor taicpu.op_reg_reg_reg(op: tasmop; _op1, _op2, _op3: tregister);
  123. begin
  124. inherited Create(op);
  125. ops := 3;
  126. loadreg(0, _op1);
  127. loadreg(1, _op2);
  128. loadreg(2, _op3);
  129. end;
  130. constructor taicpu.op_reg_reg_ref(op: tasmop; _op1, _op2: tregister; const _op3: treference);
  131. begin
  132. inherited create(op);
  133. ops := 3;
  134. loadreg(0, _op1);
  135. loadreg(1, _op2);
  136. loadref(2, _op3);
  137. end;
  138. constructor taicpu.op_reg_reg_const(op: tasmop; _op1, _op2: tregister; _op3: aint);
  139. begin
  140. inherited create(op);
  141. ops := 3;
  142. loadreg(0, _op1);
  143. loadreg(1, _op2);
  144. loadconst(2, _op3);
  145. end;
  146. constructor taicpu.op_reg_reg_const_const(op: tasmop; _op1, _op2: tregister; _op3, _op4: aint);
  147. begin
  148. inherited create(op);
  149. ops := 4;
  150. loadreg(0, _op1);
  151. loadreg(1, _op2);
  152. loadconst(2, _op3);
  153. loadconst(3, _op4);
  154. end;
  155. constructor taicpu.op_reg_const_reg(op: tasmop; _op1: tregister; _op2: aint;
  156. _op3: tregister);
  157. begin
  158. inherited create(op);
  159. ops := 3;
  160. loadreg(0, _op1);
  161. loadconst(1, _op2);
  162. loadreg(2, _op3);
  163. end;
  164. constructor taicpu.op_sym(op: tasmop; _op1: tasmsymbol);
  165. begin
  166. inherited Create(op);
  167. is_jmp := op in [A_BC, A_BA];
  168. ops := 1;
  169. loadsymbol(0, _op1, 0);
  170. end;
  171. constructor taicpu.op_reg_reg_sym(op: tasmop; _op1, _op2: tregister; _op3: tasmsymbol);
  172. begin
  173. inherited create(op);
  174. is_jmp := op in [A_BC, A_BA];
  175. ops := 3;
  176. loadreg(0, _op1);
  177. loadreg(1, _op2);
  178. loadsymbol(2, _op3, 0);
  179. end;
  180. constructor taicpu.op_reg_sym(op: tasmop; _op1: tregister; _op2: tasmsymbol);
  181. begin
  182. inherited create(op);
  183. is_jmp := op in [A_BC, A_BA];
  184. ops := 2;
  185. loadreg(0, _op1);
  186. loadsymbol(1, _op2, 0);
  187. end;
  188. constructor taicpu.op_sym_ofs(op: tasmop; _op1: tasmsymbol; _op1ofs: longint);
  189. begin
  190. inherited Create(op);
  191. ops := 1;
  192. loadsymbol(0, _op1, _op1ofs);
  193. end;
  194. function taicpu.is_same_reg_move(regtype: Tregistertype): boolean;
  195. begin
  196. Result := (
  197. ((opcode = A_MOVE) and (regtype = R_INTREGISTER)) or
  198. ((regtype = R_FPUREGISTER) and (opcode in [A_MOV_S, A_MOV_D]))
  199. ) and
  200. (oper[0]^.reg = oper[1]^.reg);
  201. end;
  202. function taicpu.is_macro: boolean;
  203. begin
  204. result :=
  205. { 'seq', 'sge', 'sgeu', 'sgt', 'sgtu', 'sle', 'sleu', 'sne', }
  206. (opcode=A_SEQ) or (opcode=A_SGE) or (opcode=A_SGEU) or (opcode=A_SGT) or
  207. (opcode=A_SGTU) or (opcode=A_SLE) or (opcode=A_SLEU) or (opcode=A_SNE)
  208. { JAL is not here! See comments in TCGMIPS.a_call_name. }
  209. or (opcode=A_LA) or ((opcode=A_BC) and
  210. not (condition in [C_EQ,C_NE,C_GTZ,C_GEZ,C_LTZ,C_LEZ,C_COP1TRUE,C_COP1FALSE])) {or (op=A_JAL)}
  211. or (opcode=A_REM) or (opcode=A_REMU)
  212. { DIV and DIVU are normally macros, but use $zero as first arg to generate a CPU instruction. }
  213. or (((opcode=A_DIV) or (opcode=A_DIVU)) and
  214. ((ops<>3) or (oper[0]^.typ<>top_reg) or (oper[0]^.reg<>NR_R0)))
  215. or (opcode=A_MULO) or (opcode=A_MULOU)
  216. { A_LI is only a macro if the immediate is not in thez 16-bit range }
  217. or (opcode=A_LI);
  218. end;
  219. function taicpu.spilling_get_operation_type(opnr: longint): topertype;
  220. type
  221. op_write_set_type = set of TAsmOp;
  222. const
  223. op_write_set: op_write_set_type =
  224. [A_NEG,
  225. A_NEGU,
  226. A_LI,
  227. A_DLI,
  228. A_LA,
  229. A_MOVE,
  230. A_LB,
  231. A_LBU,
  232. A_LH,
  233. A_LHU,
  234. A_LW,
  235. A_LWU,
  236. A_LWL,
  237. A_LWR,
  238. A_LD,
  239. A_LDL,
  240. A_LDR,
  241. A_LL,
  242. A_LLD,
  243. A_ADDI,
  244. A_DADDI,
  245. A_ADDIU,
  246. A_DADDIU,
  247. A_SLTI,
  248. A_SLTIU,
  249. A_ANDI,
  250. A_ORI,
  251. A_XORI,
  252. A_LUI,
  253. A_DNEG,
  254. A_DNEGU,
  255. A_ADD,
  256. A_DADD,
  257. A_ADDU,
  258. A_DADDU,
  259. A_SUB,
  260. A_DSUB,
  261. A_SUBU,
  262. A_DSUBU,
  263. A_SLT,
  264. A_SLTU,
  265. A_AND,
  266. A_OR,
  267. A_XOR,
  268. A_NOR,
  269. { We can get into trouble if an instruction can be interpreted as
  270. macros with different operands. The following commented out ones
  271. refer to elementary instructions: DIV[U], MULT[U] do not modify
  272. first operand. Rest are subject to check. }
  273. A_MUL,
  274. A_MULO,
  275. A_MULOU,
  276. A_DMUL,
  277. A_DMULO,
  278. A_DMULOU,
  279. // A_DIV,
  280. // A_DIVU,
  281. A_DDIV,
  282. A_DDIVU,
  283. A_REM,
  284. A_REMU,
  285. A_DREM,
  286. A_DREMU,
  287. // A_MULT,
  288. A_DMULT,
  289. // A_MULTU,
  290. A_DMULTU,
  291. A_MFHI,
  292. A_MFLO,
  293. A_SLL,
  294. A_SRL,
  295. A_SRA,
  296. A_SLLV,
  297. A_SRLV,
  298. A_SRAV,
  299. A_DSLL,
  300. A_DSRL,
  301. A_DSRA,
  302. A_DSLLV,
  303. A_DSRLV,
  304. A_DSRAV,
  305. A_DSLL32,
  306. A_DSRL32,
  307. A_DSRA32,
  308. A_LWC1,
  309. A_LDC1,
  310. A_ADD_S,
  311. A_ADD_D,
  312. A_SUB_S,
  313. A_SUB_D,
  314. A_MUL_S,
  315. A_MUL_D,
  316. A_DIV_S,
  317. A_DIV_D,
  318. A_ABS_S,
  319. A_ABS_D,
  320. A_NEG_S,
  321. A_NEG_D,
  322. A_SQRT_S,
  323. A_SQRT_D,
  324. A_MOV_S,
  325. A_MOV_D,
  326. A_CVT_S_D,
  327. A_CVT_S_W,
  328. A_CVT_S_L,
  329. A_CVT_D_S,
  330. A_CVT_D_W,
  331. A_CVT_D_L,
  332. A_CVT_W_S,
  333. A_CVT_W_D,
  334. A_CVT_L_S,
  335. A_CVT_L_D,
  336. A_ROUND_W_S,
  337. A_ROUND_W_D,
  338. A_ROUND_L_S,
  339. A_ROUND_L_D,
  340. A_TRUNC_W_S,
  341. A_TRUNC_W_D,
  342. A_TRUNC_L_S,
  343. A_TRUNC_L_D,
  344. A_CEIL_W_S,
  345. A_CEIL_W_D,
  346. A_CEIL_L_S,
  347. A_CEIL_L_D,
  348. A_FLOOR_W_S,
  349. A_FLOOR_W_D,
  350. A_FLOOR_L_S,
  351. A_FLOOR_L_D,
  352. A_SEQ,
  353. A_SGE,
  354. A_SGEU,
  355. A_SGT,
  356. A_SGTU,
  357. A_SLE,
  358. A_SLEU,
  359. A_SNE,
  360. A_EXT,
  361. A_INS,
  362. A_MFC0,
  363. A_SEB,
  364. A_SEH];
  365. begin
  366. result := operand_read;
  367. case opcode of
  368. A_DIV, { these have 3 operands if used as macros }
  369. A_DIVU:
  370. if (ops=3) and (opnr=0) then
  371. result:=operand_write;
  372. else
  373. if opcode in op_write_set then
  374. if opnr = 0 then
  375. result := operand_write;
  376. end;
  377. end;
  378. function spilling_create_load(const ref: treference; r: tregister): taicpu;
  379. begin
  380. case getregtype(r) of
  381. R_INTREGISTER :
  382. result:=taicpu.op_reg_ref(A_LW,r,ref);
  383. R_FPUREGISTER :
  384. begin
  385. case getsubreg(r) of
  386. R_SUBFS :
  387. result:=taicpu.op_reg_ref(A_LWC1,r,ref);
  388. R_SUBFD :
  389. result:=taicpu.op_reg_ref(A_LDC1,r,ref);
  390. else
  391. internalerror(200401042);
  392. end;
  393. end
  394. else
  395. internalerror(200401041);
  396. end;
  397. end;
  398. function spilling_create_store(r: tregister; const ref: treference): taicpu;
  399. begin
  400. case getregtype(r) of
  401. R_INTREGISTER :
  402. result:=taicpu.op_reg_ref(A_SW,r,ref);
  403. R_FPUREGISTER :
  404. begin
  405. case getsubreg(r) of
  406. R_SUBFS :
  407. result:=taicpu.op_reg_ref(A_SWC1,r,ref);
  408. R_SUBFD :
  409. result:=taicpu.op_reg_ref(A_SDC1,r,ref);
  410. else
  411. internalerror(200401042);
  412. end;
  413. end
  414. else
  415. internalerror(200401041);
  416. end;
  417. end;
  418. procedure InitAsm;
  419. begin
  420. end;
  421. procedure DoneAsm;
  422. begin
  423. end;
  424. procedure fixup_jmps(list: TAsmList);
  425. var
  426. p,pdelayslot: tai;
  427. newjmp,newnoop: taicpu;
  428. labelpositions: TFPList;
  429. instrpos: ptrint;
  430. l: tasmlabel;
  431. again: boolean;
  432. insai: tai;
  433. procedure create_pic_load(ai: taicpu; insloc: tai);
  434. var
  435. href: treference;
  436. newins: taicpu;
  437. begin
  438. { validity of operand has been checked by caller }
  439. href:=ai.oper[ai.ops-1]^.ref^;
  440. href.refaddr:=addr_pic;
  441. href.base:=NR_GP;
  442. newins:=taicpu.op_reg_ref(A_LW,NR_PIC_FUNC,href);
  443. newins.fileinfo:=ai.fileinfo;
  444. list.insertbefore(newins,insloc);
  445. inc(instrpos,2);
  446. if (href.symbol.bind=AB_LOCAL) then
  447. begin
  448. href.refaddr:=addr_low;
  449. href.base:=NR_NO;
  450. newins:=taicpu.op_reg_reg_ref(A_ADDIU,NR_PIC_FUNC,NR_PIC_FUNC,href);
  451. newins.fileinfo:=ai.fileinfo;
  452. list.insertbefore(newins,insloc);
  453. inc(instrpos,2);
  454. end;
  455. end;
  456. begin
  457. // MIPS relative branch range is +-32K instructions, i.e +-128 kBytes
  458. // if certainly not enough instructions to cause an overflow, dont bother
  459. if (list.count<high(smallint)) then
  460. exit;
  461. labelpositions := TFPList.create;
  462. p := tai(list.first);
  463. instrpos := 1;
  464. // record label positions
  465. while assigned(p) do
  466. begin
  467. if p.typ = ait_label then
  468. begin
  469. if (tai_label(p).labsym.labelnr >= labelpositions.count) then
  470. labelpositions.count := tai_label(p).labsym.labelnr * 2;
  471. labelpositions[tai_label(p).labsym.labelnr] := pointer(instrpos);
  472. end;
  473. { ait_const is for jump tables }
  474. case p.typ of
  475. ait_instruction:
  476. { probleim here: pseudo-instructions can translate into
  477. several CPU instructions, possibly depending on assembler options,
  478. to obe on safe side, let's assume a mean of two. }
  479. inc(instrpos,2);
  480. ait_const:
  481. begin
  482. if (tai_const(p).consttype<>aitconst_32bit) then
  483. internalerror(2008052101);
  484. inc(instrpos);
  485. end;
  486. end;
  487. p := tai(p.next);
  488. end;
  489. { If the number of instructions is below limit, we can't overflow either }
  490. if (instrpos<high(smallint)) then
  491. exit;
  492. // check and fix distances
  493. repeat
  494. again := false;
  495. p := tai(list.first);
  496. instrpos := 1;
  497. while assigned(p) do
  498. begin
  499. case p.typ of
  500. ait_label:
  501. // update labelposition in case it changed due to insertion
  502. // of jumps
  503. begin
  504. // can happen because of newly inserted labels
  505. if (tai_label(p).labsym.labelnr > labelpositions.count) then
  506. labelpositions.count := tai_label(p).labsym.labelnr * 2;
  507. labelpositions[tai_label(p).labsym.labelnr] := pointer(instrpos);
  508. end;
  509. ait_instruction:
  510. begin
  511. inc(instrpos,2);
  512. case taicpu(p).opcode of
  513. A_BA,A_BC:
  514. if (taicpu(p).ops>0) and (taicpu(p).oper[taicpu(p).ops-1]^.typ=top_ref) and
  515. assigned(taicpu(p).oper[taicpu(p).ops-1]^.ref^.symbol) and
  516. (taicpu(p).oper[taicpu(p).ops-1]^.ref^.symbol is tasmlabel) and
  517. (labelpositions[tasmlabel(taicpu(p).oper[taicpu(p).ops-1]^.ref^.symbol).labelnr] <> NIL) and
  518. {$push}
  519. {$q-}
  520. (ptruint(abs(ptrint(labelpositions[tasmlabel(taicpu(p).oper[taicpu(p).ops-1]^.ref^.symbol).labelnr]-instrpos)) - low(smallint)) > ptruint((high(smallint) - low(smallint)))) then
  521. {$pop}
  522. begin
  523. if (taicpu(p).opcode=A_BC) then
  524. begin
  525. { we're adding a new label together with the only branch to it;
  526. providing exact label position is not necessary }
  527. current_asmdata.getjumplabel(l);
  528. pdelayslot:=tai(p.next);
  529. { We need to insert the new instruction after the delay slot instruction ! }
  530. while assigned(pdelayslot) and (pdelayslot.typ<>ait_instruction) do
  531. pdelayslot:=tai(pdelayslot.next);
  532. insai:=tai_label.create(l);
  533. list.insertafter(insai,pdelayslot);
  534. // add a new unconditional jump between this jump and the label
  535. list.insertbefore(tai_comment.create(strpnew('fixup_jmps, A_BXX changed into A_BNOTXX label;A_J;label:')),p);
  536. if (cs_create_pic in current_settings.moduleswitches) then
  537. begin
  538. create_pic_load(taicpu(p),insai);
  539. newjmp:=taicpu.op_reg(A_JR,NR_PIC_FUNC);
  540. end
  541. else
  542. begin
  543. newjmp:=taicpu.op_sym(A_J,taicpu(p).oper[2]^.ref^.symbol);
  544. newjmp.is_jmp := true;
  545. end;
  546. newjmp.fileinfo:=taicpu(p).fileinfo;
  547. list.insertbefore(newjmp,insai);
  548. inc(instrpos,2);
  549. { Add a delay slot for new A_J instruction }
  550. newnoop:=taicpu.op_none(A_NOP);
  551. newnoop.fileinfo := taicpu(p).fileinfo;
  552. list.insertbefore(newnoop,insai);
  553. inc(instrpos,2);
  554. // change the conditional jump to point to the newly inserted label
  555. tasmlabel(taicpu(p).oper[taicpu(p).ops-1]^.ref^.symbol).decrefs;
  556. taicpu(p).oper[taicpu(p).ops-1]^.ref^.symbol := l;
  557. l.increfs;
  558. // and invert its condition code
  559. taicpu(p).condition := inverse_cond(taicpu(p).condition);
  560. { skip inserted stuff and continue processing from 'pdelayslot' }
  561. p:=pdelayslot;
  562. again:=true;
  563. end
  564. else // opcode=A_BA
  565. begin
  566. if (cs_create_pic in current_settings.moduleswitches) then
  567. begin
  568. list.insertbefore(tai_comment.create(strpnew('fixup_jmps, A_BA changed into PIC sequence')),p);
  569. create_pic_load(taicpu(p),p);
  570. taicpu(p).opcode:=A_JR;
  571. taicpu(p).loadreg(0,NR_PIC_FUNC);
  572. again:=true;
  573. { inserted stuff before 'p', continue processing from 'p' on }
  574. end
  575. else
  576. begin
  577. list.insertbefore(tai_comment.create(strpnew('fixup_jmps, A_BA changed into A_J')),p);
  578. taicpu(p).opcode:=A_J;
  579. end;
  580. end;
  581. end;
  582. end;
  583. end;
  584. ait_const:
  585. inc(instrpos);
  586. end;
  587. p := tai(p.next);
  588. end;
  589. until not again;
  590. labelpositions.free;
  591. end;
  592. begin
  593. cai_cpu := taicpu;
  594. cai_align := tai_align;
  595. end.