summaryrefslogtreecommitdiff
path: root/gnu/packages/patches
diff options
context:
space:
mode:
authorSimon South <simon@simonsouth.net>2020-06-10 11:03:39 -0400
committerMarius Bakke <marius@gnu.org>2020-06-22 23:52:55 +0200
commita212006048b14dc8614010a16db5bc6585dbf699 (patch)
tree51706334e055494be414d4290e490f8e19b59b20 /gnu/packages/patches
parentcf66096d51de78c6e46c55d81d654d9941a5bc4c (diff)
downloadguix-patches-a212006048b14dc8614010a16db5bc6585dbf699.tar
guix-patches-a212006048b14dc8614010a16db5bc6585dbf699.tar.gz
gnu: jamvm: Fix to work with current gcc and glibc.
* gnu/packages/java.scm (jamvm)[source]: Add patch. (jamvm-1-bootstrap)[native-inputs]: Remove. * gnu/packages/patches/jamvm-2.0.0-disable-branch-patching.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. Signed-off-by: Marius Bakke <marius@gnu.org>
Diffstat (limited to 'gnu/packages/patches')
-rw-r--r--gnu/packages/patches/jamvm-2.0.0-disable-branch-patching.patch31
1 files changed, 31 insertions, 0 deletions
diff --git a/gnu/packages/patches/jamvm-2.0.0-disable-branch-patching.patch b/gnu/packages/patches/jamvm-2.0.0-disable-branch-patching.patch
new file mode 100644
index 0000000000..1352ed7803
--- /dev/null
+++ b/gnu/packages/patches/jamvm-2.0.0-disable-branch-patching.patch
@@ -0,0 +1,31 @@
+From d80cfc83325f8e95d35ecd9f15b36b96fa9ed3ee Mon Sep 17 00:00:00 2001
+From: Simon South <simon@simonsouth.net>
+Date: Sat, 6 Jun 2020 18:56:56 -0400
+Subject: [PATCH] Disable branch-patching
+
+This patch disables JamVM's branch-patching optimization, which tends
+to make JamVM fail with an "Illegal instruction" error on x86_64 (and
+possibly other architectures that use variable-length instructions)
+when built using modern versions of gcc and glibc.
+---
+ src/init.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/src/init.c b/src/init.c
+index 32539cf..38ad54b 100644
+--- a/src/init.c
++++ b/src/init.c
+@@ -72,8 +72,8 @@ void setDefaultInitArgs(InitArgs *args) {
+ #ifdef INLINING
+ args->replication_threshold = 10;
+ args->profile_threshold = 10;
+- args->branch_patching_dup = TRUE;
+- args->branch_patching = TRUE;
++ args->branch_patching_dup = FALSE;
++ args->branch_patching = FALSE;
+ args->print_codestats = FALSE;
+ args->join_blocks = TRUE;
+ args->profiling = TRUE;
+--
+2.25.2
+