SuccessChanges

Summary

  1. [ValueTracking] Add more known non zero tests (NFC) (details)
  2. [ValueTracking] Handle more non-trivial conditions in isKnownNonZero() (details)
  3. [clang-format] PR48569 clang-format fails to align case label with `switch` with Whitesmith Indentation (details)
Commit e8c7e7cdbbb12a485999a8b9d69e7138b3f34845 by nikita.ppv
[ValueTracking] Add more known non zero tests (NFC)

Add tests for non-trivial conditions that imply non-zero on the
false branch rather than the true branch.

The last case already folds due to canonicalization.
The file was modifiedllvm/test/Transforms/InstCombine/known-non-zero.ll
Commit b21840751278128ef6942074ae89ea63c9c6ac58 by nikita.ppv
[ValueTracking] Handle more non-trivial conditions in isKnownNonZero()

In 35676a4f9a536a2aab768af63ddbb15bc722d7f9 I've added handling for
non-trivial dominating conditions that imply non-zero on the true
branch. This adds the same support for the false branch.

The changes in pr45360.ll change block ordering and naming, but
don't change the control flow. The urem is still guaraded by a
non-zero check correctly.
The file was modifiedllvm/lib/Analysis/ValueTracking.cpp
The file was modifiedllvm/test/Transforms/IndVarSimplify/X86/pr45360.ll
The file was modifiedllvm/test/Transforms/InstCombine/known-non-zero.ll
Commit c7dcc4c72588db9ffb7ae379983450193b943f5b by mydeveloperday
[clang-format] PR48569 clang-format fails to align case label with `switch` with Whitesmith Indentation

https://bugs.llvm.org/show_bug.cgi?id=48569

This is a tentative fix which addresses a PR raise regarding Case indentation when working with Whitesmiths Indentation

I could not find online any reference sources as to what the case indentation for Whitesmith's should be (or be allowed to be)

But according to the documentation, we don't obey the rules for Whitesmith's

```
In particular, the documentation states that this option is to "indent case labels one level from the switch statement. When false, use the same indentation level as for the switch statement."
```

The behaviour we add here is actually as the TODO in the tests used to state in {D67627}, but when {D82016} was added and I brought these tests out from being TODO I realized I changed the indentation.

Reviewed By: curdeius, HazardyKnusperkeks

Differential Revision: https://reviews.llvm.org/D93806
The file was modifiedclang/lib/Format/UnwrappedLineParser.cpp
The file was modifiedclang/unittests/Format/FormatTest.cpp