Forcing multiple threads to use multiple CPUs when they are available

There are two basic ways to multi-thread in Java. Each logical task you create with these methods should run on a fresh core when needed and available. Method one: define a Runnable or Thread object (which can take a Runnable in the constructor) and start it running with the Thread.start() method. It will execute on … Read more

Does python support multiprocessor/multicore programming?

There is no such thing as “multiprocessor” or “multicore” programming. The distinction between “multiprocessor” and “multicore” computers is probably not relevant to you as an application programmer; it has to do with subtleties of how the cores share access to memory. In order to take advantage of a multicore (or multiprocessor) computer, you need a … Read more

Node.js or Erlang

I would give Erlang a try. Even though it will be a steeper learning curve, you will get more out of it since you will be learning a functional programming language. Also, since Erlang is specifically designed to create reliable, highly concurrent systems, you will learn plenty about creating highly scalable services at the same … Read more

Run an Application in GDB Until an Exception Occurs

You can try using a “catchpoint” (catch throw) to stop the debugger at the point where the exception is generated. The following excerpt From the gdb manual describes the catchpoint feature. 5.1.3 Setting catchpoints You can use catchpoints to cause the debugger to stop for certain kinds of program events, such as C++ exceptions or … Read more

What’s the status of multicore programming in Haskell?

In the 2009-2012 period, the following things have happened: 2012: From 2012, the parallel Haskell status updates began appearing in the Parallel Haskell Digest. 2011: Parallel and Concurrent Programming in Haskell, a tutorial. version 1.1 released by Simon Marlow Haskell and parallelism, mentioned in an article in the Economist magazine, Jun 2nd 2011. Parallel tree … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)