You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@systemml.apache.org by lr...@apache.org on 2015/11/19 21:47:29 UTC
[47/50] [abbrv] incubator-systemml git commit: Performance
multi-threaded matrix multiply (thread-local allocation)
Performance multi-threaded matrix multiply (thread-local allocation)
Project: http://git-wip-us.apache.org/repos/asf/incubator-systemml/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-systemml/commit/5be39df5
Tree: http://git-wip-us.apache.org/repos/asf/incubator-systemml/tree/5be39df5
Diff: http://git-wip-us.apache.org/repos/asf/incubator-systemml/diff/5be39df5
Branch: refs/heads/master
Commit: 5be39df53df6a3565553b04b47b91f172a34811c
Parents: 44a718e
Author: Matthias Boehm <mb...@us.ibm.com>
Authored: Sun Nov 15 19:04:29 2015 -0800
Committer: Matthias Boehm <mb...@us.ibm.com>
Committed: Mon Nov 16 01:21:10 2015 -0800
----------------------------------------------------------------------
.../java/com/ibm/bi/dml/runtime/matrix/data/LibMatrixMult.java | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-systemml/blob/5be39df5/src/main/java/com/ibm/bi/dml/runtime/matrix/data/LibMatrixMult.java
----------------------------------------------------------------------
diff --git a/src/main/java/com/ibm/bi/dml/runtime/matrix/data/LibMatrixMult.java b/src/main/java/com/ibm/bi/dml/runtime/matrix/data/LibMatrixMult.java
index bb96751..ebab2c6 100644
--- a/src/main/java/com/ibm/bi/dml/runtime/matrix/data/LibMatrixMult.java
+++ b/src/main/java/com/ibm/bi/dml/runtime/matrix/data/LibMatrixMult.java
@@ -3540,7 +3540,6 @@ public class LibMatrixMult
if( pm2 ) { //vector-matrix / matrix-matrix
//allocate local result for partial aggregation
_ret = new MatrixBlock(ret.rlen, ret.clen, false);
- _ret.allocateDenseBlock();
}
else { //default case
_ret = ret;
@@ -3550,6 +3549,10 @@ public class LibMatrixMult
@Override
public Object call() throws DMLRuntimeException
{
+ //thread-local allocation
+ if( _pm2 )
+ _ret.allocateDenseBlock();
+
//compute block matrix multiplication
if( _m1.isUltraSparse() || _m2.isUltraSparse() )
matrixMultUltraSparse(_m1, _m2, _ret, _rl, _ru);