summaryrefslogtreecommitdiff
path: root/var/spack/repos/builtin/packages/nwchem/Gcc6_optfix.patch
blob: 20964015a748a5ed95283934f25f3cd87d017c92 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
--- src/config/makefile.h.orig	2016-07-22 08:45:52.100229544 -0700
+++ src/config/makefile.h	2016-07-22 08:49:00.321422169 -0700
@@ -1565,6 +1565,7 @@
         GNU_GE_4_6 = $(shell [ $(GNUMAJOR) -gt 4 -o \( $(GNUMAJOR) -eq 4 -a $(GNUMINOR) -ge 6 \) ] && echo true)
         GNU_GE_4_8 = $(shell [ $(GNUMAJOR) -gt 4 -o \( $(GNUMAJOR) -eq 4 -a $(GNUMINOR) -ge 8 \) ] && echo true)
         endif
+        GNU_GE_6 = $(shell [ $(GNUMAJOR) -ge 6  ] && echo true)
         ifeq ($(GNU_GE_4_6),true)
           DEFINES  += -DGCC46
         endif
@@ -1942,6 +1943,10 @@
         FOPTIMIZE  += -O3 
         FOPTIMIZE  += -mfpmath=sse -ffast-math
         FOPTIMIZE  += -fprefetch-loop-arrays #-ftree-loop-linear
+        ifeq ($(GNU_GE_6),true)
+         FOPTIMIZE += -fno-tree-dominator-opts # solvation/hnd_cosmo_lib breaks
+        endif
+
         ifeq ($(GNU_GE_4_8),true)
           FOPTIMIZE  += -ftree-vectorize   -fopt-info-vec
         endif