Fix T50719: Memory usage won't reset to zero while re-rendering on two video cards
Was only visible with Persistent Images option ON.
This commit is contained in:
parent
9992e6a169
commit
333dc8d60f
Notes:
blender-bot
2023-02-14 07:12:58 +01:00
Referenced by issue #50719, Memory consumption indicator won't reset (incremented instead) to zero while re-rendering on two video cards
|
@ -162,6 +162,7 @@ public:
|
|||
void mem_free(device_memory& mem)
|
||||
{
|
||||
device_ptr tmp = mem.device_pointer;
|
||||
stats.mem_free(mem.device_size);
|
||||
|
||||
foreach(SubDevice& sub, devices) {
|
||||
mem.device_pointer = sub.ptr_map[tmp];
|
||||
|
@ -170,7 +171,6 @@ public:
|
|||
}
|
||||
|
||||
mem.device_pointer = 0;
|
||||
stats.mem_free(mem.device_size);
|
||||
}
|
||||
|
||||
void const_copy_to(const char *name, void *host, size_t size)
|
||||
|
@ -202,6 +202,7 @@ public:
|
|||
void tex_free(device_memory& mem)
|
||||
{
|
||||
device_ptr tmp = mem.device_pointer;
|
||||
stats.mem_free(mem.device_size);
|
||||
|
||||
foreach(SubDevice& sub, devices) {
|
||||
mem.device_pointer = sub.ptr_map[tmp];
|
||||
|
@ -210,7 +211,6 @@ public:
|
|||
}
|
||||
|
||||
mem.device_pointer = 0;
|
||||
stats.mem_free(mem.device_size);
|
||||
}
|
||||
|
||||
void pixels_alloc(device_memory& mem)
|
||||
|
|
Loading…
Reference in New Issue