This patch makes Clang recognize -cl-std=1.0 as a value argument, before only -std=cl1.0 has to be used instead.
Fixes https://bugs.llvm.org/show_bug.cgi?id=47981
Yours,
Elvina
Software Engineer
Advanced Software Technology Lab, Huawei
Paths
| Differential D91237
[OpenCL] Make Clang recognize -cl-std=1.0 as a value argument ClosedPublic Authored by Elvina on Nov 10 2020, 11:22 PM.
Details Summary This patch makes Clang recognize -cl-std=1.0 as a value argument, before only -std=cl1.0 has to be used instead. Yours,
Diff Detail
Unit TestsFailed
Event TimelineComment Actions Failure on test "linux > HWAddressSanitizer-x86_64.TestCases::sizes.cpp" looks bogus. I had the same issue with another PR https://reviews.llvm.org/D89972 and other people also faced it https://reviews.llvm.org/D89895 Comment Actions
I agree they don't work very well, unfortunately. This revision is now accepted and ready to land.Nov 11 2020, 5:15 AM This revision was landed with ongoing or failed builds.Nov 11 2020, 6:04 AM Closed by commit rG624bced7eec0: [OpenCL] Make Clang recognize -cl-std=1.0 as a value argument (authored by Elvina). · Explain Why This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 304406 clang/include/clang/Driver/Options.td
clang/lib/Frontend/CompilerInvocation.cpp
clang/test/Driver/autocomplete.c
clang/test/Driver/opencl.cl
clang/test/Frontend/stdlang.c
clang/test/Preprocessor/predefined-macros.c
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
clang-format: please reformat the code
- LangStandard::Kind OpenCLLangStd - = llvm::StringSwitch<LangStandard::Kind>(A->getValue()) - .Cases("cl", "CL", LangStandard::lang_opencl10) - .Cases("cl1.0", "CL1.0", LangStandard::lang_opencl10) - .Cases("cl1.1", "CL1.1", LangStandard::lang_opencl11) - .Cases("cl1.2", "CL1.2", LangStandard::lang_opencl12) - .Cases("cl2.0", "CL2.0", LangStandard::lang_opencl20) - .Cases("cl3.0", "CL3.0", LangStandard::lang_opencl30) - .Cases("clc++", "CLC++", LangStandard::lang_openclcpp) - .Default(LangStandard::lang_unspecified);10 diff lines are omitted. See full path.