Skip to content

Commit

Permalink
Lower print_atomic_reduction_pragma.
Browse files Browse the repository at this point in the history
This method is specific to the CoreNEURON implementation of
`visit_protected_statement`.
  • Loading branch information
1uc committed Nov 12, 2024
1 parent c54f5d5 commit a085c6f
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 21 deletions.
2 changes: 1 addition & 1 deletion src/codegen/codegen_coreneuron_cpp_visitor.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ class CodegenCoreneuronCppVisitor: public CodegenCppVisitor {
/**
* Print atomic update pragma for reduction statements
*/
void print_atomic_reduction_pragma() override;
virtual void print_atomic_reduction_pragma();


/**
Expand Down
7 changes: 0 additions & 7 deletions src/codegen/codegen_cpp_visitor.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -802,12 +802,6 @@ class CodegenCppVisitor: public visitor::ConstAstVisitor {
/****************************************************************************************/


/**
* Print atomic update pragma for reduction statements
*/
virtual void print_atomic_reduction_pragma() = 0;


/**
* Instantiate global var instance
*
Expand Down Expand Up @@ -1485,7 +1479,6 @@ class CodegenCppVisitor: public visitor::ConstAstVisitor {
void visit_var_name(const ast::VarName& node) override;
void visit_while_statement(const ast::WhileStatement& node) override;
void visit_update_dt(const ast::UpdateDt& node) override;
void visit_protect_statement(const ast::ProtectStatement& node) override;
void visit_mutex_lock(const ast::MutexLock& node) override;
void visit_mutex_unlock(const ast::MutexUnlock& node) override;
void visit_solution_expression(const ast::SolutionExpression& node) override;
Expand Down
6 changes: 0 additions & 6 deletions src/codegen/codegen_neuron_cpp_visitor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -80,12 +80,6 @@ int CodegenNeuronCppVisitor::position_of_int_var(const std::string& name) const
/* Backend specific routines */
/****************************************************************************************/


/// TODO: Edit for NEURON
void CodegenNeuronCppVisitor::print_atomic_reduction_pragma() {
return;
}

bool CodegenNeuronCppVisitor::optimize_ion_variable_copies() const {
if (optimize_ionvar_copies) {
throw std::runtime_error("Not implemented.");
Expand Down
7 changes: 0 additions & 7 deletions src/codegen/codegen_neuron_cpp_visitor.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -153,13 +153,6 @@ class CodegenNeuronCppVisitor: public CodegenCppVisitor {
/* Backend specific routines */
/****************************************************************************************/


/**
* Print atomic update pragma for reduction statements
*/
void print_atomic_reduction_pragma() override;


/**
* Check if ion variable copies should be avoided
*/
Expand Down

0 comments on commit a085c6f

Please sign in to comment.