From: Doug Coleman Date: Fri, 16 Sep 2022 15:34:11 +0000 (-0400) Subject: arm64: 9999 BRK works again X-Git-Tag: 0.99~1084 X-Git-Url: https://gitweb.factorcode.org/gitweb.cgi?p=factor.git;a=commitdiff_plain;h=0a4cd2fb2dc47eaffe03ff6b1b601d84fd789230;ds=sidebyside arm64: 9999 BRK works again --- diff --git a/arm64-notes.txt b/arm64-notes.txt new file mode 100644 index 0000000000..319d48eb7e --- /dev/null +++ b/arm64-notes.txt @@ -0,0 +1,20 @@ +subprimitives are arm64 bytes +primitives are C calls + + + +CALLBACK-STUB jit-define gets called first +set 9999 BRK to break there in lldb +lldb ./factor +run -i=boot.unix-arm.64.image + +then do c-to-factor + + +rel- relocations aka fixups +rel-vm relocation for vm in sidetable + +relocation addresses are 64bit +look at powerpc backend +return a 64bit value in a register + diff --git a/basis/bootstrap/assembler/arm.64.factor b/basis/bootstrap/assembler/arm.64.factor index b77fade66c..6079c7a0c9 100644 --- a/basis/bootstrap/assembler/arm.64.factor +++ b/basis/bootstrap/assembler/arm.64.factor @@ -300,6 +300,9 @@ big-endian off ! # All arm.64 subprimitives { { c-to-factor [ + ! Set up the datastack and retainstack registers + ! and jump into the quotation + ! write() ! 68 X8 MOVwi64 @@ -444,6 +447,8 @@ big-endian off ! C to Factor entry point [ + + 9999 BRK ! ! Optimizing compiler's side of callback accesses ! ! arguments that are on the stack via the frame pointer. ! ! On x86-32 fastcall, and x86-64, some arguments are passed diff --git a/basis/bootstrap/stage1.factor b/basis/bootstrap/stage1.factor index 0e9c8053f4..dfb15dede7 100644 --- a/basis/bootstrap/stage1.factor +++ b/basis/bootstrap/stage1.factor @@ -55,5 +55,9 @@ load-help? off ] if ] % ] [ ] make + +drop + +[ ] OBJ-STARTUP-QUOT bootstrap.image.private:special-objects get set-at