Skip to content

Segfaults on arm64 macOS #2238

@Baltoli

Description

@Baltoli

While debugging an unrelated issue, I noticed that the default build-from-source instructions cause a lot of the EVM tests to segfault on my new arm64 mac.

This is in fact something that's been identified previously in the smoke-testing script for KEVM:

# This test currently segfaults on M1 Macs
if ! ${APPLE_SILICON:-false}; then
kevm run tests/failing/static_callcodecallcodecall_110_OOGMAfter_2_d0g0v0.json --target llvm \
--mode NORMAL --schedule BERLIN --chainid 1 \
> tests/failing/static_callcodecallcodecall_110_OOGMAfter_2_d0g0v0.json.llvm-out \
|| git --no-pager diff --no-index --ignore-all-space -R tests/failing/static_callcodecallcodecall_110_OOGMAfter_2_d0g0v0.json.llvm-out tests/failing/static_callcodecallcodecall_110_OOGMAfter_2_d0g0v0.json.expected
rm -rf tests/failing/static_callcodecallcodecall_110_OOGMAfter_2_d0g0v0.json.llvm-out
fi

The underlying issue is actually in upstream LLVM; I fixed it with a patch to LLVM that landed in LLVM 17. Unfortunately, we are currently blocked on making LLVM 17 available to Nix builds of K: runtimeverification/llvm-backend#927. As a workaround, you can build K from source against LLVM 17 using Homebrew and point the KEVM build system at that K installation.

There isn't a fix for this issue as such; it will be resolved once Nix-built K can use LLVM 17.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions