Pārlūkot izejas kodu

Rework name lookup (#4332)

* Rework name lookup

This is a big change... A lot of the change here is actually reverting
back to clang 3.7 code. Specifically around template name resoltuion.

The root cause of issue #4263 is that in DXC (before this change) HLSL
routes all name lookup through template name resolution. This results
in annotating some things as templates that shouldn't be. Specifically
in the test case in #4263, the second `Load` gets annotated as a
template-id tracking to the first `Load` when it should be just a
method specialization.

This fix is a bit involved.

I revert a bunch of the template handling code back to clang-3.7. This
causes two problems:

(1) HLSL allows omiting empty template argument lists for default
template cases (i.e. `matrix` is valid in HLSL, but in C++ it would
need to be `matrix<>`). This patch should fully resolve that case.
(2) Since DXC routes all names through template lookup, some
diagnostics were only emitted in template name lookup. This patch fixes
_some_ of those cases, but there are test failures that I'll resolve in
a subsequent commit on this PR.

I'm posting this change before it is fully ready to go because it is
large and may take some time to review.

* Issue precision warnings during decl diagnosis

* Adding template test cases

This adds two new test cases. One that verifies that template default
arguments are correctly instantiated when the empty template parameter
list is omitted, and a second that verifies that template function
overloads parse correctly.

* Auto update verifier tests

This is an automated update of the verifier tests. I've manually
reviewed it and it looks correct to me but there's a lot of change here.

Expected differences are:
(1) Some of the old warnings were just wrong...
(2) We only emit promotion warnings on declarations, this removes them
from cases like `std::is_same` uses
(3) Template typenames are unsugared, so `Texture2D` becomes
`Texture2D<vector<float, 4> >`
(4) Warnings are not emitted after fatal errors in the same context (so
we lose a few warnings)
(5) Typenames are quoted
(6) QualType names are printed instaed of custom strings, this results
in some errors that would have said `float16_t` to say `half`, and
errors that ignored `unsigned` qualifiers to bake it in
(7) The order of warning emission changed because we emit in a
different place :(

* One more test case fix for quoted typenames

* Fixing the test case for 4263

* Fixing diagnostic for missing template arguments

* Updating SPIR-V testcase for template changes

* Updating PrettyPrinter with rule for rewriter

This patch adds an option to omit HLSL default template arguments when
pretty printing types inside the rewriter. This minimizes the impact of
the template lookup changes on the rewriter cases.

* Correct missing diagnostics for constant buffers

* Restoring warning to verifier test.

* Updating a testcase I added upstream
Chris B 3 gadi atpakaļ
vecāks
revīzija
a7fa058dd3
39 mainītis faili ar 954 papildinājumiem un 871 dzēšanām
  1. 3 1
      tools/clang/include/clang/AST/PrettyPrinter.h
  2. 4 5
      tools/clang/include/clang/Sema/Sema.h
  3. 12 0
      tools/clang/lib/AST/TypePrinter.cpp
  4. 1 1
      tools/clang/lib/Parse/ParseDeclCXX.cpp
  5. 3 14
      tools/clang/lib/Parse/ParseExprCXX.cpp
  6. 0 1
      tools/clang/lib/Parse/ParseTemplate.cpp
  7. 2 5
      tools/clang/lib/Parse/Parser.cpp
  8. 5 1
      tools/clang/lib/Sema/SemaDecl.cpp
  9. 12 2
      tools/clang/lib/Sema/SemaExpr.cpp
  10. 77 61
      tools/clang/lib/Sema/SemaHLSL.cpp
  11. 34 25
      tools/clang/lib/Sema/SemaTemplate.cpp
  12. 2 2
      tools/clang/test/CodeGenSPIRV/decoration.user-type.hlsl
  13. 3 3
      tools/clang/test/HLSL/const-default.hlsl
  14. 2 2
      tools/clang/test/HLSL/const-expr.hlsl
  15. 4 4
      tools/clang/test/HLSL/conversions-non-numeric-aggregates.hlsl
  16. 1 1
      tools/clang/test/HLSL/enums.hlsl
  17. 2 2
      tools/clang/test/HLSL/functions.hlsl
  18. 27 27
      tools/clang/test/HLSL/indexing-operator.hlsl
  19. 4 4
      tools/clang/test/HLSL/intrinsic-examples.hlsl
  20. 6 6
      tools/clang/test/HLSL/literals.hlsl
  21. 4 4
      tools/clang/test/HLSL/matrix-syntax-exact-precision.hlsl
  22. 2 2
      tools/clang/test/HLSL/matrix-syntax.hlsl
  23. 4 4
      tools/clang/test/HLSL/mintypes-promotion-warnings.hlsl
  24. 23 23
      tools/clang/test/HLSL/more-operators.hlsl
  25. 1 1
      tools/clang/test/HLSL/rewriter/correct_rewrites/matrix-syntax_gold.hlsl
  26. 183 183
      tools/clang/test/HLSL/scalar-assignments-exact-precision.hlsl
  27. 77 77
      tools/clang/test/HLSL/scalar-assignments.hlsl
  28. 309 309
      tools/clang/test/HLSL/scalar-operators-exact-precision.hlsl
  29. 86 86
      tools/clang/test/HLSL/scalar-operators.hlsl
  30. 2 2
      tools/clang/test/HLSL/sizeof.hlsl
  31. 1 1
      tools/clang/test/HLSL/vector-conditional.hlsl
  32. 4 4
      tools/clang/test/HLSL/vector-syntax-exact-precision.hlsl
  33. 2 2
      tools/clang/test/HLSL/vector-syntax.hlsl
  34. 2 2
      tools/clang/test/HLSLFileCheck/hlsl/compile_options/WX.hlsl
  35. 7 2
      tools/clang/test/HLSLFileCheck/hlsl/template/DependentWithBuiltinTemplate.hlsl
  36. 29 0
      tools/clang/test/HLSLFileCheck/hlsl/template/FunctionOverloads.hlsl
  37. 11 0
      tools/clang/test/HLSLFileCheck/hlsl/template/OmitDefaulted.hlsl
  38. 2 2
      tools/clang/test/HLSLFileCheck/hlsl/template/complete-array-parameter.hlsl
  39. 1 0
      tools/clang/tools/libclang/dxcrewriteunused.cpp

+ 3 - 1
tools/clang/include/clang/AST/PrettyPrinter.h

@@ -46,7 +46,7 @@ struct PrintingPolicy {
       IncludeNewlines(true),
       // HLSL Change Begin - hlsl print policy.
       HLSLSuppressUniformParameters(false), HLSLOnlyDecl(false),
-      HLSLNoinlineMethod(false)
+      HLSLNoinlineMethod(false), HLSLOmitDefaultTemplateParams(false)
       // HLSL Change End.
       {}
 
@@ -177,6 +177,8 @@ struct PrintingPolicy {
   unsigned HLSLOnlyDecl : 1;
   /// \brief When true, print inline method define as outside struct scope define.
   unsigned HLSLNoinlineMethod : 1;
+  /// \brief When true, omit default template parameter lists
+  unsigned HLSLOmitDefaultTemplateParams : 1;
   // HLSL Change Ends
 };
 

+ 4 - 5
tools/clang/include/clang/Sema/Sema.h

@@ -5511,8 +5511,7 @@ public:
 
   void LookupTemplateName(LookupResult &R, Scope *S, CXXScopeSpec &SS,
                           QualType ObjectType, bool EnteringContext,
-                          bool &MemberOfUnknownSpecialization,
-                          bool NextIsLess = false); // HLSL Change - additional special case flag
+                          bool &MemberOfUnknownSpecialization);
 
   TemplateNameKind isTemplateName(Scope *S,
                                   CXXScopeSpec &SS,
@@ -5521,8 +5520,7 @@ public:
                                   ParsedType ObjectType,
                                   bool EnteringContext,
                                   TemplateTy &Template,
-                                  bool &MemberOfUnknownSpecialization,
-                                  bool NextIsLess = false); // HLSL Change - additional special case flag
+                                  bool &MemberOfUnknownSpecialization);
 
   bool DiagnoseUnknownTemplateName(const IdentifierInfo &II,
                                    SourceLocation IILoc,
@@ -9009,7 +9007,6 @@ private:
 
   // HLSL Change Starts
   bool DiagnoseHLSLDecl(Declarator& D, DeclContext* DC, Expr *BitWidth, TypeSourceInfo* TInfo, bool isParameter);
-  bool DiagnoseHLSLLookup(const LookupResult &R);
   void TransferUnusualAttributes(Declarator& D, NamedDecl* NewDecl);
   // HLSL Change Ends
 
@@ -9083,6 +9080,8 @@ public:
   // HLSL Change Begin - adjust this from T* to T&-like
   CXXThisExpr *genereateHLSLThis(SourceLocation Loc, QualType ThisType,
                                 bool isImplicit);
+  ClassTemplateSpecializationDecl *
+  getHLSLDefaultSpecialization(ClassTemplateDecl *Decl);
   // HLSL Change End - adjust this from T* to T&-like
 };
 

+ 12 - 0
tools/clang/lib/AST/TypePrinter.cpp

@@ -983,6 +983,18 @@ void TypePrinter::printTag(TagDecl *D, raw_ostream &OS) {
       Args = TST->getArgs();
       NumArgs = TST->getNumArgs();
     } else {
+      // HLSL Change Starts
+      ClassTemplateDecl *TD = Spec->getSpecializedTemplate();
+      TemplateParameterList *Params = TD->getTemplateParameters();
+      // If this is an HLSL default template specialization, omit the template
+      // argument list, unless this is a vector or matrix type.
+      if (Policy.LangOpts.HLSL && Policy.HLSLOmitDefaultTemplateParams &&
+          Params->getLAngleLoc() == Params->getRAngleLoc() &&
+          (TD->getName() != "vector" && TD->getName() != "matrix")) {
+        spaceBeforePlaceHolder(OS);
+        return;
+      }
+      // HLSL Change Ends
       const TemplateArgumentList &TemplateArgs = Spec->getTemplateArgs();
       Args = TemplateArgs.data();
       NumArgs = TemplateArgs.size();

+ 1 - 1
tools/clang/lib/Parse/ParseDeclCXX.cpp

@@ -1023,7 +1023,7 @@ TypeResult Parser::ParseBaseTypeSpecifier(SourceLocation &BaseLoc,
   IdentifierInfo *Id = Tok.getIdentifierInfo();
   SourceLocation IdLoc = ConsumeToken();
 
-  if (Tok.is(tok::less) && !getLangOpts().HLSL) { // HLSL Change - do not fix for HLSL
+  if (Tok.is(tok::less)) {
     // It looks the user intended to write a template-id here, but the
     // template-name was wrong. Try to fix that.
     TemplateNameKind TNK = TNK_Type_template;

+ 3 - 14
tools/clang/lib/Parse/ParseExprCXX.cpp

@@ -541,8 +541,7 @@ bool Parser::ParseOptionalCXXScopeSpecifier(CXXScopeSpec &SS,
 
     // nested-name-specifier:
     //   type-name '<'
-    bool nextIsLess = Next.is(tok::less);
-    if (nextIsLess || getLangOpts().HLSL) { // HLSL Change
+    if (Next.is(tok::less)) {
       TemplateTy Template;
       UnqualifiedId TemplateName;
       TemplateName.setIdentifier(&II, Tok.getLocation());
@@ -553,31 +552,21 @@ bool Parser::ParseOptionalCXXScopeSpecifier(CXXScopeSpec &SS,
                                                         ObjectType,
                                                         EnteringContext,
                                                         Template,
-                                              MemberOfUnknownSpecialization,
-                                                        nextIsLess)) {  // HLSL Change
+                                              MemberOfUnknownSpecialization)) {
         // We have found a template name, so annotate this token
         // with a template-id annotation. We do not permit the
         // template-id to be translated into a type annotation,
         // because some clients (e.g., the parsing of class template
         // specializations) still want to see the original template-id
         // token.
-        if (nextIsLess) { // HLSL Change
         ConsumeToken();
-        }
         if (AnnotateTemplateIdToken(Template, TNK, SS, SourceLocation(),
                                     TemplateName, false))
           return true;
         continue;
       }
 
-      // HLSL Change: avoid handling other cases and emitting incorrect
-      // diagnostics if the template lookup fails.
-      if (!nextIsLess && getLangOpts().HLSL) {
-        break;
-      }
-
-      if (getLangOpts().EnableTemplates && // HLSL Change - template fixup only available when templates enabled
-          MemberOfUnknownSpecialization && (ObjectType || SS.isSet()) && 
+      if (MemberOfUnknownSpecialization && (ObjectType || SS.isSet()) && 
           (IsTypename || IsTemplateArgumentList(1))) {
         // We have something like t::getAs<T>, where getAs is a 
         // member of an unknown specialization. However, this will only

+ 0 - 1
tools/clang/lib/Parse/ParseTemplate.cpp

@@ -1214,7 +1214,6 @@ ParsedTemplateArgument Parser::ParseTemplateArgument() {
   }
   
   // Try to parse a template template argument.
-  if (!getLangOpts().HLSL) // HLSL Change - HLSL does not support template template arguments
   {
     TentativeParsingAction TPA(*this);
 

+ 2 - 5
tools/clang/lib/Parse/Parser.cpp

@@ -1414,9 +1414,7 @@ Parser::TryAnnotateName(bool IsAddressOfOperand,
     if (TryAnnotateTypeOrScopeTokenAfterScopeSpec(EnteringContext, false, SS,
                                                   !WasScopeAnnotation))
       return ANK_Error;
-    // HLSL Change Starts - allow implicitly annotated templates
-    return (Tok.isNot(tok::annot_typename) || SS.isInvalid()) ? ANK_Unresolved : ANK_Success;
-    // HLSL Change End
+    return ANK_Unresolved;
   }
 
   IdentifierInfo *Name = Tok.getIdentifierInfo();
@@ -1748,8 +1746,7 @@ bool Parser::TryAnnotateTypeOrScopeTokenAfterScopeSpec(bool EnteringContext,
                                    /*hasTemplateKeyword=*/false, TemplateName,
                                    /*ObjectType=*/ ParsedType(),
                                    EnteringContext,
-                                   Template, MemberOfUnknownSpecialization,
-                                   /*NextIsLess*/ true)) {  // HLSL Change - additional flag
+                                   Template, MemberOfUnknownSpecialization)) {
         // Consume the identifier.
         ConsumeToken();
         if (AnnotateTemplateIdToken(Template, TNK, SS, SourceLocation(),

+ 5 - 1
tools/clang/lib/Sema/SemaDecl.cpp

@@ -445,6 +445,10 @@ ParsedType Sema::getTypeName(const IdentifierInfo &II, SourceLocation NameLoc,
     (void)DiagnoseUseOfDecl(IDecl, NameLoc);
     if (!HasTrailingDot)
       T = Context.getObjCInterfaceType(IDecl);
+  } else if (getLangOpts().HLSL) { // HLSL - omit empty template argument lists
+    if (ClassTemplateDecl *TD = dyn_cast<ClassTemplateDecl>(IIDecl))
+      if (TypeDecl *DefaultSpec = getHLSLDefaultSpecialization(TD))
+        T = Context.getTypeDeclType(DefaultSpec); // HLSL Change end
   }
 
   if (T.isNull()) {
@@ -602,7 +606,7 @@ void Sema::DiagnoseUnknownTypeName(IdentifierInfo *&II,
     return;
   }
 
-  if (getLangOpts().CPlusPlus && !getLangOpts().HLSL) {  // HLSL Change
+  if (getLangOpts().CPlusPlus) {
     // See if II is a class template that the user forgot to pass arguments to.
     UnqualifiedId Name;
     Name.setIdentifier(II, IILoc);

+ 12 - 2
tools/clang/lib/Sema/SemaExpr.cpp

@@ -2336,9 +2336,19 @@ Sema::ActOnIdExpression(Scope *S, CXXScopeSpec &SS,
       return BuildPossibleImplicitMemberExpr(SS, TemplateKWLoc,
                                              R, TemplateArgs);
   }
-
+  // HLSL Change Begin: Allow templates without empty argument list if default
+  // arguments are provided.
+  if (getLangOpts().HLSL && R.isSingleResult()) {
+    if (TemplateDecl *Template = dyn_cast<TemplateDecl>(R.getFoundDecl())) {
+      if (Template->getTemplateParameters()->getMinRequiredArguments() == 0) {
+        TemplateArgsBuffer.setLAngleLoc(NameLoc);
+        TemplateArgsBuffer.setRAngleLoc(NameLoc);
+        TemplateArgs = &TemplateArgsBuffer;
+      }
+    }
+  }
+  // HLSL Change End
   if (TemplateArgs || TemplateKWLoc.isValid()) {
-
     // In C++1y, if this is a variable template id, then check it
     // in BuildTemplateIdExpr().
     // The single lookup result must be a variable template declaration.

+ 77 - 61
tools/clang/lib/Sema/SemaHLSL.cpp

@@ -31,6 +31,7 @@
 #include "clang/Sema/Template.h"
 #include "clang/Sema/TemplateDeduction.h"
 #include "clang/Sema/SemaHLSL.h"
+#include "llvm/Support/ErrorHandling.h"
 #include "llvm/Support/raw_ostream.h"
 #include "dxc/Support/Global.h"
 #include "dxc/Support/WinIncludes.h"
@@ -4026,35 +4027,39 @@ public:
     return IsRayQueryBasicKind(GetTypeElementKind(type));
   }
 
-  void WarnMinPrecision(HLSLScalarType type, SourceLocation loc) {
+  void WarnMinPrecision(QualType Type, SourceLocation Loc) {
+     Type = Type->getCanonicalTypeUnqualified();
+     if (IsVectorType(m_sema, Type) || IsMatrixType(m_sema, Type)) {
+       Type = GetOriginalMatrixOrVectorElementType(Type);
+     }
     // TODO: enalbe this once we introduce precise master option
     bool UseMinPrecision = m_context->getLangOpts().UseMinPrecision;
-    if (type == HLSLScalarType_int_min12) {
-      const char *PromotedType =
-          UseMinPrecision ? HLSLScalarTypeNames[HLSLScalarType_int_min16]
-                          : HLSLScalarTypeNames[HLSLScalarType_int16];
-      m_sema->Diag(loc, diag::warn_hlsl_sema_minprecision_promotion)
-          << HLSLScalarTypeNames[type] << PromotedType;
-    } else if (type == HLSLScalarType_float_min10) {
-      const char *PromotedType =
-          UseMinPrecision ? HLSLScalarTypeNames[HLSLScalarType_float_min16]
-                          : HLSLScalarTypeNames[HLSLScalarType_float16];
-      m_sema->Diag(loc, diag::warn_hlsl_sema_minprecision_promotion)
-          << HLSLScalarTypeNames[type] << PromotedType;
+    if (Type == m_context->Min12IntTy) {
+      QualType PromotedType =
+          UseMinPrecision ? m_context->Min16IntTy
+                          : m_context->ShortTy;
+      m_sema->Diag(Loc, diag::warn_hlsl_sema_minprecision_promotion)
+          << Type << PromotedType;
+    } else if (Type == m_context->Min10FloatTy) {
+      QualType PromotedType =
+          UseMinPrecision ? m_context->Min16FloatTy
+                          : m_context->HalfTy;
+      m_sema->Diag(Loc, diag::warn_hlsl_sema_minprecision_promotion)
+          << Type << PromotedType;
     }
     if (!UseMinPrecision) {
-      if (type == HLSLScalarType_float_min16) {
-        m_sema->Diag(loc, diag::warn_hlsl_sema_minprecision_promotion)
-            << HLSLScalarTypeNames[type]
-            << HLSLScalarTypeNames[HLSLScalarType_float16];
-      } else if (type == HLSLScalarType_int_min16) {
-        m_sema->Diag(loc, diag::warn_hlsl_sema_minprecision_promotion)
-            << HLSLScalarTypeNames[type]
-            << HLSLScalarTypeNames[HLSLScalarType_int16];
-      } else if (type == HLSLScalarType_uint_min16) {
-        m_sema->Diag(loc, diag::warn_hlsl_sema_minprecision_promotion)
-            << HLSLScalarTypeNames[type]
-            << HLSLScalarTypeNames[HLSLScalarType_uint16];
+      if (Type == m_context->Min16FloatTy) {
+        m_sema->Diag(Loc, diag::warn_hlsl_sema_minprecision_promotion)
+            << Type
+            << m_context->HalfTy;
+      } else if (Type == m_context->Min16IntTy) {
+        m_sema->Diag(Loc, diag::warn_hlsl_sema_minprecision_promotion)
+            << Type
+            << m_context->ShortTy;
+      } else if (Type == m_context->Min16UIntTy) {
+        m_sema->Diag(Loc, diag::warn_hlsl_sema_minprecision_promotion)
+            << Type
+            << m_context->UnsignedShortTy;
       }
     }
   }
@@ -4115,15 +4120,16 @@ public:
     if (TryParseAny(nameIdentifier.data(), nameIdentifier.size(), &parsedType, &rowCount, &colCount, getSema()->getLangOpts())) {
       assert(parsedType != HLSLScalarType_unknown && "otherwise, TryParseHLSLScalarType should not have succeeded.");
       if (rowCount == 0 && colCount == 0) { // scalar
+        if (!DiagnoseHLSLScalarType(parsedType, R.getNameLoc()))
+          return false;
         TypedefDecl *typeDecl = LookupScalarTypeDef(parsedType);
-        if (!typeDecl) return false;
+        if (!typeDecl)
+          return false;
         R.addDecl(typeDecl);
-      }
-      else if (rowCount == 0) { // vector
+      } else if (rowCount == 0) { // vector
         TypedefDecl *qts = LookupVectorShorthandType(parsedType, colCount);
         R.addDecl(qts);
-      }
-      else { // matrix
+      } else { // matrix
         TypedefDecl* qts = LookupMatrixShorthandType(parsedType, rowCount, colCount);
         R.addDecl(qts);
       }
@@ -12782,6 +12788,9 @@ bool Sema::DiagnoseHLSLDecl(Declarator &D, DeclContext *DC, Expr *BitWidth,
   const Type* pType = qt.getTypePtrOrNull();
   HLSLExternalSource *hlslSource = HLSLExternalSource::FromSema(this);
 
+  if (!isFunction)
+    hlslSource->WarnMinPrecision(qt, D.getLocStart());
+
   // Early checks - these are not simple attribution errors, but constructs that
   // are fundamentally unsupported,
   // and so we avoid errors that might indicate they can be repaired.
@@ -12839,6 +12848,7 @@ bool Sema::DiagnoseHLSLDecl(Declarator &D, DeclContext *DC, Expr *BitWidth,
     const FunctionProtoType *pFP = pType->getAs<FunctionProtoType>();
     if (pFP) {
       qt = pFP->getReturnType();
+      hlslSource->WarnMinPrecision(qt, D.getLocStart());
       pType = qt.getTypePtrOrNull();
 
       // prohibit string as a return type
@@ -13298,23 +13308,6 @@ bool Sema::DiagnoseHLSLDecl(Declarator &D, DeclContext *DC, Expr *BitWidth,
   return result;
 }
 
-// Diagnose HLSL types on lookup
-bool Sema::DiagnoseHLSLLookup(const LookupResult &R) {
-  const DeclarationNameInfo declName = R.getLookupNameInfo();
-  IdentifierInfo* idInfo = declName.getName().getAsIdentifierInfo();
-  if (idInfo) {
-    StringRef nameIdentifier = idInfo->getName();
-    HLSLScalarType parsedType;
-    int rowCount, colCount;
-    if (TryParseAny(nameIdentifier.data(), nameIdentifier.size(), &parsedType, &rowCount, &colCount, getLangOpts())) {
-      HLSLExternalSource *hlslExternalSource = HLSLExternalSource::FromSema(this);
-      hlslExternalSource->WarnMinPrecision(parsedType, R.getNameLoc());
-      return hlslExternalSource->DiagnoseHLSLScalarType(parsedType, R.getNameLoc());
-    }
-  }
-  return true;
-}
-
 static QualType getUnderlyingType(QualType Type)
 {
   while (const TypedefType *TD = dyn_cast<TypedefType>(Type))
@@ -13422,30 +13415,26 @@ clang::QualType hlsl::GetOriginalMatrixOrVectorElementType(
 {
   // TODO: Determine if this is really the best way to get the matrix/vector specialization
   // without losing the AttributedType on the template parameter
-  if (const Type* pType = type.getTypePtrOrNull()) {
+  if (const Type* Ty = type.getTypePtrOrNull()) {
     // A non-dependent template specialization type is always "sugar",
     // typically for a RecordType.  For example, a class template
     // specialization type of @c vector<int> will refer to a tag type for
     // the instantiation @c std::vector<int, std::allocator<int>>.
-    if (const TemplateSpecializationType* pTemplate = pType->getAs<TemplateSpecializationType>()) {
+    if (const TemplateSpecializationType* pTemplate = Ty->getAs<TemplateSpecializationType>()) {
       // If we have enough arguments, pull them from the template directly, rather than doing
       // the extra lookups.
       if (pTemplate->getNumArgs() > 0)
         return pTemplate->getArg(0).getAsType();
 
       QualType templateRecord = pTemplate->desugar();
-      const Type *pTemplateRecordType = templateRecord.getTypePtr();
-      if (pTemplateRecordType) {
-        const TagType *pTemplateTagType = pTemplateRecordType->getAs<TagType>();
-        if (pTemplateTagType) {
-          const ClassTemplateSpecializationDecl *specializationDecl =
-              dyn_cast_or_null<ClassTemplateSpecializationDecl>(
-                  pTemplateTagType->getDecl());
-          if (specializationDecl) {
-            return specializationDecl->getTemplateArgs()[0].getAsType();
-          }
-        }
-      }
+      Ty = templateRecord.getTypePtr();
+    }
+    if (!Ty)
+      return QualType();
+    
+    if (const auto *TagTy = Ty->getAs<TagType>()) {
+      if (const auto *SpecDecl = dyn_cast_or_null<ClassTemplateSpecializationDecl>(TagTy->getDecl()))
+        return SpecDecl->getTemplateArgs()[0].getAsType();
     }
   }
   return QualType();
@@ -13968,3 +13957,30 @@ clang::QualType ApplyTypeSpecSignToParsedType(
 {
     return HLSLExternalSource::FromSema(self)->ApplyTypeSpecSignToParsedType(type, TSS, Loc);
 }
+
+ClassTemplateSpecializationDecl *
+Sema::getHLSLDefaultSpecialization(ClassTemplateDecl *Decl) {
+  if (Decl->getTemplateParameters()->getMinRequiredArguments() == 0) {
+    void *InsertPos = nullptr;
+    TemplateArgumentListInfo EmptyArgs;
+    EmptyArgs.setLAngleLoc(Decl->getSourceRange().getEnd());
+    EmptyArgs.setRAngleLoc(Decl->getSourceRange().getEnd());
+    SmallVector<TemplateArgument, 2> Converted;
+    if (!CheckTemplateArgumentList(Decl, Decl->getSourceRange().getEnd(), EmptyArgs,
+                                   false, Converted)) {
+      ClassTemplateSpecializationDecl *DefaultSpec =
+          Decl->findSpecialization(Converted, InsertPos);
+      if (!DefaultSpec) {
+        DefaultSpec = ClassTemplateSpecializationDecl::Create(
+            getASTContext(), TagDecl::TagKind::TTK_Class,
+            getASTContext().getTranslationUnitDecl(), SourceLocation(),
+            SourceLocation(), Decl, Converted.data(), Converted.size(),
+            DefaultSpec);
+        Decl->AddSpecialization(DefaultSpec, InsertPos);
+        DefaultSpec->setImplicit(true);
+      }
+      return DefaultSpec;
+    }
+  }
+  return nullptr;
+}

+ 34 - 25
tools/clang/lib/Sema/SemaTemplate.cpp

@@ -140,8 +140,7 @@ TemplateNameKind Sema::isTemplateName(Scope *S,
                                       ParsedType ObjectTypePtr,
                                       bool EnteringContext,
                                       TemplateTy &TemplateResult,
-                                      bool &MemberOfUnknownSpecialization,
-                                      bool NextIsLess) { // HLSL CHange
+                                      bool &MemberOfUnknownSpecialization) {
   assert(getLangOpts().CPlusPlus && "No template names in C!");
 
   DeclarationName TName;
@@ -169,8 +168,7 @@ TemplateNameKind Sema::isTemplateName(Scope *S,
 
   LookupResult R(*this, TName, Name.getLocStart(), LookupOrdinaryName);
   LookupTemplateName(R, S, SS, ObjectType, EnteringContext,
-                     MemberOfUnknownSpecialization,
-                     NextIsLess); // HLSL Change
+                     MemberOfUnknownSpecialization);
   if (R.empty()) return TNK_Non_template;
   if (R.isAmbiguous()) {
     // Suppress diagnostics;  we'll redo this lookup later.
@@ -250,8 +248,7 @@ void Sema::LookupTemplateName(LookupResult &Found,
                               Scope *S, CXXScopeSpec &SS,
                               QualType ObjectType,
                               bool EnteringContext,
-                              bool &MemberOfUnknownSpecialization,
-                              bool NextIsLess) { // HLSL Change
+                              bool &MemberOfUnknownSpecialization) {
   // Determine where to perform name lookup
   MemberOfUnknownSpecialization = false;
   DeclContext *LookupCtx = nullptr;
@@ -312,18 +309,11 @@ void Sema::LookupTemplateName(LookupResult &Found,
   } else {
     // Perform unqualified name lookup in the current scope.
     LookupName(Found, S);
-    // HLSL Change: Diagnose on lookup level. Currently this is used to throw warnings for minprecision promotion
-    if (getLangOpts().HLSL)
-      DiagnoseHLSLLookup(Found);
-    // HLSL Change End
     if (!ObjectType.isNull())
       AllowFunctionTemplatesInLookup = false;
   }
 
-  // HLSL Change: do not try to save template name lookups with auto-correct,
-  // otherwise identifiers like variable-names might match and fail;
-  // however we still do this if 'NextIsLess' is known to be true.
-  if (Found.empty() && !isDependent && (!getLangOpts().HLSL || NextIsLess)) {
+  if (Found.empty() && !isDependent) {
     // If we did not find any names, attempt to correct any typos.
     DeclarationName Name = Found.getLookupName();
     Found.clear();
@@ -3058,22 +3048,41 @@ bool Sema::CheckTemplateTypeArgument(TemplateTypeParmDecl *Param,
   case TemplateArgument::Template: {
     // We have a template type parameter but the template argument
     // is a template without any arguments.
-    // HLSL Change Starts
-    // We suppress some errors when templates are enabled in order to preserve
-    // backwards compatibility.
     SourceRange SR = AL.getSourceRange();
     TemplateName Name = Arg.getAsTemplate();
+
+    // HLSL Change Starts
+    // HLSL allows omiting empty template argument lists
     TemplateDecl *Decl = Name.getAsTemplateDecl();
-    if (Decl && !Decl->getLocation().isValid() && getLangOpts().EnableTemplates)
-      break;
-    Diag(SR.getBegin(), diag::err_template_missing_args)
-      << Name << SR;
-    if (Decl && Decl->getLocation().isValid()) { // HLSL Change - ellide location notes for built-ins
-      Diag(Decl->getLocation(), diag::note_template_decl_here);
+    if (getLangOpts().HLSL && Decl) {
+      if (ClassTemplateDecl *TD = dyn_cast<ClassTemplateDecl>(Decl)) {
+        if (TypeDecl *DefaultSpec = getHLSLDefaultSpecialization(TD)) {
+          SourceRange SR = Decl->getSourceRange();
+          TemplateArgumentListInfo TemplateArgs(SR.getEnd(), SR.getEnd());
+          ArgType = CheckTemplateIdType(TemplateName(Decl), SR.getBegin(),
+                                        TemplateArgs);
+          CXXScopeSpec SS;
+          TypeLocBuilder TLB;
+          TemplateSpecializationTypeLoc TL =
+              TLB.push<TemplateSpecializationTypeLoc>(ArgType);
+          TL.setTemplateKeywordLoc(SourceLocation());
+          TL.setTemplateNameLoc(SR.getBegin());
+          TL.setLAngleLoc(SR.getEnd());
+          TL.setRAngleLoc(SR.getEnd());
+          TSI = TLB.getTypeSourceInfo(Context, ArgType);
+        }
+      }
     }
+    if (ArgType.isNull()) {
+      Diag(SR.getBegin(), diag::err_template_missing_args) << Name << SR;
+      // HLSL Change - ellide location notes for built-ins
+      if (Decl && Decl->getLocation().isValid()) {
+        Diag(Decl->getLocation(), diag::note_template_decl_here);
+      }
+      return true;
+    }
+    break;
     // HLSL Change Ends
-
-    return true;
   }
   case TemplateArgument::Expression: {
     // We have a template type parameter but the template argument is an

+ 2 - 2
tools/clang/test/CodeGenSPIRV/decoration.user-type.hlsl

@@ -47,9 +47,9 @@ RWBuffer<float> t;
 Texture2DMSArray<float4, 64> u;
 // CHECK: OpDecorateString %v UserTypeGOOGLE "texture2dmsarray:<float4,64>"
 const Texture2DMSArray<float4, 64> v;
-// CHECK: OpDecorateString %t1 UserTypeGOOGLE "texture1d"
+// CHECK: OpDecorateString %t1 UserTypeGOOGLE "texture1d:<vector<float,4> >"
 Texture1D t1;
-// CHECK: OpDecorateString %t2 UserTypeGOOGLE "texture2d"
+// CHECK: OpDecorateString %t2 UserTypeGOOGLE "texture2d:<vector<float,4> >"
 Texture2D t2;
 
 // CHECK: OpDecorateString %eArr UserTypeGOOGLE "texture1d:<float>"

+ 3 - 3
tools/clang/test/HLSL/const-default.hlsl

@@ -5,7 +5,7 @@ int4 g_vec1;                                                /* expected-note {{v
 uint64_t3x4 g_mat1;                                         /* fxc-error {{X3000: unrecognized identifier 'uint64_t3x4'}} */
 
 cbuffer g_cbuffer {
-    min12int m_buffer_min12int;                             /* expected-note {{variable 'm_buffer_min12int' declared const here}} expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+    min12int m_buffer_min12int;                             /* expected-note {{variable 'm_buffer_min12int' declared const here}} expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}} */
     float4 m_buffer_float4;                                 /* expected-note {{variable 'm_buffer_float4' declared const here}} fxc-pass {{}} */
     int3x4 m_buffer_int3x4;
 }
@@ -22,7 +22,7 @@ struct MyStruct {
 };
 
 ConstantBuffer<MyStruct> g_const_buffer;
-TextureBuffer<MyStruct> g_texture_buffer;                
+TextureBuffer<MyStruct> g_texture_buffer;
 
 float4 main() : SV_TARGET
 {
@@ -45,4 +45,4 @@ float4 main() : SV_TARGET
     g_texture_buffer.my_int3x4._14 = 3;                     /* expected-error {{read-only variable is not assignable}} fxc-error {{X3025: global variables are implicitly constant, enable compatibility mode to allow modification}} */
 
     return (float4)g_float1;
-}
+}

+ 2 - 2
tools/clang/test/HLSL/const-expr.hlsl

@@ -4,7 +4,7 @@ float overload1(float f) { return 1; }                        /* expected-note {
 double overload1(double f) { return 2; }                       /* expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} fxc-pass {{}} */
 int overload1(int i) { return 3; }                             /* expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} fxc-pass {{}} */
 uint overload1(uint i) { return 4; }                           /* expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} fxc-pass {{}} */
-min12int overload1(min12int i) { return 5; }                   /* expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} expected-warning {{min12int is promoted to min16int}} expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+min12int overload1(min12int i) { return 5; }                   /* expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} expected-note {{candidate function}} expected-warning {{'min12int' is promoted to 'min16int'}} expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}} */
 
 
 static const float2 g_f2_arr[8] =
@@ -382,4 +382,4 @@ void fn_ice() {
 }
 
 void cs_main() {
-}
+}

+ 4 - 4
tools/clang/test/HLSL/conversions-non-numeric-aggregates.hlsl

@@ -7,13 +7,13 @@ struct ObjStruct { Buffer a; };
 
 void main()
 {
-  (Buffer[1])0; /* expected-error {{cannot convert from 'literal int' to 'Buffer [1]'}} fxc-error {{X3017: cannot convert from 'int' to 'Buffer<float4>[1]'}} */
+  (Buffer[1])0; /* expected-error {{cannot convert from 'literal int' to 'Buffer<vector<float, 4> > [1]'}} fxc-error {{X3017: cannot convert from 'int' to 'Buffer<float4>[1]'}} */
   (ObjStruct)0; /* expected-error {{cannot convert from 'literal int' to 'ObjStruct'}} fxc-error {{X3017: cannot convert from 'int' to 'struct ObjStruct'}} */
-  (Buffer[1])(int[1])0; /* expected-error {{cannot convert from 'int [1]' to 'Buffer [1]'}} fxc-error {{X3017: cannot convert from 'const int[1]' to 'Buffer<float4>[1]'}} */
+  (Buffer[1])(int[1])0; /* expected-error {{cannot convert from 'int [1]' to 'Buffer<vector<float, 4> > [1]'}} fxc-error {{X3017: cannot convert from 'const int[1]' to 'Buffer<float4>[1]'}} */
   (ObjStruct)(NumStruct)0; /* expected-error {{cannot convert from 'NumStruct' to 'ObjStruct'}} fxc-error {{X3017: cannot convert from 'const struct NumStruct' to 'struct ObjStruct'}} */
 
   Buffer oa1[1];
   ObjStruct os1;
-  (int)oa1; /* expected-error {{cannot convert from 'Buffer [1]' to 'int'}} fxc-error {{X3017: cannot convert from 'Buffer<float4>[1]' to 'int'}} */
+  (int)oa1; /* expected-error {{cannot convert from 'Buffer<vector<float, 4> > [1]' to 'int'}} fxc-error {{X3017: cannot convert from 'Buffer<float4>[1]' to 'int'}} */
   (int)os1; /* expected-error {{cannot convert from 'ObjStruct' to 'int'}} fxc-error {{X3017: cannot convert from 'struct ObjStruct' to 'int'}} */
-}
+}

+ 1 - 1
tools/clang/test/HLSL/enums.hlsl

@@ -74,7 +74,7 @@ enum MyEnumMin16Float : min16float {                        /* expected-error {{
   ZEROMIN16F,
 };
 
-enum MyEnumMin10Float : min10float {                        /* expected-error {{non-integral type 'min10float' is an invalid underlying type}} expected-warning {{min10float is promoted to min16float}} */
+enum MyEnumMin10Float : min10float {                        /* expected-error {{non-integral type 'min10float' is an invalid underlying type}} */
   ZEROMIN10F,
 };
 

+ 2 - 2
tools/clang/test/HLSL/functions.hlsl

@@ -220,11 +220,11 @@ void fn_uint_oload3(inout uint u) { }
 void fn_uint_oload3(out uint u) { }
 
 // function redefinitions
-void fn_redef(min10float x) {}      /* expected-warning {{min10float is promoted to min16float}} fxc-pass {{}} */
+void fn_redef(min10float x) {}      /* expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}} */
 void fn_redef(min16float x) {}
 
 
-void fn_redef2(min12int x) {}       /* expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+void fn_redef2(min12int x) {}       /* expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}} */
 void fn_redef2(min16int x) {}
 
 void fn_redef3(half x) {}

+ 27 - 27
tools/clang/test/HLSL/indexing-operator.hlsl

@@ -29,10 +29,10 @@ Texture1DArray g_t1da;
 Texture2D g_t2d;
 Texture2DArray g_t2da;
 // fxc error X3000: syntax error: unexpected token 'g_t2dms_err'
-Texture2DMS g_t2dms_err; // expected-error {{too few template arguments for class template 'Texture2DMS'}} fxc-error {{X3000: syntax error: unexpected token 'g_t2dms_err'}}
+Texture2DMS g_t2dms_err; // expected-error {{use of class template 'Texture2DMS' requires template arguments}} fxc-error {{X3000: syntax error: unexpected token 'g_t2dms_err'}}
 Texture2DMS<float4, 8> g_t2dms;
 // fxc error X3000: syntax error: unexpected token 'g_t2dmsa_err'
-Texture2DMSArray g_t2dmsa_err; // expected-error {{too few template arguments for class template 'Texture2DMSArray'}} fxc-error {{X3000: syntax error: unexpected token 'g_t2dmsa_err'}}
+Texture2DMSArray g_t2dmsa_err; // expected-error {{use of class template 'Texture2DMSArray' requires template arguments}} fxc-error {{X3000: syntax error: unexpected token 'g_t2dmsa_err'}}
 Texture2DMSArray<float4, 8> g_t2dmsa;
 Texture3D g_t3d;
 TextureCube g_tc;
@@ -40,22 +40,22 @@ TextureCubeArray g_tca;
 
 RWStructuredBuffer<float4> g_rw_sb;
 // fxc error X3000: syntax error: unexpected token 'g_rw_b_err'
-RWBuffer g_rw_b_err; // expected-error {{too few template arguments for class template 'RWBuffer'}} fxc-error {{X3000: syntax error: unexpected token 'g_rw_b_err'}}
+RWBuffer g_rw_b_err; // expected-error {{use of class template 'RWBuffer' requires template arguments}} fxc-error {{X3000: syntax error: unexpected token 'g_rw_b_err'}}
 RWBuffer<float4> g_rw_b;
 // fxc error X3000: syntax error: unexpected token 'g_rw_t1d_err'
-RWTexture1D g_rw_t1d_err; // expected-error {{too few template arguments for class template 'RWTexture1D'}} fxc-error {{X3000: syntax error: unexpected token 'g_rw_t1d_err'}}
+RWTexture1D g_rw_t1d_err; // expected-error {{use of class template 'RWTexture1D' requires template arguments}} fxc-error {{X3000: syntax error: unexpected token 'g_rw_t1d_err'}}
 RWTexture1D<float4> g_rw_t1d;
 // fxc error X3000: syntax error: unexpected token 'g_rw_t1da_err'
-RWTexture1DArray g_rw_t1da_err; // expected-error {{too few template arguments for class template 'RWTexture1DArray'}} fxc-error {{X3000: syntax error: unexpected token 'g_rw_t1da_err'}}
+RWTexture1DArray g_rw_t1da_err; // expected-error {{use of class template 'RWTexture1DArray' requires template arguments}} fxc-error {{X3000: syntax error: unexpected token 'g_rw_t1da_err'}}
 RWTexture1DArray<float4> g_rw_t1da;
 // fxc error X3000: syntax error: unexpected token 'g_rw_t2d_err'
-RWTexture2D g_rw_t2d_err; // expected-error {{too few template arguments for class template 'RWTexture2D'}} fxc-error {{X3000: syntax error: unexpected token 'g_rw_t2d_err'}}
+RWTexture2D g_rw_t2d_err; // expected-error {{use of class template 'RWTexture2D' requires template arguments}} fxc-error {{X3000: syntax error: unexpected token 'g_rw_t2d_err'}}
 RWTexture2D<float4> g_rw_t2d;
 // fxc error X3000: syntax error: unexpected token 'g_rw_t2da_err'
-RWTexture2DArray g_rw_t2da_err; // expected-error {{too few template arguments for class template 'RWTexture2DArray'}} fxc-error {{X3000: syntax error: unexpected token 'g_rw_t2da_err'}}
+RWTexture2DArray g_rw_t2da_err; // expected-error {{use of class template 'RWTexture2DArray' requires template arguments}} fxc-error {{X3000: syntax error: unexpected token 'g_rw_t2da_err'}}
 RWTexture2DArray<float4> g_rw_t2da;
 // fxc error X3000: syntax error: unexpected token 'g_rw_t3d_err'
-RWTexture3D g_rw_t3d_err; // expected-error {{too few template arguments for class template 'RWTexture3D'}} fxc-error {{X3000: syntax error: unexpected token 'g_rw_t3d_err'}}
+RWTexture3D g_rw_t3d_err; // expected-error {{use of class template 'RWTexture3D' requires template arguments}} fxc-error {{X3000: syntax error: unexpected token 'g_rw_t3d_err'}}
 RWTexture3D<float4> g_rw_t3d;
 
 // No such thing as these:
@@ -127,21 +127,21 @@ float4 test_scalar_indexing()
           `-IntegerLiteral <col:14> 'literal int' 0
   */
   // fxc error X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
-  f4 += g_t1da[0]; // expected-error {{no viable overloaded operator[] for type 'Texture1DArray'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'literal int' to 'vector<uint, 2>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
+  f4 += g_t1da[0]; // expected-error {{no viable overloaded operator[] for type 'Texture1DArray<vector<float, 4> >'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'literal int' to 'vector<uint, 2>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   // fxc error X3120 : invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
-  f4 += g_t2d[0]; // expected-error {{no viable overloaded operator[] for type 'Texture2D'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'literal int' to 'vector<uint, 2>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
+  f4 += g_t2d[0]; // expected-error {{no viable overloaded operator[] for type 'Texture2D<vector<float, 4> >'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'literal int' to 'vector<uint, 2>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   // fxc error X3120 : invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
-  f4 += g_t2da[0]; // expected-error {{no viable overloaded operator[] for type 'Texture2DArray'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'literal int' to 'vector<uint, 3>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
+  f4 += g_t2da[0]; // expected-error {{no viable overloaded operator[] for type 'Texture2DArray<vector<float, 4> >'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'literal int' to 'vector<uint, 3>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   // fxc error X3120 : invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
   f4 += g_t2dms[0]; // expected-error {{no viable overloaded operator[] for type 'Texture2DMS<float4, 8>'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'literal int' to 'vector<uint, 2>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   // fxc error X3120 : invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
   f4 += g_t2dmsa[0]; // expected-error {{no viable overloaded operator[] for type 'Texture2DMSArray<float4, 8>'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'literal int' to 'vector<uint, 3>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   // fxc error X3120 : invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
-  f4 += g_t3d[0]; // expected-error {{no viable overloaded operator[] for type 'Texture3D'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'literal int' to 'vector<uint, 3>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
+  f4 += g_t3d[0]; // expected-error {{no viable overloaded operator[] for type 'Texture3D<vector<float, 4> >'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'literal int' to 'vector<uint, 3>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   // fxc  error X3121: array, matrix, vector, or indexable object type expected in index expression
-  f4 += g_tc[0]; // expected-error {{type 'TextureCube' does not provide a subscript operator}} fxc-error {{X3121: array, matrix, vector, or indexable object type expected in index expression}}
+  f4 += g_tc[0]; // expected-error {{type 'TextureCube<vector<float, 4> >' does not provide a subscript operator}} fxc-error {{X3121: array, matrix, vector, or indexable object type expected in index expression}}
   // fxc  error X3121: array, matrix, vector, or indexable object type expected in index expression
-  f4 += g_tca[0]; // expected-error {{type 'TextureCubeArray' does not provide a subscript operator}} fxc-error {{X3121: array, matrix, vector, or indexable object type expected in index expression}}
+  f4 += g_tca[0]; // expected-error {{type 'TextureCubeArray<vector<float, 4> >' does not provide a subscript operator}} fxc-error {{X3121: array, matrix, vector, or indexable object type expected in index expression}}
 
   g_b[0] = f4;          /* expected-error {{cannot assign to return value because function 'operator[]<const vector<float, 4> &>' returns a const value}} fxc-error {{X3025: l-value specifies const object}} */
   g_t1d[0] = f4;        /* expected-error {{cannot assign to return value because function 'operator[]<const vector<float, 4> &>' returns a const value}} fxc-error {{X3025: l-value specifies const object}} */
@@ -199,9 +199,9 @@ float4 test_vector2_indexing()
   int2 offset = { 1, 2 };
   float4 f4 = 0;
   // fxc error X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
-  f4 += g_b[offset]; // expected-error {{no viable overloaded operator[] for type 'Buffer'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'int2' to 'unsigned int' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
+  f4 += g_b[offset]; // expected-error {{no viable overloaded operator[] for type 'Buffer<vector<float, 4> >'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'int2' to 'unsigned int' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   // fxc error X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
-  f4 += g_t1d[offset]; // expected-error {{no viable overloaded operator[] for type 'Texture1D'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'int2' to 'unsigned int' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
+  f4 += g_t1d[offset]; // expected-error {{no viable overloaded operator[] for type 'Texture1D<vector<float, 4> >'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'int2' to 'unsigned int' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   // fxc error X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
   f4 += g_sb[offset]; // expected-error {{no viable overloaded operator[] for type 'StructuredBuffer<float4>'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'int2' to 'unsigned int' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   f4 += g_t1da[offset];
@@ -233,16 +233,16 @@ float4 test_vector2_indexing()
             `-DeclRefExpr <col:15> 'int2':'vector<int, 2>' lvalue Var 'offset' 'int2':'vector<int, 2>'
   */
   // fxc error X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
-  f4 += g_t2da[offset]; // expected-error {{no viable overloaded operator[] for type 'Texture2DArray'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'vector<int, 2>' to 'vector<uint, 3>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
+  f4 += g_t2da[offset]; // expected-error {{no viable overloaded operator[] for type 'Texture2DArray<vector<float, 4> >'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'vector<int, 2>' to 'vector<uint, 3>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   f4 += g_t2dms[offset];
   // fxc error X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
   f4 += g_t2dmsa[offset]; // expected-error {{no viable overloaded operator[] for type 'Texture2DMSArray<float4, 8>'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'vector<int, 2>' to 'vector<uint, 3>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   // fxc error X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
-  f4 += g_t3d[offset]; // expected-error {{no viable overloaded operator[] for type 'Texture3D'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'vector<int, 2>' to 'vector<uint, 3>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
+  f4 += g_t3d[offset]; // expected-error {{no viable overloaded operator[] for type 'Texture3D<vector<float, 4> >'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'vector<int, 2>' to 'vector<uint, 3>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   // fxc error X3121: array, matrix, vector, or indexable object type expected in index expression
-  f4 += g_tc[offset]; // expected-error {{type 'TextureCube' does not provide a subscript operator}} fxc-error {{X3121: array, matrix, vector, or indexable object type expected in index expression}}
+  f4 += g_tc[offset]; // expected-error {{type 'TextureCube<vector<float, 4> >' does not provide a subscript operator}} fxc-error {{X3121: array, matrix, vector, or indexable object type expected in index expression}}
   // fxc error X3121: array, matrix, vector, or indexable object type expected in index expression
-  f4 += g_tca[offset]; // expected-error {{type 'TextureCubeArray' does not provide a subscript operator}} fxc-error {{X3121: array, matrix, vector, or indexable object type expected in index expression}}
+  f4 += g_tca[offset]; // expected-error {{type 'TextureCubeArray<vector<float, 4> >' does not provide a subscript operator}} fxc-error {{X3121: array, matrix, vector, or indexable object type expected in index expression}}
 
   g_t1da[offset] = f4;    /* expected-error {{cannot assign to return value because function 'operator[]<const vector<float, 4> &>' returns a const value}} fxc-error {{X3025: l-value specifies const object}} */
   g_t2d[offset] = f4;     /* expected-error {{cannot assign to return value because function 'operator[]<const vector<float, 4> &>' returns a const value}} fxc-error {{X3025: l-value specifies const object}} */
@@ -290,15 +290,15 @@ float4 test_vector3_indexing()
   int3 offset = { 1, 2, 3 };
   float4 f4 = 0;
   // fxc error X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
-  f4 += g_b[offset]; // expected-error {{no viable overloaded operator[] for type 'Buffer'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'int3' to 'unsigned int' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
+  f4 += g_b[offset]; // expected-error {{no viable overloaded operator[] for type 'Buffer<vector<float, 4> >'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'int3' to 'unsigned int' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   // fxc error X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
-  f4 += g_t1d[offset]; // expected-error {{no viable overloaded operator[] for type 'Texture1D'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'int3' to 'unsigned int' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
+  f4 += g_t1d[offset]; // expected-error {{no viable overloaded operator[] for type 'Texture1D<vector<float, 4> >'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'int3' to 'unsigned int' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   // fxc error X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
   f4 += g_sb[offset]; // expected-error {{no viable overloaded operator[] for type 'StructuredBuffer<float4>'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'int3' to 'unsigned int' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   // fxc error X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
-  f4 += g_t1da[offset]; // expected-error {{no viable overloaded operator[] for type 'Texture1DArray'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'vector<int, 3>' to 'vector<uint, 2>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
+  f4 += g_t1da[offset]; // expected-error {{no viable overloaded operator[] for type 'Texture1DArray<vector<float, 4> >'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'vector<int, 3>' to 'vector<uint, 2>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   // fxc error X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions
-  f4 += g_t2d[offset]; // expected-error {{no viable overloaded operator[] for type 'Texture2D'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'vector<int, 3>' to 'vector<uint, 2>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
+  f4 += g_t2d[offset]; // expected-error {{no viable overloaded operator[] for type 'Texture2D<vector<float, 4> >'}} expected-note {{candidate function [with element = const vector<float, 4> &] not viable: no known conversion from 'vector<int, 3>' to 'vector<uint, 2>' for 1st argument}} fxc-error {{X3120: invalid type for index - index must be a scalar, or a vector with the correct number of dimensions}}
   f4 += g_t2da[offset];
   /*verify-ast
     CompoundAssignOperator <col:3, col:22> 'float4':'vector<float, 4>' lvalue '+=' ComputeLHSTy='float4':'vector<float, 4>' ComputeResultTy='float4':'vector<float, 4>'
@@ -344,9 +344,9 @@ float4 test_vector3_indexing()
             `-DeclRefExpr <col:15> 'int3':'vector<int, 3>' lvalue Var 'offset' 'int3':'vector<int, 3>'
   */
   // fxc error X3121: array, matrix, vector, or indexable object type expected in index expression
-  f4 += g_tc[offset]; // expected-error {{type 'TextureCube' does not provide a subscript operator}} fxc-error {{X3121: array, matrix, vector, or indexable object type expected in index expression}}
+  f4 += g_tc[offset]; // expected-error {{type 'TextureCube<vector<float, 4> >' does not provide a subscript operator}} fxc-error {{X3121: array, matrix, vector, or indexable object type expected in index expression}}
   // fxc error X3121: array, matrix, vector, or indexable object type expected in index expression
-  f4 += g_tca[offset]; // expected-error {{type 'TextureCubeArray' does not provide a subscript operator}} fxc-error {{X3121: array, matrix, vector, or indexable object type expected in index expression}}
+  f4 += g_tca[offset]; // expected-error {{type 'TextureCubeArray<vector<float, 4> >' does not provide a subscript operator}} fxc-error {{X3121: array, matrix, vector, or indexable object type expected in index expression}}
 
   g_t2da[offset] = f4;      /* expected-error {{cannot assign to return value because function 'operator[]<const vector<float, 4> &>' returns a const value}} fxc-error {{X3025: l-value specifies const object}} */
   g_t2dmsa[offset] = f4;    /* expected-error {{cannot assign to return value because function 'operator[]<const vector<float, 4> &>' returns a const value}} fxc-error {{X3025: l-value specifies const object}} */
@@ -785,4 +785,4 @@ void my_subscripts()
 
 float4 plain(float4 param4 /* : FOO */) /*: FOO */{
   return 0; //  test_mips_double_indexing();
-}
+}

+ 4 - 4
tools/clang/test/HLSL/intrinsic-examples.hlsl

@@ -17,14 +17,14 @@ float4 RWByteAddressBufferMain(uint2 a : A, uint2 b : B) : SV_Target
   uint status;
   // TODO - fix the following error - the subscript exist, but the indexer type is incorrect - message is misleading
   r += uav1[b]; // expected-error {{type 'RWByteAddressBuffer' does not provide a subscript operator}} fxc-error {{X3121: array, matrix, vector, or indexable object type expected in index expression}}
-  r += uav1.Load(a); // expected-error {{no matching member function for call to 'Load'}} expected-note {{candidate function template not viable: requires 2 arguments, but 1 was provided}} fxc-error {{X3013:     RWByteAddressBuffer<uint>.Load(uint)}} fxc-error {{X3013:     RWByteAddressBuffer<uint>.Load(uint, out uint status)}} fxc-error {{X3013: 'Load': no matching 1 parameter intrinsic method}} fxc-error {{X3013: Possible intrinsic methods are:}}
-  uav1.Load(a, status); // expected-error {{no matching member function for call to 'Load'}} expected-note {{candidate function template not viable: requires single argument 'byteOffset', but 2 arguments were provided}} fxc-error {{X3013:     RWByteAddressBuffer<uint>.Load(uint)}} fxc-error {{X3013:     RWByteAddressBuffer<uint>.Load(uint, out uint status)}} fxc-error {{X3013: 'Load': no matching 2 parameter intrinsic method}} fxc-error {{X3013: Possible intrinsic methods are:}}
+  r += uav1.Load(a); // expected-error {{no matching member function for call to 'Load'}} expected-note {{candidate function not viable: no known conversion from 'uint2' to 'TbyteOffset' for 1st argument}} expected-note {{candidate function template not viable: requires 2 arguments, but 1 was provided}} expected-note {{candidate function template not viable: requires 2 arguments, but 1 was provided}} fxc-error {{X3013:     RWByteAddressBuffer<uint>.Load(uint)}} fxc-error {{X3013:     RWByteAddressBuffer<uint>.Load(uint, out uint status)}} fxc-error {{X3013: 'Load': no matching 1 parameter intrinsic method}} fxc-error {{X3013: Possible intrinsic methods are:}}
+  uav1.Load(a, status); // expected-error {{no matching member function for call to 'Load'}} expected-note {{candidate function not viable: no known conversion from 'uint2' to 'TbyteOffset' for 1st argument}} expected-note {{candidate function template not viable: requires single argument 'byteOffset', but 2 arguments were provided}} expected-note {{candidate function template not viable: requires single argument 'byteOffset', but 2 arguments were provided}} fxc-error {{X3013:     RWByteAddressBuffer<uint>.Load(uint)}} fxc-error {{X3013:     RWByteAddressBuffer<uint>.Load(uint, out uint status)}} fxc-error {{X3013: 'Load': no matching 2 parameter intrinsic method}} fxc-error {{X3013: Possible intrinsic methods are:}}
   r += status;
-  uav1.Load(a, status); // expected-error {{no matching member function for call to 'Load'}} expected-note {{requires single argument 'byteOffset', but 2 arguments were provided}} fxc-error {{X3013:     RWByteAddressBuffer<uint>.Load(uint)}} fxc-error {{X3013:     RWByteAddressBuffer<uint>.Load(uint, out uint status)}} fxc-error {{X3013: 'Load': no matching 2 parameter intrinsic method}} fxc-error {{X3013: Possible intrinsic methods are:}}
+  uav1.Load(a, status); // expected-error {{no matching member function for call to 'Load'}} expected-note {{candidate function not viable: no known conversion from 'uint2' to 'TbyteOffset' for 1st argument}} expected-note {{candidate function template not viable: requires single argument 'byteOffset', but 2 arguments were provided}} expected-note {{requires single argument 'byteOffset', but 2 arguments were provided}} fxc-error {{X3013:     RWByteAddressBuffer<uint>.Load(uint)}} fxc-error {{X3013:     RWByteAddressBuffer<uint>.Load(uint, out uint status)}} fxc-error {{X3013: 'Load': no matching 2 parameter intrinsic method}} fxc-error {{X3013: Possible intrinsic methods are:}}
   r += status;
   uav1[b] = r; // expected-error {{type 'RWByteAddressBuffer' does not provide a subscript operator}} fxc-error {{X3121: array, matrix, vector, or indexable object type expected in index expression}}
   uav1.Load(a.x, status);
-  min16float4 h = min16float4(1,2,3,4);                     /* expected-warning {{min16float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} */
+  min16float4 h = min16float4(1,2,3,4);                     /* expected-warning {{'min16float' is promoted to 'half'}} */
 
   // valid template argument
   r += uav1.Load<half4>(0);

+ 6 - 6
tools/clang/test/HLSL/literals.hlsl

@@ -163,8 +163,8 @@ float test() {
   VERIFY_TYPES(min16float4x4, m16f4x4 * (0.5 + 1));
 
   // Ensure Conversion works.
-  VERIFY_TYPE_CONVERSION(min10float, 1.5f);  /* expected-warning {{min10float is promoted to min16float}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} */
-  VERIFY_TYPE_CONVERSION(min10float, 0.25l); /* expected-warning {{min10float is promoted to min16float}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} */
+  VERIFY_TYPE_CONVERSION(min10float, 1.5f);  /* expected-warning {{'min10float' is promoted to 'min16float'}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} */
+  VERIFY_TYPE_CONVERSION(min10float, 0.25l); /* expected-warning {{'min10float' is promoted to 'min16float'}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} */
 
   VERIFY_TYPE_CONVERSION(min16float, 1.5f);  /* fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} */
   VERIFY_TYPE_CONVERSION(min16float, 2.5l);  /* fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} */
@@ -184,9 +184,9 @@ float test() {
   VERIFY_TYPE_CONVERSION(uint, 1UL);
   VERIFY_TYPE_CONVERSION(uint, 1LL);         /* fxc-error {{X3000: syntax error: unexpected token 'L'}} */
 
-  VERIFY_TYPE_CONVERSION(min12int, 1L);  /* expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
-  VERIFY_TYPE_CONVERSION(min12int, 1UL); /* expected-warning {{min12int is promoted to min16int}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} */
-  VERIFY_TYPE_CONVERSION(min12int, 1LL); /* expected-warning {{min12int is promoted to min16int}} fxc-error {{X3000: syntax error: unexpected token 'L'}} */
+  VERIFY_TYPE_CONVERSION(min12int, 1L);  /* expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}} */
+  VERIFY_TYPE_CONVERSION(min12int, 1UL); /* expected-warning {{'min12int' is promoted to 'min16int'}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} */
+  VERIFY_TYPE_CONVERSION(min12int, 1LL); /* expected-warning {{'min12int' is promoted to 'min16int'}} fxc-error {{X3000: syntax error: unexpected token 'L'}} */
 
   VERIFY_TYPE_CONVERSION(min16int, 1L);
   VERIFY_TYPE_CONVERSION(min16int, 1UL); /* fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} */
@@ -205,4 +205,4 @@ float test() {
   return 0.0f;
 }
 
-int half_btf(int w,int bit) { return (w + (1<<bit)) >> bit; } /* expected-warning {{ambiguous type for bit shift; use a type suffix on literal values, like 'L' or 'U', or a cast}} fxc-pass {{}} */
+int half_btf(int w,int bit) { return (w + (1<<bit)) >> bit; } /* expected-warning {{ambiguous type for bit shift; use a type suffix on literal values, like 'L' or 'U', or a cast}} fxc-pass {{}} */

+ 4 - 4
tools/clang/test/HLSL/matrix-syntax-exact-precision.hlsl

@@ -61,10 +61,10 @@ void matrix_out_of_bounds() {
 
 void matrix_unsigned() {
    unsigned int4x2 intMatrix;
-   unsigned min16int4x3 min16Matrix; /* expected-warning {{min16int is promoted to int16_t}} fxc-error {{X3085: unsigned can not be used with type}} */
+   unsigned min16int4x3 min16Matrix; /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-error {{X3085: unsigned can not be used with type}} */
    unsigned int64_t3x3 int64Matrix;  /* fxc-error {{X3000: syntax error: unexpected token 'int64_t3x3'}} */
    unsigned uint3x4 uintMatrix;      /* fxc-error {{X3085: unsigned can not be used with type}} */
-   unsigned min16uint4x1 min16uintMatrix;                   /* expected-warning {{min16uint is promoted to uint16_t}} fxc-error {{X3085: unsigned can not be used with type}} */
+   unsigned min16uint4x1 min16uintMatrix;                   /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-error {{X3085: unsigned can not be used with type}} */
    unsigned uint64_t2x2 int64uintMatrix;                    /* fxc-error {{X3000: syntax error: unexpected token 'uint64_t2x2'}} */
    unsigned dword3x2 dwordmector; /* fxc-error {{X3000: syntax error: unexpected token 'dword3x2'}} */
 
@@ -72,8 +72,8 @@ void matrix_unsigned() {
    unsigned bool3x4 boolMatirx;   /* expected-error {{'bool' cannot be signed or unsigned}} fxc-error {{X3085: unsigned can not be used with type}} */
    unsigned half4x1 halfMatrix;   /* expected-error {{'half' cannot be signed or unsigned}} fxc-error {{X3085: unsigned can not be used with type}} */
    unsigned double1x2 doubleMatrix;                           /* expected-error {{'double' cannot be signed or unsigned}} fxc-error {{X3085: unsigned can not be used with type}} */
-   unsigned min12int2x3 min12intMatrix;                       /* expected-error {{'min12int' cannot be signed or unsigned}} expected-warning {{min12int is promoted to int16_t}} fxc-error {{X3085: unsigned can not be used with type}} */
-   unsigned min16float3x4 min16floatMatrix;                   /* expected-error {{'min16float' cannot be signed or unsigned}} expected-warning {{min16float is promoted to float16_t}} fxc-error {{X3085: unsigned can not be used with type}} */
+   unsigned min12int2x3 min12intMatrix;                       /* expected-error {{'min12int' cannot be signed or unsigned}} expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-error {{X3085: unsigned can not be used with type}} */
+   unsigned min16float3x4 min16floatMatrix;                   /* expected-error {{'min16float' cannot be signed or unsigned}} expected-warning {{'min16float' is promoted to 'half'}} fxc-error {{X3085: unsigned can not be used with type}} */
 
    unsigned int16_t2x3 uint16_tMatrix1;                       /* fxc-error {{X3000: syntax error: unexpected token 'int16_t2x3'}} */
    unsigned int32_t4x2 uint32_tMatrix1;                       /* fxc-error {{X3000: syntax error: unexpected token 'int32_t4x2'}} */

+ 2 - 2
tools/clang/test/HLSL/matrix-syntax.hlsl

@@ -72,7 +72,7 @@ void matrix_unsigned() {
    unsigned bool3x4 boolvector;   /* expected-error {{'bool' cannot be signed or unsigned}} fxc-error {{X3085: unsigned can not be used with type}} */
    unsigned half4x1 halfvector;   /* expected-error {{'half' cannot be signed or unsigned}} fxc-error {{X3085: unsigned can not be used with type}} */
    unsigned double1x2 doublevector;                           /* expected-error {{'double' cannot be signed or unsigned}} fxc-error {{X3085: unsigned can not be used with type}} */
-   unsigned min12int2x3 min12intvector;                       /* expected-error {{'min12int' cannot be signed or unsigned}} expected-warning {{min12int is promoted to min16int}} fxc-error {{X3085: unsigned can not be used with type}} */
+   unsigned min12int2x3 min12intvector;                       /* expected-error {{'min12int' cannot be signed or unsigned}} expected-warning {{'min12int' is promoted to 'min16int'}} fxc-error {{X3085: unsigned can not be used with type}} */
    unsigned min16float3x4 min16floatvector;                   /* expected-error {{'min16float' cannot be signed or unsigned}} fxc-error {{X3085: unsigned can not be used with type}} */
 
 }
@@ -157,4 +157,4 @@ void main() {
     myConstMatrix[0][0] = 3;                                /* expected-error {{cannot assign to variable 'myConstMatrix' with const-qualified type 'const matrix<float, 4, 4>'}} fxc-error {{X3025: l-value specifies const object}} */
     myConstMatrix[3] = float4(1,2,3,4);                     /* expected-error {{cannot assign to variable 'myConstMatrix' with const-qualified type 'const matrix<float, 4, 4>'}} fxc-error {{X3025: l-value specifies const object}} */
 
-}
+}

+ 4 - 4
tools/clang/test/HLSL/mintypes-promotion-warnings.hlsl

@@ -3,7 +3,7 @@
 // Verify minfloat/minint promotion warnings for shader input/outputs
 
 void main(
-  min10float in_f10, // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  min12int in_i12, // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
-  out min10float out_f10, // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  out min12int out_i12) {} // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+  min10float in_f10, // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+  min12int in_i12, // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}
+  out min10float out_f10, // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+  out min12int out_i12) {} // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}

+ 23 - 23
tools/clang/test/HLSL/more-operators.hlsl

@@ -156,16 +156,16 @@ float4 plain(float4 param4 /* : FOO */) /*: FOO */{
     float float_l = 1;
     double double_l = 1;
     min16float min16float_l = 1;
-    min10float min10float_l = 1;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+    min10float min10float_l = 1;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
     min16int min16int_l = 1;
-    min12int min12int_l = 1;        // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+    min12int min12int_l = 1;        // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}
     min16uint min16uint_l = 1;
     SamplerState SamplerState_l = g_SamplerState;
     bool1 bool1_l = 0;
     bool2 bool2_l = 0;
     float3 float3_l = 0;
     double4 double4_l = 0;
-    min10float1x2 min10float1x2_l = 0;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+    min10float1x2 min10float1x2_l = 0;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
     uint2x3 uint2x3_l = 0;
     min16uint4x4 min16uint4x4_l = 0;
     int3x2 int3x2_l = 0;
@@ -190,9 +190,9 @@ float4 plain(float4 param4 /* : FOO */) /*: FOO */{
     _Static_assert(std::is_same<float, __decltype(-float_l)>::value, "");
     _Static_assert(std::is_same<double, __decltype(-double_l)>::value, "");
     _Static_assert(std::is_same<min16float, __decltype(-min16float_l)>::value, "");
-    _Static_assert(std::is_same<min10float, __decltype(-min10float_l)>::value, "");  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+    _Static_assert(std::is_same<min10float, __decltype(-min10float_l)>::value, "");  // fxc-pass {{}}
     _Static_assert(std::is_same<min16int, __decltype(-min16int_l)>::value, "");
-    _Static_assert(std::is_same<min12int, __decltype(-min12int_l)>::value, "");    // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+    _Static_assert(std::is_same<min12int, __decltype(-min12int_l)>::value, "");    // fxc-pass {{}}
     _Static_assert(std::is_same<min16uint, __decltype(-min16uint_l)>::value, "");
     (-SamplerState_l); // expected-error {{scalar, vector, or matrix expected}} fxc-error {{X3022: scalar, vector, or matrix expected}}
     (-f3_s_l); // expected-error {{scalar, vector, or matrix expected}} fxc-error {{X3022: scalar, vector, or matrix expected}}
@@ -201,7 +201,7 @@ float4 plain(float4 param4 /* : FOO */) /*: FOO */{
     _Static_assert(std::is_same<int2, __decltype(-bool2_l)>::value, "");
     _Static_assert(std::is_same<float3, __decltype(-float3_l)>::value, "");
     _Static_assert(std::is_same<double4, __decltype(-double4_l)>::value, "");
-    _Static_assert(std::is_same<min10float1x2, __decltype(-min10float1x2_l)>::value, "");      /* expected-warning {{min10float is promoted to min16float}} fxc-pass {{}} */
+    _Static_assert(std::is_same<min10float1x2, __decltype(-min10float1x2_l)>::value, "");      /* fxc-pass {{}} */
     _Static_assert(std::is_same<uint2x3, __decltype(-uint2x3_l)>::value, "");
     _Static_assert(std::is_same<min16uint4x4, __decltype(-min16uint4x4_l)>::value, "");
     _Static_assert(std::is_same<int3x2, __decltype(-int3x2_l)>::value, "");
@@ -212,9 +212,9 @@ float4 plain(float4 param4 /* : FOO */) /*: FOO */{
     _Static_assert(std::is_same<float, __decltype(+float_l)>::value, "");
     _Static_assert(std::is_same<double, __decltype(+double_l)>::value, "");
     _Static_assert(std::is_same<min16float, __decltype(+min16float_l)>::value, "");
-    _Static_assert(std::is_same<min10float, __decltype(+min10float_l)>::value, "");  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+    _Static_assert(std::is_same<min10float, __decltype(+min10float_l)>::value, "");  // fxc-pass {{}}
     _Static_assert(std::is_same<min16int, __decltype(+min16int_l)>::value, "");
-    _Static_assert(std::is_same<min12int, __decltype(+min12int_l)>::value, "");    // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+    _Static_assert(std::is_same<min12int, __decltype(+min12int_l)>::value, "");    // fxc-pass {{}}
     _Static_assert(std::is_same<min16uint, __decltype(+min16uint_l)>::value, "");
     (+SamplerState_l); // expected-error {{scalar, vector, or matrix expected}} fxc-error {{X3022: scalar, vector, or matrix expected}}
     (+f3_s_l); // expected-error {{scalar, vector, or matrix expected}} fxc-error {{X3022: scalar, vector, or matrix expected}}
@@ -223,7 +223,7 @@ float4 plain(float4 param4 /* : FOO */) /*: FOO */{
     _Static_assert(std::is_same<int2, __decltype(+bool2_l)>::value, "");
     _Static_assert(std::is_same<float3, __decltype(+float3_l)>::value, "");
     _Static_assert(std::is_same<double4, __decltype(+double4_l)>::value, "");
-    _Static_assert(std::is_same<min10float1x2, __decltype(+min10float1x2_l)>::value, "");      /* expected-warning {{min10float is promoted to min16float}} fxc-pass {{}} */
+    _Static_assert(std::is_same<min10float1x2, __decltype(+min10float1x2_l)>::value, "");      /* fxc-pass {{}} */
     _Static_assert(std::is_same<uint2x3, __decltype(+uint2x3_l)>::value, "");
     _Static_assert(std::is_same<min16uint4x4, __decltype(+min16uint4x4_l)>::value, "");
     _Static_assert(std::is_same<int3x2, __decltype(+int3x2_l)>::value, "");
@@ -236,7 +236,7 @@ float4 plain(float4 param4 /* : FOO */) /*: FOO */{
     (~min16float_l); // expected-error {{int or unsigned int type required}} fxc-error {{X3082: int or unsigned int type required}}
     (~min10float_l); // expected-error {{int or unsigned int type required}} fxc-error {{X3082: int or unsigned int type required}}
     _Static_assert(std::is_same<min16int, __decltype(~min16int_l)>::value, "");
-    _Static_assert(std::is_same<min12int, __decltype(~min12int_l)>::value, "");    // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+    _Static_assert(std::is_same<min12int, __decltype(~min12int_l)>::value, "");    // fxc-pass {{}}
     _Static_assert(std::is_same<min16uint, __decltype(~min16uint_l)>::value, "");
     (~SamplerState_l); // expected-error {{scalar, vector, or matrix expected}} fxc-error {{X3082: int or unsigned int type required}}
     (~f3_s_l); // expected-error {{scalar, vector, or matrix expected}} fxc-error {{X3082: int or unsigned int type required}}
@@ -287,12 +287,12 @@ float4 plain(float4 param4 /* : FOO */) /*: FOO */{
     _Static_assert(std::is_same<double, __decltype(double_l--)>::value, "");
     _Static_assert(std::is_same<min16float&, __decltype(--min16float_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
     _Static_assert(std::is_same<min16float, __decltype(min16float_l--)>::value, "");
-    _Static_assert(std::is_same<min10float&, __decltype(--min10float_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-    _Static_assert(std::is_same<min10float, __decltype(min10float_l--)>::value, "");  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+    _Static_assert(std::is_same<min10float&, __decltype(--min10float_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
+    _Static_assert(std::is_same<min10float, __decltype(min10float_l--)>::value, "");  // fxc-pass {{}}
     _Static_assert(std::is_same<min16int&, __decltype(--min16int_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
     _Static_assert(std::is_same<min16int, __decltype(min16int_l--)>::value, "");
-    _Static_assert(std::is_same<min12int&, __decltype(--min12int_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
-    _Static_assert(std::is_same<min12int, __decltype(min12int_l--)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+    _Static_assert(std::is_same<min12int&, __decltype(--min12int_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
+    _Static_assert(std::is_same<min12int, __decltype(min12int_l--)>::value, "");  // fxc-pass {{}}
     _Static_assert(std::is_same<min16uint&, __decltype(--min16uint_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
     _Static_assert(std::is_same<min16uint, __decltype(min16uint_l--)>::value, "");
     (--SamplerState_l); // expected-error {{scalar, vector, or matrix expected}} fxc-pass {{}}
@@ -309,8 +309,8 @@ float4 plain(float4 param4 /* : FOO */) /*: FOO */{
     _Static_assert(std::is_same<float3, __decltype(float3_l--)>::value, "");
     _Static_assert(std::is_same<double4&, __decltype(--double4_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
     _Static_assert(std::is_same<double4, __decltype(double4_l--)>::value, "");
-    _Static_assert(std::is_same<min10float1x2&, __decltype(--min10float1x2_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-    _Static_assert(std::is_same<min10float1x2, __decltype(min10float1x2_l--)>::value, "");      /* expected-warning {{min10float is promoted to min16float}} fxc-pass {{}} */
+    _Static_assert(std::is_same<min10float1x2&, __decltype(--min10float1x2_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
+    _Static_assert(std::is_same<min10float1x2, __decltype(min10float1x2_l--)>::value, "");      /* fxc-pass {{}} */
     _Static_assert(std::is_same<uint2x3&, __decltype(--uint2x3_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
     _Static_assert(std::is_same<uint2x3, __decltype(uint2x3_l--)>::value, "");
     _Static_assert(std::is_same<min16uint4x4&, __decltype(--min16uint4x4_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
@@ -331,12 +331,12 @@ float4 plain(float4 param4 /* : FOO */) /*: FOO */{
     _Static_assert(std::is_same<double, __decltype(double_l++)>::value, "");
     _Static_assert(std::is_same<min16float&, __decltype(++min16float_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
     _Static_assert(std::is_same<min16float, __decltype(min16float_l++)>::value, "");
-    _Static_assert(std::is_same<min10float&, __decltype(++min10float_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-    _Static_assert(std::is_same<min10float, __decltype(min10float_l++)>::value, "");  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+    _Static_assert(std::is_same<min10float&, __decltype(++min10float_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
+    _Static_assert(std::is_same<min10float, __decltype(min10float_l++)>::value, "");  // fxc-pass {{}}
     _Static_assert(std::is_same<min16int&, __decltype(++min16int_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
     _Static_assert(std::is_same<min16int, __decltype(min16int_l++)>::value, "");
-    _Static_assert(std::is_same<min12int&, __decltype(++min12int_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
-    _Static_assert(std::is_same<min12int, __decltype(min12int_l++)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+    _Static_assert(std::is_same<min12int&, __decltype(++min12int_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
+    _Static_assert(std::is_same<min12int, __decltype(min12int_l++)>::value, "");  // fxc-pass {{}}
     _Static_assert(std::is_same<min16uint&, __decltype(++min16uint_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
     _Static_assert(std::is_same<min16uint, __decltype(min16uint_l++)>::value, "");
     (++SamplerState_l); // expected-error {{scalar, vector, or matrix expected}} fxc-pass {{}}
@@ -353,8 +353,8 @@ float4 plain(float4 param4 /* : FOO */) /*: FOO */{
     _Static_assert(std::is_same<float3, __decltype(float3_l++)>::value, "");
     _Static_assert(std::is_same<double4&, __decltype(++double4_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
     _Static_assert(std::is_same<double4, __decltype(double4_l++)>::value, "");
-    _Static_assert(std::is_same<min10float1x2&, __decltype(++min10float1x2_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-    _Static_assert(std::is_same<min10float1x2, __decltype(min10float1x2_l++)>::value, "");  /* expected-warning {{min10float is promoted to min16float}} fxc-pass {{}} */
+    _Static_assert(std::is_same<min10float1x2&, __decltype(++min10float1x2_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
+    _Static_assert(std::is_same<min10float1x2, __decltype(min10float1x2_l++)>::value, "");  /* fxc-pass {{}} */
     _Static_assert(std::is_same<uint2x3&, __decltype(++uint2x3_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
     _Static_assert(std::is_same<uint2x3, __decltype(uint2x3_l++)>::value, "");
     _Static_assert(std::is_same<min16uint4x4&, __decltype(++min16uint4x4_l)>::value, ""); // expected-error {{pointers are unsupported in HLSL}} fxc-pass {{}}
@@ -494,4 +494,4 @@ float3 fn(float a, float b)
 float4 main2(float2 coord : TEXCOORD) : SV_Target
 {
   return DoSample(tex12, fn(coord.x, coord.y).xy);
-}
+}

+ 1 - 1
tools/clang/test/HLSL/rewriter/correct_rewrites/matrix-syntax_gold.hlsl

@@ -1,5 +1,5 @@
 // Rewrite unchanged result:
-matrix m;
+const matrix<float, 4, 4> m;
 void abs_without_using_result() {
   matrix<float, 4, 4> mymatrix;
   abs(mymatrix);

+ 183 - 183
tools/clang/test/HLSL/scalar-assignments-exact-precision.hlsl

@@ -12,7 +12,7 @@ snorm bool sb;         // expected-error {{snorm and unorm qualifier can only be
 
 // Used to generate this undesirable error:
 // cannot initialize a variable of type 'min16float' (aka 'half') with an lvalue of type 'const char [4]'
-min16float foobar = "foo"; // expected-error {{cannot initialize a variable of type 'min16float' with an lvalue of type 'literal string'}} expected-warning {{min16float is promoted to float16_t}} fxc-error {{X3017: cannot implicitly convert from 'const string' to 'min16float'}}
+min16float foobar = "foo"; // expected-error {{cannot initialize a variable of type 'min16float' with an lvalue of type 'literal string'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-error {{X3017: cannot implicitly convert from 'const string' to 'min16float'}}
 
 /*
 (let (
@@ -37,11 +37,11 @@ bool left3; dword right3; left3 = right3;
 bool left4; half right4; left4 = right4;
 bool left5; float right5; left5 = right5;
 bool left6; double right6; left6 = right6;
-bool left7; min16float right7; left7 = right7;              /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-bool left8; min10float right8; left8 = right8;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-bool left9; min16int right9; left9 = right9;    /* expected-warning {{min16int is promoted to int16_t}} fxc-pass {{}} */
-bool left10; min12int right10; left10 = right10;  // expected-warning {{min12int is promoted to int16_t}} fxc-pass {{}}
-bool left11; min16uint right11; left11 = right11; /* expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}} */
+bool left7; min16float right7; left7 = right7;              /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+bool left8; min10float right8; left8 = right8;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+bool left9; min16int right9; left9 = right9;    /* expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-pass {{}} */
+bool left10; min12int right10; left10 = right10;  // expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-pass {{}}
+bool left11; min16uint right11; left11 = right11; /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}} */
 int left12; bool right12; left12 = right12;
 int left13; int right13; left13 = right13;
 int left14; uint right14; left14 = right14;
@@ -49,11 +49,11 @@ int left15; dword right15; left15 = right15;
 int left16; half right16; left16 = right16;
 int left17; float right17; left17 = right17;
 int left18; double right18; left18 = right18; // expected-warning {{conversion from larger type 'double' to smaller type 'int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-int left19; min16float right19; left19 = right19;           /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-int left20; min10float right20; left20 = right20;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-int left21; min16int right21; left21 = right21;    /* expected-warning {{min16int is promoted to int16_t}} fxc-pass {{}} */
-int left22; min12int right22; left22 = right22;  // expected-warning {{min12int is promoted to int16_t}} fxc-pass {{}}
-int left23; min16uint right23; left23 = right23; /* expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}} */
+int left19; min16float right19; left19 = right19;           /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+int left20; min10float right20; left20 = right20;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+int left21; min16int right21; left21 = right21;    /* expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-pass {{}} */
+int left22; min12int right22; left22 = right22;  // expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-pass {{}}
+int left23; min16uint right23; left23 = right23; /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}} */
 uint left24; bool right24; left24 = right24;
 uint left25; int right25; left25 = right25;
 uint left26; uint right26; left26 = right26;
@@ -61,11 +61,11 @@ uint left27; dword right27; left27 = right27;
 uint left28; half right28; left28 = right28;
 uint left29; float right29; left29 = right29;
 uint left30; double right30; left30 = right30; // expected-warning {{conversion from larger type 'double' to smaller type 'uint', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-uint left31; min16float right31; left31 = right31;          /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-uint left32; min10float right32; left32 = right32;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-uint left33; min16int right33; left33 = right33;    /* expected-warning {{min16int is promoted to int16_t}} fxc-pass {{}} */
-uint left34; min12int right34; left34 = right34;  // expected-warning {{min12int is promoted to int16_t}} fxc-pass {{}}
-uint left35; min16uint right35; left35 = right35; /* expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}} */
+uint left31; min16float right31; left31 = right31;          /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+uint left32; min10float right32; left32 = right32;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+uint left33; min16int right33; left33 = right33;    /* expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-pass {{}} */
+uint left34; min12int right34; left34 = right34;  // expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-pass {{}}
+uint left35; min16uint right35; left35 = right35; /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}} */
 dword left36; bool right36; left36 = right36;
 dword left37; int right37; left37 = right37;
 dword left38; uint right38; left38 = right38;
@@ -73,11 +73,11 @@ dword left39; dword right39; left39 = right39;
 dword left40; half right40; left40 = right40;
 dword left41; float right41; left41 = right41;
 dword left42; double right42; left42 = right42; // expected-warning {{conversion from larger type 'double' to smaller type 'dword', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-dword left43; min16float right43; left43 = right43;         /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-dword left44; min10float right44; left44 = right44;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-dword left45; min16int right45; left45 = right45;    /* expected-warning {{min16int is promoted to int16_t}} fxc-pass {{}} */
-dword left46; min12int right46; left46 = right46;  // expected-warning {{min12int is promoted to int16_t}} fxc-pass {{}}
-dword left47; min16uint right47; left47 = right47; /* expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}} */
+dword left43; min16float right43; left43 = right43;         /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+dword left44; min10float right44; left44 = right44;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+dword left45; min16int right45; left45 = right45;    /* expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-pass {{}} */
+dword left46; min12int right46; left46 = right46;  // expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-pass {{}}
+dword left47; min16uint right47; left47 = right47; /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}} */
 half left48; bool right48; left48 = right48;
 half left49; int right49; left49 = right49;        /* expected-warning {{conversion from larger type 'int' to smaller type 'half', possible loss of data}} fxc-pass {{}} */
 half left50; uint right50; left50 = right50;       /* expected-warning {{conversion from larger type 'uint' to smaller type 'half', possible loss of data}} fxc-pass {{}} */
@@ -85,11 +85,11 @@ half left51; dword right51; left51 = right51;      /* expected-warning {{convers
 half left52; half right52; left52 = right52;
 half left53; float right53; left53 = right53;      /* expected-warning {{conversion from larger type 'float' to smaller type 'half', possible loss of data}} fxc-pass {{}} */
 half left54; double right54; left54 = right54; // expected-warning {{conversion from larger type 'double' to smaller type 'half', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-half left55; min16float right55; left55 = right55;          /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-half left56; min10float right56; left56 = right56;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-half left57; min16int right57; left57 = right57;    /* expected-warning {{min16int is promoted to int16_t}} fxc-pass {{}} */
-half left58; min12int right58; left58 = right58;  // expected-warning {{min12int is promoted to int16_t}} fxc-pass {{}}
-half left59; min16uint right59; left59 = right59; /* expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}} */
+half left55; min16float right55; left55 = right55;          /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+half left56; min10float right56; left56 = right56;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+half left57; min16int right57; left57 = right57;    /* expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-pass {{}} */
+half left58; min12int right58; left58 = right58;  // expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-pass {{}}
+half left59; min16uint right59; left59 = right59; /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}} */
 float left60; bool right60; left60 = right60;
 float left61; int right61; left61 = right61;
 float left62; uint right62; left62 = right62;
@@ -97,11 +97,11 @@ float left63; dword right63; left63 = right63;
 float left64; half right64; left64 = right64;
 float left65; float right65; left65 = right65;
 float left66; double right66; left66 = right66; // expected-warning {{conversion from larger type 'double' to smaller type 'float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-float left67; min16float right67; left67 = right67;         /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-float left68; min10float right68; left68 = right68;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-float left69; min16int right69; left69 = right69;    /* expected-warning {{min16int is promoted to int16_t}} fxc-pass {{}} */
-float left70; min12int right70; left70 = right70;  // expected-warning {{min12int is promoted to int16_t}} fxc-pass {{}}
-float left71; min16uint right71; left71 = right71; /* expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}} */
+float left67; min16float right67; left67 = right67;         /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+float left68; min10float right68; left68 = right68;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+float left69; min16int right69; left69 = right69;    /* expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-pass {{}} */
+float left70; min12int right70; left70 = right70;  // expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-pass {{}}
+float left71; min16uint right71; left71 = right71; /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}} */
 double left72; bool right72; left72 = right72;
 double left73; int right73; left73 = right73;
 double left74; uint right74; left74 = right74;
@@ -109,71 +109,71 @@ double left75; dword right75; left75 = right75;
 double left76; half right76; left76 = right76;
 double left77; float right77; left77 = right77;
 double left78; double right78; left78 = right78;
-double left79; min16float right79; left79 = right79;        /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-double left80; min10float right80; left80 = right80;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-double left81; min16int right81; left81 = right81;    /* expected-warning {{min16int is promoted to int16_t}} fxc-pass {{}} */
-double left82; min12int right82; left82 = right82;  // expected-warning {{min12int is promoted to int16_t}} fxc-pass {{}}
-double left83; min16uint right83; left83 = right83; /* expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}} */
-min16float left84; bool right84; left84 = right84;  /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-min16float left85; int right85; left85 = right85; // expected-warning {{conversion from larger type 'int' to smaller type 'min16float', possible loss of data}} expected-warning {{min16float is promoted to float16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16float left86; uint right86; left86 = right86; // expected-warning {{conversion from larger type 'uint' to smaller type 'min16float', possible loss of data}} expected-warning {{min16float is promoted to float16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16float left87; dword right87; left87 = right87; // expected-warning {{conversion from larger type 'dword' to smaller type 'min16float', possible loss of data}} expected-warning {{min16float is promoted to float16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16float left88; half right88; left88 = right88; // expected-warning {{min16float is promoted to float16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16float left89; float right89; left89 = right89; // expected-warning {{conversion from larger type 'float' to smaller type 'min16float', possible loss of data}} expected-warning {{min16float is promoted to float16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16float left90; double right90; left90 = right90; // expected-warning {{conversion from larger type 'double' to smaller type 'min16float', possible loss of data}} expected-warning {{min16float is promoted to float16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16float left91; min16float right91; left91 = right91;    /* expected-warning {{min16float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-min16float left92; min10float right92; left92 = right92;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}}
-min16float left93; min16int right93; left93 = right93;    /* expected-warning {{min16float is promoted to float16_t}} expected-warning {{min16int is promoted to int16_t}} fxc-pass {{}} */
-min16float left94; min12int right94; left94 = right94;  // expected-warning {{min12int is promoted to int16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}}
-min16float left95; min16uint right95; left95 = right95; /* expected-warning {{min16float is promoted to float16_t}} expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}} */
-min10float left96; bool right96; left96 = right96;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-min10float left97; int right97; left97 = right97; // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to float16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left98; uint right98; left98 = right98; // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to float16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left99; dword right99; left99 = right99; // expected-warning {{conversion from larger type 'dword' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to float16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left100; half right100; left100 = right100; // expected-warning {{conversion from larger type 'half' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to float16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left101; float right101; left101 = right101; // expected-warning {{conversion from larger type 'float' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to float16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left102; double right102; left102 = right102; // expected-warning {{conversion from larger type 'double' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to float16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left103; min16float right103; left103 = right103; // expected-warning {{conversion from larger type 'min16float' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left104; min10float right104; left104 = right104;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}} //
-min10float left105; min16int right105; left105 = right105; // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to float16_t}} expected-warning {{min16int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left106; min12int right106; left106 = right106; // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to float16_t}} expected-warning {{min12int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left107; min16uint right107; left107 = right107; // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to float16_t}} expected-warning {{min16uint is promoted to uint16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min16int left108; bool right108; left108 = right108;        /* expected-warning {{min16int is promoted to int16_t}} fxc-pass {{}} */
-min16int left109; int right109; left109 = right109; // expected-warning {{conversion from larger type 'int' to smaller type 'min16int', possible loss of data}} expected-warning {{min16int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16int left110; uint right110; left110 = right110; // expected-warning {{conversion from larger type 'uint' to smaller type 'min16int', possible loss of data}} expected-warning {{min16int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16int left111; dword right111; left111 = right111; // expected-warning {{conversion from larger type 'dword' to smaller type 'min16int', possible loss of data}} expected-warning {{min16int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16int left112; half right112; left112 = right112; // expected-warning {{min16int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16int left113; float right113; left113 = right113; // expected-warning {{conversion from larger type 'float' to smaller type 'min16int', possible loss of data}} expected-warning {{min16int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16int left114; double right114; left114 = right114; // expected-warning {{conversion from larger type 'double' to smaller type 'min16int', possible loss of data}} expected-warning {{min16int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16int left115; min16float right115; left115 = right115;    /* expected-warning {{min16float is promoted to float16_t}} expected-warning {{min16int is promoted to int16_t}} fxc-pass {{}} */
-min16int left116; min10float right116; left116 = right116;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min16int is promoted to int16_t}} fxc-pass {{}}
-min16int left117; min16int right117; left117 = right117;    /* expected-warning {{min16int is promoted to int16_t}} expected-warning {{min16int is promoted to int16_t}} fxc-pass {{}} */
-min16int left118; min12int right118; left118 = right118;  // expected-warning {{min12int is promoted to int16_t}} expected-warning {{min16int is promoted to int16_t}} fxc-pass {{}}
-min16int left119; min16uint right119; left119 = right119; /* expected-warning {{min16int is promoted to int16_t}} expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}} */
-min12int left120; bool right120; left120 = right120;  // expected-warning {{min12int is promoted to int16_t}} fxc-pass {{}}
-min12int left121; int right121; left121 = right121; // expected-warning {{conversion from larger type 'int' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min12int left122; uint right122; left122 = right122; // expected-warning {{conversion from larger type 'uint' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min12int left123; dword right123; left123 = right123; // expected-warning {{conversion from larger type 'dword' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min12int left124; half right124; left124 = right124; // expected-warning {{conversion from larger type 'half' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min12int left125; float right125; left125 = right125; // expected-warning {{conversion from larger type 'float' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min12int left126; double right126; left126 = right126; // expected-warning {{conversion from larger type 'double' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min12int left127; min16float right127; left127 = right127; // expected-warning {{conversion from larger type 'min16float' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to int16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min12int left128; min10float right128; left128 = right128;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min12int is promoted to int16_t}} fxc-pass {{}} //
-min12int left129; min16int right129; left129 = right129; // expected-warning {{conversion from larger type 'min16int' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to int16_t}} expected-warning {{min16int is promoted to int16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min12int left130; min12int right130; left130 = right130;  // expected-warning {{min12int is promoted to int16_t}} expected-warning {{min12int is promoted to int16_t}} fxc-pass {{}} //
-min12int left131; min16uint right131; left131 = right131; // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to int16_t}} expected-warning {{min16uint is promoted to uint16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min16uint left132; bool right132; left132 = right132;     /* expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}} */
-min16uint left133; int right133; left133 = right133; // expected-warning {{conversion from larger type 'int' to smaller type 'min16uint', possible loss of data}} expected-warning {{min16uint is promoted to uint16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16uint left134; uint right134; left134 = right134; // expected-warning {{conversion from larger type 'uint' to smaller type 'min16uint', possible loss of data}} expected-warning {{min16uint is promoted to uint16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16uint left135; dword right135; left135 = right135; // expected-warning {{conversion from larger type 'dword' to smaller type 'min16uint', possible loss of data}} expected-warning {{min16uint is promoted to uint16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16uint left136; half right136; left136 = right136; // expected-warning {{min16uint is promoted to uint16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16uint left137; float right137; left137 = right137; // expected-warning {{conversion from larger type 'float' to smaller type 'min16uint', possible loss of data}} expected-warning {{min16uint is promoted to uint16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16uint left138; double right138; left138 = right138; // expected-warning {{conversion from larger type 'double' to smaller type 'min16uint', possible loss of data}} expected-warning {{min16uint is promoted to uint16_t}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min16uint left139; min16float right139; left139 = right139;    /* expected-warning {{min16float is promoted to float16_t}} expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}} */
-min16uint left140; min10float right140; left140 = right140;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}}
-min16uint left141; min16int right141; left141 = right141;    /* expected-warning {{min16int is promoted to int16_t}} expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}} */
-min16uint left142; min12int right142; left142 = right142;  // expected-warning {{min12int is promoted to int16_t}} expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}}
-min16uint left143; min16uint right143; left143 = right143; /* expected-warning {{min16uint is promoted to uint16_t}} expected-warning {{min16uint is promoted to uint16_t}} fxc-pass {{}} */
+double left79; min16float right79; left79 = right79;        /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+double left80; min10float right80; left80 = right80;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+double left81; min16int right81; left81 = right81;    /* expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-pass {{}} */
+double left82; min12int right82; left82 = right82;  // expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-pass {{}}
+double left83; min16uint right83; left83 = right83; /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}} */
+min16float left84; bool right84; left84 = right84;  /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+min16float left85; int right85; left85 = right85; // expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{conversion from larger type 'int' to smaller type 'min16float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16float left86; uint right86; left86 = right86; // expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{conversion from larger type 'uint' to smaller type 'min16float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16float left87; dword right87; left87 = right87; // expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{conversion from larger type 'dword' to smaller type 'min16float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16float left88; half right88; left88 = right88; // expected-warning {{'min16float' is promoted to 'half'}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16float left89; float right89; left89 = right89; // expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{conversion from larger type 'float' to smaller type 'min16float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16float left90; double right90; left90 = right90; // expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{conversion from larger type 'double' to smaller type 'min16float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16float left91; min16float right91; left91 = right91;    /* expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+min16float left92; min10float right92; left92 = right92;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}}
+min16float left93; min16int right93; left93 = right93;    /* expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-pass {{}} */
+min16float left94; min12int right94; left94 = right94;  // expected-warning {{'min12int' is promoted to 'int16_t'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}}
+min16float left95; min16uint right95; left95 = right95; /* expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}} */
+min10float left96; bool right96; left96 = right96;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+min10float left97; int right97; left97 = right97; // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left98; uint right98; left98 = right98; // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left99; dword right99; left99 = right99; // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{conversion from larger type 'dword' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left100; half right100; left100 = right100; // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{conversion from larger type 'half' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left101; float right101; left101 = right101; // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{conversion from larger type 'float' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left102; double right102; left102 = right102; // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{conversion from larger type 'double' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left103; min16float right103; left103 = right103; // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{conversion from larger type 'min16float' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left104; min10float right104; left104 = right104;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}} //
+min10float left105; min16int right105; left105 = right105; // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min16int' is promoted to 'int16_t'}} expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left106; min12int right106; left106 = right106; // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min12int' is promoted to 'int16_t'}} expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left107; min16uint right107; left107 = right107; // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min16uint' is promoted to 'uint16_t'}} expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min16int left108; bool right108; left108 = right108;        /* expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-pass {{}} */
+min16int left109; int right109; left109 = right109; // expected-warning {{'min16int' is promoted to 'int16_t'}} expected-warning {{conversion from larger type 'int' to smaller type 'min16int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16int left110; uint right110; left110 = right110; // expected-warning {{'min16int' is promoted to 'int16_t'}} expected-warning {{conversion from larger type 'uint' to smaller type 'min16int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16int left111; dword right111; left111 = right111; // expected-warning {{'min16int' is promoted to 'int16_t'}} expected-warning {{conversion from larger type 'dword' to smaller type 'min16int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16int left112; half right112; left112 = right112; // expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16int left113; float right113; left113 = right113; // expected-warning {{'min16int' is promoted to 'int16_t'}} expected-warning {{conversion from larger type 'float' to smaller type 'min16int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16int left114; double right114; left114 = right114; // expected-warning {{'min16int' is promoted to 'int16_t'}} expected-warning {{conversion from larger type 'double' to smaller type 'min16int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16int left115; min16float right115; left115 = right115;    /* expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-pass {{}} */
+min16int left116; min10float right116; left116 = right116;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-pass {{}}
+min16int left117; min16int right117; left117 = right117;    /* expected-warning {{'min16int' is promoted to 'int16_t'}} expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-pass {{}} */
+min16int left118; min12int right118; left118 = right118;  // expected-warning {{'min12int' is promoted to 'int16_t'}} expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-pass {{}}
+min16int left119; min16uint right119; left119 = right119; /* expected-warning {{'min16int' is promoted to 'int16_t'}} expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}} */
+min12int left120; bool right120; left120 = right120;  // expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-pass {{}}
+min12int left121; int right121; left121 = right121; // expected-warning {{'min12int' is promoted to 'int16_t'}} expected-warning {{conversion from larger type 'int' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min12int left122; uint right122; left122 = right122; // expected-warning {{'min12int' is promoted to 'int16_t'}} expected-warning {{conversion from larger type 'uint' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min12int left123; dword right123; left123 = right123; // expected-warning {{'min12int' is promoted to 'int16_t'}} expected-warning {{conversion from larger type 'dword' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min12int left124; half right124; left124 = right124; // expected-warning {{'min12int' is promoted to 'int16_t'}} expected-warning {{conversion from larger type 'half' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min12int left125; float right125; left125 = right125; // expected-warning {{'min12int' is promoted to 'int16_t'}} expected-warning {{conversion from larger type 'float' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min12int left126; double right126; left126 = right126; // expected-warning {{'min12int' is promoted to 'int16_t'}} expected-warning {{conversion from larger type 'double' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min12int left127; min16float right127; left127 = right127; // expected-warning {{'min12int' is promoted to 'int16_t'}} expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{conversion from larger type 'min16float' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min12int left128; min10float right128; left128 = right128;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-pass {{}} //
+min12int left129; min16int right129; left129 = right129; // expected-warning {{'min12int' is promoted to 'int16_t'}} expected-warning {{'min16int' is promoted to 'int16_t'}} expected-warning {{conversion from larger type 'min16int' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min12int left130; min12int right130; left130 = right130;  // expected-warning {{'min12int' is promoted to 'int16_t'}} expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-pass {{}} //
+min12int left131; min16uint right131; left131 = right131; // expected-warning {{'min12int' is promoted to 'int16_t'}} expected-warning {{'min16uint' is promoted to 'uint16_t'}} expected-warning {{conversion from larger type 'min16uint' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min16uint left132; bool right132; left132 = right132;     /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}} */
+min16uint left133; int right133; left133 = right133; // expected-warning {{'min16uint' is promoted to 'uint16_t'}} expected-warning {{conversion from larger type 'int' to smaller type 'min16uint', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16uint left134; uint right134; left134 = right134; // expected-warning {{'min16uint' is promoted to 'uint16_t'}} expected-warning {{conversion from larger type 'uint' to smaller type 'min16uint', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16uint left135; dword right135; left135 = right135; // expected-warning {{'min16uint' is promoted to 'uint16_t'}} expected-warning {{conversion from larger type 'dword' to smaller type 'min16uint', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16uint left136; half right136; left136 = right136; // expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16uint left137; float right137; left137 = right137; // expected-warning {{'min16uint' is promoted to 'uint16_t'}} expected-warning {{conversion from larger type 'float' to smaller type 'min16uint', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16uint left138; double right138; left138 = right138; // expected-warning {{'min16uint' is promoted to 'uint16_t'}} expected-warning {{conversion from larger type 'double' to smaller type 'min16uint', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min16uint left139; min16float right139; left139 = right139;    /* expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}} */
+min16uint left140; min10float right140; left140 = right140;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}}
+min16uint left141; min16int right141; left141 = right141;    /* expected-warning {{'min16int' is promoted to 'int16_t'}} expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}} */
+min16uint left142; min12int right142; left142 = right142;  // expected-warning {{'min12int' is promoted to 'int16_t'}} expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}}
+min16uint left143; min16uint right143; left143 = right143; /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-pass {{}} */
 
 // new explicit size types
 int16_t left144; bool right144; left144 = right144;        /* fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left144'}} */
@@ -183,11 +183,11 @@ int16_t left147; dword right147; left147 = right147;       /* expected-warning {
 int16_t left148; half right148; left148 = right148;        /* fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left148'}} */
 int16_t left149; float right149; left149 = right149;       /* expected-warning {{conversion from larger type 'float' to smaller type 'int16_t', possible loss of data}} fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left149'}} */
 int16_t left150; double right150; left150 = right150;      /* expected-warning {{conversion from larger type 'double' to smaller type 'int16_t', possible loss of data}} fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left150'}} */
-int16_t left151; min16float right151; left151 = right151;  /* expected-warning {{min16float is promoted to float16_t}} fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left151'}} */
-int16_t left152; min10float right152; left152 = right152;  /* expected-warning {{min10float is promoted to float16_t}} fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left152'}} */
-int16_t left153; min16int right153; left153 = right153;    /* expected-warning {{min16int is promoted to int16_t}} fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left153'}} */
-int16_t left154; min12int right154; left154 = right154;    /* expected-warning {{min12int is promoted to int16_t}} fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left154'}} */
-int16_t left155; min16uint right155; left155 = right155;   /* expected-warning {{min16uint is promoted to uint16_t}} fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left155'}} */
+int16_t left151; min16float right151; left151 = right151;  /* expected-warning {{'min16float' is promoted to 'half'}} fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left151'}} */
+int16_t left152; min10float right152; left152 = right152;  /* expected-warning {{'min10float' is promoted to 'half'}} fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left152'}} */
+int16_t left153; min16int right153; left153 = right153;    /* expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left153'}} */
+int16_t left154; min12int right154; left154 = right154;    /* expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left154'}} */
+int16_t left155; min16uint right155; left155 = right155;   /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left155'}} */
 int16_t left156; int16_t right156; left156 = right156;     /* fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left156'}} */
 int16_t left157; int32_t right157; left157 = right157;     /* expected-warning {{conversion from larger type 'int32_t' to smaller type 'int16_t', possible loss of data}} fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left157'}} */
 int16_t left158; int64_t right158; left158 = right158;     /* expected-warning {{conversion from larger type 'int64_t' to smaller type 'int16_t', possible loss of data}} fxc-error {{X3000: unrecognized identifier 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'left158'}} */
@@ -202,11 +202,11 @@ int32_t left167; dword right167; left167 = right167;       /* fxc-error {{X3000:
 int32_t left168; half right168; left168 = right168;        /* fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left168'}} */
 int32_t left169; float right169; left169 = right169;       /* fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left169'}} */
 int32_t left170; double right170; left170 = right170;      /* expected-warning {{conversion from larger type 'double' to smaller type 'int32_t', possible loss of data}} fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left170'}} */
-int32_t left171; min16float right171; left171 = right171;  /* expected-warning {{min16float is promoted to float16_t}} fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left171'}} */
-int32_t left172; min10float right172; left172 = right172;  /* expected-warning {{min10float is promoted to float16_t}} fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left172'}} */
-int32_t left173; min16int right173; left173 = right173;    /* expected-warning {{min16int is promoted to int16_t}} fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left173'}} */
-int32_t left174; min12int right174; left174 = right174;    /* expected-warning {{min12int is promoted to int16_t}} fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left174'}} */
-int32_t left175; min16uint right175; left175 = right175;   /* expected-warning {{min16uint is promoted to uint16_t}} fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left175'}} */
+int32_t left171; min16float right171; left171 = right171;  /* expected-warning {{'min16float' is promoted to 'half'}} fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left171'}} */
+int32_t left172; min10float right172; left172 = right172;  /* expected-warning {{'min10float' is promoted to 'half'}} fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left172'}} */
+int32_t left173; min16int right173; left173 = right173;    /* expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left173'}} */
+int32_t left174; min12int right174; left174 = right174;    /* expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left174'}} */
+int32_t left175; min16uint right175; left175 = right175;   /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left175'}} */
 int32_t left176; int16_t right176; left176 = right176;     /* fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left176'}} */
 int32_t left177; int32_t right177; left177 = right177;     /* fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left177'}} */
 int32_t left178; int64_t right178; left178 = right178;     /* expected-warning {{conversion from larger type 'int64_t' to smaller type 'int32_t', possible loss of data}} fxc-error {{X3000: unrecognized identifier 'int32_t'}} fxc-error {{X3000: unrecognized identifier 'left178'}} */
@@ -221,11 +221,11 @@ int64_t left187; dword right187; left187 = right187;       /* fxc-error {{X3000:
 int64_t left188; half right188; left188 = right188;        /* fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left188'}} */
 int64_t left189; float right189; left189 = right189;       /* fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left189'}} */
 int64_t left190; double right190; left190 = right190;      /* fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left190'}} */
-int64_t left191; min16float right191; left191 = right191;  /* expected-warning {{min16float is promoted to float16_t}} fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left191'}} */
-int64_t left192; min10float right192; left192 = right192;  /* expected-warning {{min10float is promoted to float16_t}} fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left192'}} */
-int64_t left193; min16int right193; left193 = right193;    /* expected-warning {{min16int is promoted to int16_t}} fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left193'}} */
-int64_t left194; min12int right194; left194 = right194;    /* expected-warning {{min12int is promoted to int16_t}} fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left194'}} */
-int64_t left195; min16uint right195; left195 = right195;   /* expected-warning {{min16uint is promoted to uint16_t}} fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left195'}} */
+int64_t left191; min16float right191; left191 = right191;  /* expected-warning {{'min16float' is promoted to 'half'}} fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left191'}} */
+int64_t left192; min10float right192; left192 = right192;  /* expected-warning {{'min10float' is promoted to 'half'}} fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left192'}} */
+int64_t left193; min16int right193; left193 = right193;    /* expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left193'}} */
+int64_t left194; min12int right194; left194 = right194;    /* expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left194'}} */
+int64_t left195; min16uint right195; left195 = right195;   /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left195'}} */
 int64_t left196; int16_t right196; left196 = right196;     /* fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left196'}} */
 int64_t left197; int32_t right197; left197 = right197;     /* fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left197'}} */
 int64_t left198; int64_t right198; left198 = right198;     /* fxc-error {{X3000: unrecognized identifier 'int64_t'}} fxc-error {{X3000: unrecognized identifier 'left198'}} */
@@ -240,11 +240,11 @@ float16_t left207; dword right207; left207 = right207;     /* expected-warning {
 float16_t left208; half right208; left208 = right208;      /* fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left208'}} */
 float16_t left209; float right209; left209 = right209;     /* expected-warning {{conversion from larger type 'float' to smaller type 'float16_t', possible loss of data}} fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left209'}} */
 float16_t left210; double right210; left210 = right210;    /* expected-warning {{conversion from larger type 'double' to smaller type 'float16_t', possible loss of data}} fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left210'}} */
-float16_t left211; min16float right211; left211 = right211;    /* expected-warning {{min16float is promoted to float16_t}} fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left211'}} */
-float16_t left212; min10float right212; left212 = right212;    /* expected-warning {{min10float is promoted to float16_t}} fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left212'}} */
-float16_t left213; min16int right213; left213 = right213;  /* expected-warning {{min16int is promoted to int16_t}} fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left213'}} */
-float16_t left214; min12int right214; left214 = right214;  /* expected-warning {{min12int is promoted to int16_t}} fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left214'}} */
-float16_t left215; min16uint right215; left215 = right215; /* expected-warning {{min16uint is promoted to uint16_t}} fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left215'}} */
+float16_t left211; min16float right211; left211 = right211;    /* expected-warning {{'min16float' is promoted to 'half'}} fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left211'}} */
+float16_t left212; min10float right212; left212 = right212;    /* expected-warning {{'min10float' is promoted to 'half'}} fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left212'}} */
+float16_t left213; min16int right213; left213 = right213;  /* expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left213'}} */
+float16_t left214; min12int right214; left214 = right214;  /* expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left214'}} */
+float16_t left215; min16uint right215; left215 = right215; /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left215'}} */
 float16_t left216; int16_t right216; left216 = right216;   /* fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left216'}} */
 float16_t left217; int32_t right217; left217 = right217;   /* expected-warning {{conversion from larger type 'int32_t' to smaller type 'float16_t', possible loss of data}} fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left217'}} */
 float16_t left218; int64_t right218; left218 = right218;   /* expected-warning {{conversion from larger type 'int64_t' to smaller type 'float16_t', possible loss of data}} fxc-error {{X3000: unrecognized identifier 'float16_t'}} fxc-error {{X3000: unrecognized identifier 'left218'}} */
@@ -259,11 +259,11 @@ float32_t left227; dword right227; left227 = right227;     /* fxc-error {{X3000:
 float32_t left228; half right228; left228 = right228;      /* fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left228'}} */
 float32_t left229; float right229; left229 = right229;     /* fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left229'}} */
 float32_t left230; double right230; left230 = right230;    /* expected-warning {{conversion from larger type 'double' to smaller type 'float32_t', possible loss of data}} fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left230'}} */
-float32_t left231; min16float right231; left231 = right231;    /* expected-warning {{min16float is promoted to float16_t}} fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left231'}} */
-float32_t left232; min10float right232; left232 = right232;    /* expected-warning {{min10float is promoted to float16_t}} fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left232'}} */
-float32_t left233; min16int right233; left233 = right233;  /* expected-warning {{min16int is promoted to int16_t}} fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left233'}} */
-float32_t left234; min12int right234; left234 = right234;  /* expected-warning {{min12int is promoted to int16_t}} fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left234'}} */
-float32_t left235; min16uint right235; left235 = right235; /* expected-warning {{min16uint is promoted to uint16_t}} fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left235'}} */
+float32_t left231; min16float right231; left231 = right231;    /* expected-warning {{'min16float' is promoted to 'half'}} fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left231'}} */
+float32_t left232; min10float right232; left232 = right232;    /* expected-warning {{'min10float' is promoted to 'half'}} fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left232'}} */
+float32_t left233; min16int right233; left233 = right233;  /* expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left233'}} */
+float32_t left234; min12int right234; left234 = right234;  /* expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left234'}} */
+float32_t left235; min16uint right235; left235 = right235; /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left235'}} */
 float32_t left236; int16_t right236; left236 = right236;   /* fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left236'}} */
 float32_t left237; int32_t right237; left237 = right237;   /* fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left237'}} */
 float32_t left238; int64_t right238; left238 = right238;   /* expected-warning {{conversion from larger type 'int64_t' to smaller type 'float32_t', possible loss of data}} fxc-error {{X3000: unrecognized identifier 'float32_t'}} fxc-error {{X3000: unrecognized identifier 'left238'}} */
@@ -278,11 +278,11 @@ float64_t left247; dword right247; left247 = right247;     /* fxc-error {{X3000:
 float64_t left248; half right248; left248 = right248;      /* fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left248'}} */
 float64_t left249; float right249; left249 = right249;     /* fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left249'}} */
 float64_t left250; double right250; left250 = right250;    /* fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left250'}} */
-float64_t left251; min16float right251; left251 = right251;    /* expected-warning {{min16float is promoted to float16_t}} fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left251'}} */
-float64_t left252; min10float right252; left252 = right252;    /* expected-warning {{min10float is promoted to float16_t}} fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left252'}} */
-float64_t left253; min16int right253; left253 = right253;  /* expected-warning {{min16int is promoted to int16_t}} fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left253'}} */
-float64_t left254; min12int right254; left254 = right254;  /* expected-warning {{min12int is promoted to int16_t}} fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left254'}} */
-float64_t left255; min16uint right255; left255 = right255; /* expected-warning {{min16uint is promoted to uint16_t}} fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left255'}} */
+float64_t left251; min16float right251; left251 = right251;    /* expected-warning {{'min16float' is promoted to 'half'}} fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left251'}} */
+float64_t left252; min10float right252; left252 = right252;    /* expected-warning {{'min10float' is promoted to 'half'}} fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left252'}} */
+float64_t left253; min16int right253; left253 = right253;  /* expected-warning {{'min16int' is promoted to 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left253'}} */
+float64_t left254; min12int right254; left254 = right254;  /* expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left254'}} */
+float64_t left255; min16uint right255; left255 = right255; /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left255'}} */
 float64_t left256; int16_t right256; left256 = right256;   /* fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left256'}} */
 float64_t left257; int32_t right257; left257 = right257;   /* fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left257'}} */
 float64_t left258; int64_t right258; left258 = right258;   /* fxc-error {{X3000: unrecognized identifier 'float64_t'}} fxc-error {{X3000: unrecognized identifier 'left258'}} */
@@ -353,106 +353,106 @@ double left299; float64_t right299; left299 = right299;    /* fxc-error {{X3000:
  float left1001; unorm float right1001; left1001 = right1001;
 // float left1002; snorm double right1002; left1002 = right1002;
 // float left1003; unorm double right1003; left1003 = right1003;
- float left1004; snorm min16float right1004; left1004 = right1004;    /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
- float left1005; unorm min16float right1005; left1005 = right1005;    /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
- float left1006; snorm min10float right1006; left1006 = right1006;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
- float left1007; unorm min10float right1007; left1007 = right1007;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
+ float left1004; snorm min16float right1004; left1004 = right1004;    /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+ float left1005; unorm min16float right1005; left1005 = right1005;    /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+ float left1006; snorm min10float right1006; left1006 = right1006;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+ float left1007; unorm min10float right1007; left1007 = right1007;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
 snorm float left1008;  float right1008; left1008 = right1008;
 snorm float left1009; snorm float right1009; left1009 = right1009;
 snorm float left1010; unorm float right1010; left1010 = right1010;
 // snorm float left1011;  double right1011; left1011 = right1011;
 // snorm float left1012; snorm double right1012; left1012 = right1012;
 // snorm float left1013; unorm double right1013; left1013 = right1013;
-snorm float left1014;  min16float right1014; left1014 = right1014;  /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-snorm float left1015; snorm min16float right1015; left1015 = right1015;    /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-snorm float left1016; unorm min16float right1016; left1016 = right1016;    /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-snorm float left1017;  min10float right1017; left1017 = right1017;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-snorm float left1018; snorm min10float right1018; left1018 = right1018;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-snorm float left1019; unorm min10float right1019; left1019 = right1019;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
+snorm float left1014;  min16float right1014; left1014 = right1014;  /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+snorm float left1015; snorm min16float right1015; left1015 = right1015;    /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+snorm float left1016; unorm min16float right1016; left1016 = right1016;    /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+snorm float left1017;  min10float right1017; left1017 = right1017;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+snorm float left1018; snorm min10float right1018; left1018 = right1018;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+snorm float left1019; unorm min10float right1019; left1019 = right1019;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
 unorm float left1020;  float right1020; left1020 = right1020;
 unorm float left1021; snorm float right1021; left1021 = right1021;
 unorm float left1022; unorm float right1022; left1022 = right1022;
 // unorm float left1023;  double right1023; left1023 = right1023;
 // unorm float left1024; snorm double right1024; left1024 = right1024;
 // unorm float left1025; unorm double right1025; left1025 = right1025;
-unorm float left1026;  min16float right1026; left1026 = right1026;       /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-unorm float left1027; snorm min16float right1027; left1027 = right1027;  /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-unorm float left1028; unorm min16float right1028; left1028 = right1028;  /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-unorm float left1029;  min10float right1029; left1029 = right1029;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-unorm float left1030; snorm min10float right1030; left1030 = right1030;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-unorm float left1031; unorm min10float right1031; left1031 = right1031;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
+unorm float left1026;  min16float right1026; left1026 = right1026;       /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+unorm float left1027; snorm min16float right1027; left1027 = right1027;  /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+unorm float left1028; unorm min16float right1028; left1028 = right1028;  /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+unorm float left1029;  min10float right1029; left1029 = right1029;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+unorm float left1030; snorm min10float right1030; left1030 = right1030;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+unorm float left1031; unorm min10float right1031; left1031 = right1031;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
  double left1032; snorm float right1032; left1032 = right1032;
  double left1033; unorm float right1033; left1033 = right1033;
  double left1034; snorm double right1034; left1034 = right1034;
  double left1035; unorm double right1035; left1035 = right1035;
- double left1036; snorm min16float right1036; left1036 = right1036;      /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
- double left1037; unorm min16float right1037; left1037 = right1037;      /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
- double left1038; snorm min10float right1038; left1038 = right1038;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
- double left1039; unorm min10float right1039; left1039 = right1039;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
+ double left1036; snorm min16float right1036; left1036 = right1036;      /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+ double left1037; unorm min16float right1037; left1037 = right1037;      /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+ double left1038; snorm min10float right1038; left1038 = right1038;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+ double left1039; unorm min10float right1039; left1039 = right1039;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
 snorm double left1040;  float right1040; left1040 = right1040;
 snorm double left1041; snorm float right1041; left1041 = right1041;
 snorm double left1042; unorm float right1042; left1042 = right1042;
 snorm double left1043;  double right1043; left1043 = right1043;
 snorm double left1044; snorm double right1044; left1044 = right1044;
 snorm double left1045; unorm double right1045; left1045 = right1045;
-snorm double left1046;  min16float right1046; left1046 = right1046;  /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-snorm double left1047; snorm min16float right1047; left1047 = right1047;    /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-snorm double left1048; unorm min16float right1048; left1048 = right1048;    /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-snorm double left1049;  min10float right1049; left1049 = right1049;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-snorm double left1050; snorm min10float right1050; left1050 = right1050;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-snorm double left1051; unorm min10float right1051; left1051 = right1051;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
+snorm double left1046;  min16float right1046; left1046 = right1046;  /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+snorm double left1047; snorm min16float right1047; left1047 = right1047;    /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+snorm double left1048; unorm min16float right1048; left1048 = right1048;    /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+snorm double left1049;  min10float right1049; left1049 = right1049;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+snorm double left1050; snorm min10float right1050; left1050 = right1050;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+snorm double left1051; unorm min10float right1051; left1051 = right1051;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
 unorm double left1052;  float right1052; left1052 = right1052;
 unorm double left1053; snorm float right1053; left1053 = right1053;
 unorm double left1054; unorm float right1054; left1054 = right1054;
 unorm double left1055;  double right1055; left1055 = right1055;
 unorm double left1056; snorm double right1056; left1056 = right1056;
 unorm double left1057; unorm double right1057; left1057 = right1057;
-unorm double left1058;  min16float right1058; left1058 = right1058;       /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-unorm double left1059; snorm min16float right1059; left1059 = right1059;  /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-unorm double left1060; unorm min16float right1060; left1060 = right1060;  /* expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-unorm double left1061;  min10float right1061; left1061 = right1061;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-unorm double left1062; snorm min10float right1062; left1062 = right1062;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
-unorm double left1063; unorm min10float right1063; left1063 = right1063;  // expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}}
+unorm double left1058;  min16float right1058; left1058 = right1058;       /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+unorm double left1059; snorm min16float right1059; left1059 = right1059;  /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+unorm double left1060; unorm min16float right1060; left1060 = right1060;  /* expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+unorm double left1061;  min10float right1061; left1061 = right1061;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+unorm double left1062; snorm min10float right1062; left1062 = right1062;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
+unorm double left1063; unorm min10float right1063; left1063 = right1063;  // expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}}
 // min16float left1064; snorm float right1064; left1064 = right1064;
 // min16float left1065; unorm float right1065; left1065 = right1065;
 // min16float left1066; snorm double right1066; left1066 = right1066;
 // min16float left1067; unorm double right1067; left1067 = right1067;
- min16float left1068; snorm min16float right1068; left1068 = right1068;   /* expected-warning {{min16float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
- min16float left1069; unorm min16float right1069; left1069 = right1069;   /* expected-warning {{min16float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
- min16float left1070; snorm min10float right1070; left1070 = right1070;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}}
- min16float left1071; unorm min10float right1071; left1071 = right1071;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}}
+ min16float left1068; snorm min16float right1068; left1068 = right1068;   /* expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+ min16float left1069; unorm min16float right1069; left1069 = right1069;   /* expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+ min16float left1070; snorm min10float right1070; left1070 = right1070;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}}
+ min16float left1071; unorm min10float right1071; left1071 = right1071;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}}
 // snorm min16float left1072;  float right1072; left1072 = right1072;
 // snorm min16float left1073; snorm float right1073; left1073 = right1073;
 // snorm min16float left1074; unorm float right1074; left1074 = right1074;
 // snorm min16float left1075;  double right1075; left1075 = right1075;
 // snorm min16float left1076; snorm double right1076; left1076 = right1076;
 // snorm min16float left1077; unorm double right1077; left1077 = right1077;
-snorm min16float left1078;  min16float right1078; left1078 = right1078;  /* expected-warning {{min16float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-snorm min16float left1079; snorm min16float right1079; left1079 = right1079;    /* expected-warning {{min16float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-snorm min16float left1080; unorm min16float right1080; left1080 = right1080;    /* expected-warning {{min16float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-snorm min16float left1081;  min10float right1081; left1081 = right1081;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}}
-snorm min16float left1082; snorm min10float right1082; left1082 = right1082;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}}
-snorm min16float left1083; unorm min10float right1083; left1083 = right1083;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}}
+snorm min16float left1078;  min16float right1078; left1078 = right1078;  /* expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+snorm min16float left1079; snorm min16float right1079; left1079 = right1079;    /* expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+snorm min16float left1080; unorm min16float right1080; left1080 = right1080;    /* expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+snorm min16float left1081;  min10float right1081; left1081 = right1081;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}}
+snorm min16float left1082; snorm min10float right1082; left1082 = right1082;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}}
+snorm min16float left1083; unorm min10float right1083; left1083 = right1083;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}}
 // unorm min16float left1084;  float right1084; left1084 = right1084;
 // unorm min16float left1085; snorm float right1085; left1085 = right1085;
 // unorm min16float left1086; unorm float right1086; left1086 = right1086;
 // unorm min16float left1087;  double right1087; left1087 = right1087;
 // unorm min16float left1088; snorm double right1088; left1088 = right1088;
 // unorm min16float left1089; unorm double right1089; left1089 = right1089;
-unorm min16float left1090;  min16float right1090; left1090 = right1090;       /* expected-warning {{min16float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-unorm min16float left1091; snorm min16float right1091; left1091 = right1091;  /* expected-warning {{min16float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-unorm min16float left1092; unorm min16float right1092; left1092 = right1092;  /* expected-warning {{min16float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}} */
-unorm min16float left1093;  min10float right1093; left1093 = right1093;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}}
-unorm min16float left1094; snorm min10float right1094; left1094 = right1094;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}}
-unorm min16float left1095; unorm min10float right1095; left1095 = right1095;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min16float is promoted to float16_t}} fxc-pass {{}}
+unorm min16float left1090;  min16float right1090; left1090 = right1090;       /* expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+unorm min16float left1091; snorm min16float right1091; left1091 = right1091;  /* expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+unorm min16float left1092; unorm min16float right1092; left1092 = right1092;  /* expected-warning {{'min16float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}} */
+unorm min16float left1093;  min10float right1093; left1093 = right1093;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}}
+unorm min16float left1094; snorm min10float right1094; left1094 = right1094;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}}
+unorm min16float left1095; unorm min10float right1095; left1095 = right1095;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min16float' is promoted to 'half'}} fxc-pass {{}}
 // min10float left1096; snorm float right1096; left1096 = right1096;
 // min10float left1097; unorm float right1097; left1097 = right1097;
 // min10float left1098; snorm double right1098; left1098 = right1098;
 // min10float left1099; unorm double right1099; left1099 = right1099;
 // min10float left1100; snorm min16float right1100; left1100 = right1100;
 // min10float left1101; unorm min16float right1101; left1101 = right1101;
- min10float left1102; snorm min10float right1102; left1102 = right1102;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}} //
- min10float left1103; unorm min10float right1103; left1103 = right1103;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}} //
+ min10float left1102; snorm min10float right1102; left1102 = right1102;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}} //
+ min10float left1103; unorm min10float right1103; left1103 = right1103;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}} //
 // snorm min10float left1104;  float right1104; left1104 = right1104;
 // snorm min10float left1105; snorm float right1105; left1105 = right1105;
 // snorm min10float left1106; unorm float right1106; left1106 = right1106;
@@ -462,9 +462,9 @@ unorm min16float left1095; unorm min10float right1095; left1095 = right1095;  //
 // snorm min10float left1110;  min16float right1110; left1110 = right1110;
 // snorm min10float left1111; snorm min16float right1111; left1111 = right1111;
 // snorm min10float left1112; unorm min16float right1112; left1112 = right1112;
-snorm min10float left1113;  min10float right1113; left1113 = right1113;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}} //
-snorm min10float left1114; snorm min10float right1114; left1114 = right1114;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}} //
-snorm min10float left1115; unorm min10float right1115; left1115 = right1115;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}} //
+snorm min10float left1113;  min10float right1113; left1113 = right1113;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}} //
+snorm min10float left1114; snorm min10float right1114; left1114 = right1114;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}} //
+snorm min10float left1115; unorm min10float right1115; left1115 = right1115;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}} //
 // unorm min10float left1116;  float right1116; left1116 = right1116;
 // unorm min10float left1117; snorm float right1117; left1117 = right1117;
 // unorm min10float left1118; unorm float right1118; left1118 = right1118;
@@ -474,8 +474,8 @@ snorm min10float left1115; unorm min10float right1115; left1115 = right1115;  //
 // unorm min10float left1122;  min16float right1122; left1122 = right1122;
 // unorm min10float left1123; snorm min16float right1123; left1123 = right1123;
 // unorm min10float left1124; unorm min16float right1124; left1124 = right1124;
-unorm min10float left1125;  min10float right1125; left1125 = right1125;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}} //
-unorm min10float left1126; snorm min10float right1126; left1126 = right1126;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}} //
-unorm min10float left1127; unorm min10float right1127; left1127 = right1127;  // expected-warning {{min10float is promoted to float16_t}} expected-warning {{min10float is promoted to float16_t}} fxc-pass {{}} //
+unorm min10float left1125;  min10float right1125; left1125 = right1125;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}} //
+unorm min10float left1126; snorm min10float right1126; left1126 = right1126;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}} //
+unorm min10float left1127; unorm min10float right1127; left1127 = right1127;  // expected-warning {{'min10float' is promoted to 'half'}} expected-warning {{'min10float' is promoted to 'half'}} fxc-pass {{}} //
 
-}
+}

+ 77 - 77
tools/clang/test/HLSL/scalar-assignments.hlsl

@@ -38,9 +38,9 @@ bool left4; half right4; left4 = right4;
 bool left5; float right5; left5 = right5;
 bool left6; double right6; left6 = right6;
 bool left7; min16float right7; left7 = right7;
-bool left8; min10float right8; left8 = right8;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+bool left8; min10float right8; left8 = right8;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 bool left9; min16int right9; left9 = right9;
-bool left10; min12int right10; left10 = right10;  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+bool left10; min12int right10; left10 = right10;  // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}
 bool left11; min16uint right11; left11 = right11;
 int left12; bool right12; left12 = right12;
 int left13; int right13; left13 = right13;
@@ -50,9 +50,9 @@ int left16; half right16; left16 = right16;
 int left17; float right17; left17 = right17;
 int left18; double right18; left18 = right18; // expected-warning {{conversion from larger type 'double' to smaller type 'int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 int left19; min16float right19; left19 = right19;
-int left20; min10float right20; left20 = right20;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+int left20; min10float right20; left20 = right20;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 int left21; min16int right21; left21 = right21;
-int left22; min12int right22; left22 = right22;  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+int left22; min12int right22; left22 = right22;  // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}
 int left23; min16uint right23; left23 = right23;
 uint left24; bool right24; left24 = right24;
 uint left25; int right25; left25 = right25;
@@ -62,9 +62,9 @@ uint left28; half right28; left28 = right28;
 uint left29; float right29; left29 = right29;
 uint left30; double right30; left30 = right30; // expected-warning {{conversion from larger type 'double' to smaller type 'uint', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 uint left31; min16float right31; left31 = right31;
-uint left32; min10float right32; left32 = right32;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+uint left32; min10float right32; left32 = right32;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 uint left33; min16int right33; left33 = right33;
-uint left34; min12int right34; left34 = right34;  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+uint left34; min12int right34; left34 = right34;  // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}
 uint left35; min16uint right35; left35 = right35;
 dword left36; bool right36; left36 = right36;
 dword left37; int right37; left37 = right37;
@@ -74,9 +74,9 @@ dword left40; half right40; left40 = right40;
 dword left41; float right41; left41 = right41;
 dword left42; double right42; left42 = right42; // expected-warning {{conversion from larger type 'double' to smaller type 'dword', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 dword left43; min16float right43; left43 = right43;
-dword left44; min10float right44; left44 = right44;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+dword left44; min10float right44; left44 = right44;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 dword left45; min16int right45; left45 = right45;
-dword left46; min12int right46; left46 = right46;  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+dword left46; min12int right46; left46 = right46;  // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}
 dword left47; min16uint right47; left47 = right47;
 half left48; bool right48; left48 = right48;
 half left49; int right49; left49 = right49;
@@ -86,9 +86,9 @@ half left52; half right52; left52 = right52;
 half left53; float right53; left53 = right53;
 half left54; double right54; left54 = right54; // expected-warning {{conversion from larger type 'double' to smaller type 'half', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 half left55; min16float right55; left55 = right55;
-half left56; min10float right56; left56 = right56;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+half left56; min10float right56; left56 = right56;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 half left57; min16int right57; left57 = right57;
-half left58; min12int right58; left58 = right58;  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+half left58; min12int right58; left58 = right58;  // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}
 half left59; min16uint right59; left59 = right59;
 float left60; bool right60; left60 = right60;
 float left61; int right61; left61 = right61;
@@ -98,9 +98,9 @@ float left64; half right64; left64 = right64;
 float left65; float right65; left65 = right65;
 float left66; double right66; left66 = right66; // expected-warning {{conversion from larger type 'double' to smaller type 'float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 float left67; min16float right67; left67 = right67;
-float left68; min10float right68; left68 = right68;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+float left68; min10float right68; left68 = right68;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 float left69; min16int right69; left69 = right69;
-float left70; min12int right70; left70 = right70;  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+float left70; min12int right70; left70 = right70;  // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}
 float left71; min16uint right71; left71 = right71;
 double left72; bool right72; left72 = right72;
 double left73; int right73; left73 = right73;
@@ -110,9 +110,9 @@ double left76; half right76; left76 = right76;
 double left77; float right77; left77 = right77;
 double left78; double right78; left78 = right78;
 double left79; min16float right79; left79 = right79;
-double left80; min10float right80; left80 = right80;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+double left80; min10float right80; left80 = right80;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 double left81; min16int right81; left81 = right81;
-double left82; min12int right82; left82 = right82;  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+double left82; min12int right82; left82 = right82;  // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}
 double left83; min16uint right83; left83 = right83;
 min16float left84; bool right84; left84 = right84;
 min16float left85; int right85; left85 = right85; // expected-warning {{conversion from larger type 'int' to smaller type 'min16float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
@@ -122,22 +122,22 @@ min16float left88; half right88; left88 = right88; // expected-warning {{convers
 min16float left89; float right89; left89 = right89; // expected-warning {{conversion from larger type 'float' to smaller type 'min16float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 min16float left90; double right90; left90 = right90; // expected-warning {{conversion from larger type 'double' to smaller type 'min16float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 min16float left91; min16float right91; left91 = right91;
-min16float left92; min10float right92; left92 = right92;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+min16float left92; min10float right92; left92 = right92;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 min16float left93; min16int right93; left93 = right93;
-min16float left94; min12int right94; left94 = right94;  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+min16float left94; min12int right94; left94 = right94;  // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}
 min16float left95; min16uint right95; left95 = right95;
-min10float left96; bool right96; left96 = right96;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-min10float left97; int right97; left97 = right97; // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left98; uint right98; left98 = right98; // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left99; dword right99; left99 = right99; // expected-warning {{conversion from larger type 'dword' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left100; half right100; left100 = right100; // expected-warning {{conversion from larger type 'half' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left101; float right101; left101 = right101; // expected-warning {{conversion from larger type 'float' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left102; double right102; left102 = right102; // expected-warning {{conversion from larger type 'double' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min10float left103; min16float right103; left103 = right103; // expected-warning {{conversion from larger type 'min16float' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min10float left104; min10float right104; left104 = right104;  // expected-warning {{min10float is promoted to min16float}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}} //
-min10float left105; min16int right105; left105 = right105; // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min10float left106; min12int right106; left106 = right106; // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} expected-warning {{min12int is promoted to min16int}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min10float left107; min16uint right107; left107 = right107; // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min10float left96; bool right96; left96 = right96;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+min10float left97; int right97; left97 = right97; // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left98; uint right98; left98 = right98; // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left99; dword right99; left99 = right99; // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{conversion from larger type 'dword' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left100; half right100; left100 = right100; // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{conversion from larger type 'half' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left101; float right101; left101 = right101; // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{conversion from larger type 'float' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left102; double right102; left102 = right102; // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{conversion from larger type 'double' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min10float left103; min16float right103; left103 = right103; // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{conversion from larger type 'min16float' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min10float left104; min10float right104; left104 = right104;  // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}} //
+min10float left105; min16int right105; left105 = right105; // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min10float left106; min12int right106; left106 = right106; // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{'min12int' is promoted to 'min16int'}} expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min10float left107; min16uint right107; left107 = right107; // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 min16int left108; bool right108; left108 = right108;
 min16int left109; int right109; left109 = right109; // expected-warning {{conversion from larger type 'int' to smaller type 'min16int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 min16int left110; uint right110; left110 = right110; // expected-warning {{conversion from larger type 'uint' to smaller type 'min16int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
@@ -146,22 +146,22 @@ min16int left112; half right112; left112 = right112; // expected-warning {{conve
 min16int left113; float right113; left113 = right113; // expected-warning {{conversion from larger type 'float' to smaller type 'min16int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 min16int left114; double right114; left114 = right114; // expected-warning {{conversion from larger type 'double' to smaller type 'min16int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 min16int left115; min16float right115; left115 = right115;
-min16int left116; min10float right116; left116 = right116;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+min16int left116; min10float right116; left116 = right116;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 min16int left117; min16int right117; left117 = right117;
-min16int left118; min12int right118; left118 = right118;  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+min16int left118; min12int right118; left118 = right118;  // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}
 min16int left119; min16uint right119; left119 = right119;
-min12int left120; bool right120; left120 = right120;  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
-min12int left121; int right121; left121 = right121; // expected-warning {{conversion from larger type 'int' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to min16int}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min12int left122; uint right122; left122 = right122; // expected-warning {{conversion from larger type 'uint' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to min16int}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min12int left123; dword right123; left123 = right123; // expected-warning {{conversion from larger type 'dword' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to min16int}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min12int left124; half right124; left124 = right124; // expected-warning {{conversion from larger type 'half' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to min16int}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min12int left125; float right125; left125 = right125; // expected-warning {{conversion from larger type 'float' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to min16int}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min12int left126; double right126; left126 = right126; // expected-warning {{conversion from larger type 'double' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to min16int}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
-min12int left127; min16float right127; left127 = right127; // expected-warning {{conversion from larger type 'min16float' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to min16int}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min12int left128; min10float right128; left128 = right128;  // expected-warning {{min10float is promoted to min16float}} expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} //
-min12int left129; min16int right129; left129 = right129; // expected-warning {{conversion from larger type 'min16int' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to min16int}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
-min12int left130; min12int right130; left130 = right130;  // expected-warning {{min12int is promoted to min16int}} expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} //
-min12int left131; min16uint right131; left131 = right131; // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min12int', possible loss of data}} expected-warning {{min12int is promoted to min16int}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min12int left120; bool right120; left120 = right120;  // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}
+min12int left121; int right121; left121 = right121; // expected-warning {{'min12int' is promoted to 'min16int'}} expected-warning {{conversion from larger type 'int' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min12int left122; uint right122; left122 = right122; // expected-warning {{'min12int' is promoted to 'min16int'}} expected-warning {{conversion from larger type 'uint' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min12int left123; dword right123; left123 = right123; // expected-warning {{'min12int' is promoted to 'min16int'}} expected-warning {{conversion from larger type 'dword' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min12int left124; half right124; left124 = right124; // expected-warning {{'min12int' is promoted to 'min16int'}} expected-warning {{conversion from larger type 'half' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min12int left125; float right125; left125 = right125; // expected-warning {{'min12int' is promoted to 'min16int'}} expected-warning {{conversion from larger type 'float' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min12int left126; double right126; left126 = right126; // expected-warning {{'min12int' is promoted to 'min16int'}} expected-warning {{conversion from larger type 'double' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}} //
+min12int left127; min16float right127; left127 = right127; // expected-warning {{'min12int' is promoted to 'min16int'}} expected-warning {{conversion from larger type 'min16float' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min12int left128; min10float right128; left128 = right128;  // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}} //
+min12int left129; min16int right129; left129 = right129; // expected-warning {{'min12int' is promoted to 'min16int'}} expected-warning {{conversion from larger type 'min16int' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
+min12int left130; min12int right130; left130 = right130;  // expected-warning {{'min12int' is promoted to 'min16int'}} expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}} //
+min12int left131; min16uint right131; left131 = right131; // expected-warning {{'min12int' is promoted to 'min16int'}} expected-warning {{conversion from larger type 'min16uint' to smaller type 'min12int', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 min16uint left132; bool right132; left132 = right132;
 min16uint left133; int right133; left133 = right133; // expected-warning {{conversion from larger type 'int' to smaller type 'min16uint', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 min16uint left134; uint right134; left134 = right134; // expected-warning {{conversion from larger type 'uint' to smaller type 'min16uint', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
@@ -170,9 +170,9 @@ min16uint left136; half right136; left136 = right136; // expected-warning {{conv
 min16uint left137; float right137; left137 = right137; // expected-warning {{conversion from larger type 'float' to smaller type 'min16uint', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 min16uint left138; double right138; left138 = right138; // expected-warning {{conversion from larger type 'double' to smaller type 'min16uint', possible loss of data}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
 min16uint left139; min16float right139; left139 = right139;
-min16uint left140; min10float right140; left140 = right140;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+min16uint left140; min10float right140; left140 = right140;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 min16uint left141; min16int right141; left141 = right141;
-min16uint left142; min12int right142; left142 = right142;  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+min16uint left142; min12int right142; left142 = right142;  // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}
 min16uint left143; min16uint right143; left143 = right143;
 
 // Now with unorm and snorm modifiers.
@@ -198,8 +198,8 @@ min16uint left143; min16uint right143; left143 = right143;
 // float left1003; unorm double right1003; left1003 = right1003;
  float left1004; snorm min16float right1004; left1004 = right1004;
  float left1005; unorm min16float right1005; left1005 = right1005;
- float left1006; snorm min10float right1006; left1006 = right1006;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
- float left1007; unorm min10float right1007; left1007 = right1007;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+ float left1006; snorm min10float right1006; left1006 = right1006;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+ float left1007; unorm min10float right1007; left1007 = right1007;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 snorm float left1008;  float right1008; left1008 = right1008;
 snorm float left1009; snorm float right1009; left1009 = right1009;
 snorm float left1010; unorm float right1010; left1010 = right1010;
@@ -209,9 +209,9 @@ snorm float left1010; unorm float right1010; left1010 = right1010;
 snorm float left1014;  min16float right1014; left1014 = right1014;
 snorm float left1015; snorm min16float right1015; left1015 = right1015;
 snorm float left1016; unorm min16float right1016; left1016 = right1016;
-snorm float left1017;  min10float right1017; left1017 = right1017;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-snorm float left1018; snorm min10float right1018; left1018 = right1018;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-snorm float left1019; unorm min10float right1019; left1019 = right1019;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+snorm float left1017;  min10float right1017; left1017 = right1017;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+snorm float left1018; snorm min10float right1018; left1018 = right1018;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+snorm float left1019; unorm min10float right1019; left1019 = right1019;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 unorm float left1020;  float right1020; left1020 = right1020;
 unorm float left1021; snorm float right1021; left1021 = right1021;
 unorm float left1022; unorm float right1022; left1022 = right1022;
@@ -221,17 +221,17 @@ unorm float left1022; unorm float right1022; left1022 = right1022;
 unorm float left1026;  min16float right1026; left1026 = right1026;
 unorm float left1027; snorm min16float right1027; left1027 = right1027;
 unorm float left1028; unorm min16float right1028; left1028 = right1028;
-unorm float left1029;  min10float right1029; left1029 = right1029;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-unorm float left1030; snorm min10float right1030; left1030 = right1030;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-unorm float left1031; unorm min10float right1031; left1031 = right1031;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+unorm float left1029;  min10float right1029; left1029 = right1029;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+unorm float left1030; snorm min10float right1030; left1030 = right1030;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+unorm float left1031; unorm min10float right1031; left1031 = right1031;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
  double left1032; snorm float right1032; left1032 = right1032;
  double left1033; unorm float right1033; left1033 = right1033;
  double left1034; snorm double right1034; left1034 = right1034;
  double left1035; unorm double right1035; left1035 = right1035;
  double left1036; snorm min16float right1036; left1036 = right1036;
  double left1037; unorm min16float right1037; left1037 = right1037;
- double left1038; snorm min10float right1038; left1038 = right1038;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
- double left1039; unorm min10float right1039; left1039 = right1039;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+ double left1038; snorm min10float right1038; left1038 = right1038;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+ double left1039; unorm min10float right1039; left1039 = right1039;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 snorm double left1040;  float right1040; left1040 = right1040;
 snorm double left1041; snorm float right1041; left1041 = right1041;
 snorm double left1042; unorm float right1042; left1042 = right1042;
@@ -241,9 +241,9 @@ snorm double left1045; unorm double right1045; left1045 = right1045;
 snorm double left1046;  min16float right1046; left1046 = right1046;
 snorm double left1047; snorm min16float right1047; left1047 = right1047;
 snorm double left1048; unorm min16float right1048; left1048 = right1048;
-snorm double left1049;  min10float right1049; left1049 = right1049;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-snorm double left1050; snorm min10float right1050; left1050 = right1050;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-snorm double left1051; unorm min10float right1051; left1051 = right1051;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+snorm double left1049;  min10float right1049; left1049 = right1049;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+snorm double left1050; snorm min10float right1050; left1050 = right1050;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+snorm double left1051; unorm min10float right1051; left1051 = right1051;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 unorm double left1052;  float right1052; left1052 = right1052;
 unorm double left1053; snorm float right1053; left1053 = right1053;
 unorm double left1054; unorm float right1054; left1054 = right1054;
@@ -253,17 +253,17 @@ unorm double left1057; unorm double right1057; left1057 = right1057;
 unorm double left1058;  min16float right1058; left1058 = right1058;
 unorm double left1059; snorm min16float right1059; left1059 = right1059;
 unorm double left1060; unorm min16float right1060; left1060 = right1060;
-unorm double left1061;  min10float right1061; left1061 = right1061;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-unorm double left1062; snorm min10float right1062; left1062 = right1062;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-unorm double left1063; unorm min10float right1063; left1063 = right1063;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+unorm double left1061;  min10float right1061; left1061 = right1061;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+unorm double left1062; snorm min10float right1062; left1062 = right1062;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+unorm double left1063; unorm min10float right1063; left1063 = right1063;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 // min16float left1064; snorm float right1064; left1064 = right1064;
 // min16float left1065; unorm float right1065; left1065 = right1065;
 // min16float left1066; snorm double right1066; left1066 = right1066;
 // min16float left1067; unorm double right1067; left1067 = right1067;
  min16float left1068; snorm min16float right1068; left1068 = right1068;
  min16float left1069; unorm min16float right1069; left1069 = right1069;
- min16float left1070; snorm min10float right1070; left1070 = right1070;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
- min16float left1071; unorm min10float right1071; left1071 = right1071;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+ min16float left1070; snorm min10float right1070; left1070 = right1070;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+ min16float left1071; unorm min10float right1071; left1071 = right1071;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 // snorm min16float left1072;  float right1072; left1072 = right1072;
 // snorm min16float left1073; snorm float right1073; left1073 = right1073;
 // snorm min16float left1074; unorm float right1074; left1074 = right1074;
@@ -273,9 +273,9 @@ unorm double left1063; unorm min10float right1063; left1063 = right1063;  // exp
 snorm min16float left1078;  min16float right1078; left1078 = right1078;
 snorm min16float left1079; snorm min16float right1079; left1079 = right1079;
 snorm min16float left1080; unorm min16float right1080; left1080 = right1080;
-snorm min16float left1081;  min10float right1081; left1081 = right1081;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-snorm min16float left1082; snorm min10float right1082; left1082 = right1082;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-snorm min16float left1083; unorm min10float right1083; left1083 = right1083;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+snorm min16float left1081;  min10float right1081; left1081 = right1081;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+snorm min16float left1082; snorm min10float right1082; left1082 = right1082;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+snorm min16float left1083; unorm min10float right1083; left1083 = right1083;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 // unorm min16float left1084;  float right1084; left1084 = right1084;
 // unorm min16float left1085; snorm float right1085; left1085 = right1085;
 // unorm min16float left1086; unorm float right1086; left1086 = right1086;
@@ -285,17 +285,17 @@ snorm min16float left1083; unorm min10float right1083; left1083 = right1083;  //
 unorm min16float left1090;  min16float right1090; left1090 = right1090;
 unorm min16float left1091; snorm min16float right1091; left1091 = right1091;
 unorm min16float left1092; unorm min16float right1092; left1092 = right1092;
-unorm min16float left1093;  min10float right1093; left1093 = right1093;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-unorm min16float left1094; snorm min10float right1094; left1094 = right1094;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-unorm min16float left1095; unorm min10float right1095; left1095 = right1095;  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+unorm min16float left1093;  min10float right1093; left1093 = right1093;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+unorm min16float left1094; snorm min10float right1094; left1094 = right1094;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
+unorm min16float left1095; unorm min10float right1095; left1095 = right1095;  // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
 // min10float left1096; snorm float right1096; left1096 = right1096;
 // min10float left1097; unorm float right1097; left1097 = right1097;
 // min10float left1098; snorm double right1098; left1098 = right1098;
 // min10float left1099; unorm double right1099; left1099 = right1099;
 // min10float left1100; snorm min16float right1100; left1100 = right1100;
 // min10float left1101; unorm min16float right1101; left1101 = right1101;
- min10float left1102; snorm min10float right1102; left1102 = right1102;  // expected-warning {{min10float is promoted to min16float}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}} //
- min10float left1103; unorm min10float right1103; left1103 = right1103;  // expected-warning {{min10float is promoted to min16float}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}} //
+ min10float left1102; snorm min10float right1102; left1102 = right1102;  // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}} //
+ min10float left1103; unorm min10float right1103; left1103 = right1103;  // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}} //
 // snorm min10float left1104;  float right1104; left1104 = right1104;
 // snorm min10float left1105; snorm float right1105; left1105 = right1105;
 // snorm min10float left1106; unorm float right1106; left1106 = right1106;
@@ -305,9 +305,9 @@ unorm min16float left1095; unorm min10float right1095; left1095 = right1095;  //
 // snorm min10float left1110;  min16float right1110; left1110 = right1110;
 // snorm min10float left1111; snorm min16float right1111; left1111 = right1111;
 // snorm min10float left1112; unorm min16float right1112; left1112 = right1112;
-snorm min10float left1113;  min10float right1113; left1113 = right1113;  // expected-warning {{min10float is promoted to min16float}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}} //
-snorm min10float left1114; snorm min10float right1114; left1114 = right1114;  // expected-warning {{min10float is promoted to min16float}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}} //
-snorm min10float left1115; unorm min10float right1115; left1115 = right1115;  // expected-warning {{min10float is promoted to min16float}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}} //
+snorm min10float left1113;  min10float right1113; left1113 = right1113;  // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}} //
+snorm min10float left1114; snorm min10float right1114; left1114 = right1114;  // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}} //
+snorm min10float left1115; unorm min10float right1115; left1115 = right1115;  // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}} //
 // unorm min10float left1116;  float right1116; left1116 = right1116;
 // unorm min10float left1117; snorm float right1117; left1117 = right1117;
 // unorm min10float left1118; unorm float right1118; left1118 = right1118;
@@ -317,8 +317,8 @@ snorm min10float left1115; unorm min10float right1115; left1115 = right1115;  //
 // unorm min10float left1122;  min16float right1122; left1122 = right1122;
 // unorm min10float left1123; snorm min16float right1123; left1123 = right1123;
 // unorm min10float left1124; unorm min16float right1124; left1124 = right1124;
-unorm min10float left1125;  min10float right1125; left1125 = right1125;  // expected-warning {{min10float is promoted to min16float}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}} //
-unorm min10float left1126; snorm min10float right1126; left1126 = right1126;  // expected-warning {{min10float is promoted to min16float}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}} //
-unorm min10float left1127; unorm min10float right1127; left1127 = right1127;  // expected-warning {{min10float is promoted to min16float}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}} //
+unorm min10float left1125;  min10float right1125; left1125 = right1125;  // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}} //
+unorm min10float left1126; snorm min10float right1126; left1126 = right1126;  // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}} //
+unorm min10float left1127; unorm min10float right1127; left1127 = right1127;  // expected-warning {{'min10float' is promoted to 'min16float'}} expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}} //
 
-}
+}

Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 309 - 309
tools/clang/test/HLSL/scalar-operators-exact-precision.hlsl


+ 86 - 86
tools/clang/test/HLSL/scalar-operators.hlsl

@@ -20,9 +20,9 @@ float4 plain(float4 param4 : FOO) : FOO {
     float       floats      = 0;
     double      doubles     = 0;
     min16float  min16floats = 0;
-    min10float  min10floats = 0; // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+    min10float  min10floats = 0; // expected-warning {{'min10float' is promoted to 'min16float'}} fxc-pass {{}}
     min16int    min16ints   = 0;
-    min12int    min12ints   = 0; // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+    min12int    min12ints   = 0; // expected-warning {{'min12int' is promoted to 'min16int'}} fxc-pass {{}}
     min16uint   min16uints  = 0;
 
     // _Static_assert(std::is_same<bool, bool>::value, "bool, bool failed");
@@ -73,9 +73,9 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(bools + floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(bools + doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(bools + min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(bools + min10floats)>::value, ""); // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(bools + min10floats)>::value, ""); // fxc-pass {{}}
   _Static_assert(std::is_same<min16int, __decltype(bools + min16ints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(bools + min12ints)>::value, "");     /* expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+  _Static_assert(std::is_same<min12int, __decltype(bools + min12ints)>::value, "");     /* fxc-pass {{}} */
   _Static_assert(std::is_same<min16uint, __decltype(bools + min16uints)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints + bools)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints + ints)>::value, "");
@@ -84,7 +84,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(ints + floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(ints + doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(ints + min16floats)>::value, "");  /* expected-warning {{conversion from larger type 'int' to smaller type 'min16float', possible loss of data}} fxc-pass {{}} */
-  _Static_assert(std::is_same<min10float, __decltype(ints + min10floats)>::value, "");  // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(ints + min10floats)>::value, "");  // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<int, __decltype(ints + min16ints)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints + min12ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(ints + min16uints)>::value, "");
@@ -95,7 +95,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(uints + floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(uints + doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(uints + min16floats)>::value, ""); /* expected-warning {{conversion from larger type 'uint' to smaller type 'min16float', possible loss of data}} fxc-pass {{}} */
-  _Static_assert(std::is_same<min10float, __decltype(uints + min10floats)>::value, "");  // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(uints + min10floats)>::value, "");  // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<uint, __decltype(uints + min16ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(uints + min12ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(uints + min16uints)>::value, "");
@@ -143,17 +143,17 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<min16float, __decltype(min16floats + min16ints)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min16floats + min12ints)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min16floats + min16uints)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min10floats + bools)>::value, "");  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats + ints)>::value, "");   // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats + uints)>::value, "");  // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats + bools)>::value, "");  // fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats + ints)>::value, "");   // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats + uints)>::value, "");  // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<float, __decltype(min10floats + halfs)>::value, "");
   _Static_assert(std::is_same<float, __decltype(min10floats + floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(min10floats + doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min10floats + min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min10floats + min10floats)>::value, ""); // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats + min16ints)>::value, "");  // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats + min12ints)>::value, "");  // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats + min16uints)>::value, ""); // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats + min10floats)>::value, ""); // fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats + min16ints)>::value, "");  // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats + min12ints)>::value, "");  // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats + min16uints)>::value, ""); // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<min16int, __decltype(min16ints + bools)>::value, "");
   _Static_assert(std::is_same<int, __decltype(min16ints + ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(min16ints + uints)>::value, "");
@@ -161,20 +161,20 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(min16ints + floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(min16ints + doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min16ints + min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min16ints + min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min16ints + min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<min16int, __decltype(min16ints + min16ints)>::value, "");
   _Static_assert(std::is_same<min16int, __decltype(min16ints + min12ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16ints + min16uints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(min12ints + bools)>::value, "");          /* expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+  _Static_assert(std::is_same<min12int, __decltype(min12ints + bools)>::value, "");          /* fxc-pass {{}} */
   _Static_assert(std::is_same<int, __decltype(min12ints + ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(min12ints + uints)>::value, "");
   _Static_assert(std::is_same<float, __decltype(min12ints + halfs)>::value, "");
   _Static_assert(std::is_same<float, __decltype(min12ints + floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(min12ints + doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min12ints + min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min12ints + min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min12ints + min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<min16int, __decltype(min12ints + min16ints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(min12ints + min12ints)>::value, "");    // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints + min12ints)>::value, "");    // fxc-pass {{}}
   _Static_assert(std::is_same<min16uint, __decltype(min12ints + min16uints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints + bools)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(min16uints + ints)>::value, "");
@@ -183,7 +183,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(min16uints + floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(min16uints + doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min16uints + min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min16uints + min10floats)>::value, "");   // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min16uints + min10floats)>::value, "");   // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<min16uint, __decltype(min16uints + min16ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints + min12ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints + min16uints)>::value, "");
@@ -194,9 +194,9 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(bools - floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(bools - doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(bools - min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(bools - min10floats)>::value, "");  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(bools - min10floats)>::value, "");  // fxc-pass {{}}
   _Static_assert(std::is_same<min16int, __decltype(bools - min16ints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(bools - min12ints)>::value, "");      /* expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+  _Static_assert(std::is_same<min12int, __decltype(bools - min12ints)>::value, "");      /* fxc-pass {{}} */
   _Static_assert(std::is_same<min16uint, __decltype(bools - min16uints)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints - bools)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints - ints)>::value, "");
@@ -205,7 +205,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(ints - floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(ints - doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(ints - min16floats)>::value, "");   /* expected-warning {{conversion from larger type 'int' to smaller type 'min16float', possible loss of data}} fxc-pass {{}} */
-  _Static_assert(std::is_same<min10float, __decltype(ints - min10floats)>::value, "");  // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(ints - min10floats)>::value, "");  // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<int, __decltype(ints - min16ints)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints - min12ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(ints - min16uints)>::value, "");
@@ -216,7 +216,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(uints - floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(uints - doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(uints - min16floats)>::value, ""); /* expected-warning {{conversion from larger type 'uint' to smaller type 'min16float', possible loss of data}} fxc-pass {{}} */
-  _Static_assert(std::is_same<min10float, __decltype(uints - min10floats)>::value, "");  // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(uints - min10floats)>::value, "");  // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<uint, __decltype(uints - min16ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(uints - min12ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(uints - min16uints)>::value, "");
@@ -264,17 +264,17 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<min16float, __decltype(min16floats - min16ints)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min16floats - min12ints)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min16floats - min16uints)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min10floats - bools)>::value, "");   // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats - ints)>::value, "");    // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats - uints)>::value, "");   // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats - bools)>::value, "");   // fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats - ints)>::value, "");    // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats - uints)>::value, "");   // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<float, __decltype(min10floats - halfs)>::value, "");
   _Static_assert(std::is_same<float, __decltype(min10floats - floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(min10floats - doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min10floats - min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min10floats - min10floats)>::value, "");  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats - min16ints)>::value, "");    // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats - min12ints)>::value, "");    // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats - min16uints)>::value, "");   // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats - min10floats)>::value, "");  // fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats - min16ints)>::value, "");    // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats - min12ints)>::value, "");    // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats - min16uints)>::value, "");   // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<min16int, __decltype(min16ints - bools)>::value, "");
   _Static_assert(std::is_same<int, __decltype(min16ints - ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(min16ints - uints)>::value, "");
@@ -282,20 +282,20 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(min16ints - floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(min16ints - doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min16ints - min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min16ints - min10floats)>::value, "");   // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min16ints - min10floats)>::value, "");   // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<min16int, __decltype(min16ints - min16ints)>::value, "");
   _Static_assert(std::is_same<min16int, __decltype(min16ints - min12ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16ints - min16uints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(min12ints - bools)>::value, "");           /* expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+  _Static_assert(std::is_same<min12int, __decltype(min12ints - bools)>::value, "");           /* fxc-pass {{}} */
   _Static_assert(std::is_same<int, __decltype(min12ints - ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(min12ints - uints)>::value, "");
   _Static_assert(std::is_same<float, __decltype(min12ints - halfs)>::value, "");
   _Static_assert(std::is_same<float, __decltype(min12ints - floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(min12ints - doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min12ints - min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min12ints - min10floats)>::value, "");   // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min12ints - min10floats)>::value, "");   // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<min16int, __decltype(min12ints - min16ints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(min12ints - min12ints)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints - min12ints)>::value, "");  // fxc-pass {{}}
   _Static_assert(std::is_same<min16uint, __decltype(min12ints - min16uints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints - bools)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(min16uints - ints)>::value, "");
@@ -304,7 +304,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(min16uints - floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(min16uints - doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min16uints - min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min16uints - min10floats)>::value, "");   // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min16uints - min10floats)>::value, "");   // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<min16uint, __decltype(min16uints - min16ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints - min12ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints - min16uints)>::value, "");
@@ -315,9 +315,9 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(bools / floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(bools / doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(bools / min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(bools / min10floats)>::value, "");   // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(bools / min10floats)>::value, "");   // fxc-pass {{}}
   _Static_assert(std::is_same<min16int, __decltype(bools / min16ints)>::value, "");       /* expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} fxc-pass {{}} */
-  _Static_assert(std::is_same<min12int, __decltype(bools / min12ints)>::value, "");       /* expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+  _Static_assert(std::is_same<min12int, __decltype(bools / min12ints)>::value, "");       /* expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} fxc-pass {{}} */
   _Static_assert(std::is_same<min16uint, __decltype(bools / min16uints)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints / bools)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints / ints)>::value, "");
@@ -326,7 +326,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(ints / floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(ints / doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(ints / min16floats)>::value, "");    /* expected-warning {{conversion from larger type 'int' to smaller type 'min16float', possible loss of data}} fxc-pass {{}} */
-  _Static_assert(std::is_same<min10float, __decltype(ints / min10floats)>::value, "");   // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(ints / min10floats)>::value, "");   // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<int, __decltype(ints / min16ints)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints / min12ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(ints / min16uints)>::value, "");
@@ -337,7 +337,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(uints / floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(uints / doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(uints / min16floats)>::value, "");  /* expected-warning {{conversion from larger type 'uint' to smaller type 'min16float', possible loss of data}} fxc-pass {{}} */
-  _Static_assert(std::is_same<min10float, __decltype(uints / min10floats)>::value, "");  // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(uints / min10floats)>::value, "");  // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<uint, __decltype(uints / min16ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(uints / min12ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(uints / min16uints)>::value, "");
@@ -385,17 +385,17 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<min16float, __decltype(min16floats / min16ints)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min16floats / min12ints)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min16floats / min16uints)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min10floats / bools)>::value, "");   // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats / ints)>::value, "");    // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats / uints)>::value, "");   // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats / bools)>::value, "");   // fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats / ints)>::value, "");    // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats / uints)>::value, "");   // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<float, __decltype(min10floats / halfs)>::value, "");
   _Static_assert(std::is_same<float, __decltype(min10floats / floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(min10floats / doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min10floats / min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min10floats / min10floats)>::value, "");  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats / min16ints)>::value, "");    // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats / min12ints)>::value, "");    // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats / min16uints)>::value, "");   // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats / min10floats)>::value, "");  // fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats / min16ints)>::value, "");    // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats / min12ints)>::value, "");    // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats / min16uints)>::value, "");   // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-52): error X3706: signed integer division is not supported on minimum-precision types. Cast to int to use 32-bit division.;compilation failed; no code produced;
   // Note: binary operator promotes bool to int early, so this is an int division, which is legal.
   // TODO: double check fxc behavior for this, since it should be similar
@@ -407,7 +407,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(min16ints / floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(min16ints / doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min16ints / min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min16ints / min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min16ints / min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-56): error X3706: signed integer division is not supported on minimum-precision types. Cast to int to use 32-bit division.;compilation failed; no code produced;
   min16ints = (min16ints / min16ints); // expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} fxc-error {{X3706: signed integer division is not supported on minimum-precision types. Cast to int to use 32-bit division.}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-56): error X3706: signed integer division is not supported on minimum-precision types. Cast to int to use 32-bit division.;compilation failed; no code produced;
@@ -417,14 +417,14 @@ float4 plain(float4 param4 : FOO) : FOO {
   // Note: binary operator promotes bool to int early, so this is an int division, which is legal.
   // TODO: double check fxc behavior for this, since it should be similar
   ints = (min12ints / bools); // expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} fxc-error {{X3706: signed integer division is not supported on minimum-precision types. Cast to int to use 32-bit division.}}
-  _Static_assert(std::is_same<min12int, __decltype(min12ints / bools)>::value, "");    // expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints / bools)>::value, "");    // expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} fxc-pass {{}}
   _Static_assert(std::is_same<int, __decltype(min12ints / ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(min12ints / uints)>::value, "");
   _Static_assert(std::is_same<float, __decltype(min12ints / halfs)>::value, "");
   _Static_assert(std::is_same<float, __decltype(min12ints / floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(min12ints / doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min12ints / min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min12ints / min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min12ints / min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-56): error X3706: signed integer division is not supported on minimum-precision types. Cast to int to use 32-bit division.;compilation failed; no code produced;
   min12ints = (min12ints / min16ints); // expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} expected-warning {{conversion from larger type 'min16int' to smaller type 'min12int', possible loss of data}} fxc-error {{X3706: signed integer division is not supported on minimum-precision types. Cast to int to use 32-bit division.}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-56): error X3706: signed integer division is not supported on minimum-precision types. Cast to int to use 32-bit division.;compilation failed; no code produced;
@@ -437,7 +437,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<float, __decltype(min16uints / floats)>::value, "");
   _Static_assert(std::is_same<double, __decltype(min16uints / doubles)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min16uints / min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min16uints / min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min16uints / min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<min16uint, __decltype(min16uints / min16ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints / min12ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints / min16uints)>::value, "");
@@ -449,9 +449,9 @@ float4 plain(float4 param4 : FOO) : FOO {
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-50): error X3684: modulo cannot be used with doubles, cast to float first;compilation failed; no code produced;
   bools = (bools % doubles); // expected-error {{modulo cannot be used with doubles, cast to float first}} fxc-error {{X3684: modulo cannot be used with doubles, cast to float first}}
   _Static_assert(std::is_same<min16float, __decltype(bools % min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(bools % min10floats)>::value, "");  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(bools % min10floats)>::value, "");  // fxc-pass {{}}
   _Static_assert(std::is_same<min16int, __decltype(bools % min16ints)>::value, "");      /* expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} fxc-pass {{}} */
-  _Static_assert(std::is_same<min12int, __decltype(bools % min12ints)>::value, "");      /* expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+  _Static_assert(std::is_same<min12int, __decltype(bools % min12ints)>::value, "");      /* expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} fxc-pass {{}} */
   _Static_assert(std::is_same<min16uint, __decltype(bools % min16uints)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints % bools)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints % ints)>::value, "");
@@ -461,7 +461,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-49): error X3684: modulo cannot be used with doubles, cast to float first;compilation failed; no code produced;
   ints = (ints % doubles); // expected-error {{modulo cannot be used with doubles, cast to float first}} expected-warning {{conversion from larger type 'double' to smaller type 'int', possible loss of data}} fxc-error {{X3684: modulo cannot be used with doubles, cast to float first}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
   _Static_assert(std::is_same<min16float, __decltype(ints % min16floats)>::value, "");    /* expected-warning {{conversion from larger type 'int' to smaller type 'min16float', possible loss of data}} fxc-pass {{}} */
-  _Static_assert(std::is_same<min10float, __decltype(ints % min10floats)>::value, "");  // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(ints % min10floats)>::value, "");  // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<int, __decltype(ints % min16ints)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints % min12ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(ints % min16uints)>::value, "");
@@ -473,7 +473,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-50): error X3684: modulo cannot be used with doubles, cast to float first;compilation failed; no code produced;
   uints = (uints % doubles); // expected-error {{modulo cannot be used with doubles, cast to float first}} expected-warning {{conversion from larger type 'double' to smaller type 'uint', possible loss of data}} fxc-error {{X3684: modulo cannot be used with doubles, cast to float first}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
   _Static_assert(std::is_same<min16float, __decltype(uints % min16floats)>::value, "");    /* expected-warning {{conversion from larger type 'uint' to smaller type 'min16float', possible loss of data}} fxc-pass {{}} */
-  _Static_assert(std::is_same<min10float, __decltype(uints % min10floats)>::value, "");  // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(uints % min10floats)>::value, "");  // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<uint, __decltype(uints % min16ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(uints % min12ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(uints % min16uints)>::value, "");
@@ -535,18 +535,18 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<min16float, __decltype(min16floats % min16ints)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min16floats % min12ints)>::value, "");
   _Static_assert(std::is_same<min16float, __decltype(min16floats % min16uints)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min10floats % bools)>::value, "");  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats % ints)>::value, "");  // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats % uints)>::value, "");  // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats % bools)>::value, "");  // fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats % ints)>::value, "");  // expected-warning {{conversion from larger type 'int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats % uints)>::value, "");  // expected-warning {{conversion from larger type 'uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<float, __decltype(min10floats % halfs)>::value, "");
   _Static_assert(std::is_same<float, __decltype(min10floats % floats)>::value, "");
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-56): error X3684: modulo cannot be used with doubles, cast to float first;compilation failed; no code produced;
   min10floats = (min10floats % doubles); // expected-error {{modulo cannot be used with doubles, cast to float first}} expected-warning {{conversion from larger type 'double' to smaller type 'min10float', possible loss of data}} fxc-error {{X3684: modulo cannot be used with doubles, cast to float first}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
   _Static_assert(std::is_same<min16float, __decltype(min10floats % min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min10floats % min10floats)>::value, "");  // expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats % min16ints)>::value, "");  // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats % min12ints)>::value, "");  // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
-  _Static_assert(std::is_same<min10float, __decltype(min10floats % min16uints)>::value, "");  // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats % min10floats)>::value, "");  // fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats % min16ints)>::value, "");  // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats % min12ints)>::value, "");  // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min10floats % min16uints)>::value, "");  // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-52): error X3706: signed integer remainder is not supported on minimum-precision types. Cast to int to use 32-bit division.;compilation failed; no code produced;
   // Note: binary operator promotes bool to int early, so this is an int division, which is legal.
   // TODO: double check fxc behavior for this, since it should be similar
@@ -559,7 +559,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-54): error X3684: modulo cannot be used with doubles, cast to float first;compilation failed; no code produced;
   min16ints = (min16ints % doubles); // expected-error {{modulo cannot be used with doubles, cast to float first}} expected-warning {{conversion from larger type 'double' to smaller type 'min16int', possible loss of data}} fxc-error {{X3684: modulo cannot be used with doubles, cast to float first}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
   _Static_assert(std::is_same<min16float, __decltype(min16ints % min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min16ints % min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min16ints % min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min16int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-56): error X3706: signed integer remainder is not supported on minimum-precision types. Cast to int to use 32-bit division.;compilation failed; no code produced;
   min16ints = (min16ints % min16ints); // expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} fxc-error {{X3706: signed integer remainder is not supported on minimum-precision types. Cast to int to use 32-bit division.}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-56): error X3706: signed integer remainder is not supported on minimum-precision types. Cast to int to use 32-bit division.;compilation failed; no code produced;
@@ -569,7 +569,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   // Note: binary operator promotes bool to int early, so this is an int division, which is legal.
   // TODO: double check fxc behavior for this, since it should be similar
   ints = (min12ints % bools); // expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} fxc-error {{X3706: signed integer remainder is not supported on minimum-precision types. Cast to int to use 32-bit division.}}
-  _Static_assert(std::is_same<min12int, __decltype(min12ints % bools)>::value, "");    // expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints % bools)>::value, "");    // expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} fxc-pass {{}}
   _Static_assert(std::is_same<int, __decltype(min12ints % ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(min12ints % uints)>::value, "");
   _Static_assert(std::is_same<float, __decltype(min12ints % halfs)>::value, "");
@@ -577,7 +577,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-54): error X3684: modulo cannot be used with doubles, cast to float first;compilation failed; no code produced;
   min16ints = (min12ints % doubles); // expected-error {{modulo cannot be used with doubles, cast to float first}} expected-warning {{conversion from larger type 'double' to smaller type 'min16int', possible loss of data}} fxc-error {{X3684: modulo cannot be used with doubles, cast to float first}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
   _Static_assert(std::is_same<min16float, __decltype(min12ints % min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min12ints % min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min12ints % min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min12int' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-56): error X3706: signed integer remainder is not supported on minimum-precision types. Cast to int to use 32-bit division.;compilation failed; no code produced;
   min16ints = (min12ints % min16ints); // expected-error {{signed integer division is not supported on minimum-precision types, cast to int to use 32-bit division}} fxc-error {{X3706: signed integer remainder is not supported on minimum-precision types. Cast to int to use 32-bit division.}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-56): error X3706: signed integer remainder is not supported on minimum-precision types. Cast to int to use 32-bit division.;compilation failed; no code produced;
@@ -591,7 +591,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-55): error X3684: modulo cannot be used with doubles, cast to float first;compilation failed; no code produced;
   min16ints = (min16uints % doubles); // expected-error {{modulo cannot be used with doubles, cast to float first}} expected-warning {{conversion from larger type 'double' to smaller type 'min16int', possible loss of data}} fxc-error {{X3684: modulo cannot be used with doubles, cast to float first}} fxc-warning {{X3205: conversion from larger type to smaller, possible loss of data}}
   _Static_assert(std::is_same<min16float, __decltype(min16uints % min16floats)>::value, "");
-  _Static_assert(std::is_same<min10float, __decltype(min16uints % min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} expected-warning {{min10float is promoted to min16float}} fxc-pass {{}}
+  _Static_assert(std::is_same<min10float, __decltype(min16uints % min10floats)>::value, "");  // expected-warning {{conversion from larger type 'min16uint' to smaller type 'min10float', possible loss of data}} fxc-pass {{}}
   _Static_assert(std::is_same<min16uint, __decltype(min16uints % min16ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints % min12ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints % min16uints)>::value, "");
@@ -1495,9 +1495,9 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<min16int, __decltype(min16ints << min16ints)>::value, "");
   _Static_assert(std::is_same<min16int, __decltype(min16ints << min12ints)>::value, "");
   _Static_assert(std::is_same<min16int, __decltype(min16ints << min16uints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(min12ints << bools)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
-  _Static_assert(std::is_same<min12int, __decltype(min12ints << ints)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
-  _Static_assert(std::is_same<min12int, __decltype(min12ints << uints)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints << bools)>::value, "");  // fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints << ints)>::value, "");  // fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints << uints)>::value, "");  // fxc-pass {{}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-53): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-54): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
   min12ints = (min12ints << halfs); // expected-error {{int or unsigned int type required}} fxc-error {{X3082: int or unsigned int type required}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-54): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-55): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
@@ -1508,9 +1508,9 @@ float4 plain(float4 param4 : FOO) : FOO {
   min12ints = (min12ints << min16floats); // expected-error {{int or unsigned int type required}} fxc-error {{X3082: int or unsigned int type required}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-59): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-60): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
   min12ints = (min12ints << min10floats); // expected-error {{int or unsigned int type required}} fxc-error {{X3082: int or unsigned int type required}}
-  _Static_assert(std::is_same<min12int, __decltype(min12ints << min16ints)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
-  _Static_assert(std::is_same<min12int, __decltype(min12ints << min12ints)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
-  _Static_assert(std::is_same<min12int, __decltype(min12ints << min16uints)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints << min16ints)>::value, "");  // fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints << min12ints)>::value, "");  // fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints << min16uints)>::value, "");  // fxc-pass {{}}
   _Static_assert(std::is_same<min16uint, __decltype(min16uints << bools)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints << ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints << uints)>::value, "");
@@ -1701,9 +1701,9 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<min16int, __decltype(min16ints >> min16ints)>::value, "");
   _Static_assert(std::is_same<min16int, __decltype(min16ints >> min12ints)>::value, "");
   _Static_assert(std::is_same<min16int, __decltype(min16ints >> min16uints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(min12ints >> bools)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
-  _Static_assert(std::is_same<min12int, __decltype(min12ints >> ints)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
-  _Static_assert(std::is_same<min12int, __decltype(min12ints >> uints)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints >> bools)>::value, "");  // fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints >> ints)>::value, "");  // fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints >> uints)>::value, "");  // fxc-pass {{}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-53): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-54): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
   min12ints = (min12ints >> halfs); // expected-error {{int or unsigned int type required}} fxc-error {{X3082: int or unsigned int type required}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-54): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-55): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
@@ -1714,9 +1714,9 @@ float4 plain(float4 param4 : FOO) : FOO {
   min12ints = (min12ints >> min16floats); // expected-error {{int or unsigned int type required}} fxc-error {{X3082: int or unsigned int type required}}
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-59): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-60): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
   min12ints = (min12ints >> min10floats); // expected-error {{int or unsigned int type required}} fxc-error {{X3082: int or unsigned int type required}}
-  _Static_assert(std::is_same<min12int, __decltype(min12ints >> min16ints)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
-  _Static_assert(std::is_same<min12int, __decltype(min12ints >> min12ints)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
-  _Static_assert(std::is_same<min12int, __decltype(min12ints >> min16uints)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints >> min16ints)>::value, "");  // fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints >> min12ints)>::value, "");  // fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints >> min16uints)>::value, "");  // fxc-pass {{}}
   _Static_assert(std::is_same<min16uint, __decltype(min16uints >> bools)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints >> ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints >> uints)>::value, "");
@@ -1747,7 +1747,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-54): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-55): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
   bools = (bools & min10floats); // expected-error {{int or unsigned int type required}} fxc-error {{X3082: int or unsigned int type required}}
   _Static_assert(std::is_same<min16int, __decltype(bools & min16ints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(bools & min12ints)>::value, "");    /* expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+  _Static_assert(std::is_same<min12int, __decltype(bools & min12ints)>::value, "");    /* fxc-pass {{}} */
   _Static_assert(std::is_same<min16uint, __decltype(bools & min16uints)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints & bools)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints & ints)>::value, "");
@@ -1907,7 +1907,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<min16int, __decltype(min16ints & min16ints)>::value, "");
   _Static_assert(std::is_same<min16int, __decltype(min16ints & min12ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16ints & min16uints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(min12ints & bools)>::value, "");    /* expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+  _Static_assert(std::is_same<min12int, __decltype(min12ints & bools)>::value, "");    /* fxc-pass {{}} */
   _Static_assert(std::is_same<int, __decltype(min12ints & ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(min12ints & uints)>::value, "");
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-52): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-53): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
@@ -1921,7 +1921,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-58): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-59): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
   min12ints = (min12ints & min10floats); // expected-error {{int or unsigned int type required}} fxc-error {{X3082: int or unsigned int type required}}
   _Static_assert(std::is_same<min16int, __decltype(min12ints & min16ints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(min12ints & min12ints)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints & min12ints)>::value, "");  // fxc-pass {{}}
   _Static_assert(std::is_same<min16uint, __decltype(min12ints & min16uints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints & bools)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(min16uints & ints)>::value, "");
@@ -1953,7 +1953,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-54): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-55): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
   bools = (bools | min10floats); // expected-error {{int or unsigned int type required}} fxc-error {{X3082: int or unsigned int type required}}
   _Static_assert(std::is_same<min16int, __decltype(bools | min16ints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(bools | min12ints)>::value, "");    /* expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+  _Static_assert(std::is_same<min12int, __decltype(bools | min12ints)>::value, "");    /* fxc-pass {{}} */
   _Static_assert(std::is_same<min16uint, __decltype(bools | min16uints)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints | bools)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints | ints)>::value, "");
@@ -2113,7 +2113,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<min16int, __decltype(min16ints | min16ints)>::value, "");
   _Static_assert(std::is_same<min16int, __decltype(min16ints | min12ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16ints | min16uints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(min12ints | bools)>::value, "");    /* expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+  _Static_assert(std::is_same<min12int, __decltype(min12ints | bools)>::value, "");    /* fxc-pass {{}} */
   _Static_assert(std::is_same<int, __decltype(min12ints | ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(min12ints | uints)>::value, "");
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-52): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-53): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
@@ -2127,7 +2127,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-58): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-59): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
   min12ints = (min12ints | min10floats); // expected-error {{int or unsigned int type required}} fxc-error {{X3082: int or unsigned int type required}}
   _Static_assert(std::is_same<min16int, __decltype(min12ints | min16ints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(min12ints | min12ints)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints | min12ints)>::value, "");  // fxc-pass {{}}
   _Static_assert(std::is_same<min16uint, __decltype(min12ints | min16uints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints | bools)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(min16uints | ints)>::value, "");
@@ -2159,7 +2159,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-54): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-55): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
   bools = (bools ^ min10floats); // expected-error {{int or unsigned int type required}} fxc-error {{X3082: int or unsigned int type required}}
   _Static_assert(std::is_same<min16int, __decltype(bools ^ min16ints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(bools ^ min12ints)>::value, "");    /* expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+  _Static_assert(std::is_same<min12int, __decltype(bools ^ min12ints)>::value, "");    /* fxc-pass {{}} */
   _Static_assert(std::is_same<min16uint, __decltype(bools ^ min16uints)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints ^ bools)>::value, "");
   _Static_assert(std::is_same<int, __decltype(ints ^ ints)>::value, "");
@@ -2319,7 +2319,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<min16int, __decltype(min16ints ^ min16ints)>::value, "");
   _Static_assert(std::is_same<min16int, __decltype(min16ints ^ min12ints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16ints ^ min16uints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(min12ints ^ bools)>::value, "");    /* expected-warning {{min12int is promoted to min16int}} fxc-pass {{}} */
+  _Static_assert(std::is_same<min12int, __decltype(min12ints ^ bools)>::value, "");    /* fxc-pass {{}} */
   _Static_assert(std::is_same<int, __decltype(min12ints ^ ints)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(min12ints ^ uints)>::value, "");
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-52): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-53): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
@@ -2333,7 +2333,7 @@ float4 plain(float4 param4 : FOO) : FOO {
   // X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,22-58): error X3082: int or unsigned int type required;X:\temp\Sfbl_grfx_dev_p\x86\chk\operators.js.hlsl(16,12-59): error X3013: 'get_value': no matching 1 parameter function;compilation failed; no code produced
   min12ints = (min12ints ^ min10floats); // expected-error {{int or unsigned int type required}} fxc-error {{X3082: int or unsigned int type required}}
   _Static_assert(std::is_same<min16int, __decltype(min12ints ^ min16ints)>::value, "");
-  _Static_assert(std::is_same<min12int, __decltype(min12ints ^ min12ints)>::value, "");  // expected-warning {{min12int is promoted to min16int}} fxc-pass {{}}
+  _Static_assert(std::is_same<min12int, __decltype(min12ints ^ min12ints)>::value, "");  // fxc-pass {{}}
   _Static_assert(std::is_same<min16uint, __decltype(min12ints ^ min16uints)>::value, "");
   _Static_assert(std::is_same<min16uint, __decltype(min16uints ^ bools)>::value, "");
   _Static_assert(std::is_same<uint, __decltype(min16uints ^ ints)>::value, "");
@@ -2595,4 +2595,4 @@ float4 plain(float4 param4 : FOO) : FOO {
   _Static_assert(std::is_same<bool, __decltype(min16uints || min16uints)>::value, "");
 
   return param4;
-}
+}

+ 2 - 2
tools/clang/test/HLSL/sizeof.hlsl

@@ -25,7 +25,7 @@ void main()
   sizeof 42; // expected-error {{invalid application of 'sizeof' to literal type 'literal int'}}
   sizeof 42.0; // expected-error {{invalid application of 'sizeof' to literal type 'literal float'}}
   sizeof ""; // expected-error {{invalid application of 'sizeof' to non-numeric type 'literal string'}}
-  sizeof(Buffer); // expected-error {{invalid application of 'sizeof' to non-numeric type 'Buffer'}}
+  sizeof(Buffer); // expected-error {{invalid application of 'sizeof' to non-numeric type 'Buffer<vector<float, 4> >'}}
   sizeof(StructWithResource); // expected-error {{invalid application of 'sizeof' to non-numeric type 'StructWithResource'}}
   sizeof(main); // expected-error {{invalid application of 'sizeof' to non-numeric type 'void ()'}}
-}
+}

+ 1 - 1
tools/clang/test/HLSL/vector-conditional.hlsl

@@ -281,4 +281,4 @@ float4 main(float4 v0 : TEXCOORD) : SV_Target
   acc += (b4.x ? a1 : a4)[0];                               /* expected-error {{conditional operator only supports results with numeric scalar, vector, or matrix types.}} fxc-error {{X3020: type mismatch between conditional values}} */
 
   return acc;
-}
+}

+ 4 - 4
tools/clang/test/HLSL/vector-syntax-exact-precision.hlsl

@@ -90,10 +90,10 @@ void vector_out_of_bounds() {
 
 void vector_unsigned() {
    unsigned int4 intvector;
-   unsigned min16int4 min16vector;                          /* expected-warning {{min16int is promoted to int}} fxc-error {{X3085: unsigned can not be used with type}} */
+   unsigned min16int4 min16vector;                          /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-error {{X3085: unsigned can not be used with type}} */
    unsigned int64_t3 int64vector;                           /* fxc-error {{X3000: syntax error: unexpected token 'int64_t3'}} */
    unsigned uint3 uintvector;                               /* fxc-error {{X3085: unsigned can not be used with type}} */
-   unsigned min16uint4 min16uintvector;                     /* expected-warning {{min16uint is promoted to uint}} fxc-error {{X3085: unsigned can not be used with type}} */
+   unsigned min16uint4 min16uintvector;                     /* expected-warning {{'min16uint' is promoted to 'uint16_t'}} fxc-error {{X3085: unsigned can not be used with type}} */
    unsigned uint64_t2 int64uintvector;                      /* fxc-error {{X3000: syntax error: unexpected token 'uint64_t2'}} */
    unsigned dword3 dwordvector; /* fxc-error {{X3000: syntax error: unexpected token 'dword3'}} */
 
@@ -101,8 +101,8 @@ void vector_unsigned() {
    unsigned bool3 boolvector;   /* expected-error {{'bool' cannot be signed or unsigned}} fxc-error {{X3085: unsigned can not be used with type}} */
    unsigned half4 halfvector;   /* expected-error {{'half' cannot be signed or unsigned}} fxc-error {{X3085: unsigned can not be used with type}} */
    unsigned double1 doublevector;                           /* expected-error {{'double' cannot be signed or unsigned}} fxc-error {{X3085: unsigned can not be used with type}} */
-   unsigned min12int2 min12intvector;                       /* expected-error {{'min12int' cannot be signed or unsigned}} expected-warning {{min12int is promoted to int16_t}} fxc-error {{X3085: unsigned can not be used with type}} */
-   unsigned min16float3 min16floatvector;                   /* expected-error {{'min16float' cannot be signed or unsigned}} expected-warning {{min16float is promoted to float16_t}} fxc-error {{X3085: unsigned can not be used with type}} */
+   unsigned min12int2 min12intvector;                       /* expected-error {{'min12int' cannot be signed or unsigned}} expected-warning {{'min12int' is promoted to 'int16_t'}} fxc-error {{X3085: unsigned can not be used with type}} */
+   unsigned min16float3 min16floatvector;                   /* expected-error {{'min16float' cannot be signed or unsigned}} expected-warning {{'min16float' is promoted to 'half'}} fxc-error {{X3085: unsigned can not be used with type}} */
 
    unsigned int16_t1 int16_tvector;                         /* fxc-error {{X3000: syntax error: unexpected token 'int16_t1'}} */
    unsigned int32_t1 int32_tvector;                         /* fxc-error {{X3000: syntax error: unexpected token 'int32_t1'}} */

+ 2 - 2
tools/clang/test/HLSL/vector-syntax.hlsl

@@ -101,7 +101,7 @@ void vector_unsigned() {
    unsigned bool3 boolvector;   /* expected-error {{'bool' cannot be signed or unsigned}} fxc-error {{X3085: unsigned can not be used with type}} */
    unsigned half4 halfvector;   /* expected-error {{'half' cannot be signed or unsigned}} fxc-error {{X3085: unsigned can not be used with type}} */
    unsigned double1 doublevector;                           /* expected-error {{'double' cannot be signed or unsigned}} fxc-error {{X3085: unsigned can not be used with type}} */
-   unsigned min12int2 min12intvector;                       /* expected-error {{'min12int' cannot be signed or unsigned}} expected-warning {{min12int is promoted to min16int}} fxc-error {{X3085: unsigned can not be used with type}} */
+   unsigned min12int2 min12intvector;                       /* expected-error {{'min12int' cannot be signed or unsigned}} expected-warning {{'min12int' is promoted to 'min16int'}} fxc-error {{X3085: unsigned can not be used with type}} */
    unsigned min16float3 min16floatvector;                   /* expected-error {{'min16float' cannot be signed or unsigned}} fxc-error {{X3085: unsigned can not be used with type}} */
 }
 
@@ -180,4 +180,4 @@ float fn() {
 // float4 main(float4 param4 : FOO) : FOO {
 float4 plain(float4 param4 /* : FOO */) /*: FOO */{
   return fn();
-}
+}

+ 2 - 2
tools/clang/test/HLSLFileCheck/hlsl/compile_options/WX.hlsl

@@ -1,7 +1,7 @@
 // RUN: %dxc -E main -T ps_6_0 -WX %s | FileCheck %s
 
-// CHECK: error: min10float is promoted to min16float
+// CHECK: error: 'min10float' is promoted to 'min16float'
 
 float4 main(min10float4 a:A) : SV_Target { // expected-error {{min12int is promoted to min16int}}
   return a;
-}
+}

+ 7 - 2
tools/clang/test/HLSLFileCheck/hlsl/template/DependentWithBuiltinTemplate.hlsl

@@ -64,8 +64,13 @@ void increment(inout T X) {
 #ifdef EPARTIAL
 // EPARTIAL: error: function template partial specialization is not allowed
 template<typename VComp, uint VSize>
-void increment(inout vector<VComp, VSize> X) {
-  X.x += 1;
+void decrement(inout vector<VComp, VSize> X) {
+  X.x -= 1;
+}
+
+template<typename VComp>
+void decrement<VComp, 4>(inout vector<VComp, 4> X) {
+  X.x -= 1;
 }
 #endif
 

+ 29 - 0
tools/clang/test/HLSLFileCheck/hlsl/template/FunctionOverloads.hlsl

@@ -0,0 +1,29 @@
+// RUN: %dxc -T ps_6_6 -E main -HV 2021 -ast-dump %s | FileCheck %s
+
+template <typename T> struct MyTex2D {
+  uint heapId;
+
+  template <typename Arg0> T Load(Arg0 arg0) { return Get().Load(arg0); }
+
+  template <typename Arg0, typename Arg1> T Load(Arg0 arg0, Arg1 arg1) {
+    return Get().Load(arg0, arg1);
+  }
+
+  Texture2D<T> Get() { return (Texture2D<T>)ResourceDescriptorHeap[heapId]; }
+};
+
+cbuffer constantBuffer : register(b0) { MyTex2D<float4> tex; };
+
+float4 main() : SV_Target {
+  float4 output = tex.Load(int3(0, 0, 0));
+  return output;
+}
+
+// CHECK:      FunctionTemplateDecl {{0x[0-9a-fA-F]+}} <line:6:3, col:73> col:30 Load
+// CHECK-NEXT: TemplateTypeParmDecl {{0x[0-9a-fA-F]+}} <col:13, col:22> col:22 referenced typename Arg0
+// CHECK-NEXT: CXXMethodDecl {{0x[0-9a-fA-F]+}} <col:28, col:73> col:30 Load 'T (Arg0)'
+
+// CHECK:      FunctionTemplateDecl {{0x[0-9a-fA-F]+}} <line:8:3, line:10:3> line:8:45 Load
+// CHECK-NEXT: TemplateTypeParmDecl {{0x[0-9a-fA-F]+}} <col:13, col:22> col:22 referenced typename Arg0
+// CHECK-NEXT: TemplateTypeParmDecl {{0x[0-9a-fA-F]+}} <col:28, col:37> col:37 referenced typename Arg1
+// CHECK-NEXT: CXXMethodDecl {{0x[0-9a-fA-F]+}} <col:43, line:10:3> line:8:45 Load 'T (Arg0, Arg1)'

+ 11 - 0
tools/clang/test/HLSLFileCheck/hlsl/template/OmitDefaulted.hlsl

@@ -0,0 +1,11 @@
+// RUN: %dxc -E main -T ps_6_0 %s -ast-dump | FileCheck %s
+
+// CHECK: VarDecl {{0x[0-9a-fA-F]+}} {{<.*>}} col:14 used Tex 'Texture2D<vector<float, 4> >'
+
+Texture2D    Tex;
+SamplerState Samp;
+
+float4 main(uint val : A) : SV_Target
+{
+  return Tex.Sample(Samp, float2(0.1, 0.2));
+}

+ 2 - 2
tools/clang/test/HLSLFileCheck/hlsl/template/complete-array-parameter.hlsl

@@ -4,5 +4,5 @@ float4 Val(Texture2D f[2]) {
   return float4(0,0,0,0);
 }
 
-// CHECK: FunctionDecl 0x{{[0-9a-fA-F]+}} <{{.*}}, line:5:1> line:3:8 Val 'float4 (Texture2D [2])'
-// CHECK-NEXT: ParmVarDecl 0x{{[0-9a-fA-F]+}} <col:12, col:25> col:22 f 'Texture2D [2]'
+// CHECK: FunctionDecl 0x{{[0-9a-fA-F]+}} <{{.*}}, line:5:1> line:3:8 Val 'float4 (Texture2D<vector<float, 4> > [2])'
+// CHECK-NEXT: ParmVarDecl 0x{{[0-9a-fA-F]+}} <col:12, col:25> col:22 f 'Texture2D<vector<float, 4> > [2]'

+ 1 - 0
tools/clang/tools/libclang/dxcrewriteunused.cpp

@@ -1109,6 +1109,7 @@ HRESULT DoSimpleReWrite(_In_ DxcLangExtensionsHelper *pHelper,
   }
 
   PrintingPolicy p = PrintingPolicy(C.getPrintingPolicy());
+  p.HLSLOmitDefaultTemplateParams = 1;
   p.Indentation = 1;
 
   if (entryFnDecl) {

Daži faili netika attēloti, jo izmaiņu fails ir pārāk liels