[flang] [clang-tools-extra] [lld] [lldb] [llvm] [libc] [clang] [libcxx] [compiler-rt] Make clang report invalid target versions for all environment types. (PR #78655)

via cfe-commits cfe-commits at lists.llvm.org
Thu Feb 1 11:45:41 PST 2024


ZijunZhaoCCK wrote:

> If I remove `OpenCL`, `clang/test/CodeGenOpenCL/amdgpu-alignment.cl` won't fail. It seems that OpenCL is a not a necessary change in this PR.
> 
> ```
> --- i/llvm/lib/TargetParser/Triple.cpp
> +++ w/llvm/lib/TargetParser/Triple.cpp
> @@ -325,4 +325,2 @@ StringRef Triple::getEnvironmentTypeName(EnvironmentType Kind) {
>    case Amplification: return "amplification";
> -  case OpenCL:
> -    return "opencl";
>    case OpenHOS: return "ohos";
> @@ -696,3 +694,2 @@ static Triple::EnvironmentType parseEnvironment(StringRef EnvironmentName) {
>        .StartsWith("amplification", Triple::Amplification)
> -      .StartsWith("opencl", Triple::OpenCL)
>        .StartsWith("ohos", Triple::OpenHOS)
> ```

Oh , my bad. Failed tests are ```Failed Tests (4):
  Clang :: CodeGenOpenCL/amdgpu-debug-info-pointer-address-space.cl
  Clang :: CodeGenOpenCL/amdgpu-debug-info-variable-expression.cl
  Clang :: Driver/amdgpu-toolchain-opencl.cl
  Clang :: Driver/opencl.cl```

https://github.com/llvm/llvm-project/pull/78655


More information about the cfe-commits mailing list