diff --git a/include/dxc/DXIL/DxilShaderModel.h b/include/dxc/DXIL/DxilShaderModel.h index def8176738..96f1408732 100644 --- a/include/dxc/DXIL/DxilShaderModel.h +++ b/include/dxc/DXIL/DxilShaderModel.h @@ -44,9 +44,6 @@ class ShaderModel { bool IsDS() const { return m_Kind == Kind::Domain; } bool IsCS() const { return m_Kind == Kind::Compute; } bool IsLib() const { return m_Kind == Kind::Library; } - bool IsRay() const { - return m_Kind >= Kind::RayGeneration && m_Kind <= Kind::Callable; - } bool IsMS() const { return m_Kind == Kind::Mesh; } bool IsAS() const { return m_Kind == Kind::Amplification; } bool IsValid() const; diff --git a/lib/DXIL/DxilShaderModel.cpp b/lib/DXIL/DxilShaderModel.cpp index f1fe6078b0..85d3a6853c 100644 --- a/lib/DXIL/DxilShaderModel.cpp +++ b/lib/DXIL/DxilShaderModel.cpp @@ -76,7 +76,8 @@ bool ShaderModel::IsValidForDxil() const { bool ShaderModel::IsValidForModule() const { // Ray tracing shader model should only be used on functions in a lib - return IsValid() && !IsRay(); + return IsValid() && + !(m_Kind >= Kind::RayGeneration && m_Kind <= Kind::Callable); } const ShaderModel *ShaderModel::Get(Kind Kind, unsigned Major, unsigned Minor) {