-
Notifications
You must be signed in to change notification settings - Fork 13.3k
[clang-sycl-linker] Fix use of uninitialized memory in temp files #114488
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Signed-off-by: Sarnie, Nick <nick.sarnie@intel.com>
@llvm/pr-subscribers-clang Author: Nick Sarnie (sarnex) ChangesThis fixes the current sanitizer CI failures. I manually confirmed the fix with a MemorySanitizer build. Full diff: https://github.com/llvm/llvm-project/pull/114488.diff 1 Files Affected:
diff --git a/clang/tools/clang-sycl-linker/ClangSYCLLinker.cpp b/clang/tools/clang-sycl-linker/ClangSYCLLinker.cpp
index 0639b95c76e218..076458a275d986 100644
--- a/clang/tools/clang-sycl-linker/ClangSYCLLinker.cpp
+++ b/clang/tools/clang-sycl-linker/ClangSYCLLinker.cpp
@@ -230,7 +230,7 @@ Expected<StringRef> linkDeviceInputFiles(ArrayRef<std::string> InputFiles,
CmdArgs.push_back("--suppress-warnings");
if (Error Err = executeCommands(*LLVMLinkPath, CmdArgs))
return std::move(Err);
- return *OutFileOrErr;
+ return Args.MakeArgString(*OutFileOrErr);
}
// This utility function is used to gather all SYCL device library files that
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch, thanks.
PR title: "[Clang][SYCL] Fix use of uninitalized memory in temp files" tag: [Clang][SYCL] -> [clang-sycl-linker] |
…vm#114488) This fixes the current sanitizer CI [failures](https://lab.llvm.org/buildbot/#/builders/169/builds/4839/steps/13/logs/stdio). I manually confirmed the fix with a MemorySanitizer build. Signed-off-by: Sarnie, Nick <nick.sarnie@intel.com>
…vm#114488) This fixes the current sanitizer CI [failures](https://lab.llvm.org/buildbot/#/builders/169/builds/4839/steps/13/logs/stdio). I manually confirmed the fix with a MemorySanitizer build. Signed-off-by: Sarnie, Nick <nick.sarnie@intel.com>
This fixes the current sanitizer CI failures. I manually confirmed the fix with a MemorySanitizer build.