Commit ece76d47 authored by Simon Spannagel's avatar Simon Spannagel
Browse files

Objects: solve performance issue by not cleaning up TRef dependants.

parent 487764a7
......@@ -7,7 +7,12 @@ Object::Object(std::string detectorID) : m_detectorID(std::move(detectorID)) {}
Object::Object(double timestamp) : m_timestamp(timestamp) {}
Object::Object(std::string detectorID, double timestamp) : m_detectorID(std::move(detectorID)), m_timestamp(timestamp) {}
Object::Object(const Object&) = default;
Object::~Object() = default;
Object::~Object() {
// In Corryvreckan, all objects are destroyed together, i.e. at the end of the event. To avoid costly reverse-iterations
// through the TRef dependency hash lists, we just tell ROOT not to care about possible TRef-dependants and to just
// destroy the object directly by resetting the `kMustCleanup` bit.
std::ostream& corryvreckan::operator<<(std::ostream& out, const Object& obj) {
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment