summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKenneth Graunke <kenneth@whitecape.org>2010-11-08 16:10:46 -0800
committerKenneth Graunke <kenneth@whitecape.org>2010-11-08 16:22:15 -0800
commita457ca7844c7943e17aa18a73757cc4ac965e200 (patch)
treedd384dd8b9019139db211cea633167475ab19852
parentef6967ddc201be6c400701703dd0774570d5bfee (diff)
ir_dead_functions: Actually free dead functions and signatures.
This makes linked shaders use around 36k less memory since the built-in prototypes are now freed.
-rw-r--r--src/glsl/ir_dead_functions.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/glsl/ir_dead_functions.cpp b/src/glsl/ir_dead_functions.cpp
index 26554441d3..16037a2632 100644
--- a/src/glsl/ir_dead_functions.cpp
+++ b/src/glsl/ir_dead_functions.cpp
@@ -125,6 +125,7 @@ do_dead_functions(exec_list *instructions)
if (!entry->used) {
entry->signature->remove();
+ delete entry->signature;
progress = true;
}
delete(entry);
@@ -143,6 +144,7 @@ do_dead_functions(exec_list *instructions)
* symbol table should be OK.
*/
func->remove();
+ delete func;
progress = true;
}
}