8000 Multiple sparse statement leads to incorrect code (after #78?) · Issue #92 · BlueBrain/mod2c · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Jun 8, 2023. It is now read-only.

Multiple sparse statement leads to incorrect code (after #78?) #92

Open
pramodk opened this issue Mar 28, 2023 · 0 comments
Open

Multiple sparse statement leads to incorrect code (after #78?) #92

99B2
pramodk opened this issue Mar 28, 2023 · 0 comments
Assignees

Comments

@pramodk
Copy link
Collaborator
pramodk commented Mar 28, 2023

Consider an example of MOD file provided in:

/gpfs/bbp.cscs.ch/project/proj16/kumbhar/pramod_scratch/mod2c_issue_multiple_sparse_solve

which has parts like:

INITIAL {
	atpi_clamp = atpi
	adpi_clamp = adpi
	pi_clamp = pi
	volin = PI*diam*diam/4 : cross section area
	volout = 1 (um2)
	surf = PI*diam*(1e7) : circumference

	:clamp atp, adp, p to initial values
	srcrate = 10e15
	FROM i = 1 TO 1 {
		SOLVE scheme STEADYSTATE sparse
	}

	: set to 0 to unclamp atp, adp, p
	srcrate = 10e15

	SOLVE scheme METHOD sparse
	ina_init = 3*atpact*(1e-3)
	ik_init = -2*atpact*(1e-3)
}

BREAKPOINT {
	SOLVE scheme METHOD sparse

	inapump = 3*atpact*(1e-3)
	ikpump = -2*atpact*(1e-3)
	:Flux in both directions is allowed, but should be very unlikely
	ina = inapump - ina_init
	ik = ikpump - ik_init
}

Compiling this with coreneuron+mod2c leads to:

x86_64/corenrn/mod2c/nakpump.cpp:537:46: error: redefinition of 'code_to_enable'
constexpr coreneuron::scopmath::enabled_code code_to_enable{coreneuron::scopmath::enabled_code::all};
                                             ^
x86_64/corenrn/mod2c/nakpump.cpp:528:46: note: previous definition is here
constexpr coreneuron::scopmath::enabled_code code_to_enable{coreneuron::scopmath::enabled_code::all};
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants
0