psystem.pas 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556
  1. {
  2. $Id$
  3. Copyright (c) 1998-2002 by Florian Klaempfl
  4. Load the system unit, create required defs for systemunit
  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 psystem;
  19. {$i fpcdefs.inc}
  20. interface
  21. uses
  22. symbase;
  23. procedure insertinternsyms(p : tsymtable);
  24. procedure insert_intern_types(p : tsymtable);
  25. procedure readconstdefs;
  26. procedure createconstdefs;
  27. procedure registernodes;
  28. procedure registertais;
  29. implementation
  30. uses
  31. globals,globtype,
  32. symconst,symtype,symsym,symdef,symtable,
  33. aasmtai,aasmcpu,
  34. {$ifdef GDB}
  35. gdb,
  36. {$endif GDB}
  37. node,nbas,nflw,nset,ncon,ncnv,nld,nmem,ncal,nmat,nadd,ninl,nopt;
  38. procedure insertinternsyms(p : tsymtable);
  39. {
  40. all intern procedures for the system unit
  41. }
  42. begin
  43. p.insert(tsyssym.create('Concat',in_concat_x));
  44. p.insert(tsyssym.create('Write',in_write_x));
  45. p.insert(tsyssym.create('WriteLn',in_writeln_x));
  46. p.insert(tsyssym.create('Assigned',in_assigned_x));
  47. p.insert(tsyssym.create('Read',in_read_x));
  48. p.insert(tsyssym.create('ReadLn',in_readln_x));
  49. p.insert(tsyssym.create('Ofs',in_ofs_x));
  50. p.insert(tsyssym.create('SizeOf',in_sizeof_x));
  51. p.insert(tsyssym.create('TypeOf',in_typeof_x));
  52. p.insert(tsyssym.create('Low',in_low_x));
  53. p.insert(tsyssym.create('High',in_high_x));
  54. p.insert(tsyssym.create('Seg',in_seg_x));
  55. p.insert(tsyssym.create('Ord',in_ord_x));
  56. p.insert(tsyssym.create('Pred',in_pred_x));
  57. p.insert(tsyssym.create('Succ',in_succ_x));
  58. p.insert(tsyssym.create('Exclude',in_exclude_x_y));
  59. p.insert(tsyssym.create('Include',in_include_x_y));
  60. p.insert(tsyssym.create('Break',in_break));
  61. p.insert(tsyssym.create('Exit',in_exit));
  62. p.insert(tsyssym.create('Continue',in_continue));
  63. p.insert(tsyssym.create('Dec',in_dec_x));
  64. p.insert(tsyssym.create('Inc',in_inc_x));
  65. p.insert(tsyssym.create('Str',in_str_x_string));
  66. p.insert(tsyssym.create('Assert',in_assert_x_y));
  67. p.insert(tsyssym.create('Val',in_val_x));
  68. p.insert(tsyssym.create('Addr',in_addr_x));
  69. p.insert(tsyssym.create('TypeInfo',in_typeinfo_x));
  70. p.insert(tsyssym.create('SetLength',in_setlength_x));
  71. p.insert(tsyssym.create('Finalize',in_finalize_x));
  72. p.insert(tsyssym.create('Length',in_length_x));
  73. p.insert(tsyssym.create('New',in_new_x));
  74. p.insert(tsyssym.create('Dispose',in_dispose_x));
  75. end;
  76. procedure insert_intern_types(p : tsymtable);
  77. {
  78. all the types inserted into the system unit
  79. }
  80. function addtype(const s:string;const t:ttype):ttypesym;
  81. begin
  82. result:=ttypesym.create(s,t);
  83. p.insert(result);
  84. { add init/final table if required }
  85. if t.def.needs_inittable then
  86. generate_inittable(result);
  87. end;
  88. procedure adddef(const s:string;def:tdef);
  89. var
  90. t : ttype;
  91. begin
  92. t.setdef(def);
  93. p.insert(ttypesym.create(s,t));
  94. end;
  95. var
  96. { several defs to simulate more or less C++ objects for GDB }
  97. vmttype,
  98. vmtarraytype : ttype;
  99. vmtsymtable : tsymtable;
  100. begin
  101. { Normal types }
  102. if (cs_fp_emulation in aktmoduleswitches) then
  103. begin
  104. addtype('Single',s32floattype);
  105. { extended size is the best real type for the target }
  106. addtype('Real',s32floattype);
  107. pbestrealtype:=@s32floattype;
  108. end
  109. else
  110. begin
  111. addtype('Single',s32floattype);
  112. addtype('Double',s64floattype);
  113. { extended size is the best real type for the target }
  114. addtype('Extended',pbestrealtype^);
  115. addtype('Real',s64floattype);
  116. end;
  117. {$ifdef x86}
  118. adddef('Comp',tfloatdef.create(s64comp));
  119. {$endif x86}
  120. addtype('Currency',s64currencytype);
  121. addtype('Pointer',voidpointertype);
  122. addtype('FarPointer',voidfarpointertype);
  123. addtype('ShortString',cshortstringtype);
  124. addtype('LongString',clongstringtype);
  125. addtype('AnsiString',cansistringtype);
  126. addtype('WideString',cwidestringtype);
  127. addtype('Boolean',booltype);
  128. addtype('ByteBool',booltype);
  129. adddef('WordBool',torddef.create(bool16bit,0,1));
  130. adddef('LongBool',torddef.create(bool32bit,0,1));
  131. addtype('Char',cchartype);
  132. addtype('WideChar',cwidechartype);
  133. adddef('Text',tfiledef.createtext);
  134. addtype('Cardinal',u32bittype);
  135. addtype('QWord',cu64bittype);
  136. addtype('Int64',cs64bittype);
  137. adddef('TypedFile',tfiledef.createtyped(voidtype));
  138. addtype('Variant',cvarianttype);
  139. { Internal types }
  140. addtype('$formal',cformaltype);
  141. addtype('$void',voidtype);
  142. addtype('$byte',u8bittype);
  143. addtype('$word',u16bittype);
  144. addtype('$ulong',u32bittype);
  145. addtype('$longint',s32bittype);
  146. addtype('$qword',cu64bittype);
  147. addtype('$int64',cs64bittype);
  148. addtype('$char',cchartype);
  149. addtype('$widechar',cwidechartype);
  150. addtype('$shortstring',cshortstringtype);
  151. addtype('$longstring',clongstringtype);
  152. addtype('$ansistring',cansistringtype);
  153. addtype('$widestring',cwidestringtype);
  154. addtype('$openshortstring',openshortstringtype);
  155. addtype('$boolean',booltype);
  156. addtype('$void_pointer',voidpointertype);
  157. addtype('$char_pointer',charpointertype);
  158. addtype('$void_farpointer',voidfarpointertype);
  159. addtype('$openchararray',openchararraytype);
  160. addtype('$file',cfiletype);
  161. addtype('$variant',cvarianttype);
  162. addtype('$s32real',s32floattype);
  163. addtype('$s64real',s64floattype);
  164. addtype('$s80real',s80floattype);
  165. addtype('$s64currency',s64currencytype);
  166. { Add a type for virtual method tables }
  167. vmtsymtable:=trecordsymtable.create;
  168. vmttype.setdef(trecorddef.create(vmtsymtable));
  169. pvmttype.setdef(tpointerdef.create(vmttype));
  170. vmtsymtable.insert(tvarsym.create('$parent',pvmttype));
  171. vmtsymtable.insert(tvarsym.create('$length',s32bittype));
  172. vmtsymtable.insert(tvarsym.create('$mlength',s32bittype));
  173. vmtarraytype.setdef(tarraydef.create(0,1,s32bittype));
  174. tarraydef(vmtarraytype.def).elementtype:=voidpointertype;
  175. vmtsymtable.insert(tvarsym.create('$__pfn',vmtarraytype));
  176. addtype('$__vtbl_ptr_type',vmttype);
  177. addtype('$pvmt',pvmttype);
  178. vmtarraytype.setdef(tarraydef.create(0,1,s32bittype));
  179. tarraydef(vmtarraytype.def).elementtype:=pvmttype;
  180. addtype('$vtblarray',vmtarraytype);
  181. { Add functions that require compiler magic }
  182. insertinternsyms(p);
  183. end;
  184. procedure readconstdefs;
  185. {
  186. Load all default definitions for consts from the system unit
  187. }
  188. begin
  189. globaldef('byte',u8bittype);
  190. globaldef('word',u16bittype);
  191. globaldef('ulong',u32bittype);
  192. globaldef('longint',s32bittype);
  193. globaldef('qword',cu64bittype);
  194. globaldef('int64',cs64bittype);
  195. globaldef('formal',cformaltype);
  196. globaldef('void',voidtype);
  197. globaldef('char',cchartype);
  198. globaldef('widechar',cwidechartype);
  199. globaldef('shortstring',cshortstringtype);
  200. globaldef('longstring',clongstringtype);
  201. globaldef('ansistring',cansistringtype);
  202. globaldef('widestring',cwidestringtype);
  203. globaldef('openshortstring',openshortstringtype);
  204. globaldef('openchararray',openchararraytype);
  205. globaldef('s32real',s32floattype);
  206. globaldef('s64real',s64floattype);
  207. globaldef('s80real',s80floattype);
  208. globaldef('s64currency',s64currencytype);
  209. globaldef('boolean',booltype);
  210. globaldef('void_pointer',voidpointertype);
  211. globaldef('char_pointer',charpointertype);
  212. globaldef('void_farpointer',voidfarpointertype);
  213. globaldef('file',cfiletype);
  214. globaldef('pvmt',pvmttype);
  215. globaldef('variant',cvarianttype);
  216. {$ifdef i386}
  217. ordpointertype:=u32bittype;
  218. {$endif i386}
  219. {$ifdef x86_64}
  220. ordpointertype:=cu64bittype;
  221. {$endif x86_64}
  222. {$ifdef powerpc}
  223. ordpointertype:=u32bittype;
  224. {$endif powerpc}
  225. {$ifdef sparc}
  226. ordpointertype:=u32bittype;
  227. {$endif sparc}
  228. {$ifdef m68k}
  229. ordpointertype:=u32bittype;
  230. {$endif}
  231. end;
  232. procedure createconstdefs;
  233. {
  234. Create all default definitions for consts for the system unit
  235. }
  236. var
  237. oldregisterdef : boolean;
  238. begin
  239. { create definitions for constants }
  240. oldregisterdef:=registerdef;
  241. registerdef:=false;
  242. cformaltype.setdef(tformaldef.create);
  243. voidtype.setdef(torddef.create(uvoid,0,0));
  244. u8bittype.setdef(torddef.create(u8bit,0,255));
  245. u16bittype.setdef(torddef.create(u16bit,0,65535));
  246. u32bittype.setdef(torddef.create(u32bit,0,high(cardinal)));
  247. s32bittype.setdef(torddef.create(s32bit,low(longint),high(longint)));
  248. cu64bittype.setdef(torddef.create(u64bit,low(qword),TConstExprInt(high(qword))));
  249. cs64bittype.setdef(torddef.create(s64bit,low(int64),high(int64)));
  250. booltype.setdef(torddef.create(bool8bit,0,1));
  251. cchartype.setdef(torddef.create(uchar,0,255));
  252. cwidechartype.setdef(torddef.create(uwidechar,0,65535));
  253. cshortstringtype.setdef(tstringdef.createshort(255));
  254. { should we give a length to the default long and ansi string definition ?? }
  255. clongstringtype.setdef(tstringdef.createlong(-1));
  256. cansistringtype.setdef(tstringdef.createansi(-1));
  257. cwidestringtype.setdef(tstringdef.createwide(-1));
  258. { length=0 for shortstring is open string (needed for readln(string) }
  259. openshortstringtype.setdef(tstringdef.createshort(0));
  260. openchararraytype.setdef(tarraydef.create(0,-1,s32bittype));
  261. tarraydef(openchararraytype.def).elementtype:=cchartype;
  262. {$ifdef x86}
  263. {$ifdef i386}
  264. ordpointertype:=u32bittype;
  265. {$endif i386}
  266. {$ifdef x86_64}
  267. ordpointertype:=cu64bittype;
  268. {$endif x86_64}
  269. s32floattype.setdef(tfloatdef.create(s32real));
  270. s64floattype.setdef(tfloatdef.create(s64real));
  271. s80floattype.setdef(tfloatdef.create(s80real));
  272. {$endif x86}
  273. {$ifdef powerpc}
  274. ordpointertype:=u32bittype;
  275. s32floattype.setdef(tfloatdef.create(s32real));
  276. s64floattype.setdef(tfloatdef.create(s64real));
  277. s80floattype.setdef(tfloatdef.create(s80real));
  278. {$endif powerpc}
  279. {$ifdef sparc}
  280. ordpointertype:=u32bittype;
  281. s32floattype.setdef(tfloatdef.create(s32real));
  282. s64floattype.setdef(tfloatdef.create(s64real));
  283. s80floattype.setdef(tfloatdef.create(s80real));
  284. {$endif sparc}
  285. {$ifdef m68k}
  286. ordpointertype:=u32bittype;
  287. s32floattype.setdef(tfloatdef.create(s32real));
  288. s64floattype.setdef(tfloatdef.create(s64real));
  289. s80floattype.setdef(tfloatdef.create(s80real));
  290. {$endif}
  291. s64currencytype.setdef(tfloatdef.create(s64currency));
  292. { some other definitions }
  293. voidpointertype.setdef(tpointerdef.create(voidtype));
  294. charpointertype.setdef(tpointerdef.create(cchartype));
  295. voidfarpointertype.setdef(tpointerdef.createfar(voidtype));
  296. cfiletype.setdef(tfiledef.createuntyped);
  297. cvarianttype.setdef(tvariantdef.create);
  298. registerdef:=oldregisterdef;
  299. end;
  300. procedure registernodes;
  301. {
  302. Register all possible nodes in the nodeclass array that
  303. will be used for loading the nodes from a ppu
  304. }
  305. begin
  306. nodeclass[addn]:=caddnode;
  307. nodeclass[muln]:=caddnode;
  308. nodeclass[subn]:=caddnode;
  309. nodeclass[divn]:=cmoddivnode;
  310. nodeclass[symdifn]:=caddnode;
  311. nodeclass[modn]:=cmoddivnode;
  312. nodeclass[assignn]:=cassignmentnode;
  313. nodeclass[loadn]:=cloadnode;
  314. nodeclass[rangen]:=crangenode;
  315. nodeclass[ltn]:=caddnode;
  316. nodeclass[lten]:=caddnode;
  317. nodeclass[gtn]:=caddnode;
  318. nodeclass[gten]:=caddnode;
  319. nodeclass[equaln]:=caddnode;
  320. nodeclass[unequaln]:=caddnode;
  321. nodeclass[inn]:=cinnode;
  322. nodeclass[orn]:=caddnode;
  323. nodeclass[xorn]:=caddnode;
  324. nodeclass[shrn]:=cshlshrnode;
  325. nodeclass[shln]:=cshlshrnode;
  326. nodeclass[slashn]:=caddnode;
  327. nodeclass[andn]:=caddnode;
  328. nodeclass[subscriptn]:=csubscriptnode;
  329. nodeclass[derefn]:=cderefnode;
  330. nodeclass[addrn]:=caddrnode;
  331. nodeclass[doubleaddrn]:=cdoubleaddrnode;
  332. nodeclass[ordconstn]:=cordconstnode;
  333. nodeclass[typeconvn]:=ctypeconvnode;
  334. nodeclass[calln]:=ccallnode;
  335. nodeclass[callparan]:=ccallparanode;
  336. nodeclass[realconstn]:=crealconstnode;
  337. nodeclass[unaryminusn]:=cunaryminusnode;
  338. nodeclass[asmn]:=casmnode;
  339. nodeclass[vecn]:=cvecnode;
  340. nodeclass[pointerconstn]:=cpointerconstnode;
  341. nodeclass[stringconstn]:=cstringconstnode;
  342. nodeclass[funcretn]:=cfuncretnode;
  343. nodeclass[selfn]:=cselfnode;
  344. nodeclass[notn]:=cnotnode;
  345. nodeclass[inlinen]:=cinlinenode;
  346. nodeclass[niln]:=cnilnode;
  347. nodeclass[errorn]:=cerrornode;
  348. nodeclass[typen]:=ctypenode;
  349. nodeclass[hnewn]:=chnewnode;
  350. nodeclass[hdisposen]:=chdisposenode;
  351. nodeclass[setelementn]:=csetelementnode;
  352. nodeclass[setconstn]:=csetconstnode;
  353. nodeclass[blockn]:=cblocknode;
  354. nodeclass[statementn]:=cstatementnode;
  355. nodeclass[ifn]:=cifnode;
  356. nodeclass[breakn]:=cbreaknode;
  357. nodeclass[continuen]:=ccontinuenode;
  358. nodeclass[whilerepeatn]:=cwhilerepeatnode;
  359. nodeclass[forn]:=cfornode;
  360. nodeclass[exitn]:=cexitnode;
  361. nodeclass[withn]:=cwithnode;
  362. nodeclass[casen]:=ccasenode;
  363. nodeclass[labeln]:=clabelnode;
  364. nodeclass[goton]:=cgotonode;
  365. nodeclass[tryexceptn]:=ctryexceptnode;
  366. nodeclass[raisen]:=craisenode;
  367. nodeclass[tryfinallyn]:=ctryfinallynode;
  368. nodeclass[onn]:=connode;
  369. nodeclass[isn]:=cisnode;
  370. nodeclass[asn]:=casnode;
  371. nodeclass[caretn]:=caddnode;
  372. nodeclass[failn]:=cfailnode;
  373. nodeclass[starstarn]:=caddnode;
  374. nodeclass[procinlinen]:=cprocinlinenode;
  375. nodeclass[arrayconstructorn]:=carrayconstructornode;
  376. nodeclass[arrayconstructorrangen]:=carrayconstructorrangenode;
  377. nodeclass[tempcreaten]:=ctempcreatenode;
  378. nodeclass[temprefn]:=ctemprefnode;
  379. nodeclass[tempdeleten]:=ctempdeletenode;
  380. nodeclass[addoptn]:=caddnode;
  381. nodeclass[nothingn]:=cnothingnode;
  382. nodeclass[loadvmtn]:=cloadvmtnode;
  383. nodeclass[guidconstn]:=cguidconstnode;
  384. nodeclass[rttin]:=crttinode;
  385. end;
  386. procedure registertais;
  387. {
  388. Register all possible tais in the taiclass array that
  389. will be used for loading the tais from a ppu
  390. }
  391. begin
  392. aiclass[ait_none]:=nil;
  393. aiclass[ait_align]:=tai_align;
  394. aiclass[ait_section]:=tai_section;
  395. aiclass[ait_comment]:=tai_comment;
  396. aiclass[ait_direct]:=tai_direct;
  397. aiclass[ait_string]:=tai_string;
  398. aiclass[ait_instruction]:=taicpu;
  399. aiclass[ait_datablock]:=tai_datablock;
  400. aiclass[ait_symbol]:=tai_symbol;
  401. aiclass[ait_symbol_end]:=tai_symbol_end;
  402. aiclass[ait_label]:=tai_label;
  403. aiclass[ait_const_32bit]:=tai_const;
  404. aiclass[ait_const_16bit]:=tai_const;
  405. aiclass[ait_const_8bit]:=tai_const;
  406. aiclass[ait_const_symbol]:=tai_const_symbol;
  407. aiclass[ait_const_rva]:=tai_const_symbol;
  408. aiclass[ait_real_32bit]:=tai_real_32bit;
  409. aiclass[ait_real_64bit]:=tai_real_64bit;
  410. aiclass[ait_real_80bit]:=tai_real_80bit;
  411. aiclass[ait_comp_64bit]:=tai_comp_64bit;
  412. {$ifdef GDB}
  413. aiclass[ait_stabn]:=tai_stabn;
  414. aiclass[ait_stabs]:=tai_stabs;
  415. aiclass[ait_force_line]:=tai_force_line;
  416. aiclass[ait_stab_function_name]:=tai_stab_function_name;
  417. {$endif GDB}
  418. {$ifdef alpha}
  419. { the follow is for the DEC Alpha }
  420. aiclass[ait_frame]:=tai_frame;
  421. aiclass[ait_ent]:=tai_ent;
  422. {$endif alpha}
  423. {$ifdef m68k}
  424. {$warning FIXME: tai_labeled_instruction doesn't exists}
  425. // aiclass[ait_labeled_instruction]:=tai_labeled_instruction;
  426. {$endif m68k}
  427. {$ifdef ia64}
  428. aiclass[ait_bundle]:=tai_bundle;
  429. aiclass[ait_stop]:=tai_stop;
  430. {$endif ia64}
  431. {$ifdef SPARC}
  432. // aiclass[ait_labeled_instruction]:=tai_labeled_instruction;
  433. {$endif SPARC}
  434. aiclass[ait_cut]:=tai_cut;
  435. aiclass[ait_regalloc]:=tai_regalloc;
  436. aiclass[ait_tempalloc]:=tai_tempalloc;
  437. aiclass[ait_marker]:=tai_marker;
  438. end;
  439. end.
  440. {
  441. $Log$
  442. Revision 1.38 2002-08-23 13:11:11 mazen
  443. fixed compilation problem related to tai_labeled_instruction
  444. Revision 1.37 2002/08/18 20:06:25 peter
  445. * inlining is now also allowed in interface
  446. * renamed write/load to ppuwrite/ppuload
  447. * tnode storing in ppu
  448. * nld,ncon,nbas are already updated for storing in ppu
  449. Revision 1.36 2002/08/15 19:10:35 peter
  450. * first things tai,tnode storing in ppu
  451. Revision 1.35 2002/08/14 19:14:39 carl
  452. + fpu emulation support (generic and untested)
  453. Revision 1.34 2002/08/13 18:01:52 carl
  454. * rename swatoperands to swapoperands
  455. + m68k first compilable version (still needs a lot of testing):
  456. assembler generator, system information , inline
  457. assembler reader.
  458. Revision 1.33 2002/08/11 15:28:00 florian
  459. + support of explicit type case <any ordinal type>->pointer
  460. (delphi mode only)
  461. Revision 1.32 2002/07/25 17:54:24 carl
  462. + Extended is now CPU dependant (equal to bestrealtype)
  463. Revision 1.30 2002/07/07 09:52:32 florian
  464. * powerpc target fixed, very simple units can be compiled
  465. * some basic stuff for better callparanode handling, far from being finished
  466. Revision 1.29 2002/07/06 20:18:47 carl
  467. + more SPARC patches from Mazen
  468. Revision 1.28 2002/07/04 20:43:02 florian
  469. * first x86-64 patches
  470. Revision 1.27 2002/07/01 16:23:54 peter
  471. * cg64 patch
  472. * basics for currency
  473. * asnode updates for class and interface (not finished)
  474. Revision 1.26 2002/05/18 13:34:16 peter
  475. * readded missing revisions
  476. Revision 1.25 2002/05/16 19:46:44 carl
  477. + defines.inc -> fpcdefs.inc to avoid conflicts if compiling by hand
  478. + try to fix temp allocation (still in ifdef)
  479. + generic constructor calls
  480. + start of tassembler / tmodulebase class cleanup
  481. Revision 1.23 2002/05/12 16:53:09 peter
  482. * moved entry and exitcode to ncgutil and cgobj
  483. * foreach gets extra argument for passing local data to the
  484. iterator function
  485. * -CR checks also class typecasts at runtime by changing them
  486. into as
  487. * fixed compiler to cycle with the -CR option
  488. * fixed stabs with elf writer, finally the global variables can
  489. be watched
  490. * removed a lot of routines from cga unit and replaced them by
  491. calls to cgobj
  492. * u32bit-s32bit updates for and,or,xor nodes. When one element is
  493. u32bit then the other is typecasted also to u32bit without giving
  494. a rangecheck warning/error.
  495. * fixed pascal calling method with reversing also the high tree in
  496. the parast, detected by tcalcst3 test
  497. Revision 1.22 2002/01/24 12:33:53 jonas
  498. * adapted ranges of native types to int64 (e.g. high cardinal is no
  499. longer longint($ffffffff), but just $fffffff in psystem)
  500. * small additional fix in 64bit rangecheck code generation for 32 bit
  501. processors
  502. * adaption of ranges required the matching talgorithm used for selecting
  503. which overloaded procedure to call to be adapted. It should now always
  504. select the closest match for ordinal parameters.
  505. + inttostr(qword) in sysstr.inc/sysstrh.inc
  506. + abs(int64), sqr(int64), sqr(qword) in systemh.inc/generic.inc (previous
  507. fixes were required to be able to add them)
  508. * is_in_limit() moved from ncal to types unit, should always be used
  509. instead of direct comparisons of low/high values of orddefs because
  510. qword is a special case
  511. }