ag386int.pas 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675
  1. {
  2. $Id$
  3. Copyright (c) 1996,97 by Florian Klaempfl
  4. This unit implements an asmoutput class for Intel syntax with Intel i386+
  5. This program is free software; you can redistribute it and/or modify
  6. it under the terms of the GNU General Public License as published by
  7. the Free Software Foundation; either version 2 of the License, or
  8. (at your option) any later version.
  9. This program is distributed in the hope that it will be useful,
  10. but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. GNU General Public License for more details.
  13. You should have received a copy of the GNU General Public License
  14. along with this program; if not, write to the Free Software
  15. Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  16. ****************************************************************************
  17. }
  18. unit ag386int;
  19. interface
  20. uses aasm,assemble;
  21. type
  22. pi386intasmlist=^ti386intasmlist;
  23. ti386intasmlist = object(tasmlist)
  24. procedure WriteTree(p:paasmoutput);virtual;
  25. procedure WriteAsmList;virtual;
  26. end;
  27. implementation
  28. uses
  29. dos,globals,systems,cobjects,i386,
  30. strings,files,verbose
  31. {$ifdef GDB}
  32. ,gdb
  33. {$endif GDB}
  34. ;
  35. const
  36. line_length = 70;
  37. extstr : array[EXT_NEAR..EXT_ABS] of String[8] =
  38. ('NEAR','FAR','PROC','BYTE','WORD','DWORD',
  39. 'CODEPTR','DATAPTR','FWORD','PWORD','QWORD','TBYTE','ABS');
  40. function double2str(d : double) : string;
  41. var
  42. hs : string;
  43. p : byte;
  44. begin
  45. str(d,hs);
  46. { nasm expects a lowercase e }
  47. p:=pos('E',hs);
  48. if p>0 then
  49. hs[p]:='e';
  50. p:=pos('+',hs);
  51. if p>0 then
  52. delete(hs,p,1);
  53. double2str:=lower(hs);
  54. end;
  55. function extended2str(e : extended) : string;
  56. var
  57. hs : string;
  58. p : byte;
  59. begin
  60. {$ifdef VER0_99_5}
  61. str(double(e),hs);
  62. {$else}
  63. str(e,hs);
  64. {$endif}
  65. { nasm expects a lowercase e }
  66. p:=pos('E',hs);
  67. if p>0 then
  68. hs[p]:='e';
  69. p:=pos('+',hs);
  70. if p>0 then
  71. delete(hs,p,1);
  72. extended2str:=lower(hs);
  73. end;
  74. function comp2str(d : bestreal) : string;
  75. type
  76. pdouble = ^double;
  77. var
  78. c : comp;
  79. dd : pdouble;
  80. begin
  81. {$ifdef TP}
  82. c:=d;
  83. {$else}
  84. c:=comp(d);
  85. {$endif}
  86. dd:=pdouble(@c); { this makes a bitwise copy of c into a double }
  87. comp2str:=double2str(dd^);
  88. end;
  89. function getreferencestring(const ref : treference) : string;
  90. var
  91. s : string;
  92. first : boolean;
  93. begin
  94. if ref.isintvalue then
  95. s:= tostr(ref.offset)
  96. else
  97. with ref do
  98. begin
  99. first:=true;
  100. if ref.segment<>R_DEFAULT_SEG then
  101. s:=int_reg2str[segment]+':['
  102. else
  103. s:='[';
  104. if assigned(symbol) then
  105. begin
  106. s:=s+symbol^;
  107. first:=false;
  108. end;
  109. if (base<>R_NO) then
  110. begin
  111. if not(first) then
  112. s:=s+'+'
  113. else
  114. first:=false;
  115. s:=s+int_reg2str[base];
  116. end;
  117. if (index<>R_NO) then
  118. begin
  119. if not(first) then
  120. s:=s+'+'
  121. else
  122. first:=false;
  123. s:=s+int_reg2str[index];
  124. if scalefactor<>0 then
  125. s:=s+'*'+tostr(scalefactor);
  126. end;
  127. if offset<0 then
  128. s:=s+tostr(offset)
  129. else if (offset>0) then
  130. s:=s+'+'+tostr(offset);
  131. s:=s+']';
  132. end;
  133. getreferencestring:=s;
  134. end;
  135. function getopstr(t : byte;o : pointer;s : topsize; _operator: tasmop;dest : boolean) : string;
  136. var
  137. hs : string;
  138. begin
  139. case t of
  140. top_reg : getopstr:=int_reg2str[tregister(o)];
  141. top_const,
  142. top_ref : begin
  143. if t=top_const then
  144. hs := tostr(longint(o))
  145. else
  146. hs:=getreferencestring(preference(o)^);
  147. { can possibly give a range check error under tp }
  148. { if using in... }
  149. if ((_operator <> A_LGS) and (_operator <> A_LSS) and
  150. (_operator <> A_LFS) and (_operator <> A_LDS) and
  151. (_operator <> A_LES)) then
  152. Begin
  153. case s of
  154. S_B : hs:='byte ptr '+hs;
  155. S_W : hs:='word ptr '+hs;
  156. S_L : hs:='dword ptr '+hs;
  157. S_IS : hs:='word ptr '+hs;
  158. S_IL : hs:='dword ptr '+hs;
  159. S_IQ : hs:='qword ptr '+hs;
  160. S_FS : hs:='dword ptr '+hs;
  161. S_FL : hs:='qword ptr '+hs;
  162. S_FX : hs:='tbyte ptr '+hs;
  163. S_BW : if dest then
  164. hs:='word ptr '+hs
  165. else
  166. hs:='byte ptr '+hs;
  167. S_BL : if dest then
  168. hs:='dword ptr '+hs
  169. else
  170. hs:='byte ptr '+hs;
  171. S_WL : if dest then
  172. hs:='dword ptr '+hs
  173. else
  174. hs:='word ptr '+hs;
  175. end;
  176. end;
  177. getopstr:=hs;
  178. end;
  179. top_symbol : begin
  180. hs[0]:=chr(strlen(pchar(pcsymbol(o)^.symbol)));
  181. move(pchar(pcsymbol(o)^.symbol)^,hs[1],byte(hs[0]));
  182. hs:='offset '+hs;
  183. if pcsymbol(o)^.offset>0 then
  184. hs:=hs+'+'+tostr(pcsymbol(o)^.offset)
  185. else
  186. if pcsymbol(o)^.offset<0 then
  187. hs:=hs+tostr(pcsymbol(o)^.offset);
  188. getopstr:=hs;
  189. end;
  190. else
  191. internalerror(10001);
  192. end;
  193. end;
  194. function getopstr_jmp(t : byte;o : pointer) : string;
  195. var
  196. hs : string;
  197. begin
  198. case t of
  199. top_reg : getopstr_jmp:=int_reg2str[tregister(o)];
  200. top_ref : getopstr_jmp:=getreferencestring(preference(o)^);
  201. top_const : getopstr_jmp:=tostr(longint(o));
  202. top_symbol : begin
  203. hs[0]:=chr(strlen(pchar(pcsymbol(o)^.symbol)));
  204. move(pchar(pcsymbol(o)^.symbol)^,hs[1],byte(hs[0]));
  205. if pcsymbol(o)^.offset>0 then
  206. hs:=hs+'+'+tostr(pcsymbol(o)^.offset)
  207. else
  208. if pcsymbol(o)^.offset<0 then
  209. hs:=hs+tostr(pcsymbol(o)^.offset);
  210. getopstr_jmp:=hs;
  211. end;
  212. else
  213. internalerror(10001);
  214. end;
  215. end;
  216. {****************************************************************************
  217. TI386INTASMLIST
  218. ****************************************************************************}
  219. var
  220. LastSec : tsection;
  221. const
  222. ait_const2str:array[ait_const_32bit..ait_const_8bit] of string[8]=
  223. (#9'DD'#9,#9'DW'#9,#9'DB'#9);
  224. ait_section2masmstr : array[tsection] of string[6]=
  225. ('','CODE','DATA','BSS','');
  226. Function PadTabs(p:pchar;addch:char):string;
  227. var
  228. s : string;
  229. i : longint;
  230. begin
  231. i:=strlen(p);
  232. if addch<>#0 then
  233. begin
  234. inc(i);
  235. s:=StrPas(p)+addch;
  236. end
  237. else
  238. s:=StrPas(p);
  239. if i<8 then
  240. PadTabs:=s+#9#9
  241. else
  242. PadTabs:=s+#9;
  243. end;
  244. procedure ti386intasmlist.WriteTree(p:paasmoutput);
  245. type
  246. twowords=record
  247. word1,word2:word;
  248. end;
  249. var
  250. s,
  251. prefix,
  252. suffix : string;
  253. hp : pai;
  254. counter,
  255. lines,
  256. i,j,l : longint;
  257. consttyp : tait;
  258. found,
  259. quoted : boolean;
  260. begin
  261. if not assigned(p) then
  262. exit;
  263. hp:=pai(p^.first);
  264. while assigned(hp) do
  265. begin
  266. case hp^.typ of
  267. ait_comment : Begin
  268. AsmWrite(target_asm.comment);
  269. AsmWritePChar(pai_asm_comment(hp)^.str);
  270. AsmLn;
  271. End;
  272. ait_regalloc,
  273. ait_regdealloc :;
  274. ait_section : begin
  275. if LastSec<>sec_none then
  276. AsmWriteLn('_'+ait_section2masmstr[LastSec]+#9#9'ENDS');
  277. if pai_section(hp)^.sec<>sec_none then
  278. begin
  279. AsmLn;
  280. AsmWriteLn('_'+ait_section2masmstr[pai_section(hp)^.sec]+#9#9+
  281. 'SEGMENT'#9'PARA PUBLIC USE32 '''+
  282. ait_section2masmstr[pai_section(hp)^.sec]+'''');
  283. end;
  284. LastSec:=pai_section(hp)^.sec;
  285. end;
  286. ait_align : begin
  287. { CAUSES PROBLEMS WITH THE SEGMENT DEFINITION }
  288. { SEGMENT DEFINITION SHOULD MATCH TYPE OF ALIGN }
  289. { HERE UNDER TASM! }
  290. AsmWriteLn(#9'ALIGN '+tostr(pai_align(hp)^.aligntype));
  291. end;
  292. ait_external : AsmWriteLn(#9'EXTRN'#9+StrPas(pai_external(hp)^.name)+
  293. ' :'+extstr[pai_external(hp)^.exttyp]);
  294. ait_datablock : begin
  295. if pai_datablock(hp)^.is_global then
  296. AsmWriteLn(#9'PUBLIC'#9+StrPas(pai_datablock(hp)^.name));
  297. AsmWriteLn(PadTabs(pai_datablock(hp)^.name,#0)+'DB'#9+tostr(pai_datablock(hp)^.size)+' DUP(?)');
  298. end;
  299. ait_const_32bit,
  300. ait_const_8bit,
  301. ait_const_16bit : begin
  302. AsmWrite(ait_const2str[hp^.typ]+tostr(pai_const(hp)^.value));
  303. consttyp:=hp^.typ;
  304. l:=0;
  305. repeat
  306. found:=(not (Pai(hp^.next)=nil)) and (Pai(hp^.next)^.typ=consttyp);
  307. if found then
  308. begin
  309. hp:=Pai(hp^.next);
  310. s:=','+tostr(pai_const(hp)^.value);
  311. AsmWrite(s);
  312. inc(l,length(s));
  313. end;
  314. until (not found) or (l>line_length);
  315. AsmLn;
  316. end;
  317. ait_const_symbol : begin
  318. AsmWrite(#9#9+'DD '#9'offset ');
  319. AsmWritePChar(pchar(pai_const(hp)^.value));
  320. AsmLn;
  321. end;
  322. ait_const_symbol_offset : begin
  323. AsmWrite(#9#9+'DD '#9'offset ');
  324. AsmWritePChar(pai_const_symbol_offset(hp)^.name);
  325. if pai_const_symbol_offset(hp)^.offset>0 then
  326. AsmWrite('+'+tostr(pai_const_symbol_offset(hp)^.offset))
  327. else if pai_const_symbol_offset(hp)^.offset<0 then
  328. AsmWrite(tostr(pai_const_symbol_offset(hp)^.offset));
  329. AsmLn;
  330. end;
  331. ait_real_32bit : AsmWriteLn(#9#9'DD'#9+double2str(pai_single(hp)^.value));
  332. ait_real_64bit : AsmWriteLn(#9#9'DQ'#9+double2str(pai_double(hp)^.value));
  333. ait_real_extended : AsmWriteLn(#9#9'DT'#9+extended2str(pai_extended(hp)^.value));
  334. ait_comp : AsmWriteLn(#9#9'DQ'#9+comp2str(pai_extended(hp)^.value));
  335. ait_string : begin
  336. counter := 0;
  337. lines := pai_string(hp)^.len div line_length;
  338. { separate lines in different parts }
  339. if pai_string(hp)^.len > 0 then
  340. Begin
  341. for j := 0 to lines-1 do
  342. begin
  343. AsmWrite(#9#9'DB'#9);
  344. quoted:=false;
  345. for i:=counter to counter+line_length do
  346. begin
  347. { it is an ascii character. }
  348. if (ord(pai_string(hp)^.str[i])>31) and
  349. (ord(pai_string(hp)^.str[i])<128) and
  350. (pai_string(hp)^.str[i]<>'"') then
  351. begin
  352. if not(quoted) then
  353. begin
  354. if i>counter then
  355. AsmWrite(',');
  356. AsmWrite('"');
  357. end;
  358. AsmWrite(pai_string(hp)^.str[i]);
  359. quoted:=true;
  360. end { if > 31 and < 128 and ord('"') }
  361. else
  362. begin
  363. if quoted then
  364. AsmWrite('"');
  365. if i>counter then
  366. AsmWrite(',');
  367. quoted:=false;
  368. AsmWrite(tostr(ord(pai_string(hp)^.str[i])));
  369. end;
  370. end; { end for i:=0 to... }
  371. if quoted then AsmWrite('"');
  372. AsmWrite(target_os.newline);
  373. counter := counter+line_length;
  374. end; { end for j:=0 ... }
  375. { do last line of lines }
  376. AsmWrite(#9#9'DB'#9);
  377. quoted:=false;
  378. for i:=counter to pai_string(hp)^.len-1 do
  379. begin
  380. { it is an ascii character. }
  381. if (ord(pai_string(hp)^.str[i])>31) and
  382. (ord(pai_string(hp)^.str[i])<128) and
  383. (pai_string(hp)^.str[i]<>'"') then
  384. begin
  385. if not(quoted) then
  386. begin
  387. if i>counter then
  388. AsmWrite(',');
  389. AsmWrite('"');
  390. end;
  391. AsmWrite(pai_string(hp)^.str[i]);
  392. quoted:=true;
  393. end { if > 31 and < 128 and " }
  394. else
  395. begin
  396. if quoted then
  397. AsmWrite('"');
  398. if i>counter then
  399. AsmWrite(',');
  400. quoted:=false;
  401. AsmWrite(tostr(ord(pai_string(hp)^.str[i])));
  402. end;
  403. end; { end for i:=0 to... }
  404. if quoted then
  405. AsmWrite('"');
  406. end;
  407. AsmLn;
  408. end;
  409. ait_label : begin
  410. if pai_label(hp)^.l^.is_used then
  411. begin
  412. AsmWrite(lab2str(pai_label(hp)^.l));
  413. if (assigned(hp^.next) and not(pai(hp^.next)^.typ in
  414. [ait_const_32bit,ait_const_16bit,ait_const_8bit,
  415. ait_const_symbol,ait_const_symbol_offset,
  416. ait_real_32bit,ait_real_64bit,ait_real_extended,ait_string])) then
  417. AsmWriteLn(':');
  418. end;
  419. end;
  420. ait_direct : begin
  421. AsmWritePChar(pai_direct(hp)^.str);
  422. AsmLn;
  423. end;
  424. ait_labeled_instruction : AsmWriteLn(#9#9+int_op2str[pai_labeled(hp)^._operator]+#9+lab2str(pai_labeled(hp)^.lab));
  425. ait_symbol : begin
  426. if pai_symbol(hp)^.is_global then
  427. AsmWriteLn(#9'PUBLIC'#9+StrPas(pai_symbol(hp)^.name));
  428. AsmWritePChar(pai_symbol(hp)^.name);
  429. if assigned(hp^.next) and not(pai(hp^.next)^.typ in
  430. [ait_const_32bit,ait_const_16bit,ait_const_8bit,
  431. ait_const_symbol,ait_const_symbol_offset,
  432. ait_real_64bit,ait_real_extended,ait_string]) then
  433. AsmWriteLn(':')
  434. end;
  435. ait_instruction : begin
  436. suffix:='';
  437. prefix:= '';
  438. { added prefix instructions, must be on same line as opcode }
  439. if (pai386(hp)^.op1t = top_none) and
  440. ((pai386(hp)^._operator = A_REP) or
  441. (pai386(hp)^._operator = A_LOCK) or
  442. (pai386(hp)^._operator = A_REPE) or
  443. (pai386(hp)^._operator = A_REPNE)) then
  444. Begin
  445. prefix:=int_op2str[pai386(hp)^._operator]+#9;
  446. hp:=Pai(hp^.next);
  447. { this is theorically impossible... }
  448. if hp=nil then
  449. begin
  450. s:=#9#9+prefix;
  451. AsmWriteLn(s);
  452. break;
  453. end;
  454. end
  455. else
  456. prefix:= '';
  457. if pai386(hp)^.op1t<>top_none then
  458. begin
  459. if pai386(hp)^._operator in [A_CALL] then
  460. begin
  461. { with tasm call near ptr [edi+12] does not
  462. work but call near [edi+12] works ?? (PM)
  463. It works with call dword ptr [], but you
  464. need /m2 (2 passes) with tasm (PFV)
  465. }
  466. { if pai386(hp)^.op1t=top_ref then
  467. s:='near '+getopstr_jmp(pai386(hp)^.op1t,pai386(hp)^.op1)
  468. else
  469. s:='near ptr '+getopstr_jmp(pai386(hp)^.op1t,pai386(hp)^.op1);}
  470. s:='dword ptr '+getopstr_jmp(pai386(hp)^.op1t,pai386(hp)^.op1);
  471. end
  472. else
  473. begin
  474. s:=getopstr(pai386(hp)^.op1t,pai386(hp)^.op1,pai386(hp)^.size,pai386(hp)^._operator,false);
  475. if pai386(hp)^.op3t<>top_none then
  476. begin
  477. if pai386(hp)^.op2t<>top_none then
  478. s:=getopstr(pai386(hp)^.op2t,pointer(longint(twowords(pai386(hp)^.op2).word1)),
  479. pai386(hp)^.size,pai386(hp)^._operator,true)+','+s;
  480. s:=getopstr(pai386(hp)^.op3t,pointer(longint(twowords(pai386(hp)^.op2).word2)),
  481. pai386(hp)^.size,pai386(hp)^._operator,false)+','+s;
  482. end
  483. else
  484. if pai386(hp)^.op2t<>top_none then
  485. s:=getopstr(pai386(hp)^.op2t,pai386(hp)^.op2,pai386(hp)^.size,
  486. pai386(hp)^._operator,true)+','+s;
  487. end;
  488. s:=#9+s;
  489. end
  490. else
  491. begin
  492. { check if string instruction }
  493. { long form, otherwise may give range check errors }
  494. { in turbo pascal... }
  495. if ((pai386(hp)^._operator = A_CMPS) or
  496. (pai386(hp)^._operator = A_INS) or
  497. (pai386(hp)^._operator = A_OUTS) or
  498. (pai386(hp)^._operator = A_SCAS) or
  499. (pai386(hp)^._operator = A_STOS) or
  500. (pai386(hp)^._operator = A_MOVS) or
  501. (pai386(hp)^._operator = A_LODS) or
  502. (pai386(hp)^._operator = A_XLAT)) then
  503. Begin
  504. case pai386(hp)^.size of
  505. S_B: suffix:='b';
  506. S_W: suffix:='w';
  507. S_L: suffix:='d';
  508. else
  509. Message(assem_f_invalid_suffix_intel);
  510. end;
  511. end;
  512. s:='';
  513. end;
  514. AsmWriteLn(#9#9+prefix+int_op2str[pai386(hp)^._operator]+suffix+s);
  515. end;
  516. {$ifdef GDB}
  517. ait_stabn,
  518. ait_stabs,
  519. ait_stab_function_name : ;
  520. {$endif GDB}
  521. else
  522. internalerror(10000);
  523. end;
  524. hp:=pai(hp^.next);
  525. end;
  526. end;
  527. procedure ti386intasmlist.WriteAsmList;
  528. begin
  529. {$ifdef EXTDEBUG}
  530. if assigned(current_module^.mainsource) then
  531. comment(v_info,'Start writing intel-styled assembler output for '+current_module^.mainsource^);
  532. {$endif}
  533. LastSec:=sec_none;
  534. AsmWriteLn(#9'.386p');
  535. AsmWriteLn(#9'LOCALS '+target_asm.labelprefix);
  536. AsmWriteLn('DGROUP'#9'GROUP'#9'_BSS,_DATA');
  537. AsmWriteLn(#9'ASSUME'#9'CS:_CODE,ES:DGROUP,DS:DGROUP,SS:DGROUP');
  538. AsmLn;
  539. countlabelref:=false;
  540. WriteTree(externals);
  541. { INTEL ASM doesn't support stabs
  542. WriteTree(debuglist);}
  543. WriteTree(codesegment);
  544. WriteTree(datasegment);
  545. WriteTree(consts);
  546. WriteTree(rttilist);
  547. WriteTree(bsssegment);
  548. countlabelref:=true;
  549. AsmWriteLn(#9'END');
  550. AsmLn;
  551. {$ifdef EXTDEBUG}
  552. if assigned(current_module^.mainsource) then
  553. comment(v_info,'Done writing intel-styled assembler output for '+current_module^.mainsource^);
  554. {$endif EXTDEBUG}
  555. end;
  556. end.
  557. {
  558. $Log$
  559. Revision 1.17 1998-10-12 12:20:40 pierre
  560. + added tai_const_symbol_offset
  561. for r : pointer = @var.field;
  562. * better message for different arg names on implementation
  563. of function
  564. Revision 1.16 1998/10/06 17:16:33 pierre
  565. * some memory leaks fixed (thanks to Peter for heaptrc !)
  566. Revision 1.15 1998/10/01 20:19:06 jonas
  567. + ait_marker support
  568. Revision 1.14 1998/09/20 17:11:21 jonas
  569. * released REGALLOC
  570. Revision 1.13 1998/08/10 15:49:38 peter
  571. * small fixes for 0.99.5
  572. Revision 1.12 1998/08/08 10:19:17 florian
  573. * small fixes to write the extended type correct
  574. Revision 1.11 1998/06/05 17:46:02 peter
  575. * tp doesn't like comp() typecast
  576. Revision 1.10 1998/05/25 17:11:36 pierre
  577. * firstpasscount bug fixed
  578. now all is already set correctly the first time
  579. under EXTDEBUG try -gp to skip all other firstpasses
  580. it works !!
  581. * small bug fixes
  582. - for smallsets with -dTESTSMALLSET
  583. - some warnings removed (by correcting code !)
  584. Revision 1.9 1998/05/23 01:20:55 peter
  585. + aktasmmode, aktoptprocessor, aktoutputformat
  586. + smartlink per module $SMARTLINK-/+ (like MMX) and moved to aktswitches
  587. + $LIBNAME to set the library name where the unit will be put in
  588. * splitted cgi386 a bit (codeseg to large for bp7)
  589. * nasm, tasm works again. nasm moved to ag386nsm.pas
  590. Revision 1.8 1998/05/06 18:36:53 peter
  591. * tai_section extended with code,data,bss sections and enumerated type
  592. * ident 'compiled by FPC' moved to pmodules
  593. * small fix for smartlink
  594. Revision 1.7 1998/05/06 08:38:32 pierre
  595. * better position info with UseTokenInfo
  596. UseTokenInfo greatly simplified
  597. + added check for changed tree after first time firstpass
  598. (if we could remove all the cases were it happen
  599. we could skip all firstpass if firstpasscount > 1)
  600. Only with ExtDebug
  601. Revision 1.6 1998/05/04 17:54:24 peter
  602. + smartlinking works (only case jumptable left todo)
  603. * redesign of systems.pas to support assemblers and linkers
  604. + Unitname is now also in the PPU-file, increased version to 14
  605. Revision 1.5 1998/05/01 07:43:52 florian
  606. + basics for rtti implemented
  607. + switch $m (generate rtti for published sections)
  608. Revision 1.4 1998/04/29 10:33:41 pierre
  609. + added some code for ansistring (not complete nor working yet)
  610. * corrected operator overloading
  611. * corrected nasm output
  612. + started inline procedures
  613. + added starstarn : use ** for exponentiation (^ gave problems)
  614. + started UseTokenInfo cond to get accurate positions
  615. Revision 1.3 1998/04/08 16:58:01 pierre
  616. * several bugfixes
  617. ADD ADC and AND are also sign extended
  618. nasm output OK (program still crashes at end
  619. and creates wrong assembler files !!)
  620. procsym types sym in tdef removed !!
  621. Revision 1.2 1998/04/08 11:34:17 peter
  622. * nasm works (linux only tested)
  623. }