This is the mail archive of the crossgcc@sourceware.org mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more information.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

lwsync used on e500(v2) targets


I just submitted a patch to the java-patches mailing list
(http://gcc.gnu.org/ml/java-patches/2009-q4/msg00058.html)

I would like to get this patch into the crosstool for older
gcc releases. I used 4.3.2 and 4.3.3.

I attached the patch for these two releases.

I hope this helps some people to get gcj working on
e500(v2) targets.
--- gcc-4.3.3/boehm-gc/include/private/gc_locks.h.org	2009-12-06 06:46:46.298479999 +0100
+++ gcc-4.3.3/boehm-gc/include/private/gc_locks.h	2009-12-06 06:48:16.038566974 +0100
@@ -178,7 +178,11 @@
 #     endif
 #     define GC_TEST_AND_SET_DEFINED
       inline static void GC_clear(volatile unsigned int *addr) {
+#ifdef __NO_LWSYNC__
+	__asm__ __volatile__("sync" : : : "memory");
+#else
 	__asm__ __volatile__("lwsync" : : : "memory");
+#endif
         *(addr) = 0;
       }
 #     define GC_CLEAR_DEFINED

--
For unsubscribe information see http://sourceware.org/lists.html#faq

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]