Age | Commit message (Collapse) | Author |
|
Makes behavior of proxy_from backlink working similar to the old dependency graph.
it's nasty, but needed here in the studio to get proxies fixes ASAP.
|
|
|
|
Gives about 5% speedup in scene with lots of nodes (army_of_clones.blend)
|
|
|
|
It was possible to have issues in cases when several child dependencies
goes to IDs with different layers. In this case order of flushing was not
really well defined, which could lead to cases when indirect dependency
via invisible object wouldn't work.
Need some sort of barrier to prevent scheduling of parent nodes for until
all children are done, but that's becoming quite nasty thing to implement.
Added a temp field to component for now. maybe it's not so crazy actually
and we might use it for evaluation as well, so we wouldn't flush updates
to components which does not affect visible stuff.
|
|
|
|
|
|
This is mainly a maintenance commit which was aimed to make work with
this module more pleasant and solve such issues as:
- Annoyance with looong files, which had craftload in them
- Usage of STL for the data structures we've got in BLI
- Possible symbol conflicts
- Not real clear layout of what is located where
So in this commit the following changes are done:
- STL is prohibited, it's not really predictable on various compilers,
with our BLI algorithms we can predict things much better.
There are still few usages of std::vector, but that we'll be
solving later once we've got similar thing in BLI.
- Simplify foreach loops, avoid using const_iterator all over the place.
- New directory layout, which is hopefully easier to follow.
- Some files were split, some of them will be split soon.
The idea of this is to split huge functions into own files with
good documentation and everything.
- Removed stuff which was planned for use in the future but was never
finished, tested or anything.
Let's wipe it out for now, and bring back once we really start using
it, so it'll be more clear if it solves our needs.
- All the internal routines were moved to DEG namespace to separate
them better from rest of blender.
Some places now annoyingly using DEG::foo, but that we can olve by
moving some utility functions inside of the namespace.
While working on this we've found some hotspot in updates flush, so
now playback of blenrig is few percent faster (something like 96fps
with previous master and around 99-100fps after this change).
Not saying it's something final, there is still room for cleanup and
API simplification, but those might happen as a regular development
now without doing any global changes.
|
|
|
|
This is a weak concept, but nice t support it for now, so we can enable
new depsgraph by default earlier.
|
|
|
|
|
|
Followup commit to 18e5e2fa1ac26ccbbd0cc8b486a5d92be6888021. Needs the same
treatment in the second pass when ID tags are reset again.
|
|
Nested node trees are not handled in BKE_main_id_tag_all.
|
|
Also don't reset values there which were re-set on the next evaluation anyway.
|
|
Gives additional speedup from ~88 to ~91 fps with a test rig.
|
|
It uses some additional compute power and the evaluation priority is
not even used.
This brings fps 88.2 with blenrig_for_debugging.blend on this desktop.
|
|
Simple thing, and apparently fps goes up to 80 with the demo file from jpbouza.
Not sure why at this point fps is so much higher than the old dependency graph
here now. And it's definitely something what others should verify as well.
|
|
This reduces stress on the task scheduler and avoids some unwanted overhead
caused by all the threading business in the cases when there's only one
children node. We try to immediately switch to it's evaluation now, keeping
active thread up and running.
This bumps FPS from 58 to 64 on the blenrig test file from jpbouza.
|
|
This commit implements new function BLI_task_pool_push_from_thread()
who's main goal is to have less parasitic load on the CPU bu avoiding
memory allocations as much as possible, making taks pushing cheaper.
This function expects thread ID, which must be 0 for the thread from
which pool is created from (and from which wait_work() is called) and
for other threads it mush be the ID which was sent to the thread working
function.
This reduces allocations quite a bit in the new dependency graph,
hopefully gaining some visible speedup on a fewzillion core machines
(on my own machine can only see benefit in profiler, which shows
significant reduce of time wasted in the memory allocation).
|
|
|
|
Set is much slower to iterate through (due to cache misses and such) and
the only advantage of using set is faster removal of link. However, we are
iterating links much much more often than removing them, and even when we
are removing links we don't really need to remove link from nodes which it
connects -- we don't support partial depsgraph updates, so removing links
from nodes on destruction is a waste of time.
If we ever want to support partial updates we can have dedicated function
to remove link from nodes it connects.
This gives a surprising increase of fps from 42 to 56 with test file from
Mr. J.P.Bouza (blenrig_for_debugging.blend). Surprising because old DEG is
actually slower here (52 fps). Didn't see any regressions (and don't see
why they will happen), so let's ask our riggers and animators to perform
further speed tests ;)
|
|
Use atomic operations instead, should in theory improve timing of
scheduling. However, probably not so visible yet because actual
task scheduling still have some locks and memory allocations.
Baby steps, what would i say.
|
|
Currently a lot of the nodes in the new dependency graph are empty placeholders
for organizational purposes. These nodes would, however, still be assigned a task
which gets scheduled and takes up some time for worker threads to pop from the
queue and run. This can be avoided by skipping these nodes during depsgraph
scheduling, and scheduling their childrent right away. Gives a few percent speedup
in BlenRig.
|
|
Some of the tagging functions would be called for every operation, and then
in turn tag their ID nodes with all their operations again. With extensive rigs
we get ID nodes with a lot (10,000+) operation nodes, which leads to millions
of unnecessary tagging calls.
|
|
The hash table is used to look up bone poses, particularly during constraint
evaluation. Without this the default BLI_findstring method on a plain ListBase
is used, which is really slow for extensive rigs.
|
|
|
|
|
|
BKE_main_id_tag_/BKE_main_id_flag_ were horrible naming now that we split those
into flags (for presistent one) and tags (for runtime ones).
Got rid of previous 'tag_' functions behavior (those who were dedicated shortcuts
to set/clear LIB_TAG_DOIT), so now '_tag_' functions affect tags, and '_flag_'
functions affect flags.
|
|
|
|
graph
|
|
|
|
Previously several areas were calling TEST_SHARED_PTR_SUPPORT and
TEST_UNORDERED_MAP_SUPPORT which isn't that bad on it's own but
was causing some quite verbose output with same information line
printed multiple times. additionally, what's more worse, define flags
for Ceres were duplicated in main CMakeLists and Ceres's CMakeLists.
Now we've got a single place where checks for those classes are
happening and other areas are simply checking for variables set by
those check macros, keeping CMake output clean and nice.
|
|
This isn't really ideal fix, but currently i can't tell how proxies should work
with the new dependency graph. This backward links are crazy, non-threadsafe
and mindblowing. Need to do some smarter/easier system.
|
|
While SCons building system was serving us really good for ages it's no longer
having much attention by the developers and started to become quite a difficult
task to maintain.
What's even worse -- there started to be quite serious divergence between SCons
and CMake which was only accumulating over the releases now. The fact that none
of the active developers are really using SCons and that our main studio is also
using CMake spotting bugs in the SCons builds became quite a difficult task and
we aren't always spotting them in time.
Meanwhile CMake became really mature building system which is available on every
platform we support and arguably it's also easier and more robust to use.
This commit includes:
- Removal of actual SCons building system
- Removal of SCons git submodule
- Removal of documentation which is stored in the sources and covers SCons
- Tweaks to the buildbot master to stop using SCons submodule
(this change requires deploying to the server)
- Tweaks to the install dependencies script to skip installing or mentioning
SCons building system
- Tweaks to various helper scripts to avoid mention of SCons folders/files
as well
Reviewers: mont29, dingto, dfelinto, lukastoenne, lukasstockner97, brecht, Severin, merwin, aligorith, psy-fi, campbellbarton, juicyfruit
Reviewed By: campbellbarton, juicyfruit
Differential Revision: https://developer.blender.org/D1680
|
|
This is purely internal sanitizing/cleanup, no change in behavior is expected at all.
This change was also needed because we were getting short on ID flags, and
future enhancement of 'user_one' ID behavior requires two new ones.
id->flag remains for persistent data (fakeuser only, so far!), this also allows us
100% backward & forward compatibility.
New id->tag is used for most flags. Though written in .blend files, its content
is cleared at read time.
Note that .blend file version was bumped, so that we can clear runtimeflags from
old .blends, important in case we add new persistent flags in future.
Also, behavior of tags (either status ones, or whether they need to be cleared before/after use)
has been added as comments to their declaration.
Reviewers: sergey, campbellbarton
Differential Revision: https://developer.blender.org/D1683
|
|
Tagging NodeTree->flag instead of NodeTree->id.flag, not sure if this fixes something, but...
|
|
|
|
This commit makes drivers on node groups to with when using new dependency graph.
Still TODO: Need a relation between drivers and tree evaluation perhaps, so we
guarantee proper order of all operations.
|
|
Previously it was possible that same component will be tagged for update
again and again, making update flushing really slow. Now we'll store flag
whether component was fully tagged.
This is still temporary solution because ideally we should just support
partial updates, but that's for the future.
Gives around 10% speedup on file from jpbouza.
|
|
|
|
The issue was caused by driver referencing path outside of the key datablock.
|
|
explicit id.
|
|
- Removed relation labels, since these mostly just reflect connected nodes, and also appear too far off the edge lines
- Draw cyclic links in dark red
- Slightly thicker edges and larger margins
|
|
|
|
Was only visible with new dependency graph.
Changing emit_from still doesn't behave fully reliably tho, that needs some
closer investigation.
|
|
|
|
Issue was caused by blender internal accessing data from DNA during rendering.
There's no simple solution to make stuff thread safe, so for now simply restart
rendering on frame update.
|
|
|
|
new DEG
|