Skip to content

Commit

Permalink
Revert r301487: Replace HashString algorithm with xxHash64
Browse files Browse the repository at this point in the history
This reverts commit r301487 to make buildbots green.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@301491 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
rui314 committed Apr 26, 2017
1 parent 3670d2e commit 4deadfa
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 15 deletions.
9 changes: 3 additions & 6 deletions test/CodeGen/target-features-error-2.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// RUN: %clang_cc1 %s -triple=x86_64-linux-gnu -S -verify -o - -D NEED_SSE41
// RUN: %clang_cc1 %s -triple=x86_64-linux-gnu -S -verify -o - -D NEED_SSE42
// RUN: %clang_cc1 %s -triple=x86_64-linux-gnu -S -verify -o - -D NEED_AVX_1
// RUN: %clang_cc1 %s -triple=x86_64-linux-gnu -S -verify -o - -D NEED_AVX_2
// RUN: %clang_cc1 %s -triple=x86_64-linux-gnu -S -verify -o - -D NEED_AVX_3
Expand All @@ -7,12 +7,9 @@
#define __MM_MALLOC_H
#include <x86intrin.h>

// Really, this needs AVX, but because targetting AVX includes all the SSE features too, and
// features are sorted by hash function, and we just return the first missing feature, then we end
// up returning the subfeature sse4.1 instead of avx.
#if NEED_SSE41
#if NEED_SSE42
int baz(__m256i a) {
return _mm256_extract_epi32(a, 3); // expected-error {{always_inline function '_mm256_extract_epi32' requires target feature 'sse4.1', but would be inlined into function 'baz' that is compiled without support for 'sse4.1'}}
return _mm256_extract_epi32(a, 3); // expected-error {{always_inline function '_mm256_extract_epi32' requires target feature 'sse4.2', but would be inlined into function 'baz' that is compiled without support for 'sse4.2'}}
}
#endif

Expand Down
3 changes: 2 additions & 1 deletion test/CodeGen/target-features-error.c
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@ int __attribute__((target("avx"), always_inline)) foo(int a) {
return a + 4;
}
int bar() {
return foo(4); // expected-error {{always_inline function 'foo' requires target feature 'sse4.1', but would be inlined into function 'bar' that is compiled without support for 'sse4.1'}}
return foo(4); // expected-error {{always_inline function 'foo' requires target feature 'sse4.2', but would be inlined into function 'bar' that is compiled without support for 'sse4.2'}}
}

7 changes: 1 addition & 6 deletions test/SemaCXX/typo-correction-delayed.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ void testNoCandidates() {
}

class string {};

struct Item {
void Nest();
string text();
Expand Down Expand Up @@ -89,16 +88,12 @@ void f(LinkedNode *node) {
struct NestedNode {
NestedNode* Nest();
NestedNode* next();
// Note, this test is dependent on the order in which identifiers are passed
// to the typo corrector, which is based on the hash function used. For
// consistency, I am making the next keyword the first identifier returned.
string eext() const;
string text() const;
};
void f(NestedNode *node) {
// There are two equidistant, usable corrections for Next: next and Nest
NestedNode *next = node->Next(); // expected-error-re {{no member named 'Next' in 'initializerCorrections::NestedNode'{{$}}}}
}

}

namespace PR21669 {
Expand Down
4 changes: 2 additions & 2 deletions unittests/Tooling/CompilationDatabaseTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,10 @@ TEST(JSONCompilationDatabase, GetAllFiles) {

std::vector<std::string> expected_files;
SmallString<16> PathStorage;
llvm::sys::path::native("//net/dir/file2", PathStorage);
expected_files.push_back(PathStorage.str());
llvm::sys::path::native("//net/dir/file1", PathStorage);
expected_files.push_back(PathStorage.str());
llvm::sys::path::native("//net/dir/file2", PathStorage);
expected_files.push_back(PathStorage.str());
EXPECT_EQ(expected_files,
getAllFiles("[{\"directory\":\"//net/dir\","
"\"command\":\"command\","
Expand Down

0 comments on commit 4deadfa

Please sign in to comment.