public inbox for java-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] Implement boehm-gc for AARCH64:ILP32
@ 2015-02-11  6:04 Andrew Pinski
  0 siblings, 0 replies; only message in thread
From: Andrew Pinski @ 2015-02-11  6:04 UTC (permalink / raw)
  To: GCC Patches, Java Patch List, bdwgc

[-- Attachment #1: Type: text/plain, Size: 619 bytes --]

Hi,
  This is a simple patch which allows all of the boehm-gc testsuite
that is included with GCC to pass for AARCH64:ILP32.
Basically we need to set CPP_WORDSZ to 32 and the alignment to 4 so we
detect pointers correctly.

OK for GCC?  Bootstrapped and tested for aarch64-linux-gnu with no
regressions and many libjava testcases now pass.

OK for boehm-gc upstream?  I don't have write access to upstream
sources though, if approved there please apply it also.

Thanks,
Andrew Pinski

GCC ChangeLog:
    * include/private/gcconfig.h (CPP_WORDSZ): Correct for AARCH64:ILP32.
    (ALIGNMENT): Correct for AARCH64:ILP32.

[-- Attachment #2: fixboehm-gc-gcc.diff.txt --]
[-- Type: text/plain, Size: 834 bytes --]

commit 7d15d08c61991c3f7fea822fb567106dde83a166
Author: Andrew Pinski <apinski@cavium.com>
Date:   Wed Feb 11 02:35:45 2015 +0000

    Fix boehm-gc for AARCH64:ILP32
    
    * include/private/gcconfig.h (CPP_WORDSZ): Correct for AARCH64:ILP32.
    (ALIGNMENT): Correct for AARCH64:ILP32.

diff --git a/boehm-gc/include/private/gcconfig.h b/boehm-gc/include/private/gcconfig.h
index 7e081d9..049e24c 100644
--- a/boehm-gc/include/private/gcconfig.h
+++ b/boehm-gc/include/private/gcconfig.h
@@ -1854,9 +1854,14 @@
 # endif
 
 # ifdef AARCH64
-#   define CPP_WORDSZ 64
 #   define MACH_TYPE "AARCH64"
-#   define ALIGNMENT 8
+#   ifdef __ILP32__
+#     define CPP_WORDSZ 32
+#     define ALIGNMENT 4
+#   else
+#     define CPP_WORDSZ 64
+#     define ALIGNMENT 8
+#   endif
 #   ifndef HBLKSIZE
 #     define HBLKSIZE 4096
 #   endif

[-- Attachment #3: fixboehm-gc-upstream.diff.txt --]
[-- Type: text/plain, Size: 508 bytes --]

diff --git a/include/private/gcconfig.h b/include/private/gcconfig.h
index aa80d53..989a734 100644
--- a/include/private/gcconfig.h
+++ b/include/private/gcconfig.h
@@ -2020,9 +2020,14 @@
 # endif
 
 # ifdef AARCH64
-#   define CPP_WORDSZ 64
 #   define MACH_TYPE "AARCH64"
-#   define ALIGNMENT 8
+#   ifdef __ILP32__
+#     define CPP_WORDSZ 32
+#     define ALIGNMENT 4
+#   else
+#     define CPP_WORDSZ 64
+#     define ALIGNMENT 8
+#   endif
 #   ifndef HBLKSIZE
 #     define HBLKSIZE 4096
 #   endif

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2015-02-11  6:04 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-02-11  6:04 [PATCH] Implement boehm-gc for AARCH64:ILP32 Andrew Pinski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).