Skip to content
This repository was archived by the owner on Apr 28, 2023. It is now read-only.

Commit 0079a95

Browse files
Add mcpu flag for future use
This commit adds the --mcpu flag to TC so we can emit LLVM and asm for different architectures.
1 parent 886b563 commit 0079a95

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

tc/core/flags.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ DEFINE_string(
5353
"compiler flags to set when nvcc is used");
5454

5555
// CPU codegen options
56+
DEFINE_string(mcpu, "", "see llvm's --mcpu");
5657
DEFINE_bool(llvm_dump_before_opt, false, "Print IR before optimization");
5758
DEFINE_bool(llvm_dump_after_opt, false, "Print IR after optimization");
5859
DEFINE_bool(llvm_dump_asm, false, "Print asm");

tc/core/flags.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,8 @@ DECLARE_string(cuda_compiler);
3636
DECLARE_string(llvm_flags);
3737
DECLARE_string(nvcc_flags);
3838

39-
// llvm codegen
39+
// CPU codegen options
40+
DECLARE_string(mcpu);
4041
DECLARE_bool(llvm_dump_before_opt);
4142
DECLARE_bool(llvm_dump_after_opt);
4243
DECLARE_bool(llvm_dump_asm);

0 commit comments

Comments
 (0)