Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dynamic memory allocation support; refactoring #100

Merged
merged 7 commits into from
Feb 21, 2024
Merged

Conversation

koute
Copy link
Collaborator

@koute koute commented Feb 21, 2024

Fixes #52
Fixes #36
Reverts #80
Partially implements #72 (the xtheadcondmov extension)

The `Zicond` extension ends up producing pretty bad code. For example,
the following piece of code:

```
fn func(a0: u32, a1: u32, a2: u32) -> u32 {
    if a0 == 0 {
        a1
    } else {
        a2
    }
}
```

with `Zicond` produces *two* conditional moves and one `or`, while
with the `xtheadcondmov` it is a single conditional move and
a register to register move, as you'd expect.

The `Zicond` might be more in-line with RISC-V's philosophy of not
requiring more than two read ports per instruction, but we really
don't care, and this *does* produce a measurable and significant
performance difference.
@koute koute merged commit 37c6397 into master Feb 21, 2024
5 checks passed
@koute koute deleted the master_dynalloc branch February 21, 2024 16:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Make guest page size configurable Support runtime memory growth
1 participant