-
Notifications
You must be signed in to change notification settings - Fork 73
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
Making the ISPM work on all cores using the bootloader #154
Comments
An alternative is to add functionality to the bootloader that calls a bootloader-function on eacher non-main core, whose only job is to load the ISPM. The core then goes back to sleep. |
Thanks for looking into this. Let us think about it when there is a need. This is very brittle anyway, as one needs to decide which functions shall be on which core. I do not think we want to have the very same function in all core's ISPMs. |
I've just opened this issue to write down my ideas. No plan to actually do any of this yet. I've also thought about what goes in each core's ISPM. We could also allow additional core-specific section, like |
A maybe not so trivial issue is that all ISPMs are mapped to the same address. Can we have several functions in the .elf file that are mapper to the same address? |
I think it is possible in ELF to have sections referencing the same addresses. Though I have no experience with this, so maybe this is a misunderstanding of mine. We'll need to explore and test more. |
I think there is some misunderstanding here. In the bootloader, which is the same for all cores, we have these lines
This is executed by all cores. Now, this might no longer work, for whatever reason, but the intention is that each core copies instructions from the main memory to the SPM. |
I think we never had a usable solution for using the I-SPM on all cores, just the first core. And even that we have never really used. |
We currently have the issue of the instruction scratchpad (ISPM) not working on non-main cores.
It works on the main core by the bootloader reading the downloaded ELF and putting anything that is in the
.text.spm
section in the ISPM.However, this does not work for other cores since there is no way for the main core to load stuff into other cores' ISPMs, and there is no way for the cores themselves to do it, since they are called using pthreads or coresthread_create.
My idea is to update corethread/pthreads such that they call the bootloader on the other cores instead of the given function. The bootloader will be updated such that if it is not called from the main core, it loads the ISPM then runs the required function. This of course requires an update to the bootloader.
This is not totally fleshed out, but I think it would be a good way to use existing functionality in the bootloader to give us access to the ISPMs on non-main cores.
The text was updated successfully, but these errors were encountered: