cgcpu.pas 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565
  1. {
  2. $Id$
  3. Copyright (c) 1998-2002 by Florian Klaempfl
  4. This unit implements the code generator for the 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. { This unit implements the code generator for the i386.
  19. }
  20. unit cgcpu;
  21. {$i fpcdefs.inc}
  22. interface
  23. uses
  24. cgbase,cgobj,cg64f32,cgx86,
  25. aasmbase,aasmtai,aasmcpu,
  26. cpubase,cpuinfo,
  27. node,symconst
  28. {$ifdef delphi}
  29. ,dmisc
  30. {$endif}
  31. ;
  32. type
  33. tcg386 = class(tcgx86)
  34. procedure init_register_allocators;override;
  35. class function reg_cgsize(const reg: tregister): tcgsize; override;
  36. procedure g_save_all_registers(list : taasmoutput);override;
  37. procedure g_restore_all_registers(list : taasmoutput;const funcretparaloc:tparalocation);override;
  38. procedure g_copyvaluepara_openarray(list : taasmoutput;const ref, lenref:treference;elesize:aword);override;
  39. end;
  40. tcg64f386 = class(tcg64f32)
  41. procedure a_op64_ref_reg(list : taasmoutput;op:TOpCG;const ref : treference;reg : tregister64);override;
  42. procedure a_op64_reg_reg(list : taasmoutput;op:TOpCG;regsrc,regdst : tregister64);override;
  43. procedure a_op64_const_reg(list : taasmoutput;op:TOpCG;value : qword;reg : tregister64);override;
  44. procedure a_op64_const_ref(list : taasmoutput;op:TOpCG;value : qword;const ref : treference);override;
  45. private
  46. procedure get_64bit_ops(op:TOpCG;var op1,op2:TAsmOp);
  47. end;
  48. implementation
  49. uses
  50. globtype,globals,verbose,systems,cutils,
  51. symdef,symsym,defutil,paramgr,procinfo,
  52. rgcpu,rgx86,tgobj;
  53. procedure Tcg386.init_register_allocators;
  54. begin
  55. inherited init_register_allocators;
  56. if cs_create_pic in aktmoduleswitches then
  57. rg[R_INTREGISTER]:=trgcpu.create(R_INTREGISTER,R_SUBWHOLE,[RS_EAX,RS_EDX,RS_ECX,RS_ESI,RS_EDI],first_int_imreg,[RS_EBP,RS_EBX])
  58. else
  59. rg[R_INTREGISTER]:=trgcpu.create(R_INTREGISTER,R_SUBWHOLE,[RS_EAX,RS_EDX,RS_ECX,RS_EBX,RS_ESI,RS_EDI],first_int_imreg,[RS_EBP]);
  60. rg[R_MMXREGISTER]:=trgcpu.create(R_MMXREGISTER,R_SUBNONE,[RS_XMM0,RS_XMM1,RS_XMM2,RS_XMM3,RS_XMM4,RS_XMM5,RS_XMM6,RS_XMM7],first_sse_imreg,[]);
  61. rg[R_MMREGISTER]:=trgcpu.create(R_MMREGISTER,R_SUBNONE,[RS_XMM0,RS_XMM1,RS_XMM2,RS_XMM3,RS_XMM4,RS_XMM5,RS_XMM6,RS_XMM7],first_sse_imreg,[]);
  62. rgfpu:=Trgx86fpu.create;
  63. end;
  64. class function tcg386.reg_cgsize(const reg: tregister): tcgsize;
  65. const subreg2cgsize:array[Tsubregister] of Tcgsize =
  66. (OS_NO,OS_8,OS_8,OS_16,OS_32,OS_64,OS_NO,OS_NO);
  67. begin
  68. case getregtype(reg) of
  69. R_INTREGISTER :
  70. reg_cgsize:=subreg2cgsize[getsubreg(reg)];
  71. R_FPUREGISTER :
  72. reg_cgsize:=OS_F80;
  73. R_MMXREGISTER,
  74. R_MMREGISTER :
  75. reg_cgsize:=OS_M64;
  76. R_SPECIALREGISTER :
  77. case reg of
  78. NR_CS,NR_DS,NR_ES,NR_SS,NR_FS,NR_GS:
  79. reg_cgsize:=OS_16
  80. else
  81. reg_cgsize:=OS_32
  82. end
  83. else
  84. internalerror(200303181);
  85. end;
  86. end;
  87. { const
  88. opsize_2_cgsize: array[topsize] of tcgsize = (OS_NO,
  89. OS_8,OS_16,OS_32,OS_NO,OS_NO,OS_NO,
  90. OS_32,OS_64,OS_64,
  91. OS_F32,OS_F64,OS_F80,OS_F32,OS_F64,OS_M64,OS_NO,
  92. OS_NO,OS_NO,OS_NO
  93. );
  94. begin
  95. result := opsize_2_cgsize[reg2opsize(reg)];
  96. end;}
  97. procedure tcg386.g_save_all_registers(list : taasmoutput);
  98. begin
  99. list.concat(Taicpu.Op_none(A_PUSHA,S_L));
  100. tg.GetTemp(list,POINTER_SIZE,tt_noreuse,current_procinfo.save_regs_ref);
  101. a_load_reg_ref(list,OS_ADDR,OS_ADDR,NR_STACK_POINTER_REG,current_procinfo.save_regs_ref);
  102. end;
  103. procedure tcg386.g_restore_all_registers(list : taasmoutput;const funcretparaloc:tparalocation);
  104. var
  105. href : treference;
  106. begin
  107. a_load_ref_reg(list,OS_ADDR,OS_ADDR,current_procinfo.save_regs_ref,NR_STACK_POINTER_REG);
  108. tg.UnGetTemp(list,current_procinfo.save_regs_ref);
  109. if funcretparaloc.loc=LOC_REGISTER then
  110. begin
  111. if funcretparaloc.size in [OS_64,OS_S64] then
  112. begin
  113. reference_reset_base(href,NR_STACK_POINTER_REG,20);
  114. a_load_reg_ref(list,OS_32,OS_32,NR_FUNCTION_RETURN64_HIGH_REG,href);
  115. reference_reset_base(href,NR_STACK_POINTER_REG,28);
  116. a_load_reg_ref(list,OS_32,OS_32,NR_FUNCTION_RETURN64_LOW_REG,href);
  117. end
  118. else
  119. begin
  120. reference_reset_base(href,NR_STACK_POINTER_REG,28);
  121. a_load_reg_ref(list,OS_32,OS_32,NR_FUNCTION_RETURN_REG,href);
  122. end;
  123. end;
  124. list.concat(Taicpu.Op_none(A_POPA,S_L));
  125. { We add a NOP because of the 386DX CPU bugs with POPAD }
  126. list.concat(taicpu.op_none(A_NOP,S_L));
  127. end;
  128. procedure tcg386.g_copyvaluepara_openarray(list : taasmoutput;const ref, lenref:treference;elesize:aword);
  129. var
  130. power,len : longint;
  131. opsize : topsize;
  132. {$ifndef __NOWINPECOFF__}
  133. again,ok : tasmlabel;
  134. {$endif}
  135. begin
  136. { get stack space }
  137. getexplicitregister(list,NR_EDI);
  138. list.concat(Taicpu.op_ref_reg(A_MOV,S_L,lenref,NR_EDI));
  139. list.concat(Taicpu.op_reg(A_INC,S_L,NR_EDI));
  140. if (elesize<>1) then
  141. begin
  142. if ispowerof2(elesize, power) then
  143. list.concat(Taicpu.op_const_reg(A_SHL,S_L,power,NR_EDI))
  144. else
  145. list.concat(Taicpu.op_const_reg(A_IMUL,S_L,elesize,NR_EDI));
  146. end;
  147. {$ifndef __NOWINPECOFF__}
  148. { windows guards only a few pages for stack growing, }
  149. { so we have to access every page first }
  150. if target_info.system=system_i386_win32 then
  151. begin
  152. objectlibrary.getlabel(again);
  153. objectlibrary.getlabel(ok);
  154. a_label(list,again);
  155. list.concat(Taicpu.op_const_reg(A_CMP,S_L,winstackpagesize,NR_EDI));
  156. a_jmp_cond(list,OC_B,ok);
  157. list.concat(Taicpu.op_const_reg(A_SUB,S_L,winstackpagesize-4,NR_ESP));
  158. list.concat(Taicpu.op_reg(A_PUSH,S_L,NR_EDI));
  159. list.concat(Taicpu.op_const_reg(A_SUB,S_L,winstackpagesize,NR_EDI));
  160. a_jmp_always(list,again);
  161. a_label(list,ok);
  162. list.concat(Taicpu.op_reg_reg(A_SUB,S_L,NR_EDI,NR_ESP));
  163. ungetregister(list,NR_EDI);
  164. { now reload EDI }
  165. getexplicitregister(list,NR_EDI);
  166. list.concat(Taicpu.op_ref_reg(A_MOV,S_L,lenref,NR_EDI));
  167. list.concat(Taicpu.op_reg(A_INC,S_L,NR_EDI));
  168. if (elesize<>1) then
  169. begin
  170. if ispowerof2(elesize, power) then
  171. list.concat(Taicpu.op_const_reg(A_SHL,S_L,power,NR_EDI))
  172. else
  173. list.concat(Taicpu.op_const_reg(A_IMUL,S_L,elesize,NR_EDI));
  174. end;
  175. end
  176. else
  177. {$endif __NOWINPECOFF__}
  178. list.concat(Taicpu.op_reg_reg(A_SUB,S_L,NR_EDI,NR_ESP));
  179. { align stack on 4 bytes }
  180. list.concat(Taicpu.op_const_reg(A_AND,S_L,$fffffff4,NR_ESP));
  181. { load destination }
  182. a_load_reg_reg(list,OS_INT,OS_INT,NR_ESP,NR_EDI);
  183. { Allocate other registers }
  184. getexplicitregister(list,NR_ECX);
  185. getexplicitregister(list,NR_ESI);
  186. { load count }
  187. a_load_ref_reg(list,OS_INT,OS_INT,lenref,NR_ECX);
  188. { load source }
  189. a_load_ref_reg(list,OS_INT,OS_INT,ref,NR_ESI);
  190. { scheduled .... }
  191. list.concat(Taicpu.op_reg(A_INC,S_L,NR_ECX));
  192. { calculate size }
  193. len:=elesize;
  194. opsize:=S_B;
  195. if (len and 3)=0 then
  196. begin
  197. opsize:=S_L;
  198. len:=len shr 2;
  199. end
  200. else
  201. if (len and 1)=0 then
  202. begin
  203. opsize:=S_W;
  204. len:=len shr 1;
  205. end;
  206. if ispowerof2(len, power) then
  207. list.concat(Taicpu.op_const_reg(A_SHL,S_L,power,NR_ECX))
  208. else
  209. list.concat(Taicpu.op_const_reg(A_IMUL,S_L,len,NR_ECX));
  210. list.concat(Taicpu.op_none(A_REP,S_NO));
  211. case opsize of
  212. S_B : list.concat(Taicpu.Op_none(A_MOVSB,S_NO));
  213. S_W : list.concat(Taicpu.Op_none(A_MOVSW,S_NO));
  214. S_L : list.concat(Taicpu.Op_none(A_MOVSL,S_NO));
  215. end;
  216. ungetregister(list,NR_EDI);
  217. ungetregister(list,NR_ECX);
  218. ungetregister(list,NR_ESI);
  219. { patch the new address }
  220. a_load_reg_ref(list,OS_INT,OS_INT,NR_ESP,ref);
  221. end;
  222. { ************* 64bit operations ************ }
  223. procedure tcg64f386.get_64bit_ops(op:TOpCG;var op1,op2:TAsmOp);
  224. begin
  225. case op of
  226. OP_ADD :
  227. begin
  228. op1:=A_ADD;
  229. op2:=A_ADC;
  230. end;
  231. OP_SUB :
  232. begin
  233. op1:=A_SUB;
  234. op2:=A_SBB;
  235. end;
  236. OP_XOR :
  237. begin
  238. op1:=A_XOR;
  239. op2:=A_XOR;
  240. end;
  241. OP_OR :
  242. begin
  243. op1:=A_OR;
  244. op2:=A_OR;
  245. end;
  246. OP_AND :
  247. begin
  248. op1:=A_AND;
  249. op2:=A_AND;
  250. end;
  251. else
  252. internalerror(200203241);
  253. end;
  254. end;
  255. procedure tcg64f386.a_op64_ref_reg(list : taasmoutput;op:TOpCG;const ref : treference;reg : tregister64);
  256. var
  257. op1,op2 : TAsmOp;
  258. tempref : treference;
  259. begin
  260. get_64bit_ops(op,op1,op2);
  261. list.concat(taicpu.op_ref_reg(op1,S_L,ref,reg.reglo));
  262. tempref:=ref;
  263. inc(tempref.offset,4);
  264. list.concat(taicpu.op_ref_reg(op2,S_L,tempref,reg.reghi));
  265. end;
  266. procedure tcg64f386.a_op64_reg_reg(list : taasmoutput;op:TOpCG;regsrc,regdst : tregister64);
  267. var
  268. op1,op2 : TAsmOp;
  269. begin
  270. case op of
  271. OP_NEG :
  272. begin
  273. if (regsrc.reglo<>regdst.reglo) then
  274. a_load64_reg_reg(list,regsrc,regdst);
  275. list.concat(taicpu.op_reg(A_NOT,S_L,regdst.reghi));
  276. list.concat(taicpu.op_reg(A_NEG,S_L,regdst.reglo));
  277. list.concat(taicpu.op_const_reg(A_SBB,S_L,aword(-1),regdst.reghi));
  278. exit;
  279. end;
  280. OP_NOT :
  281. begin
  282. if (regsrc.reglo<>regdst.reglo) then
  283. a_load64_reg_reg(list,regsrc,regdst);
  284. list.concat(taicpu.op_reg(A_NOT,S_L,regdst.reghi));
  285. list.concat(taicpu.op_reg(A_NOT,S_L,regdst.reglo));
  286. exit;
  287. end;
  288. end;
  289. get_64bit_ops(op,op1,op2);
  290. list.concat(taicpu.op_reg_reg(op1,S_L,regsrc.reglo,regdst.reglo));
  291. list.concat(taicpu.op_reg_reg(op2,S_L,regsrc.reghi,regdst.reghi));
  292. end;
  293. procedure tcg64f386.a_op64_const_reg(list : taasmoutput;op:TOpCG;value : qword;reg : tregister64);
  294. var
  295. op1,op2 : TAsmOp;
  296. begin
  297. case op of
  298. OP_AND,OP_OR,OP_XOR:
  299. begin
  300. cg.a_op_const_reg(list,op,OS_32,lo(value),reg.reglo);
  301. cg.a_op_const_reg(list,op,OS_32,hi(value),reg.reghi);
  302. end;
  303. OP_ADD, OP_SUB:
  304. begin
  305. // can't use a_op_const_ref because this may use dec/inc
  306. get_64bit_ops(op,op1,op2);
  307. list.concat(taicpu.op_const_reg(op1,S_L,lo(value),reg.reglo));
  308. list.concat(taicpu.op_const_reg(op2,S_L,hi(value),reg.reghi));
  309. end;
  310. else
  311. internalerror(200204021);
  312. end;
  313. end;
  314. procedure tcg64f386.a_op64_const_ref(list : taasmoutput;op:TOpCG;value : qword;const ref : treference);
  315. var
  316. op1,op2 : TAsmOp;
  317. tempref : treference;
  318. begin
  319. case op of
  320. OP_AND,OP_OR,OP_XOR:
  321. begin
  322. cg.a_op_const_ref(list,op,OS_32,lo(value),ref);
  323. tempref:=ref;
  324. inc(tempref.offset,4);
  325. cg.a_op_const_ref(list,op,OS_32,hi(value),tempref);
  326. end;
  327. OP_ADD, OP_SUB:
  328. begin
  329. get_64bit_ops(op,op1,op2);
  330. // can't use a_op_const_ref because this may use dec/inc
  331. list.concat(taicpu.op_const_ref(op1,S_L,lo(value),ref));
  332. tempref:=ref;
  333. inc(tempref.offset,4);
  334. list.concat(taicpu.op_const_ref(op2,S_L,hi(value),tempref));
  335. end;
  336. else
  337. internalerror(200204022);
  338. end;
  339. end;
  340. begin
  341. cg := tcg386.create;
  342. cg64 := tcg64f386.create;
  343. end.
  344. {
  345. $Log$
  346. Revision 1.46 2004-02-22 16:48:09 florian
  347. * x86_64 uses generic concatcopy_valueopenarray for now
  348. Revision 1.45 2004/02/04 22:01:13 peter
  349. * first try to get cpupara working for x86_64
  350. Revision 1.44 2004/01/14 23:39:05 florian
  351. * another bunch of x86-64 fixes mainly calling convention and
  352. assembler reader related
  353. Revision 1.43 2004/01/12 16:39:40 peter
  354. * sparc updates, mostly float related
  355. Revision 1.42 2003/12/24 00:10:02 florian
  356. - delete parameter in cg64 methods removed
  357. Revision 1.41 2003/12/19 22:08:44 daniel
  358. * Some work to restore the MMX capabilities
  359. Revision 1.40 2003/10/10 17:48:14 peter
  360. * old trgobj moved to x86/rgcpu and renamed to trgx86fpu
  361. * tregisteralloctor renamed to trgobj
  362. * removed rgobj from a lot of units
  363. * moved location_* and reference_* to cgobj
  364. * first things for mmx register allocation
  365. Revision 1.39 2003/10/01 20:34:49 peter
  366. * procinfo unit contains tprocinfo
  367. * cginfo renamed to cgbase
  368. * moved cgmessage to verbose
  369. * fixed ppc and sparc compiles
  370. Revision 1.38 2003/09/25 13:13:32 florian
  371. * more x86-64 fixes
  372. Revision 1.37 2003/09/03 15:55:01 peter
  373. * NEWRA branch merged
  374. Revision 1.36.2.1 2003/08/29 17:28:59 peter
  375. * next batch of updates
  376. Revision 1.36 2003/06/12 18:31:18 peter
  377. * fix newra cycle for i386
  378. Revision 1.35 2003/06/03 21:11:09 peter
  379. * cg.a_load_* get a from and to size specifier
  380. * makeregsize only accepts newregister
  381. * i386 uses generic tcgnotnode,tcgunaryminus
  382. Revision 1.34 2003/06/01 21:38:06 peter
  383. * getregisterfpu size parameter added
  384. * op_const_reg size parameter added
  385. * sparc updates
  386. Revision 1.33 2003/05/22 21:32:28 peter
  387. * removed some unit dependencies
  388. Revision 1.32 2002/11/25 17:43:26 peter
  389. * splitted defbase in defutil,symutil,defcmp
  390. * merged isconvertable and is_equal into compare_defs(_ext)
  391. * made operator search faster by walking the list only once
  392. Revision 1.31 2002/10/05 12:43:29 carl
  393. * fixes for Delphi 6 compilation
  394. (warning : Some features do not work under Delphi)
  395. Revision 1.30 2002/09/07 15:25:10 peter
  396. * old logs removed and tabs fixed
  397. Revision 1.29 2002/07/20 19:28:47 florian
  398. * splitting of i386\cgcpu.pas into x86\cgx86.pas and i386\cgcpu.pas
  399. cgx86.pas will contain the common code for i386 and x86_64
  400. Revision 1.28 2002/07/20 11:58:00 florian
  401. * types.pas renamed to defbase.pas because D6 contains a types
  402. unit so this would conflicts if D6 programms are compiled
  403. + Willamette/SSE2 instructions to assembler added
  404. Revision 1.27 2002/07/11 14:41:32 florian
  405. * start of the new generic parameter handling
  406. Revision 1.26 2002/07/07 09:52:33 florian
  407. * powerpc target fixed, very simple units can be compiled
  408. * some basic stuff for better callparanode handling, far from being finished
  409. Revision 1.25 2002/07/01 18:46:30 peter
  410. * internal linker
  411. * reorganized aasm layer
  412. Revision 1.24 2002/07/01 16:23:55 peter
  413. * cg64 patch
  414. * basics for currency
  415. * asnode updates for class and interface (not finished)
  416. Revision 1.23 2002/06/16 08:16:59 carl
  417. * bugfix of missing popecx for shift operations
  418. Revision 1.22 2002/05/22 19:02:16 carl
  419. + generic FPC_HELP_FAIL
  420. + generic FPC_HELP_DESTRUCTOR instated (original from Pierre)
  421. + generic FPC_DISPOSE_CLASS
  422. + TEST_GENERIC define
  423. Revision 1.21 2002/05/20 13:30:40 carl
  424. * bugfix of hdisponen (base must be set, not index)
  425. * more portability fixes
  426. Revision 1.20 2002/05/18 13:34:22 peter
  427. * readded missing revisions
  428. Revision 1.19 2002/05/16 19:46:50 carl
  429. + defines.inc -> fpcdefs.inc to avoid conflicts if compiling by hand
  430. + try to fix temp allocation (still in ifdef)
  431. + generic constructor calls
  432. + start of tassembler / tmodulebase class cleanup
  433. Revision 1.17 2002/05/13 19:54:37 peter
  434. * removed n386ld and n386util units
  435. * maybe_save/maybe_restore added instead of the old maybe_push
  436. Revision 1.16 2002/05/12 19:59:05 carl
  437. * some small portability fixes
  438. Revision 1.15 2002/05/12 16:53:16 peter
  439. * moved entry and exitcode to ncgutil and cgobj
  440. * foreach gets extra argument for passing local data to the
  441. iterator function
  442. * -CR checks also class typecasts at runtime by changing them
  443. into as
  444. * fixed compiler to cycle with the -CR option
  445. * fixed stabs with elf writer, finally the global variables can
  446. be watched
  447. * removed a lot of routines from cga unit and replaced them by
  448. calls to cgobj
  449. * u32bit-s32bit updates for and,or,xor nodes. When one element is
  450. u32bit then the other is typecasted also to u32bit without giving
  451. a rangecheck warning/error.
  452. * fixed pascal calling method with reversing also the high tree in
  453. the parast, detected by tcalcst3 test
  454. Revision 1.14 2002/04/25 20:16:40 peter
  455. * moved more routines from cga/n386util
  456. Revision 1.13 2002/04/21 15:31:05 carl
  457. * changeregsize -> rg.makeregsize
  458. + a_jmp_always added
  459. Revision 1.12 2002/04/15 19:44:20 peter
  460. * fixed stackcheck that would be called recursively when a stack
  461. error was found
  462. * generic changeregsize(reg,size) for i386 register resizing
  463. * removed some more routines from cga unit
  464. * fixed returnvalue handling
  465. * fixed default stacksize of linux and go32v2, 8kb was a bit small :-)
  466. Revision 1.11 2002/04/04 19:06:10 peter
  467. * removed unused units
  468. * use tlocation.size in a_*loc*() routines
  469. Revision 1.10 2002/04/02 20:29:02 jonas
  470. * optimized the code generated by the a_op_const_* and a_op64_const
  471. methods
  472. Revision 1.9 2002/04/02 17:11:33 peter
  473. * tlocation,treference update
  474. * LOC_CONSTANT added for better constant handling
  475. * secondadd splitted in multiple routines
  476. * location_force_reg added for loading a location to a register
  477. of a specified size
  478. * secondassignment parses now first the right and then the left node
  479. (this is compatible with Kylix). This saves a lot of push/pop especially
  480. with string operations
  481. * adapted some routines to use the new cg methods
  482. }