From 483c4abb3fd401e8ce969fe025095ba9c739b93d Mon Sep 17 00:00:00 2001 From: Leo Yuriev Date: Wed, 14 Mar 2018 14:57:46 +0300 Subject: [PATCH] mdbx: remove Elbrus's alignment_reduction_ignored workaround. --- Makefile | 8 -------- src/bits.h | 4 +++- 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/Makefile b/Makefile index c434dbdd..44601a17 100644 --- a/Makefile +++ b/Makefile @@ -26,14 +26,6 @@ CXX ?= g++ XCFLAGS ?= -DNDEBUG=1 -DMDBX_DEBUG=0 -DLIBMDBX_EXPORTS=1 CFLAGS ?= -O2 -g3 -Wall -Werror -Wextra -ffunction-sections -fPIC -fvisibility=hidden CFLAGS += -D_GNU_SOURCE=1 -std=gnu11 -pthread $(XCFLAGS) - -# temporary workaround for lcc's bug -TARGET_ARCH_e2k = $(shell (export LC_ALL=C; ($(CC) --version 2>&1; $(CC) -v 2>&1) | grep -q -i 'e2k' && echo yes || echo no)) -ifeq ($(TARGET_ARCH_e2k),yes) -TARGET_ARCH := e2k -CFLAGS += -mtune=native -Wno-alignment-reduction-ignored -endif - CXXFLAGS = -std=c++11 $(filter-out -std=gnu11,$(CFLAGS)) TESTDB ?= $(shell [ -d /dev/shm ] && echo /dev/shm || echo /tmp)/mdbx-check.db TESTLOG ?= $(shell [ -d /dev/shm ] && echo /dev/shm || echo /tmp)/mdbx-check.log diff --git a/src/bits.h b/src/bits.h index b22167c3..ceabe608 100644 --- a/src/bits.h +++ b/src/bits.h @@ -99,7 +99,9 @@ #endif /* -Wconstant-logical-operand */ #if __has_warning("-Walignment-reduction-ignored") || defined(__e2k__) || defined(__ICC) -#if defined(__ICC) +#if defined(__LCC__) +#pragma diag_suppress alignment_reduction_ignored +#elif defined(__ICC) #pragma warning(disable: 3453 1366) #elif defined(__clang__) #pragma clang diagnostic ignored "-Walignment-reduction-ignored"