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

Executable explicitly contains a flat list of *all* Processes after ProcGroups are created #714

Merged
merged 5 commits into from
Jun 16, 2023

Conversation

srrisbud
Copy link
Contributor

@srrisbud srrisbud commented Jun 15, 2023

Issue Number: N/A

Objective of pull request: Executable explicitly contains a flat list of all Processes after ProcGroups are created (all SubProcesses are resolved). This helps in propagating the Runtime to all Processes.

Pull request checklist

Your PR fulfills the following requirements:

  • Issue created that explains the change and why it's needed
  • Tests are part of the PR (for bug fixes / features)
  • Docs reviewed and added / updated if needed (for bug fixes / features)
  • PR conforms to Coding Conventions
  • PR applys BSD 3-clause or LGPL2.1+ Licenses to all code files
  • Lint (flakeheaven lint src/lava tests/) and (bandit -r src/lava/.) pass locally
  • Build tests (pytest) passes locally

Pull request type

Please check your PR type:

  • Bugfix

What is the current behavior?

  • Currently, keys of ProcBuilders dict are used to assign Runtime to Processes. However, the keys of NcProcBuilders dict are only "neuron-like" Processes. Connection-like Processes are omitted from this dict. This resulted in not assigning any Runtime to connection-like Processes. Consequently, get/set doesn't work for Vars of such Processes.

What is the new behavior?

  • A flat list of all Processes is stored in the Executable. When assigning Runtime, this list is iterated over. This way, no Process is left behind in assigning the Runtime.

Does this introduce a breaking change?

  • No

… all Processes are assigned the Runtime

Signed-off-by: Risbud, Sumedh <[email protected]>
…for example, to measure the size of NxBoard object after compilation

Signed-off-by: Risbud, Sumedh <[email protected]>
@srrisbud srrisbud self-assigned this Jun 15, 2023
@srrisbud srrisbud merged commit 5d8bd3e into lava-nc:main Jun 16, 2023
monkin77 pushed a commit to monkin77/thesis-lava that referenced this pull request Jul 12, 2024
…rocGroups are created (lava-nc#714)

* Explicitly keep track of all Processes in the Executable to make sure all Processes are assigned the Runtime

Signed-off-by: Risbud, Sumedh <[email protected]>

* A utility to measure the size of a python object recursively. Useful for example, to measure the size of NxBoard object after compilation

Signed-off-by: Risbud, Sumedh <[email protected]>

* Removed the utility to estimate Python object size

Signed-off-by: Risbud, Sumedh <[email protected]>

* Fixed Runtime unittest to accommodate passing an explicit ProcessList to the Executable

Signed-off-by: Risbud, Sumedh <[email protected]>

* Removed unused import

Signed-off-by: Risbud, Sumedh <[email protected]>

---------

Signed-off-by: Risbud, Sumedh <[email protected]>
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.

1 participant