about summary refs log tree commit diff stats
path: root/src/main.c
diff options
context:
space:
mode:
authorptitSeb <sebastien.chev@gmail.com>2023-10-17 18:25:16 +0200
committerptitSeb <sebastien.chev@gmail.com>2023-10-17 18:25:16 +0200
commit6ef2b22a3ce4aaf5df5069dab226c1eeab806b19 (patch)
treef55bcee33bd10845d34de282f23cfeb1f7bb1507 /src/main.c
parentda19b2008a8e4afc75ec46a43453dcc93256d48e (diff)
downloadbox64-6ef2b22a3ce4aaf5df5069dab226c1eeab806b19.tar.gz
box64-6ef2b22a3ce4aaf5df5069dab226c1eeab806b19.zip
[ARM64_DYNAREC] Added support for BOX4_DYNAREC_ALIGNED_ATOMICS
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c
index a66e743b..cdbff19c 100644
--- a/src/main.c
+++ b/src/main.c
@@ -66,6 +66,7 @@ int box64_dynarec_jvm = 1;
 int box64_dynarec_wait = 1;
 int box64_dynarec_test = 0;
 int box64_dynarec_missing = 0;
+int box64_dynarec_aligned_atomics = 0;
 uintptr_t box64_nodynarec_start = 0;
 uintptr_t box64_nodynarec_end = 0;
 #ifdef ARM64
@@ -637,6 +638,15 @@ void LoadLogEnv()
         if(box64_dynarec_fastpage)
             printf_log(LOG_INFO, "Dynarec will use Fast HotPage\n");
     }
+    p = getenv("BOX64_DYNAREC_ALIGNED_ATOMICS");
+    if(p) {
+        if(strlen(p)==1) {
+            if(p[0]>='0' && p[0]<='1')
+                box64_dynarec_aligned_atomics = p[0]-'0';
+        }
+        if(box64_dynarec_aligned_atomics)
+            printf_log(LOG_INFO, "Dynarec will generate only aligned atomics code\n");
+    }
     p = getenv("BOX64_DYNAREC_MISSING");
     if(p) {
         if(strlen(p)==1) {