Re: Concurrency-interest Digest, Vol 15, Issue 11

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Re: Concurrency-interest Digest, Vol 15, Issue 11

Mike Edwards-2

Peter,

In general, modern JVM implementations use the threading system provided by the
operating system.  As a result when you're using multiple threads in Java, the threads
are distributed to the processor cores by the OS, which typically mean that they are
run on whichever core is available.

So your colleague is incorrect on this point.  Tell him to go look at the SpecJBB
scores on the spec website, which show virtually linear scaling of Java running on large
multiprocessor systems with eg 128 cores. (www.spec.org).

The funny thing is that there is some demand from modern system designs to do things
differently - there is increasing use of NUMA style architectures, where performance of
access to memory varies depending on which processor and which section of memory
is involved.  This implies that it may benefit performance by running a thread on a
processor that is "close" to the memory it references.  Java is not so good at doing
this because of the nature of the Java Heap - the heap typically spans some large
block of memory and a thread can access objects anywhere in the heap.....


Yours,  Mike.

Strategist - Emerging Technologies.
IBM Hursley Park, Mail Point 146, Winchester, SO21 2JN, Great Britain.

> Date: Wed, 12 Apr 2006 14:47:39 +0100
> From: "Peter Veentjer" <[hidden email]>
> Subject: [concurrency-interest] multi core/cpu systems and Java
> To: [hidden email]
> Message-ID:
>    <[hidden email]>
> Content-Type: text/plain; charset=ISO-8859-1
>
> I have a question about multicore/multicpu processors (and especially
> the Intel and AMD processors) and Java and threads.
>
> The question is:
> are Java threads (of a single vm) executed on all core`s or are they
> bound to a single cpu?
> With other words: if you are executing a single cpu-bound application,
> do you get any benefits of a multicore system? The most logical answer
> would be yes.. but a colleague claims that java threads are bound to a
> single cpu so you won't get any performance gain.
>
> The operating systems are: Windows and Linux 2.6 and the vm is the
> standard 5.0 version from Sun.

_______________________________________________
Concurrency-interest mailing list
[hidden email]
http://altair.cs.oswego.edu/mailman/listinfo/concurrency-interest