From 7872180a6ef5f531584f49d808ce8da79081ad4f Mon Sep 17 00:00:00 2001 From: Taylor R Campbell Date: Tue, 15 Jan 2019 03:09:58 +0000 Subject: [PATCH] Block offset units are instructions, not bytes, so we get two more bits. --- src/compiler/machines/aarch64/assmd.scm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/compiler/machines/aarch64/assmd.scm b/src/compiler/machines/aarch64/assmd.scm index aedb36042..7aa3ea8f2 100644 --- a/src/compiler/machines/aarch64/assmd.scm +++ b/src/compiler/machines/aarch64/assmd.scm @@ -41,12 +41,12 @@ USA. 16) (define-integrable maximum-block-offset - ;; PC always aligned on 32-bit boundary + ;; PC always aligned on 32-bit boundary. Use the extra bit. (- (expt 2 (1+ block-offset-width)) 4)) (define-integrable (block-offset->bit-string offset start?) (unsigned-integer->bit-string block-offset-width - (+ (* 2 offset) + (+ (shift-left (quotient offset 4) 1) (if start? 0 1)))) ;;; Machine dependent instruction order -- 2.25.1