This repository was archived by the owner on Mar 25, 2025. It is now read-only.
Codegen fixes for Eigen solvers with use of PROCEDURE using TABLE statement#925
Merged
Merged
Conversation
* table statements can have array variables. Until now only
scalar variables were supported in code generation.
* we can check symbol table to find out if the variable is
an array and it's length.
* similar to mod2c implementation, generate code for array
variable assignments:
https://github.com/BlueBrain/mod2c/blob/469c74dc7d96bbc5a06a42696422154b4cd2ce28/src/mod2c_core/parsact.c#L942
* with this, `glia__dbbs_mod_collection__Cav2_3__0.mod` from #888
compiles
…tement
* When we have TABLE statement used in a PROCEDURE and if such procedure
is called from DERIVATIVE block then we end-up calling table statement
related function from initialize() function:
`c++
struct functor {
NrnThread* nt;
glia__dbbs_mod_collection__Ca__granule_cell_Instance* inst;
int id, pnodecount;
double v;
Datum* indexes;
double old_s, old_u;
void initialize() {
rate_glia__dbbs_mod_collection__Ca__granule_cell(id, pnodecount, inst, data, indexes, thread, nt, v, v);
...
`
Here we are lacking data and thread variable as members in `struct functor`.
* This happens with the `glia__dbbs_mod_collection__Ca__granule_cell.mod` in #888
6 tasks
Collaborator
|
Logfiles from GitLab pipeline #73298 (:white_check_mark:) have been uploaded here! Status and direct links: |
Collaborator
|
Logfiles from GitLab pipeline #73496 (:white_check_mark:) have been uploaded here! Status and direct links: |
JCGoran
pushed a commit
to neuronsimulator/nrn
that referenced
this pull request
Mar 12, 2025
…tement (BlueBrain/nmodl#925) * When we have TABLE statement used in a PROCEDURE and if such procedure is called from DERIVATIVE block then we end-up calling table statement related function from initialize() function: ```c++ struct functor { NrnThread* nt; glia__dbbs_mod_collection__Ca__granule_cell_Instance* inst; int id, pnodecount; double v; Datum* indexes; double old_s, old_u; void initialize() { rate_glia__dbbs_mod_collection__Ca__granule_cell(id, pnodecount, inst, data, indexes, thread, nt, v, v); ... ``` Here we are lacking `data` and `thread` variable as members in `struct functor`. * This happens with the `glia__dbbs_mod_collection__Ca__granule_cell.mod` in BlueBrain/nmodl#888 NMODL Repo SHA: BlueBrain/nmodl@c7813f8
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When we have TABLE statement used in a PROCEDURE and if such procedure
is called from DERIVATIVE block then we end-up calling table statement
related function from initialize() function:
Here we are lacking
dataandthreadvariable as members instruct functor.This happens with the
glia__dbbs_mod_collection__Ca__granule_cell.modin Testing & Fixing issues with DBBS-Lab's MOD file collection #888