1) Do Python, Ruby or Haskell support true multithreading?
This has nothing to do with language. We are talking about hardware (if there is only 1 processor on the computer, it is simply physically impossible to execute two instructions at the same time), the operating system (again, if the OS does not support true multithreading, there is nothing you can do) and the language execution / execution mechanism.
If a language specification explicitly prohibits or applies true multithreading, this has absolutely nothing to do with the language.
All the languages you mention, plus all the languages mentioned in the answers so far, have several implementations, some of which support true multithreading, some not, and some of them are built on top of other execution mechanisms that may or may not support true multithreading.
Take Ruby, for example. Here are just a few of its implementations and their stream models:
- MRI: green threads, no true multithreading
- YARV: OS threads, no true multithreading
- Rubinius: OS threads, true multithreading
- MacRuby: OS threads, true multithreading
- JRuby, XRuby: JVM threads, depends on the JVM (if the JVM supports true multithreading, then JRuby / XRuby too, if the JVM does not, then there is nothing you can do about it)
- IronRuby, Ruby.NET: like JRuby, XRuby, but in the CLI, not in the JVM
See also my answer to another similar question about Ruby . (Note that this answer is over a year old, and some of them are no longer accurate. Rubinius, for example, now uses real parallel native threads instead of real parallel green threads. In addition, since then several new Ruby implementations have such as BlueRuby, tinyrb , Ruby Go Lightly, Red Sun, and SmallRuby.)
Similarly for Python:
- CPython: native threads, no true multithreading
- PyPy: native threads, depends on the execution mechanism (PyPy can be run initially either on top of the JVM or on top of the CLI or on top of another Python execution mechanism. Whenever the underlying platform supports true multithreading, PyPy too.)
- Unladen Swallow: native threads, there is currently no true multithreading, but a fix is planned
- Jython: JVM threads, see JRuby
- IronPython: CLI threads, see IronRuby
For Haskell, at least the Glorious Glasgow Haskell Compiler supports true multithreading with native threads. I do not know about UHC, LHC, JHC, YHC, HUGS or everyone else.
For Erlang, both BEAM and HiPE support true multithreading with green threads.
2) If the program contains threads, will the virtual machine automatically assign work to several cores (or physical CPUs if the motherboard has more than 1 CPU)?
Again: this depends on the virtual machine, operating system, and hardware. In addition, some of the implementations mentioned above do not even have virtual machines.