[Simh] SimH and multi-core host processors

Mark Pizzolato - Info Comm Mark at infocomm.com
Wed Jul 15 13:21:20 EDT 2015


Hi Gary,

On Tuesday, July 14, 2015 at 8:08 PM, Gary Lee Phillips wrote:
> I just looked through the introductory documents and found no mention
> of running SimH emulations on hosts with multi-core processors. Is
> SimH aware of the fact that it is running on such a CPU?

Not specifically.  

> I downloaded the OpenBSD for vax CD image yesterday. Having a
> Raspberry Pi 2 Model B sitting here and not getting much use, I
> decided (probably foolishly) to use it to install OpenBSD to a vax
> disk image file. I have SimH 3.8.1 on the Pi, which has an ARM V7 quad
> core processor and 1GB of RAM. I had copied my VAX configuration file
> over from a single core Linux machine, and modified that to set up for
> the OpenBSD install.
> 
> Normally on a single core 32-bit machine I use "set throttle 60%" to
> avoid overloading the system if the SimH emulated machine becomes
> compute bound or starts idle looping.

Simh v3.8-1 did not detect idle for OpenBSD operating systems.  The latest github codebase does.  Throttling will probably not be necessary anywhere.

> I was surprised at how slow the OpenBSD installation routine ran. In
> fact, once I got it going, it has been running for over 24 hours now
> and is still unpacking required system files from the compressed tar
> (.tgz) archive files on the CD. Progress is made, but slowly. Tonight
> it dawned on me to check the CPU utlization meter on the Linux host.
> Sure enough, with only the installation running on SimH, the CPU was
> limited at 15% utlization and would not go above that level. If one
> core is 25% of the whole CPU capability, and I use only a maximum of
> 60% of one core, that comes out to 15%, the point at which the system
> throttles back whether it is busy or not. So, I'm guessing, if I
> remove the "set throttle" statement from the configuration, the
> maximum CPU capability SimH will use for a single instance is still
> limited to 25% of the machine's total capability. Does that make
> sense?
> 
> I will test this myself, but can't do so until I finish with
> installing OpenBSD.

As Olaf already said, you can stop simulation any time with ^E and disable throttling and resume.

> Is there any way to get a single instance of SimH to run across
> multiple cores? Or is it just single threaded so it is limited to
> running on a single core at any time?

It is not clear how or what you would expect to happen here.  Simulating a single CPU can only be done with a single core.

Apart from instruction execution, the latest code in the github codebase DOES have support to perform disk, tape  and network activities asynchronously (in separate threads).  This can significantly increase the simulation throughput of  many workloads without regard to the number of cores on the host platform.  If multiple cores are available and the system isn't otherwise idle, then CPU instruction simulation can be done concurrently with the I/O setup and completion on other cores. 

The github codebase is at https://github.com/simh/simh/archive/master.zip

- Mark


More information about the Simh mailing list