1 // Verify that DWARF version is properly clamped for nvptx, but not for the host.
2 // RUN: %clang -### --target=x86_64-linux-gnu -nogpulib -nogpuinc -c %s -gdwarf-5 -gembed-source 2>&1 \
3 // RUN: | FileCheck %s --check-prefix=DWARF-CLAMP
4 // RUN: %clang -### --target=x86_64-linux-gnu -nogpulib -nogpuinc -c %s -ggdb -gembed-source -gdwarf-5 2>&1 \
5 // RUN: | FileCheck %s --check-prefix=DWARF-CLAMP
7 // DWARF-CLAMP: "-triple" "nvptx64-nvidia-cuda"
8 // DWARF-CLAMP-SAME: -dwarf-version=2
9 // DWARF-CLAMP: "-triple" "x86_64
10 // DWARF-CLAMP-SAME: -dwarf-version=5