Skip to main content
added 1022 characters in body
Source Link
Justme
  • 37.2k
  • 1
  • 85
  • 169

The x86 CPUs has had a HLT instruction ever since 8088. So it's the CPU tha halts, not a PC or anything else around the CPU, be it in a PC or any other type of computer.

It simply makes the CPU to pause or stop execution, until the CPU is reset or there is an interrupt request - which of course requires that interrupts are left enabled on the CPU and interrupt controller, and some peripheral is actually requesting an interrupt (such as system timer). So if you disable interrupts with CLI before running HLT, the CPU will never come out of halt state unless you push the reset button or turn it off.

Having a CPU instruction to halt display generation is impossible, PC video adapters keep doing what they were doing unless they are programmed to do something else like not to generate video, but that won't be a single CPU instruction, simply IO register writes like you normally would write video card registers.

In short, there cannot be a single x86 CPU instruction that would blank a display in a PC. It's not the job of CPU to have anything to do with display generation on PCs, it's the job of the video adapter and the program code that executes on the CPU can affect the display generation with standard IO and memory accesses.

If you wanted, you could make some program code that controls the display adapter to disable itself somehow, such as output blank screen without cursor or anything, or even stop outputing sync pulses to the display. That's actually how DPMS monitors know when to sleep and in which mode, depending on if H or V sync or both are missing. ThwThe next thing your program could do is to run CLI and HLT to halt CPU until powered off or reset.

TVs also did really turn off instead of just going blank. When turned off, or in standby, there will be no power on CRT driving circuits, i.e. the electron gun and deflection coils. It would make no sense to keep scanning the display with black lines when it is supposed to be off.

Edit to be crystal clear on this : there is no single CPU instruction that will make a whole PC computer with all it's subsystems halt. The HLT instruction is just for the CPU like any other instruction and it just halts the CPU. Other parts of the PC such as timers, interrupt controllers, DMA controllers, real-time clocks, video adapter, sound card, etc keep doing what they where programmed to do by the CPU, so these subsystems don't care if the CPU is executing calculations, running an idle loop, or halted.

Therefore, if you execute a CLI and HLT in the middle of a DOS game loading from floppy, you will get frozen video showing a static frame buffer, maybe looping audio sample buffer or sample playback stops after the current buffer depending on sound card and how it was set up play with DMA, stuck FM or MIDI notes that continue to play forever, floppy drive motor left turned on as there is no CPU counting timer interrupts and controlling the floppy motor to turn off after a few seconds of idling.

The x86 CPUs has had a HLT instruction ever since 8088. So it's the CPU tha halts, not a PC or anything else around the CPU, be it in a PC or any other type of computer.

It simply makes the CPU to pause or stop execution, until the CPU is reset or there is an interrupt request - which of course requires that interrupts are left enabled on the CPU and interrupt controller, and some peripheral is actually requesting an interrupt (such as system timer). So if you disable interrupts with CLI before running HLT, the CPU will never come out of halt state unless you push the reset button or turn it off.

Having a CPU instruction to halt display generation is impossible, PC video adapters keep doing what they were doing unless they are programmed to do something else like not to generate video, but that won't be a single CPU instruction, simply IO register writes like you normally would write video card registers.

In short, there cannot be a single x86 CPU instruction that would blank a display in a PC. It's not the job of CPU to have anything to do with display generation on PCs, it's the job of the video adapter and the program code that executes on the CPU can affect the display generation with standard IO and memory accesses.

If you wanted, you could make some program code that controls the display adapter to disable itself somehow, such as output blank screen without cursor or anything, or even stop outputing sync pulses to the display. That's actually how DPMS monitors know when to sleep and in which mode, depending on if H or V sync or both are missing. Thw next thing your program could do is to run CLI and HLT to halt CPU until powered off or reset.

TVs also did really turn off instead of just going blank. When turned off, or in standby, there will be no power on CRT driving circuits, i.e. the electron gun and deflection coils. It would make no sense to keep scanning the display with black lines when it is supposed to be off.

The x86 CPUs has had a HLT instruction ever since 8088. So it's the CPU tha halts, not a PC or anything else around the CPU, be it in a PC or any other type of computer.

It simply makes the CPU to pause or stop execution, until the CPU is reset or there is an interrupt request - which of course requires that interrupts are left enabled on the CPU and interrupt controller, and some peripheral is actually requesting an interrupt (such as system timer). So if you disable interrupts with CLI before running HLT, the CPU will never come out of halt state unless you push the reset button or turn it off.

Having a CPU instruction to halt display generation is impossible, PC video adapters keep doing what they were doing unless they are programmed to do something else like not to generate video, but that won't be a single CPU instruction, simply IO register writes like you normally would write video card registers.

In short, there cannot be a single x86 CPU instruction that would blank a display in a PC. It's not the job of CPU to have anything to do with display generation on PCs, it's the job of the video adapter and the program code that executes on the CPU can affect the display generation with standard IO and memory accesses.

If you wanted, you could make some program code that controls the display adapter to disable itself somehow, such as output blank screen without cursor or anything, or even stop outputing sync pulses to the display. That's actually how DPMS monitors know when to sleep and in which mode, depending on if H or V sync or both are missing. The next thing your program could do is to run CLI and HLT to halt CPU until powered off or reset.

TVs also did really turn off instead of just going blank. When turned off, or in standby, there will be no power on CRT driving circuits, i.e. the electron gun and deflection coils. It would make no sense to keep scanning the display with black lines when it is supposed to be off.

Edit to be crystal clear on this : there is no single CPU instruction that will make a whole PC computer with all it's subsystems halt. The HLT instruction is just for the CPU like any other instruction and it just halts the CPU. Other parts of the PC such as timers, interrupt controllers, DMA controllers, real-time clocks, video adapter, sound card, etc keep doing what they where programmed to do by the CPU, so these subsystems don't care if the CPU is executing calculations, running an idle loop, or halted.

Therefore, if you execute a CLI and HLT in the middle of a DOS game loading from floppy, you will get frozen video showing a static frame buffer, maybe looping audio sample buffer or sample playback stops after the current buffer depending on sound card and how it was set up play with DMA, stuck FM or MIDI notes that continue to play forever, floppy drive motor left turned on as there is no CPU counting timer interrupts and controlling the floppy motor to turn off after a few seconds of idling.

added 114 characters in body
Source Link
Justme
  • 37.2k
  • 1
  • 85
  • 169

The x86 CPUs has had a HLT instruction ever since 8088. So it's the CPU tha halts, not a PC or anything else around the CPU, be it in a PC or any other type of computer.

It simply makes the CPU to pause or stop execution, until the CPU is reset or there is an interrupt request - which of course requires that interrupts are left enabled on the CPU and interrupt controller, and some peripheral is actually requesting an interrupt (such as system timer). So if you disable interrupts with CLI before running HLT, the CPU will never come out of halt state unless you push the reset button or turn it off.

Having a CPU instruction to halt display generation is impossible, PC video adapters keep doing what they were doing unless they are programmed to do something else like not to generate video, but that won't be a single CPU instruction, simply IO register writes like you normally would write video card registers.

In short, there cannot be a single x86 CPU instruction that would blank a display in a PC. It's not the job of CPU to have anything to do with display generation on PCs, it's the job of the video adapter and the program code that executes on the CPU can affect the display generation with standard IO and memory accesses.

If you wanted, you could make some program code that controls the display adapter to disable itself somehow, such as output blank screen without cursor or anything, or even stop outputing sync pulses to the display. That's actually how DPMS monitors know when to sleep and in which mode, depending on if H or V sync or both are missing. Thw next thing your program could do is to run CLI and HLT to halt CPU until powered off or reset.

TVs also did really turn off instead of just going blank. When turned off, or in standby, there will be no power on CRT driving circuits, i.e. the electron gun and deflection coils. It would make no sense to keep scanning the display with black lines when it is supposed to be off.

The x86 CPUs has had a HLT instruction ever since 8088.

It simply makes the CPU to pause or stop execution, until the CPU is reset or there is an interrupt request - which of course requires that interrupts are left enabled on the CPU and interrupt controller, and some peripheral is actually requesting an interrupt (such as system timer). So if you disable interrupts with CLI before running HLT, the CPU will never come out of halt state unless you push the reset button or turn it off.

Having a CPU instruction to halt display generation is impossible, PC video adapters keep doing what they were doing unless they are programmed to do something else like not to generate video, but that won't be a single CPU instruction, simply IO register writes like you normally would write video card registers.

In short, there cannot be a single x86 CPU instruction that would blank a display in a PC. It's not the job of CPU to have anything to do with display generation on PCs, it's the job of the video adapter and the program code that executes on the CPU can affect the display generation with standard IO and memory accesses.

If you wanted, you could make some program code that controls the display adapter to disable itself somehow, such as output blank screen without cursor or anything, or even stop outputing sync pulses to the display. That's actually how DPMS monitors know when to sleep and in which mode, depending on if H or V sync or both are missing. Thw next thing your program could do is to run CLI and HLT to halt CPU until powered off or reset.

TVs also did really turn off instead of just going blank. When turned off, or in standby, there will be no power on CRT driving circuits, i.e. the electron gun and deflection coils. It would make no sense to keep scanning the display with black lines when it is supposed to be off.

The x86 CPUs has had a HLT instruction ever since 8088. So it's the CPU tha halts, not a PC or anything else around the CPU, be it in a PC or any other type of computer.

It simply makes the CPU to pause or stop execution, until the CPU is reset or there is an interrupt request - which of course requires that interrupts are left enabled on the CPU and interrupt controller, and some peripheral is actually requesting an interrupt (such as system timer). So if you disable interrupts with CLI before running HLT, the CPU will never come out of halt state unless you push the reset button or turn it off.

Having a CPU instruction to halt display generation is impossible, PC video adapters keep doing what they were doing unless they are programmed to do something else like not to generate video, but that won't be a single CPU instruction, simply IO register writes like you normally would write video card registers.

In short, there cannot be a single x86 CPU instruction that would blank a display in a PC. It's not the job of CPU to have anything to do with display generation on PCs, it's the job of the video adapter and the program code that executes on the CPU can affect the display generation with standard IO and memory accesses.

If you wanted, you could make some program code that controls the display adapter to disable itself somehow, such as output blank screen without cursor or anything, or even stop outputing sync pulses to the display. That's actually how DPMS monitors know when to sleep and in which mode, depending on if H or V sync or both are missing. Thw next thing your program could do is to run CLI and HLT to halt CPU until powered off or reset.

TVs also did really turn off instead of just going blank. When turned off, or in standby, there will be no power on CRT driving circuits, i.e. the electron gun and deflection coils. It would make no sense to keep scanning the display with black lines when it is supposed to be off.

added 331 characters in body
Source Link
Justme
  • 37.2k
  • 1
  • 85
  • 169

The x86 CPUs has had a HLT instruction ever since 8088.

It simply makes the CPU to pause or stop execution, until the CPU is reset or there is an interrupt request - which of course requires that interrupts are left enabled on the CPU and interrupt controller, and some peripheral is actually requesting an interrupt (such as system timer). So if you disable interrupts with CLI before running HLT, the CPU will never come out of halt state unless you push the reset button or turn it off.

Having a CPU instruction to halt display generation is impossible, PC video adapters keep doing what they were doing unless they are programmed to do something else like not to generate video, but that won't be a single CPU instruction, simply IO register writes like you normally would write video card registers.

In short, there cannot be a single x86 CPU instruction that would blank a display in a PC. It's not the job of CPU to have anything to do with display generation on PCs, it's the job of the video adapter and the program code that executes on the CPU can affect the display generation with standard IO and memory accesses.

If you wanted, you could make some program code that controls the display adapter to disable itself somehow, such as output blank screen without cursor or anything, or even stop outputing sync pulses to the display. That's actually how DPMS monitors know when to sleep and in which mode, depending on if H or V sync or both are missing. Thw next thing your program could do is to run CLI and HLT to halt CPU until powered off or reset.

TVs also did really turn off instead of just going blank. When turned off, or in standby, there will be no power on CRT driving circuits, i.e. the electron gun and deflection coils. It would make no sense to keep scanning the display with black lines when it is supposed to be off.

The x86 has had a HLT instruction ever since 8088.

It simply makes the CPU to pause or stop execution, until the CPU is reset or there is an interrupt request - which of course requires that interrupts are left enabled on the CPU and interrupt controller, and some peripheral is actually requesting an interrupt (such as system timer). So if you disable interrupts with CLI before running HLT, the CPU will never come out of halt state unless you push the reset button or turn it off.

Having a CPU instruction to halt display generation is impossible, PC video adapters keep doing what they were doing unless they are programmed to do something else like not to generate video, but that won't be a single CPU instruction, simply IO register writes like you normally would write video card registers.

TVs also did really turn off instead of just going blank. When turned off, or in standby, there will be no power on CRT driving circuits, i.e. the electron gun and deflection coils. It would make no sense to keep scanning the display with black lines when it is supposed to be off.

The x86 CPUs has had a HLT instruction ever since 8088.

It simply makes the CPU to pause or stop execution, until the CPU is reset or there is an interrupt request - which of course requires that interrupts are left enabled on the CPU and interrupt controller, and some peripheral is actually requesting an interrupt (such as system timer). So if you disable interrupts with CLI before running HLT, the CPU will never come out of halt state unless you push the reset button or turn it off.

Having a CPU instruction to halt display generation is impossible, PC video adapters keep doing what they were doing unless they are programmed to do something else like not to generate video, but that won't be a single CPU instruction, simply IO register writes like you normally would write video card registers.

In short, there cannot be a single x86 CPU instruction that would blank a display in a PC. It's not the job of CPU to have anything to do with display generation on PCs, it's the job of the video adapter and the program code that executes on the CPU can affect the display generation with standard IO and memory accesses.

If you wanted, you could make some program code that controls the display adapter to disable itself somehow, such as output blank screen without cursor or anything, or even stop outputing sync pulses to the display. That's actually how DPMS monitors know when to sleep and in which mode, depending on if H or V sync or both are missing. Thw next thing your program could do is to run CLI and HLT to halt CPU until powered off or reset.

TVs also did really turn off instead of just going blank. When turned off, or in standby, there will be no power on CRT driving circuits, i.e. the electron gun and deflection coils. It would make no sense to keep scanning the display with black lines when it is supposed to be off.

Source Link
Justme
  • 37.2k
  • 1
  • 85
  • 169
Loading