Skip to content

Port to the x86 Architecture #4385

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

Merged
merged 25 commits into from
May 14, 2025

Conversation

ioanaculic
Copy link
Contributor

Pull Request Overview

This pull request fixes the #4171:

  • removes the external dependency to the x86 crate
  • replaces the x86 structures using tock-registers
  • fixes some lints

Testing Strategy

This pull request was tested by @ioanaculic.

TODO or Help Wanted

Rebase and feeback.

I would like to get some feedback before I rebase this.

Documentation Updated

  • Updated the relevant files in /docs, or no updates are required.

Formatting

  • Ran make prepush.

bradjc
bradjc previously approved these changes Mar 26, 2025
Copy link
Contributor

@bradjc bradjc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is awesome!!

Note, I haven't reviewed any of the code, but the general directory structure looks good to me.

@alevy
Copy link
Member

alevy commented Mar 26, 2025

@reynoldsbd et al, are you able to maybe take a look at this? In particular, you might have the ability to test functional correctness with a downstream with more functionality elsewhere.

In general, my sense is that this looks like what we would want upstream, and if it otherwise smells right (basically works and doesn't have soundness etc issues), we should merge and fix functional issues as they arise (potentially as downstream users find them when moving to this implementation).

@reynoldsbd
Copy link
Contributor

This is awesome, thanks so much @ioanaculic for taking this closer to the finish line! :)

This all looks sensible on first glance. My team is doing some internal validation as well to make sure this all continues to work on our platforms. I'll follow up once we have some results to share. cc @alevy

One last topic: Apart from the x86 dependency, it's not immediately clear to me whether any of the other feedback or pending opens from the original PR have been addressed in this new PR. There was some good feedback over there and I'd hate for it to slip through the cracks. It'd also be nice to have the original PR description copied over to this one; I personally place high value on leaving a good trail in Git history, but I recognize that's not a top priority for everyone.

@lschuermann
Copy link
Member

We've discussed this briefly on the core call today.

@reynoldsbd It seems like this already includes all of the other changes which you made on the original PR in response to feedback, and is a strict superset of the commits of that PR.

Therefore, it seems easiest to reference back to #4171, perhaps take some of the original PR's description and feedback integrate it into this one, and finally push this new PR over the finish line.

One of our remaining concerns is around testing these changes, especially running userspace applications, and testing the memory protection implementation. One thing that could allow us to better test these changes is if you could provide a small dummy / test application (either in source or binary form), with instructions on how to load it?

This all looks sensible on first glance. My team is doing some internal validation as well to make sure this all continues to work on our platforms. I'll follow up once we have some results to share. cc @alevy

It's great to hear that you're testing these changes internally. We'd thus holding off on merging this for a couple more days, and can use that time to gather more reviews generally.

@bradjc
Copy link
Contributor

bradjc commented Apr 2, 2025

We need to document how to get qemu. The getting started guide doesn't actually include those instructions.

@reynoldsbd
Copy link
Contributor

Good news, we confirmed this is all running smoothly on real silicon!

@HMiyaziwala has opened a PR in the libtock-rs repo to add support for x86. That should allow you to use one of the example apps for testing.

@ioanaculic
Copy link
Contributor Author

We need to document how to get qemu. The getting started guide doesn't actually include those instructions.

Done.

@ioanaculic ioanaculic force-pushed the delete_x86_dependency branch from eaeeec8 to e5f144a Compare April 25, 2025 10:21
Copy link
Member

@alevy alevy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apart from my and @bradjc's comments, I think this is good to go.

alevy
alevy previously approved these changes May 9, 2025
@alevy
Copy link
Member

alevy commented May 9, 2025

I'm sorry, this really should be the last thing, IMO, but I added some suggested changes necessary for the documentation to compile. I can't apply those myself since I don't have push access to the branch.

@ioanaculic
Copy link
Contributor Author

I'm sorry, this really should be the last thing, IMO, but I added some suggested changes necessary for the documentation to compile. I can't apply those myself since I don't have push access to the branch.

Thank you. I commited all the suggestions.

@alevy alevy added the last-call Final review period for a pull request. label May 13, 2025
Copy link
Member

@ppannuto ppannuto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A more 'skim' of a review; deferring largely to the this being working code and a foundation

@ppannuto ppannuto dismissed their stale review May 13, 2025 20:09

Literally wrong button :(

Copy link
Member

@ppannuto ppannuto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually hitting the 'Approve' radio button this time 😬

@alevy alevy added this pull request to the merge queue May 14, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to no response for status checks May 14, 2025
@alevy alevy added this pull request to the merge queue May 14, 2025
Merged via the queue into tock:master with commit 292c5de May 14, 2025
15 checks passed
@bradjc bradjc changed the title Fix the port to the x86 Architecture Port to the x86 Architecture May 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
last-call Final review period for a pull request.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants