cpupara.pas 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692
  1. {
  2. $Id$
  3. Copyright (c) 2002 by Florian Klaempfl
  4. Generates the argument location information for 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 bymethodpointer
  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. { Generates the argument location information for i386.
  19. }
  20. unit cpupara;
  21. {$i fpcdefs.inc}
  22. interface
  23. uses
  24. cclasses,globtype,
  25. aasmtai,
  26. cpubase,
  27. cgbase,
  28. symconst,symtype,symdef,paramgr;
  29. type
  30. ti386paramanager = class(tparamanager)
  31. function ret_in_param(def : tdef;calloption : tproccalloption) : boolean;override;
  32. function push_addr_param(varspez:tvarspez;def : tdef;calloption : tproccalloption) : boolean;override;
  33. function get_para_align(calloption : tproccalloption):byte;override;
  34. function get_volatile_registers_int(calloption : tproccalloption):tcpuregisterset;override;
  35. function get_volatile_registers_fpu(calloption : tproccalloption):tcpuregisterset;override;
  36. function get_volatile_registers_mm(calloption : tproccalloption):tcpuregisterset;override;
  37. { Returns the location for the nr-st 32 Bit int parameter
  38. if every parameter before is an 32 Bit int parameter as well
  39. and if the calling conventions for the helper routines of the
  40. rtl are used.
  41. }
  42. function getintparaloc(calloption : tproccalloption; nr : longint) : tparalocation;override;
  43. function create_paraloc_info(p : tabstractprocdef; side: tcallercallee):longint;override;
  44. function create_varargs_paraloc_info(p : tabstractprocdef; varargspara:tvarargspara):longint;override;
  45. private
  46. procedure create_funcret_paraloc_info(p : tabstractprocdef; side: tcallercallee);
  47. function create_stdcall_paraloc_info(p : tabstractprocdef; side: tcallercallee):longint;
  48. function create_register_paraloc_info(p : tabstractprocdef; side: tcallercallee):longint;
  49. end;
  50. implementation
  51. uses
  52. cutils,
  53. systems,verbose,
  54. defutil,
  55. cpuinfo;
  56. const
  57. parasupregs : array[0..2] of tsuperregister = (RS_EAX,RS_EDX,RS_ECX);
  58. {****************************************************************************
  59. TI386PARAMANAGER
  60. ****************************************************************************}
  61. function ti386paramanager.ret_in_param(def : tdef;calloption : tproccalloption) : boolean;
  62. begin
  63. case target_info.system of
  64. system_i386_win32 :
  65. begin
  66. case def.deftype of
  67. recorddef :
  68. begin
  69. { Win32 GCC returns small records in the FUNCTION_RETURN_REG.
  70. For stdcall we follow delphi instead of GCC }
  71. if (calloption in [pocall_cdecl,pocall_cppdecl]) and
  72. (def.size<=8) then
  73. begin
  74. result:=false;
  75. exit;
  76. end;
  77. end;
  78. end;
  79. end;
  80. end;
  81. result:=inherited ret_in_param(def,calloption);
  82. end;
  83. function ti386paramanager.push_addr_param(varspez:tvarspez;def : tdef;calloption : tproccalloption) : boolean;
  84. begin
  85. case target_info.system of
  86. system_i386_win32 :
  87. begin
  88. case def.deftype of
  89. recorddef :
  90. begin
  91. { Win32 passes small records on the stack for call by
  92. value }
  93. if (calloption in [pocall_stdcall,pocall_cdecl,pocall_cppdecl]) and
  94. (varspez=vs_value) and
  95. (def.size<=8) then
  96. begin
  97. result:=false;
  98. exit;
  99. end;
  100. end;
  101. arraydef :
  102. begin
  103. { Win32 passes arrays on the stack for call by
  104. value }
  105. if (calloption in [pocall_stdcall,pocall_cdecl,pocall_cppdecl]) and
  106. (varspez=vs_value) and
  107. (tarraydef(def).highrange>=tarraydef(def).lowrange) then
  108. begin
  109. result:=true;
  110. exit;
  111. end;
  112. end;
  113. end;
  114. end;
  115. end;
  116. result:=inherited push_addr_param(varspez,def,calloption);
  117. end;
  118. function ti386paramanager.get_para_align(calloption : tproccalloption):byte;
  119. begin
  120. if calloption=pocall_oldfpccall then
  121. begin
  122. if target_info.system in [system_i386_go32v2,system_i386_watcom] then
  123. result:=2
  124. else
  125. result:=4;
  126. end
  127. else
  128. result:=std_param_align;
  129. end;
  130. function ti386paramanager.get_volatile_registers_int(calloption : tproccalloption):tcpuregisterset;
  131. begin
  132. case calloption of
  133. pocall_internproc :
  134. result:=[];
  135. pocall_compilerproc :
  136. begin
  137. if pocall_default=pocall_oldfpccall then
  138. result:=[RS_EAX,RS_EDX,RS_ECX,RS_ESI,RS_EDI,RS_EBX]
  139. else
  140. result:=[RS_EAX,RS_EDX,RS_ECX];
  141. end;
  142. pocall_inline,
  143. pocall_register,
  144. pocall_safecall,
  145. pocall_stdcall,
  146. pocall_cdecl,
  147. pocall_cppdecl :
  148. result:=[RS_EAX,RS_EDX,RS_ECX];
  149. pocall_far16,
  150. pocall_pascal,
  151. pocall_oldfpccall :
  152. result:=[RS_EAX,RS_EDX,RS_ECX,RS_ESI,RS_EDI,RS_EBX];
  153. else
  154. internalerror(200309071);
  155. end;
  156. end;
  157. function ti386paramanager.get_volatile_registers_fpu(calloption : tproccalloption):tcpuregisterset;
  158. begin
  159. result:=[0..first_fpu_imreg-1];
  160. end;
  161. function ti386paramanager.get_volatile_registers_mm(calloption : tproccalloption):tcpuregisterset;
  162. begin
  163. result:=[0..first_sse_imreg-1];
  164. end;
  165. function ti386paramanager.getintparaloc(calloption : tproccalloption; nr : longint) : tparalocation;
  166. begin
  167. fillchar(result,sizeof(tparalocation),0);
  168. result.size:=OS_INT;
  169. result.alignment:=get_para_align(calloption);
  170. if calloption=pocall_register then
  171. begin
  172. if (nr<=high(parasupregs)+1) then
  173. begin
  174. if nr=0 then
  175. internalerror(200309271);
  176. result.loc:=LOC_REGISTER;
  177. result.register:=newreg(R_INTREGISTER,parasupregs[nr-1],R_SUBWHOLE);
  178. end
  179. else
  180. begin
  181. result.loc:=LOC_REFERENCE;
  182. result.reference.index:=NR_STACK_POINTER_REG;
  183. result.reference.offset:=POINTER_SIZE*nr;
  184. end;
  185. end
  186. else
  187. begin
  188. result.loc:=LOC_REFERENCE;
  189. result.reference.index:=NR_STACK_POINTER_REG;
  190. result.reference.offset:=POINTER_SIZE*nr;
  191. end;
  192. end;
  193. procedure ti386paramanager.create_funcret_paraloc_info(p : tabstractprocdef; side: tcallercallee);
  194. var
  195. paraloc : tparalocation;
  196. begin
  197. { Function return }
  198. fillchar(paraloc,sizeof(tparalocation),0);
  199. paraloc.size:=def_cgsize(p.rettype.def);
  200. { Return in FPU register? }
  201. if p.rettype.def.deftype=floatdef then
  202. begin
  203. paraloc.loc:=LOC_FPUREGISTER;
  204. paraloc.register:=NR_FPU_RESULT_REG;
  205. end
  206. else
  207. { Return in register? }
  208. if not ret_in_param(p.rettype.def,p.proccalloption) then
  209. begin
  210. paraloc.loc:=LOC_REGISTER;
  211. {$ifndef cpu64bit}
  212. if paraloc.size in [OS_64,OS_S64] then
  213. begin
  214. paraloc.register64.reglo:=NR_FUNCTION_RETURN64_LOW_REG;
  215. paraloc.register64.reghi:=NR_FUNCTION_RETURN64_HIGH_REG;
  216. end
  217. else
  218. {$endif cpu64bit}
  219. begin
  220. paraloc.register:=NR_FUNCTION_RETURN_REG;
  221. end;
  222. end
  223. else
  224. begin
  225. paraloc.loc:=LOC_REFERENCE;
  226. end;
  227. p.funcret_paraloc[side]:=paraloc;
  228. end;
  229. function ti386paramanager.create_varargs_paraloc_info(p : tabstractprocdef; varargspara:tvarargspara):longint;
  230. var
  231. hp : tparaitem;
  232. paraloc : tparalocation;
  233. l,
  234. varalign,
  235. paraalign,
  236. parasize : longint;
  237. begin
  238. parasize:=0;
  239. paraalign:=get_para_align(p.proccalloption);
  240. { Retrieve last know info from normal parameters }
  241. hp:=tparaitem(p.para.last);
  242. if assigned(hp) then
  243. parasize:=hp.paraloc[callerside].reference.offset;
  244. { Assign varargs }
  245. hp:=tparaitem(varargspara.first);
  246. while assigned(hp) do
  247. begin
  248. paraloc.size:=def_cgsize(hp.paratype.def);
  249. paraloc.loc:=LOC_REFERENCE;
  250. paraloc.alignment:=paraalign;
  251. paraloc.reference.index:=NR_STACK_POINTER_REG;
  252. l:=push_size(hp.paratyp,hp.paratype.def,p.proccalloption);
  253. varalign:=size_2_align(l);
  254. paraloc.reference.offset:=parasize;
  255. varalign:=used_align(varalign,paraalign,paraalign);
  256. parasize:=align(parasize+l,varalign);
  257. hp.paraloc[callerside]:=paraloc;
  258. hp:=tparaitem(hp.next);
  259. end;
  260. { We need to return the size allocated }
  261. result:=parasize;
  262. end;
  263. function ti386paramanager.create_stdcall_paraloc_info(p : tabstractprocdef; side: tcallercallee):longint;
  264. var
  265. hp : tparaitem;
  266. paraloc : tparalocation;
  267. l,
  268. varalign,
  269. paraalign,
  270. parasize : longint;
  271. begin
  272. parasize:=0;
  273. paraalign:=get_para_align(p.proccalloption);
  274. { we push Flags and CS as long
  275. to cope with the IRETD
  276. and we save 6 register + 4 selectors }
  277. if po_interrupt in p.procoptions then
  278. inc(parasize,8+6*4+4*2);
  279. { Offset is calculated like:
  280. sub esp,12
  281. mov [esp+8],para3
  282. mov [esp+4],para2
  283. mov [esp],para1
  284. call function
  285. That means the for pushes the para with the
  286. highest offset (see para3) needs to be pushed first
  287. }
  288. hp:=tparaitem(p.para.first);
  289. while assigned(hp) do
  290. begin
  291. if hp.paratyp in [vs_var,vs_out] then
  292. paraloc.size:=OS_ADDR
  293. else
  294. paraloc.size:=def_cgsize(hp.paratype.def);
  295. paraloc.loc:=LOC_REFERENCE;
  296. paraloc.alignment:=paraalign;
  297. if side=callerside then
  298. paraloc.reference.index:=NR_STACK_POINTER_REG
  299. else
  300. paraloc.reference.index:=NR_FRAME_POINTER_REG;
  301. l:=push_size(hp.paratyp,hp.paratype.def,p.proccalloption);
  302. varalign:=used_align(size_2_align(l),paraalign,paraalign);
  303. paraloc.reference.offset:=parasize;
  304. parasize:=align(parasize+l,varalign);
  305. hp.paraloc[side]:=paraloc;
  306. hp:=tparaitem(hp.next);
  307. end;
  308. { Adapt offsets for left-to-right calling }
  309. if p.proccalloption in pushleftright_pocalls then
  310. begin
  311. hp:=tparaitem(p.para.first);
  312. while assigned(hp) do
  313. begin
  314. l:=push_size(hp.paratyp,hp.paratype.def,p.proccalloption);
  315. varalign:=used_align(size_2_align(l),paraalign,paraalign);
  316. l:=align(l,varalign);
  317. hp.paraloc[side].reference.offset:=parasize-hp.paraloc[side].reference.offset-l;
  318. if side=calleeside then
  319. inc(hp.paraloc[side].reference.offset,target_info.first_parm_offset);
  320. hp:=tparaitem(hp.next);
  321. end;
  322. end
  323. else
  324. begin
  325. { Only need to adapt the callee side to include the
  326. standard stackframe size }
  327. if side=calleeside then
  328. begin
  329. hp:=tparaitem(p.para.first);
  330. while assigned(hp) do
  331. begin
  332. inc(hp.paraloc[side].reference.offset,target_info.first_parm_offset);
  333. hp:=tparaitem(hp.next);
  334. end;
  335. end;
  336. end;
  337. { We need to return the size allocated }
  338. result:=parasize;
  339. end;
  340. function ti386paramanager.create_register_paraloc_info(p : tabstractprocdef; side: tcallercallee):longint;
  341. var
  342. hp : tparaitem;
  343. paraloc : tparalocation;
  344. subreg : tsubregister;
  345. pushaddr,
  346. is_64bit : boolean;
  347. l,parareg,
  348. varalign,
  349. paraalign,
  350. parasize : longint;
  351. begin
  352. parareg:=0;
  353. parasize:=0;
  354. paraalign:=get_para_align(p.proccalloption);
  355. { Register parameters are assigned from left to right }
  356. hp:=tparaitem(p.para.first);
  357. while assigned(hp) do
  358. begin
  359. pushaddr:=push_addr_param(hp.paratyp,hp.paratype.def,p.proccalloption);
  360. if pushaddr then
  361. paraloc.size:=OS_ADDR
  362. else
  363. paraloc.size:=def_cgsize(hp.paratype.def);
  364. paraloc.alignment:=paraalign;
  365. is_64bit:=(paraloc.size in [OS_64,OS_S64,OS_F64]);
  366. {
  367. EAX
  368. EDX
  369. ECX
  370. Stack
  371. Stack
  372. 64bit values,floats,arrays and records are always
  373. on the stack.
  374. }
  375. if (parareg<=high(parasupregs)) and
  376. not(
  377. is_64bit or
  378. ((hp.paratype.def.deftype in [floatdef,recorddef,arraydef]) and
  379. (not pushaddr))
  380. ) then
  381. begin
  382. paraloc.loc:=LOC_REGISTER;
  383. if (paraloc.size=OS_NO) or is_64bit then
  384. subreg:=R_SUBWHOLE
  385. else
  386. subreg:=cgsize2subreg(paraloc.size);
  387. paraloc.alignment:=paraalign;
  388. paraloc.register:=newreg(R_INTREGISTER,parasupregs[parareg],subreg);
  389. inc(parareg);
  390. end
  391. else
  392. begin
  393. paraloc.loc:=LOC_REFERENCE;
  394. if side=callerside then
  395. paraloc.reference.index:=NR_STACK_POINTER_REG
  396. else
  397. paraloc.reference.index:=NR_FRAME_POINTER_REG;
  398. l:=push_size(hp.paratyp,hp.paratype.def,p.proccalloption);
  399. varalign:=size_2_align(l);
  400. paraloc.reference.offset:=parasize;
  401. varalign:=used_align(varalign,paraalign,paraalign);
  402. parasize:=align(parasize+l,varalign);
  403. end;
  404. hp.paraloc[side]:=paraloc;
  405. hp:=tparaitem(hp.next);
  406. end;
  407. { Register parameters are assigned from left-to-right, adapt offset
  408. for calleeside to be reversed }
  409. hp:=tparaitem(p.para.first);
  410. while assigned(hp) do
  411. begin
  412. if (hp.paraloc[side].loc=LOC_REFERENCE) then
  413. begin
  414. l:=push_size(hp.paratyp,hp.paratype.def,p.proccalloption);
  415. varalign:=used_align(size_2_align(l),paraalign,paraalign);
  416. l:=align(l,varalign);
  417. hp.paraloc[side].reference.offset:=parasize-hp.paraloc[side].reference.offset-l;
  418. if side=calleeside then
  419. inc(hp.paraloc[side].reference.offset,target_info.first_parm_offset);
  420. end;
  421. hp:=tparaitem(hp.next);
  422. end;
  423. { We need to return the size allocated }
  424. result:=parasize;
  425. end;
  426. function ti386paramanager.create_paraloc_info(p : tabstractprocdef; side: tcallercallee):longint;
  427. begin
  428. result:=0;
  429. case p.proccalloption of
  430. pocall_register :
  431. result:=create_register_paraloc_info(p,side);
  432. pocall_inline,
  433. pocall_compilerproc,
  434. pocall_internproc :
  435. begin
  436. { Use default calling }
  437. if (pocall_default=pocall_register) then
  438. result:=create_register_paraloc_info(p,side)
  439. else
  440. result:=create_stdcall_paraloc_info(p,side);
  441. end;
  442. else
  443. result:=create_stdcall_paraloc_info(p,side);
  444. end;
  445. create_funcret_paraloc_info(p,side);
  446. end;
  447. begin
  448. paramanager:=ti386paramanager.create;
  449. end.
  450. {
  451. $Log$
  452. Revision 1.49 2004-02-05 18:28:37 peter
  453. * x86_64 fixes for opsize
  454. Revision 1.48 2003/12/28 22:09:12 florian
  455. + setting of bit 6 of cr for c var args on ppc implemented
  456. Revision 1.47 2003/12/03 23:13:20 peter
  457. * delayed paraloc allocation, a_param_*() gets extra parameter
  458. if it needs to allocate temp or real paralocation
  459. * optimized/simplified int-real loading
  460. Revision 1.46 2003/12/01 18:44:15 peter
  461. * fixed some crashes
  462. * fixed varargs and register calling probs
  463. Revision 1.45 2003/11/28 17:24:22 peter
  464. * reversed offset calculation for caller side so it works
  465. correctly for interfaces
  466. Revision 1.44 2003/11/23 17:05:16 peter
  467. * register calling is left-right
  468. * parameter ordering
  469. * left-right calling inserts result parameter last
  470. Revision 1.43 2003/11/11 21:11:23 peter
  471. * check for push_addr
  472. Revision 1.42 2003/10/19 01:34:30 florian
  473. * some ppc stuff fixed
  474. * memory leak fixed
  475. Revision 1.41 2003/10/17 14:38:32 peter
  476. * 64k registers supported
  477. * fixed some memory leaks
  478. Revision 1.40 2003/10/11 16:06:42 florian
  479. * fixed some MMX<->SSE
  480. * started to fix ppc, needs an overhaul
  481. + stabs info improve for spilling, not sure if it works correctly/completly
  482. - MMX_SUPPORT removed from Makefile.fpc
  483. Revision 1.39 2003/10/10 17:48:14 peter
  484. * old trgobj moved to x86/rgcpu and renamed to trgx86fpu
  485. * tregisteralloctor renamed to trgobj
  486. * removed rgobj from a lot of units
  487. * moved location_* and reference_* to cgobj
  488. * first things for mmx register allocation
  489. Revision 1.38 2003/10/07 15:17:07 peter
  490. * inline supported again, LOC_REFERENCEs are used to pass the
  491. parameters
  492. * inlineparasymtable,inlinelocalsymtable removed
  493. * exitlabel inserting fixed
  494. Revision 1.37 2003/10/05 21:21:52 peter
  495. * c style array of const generates callparanodes
  496. * varargs paraloc fixes
  497. Revision 1.36 2003/10/03 22:00:33 peter
  498. * parameter alignment fixes
  499. Revision 1.35 2003/10/01 20:34:49 peter
  500. * procinfo unit contains tprocinfo
  501. * cginfo renamed to cgbase
  502. * moved cgmessage to verbose
  503. * fixed ppc and sparc compiles
  504. Revision 1.34 2003/09/30 21:02:37 peter
  505. * updates for inlining
  506. Revision 1.33 2003/09/28 17:55:04 peter
  507. * parent framepointer changed to hidden parameter
  508. * tloadparentfpnode added
  509. Revision 1.32 2003/09/28 13:35:24 peter
  510. * register calling updates
  511. Revision 1.31 2003/09/25 21:30:11 peter
  512. * parameter fixes
  513. Revision 1.30 2003/09/23 17:56:06 peter
  514. * locals and paras are allocated in the code generation
  515. * tvarsym.localloc contains the location of para/local when
  516. generating code for the current procedure
  517. Revision 1.29 2003/09/16 16:17:01 peter
  518. * varspez in calls to push_addr_param
  519. Revision 1.28 2003/09/10 08:31:47 marco
  520. * Patch from Peter for paraloc
  521. Revision 1.27 2003/09/09 21:03:17 peter
  522. * basics for x86 register calling
  523. Revision 1.26 2003/09/09 15:55:05 peter
  524. * winapi doesn't like pushing 8 byte record
  525. Revision 1.25 2003/09/08 18:28:51 peter
  526. * fix compilerproc for default=oldfpccall
  527. Revision 1.24 2003/09/07 22:09:35 peter
  528. * preparations for different default calling conventions
  529. * various RA fixes
  530. Revision 1.23 2003/09/03 15:55:01 peter
  531. * NEWRA branch merged
  532. Revision 1.22.2.2 2003/08/28 18:35:08 peter
  533. * tregister changed to cardinal
  534. Revision 1.22.2.1 2003/08/27 19:55:54 peter
  535. * first tregister patch
  536. Revision 1.22 2003/08/11 21:18:20 peter
  537. * start of sparc support for newra
  538. Revision 1.21 2003/07/05 20:11:41 jonas
  539. * create_paraloc_info() is now called separately for the caller and
  540. callee info
  541. * fixed ppc cycle
  542. Revision 1.20 2003/07/02 22:18:04 peter
  543. * paraloc splitted in callerparaloc,calleeparaloc
  544. * sparc calling convention updates
  545. Revision 1.19 2003/06/17 16:34:19 peter
  546. * freeintparaloc added
  547. Revision 1.18 2003/06/07 18:57:04 jonas
  548. + added freeintparaloc
  549. * ppc get/freeintparaloc now check whether the parameter regs are
  550. properly allocated/deallocated (and get an extra list para)
  551. * ppc a_call_* now internalerrors if pi_do_call is not yet set
  552. * fixed lot of missing pi_do_call's
  553. Revision 1.17 2003/06/06 14:41:22 peter
  554. * needs cpuinfo
  555. Revision 1.16 2003/06/06 07:36:06 michael
  556. + Forgot a line in patch from peter
  557. Revision 1.15 2003/06/06 07:35:14 michael
  558. + Patch to Patch from peter
  559. Revision 1.14 2003/06/06 07:34:11 michael
  560. + Patch from peter
  561. Revision 1.13 2003/06/05 20:58:05 peter
  562. * updated
  563. Revision 1.12 2003/05/30 23:57:08 peter
  564. * more sparc cleanup
  565. * accumulator removed, splitted in function_return_reg (called) and
  566. function_result_reg (caller)
  567. Revision 1.11 2003/05/13 15:16:13 peter
  568. * removed ret_in_acc, it's the reverse of ret_in_param
  569. * fixed ret_in_param for win32 cdecl array
  570. Revision 1.10 2003/04/22 23:50:23 peter
  571. * firstpass uses expectloc
  572. * checks if there are differences between the expectloc and
  573. location.loc from secondpass in EXTDEBUG
  574. Revision 1.9 2003/04/22 14:33:38 peter
  575. * removed some notes/hints
  576. Revision 1.8 2003/01/08 18:43:57 daniel
  577. * Tregister changed into a record
  578. Revision 1.7 2002/12/24 15:56:50 peter
  579. * stackpointer_alloc added for adjusting ESP. Win32 needs
  580. this for the pageprotection
  581. Revision 1.6 2002/12/17 22:19:33 peter
  582. * fixed pushing of records>8 bytes with stdcall
  583. * simplified hightree loading
  584. Revision 1.5 2002/11/18 17:32:00 peter
  585. * pass proccalloption to ret_in_xxx and push_xxx functions
  586. Revision 1.4 2002/11/15 01:58:56 peter
  587. * merged changes from 1.0.7 up to 04-11
  588. - -V option for generating bug report tracing
  589. - more tracing for option parsing
  590. - errors for cdecl and high()
  591. - win32 import stabs
  592. - win32 records<=8 are returned in eax:edx (turned off by default)
  593. - heaptrc update
  594. - more info for temp management in .s file with EXTDEBUG
  595. Revision 1.3 2002/08/09 07:33:04 florian
  596. * a couple of interface related fixes
  597. Revision 1.2 2002/07/11 14:41:32 florian
  598. * start of the new generic parameter handling
  599. Revision 1.1 2002/07/07 09:52:33 florian
  600. * powerpc target fixed, very simple units can be compiled
  601. * some basic stuff for better callparanode handling, far from being finished
  602. }