-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
removed common.h/cpp; added compile_config.h/cpp; cleanups
- Loading branch information
1 parent
2291d0e
commit 0c3358e
Showing
31 changed files
with
150 additions
and
316 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
#include "taichi/compile_config.h" | ||
|
||
TLANG_NAMESPACE_BEGIN | ||
|
||
CompileConfig::CompileConfig() { | ||
arch = Arch::x64; | ||
simd_width = default_simd_width(arch); | ||
external_optimization_level = 3; | ||
print_ir = false; | ||
print_accessor_ir = false; | ||
use_llvm = true; | ||
print_struct_llvm_ir = false; | ||
print_kernel_llvm_ir = false; | ||
print_kernel_llvm_ir_optimized = false; | ||
demote_dense_struct_fors = true; | ||
max_vector_width = 8; | ||
debug = false; | ||
lazy_compilation = true; | ||
serial_schedule = false; | ||
simplify_before_lower_access = true; | ||
lower_access = true; | ||
simplify_after_lower_access = true; | ||
default_fp = DataType::f32; | ||
default_ip = DataType::i32; | ||
verbose_kernel_launches = false; | ||
enable_profiler = false; | ||
default_cpu_block_dim = 0; // 0 = adaptive | ||
default_gpu_block_dim = 64; | ||
verbose = true; | ||
fast_math = true; | ||
} | ||
|
||
TLANG_NAMESPACE_END |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
#include "taichi/lang_util.h" | ||
#include "taichi/arch.h" | ||
|
||
TLANG_NAMESPACE_BEGIN | ||
|
||
struct CompileConfig { | ||
Arch arch; | ||
bool debug; | ||
int simd_width; | ||
bool lazy_compilation; | ||
int external_optimization_level; | ||
int max_vector_width; | ||
bool print_ir; | ||
bool print_accessor_ir; | ||
bool serial_schedule; | ||
bool simplify_before_lower_access; | ||
bool lower_access; | ||
bool simplify_after_lower_access; | ||
bool demote_dense_struct_fors; | ||
bool use_llvm; | ||
bool print_struct_llvm_ir; | ||
bool print_kernel_llvm_ir; | ||
bool print_kernel_llvm_ir_optimized; | ||
bool verbose_kernel_launches; | ||
bool enable_profiler; | ||
bool verbose; | ||
bool fast_math; | ||
bool use_unified_memory; | ||
DataType default_fp; | ||
DataType default_ip; | ||
std::string extra_flags; | ||
int default_cpu_block_dim; | ||
int default_gpu_block_dim; | ||
|
||
CompileConfig(); | ||
}; | ||
|
||
extern CompileConfig default_compile_config; | ||
|
||
TLANG_NAMESPACE_END |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.