Add Spatz task compilation and embedding support for MAGIA-SDK#3
Add Spatz task compilation and embedding support for MAGIA-SDK#3callme-sam wants to merge 67 commits intopulp-platform:mainfrom
Conversation
|
CC: @Dequino @luca24balboni - Ready for review |
There was a problem hiding this comment.
Can you explain me what are the effects of this change? Have you tried it on RTL? If it is the case, once the PR will be succesfully merged on magia-sdk, we need to update also the Makefile in MAGIA's main repo. If you did not tested yet on RTL, I can try it on the MAGIA's main repo changing directly the ISA extension?
There was a problem hiding this comment.
The switch of the ISA extension to xgap9 was necessary to add float16 support, which is not supported by xpulpv2. This follows a discussion on the Mattermost MAGIA Deployment channel between Francesco, Alberto, and Giuseppe. To quote Giuseppe: "Using xgap9 on that compiler basically amounts to using xpulpv2 plus FP support."
I admit I haven't tested it on RTL yet, my bad. I'll do it as soon as I have a moment; I also need to build the MAGIA RTL from scratch (never tried). That said, I believe you can test it on the MAGIA main branch simply by changing the ISA extension. Let me know if you have the time and opportunity to do so, thanks a lot!
There was a problem hiding this comment.
Ok, I have tested it also on RTL and it seems there aren't problems, so it's okay from my side
There was a problem hiding this comment.
Ok, I have tested it also on RTL and it seems there aren't problems, so it's okay from my side
|
When the PR will be merged I will update my branch |
|
Some comments and action items to do: And add it as a new option for the make workflow I'll now try to locally run the tests to see if any issue rises |
…atz boot race condition
…nt RTL changes to fix Spatz boot race condition
f21f2e3 to
57e730b
Compare
|
Hi, The PR is finalized. Since the last reviews, the following changes have been introduced:
I’m keeping this as a Draft for now just to be safe. I am waiting for Lorenzo to implement the latest RTL changes (introduced by Luca to fix the Spatz boot race condition) into the gvsoc model for a final test. After that, if there are no further requests (which are always welcome), it’s ready to be merged. Thanks everyone! |
|
Ok, I've also tested it with an updated version of gvsoc, and everything looks fine. I'm taking it out of draft mode. If there are no further requests, this is ready to merge for me |
Dequino
left a comment
There was a problem hiding this comment.
1 - The Makefile changed the MAGIA_DIR to ../MAGIA which breaks the other commands if you install magia-sdk under MAGIA like suggested in the README.
2 - The README file referred in "Spatz integration in MAGIA" of the README refers to a file that kind of repeats itself 3 times and has some little inaccuracies due to the fact it refers to baremetal and not the SDK directly, maybe put a warning on it.
3 - The new path for the modelsim.ini copy instruction is also broken (that command is not run from the sdk folder, but from the build folder, so the relative path breaks)
…command to run RTL simulations for MAGIA-Spatz tests
…ve common dir at test top-dir
Description
This PR introduces the support for compiling Spatz tasks and embedding them into the CV32 binary, porting the workflow originally developed by @luca24balboni in the MAGIA repository.
Key Changes
CMake Translation & Workflow: Translated the compilation and embedding logic from Makefile to CMake. The new flow:
Bootrom Integration: Added conditional compilation for the Bootrom, which is now built only when a Spatz task is included in the compilation process.
Utilities Merge: Merged necessary hardware/utility headers from the original MAGIA project with the existing magia-v2 headers, resolving naming conflicts and ensuring compatibility.
Test Suite: Ported two existing tests and added new tests in tests/spatz_on_magia to verify the end-to-end flow.
Root Makefile Update: Added a new configuration option spatz_tests (enabled by default). It allows users to disable the compilation of Spatz-specific tests by setting it to 0.