Dear list,

I am working with some large image files (111MB) and I want to save the data
in an x10 Array. It takes a long time to load the data from the storage (5s)
using FileReader.readByte(), hear is a code snippet:

// open file
val fileobject = new File(file);
val filereader = fileobject.openRead();
...
// read array data
val arr = new Array[Byte]([0..width-1, 0..height-1]);
for((i,j) in arr) {
  arr(i,j) = filereader.readByte();
}

If I use X10_NTHREADS=1 this code three times faster than X10_NTHREADS=4. I
work on a Intel Quadcore machine and I want to use 4 threads in later
computations. Are there some possibilities to accelerate the IO task? Maybe
with loop chunking or memory mapped files?

Thanks,
Sascha
------------------------------------------------------------------------------
Sell apps to millions through the Intel(R) Atom(Tm) Developer Program
Be part of this innovative community and reach millions of netbook users 
worldwide. Take advantage of special opportunities to increase revenue and 
speed time-to-market. Join now, and jumpstart your future.
http://p.sf.net/sfu/intel-atom-d2d
_______________________________________________
X10-users mailing list
X10-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/x10-users

Reply via email to