1) Fix for bug 3392 - [GCCE] GCC definition for FORCEINLINE required for e32test build. GCC_SURGE
authorMike Kinghan <mikek@symbian.org>
Mon, 26 Jul 2010 18:22:55 +0100
branchGCC_SURGE
changeset 235 cbd07013118c
parent 234 56f96efe467a
child 236 7dc50dc94301
1) Fix for bug 3392 - [GCCE] GCC definition for FORCEINLINE required for e32test build. 2) Fix for bug 3391 - [GCCE] ARM GNU inline assembly needed for drtaeabi.cpp in e32test build.
kernel/eka/compsupp/rvct/drtaeabi.cpp
kernel/eka/compsupp/symaehabi/cxxabi.h
kernel/eka/compsupp/symaehabi/unwind_env.h
--- a/kernel/eka/compsupp/rvct/drtaeabi.cpp	Mon Jul 26 14:13:30 2010 +0100
+++ b/kernel/eka/compsupp/rvct/drtaeabi.cpp	Mon Jul 26 18:22:55 2010 +0100
@@ -48,6 +48,7 @@
 
 extern const char * const  $Sub$$_ZTSv = "v";
 
+#if defined(__ARMCC__)
 __asm void __rt_exporter_dummy()
 	{
 	IMPORT _ZTVN10__cxxabiv123__fundamental_type_infoE [DYNAMIC]
@@ -64,6 +65,20 @@
 	DCD _ZTVN10__cxxabiv123__fundamental_type_infoE
 	DCD _ZTSv
 	}
+#elif defined(__GCCE__)
+__NAKED__ void __rt_exporter_dummy()
+	{
+	asm(".weak ZTVN10__cxxabiv123__fundamental_type_infoE");
+	asm(".extern _ZTSv");
+	asm(".global $Sub$$_ZTIv");
+	asm("$Sub$$_ZTIv");
+	asm(".word _ZTVN10__cxxabiv123__fundamental_type_infoE");
+	asm(".word _ZTSv");
+	}
+
+#else
+#error What compiler?
+#endif
 
 #if __ARMCC_VERSION > 400000
 asm void __symbian_prevent_export()
--- a/kernel/eka/compsupp/symaehabi/cxxabi.h	Mon Jul 26 14:13:30 2010 +0100
+++ b/kernel/eka/compsupp/symaehabi/cxxabi.h	Mon Jul 26 18:22:55 2010 +0100
@@ -78,37 +78,36 @@
 
 #ifdef __EDG_RUNTIME_USES_NAMESPACES
 namespace __cxxabiv1 {
-  using namespace std;
 #endif /* ifdef __EDG_RUNTIME_USES_NAMESPACES */
 
   /* type_info implementation classes */
 
 #pragma define_type_info
-  class __fundamental_type_info : public type_info {
+  class __fundamental_type_info : public std::type_info {
   public:
     virtual ~__fundamental_type_info();
   };
 
 #pragma define_type_info
-  class __array_type_info : public type_info {
+  class __array_type_info : public std::type_info {
   public:
     virtual ~__array_type_info();
   };
 
 #pragma define_type_info
-  class __function_type_info : public type_info {
+  class __function_type_info : public std::type_info {
   public:
     virtual ~__function_type_info();
   };
 
 #pragma define_type_info
-  class __enum_type_info : public type_info {
+  class __enum_type_info : public std::type_info {
   public:
     virtual ~__enum_type_info();
   };
 
 #pragma define_type_info
-  class __class_type_info : public type_info {
+  class __class_type_info : public std::type_info {
   public:
     virtual ~__class_type_info();
   };
@@ -146,7 +145,7 @@
   };
 
 #pragma define_type_info
-  class __pbase_type_info : public type_info {
+  class __pbase_type_info : public std::type_info {
   public:
     virtual ~__pbase_type_info();
     unsigned int __flags;
--- a/kernel/eka/compsupp/symaehabi/unwind_env.h	Mon Jul 26 14:13:30 2010 +0100
+++ b/kernel/eka/compsupp/symaehabi/unwind_env.h	Mon Jul 26 18:22:55 2010 +0100
@@ -162,8 +162,15 @@
 #define NORETURNDECL __declspec(noreturn)
 /* Inlining when compiling C */
 #define INLINE __inline
+#if defined(__ARMCC__)
 /* Stronger encouragement to inline */
 #define FORCEINLINE __forceinline
+#elif defined(__GCCE__)
+#define FORCEINLINE __inline __attribute__ ((always_inline))
+#else
+#error What compiler?
+#endif
+
 
 /* ---------------------------------------------------------------------- */