4 ms·
Having a dedicated processor for each object is a terrible idea in terms of energy. Consider current high-core count Intel processors on Windows. Windows shuts
by cjensen 10y ago
Having a dedicated processor for each object is a terrible idea in terms of energy.
Consider current high-core count Intel processors on Windows. Windows shuts down entire cores to save energy. Windows only powers enough cores to cover your current workload plus some margin. I assume other OSs work the same.
If each object has its own processor, then either (1) you must keep the core powered for the lifetime of the object or (2) the core must be energized each time the object receives a message, and re-energizing is not free.
I guess if the core could auto-detect its load (as current Intel processors do) that would help. But I think dynamically shuttling threads between cores and shutting down as much as possible (which is exactly what Windows does) is likely to be much more efficient.
So go ahead and have a thread-per-object for this hypothetical architecture, but let the OS decide when and where to assign cores.
- BuuQu9hu 10y agoYou don't want this at the object level anyway. You want to have objects clumped into vats, which are related object graphs that are isolated from other vats but freely intermingle otherwise. Then, messages between vats invoke turns of delivery inside vats independent of other vats, and we can schedule one vat per processor.