| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It works on x86, but C says it is undefined and it makes UBSan
unhappy. Happily, this memcpy approach probably also works fine under
processors which previously used the byte-at-a-time approach such as
ARM. But for right now using memcpy here is still gated under the
processor alignment flags.
In my tests recent GCC and Clang seemed to produce basically identical
code for either approach when using -O3; I imagine most compilers
these days are very good at analyzing/inlining/unrolling memcpys.
Also remove the manually unrolled versions of xor_buf, which caused
problems with GCC and -O3 due to it vectorizing the loads into
(aligned) SSE2 loads, which would fail when a misaligned pointer was
passed. Which always seemed kind of bogus to me, but I guess that's
what undefined behavior is for. Enable -O3 for GCC.
With this change the test suite is clean under GCC ASan+UBSan and
Clang ASan+UBSan, with the exception of one failure due to a bug in
libstdc++ (GCC bug 60734) when compiled by Clang.
|
|
|
|
| |
GH #382
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously a build had optimizations disabled completely when debug info was
emitted. But there are many reasons to use optimized builds with debug symbols
(running under valgrind, against afl, with Asan/Ubsan, in prod, etc).
And personally I find even debugging at -O2 or -O3 is fine most of the time and
worth it for the speed. Use the (now documented!) --no-optimizations flag if no
optimization is desired while debugging.
This also removes the distinction between library and application compile flags;
there is a single optimization level that is probably good enough for everything.
On Win32 it removes definding _CONSOLE for the application. This seems to be
some mythical value that may have been required at some point, but is not
documented anywhere I can find. Who knows what VC thinks, hoping I don't have to
add this back. It also drops defining `EBUG` which is what happens when you
tell cl.exe to '/DEBUG'. LOL.
|
|
|
|
| |
See also -march in https://gcc.gnu.org/onlinedocs/gcc/ARM-Options.html
|
|
|
|
|
|
|
| |
On Darwin platforms, there are frameworks that can bundle libraries and
header files in a standardized directory structure. We need to support
linking to them because most of the OS X or iOS-specific APIs are
provided as frameworks.
|
|
|
|
| |
Fixes #241
|
|
|
|
| |
Fixes #250
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
/FS is needed for parallel builds
/bigobj is needed for amalgamation build. Remove explicit setting from
appveyor
/DEBUG is a parameter, not a precompiler constant
Conflicts:
src/build-data/cc/msvc.txt
|
|
|
|
|
|
| |
This commit aims to preserve all settings. In some cases it will drop
optimization flags and fall back to compiler's defaults in the new debug
mode.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
amalgamation objects (aes_ni and clmul). The real advantage is
for the static link, as GCM will pull in clmul via its reference,
which is sufficient to also pull the AES impl into the link.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Convert all uses of Algorithm_Factory and the engines to using Algo_Registry
The shared pool of entropy sources remains but is moved to EntropySource.
With that and few remaining initializations (default OIDs and aliases)
moved elsewhere, the global state is empty and init and shutdown are no-ops.
Remove almost all of the headers and code for handling the global
state, except LibraryInitializer which remains as a compatability stub.
Update seeding for blinding so only one hacky almost-global RNG
instance needs to be setup instead of across all pubkey uses (it uses
either the system RNG or an AutoSeeded_RNG if the system RNG is not
available).
|
|
|
|
| |
Github issue 34
|
| |
|
|
|
|
| |
causes problems when it converts unaligned loads to aligned SSE loads.
|
| |
|
|
|
|
|
| |
to work around weird MSVC limitations in 32-bit mode, but maybe useful
elsewhere someday. Github #11.
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
rather than causing the whole build to fail. Also mark MSVC as supporting
intrinsics (except AVX2 which seemingly is not yet supported). Github issue 7.
|
|
|
|
| |
Bug 264
|
| |
|
|
|
|
| |
non-release builds now
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
in on platforms/configs I don't test regularly, and that shouldn't
break end-user builds.
|
| |
|
|
|
|
| |
Fix a few nullptr and cast warnings.
|
|
|
|
|
|
|
|
|
|
|
| |
compiler and target platform might support it. For instance the AES
SSSE3 code is now always in any x86 build, with just that specific
file being compiled with -mssse3. Since we'll only call that code if
cpuid confirms it works at runtime, we don't have portability issues,
and it can be safely included in generic builds (eg for distributions).
Tweak how machine specific compiler flags are generated to be a bit
easier to maintain.
|