Skip to content

ScalaCL: OutOfResources on simple loop over test code #17

Open
@ochafik

Description

@ochafik

From @lostmsu on April 27, 2012 7:5

import scalacl._

object OpenCLTest {
  def main(args: Array[String]): Unit ={
    implicit val context = Context.best
    val rng = (100 until 100000).cl
    for(i <- 1 to 1000){
      val sum = rng.map(_ * 2).zipWithIndex.map(p => p._1 * p._2).sum
      print(i + ": ")
      println("sum = " + sum)
    }
  }
}

Copied from original issue: nativelibs4java/nativelibs4java#309

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions