http://www.miikahweb.com/feed.php MiikaHweb - Blender Cycles_memory_experiments Branch http://www.miikahweb.com/ MiikaHweb - Blender Cycles_memory_experiments Branch fi Fri, 23 Aug 19 02:57:17 +0000 MiikaHweb RSS contact at miikahweb.com <![CDATA[[afe8eb3]: Cycles: Merge density and color volume attributes if they both...]]> http://www.miikahweb.com/en/blender/git-logs/commit/afe8eb3b59b2989ee387042b98de6ce880d74a6f afe8eb3
Branches : cycles_memory_experiments, gooseberry, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Cycles: Merge density and color volume attributes if they both requested

This way we store quite reasonable amount of memory (density is stored as RGBA
textures, which ends up in gigabytes of RAM for hires smoke sims).

It's not really pretty implementation and we'll really need to support textures
with 1 and 3 channels instead of doing such packing, but we need to be able to
render some files here.

----------------------------------------
4 Paths Changed]]>
Mon, 08 Jun 2015 13:48:11 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/afe8eb3b59b2989ee387042b98de6ce880d74a6fSergey Sharybin
<![CDATA[[b3259d5]: Cycles: Free hires smoke data from blender side after scene...]]> http://www.miikahweb.com/en/blender/git-logs/commit/b3259d51b464c01bfe2a507cffe04f46df761e86 b3259d5
Branches : cycles_memory_experiments, gooseberry, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Cycles: Free hires smoke data from blender side after scene was fully synchronized

This happens if all object's smokes are backed to files and rendering is either
happening from command line of with locked interface.

The idea behind this change is to make as much memory available for path tracing
as possible, so after heavy swapping during synchronization period there's loads
of free memory to put important data back to RAM.

----------------------------------------
8 Paths Changed]]>
Mon, 08 Jun 2015 13:34:07 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/b3259d51b464c01bfe2a507cffe04f46df761e86Sergey Sharybin
<![CDATA[[f1cd1e6]: Merge branch 'master' into cycles_memory_experiments]]> http://www.miikahweb.com/en/blender/git-logs/commit/f1cd1e650354dd9096cd35914234441047cc393b f1cd1e6
Branches : cycles_memory_experiments, gooseberry, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Merge branch 'master' into cycles_memory_experiments

Conflicts:
intern/cycles/blender/blender_object.cpp
intern/cycles/blender/blender_sync.h
intern/cycles/render/graph.h
intern/cycles/render/mesh.cpp

----------------------------------------
0 Paths Changed]]>
Mon, 08 Jun 2015 12:20:07 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/f1cd1e650354dd9096cd35914234441047cc393bSergey Sharybin
<![CDATA[[8b9d181]: Smoke: Fix crash when auto-sim happens outside of the backed...]]> http://www.miikahweb.com/en/blender/git-logs/commit/8b9d1818a57f538ec1c629ce94871351601ffa4c 8b9d181
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Smoke: Fix crash when auto-sim happens outside of the backed frame range

Apparently, even if the smoke is backed to an external files it still could be
tried to be simulated at the frames outside of the baked range.

Kinda weird feature which isn't really safe, but better not to crash here.

Not totally happy with the code yet, will check with Lukas or Daniel how it
could be improved further.

----------------------------------------
5 Paths Changed]]>
Thu, 23 Apr 2015 09:51:21 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/8b9d1818a57f538ec1c629ce94871351601ffa4cSergey Sharybin
<![CDATA[[edb7a68]: Cycles: Typo in triangle storage tooltip]]> http://www.miikahweb.com/en/blender/git-logs/commit/edb7a6819dd3898c714be9f54d96d390d3c6ec77 edb7a68
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Cycles: Typo in triangle storage tooltip

----------------------------------------
1 Path Changed]]>
Wed, 22 Apr 2015 07:17:31 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/edb7a6819dd3898c714be9f54d96d390d3c6ec77Sergey Sharybin
<![CDATA[[5edf8a8]: Cycles: Fix threading issue caused by several nodes sharing...]]> http://www.miikahweb.com/en/blender/git-logs/commit/5edf8a8a5b01cfec2e83ae0fa33c067ac894dba8 5edf8a8
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Cycles: Fix threading issue caused by several nodes sharing the same image

----------------------------------------
2 Paths Changed]]>
Mon, 20 Apr 2015 11:36:08 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/5edf8a8a5b01cfec2e83ae0fa33c067ac894dba8Sergey Sharybin
<![CDATA[[dbd8733]: Cycles: Replace name-based node matching with type-based]]> http://www.miikahweb.com/en/blender/git-logs/commit/dbd873380f5865c0c8d200f4866c2b470842a0c3 dbd8733
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Cycles: Replace name-based node matching with type-based

This commit replaces name-based node matching in the mesh device update
with check of special type. It is more robust approach for adding new
nodes which could use image slots for storage. it's also adds updates
of environment texture nodes used in bump shader (this was missing in
the original image sync reshuffle commit).

----------------------------------------
4 Paths Changed]]>
Mon, 20 Apr 2015 11:27:20 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/dbd873380f5865c0c8d200f4866c2b470842a0c3Sergey Sharybin
<![CDATA[[386e1a1]: Merge branch 'master' into cycles_memory_experiments]]> http://www.miikahweb.com/en/blender/git-logs/commit/386e1a1c9444777ab054413735b532109efa1633 386e1a1
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Merge branch 'master' into cycles_memory_experiments

----------------------------------------
0 Paths Changed]]>
Mon, 20 Apr 2015 10:07:15 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/386e1a1c9444777ab054413735b532109efa1633Sergey Sharybin
<![CDATA[[638b979]: Cycles: Add debug option to disable pre-aligned triangles storage...]]> http://www.miikahweb.com/en/blender/git-logs/commit/638b979895b25e630c7138ac4304321c2544971f 638b979
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Cycles: Add debug option to disable pre-aligned triangles storage

This option makes it so BVH does not use pre-aligned storage for triangle vertex
coordinates which was originally needed for faster coordinate lookup when doing
triangle intersection test. This array gives up to 10% performance comparing to
fetching individual coordinates but it also used 12 floats per BVH primitive,
which might translate to quite huge array in a complex scene.

Intention of this option is to investigate if this is a right direction to make
gooseberry files being able to render on local farm which is not totally great
in memory.

Current approach is not totally cheap, meaning even the case with the storage
enabled might be slower, but currently it's within 1%.

----------------------------------------
9 Paths Changed]]>
Fri, 17 Apr 2015 18:34:54 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/638b979895b25e630c7138ac4304321c2544971fSergey Sharybin
<![CDATA[[78f8c3e]: Merge branch 'master' into cycles_memory_experiments]]> http://www.miikahweb.com/en/blender/git-logs/commit/78f8c3eb311c77acc8e757668c2e5015d1b75ff5 78f8c3e
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Merge branch 'master' into cycles_memory_experiments

----------------------------------------
0 Paths Changed]]>
Thu, 16 Apr 2015 12:42:11 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/78f8c3eb311c77acc8e757668c2e5015d1b75ff5Sergey Sharybin
<![CDATA[[f5d5ffd]: Smoke: Fix compilation error with smoke disabled]]> http://www.miikahweb.com/en/blender/git-logs/commit/f5d5ffd335a55138a428b0e2000962ddb48ae250 f5d5ffd
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Smoke: Fix compilation error with smoke disabled

----------------------------------------
1 Path Changed]]>
Thu, 16 Apr 2015 09:32:37 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/f5d5ffd335a55138a428b0e2000962ddb48ae250Sergey Sharybin
<![CDATA[[d5c40c7]: Smoke: Fix another crash caused by recent changes]]> http://www.miikahweb.com/en/blender/git-logs/commit/d5c40c704fd5bed4eb718ae9bb50371ca96ba409 d5c40c7
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Smoke: Fix another crash caused by recent changes

Didn't notice initFie and so are called from constructor for some reason..

----------------------------------------
1 Path Changed]]>
Wed, 15 Apr 2015 19:11:35 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/d5c40c704fd5bed4eb718ae9bb50371ca96ba409Sergey Sharybin
<![CDATA[[465e59a]: Smoke: Fix wrong bit test in previous commit]]> http://www.miikahweb.com/en/blender/git-logs/commit/465e59ac7d4534858447c3b83e009a4058ca3e2c 465e59a
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Smoke: Fix wrong bit test in previous commit

----------------------------------------
1 Path Changed]]>
Wed, 15 Apr 2015 17:50:39 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/465e59ac7d4534858447c3b83e009a4058ca3e2cSergey Sharybin
<![CDATA[[4b04fad]: Smoke: Don't allocate arrays needed for hi-res simulation if...]]> http://www.miikahweb.com/en/blender/git-logs/commit/4b04fad0a99d45d962c54ae3db8a11da79f44753 4b04fad
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Smoke: Don't allocate arrays needed for hi-res simulation if smoke is baked to file

There used to be quite huge 3D arrays stored in memory which are only needed for
simulation steps and not used at all if the smoke is baked to file. That memory
is unmanaged by blender and not visible in the info space header and in practice
they could easily be gigabytes for hires smoke.

This commit only addressed hires smoke since it's the more important at this
point, and non-hires smoke wouldn't have such noticeable benefit.

In the case of tornado file it gives around 20% memory saving (which is about
26GB vs. 33GB on later frames of 01.03.02.A3 shot.

----------------------------------------
5 Paths Changed]]>
Wed, 15 Apr 2015 15:35:02 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/4b04fad0a99d45d962c54ae3db8a11da79f44753Sergey Sharybin
<![CDATA[[a1c1b32]: Merge branch 'master' into cycles_memory_experiments]]> http://www.miikahweb.com/en/blender/git-logs/commit/a1c1b32e4e76403656a66ac8f6e538f134563304 a1c1b32
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Merge branch 'master' into cycles_memory_experiments

----------------------------------------
0 Paths Changed]]>
Wed, 15 Apr 2015 15:41:25 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/a1c1b32e4e76403656a66ac8f6e538f134563304Sergey Sharybin
<![CDATA[[5155c16]: Cycles leaf nodes split: Fix crash when rendering scene without...]]> http://www.miikahweb.com/en/blender/git-logs/commit/5155c165b57a3d7d994c1d507e1ff9fb144c71c0 5155c16
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Cycles leaf nodes split: Fix crash when rendering scene without inner nodes

----------------------------------------
2 Paths Changed]]>
Tue, 14 Apr 2015 12:26:53 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/5155c165b57a3d7d994c1d507e1ff9fb144c71c0Sergey Sharybin
<![CDATA[[cb69152]: Merge branch 'master' into cycles_memory_experiments]]> http://www.miikahweb.com/en/blender/git-logs/commit/cb69152ad54bf468477def8f5399afbafbc771e1 cb69152
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Merge branch 'master' into cycles_memory_experiments

----------------------------------------
0 Paths Changed]]>
Tue, 14 Apr 2015 11:19:13 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/cb69152ad54bf468477def8f5399afbafbc771e1Sergey Sharybin
<![CDATA[[e0bbdd9]: Cycles: Split BVH nodes storage into inner and leaf nodes]]> http://www.miikahweb.com/en/blender/git-logs/commit/e0bbdd97042d1de75c5ce54b36a5789e6a8526fb e0bbdd9
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Cycles: Split BVH nodes storage into inner and leaf nodes

This way we can get rid of inefficient memory usage caused by BVH boundbox
part being unused by leaf nodes but still being allocated for them. Doing
such split allows to save 6 of float4 values for QBVH per leaf node and 3
of float4 values for regular BVH per leaf node.

This translates into following memory save using 01.01.01.G rendered
without hair:

Device memory size Device memory peak Global memory peak
Before the patch: 4957 5051 7668
With the patch: 4467 4562 7332

The measurements are done against current master. Still need to run speed tests
and it's hard to predict if it's faster or not: on the one hand leaf nodes are
now much more coherent in cache, on the other hand they're not so much coherent
with regular nodes anymore.

Reviewers: brecht, juicyfruit

Subscribers: venomgfx, eyecandy

Differential Revision: https://developer.blender.org/D1236

----------------------------------------
15 Paths Changed]]>
Tue, 14 Apr 2015 11:19:10 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/e0bbdd97042d1de75c5ce54b36a5789e6a8526fbSergey Sharybin
<![CDATA[[90c18b4]: Cycles: Synchronize images after building mesh BVH]]> http://www.miikahweb.com/en/blender/git-logs/commit/90c18b422de5169354e7360acb239f939af48ff8 90c18b4
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Cycles: Synchronize images after building mesh BVH

This way memory overhead caused by the BVH building is not so visible and peak
memory usage will be reduced.

Implementing this idea is not so straightforward actually, because we need to
synchronize images used for true displacement before meshes. Detecting whether
image is used for true displacement is not so striaghtforward, so for now all
all displacement types will synchronize images used for them.

Such change brings memory usage from 4.1G to 4.0G with the 01_01_01_D scene
from gooseberry. With 01_01_01_G scene it's 7.6G vs. 6.8G (before and after
the patch).

Reviewers: campbellbarton, juicyfruit, brecht

Subscribers: eyecandy

Differential Revision: https://developer.blender.org/D1217

----------------------------------------
5 Paths Changed]]>
Fri, 10 Apr 2015 18:19:38 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/90c18b422de5169354e7360acb239f939af48ff8Sergey Sharybin
<![CDATA[[ac6038e]: Cycles: free mesh BVH after packing the scene BVH]]> http://www.miikahweb.com/en/blender/git-logs/commit/ac6038e9914f2e9fe73b12c57f89f969be1f2bb7 ac6038e
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Cycles: free mesh BVH after packing the scene BVH

The idea is to avoid having original BVH and BVH packed into scene BVH and hence
reduce memory footprint.

This change doesn't give any measurable differences on it's own, but together
with D1215 and D1217 it gives quite nice results.

Reviewers: campbellbarton, brecht, juicyfruit

Subscribers: eyecandy

Differential Revision: https://developer.blender.org/D1218

----------------------------------------
5 Paths Changed]]>
Fri, 10 Apr 2015 18:20:34 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/ac6038e9914f2e9fe73b12c57f89f969be1f2bb7Sergey Sharybin
<![CDATA[[bf2856c]: Cycles: Experiment with culling objects based on the camera...]]> http://www.miikahweb.com/en/blender/git-logs/commit/bf2856c758fbdbaaf4ae872a5f9540654f754309 bf2856c
Branches : cycles_memory_experiments, gooseberry, gooseberry_farm, temp_motionpaths
Author : Sergey Sharybin (sergey)
----------------------------------------
Cycles: Experiment with culling objects based on the camera frustum

The idea is to give artists a simplier way to control memory usage in such
scenes as grass fields by doing automatic object culling based on whether
they're visible in the frame or not.

This is controlled on per-object level. In order to use this option few
steps are required:

- Allow renderer to use camera culling (Performance panel of render settings)
- Set camera cull margin (measured in relative value to the render resolution)
- Enable Camera Cull for objects which are desired to be culled
(object culling option could be found in Option panel in object buttons).

Interface decisions are not final for sure and to be refined if this
option is considered good enough for production.

Reviewers: juicyfruit, brecht, campbellbarton

Subscribers: venomgfx, eyecandy

Differential Revision: https://developer.blender.org/D1230

----------------------------------------
4 Paths Changed]]>
Fri, 10 Apr 2015 15:55:44 +0000 http://www.miikahweb.com/en/blender/git-logs/commit/bf2856c758fbdbaaf4ae872a5f9540654f754309Sergey Sharybin