Hi folks. Newbie developer question here.
I notice that the framework (sys directory) is mostly standardized across different cores, and where it differs it's mostly because an older framework is still in place. This makes sense, but why is this common code copied per core? If it's really common wouldn't it make more sense to either have a centralized repo that all cores need to include when building, or ideally just a centralized synthesized netlist used in the same way?
Basically, treat sys like either a code or netlist library rather than a copy. Not a criticism, just trying to understand.
Thanks.
aBP
sys copy vs. central code or netlist
-
- Core Developer
- Posts: 48
- Joined: Fri Dec 11, 2020 2:39 pm
- Has thanked: 3 times
- Been thanked: 32 times
Re: sys copy vs. central code or netlist
I think the centralized framework code is managed on Template core.
Each core uses copy of sys directory in Template core and merges updates in Template core.
I'm not sure why it doesn't form like git submodule.
I guess it gets a bit more complicated
Anyway I also joined recently so don't know about the historical context.
Each core uses copy of sys directory in Template core and merges updates in Template core.
I'm not sure why it doesn't form like git submodule.
I guess it gets a bit more complicated
Anyway I also joined recently so don't know about the historical context.
-
- Posts: 3
- Joined: Sat Jan 30, 2021 2:45 am
Re: sys copy vs. central code or netlist
Thanks. Yeah, I guess I just assumed that each core importing the single current sys source (or ideally a sys synthesized netlist with black box for the core's logic) would be more efficient than managing multiple copies.
- Sorgelig
- Site Admin
- Posts: 890
- Joined: Thu May 21, 2020 9:49 pm
- Has thanked: 2 times
- Been thanked: 214 times
Re: sys copy vs. central code or netlist
using sys as a submodule gives not much advantage. Being a submodule it points to a specific commit, not to latest changes.
Updating currently is just a simple copy of sys. It simplifies comparison between commits so you can use simple git difftool to see the difference while with submodule it's more harder to compare. Also it's easy to forget to update submodule while pulling and continue to use older submodule. Overall submodule feature gives more issues than help.
Updating currently is just a simple copy of sys. It simplifies comparison between commits so you can use simple git difftool to see the difference while with submodule it's more harder to compare. Also it's easy to forget to update submodule while pulling and continue to use older submodule. Overall submodule feature gives more issues than help.
-
- Posts: 3
- Joined: Sat Jan 30, 2021 2:45 am
-
- Core Developer
- Posts: 547
- Joined: Sun May 24, 2020 9:30 pm
- Has thanked: 20 times
- Been thanked: 145 times
Re: sys copy vs. central code or netlist
From time to time, there are new features or changes to existing features which require small adjustments to be made by the core, as well.
Using submodules buries these, and can cause confusion.
Having said all this, it might be nice to have a version identifier inside of the sys folder, so that it is easy to see how long it has been since the framework has been updated for each core, which may give a hint about any extra work for the person doing the update.
Using submodules buries these, and can cause confusion.
Having said all this, it might be nice to have a version identifier inside of the sys folder, so that it is easy to see how long it has been since the framework has been updated for each core, which may give a hint about any extra work for the person doing the update.