[Bf-blender-cvs] [8a790c2] object_nodes: Removed unused codegen_begin/end functions.

Lukas Tönne noreply at git.blender.org
Thu May 19 19:29:32 CEST 2016


Commit: 8a790c2b8662309c6e1621d4668bc3ffb53d03df
Author: Lukas Tönne
Date:   Thu May 19 18:06:56 2016 +0200
Branches: object_nodes
https://developer.blender.org/rB8a790c2b8662309c6e1621d4668bc3ffb53d03df

Removed unused codegen_begin/end functions.

===================================================================

M	source/blender/blenvm/llvm/llvm_codegen.cc
M	source/blender/blenvm/llvm/llvm_codegen.h

===================================================================

diff --git a/source/blender/blenvm/llvm/llvm_codegen.cc b/source/blender/blenvm/llvm/llvm_codegen.cc
index cecd141..772c9e7 100644
--- a/source/blender/blenvm/llvm/llvm_codegen.cc
+++ b/source/blender/blenvm/llvm/llvm_codegen.cc
@@ -610,14 +610,6 @@ llvm::Module *LLVMCompilerBase::define_nodes_module()
 
 llvm::Module *LLVMSimpleCompilerImpl::m_nodes_module = NULL;
 
-void LLVMSimpleCompilerImpl::codegen_begin()
-{
-}
-
-void LLVMSimpleCompilerImpl::codegen_end()
-{
-}
-
 llvm::Type *LLVMSimpleCompilerImpl::create_value_type(const string &name, const TypeSpec *spec)
 {
 	using namespace llvm;
@@ -653,14 +645,6 @@ llvm::Type *LLVMSimpleCompilerImpl::create_value_type(const string &name, const
 
 llvm::Module *LLVMTextureCompilerImpl::m_nodes_module = NULL;
 
-void LLVMTextureCompilerImpl::codegen_begin()
-{
-}
-
-void LLVMTextureCompilerImpl::codegen_end()
-{
-}
-
 llvm::Type *LLVMTextureCompilerImpl::create_value_type(const string &name, const TypeSpec *spec)
 {
 	using namespace llvm;
@@ -700,8 +684,6 @@ FunctionLLVM *LLVMCompiler::compile_function(const string &name, const NodeGraph
 	
 	std::string error;
 	
-	codegen_begin();
-	
 	create_module(name);
 	
 	if (get_nodes_module() == NULL) {
@@ -716,8 +698,6 @@ FunctionLLVM *LLVMCompiler::compile_function(const string &name, const NodeGraph
 	BLI_assert(module()->getFunction(name) && "Function not registered in module!");
 	BLI_assert(func != NULL && "codegen_node_function returned NULL!");
 	
-	codegen_end();
-	
 	BLI_assert(opt_level >= 0 && opt_level <= 3 && "Invalid optimization level (must be between 0 and 3)");
 	optimize_function(func, opt_level);
 	
diff --git a/source/blender/blenvm/llvm/llvm_codegen.h b/source/blender/blenvm/llvm/llvm_codegen.h
index 0ea137e..0cd911c 100644
--- a/source/blender/blenvm/llvm/llvm_codegen.h
+++ b/source/blender/blenvm/llvm/llvm_codegen.h
@@ -87,9 +87,6 @@ protected:
 	llvm::BasicBlock *codegen_function_body_expression(const NodeGraph &graph, llvm::Function *func);
 	llvm::Function *codegen_node_function(const string &name, const NodeGraph &graph);
 	
-	virtual void codegen_begin() = 0;
-	virtual void codegen_end() = 0;
-	
 	void map_argument(llvm::BasicBlock *block, const OutputKey &output, llvm::Argument *arg);
 	void store_return_value(llvm::BasicBlock *block, const OutputKey &output, llvm::Value *arg);
 	
@@ -115,9 +112,6 @@ private:
 };
 
 struct LLVMSimpleCompilerImpl : public LLVMCompilerBase {
-	void codegen_begin();
-	void codegen_end();
-	
 	llvm::Type *create_value_type(const string &name, const TypeSpec *spec);
 	
 	llvm::Module *get_nodes_module() const { return m_nodes_module; }
@@ -128,9 +122,6 @@ private:
 };
 
 struct LLVMTextureCompilerImpl : public LLVMCompilerBase {
-	void codegen_begin();
-	void codegen_end();
-	
 	llvm::Type *create_value_type(const string &name, const TypeSpec *spec);
 	
 	llvm::Module *get_nodes_module() const { return m_nodes_module; }




More information about the Bf-blender-cvs mailing list