I am trying to compile the latest MAGMA v1.6.1 on my macbook pro running OS X 10.10.2.
I am not able to compile the source code, and I have tried using both gcc/gfortran v5.0 and clang v6.0 (without fortran bindings in this case). I am using the latest available CUDA 7 release candidate.
Thank you in advance for your support.
This is the error reported when trying to build:
gcc: warning: couldn’t understand kern.osversion ‘14.1.0
ld: warning: could not create compact unwind for _magma_cbulge_applyQ_v2_m: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_chetrd_he2hb_mgpu: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_chetrd_he2hb_mgpu_spec: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_ctrevc3_mt: dwarf uses DW_CFA_GNU_args_size
ld: warning: could not create compact unwind for _magma_cunmql2_gpu: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_cunmqr2_gpu: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_dbulge_applyQ_v2_m: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_dormql2_gpu: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_dormqr2_gpu: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_dsytrd_sy2sb_mgpu: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_dsytrd_sy2sb_mgpu_spec: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_sbulge_applyQ_v2_m: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_sormql2_gpu: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_sormqr2_gpu: stack subq instruction is too different from dwarf stack size
ld: warning: ld: warning: could not create compact unwind for _magma_ssytrd_sy2sb_mgpu: stack subq instruction is too different from dwarf stack sizecould not create compact unwind for _magma_ssytrd_sy2sb_mgpu_spec: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_zbulge_applyQ_v2_m: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_zhetrd_he2hb_mgpu: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_zhetrd_he2hb_mgpu_spec: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_ztrevc3_mt: dwarf uses DW_CFA_GNU_args_size
ld: warning: could not create compact unwind for _magma_zunmql2_gpu: stack subq instruction is too different from dwarf stack size
ld: warning: could not create compact unwind for _magma_zunmqr2_gpu: stack subq instruction is too different from dwarf stack size
Undefined symbols for architecture x86_64:
"__Unwind_Resume", referenced from:
_magma_cbulge_back_m in cbulge_back_m.o
_magma_ctrevc3_mt in ctrevc3_mt.o
_magma_dbulge_back_m in dbulge_back_m.o
_magma_dtrevc3_mt in dtrevc3_mt.o
_magma_sbulge_back_m in sbulge_back_m.o
_magma_strevc3_mt in strevc3_mt.o
_magma_zbulge_back_m in zbulge_back_m.o
...
ld: symbol(s) not found for architecture x86_64
collect2: error: ld returned 1 exit status
make[1]: *** [lib/libmagma.so] Error 1
make: *** [shared] Error 2
Exit 2
Here is my make.inc file:
#//////////////////////////////////////////////////////////////////////////////
# -- MAGMA (version 1.6.1) --
# Univ. of Tennessee, Knoxville
# Univ. of California, Berkeley
# Univ. of Colorado, Denver
# @date January 2015
#//////////////////////////////////////////////////////////////////////////////
# GPU_TARGET contains one or more of Tesla, Fermi, or Kepler,
# to specify for which GPUs you want to compile MAGMA:
# Tesla - NVIDIA compute capability 1.x cards (no longer supported in CUDA 6.5)
# Fermi - NVIDIA compute capability 2.x cards
# Kepler - NVIDIA compute capability 3.x cards
# The default is "Fermi Kepler".
# See http://developer.nvidia.com/cuda-gpus
#
#GPU_TARGET ?= Fermi Kepler
CC = gcc
CXX = g++
NVCC = nvcc
FORT = gfortran
ARCH = ar
ARCHFLAGS = cr
RANLIB = ranlib
# use -m32 to compile with 32-bit long & pointers.
# use -m64 to compile with 64-bit long & pointers (lp64). int is still 32-bit.
# add -DNDEBUG to disable asserts and certain error checks.
#
# MacOS veclib has a bug where some single precision functions return
# a double precision result, for instance slange.
# This is observed with -m64, but oddly not with -m32.
# The easiest fix is to replace those routines with correct ones from LAPACK.
# See BLAS_FIX below.
# Alternatively, don't link with the veclib/accelerate framework;
# use a different BLAS and LAPACK library.
# Use -fPIC to make shared (.so) and static (.a) library;
# can be commented out if making only static library.
FPIC = -fPIC
CFLAGS = -m64 -O3 $(FPIC) -DADD_ -Wall
FFLAGS = -m64 -O3 $(FPIC) -DADD_ -Wall -Wno-unused-dummy-argument
F90FLAGS = -m64 -O3 $(FPIC) -DADD_ -Wall -Wno-unused-dummy-argument -x f95-cpp-input
NVCCFLAGS = -m64 -O3 -DADD_ -Xcompiler "-fno-strict-aliasing $(FPIC)"
LDFLAGS = -m64 $(FPIC)
# MacOS likes the library's path to be set
INSTALL_NAME = -install_name @rpath/
LIB = -framework Accelerate -lcublas -lcudart -lstdc++ -lm
# define library directories preferably in your environment, or here.
#CUDADIR ?= /usr/local/cuda
-include make.check-cuda
LIBDIR = -L$(CUDADIR)/lib
INC = -I$(CUDADIR)/include
# ========================================
# replace single & single-complex BLAS functions with reference versions.
# (i.e., functions that return float; subroutines do not need a fix.)
LIB := -L$(MAGMA_DIR)/lib -lblas_fix $(LIB)
BLAS_FIX = $(MAGMA_DIR)/lib/libblas_fix.a
.PHONY: blas_fix
blas_fix:
@echo "======================================== BLAS fix for MacOS"
( cd $(MAGMA_DIR)/blas_fix && $(MAKE) )
@echo
lib: blas_fix
MAGMA v1.6.1 does not compile on Mac OS X 10.10.2
Re: MAGMA v1.6.1 does not compile on Mac OS X 10.10.2
I have not seen this before. I'm using clang 6.0 with gfortran 4.9, or gcc 4.9 with gfortran 4.9, on MacOS 10.9.5.
Here's one post I found related to this:
https://software.intel.com/en-us/forums/topic/279914
Does that help?
-mark
Here's one post I found related to this:
https://software.intel.com/en-us/forums/topic/279914
Does that help?
-mark
Re: MAGMA v1.6.1 does not compile on Mac OS X 10.10.2
Hi Mark,
switching to gcc 4.9 and gfortran 4.9 I was able to compile using CUDA 6.5; now I am trying to compile using the same compilers and the latest CUDA 7.0 RC.
Thank you for pointing me at the Intel forum, I was not aware of this linker issue indeed.
switching to gcc 4.9 and gfortran 4.9 I was able to compile using CUDA 6.5; now I am trying to compile using the same compilers and the latest CUDA 7.0 RC.
Thank you for pointing me at the Intel forum, I was not aware of this linker issue indeed.