From 1f099e81a73674791cd0099e6e439d7d69486db7 Mon Sep 17 00:00:00 2001 From: florian Date: Sat, 24 May 2003 21:12:57 +0000 Subject: [PATCH] * if something doesn't work with callparatemp, the define callparatemp should be used because other processors with reigster calling conventions depend on this as well --- compiler/fpcdefs.inc | 13 +++++++++++-- compiler/nadd.pas | 23 ++++++++++++++--------- 2 files changed, 25 insertions(+), 11 deletions(-) diff --git a/compiler/fpcdefs.inc b/compiler/fpcdefs.inc index 66450593c1..4972ef6cf3 100644 --- a/compiler/fpcdefs.inc +++ b/compiler/fpcdefs.inc @@ -57,6 +57,10 @@ {$undef cpuflags} {$endif alpha} +{$ifdef sparc} + {$define callparatemp} +{$endif sparc} + {$ifdef powerpc} {$define callparatemp} {$endif powerpc} @@ -73,7 +77,12 @@ { $Log$ - Revision 1.19 2003-05-09 17:47:02 peter + Revision 1.20 2003-05-24 21:12:57 florian + * if something doesn't work with callparatemp, the define callparatemp + should be used because other processors with reigster calling conventions + depend on this as well + + Revision 1.19 2003/05/09 17:47:02 peter * self moved to hidden parameter * removed hdisposen,hnewn,selfn @@ -132,4 +141,4 @@ Revision 1.3 2002/07/04 18:56:50 florian + log added -} +} \ No newline at end of file diff --git a/compiler/nadd.pas b/compiler/nadd.pas index 976c47f1ba..c40e60aa8d 100644 --- a/compiler/nadd.pas +++ b/compiler/nadd.pas @@ -1,4 +1,4 @@ - { +{ $Id$ Copyright (c) 1998-2002 by Florian Klaempfl @@ -777,11 +777,11 @@ implementation if not(is_constcharnode(left) and is_constcharnode(right)) then begin inserttypeconv(left,cshortstringtype); -{$ifndef powerpc} +{$ifndef callparatemp} hp := genaddsstringcharoptnode(self); result := hp; exit; -{$endif powerpc} +{$endif callparatemp} end; end; end @@ -1781,7 +1781,7 @@ implementation end else begin -{$ifndef powerpc} +{$ifndef callparatemp} { can create a call which isn't handled by callparatemp } if canbeaddsstringcharoptnode(self) then begin @@ -1790,7 +1790,7 @@ implementation exit; end else -{$endif powerpc} +{$endif callparatemp} begin { Fix right to be shortstring } if is_char(right.resulttype.def) then @@ -1799,7 +1799,7 @@ implementation firstpass(right); end; end; -{$ifndef powerpc} +{$ifndef callparatemp} { can create a call which isn't handled by callparatemp } if canbeaddsstringcsstringoptnode(self) then begin @@ -1807,7 +1807,7 @@ implementation pass_1 := hp; exit; end; -{$endif powerpc} +{$endif callparatemp} end; { otherwise, let addstring convert everything } result := first_addstring; @@ -1958,7 +1958,12 @@ begin end. { $Log$ - Revision 1.88 2003-05-23 22:57:38 jonas + Revision 1.89 2003-05-24 21:12:57 florian + * if something doesn't work with callparatemp, the define callparatemp + should be used because other processors with reigster calling conventions + depend on this as well + + Revision 1.88 2003/05/23 22:57:38 jonas - disable addoptnodes for powerpc, because they can generate calls in pass_2, so -dcallparatemp can't detect them as nested calls @@ -2174,4 +2179,4 @@ end. with string operations * adapted some routines to use the new cg methods -} +} \ No newline at end of file