Skip to content

Can't run (requested regions overlap) #1

Closed
@telmotrooper

Description

@telmotrooper

I'm using the toolchain binaries from SiFive.

I can compile the program just fine with the command:

riscv64-unknown-elf-gcc -march=rv64g -mabi=lp64 -static -mcmodel=medany \
  -fvisibility=hidden -nostdlib -nostartfiles -Thello.ld hello.s -o hello

And it generates the expected file:

file hello

hello: ELF 64-bit LSB executable, UCB RISC-V, version 1 (SYSV), statically linked, not stripped

But when I try to run the program in QEMU I get an error:

qemu-system-riscv64 -nographic -machine sifive_u -kernel hello

rom: requested regions overlap (rom phdr #0: hello. free=0x000000008000e250, addr=0x0000000080000000)
qemu-system-riscv64: rom check and register reset failed

My QEMU version is:

qemu-system-riscv64 --versionQEMU emulator version 5.1.0

Copyright (c) 2003-2020 Fabrice Bellard and the QEMU Project developers

Can you please help me understand why is the program not working?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions