Repository navigation
Description
As lapack was updated I was thinking is it possible easily to use it.
I made those changes to the Makefile:
--- Makefile.old 2011-11-23 13:36:44.000000000 +0100
+++ Makefile 2011-11-23 13:38:38.000000000 +0100
@@ -195,47 +195,47 @@
netlib :
else
-netlib : lapack-3.1.1 patch.for_lapack-3.1.1 lapack-3.1.1/make.inc
+netlib : lapack-3.4.0 patch.for_lapack-3.4.0 lapack-3.4.0/make.inc
ifndef NOFORTRAN
- -@$(MAKE) -C lapack-3.1.1 lapacklib
- -@$(MAKE) -C lapack-3.4.0 lapacklib
endif
endif
-prof_lapack : lapack-3.1.1 lapack-3.1.1/make.inc
- -@$(MAKE) -C lapack-3.1.1 lapack_prof
+prof_lapack : lapack-3.4.0 lapack-3.4.0/make.inc - -@$(MAKE) -C lapack-3.4.0 lapack_prof
-lapack-3.1.1/make.inc :
+lapack-3.4.0/make.inc :
ifndef NOFORTRAN
- -@echo "FORTRAN = $(FC)" > lapack-3.1.1/make.inc
- -@echo "OPTS = $(FFLAGS)" >> lapack-3.1.1/make.inc
- -@echo "POPTS = $(FPFLAGS)" >> lapack-3.1.1/make.inc
- -@echo "NOOPT = $(FFLAGS) -O0" >> lapack-3.1.1/make.inc
- -@echo "PNOOPT = $(FPFLAGS) -O0" >> lapack-3.1.1/make.inc
- -@echo "LOADOPTS =
$(FFLAGS) $ (EXTRALIB)" >> lapack-3.1.1/make.inc - -@echo "ARCH = $(AR)" >> lapack-3.1.1/make.inc
- -@echo "RANLIB = $(RANLIB)" >> lapack-3.1.1/make.inc
- -@echo "LAPACKLIB = ../$(LIBNAME)" >> lapack-3.1.1/make.inc
- -@echo "LAPACKLIB_P = ../$(LIBNAME_P)" >> lapack-3.1.1/make.inc
- -@echo "SUFFIX = $(SUFFIX)" >> lapack-3.1.1/make.inc
- -@echo "PSUFFIX = $(PSUFFIX)" >> lapack-3.1.1/make.inc
-# -@echo "CEXTRALIB = $(CEXTRALIB)" >> lapack-3.1.1/make.inc - -@cat make.inc >> lapack-3.1.1/make.inc
- -@echo "FORTRAN = $(FC)" > lapack-3.4.0/make.inc
- -@echo "OPTS = $(FFLAGS)" >> lapack-3.4.0/make.inc
- -@echo "POPTS = $(FPFLAGS)" >> lapack-3.4.0/make.inc
- -@echo "NOOPT = $(FFLAGS) -O0" >> lapack-3.4.0/make.inc
- -@echo "PNOOPT = $(FPFLAGS) -O0" >> lapack-3.4.0/make.inc
- -@echo "LOADOPTS =
$(FFLAGS) $ (EXTRALIB)" >> lapack-3.4.0/make.inc - -@echo "ARCH = $(AR)" >> lapack-3.4.0/make.inc
- -@echo "RANLIB = $(RANLIB)" >> lapack-3.4.0/make.inc
- -@echo "LAPACKLIB = ../$(LIBNAME)" >> lapack-3.4.0/make.inc
- -@echo "LAPACKLIB_P = ../$(LIBNAME_P)" >> lapack-3.4.0/make.inc
- -@echo "SUFFIX = $(SUFFIX)" >> lapack-3.4.0/make.inc
- -@echo "PSUFFIX = $(PSUFFIX)" >> lapack-3.4.0/make.inc
+# -@echo "CEXTRALIB = $(CEXTRALIB)" >> lapack-3.4.0/make.inc - -@cat make.inc >> lapack-3.4.0/make.inc
endif
-lapack-3.1.1 : lapack-3.1.1.tgz
+lapack-3.4.0 : lapack-3.4.0.tgz
ifndef NOFORTRAN
- @if test
$(MD5SUM) lapack-3.1.1.tgz | $(AWK) '{print $$1}'= 00b21551a899bcfbaa7b8443e1faeef9; then \ - @if test
$(MD5SUM) lapack-3.4.0.tgz | $(AWK) '{print $$1}'= 00b21551a899bcfbaa7b8443e1faeef9; then
echo$(TAR) zxf $ < ;\ -
$(TAR) zxf $< && (cd lapack-3.1.1; $(PATCH) -p1 < ../patch.for_lapack-3.1.1) ;\ -
else \
$(TAR) zxf $< && (cd lapack-3.4.0; $(PATCH) -p1 < ../patch.for_lapack-3.4.0) ;\ -
echo " lapack-3.1.1.tgz check sum is wrong (Please use orignal)." ;\ -
rm -rf lapack-3.1.1 ;\ -
echo " lapack-3.4.0.tgz check sum is wrong (Please use orignal)." ;\ -
fi
rm -rf lapack-3.4.0 ;\
endif
-lapack-3.1.1.tgz :
+lapack-3.4.0.tgz :
ifndef NOFORTRAN
- -wget http://www.netlib.org/lapack/lapack-3.1.1.tgz
- -wget http://www.netlib.org/lapack/lapack-3.4.0.tgz
endif
large.tgz :
@@ -248,21 +248,21 @@
-wget http://www.netlib.org/lapack/timing/timing.tgz
endif
-lapack-timing : lapack-3.1.1 large.tgz timing.tgz
+lapack-timing : lapack-3.4.0 large.tgz timing.tgz
ifndef NOFORTRAN
- (cd lapack-3.1.1; $(TAR) zxf ../timing.tgz TIMING)
- (cd lapack-3.1.1/TIMING; $(TAR) zxf ../../large.tgz )
- make -C lapack-3.1.1 tmglib
- make -C lapack-3.1.1/TIMING
- (cd lapack-3.4.0; $(TAR) zxf ../timing.tgz TIMING)
- (cd lapack-3.4.0/TIMING; $(TAR) zxf ../../large.tgz )
- make -C lapack-3.4.0 tmglib
- make -C lapack-3.4.0/TIMING
endif
lapack-test :
- $(MAKE) -C lapack-3.1.1 tmglib
- $(MAKE) -C lapack-3.1.1/TESTING xeigtstc xeigtstd xeigtsts xeigtstz xlintstc xlintstd xlintstds xlintsts xlintstz xlintstzc
- @rm -f lapack-3.1.1/TESTING/*.out
- $(MAKE) -j 1 -C lapack-3.1.1/TESTING
- $(GREP) failed lapack-3.1.1/TESTING/*.out
- $(MAKE) -C lapack-3.4.0 tmglib
- $(MAKE) -C lapack-3.4.0/TESTING xeigtstc xeigtstd xeigtsts xeigtstz xlintstc xlintstd xlintstds xlintsts xlintstz xlintstzc
- @rm -f lapack-3.4.0/TESTING/*.out
- $(MAKE) -j 1 -C lapack-3.4.0/TESTING
- $(GREP) failed lapack-3.4.0/TESTING/*.out
dummy :
@@ -280,9 +280,9 @@
#endif
@rm -f .$(LIBSUFFIX) *.so *~ *.exe getarch getarch_2nd *.dll *.lib *.$(SUFFIX) *.dwf libopenblas.$(LIBSUFFIX) libopenblas_p.$(LIBSUFFIX) *.lnk myconfig.h
@rm -f Makefile.conf config.h Makefile_kernel.conf config_kernel.h st *.dylib
- @if test -d lapack-3.1.1; then \
- echo deleting lapack-3.1.1; \
- rm -rf lapack-3.1.1 ;\
- @if test -d lapack-3.4.0; then \
- echo deleting lapack-3.4.0; \
- rm -rf lapack-3.4.0 ;
fi
@rm -f *.grd Makefile.conf_last config_last.h - @echo Done.
\ Pas de fin de ligne à la fin du fichier. - @echo Done.
Copied patch.for_lapack-3.1.1 into patch.for_lapack-3.4.0 and all compiled correctly in my:
OpenBLAS build complete.
OS ... Linux
Architecture ... x86_64
BINARY ... 64bit
C compiler ... GCC (command line : gcc)
Fortran compiler ... GFORTRAN (command line : gfortran)
Library Name ... libopenblas_penrynp-r0.1alpha2.4.a (Multi threaded; Max num-threads is 8)
Activity
xianyi commentedon Nov 24, 2011
Hi,
Thank you for this patch. I will add this patch into develop branch.
You can also fork this project. Then, you can click "Pull Request" button on github.com
Thank you again!~
Xianyi
xianyi commentedon Nov 24, 2011
Hi,
After applying this patch, this patch didn't work.
Output:
lapack-3.4.0.tgz check sum is wrong (Please use orignal).
/bin/sh: cannot create lapack-3.4.0/make.inc: Directory nonexistent
....
Then, I changed md5 checking for lapack-3.4.0. However, it failed on the patching. Outputs:
tar zxf lapack-3.4.0.tgz
patching file INSTALL/Makefile
Hunk #1 FAILED at 27.
1 out of 1 hunk FAILED -- saving rejects to file INSTALL/Makefile.rej
patching file Makefile
Hunk #1 FAILED at 20.
...
Thanks
Xianyi
MarbolanGos commentedon Nov 24, 2011
You are right I changed other things. Sorry...
Thanks for updating lapack.
xianyi commentedon Nov 24, 2011
Hi,
You can send the patch to me (traits.zhang at gmail dot com). Alternatively, you can use "Pull Request" on github.com
Thanks
Xianyi
Refs #72. Upgraded LAPACK to 3.4.0 version.
xianyi commentedon Nov 28, 2011
Hi,
I just upgraded LAPACK to 3.4.0 version in develop branch. You can download it from https://github.com/xianyi/OpenBLAS/zipball/develop
Could you help me test LAPACK 3.4.0 ?
Thanks
Xianyi
MarbolanGos commentedon Nov 28, 2011
Hi,
Sorry for not responding I was busy those days. Thank you for taking care of it.
I tried your archive on 3 different computers with intel based CPUs all compiled well and I had no errors on lapack tests. All on Linux stations (64 bits).
upsha commentedon Dec 4, 2011
Hi,
I compiled the LAPACK-3.4.0 with MinGW-w64 without error. It runs with my small test code. However, I haven't figure out how to install python with MinGW-w64 and cannot run the build-in lapack_testing.py yet.
Best,
Upsha
xianyi commentedon Dec 5, 2011
Hi Upsha,
Thank you for the test.
Xianyi
ViralBShah commentedon Dec 10, 2011
Does one get a faster LAPACK by using this patch, rather than by compiling LAPACK directly and linking it to openblas?
xianyi commentedon Jan 1, 2012
Hi Viral,
I think Mr. Goto optimized some LAPACK functions such as LU factorization. Thus, it will be faster than original LAPACK.
Thanks
Xianyi
ViralBShah commentedon Jan 1, 2012
Ok, in that case I will try it out once you merge it into master and make the next release.
-viral
On Jan 1, 2012, at 7:32 PM, Xianyi Zhang wrote:
Merge pull request #72 from xianyi/develop
Pull request OpenMathLib#72: Покрытие тестами функции sum