a Chinese writer

Thoughts on Module 1 ” Fundamentals of comuputer systems”

Hi everyone!

I noticed something interesting: hardware interrupts seem to serve a similar purpose as multiprogramming.

We learned that when there is an I/O request, the processor doesn’t have to stop executing other instructions and wait. Instead, it pauses its current task and handles the I/O request only when a hardware interrupt notifies it. This allows the processor to run more efficiently.

Similarly, multiprogramming achieves the same goal. While one program requests an I/O operation and has to wait for it to complete, the operating system selects another program to execute. Once the I/O is done, the OS resumes the original program. This ensures that the processor stays busy executing instructions while I/O controllers and devices perform their tasks, leading to more efficient use of hardware resources.

So I have a couple of questions to think about and share with you:

What is the functional difference between hardware interrupts and multiprogramming?

What is the difference and relationship between the CPU and the operating system when it comes to handling I/O services?

    Thank you!

    Reply one:

    I use both a Mac and an iPhone as well. I’ve used other kinds of computers and Android phones in the past, so I can really tell how smooth MacOS is. I may not be able to give specific examples like you did, but the difference is clear to me.

    Also, considering their high quality and convenience, they aren’t actually that expensive.
    In my view, user experience(UX)should be considered a top priority in technology design. And since we are studying IT, I’m also very interested in learning more about why Apple’s OS and technologies perform so well and how they can consistently stay ahead of the competition.

    Reply two:

    Your explanation is quite clear, and the references are great!

    Hardware interrupts require external devices to notify the CPU that data from external events is ready to be handled and needs immediate attention.

    In multiprogramming, however, the operating system chooses to work on Program B while Program A is waiting for I/O operations. It will resume working on Program A based on the scheduling algorithm, which may or may not be immediate. This is a form of multiprogramming scheduling and management and does not necessarily involve external devices or signals.

    This brings up another question: what is the relationship between the CPU and the operating system?

    I know the CPU is part of the hardware system, and the operating system is system software. But I think the OS acts as the manager, deciding what the CPU should do and how to do it. Right? As I mentioned above, multiprogramming scheduling and management, which ensures efficient utilisation of the CPU.

    留下评论