Skip to content

Commit aa66cf5

Browse files
Debug
1 parent 1447719 commit aa66cf5

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

sycl-jit/jit-compiler/lib/rtc/DeviceCompilation.cpp

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,8 @@
5353
#include <array>
5454
#include <sstream>
5555

56+
#include <iostream>
57+
5658
using namespace clang;
5759
using namespace clang::tooling;
5860
using namespace clang::driver;
@@ -100,6 +102,10 @@ class SYCLToolchain {
100102
FileManager *Files,
101103
std::shared_ptr<PCHContainerOperations> PCHContainerOps,
102104
DiagnosticConsumer *DiagConsumer) override {
105+
std::cerr << __PRETTY_FUNCTION__ << std::endl;
106+
for (auto &arg : Invocation->getCC1CommandLine())
107+
std::cout << " " << arg;
108+
std::cout << std::endl;
103109
// Create a compiler instance to handle the actual work.
104110
CompilerInstance Compiler(std::move(Invocation),
105111
std::move(PCHContainerOps));
@@ -127,6 +133,7 @@ class SYCLToolchain {
127133
std::vector<std::string> createCommandLine(const InputArgList &UserArgList,
128134
BinaryFormat Format,
129135
std::string_view SourceFilePath) {
136+
std::cerr << __PRETTY_FUNCTION__ << std::endl;
130137
DerivedArgList DAL{UserArgList};
131138
const auto &OptTable = getDriverOptTable();
132139
DAL.AddFlagArg(nullptr, OptTable.getOption(OPT_fsycl_device_only));
@@ -163,6 +170,9 @@ class SYCLToolchain {
163170
transform(ASL, std::back_inserter(CommandLine),
164171
[](const char *AS) { return std::string{AS}; });
165172
CommandLine.emplace_back(SourceFilePath);
173+
for (auto &arg : CommandLine)
174+
std::cout << " " << arg;
175+
std::cout << std::endl;
166176
return CommandLine;
167177
}
168178

@@ -177,6 +187,10 @@ class SYCLToolchain {
177187
FileManager *Files,
178188
std::shared_ptr<PCHContainerOperations> PCHContainerOps,
179189
DiagnosticConsumer *DiagConsumer) override {
190+
std::cerr << __PRETTY_FUNCTION__ << std::endl;
191+
for (auto &arg : Invocation->getCC1CommandLine())
192+
std::cout << " " << arg;
193+
std::cout << std::endl;
180194
auto MainFilePath = Invocation->getFrontendOpts().Inputs[0].getFile();
181195
auto MainFileBuffer = Files->getBufferForFile(MainFilePath);
182196
assert(MainFileBuffer && "Can't get memory buffer for in-memory source?");
@@ -450,6 +464,7 @@ Expected<ModuleUPtr> jit_compiler::compileDeviceCode(
450464
ClangDiagnosticWrapper Wrapper(BuildLog, &DiagOpts);
451465

452466
bool AutoPCH = UserArgList.hasArg(OPT_auto_pch);
467+
std::cerr << "AutoPCH: " << std::boolalpha << AutoPCH << std::endl;
453468

454469
if (SYCLToolchain::instance().run(UserArgList, Format, SourceFile.Path, ELOA,
455470
getInMemoryFS(SourceFile, IncludeFiles),

sycl/test-e2e/KernelCompiler/sycl_basic.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010

1111
// RUN: %{build} -o %t.out
1212
// RUN: %if hip %{ env SYCL_JIT_AMDGCN_PTX_TARGET_CPU=%{amd_arch} %} %{l0_leak_check} %{run} %t.out
13+
// RUN: false
1314

1415
// XFAIL: target-native_cpu
1516
// XFAIL-TRACKER: https://github.com/intel/llvm/issues/20142

0 commit comments

Comments
 (0)