Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to 3.8 #5

Merged
merged 43 commits into from
Apr 26, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
43 commits
Select commit Hold shift + click to select a range
ef215a3
updatre blaze from 2.6 to 3.8.2
Apr 1, 2024
7ff5211
re-engineer wrapper and exporter
Apr 1, 2024
64251a8
finish DynamicMatrix, DynamicVector
Apr 1, 2024
a6b297f
rename test, use tinytest instead of RUnit. Complete wrap & as for th…
ChingChuan-Chen Apr 2, 2024
b771654
fix customvector and add test for complex dynamic vector
ChingChuan-Chen Apr 2, 2024
a48d987
add wrap tests for vectors
Apr 2, 2024
58d034f
complete CustomVector with unaligned flag
Apr 3, 2024
f239cf0
update tests
Apr 3, 2024
1ad48ac
Aligned CustomVector will need help
Apr 3, 2024
64e9338
remove unused test code
Apr 3, 2024
07510ef
add staticvector check
Apr 3, 2024
d4bf92b
fix vector test & matrix SO
Apr 3, 2024
04f06c6
fix tests
Apr 3, 2024
13d1bd3
fix CustomVector Exporter
ChingChuan-Chen Apr 4, 2024
4291884
complete tests for StaticMatrix/HybridMatrix/DynamicMatrix
ChingChuan-Chen Apr 4, 2024
0cae12b
add complex<double> test for DynamicMatrix
ChingChuan-Chen Apr 4, 2024
c66bcab
add CustomMatrix
ChingChuan-Chen Apr 4, 2024
f68447c
change license, reengineer RcppBlazeAs.h
ChingChuan-Chen Apr 7, 2024
73e0d5c
draft of wrapper for CustomMatrix is complete. Testing.
ChingChuan-Chen Apr 7, 2024
407fa25
add CustomMatrix with tests
ChingChuan-Chen Apr 11, 2024
aa09381
CompressedVector and ZeroVector wrapper complete
ChingChuan-Chen Apr 12, 2024
b4ff9e0
add CompressedVector & ZeroVector
ChingChuan-Chen Apr 12, 2024
323de2b
complete ZeroVector wrap and as
ChingChuan-Chen Apr 13, 2024
854fc33
complete IdentityMatrix, UniformMatrix, ZeroMatrix
ChingChuan-Chen Apr 13, 2024
41220c5
wrapper for CompressedMatrix complete
ChingChuan-Chen Apr 13, 2024
721118e
draft for CompressedMatrix
ChingChuan-Chen Apr 16, 2024
f93eec8
efficient copy for TSparseMatrix
ChingChuan-Chen Apr 16, 2024
0248229
fix TSPARSE
ChingChuan-Chen Apr 16, 2024
e9eae6c
finish all base blaze matrix/vector to wrap and as in Rcpp
ChingChuan-Chen Apr 17, 2024
e21bebe
enable fastLmPure
ChingChuan-Chen Apr 17, 2024
43f338a
fix lmBenchmark.R
ChingChuan-Chen Apr 17, 2024
7cbf682
address more on README
ChingChuan-Chen Apr 17, 2024
5b6b3d9
Fix typo
ChingChuan-Chen Apr 17, 2024
10c85b5
modify lmBenchmark.R
ChingChuan-Chen Apr 17, 2024
842fb49
add Band, Row, Column
ChingChuan-Chen Apr 25, 2024
e891647
complete subvector & elements
ChingChuan-Chen Apr 25, 2024
52a2a70
complete submatrix, rows, columns
ChingChuan-Chen Apr 25, 2024
1dbd7ae
add blaze Expression
ChingChuan-Chen Apr 26, 2024
44847a9
fix build
ChingChuan-Chen Apr 26, 2024
216fb63
add ignore
ChingChuan-Chen Apr 26, 2024
d716fa2
fix build
ChingChuan-Chen Apr 26, 2024
70baaa9
update urls
ChingChuan-Chen Apr 26, 2024
b497a57
update date
ChingChuan-Chen Apr 26, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
7 changes: 3 additions & 4 deletions .Rbuildignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
^.*\.Rproj$
^\.Rproj\.user$
.Rhistory
.travis.yml
.git
appveyor.yml
\.Rhistory
\.git
local
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
.Rproj.user
.Rhistory
.RData
src/*.rds
src/*.o
src/*.so
src/*.dll
36 changes: 0 additions & 36 deletions .travis.yml

This file was deleted.

53 changes: 21 additions & 32 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,46 +1,35 @@
Package: RcppBlaze
Type: Package
Title: 'Rcpp' Integration for the 'Blaze' High-Performance C++ Math Library
Version: 0.2.2
Date: 2017-10-08
Version: 1.0.0
Date: 2024-04-27
Author: Ching-Chuan Chen, Klaus Iglberger, Georg Hager, Christian Godenschwager,
Tobias Scharpff, Dirk Eddelbuettel, Romain Francois, Douglas Bates
Maintainer: Ching-Chuan Chen <zw12356@gmail.com>
URL: https://github.com/Chingchuan-chen/RcppBlaze,
https://bitbucket.org/blaze-lib/blaze
BugReports: https://github.com/Chingchuan-chen/RcppBlaze/issues
Description: 'Blaze' is an open-source, high-performance C++ math library
for dense and sparse arithmetic. With its state-of-the-art Smart Expression
Template implementation 'Blaze' combines the elegance and ease of use of a
domain-specific language with 'HPC'-grade performance, making it one of the most
intuitive and fastest C++ math libraries available. The 'Blaze' library offers:
- high performance through the integration of 'BLAS' libraries and manually
tuned 'HPC' math kernels - vectorization by 'SSE', 'SSE2', 'SSE3', 'SSSE3', 'SSE4',
'AVX', 'AVX2', 'AVX-512', 'FMA', and 'SVML' - parallel execution by 'OpenMP', C++11
threads and 'Boost' threads ('Boost' threads are disabled in 'RcppBlaze') - the
intuitive and easy to use API of a domain specific language - unified arithmetic
with dense and sparse vectors and matrices - thoroughly tested matrix and vector
arithmetic - completely portable, high quality C++ source code. The 'RcppBlaze'
package includes the header files from the 'Blaze' library with disabling some
functionalities related to link to the thread and system libraries which make
'RcppBlaze' be a header-only library. Therefore, users do not need to install
'Blaze' and the dependency 'Boost'. 'Blaze' is licensed under the New (Revised)
BSD license, while 'RcppBlaze' (the 'Rcpp' bindings/bridge to 'Blaze') is licensed
under the GNU GPL version 2 or later, as is the rest of 'Rcpp'. Note that since
'Blaze' has committed to 'C++14' commit to 'C++14' which does not used by most R users
from version 3.0, we will use the version 2.6 of 'Blaze' which is 'C++98' compatible
to support the most compilers and system.
Description: Blaze is an open-source, high-performance C++ math library for dense and sparse arithmetic.
With its state-of-the-art Smart Expression Template implementation Blaze combines the elegance and
ease of use of a domain-specific language with HPC-grade performance, making it one of the most
intuitive and fastest C++ math libraries available. The 'RcppBlaze' package includes the header files
from the 'Blaze' library with disabling some functionalities related to link to the thread and system
libraries which make 'RcppBlaze' be a header-only library. Therefore, users do not need to install
'Blaze'.
Depends:
R (>= 3.0.2)
R (>= 4.2.0)
Imports:
utils,
Rcpp (>= 0.11.0),
Matrix (>= 1.1-0)
LinkingTo: Rcpp,
BH (>= 1.54.0-2)
Rcpp (>= 1.0.0),
Matrix (>= 1.5-0)
LinkingTo:
Rcpp
Suggests:
RUnit,
MatrixExtra,
microbenchmark,
tinytest,
pkgKitten
LazyData: yes
License: GPL (>= 2)
RoxygenNote: 6.0.1
LazyLoad: yes
Encoding: UTF-8
License: BSD_3_clause + file LICENSE
RoxygenNote: 7.3.1
2 changes: 2 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
YEAR: 2011-2024
COPYRIGHT HOLDER: Ching-Chuan Chen
1 change: 0 additions & 1 deletion NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ importClassesFrom(Matrix,dgRMatrix)
importClassesFrom(Matrix,lgCMatrix)
importClassesFrom(Matrix,lgRMatrix)
importFrom(Rcpp,Rcpp.plugin.maker)
importFrom(Rcpp,evalCpp)
importFrom(utils,package.skeleton)
importFrom(utils,packageDescription)
useDynLib(RcppBlaze, .registration = TRUE)
7 changes: 7 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
# RcppBlaze v1.0.0

* Update Blaze-lib to 3.8.2 since Rcpp supports C++14 / C++17 since 4.2.0.
* Because of the support of C++14, R need to be >= `4.2.0` to install `RcppBlaze`.
* Enable C++11 Threads when compiling `fastLm`.
* Change to use BSD License which is aligned with `blize-lib`.

# RcppBlaze v0.2.2

* Fix building problem on windows.
Expand Down
78 changes: 23 additions & 55 deletions R/RcppBlaze-package.R
Original file line number Diff line number Diff line change
Expand Up @@ -3,99 +3,67 @@
#' RcppBlaze construct a bridge between R and Blaze.
#'
#' 'Blaze' is an open-source, high-performance C++ math library for dense and sparse arithmetic.
## Copyright (C) 2010 - 2013 Dirk Eddelbuettel, Romain Francois and Douglas Bates
## Copyright (C) 2014 Dirk Eddelbuettel
## Copyright (C) 2017 Chingchuan Chen
## Copyright (C) 2010 - 2024 Dirk Eddelbuettel, Romain Francois and Douglas Bates
## Copyright (C) 2017 - 2024 Ching-Chuan Chen
##
## This file is based on RcppEigen-package.Rd and RcppArmadillo-package.Rd
## from RcppArmadillo and RcppEigen.
## This file is based on files from RcppArmadillo.
## This file is part of RcppBlaze.
##
## RcppBlaze is free software: you can redistribute it and/or modify it
## under the terms of the GNU General Public License as published by
## the Free Software Foundation, either version 2 of the License, or
## (at your option) any later version.
##
## RcppBlaze is distributed in the hope that it will be useful, but
## WITHOUT ANY WARRANTY; without even the implied warranty of
## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
## GNU General Public License for more details.
##
## You should have received a copy of the GNU General Public License
## along with RcppBlaze If not, see <http://www.gnu.org/licenses/>.
## under the terms of the 3-Clause BSD License. You should have received
## a copy of 3-Clause BSD License along with RcppBlaze.
## If not, see https://opensource.org/license/BSD-3-Clause.

#' With its state-of-the-art Smart Expression Template implementation \strong{Blaze} combines the elegance and
#' ease of use of a domain-specific language with HPC-grade performance, making it one of the most
#' intuitive and fastest C++ math libraries available. The \strong{Blaze} library offers:
#' \itemize{
#' \item high performance through the integration of BLAS libraries and manually tuned HPC math kernels
#' \item vectorization by SSE, SSE2, SSE3, SSSE3, SSE4, AVX, AVX2, AVX-512, FMA, and SVML
#' \item parallel execution by OpenMP, C++11 threads and \strong{Boost} threads
#' (\strong{Boost} threads is disables in \strong{RcppBlaze})
#' \item the intuitive and easy to use API of a domain specific language
#' \item unified arithmetic with dense and sparse vectors and matrices
#' \item thoroughly tested matrix and vector arithmetic
#' \item completely portable, high quality C++ source code
#' }
#'
#' The \strong{RcppBlaze} package includes the header files from the \strong{Blaze} library with disabling some
#' functionalities related to link to the thread and system libraries which make \strong{RcppBlaze} be a
#' header-only library. Therefore, users do not need to install \strong{Blaze} and the dependency \strong{Boost}.
#' \strong{Blaze} is licensed under the New (Revised) BSD license, while \strong{RcppBlaze}
#' (the \strong{Rcpp} bindings/bridge to \strong{Blaze}) is licensed under the GNU GPL version 2 or later,
#' as is the rest of \strong{Rcpp}.
#'
#' Note that since \strong{Blaze} has committed to C++14 which does not used by most \strong{R} users from version 3.0,
#' we will use the version 2.6 of \strong{Blaze} which is C++98 compatible to support the most compilers and system.
#'
#' @section Caution:
#' On the windows x64 with \strong{Rtools33}, \strong{Rtools34}, \code{std::ptrdiff_s} is defined as \code{long long unsigned int},
#' so do not direct wrap the dimention of matrix or the size of vector to output in case the compiling error occurs.
#' intuitive and fastest C++ math libraries available. The \strong{RcppBlaze} package includes the header files
#' from the \strong{Blaze} library with disabling some functionalities related to link to the thread and system
#' libraries which make \strong{RcppBlaze} be a header-only library. Therefore, users do not need to install
#' \strong{Blaze}.
#'
#' @section Using RcppBlaze:
#' The simplest way to get started is to create a skeleton of a package
#' using \code{RcppBlaze}. This can be done conveniently by the
#' \code{\link{RcppBlaze.package.skeleton}}
#' function.
#' \code{\link{RcppBlaze.package.skeleton}} function.
#'
#' The important steps are
#' \enumerate{
#' \item Include the \samp{RcppBlaze.h} header file, which also includes \samp{blaze/Blaze.h}.
#' \item Import \code{Rcpp}, LinkingTo \code{Rcpp}, \code{BH} and \code{RcppBlaze} by adding these lines to the \samp{DESCRIPTION} file:
#' \item Import \code{Rcpp}, LinkingTo \code{Rcpp} and \code{RcppBlaze} by adding these lines to the \samp{DESCRIPTION} file:
#' \preformatted{
#' Imports: Rcpp (>= 0.11.0)
#' LinkingTo: Rcpp, BH, RcppBlaze
#' Imports: Rcpp (>= 1.0.0)
#' LinkingTo: Rcpp, RcppBlaze
#' }
#' \item Link against the \code{BLAS} and \code{LAPACK} libraries, by adding following two lines in the \samp{Makevars} and
#' \samp{Makevars.win} files:
#' \item Link against the \code{BLAS} and \code{LAPACK} libraries, by adding following two lines in the \samp{Makevars} and \samp{Makevars.win} files:
#' \preformatted{
#' PKG_LIBS = $(LAPACK_LIBS) $(BLAS_LIBS) $(FLIBS)
#' }
#' }
#'
#' Note that if you would like to enable Boost threads support, you need to import \strong{BH} package in your DESCRIPTION.
#' Note that \code{CompressedVector} and \code{CompressedMatrix} only support \code{int}, \code{float} and \code{double} types.
#'
#' @author
#' For RcppBlaze: Chingchuan Chen
#' Maintainer: Chingchuan Chen <zw12356@gmail.com>
#' For RcppBlaze: Ching-Chuan Chen
#' Maintainer: Ching-Chuan Chen <zw12356@gmail.com>
#' For blaze: Klaus Iglberger, Georg Hager, Christian Godenschwager, Tobias Scharpff
#'
#' @references
#' \enumerate{
#' \item Blaze project: \url{https://bitbucket.org/blaze-lib/blaze}
#' \item K. Iglberger, G. Hager, J. Treibig, and U. Ruede:
#' \href{http://epubs.siam.org/sisc/resource/1/sjoce3/v34/i2/pC42_s1}{
#' \href{https://doi.org/10.1137/110830125}{
#' Expression Templates Revisited: A Performance Analysis of Current Methodologies.}
#' SIAM Journal on Scientific Computing, 34(2): C42--C69, 2012
#' \item K. Iglberger, G. Hager, J. Treibig, and U. Ruede:
#' \href{http://ieeexplore.ieee.org/stamp/stamp.jsp?arnumber=06266939}{
#' \href{https://doi.org/10.1109/HPCSim.2012.6266939}{
#' High Performance Smart Expression Template Math Libraries.}
#' Proceedings of the 2nd International Workshop on New Algorithms and Programming Models
#' for the Manycore Era (APMM 2012) at HPCS 2012
#' }
#'
#' @keywords package interface
#' @docType package
#' @name RcppBlaze-package
#' @useDynLib RcppBlaze, .registration = TRUE
#' @importFrom Rcpp evalCpp
#' @importClassesFrom Matrix dgCMatrix lgCMatrix dgRMatrix lgRMatrix
NULL
"_PACKAGE"
Loading