numo-blis 0.1.0 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +10 -0
- data/ext/numo/blis/extconf.rb +18 -2
- data/lib/numo/blis/version.rb +1 -1
- metadata +3 -3
    
        checksums.yaml
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            ---
         | 
| 2 2 | 
             
            SHA256:
         | 
| 3 | 
            -
              metadata.gz:  | 
| 4 | 
            -
              data.tar.gz:  | 
| 3 | 
            +
              metadata.gz: '09533d7e6a34154affbbfbb3bf8788c25a9eb9c5711dcc68aaf13b457c18986f'
         | 
| 4 | 
            +
              data.tar.gz: 2856a6a930c539af6f134b598f08d54ee53da8b40bbe524d6deab44b5dacbd7d
         | 
| 5 5 | 
             
            SHA512:
         | 
| 6 | 
            -
              metadata.gz:  | 
| 7 | 
            -
              data.tar.gz:  | 
| 6 | 
            +
              metadata.gz: 2035b24379d38daa06e1b3ecd071f5926d00f0673a9190d2fc42d0f58464a62a7aea8fbc347c8ab71534cad02e05a54a002bfda36e5fc46b07b78108bc216adb
         | 
| 7 | 
            +
              data.tar.gz: '0699449615647ef228361d6d2e8e73cb7f20bad8cba35a7d62bbd712d38c901fa54c7efb6702daba9f1af17538b7e6b2e831d76f1f95da81b6f9d54edcbce21a'
         | 
    
        data/CHANGELOG.md
    CHANGED
    
    | @@ -1,5 +1,15 @@ | |
| 1 1 | 
             
            ## [Unreleased]
         | 
| 2 2 |  | 
| 3 | 
            +
            ## [0.2.0] - 2021-07-31
         | 
| 4 | 
            +
             | 
| 5 | 
            +
            - Added enable-threading option to specify the threding method of BLIS.
         | 
| 6 | 
            +
             | 
| 7 | 
            +
              ```
         | 
| 8 | 
            +
              $ gem install numo-blis -- --enable-threading=openmp
         | 
| 9 | 
            +
              ```
         | 
| 10 | 
            +
             | 
| 11 | 
            +
            - Changed to detect threading method automatically when the enable-threading option is not given.
         | 
| 12 | 
            +
             | 
| 3 13 | 
             
            ## [0.1.0] - 2021-07-17
         | 
| 4 14 |  | 
| 5 15 | 
             
            - Initial release
         | 
    
        data/ext/numo/blis/extconf.rb
    CHANGED
    
    | @@ -1,4 +1,3 @@ | |
| 1 | 
            -
            # frozen-string-literal: true
         | 
| 2 1 |  | 
| 3 2 | 
             
            require 'etc'
         | 
| 4 3 | 
             
            require 'fileutils'
         | 
| @@ -8,6 +7,8 @@ require 'open3' | |
| 8 7 | 
             
            require 'rbconfig'
         | 
| 9 8 | 
             
            require 'rubygems/package'
         | 
| 10 9 |  | 
| 10 | 
            +
            ENABLE_THREADING_ARG = arg_config('--enable-threading')
         | 
| 11 | 
            +
             | 
| 11 12 | 
             
            VENDOR_DIR = File.expand_path("#{__dir__}/../../../vendor")
         | 
| 12 13 | 
             
            SOEXT = RbConfig::CONFIG['SOEXT'] || case RUBY_PLATFORM
         | 
| 13 14 | 
             
                                                 when /mswin|msys|mingw|cygwin/
         | 
| @@ -26,13 +27,28 @@ BLIS_TGZ = "#{VENDOR_DIR}/tmp/blis-#{BLIS_VERSION}.tgz" | |
| 26 27 | 
             
            LAPACK_TGZ = "#{VENDOR_DIR}/tmp/lapack-#{LAPACK_VERSION}.tgz"
         | 
| 27 28 | 
             
            BLIS_KEY = 'ce5998fccfac88153f1e52d6497020529a3b5217'
         | 
| 28 29 | 
             
            LAPACK_KEY = '4a9384523bf236c83568884e8c62d9517e41ac42'
         | 
| 30 | 
            +
            RB_CC = "'#{RbConfig::expand('$(CC)')}'"
         | 
| 31 | 
            +
            RB_CXX = "'#{RbConfig::expand('$(CPP)')}'"
         | 
| 32 | 
            +
             | 
| 33 | 
            +
            BLIS_THREADING = if ['openmp', 'pthreads', 'no'].include?(ENABLE_THREADING_ARG)
         | 
| 34 | 
            +
                               ENABLE_THREADING_ARG
         | 
| 35 | 
            +
                             elsif try_compile('#include <omp.h>')
         | 
| 36 | 
            +
                               'openmp'
         | 
| 37 | 
            +
                             elsif try_complie('#include <pthread.h>')
         | 
| 38 | 
            +
                               'pthreads'
         | 
| 39 | 
            +
                             else
         | 
| 40 | 
            +
                               'no'
         | 
| 41 | 
            +
                             end
         | 
| 29 42 | 
             
            BLIS_CONFIGURE_OPTIONS = ['--enable-cblas',
         | 
| 30 | 
            -
                                       | 
| 43 | 
            +
                                      "--enable-threading=#{BLIS_THREADING}",
         | 
| 31 44 | 
             
                                      "--prefix=#{VENDOR_DIR}",
         | 
| 45 | 
            +
                                      "CC=#{RB_CC}",
         | 
| 46 | 
            +
                                      "CXX=#{RB_CXX}",
         | 
| 32 47 | 
             
                                      'auto'].join(' ')
         | 
| 33 48 | 
             
            LAPACK_CMAKE_OPTIONS = ["-DBLAS_LIBRARIES='#{VENDOR_DIR}/lib/libblis.#{SOEXT}'",
         | 
| 34 49 | 
             
                                    '-DLAPACKE=ON',
         | 
| 35 50 | 
             
                                    '-DBUILD_SHARED_LIBS=ON',
         | 
| 51 | 
            +
                                    '-DCMAKE_BUILD_TYPE=Release',
         | 
| 36 52 | 
             
                                    "-DCMAKE_INSTALL_PREFIX='#{VENDOR_DIR}'"].join(' ')
         | 
| 37 53 |  | 
| 38 54 | 
             
            unless File.exist?("#{VENDOR_DIR}/installed_blis-#{BLIS_VERSION}")
         | 
    
        data/lib/numo/blis/version.rb
    CHANGED
    
    
    
        metadata
    CHANGED
    
    | @@ -1,14 +1,14 @@ | |
| 1 1 | 
             
            --- !ruby/object:Gem::Specification
         | 
| 2 2 | 
             
            name: numo-blis
         | 
| 3 3 | 
             
            version: !ruby/object:Gem::Version
         | 
| 4 | 
            -
              version: 0. | 
| 4 | 
            +
              version: 0.2.0
         | 
| 5 5 | 
             
            platform: ruby
         | 
| 6 6 | 
             
            authors:
         | 
| 7 7 | 
             
            - yoshoku
         | 
| 8 8 | 
             
            autorequire:
         | 
| 9 9 | 
             
            bindir: exe
         | 
| 10 10 | 
             
            cert_chain: []
         | 
| 11 | 
            -
            date: 2021-07- | 
| 11 | 
            +
            date: 2021-07-31 00:00:00.000000000 Z
         | 
| 12 12 | 
             
            dependencies:
         | 
| 13 13 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 14 14 | 
             
              name: numo-linalg
         | 
| @@ -72,7 +72,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement | |
| 72 72 | 
             
                - !ruby/object:Gem::Version
         | 
| 73 73 | 
             
                  version: '0'
         | 
| 74 74 | 
             
            requirements: []
         | 
| 75 | 
            -
            rubygems_version: 3. | 
| 75 | 
            +
            rubygems_version: 3.2.22
         | 
| 76 76 | 
             
            signing_key:
         | 
| 77 77 | 
             
            specification_version: 4
         | 
| 78 78 | 
             
            summary: Numo::BLIS downloads and builds BLIS during installation and uses that as
         |