FailedChanges

Changes from Git (git http://labmaster3.local/git/llvm-project.git)

Summary

  1. [NFC][ScalarEvolution] Add a test showing SCEV failure to recognize 'urem' (details)
  2. [libc] This commit fixes the strcmp fuzzing test. It uses a single input and (details)
  3. [X86] Explicitly add popcnt feature to Intel CPUs with SSE4.2 in the frontend. (details)
Commit 25521150d7b577f6f1b402826f2afbb0ec5fb59b by lebedev.ri
[NFC][ScalarEvolution] Add a test showing SCEV failure to recognize 'urem'

While InstCombine trivially converts that `srem` into a `urem`,
it might happen later than wanted. SCEV should recognize this natively.
The file was addedllvm/test/Analysis/ScalarEvolution/srem.ll
Commit b07feef8736d52e11c41631d3813a57a3b3ce6e5 by gyurgyikcp
[libc] This commit fixes the strcmp fuzzing test. It uses a single input and
splits it into two by using the value of the first byte to determine the
length of the first string. Reviewed-by: PaulkaToast, Differential
Revision: https://reviews.llvm.org/D82427

Summary:
[libc] Since only one input is given, it is necessary to split the string into two containers so that they can be compared for the purposes of this fuzz test. This is done in the following manner:

1. Take the value of the first byte; this is size1. (Credits to @PaulkaToast for this idea).
2. size2 is the value of size - size1.
3. Copy the characters to new containers, data1 and data2 with corresponding sizes.
4. Add a null terminator to the first container, and verify the second container has a null terminator.
5. Verify output of strcmp.

A simpler alternative considered was simply splitting the input data into two, but this means the two strings are always within +- 1 character of each other. This above implementation avoids this.

ninja check-libc was run; no issues.

Reviewers: PaulkaToast, sivachandra

Reviewed By: PaulkaToast

Subscribers: mgorny, tschuett, ecnelises, libc-commits, PaulkaToast

Tags: #libc-project

Differential Revision: https://reviews.llvm.org/D82427
The file was modifiedlibc/fuzzing/string/strcmp_fuzz.cpp
The file was modifiedlibc/fuzzing/string/CMakeLists.txt
Commit 20a60f46f505fc790e126b8b860c689870355f36 by craig.topper
[X86] Explicitly add popcnt feature to Intel CPUs with SSE4.2 in the frontend.

Previously we inferred it if sse4.2 ended up being enabled after
all feature processing. But writing -march=nehalem -mno-sse4.2
should have popcnt enabled.
The file was modifiedclang/lib/Basic/Targets/X86.cpp
The file was modifiedclang/test/Preprocessor/x86_target_features.c