Commit Graph

34 Commits

Author SHA1 Message Date
0c19f895d3 Replace remaining uses of zlib crc32 with Common/Hash.h 2022-01-01 10:36:38 -08:00
2652aed85c Common: Merge CRC32.h into Hash.h
This makes it easier to find the relevant functions.
2022-01-01 10:36:38 -08:00
e149ad4f0a treewide: convert GPLv2+ license info to SPDX tags
SPDX standardizes how source code conveys its copyright and licensing
information. See https://spdx.github.io/spdx-spec/1-rationale/ . SPDX
tags are adopted in many large projects, including things like the Linux
kernel.
2021-07-05 04:35:56 +02:00
82f1e6204d Fix -Wsign-compare warnings 2020-11-21 02:08:09 +01:00
59dc7cfe7d Use size_t in some DSP code code 2020-07-24 15:06:39 -07:00
213a9adcff CMake: Fix building ARM64 on Windows 2020-02-12 12:29:31 +01:00
d744c5a148 Compile fixes for Windows-on-ARM64 2019-12-28 19:20:41 +10:00
011ee110bc Common/Hash: Namespace code under the Common namespace
Brings more common code under the Common namespace.
2018-05-16 15:39:23 -04:00
c3483a1823 CommonFuncs: Generify rotation functions and move them to BitUtils.h
These are bit manipulation functions, so they belong within BitUtils.

This also gets rid of duplicated code and avoids relying on compiler
reserved names existing or not existing to determine whether or not we
define a set of functions.

Optimizers are smart enough in GCC and clang to transform the code to a
ROR or ROL instruction in the respective functions.
2018-03-31 18:09:45 -04:00
a5a0599145 CustomTexture: Drop old texture format. 2018-01-20 17:08:47 +01:00
3a13e1aa7a Common/Hash: small cleanup 2017-05-03 06:40:52 +01:00
25f61f0329 Common/Hash: use __crc32d() intrinsic on ARM64 2017-05-03 06:40:47 +01:00
0f978227f5 Common: Use function-level targeting for CRC32 (SSE4.2) 2017-01-24 20:04:55 +10:00
3570c7f03a Reformat all the things. Have fun with merge conflicts. 2016-06-24 10:43:46 +02:00
4b06e92731 A few more asterisks, mostly casts 2016-01-21 22:20:22 +01:00
3e283ea9f1 More asterisks 2016-01-21 21:16:51 +01:00
1fc1f00162 Include cstring in Hash.cpp to fix building without PCH 2015-10-06 14:59:56 +02:00
310bb46967 Hash: Narrow define scope 2015-08-29 02:57:35 -04:00
ffe085f5ea [AArch64] Implement CRC32 texture hashing.
In a particular hashing heavy scene in Crazy Taxi the Murmur3 hash used 3.11% CPU time.
The new CRC32 hash in the same scene used 1.86%
This was tested on a Nvidia SHIELD Android TV with Cortex-A57s.

This will be a bit slower on the Nexus 9, the Denver CPU core is a bit slower with CRC32 texture hashing than Murmur3 texture hashing.
2015-06-08 19:16:50 -05:00
30ebb2459e Set copyright year to when a file was created 2015-05-25 13:22:31 +02:00
cefcb0ace9 Update license headers to GPLv2+ 2015-05-25 13:22:31 +02:00
93b16a4a2d Formatting/Whitespace Cleanup
Various fixes to formatting and whitespace
2015-02-25 10:48:21 -05:00
f298f00e1b Clean up the intrinsics #ifdef mess 2015-02-24 01:02:36 +01:00
f6c9b8243e GetCRC32: Fix the hash for the last byte(s)
This fixes issue 8227
https://code.google.com/p/dolphin-emu/issues/detail?id=8227
2015-02-18 14:26:28 +01:00
1c388b6c37 Fix clang on x86_64.
If we are compiling in the CRC32 hash, clang has an issue with casting a s32 to a u64.
Change our lens argument to a unsigned integer to fix the issue.
2015-01-29 01:55:20 -06:00
c6dd5044d6 VideoCommon: make hash independet from hires textures 2014-12-29 10:24:27 +01:00
d2e004fa9e Use CRC to output 64 bits instead of 32
A bit hacky, but should dramatically reduce the odds of hash collision.
2014-10-18 00:24:35 -07:00
15a4bccb73 Hash: unroll CRC loop, since CRC32 typically has nontrivial latency
Seems to be about 20-30% faster texture cache hashing on my machine.
2014-10-17 15:39:08 -07:00
46057db37d Fix build failing when disabling precompiled headers. 2014-09-19 18:17:51 -04:00
49b0eef393 Remove the min/max functions in CommonFuncs.
The algorithm header has the same functions.
2014-05-29 21:44:41 -04:00
31cfc73a09 Fixes spacing for "for", "while", "switch" and "if"
Also moved && and || to ends of lines instead of start.
Fixed misc vertical alignments and some { needed newlining.
2014-03-11 00:35:07 +13:00
4f02132f93 Make our architecture defines less stupid.
Our defines were never clear between what meant 64bit or x86_64
This makes a clear cut between bitness and architecture.
This commit also has the side effect of bringing up aarch64 compiling support.
2014-03-04 09:36:59 -06:00
2afe215271 Convert all includes to relative paths. 2014-02-18 02:19:10 -05:00
34692ab826 Remove unnecessary Src/ folders 2013-12-31 14:03:19 -05:00