cvsuser 02/12/05 11:48:52
Modified: . MANIFEST dod.c
config/gen/makefiles root.in
Added: . cpu_dep.c
Log:
Hopeefully fix the register issues with SPARC systems
Courtesy of Jason Gloudon <[EMAIL PROTECTED]>
Revision Changes Path
1.273 +1 -0 parrot/MANIFEST
Index: MANIFEST
===================================================================
RCS file: /cvs/public/parrot/MANIFEST,v
retrieving revision 1.272
retrieving revision 1.273
diff -u -w -r1.272 -r1.273
--- MANIFEST 5 Dec 2002 04:29:42 -0000 1.272
+++ MANIFEST 5 Dec 2002 19:48:50 -0000 1.273
@@ -1680,3 +1680,4 @@
vtable.tbl
vtable_h.pl
warnings.c
+cpu_dep.c
1.34 +5 -1 parrot/dod.c
Index: dod.c
===================================================================
RCS file: /cvs/public/parrot/dod.c,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -w -r1.33 -r1.34
--- dod.c 22 Nov 2002 22:06:05 -0000 1.33
+++ dod.c 5 Dec 2002 19:48:50 -0000 1.34
@@ -1,7 +1,7 @@
/* dod.c
* Copyright: (When this is determined...it will go here)
* CVS Info
- * $Id: dod.c,v 1.33 2002/11/22 22:06:05 leo Exp $
+ * $Id: dod.c,v 1.34 2002/12/05 19:48:50 dan Exp $
* Overview:
* Handles dead object destruction of the various headers
* Data Structure and Algorithms:
@@ -20,6 +20,7 @@
int CONSERVATIVE_POINTER_CHASING = 0;
#endif
+extern flush_register_windows(void);
static size_t find_common_mask(size_t val1, size_t val2);
PMC *
@@ -502,6 +503,9 @@
size_t mask = find_common_mask(buffer_min < pmc_min ? buffer_min : pmc_min,
buffer_max > pmc_max ? buffer_max : pmc_max);
+
+ /* Flush register windows if needed */
+ flush_register_windows();
if (!lo_var_ptr)
return last;
1.1 parrot/cpu_dep.c
Index: cpu_dep.c
===================================================================
/* cpu_dep.c
* Copyright: (When this is determined...it will go here)
* CVS Info
* $Id: cpu_dep.c,v 1.1 2002/12/05 19:48:50 dan Exp $
* Overview:
* CPU
dependent functions
* Data Structure and Algorithms:
* History:
* Notes:
*
References:
*/
#include "parrot/parrot.h"
void flush_register_windows(void){
#ifdef __sparc
static union {
int insns[4];
double align_hack[2];
} u = { {
#ifdef __sparcv9
0x81580000, /* flushw */
#else
0x91d02003, /* ta ST_FLUSH_WINDOWS */
#endif
0x81c3e008, /* retl */
0x01000000 /*
nop */
} };
static void (*fn_ptr)(void) = (void (*)(void))&u.align_hack[0];
fn_ptr();
#else
return;
#endif
}
1.60 +3 -1 parrot/config/gen/makefiles/root.in
Index: root.in
===================================================================
RCS file: /cvs/public/parrot/config/gen/makefiles/root.in,v
retrieving revision 1.59
retrieving revision 1.60
diff -u -w -r1.59 -r1.60
--- root.in 26 Nov 2002 00:45:10 -0000 1.59
+++ root.in 5 Dec 2002 19:48:52 -0000 1.60
@@ -106,7 +106,7 @@
packout$(O) byteorder$(O) debug$(O) smallobject$(O) \
headers$(O) dod$(O) method_util$(O) exit$(O) \
misc$(O) spf_render$(O) spf_vtable$(O) datatypes$(O) fingerprint$(O) \
- nci$(O)
+ nci$(O) cpu_dep$(O)
O_FILES = $(INTERP_O_FILES) $(IO_O_FILES) $(CLASS_O_FILES) \
$(ENCODING_O_FILES) $(CHARTYPE_O_FILES)
@@ -424,6 +424,8 @@
exit$(O) : $(GENERAL_H_FILES) exit.c
nci$(O) : $(GENERAL_H_FILES) exit.c
+
+cpu_dep$(O) : $(GENERAL_H_FILES)
nci.c : call_list.txt build_nativecall.pl
perl build_nativecall.pl call_list.txt