Browse Source

dont look for immintrin on GCC pre-4.4. Also dont build with -maes; need to autoconfig other flags

master
Michael Hamburg 7 years ago
parent
commit
5717005809
5 changed files with 9 additions and 11 deletions
  1. +1
    -1
      Makefile
  2. +1
    -3
      src/GENERATED/include/decaf/ed255.hxx
  3. +1
    -3
      src/GENERATED/include/decaf/ed448.hxx
  4. +5
    -1
      src/include/word.h
  5. +1
    -3
      src/per_curve/eddsa.tmpl.hxx

+ 1
- 1
Makefile View File

@@ -50,7 +50,7 @@ endif
TODAY = $(shell date "+%Y-%m-%d")

#FIXME ARCHFLAGS
ARCHFLAGS ?= -maes -mavx2 -mbmi2 #TODO
ARCHFLAGS ?= -mavx2 -mbmi2 #TODO

ifeq ($(CC),clang)
WARNFLAGS_C += -Wgcc-compat


+ 1
- 3
src/GENERATED/include/decaf/ed255.hxx View File

@@ -149,9 +149,7 @@ public:
inline SecureBuffer sign (
const Block &message,
const Block &context = NO_CONTEXT()
) const /* TODO: this exn spec tickles a Clang bug?
* throw(LengthException, std::bad_alloc)
*/ {
) const /* throw(LengthException, std::bad_alloc) */ {
if (context.size() > 255) {
throw LengthException();
}


+ 1
- 3
src/GENERATED/include/decaf/ed448.hxx View File

@@ -149,9 +149,7 @@ public:
inline SecureBuffer sign (
const Block &message,
const Block &context = NO_CONTEXT()
) const /* TODO: this exn spec tickles a Clang bug?
* throw(LengthException, std::bad_alloc)
*/ {
) const /* throw(LengthException, std::bad_alloc) */ {
if (context.size() > 255) {
throw LengthException();
}


+ 5
- 1
src/include/word.h View File

@@ -36,7 +36,11 @@ extern int posix_memalign(void **, size_t, size_t);
#if defined(__ARM_NEON__)
#include <arm_neon.h>
#elif defined(__SSE2__)
#include <immintrin.h>
#if !defined(__GNUC__) || __clang__ || __GNUC__ >= 5 || (__GNUC__==4 && __GNUC_MINOR__ >= 4)
#include <immintrin.h>
#else
#include <emmintrin.h>
#endif
#endif

#if (ARCH_WORD_BITS == 64)


+ 1
- 3
src/per_curve/eddsa.tmpl.hxx View File

@@ -133,9 +133,7 @@ public:
inline SecureBuffer sign (
const Block &message,
const Block &context = NO_CONTEXT()
) const /* TODO: this exn spec tickles a Clang bug?
* throw(LengthException, std::bad_alloc)
*/ {
) const /* throw(LengthException, std::bad_alloc) */ {
if (context.size() > 255) {
throw LengthException();
}


Loading…
Cancel
Save