Skip to content

How userstart affect Virtual Addressing in riscv tests? #583

@iamazizhaider

Description

@iamazizhaider

Can you guide me about this userstart that the we set in Virtual environment.

When I run on spike, this sets the sepc register causing system to go into "exception trap_instruction_page_fault, epc 0x0000000000001aa4". The very next instruction takes us into VA space. I am unable to understand this behaviour.
image

This image is from riscv-tests/env/v/entry.S

We basically load userstart address into a0 and load sepc from a0. That sepc is 0x1aa4 and how does it change to 0x780001aa4 when I change the memory map to 0x800000000 instead of 0x80000000. The userstart I got from dump is this (coudln't find source file)

image
I am fairly new to this so would appreciate any help I can get to make it running on my own software emulator that requires addressing space of 0x800000000.

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