mirror of
https://chromium.googlesource.com/libyuv/libyuv
synced 2026-01-01 03:12:16 +08:00
Detect asimd as same as Neon for Arm features. Used on Juno aarch64 linux.
BUG=361 TESTED=.\libyuv_unittest --gtest_filter=libyuvTest.TestLinuxNeon R=tpsiaki@google.com Review URL: https://webrtc-codereview.appspot.com/31439004 git-svn-id: http://libyuv.googlecode.com/svn/trunk@1088 16f28f9a-4ce2-e073-06de-1de4eb20be90
This commit is contained in:
parent
9e430982a1
commit
c52d66d7da
@ -1,6 +1,6 @@
|
||||
Name: libyuv
|
||||
URL: http://code.google.com/p/libyuv/
|
||||
Version: 1086
|
||||
Version: 1088
|
||||
License: BSD
|
||||
License File: LICENSE
|
||||
|
||||
|
||||
@ -11,6 +11,6 @@
|
||||
#ifndef INCLUDE_LIBYUV_VERSION_H_ // NOLINT
|
||||
#define INCLUDE_LIBYUV_VERSION_H_
|
||||
|
||||
#define LIBYUV_VERSION 1086
|
||||
#define LIBYUV_VERSION 1088
|
||||
|
||||
#endif // INCLUDE_LIBYUV_VERSION_H_ NOLINT
|
||||
|
||||
@ -135,6 +135,12 @@ int ArmCpuCaps(const char* cpuinfo_name) {
|
||||
fclose(f);
|
||||
return kCpuHasNEON;
|
||||
}
|
||||
// aarch64 uses asimd for Neon.
|
||||
p = strstr(cpuinfo_line, " asimd");
|
||||
if (p && (p[6] == ' ' || p[6] == '\n')) {
|
||||
fclose(f);
|
||||
return kCpuHasNEON;
|
||||
}
|
||||
}
|
||||
}
|
||||
fclose(f);
|
||||
|
||||
@ -126,6 +126,7 @@ TEST_F(libyuvTest, TestLinuxNeon) {
|
||||
if (FileExists("../../unit_test/testdata/arm_v7.txt")) {
|
||||
EXPECT_EQ(0, ArmCpuCaps("../../unit_test/testdata/arm_v7.txt"));
|
||||
EXPECT_EQ(kCpuHasNEON, ArmCpuCaps("../../unit_test/testdata/tegra3.txt"));
|
||||
EXPECT_EQ(kCpuHasNEON, ArmCpuCaps("../../unit_test/testdata/juno.txt"));
|
||||
} else {
|
||||
printf("WARNING: unable to load \"../../unit_test/testdata/arm_v7.txt\"\n");
|
||||
}
|
||||
|
||||
15
unit_test/testdata/juno.txt
vendored
Normal file
15
unit_test/testdata/juno.txt
vendored
Normal file
@ -0,0 +1,15 @@
|
||||
Processor : AArch64 Processor rev 0 (aarch64)
|
||||
processor : 0
|
||||
processor : 1
|
||||
processor : 2
|
||||
processor : 3
|
||||
processor : 4
|
||||
processor : 5
|
||||
Features : fp asimd evtstrm aes pmull sha1 sha2 crc32
|
||||
CPU implementer : 0x41
|
||||
CPU architecture: AArch64
|
||||
CPU variant : 0x0
|
||||
CPU part : 0xd07
|
||||
CPU revision : 0
|
||||
|
||||
Hardware : Juno
|
||||
Loading…
x
Reference in New Issue
Block a user