Cache keys must be guaranteed to have no uninitialized bits so that they can be compared with memcmpy() and hash values can be computed from their raw memory representation. We do this by calling memset(this, ...) in the Memset<T> class used as the first base class. This is safe since no other constructor has run yet (similar to doing placement new in zeroed out memory). GCC 8.2's class-memset warning should thus not be treated as an error. Bug: b/135744933 Bug: b/134932616 Change-Id: I378b663281b1737359330c29c8c73934e7dd20f7 Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/33368Tested-by:Nicolas Capens <nicolascapens@google.com> Kokoro-Presubmit: kokoro <noreply+kokoro@google.com> Reviewed-by:
Alexis Hétu <sugoi@google.com>
| Name |
Last commit
|
Last update |
|---|---|---|
| .vscode | Loading commit data... | |
| build | Loading commit data... | |
| build_overrides | Loading commit data... | |
| docs | Loading commit data... | |
| extensions | Loading commit data... | |
| include | Loading commit data... | |
| src | Loading commit data... | |
| tests | Loading commit data... | |
| third_party | Loading commit data... | |
| .dir-locals.el | Loading commit data... | |
| .gitignore | Loading commit data... | |
| .gitmodules | Loading commit data... | |
| .travis.yml | Loading commit data... | |
| AUTHORS.txt | Loading commit data... | |
| Android.bp | Loading commit data... | |
| Android.mk | Loading commit data... | |
| BUILD.gn | Loading commit data... | |
| CMakeLists.txt | Loading commit data... | |
| CONTRIBUTING.txt | Loading commit data... | |
| CONTRIBUTORS.txt | Loading commit data... | |
| LICENSE.txt | Loading commit data... | |
| OWNERS | Loading commit data... | |
| README.md | Loading commit data... | |
| SwiftShader.sln | Loading commit data... |