[Mesa-dev] [PATCH] clover: log build options when dumping clc source
EdB
edb+mesa at sigluy.net
Mon May 11 08:45:08 PDT 2015
---
src/gallium/state_trackers/clover/llvm/invocation.cpp | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/src/gallium/state_trackers/clover/llvm/invocation.cpp b/src/gallium/state_trackers/clover/llvm/invocation.cpp
index 7d2d941..fc7ab9c 100644
--- a/src/gallium/state_trackers/clover/llvm/invocation.cpp
+++ b/src/gallium/state_trackers/clover/llvm/invocation.cpp
@@ -708,8 +708,10 @@ clover::compile_program_llvm(const std::string &source,
llvm_ctx.setDiagnosticHandler(diagnostic_handler, &r_log);
- if (get_debug_flags() & DBG_CLC)
- debug_log(source, ".cl");
+ if (get_debug_flags() & DBG_CLC) {
+ const std::string src = "// Build options: " + opts + '\n' + source;
+ debug_log(src, ".cl");
+ }
// The input file name must have the .cl extension in order for the
// CompilerInvocation class to recognize it as an OpenCL source file.
--
2.1.0
More information about the mesa-dev
mailing list