llnl / llnl/conduit

Add `Node` move constructor

Open
#1,632 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

feature
Dominant language
C++
Stars
248
Forks
72
Avg merge
1d 16h
Merged PRs (30d)
15

Description

From Jason Burmark:

> [Codex] also pointed out that conduit::Node doesn't have a move constructor, which would probably be a good thing to add.

> conduit::Node itself is generally fine on destruction. Its copy constructor does a deep copy via
set(node), so copied nodes own their own storage and clean up independently; see conduit/src/libs/
conduit/conduit_node.cpp:109. Conduit does not appear to define a C++ move constructor for Node; it has
a Node::move(Node&) member function instead, which is a different thing; see conduit/src/libs/conduit/
conduit_node.cpp:8926. So the main risk with Node is accidental extra deep copies and higher memory
use, not a double-free.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in conduit/src/libs/conduit/conduit_node.cpp at the copy-constructor implementation around line 109 and the existing Node::move(Node&) member around line 8926. Trace the Node declaration and current construction behavior, then verify that adding move construction avoids unnecessary deep copies while preserving ownership and destruction semantics.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
hpc
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
65/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.