diff options
author | Jan Vesely <jan.vesely@rutgers.edu> | 2018-11-27 16:01:10 +0000 |
---|---|---|
committer | Jan Vesely <jan.vesely@rutgers.edu> | 2018-11-27 16:01:10 +0000 |
commit | 24987cf7fca64e11b2e593097bf30512804bc3ae (patch) | |
tree | a157450be6ee036bc5c12e894b82a30f9ffe0d0c /libclc | |
parent | 1218ebef0f0ef48141da818a06a8f139eefe9cc3 (diff) |
configure: Add target specific asm rule.
Run the file through target specific preprocessing stage.
Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
Reviewer: Aaron Watry
llvm-svn: 347664
Diffstat (limited to 'libclc')
-rwxr-xr-x | libclc/configure.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libclc/configure.py b/libclc/configure.py index 2a5d3a77846e..dab5dc94dfab 100755 --- a/libclc/configure.py +++ b/libclc/configure.py @@ -213,6 +213,8 @@ for target in targets: clang_bc_flags += ' -mcpu=' + device['gpu'] clang_bc_rule = "CLANG_CL_BC_" + target + "_" + device['gpu'] c_compiler_rule(b, clang_bc_rule, "LLVM-CC", llvm_clang, clang_bc_flags) + as_bc_rule = "LLVM_AS_BC_" + target + "_" + device['gpu'] + b.rule(as_bc_rule, "%s -E -P %s -x cl $in -o - | %s -o $out" % (llvm_clang, clang_bc_flags, llvm_as), 'LLVM-AS $out') objects = [] sources_seen = set() @@ -265,7 +267,7 @@ for target in targets: src_file = os.path.join(src_path, src) ext = os.path.splitext(src)[1] if ext == '.ll': - b.build(obj, 'LLVM_AS', src_file) + b.build(obj, as_bc_rule, src_file) else: b.build(obj, clang_bc_rule, src_file) |