[Vm-dev] [OpenSmalltalk/opensmalltalk-vm] Illegal instruction `mrs x0, id_aa64isar0_el1` on aarch64 on older Linux kernels (Issue #608)

Eliot Miranda notifications at github.com
Tue Nov 30 16:06:26 UTC 2021


Hi Tony,

> On Nov 29, 2021, at 7:51 AM, Tony Garnock-Jones ***@***.***> wrote:
> 
> 
> I'm running Cog on aarch64, and because I have an old linux kernel (v3.18.140) which I cannot upgrade (it's a repurposed PostmarketOS Android device), Cog yields illegal instruction trying to execute mrs x0, id_aa64isar0_el1. This instruction is privileged, but later linux kernels trap and emulate it for userspace.
> 
> Given that it's currently only being used to detect presence of atomic instructions (self setHasAtomicInstructions: (idISAR0 >> 20 bitAnd: 2r1111) = 2r10), and there's a kernel API for retrieving that specific bit of information (https://www.kernel.org/doc/html/latest/arm64/elf_hwcaps.html suggests HWCAP_ATOMICS), perhaps instead of using the instruction directly Cog could call the relevant getauxval variant?
> 

Good suggestion.  I’ll try and get this folded in I the next couple of days.
> For now, I have the Stack VM running well on aarch64, so I can make progress, even if it is a little slower than it could be :-)
> 
>> You are receiving this because you are subscribed to this thread.
> Reply to this email directly, view it on GitHub, or unsubscribe.
> Triage notifications on the go with GitHub Mobile for iOS or Android. 


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/OpenSmalltalk/opensmalltalk-vm/issues/608#issuecomment-982780994
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/vm-dev/attachments/20211130/15211c16/attachment.html>


More information about the Vm-dev mailing list