nmat.pas 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776
  1. {
  2. $Id$
  3. Copyright (c) 2000 by Florian Klaempfl
  4. Type checking and register allocation for math nodes
  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 nmat;
  19. {$i defines.inc}
  20. interface
  21. uses
  22. node;
  23. type
  24. tmoddivnode = class(tbinopnode)
  25. function pass_1 : tnode;override;
  26. function det_resulttype:tnode;override;
  27. protected
  28. { override the following if you want to implement }
  29. { parts explicitely in the code generator (JM) }
  30. function first_moddiv64bitint: tnode; virtual;
  31. function firstoptimize: tnode; virtual;
  32. end;
  33. tmoddivnodeclass = class of tmoddivnode;
  34. tshlshrnode = class(tbinopnode)
  35. function pass_1 : tnode;override;
  36. function det_resulttype:tnode;override;
  37. end;
  38. tshlshrnodeclass = class of tshlshrnode;
  39. tunaryminusnode = class(tunarynode)
  40. constructor create(expr : tnode);virtual;
  41. function pass_1 : tnode;override;
  42. function det_resulttype:tnode;override;
  43. end;
  44. tunaryminusnodeclass = class of tunaryminusnode;
  45. tnotnode = class(tunarynode)
  46. constructor create(expr : tnode);virtual;
  47. function pass_1 : tnode;override;
  48. function det_resulttype:tnode;override;
  49. end;
  50. tnotnodeclass = class of tnotnode;
  51. var
  52. cmoddivnode : tmoddivnodeclass;
  53. cshlshrnode : tshlshrnodeclass;
  54. cunaryminusnode : tunaryminusnodeclass;
  55. cnotnode : tnotnodeclass;
  56. implementation
  57. uses
  58. systems,tokens,
  59. verbose,globals,cutils,
  60. {$ifdef support_mmx}
  61. globtype,
  62. {$endif}
  63. symconst,symtype,symtable,symdef,types,
  64. htypechk,pass_1,cpubase,cpuinfo,
  65. cgbase,
  66. ncon,ncnv,ncal,nadd;
  67. {****************************************************************************
  68. TMODDIVNODE
  69. ****************************************************************************}
  70. function tmoddivnode.det_resulttype:tnode;
  71. var
  72. t : tnode;
  73. rd,ld : tdef;
  74. rv,lv : tconstexprint;
  75. begin
  76. result:=nil;
  77. resulttypepass(left);
  78. resulttypepass(right);
  79. set_varstate(left,true);
  80. set_varstate(right,true);
  81. if codegenerror then
  82. exit;
  83. { constant folding }
  84. if is_constintnode(left) and is_constintnode(right) then
  85. begin
  86. rv:=tordconstnode(right).value;
  87. lv:=tordconstnode(left).value;
  88. { check for division by zero }
  89. if (rv=0) then
  90. begin
  91. Message(parser_e_division_by_zero);
  92. { recover }
  93. rv:=1;
  94. end;
  95. case nodetype of
  96. modn:
  97. t:=genintconstnode(lv mod rv);
  98. divn:
  99. t:=genintconstnode(lv div rv);
  100. end;
  101. result:=t;
  102. exit;
  103. end;
  104. { allow operator overloading }
  105. t:=self;
  106. if isbinaryoverloaded(t) then
  107. begin
  108. result:=t;
  109. exit;
  110. end;
  111. { if one operand is a cardinal and the other is a positive constant, convert the }
  112. { constant to a cardinal as well so we don't have to do a 64bit division (JM) }
  113. { Do the same for qwords and positive constants as well, otherwise things like }
  114. { "qword mod 10" are evaluated with int64 as result, which is wrong if the }
  115. { "qword" was > high(int64) (JM) }
  116. if (left.resulttype.def.deftype=orddef) and (right.resulttype.def.deftype=orddef) then
  117. if (torddef(right.resulttype.def).typ in [u32bit,u64bit]) and
  118. is_constintnode(left) and
  119. (tordconstnode(left).value >= 0) then
  120. inserttypeconv(left,right.resulttype)
  121. else if (torddef(left.resulttype.def).typ in [u32bit,u64bit]) and
  122. is_constintnode(right) and
  123. (tordconstnode(right).value >= 0) then
  124. inserttypeconv(right,left.resulttype);
  125. if (left.resulttype.def.deftype=orddef) and (right.resulttype.def.deftype=orddef) and
  126. (is_64bitint(left.resulttype.def) or is_64bitint(right.resulttype.def) or
  127. { when mixing cardinals and signed numbers, convert everythign to 64bit (JM) }
  128. ((torddef(right.resulttype.def).typ = u32bit) and
  129. is_signed(left.resulttype.def)) or
  130. ((torddef(left.resulttype.def).typ = u32bit) and
  131. is_signed(right.resulttype.def))) then
  132. begin
  133. rd:=right.resulttype.def;
  134. ld:=left.resulttype.def;
  135. { issue warning if necessary }
  136. if not (is_64bitint(left.resulttype.def) or is_64bitint(right.resulttype.def)) then
  137. CGMessage(type_w_mixed_signed_unsigned);
  138. if is_signed(rd) or is_signed(ld) then
  139. begin
  140. if (torddef(ld).typ<>s64bit) then
  141. inserttypeconv(left,cs64bittype);
  142. if (torddef(rd).typ<>s64bit) then
  143. inserttypeconv(right,cs64bittype);
  144. end
  145. else
  146. begin
  147. if (torddef(ld).typ<>u64bit) then
  148. inserttypeconv(left,cu64bittype);
  149. if (torddef(rd).typ<>u64bit) then
  150. inserttypeconv(right,cu64bittype);
  151. end;
  152. resulttype:=left.resulttype;
  153. end
  154. else
  155. begin
  156. if not(right.resulttype.def.deftype=orddef) or
  157. not(torddef(right.resulttype.def).typ in [s32bit,u32bit]) then
  158. inserttypeconv(right,s32bittype);
  159. if not(left.resulttype.def.deftype=orddef) or
  160. not(torddef(left.resulttype.def).typ in [s32bit,u32bit]) then
  161. inserttypeconv(left,s32bittype);
  162. { the resulttype.def depends on the right side, because the left becomes }
  163. { always 64 bit }
  164. resulttype:=right.resulttype;
  165. end;
  166. end;
  167. function tmoddivnode.first_moddiv64bitint: tnode;
  168. var
  169. procname: string[31];
  170. begin
  171. result := nil;
  172. { otherwise create a call to a helper }
  173. if nodetype = divn then
  174. procname := 'fpc_div_'
  175. else
  176. procname := 'fpc_mod_';
  177. if is_signed(resulttype.def) then
  178. procname := procname + 'int64'
  179. else
  180. procname := procname + 'qword';
  181. result := ccallnode.createintern(procname,ccallparanode.create(left,
  182. ccallparanode.create(right,nil)));
  183. left := nil;
  184. right := nil;
  185. firstpass(result);
  186. end;
  187. function tmoddivnode.firstoptimize: tnode;
  188. var
  189. power, shiftval : longint;
  190. newtype: tnodetype;
  191. begin
  192. result := nil;
  193. { divide/mod a number by a constant which is a power of 2? }
  194. if (cs_optimize in aktglobalswitches) and
  195. (right.nodetype = ordconstn) and
  196. { ((nodetype = divn) or
  197. not is_signed(resulttype.def)) and}
  198. (not is_signed(resulttype.def)) and
  199. ispowerof2(tordconstnode(right).value,power) then
  200. begin
  201. if nodetype = divn then
  202. begin
  203. (*
  204. if is_signed(resulttype.def) then
  205. begin
  206. if is_64bitint(left.resulttype.def) then
  207. if not (cs_littlesize in aktglobalswitches) then
  208. shiftval := 63
  209. else
  210. { the shift code is a lot bigger than the call to }
  211. { the divide helper }
  212. exit
  213. else
  214. shiftval := 31;
  215. { we reuse left twice, so create once a copy of it }
  216. { !!! if left is a call is -> call gets executed twice }
  217. left := caddnode.create(addn,left,
  218. caddnode.create(andn,
  219. cshlshrnode.create(sarn,left.getcopy,
  220. cordconstnode.create(shiftval,s32bittype)),
  221. cordconstnode.create(tordconstnode(right).value-1,
  222. right.resulttype)));
  223. newtype := sarn;
  224. end
  225. else
  226. *)
  227. newtype := shrn;
  228. tordconstnode(right).value := power;
  229. result := cshlshrnode.create(newtype,left,right)
  230. end
  231. else
  232. begin
  233. dec(tordconstnode(right).value);
  234. result := caddnode.create(andn,left,right);
  235. end;
  236. { left and right are reused }
  237. left := nil;
  238. right := nil;
  239. firstpass(result);
  240. exit;
  241. end;
  242. end;
  243. function tmoddivnode.pass_1 : tnode;
  244. begin
  245. result:=nil;
  246. firstpass(left);
  247. firstpass(right);
  248. if codegenerror then
  249. exit;
  250. result := firstoptimize;
  251. if assigned(result) then
  252. exit;
  253. { 64bit }
  254. if (left.resulttype.def.deftype=orddef) and (right.resulttype.def.deftype=orddef) and
  255. (is_64bitint(left.resulttype.def) or is_64bitint(right.resulttype.def)) then
  256. begin
  257. result := first_moddiv64bitint;
  258. if assigned(result) then
  259. exit;
  260. location.loc:=LOC_REGISTER;
  261. calcregisters(self,2,0,0);
  262. end
  263. else
  264. begin
  265. left_right_max;
  266. if left.registers32<=right.registers32 then
  267. inc(registers32);
  268. end;
  269. location.loc:=LOC_REGISTER;
  270. end;
  271. {****************************************************************************
  272. TSHLSHRNODE
  273. ****************************************************************************}
  274. function tshlshrnode.det_resulttype:tnode;
  275. var
  276. t : tnode;
  277. begin
  278. result:=nil;
  279. resulttypepass(left);
  280. resulttypepass(right);
  281. set_varstate(right,true);
  282. set_varstate(left,true);
  283. if codegenerror then
  284. exit;
  285. { constant folding }
  286. if is_constintnode(left) and is_constintnode(right) then
  287. begin
  288. case nodetype of
  289. shrn:
  290. t:=genintconstnode(tordconstnode(left).value shr tordconstnode(right).value);
  291. shln:
  292. t:=genintconstnode(tordconstnode(left).value shl tordconstnode(right).value);
  293. end;
  294. result:=t;
  295. exit;
  296. end;
  297. { allow operator overloading }
  298. t:=self;
  299. if isbinaryoverloaded(t) then
  300. begin
  301. result:=t;
  302. exit;
  303. end;
  304. { 64 bit ints have their own shift handling }
  305. if not(is_64bitint(left.resulttype.def)) then
  306. begin
  307. if torddef(left.resulttype.def).typ <> u32bit then
  308. inserttypeconv(left,s32bittype);
  309. end;
  310. inserttypeconv(right,s32bittype);
  311. resulttype:=left.resulttype;
  312. end;
  313. function tshlshrnode.pass_1 : tnode;
  314. var
  315. regs : longint;
  316. begin
  317. result:=nil;
  318. firstpass(left);
  319. firstpass(right);
  320. if codegenerror then
  321. exit;
  322. { 64 bit ints have their own shift handling }
  323. if not(is_64bitint(left.resulttype.def)) then
  324. regs:=1
  325. else
  326. regs:=2;
  327. if (right.nodetype<>ordconstn) then
  328. inc(regs);
  329. location.loc:=LOC_REGISTER;
  330. calcregisters(self,regs,0,0);
  331. end;
  332. {****************************************************************************
  333. TUNARYMINUSNODE
  334. ****************************************************************************}
  335. constructor tunaryminusnode.create(expr : tnode);
  336. begin
  337. inherited create(unaryminusn,expr);
  338. end;
  339. function tunaryminusnode.det_resulttype : tnode;
  340. var
  341. t : tnode;
  342. minusdef : pprocdeflist;
  343. begin
  344. result:=nil;
  345. resulttypepass(left);
  346. set_varstate(left,true);
  347. if codegenerror then
  348. exit;
  349. { constant folding }
  350. if is_constintnode(left) then
  351. begin
  352. tordconstnode(left).value:=-tordconstnode(left).value;
  353. result:=left;
  354. left:=nil;
  355. exit;
  356. end;
  357. if is_constrealnode(left) then
  358. begin
  359. trealconstnode(left).value_real:=-trealconstnode(left).value_real;
  360. result:=left;
  361. left:=nil;
  362. exit;
  363. end;
  364. resulttype:=left.resulttype;
  365. if (left.resulttype.def.deftype=floatdef) then
  366. begin
  367. end
  368. {$ifdef SUPPORT_MMX}
  369. else if (cs_mmx in aktlocalswitches) and
  370. is_mmx_able_array(left.resulttype.def) then
  371. begin
  372. { if saturation is on, left.resulttype.def isn't
  373. "mmx able" (FK)
  374. if (cs_mmx_saturation in aktlocalswitches^) and
  375. (torddef(tarraydef(resulttype.def).definition).typ in
  376. [s32bit,u32bit]) then
  377. CGMessage(type_e_mismatch);
  378. }
  379. end
  380. {$endif SUPPORT_MMX}
  381. else if is_64bitint(left.resulttype.def) then
  382. begin
  383. end
  384. else if (left.resulttype.def.deftype=orddef) then
  385. begin
  386. inserttypeconv(left,s32bittype);
  387. resulttype:=left.resulttype;
  388. end
  389. else
  390. begin
  391. if assigned(overloaded_operators[_minus]) then
  392. minusdef:=overloaded_operators[_minus].defs
  393. else
  394. minusdef:=nil;
  395. while assigned(minusdef) do
  396. begin
  397. if is_equal(tparaitem(minusdef^.def.para.first).paratype.def,left.resulttype.def) and
  398. (tparaitem(minusdef^.def.para.first).next=nil) then
  399. begin
  400. t:=ccallnode.create(ccallparanode.create(left,nil),
  401. overloaded_operators[_minus],nil,nil);
  402. left:=nil;
  403. result:=t;
  404. exit;
  405. end;
  406. minusdef:=minusdef^.next;
  407. end;
  408. CGMessage(type_e_mismatch);
  409. end;
  410. end;
  411. { generic code }
  412. { overridden by: }
  413. { i386 }
  414. function tunaryminusnode.pass_1 : tnode;
  415. begin
  416. result:=nil;
  417. firstpass(left);
  418. if codegenerror then
  419. exit;
  420. registers32:=left.registers32;
  421. registersfpu:=left.registersfpu;
  422. {$ifdef SUPPORT_MMX}
  423. registersmmx:=left.registersmmx;
  424. {$endif SUPPORT_MMX}
  425. if (left.resulttype.def.deftype=floatdef) then
  426. begin
  427. if (left.location.loc<>LOC_REGISTER) and
  428. (registersfpu<1) then
  429. registersfpu:=1;
  430. location.loc:=LOC_REGISTER;
  431. end
  432. {$ifdef SUPPORT_MMX}
  433. else if (cs_mmx in aktlocalswitches) and
  434. is_mmx_able_array(left.resulttype.def) then
  435. begin
  436. if (left.location.loc<>LOC_MMXREGISTER) and
  437. (registersmmx<1) then
  438. registersmmx:=1;
  439. end
  440. {$endif SUPPORT_MMX}
  441. else if is_64bitint(left.resulttype.def) then
  442. begin
  443. if (left.location.loc<>LOC_REGISTER) and
  444. (registers32<2) then
  445. registers32:=2;
  446. location.loc:=LOC_REGISTER;
  447. end
  448. else if (left.resulttype.def.deftype=orddef) then
  449. begin
  450. if (left.location.loc<>LOC_REGISTER) and
  451. (registers32<1) then
  452. registers32:=1;
  453. location.loc:=LOC_REGISTER;
  454. end;
  455. end;
  456. {****************************************************************************
  457. TNOTNODE
  458. ****************************************************************************}
  459. constructor tnotnode.create(expr : tnode);
  460. begin
  461. inherited create(notn,expr);
  462. end;
  463. function tnotnode.det_resulttype : tnode;
  464. var
  465. t : tnode;
  466. notdef : pprocdeflist;
  467. v : tconstexprint;
  468. begin
  469. result:=nil;
  470. resulttypepass(left);
  471. set_varstate(left,true);
  472. if codegenerror then
  473. exit;
  474. { constant folding }
  475. if (left.nodetype=ordconstn) then
  476. begin
  477. v:=tordconstnode(left).value;
  478. case torddef(left.resulttype.def).typ of
  479. bool8bit,
  480. bool16bit,
  481. bool32bit :
  482. begin
  483. { here we do a boolean(byte(..)) type cast because }
  484. { boolean(<int64>) is buggy in 1.00 }
  485. v:=byte(not(boolean(byte(v))));
  486. end;
  487. uchar,
  488. u8bit :
  489. v:=byte(not byte(v));
  490. s8bit :
  491. v:=shortint(not shortint(v));
  492. uwidechar,
  493. u16bit :
  494. v:=word(not word(v));
  495. s16bit :
  496. v:=smallint(not smallint(v));
  497. u32bit :
  498. v:=cardinal(not cardinal(v));
  499. s32bit :
  500. v:=longint(not longint(v));
  501. u64bit :
  502. v:=int64(not int64(v)); { maybe qword is required }
  503. s64bit :
  504. v:=int64(not int64(v));
  505. else
  506. CGMessage(type_e_mismatch);
  507. end;
  508. t:=cordconstnode.create(v,left.resulttype);
  509. result:=t;
  510. exit;
  511. end;
  512. resulttype:=left.resulttype;
  513. if is_boolean(resulttype.def) then
  514. begin
  515. end
  516. else
  517. {$ifdef SUPPORT_MMX}
  518. if (cs_mmx in aktlocalswitches) and
  519. is_mmx_able_array(left.resulttype.def) then
  520. begin
  521. end
  522. else
  523. {$endif SUPPORT_MMX}
  524. if is_64bitint(left.resulttype.def) then
  525. begin
  526. end
  527. else if is_integer(left.resulttype.def) then
  528. begin
  529. end
  530. else
  531. begin
  532. if assigned(overloaded_operators[_op_not]) then
  533. notdef:=overloaded_operators[_op_not].defs
  534. else
  535. notdef:=nil;
  536. while assigned(notdef) do
  537. begin
  538. if is_equal(tparaitem(notdef^.def.para.first).paratype.def,left.resulttype.def) and
  539. (tparaitem(notdef^.def.para.first).next=nil) then
  540. begin
  541. t:=ccallnode.create(ccallparanode.create(left,nil),
  542. overloaded_operators[_op_not],nil,nil);
  543. left:=nil;
  544. result:=t;
  545. exit;
  546. end;
  547. notdef:=notdef^.next;
  548. end;
  549. CGMessage(type_e_mismatch);
  550. end;
  551. end;
  552. function tnotnode.pass_1 : tnode;
  553. begin
  554. result:=nil;
  555. firstpass(left);
  556. if codegenerror then
  557. exit;
  558. location.loc:=left.location.loc;
  559. registers32:=left.registers32;
  560. {$ifdef SUPPORT_MMX}
  561. registersmmx:=left.registersmmx;
  562. {$endif SUPPORT_MMX}
  563. if is_boolean(resulttype.def) then
  564. begin
  565. if (location.loc in [LOC_REFERENCE,LOC_MEM,LOC_CREGISTER]) then
  566. begin
  567. location.loc:=LOC_REGISTER;
  568. if (registers32<1) then
  569. registers32:=1;
  570. end;
  571. { before loading it into flags we need to load it into
  572. a register thus 1 register is need PM }
  573. {$ifdef i386}
  574. if left.location.loc<>LOC_JUMP then
  575. location.loc:=LOC_FLAGS;
  576. {$endif def i386}
  577. end
  578. else
  579. {$ifdef SUPPORT_MMX}
  580. if (cs_mmx in aktlocalswitches) and
  581. is_mmx_able_array(left.resulttype.def) then
  582. begin
  583. if (left.location.loc<>LOC_MMXREGISTER) and
  584. (registersmmx<1) then
  585. registersmmx:=1;
  586. end
  587. else
  588. {$endif SUPPORT_MMX}
  589. if is_64bitint(left.resulttype.def) then
  590. begin
  591. if (location.loc in [LOC_REFERENCE,LOC_MEM,LOC_CREGISTER]) then
  592. begin
  593. location.loc:=LOC_REGISTER;
  594. if (registers32<2) then
  595. registers32:=2;
  596. end;
  597. end
  598. else if is_integer(left.resulttype.def) then
  599. begin
  600. if (left.location.loc<>LOC_REGISTER) and
  601. (registers32<1) then
  602. registers32:=1;
  603. location.loc:=LOC_REGISTER;
  604. end
  605. end;
  606. begin
  607. cmoddivnode:=tmoddivnode;
  608. cshlshrnode:=tshlshrnode;
  609. cunaryminusnode:=tunaryminusnode;
  610. cnotnode:=tnotnode;
  611. end.
  612. {
  613. $Log$
  614. Revision 1.27 2001-12-29 15:27:24 jonas
  615. * made 'mod powerof2' -> 'and' optimization processor independent
  616. Revision 1.26 2001/12/27 15:33:58 jonas
  617. * fixed fpuregister counting errors ("merged")
  618. Revision 1.25 2001/11/02 22:58:02 peter
  619. * procsym definition rewrite
  620. Revision 1.24 2001/10/12 13:51:51 jonas
  621. * fixed internalerror(10) due to previous fpu overflow fixes ("merged")
  622. * fixed bug in n386add (introduced after compilerproc changes for string
  623. operations) where calcregisters wasn't called for shortstring addnodes
  624. * NOTE: from now on, the location of a binary node must now always be set
  625. before you call calcregisters() for it
  626. Revision 1.23 2001/09/05 15:22:09 jonas
  627. * made multiplying, dividing and mod'ing of int64 and qword processor
  628. independent with compilerprocs (+ small optimizations by using shift/and
  629. where possible)
  630. Revision 1.22 2001/09/02 21:12:07 peter
  631. * move class of definitions into type section for delphi
  632. Revision 1.21 2001/08/26 13:36:41 florian
  633. * some cg reorganisation
  634. * some PPC updates
  635. Revision 1.20 2001/04/13 01:22:10 peter
  636. * symtable change to classes
  637. * range check generation and errors fixed, make cycle DEBUG=1 works
  638. * memory leaks fixed
  639. Revision 1.19 2001/04/05 21:00:27 peter
  640. * fix constant not evaluation
  641. Revision 1.18 2001/04/04 22:42:40 peter
  642. * move constant folding into det_resulttype
  643. Revision 1.17 2001/04/02 21:20:31 peter
  644. * resulttype rewrite
  645. Revision 1.16 2001/03/20 18:11:03 jonas
  646. * not (cardinal) now has cardinal instead of longint result (bug reported
  647. in mailinglist) ("merged")
  648. Revision 1.15 2001/03/04 10:38:55 jonas
  649. * fixed 'qword mod/div pos_const' to have qword result
  650. Revision 1.14 2001/02/20 21:48:17 peter
  651. * remove nasm hack
  652. Revision 1.13 2001/01/06 18:28:39 peter
  653. * fixed wrong notes about locals
  654. Revision 1.12 2001/01/05 17:36:57 florian
  655. * the info about exception frames is stored now on the stack
  656. instead on the heap
  657. Revision 1.11 2000/12/25 00:07:26 peter
  658. + new tlinkedlist class (merge of old tstringqueue,tcontainer and
  659. tlinkedlist objects)
  660. Revision 1.10 2000/12/16 15:54:01 jonas
  661. * 'resulttype.def of cardinal shl/shr x' is cardinal instead of longint
  662. Revision 1.9 2000/11/29 00:30:34 florian
  663. * unused units removed from uses clause
  664. * some changes for widestrings
  665. Revision 1.8 2000/10/31 22:02:49 peter
  666. * symtable splitted, no real code changes
  667. Revision 1.7 2000/10/01 19:48:24 peter
  668. * lot of compile updates for cg11
  669. Revision 1.6 2000/09/27 21:33:22 florian
  670. * finally nadd.pas compiles
  671. Revision 1.5 2000/09/27 20:25:44 florian
  672. * more stuff fixed
  673. Revision 1.4 2000/09/24 15:06:19 peter
  674. * use defines.inc
  675. Revision 1.3 2000/09/22 22:48:54 florian
  676. * some fixes
  677. Revision 1.2 2000/09/22 22:09:54 florian
  678. * more stuff converted
  679. Revision 1.1 2000/09/20 21:35:12 florian
  680. * initial revision
  681. }