This patch is to fix some missing lax-vector-conversion warnings including
cases that involve vector bool and vector pixel, also to fix the vector
compatibility check for the warnings.
Details
- Reviewers
nemanjai amyk - Group Reviewers
Restricted Project - Commits
- rG02a71b05fc67: [PowerPC] Include vector bool and pixel when emitting lax warning
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
clang/lib/Sema/SemaExpr.cpp | ||
---|---|---|
9845 | areCompatibleVectorTypes is defined in lib/AST/ASTContext.cpp, it considers all vectors with the same unqualified types to be compatible, also vectors with the same number of elements where neither of them is vector bool/pixel or some specific SVE types are compatible. |
We may also need an associated test case for the changed behaviour for using areCompatibleVectorTypes() instead of areSameVectorElemTypes().
The test coverage should display when warnings are emitted now that we account for vector bool, vector pixel and type qualifiers.
clang/lib/Sema/SemaExpr.cpp | ||
---|---|---|
9861 | Is there test coverage for these addition to the if condition? |
Might be a silly question, but what does it mean to be a "compatible" vector type?