Page MenuHome

BLI: Use BLI::VectorSet to implement EdgeSet
Changes PlannedPublic

Authored by Jacques Lucke (JacquesLucke) on Sep 14 2019, 3:10 PM.

Details

Summary

This uses a new C++ data structure as base for the C EdgeSet.
Currently, the new implementation is up to 5% slower than the old
implementation that only worked with edges. I think I should be
able to make it a little faster in the future. However, in my opinion
even without that, this new implementation is preferable to the
old one.

I intend to update the other hash table implementations as well
over time. Just started with this one, because it is the simplest.

Diff Detail

Repository
rB Blender
Branch
edge-set-with-vector-set (branched from master)
Build Status
Buildable 4959
Build 4959: arc lint + arc unit

Event Timeline

While the slowdown isn't much, I'd prefer to find where the overhead is and see if it can be resolved
since there is no rush to apply this kind of patch and might mean the final patch ends up working differently.

Or, there might not be practical solution to the problem - in which case we need to evaluate of the slowdown is worth it.

Also, is the memory use equivalent.

Fair enough, will implement some optimizations and measure again.

The memory usage is practically the same. It uses the same storage layout (one array with ints and one array with edges). Only VectorSet itself, without any elements in the set, is probably larger.

Jacques Lucke (JacquesLucke) planned changes to this revision.Sep 15 2019, 2:12 AM