1) Swapping to c++ instead of assembly implementations of several kernel APIs to avoid calling probably broken implementations of __EH_FRAME_?? macros GCC_SURGE
authormikek
Fri, 02 Jul 2010 09:53:45 +0100
branchGCC_SURGE
changeset 190 0d42d469e749
parent 188 38a7352e23d3
child 191 00cd07a1b0af
1) Swapping to c++ instead of assembly implementations of several kernel APIs to avoid calling probably broken implementations of __EH_FRAME_?? macros 2) Commenting out otherwise unavoidable calls to __EH_FRAME_?? macros in uc_exe.cia. This is a temporary hack. Both changes to see if they get past an early kernel panic in the Syborg ROM from the current build: EH ERROR: no exception descriptor for address 0x801eb277 Thread efile.exe::Main Panic USER-EXEC 3
kernel/eka/euser/epoc/arm/uc_exe.cia
kernel/eka/include/cpudefs.h
--- a/kernel/eka/euser/epoc/arm/uc_exe.cia	Wed Jun 30 18:53:50 2010 +0100
+++ b/kernel/eka/euser/epoc/arm/uc_exe.cia	Fri Jul 02 09:53:45 2010 +0100
@@ -61,11 +61,15 @@
 
 	asm("mov r11, sp ");		// save stack pointer
 
+#if 0 /* IMK: Temorarily deleting these __EH_FRAME calls to discover if the suspect
+	GCCE definitions of them are behind a kernel panic. */
+
 	// The frame starts 84 bytes (up) from r11 i.e. CFA is r11 + 84
 	__EH_FRAME_ADDRESS(sp, 84) // Reg needs to be sp (=r11) here for gcce
 	// we can only restore callee-save values, but that's what we want if we 'leave'
 	// saved link is -8 bytes from CFA (= r11 + 0x24 + 0x20 + 0x8)
 	__EH_FRAME_SAVE1(lr, -8)
+#endif
 
 	// the other callee saves start at -48 from CFA (= r11 + 0x24)
 #if 0
@@ -76,7 +80,9 @@
 #if defined(__ARMCC__)
 	FRAME SAVE {r4-r11}, -48
 #elif defined(__GCCE__)
+#if 0 /* IMK: see above */
 	__EH_FRAME_SAVE1(r4-r11,-48)
+#endif
 #else
 #error What compiler?	
 #endif
--- a/kernel/eka/include/cpudefs.h	Wed Jun 30 18:53:50 2010 +0100
+++ b/kernel/eka/include/cpudefs.h	Fri Jul 02 09:53:45 2010 +0100
@@ -245,10 +245,10 @@
 	#define __HEAP_MACHINE_CODED__
 	#define __REALS_MACHINE_CODED__
 	#define __COBJECT_MACHINE_CODED__
-	#define __CACTIVESCHEDULER_MACHINE_CODED__
-	#define __CSERVER_MACHINE_CODED__
-//	#define __ARRAY_MACHINE_CODED__ IMK working around bug #2976
-	#define __HUFFMAN_MACHINE_CODED__
+//	#define __CACTIVESCHEDULER_MACHINE_CODED__ IMK: working around bug #1409
+//	#define __CSERVER_MACHINE_CODED__ IMK: working around bug #1409
+//	#define __ARRAY_MACHINE_CODED__ IMK: working around bug #2976, #2976 
+//	#define __HUFFMAN_MACHINE_CODED__ IMK: working around bug #1409
 #if defined(__MARM_ARM4__) || defined(__MARM_ARMI__) || defined(__MARM_THUMB__) || defined(__MARM_ARMV4__) || defined(__MARM_ARMV5__)
 	#define __DES16_MACHINE_CODED_HWORD__
 #endif