[MLton] Multicore CPU's and MLton

Matthew Fluet fluet@cs.cornell.edu
Sun, 3 Jul 2005 14:44:41 -0400 (EDT)


> Anway, I was wondering is there any quick and dirty way for MLton to 
> take advantage of that extra core... SML/NJ CM has a parallel build.. 
> option which is nice.. 

But SML/NJ's parallel build just launches a separate sml process and 
coordinates which source files it should compile.  I.e., it is process 
level parallelism, not thread level or even SML function level 
parallelism.

> but it seems like the whole program approach to 
> MLton seems to be in conflict with the hardware CPU trends... 

Perhaps; I don't actually understand multi-core...  From the application 
level, do they look any different than a SMP system?  Which is to say, 
I've been running dual processor systems for over 5 years now, and I've 
never felt like I needed more parallelism in any application.  I want 
multi-processors so that I can run multi processes -- a mlton build, xmms, 
oggenc, mythtv, etc. -- simultaneously.

Anyways, I just don't get the hype around multi-core, because it seems to 
have started this frenzy that suggests that there is all this parallelism 
that has just been languishing due to the lack of sufficient processing 
units -- when, it's just the opposite.  We can't even keep a modern 
processor's pipeline full for more than a few cycles at a time, let along 
more than one.

> On, a related note. are there any cool opitmizations that could be 
> applied to make ML programs more concurent in a some what transparent 
> way. 

Perhaps.  The mostly-functional nature of ML seems to suggest that it is 
parallelizable, but not that even pH (parallel Haskell) didn't make much 
headway.

> Multi-core systems with lots of concurent threads seem to be the 
> future.

I'll believe it when I see it.