From 8c6de3157c51f792baf4e011072e72195f6f18b337605d4e5112207f52a97119 Mon Sep 17 00:00:00 2001 From: Dmitry Roshchin Date: Thu, 12 Jun 2014 19:46:26 +0000 Subject: [PATCH 1/3] Accepting request 237012 from home:Dmitry_R:branches:science - Update to version 0.2.9 * Update LAPACK to 3.5.0 version * Fixed compatiable issues with Clang and Pathscale compilers. * Added OPENBLAS_VERBOSE environment variable.(#338) * Make OpenBLAS thread-pool resilient to fork via pthread_atfork. (#294) * Rewrote rotmg * Fixed sdsdot bug. * Improved the result for LAPACK testing. (#372) x86/x86-64: * Optimization on Intel Haswell. * Enable optimization kernels on AMD Bulldozer and Piledriver. * Detect Intel Haswell for new Macbook. * To improve LAPACK testing, we fallback some kernels. (#372) https://github.com/xianyi/OpenBLAS/wiki/Fixed-optimized-kernels-To-do-List ARM: * Support ARMv6 and ARMv7 ISA. * Optimization on ARM Cortex-A9. - Update patches: * openblas-0.2.8-libs.patch * openblas-0.2.8-noexecstack.patch - Fix gcc warnings (#385) * openblas-0.2.9-gcc-warnings.patch OBS-URL: https://build.opensuse.org/request/show/237012 OBS-URL: https://build.opensuse.org/package/show/science/openblas?expand=0&rev=23 --- openblas-0.2.9-gcc-warnings.patch | 72 +++++++++++++++++++ ....8-libs.patch => openblas-0.2.9-libs.patch | 13 ++-- ....patch => openblas-0.2.9-noexecstack.patch | 24 +++---- openblas-0.2.9.tar.gz | 3 + openblas.changes | 27 +++++++ openblas.spec | 19 +++-- v0.2.8.tar.gz | 3 - 7 files changed, 129 insertions(+), 32 deletions(-) create mode 100644 openblas-0.2.9-gcc-warnings.patch rename openblas-0.2.8-libs.patch => openblas-0.2.9-libs.patch (64%) rename openblas-0.2.8-noexecstack.patch => openblas-0.2.9-noexecstack.patch (60%) create mode 100644 openblas-0.2.9.tar.gz delete mode 100644 v0.2.8.tar.gz diff --git a/openblas-0.2.9-gcc-warnings.patch b/openblas-0.2.9-gcc-warnings.patch new file mode 100644 index 0000000..5a0855f --- /dev/null +++ b/openblas-0.2.9-gcc-warnings.patch @@ -0,0 +1,72 @@ +diff --git a/driver/others/dynamic.c b/driver/others/dynamic.c +index 7b7beb9..ec421d6 100644 +--- a/driver/others/dynamic.c ++++ b/driver/others/dynamic.c +@@ -116,18 +116,24 @@ extern void openblas_warning(int verbose, const char * msg); + + static int get_vendor(void){ + int eax, ebx, ecx, edx; +- char vendor[13]; ++ ++ union ++ { ++ char vchar[16]; ++ int vint[4]; ++ } vendor; + + cpuid(0, &eax, &ebx, &ecx, &edx); +- +- *(int *)(&vendor[0]) = ebx; +- *(int *)(&vendor[4]) = edx; +- *(int *)(&vendor[8]) = ecx; +- vendor[12] = (char)0; + +- if (!strcmp(vendor, "GenuineIntel")) return VENDOR_INTEL; +- if (!strcmp(vendor, "AuthenticAMD")) return VENDOR_AMD; +- if (!strcmp(vendor, "CentaurHauls")) return VENDOR_CENTAUR; ++ *(&vendor.vint[0]) = ebx; ++ *(&vendor.vint[1]) = edx; ++ *(&vendor.vint[2]) = ecx; ++ ++ vendor.vchar[12] = '\0'; ++ ++ if (!strcmp(vendor.vchar, "GenuineIntel")) return VENDOR_INTEL; ++ if (!strcmp(vendor.vchar, "AuthenticAMD")) return VENDOR_AMD; ++ if (!strcmp(vendor.vchar, "CentaurHauls")) return VENDOR_CENTAUR; + + if ((eax == 0) || ((eax & 0x500) != 0)) return VENDOR_INTEL; + +@@ -232,7 +238,7 @@ static gotoblas_t *get_coretype(void){ + if (family <= 0xe) { + // Verify that CPU has 3dnow and 3dnowext before claiming it is Athlon + cpuid(0x80000000, &eax, &ebx, &ecx, &edx); +- if (eax & 0xffff >= 0x01) { ++ if ( (eax & 0xffff) >= 0x01) { + cpuid(0x80000001, &eax, &ebx, &ecx, &edx); + if ((edx & (1 << 30)) == 0 || (edx & (1 << 31)) == 0) + return NULL; +diff --git a/kernel/arm/gemv_n.c b/kernel/arm/gemv_n.c +index aedcca9..a295080 100644 +--- a/kernel/arm/gemv_n.c ++++ b/kernel/arm/gemv_n.c +@@ -61,7 +61,7 @@ int CNAME(BLASLONG m, BLASLONG n, BLASLONG dummy1, FLOAT alpha, FLOAT *a, BLASLO + a_ptr += lda; + ix += inc_x; + } +- ++ return(0); + } + + +diff --git a/kernel/arm/gemv_t.c b/kernel/arm/gemv_t.c +index 8fd6a66..f94db40 100644 +--- a/kernel/arm/gemv_t.c ++++ b/kernel/arm/gemv_t.c +@@ -61,6 +61,7 @@ int CNAME(BLASLONG m, BLASLONG n, BLASLONG dummy1, FLOAT alpha, FLOAT *a, BLASLO + iy += inc_y; + a_ptr += lda; + } ++ return(0); + + } + diff --git a/openblas-0.2.8-libs.patch b/openblas-0.2.9-libs.patch similarity index 64% rename from openblas-0.2.8-libs.patch rename to openblas-0.2.9-libs.patch index e6b5898..48d29aa 100644 --- a/openblas-0.2.8-libs.patch +++ b/openblas-0.2.9-libs.patch @@ -1,12 +1,13 @@ -Index: OpenBLAS-0.2.8/exports/Makefile +Index: OpenBLAS-0.2.9/exports/Makefile =================================================================== ---- OpenBLAS-0.2.8.orig/exports/Makefile -+++ OpenBLAS-0.2.8/exports/Makefile -@@ -22,10 +22,9 @@ ifndef NEED2UNDERSCORES - NEED2UNDERSCORES=0 +--- OpenBLAS-0.2.9.orig/exports/Makefile ++++ OpenBLAS-0.2.9/exports/Makefile +@@ -26,10 +26,10 @@ ifndef ONLY_CBLAS + ONLY_CBLAS = 0 endif -ifeq ($(OSNAME), WINNT) ++ ifeq ($(F_COMPILER), GFORTRAN) EXTRALIB += -lgfortran -endif @@ -14,7 +15,7 @@ Index: OpenBLAS-0.2.8/exports/Makefile ifeq ($(USE_OPENMP), 1) ifeq ($(C_COMPILER), GCC) EXTRALIB += -lgomp -@@ -33,11 +32,6 @@ endif +@@ -37,11 +37,6 @@ endif endif endif diff --git a/openblas-0.2.8-noexecstack.patch b/openblas-0.2.9-noexecstack.patch similarity index 60% rename from openblas-0.2.8-noexecstack.patch rename to openblas-0.2.9-noexecstack.patch index 6c4969f..bd4ff1c 100644 --- a/openblas-0.2.8-noexecstack.patch +++ b/openblas-0.2.9-noexecstack.patch @@ -1,24 +1,24 @@ -Index: OpenBLAS-0.2.8/exports/Makefile +Index: OpenBLAS-0.2.9/exports/Makefile =================================================================== ---- OpenBLAS-0.2.8.orig/exports/Makefile -+++ OpenBLAS-0.2.8/exports/Makefile -@@ -115,6 +115,7 @@ so : ../$(LIBSONAME) - - ../$(LIBSONAME) : ../$(LIBNAME) linux.def linktest.c +--- OpenBLAS-0.2.9.orig/exports/Makefile ++++ OpenBLAS-0.2.9/exports/Makefile +@@ -101,6 +101,7 @@ so : ../$(LIBSONAME) + ../$(LIBSONAME) : ../$(LIBNAME) linktest.c + ifneq ($(C_COMPILER), LSB) $(CC) $(CFLAGS) $(LDFLAGS) -shared -o ../$(LIBSONAME) \ + -Wl,-z,noexecstack \ -Wl,--whole-archive ../$(LIBNAME) -Wl,--no-whole-archive \ - -Wl,--retain-symbols-file=linux.def -Wl,-soname,$(LIBPREFIX).so.$(MAJOR_VERSION) $(EXTRALIB) - ifneq ($(C_COMPILER), LSB) -@@ -134,6 +135,7 @@ so : ../$(LIBSONAME) + -Wl,-soname,$(LIBPREFIX).so.$(MAJOR_VERSION) $(EXTRALIB) + $(CC) $(CFLAGS) $(LDFLAGS) -w -o linktest linktest.c ../$(LIBSONAME) $(FEXTRALIB) && echo OK. +@@ -122,6 +123,7 @@ so : ../$(LIBSONAME) - ../$(LIBSONAME) : ../$(LIBNAME) linux.def linktest.c + ../$(LIBSONAME) : ../$(LIBNAME) linktest.c $(CC) $(CFLAGS) $(LDFLAGS) -shared -o ../$(LIBSONAME) \ + -Wl,-z,noexecstack \ -Wl,--whole-archive ../$(LIBNAME) -Wl,--no-whole-archive \ - -Wl,--retain-symbols-file=linux.def $(FEXTRALIB) $(EXTRALIB) + $(FEXTRALIB) $(EXTRALIB) $(CC) $(CFLAGS) $(LDFLAGS) -w -o linktest linktest.c ../$(LIBSONAME) $(FEXTRALIB) && echo OK. -@@ -153,6 +155,7 @@ ifeq ($(OSNAME), SunOS) +@@ -141,6 +143,7 @@ ifeq ($(OSNAME), SunOS) so : ../$(LIBSONAME) $(CC) $(CFLAGS) $(LDFLAGS) -shared -o ../$(LIBSONAME) \ diff --git a/openblas-0.2.9.tar.gz b/openblas-0.2.9.tar.gz new file mode 100644 index 0000000..50eabd4 --- /dev/null +++ b/openblas-0.2.9.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a9ce75fe29f8527467b159490facca0bfc62e8a40a165b51822caa46368b0dc0 +size 9700585 diff --git a/openblas.changes b/openblas.changes index 318fe68..246d9e9 100644 --- a/openblas.changes +++ b/openblas.changes @@ -1,3 +1,30 @@ +------------------------------------------------------------------- +Tue Jun 10 14:34:02 UTC 2014 - dmitry_r@opensuse.org + +- Update to version 0.2.9 + * Update LAPACK to 3.5.0 version + * Fixed compatiable issues with Clang and Pathscale compilers. + * Added OPENBLAS_VERBOSE environment variable.(#338) + * Make OpenBLAS thread-pool resilient to fork via pthread_atfork. + (#294) + * Rewrote rotmg + * Fixed sdsdot bug. + * Improved the result for LAPACK testing. (#372) + x86/x86-64: + * Optimization on Intel Haswell. + * Enable optimization kernels on AMD Bulldozer and Piledriver. + * Detect Intel Haswell for new Macbook. + * To improve LAPACK testing, we fallback some kernels. (#372) + https://github.com/xianyi/OpenBLAS/wiki/Fixed-optimized-kernels-To-do-List + ARM: + * Support ARMv6 and ARMv7 ISA. + * Optimization on ARM Cortex-A9. +- Update patches: + * openblas-0.2.8-libs.patch + * openblas-0.2.8-noexecstack.patch +- Fix gcc warnings (#385) + * openblas-0.2.9-gcc-warnings.patch + ------------------------------------------------------------------- Sat Apr 12 09:02:16 UTC 2014 - dmitry_r@opensuse.org diff --git a/openblas.spec b/openblas.spec index a22c04d..d339274 100644 --- a/openblas.spec +++ b/openblas.spec @@ -17,22 +17,24 @@ Name: openblas -Version: 0.2.8 +Version: 0.2.9 Release: 0 Summary: An optimized BLAS library based on GotoBLAS2 License: BSD-3-Clause Group: Productivity/Scientific/Math Url: http://www.openblas.net -Source0: https://github.com/xianyi/OpenBLAS/archive/v%{version}.tar.gz +Source0: https://github.com/xianyi/OpenBLAS/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz # PATCH-FIX-UPSTREAM openblas-0.2.8-libs.patch: Link against libgfortran -Patch0: openblas-0.2.8-libs.patch +Patch0: openblas-0.2.9-libs.patch # PATCH-FIX-UPSTREAM c_xerbla_no-void-return.patch Patch1: c_xerbla_no-void-return.patch # PATCH-FEATURE-OPENSUSE openblas-0.1.0-soname.patch Patch2: openblas-0.1.0-soname.patch # PATCH-FIX-UPSTREAM openblas-0.2.8-noexecstack.patch -Patch3: openblas-0.2.8-noexecstack.patch -BuildRoot: %{_tmppath}/build +Patch3: openblas-0.2.9-noexecstack.patch +# PATCH-FIX-UPSTREAM openblas-0.2.9-gcc-warnings.patch -- Fix GCC warnings (bug#385) +Patch4: openblas-0.2.9-gcc-warnings.patch +BuildRoot: %{_tmppath}/%{name}-%{version}-build ExclusiveArch: %ix86 ia64 ppc ppc64 x86_64 BuildRequires: gcc-fortran BuildRequires: update-alternatives @@ -112,12 +114,7 @@ cd OpenBLAS-%{version} %patch1 -p1 %patch2 -p1 %patch3 -p1 - -# Bad licenses -# openblas 0.29 will contain lapack 3.5.0 with fixed files -rm lapack-netlib/DOCS/psfig.tex -rm lapack-netlib/lapacke/example/example_DGESV_rowmajor.c -rm lapack-netlib/lapacke/example/example_ZGESV_rowmajor.c +%patch4 -p1 cd .. # prepare build for serial, threaded and OpenMP versions diff --git a/v0.2.8.tar.gz b/v0.2.8.tar.gz deleted file mode 100644 index d32cbc3..0000000 --- a/v0.2.8.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:359f5cd2604ed76d97b0669b9b846a59a1d0283065d23f8847956629871fedd8 -size 9466378 From 31685c8f353b615eb980765f250c29d368b1ecf1f62bd7a7cae43accb0a23140 Mon Sep 17 00:00:00 2001 From: Dmitry Roshchin Date: Thu, 12 Jun 2014 19:52:20 +0000 Subject: [PATCH 2/3] Fix changes file OBS-URL: https://build.opensuse.org/package/show/science/openblas?expand=0&rev=24 --- openblas.changes | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/openblas.changes b/openblas.changes index 246d9e9..c9838dd 100644 --- a/openblas.changes +++ b/openblas.changes @@ -20,8 +20,8 @@ Tue Jun 10 14:34:02 UTC 2014 - dmitry_r@opensuse.org * Support ARMv6 and ARMv7 ISA. * Optimization on ARM Cortex-A9. - Update patches: - * openblas-0.2.8-libs.patch - * openblas-0.2.8-noexecstack.patch + * openblas-0.2.9-libs.patch + * openblas-0.2.9-noexecstack.patch - Fix gcc warnings (#385) * openblas-0.2.9-gcc-warnings.patch From 861eea5119edba69c68c33433fea6d8c680605d794da4eb3e2d5d1969b496f23 Mon Sep 17 00:00:00 2001 From: Dmitry Roshchin Date: Thu, 12 Jun 2014 20:06:06 +0000 Subject: [PATCH 3/3] Fix patch name OBS-URL: https://build.opensuse.org/package/show/science/openblas?expand=0&rev=25 --- openblas-0.2.9-libs.patch => openblas-libs.patch | 0 ...s-0.2.9-noexecstack.patch => openblas-noexecstack.patch | 0 openblas.changes | 7 +++++-- openblas.spec | 4 ++-- 4 files changed, 7 insertions(+), 4 deletions(-) rename openblas-0.2.9-libs.patch => openblas-libs.patch (100%) rename openblas-0.2.9-noexecstack.patch => openblas-noexecstack.patch (100%) diff --git a/openblas-0.2.9-libs.patch b/openblas-libs.patch similarity index 100% rename from openblas-0.2.9-libs.patch rename to openblas-libs.patch diff --git a/openblas-0.2.9-noexecstack.patch b/openblas-noexecstack.patch similarity index 100% rename from openblas-0.2.9-noexecstack.patch rename to openblas-noexecstack.patch diff --git a/openblas.changes b/openblas.changes index c9838dd..b4a7dc6 100644 --- a/openblas.changes +++ b/openblas.changes @@ -20,8 +20,11 @@ Tue Jun 10 14:34:02 UTC 2014 - dmitry_r@opensuse.org * Support ARMv6 and ARMv7 ISA. * Optimization on ARM Cortex-A9. - Update patches: - * openblas-0.2.9-libs.patch - * openblas-0.2.9-noexecstack.patch + * openblas-0.2.8-libs.patch + * openblas-0.2.8-noexecstack.patch + to + * openblas-libs.patch + * openblas-noexecstack.patch - Fix gcc warnings (#385) * openblas-0.2.9-gcc-warnings.patch diff --git a/openblas.spec b/openblas.spec index d339274..a76aa04 100644 --- a/openblas.spec +++ b/openblas.spec @@ -25,13 +25,13 @@ Group: Productivity/Scientific/Math Url: http://www.openblas.net Source0: https://github.com/xianyi/OpenBLAS/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz # PATCH-FIX-UPSTREAM openblas-0.2.8-libs.patch: Link against libgfortran -Patch0: openblas-0.2.9-libs.patch +Patch0: openblas-libs.patch # PATCH-FIX-UPSTREAM c_xerbla_no-void-return.patch Patch1: c_xerbla_no-void-return.patch # PATCH-FEATURE-OPENSUSE openblas-0.1.0-soname.patch Patch2: openblas-0.1.0-soname.patch # PATCH-FIX-UPSTREAM openblas-0.2.8-noexecstack.patch -Patch3: openblas-0.2.9-noexecstack.patch +Patch3: openblas-noexecstack.patch # PATCH-FIX-UPSTREAM openblas-0.2.9-gcc-warnings.patch -- Fix GCC warnings (bug#385) Patch4: openblas-0.2.9-gcc-warnings.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build